Merge pull request #2926 from jumpserver/pr@dev@perf_table_export_mfa

perf: 优化列表导出mfa验证弹窗逻辑
This commit is contained in:
老广
2023-03-15 19:30:34 +08:00
committed by GitHub
2 changed files with 3 additions and 3 deletions

View File

@@ -159,8 +159,7 @@ export default {
},
mounted() {
this.$eventBus.$on('showExportDialog', ({ selectedRows, url, name }) => {
// Todo: 没有时间了,只能先这么处理了
if (url === this.url || url.indexOf(this.url) > -1 || url.indexOf('account') > -1) {
if (url === this.url || url.indexOf(this.url) > -1) {
this.showExportDialog()
}
})

View File

@@ -37,7 +37,8 @@ export default {
handleExportClick: {
type: Function,
default: function({ selectedRows }) {
this.$eventBus.$emit('showExportDialog', { selectedRows, url: this.tableUrl, name: this.name })
const option = assignIfNot(this.exportOptions, { url: this.tableUrl })
this.$eventBus.$emit('showExportDialog', { selectedRows, url: option.url, name: this.name })
}
},
hasImport: defaultTrue,