From 2a97a511646ba9ff6437de6cd17bcb38f249fbd6 Mon Sep 17 00:00:00 2001 From: fit2cloud-chenyw Date: Thu, 25 Aug 2022 14:59:25 +0800 Subject: [PATCH 01/16] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF-=E8=BF=87?= =?UTF-8?q?=E6=BB=A4=E5=99=A8=E6=8C=89=E9=92=AE):=20=E6=B8=85=E7=A9=BA?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E5=8F=AF=E4=BB=A5=E6=8B=96=E5=85=A5=E5=A4=9A?= =?UTF-8?q?=E4=B8=AA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../canvas/components/Editor/SettingMenu.vue | 10 +++++ .../canvas/custom-component/UserView.vue | 2 +- frontend/src/utils/conditionUtil.js | 1 - frontend/src/views/panel/filter/index.vue | 39 ++++--------------- 4 files changed, 19 insertions(+), 33 deletions(-) diff --git a/frontend/src/components/canvas/components/Editor/SettingMenu.vue b/frontend/src/components/canvas/components/Editor/SettingMenu.vue index 03f610bc6f..8bf5c7dfec 100644 --- a/frontend/src/components/canvas/components/Editor/SettingMenu.vue +++ b/frontend/src/components/canvas/components/Editor/SettingMenu.vue @@ -135,6 +135,16 @@ export default { }, deleteComponent() { + if (this.curComponent.type === 'custom-button' && this.curComponent.serviceName === 'buttonSureWidget') { + let len = this.componentData.length + while (len--) { + const item = this.componentData[len] + + if (item.type === 'custom-button' && item.serviceName === 'buttonResetWidget') { + this.componentData.splice(len, 1) + } + } + } this.$emit('amRemoveItem') this.deleteCurCondition() this.$store.commit('deleteComponent') diff --git a/frontend/src/components/canvas/custom-component/UserView.vue b/frontend/src/components/canvas/custom-component/UserView.vue index 10a4e25df5..6805b544de 100644 --- a/frontend/src/components/canvas/custom-component/UserView.vue +++ b/frontend/src/components/canvas/custom-component/UserView.vue @@ -368,7 +368,7 @@ export default { }, 'cfilters': { handler: function(val1, val2) { - if (isChange(val1, val2) && !this.isFirstLoad) { + if ((isChange(val1, val2) || isChange(val1, this.filters)) && !this.isFirstLoad) { this.getData(this.element.propValue.viewId) } }, diff --git a/frontend/src/utils/conditionUtil.js b/frontend/src/utils/conditionUtil.js index a9b8dc42ac..5cbd3ecbea 100644 --- a/frontend/src/utils/conditionUtil.js +++ b/frontend/src/utils/conditionUtil.js @@ -100,7 +100,6 @@ export const buildFilterMap = panelItems => { let result = buildViewKeyMap(panelItems) result = buildViewKeyFilters(panelItems, result) - fillElementsFilter(panelItems, result) return result } diff --git a/frontend/src/views/panel/filter/index.vue b/frontend/src/views/panel/filter/index.vue index a99b39cf2a..49e3f0bc5a 100644 --- a/frontend/src/views/panel/filter/index.vue +++ b/frontend/src/views/panel/filter/index.vue @@ -9,9 +9,9 @@ v-for="(widget, index) in item" :key="widget.widgetName+index" :data-id="widget.widgetName" - :draggable="(widget.widgetName !== 'buttonSureWidget' && widget.widgetName !== 'buttonResetWidget') || (widget.widgetName === 'buttonSureWidget' && !searchButtonExist) || (widget.widgetName === 'buttonResetWidget' && searchButtonExist)" + :draggable="(widget.widgetName !== 'buttonSureWidget' && widget.widgetName !== 'buttonResetWidget') || (widget.widgetName === 'buttonSureWidget' && !searchButtonExist) || (widget.widgetName === 'buttonResetWidget' && searchButtonExist && !resetButtonExist)" :data-index="index" - :class="'filter-widget '+ (widget.defaultClass || '')" + :class="('filter-widget '+ (widget.widgetName === 'buttonSureWidget' ? sureButtonClass : widget.widgetName === 'buttonResetWidget' ? resetButtonClass : widget.defaultClass))" >
@@ -74,38 +74,15 @@ export default { resetButtonExist() { return this.componentData && this.componentData.some(component => component.type === 'custom-button' && component.serviceName === 'buttonResetWidget') }, - resetButtonDisable() { - return !this.resetButtonExist && this.searchButtonExist - } - }, - watch: { - searchButtonExist(val, old) { - if (val === old) return - if (val) { - this.widgetSubjects['按钮'][0].defaultClass = 'button-disable-filter' - if (this.resetButtonExist) { - this.widgetSubjects['按钮'][1].defaultClass = 'button-disable-filter' - } else { - this.widgetSubjects['按钮'][1].defaultClass = 'time-filter' - } - } else { - this.widgetSubjects['按钮'][0].defaultClass = 'time-filter' - this.widgetSubjects['按钮'][1].defaultClass = 'button-disable-filter' - } + sureButtonClass() { + return this.searchButtonExist ? 'button-disable-filter' : 'time-filter' }, - resetButtonExist(val, old) { - if (val === old) return - if (val) { - this.widgetSubjects['按钮'][1].defaultClass = 'button-disable-filter' - } else { - if (this.searchButtonExist) { - this.widgetSubjects['按钮'][1].defaultClass = 'time-filter' - } else { - this.widgetSubjects['按钮'][1].defaultClass = 'button-disable-filter' - } - } + resetButtonClass() { + return (this.searchButtonExist && !this.resetButtonExist) ? 'time-filter' : 'button-disable-filter' } + }, + created() { this.init() }, From 6b436eb6e6ed66642c10d0b807f2fa8d068287d7 Mon Sep 17 00:00:00 2001 From: taojinlong Date: Thu, 25 Aug 2022 15:21:16 +0800 Subject: [PATCH 02/16] =?UTF-8?q?fix(=E6=95=B0=E6=8D=AE=E9=9B=86):=20?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E7=AE=A1=E7=90=86=E4=B8=AD=E9=A2=84=E8=A7=88?= =?UTF-8?q?=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/io/dataease/service/dataset/DataSetTableService.java | 3 +++ frontend/src/views/system/task/TableSelector.vue | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/backend/src/main/java/io/dataease/service/dataset/DataSetTableService.java b/backend/src/main/java/io/dataease/service/dataset/DataSetTableService.java index 5bc83c1d43..22210b6bab 100644 --- a/backend/src/main/java/io/dataease/service/dataset/DataSetTableService.java +++ b/backend/src/main/java/io/dataease/service/dataset/DataSetTableService.java @@ -616,6 +616,9 @@ public class DataSetTableService { // check doris table if (!checkEngineTableIsExists(dataSetTableRequest.getId())) { if (dataSetTableRequest.isPreviewForTask()) { + map.put("fields", fields); + map.put("data", new ArrayList<>()); + map.put("page", new DataSetPreviewPage()); return map; } else { throw new RuntimeException(Translator.get("i18n_data_not_sync")); diff --git a/frontend/src/views/system/task/TableSelector.vue b/frontend/src/views/system/task/TableSelector.vue index ae94be6a74..dc9810601d 100644 --- a/frontend/src/views/system/task/TableSelector.vue +++ b/frontend/src/views/system/task/TableSelector.vue @@ -138,7 +138,6 @@ export default { table: [], filterText: "", fields: [], - tableName: "", dataLoading: false, treeLoading: false, }; @@ -184,6 +183,7 @@ export default { initData(table) { this.dataLoading = true; table.row = 100; + table.previewForTask = true post("/dataset/table/getPreviewData/1/100", table, false, 30000) .then((response) => { this.fields = response.data.fields; @@ -263,4 +263,4 @@ export default { } } } - \ No newline at end of file + From 57855c5937881a27e3f0c8d093b888f4ed58c65e Mon Sep 17 00:00:00 2001 From: taojinlong Date: Thu, 25 Aug 2022 15:39:07 +0800 Subject: [PATCH 03/16] =?UTF-8?q?fix(=E6=95=B0=E6=8D=AE=E9=9B=86):=20?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E7=AE=A1=E7=90=86=E4=B8=AD=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E5=BC=80=E5=A7=8B=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/views/system/task/form.vue | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/frontend/src/views/system/task/form.vue b/frontend/src/views/system/task/form.vue index 84494311cd..b71bdda796 100644 --- a/frontend/src/views/system/task/form.vue +++ b/frontend/src/views/system/task/form.vue @@ -341,7 +341,10 @@ export default { created() { const { datasetName, id } = this.$route.query; this.taskDetail = { datasetName, id }; - if (!id) return; + if (!id) { + this.taskForm.startTime = new Date() + return; + }; this.getTaskDetail(id); }, methods: { @@ -638,4 +641,4 @@ export default { text-align: right; } } - \ No newline at end of file + From ad34325bab06e37ae219512ed1c7a930d3642cd5 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Thu, 25 Aug 2022 15:50:32 +0800 Subject: [PATCH 04/16] =?UTF-8?q?refactor(=E4=BB=AA=E8=A1=A8=E6=9D=BF):=20?= =?UTF-8?q?=E4=BB=AA=E8=A1=A8=E6=9D=BF=E4=BD=BF=E7=94=A8=E7=BC=93=E5=AD=98?= =?UTF-8?q?=E5=90=8E=E4=BF=9D=E5=AD=98=E6=8C=89=E9=92=AE=E9=BB=98=E8=AE=A4?= =?UTF-8?q?=E5=8F=AF=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/canvas/store/snapshot.js | 3 +++ frontend/src/views/panel/edit/index.vue | 1 + 2 files changed, 4 insertions(+) diff --git a/frontend/src/components/canvas/store/snapshot.js b/frontend/src/components/canvas/store/snapshot.js index d2edd612ab..a36682975e 100644 --- a/frontend/src/components/canvas/store/snapshot.js +++ b/frontend/src/components/canvas/store/snapshot.js @@ -64,6 +64,9 @@ export default { state.changeTimes = 0 state.lastSaveSnapshotIndex = deepCopy(state.snapshotIndex) }, + recordChangeTimes(state) { + state.changeTimes++ + }, recordStyleChange(state) { state.styleChangeTimes++ } diff --git a/frontend/src/views/panel/edit/index.vue b/frontend/src/views/panel/edit/index.vue index f6f0b395fe..3b57490fc1 100644 --- a/frontend/src/views/panel/edit/index.vue +++ b/frontend/src/views/panel/edit/index.vue @@ -783,6 +783,7 @@ export default { setTimeout(() => { if (useCache) { _this.$store.commit('recordSnapshot', 'cache') + _this.$store.commit('recordChangeTimes' ) } else { _this.$store.commit('refreshSaveStatus') } From fa709d53393fe601cafe3f903a664956ad10cd0d Mon Sep 17 00:00:00 2001 From: fit2cloud-chenyw Date: Thu, 25 Aug 2022 15:53:57 +0800 Subject: [PATCH 05/16] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF-=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E6=8C=89=E9=92=AE):=20=E6=9F=A5=E8=AF=A2=E6=8C=89?= =?UTF-8?q?=E9=92=AE=E5=AF=B9tab=E5=86=85=E9=83=A8=E8=A7=86=E5=9B=BE?= =?UTF-8?q?=E6=97=A0=E6=95=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/canvas/components/Editor/Preview.vue | 9 ++++++++- .../src/components/canvas/components/Editor/index.vue | 9 ++++++++- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/frontend/src/components/canvas/components/Editor/Preview.vue b/frontend/src/components/canvas/components/Editor/Preview.vue index cf2618a374..2e40f650d6 100644 --- a/frontend/src/components/canvas/components/Editor/Preview.vue +++ b/frontend/src/components/canvas/components/Editor/Preview.vue @@ -75,7 +75,7 @@ import { mapState } from 'vuex' import ComponentWrapper from './ComponentWrapper' import { changeStyleWithScale } from '@/components/canvas/utils/translate' import { uuid } from 'vue-uuid' -import {deepCopy, imgUrlTrans} from '@/components/canvas/utils/utils' +import { deepCopy, imgUrlTrans } from '@/components/canvas/utils/utils' import eventBus from '@/components/canvas/utils/eventBus' import elementResizeDetectorMaker from 'element-resize-detector' import UserViewDialog from '@/components/canvas/custom-component/UserViewDialog' @@ -330,6 +330,13 @@ export default { if (component.type === 'view' && this.buttonFilterMap[component.propValue.viewId]) { component.filters = this.buttonFilterMap[component.propValue.viewId] } + if (component.type === 'de-tabs') { + for (let idx = 0; idx < component.options.tabList.length; idx++) { + const ele = component.options.tabList[idx].content + if (!ele.type || ele.type !== 'view') continue + ele.filters = this.buttonFilterMap[ele.propValue.viewId] + } + } }) }, buildButtonFilterMap(panelItems, isClear = false) { diff --git a/frontend/src/components/canvas/components/Editor/index.vue b/frontend/src/components/canvas/components/Editor/index.vue index 189782501b..df535a5241 100644 --- a/frontend/src/components/canvas/components/Editor/index.vue +++ b/frontend/src/components/canvas/components/Editor/index.vue @@ -189,7 +189,7 @@ import DeDrag from '@/components/DeDrag' // eslint-disable-next-line no-unused-vars import { getStyle, getComponentRotatedStyle } from '@/components/canvas/utils/style' -import {_$, imgUrlTrans} from '@/components/canvas/utils/utils' +import { _$, imgUrlTrans } from '@/components/canvas/utils/utils' import ContextMenu from './ContextMenu' import MarkLine from './MarkLine' import Area from './Area' @@ -1133,6 +1133,13 @@ export default { if (component.type === 'view' && this.buttonFilterMap[component.propValue.viewId]) { component.filters = this.buttonFilterMap[component.propValue.viewId] } + if (component.type === 'de-tabs') { + for (let idx = 0; idx < component.options.tabList.length; idx++) { + const ele = component.options.tabList[idx].content + if (!ele.type || ele.type !== 'view') continue + ele.filters = this.buttonFilterMap[ele.propValue.viewId] + } + } }) }, buildButtonFilterMap(panelItems, isClear = false) { From 63648496a8b88bee05d52679478a751f726012c9 Mon Sep 17 00:00:00 2001 From: taojinlong Date: Thu, 25 Aug 2022 15:39:07 +0800 Subject: [PATCH 06/16] =?UTF-8?q?fix(=E6=95=B0=E6=8D=AE=E6=BA=90):=20?= =?UTF-8?q?=E6=A0=A1=E9=AA=8Capi=E6=95=B0=E6=8D=AE=E6=BA=90=E7=8A=B6?= =?UTF-8?q?=E6=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../io/dataease/service/datasource/DatasourceService.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/backend/src/main/java/io/dataease/service/datasource/DatasourceService.java b/backend/src/main/java/io/dataease/service/datasource/DatasourceService.java index 40f8c95233..964f3eb99a 100644 --- a/backend/src/main/java/io/dataease/service/datasource/DatasourceService.java +++ b/backend/src/main/java/io/dataease/service/datasource/DatasourceService.java @@ -168,7 +168,10 @@ public class DatasourceService { JsonObject apiItemStatuses = JsonParser.parseString(datasourceDTO.getStatus()).getAsJsonObject(); for (int i = 0; i < apiDefinitionList.size(); i++) { - String status = apiItemStatuses.get(apiDefinitionList.get(i).getName()).getAsString(); + String status = null; + if(apiItemStatuses.get(apiDefinitionList.get(i).getName()) != null){ + status = apiItemStatuses.get(apiDefinitionList.get(i).getName()).getAsString(); + } apiDefinitionList.get(i).setStatus(status); apiDefinitionList.get(i).setSerialNumber(i); apiDefinitionListWithStatus.add(apiDefinitionList.get(i)); From 6278f8b4a23fc7014ccdfc8322419015d47fe9b4 Mon Sep 17 00:00:00 2001 From: limbo Date: Thu, 25 Aug 2022 16:09:21 +0800 Subject: [PATCH 07/16] fix typo --- CONTRIBUTING.md | 6 +++--- README.md | 4 ++-- SECURITY.md | 2 +- .../main/java/io/dataease/service/sys/SysUserService.java | 2 +- frontend/src/lang/en.js | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index f3b3ce3188..22fd416bb9 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -3,9 +3,9 @@ ## Create pull request PR are always welcome, even if they only contain small fixes like typos or a few lines of code. If there will be a significant effort, please document it as an issue and get a discussion going before starting to work on it. -Please submit a PR broken down into small changes bit by bit. A PR consisting of a lot features and code changes may be hard to review. It is recommended to submit PRs in an incremental fashion. +Please submit a PR broken down into small changes' bit by bit. A PR consisting of a lot of features and code changes may be hard to review. It is recommended to submit PRs in an incremental fashion. -This [development guideline](https://dataease.io/docs/dev_manual/dev_manual/) contains information about repository structure, how to setup development environment, how to run it, and more. +This [development guideline](https://dataease.io/docs/dev_manual/dev_manual/) contains information about repository structure, how to set up development environment, how to run it, and more. Note: If you split your pull request to small changes, please make sure any of the changes goes to master will not break anything. Otherwise, it can not be merged until this feature complete. @@ -21,5 +21,5 @@ When reporting issues, always include: * Steps to reproduce the issue. * Snapshots or log files if needed -Because the issues are open to the public, when submitting files, be sure to remove any sensitive information, e.g. user name, password, IP address, and company name. You can +Because the issues are open to the public, when submitting files, be sure to remove any sensitive information, e.g. username, password, IP address, and company name. You can replace those parts with "REDACTED" or other strings like "****". diff --git a/README.md b/README.md index 156368fc82..e01b092a44 100644 --- a/README.md +++ b/README.md @@ -72,8 +72,8 @@ DataEase 是开源的数据可视化分析工具,帮助用户快速分析数 仅需两步快速安装 DataEase: -1. 准备一台不小于 8 G内存的 64位 Linux 主机; -2. 以 root 用户执行如下命令一键安装 DataEase。 +1. 准备一台不小于 8 G内存的 64位 Linux 主机; +2. 以 root 用户执行如下命令一键安装 DataEase。 ```sh curl -sSL https://github.com/dataease/dataease/releases/latest/download/quick_start.sh | sh diff --git a/SECURITY.md b/SECURITY.md index 66aa1f1fe7..4b666b7f4a 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -16,4 +16,4 @@ All security bugs should be reported to the contact as below: - support@fit2cloud.com - 400-052-0755 -Thanks for you support! +Thanks for your support! diff --git a/backend/src/main/java/io/dataease/service/sys/SysUserService.java b/backend/src/main/java/io/dataease/service/sys/SysUserService.java index 8fbf8d6cbc..552d8cf27c 100644 --- a/backend/src/main/java/io/dataease/service/sys/SysUserService.java +++ b/backend/src/main/java/io/dataease/service/sys/SysUserService.java @@ -196,7 +196,7 @@ public class SysUserService { } /** - * 修改用户密码清楚缓存 + * 修改用户密码清除缓存 * * @param request * @return diff --git a/frontend/src/lang/en.js b/frontend/src/lang/en.js index 0694b84a10..eaced79f26 100644 --- a/frontend/src/lang/en.js +++ b/frontend/src/lang/en.js @@ -2341,7 +2341,7 @@ export default { teaching_video_bottom_hint: 'More videos', enterprise_edition_hint1: 'Provide enterprise application scenario X-Pack enhancement package', enterprise_edition_hint2: 'Provide high-level original factory service support', - enterprise_edition_hint3: 'Provide DateEase best practice recommendations', + enterprise_edition_hint3: 'Provide DataEase best practice recommendations', open_source_community: 'Open source community', click_show: 'Click To View', show_more: 'Show More', From 9c9898b4b5274a3ce7c24006896c081fd93fbd07 Mon Sep 17 00:00:00 2001 From: taojinlong Date: Thu, 25 Aug 2022 16:12:05 +0800 Subject: [PATCH 08/16] =?UTF-8?q?fix(=E6=95=B0=E6=8D=AE=E9=9B=86):=20?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=96=87=E6=A1=A3=E8=B7=AF=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/lang/en.js | 2 +- frontend/src/lang/tw.js | 2 +- frontend/src/lang/zh.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/frontend/src/lang/en.js b/frontend/src/lang/en.js index 0694b84a10..1b1b648cff 100644 --- a/frontend/src/lang/en.js +++ b/frontend/src/lang/en.js @@ -1412,7 +1412,7 @@ export default { edit_field: 'Edit Field', preview_100_data: 'Show 100 lines data', invalid_table_check: 'Please sync data first.', - parse_error: 'Parse failed,please check.Reference:https://dataease.io/docs/faq/dataset_faq/', + parse_error: 'Parse failed,please check.Reference:https://dataease.io/docs/user_manual/dataset_configuration/dataset_Excel', origin_field_type: 'Origin Type', edit_excel_table: 'Edit Excel Dataset', edit_excel: 'Edit Excel', diff --git a/frontend/src/lang/tw.js b/frontend/src/lang/tw.js index 39e4cc6ca1..e7fe8600ef 100644 --- a/frontend/src/lang/tw.js +++ b/frontend/src/lang/tw.js @@ -1411,7 +1411,7 @@ export default { edit_field: '編輯字段', preview_100_data: '顯示前100行數據', invalid_table_check: '非直連數據集請先完成數據同步', - parse_error: 'Excel解析失敗,請檢查格式、字段等信息。具體參考:https://dataease.io/docs/faq/dataset_faq/', + parse_error: 'Excel解析失敗,請檢查格式、字段等信息。具體參考:https://dataease.io/docs/user_manual/dataset_configuration/dataset_Excel', origin_field_type: '原始類型', edit_excel_table: '編輯Excel數據集', edit_excel: '編輯Excel', diff --git a/frontend/src/lang/zh.js b/frontend/src/lang/zh.js index 296e831c81..a1976ad776 100644 --- a/frontend/src/lang/zh.js +++ b/frontend/src/lang/zh.js @@ -1412,7 +1412,7 @@ export default { edit_field: '编辑字段', preview_100_data: '显示前100行数据', invalid_table_check: '非直连数据集请先完成数据同步', - parse_error: 'Excel解析失败,请检查格式、字段等信息。具体参考:https://dataease.io/docs/faq/dataset_faq/', + parse_error: 'Excel解析失败,请检查格式、字段等信息。具体参考:https://dataease.io/docs/user_manual/dataset_configuration/dataset_Excel', origin_field_type: '原始类型', edit_excel_table: '编辑Excel数据集', edit_excel: '编辑Excel', From ec3f5c8701878bc1e7a3916088b71bf420060fa6 Mon Sep 17 00:00:00 2001 From: fit2cloud-chenyw Date: Thu, 25 Aug 2022 16:15:42 +0800 Subject: [PATCH 09/16] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF-=E6=97=A5?= =?UTF-8?q?=E6=9C=9F=E8=8C=83=E5=9B=B4=E8=BF=87=E6=BB=A4=E5=99=A8):=20?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E6=97=B6=E9=97=B4=E9=BB=98=E8=AE=A4=E5=80=BC?= =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/widget/DeWidget/DeDate.vue | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/frontend/src/components/widget/DeWidget/DeDate.vue b/frontend/src/components/widget/DeWidget/DeDate.vue index b14c72202f..ab557e31cf 100644 --- a/frontend/src/components/widget/DeWidget/DeDate.vue +++ b/frontend/src/components/widget/DeWidget/DeDate.vue @@ -15,6 +15,7 @@ :size="size" :editable="false" :picker-options="pickerOptions" + :default-time="defaultRangeTime" @change="dateChange" @focus="toFocus" @blur="onBlur" @@ -119,6 +120,12 @@ export default { } } return null + }, + defaultRangeTime() { + if (this.element.options.attrs.type === 'daterange' && this.element.options.attrs.showTime) { + return ['00:00:00', '23:59:59'] + } + return null } }, From 864c6e42fde108be09f1804d1ab09ea6762a8a2d Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Thu, 25 Aug 2022 16:50:27 +0800 Subject: [PATCH 10/16] =?UTF-8?q?refactor(=E8=A7=86=E5=9B=BE):=20=E5=AF=8C?= =?UTF-8?q?=E6=96=87=E6=9C=AC=E8=A7=86=E5=9B=BE=E5=A6=82=E6=9E=9C=E6=9C=AA?= =?UTF-8?q?=E5=AE=9A=E4=B9=89=E5=AD=97=E6=AE=B5=E6=98=BE=E7=A4=BA'?= =?UTF-8?q?=E6=97=A0=E6=B3=95=E8=8E=B7=E5=8F=96=E5=AD=97=E6=AE=B5'?= =?UTF-8?q?=E5=AE=9A=E4=B9=89=E5=AD=97=E6=AE=B5=E4=BD=86=E6=B2=A1=E6=9C=89?= =?UTF-8?q?=E5=80=BC=E5=88=99=E4=B8=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/canvas/custom-component/DeRichTextView.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/components/canvas/custom-component/DeRichTextView.vue b/frontend/src/components/canvas/custom-component/DeRichTextView.vue index 0a9d9d35b2..455d49ac2d 100644 --- a/frontend/src/components/canvas/custom-component/DeRichTextView.vue +++ b/frontend/src/components/canvas/custom-component/DeRichTextView.vue @@ -148,7 +148,7 @@ export default { if (on) { on.forEach(itm => { const ele = itm.slice(1, -1) - content = content.replace(itm, _this.dataRowNameSelect[ele] ? _this.dataRowNameSelect[ele] : '[无法获取字段值]') + content = content.replace(itm, _this.dataRowNameSelect[ele] !== undefined ? _this.dataRowNameSelect[ele] : '[无法获取字段值]') }) } content = content.replace('class="base-selected"','') From 28cb167fbefb377f531ae3f4d6402486f890aaea Mon Sep 17 00:00:00 2001 From: taojinlong Date: Thu, 25 Aug 2022 17:11:55 +0800 Subject: [PATCH 11/16] =?UTF-8?q?fix(=E6=95=B0=E6=8D=AE=E6=BA=90):=20?= =?UTF-8?q?=E5=A4=8D=E5=88=B6API=E6=95=B0=E6=8D=AE=E8=A1=A8=EF=BC=8C?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=90=8E=E7=BC=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/lang/en.js | 1 + frontend/src/lang/tw.js | 1 + frontend/src/lang/zh.js | 1 + .../views/system/datasource/DsConfiguration.vue | 15 ++++++++++++++- 4 files changed, 17 insertions(+), 1 deletion(-) diff --git a/frontend/src/lang/en.js b/frontend/src/lang/en.js index 1b1b648cff..7df8e183c4 100644 --- a/frontend/src/lang/en.js +++ b/frontend/src/lang/en.js @@ -1641,6 +1641,7 @@ export default { has_repeat_name: 'Duplicate API data table name', has_repeat_field_name: 'The field name is duplicate, please modify it before selecting', api_field_not_empty: 'Field cannot be empty', + success_copy: 'Copy succeeded', valid: 'Valid', invalid: 'Invalid', api_step_1: 'Connection API', diff --git a/frontend/src/lang/tw.js b/frontend/src/lang/tw.js index e7fe8600ef..329b01b3e3 100644 --- a/frontend/src/lang/tw.js +++ b/frontend/src/lang/tw.js @@ -1641,6 +1641,7 @@ export default { has_repeat_name: 'API 數據表名稱重複', has_repeat_field_name: '欄位名重複,請修改後再選擇', api_field_not_empty: '欄位不能為空', + success_copy: '複製成功', valid: '有效', invalid: '無效', api_step_1: '連接API', diff --git a/frontend/src/lang/zh.js b/frontend/src/lang/zh.js index a1976ad776..55c32a421d 100644 --- a/frontend/src/lang/zh.js +++ b/frontend/src/lang/zh.js @@ -1649,6 +1649,7 @@ export default { has_repeat_name: 'API 数据表名称重复', has_repeat_field_name: '字段名重复,请修改后再选择', api_field_not_empty: '字段不能为空', + success_copy: '复制成功', valid: '有效', invalid: '无效', api_step_1: '连接API', diff --git a/frontend/src/views/system/datasource/DsConfiguration.vue b/frontend/src/views/system/datasource/DsConfiguration.vue index 0519aacd44..be710c70f0 100644 --- a/frontend/src/views/system/datasource/DsConfiguration.vue +++ b/frontend/src/views/system/datasource/DsConfiguration.vue @@ -1010,8 +1010,21 @@ export default { copyItem(item){ var newItem = JSON.parse(JSON.stringify(item)) newItem.serialNumber = this.form.apiConfiguration[this.form.apiConfiguration.length - 1].serialNumber + 1 - newItem.name = item.name + '_copy' + var reg = new RegExp(item.name + '_copy_' + '([0-9]*)', "gim"); + var number = 0 + for(var i =1;i number){ + number = parseInt(num) + } + } + } + number = number + 1 + newItem.name = item.name + '_copy_' + number this.form.apiConfiguration.push(newItem) + this.$message.success(i18n.t('datasource.success_copy')) }, addApiItem(item) { if (item) { From 58f4ab3ff44ddd59c1ab452575cb1b55eed1792e Mon Sep 17 00:00:00 2001 From: dataeaseShu <106045316+dataeaseShu@users.noreply.github.com> Date: Thu, 25 Aug 2022 17:54:28 +0800 Subject: [PATCH 12/16] =?UTF-8?q?fix:=20=E4=BB=BB=E5=8A=A1=E7=AE=A1?= =?UTF-8?q?=E7=90=86=20bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/assets/None.png | Bin 0 -> 2585 bytes frontend/src/assets/None_Select.png | Bin 0 -> 3354 bytes frontend/src/assets/nothing.png | Bin 0 -> 3061 bytes frontend/src/components/cron/cron.vue | 1 - .../template/component/TemplateImport.vue | 2 + .../panel/template/component/TemplateItem.vue | 2 +- frontend/src/views/panel/template/index.vue | 79 +++-- frontend/src/views/system/plugin/index.vue | 17 +- .../src/views/system/task/DatasetTaskList.vue | 114 ++++--- frontend/src/views/system/task/TaskRecord.vue | 296 +++++++++++------- frontend/src/views/system/task/dataset.vue | 14 +- frontend/src/views/system/task/filterUser.vue | 27 +- .../views/system/task/filterUserRecord.vue | 25 +- 13 files changed, 372 insertions(+), 205 deletions(-) create mode 100644 frontend/src/assets/None.png create mode 100644 frontend/src/assets/None_Select.png create mode 100644 frontend/src/assets/nothing.png diff --git a/frontend/src/assets/None.png b/frontend/src/assets/None.png new file mode 100644 index 0000000000000000000000000000000000000000..700664ed24bce25c0a3834dc841b3d6730166005 GIT binary patch literal 2585 zcmV+!3g-2RP)mG7yNoY(;i z2uh6nKpHvypUfx{=rN;toiplR6*Uqg44(gVpFZ6^=gd)psMTt@OeT|`pP%3S^5siD zl}c^!F~_I!b8~Yz=Ir+a@VO=*ntZNqzptC7`I=u=4Z~<&TwGKOg+h}O!W?PLn>TMZ zS>PfI^DVzELTCz)Du31acf7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U-!X`9l$wH404FOtp}_J;A=;^rB%AUQcbC(UWXS7|M} z;0+i#rfeem48eNWjc&L5ngrJ*C6LqF(hD2kSWOgBv3ytWTox=HqSr}dZr-?IE$t<^ zgGGOh=)F$DEK$V(RV86&;L>W-$Ye5g5@v>UI$breYOuKYnV|~3tu(A@nlIVx^Q0lu zv_NBdvN%_&iVJ6YZi&v8j&WVfRVb!ufkx^UD^u#8L-z_t?iC!JOhbh1@`0>=XFnX%->E=Pb)euP#`VP6RGs?(l~It zv)`9-J%O+x5A4S}AUeDFvPAL814DQJ`vKA6;@R3g@6s!%3mb9y>IQwrkPjV@kQlDI zc5qE}Y~-fv^i8-%b=byyqx#;Tl45JiAz!Y*GTI|iafJ%D@~6YTKUDOkrKN*Lqfuvz z&yylpg11O;33}l;yzF z>vc#mptI<4)dRR_R_M>O55v_~4s7jD_zqHTS4LqFWZ!t^_1&b;xf(oEsnnhXb!r2B z+U>Th8J8>3?KbI&caRV(`;*+dgX=KaPR~9iK{=3l8#hI}il@1exOw$}9<5eu&&$tv z5*=>dG|g?PxhsREN1;&gq=)A$2*wSrxksL~5w62l?s^>WXR6efJ$^`TK1SH^_F0D~ zGzGr4T;xhzS+?Ge9yCU<;3b+8U!r3Z7|sA8TPGX;Lqb9BQocySgenO$1b`mNVGbx?|CWTN=bO$_H!xmD~ut@{SmFHN|Bd#%f63UA1P^;B)3kwT7oY{M% z_;P1hj_n0U`p6Ccf01v1hxQE+XL`43ug~-H{rmR^stetZR-#{p$A66b zxCtKcO^~M$;{bajgbGTXIARfH(iE*lzY2zeY&N^e0_8Xfw8>s!gTI}(Pv`Bz&oJ)* vtHoIC>~evA^4I+H=vJw+%dYEW$&>gCi(jzhJ;HsF00000NkvXXu0mjfI4=In literal 0 HcmV?d00001 diff --git a/frontend/src/assets/None_Select.png b/frontend/src/assets/None_Select.png new file mode 100644 index 0000000000000000000000000000000000000000..90e625123840e0147e1de4342d305d29d79c8057 GIT binary patch literal 3354 zcmV+#4dwEQP)80rC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Q^+LI z5FBu0<(}7PJViJ1cBNA|RY3L4+E{VISHvJ78Wsd;L^px>Ec|0qqm-*pCdDdX zk_hQUH{pt2nJr`?fs-^)TzQTiJw%P!UPvptNv&2ZjE#*w;L6@Z$=B3X`2Y8kqw(da zYvoZRz35hqh`-Diz literal 0 HcmV?d00001 diff --git a/frontend/src/assets/nothing.png b/frontend/src/assets/nothing.png new file mode 100644 index 0000000000000000000000000000000000000000..7b1fa548bf76deb8ac4fbce166a93047d199bb97 GIT binary patch literal 3061 zcmVw)vdq^ELLFd3QShuWCg$qf>&U?f{RyxyaFr#q$*WO zNjMPk5FiY~20fhfjb{`+=BatLH2tfh20e`A`TCqbefo6w2n`X1LLrq%B+_GJV~bzD zd`XXvjy~pVieE~PjEvx#QXhA~uT}U`;n#}l<6@)H*yUgIu~@8fd3l-7WHJ>R5=Ll% z+1uM&WP!6R%n$r93!%wB^88ce&vXTKX2J9kzFS;u9D&OSi{4h)6f(G!WTCHx2-W3QddZ|>(a-R&Vei5cc z_X9W3Ei{1p_wVOOK!g+h@bC~qza+7(+Aet(|JCg5>=p@xFrptF9j&t1Yd!~Kp@7jq zv)SAbMf}i3hh?)H|794(?nV^xLlYf+c03+mqv3Glj)3^JT5UP3h(B=A5sfF4Nr?Ru zMH~ctEdEB&;s+`^teZ1tucP3~?GlE|4@7in-L}}|?rvjxdfN9fzVD*5b*I_7ccgV& z6I5RxBOfW3%P&~)_fl|s;6AanzdtxQ@YN&wCi=2T>Bcx+3-{Y8!J|9^IN<~lHTExL5+fugv2x5B#;oyXy? zrQm_H*l09T$Q{LPJ2ylx1X>8BgWg=OVtBq#0!9zdOcyf78@)925M#Ur>A zEvkopSR6VxH@DsWny%!^e zHp`bqlGp~qf7m-90m-U*cF-fbER5)n)5^J!!n2+|!?zC6F-6C&{RK(-0>bZ?jz}b+ zXZO@=hv>ChZG|MRI6gU}gQF7?h}8A<^=kVQ9in3=Cz814;HWH=@H}Dmy!~-YbWE(U z|Id=d69f}J+wS69qH}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IFYg`1bw7Ak5(H>>SK z%`6_C#81IhOue+}-R1G!cF>W$R$c03Use&(6CQ#;n4KX%QLTK->^+vd0ITPE?NA7K zRYe+R1A?nRKB*|{*#od}6iQ^;^Xz)q+WNU%E^l%R67Ez+Nhf;QH$7~1o*cNW!)=g6 zSfEd>RQ9hskPs_7zEl1DQ9g;H@1;V#-TvjU;$k;!Bn>ESpFf_|gfYzCgRk@Uh=Zo40Er?1qP+J8hcH!lio zcpI$4CiQ`$4<}eXKV(389;(Y-Y zj{DnBq^^gjXKl(p-g`8c?uCVGcv`IhSI_C%CB3p+iF0rty%rq!cB(GV!>{vYjU;`6 zaX3fm>*NEz9;M9V_@832*qYpB+7Z~5`)4N;C{FSH{OnSxl;(+=oiNI&2Mt8%UIuJN z_+EjC|3D&Fuz)U**f1wEBO6b)!HhN40cD^??*?5#GMQXtfl{0VT4b;An4eCo zFQ?UsA3g6-QI8+hPPsrm`7Zx^RIB9KWfup@lCAg$I|9{2olUoH00000NkvXXu0mjf D save(this.templateInfo).then((response) => { this.openMessageSuccess("system_parameter_setting.import_succeeded"); + this.$emit("refresh"); this.$emit("closeEditTemplateDialog"); }), confirmButtonText: this.$t('template.override') @@ -154,6 +155,7 @@ export default { } else { save(this.templateInfo).then((response) => { this.openMessageSuccess("system_parameter_setting.import_succeeded"); + this.$emit("refresh"); this.$emit("closeEditTemplateDialog"); }); } diff --git a/frontend/src/views/panel/template/component/TemplateItem.vue b/frontend/src/views/panel/template/component/TemplateItem.vue index 0f859e9cb9..b9e6368dea 100644 --- a/frontend/src/views/panel/template/component/TemplateItem.vue +++ b/frontend/src/views/panel/template/component/TemplateItem.vue @@ -72,7 +72,7 @@ export default { background: #ffffff; border: 1px solid var(--deCardStrokeColor, #dee0e3); border-radius: 4px; - margin: 0 25px 25px 0; + margin: 0 12.5px 25px 12.5px; .card-img-model { border-bottom: 1px solid var(--deCardStrokeColor, #dee0e3); height: 144px; diff --git a/frontend/src/views/panel/template/index.vue b/frontend/src/views/panel/template/index.vue index 217dbfcbe5..478fd8d8d5 100644 --- a/frontend/src/views/panel/template/index.vue +++ b/frontend/src/views/panel/template/index.vue @@ -33,7 +33,9 @@
- {{ currentTemplateLabel }}  ({{ currentTemplateShowList.length }}) + {{ currentTemplateLabel }}  ({{ + currentTemplateShowList.length + }}) -
+
@@ -60,7 +66,7 @@
- + @@ -97,6 +100,8 @@ @@ -109,10 +114,10 @@ import TemplateList from "./component/TemplateList"; import TemplateItem from "./component/TemplateItem"; import TemplateImport from "./component/TemplateImport"; import { save, templateDelete, find } from "@/api/system/template"; -import elementResizeDetectorMaker from 'element-resize-detector' +import elementResizeDetectorMaker from "element-resize-detector"; import msgCfm from "@/components/msgCfm/index"; -import { log } from '@antv/g2plot/lib/utils'; +import { log } from "@antv/g2plot/lib/utils"; export default { name: "PanelMain", mixins: [msgCfm], @@ -129,7 +134,7 @@ export default { { required: true, message: this.$t("commons.input_content"), - trigger: "change", + trigger: "blur", }, { max: 50, @@ -171,17 +176,20 @@ export default { }, mounted() { this.getTree(); - const _this = this - const erd = elementResizeDetectorMaker() - const templateMainDom = document.getElementById('template-box') + const _this = this; + const erd = elementResizeDetectorMaker(); + const templateMainDom = document.getElementById("template-box"); // 监听div变动事件 - erd.listenTo(templateMainDom, element => { + erd.listenTo(templateMainDom, (element) => { _this.$nextTick(() => { - const curSeparator = Math.trunc(templateMainDom.offsetWidth / _this.templateMiniWidth) - console.log(1, curSeparator) - _this.templateCurWidth = Math.trunc(templateMainDom.offsetWidth / curSeparator) - 50 - }) - }) + const curSeparator = Math.trunc( + templateMainDom.offsetWidth / _this.templateMiniWidth + ); + console.log(1, curSeparator); + _this.templateCurWidth = + Math.trunc(templateMainDom.offsetWidth / curSeparator) - 50; + }); + }); }, methods: { roleValidator(rule, value, callback) { @@ -226,11 +234,11 @@ export default { }, templateDeleteConfirm(template) { const options = { - title: 'system_parameter_setting.delete_this_template', - type: "primary", - cb: () => this.templateDelete(template.id), - }; - this.handlerConfirm(options); + title: "system_parameter_setting.delete_this_template", + type: "primary", + cb: () => this.templateDelete(template.id), + }; + this.handlerConfirm(options); }, handleClick(tab, event) { this.getTree(); @@ -247,7 +255,7 @@ export default { templateDelete(id) { if (id) { templateDelete(id).then((response) => { - this.openMessageSuccess('commons.delete_success'); + this.openMessageSuccess("commons.delete_success"); this.getTree(); }); } @@ -257,7 +265,13 @@ export default { this.formType = type; if (type === "edit") { this.templateEditForm = JSON.parse(JSON.stringify(templateInfo)); - this.dialogTitle = this.$t(`system_parameter_setting.${"folder" === this.templateEditForm.nodeType ? 'edit_classification' : 'edit_template'}`); + this.dialogTitle = this.$t( + `system_parameter_setting.${ + "folder" === this.templateEditForm.nodeType + ? "edit_classification" + : "edit_template" + }` + ); this.originName = this.templateEditForm.label; } else { this.dialogTitle = this.$t("panel.add_category"); @@ -268,7 +282,13 @@ export default { level: 0, }; } - this.dialogTitleLabel = this.$t(`system_parameter_setting.${ "folder" === this.templateEditForm.nodeType ? 'classification_name' : 'template_name'}`) + this.dialogTitleLabel = this.$t( + `system_parameter_setting.${ + "folder" === this.templateEditForm.nodeType + ? "classification_name" + : "template_name" + }` + ); this.editTemplate = true; }, templateEdit(templateInfo) { @@ -365,7 +385,7 @@ export default { .de-tabs-right { flex: 1; background: #fff; - padding: 24px; + padding: 24px 12px 24px 12px; overflow: hidden; .template-box { @@ -373,6 +393,7 @@ export default { flex-wrap: wrap; overflow-y: auto; box-sizing: border-box; + align-content: flex-start; height: calc(100% - 10px); width: 100%; padding-bottom: 24px; diff --git a/frontend/src/views/system/plugin/index.vue b/frontend/src/views/system/plugin/index.vue index 62c4c91f56..c033ddd8a3 100644 --- a/frontend/src/views/system/plugin/index.vue +++ b/frontend/src/views/system/plugin/index.vue @@ -78,7 +78,7 @@

-
+
更新
- + {{ $t("user.clear_filter") }}
-
+ :class="[filterTexts.length ? 'table-container-filter' : '']" + > @@ -263,7 +268,6 @@
- @@ -316,9 +320,7 @@ const columnOptions = [ props: "status", }, ]; -import { - formatOrders, -} from "@/utils/index"; +import { formatOrders } from "@/utils/index"; import { datasetTaskList, post } from "@/api/dataset/dataset"; import cron from "@/components/cron/cron"; import TableSelector from "@/views/chart/view/TableSelector"; @@ -326,12 +328,18 @@ import { hasDataPermission } from "@/utils/permission"; import GridTable from "@/components/gridTable/index.vue"; import filterUser from "./filterUser.vue"; import msgCfm from "@/components/msgCfm/index"; -import _ from 'lodash'; +import _ from "lodash"; export default { name: "DatasetTaskList", components: { GridTable, cron, filterUser, TableSelector }, mixins: [msgCfm], + props: { + transCondition: { + type: Object, + default: () => {}, + }, + }, data() { return { nikeName: "", @@ -366,7 +374,11 @@ export default { }, }, created() { - this.initSearch(); + const { taskId, name } = this.transCondition; + if (taskId) { + this.nikeName = name; + } + this.search(); this.timer = setInterval(() => { this.search(false); }, 10000); @@ -385,28 +397,30 @@ export default { }); }, resizeObserver() { - this.resizeForFilter = new ResizeObserver(entries => { + this.resizeForFilter = new ResizeObserver((entries) => { if (!this.filterTexts.length) return; this.layoutResize(); }); - this.resizeForFilter.observe(document.querySelector('#resize-for-filter')); + this.resizeForFilter.observe( + document.querySelector("#resize-for-filter") + ); }, layoutResize: _.debounce(function () { - this.getScrollStatus() + this.getScrollStatus(); }, 200), scrollPre() { - const dom = document.querySelector('.filter-texts-container'); - dom.scrollLeft -= 10 + const dom = document.querySelector(".filter-texts-container"); + dom.scrollLeft -= 10; if (dom.scrollLeft <= 0) { - dom.scrollLeft = 0 + dom.scrollLeft = 0; } }, scrollNext() { - const dom = document.querySelector('.filter-texts-container'); - dom.scrollLeft += 10 - const width = dom.scrollWidth - dom.offsetWidth + const dom = document.querySelector(".filter-texts-container"); + dom.scrollLeft += 10; + const width = dom.scrollWidth - dom.offsetWidth; if (dom.scrollLeft > width) { - dom.scrollLeft = width + dom.scrollLeft = width; } }, clearFilter() { @@ -467,6 +481,7 @@ export default { this.handleCurrentChange(1); }, search(showLoading = true) { + const { taskId, name } = this.transCondition; const param = { orders: formatOrders(this.orderConditions), conditions: [...this.cacheCondition], @@ -478,6 +493,13 @@ export default { value: this.nikeName, }); } + if (taskId && this.nikeName === name) { + param.conditions.push({ + operator: "eq", + value: taskId, + field: "dataset_table_task.id", + }); + } const { currentPage, pageSize } = this.paginationConfig; datasetTaskList(currentPage, pageSize, param, showLoading).then( (response) => { @@ -490,18 +512,22 @@ export default { ); }, batchDelete() { - post("/dataset/task/batchDelete", this.multipleSelection.map(ele => ele.id), false).then(() => { + post( + "/dataset/task/batchDelete", + this.multipleSelection.map((ele) => ele.id), + false + ).then(() => { this.initSearch(); - this.openMessageSuccess('commons.delete_success'); + this.openMessageSuccess("commons.delete_success"); }); }, confirmDelete() { const options = { - title: '确定删除该任务吗?', - type: "primary", - cb: this.batchDelete, - }; - this.handlerConfirm(options); + title: "确定删除该任务吗?", + type: "primary", + cb: this.batchDelete, + }; + this.handlerConfirm(options); }, taskStatus(item) { post("/dataset/task/lastExecStatus", item, false).then((response) => { @@ -552,23 +578,23 @@ export default { ) .then(() => { post("/dataset/task/execTask", task).then((response) => { - this.initSearch( true); + this.initSearch(true); }); }) .catch(() => {}); }, selectDataset(row) { if (row) { - const { datasetName, id } = row; + const { datasetName, id } = row; this.$router.push({ - path: '/task-ds-form', + path: "/task-ds-form", query: { datasetName, id, - } - }) + }, + }); } else { - this.$router.push('/task-ds-form') + this.$router.push("/task-ds-form"); } }, disableEdit(task) { @@ -592,16 +618,16 @@ export default { }, deleteTask(task) { const options = { - title: '确定删除该任务吗?', - type: "primary", - cb: () => { - post("/dataset/task/delete/" + task.id, null).then((response) => { - this.openMessageSuccess('commons.delete_success'); + title: "确定删除该任务吗?", + type: "primary", + cb: () => { + post("/dataset/task/delete/" + task.id, null).then((response) => { + this.openMessageSuccess("commons.delete_success"); this.initSearch(); }); - }, - }; - this.handlerConfirm(options); + }, + }; + this.handlerConfirm(options); }, showErrorMassage(massage) { this.show_error_massage = true; @@ -694,7 +720,7 @@ span { } .mar3 { - margin-left: -3px; + margin-left: -3px; } } @@ -750,14 +776,16 @@ span { color: #3370ff; } - .filter-texts-container::-webkit-scrollbar { display: none; } + .filter-texts-container::-webkit-scrollbar { + display: none; + } .arrow-filter { font-size: 16px; width: 24px; height: 24px; cursor: pointer; - color: #646A73; + color: #646a73; display: flex; justify-content: center; align-items: center; diff --git a/frontend/src/views/system/task/TaskRecord.vue b/frontend/src/views/system/task/TaskRecord.vue index 0e2dcc30bf..b9d3fd61bc 100644 --- a/frontend/src/views/system/task/TaskRecord.vue +++ b/frontend/src/views/system/task/TaskRecord.vue @@ -1,8 +1,8 @@