提交 0985de7c 编写于 作者: tony001's avatar tony001

Merge remote-tracking branch 'local/master' into dev

上级 24688cd8
<script lang='tsx'> <script lang='tsx'>
import { Vue, Component, Prop, Provide, Emit, Watch, Model } from 'vue-property-decorator'; import { Vue, Component, Prop, Provide, Emit, Watch, Model,Inject } from 'vue-property-decorator';
import { CreateElement } from 'vue'; import { CreateElement } from 'vue';
import { Subject, Subscription } from 'rxjs'; import { Subject, Subscription } from 'rxjs';
import { ControlInterface } from '@/interface/control'; import { ControlInterface } from '@/interface/control';
import { UIActionTool,Util } from '@/utils'; import { UIActionTool,Util } from '@/utils';
import NavDataService from '@/service/app/navdata-service';
<#if ctrl.getPSAppCounterRefs?? && ctrl.getPSAppCounterRefs()??> <#if ctrl.getPSAppCounterRefs?? && ctrl.getPSAppCounterRefs()??>
<#list ctrl.getPSAppCounterRefs() as singleCounterRef> <#list ctrl.getPSAppCounterRefs() as singleCounterRef>
<#if singleCounterRef.getPSAppCounter()??> <#if singleCounterRef.getPSAppCounter()??>
...@@ -44,7 +45,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -44,7 +45,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 名称 * 名称
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public name?: string; @Prop() public name?: string;
...@@ -52,7 +53,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -52,7 +53,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 视图通讯对象 * 视图通讯对象
* *
* @type {Subject<ViewState>} * @type {Subject<ViewState>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public viewState!: Subject<ViewState>; @Prop() public viewState!: Subject<ViewState>;
...@@ -60,7 +61,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -60,7 +61,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 应用上下文 * 应用上下文
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public context: any; @Prop() public context: any;
...@@ -68,7 +69,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -68,7 +69,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 视图参数 * 视图参数
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public viewparams: any; @Prop() public viewparams: any;
...@@ -77,7 +78,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -77,7 +78,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* *
* @public * @public
* @type {(Subscription | undefined)} * @type {(Subscription | undefined)}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewStateEvent: Subscription | undefined; public viewStateEvent: Subscription | undefined;
...@@ -85,7 +86,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -85,7 +86,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 获取部件类型 * 获取部件类型
* *
* @returns {string} * @returns {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getControlType(): string { public getControlType(): string {
return '${ctrl.getControlType()}' return '${ctrl.getControlType()}'
...@@ -103,7 +104,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -103,7 +104,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* ${srfclassname('${appCounter.getCodeName()}')}CounterService计数器服务对象 * ${srfclassname('${appCounter.getCodeName()}')}CounterService计数器服务对象
* *
* @type {${srfclassname('${appCounter.getCodeName()}')}CounterService} * @type {${srfclassname('${appCounter.getCodeName()}')}CounterService}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${srfclassname('${appCounter.getCodeName()}')}counterservice: ${srfclassname('${appCounter.getCodeName()}')}CounterService = new ${srfclassname('${appCounter.getCodeName()}')}CounterService(); public ${srfclassname('${appCounter.getCodeName()}')}counterservice: ${srfclassname('${appCounter.getCodeName()}')}CounterService = new ${srfclassname('${appCounter.getCodeName()}')}CounterService();
</#if> </#if>
...@@ -113,7 +114,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -113,7 +114,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 计数器服务对象集合 * 计数器服务对象集合
* *
* @type {Array<*>} * @type {Array<*>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public counterServiceArray:Array<any> = [${counterRefs}]; public counterServiceArray:Array<any> = [${counterRefs}];
</#if> </#if>
...@@ -122,7 +123,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -122,7 +123,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 建构部件服务对象 * 建构部件服务对象
* *
* @type {${srfclassname('${ctrl.codeName}')}Service} * @type {${srfclassname('${ctrl.codeName}')}Service}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public service: ${srfclassname('${ctrl.codeName}')}Service = new ${srfclassname('${ctrl.codeName}')}Service({ $store: this.$store }); public service: ${srfclassname('${ctrl.codeName}')}Service = new ${srfclassname('${ctrl.codeName}')}Service({ $store: this.$store });
<#if appde??> <#if appde??>
...@@ -131,7 +132,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -131,7 +132,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* 实体服务对象 * 实体服务对象
* *
* @type {${srfclassname('${appde.getCodeName()}')}Service} * @type {${srfclassname('${appde.getCodeName()}')}Service}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public appEntityService: ${srfclassname('${appde.getCodeName()}')}Service = new ${srfclassname('${appde.getCodeName()}')}Service({ $store: this.$store }); public appEntityService: ${srfclassname('${appde.getCodeName()}')}Service = new ${srfclassname('${appde.getCodeName()}')}Service({ $store: this.$store });
</#if> </#if>
...@@ -146,7 +147,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme ...@@ -146,7 +147,7 @@ export default class ${srfclassname('${ctrl.codeName}')}Base extends Vue impleme
* *
* @param {*} [args={}] * @param {*} [args={}]
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${childCtrl.name}_${eventName?lower_case}($event: any, $event2?: any) { public ${childCtrl.name}_${eventName?lower_case}($event: any, $event2?: any) {
<#if childCtrl.getPSControlLogics(eventName)??> <#if childCtrl.getPSControlLogics(eventName)??>
...@@ -192,7 +193,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code} ...@@ -192,7 +193,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code}
* 关闭视图 * 关闭视图
* *
* @param {any} args * @param {any} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public closeView(args: any): void { public closeView(args: any): void {
let _this: any = this; let _this: any = this;
...@@ -202,7 +203,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code} ...@@ -202,7 +203,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code}
/** /**
* 计数器刷新 * 计数器刷新
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public counterRefresh(){ public counterRefresh(){
const _this:any =this; const _this:any =this;
......
<script lang='tsx'> <script lang='tsx'>
import { Vue, Component, Prop, Provide, Emit, Watch, Model } from 'vue-property-decorator'; import { Vue, Component, Prop, Provide, Emit, Watch, Model,Inject } from 'vue-property-decorator';
import { CreateElement } from 'vue'; import { CreateElement } from 'vue';
import { Subject, Subscription } from 'rxjs'; import { Subject, Subscription } from 'rxjs';
import { ControlInterface } from '@/interface/control'; import { ControlInterface } from '@/interface/control';
import { UIActionTool,Util } from '@/utils'; import { UIActionTool,Util } from '@/utils';
import NavDataService from '@/service/app/navdata-service';
<#if ctrl.getPSAppCounterRefs?? && ctrl.getPSAppCounterRefs()??> <#if ctrl.getPSAppCounterRefs?? && ctrl.getPSAppCounterRefs()??>
<#list ctrl.getPSAppCounterRefs() as singleCounterRef> <#list ctrl.getPSAppCounterRefs() as singleCounterRef>
<#if singleCounterRef.getPSAppCounter()??> <#if singleCounterRef.getPSAppCounter()??>
...@@ -44,7 +45,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -44,7 +45,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 名称 * 名称
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public name?: string; @Prop() public name?: string;
...@@ -52,7 +53,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -52,7 +53,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 视图通讯对象 * 视图通讯对象
* *
* @type {Subject<ViewState>} * @type {Subject<ViewState>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public viewState!: Subject<ViewState>; @Prop() public viewState!: Subject<ViewState>;
...@@ -60,7 +61,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -60,7 +61,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 应用上下文 * 应用上下文
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public context: any; @Prop() public context: any;
...@@ -68,7 +69,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -68,7 +69,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 视图参数 * 视图参数
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public viewparams: any; @Prop() public viewparams: any;
...@@ -77,7 +78,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -77,7 +78,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* *
* @public * @public
* @type {(Subscription | undefined)} * @type {(Subscription | undefined)}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewStateEvent: Subscription | undefined; public viewStateEvent: Subscription | undefined;
...@@ -85,7 +86,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -85,7 +86,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 获取部件类型 * 获取部件类型
* *
* @returns {string} * @returns {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getControlType(): string { public getControlType(): string {
return '${ctrl.getControlType()}' return '${ctrl.getControlType()}'
...@@ -103,7 +104,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -103,7 +104,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* ${srfclassname('${appCounter.getCodeName()}')}CounterService计数器服务对象 * ${srfclassname('${appCounter.getCodeName()}')}CounterService计数器服务对象
* *
* @type {${srfclassname('${appCounter.getCodeName()}')}CounterService} * @type {${srfclassname('${appCounter.getCodeName()}')}CounterService}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${srfclassname('${appCounter.getCodeName()}')}counterservice: ${srfclassname('${appCounter.getCodeName()}')}CounterService = new ${srfclassname('${appCounter.getCodeName()}')}CounterService(); public ${srfclassname('${appCounter.getCodeName()}')}counterservice: ${srfclassname('${appCounter.getCodeName()}')}CounterService = new ${srfclassname('${appCounter.getCodeName()}')}CounterService();
</#if> </#if>
...@@ -113,7 +114,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -113,7 +114,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 计数器服务对象集合 * 计数器服务对象集合
* *
* @type {Array<*>} * @type {Array<*>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public counterServiceArray:Array<any> = [${counterRefs}]; public counterServiceArray:Array<any> = [${counterRefs}];
</#if> </#if>
...@@ -122,7 +123,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -122,7 +123,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 建构部件服务对象 * 建构部件服务对象
* *
* @type {${srfclassname('${ctrl.codeName}')}Service} * @type {${srfclassname('${ctrl.codeName}')}Service}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public service: ${srfclassname('${ctrl.codeName}')}Service = new ${srfclassname('${ctrl.codeName}')}Service({ $store: this.$store }); public service: ${srfclassname('${ctrl.codeName}')}Service = new ${srfclassname('${ctrl.codeName}')}Service({ $store: this.$store });
<#if appde??> <#if appde??>
...@@ -131,7 +132,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -131,7 +132,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* 实体服务对象 * 实体服务对象
* *
* @type {${srfclassname('${appde.getCodeName()}')}Service} * @type {${srfclassname('${appde.getCodeName()}')}Service}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public appEntityService: ${srfclassname('${appde.getCodeName()}')}Service = new ${srfclassname('${appde.getCodeName()}')}Service({ $store: this.$store }); public appEntityService: ${srfclassname('${appde.getCodeName()}')}Service = new ${srfclassname('${appde.getCodeName()}')}Service({ $store: this.$store });
</#if> </#if>
...@@ -146,7 +147,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get ...@@ -146,7 +147,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
* *
* @param {*} [args={}] * @param {*} [args={}]
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${childCtrl.name}_${eventName?lower_case}($event: any, $event2?: any) { public ${childCtrl.name}_${eventName?lower_case}($event: any, $event2?: any) {
<#if childCtrl.getPSControlLogics(eventName)??> <#if childCtrl.getPSControlLogics(eventName)??>
...@@ -192,7 +193,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code} ...@@ -192,7 +193,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code}
* 关闭视图 * 关闭视图
* *
* @param {any} args * @param {any} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public closeView(args: any): void { public closeView(args: any): void {
let _this: any = this; let _this: any = this;
...@@ -202,7 +203,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code} ...@@ -202,7 +203,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code}
/** /**
* 计数器刷新 * 计数器刷新
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public counterRefresh(){ public counterRefresh(){
const _this:any =this; const _this:any =this;
......
<#assign layout='TABLE_24COL'><#if formmenber.getPSLayoutPos()??><#if formmenber.getPSLayoutPos().getParentPSLayout()??><#assign layout='${formmenber.getPSLayoutPos().getParentPSLayout().getLayout()}'></#if></#if> <#assign layout = 'TABLE_24COL'/>
<#assign LayoutPos = formmenber.getPSLayoutPos()> <#if formmenber.getPSLayoutPos()??>
<#assign LayoutPos = formmenber.getPSLayoutPos()/>
<#assign layout = LayoutPos.getLayout()/>
</#if>
<#if layout == 'TABLE_24COL' && LayoutPos??> <#if layout == 'TABLE_24COL' && LayoutPos??>
<i-col v-show="detailsModel.${formmenber.name}.visible" :style="{<#if (formmenber.getHeight?? && formmenber.getHeight() gt 0)>'height': '${formmenber.getHeight()?c}px !important',</#if><#if (formmenber.getWidth?? && formmenber.getWidth() gt 0)>'width':'${formmenber.getWidth()?c}px !important'</#if>}" <#if LayoutPos.getColXS() != -1> :sm="{ span: ${LayoutPos.getColXS()}, offset: <#if LayoutPos.getColXSOffset() != -1>${LayoutPos.getColXSOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColSM() != -1> :md="{ span: ${LayoutPos.getColSM()}, offset: <#if LayoutPos.getColSMOffset() != -1>${LayoutPos.getColSMOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColMD() != -1> :lg="{ span: ${LayoutPos.getColMD()}, offset: <#if LayoutPos.getColMDOffset() != -1>${LayoutPos.getColMDOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColLG() != -1> :xl="{ span: ${LayoutPos.getColLG()}, offset: <#if LayoutPos.getColLGOffset() != -1>${LayoutPos.getColLGOffset()}<#else>0</#if> }"</#if>> <i-col v-show="detailsModel.${formmenber.name}.visible" :style="{<#if (formmenber.getHeight?? && formmenber.getHeight() gt 0)>'height': '${formmenber.getHeight()?c}px !important',</#if><#if (formmenber.getWidth?? && formmenber.getWidth() gt 0)>'width':'${formmenber.getWidth()?c}px !important'</#if>}" <#if LayoutPos.getColXS() != -1> :sm="{ span: ${LayoutPos.getColXS()}, offset: <#if LayoutPos.getColXSOffset() != -1>${LayoutPos.getColXSOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColSM() != -1> :md="{ span: ${LayoutPos.getColSM()}, offset: <#if LayoutPos.getColSMOffset() != -1>${LayoutPos.getColSMOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColMD() != -1> :lg="{ span: ${LayoutPos.getColMD()}, offset: <#if LayoutPos.getColMDOffset() != -1>${LayoutPos.getColMDOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColLG() != -1> :xl="{ span: ${LayoutPos.getColLG()}, offset: <#if LayoutPos.getColLGOffset() != -1>${LayoutPos.getColLGOffset()}<#else>0</#if> }"</#if>>
${P.getPartCode(formmenber).code} ${P.getPartCode(formmenber).code}
......
...@@ -137,7 +137,7 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi ...@@ -137,7 +137,7 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi
@Errorlog @Errorlog
public wfsubmit(action: string,context: any = {}, data: any = {}, isloading?: boolean,localdata?:any): Promise<any> { public wfsubmit(action: string,context: any = {}, data: any = {}, isloading?: boolean,localdata?:any): Promise<any> {
data = this.handleWFData(data,true); data = this.handleWFData(data,true);
context = this.handleRequestData(action,context,data).context; context = this.handleRequestData(action,context,data,true).context;
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
let result: Promise<any>; let result: Promise<any>;
const _appEntityService: any = this.appEntityService; const _appEntityService: any = this.appEntityService;
...@@ -299,10 +299,12 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi ...@@ -299,10 +299,12 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi
@Errorlog @Errorlog
public loadDraft(action: string,context: any = {}, data: any = {}, isloading?: boolean): Promise<any> { public loadDraft(action: string,context: any = {}, data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data); const {data:Data,context:Context} = this.handleRequestData(action,context,data);
<#if ctrl.getControlType() != 'SEARCHFORM'>
//仿真主键数据 //仿真主键数据
const PrimaryKey = Util.createUUID(); const PrimaryKey = Util.createUUID();
Data.${appde.getKeyPSAppDEField().getCodeName()?lower_case} = PrimaryKey; Data.${appde.getKeyPSAppDEField().getCodeName()?lower_case} = PrimaryKey;
Data.${appde.getCodeName()?lower_case} = PrimaryKey; Data.${appde.getCodeName()?lower_case} = PrimaryKey;
</#if>
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
let result: Promise<any>; let result: Promise<any>;
const _appEntityService: any = this.appEntityService; const _appEntityService: any = this.appEntityService;
...@@ -312,7 +314,9 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi ...@@ -312,7 +314,9 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi
result = this.appEntityService.GetDraft(Context,Data, isloading); result = this.appEntityService.GetDraft(Context,Data, isloading);
} }
result.then((response) => { result.then((response) => {
<#if ctrl.getControlType() != 'SEARCHFORM'>
response.data.${appde.getKeyPSAppDEField().getCodeName()?lower_case} = PrimaryKey; response.data.${appde.getKeyPSAppDEField().getCodeName()?lower_case} = PrimaryKey;
</#if>
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
...@@ -357,13 +361,16 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi ...@@ -357,13 +361,16 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi
* @param data 数据 * @param data 数据
* @memberof ${srfclassname('${ctrl.codeName}')}Service * @memberof ${srfclassname('${ctrl.codeName}')}Service
*/ */
public handleRequestData(action: string,context:any, data: any = {}){ public handleRequestData(action: string,context:any, data: any = {},isMerge:boolean = false){
let mode: any = this.getMode(); let mode: any = this.getMode();
if (!mode && mode.getDataItems instanceof Function) { if (!mode && mode.getDataItems instanceof Function) {
return data; return data;
} }
let formItemItems: any[] = mode.getDataItems(); let formItemItems: any[] = mode.getDataItems();
let requestData:any = {}; let requestData:any = {};
if(isMerge && (data && data.viewparams)){
Object.assign(requestData,data.viewparams);
}
formItemItems.forEach((item:any) =>{ formItemItems.forEach((item:any) =>{
if(item && item.dataType && Object.is(item.dataType,'FONTKEY')){ if(item && item.dataType && Object.is(item.dataType,'FONTKEY')){
if(item && item.prop){ if(item && item.prop){
...@@ -375,9 +382,6 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi ...@@ -375,9 +382,6 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi
} }
} }
}); });
if(data && data.viewparams){
Object.assign(requestData,data.viewparams);
}
let tempContext:any = JSON.parse(JSON.stringify(context)); let tempContext:any = JSON.parse(JSON.stringify(context));
if(tempContext && tempContext.srfsessionid){ if(tempContext && tempContext.srfsessionid){
tempContext.srfsessionkey = tempContext.srfsessionid; tempContext.srfsessionkey = tempContext.srfsessionid;
......
<template> <template>
<div class='tabviewpanel' style="height:100%;"> <div class='tabviewpanel' style="height:100%;">
<tabs :animated="false" class='tabexppanel' name='${ctrl.getCodeName()?lower_case}' @on-click="tabPanelClick"> <tabs :value="tabValue" :animated="false" class='tabexppanel' name='${ctrl.getCodeName()?lower_case}' @on-click="tabPanelClick">
<#list ctrl.getPSControls() as tabviewpanel> <#list ctrl.getPSControls() as tabviewpanel>
<tab-pane :index="${tabviewpanel_index}" name='${tabviewpanel.name}' tab='${ctrl.getCodeName()?lower_case}' class='<#if tabviewpanel.getPSSysCss?? && tabviewpanel.getPSSysCss()??>${tabviewpanel.getPSSysCss().getCssName()}</#if>' <tab-pane :index="${tabviewpanel_index}" name='${tabviewpanel.name}' tab='${ctrl.getCodeName()?lower_case}' class='<#if tabviewpanel.getPSSysCss?? && tabviewpanel.getPSSysCss()??>${tabviewpanel.getPSSysCss().getCssName()}</#if>'
:label="(h) =>{ :label="(h) =>{
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
* 是否初始化 * 是否初始化
* *
* @returns {any} * @returns {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isInit: any = { public isInit: any = {
<#list ctrl.getPSControls() as tabviewpanel> <#list ctrl.getPSControls() as tabviewpanel>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -68,18 +68,38 @@ ...@@ -68,18 +68,38 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
} }
/**
* 从父传入的当前分页面板panel值
*
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Prop() public tabValue?: string;
/**
* 值变化
*
* @param {*} newVal
* @param {*} oldVal
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Watch('tabValue')
public onValueChange(newVal: any, oldVal: any) {
this.tabPanelClick(newVal);
}
/** /**
* 行为参数 * 行为参数
* *
* @public * @public
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public action:any = ''; public action:any = '';
...@@ -87,14 +107,14 @@ ...@@ -87,14 +107,14 @@
* 被激活的分页面板 * 被激活的分页面板
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public activiedTabViewPanel: string = '<#list ctrl.getPSControls() as tabviewpanel><#if tabviewpanel_index==0>${tabviewpanel.name}</#if></#list>'; public activiedTabViewPanel: string = '<#list ctrl.getPSControls() as tabviewpanel><#if tabviewpanel_index==0>${tabviewpanel.name}</#if></#list>';
/** /**
* 分页视图面板数据变更 * 分页视图面板数据变更
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public tabViewPanelDatasChange(){ public tabViewPanelDatasChange(){
this.counterRefresh(); this.counterRefresh();
...@@ -104,7 +124,7 @@ ...@@ -104,7 +124,7 @@
* vue 生命周期 * vue 生命周期
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -113,7 +133,7 @@ ...@@ -113,7 +133,7 @@
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
//设置分页导航srfparentdename和srfparentkey //设置分页导航srfparentdename和srfparentkey
...@@ -138,7 +158,7 @@ ...@@ -138,7 +158,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -147,7 +167,7 @@ ...@@ -147,7 +167,7 @@
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -163,7 +183,7 @@ ...@@ -163,7 +183,7 @@
* *
* @param {*} $event * @param {*} $event
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public tabPanelClick($event: any) { public tabPanelClick($event: any) {
if (!$event) { if (!$event) {
......
<#assign content>
<#if view.getViewType() == 'DETABSEARCHVIEW' || view.getViewType() == 'DETABSEARCHVIEW9'>
:tabValue="tabValue"
</#if>
</#assign>
<#ibizinclude> <#ibizinclude>
../@MACRO/HTML/DEFAULT.html.ftl ../@MACRO/HTML/DEFAULT.html.ftl
</#ibizinclude> </#ibizinclude>
\ No newline at end of file
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
* 是否被激活 * 是否被激活
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isActivied: boolean = true; public isActivied: boolean = true;
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
* 局部上下文 * 局部上下文
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public localContext: any = <#if ctrl.getPSNavigateContexts?? && ctrl.getPSNavigateContexts()??><@getNavigateContext ctrl /><#else>null</#if>; public localContext: any = <#if ctrl.getPSNavigateContexts?? && ctrl.getPSNavigateContexts()??><@getNavigateContext ctrl /><#else>null</#if>;
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
* 局部视图参数 * 局部视图参数
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public localViewParam: any = <#if ctrl.getPSNavigateParams?? && ctrl.getPSNavigateParams()??><@getNavigateParams ctrl /><#else>null</#if>; public localViewParam: any = <#if ctrl.getPSNavigateParams?? && ctrl.getPSNavigateParams()??><@getNavigateParams ctrl /><#else>null</#if>;
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
* 传入上下文 * 传入上下文
* *
* @type {string} * @type {string}
* @memberof TabExpViewtabviewpanel * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewdata: string = JSON.stringify(this.context); public viewdata: string = JSON.stringify(this.context);
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
* 视图面板过滤项 * 视图面板过滤项
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public navfilter: string = "<#if ctrl.getNavFilter?? && ctrl.getNavFilter()??>${ctrl.getNavFilter()}</#if>"; public navfilter: string = "<#if ctrl.getNavFilter?? && ctrl.getNavFilter()??>${ctrl.getNavFilter()}</#if>";
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
* vue 生命周期 * vue 生命周期
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -99,7 +99,7 @@ ...@@ -99,7 +99,7 @@
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
this.initNavParam(); this.initNavParam();
...@@ -124,7 +124,7 @@ ...@@ -124,7 +124,7 @@
/** /**
* 初始化导航参数 * 初始化导航参数
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public initNavParam(){ public initNavParam(){
if(!Object.is(this.navfilter,"")){ if(!Object.is(this.navfilter,"")){
...@@ -145,7 +145,7 @@ ...@@ -145,7 +145,7 @@
/** /**
* 视图数据变化 * 视图数据变化
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewDatasChange($event:any){ public viewDatasChange($event:any){
this.$emit('viewpanelDatasChange',$event); this.$emit('viewpanelDatasChange',$event);
...@@ -154,7 +154,7 @@ ...@@ -154,7 +154,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -163,7 +163,7 @@ ...@@ -163,7 +163,7 @@
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
......
<#ibizinclude> <#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl ../@MACRO/CSS/DEFAULT.less.ftl
</#ibizinclude> </#ibizinclude>
\ No newline at end of file .tabviewpanel{
>.view-container {
height: 100%;
}
}
\ No newline at end of file
<template> <template>
<div :class="['app-list', this.items.length > 0 ? '' : 'app-list-empty' ]"> <div :class="['app-list', this.items.length > 0 ? '' : 'app-list-empty' ]">
<div v-if="items.length > 0" style="height:100%;"> <div v-if="items.length > 0" style="height:100%;">
<#if ctrl.render??> <#if ctrl.render??>
${ctrl.render.code} ${ctrl.render.code}
<#else> <#else>
<div v-for = "item in items" :key="item.srfmajortext" :class="['app-list-item', {'isSelect': item.isselected === true ? true : false}]" @click="handleClick(item)" @dblclick="handleDblClick(item)"> <div v-for = "item in items" :key="item.srfkey" :class="['app-list-item', {'isSelect': item.isselected === true ? true : false}]" @click="handleClick(item)" @dblclick="handleDblClick(item)">
<#if ctrl.getItemPSLayoutPanel()??> <#if ctrl.getItemPSLayoutPanel()??>
<#assign panel = ctrl.getItemPSLayoutPanel()> <#assign panel = ctrl.getItemPSLayoutPanel()>
<layout_${panel.getName()} name='${panel.name}' :inputData="item" :parentRef="thisRef"></layout_${panel.getName()}> <@ibizindent blank=16>
<#elseif ctrl.itemRender??> ${P.getCtrlCode(panel, 'CONTROL.html').code}
${ctrl.itemRender.code} </@ibizindent>
<#else> <#elseif ctrl.itemRender??>
{{item.srfmajortext}} ${ctrl.itemRender.code}
</#if> <#else>
</div> {{item.srfmajortext}}
</#if> </#if>
</div>
<div v-else>
暂无数据
</div> </div>
</#if>
</div>
<div v-else>
暂无数据
</div>
</div> </div>
</template> </template>
<#ibizinclude> <#ibizinclude>
...@@ -29,7 +31,7 @@ ...@@ -29,7 +31,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.selections; return this.selections;
...@@ -39,7 +41,7 @@ ...@@ -39,7 +41,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -49,7 +51,7 @@ ...@@ -49,7 +51,7 @@
* 是否默认选中第一条数据 * 是否默认选中第一条数据
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: false }) public isSelectFirstDefault!: boolean; @Prop({ default: false }) public isSelectFirstDefault!: boolean;
...@@ -57,7 +59,7 @@ ...@@ -57,7 +59,7 @@
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -65,7 +67,7 @@ ...@@ -65,7 +67,7 @@
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public createAction!: string; @Prop() public createAction!: string;
...@@ -73,7 +75,7 @@ ...@@ -73,7 +75,7 @@
* 部件行为--remove * 部件行为--remove
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public removeAction!: string; @Prop() public removeAction!: string;
...@@ -81,7 +83,7 @@ ...@@ -81,7 +83,7 @@
* 部件行为--update * 部件行为--update
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateAction!: string; @Prop() public updateAction!: string;
...@@ -89,7 +91,7 @@ ...@@ -89,7 +91,7 @@
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
...@@ -100,7 +102,7 @@ ...@@ -100,7 +102,7 @@
* 打开新建数据视图 * 打开新建数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public newdata: any; @Prop() public newdata: any;
</#if> </#if>
...@@ -109,7 +111,7 @@ ...@@ -109,7 +111,7 @@
* 打开编辑数据视图 * 打开编辑数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public opendata: any; @Prop() public opendata: any;
</#if> </#if>
...@@ -120,7 +122,7 @@ ...@@ -120,7 +122,7 @@
* this引用 * this引用
* *
* @type {number} * @type {number}
* @memberof Main * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public thisRef: any = this; public thisRef: any = this;
...@@ -128,7 +130,7 @@ ...@@ -128,7 +130,7 @@
* 当前页 * 当前页
* *
* @type {number} * @type {number}
* @memberof Main * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public curPage: number = 1; public curPage: number = 1;
...@@ -136,7 +138,7 @@ ...@@ -136,7 +138,7 @@
* 数据 * 数据
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public items: any[] = []; public items: any[] = [];
...@@ -144,7 +146,7 @@ ...@@ -144,7 +146,7 @@
* 是否支持分页 * 是否支持分页
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isEnablePagingBar: boolean = true; public isEnablePagingBar: boolean = true;
...@@ -152,7 +154,7 @@ ...@@ -152,7 +154,7 @@
* 分页条数 * 分页条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public limit: number = ${ctrl.getPagingSize()?c}; public limit: number = ${ctrl.getPagingSize()?c};
...@@ -160,7 +162,7 @@ ...@@ -160,7 +162,7 @@
* 总条数 * 总条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public totalRecord: number = 0; public totalRecord: number = 0;
...@@ -168,7 +170,7 @@ ...@@ -168,7 +170,7 @@
* 加载的数据是否附加在items之后 * 加载的数据是否附加在items之后
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isAddBehind:boolean = false; public isAddBehind:boolean = false;
...@@ -176,7 +178,7 @@ ...@@ -176,7 +178,7 @@
* 排序方向 * 排序方向
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>'; public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>';
...@@ -184,21 +186,21 @@ ...@@ -184,21 +186,21 @@
* 排序字段 * 排序字段
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>'; public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>';
/** /**
* 选中数组 * 选中数组
* @type {Array<any>} * @type {Array<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selections: Array<any> = []; public selections: Array<any> = [];
/** /**
* Vue声明周期,组件挂载完毕 * Vue声明周期,组件挂载完毕
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public mounted () { public mounted () {
this.afterMounted(); this.afterMounted();
...@@ -207,7 +209,7 @@ ...@@ -207,7 +209,7 @@
/** /**
* 执行mounted后的逻辑 * 执行mounted后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterMounted () { public afterMounted () {
this.$el.addEventListener('scroll', ()=> { this.$el.addEventListener('scroll', ()=> {
...@@ -221,7 +223,7 @@ ...@@ -221,7 +223,7 @@
/** /**
* Vue声明周期,组件创建完毕 * Vue声明周期,组件创建完毕
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated() this.afterCreated()
...@@ -230,7 +232,7 @@ ...@@ -230,7 +232,7 @@
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -248,7 +250,7 @@ ...@@ -248,7 +250,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -257,7 +259,7 @@ ...@@ -257,7 +259,7 @@
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -271,7 +273,7 @@ ...@@ -271,7 +273,7 @@
/** /**
* 加载更多 * 加载更多
* *
* @memberof Mob * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public loadMore(){ public loadMore(){
if(this.totalRecord>this.items.length) if(this.totalRecord>this.items.length)
...@@ -299,7 +301,7 @@ ...@@ -299,7 +301,7 @@
* *
* @public * @public
* @param {*} [arg={}] * @param {*} [arg={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.fetchAction){ if(!this.fetchAction){
...@@ -363,7 +365,7 @@ ...@@ -363,7 +365,7 @@
* *
* @param {any[]} datas * @param {any[]} datas
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async remove(datas: any[]): Promise<any> { public async remove(datas: any[]): Promise<any> {
if(!this.removeAction){ if(!this.removeAction){
...@@ -395,7 +397,7 @@ ...@@ -395,7 +397,7 @@
const removeData = () => { const removeData = () => {
let keys: any[] = []; let keys: any[] = [];
datas.forEach((data: any) => { datas.forEach((data: any) => {
keys.push(data.srfkey); keys.push(data.srfkey);
}); });
let _removeAction = keys.length > 1 ? 'removeBatch' : this.removeAction ; let _removeAction = keys.length > 1 ? 'removeBatch' : this.removeAction ;
const context:any = JSON.parse(JSON.stringify(this.context)); const context:any = JSON.parse(JSON.stringify(this.context));
...@@ -446,9 +448,74 @@ ...@@ -446,9 +448,74 @@
return removeData; return removeData;
} }
/**
* 保存
*
* @param {*} $event
* @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public async save(args: any[], params?: any, $event?: any, xData?: any){
let _this = this;
let successItems:any = [];
let errorItems:any = [];
let errorMessage:any = [];
for (const item of _this.items) {
try {
if(Object.is(item.rowDataState, 'create')){
if(!this.createAction){
this.$Notice.error({ title: '错误', desc: '${view.getName()}视图列表createAction参数未配置' });
}else{
Object.assign(item,{viewparams:this.viewparams});
let response = await this.service.add(this.createAction, JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator);
successItems.push(JSON.parse(JSON.stringify(response.data)));
}
}else if(Object.is(item.rowDataState, 'update')){
if(!this.updateAction){
this.$Notice.error({ title: '错误', desc: '${view.getName()}视图列表updateAction参数未配置' });
}else{
Object.assign(item,{viewparams:this.viewparams});
<#if de??>
if(item.${appde.getCodeName()?lower_case}){
Object.assign(this.context,{${appde.getCodeName()?lower_case}:item.${appde.getCodeName()?lower_case}});
}
</#if>
let response = await this.service.add(this.updateAction,JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator);
successItems.push(JSON.parse(JSON.stringify(response.data)));
}
}
} catch (error) {
errorItems.push(JSON.parse(JSON.stringify(item)));
errorMessage.push(error);
}
}
this.$emit('save', successItems);
this.refresh();
if(errorItems.length === 0){
this.$Notice.success({ title: '', desc: '保存成功!' });
}else{
errorItems.forEach((item:any,index:number)=>{
this.$Notice.error({ title: '保存失败', desc: item.majorentityname+'保存失败!' });
console.error(errorMessage[index]);
});
}
return successItems;
}
/**
* 面板数据变化处理事件
* @param {any} item 当前列数据
* @param {any} $event 面板事件数据
*
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public onPanelDataChange(item:any,$event:any) {
Object.assign(item, $event, {rowDataState:'update'});
}
/** /**
* 选择数据 * 选择数据
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public handleClick(args: any) { public handleClick(args: any) {
...@@ -459,7 +526,7 @@ ...@@ -459,7 +526,7 @@
/** /**
* 双击数据 * 双击数据
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public handleDblClick(args: any) { public handleDblClick(args: any) {
...@@ -468,7 +535,7 @@ ...@@ -468,7 +535,7 @@
/** /**
* 触发事件 * 触发事件
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public selectchange() { public selectchange() {
...@@ -484,7 +551,7 @@ ...@@ -484,7 +551,7 @@
/** /**
* 清除当前所有选中状态 * 清除当前所有选中状态
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public clearSelection(){ public clearSelection(){
this.items.map((item: any) => { this.items.map((item: any) => {
......
...@@ -62,6 +62,65 @@ ...@@ -62,6 +62,65 @@
}); });
} }
/**
* 添加数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
@Errorlog
public add(action: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Context,Data, isloading);
}else{
result =_appEntityService.Create(Context,Data, isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
/**
* 修改数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
@Errorlog
public update(action: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Data,Context,isloading);
}else{
result =_appEntityService.Update(Data,Context,isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
<#ibizinclude> <#ibizinclude>
../@MACRO/SERVICE/SERVICE_BOTTOM.ts.ftl ../@MACRO/SERVICE/SERVICE_BOTTOM.ts.ftl
</#ibizinclude> </#ibizinclude>
\ No newline at end of file
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
* 部件行为--init * 部件行为--init
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public initAction!: string; @Prop() public initAction!: string;
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
* 部件行为--finish * 部件行为--finish
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public finishAction!: string; @Prop() public finishAction!: string;
...@@ -62,7 +62,7 @@ ...@@ -62,7 +62,7 @@
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -70,7 +70,7 @@ ...@@ -70,7 +70,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return [this.formParam]; return [this.formParam];
...@@ -80,7 +80,7 @@ ...@@ -80,7 +80,7 @@
* 获取单项数据 * 获取单项数据
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return this.formParam; return this.formParam;
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
* *
* @public * @public
* @type {Subject<{action: string, data: any}>} * @type {Subject<{action: string, data: any}>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public wizardState: Subject<ViewState> = new Subject(); public wizardState: Subject<ViewState> = new Subject();
...@@ -99,7 +99,7 @@ ...@@ -99,7 +99,7 @@
* 当前激活表单 * 当前激活表单
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
<#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getFirstPSDEWizardForm()??> <#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getFirstPSDEWizardForm()??>
<#assign firstForm = ctrl.getPSDEWizard().getFirstPSDEWizardForm()> <#assign firstForm = ctrl.getPSDEWizard().getFirstPSDEWizardForm()>
...@@ -112,7 +112,7 @@ ...@@ -112,7 +112,7 @@
* 向导表单参数 * 向导表单参数
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public formParam: any = {}; public formParam: any = {};
...@@ -121,7 +121,7 @@ ...@@ -121,7 +121,7 @@
* *
* @public * @public
* @type {Array<string>} * @type {Array<string>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public historyForms: Array<string> = []; public historyForms: Array<string> = [];
...@@ -129,7 +129,7 @@ ...@@ -129,7 +129,7 @@
* 步骤行为集合 * 步骤行为集合
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public stepActions: any = {}; public stepActions: any = {};
...@@ -137,21 +137,21 @@ ...@@ -137,21 +137,21 @@
* 向导表单集合 * 向导表单集合
* *
* @type {Array<any>} * @type {Array<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public wizardForms: Array<any> = []; public wizardForms: Array<any> = [];
/** /**
* 当前状态 * 当前状态
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public curState = ''; public curState = '';
/** /**
* Vue声明周期(处理组件的输入属性) * Vue声明周期(处理组件的输入属性)
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created(): void { public created(): void {
this.regFormActions(); this.regFormActions();
...@@ -172,7 +172,7 @@ ...@@ -172,7 +172,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -186,7 +186,7 @@ ...@@ -186,7 +186,7 @@
/** /**
* 注册表单步骤行为 * 注册表单步骤行为
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public regFormActions() { public regFormActions() {
<#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getPSDEWizardForms()??> <#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getPSDEWizardForms()??>
...@@ -199,7 +199,7 @@ ...@@ -199,7 +199,7 @@
/** /**
* 注册表单步骤行为 * 注册表单步骤行为
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public regFormAction(name: string, actions: Array<string>) { public regFormAction(name: string, actions: Array<string>) {
this.stepActions[name] = actions; this.stepActions[name] = actions;
...@@ -209,7 +209,7 @@ ...@@ -209,7 +209,7 @@
/** /**
* 初始化行为 * 初始化行为
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public doInit(opt: any = {}) { public doInit(opt: any = {}) {
<#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getInitPSDEAction()??> <#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getInitPSDEAction()??>
...@@ -237,7 +237,7 @@ ...@@ -237,7 +237,7 @@
/** /**
* 表单加载 * 表单加载
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public formLoad() { public formLoad() {
if(this.activeForm) { if(this.activeForm) {
...@@ -248,7 +248,7 @@ ...@@ -248,7 +248,7 @@
/** /**
* 完成行为 * 完成行为
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public doFinish() { public doFinish() {
<#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getFinishPSDEAction()??> <#if ctrl.getPSDEWizard()?? && ctrl.getPSDEWizard().getFinishPSDEAction()??>
...@@ -276,7 +276,7 @@ ...@@ -276,7 +276,7 @@
* *
* @param {*} args * @param {*} args
* @param {string} name * @param {string} name
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${ctrl.name}_formload(args: any, name: string, $event2?: any) { public ${ctrl.name}_formload(args: any, name: string, $event2?: any) {
if(args) { if(args) {
...@@ -289,7 +289,7 @@ ...@@ -289,7 +289,7 @@
* *
* @param {*} args * @param {*} args
* @param {string} name * @param {string} name
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${ctrl.name}_formsave(args: any, name: string, $event2?: any) { public ${ctrl.name}_formsave(args: any, name: string, $event2?: any) {
Object.assign(this.formParam, args); Object.assign(this.formParam, args);
...@@ -311,7 +311,7 @@ ...@@ -311,7 +311,7 @@
/** /**
* 获取下一步向导表单 * 获取下一步向导表单
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getNextForm() { public getNextForm() {
let index = this.wizardForms.indexOf(this.activeForm); let index = this.wizardForms.indexOf(this.activeForm);
...@@ -327,7 +327,7 @@ ...@@ -327,7 +327,7 @@
/** /**
* 上一步 * 上一步
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onClickPrev() { public onClickPrev() {
const length = this.historyForms.length; const length = this.historyForms.length;
...@@ -344,7 +344,7 @@ ...@@ -344,7 +344,7 @@
/** /**
* 下一步 * 下一步
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onClickNext() { public onClickNext() {
if(this.activeForm) { if(this.activeForm) {
...@@ -363,7 +363,7 @@ ...@@ -363,7 +363,7 @@
/** /**
* 完成 * 完成
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onClickFinish() { public onClickFinish() {
if(this.activeForm) { if(this.activeForm) {
...@@ -383,7 +383,7 @@ ...@@ -383,7 +383,7 @@
* 是否禁用 * 是否禁用
* *
* @param {string} type * @param {string} type
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isDisabled(type: string) { public isDisabled(type: string) {
const actions: Array<string> = this.stepActions[this.activeForm] const actions: Array<string> = this.stepActions[this.activeForm]
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
* 部件行为--update * 部件行为--update
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateAction!: string; @Prop() public updateAction!: string;
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
* 部件行为--remove * 部件行为--remove
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public removeAction!: string; @Prop() public removeAction!: string;
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
* 部件行为--load * 部件行为--load
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction!: string; @Prop() public loadAction!: string;
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
* 部件行为--loaddraft * 部件行为--loaddraft
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loaddraftAction!: string; @Prop() public loaddraftAction!: string;
...@@ -98,7 +98,7 @@ ...@@ -98,7 +98,7 @@
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public createAction!: string; @Prop() public createAction!: string;
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
* 刷新数据 * 刷新数据
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public saveRefView?: number; @Prop() public saveRefView?: number;
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
* *
* @param {*} newVal * @param {*} newVal
* @param {*} oldVal * @param {*} oldVal
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Watch('saveRefView') @Watch('saveRefView')
onSaveRefView(newVal: any, oldVal: any) { onSaveRefView(newVal: any, oldVal: any) {
...@@ -130,7 +130,7 @@ ...@@ -130,7 +130,7 @@
* 对象转字符串 * 对象转字符串
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public toString(item:any): string{ public toString(item:any): string{
return JSON.stringify(item); return JSON.stringify(item);
...@@ -149,7 +149,7 @@ ...@@ -149,7 +149,7 @@
* 视图名称 * 视图名称
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewname: string = '<#if ctrl.getEmbeddedPSAppView()??>${srffilepath2(ctrl.getEmbeddedPSAppView().getCodeName())}</#if>'; public viewname: string = '<#if ctrl.getEmbeddedPSAppView()??>${srffilepath2(ctrl.getEmbeddedPSAppView().getCodeName())}</#if>';
...@@ -157,7 +157,7 @@ ...@@ -157,7 +157,7 @@
* 获取数据对象 * 获取数据对象
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public items: any[] = []; public items: any[] = [];
...@@ -165,7 +165,7 @@ ...@@ -165,7 +165,7 @@
* 计数器 * 计数器
* *
* @type number * @type number
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public count: number = 0; public count: number = 0;
...@@ -178,7 +178,7 @@ ...@@ -178,7 +178,7 @@
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public deResParameters: any[] = []; public deResParameters: any[] = [];
...@@ -187,7 +187,7 @@ ...@@ -187,7 +187,7 @@
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public parameters: any[] = []; public parameters: any[] = [];
<#else> <#else>
...@@ -199,7 +199,7 @@ ...@@ -199,7 +199,7 @@
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public deResParameters: any[] = [ public deResParameters: any[] = [
<#-- BEGIN:存在父关系路径 --> <#-- BEGIN:存在父关系路径 -->
...@@ -217,7 +217,7 @@ ...@@ -217,7 +217,7 @@
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public parameters: any[] = [ public parameters: any[] = [
{ pathName: '${srfpluralize(appDataEntity.codeName)?lower_case}', parameterName: '${appDataEntity.getCodeName()?lower_case}' }, { pathName: '${srfpluralize(appDataEntity.codeName)?lower_case}', parameterName: '${appDataEntity.getCodeName()?lower_case}' },
...@@ -229,7 +229,7 @@ ...@@ -229,7 +229,7 @@
/** /**
* vue 声明周期 * vue 声明周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -238,7 +238,7 @@ ...@@ -238,7 +238,7 @@
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -259,7 +259,7 @@ ...@@ -259,7 +259,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -268,7 +268,7 @@ ...@@ -268,7 +268,7 @@
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -299,7 +299,7 @@ ...@@ -299,7 +299,7 @@
* *
* @public * @public
* @param {any[]} datas * @param {any[]} datas
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public doItems(datas: any[]): void { public doItems(datas: any[]): void {
const [{ pathName, parameterName }] = this.parameters; const [{ pathName, parameterName }] = this.parameters;
...@@ -337,7 +337,7 @@ ...@@ -337,7 +337,7 @@
* *
* @public * @public
* @param {*} data * @param {*} data
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(data: any): void { public load(data: any): void {
if(!this.fetchAction){ if(!this.fetchAction){
...@@ -372,7 +372,7 @@ ...@@ -372,7 +372,7 @@
/** /**
* 增加数据 * 增加数据
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public handleAdd(){ public handleAdd(){
if(!this.loaddraftAction){ if(!this.loaddraftAction){
...@@ -402,7 +402,7 @@ ...@@ -402,7 +402,7 @@
* *
* @param {*} item * @param {*} item
* @param {boolean} $event * @param {boolean} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setViewDirty(item: any, $event: boolean) { public setViewDirty(item: any, $event: boolean) {
let index: number = this.items.findIndex((_item: any) => Object.is(_item.id, item.id)); let index: number = this.items.findIndex((_item: any) => Object.is(_item.id, item.id));
...@@ -421,7 +421,7 @@ ...@@ -421,7 +421,7 @@
/** /**
* 部件抛出事件 * 部件抛出事件
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewDataChange($event:any){ public viewDataChange($event:any){
if($event){ if($event){
...@@ -456,7 +456,7 @@ ...@@ -456,7 +456,7 @@
* 视图加载完成 * 视图加载完成
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewload($event:any){ public viewload($event:any){
console.log('视图加载完成'); console.log('视图加载完成');
...@@ -466,7 +466,7 @@ ...@@ -466,7 +466,7 @@
* editview9 视图数据变化 * editview9 视图数据变化
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewdirty(item:any,$event:any){ public viewdirty(item:any,$event:any){
// editview9 视图数据变化; // editview9 视图数据变化;
......
...@@ -151,6 +151,10 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code} ...@@ -151,6 +151,10 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code}
*/ */
protected click(item: any) { protected click(item: any) {
if (item) { if (item) {
let navDataService = NavDataService.getInstance(this.$store);
if(Object.is(this.navModel,"route")){
navDataService.removeNavData(this.viewtag);
}
switch (item.appfunctag) { switch (item.appfunctag) {
<#if ctrl.getPSAppFuncs()??> <#if ctrl.getPSAppFuncs()??>
<#assign appFuncs = ctrl.getPSAppFuncs()> <#assign appFuncs = ctrl.getPSAppFuncs()>
......
.app-app-menu { .app-app-menu {
height: 100%; height: 100%;
width: 100%; width: 100%;
} }
\ No newline at end of file
<template>
</template>
<#ibizinclude>
../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl
</#ibizinclude>
/**
* 获取多项数据
*
* @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public getDatas(): any[] {
return [];
}
/**
* 获取单项树
*
* @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public getData(): any {
return null;
}
<#ibizinclude>
../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/CONTROL/CONTROL-BASE.style.ftl
</#ibizinclude>
\ No newline at end of file
<#-- content -->
<#assign content>
</#assign>
<#ibizinclude>
../@MACRO/HTML/DEFAULT.html.ftl
</#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl
</#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/CONTROL/CONTROL.vue.ftl
</#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/MODEL/MODEL_HEADER.ts.ftl
</#ibizinclude>
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof ${srfclassname('${ctrl.getCodeName()}')}${srfclassname('${ctrl.name}')}Mode
*/
public getDataItems(): any[] {
return [
]
}
<#ibizinclude>
../@MACRO/MODEL/MODEL_BOTTOM.ts.ftl
</#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/SERVICE/SERVICE_HEADER.ts.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/SERVICE/SERVICE_BOTTOM.ts.ftl
</#ibizinclude>
\ No newline at end of file
CTRLTYPE=SEARCHBAR
\ No newline at end of file
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
</#if> </#if>
loaddraftAction="<#if ctrl.getGetDraftPSControlAction()?? && ctrl.getGetDraftPSControlAction().getPSAppDEMethod()??>${ctrl.getGetDraftPSControlAction().getPSAppDEMethod().getCodeName()}</#if>" loaddraftAction="<#if ctrl.getGetDraftPSControlAction()?? && ctrl.getGetDraftPSControlAction().getPSAppDEMethod()??>${ctrl.getGetDraftPSControlAction().getPSAppDEMethod().getCodeName()}</#if>"
loadAction="<#if ctrl.getGetPSControlAction()?? && ctrl.getGetPSControlAction().getPSAppDEMethod()??>${ctrl.getGetPSControlAction().getPSAppDEMethod().getCodeName()}</#if>" loadAction="<#if ctrl.getGetPSControlAction()?? && ctrl.getGetPSControlAction().getPSAppDEMethod()??>${ctrl.getGetPSControlAction().getPSAppDEMethod().getCodeName()}</#if>"
<#if ctrl.getFormStyle() == "SEARCHBAR">@valuechange="qucikFormValueChange"</#if> <#if ctrl.getFormStyle() == "SEARCHBAR">@valuechange="quickFormValueChange"</#if>
<#if view.getViewType() == "DECALENDARVIEW" || view.getViewType() == "DECALENDARVIEW9"> <#if view.getViewType() == "DECALENDARVIEW" || view.getViewType() == "DECALENDARVIEW9">
@search="searchform_search($event)" @search="searchform_search($event)"
@load="searchform_load($event)" @load="searchform_load($event)"
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.items; return this.items;
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return this.selection; return this.selection;
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
* 加载行为 * 加载行为
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction?: string; @Prop() public loadAction?: string;
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
* 数据选中项 * 数据选中项
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selection: any = {}; public selection: any = {};
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
* 关系栏数据项 * 关系栏数据项
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public items: any[] = [ public items: any[] = [
<#if view.hasPSControl('form')> <#if view.hasPSControl('form')>
...@@ -127,7 +127,7 @@ ...@@ -127,7 +127,7 @@
* 默认打开项 * 默认打开项
* *
* @type {string[]} * @type {string[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public defaultOpeneds: string[] = []; public defaultOpeneds: string[] = [];
...@@ -136,7 +136,7 @@ ...@@ -136,7 +136,7 @@
* *
* @public * @public
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public parentData: any = {}; public parentData: any = {};
...@@ -144,14 +144,14 @@ ...@@ -144,14 +144,14 @@
* 宽度 * 宽度
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public width: number = <#if ctrl.getWidth() gt 240><#else>240</#if>; public width: number = <#if ctrl.getWidth() gt 240><#else>240</#if>;
/** /**
* 生命周期 * 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created(): void { public created(): void {
if (this.viewState) { if (this.viewState) {
...@@ -174,7 +174,7 @@ ...@@ -174,7 +174,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -191,7 +191,7 @@ ...@@ -191,7 +191,7 @@
* @public * @public
* @param {*} [arg={}] * @param {*} [arg={}]
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDRBarItem(arg: any = {}): any { public getDRBarItem(arg: any = {}): any {
let expmode = arg.nodetype; let expmode = arg.nodetype;
...@@ -217,7 +217,7 @@ ...@@ -217,7 +217,7 @@
* *
* @public * @public
* @param {any[]} items * @param {any[]} items
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public dataProcess(items: any[]): void { public dataProcess(items: any[]): void {
items.forEach((_item: any) => { items.forEach((_item: any) => {
...@@ -238,7 +238,7 @@ ...@@ -238,7 +238,7 @@
* @param {any[]} items * @param {any[]} items
* @param {string} id * @param {string} id
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getItem(items: any[], id: string): any { public getItem(items: any[], id: string): any {
const item: any = {}; const item: any = {};
...@@ -293,7 +293,7 @@ ...@@ -293,7 +293,7 @@
* 节点选中 * 节点选中
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onSelect($event: any): void { public onSelect($event: any): void {
const item = this.getItem(this.items, $event); const item = this.getItem(this.items, $event);
...@@ -323,7 +323,7 @@ ...@@ -323,7 +323,7 @@
* 子节点打开 * 子节点打开
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onOpen($event: any): void { public onOpen($event: any): void {
const item = this.getItem(this.items, $event); const item = this.getItem(this.items, $event);
...@@ -341,7 +341,7 @@ ...@@ -341,7 +341,7 @@
* 子节点关闭 * 子节点关闭
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onClose($event: any): void { public onClose($event: any): void {
const item = this.getItem(this.items, $event); const item = this.getItem(this.items, $event);
...@@ -360,7 +360,7 @@ ...@@ -360,7 +360,7 @@
* *
* @param {any[]} items * @param {any[]} items
* @param {boolean} state * @param {boolean} state
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setItemDisabled(items: any[], state: boolean) { public setItemDisabled(items: any[], state: boolean) {
items.forEach((item: any) => { items.forEach((item: any) => {
......
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 柱状图序列start --> <#-- 柱状图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,9 +9,9 @@ ${item.render.code} ...@@ -6,9 +9,9 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'bar', type:'bar',
xAxisIndex:${item.getIndex()}, xAxisIndex:<@getXIndex item />,
yAxisIndex:${item.getIndex()}, yAxisIndex:<@getYIndex item />,
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
encode: { encode: {
<#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if> <#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if>
x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>], x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>],
......
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 折线图序列start --> <#-- 折线图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,7 +9,7 @@ ${item.render.code} ...@@ -6,7 +9,7 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'funnel', type:'funnel',
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
<#compress><#if item.getLeft()??>left:"${item.getLeft()}",</#if> <#compress><#if item.getLeft()??>left:"${item.getLeft()}",</#if>
<#if item.getTop()??>top:"${item.getTop()}",</#if> <#if item.getTop()??>top:"${item.getTop()}",</#if>
<#if item.getBottom()??>bottom:"${item.getBottom()}",</#if> <#if item.getBottom()??>bottom:"${item.getBottom()}",</#if>
......
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 折线图序列start --> <#-- 折线图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,9 +9,9 @@ ${item.render.code} ...@@ -6,9 +9,9 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'line', type:'line',
xAxisIndex:${item.getIndex()}, xAxisIndex:<@getXIndex item />,
yAxisIndex:${item.getIndex()}, yAxisIndex:<@getYIndex item />,
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
encode: { encode: {
<#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if> <#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if>
x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>], x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>],
......
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 折线图序列start --> <#-- 折线图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,8 +9,8 @@ ${item.render.code} ...@@ -6,8 +9,8 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'pie', type:'pie',
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
<#compress><#if item.getLeft()?? && item.getLeft() != "">left:"${item.getLeft()}",</#if> <#compress><#if item.getLeft()??>left:"${item.getLeft()}",</#if>
<#if item.getTop()??>top:"${item.getTop()}",</#if> <#if item.getTop()??>top:"${item.getTop()}",</#if>
<#if item.getBottom()??>bottom:"${item.getBottom()}",</#if> <#if item.getBottom()??>bottom:"${item.getBottom()}",</#if>
<#if item.getRight()??>right:"${item.getRight()}",</#if> <#if item.getRight()??>right:"${item.getRight()}",</#if>
......
...@@ -24,7 +24,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -24,7 +24,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -34,7 +34,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -34,7 +34,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -44,7 +44,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -44,7 +44,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator!: boolean; @Prop({ default: true }) public showBusyIndicator!: boolean;
...@@ -52,14 +52,14 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -52,14 +52,14 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
/** /**
* Vue声明周期(组件初始化完毕) * Vue声明周期(组件初始化完毕)
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -68,7 +68,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -68,7 +68,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -86,7 +86,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -86,7 +86,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -95,7 +95,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -95,7 +95,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -347,13 +347,13 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -347,13 +347,13 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
Object.keys(this.seriesModel).forEach((seriesName:string) =>{ Object.keys(this.seriesModel).forEach((seriesName:string) =>{
if(_chartOption && _chartOption.series.length > 0){ if(_chartOption && _chartOption.series.length > 0){
_chartOption.series.forEach((item:any) =>{ _chartOption.series.forEach((item:any) =>{
if(this.seriesModel[seriesName].ecxObject){ if(this.seriesModel[seriesName].ecxObject && Object.is(seriesName,item.id)){
item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecxObject); item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecxObject);
} }
if(this.seriesModel[seriesName].baseOption && Object.keys(this.seriesModel[seriesName].baseOption).length > 0){ if(this.seriesModel[seriesName].baseOption && Object.keys(this.seriesModel[seriesName].baseOption).length > 0 && Object.is(seriesName,item.id)){
item = Util.deepObjectMerge(item,this.seriesModel[seriesName].baseOption); item = Util.deepObjectMerge(item,this.seriesModel[seriesName].baseOption);
} }
if(this.seriesModel[seriesName].ecObject){ if(this.seriesModel[seriesName].ecObject && Object.is(seriesName,item.id)){
item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecObject); item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecObject);
} }
}) })
......
<#-- 获取序列映射X轴的索引start-->
<#macro getXIndex item>
<#compress>
<#if item.getPSChartCoordinateSystem?? && item.getPSChartCoordinateSystem()??>
<#assign chartCoordinateSystem = item.getPSChartCoordinateSystem() />
<#if chartCoordinateSystem.getPSChartGrid?? && chartCoordinateSystem.getPSChartGrid()?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridXAxis0?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridXAxis0()??>
${chartCoordinateSystem.getPSChartGrid().getPSChartGridXAxis0().getIndex()}<#else>0</#if>
</#if>
</#compress>
</#macro>
<#-- 获取序列映射X轴的索引end-->
<#-- 获取序列映射Y轴的索引start-->
<#macro getYIndex item>
<#compress>
<#if item.getPSChartCoordinateSystem?? && item.getPSChartCoordinateSystem()??>
<#assign chartCoordinateSystem = item.getPSChartCoordinateSystem() />
<#if chartCoordinateSystem.getPSChartGrid?? && chartCoordinateSystem.getPSChartGrid()?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridYAxis0?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridYAxis0()??>
${chartCoordinateSystem.getPSChartGrid().getPSChartGridYAxis0().getIndex()}<#else>0</#if>
</#if>
</#compress>
</#macro>
<#-- 获取序列映射Y轴的索引end-->
<#-- 获取序列映射数据集的索引start-->
<#macro getDataSetIndex item>
<#compress>
<#if item.getPSChartDataSet?? && item.getPSChartDataSet()??>
<#assign chartDataSet = item.getPSChartDataSet() />
${chartDataSet.getIndex()}<#else>0
</#if>
</#compress>
</#macro>
<#-- 获取序列映射数据集的索引end-->
\ No newline at end of file
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 柱状图序列start --> <#-- 柱状图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,9 +9,9 @@ ${item.render.code} ...@@ -6,9 +9,9 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'bar', type:'bar',
xAxisIndex:${item.getIndex()}, xAxisIndex:<@getXIndex item />,
yAxisIndex:${item.getIndex()}, yAxisIndex:<@getYIndex item />,
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
encode: { encode: {
<#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if> <#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if>
x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>], x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>],
......
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 折线图序列start --> <#-- 折线图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,7 +9,7 @@ ${item.render.code} ...@@ -6,7 +9,7 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'funnel', type:'funnel',
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
<#compress><#if item.getLeft()??>left:"${item.getLeft()}",</#if> <#compress><#if item.getLeft()??>left:"${item.getLeft()}",</#if>
<#if item.getTop()??>top:"${item.getTop()}",</#if> <#if item.getTop()??>top:"${item.getTop()}",</#if>
<#if item.getBottom()??>bottom:"${item.getBottom()}",</#if> <#if item.getBottom()??>bottom:"${item.getBottom()}",</#if>
......
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 折线图序列start --> <#-- 折线图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,9 +9,9 @@ ${item.render.code} ...@@ -6,9 +9,9 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'line', type:'line',
xAxisIndex:${item.getIndex()}, xAxisIndex:<@getXIndex item />,
yAxisIndex:${item.getIndex()}, yAxisIndex:<@getYIndex item />,
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
encode: { encode: {
<#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if> <#if item.getPSChartSeriesEncode()??><#assign chartSeriesEncode = item.getPSChartSeriesEncode() /></#if>
x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>], x: [<#if chartSeriesEncode.getX()??><#list chartSeriesEncode.getX() as xValue>'${xValue?lower_case}'<#if xValue_has_next>,</#if></#list></#if>],
......
<#ibizinclude>
./CONTROL-COMMON.vue.ftl
</#ibizinclude>
<#-- 折线图序列start --> <#-- 折线图序列start -->
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
...@@ -6,7 +9,7 @@ ${item.render.code} ...@@ -6,7 +9,7 @@ ${item.render.code}
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>', id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>', name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'pie', type:'pie',
datasetIndex:${item.getIndex()}, datasetIndex:<@getDataSetIndex item />,
<#compress><#if item.getLeft()??>left:"${item.getLeft()}",</#if> <#compress><#if item.getLeft()??>left:"${item.getLeft()}",</#if>
<#if item.getTop()??>top:"${item.getTop()}",</#if> <#if item.getTop()??>top:"${item.getTop()}",</#if>
<#if item.getBottom()??>bottom:"${item.getBottom()}",</#if> <#if item.getBottom()??>bottom:"${item.getBottom()}",</#if>
......
...@@ -24,7 +24,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -24,7 +24,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -34,7 +34,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -34,7 +34,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -44,7 +44,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -44,7 +44,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator!: boolean; @Prop({ default: true }) public showBusyIndicator!: boolean;
...@@ -52,14 +52,14 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -52,14 +52,14 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
/** /**
* Vue声明周期(组件初始化完毕) * Vue声明周期(组件初始化完毕)
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -68,7 +68,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -68,7 +68,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -86,7 +86,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -86,7 +86,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -95,7 +95,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -95,7 +95,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -347,13 +347,13 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char ...@@ -347,13 +347,13 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
Object.keys(this.seriesModel).forEach((seriesName:string) =>{ Object.keys(this.seriesModel).forEach((seriesName:string) =>{
if(_chartOption && _chartOption.series.length > 0){ if(_chartOption && _chartOption.series.length > 0){
_chartOption.series.forEach((item:any) =>{ _chartOption.series.forEach((item:any) =>{
if(this.seriesModel[seriesName].ecxObject){ if(this.seriesModel[seriesName].ecxObject && Object.is(seriesName,item.id)){
item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecxObject); item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecxObject);
} }
if(this.seriesModel[seriesName].baseOption && Object.keys(this.seriesModel[seriesName].baseOption).length > 0){ if(this.seriesModel[seriesName].baseOption && Object.keys(this.seriesModel[seriesName].baseOption).length > 0 && Object.is(seriesName,item.id)){
item = Util.deepObjectMerge(item,this.seriesModel[seriesName].baseOption); item = Util.deepObjectMerge(item,this.seriesModel[seriesName].baseOption);
} }
if(this.seriesModel[seriesName].ecObject){ if(this.seriesModel[seriesName].ecObject && Object.is(seriesName,item.id)){
item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecObject); item = Util.deepObjectMerge(item,this.seriesModel[seriesName].ecObject);
} }
}) })
......
<#-- 获取序列映射X轴的索引start-->
<#macro getXIndex item>
<#compress>
<#if item.getPSChartCoordinateSystem?? && item.getPSChartCoordinateSystem()??>
<#assign chartCoordinateSystem = item.getPSChartCoordinateSystem() />
<#if chartCoordinateSystem.getPSChartGrid?? && chartCoordinateSystem.getPSChartGrid()?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridXAxis0?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridXAxis0()??>
${chartCoordinateSystem.getPSChartGrid().getPSChartGridXAxis0().getIndex()}<#else>0</#if>
</#if>
</#compress>
</#macro>
<#-- 获取序列映射X轴的索引end-->
<#-- 获取序列映射Y轴的索引start-->
<#macro getYIndex item>
<#compress>
<#if item.getPSChartCoordinateSystem?? && item.getPSChartCoordinateSystem()??>
<#assign chartCoordinateSystem = item.getPSChartCoordinateSystem() />
<#if chartCoordinateSystem.getPSChartGrid?? && chartCoordinateSystem.getPSChartGrid()?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridYAxis0?? && chartCoordinateSystem.getPSChartGrid().getPSChartGridYAxis0()??>
${chartCoordinateSystem.getPSChartGrid().getPSChartGridYAxis0().getIndex()}<#else>0</#if>
</#if>
</#compress>
</#macro>
<#-- 获取序列映射Y轴的索引end-->
<#-- 获取序列映射数据集的索引start-->
<#macro getDataSetIndex item>
<#compress>
<#if item.getPSChartDataSet?? && item.getPSChartDataSet()??>
<#assign chartDataSet = item.getPSChartDataSet() />
${chartDataSet.getIndex()}<#else>0
</#if>
</#compress>
</#macro>
<#-- 获取序列映射数据集的索引end-->
\ No newline at end of file
...@@ -95,7 +95,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -95,7 +95,7 @@ import UtilService from '@/utilservice/util-service';
* *
* @public * @public
* @type {(boolean)} * @type {(boolean)}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public isEnableCustomized!:boolean; @Prop() public isEnableCustomized!:boolean;
...@@ -104,7 +104,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -104,7 +104,7 @@ import UtilService from '@/utilservice/util-service';
* *
* @public * @public
* @type {(boolean)} * @type {(boolean)}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isHasCustomized:boolean = false; public isHasCustomized:boolean = false;
...@@ -113,7 +113,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -113,7 +113,7 @@ import UtilService from '@/utilservice/util-service';
* *
* @public * @public
* @type {(*)} * @type {(*)}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public modelDta:any; public modelDta:any;
...@@ -121,7 +121,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -121,7 +121,7 @@ import UtilService from '@/utilservice/util-service';
* modleId * modleId
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public modelId:string = "dashboard_<#if ctrl.getPSAppDataEntity()??>${ctrl.getPSAppDataEntity().getCodeName()?lower_case}<#else>app</#if>_${ctrl.getCodeName()?lower_case}"; public modelId:string = "dashboard_<#if ctrl.getPSAppDataEntity()??>${ctrl.getPSAppDataEntity().getCodeName()?lower_case}<#else>app</#if>_${ctrl.getCodeName()?lower_case}";
...@@ -129,7 +129,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -129,7 +129,7 @@ import UtilService from '@/utilservice/util-service';
* 建构功能服务对象 * 建构功能服务对象
* *
* @type {UtilService} * @type {UtilService}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public utilService:UtilService = new UtilService(); public utilService:UtilService = new UtilService();
...@@ -137,7 +137,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -137,7 +137,7 @@ import UtilService from '@/utilservice/util-service';
* 功能服务名称 * 功能服务名称
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public utilServiceName:string = "<#if ctrl.getPSAppDynaDashboardUtil?? && ctrl.getPSAppDynaDashboardUtil()??>${ctrl.getPSAppDynaDashboardUtil().getCodeName()?lower_case}</#if>"; public utilServiceName:string = "<#if ctrl.getPSAppDynaDashboardUtil?? && ctrl.getPSAppDynaDashboardUtil()??>${ctrl.getPSAppDynaDashboardUtil().getCodeName()?lower_case}</#if>";
...@@ -145,7 +145,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -145,7 +145,7 @@ import UtilService from '@/utilservice/util-service';
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -155,7 +155,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -155,7 +155,7 @@ import UtilService from '@/utilservice/util-service';
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return {}; return {};
...@@ -164,7 +164,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -164,7 +164,7 @@ import UtilService from '@/utilservice/util-service';
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -173,7 +173,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -173,7 +173,7 @@ import UtilService from '@/utilservice/util-service';
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -191,21 +191,21 @@ import UtilService from '@/utilservice/util-service'; ...@@ -191,21 +191,21 @@ import UtilService from '@/utilservice/util-service';
/** /**
* 动态设计水平列数 * 动态设计水平列数
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public layoutColNum:number = 12; public layoutColNum:number = 12;
/** /**
* 动态设计单元格高度,80px * 动态设计单元格高度,80px
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public layoutRowH:number = 80; public layoutRowH:number = 80;
/** /**
* 通知状态 * 通知状态
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public notifyState(){ public notifyState(){
this.$nextTick(() =>{ this.$nextTick(() =>{
...@@ -237,7 +237,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -237,7 +237,7 @@ import UtilService from '@/utilservice/util-service';
/** /**
* 加载布局与数据模型 * 加载布局与数据模型
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public loadModel(){ public loadModel(){
if(this.isEnableCustomized){ if(this.isEnableCustomized){
...@@ -273,7 +273,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -273,7 +273,7 @@ import UtilService from '@/utilservice/util-service';
/** /**
* 处理私人定制按钮 * 处理私人定制按钮
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public handleClick(){ public handleClick(){
const view:any ={ const view:any ={
...@@ -298,7 +298,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -298,7 +298,7 @@ import UtilService from '@/utilservice/util-service';
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -307,7 +307,7 @@ import UtilService from '@/utilservice/util-service'; ...@@ -307,7 +307,7 @@ import UtilService from '@/utilservice/util-service';
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
......
...@@ -34,12 +34,14 @@ ...@@ -34,12 +34,14 @@
<a v-for="(item,index) in items" :key="index" :href = "item.starturl"> <a v-for="(item,index) in items" :key="index" :href = "item.starturl">
<i-col <#if ctrl.getCardColLG() gt 0> :lg="${ctrl.getCardColLG()?c}"</#if><#if ctrl.getCardColMD() gt 0> :md="${ctrl.getCardColMD()?c}"</#if><#if ctrl.getCardColSM() gt 0> :sm="${ctrl.getCardColSM()?c}"</#if><#if ctrl.getCardColXS() gt 0> :xs="${ctrl.getCardColXS()?c}"</#if> style="<#if ctrl.getCardHeight() gt 0>height: ${ctrl.getCardHeight()?c}<#else>min-height: 170</#if>px;<#if ctrl.getCardWidth() gt 0> width: ${ctrl.getCardWidth()?c}px;</#if>margin-bottom: 10px;"> <i-col <#if ctrl.getCardColLG() gt 0> :lg="${ctrl.getCardColLG()?c}"</#if><#if ctrl.getCardColMD() gt 0> :md="${ctrl.getCardColMD()?c}"</#if><#if ctrl.getCardColSM() gt 0> :sm="${ctrl.getCardColSM()?c}"</#if><#if ctrl.getCardColXS() gt 0> :xs="${ctrl.getCardColXS()?c}"</#if> style="<#if ctrl.getCardHeight() gt 0>height: ${ctrl.getCardHeight()?c}<#else>min-height: 170</#if>px;<#if ctrl.getCardWidth() gt 0> width: ${ctrl.getCardWidth()?c}px;</#if>margin-bottom: 10px;">
<el-card shadow="always" :class="[ item.isselected === true ? 'isselected' : false, 'single-card-data' ]" @click.native="handleClick(item)" @dblclick.native="handleDblClick(item)"> <el-card shadow="always" :class="[ item.isselected === true ? 'isselected' : false, 'single-card-data' ]" @click.native="handleClick(item)" @dblclick.native="handleDblClick(item)">
<#if ctrl.getItemPSLayoutPanel()??> <#if ctrl.getItemPSLayoutPanel()??>
<#assign panel = ctrl.getItemPSLayoutPanel()> <#assign panel = ctrl.getItemPSLayoutPanel()>
<layout_${panel.getName()} name='${panel.name}' :inputData="item"></layout_${panel.getName()}> <@ibizindent blank=24>
<#elseif ctrl.itemRender??> ${P.getCtrlCode(panel, 'CONTROL.html').code}
</@ibizindent>
<#elseif ctrl.itemRender??>
${ctrl.itemRender.code} ${ctrl.itemRender.code}
<#else> <#else>
<img v-if="item.srficonpath" :src="item.srficonpath" class="single-card-img" /> <img v-if="item.srficonpath" :src="item.srficonpath" class="single-card-img" />
<img v-else src="/assets/img/noimage.png" class="single-card-img" /> <img v-else src="/assets/img/noimage.png" class="single-card-img" />
<div class="single-card-default"> <div class="single-card-default">
...@@ -47,7 +49,7 @@ ...@@ -47,7 +49,7 @@
{{item.srfmajortext}} {{item.srfmajortext}}
</Tooltip> </Tooltip>
</div> </div>
</#if> </#if>
</el-card> </el-card>
</i-col> </i-col>
</a> </a>
...@@ -64,7 +66,7 @@ ...@@ -64,7 +66,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.selections; return this.selections;
...@@ -74,7 +76,7 @@ ...@@ -74,7 +76,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -84,7 +86,7 @@ ...@@ -84,7 +86,7 @@
* 是否默认选中第一条数据 * 是否默认选中第一条数据
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: false }) public isSelectFirstDefault!: boolean; @Prop({ default: false }) public isSelectFirstDefault!: boolean;
...@@ -92,7 +94,7 @@ ...@@ -92,7 +94,7 @@
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -100,7 +102,7 @@ ...@@ -100,7 +102,7 @@
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public createAction!: string; @Prop() public createAction!: string;
...@@ -108,7 +110,7 @@ ...@@ -108,7 +110,7 @@
* 部件行为--remove * 部件行为--remove
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public removeAction!: string; @Prop() public removeAction!: string;
...@@ -116,7 +118,7 @@ ...@@ -116,7 +118,7 @@
* 部件行为--update * 部件行为--update
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateAction!: string; @Prop() public updateAction!: string;
...@@ -124,15 +126,46 @@ ...@@ -124,15 +126,46 @@
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
<#if view.getPSAppViewLogics?? && view.getPSAppViewLogics()??>
<#list view.getPSAppViewLogics() as logic>
<#if logic.getPFLogicCodeType() == 'APP_NEWDATA'>
/**
* 打开新建数据视图
*
* @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Prop() public newdata: any;
</#if>
<#if logic.getPFLogicCodeType() == 'APP_OPENDATA'>
/**
* 打开编辑数据视图
*
* @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Prop() public opendata: any;
</#if>
</#list>
</#if>
/**
* this引用
*
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public thisRef: any = this;
/** /**
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public isSingleSelect?: boolean; @Prop() public isSingleSelect?: boolean;
...@@ -140,7 +173,7 @@ ...@@ -140,7 +173,7 @@
* 数据 * 数据
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public items: any[] = []; public items: any[] = [];
...@@ -148,7 +181,7 @@ ...@@ -148,7 +181,7 @@
* 是否支持分页 * 是否支持分页
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isEnablePagingBar: boolean = ${ctrl.isEnablePagingBar()?c};; public isEnablePagingBar: boolean = ${ctrl.isEnablePagingBar()?c};;
...@@ -156,7 +189,7 @@ ...@@ -156,7 +189,7 @@
* 总条数 * 总条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public totalRecord: number = 0; public totalRecord: number = 0;
...@@ -164,14 +197,14 @@ ...@@ -164,14 +197,14 @@
* 加载的数据是否附加在items之后 * 加载的数据是否附加在items之后
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isAddBehind:boolean = false; public isAddBehind:boolean = false;
/** /**
* 选中数组 * 选中数组
* @type {Array<any>} * @type {Array<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selections: Array<any> = []; public selections: Array<any> = [];
...@@ -179,7 +212,7 @@ ...@@ -179,7 +212,7 @@
* 当前页 * 当前页
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public curPage: number = 1; public curPage: number = 1;
...@@ -187,7 +220,7 @@ ...@@ -187,7 +220,7 @@
* 分页条数 * 分页条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public limit: number = ${ctrl.getPagingSize()?c}; public limit: number = ${ctrl.getPagingSize()?c};
...@@ -195,7 +228,7 @@ ...@@ -195,7 +228,7 @@
* 排序方向 * 排序方向
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>'; public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>';
...@@ -203,7 +236,7 @@ ...@@ -203,7 +236,7 @@
* 排序字段 * 排序字段
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>'; public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>';
...@@ -211,7 +244,7 @@ ...@@ -211,7 +244,7 @@
* 排序点击事件 * 排序点击事件
* @param {string} field 属性名 * @param {string} field 属性名
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public sortClick(field:string) { public sortClick(field:string) {
if(this.sortField !== field){ if(this.sortField !== field){
...@@ -231,7 +264,7 @@ ...@@ -231,7 +264,7 @@
* 排序class变更 * 排序class变更
* @param {string} field 属性名 * @param {string} field 属性名
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getsortClass(field:string) { public getsortClass(field:string) {
if(this.sortField !== field || this.sortDir === ''){ if(this.sortField !== field || this.sortDir === ''){
...@@ -246,7 +279,7 @@ ...@@ -246,7 +279,7 @@
/** /**
* Vue声明周期,组件挂载完毕 * Vue声明周期,组件挂载完毕
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public mounted () { public mounted () {
this.afterMounted(); this.afterMounted();
...@@ -255,7 +288,7 @@ ...@@ -255,7 +288,7 @@
/** /**
* 执行mounted后的逻辑 * 执行mounted后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterMounted(){ public afterMounted(){
<#if !ctrl.isEnablePagingBar()> <#if !ctrl.isEnablePagingBar()>
...@@ -270,7 +303,7 @@ ...@@ -270,7 +303,7 @@
/** /**
* Vue声明周期,组件创建完毕 * Vue声明周期,组件创建完毕
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -279,7 +312,7 @@ ...@@ -279,7 +312,7 @@
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -300,7 +333,7 @@ ...@@ -300,7 +333,7 @@
/** /**
* 加载更多 * 加载更多
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public loadMore(){ public loadMore(){
if(this.totalRecord>this.items.length) if(this.totalRecord>this.items.length)
...@@ -315,7 +348,7 @@ ...@@ -315,7 +348,7 @@
* 刷新 * 刷新
* *
* @param {*} [opt={}] * @param {*} [opt={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh(opt: any = {}) { public refresh(opt: any = {}) {
this.curPage = 1; this.curPage = 1;
...@@ -325,7 +358,7 @@ ...@@ -325,7 +358,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -334,7 +367,7 @@ ...@@ -334,7 +367,7 @@
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -351,7 +384,7 @@ ...@@ -351,7 +384,7 @@
* @public * @public
* @param {*} [arg={}] * @param {*} [arg={}]
* @param {boolean} [isReset=false] 是否重置items * @param {boolean} [isReset=false] 是否重置items
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(opt: any = {}, isReset: boolean = false): void { public load(opt: any = {}, isReset: boolean = false): void {
if(!this.fetchAction){ if(!this.fetchAction){
...@@ -417,7 +450,7 @@ ...@@ -417,7 +450,7 @@
* *
* @param {any[]} datas * @param {any[]} datas
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async remove(datas: any[]): Promise<any> { public async remove(datas: any[]): Promise<any> {
if(!this.removeAction){ if(!this.removeAction){
...@@ -513,9 +546,75 @@ ...@@ -513,9 +546,75 @@
return removeData; return removeData;
} }
/**
* 保存
*
* @param {*} $event
* @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public async save(args: any[], params?: any, $event?: any, xData?: any){
let _this = this;
let successItems:any = [];
let errorItems:any = [];
let errorMessage:any = [];
for (const item of _this.items) {
try {
if(Object.is(item.rowDataState, 'create')){
if(!this.createAction){
this.$Notice.error({ title: '错误', desc: '${view.getName()}视图列表createAction参数未配置' });
}else{
Object.assign(item,{viewparams:this.viewparams});
let response = await this.service.add(this.createAction, JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator);
successItems.push(JSON.parse(JSON.stringify(response.data)));
}
}else if(Object.is(item.rowDataState, 'update')){
if(!this.updateAction){
this.$Notice.error({ title: '错误', desc: '${view.getName()}视图列表updateAction参数未配置' });
}else{
Object.assign(item,{viewparams:this.viewparams});
<#if de??>
if(item.${appde.getCodeName()?lower_case}){
Object.assign(this.context,{${appde.getCodeName()?lower_case}:item.${appde.getCodeName()?lower_case}});
}
</#if>
let response = await this.service.add(this.updateAction,JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator);
successItems.push(JSON.parse(JSON.stringify(response.data)));
}
}
} catch (error) {
errorItems.push(JSON.parse(JSON.stringify(item)));
errorMessage.push(error);
}
}
this.$emit('save', successItems);
this.refresh();
if(errorItems.length === 0){
this.$Notice.success({ title: '', desc: '保存成功!' });
}else{
errorItems.forEach((item:any,index:number)=>{
this.$Notice.error({ title: '保存失败', desc: item.majorentityname+'保存失败!' });
console.error(errorMessage[index]);
});
}
return successItems;
}
/**
* 面板数据变化处理事件
* @param {any} item 当前卡片数据
* @param {any} $event 面板事件数据
*
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public onPanelDataChange(item:any,$event:any) {
Object.assign(item, $event, {rowDataState:'update'});
}
/** /**
* 选择数据 * 选择数据
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public handleClick(args: any) { public handleClick(args: any) {
...@@ -532,7 +631,7 @@ ...@@ -532,7 +631,7 @@
/** /**
* 双击数据 * 双击数据
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public handleDblClick(args: any) { public handleDblClick(args: any) {
...@@ -541,7 +640,7 @@ ...@@ -541,7 +640,7 @@
/** /**
* 触发事件 * 触发事件
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public selectchange() { public selectchange() {
......
...@@ -9,6 +9,16 @@ ...@@ -9,6 +9,16 @@
<#if view.getViewType() == 'DEDATAVIEWEXPVIEW'> <#if view.getViewType() == 'DEDATAVIEWEXPVIEW'>
:isSelectFirstDefault="true" :isSelectFirstDefault="true"
</#if> </#if>
<#if view.getPSAppViewLogics?? && view.getPSAppViewLogics()??>
<#list view.getPSAppViewLogics() as logic>
<#if logic.getPFLogicCodeType() == 'APP_NEWDATA'>
:newdata="newdata"
</#if>
<#if logic.getPFLogicCodeType() == 'APP_OPENDATA'>
:opendata="opendata"
</#if>
</#list>
</#if>
</#assign> </#assign>
<#ibizinclude> <#ibizinclude>
../@MACRO/HTML/DEFAULT.html.ftl ../@MACRO/HTML/DEFAULT.html.ftl
......
...@@ -65,7 +65,65 @@ ...@@ -65,7 +65,65 @@
}); });
} }
/**
* 添加数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
@Errorlog
public add(action: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Context,Data, isloading);
}else{
result =_appEntityService.Create(Context,Data, isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
/**
* 修改数据
*
* @param {string} action
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
@Errorlog
public update(action: string, context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
const {data:Data,context:Context} = this.handleRequestData(action,context,data,true);
return new Promise((resolve: any, reject: any) => {
const _appEntityService: any = this.appEntityService;
let result: Promise<any>;
if (_appEntityService[action] && _appEntityService[action] instanceof Function) {
result = _appEntityService[action](Data,Context,isloading);
}else{
result =_appEntityService.Update(Data,Context,isloading);
}
result.then((response) => {
this.handleResponse(action, response);
resolve(response);
}).catch(response => {
reject(response);
});
});
}
<#ibizinclude> <#ibizinclude>
../@MACRO/SERVICE/SERVICE_BOTTOM.ts.ftl ../@MACRO/SERVICE/SERVICE_BOTTOM.ts.ftl
......
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
* 打开新建数据视图 * 打开新建数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public newdata: any; @Prop() public newdata: any;
</#if> </#if>
...@@ -85,7 +85,7 @@ ...@@ -85,7 +85,7 @@
* 打开编辑数据视图 * 打开编辑数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public opendata: any; @Prop() public opendata: any;
</#if> </#if>
......
...@@ -94,7 +94,7 @@ FullCalendar, ...@@ -94,7 +94,7 @@ FullCalendar,
* 是否默认选中第一条数据 * 是否默认选中第一条数据
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: false }) public isSelectFirstDefault!: boolean; @Prop({ default: false }) public isSelectFirstDefault!: boolean;
...@@ -102,7 +102,7 @@ FullCalendar, ...@@ -102,7 +102,7 @@ FullCalendar,
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -110,7 +110,7 @@ FullCalendar, ...@@ -110,7 +110,7 @@ FullCalendar,
* 部件行为--load * 部件行为--load
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction!: string; @Prop() public loadAction!: string;
...@@ -121,7 +121,7 @@ FullCalendar, ...@@ -121,7 +121,7 @@ FullCalendar,
* 打开新建数据视图 * 打开新建数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public newdata: any; @Prop() public newdata: any;
</#if> </#if>
...@@ -130,7 +130,7 @@ FullCalendar, ...@@ -130,7 +130,7 @@ FullCalendar,
* 打开编辑数据视图 * 打开编辑数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public opendata: any; @Prop() public opendata: any;
</#if> </#if>
...@@ -142,7 +142,7 @@ FullCalendar, ...@@ -142,7 +142,7 @@ FullCalendar,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public calendarClass: string = "calendar"; public calendarClass: string = "calendar";
...@@ -151,7 +151,7 @@ FullCalendar, ...@@ -151,7 +151,7 @@ FullCalendar,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selectedEventElement:any; public selectedEventElement:any;
...@@ -160,7 +160,7 @@ FullCalendar, ...@@ -160,7 +160,7 @@ FullCalendar,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public calendarPlugins: any[] = [ public calendarPlugins: any[] = [
dayGridPlugin, dayGridPlugin,
...@@ -174,7 +174,7 @@ FullCalendar, ...@@ -174,7 +174,7 @@ FullCalendar,
* *
* @public * @public
* @type {} * @type {}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public header: any = { public header: any = {
left: 'prev,next today gotoDate', left: 'prev,next today gotoDate',
...@@ -187,7 +187,7 @@ FullCalendar, ...@@ -187,7 +187,7 @@ FullCalendar,
* *
* @public * @public
* @type {} * @type {}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public buttonText: any = { public buttonText: any = {
today: '今天', today: '今天',
...@@ -202,7 +202,7 @@ FullCalendar, ...@@ -202,7 +202,7 @@ FullCalendar,
* *
* @public * @public
* @type {} * @type {}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public customButtons: any = { public customButtons: any = {
gotoDate: { gotoDate: {
...@@ -216,7 +216,7 @@ FullCalendar, ...@@ -216,7 +216,7 @@ FullCalendar,
* *
* @public * @public
* @type boolean * @type boolean
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public modalVisible: boolean = false; public modalVisible: boolean = false;
...@@ -225,7 +225,7 @@ FullCalendar, ...@@ -225,7 +225,7 @@ FullCalendar,
* *
* @public * @public
* @type Date * @type Date
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selectedGotoDate: Date = new Date(); public selectedGotoDate: Date = new Date();
...@@ -233,7 +233,7 @@ FullCalendar, ...@@ -233,7 +233,7 @@ FullCalendar,
* 打开时间选择模态 * 打开时间选择模态
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public openDateSelect(){ public openDateSelect(){
this.modalVisible = true; this.modalVisible = true;
...@@ -243,7 +243,7 @@ FullCalendar, ...@@ -243,7 +243,7 @@ FullCalendar,
* 跳转到指定时间 * 跳转到指定时间
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public gotoDate(){ public gotoDate(){
let appCalendar: any = this.$refs.calendar; let appCalendar: any = this.$refs.calendar;
...@@ -256,7 +256,7 @@ FullCalendar, ...@@ -256,7 +256,7 @@ FullCalendar,
* *
* @public * @public
* @type {} * @type {}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public validRange: any = { public validRange: any = {
start:"0000-01-01", start:"0000-01-01",
...@@ -268,7 +268,7 @@ FullCalendar, ...@@ -268,7 +268,7 @@ FullCalendar,
* *
* @public * @public
* @type {} * @type {}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public defaultDate: any = this.$util.dateFormat(new Date()); public defaultDate: any = this.$util.dateFormat(new Date());
...@@ -276,7 +276,7 @@ FullCalendar, ...@@ -276,7 +276,7 @@ FullCalendar,
* 设置按钮文本 * 设置按钮文本
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setButtonText(){ public setButtonText(){
this.buttonText.today = this.$t('app.calendar.today'), this.buttonText.today = this.$t('app.calendar.today'),
...@@ -291,7 +291,7 @@ FullCalendar, ...@@ -291,7 +291,7 @@ FullCalendar,
* 监听语言变化 * 监听语言变化
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Watch('$i18n.locale') @Watch('$i18n.locale')
public onLocaleChange(newval: any, val: any) { public onLocaleChange(newval: any, val: any) {
...@@ -303,7 +303,7 @@ FullCalendar, ...@@ -303,7 +303,7 @@ FullCalendar,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public events: any[] = []; public events: any[] = [];
...@@ -312,7 +312,7 @@ FullCalendar, ...@@ -312,7 +312,7 @@ FullCalendar,
* *
* @public * @public
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public calendarType: string = "${ctrl.getCalendarStyle()}"; public calendarType: string = "${ctrl.getCalendarStyle()}";
...@@ -321,7 +321,7 @@ FullCalendar, ...@@ -321,7 +321,7 @@ FullCalendar,
* *
* @public * @public
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isShowlegend: any = { public isShowlegend: any = {
<#if ctrl.getPSSysCalendarItems()??> <#if ctrl.getPSSysCalendarItems()??>
...@@ -335,7 +335,7 @@ FullCalendar, ...@@ -335,7 +335,7 @@ FullCalendar,
* 图例点击事件 * 图例点击事件
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
legendTrigger(itemType:string){ legendTrigger(itemType:string){
this.isShowlegend[itemType] = !this.isShowlegend[itemType]; this.isShowlegend[itemType] = !this.isShowlegend[itemType];
...@@ -347,7 +347,7 @@ FullCalendar, ...@@ -347,7 +347,7 @@ FullCalendar,
* *
* @public * @public
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public searchArgCache: any = {}; public searchArgCache: any = {};
...@@ -355,7 +355,7 @@ FullCalendar, ...@@ -355,7 +355,7 @@ FullCalendar,
* 搜索获取日程事件 * 搜索获取日程事件
* *
* @param {*} $event 日期信息 * @param {*} $event 日期信息
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public searchEvents(fetchInfo?:any, successCallback?:any, failureCallback?:any ) { public searchEvents(fetchInfo?:any, successCallback?:any, failureCallback?:any ) {
// 处理请求参数 // 处理请求参数
...@@ -422,7 +422,7 @@ FullCalendar, ...@@ -422,7 +422,7 @@ FullCalendar,
* 日期点击事件 * 日期点击事件
* *
* @param {*} $event 日期信息 * @param {*} $event 日期信息
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onDateClick($event: any) { public onDateClick($event: any) {
let date = $event.date; let date = $event.date;
...@@ -433,7 +433,7 @@ FullCalendar, ...@@ -433,7 +433,7 @@ FullCalendar,
* 获取编辑视图信息 * 获取编辑视图信息
* *
* @param {*} $event 事件信息 * @param {*} $event 事件信息
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getEditView(deName: string) { public getEditView(deName: string) {
let view: any = {}; let view: any = {};
...@@ -484,7 +484,7 @@ FullCalendar, ...@@ -484,7 +484,7 @@ FullCalendar,
* @param {*} $event calendar事件对象或event数据 * @param {*} $event calendar事件对象或event数据
* @param {*} isOriginData true:$event是原始event数据,false:是组件 * @param {*} isOriginData true:$event是原始event数据,false:是组件
* @param {*} $event timeline事件对象 * @param {*} $event timeline事件对象
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onEventClick($event: any, isOriginData:boolean = false, $event2?: any) { public onEventClick($event: any, isOriginData:boolean = false, $event2?: any) {
// 处理event数据 // 处理event数据
...@@ -560,7 +560,7 @@ FullCalendar, ...@@ -560,7 +560,7 @@ FullCalendar,
/** /**
* 日历刷新 * 日历刷新
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh() { public refresh() {
if(Object.is(this.calendarType,"TIMELINE")){ if(Object.is(this.calendarType,"TIMELINE")){
...@@ -575,7 +575,7 @@ FullCalendar, ...@@ -575,7 +575,7 @@ FullCalendar,
* 日程拖动事件 * 日程拖动事件
* *
* @param {*} $event 事件信息 * @param {*} $event 事件信息
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onEventDrop($event: any) { public onEventDrop($event: any) {
if(this.isSelectFirstDefault){ if(this.isSelectFirstDefault){
...@@ -620,7 +620,7 @@ FullCalendar, ...@@ -620,7 +620,7 @@ FullCalendar,
* 选中的数据 * 选中的数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selections: any[] = []; public selections: any[] = [];
...@@ -628,7 +628,7 @@ FullCalendar, ...@@ -628,7 +628,7 @@ FullCalendar,
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.selections; return this.selections;
...@@ -638,7 +638,7 @@ FullCalendar, ...@@ -638,7 +638,7 @@ FullCalendar,
* 获取单项数据 * 获取单项数据
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -648,7 +648,7 @@ FullCalendar, ...@@ -648,7 +648,7 @@ FullCalendar,
* vue 生命周期 * vue 生命周期
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
<#if ctrl.getCalendarStyle?? && ctrl.getCalendarStyle() == 'TIMELINE'> <#if ctrl.getCalendarStyle?? && ctrl.getCalendarStyle() == 'TIMELINE'>
...@@ -662,7 +662,7 @@ FullCalendar, ...@@ -662,7 +662,7 @@ FullCalendar,
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -674,10 +674,33 @@ FullCalendar, ...@@ -674,10 +674,33 @@ FullCalendar,
} }
} }
/**
* vue 生命周期
*
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public mounted(){
this.afterMounted();
}
/**
* 执行mounted后的逻辑
*
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public afterMounted(){
let appCalendar: any = this.$refs.calendar;
if(appCalendar){
let api = appCalendar.getApi();
api.updateSize()
}
}
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -686,7 +709,7 @@ FullCalendar, ...@@ -686,7 +709,7 @@ FullCalendar,
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -711,7 +734,7 @@ FullCalendar, ...@@ -711,7 +734,7 @@ FullCalendar,
* 事件绘制回调 * 事件绘制回调
* *
* @param {*} info 信息 * @param {*} info 信息
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public eventRender(info?:any,) { public eventRender(info?:any,) {
let data = Object.assign({title: info.event.title, start: info.event.start, end: info.event.end}, info.event.extendedProps); let data = Object.assign({title: info.event.title, start: info.event.start, end: info.event.end}, info.event.extendedProps);
...@@ -735,7 +758,7 @@ FullCalendar, ...@@ -735,7 +758,7 @@ FullCalendar,
* *
* @param {*} event * @param {*} event
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public renderContextMenu(event: any) { public renderContextMenu(event: any) {
let content; let content;
...@@ -764,7 +787,7 @@ FullCalendar, ...@@ -764,7 +787,7 @@ FullCalendar,
* 绘制${childCtrl.getOwner().getItemType()}类型右键菜单 * 绘制${childCtrl.getOwner().getItemType()}类型右键菜单
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public renderContextMenu${srfclassname(childCtrl.getOwner().getItemType()?lower_case)}() { public renderContextMenu${srfclassname(childCtrl.getOwner().getItemType()?lower_case)}() {
return ( return (
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
* 部件行为--load * 部件行为--load
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction!: string; @Prop() public loadAction!: string;
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public isSingleSelect!: boolean; @Prop({ default: true }) public isSingleSelect!: boolean;
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public controlClass: string = "${ctrl.name}"; public controlClass: string = "${ctrl.name}";
...@@ -75,28 +75,28 @@ ...@@ -75,28 +75,28 @@
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public items: any[] = []; public items: any[] = [];
/** /**
* 默认展开节点集合 * 默认展开节点集合
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public defExpands: any = []; public defExpands: any = [];
/** /**
* 行节点下标 * 行节点下标
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public itemNum: any = {}; public itemNum: any = {};
/** /**
* 计数下标 * 计数下标
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public num: number = 0; public num: number = 0;
...@@ -104,7 +104,7 @@ ...@@ -104,7 +104,7 @@
* 获取列属性值 * 获取列属性值
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getColumnValue(task: any, field: string) { public getColumnValue(task: any, field: string) {
<#if ctrl.getPSDETreeNodes()??> <#if ctrl.getPSDETreeNodes()??>
...@@ -133,7 +133,7 @@ ...@@ -133,7 +133,7 @@
* 获取代码项 * 获取代码项
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getCodeListItem(codelist: any, val: any) { public getCodeListItem(codelist: any, val: any) {
for(let i = 0; i < codelist.items.length; i++) { for(let i = 0; i < codelist.items.length; i++) {
...@@ -148,7 +148,7 @@ ...@@ -148,7 +148,7 @@
* 搜索获取日程事件 * 搜索获取日程事件
* *
* @param {*} $event 日期信息 * @param {*} $event 日期信息
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(task: any = {}, resolve?: any) { public load(task: any = {}, resolve?: any) {
const params: any = { const params: any = {
...@@ -209,7 +209,7 @@ ...@@ -209,7 +209,7 @@
* 计算当前节点的上下文 * 计算当前节点的上下文
* *
* @param {*} curNode 当前节点 * @param {*} curNode 当前节点
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public computecurNodeContext(curNode:any){ public computecurNodeContext(curNode:any){
let tempContext:any = {}; let tempContext:any = {};
...@@ -225,7 +225,7 @@ ...@@ -225,7 +225,7 @@
* 节点展开 * 节点展开
* *
* @param {*} item 当前节点 * @param {*} item 当前节点
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public itemExpand(item: any) { public itemExpand(item: any) {
...@@ -234,7 +234,7 @@ ...@@ -234,7 +234,7 @@
/** /**
* 刷新 * 刷新
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh() { public refresh() {
this.load(); this.load();
...@@ -246,7 +246,7 @@ ...@@ -246,7 +246,7 @@
* 选中的数据 * 选中的数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selections: any[] = []; public selections: any[] = [];
...@@ -254,7 +254,7 @@ ...@@ -254,7 +254,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.selections; return this.selections;
...@@ -264,7 +264,7 @@ ...@@ -264,7 +264,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -274,7 +274,7 @@ ...@@ -274,7 +274,7 @@
* vue 生命周期 * vue 生命周期
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.load(); this.load();
...@@ -284,7 +284,7 @@ ...@@ -284,7 +284,7 @@
* 设置行Class * 设置行Class
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setRowClass({row, rowIndex}: {row: any, rowIndex: number}) { public setRowClass({row, rowIndex}: {row: any, rowIndex: number}) {
return 'treegrid' + this.itemNum[row.id]; return 'treegrid' + this.itemNum[row.id];
...@@ -294,7 +294,7 @@ ...@@ -294,7 +294,7 @@
* 展开默认节点 * 展开默认节点
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public expandDefNode() { public expandDefNode() {
if(this.defExpands.length > 0) { if(this.defExpands.length > 0) {
...@@ -312,7 +312,7 @@ ...@@ -312,7 +312,7 @@
* 选中变化 * 选中变化
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public select($event: any) { public select($event: any) {
if (!$event) { if (!$event) {
......
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return [this.currentselectedNode]; return [this.currentselectedNode];
...@@ -65,7 +65,7 @@ ...@@ -65,7 +65,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return this.currentselectedNode; return this.currentselectedNode;
...@@ -75,7 +75,7 @@ ...@@ -75,7 +75,7 @@
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public isSingleSelect!: boolean; @Prop({ default: true }) public isSingleSelect!: boolean;
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
* 是否默认选中第一条数据 * 是否默认选中第一条数据
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: false }) public isSelectFirstDefault!: boolean; @Prop({ default: false }) public isSelectFirstDefault!: boolean;
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
* 枝干节点是否可用(具有数据能力,可抛出) * 枝干节点是否可用(具有数据能力,可抛出)
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({default:true}) public isBranchAvailable!: boolean; @Prop({default:true}) public isBranchAvailable!: boolean;
...@@ -99,7 +99,7 @@ ...@@ -99,7 +99,7 @@
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -107,7 +107,7 @@ ...@@ -107,7 +107,7 @@
* 初始化完成 * 初始化完成
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public inited: boolean = false; public inited: boolean = false;
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
* 已选中数据集合 * 已选中数据集合
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selectedNodes: any = []; public selectedNodes: any = [];
...@@ -123,7 +123,7 @@ ...@@ -123,7 +123,7 @@
* 当前选中数据项 * 当前选中数据项
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public currentselectedNode: any = {}; public currentselectedNode: any = {};
...@@ -131,7 +131,7 @@ ...@@ -131,7 +131,7 @@
* 选中数据字符串 * 选中数据字符串
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public selectedData?: string; @Prop() public selectedData?: string;
...@@ -140,7 +140,7 @@ ...@@ -140,7 +140,7 @@
* *
* @param {*} newVal * @param {*} newVal
* @param {*} oldVal * @param {*} oldVal
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Watch('selectedData') @Watch('selectedData')
public onValueChange(newVal: any, oldVal: any) { public onValueChange(newVal: any, oldVal: any) {
...@@ -162,7 +162,7 @@ ...@@ -162,7 +162,7 @@
* 回显选中数据集合 * 回显选中数据集合
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public echoselectedNodes:any[] = this.selectedData ? ( this.isSingleSelect ? [JSON.parse(this.selectedData)[0]] : JSON.parse(this.selectedData)) : []; public echoselectedNodes:any[] = this.selectedData ? ( this.isSingleSelect ? [JSON.parse(this.selectedData)[0]] : JSON.parse(this.selectedData)) : [];
...@@ -170,7 +170,7 @@ ...@@ -170,7 +170,7 @@
* 部件行为--update * 部件行为--update
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateAction!: string; @Prop() public updateAction!: string;
...@@ -178,7 +178,7 @@ ...@@ -178,7 +178,7 @@
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
...@@ -186,7 +186,7 @@ ...@@ -186,7 +186,7 @@
* 部件行为--remove * 部件行为--remove
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public removeAction!: string; @Prop() public removeAction!: string;
...@@ -194,7 +194,7 @@ ...@@ -194,7 +194,7 @@
* 部件行为--load * 部件行为--load
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction!: string; @Prop() public loadAction!: string;
...@@ -202,7 +202,7 @@ ...@@ -202,7 +202,7 @@
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public createAction!: string; @Prop() public createAction!: string;
...@@ -210,7 +210,7 @@ ...@@ -210,7 +210,7 @@
* 过滤属性 * 过滤属性
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public srfnodefilter: string = ''; public srfnodefilter: string = '';
...@@ -218,7 +218,7 @@ ...@@ -218,7 +218,7 @@
* 默认输出图标 * 默认输出图标
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isOutputIconDefault: boolean = ${ctrl.isOutputIconDefault()?c}; public isOutputIconDefault: boolean = ${ctrl.isOutputIconDefault()?c};
...@@ -226,7 +226,7 @@ ...@@ -226,7 +226,7 @@
* 树数据 * 树数据
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Provide() @Provide()
public nodes: any[] = []; --> public nodes: any[] = []; -->
...@@ -235,7 +235,7 @@ ...@@ -235,7 +235,7 @@
* 数据展开主键 * 数据展开主键
* *
* @type {string[]} * @type {string[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Provide() @Provide()
public expandedKeys: string[] = []; public expandedKeys: string[] = [];
...@@ -247,7 +247,7 @@ ...@@ -247,7 +247,7 @@
* @param {*} data * @param {*} data
* @param {*} data 当前节点对应传入对象 * @param {*} data 当前节点对应传入对象
* @param {*} checkedState 树目前选中状态对象 * @param {*} checkedState 树目前选中状态对象
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onCheck(data: any, checkedState: any) { public onCheck(data: any, checkedState: any) {
// 处理多选数据 // 处理多选数据
...@@ -264,7 +264,7 @@ ...@@ -264,7 +264,7 @@
* @public * @public
* @param {*} data 节点对应传入对象 * @param {*} data 节点对应传入对象
* @param {*} node 节点对应node对象 * @param {*} node 节点对应node对象
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selectionChange(data: any, node: any) { public selectionChange(data: any, node: any) {
// 禁用项处理 // 禁用项处理
...@@ -287,7 +287,7 @@ ...@@ -287,7 +287,7 @@
/** /**
* Vue声明周期(处理组件的输入属性) * Vue声明周期(处理组件的输入属性)
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -296,7 +296,7 @@ ...@@ -296,7 +296,7 @@
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -334,7 +334,7 @@ ...@@ -334,7 +334,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -343,7 +343,7 @@ ...@@ -343,7 +343,7 @@
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -357,7 +357,7 @@ ...@@ -357,7 +357,7 @@
/** /**
* 刷新数据 * 刷新数据
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh_all(): void { public refresh_all(): void {
this.inited = false; this.inited = false;
...@@ -369,7 +369,7 @@ ...@@ -369,7 +369,7 @@
/** /**
* 刷新父节点 * 刷新父节点
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh_parent(): void { public refresh_parent(): void {
if (Object.keys(this.currentselectedNode).length === 0) { if (Object.keys(this.currentselectedNode).length === 0) {
...@@ -398,7 +398,7 @@ ...@@ -398,7 +398,7 @@
* 数据加载 * 数据加载
* *
* @param {*} node * @param {*} node
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(node: any = {}, resolve?: any) { public load(node: any = {}, resolve?: any) {
if (node.data && node.data.children) { if (node.data && node.data.children) {
...@@ -452,7 +452,7 @@ ...@@ -452,7 +452,7 @@
* 计算当前节点的上下文 * 计算当前节点的上下文
* *
* @param {*} curNode 当前节点 * @param {*} curNode 当前节点
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public computecurNodeContext(curNode:any){ public computecurNodeContext(curNode:any){
let tempContext:any = {}; let tempContext:any = {};
...@@ -468,7 +468,7 @@ ...@@ -468,7 +468,7 @@
* 刷新功能 * 刷新功能
* *
* @param {any[]} args * @param {any[]} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh(args: any[]): void { public refresh(args: any[]): void {
this.refresh_all(); this.refresh_all();
...@@ -500,7 +500,7 @@ ...@@ -500,7 +500,7 @@
* @param {*} [curContext] 当前节点上下文 * @param {*} [curContext] 当前节点上下文
* @param {*} [arg={}] 当前节点附加参数 * @param {*} [arg={}] 当前节点附加参数
* @param {boolean} parentnode 是否是刷新父节点 * @param {boolean} parentnode 是否是刷新父节点
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh_node(curContext:any,arg: any = {}, parentnode: boolean): void { public refresh_node(curContext:any,arg: any = {}, parentnode: boolean): void {
const { srfnodeid: id } = arg; const { srfnodeid: id } = arg;
...@@ -533,7 +533,7 @@ ...@@ -533,7 +533,7 @@
* @public * @public
* @param {any[]} items * @param {any[]} items
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public formatExpanded(items: any[]): any[] { public formatExpanded(items: any[]): any[] {
const data: any[] = []; const data: any[] = [];
...@@ -551,7 +551,7 @@ ...@@ -551,7 +551,7 @@
* @param {any[]} items 当前节点所有子节点集合 * @param {any[]} items 当前节点所有子节点集合
* @param {boolean} isRoot 是否是加载根节点 * @param {boolean} isRoot 是否是加载根节点
* @param {boolean} isSelectedAll 是否选中所有子节点 * @param {boolean} isSelectedAll 是否选中所有子节点
* @memberof MainTree * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setDefaultSelection(items: any[], isRoot: boolean = false, isSelectedAll: boolean = false): void { public setDefaultSelection(items: any[], isRoot: boolean = false, isSelectedAll: boolean = false): void {
if(items.length == 0){ if(items.length == 0){
...@@ -617,7 +617,7 @@ ...@@ -617,7 +617,7 @@
* *
* @param {*} node * @param {*} node
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public renderContextMenu(node: any) { public renderContextMenu(node: any) {
let content; let content;
...@@ -646,7 +646,7 @@ ...@@ -646,7 +646,7 @@
* *
* @param {*} node * @param {*} node
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public renderContextMenu${srfclassname(childCtrl.getOwner().getNodeType()?lower_case)}() { public renderContextMenu${srfclassname(childCtrl.getOwner().getNodeType()?lower_case)}() {
return ( return (
...@@ -663,7 +663,7 @@ ${P.getCtrlCode(childCtrl, 'CONTROL.html').code} ...@@ -663,7 +663,7 @@ ${P.getCtrlCode(childCtrl, 'CONTROL.html').code}
* 设置选中高亮 * 设置选中高亮
* *
* @param {*} data * @param {*} data
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setTreeNodeHighLight(data: any): void { public setTreeNodeHighLight(data: any): void {
const tree: any = this.$refs.${ctrl.name}; const tree: any = this.$refs.${ctrl.name};
...@@ -674,7 +674,7 @@ ${P.getCtrlCode(childCtrl, 'CONTROL.html').code} ...@@ -674,7 +674,7 @@ ${P.getCtrlCode(childCtrl, 'CONTROL.html').code}
* 执行默认界面行为 * 执行默认界面行为
* *
* @param {*} node * @param {*} node
* @memberof AppView * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public doDefaultAction(node: any) { public doDefaultAction(node: any) {
if (node && node.data) { if (node && node.data) {
......
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return {}; return {};
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
* 选中数据 * 选中数据
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selection: any = {}; public selection: any = {};
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
* 过滤值 * 过滤值
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public srffilter: string = ''; public srffilter: string = '';
...@@ -92,7 +92,7 @@ ...@@ -92,7 +92,7 @@
* *
* @public * @public
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refViews: any = [ public refViews: any = [
<#list view.getAllRelatedPSAppViews() as refview> <#list view.getAllRelatedPSAppViews() as refview>
...@@ -110,7 +110,7 @@ ...@@ -110,7 +110,7 @@
* 分割宽度 * 分割宽度
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public split: number = 0.2; public split: number = 0.2;
...@@ -119,7 +119,7 @@ ...@@ -119,7 +119,7 @@
* *
* @param {*} [arg={}] * @param {*} [arg={}]
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public select(index: any, indexs: any[]) { public select(index: any, indexs: any[]) {
this.refViews.some((item:any) =>{ this.refViews.some((item:any) =>{
...@@ -142,7 +142,7 @@ ...@@ -142,7 +142,7 @@
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -157,7 +157,7 @@ ...@@ -157,7 +157,7 @@
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -166,7 +166,7 @@ ...@@ -166,7 +166,7 @@
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -181,7 +181,7 @@ ...@@ -181,7 +181,7 @@
* 视图数据变化 * 视图数据变化
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onViewDatasChange($event: any): void { public onViewDatasChange($event: any): void {
this.$emit('selectionchange', $event); this.$emit('selectionchange', $event);
...@@ -191,7 +191,7 @@ ...@@ -191,7 +191,7 @@
* 视图数据被激活 * 视图数据被激活
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public viewDatasActivated($event: any): void { public viewDatasActivated($event: any): void {
this.$emit('activated', $event); this.$emit('activated', $event);
...@@ -201,7 +201,7 @@ ...@@ -201,7 +201,7 @@
* 视图数据加载完成 * 视图数据加载完成
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onViewLoad($event: any): void { public onViewLoad($event: any): void {
this.$emit('load', $event); this.$emit('load', $event);
......
...@@ -21,7 +21,7 @@ GanttElastic, ...@@ -21,7 +21,7 @@ GanttElastic,
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -29,7 +29,7 @@ GanttElastic, ...@@ -29,7 +29,7 @@ GanttElastic,
* 部件行为--load * 部件行为--load
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction!: string; @Prop() public loadAction!: string;
...@@ -38,7 +38,7 @@ GanttElastic, ...@@ -38,7 +38,7 @@ GanttElastic,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ganttClass: string = "gantt"; public ganttClass: string = "gantt";
...@@ -47,7 +47,7 @@ GanttElastic, ...@@ -47,7 +47,7 @@ GanttElastic,
* *
* @public * @public
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public locale: string = 'zh-CN'; public locale: string = 'zh-CN';
...@@ -56,7 +56,7 @@ GanttElastic, ...@@ -56,7 +56,7 @@ GanttElastic,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public localeZH: any = { public localeZH: any = {
weekdays: ['星期一','星期二','星期三','星期四','星期五','星期六','星期日'], weekdays: ['星期一','星期二','星期三','星期四','星期五','星期六','星期日'],
...@@ -72,7 +72,7 @@ GanttElastic, ...@@ -72,7 +72,7 @@ GanttElastic,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public options: any = { public options: any = {
isflex: true, isflex: true,
...@@ -141,7 +141,7 @@ GanttElastic, ...@@ -141,7 +141,7 @@ GanttElastic,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public dynamicStyle: any = {}; public dynamicStyle: any = {};
...@@ -150,7 +150,7 @@ GanttElastic, ...@@ -150,7 +150,7 @@ GanttElastic,
* *
* @public * @public
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public tasks: any[] = []; public tasks: any[] = [];
...@@ -158,7 +158,7 @@ GanttElastic, ...@@ -158,7 +158,7 @@ GanttElastic,
* 监听语言变化 * 监听语言变化
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Watch('$i18n.locale') @Watch('$i18n.locale')
public onLocaleChange(newval: any, val: any) { public onLocaleChange(newval: any, val: any) {
...@@ -169,7 +169,7 @@ GanttElastic, ...@@ -169,7 +169,7 @@ GanttElastic,
* 获取列属性值 * 获取列属性值
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getColumnValue(task: any, field: string) { public getColumnValue(task: any, field: string) {
<#if ctrl.getPSDETreeNodes()??> <#if ctrl.getPSDETreeNodes()??>
...@@ -198,7 +198,7 @@ GanttElastic, ...@@ -198,7 +198,7 @@ GanttElastic,
* 获取代码项 * 获取代码项
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getCodeListItem(codelist: any, val: any) { public getCodeListItem(codelist: any, val: any) {
for(let i = 0; i < codelist.items.length; i++) { for(let i = 0; i < codelist.items.length; i++) {
...@@ -213,7 +213,7 @@ GanttElastic, ...@@ -213,7 +213,7 @@ GanttElastic,
* 获取部件参数 * 获取部件参数
* *
* @returns {any} * @returns {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getOptions() { public getOptions() {
if(Object.is(this.locale, 'zh-CN')) { if(Object.is(this.locale, 'zh-CN')) {
...@@ -226,7 +226,7 @@ GanttElastic, ...@@ -226,7 +226,7 @@ GanttElastic,
* 搜索获取日程事件 * 搜索获取日程事件
* *
* @param {*} $event 日期信息 * @param {*} $event 日期信息
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(task: any = {}) { public load(task: any = {}) {
const params: any = { const params: any = {
...@@ -270,7 +270,7 @@ GanttElastic, ...@@ -270,7 +270,7 @@ GanttElastic,
* 计算当前节点的上下文 * 计算当前节点的上下文
* *
* @param {*} curNode 当前节点 * @param {*} curNode 当前节点
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public computecurNodeContext(curNode:any){ public computecurNodeContext(curNode:any){
let tempContext:any = {}; let tempContext:any = {};
...@@ -286,7 +286,7 @@ GanttElastic, ...@@ -286,7 +286,7 @@ GanttElastic,
* 节点展开 * 节点展开
* *
* @param {*} task 当前节点 * @param {*} task 当前节点
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public taskItemExpand(task: any) { public taskItemExpand(task: any) {
if(!task.collapsed) { if(!task.collapsed) {
...@@ -300,7 +300,7 @@ GanttElastic, ...@@ -300,7 +300,7 @@ GanttElastic,
/** /**
* 刷新 * 刷新
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh() { public refresh() {
this.load(); this.load();
...@@ -312,7 +312,7 @@ GanttElastic, ...@@ -312,7 +312,7 @@ GanttElastic,
* 选中的数据 * 选中的数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selections: any[] = []; public selections: any[] = [];
...@@ -320,7 +320,7 @@ GanttElastic, ...@@ -320,7 +320,7 @@ GanttElastic,
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.selections; return this.selections;
...@@ -330,7 +330,7 @@ GanttElastic, ...@@ -330,7 +330,7 @@ GanttElastic,
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -340,7 +340,7 @@ GanttElastic, ...@@ -340,7 +340,7 @@ GanttElastic,
* vue 生命周期 * vue 生命周期
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.locale = this.$i18n.locale; this.locale = this.$i18n.locale;
...@@ -351,7 +351,7 @@ GanttElastic, ...@@ -351,7 +351,7 @@ GanttElastic,
* 点击事件 * 点击事件
* *
* @returns * @returns
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public taskClick({event, data}: {event: any, data: any}) { public taskClick({event, data}: {event: any, data: any}) {
const _this: any = this; const _this: any = this;
......
...@@ -7,8 +7,8 @@ ...@@ -7,8 +7,8 @@
<#if ctrl.groupRender??> <#if ctrl.groupRender??>
${ctrl.groupRender.code} ${ctrl.groupRender.code}
<#else> <#else>
<div :key="group + index" class="dataview-group-content" style="width: 280px;"> <div :key="group + index" class="dataview-group-content" style="<#if ctrl.getGroupWidth() gt 0>width: ${ctrl.getGroupWidth()?c}px;<#else>flex-grow: 1;</#if>">
<div class="dataview-group-header<#if ctrl.getGroupPSSysCss()??> ${ctrl.getGroupPSSysCss().getCssName()}</#if>" style="<#if ctrl.getGroupWidth() gt 0>width: ${ctrl.getGroupWidth()?c}px;<#else>flex-grow: 1;</#if>"> <div class="dataview-group-header<#if ctrl.getGroupPSSysCss()??> ${ctrl.getGroupPSSysCss().getCssName()}</#if>">
{{ getGroupText(group.name) }} {{ getGroupText(group.name) }}
<#if ctrl.getGroupPSUIActionGroup()??> <#if ctrl.getGroupPSUIActionGroup()??>
<Poptip trigger="hover" content="content" placement="bottom-end" style="float: right;"> <Poptip trigger="hover" content="content" placement="bottom-end" style="float: right;">
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
</#if> </#if>
</div> </div>
<draggable :list="group.items" group="${ctrl.name}" class="dataview-group-items" @change="onDragChange($event, group.name)"> <draggable :list="group.items" group="${ctrl.name}" class="dataview-group-items" @change="onDragChange($event, group.name)">
<div v-for="(item, i) in group.items" :key="i" :class="{'dataview-group-item': true, 'is-select': item.isselected}" @click="handleClick(item)"> <div v-for="(item, i) in group.items" :key="i" :class="{'dataview-group-item': true, 'is-select': item.isselected}" @click="handleClick(item)" @dblclick="handleDblClick(item)">
<#if ctrl.getItemPSLayoutPanel()??> <#if ctrl.getItemPSLayoutPanel()??>
<#assign panel = ctrl.getItemPSLayoutPanel()> <#assign panel = ctrl.getItemPSLayoutPanel()>
<layout_${panel.getName()} name='${panel.name}' :inputData="item"></layout_${panel.getName()}> <layout_${panel.getName()} name='${panel.name}' :inputData="item"></layout_${panel.getName()}>
...@@ -49,7 +49,26 @@ ...@@ -49,7 +49,26 @@
</div> </div>
</#if> </#if>
</template> </template>
</#if> <#if ctrl.getGroupQuickPSDEToolbar()??>
<div class="quick-action">
<#if ctrl.getGroupQuickPSDEToolbar().getPSDEToolbarItems()??>
<#list ctrl.getGroupQuickPSDEToolbar().getPSDEToolbarItems() as toolbarItem>
<div class="quick-action-item" title="${toolbarItem.getCaption()}" @click="${ctrl.getGroupQuickPSDEToolbar().getName()}_click({tag: '${toolbarItem.getName()}'}, $event)">
<#if toolbarItem.getPSSysImage()??>
<#if toolbarItem.getPSSysImage().getImagePath()?length gt 0>
<img src="${toolbarItem.getPSSysImage().getImagePath()}"/>
<#else>
<i class="${toolbarItem.getPSSysImage().getCssClass()}"></i>
</#if>
<#else>
<i class="el-icon-menu"></i>
</#if>
</div>
</#list>
</#if>
</div>
</#if>
</#if>
</div> </div>
</template> </template>
<#assign import_block> <#assign import_block>
...@@ -66,7 +85,7 @@ draggable, ...@@ -66,7 +85,7 @@ draggable,
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.selections; return this.selections;
...@@ -76,7 +95,7 @@ draggable, ...@@ -76,7 +95,7 @@ draggable,
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return null; return null;
...@@ -86,7 +105,7 @@ draggable, ...@@ -86,7 +105,7 @@ draggable,
* 是否默认选中第一条数据 * 是否默认选中第一条数据
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: false }) public isSelectFirstDefault!: boolean; @Prop({ default: false }) public isSelectFirstDefault!: boolean;
...@@ -94,7 +113,7 @@ draggable, ...@@ -94,7 +113,7 @@ draggable,
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -102,7 +121,7 @@ draggable, ...@@ -102,7 +121,7 @@ draggable,
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public createAction!: string; @Prop() public createAction!: string;
...@@ -110,7 +129,7 @@ draggable, ...@@ -110,7 +129,7 @@ draggable,
* 部件行为--remove * 部件行为--remove
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public removeAction!: string; @Prop() public removeAction!: string;
...@@ -118,7 +137,7 @@ draggable, ...@@ -118,7 +137,7 @@ draggable,
* 部件行为--update * 部件行为--update
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateAction!: string; @Prop() public updateAction!: string;
...@@ -126,7 +145,7 @@ draggable, ...@@ -126,7 +145,7 @@ draggable,
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
...@@ -134,7 +153,7 @@ draggable, ...@@ -134,7 +153,7 @@ draggable,
* 部件行为--updateGroup * 部件行为--updateGroup
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateGroupAction!: string; @Prop() public updateGroupAction!: string;
...@@ -142,7 +161,7 @@ draggable, ...@@ -142,7 +161,7 @@ draggable,
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public isSingleSelect?: boolean; @Prop() public isSingleSelect?: boolean;
...@@ -150,7 +169,7 @@ draggable, ...@@ -150,7 +169,7 @@ draggable,
* 数据 * 数据
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public items: any[] = []; public items: any[] = [];
...@@ -158,7 +177,7 @@ draggable, ...@@ -158,7 +177,7 @@ draggable,
* 是否支持分页 * 是否支持分页
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isEnablePagingBar: boolean = ${ctrl.isEnablePagingBar()?c};; public isEnablePagingBar: boolean = ${ctrl.isEnablePagingBar()?c};;
...@@ -166,7 +185,7 @@ draggable, ...@@ -166,7 +185,7 @@ draggable,
* 总条数 * 总条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public totalRecord: number = 0; public totalRecord: number = 0;
...@@ -174,14 +193,14 @@ draggable, ...@@ -174,14 +193,14 @@ draggable,
* 加载的数据是否附加在items之后 * 加载的数据是否附加在items之后
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isAddBehind:boolean = false; public isAddBehind:boolean = false;
/** /**
* 选中数组 * 选中数组
* @type {Array<any>} * @type {Array<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selections: Array<any> = []; public selections: Array<any> = [];
...@@ -189,7 +208,7 @@ draggable, ...@@ -189,7 +208,7 @@ draggable,
* 当前页 * 当前页
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public curPage: number = 1; public curPage: number = 1;
...@@ -197,7 +216,7 @@ draggable, ...@@ -197,7 +216,7 @@ draggable,
* 分页条数 * 分页条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public limit: number = ${ctrl.getPagingSize()?c}; public limit: number = ${ctrl.getPagingSize()?c};
...@@ -205,7 +224,7 @@ draggable, ...@@ -205,7 +224,7 @@ draggable,
* 排序方向 * 排序方向
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>'; public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>';
...@@ -213,7 +232,7 @@ draggable, ...@@ -213,7 +232,7 @@ draggable,
* 排序字段 * 排序字段
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>'; public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>';
...@@ -221,42 +240,42 @@ draggable, ...@@ -221,42 +240,42 @@ draggable,
* 是否分组 * 是否分组
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isGroup: boolean = true; public isGroup: boolean = true;
/** /**
* 分组集合 * 分组集合
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public groups: any[] = []; public groups: any[] = [];
/** /**
* 分组属性名称 * 分组属性名称
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public groupField: string = '<#if ctrl.getGroupPSDEField()??>${ctrl.getGroupPSDEField().getCodeName()?lower_case}</#if>'; public groupField: string = '<#if ctrl.getGroupPSDEField()??>${ctrl.getGroupPSDEField().getCodeName()?lower_case}</#if>';
/** /**
* 分组模式 * 分组模式
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public groupMode: string = '${ctrl.getGroupMode()}' public groupMode: string = '${ctrl.getGroupMode()}'
/** /**
* 分组模式 * 分组模式
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public groupCodelist: string = '<#if ctrl.getGroupPSCodeList()??>${ctrl.getGroupPSCodeList().getCodeName()}</#if>' public groupCodelist: string = '<#if ctrl.getGroupPSCodeList()??>${ctrl.getGroupPSCodeList().getCodeName()}</#if>'
/** /**
* Vue声明周期,组件挂载完毕 * Vue声明周期,组件挂载完毕
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public mounted () { public mounted () {
this.afterMounted(); this.afterMounted();
...@@ -265,7 +284,7 @@ draggable, ...@@ -265,7 +284,7 @@ draggable,
/** /**
* 执行mounted后的逻辑 * 执行mounted后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterMounted(){ public afterMounted(){
<#if !ctrl.isEnablePagingBar()> <#if !ctrl.isEnablePagingBar()>
...@@ -280,7 +299,7 @@ draggable, ...@@ -280,7 +299,7 @@ draggable,
/** /**
* Vue声明周期,组件创建完毕 * Vue声明周期,组件创建完毕
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created() { public created() {
this.afterCreated(); this.afterCreated();
...@@ -289,7 +308,7 @@ draggable, ...@@ -289,7 +308,7 @@ draggable,
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -310,7 +329,7 @@ draggable, ...@@ -310,7 +329,7 @@ draggable,
/** /**
* 加载更多 * 加载更多
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public loadMore(){ public loadMore(){
if(this.totalRecord>this.items.length) if(this.totalRecord>this.items.length)
...@@ -325,7 +344,7 @@ draggable, ...@@ -325,7 +344,7 @@ draggable,
* 刷新 * 刷新
* *
* @param {*} [opt={}] * @param {*} [opt={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh(opt: any = {}) { public refresh(opt: any = {}) {
this.curPage = 1; this.curPage = 1;
...@@ -335,7 +354,7 @@ draggable, ...@@ -335,7 +354,7 @@ draggable,
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -344,7 +363,7 @@ draggable, ...@@ -344,7 +363,7 @@ draggable,
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -361,7 +380,7 @@ draggable, ...@@ -361,7 +380,7 @@ draggable,
* @public * @public
* @param {*} [arg={}] * @param {*} [arg={}]
* @param {boolean} [isReset=false] 是否重置items * @param {boolean} [isReset=false] 是否重置items
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(opt: any = {}, isReset: boolean = false): void { public load(opt: any = {}, isReset: boolean = false): void {
if(!this.fetchAction){ if(!this.fetchAction){
...@@ -428,7 +447,7 @@ draggable, ...@@ -428,7 +447,7 @@ draggable,
* *
* @param {any[]} datas * @param {any[]} datas
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async remove(datas: any[]): Promise<any> { public async remove(datas: any[]): Promise<any> {
if(!this.removeAction){ if(!this.removeAction){
...@@ -528,7 +547,7 @@ draggable, ...@@ -528,7 +547,7 @@ draggable,
* 设置分组集合 * 设置分组集合
* *
* @param {*} * @param {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public updateData(opt: any) { public updateData(opt: any) {
const arg: any = { ...opt }; const arg: any = { ...opt };
...@@ -566,7 +585,7 @@ draggable, ...@@ -566,7 +585,7 @@ draggable,
* 设置分组集合 * 设置分组集合
* *
* @param {} * @param {}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setGroups() { public setGroups() {
if(!this.isGroup || !this.groupField || Object.is(this.groupMode, 'NONE')) { if(!this.isGroup || !this.groupField || Object.is(this.groupMode, 'NONE')) {
...@@ -602,7 +621,7 @@ draggable, ...@@ -602,7 +621,7 @@ draggable,
* 设置分组集合 * 设置分组集合
* *
* @param {string} name * @param {string} name
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getGroupItems(name: string) { public getGroupItems(name: string) {
let datas: any = []; let datas: any = [];
...@@ -618,7 +637,7 @@ draggable, ...@@ -618,7 +637,7 @@ draggable,
* 设置分组集合 * 设置分组集合
* *
* @param {string} name * @param {string} name
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getGroupText(name: string) { public getGroupText(name: string) {
if(Object.is(this.groupMode, 'CODELIST') && this.groupCodelist) { if(Object.is(this.groupMode, 'CODELIST') && this.groupCodelist) {
...@@ -638,7 +657,7 @@ draggable, ...@@ -638,7 +657,7 @@ draggable,
/** /**
* 选择数据 * 选择数据
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public handleClick(args: any) { public handleClick(args: any) {
...@@ -653,16 +672,22 @@ draggable, ...@@ -653,16 +672,22 @@ draggable,
/** /**
* 双击数据 * 双击数据
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public handleDblClick(args: any) { public handleDblClick(args: any) {
args.isselected = true;
this.items.forEach((item:any) =>{
if(item.srfkey !== args.srfkey){
item.isselected =false;
}
})
this.$emit('rowdblclick', args); this.$emit('rowdblclick', args);
} }
/** /**
* 触发事件 * 触发事件
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
* *
*/ */
public selectchange() { public selectchange() {
...@@ -680,7 +705,7 @@ draggable, ...@@ -680,7 +705,7 @@ draggable,
* *
* @param {*} tag * @param {*} tag
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public uiAction(tag: any, $event: any) { public uiAction(tag: any, $event: any) {
let row = this.selections.length > 0 ? this.selections[0] : {}; let row = this.selections.length > 0 ? this.selections[0] : {};
...@@ -701,7 +726,7 @@ draggable, ...@@ -701,7 +726,7 @@ draggable,
* *
* @param {*} evt * @param {*} evt
* @param {*} name * @param {*} name
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onDragChange(evt: any, name: string) { public onDragChange(evt: any, name: string) {
if(evt && evt.added && evt.added.element) { if(evt && evt.added && evt.added.element) {
...@@ -711,6 +736,10 @@ draggable, ...@@ -711,6 +736,10 @@ draggable,
} }
} }
<#if ctrl.groupRender??>
${ctrl.groupRender.code2}
</#if>
<#ibizinclude> <#ibizinclude>
../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl ../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl
</#ibizinclude> </#ibizinclude>
......
...@@ -37,6 +37,21 @@ ...@@ -37,6 +37,21 @@
.dataview-group-content:nth-child(1) { .dataview-group-content:nth-child(1) {
border-left: 1px solid #ddd; border-left: 1px solid #ddd;
} }
.quick-action {
flex-shrink: 0;
margin-left: 5px;
.quick-action-item {
width: 37px;
height: 37px;
text-align: center;
line-height: 37px;
border: 1px solid #ddd;
border-top-width: 0;
}
.quick-action-item:nth-child(1) {
border-top-width: 1px;
}
}
} }
<#ibizinclude> <#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl ../@MACRO/CSS/DEFAULT.less.ftl
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<#if item.render??> <#if item.render??>
${item.render.code} ${item.render.code}
<#else> <#else>
<app-form-group layoutType="<#if item.getPSLayoutPos()??>${item.getPSLayoutPos().getLayout()}</#if>" titleStyle="<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??>${item.getLabelPSSysCss().getCssName()}</#if>" class='<#if item.getPSSysCss?? && item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>' :uiActionGroup="detailsModel.${item.name}.uiActionGroup" @groupuiactionclick="groupUIActionClick($event)" :caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>" :isShowCaption="${item.isShowCaption()?c}" uiStyle="${item.getDetailStyle()}" :titleBarCloseMode="${item.getTitleBarCloseMode()}" :isInfoGroupMode="${item.isInfoGroupMode()?c}" <#if item.getPSSysImage()??>:iconInfo="{<#assign img=item.getPSSysImage()><#if img.getImagePath() == "">'iconclass':'${img.getCssClass()}'<#else>'iconpath':'${img.getImagePath()}'</#if>}"</#if>> <app-form-group layoutType="<#if item.getPSLayout()??>${item.getPSLayout().getLayout()}</#if>" titleStyle="<#if item.getLabelPSSysCss?? && item.getLabelPSSysCss()??>${item.getLabelPSSysCss().getCssName()}</#if>" class='<#if item.getPSSysCss?? && item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>' :uiActionGroup="detailsModel.${item.name}.uiActionGroup" @groupuiactionclick="groupUIActionClick($event)" :caption="<#if langbase??>$t('${langbase}.details.${item.name}')<#else>'${item.getCaption()}'</#if>" :isShowCaption="${item.isShowCaption()?c}" uiStyle="${item.getDetailStyle()}" :titleBarCloseMode="${item.getTitleBarCloseMode()}" :isInfoGroupMode="${item.isInfoGroupMode()?c}" <#if item.getPSSysImage()??>:iconInfo="{<#assign img=item.getPSSysImage()><#if img.getImagePath() == "">'iconclass':'${img.getCssClass()}'<#else>'iconpath':'${img.getImagePath()}'</#if>}"</#if>>
<#assign content> <#assign content>
<#list item.getPSDEFormDetails() as formmenber> <#list item.getPSDEFormDetails() as formmenber>
<#if !(formmenber.isHidden?? && formmenber.isHidden())> <#if !(formmenber.isHidden?? && formmenber.isHidden())>
......
...@@ -14,7 +14,7 @@ new FormPageModel({ ${detail} }) ...@@ -14,7 +14,7 @@ new FormPageModel({ ${detail} })
<#elseif item.getDetailType() == 'FORMPART'> <#elseif item.getDetailType() == 'FORMPART'>
new FormPartModel({ ${detail} }) new FormPartModel({ ${detail} })
<#elseif item.getDetailType() == 'GROUPPANEL'> <#elseif item.getDetailType() == 'GROUPPANEL'>
new FormGroupPanelModel({ ${detail}, uiActionGroup: { caption: '<#if item.getPSUIActionGroup()??>${item.getPSUIActionGroup().getName()}</#if>', langbase: '<#if langbase??>${langbase}</#if>', extractMode: '<#if item.getActionGroupExtractMode?? && item.getActionGroupExtractMode()??>${item.getActionGroupExtractMode()}<#else>ITEM</#if>', details: [<#if item.getPSUIActionGroup()??><#list item.getPSUIActionGroup().getPSUIActionGroupDetails() as uadetails><#if uadetails_index gt 0>, </#if>{ name: '${item.getName()}_${uadetails.getName()}', caption: '${uadetails.getPSUIAction().getCaption()}', uiactiontag: '${uadetails.getPSUIAction().getUIActionTag()?lower_case}'<#if uadetails.getPSUIAction().getPSSysImage()??>, <#assign viewimg=uadetails.getPSUIAction().getPSSysImage()/><#if viewimg.getCssClass() != ''>icon: '${viewimg.getCssClass()}'<#else>img: '${viewimg.getImagePath()}'</#if></#if> }</#list></#if>] } }) new FormGroupPanelModel({ ${detail}, uiActionGroup: { caption: '<#if item.getPSUIActionGroup()??>${item.getPSUIActionGroup().getName()}</#if>', langbase: '<#if langbase??>${langbase}</#if>', extractMode: '<#if item.getActionGroupExtractMode?? && item.getActionGroupExtractMode()??>${item.getActionGroupExtractMode()}<#else>ITEM</#if>', details: [<#if item.getPSUIActionGroup()??><#list item.getPSUIActionGroup().getPSUIActionGroupDetails() as uadetails><#if uadetails_index gt 0>, </#if>{ name: '${item.getName()}_${uadetails.getName()}', caption: '${uadetails.getPSUIAction().getCaption()}', uiactiontag: '${uadetails.getPSUIAction().getUIActionTag()?lower_case}'<#if uadetails.getPSUIAction().getPSSysImage()??>, <#assign viewimg=uadetails.getPSUIAction().getPSSysImage()/><#if viewimg.getCssClass() != ''>icon: '${viewimg.getCssClass()}'<#else>img: '${viewimg.getImagePath()}'</#if></#if>,isShowCaption:${uadetails.isShowCaption()?c},isShowIcon:${uadetails.isShowIcon()?c} }</#list></#if>] } })
<#elseif item.getDetailType() == 'IFRAME'> <#elseif item.getDetailType() == 'IFRAME'>
new FormIFrameModel({ ${detail} }) new FormIFrameModel({ ${detail} })
<#elseif item.getDetailType() == 'RAWITEM'> <#elseif item.getDetailType() == 'RAWITEM'>
......
...@@ -13,10 +13,19 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -13,10 +13,19 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl ../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl
</#ibizinclude> </#ibizinclude>
/**
* 视图默认使用
*
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Inject('navModel')
public navModel!:string;
/** /**
* 工作流审批意见控件绑定值 * 工作流审批意见控件绑定值
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public srfwfmemo:string = ""; public srfwfmemo:string = "";
...@@ -24,7 +33,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -24,7 +33,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return [this.data]; return [this.data];
...@@ -34,7 +43,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -34,7 +43,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return this.data; return this.data;
...@@ -44,7 +53,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -44,7 +53,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 是否默认保存 * 是否默认保存
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: false }) public autosave?: boolean; @Prop({ default: false }) public autosave?: boolean;
...@@ -52,7 +61,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -52,7 +61,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -60,7 +69,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -60,7 +69,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--submit * 部件行为--submit
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public WFSubmitAction!: string; @Prop() public WFSubmitAction!: string;
...@@ -68,7 +77,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -68,7 +77,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--start * 部件行为--start
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public WFStartAction!: string; @Prop() public WFStartAction!: string;
...@@ -76,7 +85,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -76,7 +85,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--update * 部件行为--update
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateAction!: string; @Prop() public updateAction!: string;
...@@ -84,7 +93,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -84,7 +93,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--remove * 部件行为--remove
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public removeAction!: string; @Prop() public removeAction!: string;
...@@ -92,7 +101,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -92,7 +101,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--loaddraft * 部件行为--loaddraft
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loaddraftAction!: string; @Prop() public loaddraftAction!: string;
...@@ -100,7 +109,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -100,7 +109,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--load * 部件行为--load
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction!: string; @Prop() public loadAction!: string;
...@@ -108,7 +117,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -108,7 +117,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public createAction!: string; @Prop() public createAction!: string;
...@@ -116,7 +125,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -116,7 +125,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public searchAction!: string; @Prop() public searchAction!: string;
...@@ -124,7 +133,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -124,7 +133,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 视图标识 * 视图标识
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public viewtag!: string; @Prop() public viewtag!: string;
...@@ -132,7 +141,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -132,7 +141,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 表单状态 * 表单状态
* *
* @type {Subject<any>} * @type {Subject<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public formState: Subject<any> = new Subject(); public formState: Subject<any> = new Subject();
...@@ -140,7 +149,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -140,7 +149,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 忽略表单项值变化 * 忽略表单项值变化
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ignorefieldvaluechange: boolean = false; public ignorefieldvaluechange: boolean = false;
...@@ -149,7 +158,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -149,7 +158,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @type {Subject<any>} * @type {Subject<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public dataChang: Subject<any> = new Subject(); public dataChang: Subject<any> = new Subject();
...@@ -158,7 +167,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -158,7 +167,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @type {(Subscription | undefined)} * @type {(Subscription | undefined)}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public dataChangEvent: Subscription | undefined; public dataChangEvent: Subscription | undefined;
...@@ -167,7 +176,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -167,7 +176,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public oldData: any = {}; public oldData: any = {};
...@@ -175,7 +184,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -175,7 +184,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 表单数据对象 * 表单数据对象
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public data: any = { public data: any = {
<#list ctrl.getPSDEFormItems() as item> <#list ctrl.getPSDEFormItems() as item>
...@@ -188,7 +197,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -188,7 +197,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 当前执行的行为逻辑 * 当前执行的行为逻辑
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public currentAction: string = ""; public currentAction: string = "";
...@@ -196,7 +205,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -196,7 +205,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 关系界面计数器 * 关系界面计数器
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public drcounter: number = 0; public drcounter: number = 0;
...@@ -204,7 +213,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -204,7 +213,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 需要等待关系界面保存时,第一次调用save参数的备份 * 需要等待关系界面保存时,第一次调用save参数的备份
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public drsaveopt: any = {}; public drsaveopt: any = {};
...@@ -212,7 +221,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -212,7 +221,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 表单保存回调存储对象 * 表单保存回调存储对象
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public saveState:any ; public saveState:any ;
...@@ -220,7 +229,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -220,7 +229,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 属性值规则 * 属性值规则
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public rules: any = { public rules: any = {
<#list ctrl.getAllPSDEFormDetails() as formdetail> <#list ctrl.getAllPSDEFormDetails() as formdetail>
...@@ -266,7 +275,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -266,7 +275,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 详情模型集合 * 详情模型集合
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public detailsModel: any = { public detailsModel: any = {
<#list ctrl.getAllPSDEFormDetails() as formdetail> <#list ctrl.getAllPSDEFormDetails() as formdetail>
...@@ -283,7 +292,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -283,7 +292,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @param {*} newVal * @param {*} newVal
* @param {*} oldVal * @param {*} oldVal
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Watch('data.${item.getName()}') @Watch('data.${item.getName()}')
on${srfclassname('${item.getName()}')}Change(newVal: any, oldVal: any) { on${srfclassname('${item.getName()}')}Change(newVal: any, oldVal: any) {
...@@ -306,7 +315,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -306,7 +315,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal } * @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public resetFormData({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void { public resetFormData({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void {
<#list ctrl.getPSDEFormItems() as item> <#list ctrl.getPSDEFormItems() as item>
...@@ -325,7 +334,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -325,7 +334,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 置空对象 * 置空对象
* *
* @param {any[]} args * @param {any[]} args
* @memberof EditForm * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ResetData(_datas:any){ public ResetData(_datas:any){
if(Object.keys(_datas).length >0){ if(Object.keys(_datas).length >0){
...@@ -342,7 +351,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -342,7 +351,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal } * @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public formLogic({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void { public formLogic({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void {
<#if P.getPartCode(item,'FORM_LOGIC').code?length gt 0> <#if P.getPartCode(item,'FORM_LOGIC').code?length gt 0>
...@@ -355,7 +364,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -355,7 +364,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
if(Object.is(name, '${formitem.name}')){ if(Object.is(name, '${formitem.name}')){
const details: string[] = [<#list itemUpdate.getPSDEFIUpdateDetails() as detail><#if detail_index gt 0>, </#if>'${detail.getPSDEFormDetailName()?lower_case}'</#list>]; const details: string[] = [<#list itemUpdate.getPSDEFIUpdateDetails() as detail><#if detail_index gt 0>, </#if>'${detail.getPSDEFormDetailName()?lower_case}'</#list>];
this.updateFormItems('${itemUpdate.codeName}', this.data, details, ${itemUpdate.isShowBusyIndicator()?c}); this.updateFormItems('${itemUpdate.getPSAppDEMethod().getCodeName()}', this.data, details, ${itemUpdate.isShowBusyIndicator()?c});
} }
</#if> </#if>
</#list> </#list>
...@@ -368,7 +377,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -368,7 +377,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* @public * @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal } * @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public formDataChange({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void { public formDataChange({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void {
if (this.ignorefieldvaluechange) { if (this.ignorefieldvaluechange) {
...@@ -385,7 +394,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -385,7 +394,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* @public * @public
* @param {*} [data={}] * @param {*} [data={}]
* @param {string} [action] * @param {string} [action]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onFormLoad(data: any = {},action:string): void { public onFormLoad(data: any = {},action:string): void {
<#if de??> <#if de??>
...@@ -410,7 +419,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -410,7 +419,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @param {*} [_datas={}] * @param {*} [_datas={}]
* @param {string} [action] * @param {string} [action]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public fillForm(_datas: any = {},action:string): void { public fillForm(_datas: any = {},action:string): void {
this.ignorefieldvaluechange = true; this.ignorefieldvaluechange = true;
...@@ -435,7 +444,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -435,7 +444,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @param {*} data * @param {*} data
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setFormEnableCond(data: any): void { public setFormEnableCond(data: any): void {
Object.values(this.detailsModel).forEach((detail: any) => { Object.values(this.detailsModel).forEach((detail: any) => {
...@@ -451,7 +460,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -451,7 +460,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 重置草稿表单状态 * 重置草稿表单状态
* *
* @public * @public
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public resetDraftFormStates(): void { public resetDraftFormStates(): void {
const form: any = this.$refs.form; const form: any = this.$refs.form;
...@@ -463,7 +472,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -463,7 +472,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 重置校验结果 * 重置校验结果
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public resetValidates(): void { public resetValidates(): void {
Object.values(this.detailsModel).forEach((detail: any) => { Object.values(this.detailsModel).forEach((detail: any) => {
...@@ -479,7 +488,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -479,7 +488,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 填充校验结果 (后台) * 填充校验结果 (后台)
* *
* @param {any[]} fieldErrors * @param {any[]} fieldErrors
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public fillValidates(fieldErrors: any[]): void { public fillValidates(fieldErrors: any[]): void {
fieldErrors.forEach((error: any) => { fieldErrors.forEach((error: any) => {
...@@ -497,7 +506,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -497,7 +506,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 表单校验状态 * 表单校验状态
* *
* @returns {boolean} * @returns {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public formValidateStatus(): boolean { public formValidateStatus(): boolean {
const form: any = this.$refs.${ctrl.name}; const form: any = this.$refs.${ctrl.name};
...@@ -512,7 +521,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -512,7 +521,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 获取全部值 * 获取全部值
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getValues(): any { public getValues(): any {
return this.data; return this.data;
...@@ -523,7 +532,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -523,7 +532,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @param {{ name: string, value: any }} $event * @param {{ name: string, value: any }} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onFormItemValueChange($event: { name: string, value: any }): void { public onFormItemValueChange($event: { name: string, value: any }): void {
if (!$event) { if (!$event) {
...@@ -541,7 +550,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -541,7 +550,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* @param {string} name * @param {string} name
* @param {*} value * @param {*} value
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setDataItemValue(name: string, value: any): void { public setDataItemValue(name: string, value: any): void {
if (!name || Object.is(name, '') || !this.data.hasOwnProperty(name)) { if (!name || Object.is(name, '') || !this.data.hasOwnProperty(name)) {
...@@ -561,7 +570,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -561,7 +570,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 表单 ${formdetail.getCaption()} 事件 * 表单 ${formdetail.getCaption()} 事件
* *
* @memberof @memberof ${srfclassname('${ctrl.codeName}')} * @memberof @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${formdetail.getName()}_click($event: any): void { public ${formdetail.getName()}_click($event: any): void {
<#if formdetail.getPSUIAction?? && formdetail.getPSUIAction()??> <#if formdetail.getPSUIAction?? && formdetail.getPSUIAction()??>
...@@ -576,7 +585,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -576,7 +585,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 表单 ${formdetail.getCaption()} 事件 * 表单 ${formdetail.getCaption()} 事件
* *
* @memberof @memberof ${srfclassname('${ctrl.codeName}')} * @memberof @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public ${formdetail.getName()}_click($event: any): void { public ${formdetail.getName()}_click($event: any): void {
<#assign itemUpdate=formdetail.getPSDEFormItemUpdate()/> <#assign itemUpdate=formdetail.getPSDEFormItemUpdate()/>
...@@ -660,7 +669,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -660,7 +669,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 分组界面行为事件 * 分组界面行为事件
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public groupUIActionClick($event: any): void { public groupUIActionClick($event: any): void {
if (!$event) { if (!$event) {
...@@ -683,7 +692,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -683,7 +692,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* Vue声明周期(处理组件的输入属性) * Vue声明周期(处理组件的输入属性)
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created(): void { public created(): void {
this.afterCreated(); this.afterCreated();
...@@ -692,7 +701,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -692,7 +701,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
if (this.viewState) { if (this.viewState) {
...@@ -754,7 +763,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -754,7 +763,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -763,7 +772,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -763,7 +772,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -781,7 +790,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -781,7 +790,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 拷贝内容 * 拷贝内容
* *
* @param {*} [arg={}] * @param {*} [arg={}]
* @memberof @memberof ${srfclassname('${ctrl.codeName}')} * @memberof @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public copy(srfkey: string): void { public copy(srfkey: string): void {
let copyData = this.$store.getters.getCopyData(srfkey); let copyData = this.$store.getters.getCopyData(srfkey);
...@@ -799,7 +808,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -799,7 +808,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
*打印 *打印
*@memberof @memberof ${srfclassname('${ctrl.codeName}')} *@memberof @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public print(){ public print(){
let _this:any = this; let _this:any = this;
...@@ -810,7 +819,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -810,7 +819,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 部件刷新 * 部件刷新
* *
* @param {any[]} args * @param {any[]} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh(args: any[]): void { public refresh(args: any[]): void {
let arg: any = {}; let arg: any = {};
...@@ -832,7 +841,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -832,7 +841,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @param {*} [arg={}] * @param {*} [arg={}]
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public autoLoad(arg: any = {}): void { public autoLoad(arg: any = {}): void {
if (arg.srfkey && !Object.is(arg.srfkey, '')) { if (arg.srfkey && !Object.is(arg.srfkey, '')) {
...@@ -853,7 +862,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -853,7 +862,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @param {*} [opt={}] * @param {*} [opt={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.loadAction){ if(!this.loadAction){
...@@ -888,7 +897,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -888,7 +897,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 加载草稿 * 加载草稿
* *
* @param {*} [opt={}] * @param {*} [opt={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public loadDraft(opt: any = {}): void { public loadDraft(opt: any = {}): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
...@@ -944,7 +953,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -944,7 +953,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 自动保存 * 自动保存
* *
* @param {*} [opt={}] * @param {*} [opt={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public autoSave(opt: any = {}): void { public autoSave(opt: any = {}): void {
if (!this.formValidateStatus()) { if (!this.formValidateStatus()) {
...@@ -997,7 +1006,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -997,7 +1006,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* @param {boolean} [showResultInfo] * @param {boolean} [showResultInfo]
* @param {boolean} [ifStateNext] formState是否下发通知 * @param {boolean} [ifStateNext] formState是否下发通知
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async save(opt: any = {}, showResultInfo?: boolean, ifStateNext: boolean = true): Promise<any> { public async save(opt: any = {}, showResultInfo?: boolean, ifStateNext: boolean = true): Promise<any> {
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
...@@ -1077,7 +1086,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1077,7 +1086,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* *
* @public * @public
* @param {*} [opt={}] * @param {*} [opt={}]
* @memberof ${srfclassname('${ctrl.name}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> { public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> {
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
...@@ -1112,7 +1121,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1112,7 +1121,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* @param {*} [data={}] * @param {*} [data={}]
* @param {*} [localdata={}] * @param {*} [localdata={}]
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async wfstart(data: any,localdata?:any): Promise<any> { public async wfstart(data: any,localdata?:any): Promise<any> {
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
...@@ -1172,7 +1181,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1172,7 +1181,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* @param {*} [data={}] * @param {*} [data={}]
* @param {*} [localdata={}] * @param {*} [localdata={}]
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async wfsubmit(data: any,localdata?:any): Promise<any> { public async wfsubmit(data: any,localdata?:any): Promise<any> {
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
...@@ -1253,7 +1262,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1253,7 +1262,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* @param {string[]} updateDetails 更新项 * @param {string[]} updateDetails 更新项
* @param {boolean} [showloading] 是否显示加载状态 * @param {boolean} [showloading] 是否显示加载状态
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public updateFormItems(mode: string, data: any = {}, updateDetails: string[], showloading?: boolean): void { public updateFormItems(mode: string, data: any = {}, updateDetails: string[], showloading?: boolean): void {
if (!mode || (mode && Object.is(mode, ''))) { if (!mode || (mode && Object.is(mode, ''))) {
...@@ -1298,7 +1307,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1298,7 +1307,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 回车事件 * 回车事件
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onEnter($event: any): void { public onEnter($event: any): void {
<#if ctrl.getControlType() == 'SEARCHFORM' && !ctrl.isEnableAutoSearch()> <#if ctrl.getControlType() == 'SEARCHFORM' && !ctrl.isEnableAutoSearch()>
...@@ -1310,7 +1319,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1310,7 +1319,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 保存并退出 * 保存并退出
* *
* @param {any[]} args * @param {any[]} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public saveAndExit(data:any[]):Promise<any>{ public saveAndExit(data:any[]):Promise<any>{
let _this = this; let _this = this;
...@@ -1335,7 +1344,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1335,7 +1344,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 保存并新建 * 保存并新建
* *
* @param {any[]} args * @param {any[]} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public saveAndNew(data:any[]):Promise<any>{ public saveAndNew(data:any[]):Promise<any>{
let _this = this; let _this = this;
...@@ -1358,7 +1367,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1358,7 +1367,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 删除并退出 * 删除并退出
* *
* @param {any[]} args * @param {any[]} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public removeAndExit(data:any[]):Promise<any>{ public removeAndExit(data:any[]):Promise<any>{
let _this = this; let _this = this;
...@@ -1382,66 +1391,68 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1382,66 +1391,68 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
* 关系界面数据保存完成 * 关系界面数据保存完成
* *
* @param {any} $event * @param {any} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public drdatasaved($event:any){ public drdatasaved($event:any){
let _this = this; let _this = this;
this.drcounter--; this.drcounter--;
if(this.drcounter > 0){ if(this.drcounter === 0){
return; this.save(this.drsaveopt, undefined, false).then((res) =>{
} this.saveState(res);
this.save(this.drsaveopt, undefined, false).then((res) =>{ this.drsaveopt = {};
this.saveState(res); if(Object.is(_this.currentAction, "saveAndNew")){
this.drsaveopt = {}; _this.ResetData(res);
if(Object.is(_this.currentAction, "saveAndNew")){ _this.loadDraft({});
_this.ResetData(res); }else if(Object.is(_this.currentAction, "saveAndExit")){
_this.loadDraft({}); if(res){
}else if(Object.is(_this.currentAction, "saveAndExit")){ _this.closeView(res.data);
if(res){ }
_this.closeView(res.data);
} }
} });
}); }
} }
/** /**
* 新建默认值 * 新建默认值
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public createDefault(){ public createDefault(){
<#list ctrl.getAllPSDEFormDetails() as formdetail><#t> <#list ctrl.getAllPSDEFormDetails() as formdetail><#t>
<#if formdetail.getCreateDV?? && formdetail.getCreateDV()??><#t> <#if formdetail.getCreateDV?? && formdetail.getCreateDV()??><#t>
<#if !(formdetail.getCreateDV() == '')><#t> <#if !(formdetail.getCreateDV() == '') || formdetail.getCreateDVT() == 'CURTIME'><#t>
if (this.data.hasOwnProperty('${formdetail.getCodeName()?lower_case}')) { if (this.data.hasOwnProperty('${formdetail.getCodeName()?lower_case}')) {
<#-- 网页请求 --> <#-- 网页请求 -->
<#if formdetail.getCreateDVT() == 'CONTEXT'> <#if formdetail.getCreateDVT() == 'CONTEXT'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.viewparams['${formdetail.getCreateDV()}']; this.data['${formdetail.getCodeName()?lower_case}'] = this.viewparams['${formdetail.getCreateDV()}'];
<#-- 用户全局对象 --> <#-- 用户全局对象 -->
<#elseif formdetail.getCreateDVT() == 'SESSION'> <#elseif formdetail.getCreateDVT() == 'SESSION'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.context['${formdetail.getCreateDV()}']; this.data['${formdetail.getCodeName()?lower_case}'] = this.context['${formdetail.getCreateDV()}'];
<#-- 当前应用数据 --> <#-- 当前应用数据 -->
<#elseif formdetail.getCreateDVT() == 'APPDATA'> <#elseif formdetail.getCreateDVT() == 'APPDATA'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.context['${formdetail.getCreateDV()}']; this.data['${formdetail.getCodeName()?lower_case}'] = this.context['${formdetail.getCreateDV()}'];
<#-- 当前操作用户(名称) --> <#-- 当前操作用户(名称) -->
<#elseif formdetail.getCreateDVT() == 'OPERATORNAME'> <#elseif formdetail.getCreateDVT() == 'OPERATORNAME'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.context['srfusername']; this.data['${formdetail.getCodeName()?lower_case}'] = this.context['srfusername'];
<#-- 当前操作用户(编号) --> <#-- 当前操作用户(编号) -->
<#elseif formdetail.getCreateDVT() == 'OPERATOR'> <#elseif formdetail.getCreateDVT() == 'OPERATOR'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.context['srfuserid']; this.data['${formdetail.getCodeName()?lower_case}'] = this.context['srfuserid'];
<#else> <#-- 当前时间 -->
<#-- 默认值 --> <#elseif formdetail.getCreateDVT() == 'CURTIME'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.$util.dateFormat(new Date());
<#else>
<#-- 默认值 -->
<#assign datatype=srfjavatype(formdetail.getStdDataType())> <#assign datatype=srfjavatype(formdetail.getStdDataType())>
this.data['${formdetail.getCodeName()?lower_case}'] = <#if datatype=='BigInteger' || datatype=='Integer' || datatype=='Double' || datatype=='Decimal' || datatype=='Float' || datatype=='BigDecimal'>${formdetail.getCreateDV()}<#else>'${formdetail.getCreateDV()}'</#if>; this.data['${formdetail.getCodeName()?lower_case}'] = <#if datatype=='BigInteger' || datatype=='Integer' || datatype=='Double' || datatype=='Decimal' || datatype=='Float' || datatype=='BigDecimal'>${formdetail.getCreateDV()}<#else>'${formdetail.getCreateDV()}'</#if>;
</#if> </#if>
} }
</#if> </#if>
</#if> </#if>
</#list> </#list>
} }
/** /**
* 更新默认值 * 更新默认值
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public updateDefault(){ public updateDefault(){
<#list ctrl.getAllPSDEFormDetails() as formdetail><#t> <#list ctrl.getAllPSDEFormDetails() as formdetail><#t>
...@@ -1481,7 +1492,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1481,7 +1492,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 搜索 * 搜索
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onSearch() { public onSearch() {
this.$emit('load', this.data); this.$emit('load', this.data);
...@@ -1490,7 +1501,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1490,7 +1501,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 重置 * 重置
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onReset() { public onReset() {
this.loadDraft(); this.loadDraft();
...@@ -1501,7 +1512,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators'; ...@@ -1501,7 +1512,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
/** /**
* 搜索 * 搜索
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onSearch() { public onSearch() {
this.$emit('load', this.data); this.$emit('load', this.data);
......
...@@ -72,17 +72,29 @@ ...@@ -72,17 +72,29 @@
<el-table-column :column-key="'${item.getName()?lower_case}'" :label="<#if langbase??>$t('${langbase}.columns.${item.getName()?lower_case}')<#else>'${item.getCaption()}'</#if>"<#if item.getWidthUnit()!='STAR'> :width="${item.width?c}" <#else> :min-width="${item.width?c}" </#if> :align="'${item.getAlign()?lower_case}'"> <el-table-column :column-key="'${item.getName()?lower_case}'" :label="<#if langbase??>$t('${langbase}.columns.${item.getName()?lower_case}')<#else>'${item.getCaption()}'</#if>"<#if item.getWidthUnit()!='STAR'> :width="${item.width?c}" <#else> :min-width="${item.width?c}" </#if> :align="'${item.getAlign()?lower_case}'">
<@getColumnHeader item 8 /> <@getColumnHeader item 8 />
<template slot-scope="scope"> <template slot-scope="scope">
<span> <div style="text-align: center;">
<#if item.getPSDEUIActionGroup().getPSDEUIActions()??> <#if item.getPSDEUIActionGroup().getPSDEUIActions()??>
<#list item.getPSDEUIActionGroup().getPSUIActions() as uiaction> <#list item.getPSDEUIActionGroup().getPSUIActionGroupDetails() as uiactionDetail>
<#if uiaction_index gt 0><divider type='vertical'></divider></#if> <#if uiactionDetail_index gt 0>
<divider type='vertical'></divider>
</#if>
<#if uiactionDetail.getPSUIAction?? && uiactionDetail.getPSUIAction()??>
<#assign uiaction = uiactionDetail.getPSUIAction() />
<#if !uiactionDetail.isShowCaption()>
<tooltip :transfer="true" :max-width="600">
</#if>
<a @click="uiAction(scope.row, '${uiaction.getUIActionTag()}', $event)"> <a @click="uiAction(scope.row, '${uiaction.getUIActionTag()}', $event)">
<i class='<#if uiaction.getIconCls?? && uiaction.getIconCls()??>${uiaction.getIconCls()}</#if>'></i> <#if uiactionDetail.isShowIcon()><i class='<#if uiaction.getIconCls?? && uiaction.getIconCls()??>${uiaction.getIconCls()}</#if>'></i></#if>
{{<#if langbase??>$t('${langbase}.uiactions.${uiaction.getUIActionTag()?lower_case}')<#else>'${uiaction.getCaption()}'</#if>}} <#if uiactionDetail.isShowCaption()>{{<#if langbase??>$t('${langbase}.uiactions.${uiaction.getUIActionTag()?lower_case}')<#else>'${uiaction.getCaption()}'</#if>}}</#if>
</a> </a>
<#if !uiactionDetail.isShowCaption()>
<div slot='content'>{{<#if langbase??>$t('${langbase}.uiactions.${uiaction.getUIActionTag()?lower_case}')<#else>'${uiaction.getCaption()}'</#if>}}</div>
</tooltip>
</#if>
</#if>
</#list> </#list>
</#if> </#if>
</span> </div>
</template> </template>
</el-table-column> </el-table-column>
<#-- [2]END:操作列 --> <#-- [2]END:操作列 -->
......
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
:height="isEnablePagingBar && items.length > 0 ? 'calc(100% - 36px)' : '100%'" :height="isEnablePagingBar && items.length > 0 ? 'calc(100% - 36px)' : '100%'"
:highlight-current-row ="isSingleSelect" :highlight-current-row ="isSingleSelect"
:row-class-name="getRowClassName" :row-class-name="getRowClassName"
:cell-class-name="getCellClassName"
@row-click="rowClick($event)" @row-click="rowClick($event)"
@select-all="selectAll($event)" @select-all="selectAll($event)"
@select="select($event)" @select="select($event)"
...@@ -111,7 +112,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -111,7 +112,7 @@ import { FormItemModel } from '@/model/form-detail';
* 代码表服务对象 * 代码表服务对象
* *
* @type {CodeListService} * @type {CodeListService}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public codeListService:CodeListService = new CodeListService({ $store: this.$store }); public codeListService:CodeListService = new CodeListService({ $store: this.$store });
...@@ -119,7 +120,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -119,7 +120,7 @@ import { FormItemModel } from '@/model/form-detail';
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return this.selections; return this.selections;
...@@ -129,7 +130,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -129,7 +130,7 @@ import { FormItemModel } from '@/model/form-detail';
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return this.selections[0]; return this.selections[0];
...@@ -142,7 +143,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -142,7 +143,7 @@ import { FormItemModel } from '@/model/form-detail';
* 打开新建数据视图 * 打开新建数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public newdata: any; @Prop() public newdata: any;
</#if> </#if>
...@@ -151,7 +152,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -151,7 +152,7 @@ import { FormItemModel } from '@/model/form-detail';
* 打开编辑数据视图 * 打开编辑数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public opendata: any; @Prop() public opendata: any;
</#if> </#if>
...@@ -162,7 +163,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -162,7 +163,7 @@ import { FormItemModel } from '@/model/form-detail';
* 显示处理提示 * 显示处理提示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: true }) public showBusyIndicator?: boolean; @Prop({ default: true }) public showBusyIndicator?: boolean;
...@@ -170,7 +171,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -170,7 +171,7 @@ import { FormItemModel } from '@/model/form-detail';
* 部件行为--update * 部件行为--update
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public updateAction!: string; @Prop() public updateAction!: string;
...@@ -178,7 +179,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -178,7 +179,7 @@ import { FormItemModel } from '@/model/form-detail';
* 部件行为--fetch * 部件行为--fetch
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public fetchAction!: string; @Prop() public fetchAction!: string;
...@@ -186,7 +187,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -186,7 +187,7 @@ import { FormItemModel } from '@/model/form-detail';
* 部件行为--remove * 部件行为--remove
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public removeAction!: string; @Prop() public removeAction!: string;
...@@ -194,7 +195,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -194,7 +195,7 @@ import { FormItemModel } from '@/model/form-detail';
* 部件行为--load * 部件行为--load
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loadAction!: string; @Prop() public loadAction!: string;
...@@ -202,7 +203,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -202,7 +203,7 @@ import { FormItemModel } from '@/model/form-detail';
* 部件行为--loaddraft * 部件行为--loaddraft
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public loaddraftAction!: string; @Prop() public loaddraftAction!: string;
...@@ -210,7 +211,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -210,7 +211,7 @@ import { FormItemModel } from '@/model/form-detail';
* 部件行为--create * 部件行为--create
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public createAction!: string; @Prop() public createAction!: string;
...@@ -218,7 +219,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -218,7 +219,7 @@ import { FormItemModel } from '@/model/form-detail';
* 当前页 * 当前页
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public curPage: number = 1; public curPage: number = 1;
...@@ -226,7 +227,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -226,7 +227,7 @@ import { FormItemModel } from '@/model/form-detail';
* 数据 * 数据
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public items: any[] = []; public items: any[] = [];
...@@ -234,7 +235,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -234,7 +235,7 @@ import { FormItemModel } from '@/model/form-detail';
* 是否支持分页 * 是否支持分页
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isEnablePagingBar: boolean = ${ctrl.isEnablePagingBar()?c}; public isEnablePagingBar: boolean = ${ctrl.isEnablePagingBar()?c};
...@@ -242,7 +243,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -242,7 +243,7 @@ import { FormItemModel } from '@/model/form-detail';
* 是否禁用排序 * 是否禁用排序
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isNoSort: boolean = ${ctrl.isNoSort()?c}; public isNoSort: boolean = ${ctrl.isNoSort()?c};
...@@ -250,7 +251,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -250,7 +251,7 @@ import { FormItemModel } from '@/model/form-detail';
* 排序方向 * 排序方向
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public minorSortDir: string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()}</#if>'; public minorSortDir: string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()}</#if>';
...@@ -258,7 +259,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -258,7 +259,7 @@ import { FormItemModel } from '@/model/form-detail';
* 排序字段 * 排序字段
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public minorSortPSDEF: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>'; public minorSortPSDEF: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>';
...@@ -266,7 +267,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -266,7 +267,7 @@ import { FormItemModel } from '@/model/form-detail';
* 分页条数 * 分页条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public limit: number = ${ctrl.getPagingSize()?c}; public limit: number = ${ctrl.getPagingSize()?c};
...@@ -274,7 +275,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -274,7 +275,7 @@ import { FormItemModel } from '@/model/form-detail';
* 是否显示标题 * 是否显示标题
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isHideHeader: boolean = ${ctrl.isHideHeader()?c}; public isHideHeader: boolean = ${ctrl.isHideHeader()?c};
...@@ -282,7 +283,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -282,7 +283,7 @@ import { FormItemModel } from '@/model/form-detail';
* 是否默认选中第一条数据 * 是否默认选中第一条数据
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({ default: false }) public isSelectFirstDefault!: boolean; @Prop({ default: false }) public isSelectFirstDefault!: boolean;
...@@ -290,7 +291,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -290,7 +291,7 @@ import { FormItemModel } from '@/model/form-detail';
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public isSingleSelect?: boolean; @Prop() public isSingleSelect?: boolean;
...@@ -298,7 +299,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -298,7 +299,7 @@ import { FormItemModel } from '@/model/form-detail';
* 选中数据字符串 * 选中数据字符串
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public selectedData?: string; @Prop() public selectedData?: string;
...@@ -307,7 +308,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -307,7 +308,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {*} newVal * @param {*} newVal
* @param {*} oldVal * @param {*} oldVal
* @memberof MainTree * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Watch('selectedData') @Watch('selectedData')
public onValueChange(newVal: any, oldVal: any) { public onValueChange(newVal: any, oldVal: any) {
...@@ -335,7 +336,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -335,7 +336,7 @@ import { FormItemModel } from '@/model/form-detail';
* 2 双击激活 * 2 双击激活
* *
* @type {(number | 0 | 1 | 2)} * @type {(number | 0 | 1 | 2)}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({default: 2}) public gridRowActiveMode!: number; @Prop({default: 2}) public gridRowActiveMode!: number;
...@@ -343,7 +344,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -343,7 +344,7 @@ import { FormItemModel } from '@/model/form-detail';
* 是否开启行编辑 * 是否开启行编辑
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({default: false}) public isOpenEdit!: boolean; @Prop({default: false}) public isOpenEdit!: boolean;
...@@ -351,7 +352,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -351,7 +352,7 @@ import { FormItemModel } from '@/model/form-detail';
* 实际是否开启行编辑 * 实际是否开启行编辑
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public actualIsOpenEdit: boolean = this.isOpenEdit; public actualIsOpenEdit: boolean = this.isOpenEdit;
...@@ -359,7 +360,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -359,7 +360,7 @@ import { FormItemModel } from '@/model/form-detail';
* 总条数 * 总条数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public totalrow: number = 0; public totalrow: number = 0;
...@@ -384,7 +385,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -384,7 +385,7 @@ import { FormItemModel } from '@/model/form-detail';
* 表格聚合行为 * 表格聚合行为
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public aggAction:string ='<#if ctrl.getAggPSDEAction()??>${ctrl.getAggPSDEAction().getCodeName()}</#if>'; public aggAction:string ='<#if ctrl.getAggPSDEAction()??>${ctrl.getAggPSDEAction().getCodeName()}</#if>';
...@@ -392,7 +393,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -392,7 +393,7 @@ import { FormItemModel } from '@/model/form-detail';
* 远程数据 * 远程数据
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public remoteData:any = {}; public remoteData:any = {};
</#if> </#if>
...@@ -411,7 +412,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -411,7 +412,7 @@ import { FormItemModel } from '@/model/form-detail';
* 表格是否显示 * 表格是否显示
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public isDisplay:boolean = <#if ctrl.getAggMode() == "ALL">false<#else>true</#if>; public isDisplay:boolean = <#if ctrl.getAggMode() == "ALL">false<#else>true</#if>;
...@@ -419,7 +420,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -419,7 +420,7 @@ import { FormItemModel } from '@/model/form-detail';
* 部件刷新 * 部件刷新
* *
* @param {any[]} args * @param {any[]} args
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public refresh(args: any[]): void { public refresh(args: any[]): void {
this.load(); this.load();
...@@ -446,7 +447,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -446,7 +447,7 @@ import { FormItemModel } from '@/model/form-detail';
* 所有列成员 * 所有列成员
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public allColumns: any[] = [ public allColumns: any[] = [
<#if ctrl.getAllPSDEGridColumns()??> <#if ctrl.getAllPSDEGridColumns()??>
...@@ -466,7 +467,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -466,7 +467,7 @@ import { FormItemModel } from '@/model/form-detail';
* 表格模型集合 * 表格模型集合
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public gridItemsModel: any[] = []; public gridItemsModel: any[] = [];
...@@ -474,7 +475,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -474,7 +475,7 @@ import { FormItemModel } from '@/model/form-detail';
* 获取表格行模型 * 获取表格行模型
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getGridRowModel(){ public getGridRowModel(){
return { return {
...@@ -488,7 +489,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -488,7 +489,7 @@ import { FormItemModel } from '@/model/form-detail';
* 属性值规则 * 属性值规则
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public rules: any = { public rules: any = {
<#list ctrl.getPSDEGridEditItems() as edititem> <#list ctrl.getPSDEGridEditItems() as edititem>
...@@ -523,7 +524,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -523,7 +524,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param {number} rowIndex 行索引 * @param {number} rowIndex 行索引
* @returns Promise<any> * @returns Promise<any>
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public validate(property:string, data:any, rowIndex:number):Promise<any>{ public validate(property:string, data:any, rowIndex:number):Promise<any>{
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
...@@ -541,7 +542,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -541,7 +542,7 @@ import { FormItemModel } from '@/model/form-detail';
* 校验所有修改过的编辑项 * 校验所有修改过的编辑项
* *
* @returns Promise<any> * @returns Promise<any>
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async validateAll(){ public async validateAll(){
let validateState = true; let validateState = true;
...@@ -563,7 +564,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -563,7 +564,7 @@ import { FormItemModel } from '@/model/form-detail';
* 表格数据加载 * 表格数据加载
* *
* @param {*} [arg={}] * @param {*} [arg={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public load(opt: any = {}, pageReset: boolean = false): void { public load(opt: any = {}, pageReset: boolean = false): void {
if(!this.fetchAction){ if(!this.fetchAction){
...@@ -643,7 +644,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -643,7 +644,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {any[]} datas * @param {any[]} datas
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async remove(datas: any[]): Promise<any> { public async remove(datas: any[]): Promise<any> {
if(!this.removeAction){ if(!this.removeAction){
...@@ -652,7 +653,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -652,7 +653,7 @@ import { FormItemModel } from '@/model/form-detail';
} }
let _datas:any[] = []; let _datas:any[] = [];
datas.forEach((record: any, index: number) => { datas.forEach((record: any, index: number) => {
if (!record.srfkey) { if (Object.is(record.srfuf,"0")) {
this.items.some((val: any, num: number) =>{ this.items.some((val: any, num: number) =>{
if(JSON.stringify(val) == JSON.stringify(record)){ if(JSON.stringify(val) == JSON.stringify(record)){
this.items.splice(num,1); this.items.splice(num,1);
...@@ -749,7 +750,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -749,7 +750,7 @@ import { FormItemModel } from '@/model/form-detail';
* 批量添加 * 批量添加
* *
* @param {*} [arg={}] * @param {*} [arg={}]
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public addBatch(arg: any = {}): void { public addBatch(arg: any = {}): void {
if(!this.fetchAction){ if(!this.fetchAction){
...@@ -780,7 +781,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -780,7 +781,7 @@ import { FormItemModel } from '@/model/form-detail';
* 数据导入 * 数据导入
* *
* @param {*} data * @param {*} data
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public importExcel(data:any ={}):void{ public importExcel(data:any ={}):void{
//导入excel //导入excel
...@@ -824,7 +825,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -824,7 +825,7 @@ import { FormItemModel } from '@/model/form-detail';
* 所有导出列成员 * 所有导出列成员
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public allExportColumns: any[] = [ public allExportColumns: any[] = [
<#if ctrl.getPSDEDataExport().getPSDEDataExportItems()??> <#if ctrl.getPSDEDataExport().getPSDEDataExportItems()??>
...@@ -845,7 +846,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -845,7 +846,7 @@ import { FormItemModel } from '@/model/form-detail';
* 数据导出 * 数据导出
* *
* @param {*} data * @param {*} data
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public exportExcel(data: any = {}): void { public exportExcel(data: any = {}): void {
// 导出Excel // 导出Excel
...@@ -928,7 +929,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -928,7 +929,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param {*} filterVal * @param {*} filterVal
* @param {*} jsonData * @param {*} jsonData
* @returns {[]} * @returns {[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async formatExcelData(filterVal:any, jsonData:any) { public async formatExcelData(filterVal:any, jsonData:any) {
let codelistColumns:Array<any> = [ let codelistColumns:Array<any> = [
...@@ -992,7 +993,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -992,7 +993,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param {any[]} items 代码表数据 * @param {any[]} items 代码表数据
* @param {*} value * @param {*} value
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getCodelistValue(items: any[], value: any, codelist: any,){ public getCodelistValue(items: any[], value: any, codelist: any,){
if(!value){ if(!value){
...@@ -1045,7 +1046,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1045,7 +1046,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param {any[]} items * @param {any[]} items
* @param {*} value * @param {*} value
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getItem(items: any[], value: any, codelist: any): any { public getItem(items: any[], value: any, codelist: any): any {
const arr: Array<any> = items.filter(item => {return item.value == value}); const arr: Array<any> = items.filter(item => {return item.value == value});
...@@ -1062,7 +1063,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1062,7 +1063,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* 生命周期 * 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public created(): void { public created(): void {
this.afterCreated(); this.afterCreated();
...@@ -1071,7 +1072,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1071,7 +1072,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterCreated(){ public afterCreated(){
this.setColState(); this.setColState();
...@@ -1096,7 +1097,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1096,7 +1097,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
...@@ -1105,7 +1106,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1105,7 +1106,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
...@@ -1120,7 +1121,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1120,7 +1121,7 @@ import { FormItemModel } from '@/model/form-detail';
* 获取选中行胡数据 * 获取选中行胡数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getSelection(): any[] { public getSelection(): any[] {
return this.selections; return this.selections;
...@@ -1131,7 +1132,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1131,7 +1132,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {*} $event * @param {*} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public rowDBLClick($event: any): void { public rowDBLClick($event: any): void {
if (!$event || this.actualIsOpenEdit || Object.is(this.gridRowActiveMode,0)) { if (!$event || this.actualIsOpenEdit || Object.is(this.gridRowActiveMode,0)) {
...@@ -1155,7 +1156,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1155,7 +1156,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {*} $event * @param {*} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public select($event: any): void { public select($event: any): void {
if (!$event) { if (!$event) {
...@@ -1170,7 +1171,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1170,7 +1171,7 @@ import { FormItemModel } from '@/model/form-detail';
* 复选框数据全部选中 * 复选框数据全部选中
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public selectAll($event: any): void { public selectAll($event: any): void {
if (!$event) { if (!$event) {
...@@ -1187,7 +1188,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1187,7 +1188,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {*} $event * @param {*} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public rowClick($event: any, ifAlways: boolean = false): void { public rowClick($event: any, ifAlways: boolean = false): void {
if (!ifAlways && (!$event || this.actualIsOpenEdit)) { if (!ifAlways && (!$event || this.actualIsOpenEdit)) {
...@@ -1229,7 +1230,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1229,7 +1230,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {*} $event * @param {*} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public pageOnChange($event: any): void { public pageOnChange($event: any): void {
if (!$event) { if (!$event) {
...@@ -1247,7 +1248,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1247,7 +1248,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {*} $event * @param {*} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onPageSizeChange($event: any): void { public onPageSizeChange($event: any): void {
if (!$event) { if (!$event) {
...@@ -1265,7 +1266,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1265,7 +1266,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* 分页刷新 * 分页刷新
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public pageRefresh(): void { public pageRefresh(): void {
this.load({}); this.load({});
...@@ -1275,7 +1276,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1275,7 +1276,7 @@ import { FormItemModel } from '@/model/form-detail';
* 排序变化 * 排序变化
* *
* @param {{ column: any, prop: any, order: any }} { column, prop, order } * @param {{ column: any, prop: any, order: any }} { column, prop, order }
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onSortChange({ column, prop, order }: { column: any, prop: any, order: any }): void { public onSortChange({ column, prop, order }: { column: any, prop: any, order: any }): void {
const dir = Object.is(order, 'ascending') ? 'asc' : Object.is(order, 'descending') ? 'desc' : ''; const dir = Object.is(order, 'ascending') ? 'asc' : Object.is(order, 'descending') ? 'desc' : '';
...@@ -1292,7 +1293,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1292,7 +1293,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {{ row: any, rowIndex: any }} { row, rowIndex } * @param {{ row: any, rowIndex: any }} { row, rowIndex }
* @returns {string} * @returns {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onRowClassName({ row, rowIndex }: { row: any, rowIndex: any }): string { public onRowClassName({ row, rowIndex }: { row: any, rowIndex: any }): string {
const index = this.selections.findIndex((select: any) => Object.is(select.srfkey, row.srfkey)); const index = this.selections.findIndex((select: any) => Object.is(select.srfkey, row.srfkey));
...@@ -1304,7 +1305,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1304,7 +1305,7 @@ import { FormItemModel } from '@/model/form-detail';
* 合计行绘制 * 合计行绘制
* *
* @param {any} param * @param {any} param
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getSummaries(param:any){ public getSummaries(param:any){
<#if ctrl.getAggMode() == "PAGE"> <#if ctrl.getAggMode() == "PAGE">
...@@ -1430,7 +1431,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1430,7 +1431,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* 远程获取合计行数据 * 远程获取合计行数据
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getAggData(){ public getAggData(){
this.service.getAggData(this.aggAction,JSON.parse(JSON.stringify(this.context)),this.showBusyIndicator).then((response:any) =>{ this.service.getAggData(this.aggAction,JSON.parse(JSON.stringify(this.context)),this.showBusyIndicator).then((response:any) =>{
...@@ -1459,7 +1460,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1459,7 +1460,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param {*} row * @param {*} row
* @param {*} tag * @param {*} tag
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public uiAction(row: any, tag: any, $event: any) { public uiAction(row: any, tag: any, $event: any) {
// this.rowClick(row, true); // this.rowClick(row, true);
...@@ -1479,7 +1480,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1479,7 +1480,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* 设置列状态 * 设置列状态
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public setColState() { public setColState() {
const _data: any = localStorage.getItem('${ctrl.getPSAppDataEntity().getName()?lower_case}_${ctrl.getCodeName()?lower_case}_${ctrl.name}'); const _data: any = localStorage.getItem('${ctrl.getPSAppDataEntity().getName()?lower_case}_${ctrl.getCodeName()?lower_case}_${ctrl.name}');
...@@ -1497,7 +1498,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1497,7 +1498,7 @@ import { FormItemModel } from '@/model/form-detail';
/** /**
* 列变化 * 列变化
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onColChange() { public onColChange() {
localStorage.setItem('${ctrl.getPSAppDataEntity().getName()?lower_case}_${ctrl.getCodeName()?lower_case}_${ctrl.name}', JSON.stringify(this.allColumns)); localStorage.setItem('${ctrl.getPSAppDataEntity().getName()?lower_case}_${ctrl.getCodeName()?lower_case}_${ctrl.name}', JSON.stringify(this.allColumns));
...@@ -1508,7 +1509,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1508,7 +1509,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {string} name * @param {string} name
* @returns {boolean} * @returns {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getColumnState(name: string): boolean { public getColumnState(name: string): boolean {
let column = this.allColumns.find((col: any) => let column = this.allColumns.find((col: any) =>
...@@ -1522,7 +1523,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1522,7 +1523,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @readonly * @readonly
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
get adaptiveState(): boolean { get adaptiveState(): boolean {
return !this.allColumns.find((column: any) => column.show && Object.is(column.util, 'STAR')); return !this.allColumns.find((column: any) => column.show && Object.is(column.util, 'STAR'));
...@@ -1533,7 +1534,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1533,7 +1534,7 @@ import { FormItemModel } from '@/model/form-detail';
* *
* @param {*} $event * @param {*} $event
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async save(args: any[], params?: any, $event?: any, xData?: any){ public async save(args: any[], params?: any, $event?: any, xData?: any){
let _this = this; let _this = this;
...@@ -1586,13 +1587,12 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1586,13 +1587,12 @@ import { FormItemModel } from '@/model/form-detail';
return successItems; return successItems;
} }
<#if ctrl.isEnableRowEdit()>
/** /**
* 新建行 * 新建行
* *
* @param {*} $event * @param {*} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public newRow(args: any[], params?: any, $event?: any, xData?: any): void { public newRow(args: any[], params?: any, $event?: any, xData?: any): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
...@@ -1631,7 +1631,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1631,7 +1631,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param row 行数据 * @param row 行数据
* @param {{ name: string, value: any }} $event * @param {{ name: string, value: any }} $event
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public onGridItemValueChange(row: any,$event: { name: string, value: any },rowIndex: number): void { public onGridItemValueChange(row: any,$event: { name: string, value: any },rowIndex: number): void {
if (!$event) { if (!$event) {
...@@ -1652,7 +1652,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1652,7 +1652,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param property 列编辑项名 * @param property 列编辑项名
* @param row 列编辑项值 * @param row 列编辑项值
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public gridEditItemChange(row: any, property: string, value: any, rowIndex: number){ public gridEditItemChange(row: any, property: string, value: any, rowIndex: number){
row.rowDataState = row.rowDataState ? row.rowDataState : "update" ; row.rowDataState = row.rowDataState ? row.rowDataState : "update" ;
...@@ -1678,7 +1678,7 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1678,7 +1678,7 @@ import { FormItemModel } from '@/model/form-detail';
* @param {string[]} updateDetails 更新项 * @param {string[]} updateDetails 更新项
* @param {boolean} [showloading] 是否显示加载状态 * @param {boolean} [showloading] 是否显示加载状态
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public updateGridEditItem(mode: string, data: any = {}, updateDetails: string[], showloading?: boolean): void { public updateGridEditItem(mode: string, data: any = {}, updateDetails: string[], showloading?: boolean): void {
if (!mode || (mode && Object.is(mode, ''))) { if (!mode || (mode && Object.is(mode, ''))) {
...@@ -1712,14 +1712,13 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1712,14 +1712,13 @@ import { FormItemModel } from '@/model/form-detail';
} }
}); });
} }
</#if>
/** /**
* 获取对应行class * 获取对应行class
* *
* @param {*} $args row 行数据,rowIndex 行索引 * @param {*} $args row 行数据,rowIndex 行索引
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getRowClassName(args:{row: any,rowIndex: number}){ public getRowClassName(args:{row: any,rowIndex: number}){
let isSelected = this.selections.some((item:any)=>{ let isSelected = this.selections.some((item:any)=>{
...@@ -1728,40 +1727,63 @@ import { FormItemModel } from '@/model/form-detail'; ...@@ -1728,40 +1727,63 @@ import { FormItemModel } from '@/model/form-detail';
return isSelected ? "grid-selected-row" : ""; return isSelected ? "grid-selected-row" : "";
} }
/**
* 获取对应列class
*
* @param {*} $args row 行数据,column 列数据,rowIndex 行索引,列索引
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public getCellClassName(args:{row: any, column: any, rowIndex: number, columnIndex:number}){
let hasRowEdit:any = {
<#list ctrl.getPSDEGridColumns() as column>
<#if ctrl.isEnableRowEdit() && column.isEnableRowEdit()>
'${column.getName()?lower_case}':true,
<#else>
'${column.getName()?lower_case}':false,
</#if>
</#list>
}
return ( hasRowEdit[args.column.property] && this.actualIsOpenEdit ) ? "edit-cell" : "info-cell";
}
/** /**
* 新建默认值 * 新建默认值
* @param {*} row 行数据 * @param {*} row 行数据
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public createDefault(row: any){ public createDefault(row: any){
<#list ctrl.getPSDEGridEditItems() as editItem><#t> <#list ctrl.getPSDEGridEditItems() as editItem><#t>
<#if editItem.getCreateDV?? && editItem.getCreateDV()??><#t> <#if editItem.getCreateDV?? && editItem.getCreateDV()??><#t>
<#if !(editItem.getCreateDV() == '')><#t> <#if !(editItem.getCreateDV() == '') || editItem.getCreateDVT() == 'CURTIME'><#t>
if (row.hasOwnProperty('${editItem.getCodeName()?lower_case}')) { if (row.hasOwnProperty('${editItem.getCodeName()?lower_case}')) {
<#-- 网页请求 --> <#-- 网页请求 -->
<#if editItem.getCreateDVT() == 'CONTEXT'> <#if editItem.getCreateDVT() == 'CONTEXT'>
row['${editItem.getCodeName()?lower_case}'] = this.viewparams['${editItem.getCreateDV()}']; row['${editItem.getCodeName()?lower_case}'] = this.viewparams['${editItem.getCreateDV()}'];
<#-- 用户全局对象 --> <#-- 用户全局对象 -->
<#elseif editItem.getCreateDVT() == 'SESSION'> <#elseif editItem.getCreateDVT() == 'SESSION'>
row['${editItem.getCodeName()?lower_case}'] = this.context['${editItem.getCreateDV()}']; row['${editItem.getCodeName()?lower_case}'] = this.context['${editItem.getCreateDV()}'];
<#-- 当前应用数据 --> <#-- 当前应用数据 -->
<#elseif editItem.getCreateDVT() == 'APPDATA'> <#elseif editItem.getCreateDVT() == 'APPDATA'>
row['${editItem.getCodeName()?lower_case}'] = this.context['${editItem.getCreateDV()}']; row['${editItem.getCodeName()?lower_case}'] = this.context['${editItem.getCreateDV()}'];
<#-- 当前操作用户(名称) --> <#-- 当前操作用户(名称) -->
<#elseif editItem.getCreateDVT() == 'OPERATORNAME'> <#elseif editItem.getCreateDVT() == 'OPERATORNAME'>
row['${editItem.getCodeName()?lower_case}'] = this.context['srfusername']; row['${editItem.getCodeName()?lower_case}'] = this.context['srfusername'];
<#-- 当前操作用户(编号) --> <#-- 当前操作用户(编号) -->
<#elseif editItem.getCreateDVT() == 'OPERATOR'> <#elseif editItem.getCreateDVT() == 'OPERATOR'>
row['${editItem.getCodeName()?lower_case}'] = this.context['srfuserid']; row['${editItem.getCodeName()?lower_case}'] = this.context['srfuserid'];
<#else> <#-- 当前时间 -->
<#-- 默认值 --> <#elseif editItem.getCreateDVT() == 'CURTIME'>
<#assign datatype=srfjavatype(editItem.getPSAppDEField().getStdDataType())> row['${editItem.getCodeName()?lower_case}'] = this.$util.dateFormat(new Date());
<#else>
<#-- 默认值 -->
<#assign datatype=srfjavatype(editItem.getPSAppDEField().getStdDataType())>
row['${editItem.getCodeName()?lower_case}'] = <#if datatype=='BigInteger' || datatype=='Integer' || datatype=='Double' || datatype=='Decimal' || datatype=='Float' || datatype=='BigDecimal'>${editItem.getCreateDV()}<#else>'${editItem.getCreateDV()}'</#if>; row['${editItem.getCodeName()?lower_case}'] = <#if datatype=='BigInteger' || datatype=='Integer' || datatype=='Double' || datatype=='Decimal' || datatype=='Float' || datatype=='BigDecimal'>${editItem.getCreateDV()}<#else>'${editItem.getCreateDV()}'</#if>;
</#if> </#if>
} }
</#if> </#if>
</#if> </#if>
</#list> </#list>
} }
<#ibizinclude> <#ibizinclude>
../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl ../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl
......
...@@ -46,6 +46,13 @@ ...@@ -46,6 +46,13 @@
margin-bottom: unset !important; margin-bottom: unset !important;
} }
} }
.el-table__body .edit-cell{
padding:0;
.app-form-item{
margin-top: 20px;
margin-bottom: 20px;
}
}
} }
.grid-pagination { .grid-pagination {
height: 36px; height: 36px;
......
...@@ -312,7 +312,6 @@ import ${srfclassname('${aggAppDataEntity.getCodeName()}')}Service from '@/servi ...@@ -312,7 +312,6 @@ import ${srfclassname('${aggAppDataEntity.getCodeName()}')}Service from '@/servi
response.data.${appde.getKeyPSAppDEField().getCodeName()?lower_case} = Util.createUUID(); response.data.${appde.getKeyPSAppDEField().getCodeName()?lower_case} = Util.createUUID();
} }
this.handleResponse(action, response, true); this.handleResponse(action, response, true);
this.mergeDefaults(response);
resolve(response); resolve(response);
}).catch(response => { }).catch(response => {
reject(response); reject(response);
...@@ -320,23 +319,6 @@ import ${srfclassname('${aggAppDataEntity.getCodeName()}')}Service from '@/servi ...@@ -320,23 +319,6 @@ import ${srfclassname('${aggAppDataEntity.getCodeName()}')}Service from '@/servi
}); });
} }
/**
* 合并配置的默认值
* @param {*}
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
public mergeDefaults(response:any = {}){
if(response.data){
<#list ctrl.getPSDEGridEditItems() as edititem><#t>
<#if edititem.getCreateDV?? && edititem.getCreateDV()??><#t>
<#if !(edititem.getCreateDV() == '')><#t>
Object.assign(response.data,{'${edititem.getCodeName()?lower_case}':'${edititem.getCreateDV()}'});
</#if>
</#if>
</#list>
}
}
<#if ctrl.getAggMode() == "ALL" && ctrl.getAggPSAppDataEntity()??> <#if ctrl.getAggMode() == "ALL" && ctrl.getAggPSAppDataEntity()??>
<#assign aggAppDataEntity = ctrl.getAggPSAppDataEntity() > <#assign aggAppDataEntity = ctrl.getAggPSAppDataEntity() >
/** /**
......
<#-- 不带数据信息标题 --> <#-- 不带数据信息标题 -->
<#if view.isShowCaptionBar()> <#if view.isShowCaptionBar()>
<p slot='title'> <div slot='title' class="header-container">
<#if view.getPSSysImage()??> <#if view.getPSSysImage()??>
<#assign viewimg = view.getPSSysImage()/> <#assign viewimg = view.getPSSysImage()/>
<#if viewimg.getImagePath() != ""> <#if viewimg.getImagePath() != "">
...@@ -10,5 +10,5 @@ ...@@ -10,5 +10,5 @@
</#if> </#if>
</#if> </#if>
<span class='caption-info'>{{$t(model.srfTitle)}}</span> <span class='caption-info'>{{$t(model.srfTitle)}}</span>
</p> </div>
</#if> </#if>
\ No newline at end of file
<#-- 带数据信息标题 --> <#-- 带数据信息标题 -->
<#if view.isShowCaptionBar() || view.hasPSControl('toolbar')> <#if view.isShowCaptionBar() || view.hasPSControl('toolbar')>
<p slot='title'> <div slot='title' class="header-container">
<#if view.isShowCaptionBar()> <#if view.isShowCaptionBar()>
<#if view.getPSSysImage()??> <#if view.getPSSysImage()??>
<#assign viewimg = view.getPSSysImage()/> <#assign viewimg = view.getPSSysImage()/>
<#if viewimg.getImagePath() != ''> <#if viewimg.getImagePath() != ''>
...@@ -11,6 +11,17 @@ ...@@ -11,6 +11,17 @@
</#if> </#if>
</#if> </#if>
<span class='caption-info'>{{$t(model.srfTitle)}}</span> <span class='caption-info'>{{$t(model.srfTitle)}}</span>
</#if> </#if>
</p> <#if view.hasPSControl('toolbar')>
<#if selfToolbarRender??>
<@ibizindent blank=4>
${selfToolbarRender}<#t>
</@ibizindent>
<#else>
<@ibizindent blank=4>
${P.getCtrlCode('toolbar', 'CONTROL.html').code}<#t>
</@ibizindent>
</#if>
</#if>
</div>
</#if> </#if>
\ No newline at end of file
...@@ -5,4 +5,4 @@ ${P.getCtrlCode('tabexppanel', 'CONTROL.html').code} ...@@ -5,4 +5,4 @@ ${P.getCtrlCode('tabexppanel', 'CONTROL.html').code}
</#assign> </#assign>
<#ibizinclude> <#ibizinclude>
../@MACRO/VIEW_LAYOUT_BASE.ftl ../@MACRO/VIEW_LAYOUT_BASE.ftl
</#ibizinclude> </#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/DEFAULT.less.ftl
</#ibizinclude>
.detabsearchview{
.toolbars-container{
margin-bottom: 6px;
overflow:hidden;
.tab-panel-group{
float: right;
.el-radio-button__inner{
color: #303133;
padding: 12px;
min-width: 42px;
min-height: 42px;
i{
font-size: 14px;
}
}
.el-radio-button.is-active .el-radio-button__inner{
background-color: #c5c8ce;
border-color: #c5c8ce;
box-shadow: -1px 0 0 0 #c5c8ce;
}
}
}
.tabexppanel {
> .ivu-tabs-bar{
display: none;
}
> .ivu-tabs-content{
border-top: 1px solid #dcdee2;
height: 100%;
}
}
}
\ No newline at end of file
<div class='view-container ${view.getViewType()?lower_case} ${srffilepath2(view.getCodeName())}<#if view.getPSSysCss?? && view.getPSSysCss()??> ${view.getPSSysCss().getCssName()}</#if>'>
<app-studioaction :viewTitle="$t(model.srfTitle)" viewName="${view.getCodeName()?lower_case}"></app-studioaction>
<card class='view-card<#if !view.isShowCaptionBar()> view-no-caption</#if> <#if !view.hasPSControl('toolbar')> view-no-toolbar</#if>' :dis-hover="true" :bordered="false">
<#ibizinclude>
../@MACRO/VIEW_CAPTION_DATAINFO.vue.ftl
</#ibizinclude>
<div class="toolbars-container" style=''>
<#if view.hasPSControl('tabexppanel')>
<#assign tabexppanel = view.getPSControl('tabexppanel') />
<el-radio-group v-model="tabValue" class="tab-panel-group">
<#if tabexppanel.getPSControls?? && tabexppanel.getPSControls()??>
<#list tabexppanel.getPSControls() as tabviewpanel>
<el-radio-button label="${tabviewpanel.name}">
<tooltip :transfer="true" :max-width="600">
<#if tabviewpanel.getPSSysImage()??>
<#assign sysimage = tabviewpanel.getPSSysImage()/>
<#if sysimage.getImagePath() == "">
<i class='${sysimage.getCssClass()}'></i>
<#else>
<img src='${sysimage.getImagePath()}'>
</#if>
<#else>
<i class='fa fa-th-large'></i>
</#if>
<div slot='content'>${tabviewpanel.getCaption()}</div>
</tooltip>
</el-radio-button>
</#list>
</#if>
</el-radio-group>
</#if>
</div>
<div class='content-container'>
<#if view.hasPSControl('tabexppanel')>
${P.getCtrlCode('tabexppanel', 'CONTROL.html').code}
</#if>
</div>
</card>
</div>
\ No newline at end of file
CTRLTYPE=VIEWLAYOUTPANEL#APPDETABSEARCHVIEW
\ No newline at end of file
...@@ -17,4 +17,28 @@ ...@@ -17,4 +17,28 @@
flex-direction: column; flex-direction: column;
} }
} }
}
.dewfdynaexpgridview{
.el-tree {
padding-right: 10px;
}
.el-tree-node__content {
height: 40px;
border-left: solid transparent;
}
.el-tree-node__label {
font-size: 15px;
font-family: "Microsoft YaHei";
}
.el-tree-node {
margin-top: 10px;
}
.el-tree-node:nth-child(1) {
margin-top: 0px;
}
.el-tree--highlight-current .el-tree-node.is-current>.el-tree-node__content {
background-color: #f0f7ff;
border-color: #1890ff6e;
}
} }
\ No newline at end of file
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<card class='view-card<#if !view.isShowCaptionBar()> view-no-caption</#if> <#if !view.hasPSControl('toolbar')> view-no-toolbar</#if>' :bordered="false" :dis-hover="true" > <card class='view-card<#if !view.isShowCaptionBar()> view-no-caption</#if> <#if !view.hasPSControl('toolbar')> view-no-toolbar</#if>' :bordered="false" :dis-hover="true" >
<#ibizinclude> <#ibizinclude>
../@MACRO/VIEW_CAPTION_DATAINFO.vue.ftl ../@MACRO/VIEW_CAPTION.vue.ftl
</#ibizinclude> </#ibizinclude>
<div class='content-container'> <div class='content-container'>
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
<div style="margin-bottom:6px;"> <div style="margin-bottom:6px;">
<#if view.isEnableQuickGroup()> <#if view.isEnableQuickGroup()>
<div class="quick-group-container"> <div class="quick-group-container">
<app-quick-group :items="quickGroupModel" <#if appCounter??>:counterService="${srfclassname('${appCounter.getCodeName()}')}counterservice"</#if> @valuechange="qucikGroupValueChange"></app-quick-group> <app-quick-group :items="quickGroupModel" <#if appCounter??>:counterService="${srfclassname('${appCounter.getCodeName()}')}counterservice"</#if> @valuechange="quickGroupValueChange"></app-quick-group>
</div> </div>
</#if> </#if>
<#if view.getQuickPSDESearchForm()??> <#if view.getQuickPSDESearchForm()??>
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
<div style="margin-bottom:6px;"> <div style="margin-bottom:6px;">
<#if view.isEnableQuickGroup()> <#if view.isEnableQuickGroup()>
<div class="quick-group-container"> <div class="quick-group-container">
<app-quick-group :items="quickGroupModel" <#if appCounter??>:counterService="${srfclassname('${appCounter.getCodeName()}')}counterservice"</#if> @valuechange="qucikGroupValueChange"></app-quick-group> <app-quick-group :items="quickGroupModel" <#if appCounter??>:counterService="${srfclassname('${appCounter.getCodeName()}')}counterservice"</#if> @valuechange="quickGroupValueChange"></app-quick-group>
</div> </div>
</#if> </#if>
<#if view.getQuickPSDESearchForm()??> <#if view.getQuickPSDESearchForm()??>
......
...@@ -7,4 +7,4 @@ ...@@ -7,4 +7,4 @@
</#assign> </#assign>
<#ibizinclude> <#ibizinclude>
../@MACRO/VIEW_LAYOUT_BASE.ftl ../@MACRO/VIEW_LAYOUT_BASE.ftl
</#ibizinclude> </#ibizinclude>
\ No newline at end of file
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
<div style="margin-bottom:6px;"> <div style="margin-bottom:6px;">
<#if view.isEnableQuickGroup()> <#if view.isEnableQuickGroup()>
<div class="quick-group-container"> <div class="quick-group-container">
<app-quick-group :items="quickGroupModel" <#if appCounter??>:counterService="${srfclassname('${appCounter.getCodeName()}')}counterservice"</#if> @valuechange="qucikGroupValueChange"></app-quick-group> <app-quick-group :items="quickGroupModel" <#if appCounter??>:counterService="${srfclassname('${appCounter.getCodeName()}')}counterservice"</#if> @valuechange="quickGroupValueChange"></app-quick-group>
</div> </div>
</#if> </#if>
<#if view.getQuickPSDESearchForm()??> <#if view.getQuickPSDESearchForm()??>
......
...@@ -24,6 +24,11 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -24,6 +24,11 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
<#ibizinclude> <#ibizinclude>
../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl ../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl
</#ibizinclude> </#ibizinclude>
<#ibizinclude>
../@MACRO/FUNC/MACRO.ftl
</#ibizinclude>
/** /**
* 视图打开模式 * 视图打开模式
* *
...@@ -38,15 +43,15 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -38,15 +43,15 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
* 选中数据字符串 * 选中数据字符串
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() protected selectedData?: string; @Prop() public selectedData?: string;
/** /**
* 获取多项数据 * 获取多项数据
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getDatas(): any[] { public getDatas(): any[] {
return []; return [];
...@@ -56,7 +61,7 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -56,7 +61,7 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
* 获取单项树 * 获取单项树
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public getData(): any { public getData(): any {
return {}; return {};
...@@ -66,20 +71,36 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -66,20 +71,36 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
* 视图名称 * 视图名称
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected view: any = { public view: any = {
viewname: '<#if ctrl.getPSAppDEView()??>${srffilepath2(ctrl.getPSAppDEView().getCodeName())}</#if>', viewname: '<#if ctrl.getPSAppDEView()??>${srffilepath2(ctrl.getPSAppDEView().getCodeName())}</#if>',
data: {}, data: {},
} }
/**
* 局部上下文
*
* @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public localContext: any = <#if ctrl.getPSNavigateContexts?? && ctrl.getPSNavigateContexts()??><@getNavigateContext ctrl /><#else>null</#if>;
/**
* 局部视图参数
*
* @type {*}
* @memberof PickupViewpickupviewpanel
*/
public localViewParam: any = <#if ctrl.getPSNavigateParams?? && ctrl.getPSNavigateParams()??><@getNavigateParams ctrl /><#else>null</#if>;
/** /**
* 视图数据 * 视图数据
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected viewdata: string = JSON.stringify(this.context); public viewdata: string = JSON.stringify(this.context);
/** /**
* 视图参数 * 视图参数
...@@ -87,39 +108,39 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -87,39 +108,39 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
* @type {*} * @type {*}
* @memberof PickupViewpickupviewpanel * @memberof PickupViewpickupviewpanel
*/ */
protected viewparam: string = JSON.stringify(this.viewparams); public viewparam: string = JSON.stringify(this.viewparams);
/** /**
* 是否显示按钮 * 是否显示按钮
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop({default: true}) protected isShowButton!: boolean; @Prop({default: true}) public isShowButton!: boolean;
/** /**
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() protected isSingleSelect?: boolean; @Prop() public isSingleSelect?: boolean;
/** /**
* 初始化完成 * 初始化完成
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected inited: boolean = false; public inited: boolean = false;
/** /**
* 视图数据变化 * 视图数据变化
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected onViewDatasChange($event: any): void { public onViewDatasChange($event: any): void {
if($event.length>0){ if($event.length>0){
$event.forEach((item:any,index:any) => { $event.forEach((item:any,index:any) => {
let srfmajortext = item['${ctrl.getPSAppDataEntity().getMajorPSAppDEField().getCodeName()?lower_case}']; let srfmajortext = item['${ctrl.getPSAppDataEntity().getMajorPSAppDEField().getCodeName()?lower_case}'];
...@@ -135,9 +156,9 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -135,9 +156,9 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
* 视图数据被激活 * 视图数据被激活
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected viewDatasActivated($event: any): void { public viewDatasActivated($event: any): void {
this.$emit('activated', $event); this.$emit('activated', $event);
} }
...@@ -145,27 +166,28 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -145,27 +166,28 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
* 视图加载完成 * 视图加载完成
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected onViewLoad($event: any): void { public onViewLoad($event: any): void {
this.$emit('load', $event); this.$emit('load', $event);
} }
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected created() { public created() {
this.afterCreated(); this.afterCreated();
} }
/** /**
* 执行created后的逻辑 * 执行created后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected afterCreated(){ public afterCreated(){
this.initNavParam();
if (this.viewState) { if (this.viewState) {
this.viewStateEvent = this.viewState.subscribe(({ tag, action, data }) => { this.viewStateEvent = this.viewState.subscribe(({ tag, action, data }) => {
if (!Object.is(tag, this.name)) { if (!Object.is(tag, this.name)) {
...@@ -180,21 +202,40 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code ...@@ -180,21 +202,40 @@ import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.code
} }
} }
/**
* 初始化导航参数
*
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public initNavParam(){
if(this.localContext && Object.keys(this.localContext).length >0){
let _context:any = this.$util.computedNavData({},this.context,this.viewparams,this.localContext);
Object.assign(this.context,_context);
}
if(this.localViewParam && Object.keys(this.localViewParam).length >0){
let _param:any = this.$util.computedNavData({},this.context,this.viewparams,this.localViewParam);
Object.assign(this.viewparams,_param);
}
this.viewdata = JSON.stringify(this.context);
this.viewparam = JSON.stringify(this.viewparams);
}
/** /**
* vue 生命周期 * vue 生命周期
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected destroyed() { public destroyed() {
this.afterDestroy(); this.afterDestroy();
} }
/** /**
* 执行destroyed后的逻辑 * 执行destroyed后的逻辑
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
protected afterDestroy() { public afterDestroy() {
if (this.viewStateEvent) { if (this.viewStateEvent) {
this.viewStateEvent.unsubscribe(); this.viewStateEvent.unsubscribe();
} }
......
<#-- content -->
<#assign content> <#assign content>
:isSingleSelect="isSingleSelect" :isSingleSelect="isSingleSelect"
:selectedData="selectedData" :selectedData="selectedData"
......
<#if ctrl.getPortletType() != 'CONTAINER'> <#if ctrl.getPortletType() != 'CONTAINER'>
<#ibizinclude>../@MACRO/CONTROL/LANGBASE.vue.ftl</#ibizinclude>
<#macro renderUiaction>
<#if ctrl.getPSUIActionGroup?? && ctrl.getPSUIActionGroup()?? && ctrl.getPSUIActionGroup().getPSUIActionGroupDetails()??>
<#assign UIActionDetails=ctrl.getPSUIActionGroup().getPSUIActionGroupDetails() />
<span class="portlet-action">
<#list UIActionDetails as uiactiondetail>
<#if !uiactiondetail.isShowCaption()>
<tooltip :transfer="true" :max-width="600">
</#if>
<a @click="uiAction('${uiactiondetail.getName()?lower_case}', $event)">
<#if uiactiondetail.getPSUIAction()??>
<#if uiactiondetail.isShowIcon()>
<#if uiactiondetail.getPSUIAction().getPSSysImage()??>
<#assign viewimg=uiactiondetail.getPSUIAction().getPSSysImage()/>
<#if viewimg.getCssClass() != ''>
<i class="${viewimg.getCssClass()}" />
<#else>
<img src="${viewimg.getImagePath()}" />
</#if>
</#if>
</#if>
<#-- <#if uiactiondetail.isShowCaption()><span><#if langbase??>{{$t('${langbase}.uiactions.${uiactiondetail.getPSUIAction().getUIActionTag()?lower_case}')}}<#else>${uiactiondetail.getPSUIAction().getCaption()}</#if></span></#if> -->
<#if uiactiondetail.isShowCaption()>
<span>${uiactiondetail.getPSUIAction().getCaption()}</span>
</#if>
</#if>
</a>
<#if !uiactiondetail.isShowCaption()>
<div slot='content'>${uiactiondetail.getPSUIAction().getCaption()}</div>
</tooltip>
</#if>
</#list>
</span>
</#if>
</#macro>
<template> <template>
<div class='portlet ${srffilepath2(ctrl.getCodeName())} <#if ctrl.getPSSysCss()??> ${ctrl.getPSSysCss().getCssName()}</#if>' :style="{<#if (ctrl.getHeight?? && ctrl.getHeight() gt 0)>'height': isAdaptiveSize ? 'calc(100% - 16px)' : (height > 0 ? height+'px' :'${ctrl.getHeight()?c}px'),</#if><#if (ctrl.getWidth?? && ctrl.getWidth() gt 0)>'width': isAdaptiveSize ? 'calc(100% - 16px)' : (width ? width+'px' :'${ctrl.getWidth()?c}px')</#if>}"> <div class='portlet ${srffilepath2(ctrl.getCodeName())} <#if ctrl.getPSSysCss()??> ${ctrl.getPSSysCss().getCssName()}</#if>' :style="{<#if (ctrl.getHeight?? && ctrl.getHeight() gt 0)>'height': isAdaptiveSize ? 'calc(100% - 16px)' : getHeight,</#if><#if (ctrl.getWidth?? && ctrl.getWidth() gt 0)>'width': isAdaptiveSize ? 'calc(100% - 16px)' : (width ? width+'px' :'${ctrl.getWidth()?c}px')</#if>}">
<#if ctrl.getPortletType?? && ctrl.getPortletType()??><#t> <#if ctrl.getPortletType?? && ctrl.getPortletType()??><#t>
<#-- 视图 --> <#-- 视图 -->
<#if ctrl.getPortletType() == 'VIEW' && ctrl.getPortletPSAppView?? && ctrl.getPortletPSAppView()??><#t> <#if ctrl.getPortletType() == 'VIEW' && ctrl.getPortletPSAppView?? && ctrl.getPortletPSAppView()??><#t>
...@@ -10,14 +45,10 @@ ...@@ -10,14 +45,10 @@
<#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if> <#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if>
${ctrl.getTitle()} ${ctrl.getTitle()}
</span> </span>
<#if ctrl.getPSUIActionGroup?? && ctrl.getPSUIActionGroup()?? && ctrl.getPSUIActionGroup().getPSUIActionGroupDetails()??> <#assign render_uiaction><@renderUiaction /></#assign>
<#assign UIActionDetails=ctrl.getPSUIActionGroup().getPSUIActionGroupDetails() /> <@ibizindent blank=12>
<span class="portlet-action"> ${render_uiaction}<#t>
<#list UIActionDetails as uiactiondetail> </@ibizindent>
<a @click="uiAction('${uiactiondetail.getName()?lower_case}', $event)"><#if uiactiondetail.getPSUIAction()??>${uiactiondetail.getPSUIAction().getCaption()}</#if></a>
</#list>
</span>
</#if>
</p> </p>
</#if> </#if>
<div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>"> <div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>">
...@@ -32,14 +63,10 @@ ...@@ -32,14 +63,10 @@
<#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if> <#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if>
${ctrl.getTitle()} ${ctrl.getTitle()}
</span> </span>
<#if ctrl.getPSUIActionGroup?? && ctrl.getPSUIActionGroup()?? && ctrl.getPSUIActionGroup().getPSUIActionGroupDetails()??> <#assign render_uiaction><@renderUiaction /></#assign>
<#assign UIActionDetails=ctrl.getPSUIActionGroup().getPSUIActionGroupDetails() /> <@ibizindent blank=12>
<span class="portlet-action"> ${render_uiaction}<#t>
<#list UIActionDetails as uiactiondetail> </@ibizindent>
<a @click="uiAction('${uiactiondetail.getName()?lower_case}', $event)"><#if uiactiondetail.getPSUIAction()??>${uiactiondetail.getPSUIAction().getCaption()}</#if></a>
</#list>
</span>
</#if>
</p> </p>
</#if> </#if>
<div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>"> <div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>">
...@@ -56,14 +83,10 @@ ...@@ -56,14 +83,10 @@
<#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if> <#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if>
${ctrl.getTitle()} ${ctrl.getTitle()}
</span> </span>
<#if ctrl.getPSUIActionGroup?? && ctrl.getPSUIActionGroup()?? && ctrl.getPSUIActionGroup().getPSUIActionGroupDetails()??> <#assign render_uiaction><@renderUiaction /></#assign>
<#assign UIActionDetails=ctrl.getPSUIActionGroup().getPSUIActionGroupDetails() /> <@ibizindent blank=12>
<span class="portlet-action"> ${render_uiaction}<#t>
<#list UIActionDetails as uiactiondetail> </@ibizindent>
<a @click="uiAction('${uiactiondetail.getName()?lower_case}', $event)"><#if uiactiondetail.getPSUIAction()??>${uiactiondetail.getPSUIAction().getCaption()}</#if></a>
</#list>
</span>
</#if>
</p> </p>
</#if> </#if>
<div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>"> <div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>">
...@@ -98,14 +121,10 @@ ...@@ -98,14 +121,10 @@
<#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if> <#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if>
${ctrl.getTitle()} ${ctrl.getTitle()}
</span> </span>
<#if ctrl.getPSUIActionGroup?? && ctrl.getPSUIActionGroup()?? && ctrl.getPSUIActionGroup().getPSUIActionGroupDetails()??> <#assign render_uiaction><@renderUiaction /></#assign>
<#assign UIActionDetails=ctrl.getPSUIActionGroup().getPSUIActionGroupDetails() /> <@ibizindent blank=12>
<span class="portlet-action"> ${render_uiaction}<#t>
<#list UIActionDetails as uiactiondetail> </@ibizindent>
<a @click="uiAction('${uiactiondetail.getName()?lower_case}', $event)"><#if uiactiondetail.getPSUIAction()??>${uiactiondetail.getPSUIAction().getCaption()}</#if></a>
</#list>
</span>
</#if>
</p> </p>
</#if> </#if>
<div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>"> <div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>">
...@@ -119,14 +138,10 @@ ...@@ -119,14 +138,10 @@
<#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if> <#if ctrl.getPSSysImage()??><i class='<#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i></#if>
${ctrl.getTitle()} ${ctrl.getTitle()}
</span> </span>
<#if ctrl.getPSUIActionGroup?? && ctrl.getPSUIActionGroup()?? && ctrl.getPSUIActionGroup().getPSUIActionGroupDetails()??> <#assign render_uiaction><@renderUiaction /></#assign>
<#assign UIActionDetails=ctrl.getPSUIActionGroup().getPSUIActionGroupDetails() /> <@ibizindent blank=12>
<span class="portlet-action"> ${render_uiaction}<#t>
<#list UIActionDetails as uiactiondetail> </@ibizindent>
<a @click="uiAction('${uiactiondetail.getName()?lower_case}', $event)"><#if uiactiondetail.getPSUIAction()??>${uiactiondetail.getPSUIAction().getCaption()}</#if></a>
</#list>
</span>
</#if>
</p> </p>
</#if> </#if>
<div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>"> <div class="<#if ctrl.isShowTitleBar()>portlet-with-title<#else>portlet-without-title</#if>">
...@@ -151,7 +166,7 @@ import { Environment } from '@/environments/environment'; ...@@ -151,7 +166,7 @@ import { Environment } from '@/environments/environment';
* 长度 * 长度
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public height?: number; @Prop() public height?: number;
...@@ -159,10 +174,19 @@ import { Environment } from '@/environments/environment'; ...@@ -159,10 +174,19 @@ import { Environment } from '@/environments/environment';
* 宽度 * 宽度
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public width?: number; @Prop() public width?: number;
/**
* 视图默认使用
*
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Inject('navModel')
public navModel!:string;
<#if ctrl.getPortletType() == 'ACTIONBAR'> <#if ctrl.getPortletType() == 'ACTIONBAR'>
/** /**
* 操作栏模型数据 * 操作栏模型数据
...@@ -240,6 +264,28 @@ import { Environment } from '@/environments/environment'; ...@@ -240,6 +264,28 @@ import { Environment } from '@/environments/environment';
return {}; return {};
} }
/**
* 获取高度
*
* @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
get getHeight(){
if(!this.$util.isEmpty(this.height) && !this.$util.isNumberNaN(this.height)){
if(this.height == 0){
return 'auto';
}else{
return this.height+'px';
}
}else{
<#if ctrl.getHeight?? && ctrl.getHeight() gt 0>
return '${ctrl.getHeight()?c}px';
<#else>
return 'auto';
</#if>
}
}
/** /**
* vue 生命周期 * vue 生命周期
* *
......
<#-- --> <#-- -->
<#if ctrl.getPortletType() != 'CONTAINER'> <#if ctrl.getPortletType() != 'CONTAINER'>
<#assign content> <#assign content>
<#if (ctrl.getHeight?? && ctrl.getHeight() gt 0)> <#if (ctrl.getHeight?? && ctrl.getHeight() gte 0)>
:height="${ctrl.getHeight()?c}" :height="${ctrl.getHeight()?c}"
</#if> </#if>
<#if (ctrl.getWidth?? && ctrl.getWidth() gt 0)> <#if (ctrl.getWidth?? && ctrl.getWidth() gte 0)>
:width="${ctrl.getWidth()?c}" :width="${ctrl.getWidth()?c}"
</#if> </#if>
</#assign> </#assign>
......
...@@ -14,7 +14,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -14,7 +14,7 @@ import CodeListService from "@service/app/codelist-service";
* 接口实现 * 接口实现
* *
* @returns {any[]} * @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
getDatas(): any[] { getDatas(): any[] {
if (!this.panelData) { if (!this.panelData) {
...@@ -27,7 +27,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -27,7 +27,7 @@ import CodeListService from "@service/app/codelist-service";
* 接口实现 * 接口实现
* *
* @returns {*} * @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
getData() { getData() {
return this.data; return this.data;
...@@ -37,15 +37,15 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -37,15 +37,15 @@ import CodeListService from "@service/app/codelist-service";
* 父级部件引用 * 父级部件引用
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public parentRef?: any; @Prop() public parentRef?: any;
/** /**
* 计算UI展示数据 * 面板数据对象
* *
* @param codelistArray 代码表模型数组 * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Prop() public inputData?: any; @Prop() public inputData?: any;
...@@ -53,7 +53,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -53,7 +53,7 @@ import CodeListService from "@service/app/codelist-service";
* 代码表服务对象 * 代码表服务对象
* *
* @type {CodeListService} * @type {CodeListService}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public codeListService:CodeListService = new CodeListService({ $store:this.$store }); public codeListService:CodeListService = new CodeListService({ $store:this.$store });
...@@ -61,7 +61,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -61,7 +61,7 @@ import CodeListService from "@service/app/codelist-service";
* 详情模型集合 * 详情模型集合
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public detailsModel: any = { public detailsModel: any = {
<#list ctrl.getAllPSPanelItems() as panelItems> <#list ctrl.getAllPSPanelItems() as panelItems>
...@@ -74,7 +74,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -74,7 +74,7 @@ import CodeListService from "@service/app/codelist-service";
* *
* @public * @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal } * @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public panelLogic({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void { public panelLogic({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void {
<#if P.getPartCode(item,'PANEL_LOGIC').code?length gt 0> <#if P.getPartCode(item,'PANEL_LOGIC').code?length gt 0>
...@@ -86,7 +86,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -86,7 +86,7 @@ import CodeListService from "@service/app/codelist-service";
* 数据模型对象 * 数据模型对象
* *
* @type {${srfclassname('${ctrl.codeName}')}Model} * @type {${srfclassname('${ctrl.codeName}')}Model}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public dataModel:${srfclassname('${ctrl.codeName}')}Model = new ${srfclassname('${ctrl.codeName}')}Model(); public dataModel:${srfclassname('${ctrl.codeName}')}Model = new ${srfclassname('${ctrl.codeName}')}Model();
...@@ -94,7 +94,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -94,7 +94,7 @@ import CodeListService from "@service/app/codelist-service";
* UI数据对象 * UI数据对象
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public data:any = {}; public data:any = {};
...@@ -109,12 +109,12 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -109,12 +109,12 @@ import CodeListService from "@service/app/codelist-service";
/** /**
* 监听数据对象 * 监听数据对象
* *
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
@Watch('inputData',{immediate:true}) @Watch('inputData',{immediate:true,deep: true})
async onInputDataChange(newVal: any, oldVal: any){ public onInputDataChange(newVal: any, oldVal: any){
if(newVal){ if(newVal){
await this.computedUIData(newVal); this.computedUIData(newVal);
this.panelLogic({ name: '', newVal: null, oldVal: null }); this.panelLogic({ name: '', newVal: null, oldVal: null });
this.$forceUpdate(); this.$forceUpdate();
} }
...@@ -124,127 +124,29 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -124,127 +124,29 @@ import CodeListService from "@service/app/codelist-service";
* 计算UI展示数据 * 计算UI展示数据
* *
* @param codelistArray 代码表模型数组 * @param codelistArray 代码表模型数组
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async computedUIData(newVal:any){ public computedUIData(newVal:any){
let codelistArray:Array<any> = [];
if((this.dataModel.getDataItems instanceof Function) && this.dataModel.getDataItems().length >0){ if((this.dataModel.getDataItems instanceof Function) && this.dataModel.getDataItems().length >0){
this.dataModel.getDataItems().forEach((item:any) =>{ this.dataModel.getDataItems().forEach((item:any) =>{
if(item.codelist){ this.data[item.name] = newVal[item.prop];
codelistArray.push(item.codelist);
}
}) })
if(codelistArray.length >0){
let res:any = await this.getAllCodeList(codelistArray);
this.dataModel.getDataItems().forEach((item:any) =>{
if(item.codelist){
this.data[item.name] = res.get(item.codelist.tag).get(newVal[item.prop]);
}else{
this.data[item.name] = newVal[item.prop];
}
})
}else{
this.dataModel.getDataItems().forEach((item:any) =>{
this.data[item.name] = newVal[item.prop];
})
}
} }
} }
/** /**
* 计算面板数据 * 计算面板数据
* *
* @param codelistArray 代码表模型数组
* @memberof Mob * @memberof Mob
*/ */
public async computePanelData(){ public computeOutputData(){
let codelistArray:Array<any> = [];
let panelData:any = {}; let panelData:any = {};
if((this.dataModel.getDataItems instanceof Function) && this.dataModel.getDataItems().length >0){ if((this.dataModel.getDataItems instanceof Function) && this.dataModel.getDataItems().length >0){
this.dataModel.getDataItems().forEach((item:any) =>{ this.dataModel.getDataItems().forEach((item:any) =>{
if(item.codelist){ panelData[item.prop] = this.data[item.name];
codelistArray.push(item.codelist); })
}
})
if(codelistArray.length >0){
let res:any = await this.getAllCodeList(codelistArray,true);
this.dataModel.getDataItems().forEach((item:any) =>{
if(item.codelist){
panelData[item.prop] = res.get(item.codelist.tag).get(this.inputData[item.name]);
}else{
panelData[item.prop] = this.inputData[item.name];
}
})
}else{
this.dataModel.getDataItems().forEach((item:any) =>{
panelData[item.prop] = this.inputData[item.name];
})
}
} }
this.panelData = Object.assign(JSON.parse(JSON.stringify(this.inputData)),panelData); this.panelData = Object.assign(JSON.parse(JSON.stringify(this.inputData)),panelData);
}
/**
* 获取所有代码表
*
* @param codelistArray 代码表模型数组
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public getAllCodeList(codelistArray:Array<any>,reverse:boolean = false):Promise<any>{
return new Promise((resolve:any,reject:any) =>{
let codeListMap:Map<string,any> = new Map();
let promiseArray:Array<any> = [];
codelistArray.forEach((item:any) =>{
if(!codeListMap.get(item.tag)){
promiseArray.push(this.getCodeList(item));
Promise.all(promiseArray).then((result:any) =>{
if(result && result.length >0){
result.forEach((codeList:any) =>{
let tempCodeListMap:Map<number,any> = new Map();
if(codeList.length >0){
codeList.forEach((codeListItem:any) =>{
if(reverse){
tempCodeListMap.set(codeListItem.text,codeListItem.value);
}else{
tempCodeListMap.set(codeListItem.value,codeListItem.text);
}
})
}
codeListMap.set(item.tag,tempCodeListMap);
})
resolve(codeListMap);
}
})
}
})
})
}
/**
* 获取代码表
*
* @param codeListObject 传入代码表对象
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public getCodeList(codeListObject:any):Promise<any>{
return new Promise((resolve:any,reject:any) =>{
if(codeListObject.tag && Object.is(codeListObject.codelistType,"STATIC")){
const codelist = this.$store.getters.getCodeList(codeListObject.tag);
if (codelist) {
resolve([...JSON.parse(JSON.stringify(codelist.items))]);
} else {
resolve([]);
console.log(`----<#noparse>${codeListObject.tag}</#noparse>----代码表不存在`);
}
}else if(codeListObject.tag && Object.is(codeListObject.codelistType,"DYNAMIC")){
this.codeListService.getItems(codeListObject.tag).then((res:any) => {
resolve(res);
}).catch((error:any) => {
resolve([]);
console.log(`----<#noparse>${codeListObject.tag}</#noparse>----代码表不存在`);
});
}
})
} }
/** /**
...@@ -253,10 +155,10 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -253,10 +155,10 @@ import CodeListService from "@service/app/codelist-service";
* @param {*} row * @param {*} row
* @param {*} tag * @param {*} tag
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async uiAction(row: any, tag: any, $event: any) { public async uiAction(row: any, tag: any, $event: any) {
await this.computePanelData(); await this.computeOutputData();
<#if ctrl.getPSAppViewLogics()??> <#if ctrl.getPSAppViewLogics()??>
<#list ctrl.getPSAppViewLogics() as logic> <#list ctrl.getPSAppViewLogics() as logic>
<#if logic.getPSAppViewUIAction().getPSUIAction()??> <#if logic.getPSAppViewUIAction().getPSUIAction()??>
...@@ -273,7 +175,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -273,7 +175,7 @@ import CodeListService from "@service/app/codelist-service";
* 打开编辑数据视图 * 打开编辑数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public opendata(args: any[],fullargs?:any[],params?: any, $event?: any, xData?: any){ public opendata(args: any[],fullargs?:any[],params?: any, $event?: any, xData?: any){
if (this.parentRef.opendata && this.parentRef.opendata instanceof Function) { if (this.parentRef.opendata && this.parentRef.opendata instanceof Function) {
...@@ -285,7 +187,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -285,7 +187,7 @@ import CodeListService from "@service/app/codelist-service";
* 打开新建数据视图 * 打开新建数据视图
* *
* @type {any} * @type {any}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public newdata(args: any[],fullargs?:any[], params?: any, $event?: any, xData?: any) { public newdata(args: any[],fullargs?:any[], params?: any, $event?: any, xData?: any) {
if (this.parentRef.newdata && this.parentRef.newdata instanceof Function) { if (this.parentRef.newdata && this.parentRef.newdata instanceof Function) {
...@@ -298,7 +200,7 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -298,7 +200,7 @@ import CodeListService from "@service/app/codelist-service";
* *
* @param {any[]} datas * @param {any[]} datas
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')} * @memberof ${srfclassname('${ctrl.codeName}')}Base
*/ */
public async remove(datas: any[]): Promise<any> { public async remove(datas: any[]): Promise<any> {
if (this.parentRef.remove && this.parentRef.remove instanceof Function) { if (this.parentRef.remove && this.parentRef.remove instanceof Function) {
...@@ -318,6 +220,59 @@ import CodeListService from "@service/app/codelist-service"; ...@@ -318,6 +220,59 @@ import CodeListService from "@service/app/codelist-service";
} }
} }
/**
* 设置变更面板编辑项的值
*
* @param data 面板数据
* @param {{ name: string, value: any }} $event
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public onPanelItemValueChange(data: any,$event: { name: string, value: any }): void {
if (!$event) {
return;
}
if (!$event.name || Object.is($event.name, '') || !data.hasOwnProperty($event.name)) {
return;
}
data[$event.name] = $event.value;
this.panelEditItemChange(data, $event.name, $event.value);
}
/**
* 面板编辑项值变化后续操作
*
* @public
* @param data 面板数据
* @param property 编辑项名
* @param value 编辑项值
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public panelEditItemChange(data: any, property: string, value: any){
// 面板数据变化事件
if((this.dataModel.getDataItems instanceof Function) && this.dataModel.getDataItems().length >0){
let modelitem =this.dataModel.getDataItems().find((item:any) =>{
return item.name === property;
})
if(modelitem){
this.$emit('panelDataChange',{[modelitem.prop]: value});
}
}
/**
* 刷新
*
* @param {*} [opt={}]
* @memberof Main
*/
public refresh(opt: any = {}) {
if (this.parentRef.refresh && this.parentRef.refresh instanceof Function) {
this.parentRef.refresh(opt);
}
}
<#ibizinclude> <#ibizinclude>
../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl ../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl
</#ibizinclude> </#ibizinclude>
......
<#assign content> <layout_${ctrl.getName()}
:parentRef="thisRef" :viewState="viewState"
</#assign> :viewparams="viewparams"
<#ibizinclude> :context="context"
../@MACRO/HTML/DEFAULT.html.ftl :parentRef="thisRef"
</#ibizinclude> :inputData="item"
\ No newline at end of file @panelDataChange="($event)=>{onPanelDataChange(item,$event)}"
name="${ctrl.name}"
ref='${ctrl.name}'>
</layout_${ctrl.getName()}>
<el-input size="small" v-model="data.${editor.getName()?lower_case}" style="width: 100%;"></el-input> <input-box
\ No newline at end of file <#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
v-model="data.${editor.getName()?lower_case}"
style="${item.getEditorCssStyle()}"
type="text"
<#if item.getUnitName?? && item.getUnitName()??>unit="${item.getUnitName()}"</#if>
<#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if>
@change="($event)=>{panelEditItemChange(data, ${editor.getName()?lower_case}, $event)}">
</input-box>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <span v-html="data.${editor.name?lower_case}"></span>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-rich-text-editor :formState="formState" :value="data.${editor.name?lower_case}" @change="(val) =>{this.data.${editor.name?lower_case} =val}" <#if item.getEnableCond??>:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"</#if> name="${editor.name?lower_case}"<#if editor.getEditorHeight() gt 0> height={${editor.getEditorHeight()?c}}</#if> style="${editor.getEditorCssStyle()}"></app-rich-text-editor>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
\ No newline at end of file <dropdown-list
v-model="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:data="data"
:context="context"
:viewparams="viewparams"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
<#if item.getPSCodeList()??>
<#assign codelist=item.getPSCodeList()>
tag='${codelist.codeName}'
codelistType='${codelist.getCodeListType()}'
</#if>
placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if>
style="${item.getEditorCssStyle()}"
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</dropdown-list>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
\ No newline at end of file <dropdown-list
v-model="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:data="data"
:context="context"
:viewparams="viewparams"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
<#if item.getPSCodeList()??>
<#assign codelist=item.getPSCodeList()>
tag='${codelist.codeName}'
codelistType='${codelist.getCodeListType()}'
</#if>
placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if>
style="${item.getEditorCssStyle()}"
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</dropdown-list>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
\ No newline at end of file <dropdown-list
v-model="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:data="data"
:context="context"
:viewparams="viewparams"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
<#if item.getPSCodeList()??>
<#assign codelist=item.getPSCodeList()>
tag='${codelist.codeName}'
codelistType='${codelist.getCodeListType()}'
</#if>
placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if>
style="${item.getEditorCssStyle()}width: 100px;"
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</dropdown-list>
<#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<app-transfer <app-transfer
v-model="data.${editor.name}" v-model="data.${editor.name}"
:data="data"
:context="context" :context="context"
:viewparams="viewparams" :viewparams="viewparams"
:localContext =<@getNavigateContext editor /> :localContext =<@getNavigateContext editor />
......
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
\ No newline at end of file <dropdown-list-mpicker
v-model="data.${editor.name?lower_case}"
:data="data"
:context="context"
:viewparams="viewparams"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
<#if item.getPSCodeList()??>
<#assign codelist=editor.getPSCodeList()>
tag='${codelist.codeName}'
codelistType='${codelist.getCodeListType()}'
<#if codelist.valueSeparator?has_content>valueSeparator="${codelist.valueSeparator}"</#if>
</#if>
placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if>
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}"
style="${item.getEditorCssStyle()}">
</dropdown-list-mpicker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
\ No newline at end of file <app-radio-group
v-model="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
name="${editor.name?lower_case}"
:data="data"
:context="context"
:viewparams="viewparams"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}"
<#if editor.getPSCodeList?? && editor.getPSCodeList()??>
<#assign codelist=item.getPSCodeList()>
tag='${codelist.codeName}'
codelistType='${codelist.getCodeListType()}'
</#if>
style="${item.getEditorCssStyle()}">
</app-radio-group>
<app-image-upload :multiple="true" :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" uploadparams='${editor.getEditorParam('uploadparams','')}' exportparams='${editor.getEditorParam('exportparams','')}' :customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>" style="${editor.getEditorCssStyle()}overflow: auto;"></app-image-upload> <app-image-upload :multiple="true" :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>' style="${editor.getEditorCssStyle()}overflow: auto;"></app-image-upload>
\ No newline at end of file \ No newline at end of file
...@@ -8,7 +8,6 @@ ...@@ -8,7 +8,6 @@
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
:rowPreview="true" :rowPreview="true"
:imageOnly="true" :imageOnly="true"
uploadparams='${editor.getEditorParam('uploadparams','')}' :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
exportparams='${editor.getEditorParam('exportparams','')}' style="${editor.getEditorCssStyle()}overflow: auto;">
:customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>" style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload> </app-file-upload>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-file-upload
\ No newline at end of file :formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onPanelItemValueChange(data,$event)}"
:data="JSON.stringify(data)"
:name='${editor.name?lower_case}'
:value="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:rowPreview="true"
:imageOnly="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-image-preview :formState="formState" name='${editor.name?lower_case}' :value="data.${editor.name?lower_case}" style="${editor.getEditorCssStyle()}"></app-image-preview>
\ No newline at end of file
<app-image-upload :multiple="false" :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" uploadparams='${editor.getEditorParam('uploadparams','')}' exportparams='${editor.getEditorParam('exportparams','')}' :customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>"></app-image-upload> <app-image-upload :multiple="false" :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>' ></app-image-upload>
\ No newline at end of file \ No newline at end of file
...@@ -8,7 +8,6 @@ ...@@ -8,7 +8,6 @@
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
:rowPreview="true" :rowPreview="true"
:imageOnly="true" :imageOnly="true"
uploadparams='${editor.getEditorParam('uploadparams','')}' :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
exportparams='${editor.getEditorParam('exportparams','')}' style="${editor.getEditorCssStyle()}overflow: auto;">
:customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>" style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload> </app-file-upload>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-file-upload
\ No newline at end of file :formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onPanelItemValueChange(data,$event)}"
:data="JSON.stringify(data)"
:name='${editor.name?lower_case}'
:value="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:rowPreview="true"
:imageOnly="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
<div class="ivu-input-wrapper ivu-input-wrapper-default ivu-input-type"> <input-box v-model="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" type='textarea' style="${editor.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if>></input-box>
<textarea class="ivu-input" v-model="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" style="${editor.getEditorCssStyle()}"<#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if>></textarea> \ No newline at end of file
</div>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <div class="ivu-input-wrapper ivu-input-wrapper-default ivu-input-type">
\ No newline at end of file <textarea
class="ivu-input"
<#if item.getEnableCond??>
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
v-model="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}"
<#if item.getPlaceHolder?? && item.getPlaceHolder()??>
placeholder="${item.getPlaceHolder()}"
</#if>
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</textarea>
</div>
<div class="ivu-input-wrapper ivu-input-wrapper-default ivu-input-type"> <input-box v-model="data.${editor.name}" :autoSize="{minRows: 10}" :disabled="detailsModel.${editor.name}.disabled" type='textarea' style="${editor.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if>></input-box>
<textarea class="ivu-input" :rows="10" v-model="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" style="${editor.getEditorCssStyle()}"<#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if>></textarea>
</div>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <div class="ivu-input-wrapper ivu-input-wrapper-default ivu-input-type">
\ No newline at end of file <textarea
class="ivu-input"
<#if item.getEnableCond??>
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
rows="10"
v-model="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}"
<#if item.getPlaceHolder?? && item.getPlaceHolder()??>
placeholder="${item.getPlaceHolder()}"
</#if>
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</textarea>
</div>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <input-box
\ No newline at end of file type="password"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
v-model="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}"
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</input-box>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-switch
\ No newline at end of file name='${editor.name?lower_case}'
:value="data.${editor.name?lower_case}"
@change="($event)=>{data.${editor.name?lower_case} = $event;panelEditItemChange(data, '${editor.name?lower_case}', $event)} "
<#if item.getEnableCond??>
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
style="${item.getEditorCssStyle()}">
</app-switch>
<input-box <input-box
v-model="data.${editor.name}" v-model="data.${editor.name}"
@enter="onEnter($event)" @enter="onEnter($event)"
<#if item.getUnitName?? && item.getUnitName()??>unit="${item.getUnitName()}"</#if> <#if editor.getUnitName?? && editor.getUnitName()??>unit="${editor.getUnitName()}"</#if>
:disabled="detailsModel.${editor.name}.disabled" :disabled="detailsModel.${editor.name}.disabled"
type='number' type='number'
<#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if> <#if item.getPSAppDEField().getPSDEField().getPrecision??>
<#if item.getPSAppDEField().getPSDEField().getDataType() == 'FLOAT' && item.getPSAppDEField().getPSDEField().getPrecision() == 0>
:precision="2"
<#else>
:precision="${item.getPSAppDEField().getPSDEField().getPrecision()?c}"
</#if>
</#if>
<#if editor.getPlaceHolder()??>placeholder="${editor.getPlaceHolder()}"</#if>
style="${editor.getEditorCssStyle()}"> style="${editor.getEditorCssStyle()}">
</input-box> </input-box>
\ No newline at end of file
<input-box <input-box
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
v-model="row[column.property]" v-model="row[column.property]"
<#if item.getUnitName()??>unit="${item.getUnitName()}"</#if> <#if item.getUnitName?? && item.getUnitName()??>
unit="${item.getUnitName()}"
</#if>
type="number" type="number"
<#if item.getPSAppDEField().getPSDEField().getPrecision??>
<#if item.getPSAppDEField().getPSDEField().getDataType() == 'FLOAT' && item.getPSAppDEField().getPSDEField().getPrecision() == 0>
:precision="2"
<#else>
:precision="${item.getPSAppDEField().getPSDEField().getPrecision()?c}"
</#if>
</#if>
style="${item.getEditorCssStyle()}" style="${item.getEditorCssStyle()}"
<#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if> <#if item.getPlaceHolder()??>
placeholder="${item.getPlaceHolder()}"
</#if>
@change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"> @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}">
</input-box> </input-box>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <input-box
\ No newline at end of file type="number"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
<#if item.getUnitName()??>unit="${item.getUnitName()}"</#if>
v-model="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}"
<#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if>
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</input-box>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
\ No newline at end of file <#if editor.getEditorParam("PICKUPVIEW",true)??>
<#if editor.getPickupPSAppView()??>
<app-picker
:formState="viewState"
:data="data"
:context="context"
:viewparams="viewparams"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
name='${editor.name}'
<#if editor.getPSAppDataEntity?? && editor.getPSAppDataEntity()??>
deMajorField='${editor.getPSAppDataEntity().getMajorPSAppDEField().getCodeName()?lower_case}'
deKeyField='${editor.getPSAppDataEntity().getCodeName()?lower_case}'
</#if>
:service="service"
:acParams=<@getAcParams editor />
valueitem='${editor.getValueItemName()}'
:value="data[${editor.name}]"
editortype=""
:pickupView=<@getPickupView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onPanelItemValueChange(data,$event)}">
<@getItemRender editor />
</app-picker>
</#if>
</#if>
<app-file-upload :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" uploadparams='${editor.getEditorParam('uploadparams','')}' exportparams='${editor.getEditorParam('exportparams','')}' :customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>" style="${editor.getEditorCssStyle()}overflow: auto;"></app-file-upload> <app-file-upload :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>' style="${editor.getEditorCssStyle()}overflow: auto;"></app-file-upload>
\ No newline at end of file \ No newline at end of file
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
:value="row[column.property]" :value="row[column.property]"
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
:rowPreview="true" :rowPreview="true"
uploadparams='${editor.getEditorParam('uploadparams','')}' :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
exportparams='${editor.getEditorParam('exportparams','')}' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>" style="${editor.getEditorCssStyle()}overflow: auto;"> style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload> </app-file-upload>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-file-upload
\ No newline at end of file :formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onPanelItemValueChange(data,$event)}"
:data="JSON.stringify(data)"
:name='${editor.name?lower_case}'
:value="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:rowPreview="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-upload-file-info name='${editor.name?lower_case}' :value="data.${editor.name?lower_case}" style="${editor.getEditorCssStyle()}"></app-upload-file-info>
\ No newline at end of file
<app-file-upload :isdrag="true" :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" uploadparams='${editor.getEditorParam('uploadparams','')}' exportparams='${editor.getEditorParam('exportparams','')}' :customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>" style="${editor.getEditorCssStyle()}overflow: auto;"></app-file-upload> <app-file-upload :isdrag="true" :formState="formState" :ignorefieldvaluechange="ignorefieldvaluechange" @formitemvaluechange="onFormItemValueChange" :data="JSON.stringify(this.data)" name='${editor.name}' :value="data.${editor.name}" :disabled="detailsModel.${editor.name}.disabled" :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>' style="${editor.getEditorCssStyle()}overflow: auto;"></app-file-upload>
\ No newline at end of file \ No newline at end of file
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
:value="row[column.property]" :value="row[column.property]"
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
:rowPreview="true" :rowPreview="true"
uploadparams='${editor.getEditorParam('uploadparams','')}' :uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
exportparams='${editor.getEditorParam('exportparams','')}' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:customparams="<#if editor.getEditorParam('customparams','') != ''>${editor.getEditorParam('customparams','')}<#else>{}</#if>" style="${editor.getEditorCssStyle()}overflow: auto;"> style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload> </app-file-upload>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-file-upload
\ No newline at end of file :isdrag="true"
:formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onPanelItemValueChange(data,$event)}"
:data="JSON.stringify(data)"
:name='${editor.name?lower_case}'
:value="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:rowPreview="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <date-picker
\ No newline at end of file type="datetime"
:transfer="true"
format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val1, val2) => { data.${editor.name?lower_case} = val1; gridEditItemChange(data, '${editor.name?lower_case}', val1)}">
</date-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <date-picker
\ No newline at end of file type="date"
:transfer="true"
format="yyyy-MM-dd"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val1, val2) => { data.${editor.name?lower_case} = val1; gridEditItemChange(data, '${editor.name?lower_case}', val1)}">
</date-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <time-picker
\ No newline at end of file :transfer="true"
format="mm"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val) => { data.${editor.name?lower_case} = val; gridEditItemChange(data, '${editor.name?lower_case}', val)}">
</time-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <time-picker
\ No newline at end of file :transfer="true"
format="HH"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val) => { data.${editor.name?lower_case} = val; gridEditItemChange(data, '${editor.name?lower_case}', val)}">
</time-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <date-picker
\ No newline at end of file type="date"
:transfer="true"
format="yyyy-MM-dd"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val1, val2) => { data.${editor.name?lower_case} = val1; gridEditItemChange(data, '${editor.name?lower_case}', val1)}">
</date-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <time-picker
\ No newline at end of file :transfer="true"
format="HH:mm:ss"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val) => { data.${editor.name?lower_case} = val; gridEditItemChange(data, '${editor.name?lower_case}', val)}">
</time-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <time-picker
\ No newline at end of file :transfer="true"
format="HH:mm"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val) => { data.${editor.name?lower_case} = val; gridEditItemChange(data, '${editor.name?lower_case}', val)}">
</time-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <time-picker
\ No newline at end of file :transfer="true"
format="ss"
placeholder="请选择时间..."
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:value="data.${editor.name?lower_case}"
style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>"
@on-change="(val) => { data.${editor.name?lower_case} = val; gridEditItemChange(data, '${editor.name?lower_case}', val)}">
</time-picker>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-stepper
\ No newline at end of file name='${editor.name}'
:value="data.${editor.name?lower_case}"
@change="($event)=>{onPanelItemValueChange(data,$event)} "
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
style="${item.getEditorCssStyle()}">
</app-stepper>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-slider
\ No newline at end of file name='${editor.name?lower_case}'
:value="data.${editor.name?lower_case}"
@change="($event)=>{onPanelItemValueChange(data,$event)} "
<#if item.getEnableCond??>
:disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
style="${item.getEditorCssStyle()}">
</app-slider>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <app-rate
\ No newline at end of file name='${editor.name?lower_case}'
:value="data.${editor.name?lower_case}"
@change="($event)=>{data.${editor.name?lower_case} = $event; panelEditItemChange(data, '${editor.name?lower_case}', $event)} "
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
style="${item.getEditorCssStyle()}">
</app-rate>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <div style="${item.getEditorCssStyle()}">
\ No newline at end of file <app-checkbox :value="data.${editor.name?lower_case}" @change="($event)=>{data.${editor.name?lower_case} = $event;panelEditItemChange(data, '${editor.name?lower_case}', $event)} " <#if item.getEnableCond??>:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"</#if>></app-checkbox>
</div>
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude> <#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
\ No newline at end of file <app-checkbox-list
v-model="data.${editor.name?lower_case}"
<#if item.getEnableCond??>
:disabled="data.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"
</#if>
:data="data"
:context="context"
:viewparams="viewparams"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
<#if item.getPSCodeList()??>
<#assign codelist=item.getPSCodeList()>
tag='${codelist.codeName}'
codelistType='${codelist.getCodeListType()}'
<#if codelist.valueSeparator?has_content>
valueSeparator="${codelist.valueSeparator}"
</#if>
mode="${codelist.getOrMode()?lower_case}"
</#if>
name="${editor.name?lower_case}"
@change="($event)=>{panelEditItemChange(data, '${editor.name?lower_case}', $event)}">
</app-checkbox-list>
...@@ -49,7 +49,12 @@ public click${item.codeName}(item: any = {}) { ...@@ -49,7 +49,12 @@ public click${item.codeName}(item: any = {}) {
<#-- END:准备参数 --> <#-- END:准备参数 -->
<#if dataview.getOpenMode() == 'INDEXVIEWTAB' || dataview.getOpenMode() == ''> <#if dataview.getOpenMode() == 'INDEXVIEWTAB' || dataview.getOpenMode() == ''>
const path: string = this.$viewTool.buildUpRoutePath(this.$route, {}, deResParameters, parameters, [], viewparam); const path: string = this.$viewTool.buildUpRoutePath(this.$route, {}, deResParameters, parameters, [], viewparam);
this.$router.push(path); if(Object.is(this.$route.fullPath,path)){
return;
}
this.$nextTick(function(){
this.$router.push(path);
})
</#if> </#if>
<#if dataview.getOpenMode() == 'POPUP'> <#if dataview.getOpenMode() == 'POPUP'>
console.log('-----POPUP-----非模式弹出,暂时不实现'); console.log('-----POPUP-----非模式弹出,暂时不实现');
......
...@@ -46,9 +46,10 @@ ...@@ -46,9 +46,10 @@
this.$Notice.warning({ title: '错误', desc: '向导添加未实现' }); this.$Notice.warning({ title: '错误', desc: '向导添加未实现' });
<#elseif viewlogic.isEnableBatchAdd()> <#elseif viewlogic.isEnableBatchAdd()>
<#-- 批量添加 --> <#-- 批量添加 -->
let batchAddPSAppViews:Array<any>=[];
<#if viewlogic.getBatchAddPSAppViews?? && viewlogic.getBatchAddPSAppViews()??> <#if viewlogic.getBatchAddPSAppViews?? && viewlogic.getBatchAddPSAppViews()??>
<#assign batchAddPSAppViews = viewlogic.getBatchAddPSAppViews()/> <#assign batchAddPSAppViews = viewlogic.getBatchAddPSAppViews()/>
const batchAddPSAppViews=[ batchAddPSAppViews=[
<#list batchAddPSAppViews as batchAddPSAppView> <#list batchAddPSAppViews as batchAddPSAppView>
{view:{viewname:'${srffilepath2(batchAddPSAppView.getCodeName())}',height: ${batchAddPSAppView.getHeight()?c},width: ${batchAddPSAppView.getWidth()?c},title: '${batchAddPSAppView.title}'}, {view:{viewname:'${srffilepath2(batchAddPSAppView.getCodeName())}',height: ${batchAddPSAppView.getHeight()?c},width: ${batchAddPSAppView.getWidth()?c},title: '${batchAddPSAppView.title}'},
res:<@getres tempView=batchAddPSAppView /><#if batchAddPSAppView.getPSAppDataEntity()??><#assign appDataEntity= batchAddPSAppView.getPSAppDataEntity()/>, res:<@getres tempView=batchAddPSAppView /><#if batchAddPSAppView.getPSAppDataEntity()??><#assign appDataEntity= batchAddPSAppView.getPSAppDataEntity()/>,
......
...@@ -29,7 +29,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -29,7 +29,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isSingleSelect: boolean = ${dataview.isSingleSelect()?c}; public isSingleSelect: boolean = ${dataview.isSingleSelect()?c};
</#if> </#if>
...@@ -38,7 +38,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -38,7 +38,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 视图唯一标识 * 视图唯一标识
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}'; public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}';
...@@ -46,7 +46,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -46,7 +46,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 搜索值 * 搜索值
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public query: string = ''; public query: string = '';
...@@ -54,7 +54,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -54,7 +54,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 是否展开搜索表单 * 是否展开搜索表单
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c}; public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c};
...@@ -62,7 +62,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -62,7 +62,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 快速搜索 * 快速搜索
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onSearch($event: any): void { public onSearch($event: any): void {
const refs: any = this.$refs; const refs: any = this.$refs;
...@@ -97,7 +97,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -97,7 +97,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupData:any; public quickGroupData:any;
/** /**
* 快速分组是否有抛值 * 快速分组是否有抛值
...@@ -171,9 +171,9 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -171,9 +171,9 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupValueChange($event:any){ public quickGroupValueChange($event:any){
if($event && $event.data){ if($event && $event.data){
this.qucikGroupData = $event.data; this.quickGroupData = $event.data;
if(this.isEmitQuickGroupValue){ if(this.isEmitQuickGroupValue){
this.onSearch($event); this.onSearch($event);
} }
...@@ -188,15 +188,15 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -188,15 +188,15 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormData:any; public quickFormData:any;
/** /**
* 快速搜索栏值变化 * 快速搜索栏值变化
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormValueChange($event:any){ public quickFormValueChange($event:any){
this.qucikFormData = $event; this.quickFormData = $event;
this.onSearch($event); this.onSearch($event);
} }
</#if> </#if>
......
...@@ -190,7 +190,7 @@ if(this.formDruipart){ ...@@ -190,7 +190,7 @@ if(this.formDruipart){
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupData:any; public quickGroupData:any;
/** /**
* 快速分组是否有抛值 * 快速分组是否有抛值
...@@ -264,9 +264,9 @@ if(this.formDruipart){ ...@@ -264,9 +264,9 @@ if(this.formDruipart){
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupValueChange($event:any){ public quickGroupValueChange($event:any){
if($event && $event.data){ if($event && $event.data){
this.qucikGroupData = $event.data; this.quickGroupData = $event.data;
if(this.isEmitQuickGroupValue){ if(this.isEmitQuickGroupValue){
this.onSearch($event); this.onSearch($event);
} }
...@@ -281,15 +281,15 @@ if(this.formDruipart){ ...@@ -281,15 +281,15 @@ if(this.formDruipart){
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormData:any; public quickFormData:any;
/** /**
* 快速搜索栏值变化 * 快速搜索栏值变化
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormValueChange($event:any){ public quickFormValueChange($event:any){
this.qucikFormData = $event; this.quickFormData = $event;
this.onSearch($event); this.onSearch($event);
} }
</#if> </#if>
......
...@@ -77,7 +77,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -77,7 +77,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupData:any; public quickGroupData:any;
/** /**
* 快速分组是否有抛值 * 快速分组是否有抛值
...@@ -151,9 +151,9 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -151,9 +151,9 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupValueChange($event:any){ public quickGroupValueChange($event:any){
if($event && $event.data){ if($event && $event.data){
this.qucikGroupData = $event.data; this.quickGroupData = $event.data;
if(this.isEmitQuickGroupValue){ if(this.isEmitQuickGroupValue){
this.onSearch($event); this.onSearch($event);
} }
...@@ -168,15 +168,15 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -168,15 +168,15 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormData:any; public quickFormData:any;
/** /**
* 快速搜索栏值变化 * 快速搜索栏值变化
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormValueChange($event:any){ public quickFormValueChange($event:any){
this.qucikFormData = $event; this.quickFormData = $event;
this.onSearch($event); this.onSearch($event);
} }
</#if> </#if>
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
* 选中数据字符串 * 选中数据字符串
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
@Prop() public selectedData?: string; @Prop() public selectedData?: string;
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
@Prop() public isSingleSelect?: boolean; @Prop() public isSingleSelect?: boolean;
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
* 搜索值 * 搜索值
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public query: string = ''; public query: string = '';
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
* 是否展开搜索表单 * 是否展开搜索表单
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c}; public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c};
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
* 2 双击激活 * 2 双击激活
* *
* @type {(number | 0 | 1 | 2)} * @type {(number | 0 | 1 | 2)}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public gridRowActiveMode: number | 0 | 1 | 2 = ${view.getGridRowActiveMode()?c}; public gridRowActiveMode: number | 0 | 1 | 2 = ${view.getGridRowActiveMode()?c};
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
* 快速搜索 * 快速搜索
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onSearch($event: any): void { public onSearch($event: any): void {
const refs: any = this.$refs; const refs: any = this.$refs;
......
...@@ -33,6 +33,9 @@ import view_${ctrl.getName()} from '@widgets/app/${srffilepath2(ctrl.getCodeName ...@@ -33,6 +33,9 @@ import view_${ctrl.getName()} from '@widgets/app/${srffilepath2(ctrl.getCodeName
}, },
beforeRouteEnter: (to: any, from: any, next: any) => { beforeRouteEnter: (to: any, from: any, next: any) => {
next((vm: any) => { next((vm: any) => {
if(!Object.is(vm.navModel,"route")){
vm.initNavDataWithTab(vm.viewCacheData);
}
vm.$store.commit('addCurPageViewtag', { fullPath: to.fullPath, viewtag: vm.viewtag }); vm.$store.commit('addCurPageViewtag', { fullPath: to.fullPath, viewtag: vm.viewtag });
}); });
}, },
......
...@@ -147,6 +147,12 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code} ...@@ -147,6 +147,12 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code}
} }
}) })
} }
if(Object.is(this.navModel,"tab")){
this.navDataService.removeNavDataByTag(this.viewtag);
}
if (this.serviceStateEvent) {
this.serviceStateEvent.unsubscribe();
}
} }
</#if> </#if>
} }
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
/** /**
* 加载权限按钮 * 加载权限按钮
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public loadWFLinks(): void { public loadWFLinks(): void {
const url = '${app.getPKGCodeName()?lower_case}/${de.getPSSystemModule().codeName?lower_case}/${de.codeName?lower_case}/wflinks'; const url = '${app.getPKGCodeName()?lower_case}/${de.getPSSystemModule().codeName?lower_case}/${de.codeName?lower_case}/wflinks';
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
* *
* @param {*} item * @param {*} item
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public wflink_click(item: any, $event: any): void { public wflink_click(item: any, $event: any): void {
if (Object.is(item.type, 'FRONT')) { if (Object.is(item.type, 'FRONT')) {
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
* *
* @param {*} item * @param {*} item
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public wflink_front(item: any, $event: any): void { public wflink_front(item: any, $event: any): void {
if (!item.page || Object.is(item.page, '')) { if (!item.page || Object.is(item.page, '')) {
...@@ -98,7 +98,7 @@ ...@@ -98,7 +98,7 @@
* @param {*} item * @param {*} item
* @param {*} $event * @param {*} $event
* @param {*} [data] * @param {*} [data]
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public wflink_backend(item: any, $event: any, data?: any): void { public wflink_backend(item: any, $event: any, data?: any): void {
const _this: any = this; const _this: any = this;
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
* @param {*} $event * @param {*} $event
* @param {*} [data] * @param {*} [data]
* @returns {Promise<any>} * @returns {Promise<any>}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public async wf_Step(item: any, $event: any, data?: any): Promise<any> { public async wf_Step(item: any, $event: any, data?: any): Promise<any> {
const arg: any = { args: {} }; const arg: any = { args: {} };
......
...@@ -8,7 +8,7 @@ import UIService from '@/uiservice/ui-service'; ...@@ -8,7 +8,7 @@ import UIService from '@/uiservice/ui-service';
/** /**
* 初始化视图 * 初始化视图
* *
* @memberof WFCIDWFDataRedirectViewBase * @memberof ${srfclassname('${view.name}')}Base
*/ */
public async viewInit(){ public async viewInit(){
const {srfkey:srfkey,srfappde:srfappde,srfworklist:srfworklist} = this.viewparams; const {srfkey:srfkey,srfappde:srfappde,srfworklist:srfworklist} = this.viewparams;
......
<#assign view_base_name>TabExpViewBase</#assign> <#assign view_base_name>TabExpViewBase</#assign>
<#-- <#assign self_content>
/**
* 加载模型
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public loadModel(){
<#assign appDataEntity = view.getPSAppDataEntity() />
if(this.context.${appDataEntity.getCodeName()?lower_case}){
this.appEntityService.getDataInfo(JSON.parse(JSON.stringify(this.context)),{},false).then((response:any) =>{
if (!response || response.status !== 200) {
return;
}
const { data: _data } = response;
if (_data.${appDataEntity.getMajorPSAppDEField().getCodeName()?lower_case}) {
Object.assign(this.model, { dataInfo: _data.${appDataEntity.getMajorPSAppDEField().getCodeName()?lower_case} });
this.$tabPageExp.setCurPageCaption(this.model.srfCaption, this.model.srfTitle, this.model.dataInfo);
<#noparse>Object.assign(this.model, { srfTitle: `${this.$t(this.model.srfTitle)} - ${this.model.dataInfo}` });</#noparse>
}
})
}
}
</#assign> -->
<#ibizinclude> <#ibizinclude>
../@MACRO/LAYOUTPANEL_VIEW.template.ftl ../@MACRO/LAYOUTPANEL_VIEW.template.ftl
......
<#ibizinclude>
../@MACRO/LAYOUTPANEL_VIEW.template.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW_HEADER-BASE.vue.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW_CONTENT-BASE.vue.ftl
</#ibizinclude>
<#assign tabexppanel = view.getPSControl('tabexppanel') />
<#if tabexppanel?? && tabexppanel.getPSControls?? && tabexppanel.getPSControls()??>
<#list tabexppanel.getPSControls() as tabviewpanel>
<#if tabviewpanel.name??>
<#assign tabValue = tabviewpanel.name />
<#break>
</#if>
</#list>
</#if>
/**
* 当前分页panel值
*
* @type {boolean}
* @memberof ${srfclassname('${view.name}')}Base
*/
public tabValue: string = <#if tabValue??>'${tabValue}'<#else>''</#if>;
<#ibizinclude>
../@MACRO/VIEW_BOTTOM-BASE.vue.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW-BASE.style.ftl
</#ibizinclude>
\ No newline at end of file
${P.getLayoutCode().code}
\ No newline at end of file
<#ibizinclude>
../@MACRO/VIEW.vue.ftl
</#ibizinclude>
\ No newline at end of file
VIEWTYPE=APPDETABSEARCHVIEW
\ No newline at end of file
<#ibizinclude>
../@MACRO/LAYOUTPANEL_VIEW.template.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW_HEADER-BASE.vue.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW_CONTENT-BASE.vue.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW_BOTTOM-BASE.vue.ftl
</#ibizinclude>
<#ibizinclude>
../@MACRO/VIEW-BASE.style.ftl
</#ibizinclude>
\ No newline at end of file
${P.getLayoutCode().code}
\ No newline at end of file
<#ibizinclude>
../@MACRO/VIEW.vue.ftl
</#ibizinclude>
\ No newline at end of file
VIEWTYPE=APPDETABSEARCHVIEW9
\ No newline at end of file
...@@ -12,6 +12,13 @@ ...@@ -12,6 +12,13 @@
../@MACRO/VIEW_CONTENT-BASE.vue.ftl ../@MACRO/VIEW_CONTENT-BASE.vue.ftl
</#ibizinclude> </#ibizinclude>
/**
* 视图唯一标识
*
* @type {string}
* @memberof ${srfclassname('${view.name}')}Base
*/
public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}';
<#ibizinclude> <#ibizinclude>
../@MACRO/VIEW_BOTTOM-BASE.vue.ftl ../@MACRO/VIEW_BOTTOM-BASE.vue.ftl
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* 搜索值 * 搜索值
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public query: string = ''; public query: string = '';
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
* 是否展开搜索表单 * 是否展开搜索表单
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c}; public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c};
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
* 快速搜索 * 快速搜索
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onSearch($event: any): void { public onSearch($event: any): void {
const refs: any = this.$refs; const refs: any = this.$refs;
......
...@@ -58,11 +58,19 @@ if(!Object.is(newVal, oldVal) ){ ...@@ -58,11 +58,19 @@ if(!Object.is(newVal, oldVal) ){
../@MACRO/VIEW_CONTENT-BASE.vue.ftl ../@MACRO/VIEW_CONTENT-BASE.vue.ftl
</#ibizinclude> </#ibizinclude>
/**
* 界面关系通讯对象
*
* @type {Subject<ViewState>}
* @memberof ${srfclassname('${view.name}')}Base
*/
@Prop() public formDruipart!: Subject<ViewState>;
/** /**
* 刷新数据参数 * 刷新数据参数
* *
* @type {number} * @type {number}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
@Prop() public saveRefView?: number; @Prop() public saveRefView?: number;
...@@ -70,7 +78,7 @@ if(!Object.is(newVal, oldVal) ){ ...@@ -70,7 +78,7 @@ if(!Object.is(newVal, oldVal) ){
* 关系数据变化 * 关系数据变化
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onViewDataDirty($event: any) { public onViewDataDirty($event: any) {
this.$emit('drdatachange', $event); this.$emit('drdatachange', $event);
...@@ -80,7 +88,7 @@ if(!Object.is(newVal, oldVal) ){ ...@@ -80,7 +88,7 @@ if(!Object.is(newVal, oldVal) ){
* 关系数据保存执行完成 * 关系数据保存执行完成
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onDRDataSaved($event: any) { public onDRDataSaved($event: any) {
this.$emit('drdatasaved', $event); this.$emit('drdatasaved', $event);
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
* 是否显示按钮 * 是否显示按钮
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
@Prop({default: true}) public isShowButton!: boolean; @Prop({default: true}) public isShowButton!: boolean;
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
* 选中数据的字符串 * 选中数据的字符串
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public selectedData: string = ""; public selectedData: string = "";
...@@ -39,25 +39,23 @@ ...@@ -39,25 +39,23 @@
* 是否初始化已选中项 * 是否初始化已选中项
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isInitSelected:boolean = false; public isInitSelected:boolean = false;
/** /**
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {any[]}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isSingleSelect: boolean = false; public isSingleSelect: boolean = false;
/** /**
* 视图参数变更 * 视图参数变更
* *
* @protected * @type {boolean}
* @param {*} newVal * @memberof ${srfclassname('${view.name}')}Base
* @param {*} oldVal
* @memberof ${srfclassname('${view.name}')}
*/ */
protected viewParamChange(newVal: any, oldVal: any): void { protected viewParamChange(newVal: any, oldVal: any): void {
if(this.viewparams.selectedData){ if(this.viewparams.selectedData){
...@@ -82,7 +80,7 @@ ...@@ -82,7 +80,7 @@
* 选中数据单击 * 选中数据单击
* *
* @param {*} item * @param {*} item
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public selectionsClick(item:any):void { public selectionsClick(item:any):void {
item._select = !item._select; item._select = !item._select;
...@@ -94,7 +92,7 @@ ...@@ -94,7 +92,7 @@
* 选中树双击 * 选中树双击
* *
* @param {*} item * @param {*} item
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public selectionsDBLClick(item:any):void { public selectionsDBLClick(item:any):void {
const index: number = this.viewSelections.findIndex((selection: any) => Object.is(selection.srfkey, item.srfkey)); const index: number = this.viewSelections.findIndex((selection: any) => Object.is(selection.srfkey, item.srfkey));
...@@ -109,7 +107,7 @@ ...@@ -109,7 +107,7 @@
/** /**
* 删除右侧全部选中数据 * 删除右侧全部选中数据
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onCLickLeft():void { public onCLickLeft():void {
const _selectiions = [...JSON.parse(JSON.stringify(this.viewSelections))]; const _selectiions = [...JSON.parse(JSON.stringify(this.viewSelections))];
...@@ -130,7 +128,7 @@ ...@@ -130,7 +128,7 @@
/** /**
* 添加左侧选中数据 * 添加左侧选中数据
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onCLickRight():void { public onCLickRight():void {
Object.values(this.containerModel).forEach((model: any) => { Object.values(this.containerModel).forEach((model: any) => {
...@@ -156,7 +154,7 @@ ...@@ -156,7 +154,7 @@
/** /**
* 选中数据全部删除 * 选中数据全部删除
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onCLickAllLeft():void { public onCLickAllLeft():void {
this.viewSelections = []; this.viewSelections = [];
...@@ -168,7 +166,7 @@ ...@@ -168,7 +166,7 @@
/** /**
* 添加左侧面板所有数据到右侧 * 添加左侧面板所有数据到右侧
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onCLickAllRight():void { public onCLickAllRight():void {
Object.values(this.containerModel).forEach((model: any) => { Object.values(this.containerModel).forEach((model: any) => {
...@@ -195,7 +193,7 @@ ...@@ -195,7 +193,7 @@
/** /**
* 确定 * 确定
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onClickOk(): void { public onClickOk(): void {
this.$emit('viewdataschange', this.viewSelections); this.$emit('viewdataschange', this.viewSelections);
...@@ -205,7 +203,7 @@ ...@@ -205,7 +203,7 @@
/** /**
* 取消 * 取消
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onClickCancel(): void { public onClickCancel(): void {
this.$emit('close', null); this.$emit('close', null);
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
* 选中数据的字符串 * 选中数据的字符串
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public selectedData: string = ""; public selectedData: string = "";
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* 视图选中数据 * 视图选中数据
* *
* @type {any[]} * @type {any[]}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public viewSelections:any[] = []; public viewSelections:any[] = [];
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
* 是否显示按钮 * 是否显示按钮
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
@Prop({default: true}) public isShowButton!: boolean; @Prop({default: true}) public isShowButton!: boolean;
...@@ -31,14 +31,14 @@ ...@@ -31,14 +31,14 @@
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isSingleSelect: boolean = true; public isSingleSelect: boolean = true;
/** /**
* 确定 * 确定
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onClickOk(): void { public onClickOk(): void {
this.$emit('viewdataschange', this.viewSelections); this.$emit('viewdataschange', this.viewSelections);
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
/** /**
* 取消 * 取消
* *
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onClickCancel(): void { public onClickCancel(): void {
this.$emit('close', null); this.$emit('close', null);
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* 视图唯一标识 * 视图唯一标识
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}'; public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}';
......
...@@ -27,7 +27,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -27,7 +27,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 搜索值 * 搜索值
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public query: string = ''; public query: string = '';
...@@ -35,7 +35,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -35,7 +35,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 是否展开搜索表单 * 是否展开搜索表单
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c}; public isExpandSearchForm: boolean = ${view.isExpandSearchForm()?c};
...@@ -43,7 +43,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -43,7 +43,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* 快速搜索 * 快速搜索
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onSearch($event: any): void { public onSearch($event: any): void {
const refs: any = this.$refs; const refs: any = this.$refs;
...@@ -56,7 +56,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -56,7 +56,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* calendar 的 beforeload 事件 * calendar 的 beforeload 事件
* *
* @param {*} arg * @param {*} arg
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onBeforeLoad(arg: any){ public onBeforeLoad(arg: any){
let _this:any = this; let _this:any = this;
...@@ -71,11 +71,11 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -71,11 +71,11 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
} }
// 快速分组和快速搜索栏 // 快速分组和快速搜索栏
let otherQueryParam:any = {}; let otherQueryParam:any = {};
if(_this && (_this.qucikGroupData as any)){ if(_this && (_this.quickGroupData as any)){
Object.assign(otherQueryParam,_this.qucikGroupData); Object.assign(otherQueryParam,_this.quickGroupData);
} }
if(_this && _this.qucikFormData){ if(_this && _this.quickFormData){
Object.assign(otherQueryParam,_this.qucikFormData); Object.assign(otherQueryParam,_this.quickFormData);
} }
Object.assign(arg,{viewparams:otherQueryParam}); Object.assign(arg,{viewparams:otherQueryParam});
} }
...@@ -84,7 +84,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -84,7 +84,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* searchform 部件 search 事件 * searchform 部件 search 事件
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public searchform_search($event: any) { public searchform_search($event: any) {
this.onSearch($event); this.onSearch($event);
...@@ -94,7 +94,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -94,7 +94,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* searchform 部件 load 事件 * searchform 部件 load 事件
* *
* @param {*} $event * @param {*} $event
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public searchform_load($event: any) { public searchform_load($event: any) {
this.onSearch($event); this.onSearch($event);
...@@ -126,7 +126,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -126,7 +126,7 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupData:any; public quickGroupData:any;
/** /**
* 快速分组是否有抛值 * 快速分组是否有抛值
...@@ -200,9 +200,9 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -200,9 +200,9 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikGroupValueChange($event:any){ public quickGroupValueChange($event:any){
if($event && $event.data){ if($event && $event.data){
this.qucikGroupData = $event.data; this.quickGroupData = $event.data;
if(this.isEmitQuickGroupValue){ if(this.isEmitQuickGroupValue){
this.onSearch($event); this.onSearch($event);
} }
...@@ -217,15 +217,15 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co ...@@ -217,15 +217,15 @@ import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/co
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormData:any; public quickFormData:any;
/** /**
* 快速搜索栏值变化 * 快速搜索栏值变化
* *
* @memberof ${srfclassname('${view.name}')}Base * @memberof ${srfclassname('${view.name}')}Base
*/ */
public qucikFormValueChange($event:any){ public quickFormValueChange($event:any){
this.qucikFormData = $event; this.quickFormData = $event;
this.onSearch($event); this.onSearch($event);
} }
</#if> </#if>
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* 视图唯一标识 * 视图唯一标识
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}'; public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}';
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
* 节点过滤值 * 节点过滤值
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public srfnodefilter: string = ''; public srfnodefilter: string = '';
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
* 快速搜索 * 快速搜索
* *
* @returns {void} * @returns {void}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public onSearch(): void { public onSearch(): void {
if (!this.viewState) { if (!this.viewState) {
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isSingleSelect: boolean = ${dataview.isSingleSelect()?c}; public isSingleSelect: boolean = ${dataview.isSingleSelect()?c};
</#if> </#if>
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* 选中数据 * 选中数据
* *
* @type {*} * @type {*}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public selection: any = {}; public selection: any = {};
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
* 视图唯一标识 * 视图唯一标识
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}'; public viewUID: string = '${srffilepath2(view.getPSAppModule().getCodeName())}-${srffilepath2(view.getCodeName())}';
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
* 选中数据字符串 * 选中数据字符串
* *
* @type {string} * @type {string}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
@Prop() public selectedData?: string; @Prop() public selectedData?: string;
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
* 是否单选 * 是否单选
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
@Prop() public isSingleSelect?: boolean; @Prop() public isSingleSelect?: boolean;
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
* 应用起始页面 * 应用起始页面
* *
* @type {boolean} * @type {boolean}
* @memberof ${srfclassname('${view.name}')} * @memberof ${srfclassname('${view.name}')}Base
*/ */
public isDefaultPage: boolean = ${view.isDefaultPage()?c}; public isDefaultPage: boolean = ${view.isDefaultPage()?c};
......
...@@ -14,44 +14,47 @@ export default { ...@@ -14,44 +14,47 @@ export default {
<#-- local langue english --> <#-- local langue english -->
app: { app: {
commonWords:{ commonWords:{
error: 'Error', error: "Error",
success: 'Success', success: "Success",
ok: 'OK', ok: "OK",
cancel: 'Cancel', cancel: "Cancel",
},
local:{
new: "New"
}, },
local:{ local:{
new: 'New' new: 'New'
}, },
gridpage: { gridpage: {
choicecolumns: 'Choice columns', choicecolumns: "Choice columns",
refresh: 'refresh', refresh: "refresh",
show: 'Show', show: "Show",
records: 'records', records: "records",
totle: 'totle', totle: "totle",
}, },
tabpage: { tabpage: {
sureclosetip: { sureclosetip: {
title: 'Close warning', title: "Close warning",
content: 'Form data Changed, are sure close?', content: "Form data Changed, are sure close?",
}, },
closeall: 'Close all', closeall: "Close all",
closeother: 'Close other', closeother: "Close other",
}, },
fileUpload: { fileUpload: {
caption: 'Upload', caption: "Upload",
}, },
searchButton: { searchButton: {
search: 'Search', search: "Search",
reset: 'Reset', reset: "Reset",
}, },
calendar:{ calendar:{
today: 'today', today: "today",
month: 'month', month: "month",
week: 'week', week: "week",
day: 'day', day: "day",
list: 'list', list: "list",
dateSelectModalTitle: 'select the time you wanted', dateSelectModalTitle: "select the time you wanted",
gotoDate: 'goto', gotoDate: "goto",
}, },
// 非实体视图 // 非实体视图
views: { views: {
...@@ -60,8 +63,8 @@ export default { ...@@ -60,8 +63,8 @@ export default {
<#list allAppViews as obj> <#list allAppViews as obj>
<#if !obj.isPSDEView()> <#if !obj.isPSDEView()>
${obj.getCodeName()?lower_case}: { ${obj.getCodeName()?lower_case}: {
caption: '<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>', caption: "<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
title: '<@getTitleLanguage obj langrestype />', title: "<@getTitleLanguage obj langrestype />",
}, },
</#if> </#if>
</#list> </#list>
...@@ -76,7 +79,7 @@ export default { ...@@ -76,7 +79,7 @@ export default {
<#list app.getAllPSAppMenuModels() as menu> <#list app.getAllPSAppMenuModels() as menu>
${menu.getCodeName()?lower_case}: { ${menu.getCodeName()?lower_case}: {
<#list menu.getAllPSAppMenuItems() as obj> <#list menu.getAllPSAppMenuItems() as obj>
${obj.getName()?lower_case}: '<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>', ${obj.getName()?lower_case}: "<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
</#list> </#list>
}, },
</#list> </#list>
......
...@@ -14,44 +14,47 @@ export default { ...@@ -14,44 +14,47 @@ export default {
<#-- 本地化语言资源 中文 --> <#-- 本地化语言资源 中文 -->
app: { app: {
commonWords:{ commonWords:{
error: '失败', error: "失败",
success: '成功', success: "成功",
ok: '确认', ok: "确认",
cancel: '取消', cancel: "取消",
},
local:{
new: "新建"
}, },
local:{ local:{
new: '新建' new: '新建'
}, },
gridpage: { gridpage: {
choicecolumns: '选择列', choicecolumns: "选择列",
refresh: '刷新', refresh: "刷新",
show: '显示', show: "显示",
records: '条', records: "条",
totle: '共', totle: "共",
}, },
tabpage: { tabpage: {
sureclosetip: { sureclosetip: {
title: '关闭提醒', title: "关闭提醒",
content: '表单数据已经修改,确定要关闭?', content: "表单数据已经修改,确定要关闭?",
}, },
closeall: '关闭所有', closeall: "关闭所有",
closeother: '关闭其他', closeother: "关闭其他",
}, },
fileUpload: { fileUpload: {
caption: '上传', caption: "上传",
}, },
searchButton: { searchButton: {
search: '搜索', search: "搜索",
reset: '重置', reset: "重置",
}, },
calendar:{ calendar:{
today: '今天', today: "今天",
month: '月', month: "月",
week: '周', week: "周",
day: '天', day: "天",
list: '列', list: "列",
dateSelectModalTitle: '选择要跳转的时间', dateSelectModalTitle: "选择要跳转的时间",
gotoDate: '跳转', gotoDate: "跳转",
}, },
// 非实体视图 // 非实体视图
views: { views: {
...@@ -60,8 +63,8 @@ export default { ...@@ -60,8 +63,8 @@ export default {
<#list allAppViews as obj> <#list allAppViews as obj>
<#if !obj.isPSDEView()> <#if !obj.isPSDEView()>
${obj.getCodeName()?lower_case}: { ${obj.getCodeName()?lower_case}: {
caption: '<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>', caption: "<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
title: '<@getTitleLanguage obj langrestype />', title: "<@getTitleLanguage obj langrestype />",
}, },
</#if> </#if>
</#list> </#list>
...@@ -76,7 +79,7 @@ export default { ...@@ -76,7 +79,7 @@ export default {
<#list app.getAllPSAppMenuModels() as menu> <#list app.getAllPSAppMenuModels() as menu>
${menu.getCodeName()?lower_case}: { ${menu.getCodeName()?lower_case}: {
<#list menu.getAllPSAppMenuItems() as obj> <#list menu.getAllPSAppMenuItems() as obj>
${obj.getName()?lower_case}: '<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>', ${obj.getName()?lower_case}: "<#ibizinclude>../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
</#list> </#list>
}, },
</#list> </#list>
......
...@@ -10,14 +10,14 @@ export default { ...@@ -10,14 +10,14 @@ export default {
${codelist.codeName}: { ${codelist.codeName}: {
<#if codelist.getAllPSCodeItems?? && codelist.getAllPSCodeItems()??> <#if codelist.getAllPSCodeItems?? && codelist.getAllPSCodeItems()??>
<#list codelist.getAllPSCodeItems() as codeitem> <#list codelist.getAllPSCodeItems() as codeitem>
'${codeitem.getValue()?j_string}': '<@getTextLanguage codeitem langrestype />', "${codeitem.getValue()?j_string}": "<@getTextLanguage codeitem langrestype />",
</#list> </#list>
</#if> </#if>
empty: '<@getEmptyTextLanguage codelist langrestype '' />', "empty": "<@getEmptyTextLanguage codelist langrestype '' />"
}, },
<#elseif codelist.getCodeListType() == "DYNAMIC"> <#elseif codelist.getCodeListType() == "DYNAMIC">
${codelist.codeName}: { ${codelist.codeName}: {
empty: '<@getEmptyTextLanguage codelist langrestype '' />', "empty": "<@getEmptyTextLanguage codelist langrestype '' />",
}, },
</#if> </#if>
</#list> </#list>
......
...@@ -10,14 +10,14 @@ export default { ...@@ -10,14 +10,14 @@ export default {
${codelist.codeName}: { ${codelist.codeName}: {
<#if codelist.getAllPSCodeItems?? && codelist.getAllPSCodeItems()??> <#if codelist.getAllPSCodeItems?? && codelist.getAllPSCodeItems()??>
<#list codelist.getAllPSCodeItems() as codeitem> <#list codelist.getAllPSCodeItems() as codeitem>
'${codeitem.getValue()?j_string}': '<@getTextLanguage codeitem langrestype />', "${codeitem.getValue()?j_string}": "<@getTextLanguage codeitem langrestype />",
</#list> </#list>
</#if> </#if>
empty: '<@getEmptyTextLanguage codelist langrestype '' />', "empty": "<@getEmptyTextLanguage codelist langrestype '' />",
}, },
<#elseif codelist.getCodeListType() == "DYNAMIC"> <#elseif codelist.getCodeListType() == "DYNAMIC">
${codelist.codeName}: { ${codelist.codeName}: {
empty: '<@getEmptyTextLanguage codelist langrestype '' />', "empty": "<@getEmptyTextLanguage codelist langrestype '' />",
}, },
</#if> </#if>
</#list> </#list>
......
...@@ -9,7 +9,7 @@ export default { ...@@ -9,7 +9,7 @@ export default {
<#if item.getAllPSAppDEFields()??> <#if item.getAllPSAppDEFields()??>
fields: { fields: {
<#list item.getAllPSAppDEFields() as field> <#list item.getAllPSAppDEFields() as field>
${field.getPSDEField().getCodeName()?lower_case}: '<@getLogicNameLanguage field.getPSDEField() langrestype />', ${field.getPSDEField().getCodeName()?lower_case}: "<@getLogicNameLanguage field.getPSDEField() langrestype />",
</#list> </#list>
}, },
</#if> </#if>
...@@ -19,7 +19,7 @@ export default { ...@@ -19,7 +19,7 @@ export default {
<#list item.getAllPSAppViews() as obj> <#list item.getAllPSAppViews() as obj>
${obj.getPSDEViewCodeName()?lower_case}: { ${obj.getPSDEViewCodeName()?lower_case}: {
caption: "<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>", caption: "<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
title: '<@getTitleLanguage obj langrestype />', title: "<@getTitleLanguage obj langrestype />",
}, },
</#list> </#list>
}, },
...@@ -62,7 +62,7 @@ export default { ...@@ -62,7 +62,7 @@ export default {
<#if ctrl.getPSDETreeNodes()??> <#if ctrl.getPSDETreeNodes()??>
<#list ctrl.getPSDETreeNodes() as obj> <#list ctrl.getPSDETreeNodes() as obj>
<#if obj.getTreeNodeType() == 'STATIC'> <#if obj.getTreeNodeType() == 'STATIC'>
${obj.getNodeType()?lower_case}: '<@getNameLanguage obj langrestype />', ${obj.getNodeType()?lower_case}: "<@getNameLanguage obj langrestype />",
</#if> </#if>
</#list> </#list>
</#if> </#if>
......
...@@ -8,7 +8,7 @@ export default { ...@@ -8,7 +8,7 @@ export default {
<#if item.getAllPSAppDEFields()??> <#if item.getAllPSAppDEFields()??>
fields: { fields: {
<#list item.getAllPSAppDEFields() as field> <#list item.getAllPSAppDEFields() as field>
${field.getPSDEField().getCodeName()?lower_case}: '<@getLogicNameLanguage field.getPSDEField() langrestype />', ${field.getPSDEField().getCodeName()?lower_case}: "<@getLogicNameLanguage field.getPSDEField() langrestype />",
</#list> </#list>
}, },
</#if> </#if>
...@@ -17,8 +17,8 @@ export default { ...@@ -17,8 +17,8 @@ export default {
views: { views: {
<#list item.getAllPSAppViews() as obj> <#list item.getAllPSAppViews() as obj>
${obj.getPSDEViewCodeName()?lower_case}: { ${obj.getPSDEViewCodeName()?lower_case}: {
caption: '<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>', caption: "<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
title: '<@getTitleLanguage obj langrestype />', title: "<@getTitleLanguage obj langrestype />",
}, },
</#list> </#list>
}, },
...@@ -34,7 +34,7 @@ export default { ...@@ -34,7 +34,7 @@ export default {
<#if ctrl.getControlType() == 'FORM' || ctrl.getControlType() == 'SEARCHFORM'> <#if ctrl.getControlType() == 'FORM' || ctrl.getControlType() == 'SEARCHFORM'>
details: { details: {
<#list ctrl.getAllPSDEFormDetails() as obj> <#list ctrl.getAllPSDEFormDetails() as obj>
${obj.name?lower_case}: '<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>', ${obj.name?lower_case}: "<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
</#list> </#list>
}, },
</#if> </#if>
...@@ -42,7 +42,7 @@ export default { ...@@ -42,7 +42,7 @@ export default {
columns: { columns: {
<#if ctrl.getAllPSDEGridColumns()??> <#if ctrl.getAllPSDEGridColumns()??>
<#list ctrl.getAllPSDEGridColumns() as obj> <#list ctrl.getAllPSDEGridColumns() as obj>
${obj.getName()?lower_case}: '<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>', ${obj.getName()?lower_case}: "<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
</#list> </#list>
</#if> </#if>
}, },
...@@ -61,7 +61,7 @@ export default { ...@@ -61,7 +61,7 @@ export default {
<#if ctrl.getPSDETreeNodes()??> <#if ctrl.getPSDETreeNodes()??>
<#list ctrl.getPSDETreeNodes() as obj> <#list ctrl.getPSDETreeNodes() as obj>
<#if obj.getTreeNodeType() == 'STATIC'> <#if obj.getTreeNodeType() == 'STATIC'>
${obj.getNodeType()?lower_case}: '<@getNameLanguage obj langrestype />', ${obj.getNodeType()?lower_case}: "<@getNameLanguage obj langrestype />",
</#if> </#if>
</#list> </#list>
</#if> </#if>
...@@ -71,8 +71,8 @@ export default { ...@@ -71,8 +71,8 @@ export default {
<#if ctrl.getAllPSDEToolbarItems()??> <#if ctrl.getAllPSDEToolbarItems()??>
<#list ctrl.getAllPSDEToolbarItems() as obj> <#list ctrl.getAllPSDEToolbarItems() as obj>
${obj.getName()?lower_case}: { ${obj.getName()?lower_case}: {
caption: '<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>', caption: "<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
tip: '<#ibizinclude>../../../@MACRO/TIPLANG.ts</#ibizinclude>', tip: "<#ibizinclude>../../../@MACRO/TIPLANG.ts</#ibizinclude>",
}, },
</#list> </#list>
</#if> </#if>
...@@ -81,7 +81,7 @@ export default { ...@@ -81,7 +81,7 @@ export default {
<#if ctrl.getPSUIActions?? && ctrl.getPSUIActions()??> <#if ctrl.getPSUIActions?? && ctrl.getPSUIActions()??>
uiactions: { uiactions: {
<#list ctrl.getPSUIActions() as obj> <#list ctrl.getPSUIActions() as obj>
${obj.getUIActionTag()?lower_case}: '<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>', ${obj.getUIActionTag()?lower_case}: "<#ibizinclude>../../../@MACRO/CAPTIONLANG.ts</#ibizinclude>",
</#list> </#list>
}, },
</#if> </#if>
......
...@@ -14,16 +14,16 @@ mock.onGet('./assets/json/data-dictionary.json').reply((config: any) => { ...@@ -14,16 +14,16 @@ mock.onGet('./assets/json/data-dictionary.json').reply((config: any) => {
<#list app.getAllPSAppCodeLists() as codelist> <#list app.getAllPSAppCodeLists() as codelist>
{ {
<#if codelist.getCodeListType() == "STATIC" && codelist.getAllPSCodeItems()??> <#if codelist.getCodeListType() == "STATIC" && codelist.getAllPSCodeItems()??>
srfkey: '${codelist.codeName}', srfkey: "${codelist.codeName}",
emptytext: '${codelist.getEmptyText()}', emptytext: "${codelist.getEmptyText()}",
"codelisttype":"static", "codelisttype":"static",
items: [ items: [
<#if codelist.getAllPSCodeItems()??> <#if codelist.getAllPSCodeItems()??>
<#list codelist.getAllPSCodeItems() as codeitem> <#list codelist.getAllPSCodeItems() as codeitem>
{ {
id: '${codeitem.getValue()?j_string}', id: "${codeitem.getValue()?j_string}",
label: '${codeitem.getText()?j_string}', label: "${codeitem.getText()?j_string}",
text: '${codeitem.getText()?j_string}', text: "${codeitem.getText()?j_string}",
<#if codeitem.getPSSysImage()??> <#if codeitem.getPSSysImage()??>
<#assign sysimage = codeitem.getPSSysImage()/> <#assign sysimage = codeitem.getPSSysImage()/>
<#if sysimage.getImagePath() == ""> <#if sysimage.getImagePath() == "">
...@@ -44,7 +44,7 @@ mock.onGet('./assets/json/data-dictionary.json').reply((config: any) => { ...@@ -44,7 +44,7 @@ mock.onGet('./assets/json/data-dictionary.json').reply((config: any) => {
value: ${codeitem.getValue()?j_string}, value: ${codeitem.getValue()?j_string},
<#if codeitem.getParentCodeItem()??><#assign parentCodeItem = codeitem.getParentCodeItem() />"pvalue": ${parentCodeItem.getValue()?j_string},</#if> <#if codeitem.getParentCodeItem()??><#assign parentCodeItem = codeitem.getParentCodeItem() />"pvalue": ${parentCodeItem.getValue()?j_string},</#if>
<#else> <#else>
value: '${codeitem.getValue()?j_string}', value: "${codeitem.getValue()?j_string}",
<#if codeitem.getParentCodeItem()??><#assign parentCodeItem = codeitem.getParentCodeItem() />"pvalue": "${parentCodeItem.getValue()?j_string}",</#if> <#if codeitem.getParentCodeItem()??><#assign parentCodeItem = codeitem.getParentCodeItem() />"pvalue": "${parentCodeItem.getValue()?j_string}",</#if>
</#if> </#if>
disabled: <#if codeitem.isDisableSelect()>true<#else>false</#if>, disabled: <#if codeitem.isDisableSelect()>true<#else>false</#if>,
......
<#ibiztemplate>
TARGET=PSAPPVIEWCTRL_SEARCHBAR
</#ibiztemplate>
${P.getCtrlCode('CONTROL-BASE.vue').code}
\ No newline at end of file
<#ibiztemplate>
TARGET=PSAPPVIEWCTRL_SEARCHBAR
</#ibiztemplate>
${P.getCtrlCode('MODEL.ts').code}
\ No newline at end of file
<#ibiztemplate>
TARGET=PSAPPVIEWCTRL_SEARCHBAR
</#ibiztemplate>
${P.getCtrlCode('SERVICE.ts').code}
\ No newline at end of file
<#ibiztemplate>
TARGET=PSAPPVIEWCTRL_SEARCHBAR
</#ibiztemplate>
${P.getCtrlCode('CONTROL.less').code}
\ No newline at end of file
<#ibiztemplate>
TARGET=PSAPPVIEWCTRL_SEARCHBAR
</#ibiztemplate>
${P.getCtrlCode('CONTROL.vue').code}
\ No newline at end of file
...@@ -487,4 +487,419 @@ uaa菜单权限 ...@@ -487,4 +487,419 @@ uaa菜单权限
## v7.0.0-alpha.1 [2020-4-29] ## v7.0.0-alpha.1 [2020-4-29]
初始化文件 ### Bug修复
修复标题工具栏样式遮挡bug
修复表格行编辑字段格式对齐
修复日历部件初始化压缩成一行问题
修复下拉多选组件最后一项数据无法删除
### 功能新增及优化
#### 模板
新增支持表单、表格新建默认值(当前时间)
新增行编辑浮点数精度格式化
新增首页面包屑导航模式
新增编辑视图第一条记录、上一条记录、下一条记录、最后一条记录界面行为
优化面板和多数据部件数据流向
优化表单在模态打开模式中padding样式
优化嵌入视图中工具栏消息数量提示样式
优化动态导航视图树样式
#### 基础文件
新增行编辑浮点数精度格式化
## v7.0.0-alpha.10 [2020-6-18]
### Bug修复
分页导航视图页面刷新bug
表单项更新,实体行为调用不到bug
关系界面子界面保存不触发父界面保存
表单样式调整
### 功能新增及优化
#### 模板
表格操作列只显示图标时显示tooltip
门户部件高度为0时自适应
面板和多数据部件数据流向
列表,数据视图保存功能
门户部件标题界面行为tooltip
新增面包屑、应用切换器组件
#### 基础文件
formitem样式调整,label适配位置
表格行编辑切换,app-picker不显示
文件上传下载参数格式处理
## v7.0.0-alpha.9 [2020-6-11]
### Bug修复
数值代码表多语言
树右键菜单滚动条样式bug
列表面板界面行为bug
多选视图界面逻辑修复
图表刷新bug修复
日历部件选中抛出数据逻辑调整
编辑视图,app-span显示0时不显示
树视图右键界面行为刷新bug
快捷菜单控制台报错bug
门户加载自定义模型错误时,正常显示默认看板
修复雷达图显示异常问题
修复编辑类、分页导航视图带数据标题问题
修复饼图、漏斗图 获取序列参数错误问题
### 功能新增及优化
#### 模板
看板和门户布局模板调整,支持门户部件标题栏界面行为组
支持数据选择、地址框、自动完成、下拉列表、标签、选项框列表、单选列表等编辑器导航参数调整
支持树导航栏、表格导航栏、列表导航栏、卡片导航栏、日历导航栏、表单关系界面、数据选择面板、分页导航面板、数据关系栏、界面行为、新建逻辑、编辑逻辑导航参数调整
支持图表无数据时显示暂无数据
支持表格新建默认值
支持日历部件右键菜单
支持表格列触发界面行为
面板布局调整
#### 基础文件
门户部件视图的样式
数据选择,地址框,自动完成,下拉列表,标签,选项框列表,单选列表等编辑器导航参数调整
表单项label位置
调整登录页面
穿梭框编辑器支持
## v7.0.0-alpha.8 [2020-6-4]
### Bug修复
修复树右键菜单事件传值bug
修复树节点图标样式
修复viewdata和viewparams解析不同步
修复界面行为多主键分隔符由";"改为","
修复多层导航失效
数据选择,自动填充编辑器参数处理,动态代码表编辑器参数
修复富文本国际化bug
修复坐标轴的自定义参数
修复分页面板配置导航参数
修复实体处理逻辑
修复应用级context对象特性丢失的问题
修复新建逻辑
修复动态代码表传递上下文、参数逻辑
### 功能新增及优化
#### 模板
树选择双击
列表快速分组和快速搜索表单
数据视图快速分组和快速搜索表单
日历图例、日历快速分组和批处理工具栏
实体国际化路径调整
面板界面行为支持
列表,数据视图下拉加载
增加图表名称代码表识别、雷达图支持
uaa菜单权限
增加数据看板动态模型数据存库
应用样式调整
#### 基础文件
人员选择标准控件样式调整
应用样式调整
## v7.0.0-alpha.7 [2020-5-28]
### Bug修复
修复门户部件flex布局
修复表格选择框列样式出现省略号
修复批删除传递参数调整
修复表单上界面行为参数传递bug
修复分页导航、编辑类视图标题
修复界面行为多主键分隔符由";"改为","
修复导航类视图宽度格式
修复图表排序
修复关系界面逻辑
修复401跳登录页清除user和token
### 功能新增及优化
#### 模板
列表,数据视图默认排序
面板项支持偏移
应用支持自定义默认端口
门户部件图标和容器样式
表格列头图片和头部样式
表格操作列图标
表格编辑项值规则
增加树选择双击事件
增加图表分组属性计数统计(srfcount)
增加雷达图支持
#### 基础文件
修复分页导航、编辑类视图标题
修复界面行为多主键分隔符由";"改为","
修复关系界面逻辑
修复401跳登录页清除user和token
## v7.0.0-alpha.6 [2020-5-23]
### Bug修复
修复处理快速分组模型动态数据部分
修复列表,数据视图默认排序
### 功能新增及优化
#### 模板
补充单位选择器、部门选择器、人员选择器
#### 基础文件
补充单位选择器、部门选择器、人员选择器
## v7.0.0-alpha.5 [2020-5-21]
### Bug修复
修复表格视图搜索placeholder显示为搜索字段
修复表单嵌表单分页异常
修复门户视图操作栏标题
修复看板部件高度自动撑
修复表单分组,界面行为组不显示
修复表格操作列数据异常
### 功能新增及优化
#### 模板
支持拷贝功能
支持实体甘特图视图
支持面板项隐藏表单项
支持表格列最小宽度和操作列样式支持
支持列表项、面板代码表转化
#### 基础文件
支持列表项、面板代码表转化
修复表单分组,界面行为组不显示
## v7.0.0-alpha.4 [2020-5-14]
### Bug修复
修复代码表代码项图标和数据
修复数据多项选择视图UI逻辑不匹配
修复列表高度异常
修复树节点上下文
修复表格(视图)高度,滚动条问题
修复表单loaddraft服务仿真主键丢失修复
修复user显示名称逻辑
修复issue地址为正式环境地址
### 功能新增及优化
#### 模板
模态时视图样式调整
增加菜单权限
增加快速分组搜索或快速搜索表单功能
增加表格内置工具栏
代码表多选控件分割符从分号转化为逗号
#### 基础文件
增加数据选择类插件表格呈现插件
## v7.0.0-alpha.3 [2020-5-10]
### Bug修复
分页导航栏传递srfparentdename和srfparentkey问题
提交流程、启动流程刷新表格数据问题
修复视图自定义导航参数大小写问题
修复批添加功能
修复树部件查询数据集合异常处理
修复图表排序问题
修复富文本国际化切换失效
### 功能新增及优化
#### 模板
搜索面板布局优化
表格checkbox宽度优化
选择类视图不显示标题
补充树节点关系导航上下文,导航参数上下文
#### 基础文件
登录页面调整
## v7.0.0-alpha.2 [2020-5-7]
### Bug修复
分页导航栏添加图标配置
### 功能新增及优化
#### 模板
表格文件上传信息显示
批添加、批删除
实体工作流动态视图
实体工作流动态导航表格视图
富文本信息模式
更新默认值
#### 基础文件
表格文件上传信息显示
实体工作流动态视图
实体工作流动态导航表格视图
## v7.0.0-alpha.1 [2020-4-29]
初始化文件
\ No newline at end of file
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册