diff --git a/src/modules/pages/maintain/forms/form.ts b/src/modules/pages/maintain/forms/form.ts index ee0459a..0c8733c 100644 --- a/src/modules/pages/maintain/forms/form.ts +++ b/src/modules/pages/maintain/forms/form.ts @@ -210,13 +210,9 @@ export class MaintainForm extends BI.Widget { } private getConnectionName(name = BI.i18nText('Dec-Dcm_Data_Connections')) { - const defaultName = name.replace(/\d+$/, ''); - const connections = this.model.connections.filter(item => item.connectionName.startsWith(defaultName)); - if (connections.length === 0) { - return name; - } + const connections = this.model.connections.filter(item => item.connectionName.startsWith(name)); - return BI.Func.createDistinctName(connections.map(item => item.connectionName), defaultName); + return BI.Func.createDistinctName(connections.map(item => item.connectionName), name); } private testConnection() {