import { IPSAppView } from '../../app/view/ipsapp-view'; import { IPSControl } from '../ipscontrol'; import { IPSDBAppViewPortletPart } from './ipsdbapp-view-portlet-part'; import { PSDBPortletPartImpl } from './psdbportlet-part-impl'; export class PSDBAppViewPortletPartImpl extends PSDBPortletPartImpl implements IPSDBAppViewPortletPart { protected contentpscontrol: IPSControl | null = null; getContentPSControl(): IPSControl | null { if (this.contentpscontrol != null) return this.contentpscontrol; const value = this.M.getContentPSControl; if (value == null) { return null; } this.contentpscontrol = this.findPSControl(value); return this.contentpscontrol; } get contentPSControl(): IPSControl | null { return this.getContentPSControl(); } getContentPSControlMust(): IPSControl { const value = this.getContentPSControl(); if (value == null) { throw new Error('未指定内容部件'); } return value; } protected portletpsappview: IPSAppView | null = null; getPortletPSAppView(): IPSAppView | null { if (this.portletpsappview != null) return this.portletpsappview; const value = this.M.getPortletPSAppView; if (value == null) { return null; } this.portletpsappview = this.getPSModel4('app.view.IPSAppView', value, 'getPortletPSAppView') as IPSAppView; return this.portletpsappview; } get portletPSAppView(): IPSAppView | null { return this.getPortletPSAppView(); } getPortletPSAppViewMust(): IPSAppView { const value = this.getPortletPSAppView(); if (value == null) { throw new Error('未指定嵌入视图对象'); } return value; } get portletType(): 'LIST' | 'CHART' | 'VIEW' | 'HTML' | 'TOOLBAR' | 'ACTIONBAR' | 'CUSTOM' | 'APPMENU' | 'CONTAINER' | 'RAWITEM' { return this.M.portletType; } get cls(): string { return 'PSDBAppViewPortletPartImpl'; } instanceof(cls: string): boolean { if (cls == 'control.dashboard.IPSDBAppViewPortletPart') return true; return super.instanceof(cls); } }