diff --git a/src/components/xAvatar/index.vue b/src/components/xAvatar/index.vue index 47b5154..aa77c77 100644 --- a/src/components/xAvatar/index.vue +++ b/src/components/xAvatar/index.vue @@ -22,12 +22,15 @@ export default { props: { data: { type: Object, default: () => { } }, - options: { type: Object, default: () => { } }, + options: { + type: Object, default: () => ({ + subfield: 'nickname' + }) + }, name: { type: String, default: "avatar" }, }, data() { return { - // data: this.modelValue, copiedData: this.data, visible: false, } diff --git a/src/components/xTable/columnItem.vue b/src/components/xTable/columnItem.vue index a7a6a11..27e051e 100644 --- a/src/components/xTable/columnItem.vue +++ b/src/components/xTable/columnItem.vue @@ -58,13 +58,12 @@ export default { // 打开新窗口链接 if (item.open && item.open.name && row[item.open.name]?.trim()) { - window.open(row[item.open.name], "_blank"); + window.open(row[item.open.name], item.open.target || "_blank"); return; } // 打开编辑层 else if (item.update && (item.update.url || item.update.name)) { - var options = Object.assign({ name: item.update.name || item.label, remoteurl: item.update.url || 'table/getUpdate?name=' + item.update.name }, item.update); - this.$emit('xtablehandleClick', row, options, 'update'); + this.$emit('xtablehandleClick', row, Object.assign({ name: item.update.name || item.label, remoteurl: item.update.url || 'table/getUpdate?name=' + item.update.name }, item.update), 'update'); return; } // 统计 @@ -74,10 +73,7 @@ export default { } // 打开表格 else if (item.table && (item.table.url || item.table.name)) { - this.$emit('xtablehandleClick', row, { - name: item.table.name || item.name, - remoteurl: item.table.url || 'table/get?name=' + item.table.name - }, item.table.type || 'dialog', 'table'); + this.$emit('xtablehandleClick', row, Object.assign({ name: item.table.name || item.label, remoteurl: item.table.url || 'table/get?name=' + item.table.name }, item.table), 'table'); return; } else if (item.http && item.http.url && item.http.key && String(row[item.http.key])?.trim()) { diff --git a/src/components/xTable/index.vue b/src/components/xTable/index.vue index fd38061..54369d5 100644 --- a/src/components/xTable/index.vue +++ b/src/components/xTable/index.vue @@ -34,9 +34,9 @@ - + - +