import {WidgetType, Vertical} from '@ui/index'; import RightShowModel from '../../link-set.model'; import BothSide from '@shared/components/both.side.component'; import Title from '@shared/components/title.component'; import {LinkType} from '@ui/type'; const className = 'fr.component.right.show'; const Widget: WidgetType = { _store() { return BI.Models.getModel(RightShowModel); }, render() { const linkSelected: LinkType = this.model.linkSelected; return { type: Vertical, cls: 'right-show', items: [ { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-ConnectionName'), rightText: linkSelected.connectionName, }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-Driver'), rightText: linkSelected.driver, }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-URL'), rightText: linkSelected.url, }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-OriginalCharsetName'), rightText: linkSelected.originalCharsetName === '' ? BI.i18nText('BI-Connection-Form-Auto') : linkSelected.originalCharsetName, }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-UserName'), rightText: linkSelected.user, }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-Password'), rightText: linkSelected.password, }, { type: Title, text: BI.i18nText('BI-Connection-Form-Pool-Properties'), }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-SQL-Validation-Query'), rightText: linkSelected.validationQuery, }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-Connection-Check'), rightText: linkSelected.testOnBorrow ? BI.i18nText('BI-Yes') : BI.i18nText('BI-No'), }, { type: BothSide, leftText: BI.i18nText('BI-Connection-Form-Connection-Max-Number'), rightText: linkSelected.maxActive, }, ], }; }, }; BI.shortcut(className, BI.inherit(BI.Widget, Widget)); export default className;