diff --git a/backend/src/main/java/io/dataease/service/panel/PanelGroupService.java b/backend/src/main/java/io/dataease/service/panel/PanelGroupService.java
index ae3ce9e76a..d026e84bc5 100644
--- a/backend/src/main/java/io/dataease/service/panel/PanelGroupService.java
+++ b/backend/src/main/java/io/dataease/service/panel/PanelGroupService.java
@@ -1068,9 +1068,10 @@ public class PanelGroupService {
datasetGroupHistoryInfo.setName(request.getDatasetGroupName());
datasetGroupHistoryInfo.setPid(request.getDatasetGroupPid());
datasetGroupMapper.updateByPrimaryKey(datasetGroupHistoryInfo);
-
- //数据源变更
- panelAppTemplateService.editDatasource(request.getDatasourceList());
+ if ("new".equals(request.getDatasourceFrom())) {
+ //数据源变更
+ panelAppTemplateService.editDatasource(request.getDatasourceList());
+ }
}
public void toTop(String panelId) {
diff --git a/frontend/src/views/system/datasource/DsFormContent.vue b/frontend/src/views/system/datasource/DsFormContent.vue
index a19fda77b5..057deb2716 100644
--- a/frontend/src/views/system/datasource/DsFormContent.vue
+++ b/frontend/src/views/system/datasource/DsFormContent.vue
@@ -71,8 +71,8 @@
{{
- positionCheck('appMarket') ? $t('app_template.datasource_info') : $t('datasource.basic_info')
- }}
+ positionCheck('appMarket') ? $t('app_template.datasource_info') : $t('datasource.basic_info')
+ }}
{{ $t('commons.validate') }}
@@ -270,7 +271,11 @@
>{{ $t('commons.cancel') }}
{{ $t('commons.save') }}
@@ -720,7 +725,7 @@ export default {
res.data.apiConfiguration = JSON.parse(Base64.decode(res.data.apiConfigurationStr))
}
this.params = { ...res.data, showModel }
- if(showModel === 'copy'){
+ if (showModel === 'copy') {
this.params.id = ''
}
this.$emit('setParams', { ...this.params })
@@ -809,16 +814,16 @@ export default {
},
saveAppMarketHistory() {
this.$refs.historyDsForm.validate(valid => {
- if (!valid) {
- return false
+ if (!valid) {
+ return false
+ }
+ const appApplyForm = {
+ ...this.attachForm,
+ ...this.historyDsForm
+ }
+ const method = this.formType === 'add' ? appApply : appEdit
+ this.appApplyMethod(method, appApplyForm)
}
- const appApplyForm = {
- ...this.attachForm,
- ...this.historyDsForm
- }
- const method = this.formType === 'add' ? appApply : appEdit
- this.appApplyMethod(method, appApplyForm)
- }
)
},
save() {
@@ -964,10 +969,10 @@ export default {
}
if (this.positionCheck('appMarket')) {
this.$refs.attachParamsForm.validate(valid => {
- if (!valid) {
- return false
+ if (!valid) {
+ return false
+ }
}
- }
)
}
this.$refs.dsForm.validate((valid) => {
@@ -1112,10 +1117,10 @@ export default {
}
if (this.positionCheck('appMarket')) {
this.$refs.attachParamsForm.validate(valid => {
- if (!valid) {
- return false
+ if (!valid) {
+ return false
+ }
}
- }
)
}
this.$refs.dsForm.validate((valid) => {