@ -7,7 +7,16 @@ import { CONNECT_CHARSET, CONNECTION_LAYOUT, INT_MAX_VALUE, INT_MIN_VALUE } from
import { getAllDatabaseTypes , getJdbcDatabaseType , resolveUrlInfo , splitUrl } from '../../../../app.service' ;
import { TextChecker } from '../../../../components/text_checker/text_checker' ;
import { ApiFactory } from 'src/modules/crud/apiFactory' ;
import { Editor , EditorIconCheckCombo , Label , TextAreaEditor , TextEditor , TextValueCombo , VerticalLayout } from '@fui/core' ;
import {
Editor ,
EditorIconCheckCombo ,
Label ,
TextAreaEditor ,
TextEditor ,
TextValueCombo ,
VerticalLayout
} from '@fui/core' ;
const api = new ApiFactory ( ) . create ( ) ;
@shortcut ( )
@ -58,8 +67,33 @@ export class FormJdbc extends BI.Widget {
render() {
const { connectionName , connectionData } = this . options . formData ;
const { driver , user , password , originalCharsetName , schema , url , connectionPoolAttr , database , authType , principal , keyPath } = connectionData as ConnectionJDBC ;
const { initialSize , maxActive , maxIdle , maxWait , validationQuery , testOnBorrow , testOnReturn , testWhileIdle , timeBetweenEvictionRunsMillis , numTestsPerEvictionRun , minIdle , minEvictableIdleTimeMillis } = connectionPoolAttr as ConnectionPoolJDBC ;
const {
driver ,
user ,
password ,
originalCharsetName ,
schema ,
url ,
connectionPoolAttr ,
database ,
authType ,
principal ,
keyPath
} = connectionData as ConnectionJDBC ;
const {
initialSize ,
maxActive ,
maxIdle ,
maxWait ,
validationQuery ,
testOnBorrow ,
testOnReturn ,
testWhileIdle ,
timeBetweenEvictionRunsMillis ,
numTestsPerEvictionRun ,
minIdle ,
minEvictableIdleTimeMillis
} = connectionPoolAttr as ConnectionPoolJDBC ;
const databaseType = getJdbcDatabaseType ( database , driver ) ;
this . oldPassword = password ;
const { host , port , databaseName } = resolveUrlInfo ( url , database ) ;
@ -766,7 +800,7 @@ export class FormJdbc extends BI.Widget {
connectionType : connectionType.JDBC ,
connectionId : this.form.connectionName.getValue ( ) ,
connectionName : this.form.connectionName.getValue ( ) ,
connectionData : {
connectionData : < ConnectionJDBC > BI . extend ( { } , connectionData , {
database : connectionData.database ,
connectionName : this.form.connectionName.getValue ( ) ,
driver : this.form.driver.getValue ( ) ,
@ -796,7 +830,7 @@ export class FormJdbc extends BI.Widget {
numTestsPerEvictionRun : this.form.numTestsPerEvictionRun.getValue ( ) ,
minEvictableIdleTimeMillis : this.form.minEvictableIdleTimeMillis.getValue ( ) ,
} ,
} ,
} ) ,
} ;
}
}