From 7581aca8cdff0ebcb68975cccc49ca12a4d34e84 Mon Sep 17 00:00:00 2001 From: alan Date: Wed, 2 Dec 2020 13:39:07 +0800 Subject: [PATCH 1/5] =?UTF-8?q?fix:=20DEC-16169=20=E6=94=B9=E7=94=A8provid?= =?UTF-8?q?er=E8=8E=B7=E5=8F=96=E6=8F=92=E4=BB=B6=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E8=BF=9E=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/app.provider.ts | 5 +++-- src/modules/app.service.ts | 5 ++--- src/modules/constants/constant.ts | 9 --------- 3 files changed, 5 insertions(+), 14 deletions(-) diff --git a/src/modules/app.provider.ts b/src/modules/app.provider.ts index 97f6753..af2db61 100644 --- a/src/modules/app.provider.ts +++ b/src/modules/app.provider.ts @@ -60,14 +60,15 @@ BI.provider('dec.connection.provider.datebase', function() { this.registerDatabaseType = (config: any) => { BI.config(CONSTANT_PLUGIN_TYPES, connections => BI.concat(connections, config)); }; - + this.registerJdbcDatabase = (config: any, resolve?: Function) => { BI.config(CONSTANT_PLUGIN_TYPES, connections => BI.concat(connections, { ...config, type: 'jdbc' })); - + BI.isFunction(resolve) && (this.resolves[config.databaseType] = resolve); }; this.$get = () => BI.inherit(BI.OB, { getJdbcResolveByType: (type: string) => this.resolves[type] || jdbcResolve, + customDatabaseType: BI.Constants.getConstant(CONSTANT_PLUGIN_TYPES), }); }); diff --git a/src/modules/app.service.ts b/src/modules/app.service.ts index d8a0a2c..145b807 100644 --- a/src/modules/app.service.ts +++ b/src/modules/app.service.ts @@ -1,11 +1,10 @@ import { DATA_BASE_TYPES, DATA_BASE_TYPES_OTHER, DESIGN_DRIVER_TYPE, OTHER_JDBC } from '@constants/constant'; -import { CONSTANT_PLUGIN_TYPES } from './app.constant'; import { DatabaseType } from './app.typings'; import { Connection } from './crud/crud.typings'; export function getAllDatabaseTypes():DatabaseType[] { return [ ...DATA_BASE_TYPES, - ...BI.Constants.getConstant(CONSTANT_PLUGIN_TYPES).map(item => { + ...BI.Providers.getProvider('dec.connection.provider.datebase').customDatabaseType.map(item => { return { ...item, internal: false, @@ -15,7 +14,7 @@ export function getAllDatabaseTypes():DatabaseType[] { ]; } function getPlugin(type: string) { - return BI.Constants.getConstant(CONSTANT_PLUGIN_TYPES).find(item => item.databaseType === type); + return BI.Providers.getProvider('dec.connection.provider.datebase').customDatabaseType.find(item => item.databaseType === type); } export function getPluginWidgetShow(plugin: string) { return BI.get(getPlugin(plugin), 'show'); diff --git a/src/modules/constants/constant.ts b/src/modules/constants/constant.ts index 0c7549f..d7519ec 100644 --- a/src/modules/constants/constant.ts +++ b/src/modules/constants/constant.ts @@ -1,5 +1,3 @@ -import { CONSTANT_PLUGIN_TYPES } from '../app.constant'; - export const PAGE_INDEX = { CONNECTION: 'connection', DATEBASE: 'datebase', @@ -619,13 +617,6 @@ export const DATA_BASE_TYPES = [ 'org.sqlite.JDBC': 'jdbc:sqlite:[PATH_TO_DB_FILES]', }, }, - ...BI.Constants.getConstant(CONSTANT_PLUGIN_TYPES).map(item => { - return { - ...item, - internal: false, - commonly: false, - }; - }), ]; From 1feaa2ec4b01dea86fb2785817f9e4cd18d673c6 Mon Sep 17 00:00:00 2001 From: qiucong Date: Mon, 7 Dec 2020 15:08:56 +0800 Subject: [PATCH 2/5] =?UTF-8?q?KERNEL-6272=20feat:=20FTP,=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E8=BF=9E=E6=8E=A5=E7=AD=89=E7=B3=BB=E7=BB=9F=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E9=85=8D=E7=BD=AE=E5=AF=86=E7=A0=81=E7=9A=84=E5=9C=B0?= =?UTF-8?q?=E6=96=B9=E9=9C=80=E8=A6=81=E5=B1=8F=E8=94=BD=E8=AE=B0=E4=BD=8F?= =?UTF-8?q?=E5=AF=86=E7=A0=81=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/pages/maintain/forms/components/form.jdbc.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/modules/pages/maintain/forms/components/form.jdbc.ts b/src/modules/pages/maintain/forms/components/form.jdbc.ts index f3f8043..e111ed2 100644 --- a/src/modules/pages/maintain/forms/components/form.jdbc.ts +++ b/src/modules/pages/maintain/forms/components/form.jdbc.ts @@ -260,6 +260,7 @@ export class FormJdbc extends BI.Widget { allowBlank: true, value: password, inputType: 'password', + autocomplete: 'new-password', watermark: BI.i18nText('Dec-Dcm_Connection_Form_Password'), ref: (_ref: any) => { this.form.password = _ref; From 4cc0ad2497aedecfbf5fbac9cf1135611872f6e9 Mon Sep 17 00:00:00 2001 From: qiucong Date: Mon, 7 Dec 2020 15:21:56 +0800 Subject: [PATCH 3/5] =?UTF-8?q?DEC-16248=20feat:=20Kyligence=E4=BC=81?= =?UTF-8?q?=E4=B8=9A=E7=89=88=E6=95=B0=E6=8D=AE=E6=BA=90=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E5=B9=B3=E5=8F=B0=E9=80=82=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/constants/constant.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/modules/constants/constant.ts b/src/modules/constants/constant.ts index d7519ec..b0e28ac 100644 --- a/src/modules/constants/constant.ts +++ b/src/modules/constants/constant.ts @@ -446,6 +446,16 @@ export const DATA_BASE_TYPES = [ type: 'jdbc', hasSchema: true, kerberos: false, + }, { + text: 'Kyligence', + databaseType: 'kyligence', + driver: 'org.apache.kylin.jdbc.Driver', + url: 'jdbc:kylin://hostname:port/database', + commonly: false, + internal: true, + type: 'jdbc', + hasSchema: true, + kerberos: false, }, { text: 'Microsoft SQL Server', databaseType: 'sql-server', From 619b427e5bda6f0a2932295aca758a70a71e0250 Mon Sep 17 00:00:00 2001 From: qiucong Date: Tue, 8 Dec 2020 11:51:35 +0800 Subject: [PATCH 4/5] =?UTF-8?q?DEC-16193=20feat:=20=E3=80=90BI=E3=80=91BI-?= =?UTF-8?q?76625=20ODPS=E6=94=B9=E4=B8=BAMaxCompute?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/constants/constant.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/constants/constant.ts b/src/modules/constants/constant.ts index b0e28ac..c30cbea 100644 --- a/src/modules/constants/constant.ts +++ b/src/modules/constants/constant.ts @@ -483,7 +483,7 @@ export const DATA_BASE_TYPES = [ }, }, { - text: 'ODPS', + text: 'MaxCompute', databaseType: 'odps', driver: 'com.aliyun.odps.jdbc.OdpsDriver', url: 'jdbc:odps:?project=', From 16240db2a986fa4a0428d1eecd833a4017460402 Mon Sep 17 00:00:00 2001 From: qiucong Date: Fri, 11 Dec 2020 10:04:01 +0800 Subject: [PATCH 5/5] =?UTF-8?q?DEC-16314=20fix:=20=E3=80=90=E8=BF=AD?= =?UTF-8?q?=E4=BB=A3=E3=80=91=E6=95=B0=E6=8D=AE=E8=BF=9E=E6=8E=A5=E2=80=94?= =?UTF-8?q?=E2=80=94Kyligence=E9=A9=B1=E5=8A=A8=E5=B8=AE=E5=8A=A9=E6=96=87?= =?UTF-8?q?=E6=A1=A3=E8=B7=B3=E8=BD=AC=E4=B8=8D=E5=AF=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/constants/constant.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/modules/constants/constant.ts b/src/modules/constants/constant.ts index c30cbea..7ec892d 100644 --- a/src/modules/constants/constant.ts +++ b/src/modules/constants/constant.ts @@ -119,6 +119,10 @@ export const DATA_BASE_DRIVER_LINK = DecCst && DecCst.Hyperlink ? [ databaseType: 'kingbase', link: DecCst.Hyperlink.Database.KINGBASE, }, + { + databaseType: 'kyligence', + link: DecCst.Hyperlink.Database.KYLIGENCE, + }, { databaseType: 'sql-server', link: DecCst.Hyperlink.Database.SQLSERVER,