import { IPSLayout } from '../layout/ipslayout'; import { IPSLayoutPos } from '../layout/ipslayout-pos'; import { IPSPanelItemCatGroupLogic } from './ipspanel-item-cat-group-logic'; import { IPSSysPanelItem } from './ipssys-panel-item'; import { IPSLanguageRes } from '../../res/ipslanguage-res'; import { IPSSysCss } from '../../res/ipssys-css'; import { IPSSysImage } from '../../res/ipssys-image'; import { IPSSysPFPlugin } from '../../res/ipssys-pfplugin'; import { PSModelObjectImpl } from '../../psmodel-object-impl'; export class PSSysPanelItemImpl extends PSModelObjectImpl implements IPSSysPanelItem { protected cappslanguageres: IPSLanguageRes | null = null; getCapPSLanguageRes(): IPSLanguageRes | null { if (this.cappslanguageres != null) return this.cappslanguageres; const value = this.M.getCapPSLanguageRes; if (value == null) { return null; } this.cappslanguageres = this.getPSModel4('res.IPSLanguageRes', value, 'getCapPSLanguageRes') as IPSLanguageRes; return this.cappslanguageres; } get capPSLanguageRes(): IPSLanguageRes | null { return this.getCapPSLanguageRes(); } getCapPSLanguageResMust(): IPSLanguageRes { const value = this.getCapPSLanguageRes(); if (value == null) { throw new Error('未指定标题语言资源'); } return value; } get caption(): string { return this.M.caption; } get codeName(): string { return this.M.codeName; } get contentHeight(): number { return this.M.contentHeight != null ? this.M.contentHeight : 0.0; } get contentWidth(): number { return this.M.contentWidth != null ? this.M.contentWidth : 0.0; } get dynaClass(): string { return this.M.dynaClass; } get dynaModelFilePath(): string { return this.M.dynaModelFilePath; } get height(): number { return this.M.height != null ? this.M.height : 0.0; } get itemStyle(): 'DEFAULT' | 'STYLE2' | 'STYLE3' | 'STYLE4' { return this.M.itemStyle; } get itemType(): string { return this.M.itemType; } get labelCssStyle(): string { return this.M.labelCssStyle; } get labelDynaClass(): string { return this.M.labelDynaClass; } protected labelpssyscss: IPSSysCss | null = null; getLabelPSSysCss(): IPSSysCss | null { if (this.labelpssyscss != null) return this.labelpssyscss; const value = this.M.getLabelPSSysCss; if (value == null) { return null; } this.labelpssyscss = this.getPSModel4('res.IPSSysCss', value, 'getLabelPSSysCss') as IPSSysCss; return this.labelpssyscss; } get labelPSSysCss(): IPSSysCss | null { return this.getLabelPSSysCss(); } getLabelPSSysCssMust(): IPSSysCss { const value = this.getLabelPSSysCss(); if (value == null) { throw new Error('未指定标签样式表对象'); } return value; } get mOSFilePath(): string { return this.M.mOSFilePath; } get memo(): string { return this.M.memo; } get name(): string { return this.M.name; } protected pslayout: IPSLayout | null = null; getPSLayout(): IPSLayout | null { if (this.pslayout != null) return this.pslayout; const value = this.M.getPSLayout; if (value == null) { return null; } this.pslayout = this.getPSModel4('control.layout.IPSLayout', value, 'getPSLayout') as IPSLayout; return this.pslayout; } get psLayout(): IPSLayout | null { return this.getPSLayout(); } getPSLayoutMust(): IPSLayout { const value = this.getPSLayout(); if (value == null) { throw new Error('未指定布局设置'); } return value; } protected pslayoutpos: IPSLayoutPos | null = null; getPSLayoutPos(): IPSLayoutPos | null { if (this.pslayoutpos != null) return this.pslayoutpos; const value = this.M.getPSLayoutPos; if (value == null) { return null; } this.pslayoutpos = this.getPSModel4('control.layout.IPSLayoutPos', value, 'getPSLayoutPos') as IPSLayoutPos; return this.pslayoutpos; } get psLayoutPos(): IPSLayoutPos | null { return this.getPSLayoutPos(); } getPSLayoutPosMust(): IPSLayoutPos { const value = this.getPSLayoutPos(); if (value == null) { throw new Error('未指定位置'); } return value; } protected pspanelitemgrouplogics: IPSPanelItemCatGroupLogic[] | null = null; getPSPanelItemGroupLogics(): IPSPanelItemCatGroupLogic[] | null { if (this.pspanelitemgrouplogics == null) { this.pspanelitemgrouplogics = this.fillChildListModel(this.M.getPSPanelItemGroupLogics, 'control.panel.IPSPanelItemCatGroupLogic') as IPSPanelItemCatGroupLogic[]; } return this.pspanelitemgrouplogics; } get psPanelItemGroupLogics(): IPSPanelItemCatGroupLogic[] | null { return this.getPSPanelItemGroupLogics(); } findPSPanelItemCatGroupLogic(objKey: any): IPSPanelItemCatGroupLogic | null { return this.getPSModel5('control.panel.IPSPanelItemCatGroupLogic', this.getPSPanelItemGroupLogics(), objKey) as IPSPanelItemCatGroupLogic; } protected pssyscss: IPSSysCss | null = null; getPSSysCss(): IPSSysCss | null { if (this.pssyscss != null) return this.pssyscss; const value = this.M.getPSSysCss; if (value == null) { return null; } this.pssyscss = this.getPSModel4('res.IPSSysCss', value, 'getPSSysCss') as IPSSysCss; return this.pssyscss; } get psSysCss(): IPSSysCss | null { return this.getPSSysCss(); } getPSSysCssMust(): IPSSysCss { const value = this.getPSSysCss(); if (value == null) { throw new Error('未指定界面样式表'); } return value; } protected pssysimage: IPSSysImage | null = null; getPSSysImage(): IPSSysImage | null { if (this.pssysimage != null) return this.pssysimage; const value = this.M.getPSSysImage; if (value == null) { return null; } this.pssysimage = this.getPSModel4('res.IPSSysImage', value, 'getPSSysImage') as IPSSysImage; return this.pssysimage; } get psSysImage(): IPSSysImage | null { return this.getPSSysImage(); } getPSSysImageMust(): IPSSysImage { const value = this.getPSSysImage(); if (value == null) { throw new Error('未指定图片对象'); } return value; } protected pssyspfplugin: IPSSysPFPlugin | null = null; getPSSysPFPlugin(): IPSSysPFPlugin | null { if (this.pssyspfplugin != null) return this.pssyspfplugin; const value = this.M.getPSSysPFPlugin; if (value == null) { return null; } this.pssyspfplugin = this.getPSModel4('res.IPSSysPFPlugin', value, 'getPSSysPFPlugin') as IPSSysPFPlugin; return this.pssyspfplugin; } get psSysPFPlugin(): IPSSysPFPlugin | null { return this.getPSSysPFPlugin(); } getPSSysPFPluginMust(): IPSSysPFPlugin { const value = this.getPSSysPFPlugin(); if (value == null) { throw new Error('未指定前端扩展插件'); } return value; } get rTMOSFilePath(): string { return this.M.rTMOSFilePath; } get userCat(): string { return this.M.userCat; } get userTag(): string { return this.M.userTag; } get userTag2(): string { return this.M.userTag2; } get userTag3(): string { return this.M.userTag3; } get userTag4(): string { return this.M.userTag4; } get width(): number { return this.M.width != null ? this.M.width : 0.0; } get showCaption(): boolean { return this.M.showCaption != null ? this.M.showCaption : false; } get cls(): string { return 'PSSysPanelItemImpl'; } instanceof(cls: string): boolean { if (cls == 'control.layout.IPSLayoutItem' || cls == 'control.panel.IPSPanelItem' || cls == 'control.panel.IPSPanelObject' || cls == 'control.panel.IPSSysPanelItem') return true; return super.instanceof(cls); } }