From 2e55726f335cce02e6b8da60f571b824eb117f9b Mon Sep 17 00:00:00 2001 From: alan Date: Wed, 25 Sep 2019 15:36:06 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20DEC-10021=20=E4=BF=AE=E6=94=B9h2?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E8=BF=9E=E6=8E=A5=E9=BB=98=E8=AE=A4url?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/constants/constant.ts | 2 +- src/modules/pages/connection/connection.ts | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/modules/constants/constant.ts b/src/modules/constants/constant.ts index 53cd989..d685117 100644 --- a/src/modules/constants/constant.ts +++ b/src/modules/constants/constant.ts @@ -275,7 +275,7 @@ export const DATA_BASE_TYPES = [ text: 'H2', databaseType: 'h2', driver: 'org.h2.Driver', - url: 'jdbc:h2://hostname:port/../database', + url: 'jdbc:h2://${ENV_HOME}/../database', commonly: false, internal: true, type: 'jdbc', diff --git a/src/modules/pages/connection/connection.ts b/src/modules/pages/connection/connection.ts index 8efc1be..aab90d6 100644 --- a/src/modules/pages/connection/connection.ts +++ b/src/modules/pages/connection/connection.ts @@ -24,10 +24,10 @@ export class Connection extends BI.Widget { watch = { connectionSelected:(name: string) => { - const canEdit = connectionCanEdit(this.model.connectionSelectedOne); - this.connectionTitleWidget.setText(`${name}(${this.getSelectConnectionType()})`); - this.connectionEditWidget.setVisible(!!name && canEdit); if (name) { + const canEdit = connectionCanEdit(this.model.connectionSelectedOne); + this.connectionTitleWidget.setText(`${name}(${this.getSelectConnectionType()})`); + this.connectionEditWidget.setVisible(!!name && canEdit); const hasRegistered = this.hasRegistered(); this.title.setVisible(hasRegistered); if (!hasRegistered) { From ed176fe13586d883998a136d70610c210db66f4d Mon Sep 17 00:00:00 2001 From: alan Date: Wed, 25 Sep 2019 15:37:21 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E5=88=A4=E6=96=AD?= =?UTF-8?q?=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/pages/connection/connection.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/pages/connection/connection.ts b/src/modules/pages/connection/connection.ts index aab90d6..c581bb7 100644 --- a/src/modules/pages/connection/connection.ts +++ b/src/modules/pages/connection/connection.ts @@ -27,7 +27,7 @@ export class Connection extends BI.Widget { if (name) { const canEdit = connectionCanEdit(this.model.connectionSelectedOne); this.connectionTitleWidget.setText(`${name}(${this.getSelectConnectionType()})`); - this.connectionEditWidget.setVisible(!!name && canEdit); + this.connectionEditWidget.setVisible(canEdit); const hasRegistered = this.hasRegistered(); this.title.setVisible(hasRegistered); if (!hasRegistered) {