diff --git a/discovery-frontend/src/app/common/component/paging-search-select/paging-search-select.component.html b/discovery-frontend/src/app/common/component/paging-search-select/paging-search-select.component.html index 7ee50b4637..db72a2b90b 100644 --- a/discovery-frontend/src/app/common/component/paging-search-select/paging-search-select.component.html +++ b/discovery-frontend/src/app/common/component/paging-search-select/paging-search-select.component.html @@ -12,7 +12,7 @@ ~ limitations under the License. --> -
{{getSelectedItem}}
-
+
diff --git a/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-query.component.ts b/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-query.component.ts index c64a358b40..27d94b18b5 100644 --- a/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-query.component.ts +++ b/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-query.component.ts @@ -690,7 +690,7 @@ export class CreateDatasetDbQueryComponent extends AbstractPopupComponent implem this.loadingShow(); if (!this.datasetJdbc.dataconnection.connection) { - this.datasetJdbc.dcId = this.datasetJdbc.dataconnection.id; + // this.datasetJdbc.dcId = this.datasetJdbc.dataconnection.id; const connectionInfo = _.clone(this.datasetJdbc.dataconnection); @@ -713,6 +713,10 @@ export class CreateDatasetDbQueryComponent extends AbstractPopupComponent implem this.datasetJdbc.dataconnection.connection.catalog = connectionInfo.catalog; } + if (this.datasetJdbc.dataconnection.connection.implementor === 'TIBERO' && !connectionInfo.url) { + this.datasetJdbc.dataconnection.connection.sid = connectionInfo.sid; + } + } @@ -818,15 +822,17 @@ export class CreateDatasetDbQueryComponent extends AbstractPopupComponent implem */ private _drawGrid(headers: header[], rows : any[]) { // 그리드가 영역을 잡지 못해서 setTimeout으로 처리 - setTimeout(() => { - this.gridComponent.create(headers, rows, new GridOption() - .SyncColumnCellResize(true) - .MultiColumnSort(true) - .RowHeight(32) - .NullCellStyleActivate(true) - .build() - )},400); - this.clickable = true; + if (this.gridComponent) { + setTimeout(() => { + this.gridComponent.create(headers, rows, new GridOption() + .SyncColumnCellResize(true) + .MultiColumnSort(true) + .RowHeight(32) + .NullCellStyleActivate(true) + .build() + )},400); + this.clickable = true; + } } diff --git a/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.html b/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.html index 6de6dc94c2..59ee0343e5 100644 --- a/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.html +++ b/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.html @@ -29,224 +29,52 @@
+
- +
- - - + [isEnableObjectKey]="true" + [objectKey]="'name'" + [pageNum]="pageResult.number" + [usePlaceholder]="true" + [isConnection]="true" + [isOptionToLeft]="true" + [unselectedMessage]="'msg.storage.ui.load.dconn' | translate"> + + + + + +
- -
-
- -
- - -
- - - -
-
-
- - -
- - - {{ 'msg.storage.alert.host.required' | translate }} -
- - - -
- - - {{ 'msg.storage.alert.port.required' | translate }} -
- - - -
- - - {{'msg.storage.alert.sid.required' | translate}} -
- - - -
- - - {{'msg.storage.alert.db.required' | translate}} -
- - - -
- - - {{'msg.storage.ui.required' | translate}} -
- - - -
- - - {{'msg.storage.alert.url.required' | translate}} -
- - - -
- -
- - - -
- -
- -
- - - {{'msg.storage.alert.user-name.required' | translate}} -
- - - - -
- - - {{'msg.storage.alert.pw.required' | translate}} -
- - - -
- - -
- - -
    -
  • - - {{'msg.storage.ui.conn.dialog.desc' | translate}} -
  • -
- - - - -
- - {{'msg.dp.btn.test' | translate}} - -
- - {{'msg.storage.ui.required' | translate}} - {{'msg.storage.ui.invalid.conn' | translate}} - {{'msg.storage.ui.valid.conn' | translate}} - -
-
- -
- - -
-
- - - - - - - - - - - - - - + + -
diff --git a/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.ts b/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.ts index a5ba34da8b..1f18c371ca 100644 --- a/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.ts +++ b/discovery-frontend/src/app/data-preparation/dataset/create-dataset/create-dataset-db-select.component.ts @@ -12,15 +12,19 @@ * limitations under the License. */ -import { Component, ElementRef, Injector, OnInit, Input } from '@angular/core'; +import {Component, ElementRef, Injector, OnInit, Input, ViewChild} from '@angular/core'; import { AbstractPopupComponent } from '../../../common/component/abstract-popup.component'; import { PopupService } from '../../../common/service/popup.service'; -import { PrDatasetJdbc, DsType, ImportType, QueryInfo, TableInfo } from '../../../domain/data-preparation/pr-dataset'; -import { ImplementorType, Dataconnection } from '../../../domain/dataconnection/dataconnection'; +import { + PrDatasetJdbc, + DsType, + ImportType, QueryInfo, TableInfo, +} from '../../../domain/data-preparation/pr-dataset'; import { DataconnectionService } from '../../../dataconnection/service/dataconnection.service'; -import { ConnectionRequest } from '../../../domain/dataconnection/connectionrequest'; -import { isNullOrUndefined, isUndefined } from 'util'; -import { DatasetService } from "../service/dataset.service"; +import { isNullOrUndefined } from 'util'; +import {ConnectionComponent} from "../../../data-storage/component/connection/connection.component"; +import {PageResult} from "../../../domain/common/page"; +import {Dataconnection} from "../../../domain/dataconnection/dataconnection"; @Component({ selector: 'app-create-dataset-db-select', @@ -32,6 +36,8 @@ export class CreateDatasetDbSelectComponent extends AbstractPopupComponent imple /*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= | Private Variables |-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/ + @ViewChild(ConnectionComponent) + private readonly _connectionComponent: ConnectionComponent; /*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= | Protected Variables @@ -40,75 +46,15 @@ export class CreateDatasetDbSelectComponent extends AbstractPopupComponent imple /*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= | Public Variables |-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/ - private firstFl: boolean = true; - - // 커넥션 연결 success flag - public connectionResultFl: boolean = null; - - public isUrl : boolean = false; - @Input() - //public datasetJdbc: DatasetJdbc; public datasetJdbc: PrDatasetJdbc; - // 데이터 커넥션 리스트 - public databaseTypeList: any[] = [ - // { label: 'Oracle', value: 'ORACLE' }, - { label: 'MySQL', value: 'MYSQL' }, - { label: 'Hive', value: 'HIVE' }, - { label: 'Presto', value: 'PRESTO' }, - { label: 'PostgreSQL', value: 'POSTGRESQL' } - ]; - - // 선택한 URL 타입 - public selectedUrlType: string; - public urlTypes: any[]; - - // 선택한 dataconnection 객체 - public dataconnection: Dataconnection = new Dataconnection(); - - // 선택한 database 객체 - public selectedDatabase: any; - - // preset list - public connectionList: any[] = []; - - // connection result 결과 - public connectionResult: string = ''; - - // connectio error 결과값 description - public connectionErrorDescription: string = ''; + public connectionList: Connection[] = []; - // select box 선택값 - public defaultSelectedIndex = 0; - - // connection request 객체 - public connectionRequest: ConnectionRequest = new ConnectionRequest(); - - // security type list - public securityTypeList: any[]; - - public selectedSecurityType: any; - - // input validation - public isShowHostRequired: boolean; - public isShowPortRequired: boolean; - public isShowSidRequired: boolean; - public isShowDatabaseRequired: boolean; - public isShowCatalogRequired: boolean; - public isShowUrlRequired: boolean; - public isShowUsernameRequired: boolean; - public isShowPasswordRequired: boolean; - - - public isNextBtnClicked: boolean; /*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= | Constructor |-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/ - - // 생성자 constructor(private popupService: PopupService, - private datasetService : DatasetService, protected connectionService: DataconnectionService, protected elementRef: ElementRef, protected injector: Injector) { @@ -120,72 +66,59 @@ export class CreateDatasetDbSelectComponent extends AbstractPopupComponent imple | Override Method |-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/ - // Init public ngOnInit() { - // Init super.ngOnInit(); - this.getConnections(); + this.pageResult.number = 0; + this.pageResult.size = 20; - this.initView(); + // 처음 + if (isNullOrUndefined(this.datasetJdbc.connectionList)) { + this.datasetJdbc.dsType = DsType.IMPORTED; + this.datasetJdbc.importType = ImportType.DATABASE; + this._getConnections(); + } else { + // 이미 커넥션 리스트가 있음 + this.connectionList = this.datasetJdbc.connectionList; + this._connectionComponent.init(this.datasetJdbc.dataconnection.connection); + this._connectionComponent.isValidConnection = true; + } } - // Destory - public ngOnDestroy() { - // Destory + public ngOnDestroy() { super.ngOnDestroy(); } /*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= | Public Method |-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/ - public initView() { - - this.datasetJdbc.dsType = DsType.IMPORTED; - this.datasetJdbc.importType = ImportType.DATABASE; - - this.selectedDatabase = this.databaseTypeList[0]; - - // URL 타입 - this.urlTypes = [ - { label: this.translateService.instant('msg.storage.ui.conn.default'), value: 'DEFAULT' }, - { label: this.translateService.instant('msg.storage.ui.conn.url.only'), value: 'URL' } - ]; - this.selectedUrlType = this.urlTypes[0].value; - - this.securityTypeList = [ - { label: this.translateService.instant('msg.storage.li.connect.always'), value: 'MANUAL' }, - { label: this.translateService.instant('msg.storage.li.connect.account'), value: 'USERINFO' }, - { label: this.translateService.instant('msg.storage.li.connect.id'), value: 'DIALOG' } - ]; - this.selectedSecurityType = this.securityTypeList[0]; - - } + /** + * When next button is clicked + */ public next() { - this.isNextBtnClicked = true; + this._connectionComponent.isConnectionCheckRequire = true; if (this.isEnableNext()) { - if (this.connectionResult !== 'valid') { - this.connectionResultFl = false; - this.connectionResult = 'Required'; - return; - } else { - this.datasetJdbc.dcId = this.dataconnection.id; - this.datasetJdbc.dataconnection = this.dataconnection; - this.popupService.notiPopup({ - name: 'create-db-query', - data: null - }); - } + this.datasetJdbc.dataconnection = this._connectionComponent.getConnectionParams(); + this.datasetJdbc.connectionList = this.connectionList; + + this.popupService.notiPopup({ + name: 'create-db-query', + data: null + }); } } + + /** + * Close popup + */ public close() { super.close(); @@ -195,237 +128,92 @@ export class CreateDatasetDbSelectComponent extends AbstractPopupComponent imple }); } - public selectConnection($event: any, isChanged : boolean = false) { - - - if (isChanged) { // Refresh when user changes data connnection - this.datasetJdbc.sqlInfo = new QueryInfo(); - this.datasetJdbc.tableInfo = new TableInfo(); - this.datasetJdbc.rsType = undefined; - - } - - for (let key in this.dataconnection) { - if (this.dataconnection.hasOwnProperty(key)) { - delete this.dataconnection[key]; - } - } - const keyList = ['id','name','implementor','hostname','port','username','password','sid','database','catalog','url', 'authenticationType']; - for(let key of keyList) { - if($event.hasOwnProperty(key)) { - - this.dataconnection[key] = $event[key]; - } - } - - this.isUrl = !isNullOrUndefined(this.dataconnection.url) && this.dataconnection.url !== ''; - - for(let datadaseType of this.databaseTypeList) { - if(datadaseType.value === this.dataconnection.implementor) { - this.selectedDatabase = datadaseType; - break; - } - } - - this.selectedSecurityType = this.securityTypeList.find(type => type.value === this.dataconnection.authenticationType) || this.securityTypeList[0]; - - - this.initConnectionFlag(); - this.initConnectionResultFlag(); - - } - - public isEqualTypeValue(targetType, selectedType): boolean { - return targetType.value === selectedType.value; - } - - - /** - * 데이터베이스이름이 필요한 DB 타입인지 확인 - * @returns {boolean} - */ - public isDbNameRequired() : boolean { - return this.isEqualTypeValue({ value: 'POSTGRESQL' }, this.selectedDatabase); - } - - /** - * sid가 필요한 DB 타입인지 확인 - * @returns {boolean} - */ - public isSIDRequired() : boolean { - return this.isEqualTypeValue({ value: 'TIBERO' }, this.selectedDatabase) - || this.isEqualTypeValue({ value: 'ORACLE' }, this.selectedDatabase); - } - - /** - * catalog가 필요한 DB 타입인지 확인 - * @returns {boolean} - */ - public isCatalogRequired() : boolean { - return this.isEqualTypeValue({ value: 'PRESTO' }, this.selectedDatabase); - } - - /** - * 프리셋 데이터 초기화 - */ - public initConnectionResultFlag() { - - this.isNextBtnClicked = false; - this.connectionResultFl = null; - - } /** - * connection validation message - * @returns {string} + * Initialise _connection component + * @param connection */ - public getValidationMessage(): boolean { - let result: boolean = true; - if(!this.isUrl) { - // hostname - if (!this.dataconnection.hostname || this.dataconnection.hostname.trim() === '') { - this.isShowHostRequired = true; - result = false; - } - // port - if (!this.dataconnection.port) { - this.isShowPortRequired = true; - result = false; - } - // sid - if (this.isSIDRequired() && (!this.dataconnection.sid || this.dataconnection.sid.trim() === '')) { - this.isShowSidRequired = true; - result = false; - } - // database - if (this.isDbNameRequired() && (!this.dataconnection.database || this.dataconnection.database.trim() === '')) { - this.isShowDatabaseRequired = true; - result = false; - } - // catalog - if (this.isCatalogRequired() && (!this.dataconnection.catalog || this.dataconnection.catalog.trim() === '')) { - this.isShowCatalogRequired = true; - result = false; - } + public selectConnection(connection) { + if (!isNullOrUndefined(connection)) { + this._connectionComponent.init(connection); } else { - // url - if (!this.dataconnection.url || this.dataconnection.url.trim() === '') { - this.isShowUrlRequired = true; - result = false; - } + this._connectionComponent.init(); } - if (!this.isConnectUserAccount()) { - - // username - if (!this.dataconnection.username || this.dataconnection.username.trim() === '') { - this.isShowUsernameRequired = true; - result = false; - } - - // password - if (!this.dataconnection.password || this.dataconnection.password.trim() === '') { - this.isShowPasswordRequired = true; - result = false; - } - - } - - return result; } + /** - * Check connection - API + * Get connection detail information */ - public checkConnection() { - - this.dataconnection.implementor = this.getImplementor(this.selectedDatabase.value); - this.connectionRequest.connection = this.dataconnection; + public getConnectionDetail() { this.loadingShow(); - this.connectionService.checkConnection(this.connectionRequest) - .then((data) => { + // get connection data in preset + this.connectionService.getDataconnectionDetail(this.datasetJdbc.dcId) + .then((connection: Dataconnection) => { + // loading hide this.loadingHide(); - if (!isUndefined(data.connected)) { - if (data.connected === false) { - this.connectionResult = 'Invalid'; - this.connectionResultFl = false; - this.connectionErrorDescription = data.message; - } else if (data.connected === true) { - this.connectionResult = 'valid'; - this.connectionResultFl = true; - } - } + this.selectConnection(connection); }) - .catch((error) => { - this.loadingHide(); - this.connectionErrorDescription = error.message; - this.connectionResult = 'Invalid'; - this.connectionResultFl = false; - }); - } - - // 선택한 db type - public setDatabase(db) { - - if (this.dataconnection.id || this.connectionList.length === 0) { - return; - } - - this.connectionResult = ''; - this.selectedDatabase = db; - this.defaultSelectedIndex = -1; - this.connectionInit(db); + .catch(error => this.commonExceptionHandler(error)); } /** - * init connection input flag + * Check if user can proceed to next step + * @returns {boolean} */ - public initConnectionFlag(): void { - this.isShowHostRequired = null; - this.isShowPortRequired = null; - this.isShowSidRequired = null; - this.isShowDatabaseRequired = null; - this.isShowCatalogRequired = null; - this.isShowUrlRequired = null; - this.isShowUsernameRequired = null; - this.isShowPasswordRequired = null; + public isEnableNext(): boolean { + return this._connectionComponent.isValidConnection; } /** - * When TEST button is clicked + * Get selectedConnectionPreset index in connectionPreset list + * @returns {number} */ - public clickValidationBtn() { - this.getValidationMessage() && this.checkConnection(); + public getConnectionDefaultIndex(): number { + // 커넥션 있을때만 작동 + return this.datasetJdbc.dcId + ? this.connectionList.findIndex((item) => { + return item.id === this.datasetJdbc.dcId; + }) + : 0; } /** - * Security : is DIALOG - * @returns {boolean} + * When it's scrolled + * @param number */ - public isConnectWithIdAndPassword(): boolean { - return this.selectedSecurityType.value === 'DIALOG'; + public onScrollPage(number) { + // if remain next page + if (this._isMorePage()) { + // save pageResult + this.pageResult.number = number; + // get more preset list + this._getConnections(); + } } /** - * Security : is USERINFO - * @returns {boolean} + * When a connection is selected from list + * @param event */ - public isConnectUserAccount(): boolean { - return this.selectedSecurityType.value === 'USERINFO'; - } + public onConnectionSelected(event) { + // only fetch data when it's different + if (this.datasetJdbc.dcId !== event.id) { + this.datasetJdbc.dcId = event.id; + this.getConnectionDetail(); - /** - * Check if user can proceed to next step - * @returns {boolean} - */ - public isEnableNext(): boolean { - return this.connectionResultFl; + // refresh existing data + this.datasetJdbc.sqlInfo = new QueryInfo(); + this.datasetJdbc.tableInfo = new TableInfo(); + this.datasetJdbc.rsType = undefined; + } } /*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= @@ -435,114 +223,81 @@ export class CreateDatasetDbSelectComponent extends AbstractPopupComponent imple /*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= | Private Method |-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=*/ - // data connection list 가져오기. - private getConnections() { - this.connectionService.getDataconnections({'projection':'default'}) - .then((data) => { - if (data.hasOwnProperty('_embedded') && data['_embedded'].hasOwnProperty('connections')) { + /** + * Get parameter for connection list + * @param {PageResult} pageResult + * @returns {Object} + * @private + */ + private _getConnectionPresetListParams(pageResult: PageResult): object { + return { + authenticationType:'MANUAL', + size: pageResult.size, + page: pageResult.number, + type: 'jdbc' + }; + } - // FIXME : only MANUAL type can be used to make dataset (No server side API) - this.connectionList = data['_embedded']['connections'].filter((item) => { - return item.authenticationType === 'MANUAL' - }); - if (this.connectionList.length !== 0 && isNullOrUndefined(this.datasetJdbc.dataconnection)) { - this.selectConnection(this.connectionList[0]); + /** + * Fetch dataset connections + */ + private _getConnections() { - } else if (!isNullOrUndefined(this.datasetJdbc.dataconnection.connection)) { + this.loadingShow(); - const connArr = this.connectionList.map((item) => {return item.id}); + this.connectionService.getAllDataconnections(this._getConnectionPresetListParams(this.pageResult), 'forSimpleListView') + .then((data) => { - if (connArr.indexOf(this.datasetJdbc.dcId) !== -1) { - this.defaultSelectedIndex = connArr.indexOf(this.datasetJdbc.dcId); + // 리스트가 있다면 + if (data.hasOwnProperty('_embedded')) { - if (this.datasetJdbc.dataconnection.connection.username && this.datasetJdbc.dataconnection.connection.password) { - if (isNullOrUndefined(this.connectionList[this.defaultSelectedIndex].username)) { - this.connectionList[this.defaultSelectedIndex].username = this.datasetJdbc.dataconnection.connection.username; - this.connectionList[this.defaultSelectedIndex].password = this.datasetJdbc.dataconnection.connection.password; - } - } + // 리스트 추가 + this.connectionList = this.connectionList.concat(data['_embedded'].connections); - this.selectConnection(this.connectionList[this.defaultSelectedIndex]); - } + if (this.connectionList.length !== 0 ) { - this.connectionResult = 'valid'; - this.connectionResultFl = true; + // 첫번째 커넥션 등록 + this.datasetJdbc.dcId = this.connectionList[0].id; + this.getConnectionDetail(); + } else { + this.loadingHide(); + // 커넥션 리스트가 0개 라면 + this.selectConnection(null); } + } else { + this.loadingHide(); + // no connections + this.connectionList = []; + this.selectConnection(null) } + + this.pageResult = data['page']; + }) .catch((err) => { + this.loadingHide(); console.info('getConnections err)', err.toString()); }); } - - private connectionInit(db) { - for (let key in this.dataconnection) { if (this.dataconnection.hasOwnProperty(key)) delete this.dataconnection[key]; } - this.dataconnection.implementor = this.getImplementor(db.value); - } - - // protected -> private - private getImplementor(param: string): ImplementorType { - if (param === 'H2') { - return ImplementorType.H2; - } else if (param === 'MYSQL') { - return ImplementorType.MYSQL; - } else if (param === 'ORACLE') { - return ImplementorType.ORACLE; - } else if (param === 'TIBERO') { - return ImplementorType.TIBERO; - } else if (param === 'HIVE') { - return ImplementorType.HIVE; - } else if (param === 'HAWQ') { - return ImplementorType.HAWQ; - } else if (param === 'POSTGRESQL') { - return ImplementorType.POSTGRESQL; - } else if (param === 'MSSQL') { - return ImplementorType.MSSQL; - } else if (param === 'PRESTO') { - return ImplementorType.PRESTO; - } else if (param === 'PHOENIX') { - return ImplementorType.PHOENIX; - } else if (param === 'NVACCEL') { - return ImplementorType.NVACCEL; - } else if (param === 'STAGE') { - return ImplementorType.STAGE; - } else if (param === 'FILE') { - return ImplementorType.FILE; - } - } - /** - * url 타입 변경 이벤트 - * @param {string} urlType + * Check if there's more pages to load + * @private */ - public onSelectedUrlType(urlType: string): void { - // 타입이 같지 않을때만 동작 - if (this.selectedUrlType !== urlType) { - // url 타입 - this.selectedUrlType = urlType; - // 커넥션 플래그 초기화 - this.initConnectionFlag(); - } + private _isMorePage(): boolean { + return (this.pageResult.number < this.pageResult.totalPages - 1); } - /** - * url이 default 타입이라면 - * @returns {boolean} - */ - public isDefaultType(): boolean { - return this.selectedUrlType === 'DEFAULT'; - } +} - /** - * Check checkbox - */ - public check() { - this.isUrl = !this.isUrl; - } +class Connection { + id: string; + implementor: string; + name: string; + type: string; } diff --git a/discovery-frontend/src/app/domain/data-preparation/pr-dataset.ts b/discovery-frontend/src/app/domain/data-preparation/pr-dataset.ts index 7fb5baa9fd..813bb38a07 100644 --- a/discovery-frontend/src/app/domain/data-preparation/pr-dataset.ts +++ b/discovery-frontend/src/app/domain/data-preparation/pr-dataset.ts @@ -12,7 +12,7 @@ * limitations under the License. */ -import { AbstractHistoryEntity } from '../common/abstract-history-entity'; +import {AbstractHistoryEntity, UserDetail} from '../common/abstract-history-entity'; import { PrDataflow } from './pr-dataflow'; import {header} from "../../common/component/grid/grid.header"; @@ -161,6 +161,7 @@ export class PrDatasetJdbc extends PrDataset { public tableInfo? : TableInfo; public dataconnection: any; + public connectionList?: any[]; } export class Rule { diff --git a/discovery-frontend/src/assets/css/metatron/component/component.form.css b/discovery-frontend/src/assets/css/metatron/component/component.form.css index 0a13167b57..4b31f724cb 100644 --- a/discovery-frontend/src/assets/css/metatron/component/component.form.css +++ b/discovery-frontend/src/assets/css/metatron/component/component.form.css @@ -130,10 +130,6 @@ .ddp-wrap-edit3 .ddp-wrap-hover-info .ddp-box-layout4 {display:none; position:absolute; top:-15px; left:20px; width:320px;} .ddp-wrap-edit3 .ddp-wrap-hover-info:hover .ddp-box-layout4 {display:block;} -/*.ddp-info-inline .ddp-wrap-hover-info {display:inline-block; position:relative; vertical-align: middle; cursor: pointer;}*/ -/*.ddp-info-inline .ddp-wrap-hover-info em.ddp-icon-info3 {display:inline-block; position:relative; top:-1px; width:11px; height:11px; background:url(../../../images/icon_que.png) no-repeat; background-position:left -12px;}*/ -/*.ddp-info-inline .ddp-wrap-hover-info .ddp-box-layout4 {display:none; position:absolute; top:-40px; left:20px; width:240px;}*/ -/*.ddp-info-inline .ddp-wrap-hover-info .ddp-box-layout4.ddp-bottom {top:inherit; bottom:-30px;}*/ .ddp-wrap-edit3 .ddp-ui-edit-suboption {overflow:hidden;} .ddp-wrap-edit3 .ddp-ui-edit-option .ddp-ui-option-in .ddp-input-typebasic {margin-top:-9px;} @@ -160,7 +156,7 @@ .ddp-wrap-edit3 .ddp-ui-edit-option.ddp-type.ddp-btn-multy .ddp-btn-gray {position:absolute; top:0; right:0; width:100px; padding:7px; text-align:center; box-sizing:border-box;} .ddp-wrap-edit3 .ddp-ui-edit-option .ddp-data-error {position:absolute; bottom:4px; left:0; color:#e70000; font-size:12px; font-style:italic;} -.ddp-wrap-edit3 .ddp-ui-edit-option .ddp-data-error:before {display:inline-block; width:13px; height:13px; vertical-align:middle; background:url(../../../images/icon_info.png) no-repeat; background-position:-28px top; content:'';} +.ddp-wrap-edit3 .ddp-ui-edit-option .ddp-data-error:before {display:inline-block; margin-right:2px; width:13px; height:13px; vertical-align:middle; background:url(../../../images/icon_info.png) no-repeat; background-position:-28px top; content:'';} .ddp-wrap-edit3 .ddp-ui-edit-option.ddp-error .ddp-data-error {bottom:-15px;} @@ -188,7 +184,7 @@ .ddp-wrap-edit4 .ddp-form-edit.type-file {white-space:nowrap;} .ddp-wrap-edit4 .ddp-form-edit.type-file input {display:inline-block; float:left; width:460px; margin-right:4px;} .ddp-wrap-edit4 .ddp-form-edit.type-file .ddp-btn-pop {float:left;} -.ddp-wrap-edit4 .ddp-form-edit.type-file .ddp-form-file {disiplay:inline-block;} +.ddp-wrap-edit4 .ddp-form-edit.type-file .ddp-form-file {display:inline-block;} .ddp-wrap-edit4 .ddp-form-edit.type-file .ddp-ui-message {display:inline-block; margin-left:10px; white-space:nowrap; vertical-align: middle;} .ddp-wrap-edit4 .ddp-form-edit.type-file .ddp-ui-message [class*="ddp-data-"] {display:block; position:relative; top:6px; padding-top:0;} /**************************************************************