From 403f1d6eaca3f91ea052a326b5cc4b2d4cf83896 Mon Sep 17 00:00:00 2001 From: "1437892690@qq.com" <1437892690@qq.com> Date: Thu, 5 Jun 2025 10:12:50 +0800 Subject: [PATCH] =?UTF-8?q?[=E5=8A=9F=E8=83=BD]=20neatlogic=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E4=BB=93=E5=BA=93=E6=94=AF=E6=8C=81=E9=85=8D=E7=BD=AE?= =?UTF-8?q?=E7=AC=AC=E4=B8=89=E6=96=B9=E6=95=B0=E6=8D=AE=E5=BA=93=E8=8E=B7?= =?UTF-8?q?=E5=8F=96=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 关联 #[1432467032998096]neatlogic数据仓库支持配置第三方数据库获取数据 http://192.168.0.96:8090/demo/rdm.html#/story-detail/939050947543040/939050947543042/1432467032998096 --- .../datawarehouse/datawarehouse-edit.vue | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/src/views/pages/framework/datawarehouse/datawarehouse-edit.vue b/src/views/pages/framework/datawarehouse/datawarehouse-edit.vue index 998ba7a4..3249deb1 100644 --- a/src/views/pages/framework/datawarehouse/datawarehouse-edit.vue +++ b/src/views/pages/framework/datawarehouse/datawarehouse-edit.vue @@ -251,15 +251,7 @@ export default { ], validateList: [{ name: 'required' }], onChange: dbType => { - if (dbType == 'mysql' || dbType == 'mongodb') { - this.reportDataSourceData.dbType = dbType; - } else { - let index = dbType.lastIndexOf('-'); - let type = dbType.substring(0, index); - let databaseId = dbType.substring(index + 1, dbType.length); - this.reportDataSourceData.dbType = type; - this.reportDataSourceData.databaseId = databaseId; - } + this.reportDataSourceData.dbType = dbType; } }, { @@ -437,6 +429,13 @@ export default { if (this.id) { this.reportDataSourceData.id = this.id; } + if (this.reportDataSourceData.dbType != 'mysql' && this.reportDataSourceData.dbType != 'mongodb') { + let index = this.reportDataSourceData.dbType.lastIndexOf('-'); + let type = this.reportDataSourceData.dbType.substring(0, index); + let databaseId = this.reportDataSourceData.dbType.substring(index + 1, this.reportDataSourceData.dbType.length); + this.reportDataSourceData.dbType = type; + this.reportDataSourceData.databaseId = databaseId; + } this.$api.framework.datawarehouse.saveDataSource(this.reportDataSourceData).then(res => { if (res.Status == 'OK') { this.$Message.success(this.$t('message.savesuccess')); -- Gitee