提交 4a1968db 编写于 作者: tony001's avatar tony001

2020.5.28 更新

上级 bff128fc
......@@ -156,7 +156,7 @@ export default class <#if ctrl.getPSAppDataEntity()??>${srfclassname('${ctrl.get
<#else>
<#if ctrlLogic.getEventArg()?? && ctrlLogic.getEventArg()?length gt 0>
if (Object.is($event.tag, '${ctrlLogic.getEventArg()}')) {
this.${ctrlLogic.name}($event, '<#if ctrlLogic.getLogicTag()?length gt 0>${ctrlLogic.getLogicTag()}</#if>', $event2);
this.${ctrlLogic.name}(null, '<#if ctrlLogic.getLogicTag()?length gt 0>${ctrlLogic.getLogicTag()}</#if>', $event2);
}
<#else>
this.${ctrlLogic.name}($event, '<#if ctrlLogic.getLogicTag()?length gt 0>${ctrlLogic.getLogicTag()}</#if>', $event2);
......
......@@ -133,6 +133,22 @@
*/
public totalRecord: number = 0;
/**
* 排序方向
*
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>';
/**
* 排序字段
*
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>';
/**
* 选中数组
* @type {Array<any>}
......@@ -254,11 +270,18 @@
if (this.isEnablePagingBar) {
Object.assign(page, { page: this.curPage-1, size: this.limit });
}
// 设置排序
if (!Object.is(this.sortDir, '') && !Object.is(this.sortField, '')) {
const sort: string = this.sortField+","+this.sortDir;
Object.assign(page, { sort: sort });
}
Object.assign(arg, page);
const parentdata: any = {};
this.$emit('beforeload', parentdata);
Object.assign(arg, parentdata);
Object.assign(arg,{viewparams:this.viewparams});
let tempViewParams:any = parentdata.viewparams?parentdata.viewparams:{};
Object.assign(tempViewParams,JSON.parse(JSON.stringify(this.viewparams)));
Object.assign(arg,{viewparams:tempViewParams});
const post: Promise<any> = this.service.search(this.fetchAction, this.context?JSON.parse(JSON.stringify(this.context)):{}, arg, this.showBusyIndicator);
post.then((response: any) => {
if (!response || response.status !== 200) {
......
......@@ -65,6 +65,10 @@
name:'query',
prop:'query'
},
{
name:'sort',
prop:'sort'
},
{
name:'page',
prop:'page'
......
......@@ -88,7 +88,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()}<#else>0</#if>;
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()?c}<#else>0</#if>;
/**
* 控件高度
......@@ -96,7 +96,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()}<#else>0</#if>;
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()?c}<#else>0</#if>;
/**
* 搜素值
......
......@@ -88,7 +88,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()}<#else>0</#if>;
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()?c}<#else>0</#if>;
/**
* 控件高度
......@@ -96,7 +96,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()}<#else>0</#if>;
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()?c}<#else>0</#if>;
/**
* 搜素值
......
......@@ -361,6 +361,33 @@ new ChartBarSeries({
},
seriesLayoutBy:"${item.getSeriesLayoutBy()}"
})
<#elseif item.getEChartsType() == "radar">
new ChartRadarSeries({
name:'${item.name?lower_case}',
type:'radar',
<#if item.getIdField()??>seriesIdField:"${item.getIdField()?lower_case}",</#if>
<#if item.getSeriesField()??>seriesNameField:"${item.getSeriesField()?lower_case}",</#if>
categorField:'${item.getCatalogField()?lower_case}',
<#if item.getCatalogPSCodeList()??><#assign categorCodeList = item.getCatalogPSCodeList() />categorCodeList:{type:'${categorCodeList.getCodeListType()}',tag:'${categorCodeList.getCodeName()}',emptycode:'empty',emptytext:'${categorCodeList.getEmptyText()}'},</#if>
valueField:'${item.getValueField()?lower_case}',
seriesValues:[],
data:[],
<#if item.getPSChartDataSet()??>
<#assign chartDataSet = item.getPSChartDataSet()/>
<#if chartDataSet.getPSChartDataSetFields()??>
dataSetFields:[
<#list chartDataSet.getPSChartDataSetFields() as singleField>
{name:"${singleField.getName()?lower_case}",codelist:<#if singleField.getPSCodeList()??><#assign codelist = singleField.getPSCodeList()/>{type:"${codelist.getCodeListType()}",tag:"${codelist.getCodeName()}",emptycode:'empty',emptytext:'${codelist.getEmptyText()}'}<#else>null</#if>,isGroupField:${singleField.isGroupField()?c},groupMode:"${singleField.getGroupMode()}"}<#if singleField_has_next>,</#if>
</#list>
],
</#if>
</#if>
baseOption:{
<#if item.getBaseOptionJOString()??>
${item.getBaseOptionJOString()}
</#if>
}
})
<#else>
new ChartLineSeries({name:'${item.name?lower_case}',categorField:'${item.getCatalogField()?lower_case}',<#if item.getCatalogPSCodeList()??><#assign categorCodeList = item.getCatalogPSCodeList() />categorCodeList:{type:'${categorCodeList.getCodeListType()}',tag:'${categorCodeList.getCodeName()}'},</#if>valueField:'${item.getValueField()?lower_case}',data:[]}),
</#if>
......
<#-- 折线图序列start -->
<#if item.render??>
${item.render.code}
<#else>
{
id:'<#if item.getName()??>${item.getName()?lower_case}</#if>',
name:'<#if item.getCaption()??>${item.getCaption()}</#if>',
type:'radar',
encode:{
<#if item.getCatalogField()??>itemName:"${item.getCatalogField()}"</#if>
}<#if item.getBaseOptionJOString()??>,
${item.getBaseOptionJOString()}
</#if>
}
</#if>
<#-- 折线图序列end -->
\ No newline at end of file
......@@ -12,7 +12,7 @@
import echarts from 'echarts';
import moment from "moment";
import CodeListService from "@service/app/codelist-service";
import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,ChartBarSeries} from '@/model/chart-detail';
import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,ChartBarSeries,ChartRadarSeries} from '@/model/chart-detail';
</#assign>
<#ibizinclude>
......@@ -264,7 +264,16 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
const parentdata: any = {};
this.$emit('beforeload', parentdata);
Object.assign(arg, parentdata);
Object.assign(arg,{viewparams:this.viewparams});
Object.assign(arg,{viewparams:this.viewparams,page:0,size:1000});
<#if ctrl.getPSDEDataSet()??>
<#assign appDataSet = ctrl.getPSDEDataSet() />
<#if appDataSet.getMajorSortDir()?? && appDataSet.getMajorSortPSDEField()??>
Object.assign(arg,{sort: '${appDataSet.getMajorSortPSDEField().getCodeName()?lower_case},${appDataSet.getMajorSortDir()?lower_case}'});
</#if>
<#if appDataSet.getPageSize()??>
Object.assign(arg,{size:${appDataSet.getPageSize()}});
</#if>
</#if>
this.service.search(this.fetchAction,JSON.parse(JSON.stringify(this.context)),arg,this.showBusyIndicator).then((res) => {
if (res) {
this.transformToBasicChartSetData(res.data,() =>{_this.drawCharts()});
......@@ -327,6 +336,16 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
}
//设置多序列
let tempSeries:any = this.seriesModel[seriesName];
// 雷达图
if(tempSeries.type && Object.is(tempSeries.type,'radar') && tempSeries.seriesIdField && tempSeries.seriesValues.length > 0){
let tempIndicator:any = [];
tempSeries.seriesValues.forEach((item:any) =>{
let singleIndicatorObj:any = {name:item,max:100};
tempIndicator.push(singleIndicatorObj);
})
this.chartOption.radar = {'indicator':tempIndicator};
}else{
// 非雷达图
if(tempSeries && tempSeries.seriesIdField && tempSeries.seriesValues.length > 0){
const returnIndex:number = this.chartOption.series.findIndex((item:any) =>{
return Object.is(item.id,seriesName);
......@@ -338,8 +357,7 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
<#noparse>Object.assign(tempSeriesTemp,{name:tempSeries.seriesMap[seriesvalueItem],datasetIndex:tempSeries.seriesIndex,encode:{x:tempSeries.categorField,y:`${seriesvalueItem}`}});</#noparse>
this.chartOption.series.push(tempSeriesTemp);
})
}
}
})
}
......@@ -354,6 +372,12 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/**
* 实体数据集转化为图表数据集
*
* 1.获取图表所有代码表值
* 2.查询集合映射图表数据集
* 3.补全图表数据集
* 4.图表数据集分组求和
* 5.排序图表数据集
*
* @param {*} data 实体数据集
* @param {Function} callback 回调
* @memberof ${srfclassname('${ctrl.name}')}Base
......@@ -366,6 +390,15 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
let allCodeList:any = await this.getChartAllCodeList();
if(Object.values(this.seriesModel).length > 0){
Object.values(this.seriesModel).forEach((singleSeries:any,index:number) =>{
// 值属性为srfcount设置{srfcount:1}到data
let valueField = singleSeries.dataSetFields.find((datasetField:any) =>{
return datasetField.name === singleSeries.valueField;
});
if(valueField && valueField.name && Object.is(valueField.name,"srfcount")){
data.forEach((singleData:any) =>{
Object.assign(singleData,{srfcount:1});
})
}
// 分组属性
let groupField = singleSeries.dataSetFields.find((datasetField:any) =>{
return datasetField.name === singleSeries.categorField;
......@@ -414,6 +447,9 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
/**
* 构建图表序列数据集合
*
* 1.分组求和
* 2.排序求和数组
*
* @param {Array<any>} data 传入数据
* @param {Array<any>} item 单个序列
* @param {Array<any>} callback 回调
......@@ -573,6 +609,13 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
})
}
returnArray = this.sortReturnArray(returnArray,groupFieldModel,allCodeList);
// 雷达图数据格式处理
if(Object.is(item.type,'radar')){
returnArray.forEach((item:any) =>{
item.type = item[groupField[0]];
delete item[groupField[0]];
})
}
console.log(JSON.stringify(returnArray));
return returnArray;
}
......@@ -605,6 +648,9 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
returnArray.push(item);
}
})
returnArray.forEach((item:any) =>{
delete item.hasused;
})
}else{
// 分组为年份
if(Object.is(groupField[0].groupMode,"YEAR")){
......@@ -621,10 +667,23 @@ import { ChartDataSetField,ChartLineSeries,ChartFunnelSeries,ChartPieSeries,Char
returnArray = arr.sort((a:any, b:any) => {
return moment(a[groupField[0].name]).unix() - moment(b[groupField[0].name]).unix();
});
}else{
let groupFieldName:string = groupField[0].name;
let isConvert:boolean = true;
arr.forEach((item:any) =>{
if(isNaN(item[groupFieldName])){
isConvert = false;
}
})
if(isConvert){
returnArray = arr.sort((a:any, b:any) => {
return a[groupFieldName] - b[groupFieldName];
});
}else{
returnArray = arr;
}
}
}
return returnArray;
}
......
......@@ -10,10 +10,22 @@
*/
public getDataItems(): any[] {
return [
{
name:'size',
prop:'size'
},
{
name:'query',
prop:'query'
},
{
name:'page',
prop:'page'
},
{
name:'sort',
prop:'sort'
}
]
}
......
......@@ -4,10 +4,18 @@
<app-build @handleClick="handleClick"></app-build>
</row>
<row v-if="!isHasCustomized">
<#list ctrl.getPSPortlets() as portlet><#t>
<#list ctrl.getPSPortlets() as portlet><#t>
<#if portlet.getPortletType?? && portlet.getPortletType()??><#t>
<#assign layout='TABLE_24COL'><#if portlet.getPSLayoutPos()??><#if portlet.getPSLayoutPos().getParentPSLayout()??><#assign layout='${portlet.getPSLayoutPos().getParentPSLayout().getLayout()}'></#if></#if><#t>
<#-- BEGIN:处理参数layout,LayoutPos -->
<#assign layout='TABLE_24COL'>
<#if portlet.getPSLayoutPos()??>
<#if portlet.getPSLayoutPos().getParentPSLayout()??>
<#assign layout='${portlet.getPSLayoutPos().getParentPSLayout().getLayout()}'>
</#if>
</#if>
<#assign LayoutPos = portlet.getPSLayoutPos()><#t>
<#-- END:处理参数layout,LayoutPos -->
<#-- BEGIN:第一个门户部件前 -->
<#if portlet_index == 0 >
<#list ctrl.getPSPortlets() as container><#t>
<#if container.getPortletType() == 'CONTAINER' && layout == 'FLEX'>
......@@ -16,6 +24,8 @@
</#list>
<div style = '<#if layout == 'FLEX' > display : flex; justify-content : ${flexLayout.getAlign()}; flex-direction:${flexLayout.getDir()} ;align-items:${flexLayout.getVAlign()};flex-wrap: wrap;</#if>'>
</#if>
<#-- END:第一个门户部件前 -->
<#-- BEGIN:门户部件绘制,栅格布局 -->
<#if layout == 'TABLE_24COL' && LayoutPos??><#t>
<i-col<#if LayoutPos.getColXS() != -1> :xs="{ span: ${LayoutPos.getColXS()}, offset: <#if LayoutPos.getColXSOffset() != -1>${LayoutPos.getColXSOffset()}<#else>0</#if>}"</#if><#if LayoutPos.getColSM() != -1> :sm="{ span: ${LayoutPos.getColSM()}, offset: <#if LayoutPos.getColSMOffset() != -1>${LayoutPos.getColSMOffset()}<#else>0</#if>}"</#if><#if LayoutPos.getColMD() != -1> :md="{ span: ${LayoutPos.getColMD()}, offset: <#if LayoutPos.getColMDOffset() != -1>${LayoutPos.getColMDOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColLG() != -1> :lg="{ span: ${LayoutPos.getColLG()}, offset: <#if LayoutPos.getColLGOffset() != -1>${LayoutPos.getColLGOffset()}<#else>0</#if> }"</#if>>
<card class="portlet-card" :bordered="false" dis-hover :padding="0">
......@@ -27,28 +37,14 @@
<a slot='extra'></a>
</#if>
<span>
<@ibizindent blank=10><#t>
${P.getCtrlCode(portlet, 'CONTROL.html').code}
</@ibizindent>
</span>
</card>
</i-col>
<#else>
<card class="portlet-card" :bordered="false" dis-hover :padding="0">
<#if portlet.isShowTitleBar() && portlet.getTitle()?has_content><#t>
<p slot='title'>
${portlet.getTitle()}
</p>
<a slot='extra'></a>
</#if>
<span>
<@ibizindent blank=10><#t>
${P.getCtrlCode(portlet, 'CONTROL.html').code}
</@ibizindent>
</span>
</card>
</#if>
<#if layout == 'FLEX'>
</i-col>
<#-- ELSE:门户部件布局,Flex -->
<#else>
<card class="portlet-card" :bordered="false" dis-hover :padding="0">
<#if portlet.isShowTitleBar() && portlet.getTitle()?has_content><#t>
<p slot='title'>
......@@ -63,11 +59,14 @@ ${P.getCtrlCode(portlet, 'CONTROL.html').code}
</span>
</card>
</#if>
<#-- END:门户部件布局 -->
<#-- BEGIN:最后一个门户部件后 -->
<#if !portlet_has_next>
</div>
</#if>
<#-- END:最后一个门户部件后 -->
</#if>
</#list>
</#list>
</row>
<row v-if="isHasCustomized" style="width: 100%;min-height: calc(100% - 40px);">
<div class="portlet-container" style="position: relative;width:100%;">
......
......@@ -189,7 +189,7 @@
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public sortDir:string = '';
public sortDir:string = '<#if ctrl.getMinorSortDir()??>${ctrl.getMinorSortDir()?lower_case}</#if>';
/**
* 排序字段
......@@ -197,7 +197,7 @@
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public sortField: string = '';
public sortField: string = '<#if ctrl.getMinorSortPSDEF()??>${ctrl.getMinorSortPSDEF().getCodeName()?lower_case}</#if>';
/**
* 排序点击事件
......
......@@ -88,7 +88,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()}<#else>0</#if>;
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()?c}<#else>0</#if>;
/**
* 控件高度
......@@ -96,7 +96,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()}<#else>0</#if>;
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()?c}<#else>0</#if>;
/**
* 搜素值
......
......@@ -690,6 +690,7 @@ ${P.getCtrlCode(childCtrl, 'CONTROL.html').code}
</#list>
</#if>
}
this.$emit('nodedblclick', this.selectedNodes);
}
<#ibizinclude>
......
......@@ -15,6 +15,7 @@
<#if view.getViewType() == 'DEPICKUPTREEVIEW'>
:isSingleSelect="isSingleSelect"
:selectedData="selectedData"
@nodedblclick="tree_nodedblclick($event)"
</#if>
</#assign>
<#ibizinclude>
......
......@@ -88,7 +88,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()}<#else>0</#if>;
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()?c}<#else>0</#if>;
/**
* 过滤值
......
......@@ -112,7 +112,6 @@
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
<#-- public split: string = '<#if ctrl.getWidth() gt 0>${ctrl.getWidth()?c}<#else>200</#if>px'; -->
public split: number = 0.2;
/**
......
......@@ -76,7 +76,7 @@ GanttElastic,
*/
public options: any = {
isflex: true,
maxRows: 100,
maxRows: 1000,
dataType: 'treegrid',
title: {
label: ""
......@@ -108,11 +108,26 @@ GanttElastic,
<#list ctrl.getPSDETreeColumns() as column>
{
label: '${column.getCaption()}',
value: '<#if column.getName() == "begin">start<#else>${column.getName()}</#if>',
<#if column_index == 0>
value: (task: any) => {
<#if column.render??>
${column.render.code}
<#else>
return this.getColumnValue(task, '<#if column.getName() == "begin">start<#else>${column.getName()}</#if>')
</#if>
},
<#if column.getName() == "text">
expander: true,
</#if>
width: <#if column.getWidth() gt 0>${column.getWidth()}<#else>100</#if>
width: <#if column.getWidth() gt 0>${column.getWidth()}<#else>100</#if>,
<#if column.isHideDefault()>
hidden: true,
</#if>
<#if column.getHeaderPSSysCss()??>
headerCls: '${column.getHeaderPSSysCss().getCssName()}',
</#if>
<#if column.getCellPSSysCss()??>
cellCls: '${column.getCellPSSysCss().getCssName()}',
</#if>
},
</#list>
</#if>
......@@ -127,9 +142,7 @@ GanttElastic,
* @type {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public dynamicStyle: any = {
};
public dynamicStyle: any = {};
/**
* 日程事件集合
......@@ -151,6 +164,50 @@ GanttElastic,
this.locale = newval;
}
/**
* 获取列属性值
*
* @public
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public getColumnValue(task: any, field: string) {
<#if ctrl.getPSDETreeNodes()??>
<#list ctrl.getPSDETreeNodes() as node>
if(Object.is(task.id.split(';')[0], '${srfjavastring(node.getNodeType())}')) {
<#if node.getPSDETreeNodeDataItems()??>
<#list node.getPSDETreeNodeDataItems() as dataItem>
<#if dataItem.getFrontPSCodeList()??>
<#assign codelist = dataItem.getFrontPSCodeList()/>
if (Object.is(field, '${dataItem.name}')) {
let codelist: any[] = this.$store.getters.getCodeList('CodeList4');
if(codelist) {
return this.getCodeListItem(codelist, task[field]);
}
}
</#if>
</#list>
</#if>
return task[field];
}
</#list>
</#if>
}
/**
* 获取代码项
*
* @public
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public getCodeListItem(codelist: any, val: any) {
for(let i = 0; i < codelist.items.length; i++) {
if(Object.is(codelist.items[i].value, val)) {
return codelist.items[i].text;
}
}
return codelist.emptytext;
}
/**
* 获取部件参数
*
......@@ -232,72 +289,11 @@ GanttElastic,
*/
public taskItemExpand(task: any) {
if(!task.collapsed) {
let index: number = this.tasks.findIndex((item: any) => Object.is(task.id, item.parentId));
if(index < 0) {
this.load(task);
} else {
let len: number = this.tasks.length;
let datas: any = [];
for(let i = len - 1;i >= 0; i--) {
if(!Object.is(task.id, this.tasks[i].parentId)) {
datas.push(this.tasks[i]);
}
}
this.tasks = datas;
}
}
/**
* 获取编辑视图信息
*
* @param {*} $event 事件信息
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public getEditView(deName: string) {
let view: any = {};
switch(deName){
<#if ctrl.getPSDETreeNodes()??>
<#list ctrl.getPSDETreeNodes() as ganttItem>
<#if ganttItem.getPSAppDataEntity()??>
<#assign _appde = ganttItem.getPSAppDataEntity() />
case "${_appde.getCodeName()?lower_case}":
<#if ganttItem.getNavPSAppView()??>
<#assign editview = ganttItem.getNavPSAppView()/>
view = {
viewname: '${srffilepath2(editview.getCodeName())}',
height: ${editview.getHeight()?c},
width: ${editview.getWidth()?c},
title: this.<@getViewLanguageTitle editview />,
placement: '${editview.getOpenMode()}',
deResParameters: <#rt>
<#if editview.isPSDEView()>
[<#t>
<#if editview.getPSAppDERSPathCount() gt 0>
<#list editview.getPSAppDERSPath(editview.getPSAppDERSPathCount() - 1) as deRSPath>
<#assign majorPSAppDataEntity = deRSPath.getMajorPSAppDataEntity()/><#t>
{ pathName: '${srfpluralize(majorPSAppDataEntity.codeName)?lower_case}', parameterName: '${majorPSAppDataEntity.getCodeName()?lower_case}' }, <#t>
</#list>
</#if>
],<#lt>
<#else>
[],<#lt>
</#if>
parameters: <#rt>
[<#t>
<#if editview.isPSDEView()>
<#assign appDataEntity = editview.getPSAppDataEntity()/>
{ pathName: '${srfpluralize(appDataEntity.codeName)?lower_case}', parameterName: '${appDataEntity.getCodeName()?lower_case}' }, <#t>
{ pathName: '${editview.getPSDEViewCodeName()?lower_case}', parameterName: '${editview.getPSDEViewCodeName()?lower_case}' } <#t>
<#else>
{ pathName: '${editview.getCodeName()?lower_case}', parameterName: '${editview.getCodeName()?lower_case}' } <#t>
</#if>
],<#lt>
};
</#if>
break;
</#if>
</#list>
</#if>
}
return view;
}
/**
......@@ -357,41 +353,10 @@ GanttElastic,
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public taskClick({event, data}: {event: any, data: any}) {
let view: any = {};
let _context: any = Object.assign({},this.context);
const _this: any = this;
let key: string = data.id.split(';')[0];
switch(key) {
<#if ctrl.getPSDETreeNodes()??>
<#list ctrl.getPSDETreeNodes() as ganttItem>
<#if ganttItem.getPSAppDataEntity()??>
<#assign _appde = ganttItem.getPSAppDataEntity() />
case "${ganttItem.getNodeType()}":
_context.${_appde.getCodeName()?lower_case} = data.${_appde.getCodeName()?lower_case};
view = this.getEditView("${_appde.getCodeName()?lower_case}");
break;
</#if>
</#list>
</#if>
}
// 根据打开模式打开视图
if (Object.is(view.placement, 'INDEXVIEWTAB') || Object.is(view.placement, '')) {
const routePath = this.$viewTool.buildUpRoutePath(this.$route, this.context, view.deResParameters, view.parameters, [JSON.parse(JSON.stringify(_context))] , JSON.parse(JSON.stringify(this.viewparams)));
this.$router.push(routePath);
} else {
let container: Subject<any> = new Subject();
if (Object.is(view.placement, 'POPOVER')) {
container = this.$apppopover.openPop(data, view,JSON.parse(JSON.stringify(_context)), JSON.parse(JSON.stringify(this.viewparams)));
} else if (Object.is(view.placement, 'POPUPMODAL')) {
container = this.$appmodal.openModal(view, JSON.parse(JSON.stringify(_context)), JSON.parse(JSON.stringify(this.viewparams)));
} else if (view.placement.startsWith('DRAWER')) {
container = this.$appdrawer.openDrawer(view, JSON.parse(JSON.stringify(_context)), JSON.parse(JSON.stringify(this.viewparams)));
}
container.subscribe((result: any) => {
if (!result || !Object.is(result.ret, 'OK')) {
return;
}
this.refresh();
});
if(_this[key + '_opendata'] instanceof Function) {
_this[key + '_opendata']([data]);
}
}
......
<#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl
</#ibizinclude>
@import '~@fullcalendar/core/main.css';
@import '~@fullcalendar/daygrid/main.css';
@import '~@fullcalendar/timegrid/main.css';
@import '~@fullcalendar/list/main.css';
.gantt {
height: 100%;
.gantt-elastic__main-view-container {
flex-grow: 1;
}
}
<#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl
</#ibizinclude>
......@@ -99,6 +99,37 @@ import ${srfclassname('${node.getPSAppDataEntity().codeName}')}Service from '@se
</#list>
</#if>
/**
* 商品类别节点分隔符号
*
* @public
* @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
public dataModel: any = {
<#if ctrl.getPSDETreeNodes()??>
<#list ctrl.getPSDETreeNodes() as node>
${node.getNodeType()}: {
<#if node.getPSDETreeNodeDataItems()??>
<#list node.getPSDETreeNodeDataItems() as dataItem>
<#if dataItem.name == "barstyle">
style: {
prop: '<#if dataItem.getPSAppDEField()??>${dataItem.getPSAppDEField().getCodeName()?lower_case}</#if>',
default: <#if dataItem.getDefaultValue()?length gt 0>${dataItem.getDefaultValue()}<#else>null</#if>
},
<#else>
<#if dataItem.name == "begin">start<#else>${dataItem.name}</#if>: {
prop: '<#if dataItem.getPSAppDEField()??>${dataItem.getPSAppDEField().getCodeName()?lower_case}</#if>',
default: <#if dataItem.getDefaultValue()?length gt 0>'${dataItem.getDefaultValue()}'<#else>null</#if>
},
</#if>
</#list>
</#if>
},
</#list>
</#if>
}
/**
* 获取节点数据
*
......@@ -525,13 +556,6 @@ import ${srfclassname('${node.getPSAppDataEntity().codeName}')}Service from '@se
}
}
</#if>
<#if node.getPSDETreeNodeDataItems()??>
<#list node.getPSDETreeNodeDataItems() as dataitem>
<#if dataitem.getPSDEField()??>
Object.assign(treeNode, { <#if dataitem.name == "begin">start<#else>${dataitem.name?lower_case}</#if>: entity.${dataitem.getPSDEField().codeName?lower_case} });
</#if>
</#list>
</#if>
<#if node.isSelected()>
Object.assign(treeNode, { selected: true });
</#if>
......@@ -547,6 +571,23 @@ import ${srfclassname('${node.getPSAppDataEntity().codeName}')}Service from '@se
if(!Object.is(filter.srfnodeid, this.TREENODE_${ctrl.getRootPSDETreeNode().getNodeType()?upper_case})) {
Object.assign(treeNode, { parentId: filter.srfotherkey });
}
for(let key in this.dataModel.${node.getNodeType()}) {
let item = this.dataModel.${node.getNodeType()}[key];
let propVal: any = entity[item.prop];
try {
let def: any = JSON.parse(item.default);
propVal = propVal != null ? propVal : def.value;
if (def.hasOwnProperty('bkcolor')) {
Object.assign(treeNode.style, { base: { fill: def.bkcolor, stroke: def.bkcolor }});
}
if (def.hasOwnProperty('color')) {
Object.assign(treeNode.style, { text: { color: def.color }});
}
} catch(e) {
propVal = propVal != null ? propVal : item.default
}
treeNode[key] = propVal
}
list.push(treeNode);
resolve(list);
bFirst = false;
......
<#ibizinclude>
../@MACRO/CONTROL/LANGBASE.vue.ftl
</#ibizinclude>
<i-form :model="this.data" class='app-form<#if ctrl.getPSSysCss()??> ${ctrl.getPSSysCss().getCssName()}</#if><#if ctrl.isInfoFormMode?? && ctrl.isInfoFormMode()> info-form-mode</#if>' ref='${ctrl.name}' id='${ctrl.name}' style="<#if ctrl.getFormWidth() gt 1>width: ${ctrl.getFormWidth()?c}px;</#if>">
<i-form :model="this.data" class='app-form<#if ctrl.getPSSysCss()??> ${ctrl.getPSSysCss().getCssName()}</#if><#if ctrl.isInfoFormMode?? && ctrl.isInfoFormMode()> info-form-mode</#if>' ref='${ctrl.name}' id='${ctrl.getPSAppDataEntity().getCodeName()?lower_case}_${ctrl.getCodeName()?lower_case}' style="<#if ctrl.getFormWidth() gt 1>width: ${ctrl.getFormWidth()?c}px;</#if>">
<input style="display:none;" />
<row >
<#if ctrl.isNoTabHeader()>
......
......@@ -13,6 +13,12 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl
</#ibizinclude>
/**
* 工作流审批意见控件绑定值
*
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public srfwfmemo:string = "";
/**
* 获取多项数据
......@@ -797,7 +803,7 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
*/
public print(){
let _this:any = this;
_this.$print({id:'${ctrl.name}',popTitle:'${ctrl.getLogicName()}'});
_this.$print({id:'${ctrl.getPSAppDataEntity().getCodeName()?lower_case}_${ctrl.getCodeName()?lower_case}',popTitle:'${ctrl.getLogicName()}'});
}
/**
......@@ -1193,6 +1199,10 @@ import { debounceTime, distinctUntilChanged } from 'rxjs/operators';
if(this.viewparams){
Object.assign(arg,{viewparams:this.viewparams});
}
// 强制补充srfwfmemo
if(this.srfwfmemo){
Object.assign(arg,{srfwfmemo:this.srfwfmemo});
}
const result: Promise<any> = this.service.wfsubmit(_this.WFSubmitAction, JSON.parse(JSON.stringify(this.context)),arg, this.showBusyIndicator,localdata);
result.then((response: any) => {
if (!response || response.status !== 200) {
......
......@@ -28,6 +28,29 @@
]
</#macro>
<#-- END:获取视图本身路由参数 -->
<#-- BEGIN:插入空格 -->
<#macro insertBlank num>
<#assign blank_space = " " />
<#list 1..num as i>
${blank_space}<#t>
</#list>
</#macro>
<#-- END:插入空格 -->
<#-- BEGIN:表格列标题自定义绘制 -->
<#macro getColumnHeader item blankNum>
<@insertBlank blankNum /><template v-slot:header="{column}">
<@insertBlank blankNum /> <span class="column-header <#if item.getHeaderPSSysCss?? && item.getHeaderPSSysCss()??>${item.getHeaderPSSysCss().getCssName()}</#if>">
<#if item.getPSSysImage()??>
<#assign img=item.getPSSysImage()>
<@insertBlank blankNum /> <i class='<#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if>'></i>
</#if>
<@insertBlank blankNum /> {{<#if langbase??>$t('${langbase}.columns.${item.getName()?lower_case}')<#else>'${item.getCaption()}'</#if>}}
<@insertBlank blankNum /> </span>
<@insertBlank blankNum /></template>
</#macro>
<#-- END:表格列标题自定义绘制 -->
<#ibizinclude>
../@MACRO/CONTROL/LANGBASE.vue.ftl
</#ibizinclude>
......@@ -38,6 +61,7 @@
<#if item.getColumnType() == 'GROUPGRIDCOLUMN' && item.getPSDEGridColumns()??>
<#-- BEGIN:分组列 -->
<el-table-column show-overflow-tooltip :align="'${item.getAlign()?lower_case}'" :label="<#if langbase??>$t('${langbase}.columns.${item.getName()?lower_case}')<#else>'${item.getCaption()}'</#if>">
<@getColumnHeader item 4 />
<#list item.getPSDEGridColumns() as column>
${P.getPartCode(column,'COLUMN').code}
</#list>
......@@ -46,12 +70,14 @@
<#elseif item.getColumnType() == 'UAGRIDCOLUMN'>
<#-- BEGIN:操作列 -->
<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 />
<template slot-scope="scope">
<span>
<#if item.getPSDEUIActionGroup().getPSDEUIActions()??>
<#list item.getPSDEUIActionGroup().getPSDEUIActions() as uiaction>
<#list item.getPSDEUIActionGroup().getPSUIActions() as uiaction>
<#if uiaction_index gt 0><divider type='vertical'></divider></#if>
<a @click="uiAction(scope.row, '${uiaction.getUIActionTag()}', $event)">
<i class='<#if uiaction.getIconCls?? && uiaction.getIconCls()??>${uiaction.getIconCls()}</#if>'></i>
{{<#if langbase??>$t('${langbase}.uiactions.${uiaction.getUIActionTag()?lower_case}')<#else>'${uiaction.getCaption()}'</#if>}}
</a>
</#list>
......@@ -63,7 +89,8 @@
<#elseif item.getColumnType() == 'DEFGRIDCOLUMN'>
<#-- BEGIN:数据列 -->
<el-table-column show-overflow-tooltip :prop="'${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}'"<#if (!ctrl.isNoSort()) && item.isEnableSort()> :sortable="'custom'"</#if>>
<template v-slot="{row,column}">
<@getColumnHeader item 8 />
<template v-slot="{row,column,$index}">
<#if (item.render??) || (item.getCodeList()?? && item.getCLConvertMode() == 'FRONT') || item.isEnableRowEdit()>
<#-- BEGIN:列绘制、前端绘制代码表、行编辑 -->
<#if (ctrl.isEnableRowEdit() && item.isEnableRowEdit())>
......@@ -74,11 +101,9 @@
<#-- END:列绘制 -->
<#else>
<template v-if="actualIsOpenEdit">
<i-form style="height:100%;" :model="row">
<app-form-item :name="column.property" :itemRules="rules[column.property]">
<app-form-item :error="gridItemsModel[$index][column.property].error">
${P.getEditorCode(item, "GRIDEIDTOR.vue").code}
</app-form-item>
</i-form>
</template>
</#if>
<#-- END:行编辑 -->
......
......@@ -3,6 +3,7 @@
<#if ctrl.render?? || ctrl.getRender()??>
${ctrl.render.code}
<#else>
<i-form style="height:100%">
<el-table v-if="isDisplay === true"
<#-- BEGIN:是否支持排序 -->
<#if !ctrl.isNoSort()>
......@@ -50,6 +51,7 @@
<el-table-column></el-table-column>
</template>
</el-table>
<#if ctrl.isEnablePagingBar()>
<row class='grid-pagination' v-show="items.length > 0">
<page class='pull-right' @on-change="pageOnChange($event)"
......@@ -94,10 +96,12 @@
</row>
</#if>
</#if>
</i-form>
</div>
</template>
<#assign import_block>
import CodeListService from "@service/app/codelist-service";
import { FormItemModel } from '@/model/form-detail';
</#assign>
<#ibizinclude>
../@MACRO/CONTROL/CONTROL_HEADER-BASE.vue.ftl
......@@ -458,6 +462,28 @@ import CodeListService from "@service/app/codelist-service";
</#if>
]
/**
* 表格模型集合
*
* @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public gridItemsModel: any[] = [];
/**
* 获取表格行模型
*
* @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public getGridRowModel(){
return {
<#list ctrl.getPSDEGridEditItems() as edititem>
${edititem.getName()}: new FormItemModel(),
</#list>
}
}
/**
* 属性值规则
*
......@@ -469,8 +495,9 @@ import CodeListService from "@service/app/codelist-service";
${edititem.getName()}: [
{ required: <#if edititem.isAllowEmpty()>false<#else>true</#if>, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: <#if edititem.getCaption?? && edititem.getCaption()??>'${edititem.getCaption()} 值不能为空'<#else>'值不能为空'</#if>, trigger: 'change' },
{ required: <#if edititem.isAllowEmpty()>false<#else>true</#if>, validator: (rule:any, value:any, callback:any) => { return (rule.required && (value === null || value === undefined || value === "")) ? false : true;}, message: <#if edititem.getCaption?? && edititem.getCaption()??>'${edititem.getCaption()} 值不能为空'<#else>'值不能为空'</#if>, trigger: 'blur' },
<#if ctrl.getPSGEIDEFValueRules?? && ctrl.getPSGEIDEFValueRules()??>
<#list ctrl.getPSGEIDEFValueRules() as fideValueRule>
<#if ctrl.getPSDEGridEditItemVRs?? && ctrl.getPSDEGridEditItemVRs()??>
<#list ctrl.getPSDEGridEditItemVRs() as fideValueRule>
<#if fideValueRule.getPSDEGridEditItemName() == edititem.getName()>
<#if fideValueRule.getPSSysValueRule()??>
<#assign valueRule = fideValueRule.getPSSysValueRule()/>
<#if valueRule.getRuleType?? && valueRule.getRuleType()??>
......@@ -481,12 +508,57 @@ import CodeListService from "@service/app/codelist-service";
</#if>
</#if>
</#if>
</#if>
</#list>
</#if>
],
</#list>
}
/**
* 表格行编辑项校验
*
* @param {string} property 属性名
* @param {*} data 行数据
* @param {number} rowIndex 行索引
* @returns Promise<any>
*
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public validate(property:string, data:any, rowIndex:number):Promise<any>{
return new Promise((resolve, reject) => {
this.$util.validateItem(property,data,this.rules).then(()=>{
this.gridItemsModel[rowIndex][property].setError(null);
resolve(true);
}).catch(({ errors, fields }) => {
this.gridItemsModel[rowIndex][property].setError(errors[0].message);
resolve(false);
});
});
}
/**
* 校验所有修改过的编辑项
*
* @returns Promise<any>
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public async validateAll(){
let validateState = true;
let index = -1;
for(let item of this.items){
index++;
if(item.rowDataState === "create" || item.rowDataState === "update"){
for(let property of Object.keys(this.rules)){
if(!await this.validate(property,item,index)){
validateState = false;
}
}
}
}
return validateState;
}
/**
* 表格数据加载
*
......@@ -529,8 +601,10 @@ import CodeListService from "@service/app/codelist-service";
const data: any = response.data;
this.totalrow = response.total;
this.items = JSON.parse(JSON.stringify(data));
// 清空selections
// 清空selections,gridItemsModel
this.selections = [];
this.gridItemsModel = [];
this.items.forEach(()=>{this.gridItemsModel.push(this.getGridRowModel())});
this.$emit('load', this.items);
// 设置默认选中
let _this = this;
......@@ -582,6 +656,7 @@ import CodeListService from "@service/app/codelist-service";
this.items.some((val: any, num: number) =>{
if(JSON.stringify(val) == JSON.stringify(record)){
this.items.splice(num,1);
this.gridItemsModel.splice(num,1);
return true;
}
});
......@@ -617,8 +692,9 @@ import CodeListService from "@service/app/codelist-service";
keys.push(data.srfkey);
});
let _removeAction = keys.length > 1 ? 'removeBatch' : this.removeAction ;
let _keys = keys.length > 1 ? keys : keys[0] ;
const context:any = JSON.parse(JSON.stringify(this.context));
const post: Promise<any> = this.service.delete(_removeAction,Object.assign(context,{ ${ctrl.getPSAppDataEntity().codeName?lower_case}: keys.join(';') }),Object.assign({ ${ctrl.getPSAppDataEntity().codeName?lower_case}: keys.join(';') },{viewparams:this.viewparams}), this.showBusyIndicator);
const post: Promise<any> = this.service.delete(_removeAction,Object.assign(context,{ ${ctrl.getPSAppDataEntity().codeName?lower_case}: _keys }),Object.assign({ ${ctrl.getPSAppDataEntity().codeName?lower_case}: _keys },{viewparams:this.viewparams}), this.showBusyIndicator);
return new Promise((resolve: any, reject: any) => {
post.then((response: any) => {
if (!response || response.status !== 200) {
......@@ -633,6 +709,7 @@ import CodeListService from "@service/app/codelist-service";
this.items.some((item:any,index:number)=>{
if(Object.is(item.srfkey,data.srfkey)){
this.items.splice(index,1);
this.gridItemsModel.splice(index,1);
return true;
}
});
......@@ -1454,44 +1531,59 @@ import CodeListService from "@service/app/codelist-service";
* 保存
*
* @param {*} $event
* @returns {void}
* @returns {Promise<any>}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public save(args: any[], params?: any, $event?: any, xData?: any): void {
public async save(args: any[], params?: any, $event?: any, xData?: any){
let _this = this;
let promises:any = [];
_this.items.forEach((item:any)=>{
if(!item.rowDataState){
return;
} else if(Object.is(item.rowDataState, 'create')){
if(!await this.validateAll()){
this.$Notice.error({ title: '错误', desc: '值规则校验异常' });
return [];
}
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参数未配置' });
return;
}
}else{
Object.assign(item,{viewparams:this.viewparams});
promises.push(this.service.add(this.createAction, JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator));
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参数未配置' });
return;
}
}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}})
Object.assign(this.context,{${appde.getCodeName()?lower_case}:item.${appde.getCodeName()?lower_case}});
}
</#if>
promises.push(this.service.add(this.updateAction,JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator));
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)));
}
});
Promise.all(promises).then((response: any) => {
this.$emit('save', response);
this.$Notice.success({ title: '', desc: '保存成功!' });
}
} catch (error) {
errorItems.push(JSON.parse(JSON.stringify(item)));
errorMessage.push(error);
}
}
this.$emit('save', successItems);
this.refresh([]);
}).catch((response: any) => {
this.$Notice.error({ title: '错误', desc: '系统异常' });
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;
}
<#if ctrl.isEnableRowEdit()>
/**
......@@ -1519,6 +1611,7 @@ import CodeListService from "@service/app/codelist-service";
const data = response.data;
data.rowDataState = "create";
_this.items.push(data);
_this.gridItemsModel.push(_this.getGridRowModel());
}).catch((response: any) => {
if (response && response.status === 401) {
return;
......@@ -1538,7 +1631,7 @@ import CodeListService from "@service/app/codelist-service";
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public onGridItemValueChange(row: any,$event: { name: string, value: any }): void {
public onGridItemValueChange(row: any,$event: { name: string, value: any },rowIndex: number): void {
if (!$event) {
return;
}
......@@ -1546,7 +1639,7 @@ import CodeListService from "@service/app/codelist-service";
return;
}
row[$event.name] = $event.value;
this.gridEditItemChange(row, $event.name, $event.value);
this.gridEditItemChange(row, $event.name, $event.value, rowIndex);
}
/**
......@@ -1559,8 +1652,9 @@ import CodeListService from "@service/app/codelist-service";
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public gridEditItemChange(row: any, property: string, value: any){
public gridEditItemChange(row: any, property: string, value: any, rowIndex: number){
row.rowDataState = row.rowDataState ? row.rowDataState : "update" ;
this.validate(property,row,rowIndex);
<#if ctrl.getPSDEGridEditItems()??>
<#list ctrl.getPSDEGridEditItems() as editItem>
<#if editItem.getPSDEGridEditItemUpdate()??>
......
......@@ -25,6 +25,10 @@
overflow: hidden;
word-break: break-all;
}
.el-table-column--selection .cell {
padding-left: 0px;
padding-right: 0px;
}
.app-column-link, .app-format-data{
display: inline;
}
......
......@@ -111,7 +111,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()}<#else>0</#if>;
public ctrlWidth:number = <#if ctrl.getWidth()??>${ctrl.getWidth()?c}<#else>0</#if>;
/**
* 控件高度
......@@ -119,7 +119,7 @@
* @type {number}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()}<#else>0</#if>;
public ctrlHeight: number = <#if ctrl.getHeight()??>${ctrl.getHeight()?c}<#else>0</#if>;
/**
* 选中数据
......
......@@ -583,8 +583,9 @@ import CodeListService from "@service/app/codelist-service";
keys.push(data.srfkey);
});
let _removeAction = keys.length > 1 ? 'removeBatch' : this.removeAction ;
let _keys = keys.length > 1 ? keys : keys[0] ;
const context:any = JSON.parse(JSON.stringify(this.context));
const post: Promise<any> = this.service.delete(_removeAction,Object.assign(context,{ ${ctrl.getPSAppDataEntity().codeName?lower_case}: keys.join(';') }),Object.assign({ ${ctrl.getPSAppDataEntity().codeName?lower_case}: keys.join(';') },{viewparams:this.viewparams}), this.showBusyIndicator);
const post: Promise<any> = this.service.delete(_removeAction,Object.assign(context,{ ${ctrl.getPSAppDataEntity().codeName?lower_case}: _keys }),Object.assign({ ${ctrl.getPSAppDataEntity().codeName?lower_case}: _keys },{viewparams:this.viewparams}), this.showBusyIndicator);
return new Promise((resolve: any, reject: any) => {
post.then((response: any) => {
if (!response || response.status !== 200) {
......@@ -1411,7 +1412,7 @@ import CodeListService from "@service/app/codelist-service";
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
protected save(args: any[], params?: any, $event?: any, xData?: any): void {
protected async save(args: any[], params?: any, $event?: any, xData?: any) {
let _this = this;
let promises:any = [];
_this.items.forEach((item:any)=>{
......@@ -1490,7 +1491,7 @@ import CodeListService from "@service/app/codelist-service";
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
protected onGridItemValueChange(row: any,$event: { name: string, value: any }): void {
public onGridItemValueChange(row: any,$event: { name: string, value: any },rowIndex: number): void {
if (!$event) {
return;
}
......@@ -1511,7 +1512,7 @@ import CodeListService from "@service/app/codelist-service";
* @returns {void}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
protected gridEditItemChange(row: any, property: string, value: any){
public gridEditItemChange(row: any, property: string, value: any, rowIndex: number){
row.rowDataState = row.rowDataState ? row.rowDataState : "update" ;
<#if ctrl.getPSDEGridEditItems()??>
<#list ctrl.getPSDEGridEditItems() as editItem>
......
......@@ -3,10 +3,10 @@
<#comment><!--结束:快速搜索或工具栏存在--></#comment>
<#if view.hasPSControl('searchform')>
${P.getCtrlCode('searchform', 'CONTROL.html').code}
</#if>
<#if view.hasPSControl('list')>
</#if>
<#if view.hasPSControl('list')>
${P.getCtrlCode('list', 'CONTROL.html').code}
</#if>
</#if>
</#assign>
<#ibizinclude>
......
......@@ -3,10 +3,10 @@
<#comment><!--结束:快速搜索或工具栏存在--></#comment>
<#if view.hasPSControl('searchform')>
${P.getCtrlCode('searchform', 'CONTROL.html').code}
</#if>
<#if view.hasPSControl('list')>
</#if>
<#if view.hasPSControl('list')>
${P.getCtrlCode('list', 'CONTROL.html').code}
</#if>
</#if>
</#assign>
<#ibizinclude>
......
<#ibizinclude>
../@MACRO/DEFAULT.less.ftl
</#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/DEFAULT.vue.ftl
</#ibizinclude>
\ No newline at end of file
CTRLTYPE=VIEWLAYOUTPANEL#APPDEGANTTVIEW9
\ No newline at end of file
......@@ -8,12 +8,13 @@
<#assign portletClass = "portlet">
</#if>
<template>
<div class='${portletClass} ${srffilepath2(ctrl.getCodeName())}' :style="{<#if (ctrl.getHeight?? && ctrl.getHeight() gt 0)>'height': isAdaptiveSize ? '${portletHeight}' : <#if ctrl.getHeight() == 1>'auto'<#else>'${ctrl.getHeight()?c}px'</#if>,</#if><#if (ctrl.getWidth?? && ctrl.getWidth() gt 0)>'width': isAdaptiveSize ? '${portletWidth}' : '${ctrl.getWidth()?c}px '</#if>}">
<div class='${portletClass} ${srffilepath2(ctrl.getCodeName())} <#if ctrl.getPSSysCss()??> ${ctrl.getPSSysCss().getCssName()}</#if>' :style="{<#if (ctrl.getHeight?? && ctrl.getHeight() gt 0)>'height': isAdaptiveSize ? '${portletHeight}' : <#if ctrl.getHeight() == 1>'auto'<#else>'${ctrl.getHeight()?c}px'</#if>,</#if><#if (ctrl.getWidth?? && ctrl.getWidth() gt 0)>'width': isAdaptiveSize ? '${portletWidth}' : '${ctrl.getWidth()?c}px '</#if>}">
<#if ctrl.getPortletType?? && ctrl.getPortletType()??><#t>
<#-- 视图 -->
<#if ctrl.getPortletType() == 'VIEW' && ctrl.getPortletPSAppView?? && ctrl.getPortletPSAppView()??><#t>
<#if ctrl.isShowTitleBar() && ctrl.getTitle()??>
<p class='portlet-title'>
<i class='<#if ctrl.getPSSysImage()??><#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if></#if>'></i>
${ctrl.getTitle()}
</p>
</#if>
......@@ -25,6 +26,7 @@
<#elseif ctrl.getPortletType() == 'APPMENU'><#t>
<#if ctrl.isShowTitleBar() && ctrl.getTitle()??>
<p class='portlet-title'>
<i class='<#if ctrl.getPSSysImage()??><#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if></#if>'></i>
${ctrl.getTitle()}
</p>
</#if>
......@@ -38,6 +40,7 @@
<#elseif ctrl.getPortletType() == 'CUSTOM'>
<#if ctrl.isShowTitleBar() && ctrl.getTitle()??>
<p class='portlet-title'>
<i class='<#if ctrl.getPSSysImage()??><#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if></#if>'></i>
${ctrl.getTitle()}
</p>
</#if>
......@@ -52,6 +55,7 @@
<#elseif ctrl.getPortletType() == 'ACTIONBAR'>
<#if ctrl.isShowTitleBar() && ctrl.getTitle()??>
<p class='portlet-title'>
<i class='<#if ctrl.getPSSysImage()??><#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if></#if>'></i>
${ctrl.getTitle()}
</p>
</#if>
......@@ -66,6 +70,7 @@
<#elseif ctrl.getPortletType() == 'HTML'>
<#if ctrl.isShowTitleBar() && ctrl.getTitle()??>
<p class='portlet-title'>
<i class='<#if ctrl.getPSSysImage()??><#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if></#if>'></i>
${ctrl.getTitle()}
</p>
</#if>
......@@ -96,13 +101,6 @@
</@ibizindent>
</div>
</#if>
<#if layout == 'FLEX'>
<div class="portlet-without-title">
<@ibizindent blank=18>
${P.getCtrlCode(portlet, 'CONTROL.html').code}
</@ibizindent>
</div>
</#if>
<#if layout == 'FLEX' >
</div>
</#if>
......@@ -112,6 +110,7 @@
<#elseif ctrl.getContentPSControl()??><#t>
<#if ctrl.isShowTitleBar() && ctrl.getTitle()??>
<p class='portlet-title'>
<i class='<#if ctrl.getPSSysImage()??><#assign img=ctrl.getPSSysImage()><#if img.getCssClass()?? && (img.getCssClass()?length gt 0)>${img.getCssClass()}</#if></#if>'></i>
${ctrl.getTitle()}
</p>
</#if>
......@@ -135,7 +134,7 @@
* 操作栏模型数据
*
* @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public actionBarModelData:any[] =[
<#if ctrl.getPSAppViewLogics?? && ctrl.getPSAppViewLogics()??>
......@@ -161,7 +160,7 @@
/**
* 触发界面行为
*
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public handleItemClick($event:any){
<#if ctrl.getPSAppViewLogics?? && ctrl.getPSAppViewLogics()??>
......@@ -174,11 +173,16 @@
}
</#if>
<#if ctrl.getPortletType?? && ctrl.getPortletType()?? && ctrl.getPortletType() == "TOOLBAR" >
<#assign toolbar = ctrl.getContentPSControl()/>
${P.getCtrlCode(toolbar, 'CONTROL.vue').code}
</#if>
/**
* 是否自适应大小
*
* @returns {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Prop({default: false})public isAdaptiveSize!: boolean;
......@@ -186,7 +190,7 @@
* 获取多项数据
*
* @returns {any[]}
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public getDatas(): any[] {
return [];
......@@ -196,7 +200,7 @@
* 获取单项树
*
* @returns {*}
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public getData(): any {
return {};
......@@ -205,7 +209,7 @@
/**
* vue 生命周期
*
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public created() {
this.afterCreated();
......@@ -214,7 +218,7 @@
/**
* 执行created后的逻辑
*
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public afterCreated(){
if (this.viewState) {
......@@ -233,7 +237,7 @@
/**
* vue 生命周期
*
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public destroyed() {
this.afterDestroy();
......@@ -242,7 +246,7 @@
/**
* 执行destroyed后的逻辑
*
* @memberof ${srfclassname('${ctrl.codeName}')}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public afterDestroy() {
if (this.viewStateEvent) {
......
......@@ -22,6 +22,9 @@
white-space: nowrap;
color: #304265;
font-weight: 600;
i{
margin-right: 5px;
}
}
> .portlet-with-title{
width:100%;
......@@ -38,4 +41,14 @@
.app-charts{
height: 100%!important;
}
.toolbar-container {
button{
margin: 6px 0px 4px 16px;
}
.ivu-badge{
.ivu-badge-count{
top: 0;
}
}
}
}
\ No newline at end of file
<#assign flexAttr>
<#if item.getPSLayoutPos()?? && item.getPSLayoutPos().getLayout() == "FLEX"><#assign layoutPos = item.getPSLayoutPos()/><#if layoutPos.getGrow() gt -1>flex-grow: ${layoutPos.getGrow()};</#if></#if></#assign>
<#assign tableAttr>
<#if item.getPSLayoutPos()?? && item.getPSLayoutPos().getLayout() != "FLEX"><#assign layoutPos = item.getPSLayoutPos()/><#if layoutPos.getColLG() gt -1> :lg="${layoutPos.getColLG()?c}"</#if><#if layoutPos.getColMD() gt -1> :md="${layoutPos.getColMD()?c}"</#if><#if layoutPos.getColSM() gt -1> :sm="${layoutPos.getColSM()?c}"</#if><#if layoutPos.getColXS() gt -1> :xs="${layoutPos.getColXS()?c}"</#if></#if></#assign>
<#if item.getPSLayoutPos()?? && item.getPSLayoutPos().getLayout() != "FLEX"><#t>
<#assign layoutPos = item.getPSLayoutPos()/><#t>
<#if layoutPos.getColXS() != -1> :xs="{ span: ${layoutPos.getColXS()}, offset: <#if layoutPos.getColXSOffset() != -1>${layoutPos.getColXSOffset()}<#else>0</#if> }"</#if><#t>
<#if layoutPos.getColSM() != -1> :sm="{ span: ${layoutPos.getColSM()}, offset: <#if layoutPos.getColSMOffset() != -1>${layoutPos.getColSMOffset()}<#else>0</#if> }"</#if><#t>
<#if layoutPos.getColMD() != -1> :md="{ span: ${layoutPos.getColMD()}, offset: <#if layoutPos.getColMDOffset() != -1>${layoutPos.getColMDOffset()}<#else>0</#if> }"</#if><#t>
<#if layoutPos.getColLG() != -1> :lg="{ span: ${layoutPos.getColLG()}, offset: <#if layoutPos.getColLGOffset() != -1>${layoutPos.getColLGOffset()}<#else>0</#if> }"</#if><#t>
</#if><#t>
</#assign>
<#assign content>
<#if item.render??>
${item.render.code}
......
<#if item.getLogicType() == 'GROUP'><#if item.isNotMode()>!(</#if><#if item.getPSPanelItemLogics()??><#list item.getPSPanelItemLogics() as subLogic><#if subLogic_index gt 0><#if item.getGroupOP() == 'AND'> && </#if><#if item.getGroupOP() == 'OR'> || </#if></#if>${P.getPartCode(subLogic, 'DETAIL_LOGIC').code}</#list></#if><#if item.isNotMode()>)</#if><#elseif item.getLogicType() == 'SINGLE'>this.$verify.testCond(_${item.getDstModelField()?lower_case}, '${item.getCondOp()}', '${item.getValue()}')</#if>
\ No newline at end of file
<#assign selfContent>
<i-button type="primary" long @click="${item.name}_click($event)" <#if item.getHeight() gt 0> style="height: ${item.getHeight()?c}px;"</#if>>
<i-button type="primary" long <#if item.getPSUIAction?? && item.getPSUIAction()??>@click="uiAction(null, '${item.getPSUIAction().getUIActionTag()}', $event)"</#if> <#if item.getHeight() gt 0> style="height: ${item.getHeight()?c}px;"</#if>>
<#if item.getPSSysImage()??>
<#assign image = item.getPSSysImage()>
<i class="${image.getCssClass()}"></i>
......@@ -14,11 +14,11 @@
./@MACRO/PLAYOUT.vue.ftl
</#ibizinclude>
<#if item.getParentLayoutMode()=='FLEX'>
<div style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<div v-show="detailsModel.${item.name}.visible" style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</div>
<#else>
<i-col ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<i-col v-show="detailsModel.${item.name}.visible" ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-button<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</i-col>
</#if>
\ No newline at end of file
......@@ -3,10 +3,10 @@
./@MACRO/PLAYOUT.vue.ftl
</#ibizinclude>
<#if layout.getLayout()=='FLEX'>
<div class="app-layoutpanel-container<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>" style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if>">
<#if item.render??>
${item.render.code}
<#else>
<div v-show="detailsModel.${item.name}.visible" class="app-layoutpanel-container<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>" style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if>">
<#if item.render??>
${item.render.code}
<#else>
<#-- <#if item.isShowCaption()>
<#if item.getLabelPSSysCss()??>
<div class="${item.getLabelPSSysCss().getCssName()}" style="height: 50px;${item.getLabelPSSysCss().getRawCssStyle()}">${item.getCaption()}</div>
......@@ -15,21 +15,21 @@ ${item.render.code}
</#if>
</#if> -->
<div style="height:100%;display: flex;<#if layout.getDir()!="">flex-direction: ${layout.getDir()};</#if><#if layout.getAlign()!="">justify-content: ${layout.getAlign()};</#if><#if layout.getVAlign()!="">align-items: ${layout.getVAlign()};</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>">
<@ibizindent blank=8>
<#if item.getPSPanelItems()??>
<#list item.getPSPanelItems() as panelItem>
${P.getPartCode(panelItem).code}
</#list>
</#if>
</@ibizindent>
<@ibizindent blank=8>
<#if item.getPSPanelItems()??>
<#list item.getPSPanelItems() as panelItem>
${P.getPartCode(panelItem).code}
</#list>
</#if>
</@ibizindent>
</div>
</#if>
</#if>
</div>
<#else>
<i-col ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if>" class="app-layoutpanel-container<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<#if item.render??>
${item.render.code}
<#else>
<i-col v-show="detailsModel.${item.name}.visible" ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if>" class="app-layoutpanel-container<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<#if item.render??>
${item.render.code}
<#else>
<#-- <#if item.isShowCaption()>
<#if item.getLabelPSSysCss()??>
<div class="${item.getLabelPSSysCss().getCssName()}" style="height: 50px;${item.getLabelPSSysCss().getRawCssStyle()}">${item.getCaption()}</div>
......@@ -38,14 +38,14 @@ ${item.render.code}
</#if>
</#if> -->
<row style="height:100%;<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>">
<@ibizindent blank=8>
<#if item.getPSPanelItems()??>
<#list item.getPSPanelItems() as panelItem>
${P.getPartCode(panelItem).code}
</#list>
</#if>
</@ibizindent>
<@ibizindent blank=8>
<#if item.getPSPanelItems()??>
<#list item.getPSPanelItems() as panelItem>
${P.getPartCode(panelItem).code}
</#list>
</#if>
</@ibizindent>
</row>
</#if>
</#if>
</i-col>
</#if>
\ No newline at end of file
......@@ -6,11 +6,11 @@ ${P.getCtrlCode(item.getPSControl(), 'CONTROL.html').code}
./@MACRO/PLAYOUT.vue.ftl
</#ibizinclude>
<#if item.getParentLayoutMode()=='FLEX'>
<div style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<div v-show="detailsModel.${item.name}.visible" style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</div>
<#else>
<i-col ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<i-col v-show="detailsModel.${item.name}.visible" ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</i-col>
</#if>
\ No newline at end of file
......@@ -10,11 +10,11 @@ ${P.getCtrlCode('${item.name}', 'CONTROL.html').code}
./@MACRO/PLAYOUT.vue.ftl
</#ibizinclude>
<#if item.getParentLayoutMode()=='FLEX'>
<div style="${flexAttr}<#if item.getWidth() != -1>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<div v-show="detailsModel.${item.name}.visible" style="${flexAttr}<#if item.getWidth() != -1>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</div>
<#else>
<i-col ${tableAttr} style="${flexAttr}<#if item.getWidth() != -1>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<i-col v-show="detailsModel.${item.name}.visible" ${tableAttr} style="${flexAttr}<#if item.getWidth() != -1>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-ctrlpos<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</i-col>
</#if>
\ No newline at end of file
......@@ -13,11 +13,11 @@
./@MACRO/PLAYOUT.vue.ftl
</#ibizinclude>
<#if item.getParentLayoutMode()=='FLEX'>
<div style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-field <#if item.getPSSysCss?? && item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<div v-show="detailsModel.${item.name}.visible" style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-field <#if item.getPSSysCss?? && item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</div>
<#else>
<i-col ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-field<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<i-col v-show="detailsModel.${item.name}.visible" ${tableAttr} style="${flexAttr}<#if item.getWidth() gt 0>width: ${item.getWidth()?c}px;</#if><#if item.getHeight() gt 0>height: ${item.getHeight()?c}px;</#if><#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-field<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</i-col>
</#if>
\ No newline at end of file
......@@ -6,11 +6,11 @@ ${item.getHtmlContent()}
./@MACRO/PLAYOUT.vue.ftl
</#ibizinclude>
<#if item.getParentLayoutMode()=='FLEX'>
<div style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-rowitem<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<div v-show="detailsModel.${item.name}.visible" style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-rowitem<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</div>
<#else>
<i-col ${tableAttr} style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-rowitem<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<i-col v-show="detailsModel.${item.name}.visible" ${tableAttr} style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-rowitem<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</i-col>
</#if>
......
......@@ -2,11 +2,11 @@
./@MACRO/PLAYOUT.vue.ftl
</#ibizinclude>
<#if item.getParentLayoutMode()=='FLEX'>
<div style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-usercontrol<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<div v-show="detailsModel.${item.name}.visible" style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-usercontrol<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</div>
<#else>
<i-col ${tableAttr} style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-usercontrol<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
<i-col v-show="detailsModel.${item.name}.visible" ${tableAttr} style="${flexAttr}<#if item.getPSSysCss()??>${item.getPSSysCss().getRawCssStyle()}</#if>" class="app-layoutpanel-usercontrol<#if item.getPSSysCss()??> ${item.getPSSysCss().getCssName()}</#if>">
${content}
</i-col>
</#if>
\ No newline at end of file
<#list ctrl.getAllPSPanelItems() as panelitem>
<#if panelitem.getPSPanelItemGroupLogic('ITEMBLANK')??>
<#assign ITEMBLANK = panelitem.getPSPanelItemGroupLogic('ITEMBLANK')/>
if (Object.is(name, '')<#if ITEMBLANK.getRelatedItemNames()??><#list ITEMBLANK.getRelatedItemNames() as detailName> || Object.is(name, '${detailName}')</#list></#if>) {
let ret = true;
<#if ITEMBLANK.getRelatedItemNames()??>
<#list ITEMBLANK.getRelatedItemNames() as detailName>
const _${detailName} = this.data.${detailName};
</#list>
</#if>
if (${P.getPartCode(ITEMBLANK, 'DETAIL_LOGIC').code}) {
ret = false;
}
this.rules.${panelitem.name}.some((rule: any) => {
if (rule.hasOwnProperty('required')) {
rule.required = ret;
}
return false;
});
}
</#if>
<#if panelitem.getPSPanelItemGroupLogic('ITEMENABLE')??>
<#assign ITEMENABLE = panelitem.getPSPanelItemGroupLogic('ITEMENABLE')/>
if (Object.is(name, '')<#if ITEMENABLE.getRelatedItemNames()??><#list ITEMENABLE.getRelatedItemNames() as detailName> || Object.is(name, '${detailName}')</#list></#if>) {
let ret = false;
<#if ITEMENABLE.getRelatedItemNames()??>
<#list ITEMENABLE.getRelatedItemNames() as detailName>
const _${detailName} = this.data.${detailName};
</#list>
</#if>
if (${P.getPartCode(ITEMENABLE, 'DETAIL_LOGIC').code}) {
ret = true;
}
this.detailsModel.${panelitem.name}.setDisabled(!ret);
}
</#if>
<#if panelitem.getPSPanelItemGroupLogic('PANELVISIBLE')??>
<#assign PANELVISIBLE = panelitem.getPSPanelItemGroupLogic('PANELVISIBLE')/>
if (Object.is(name, '')<#if PANELVISIBLE.getRelatedItemNames()??><#list PANELVISIBLE.getRelatedItemNames() as detailName> || Object.is(name, '${detailName}')</#list></#if>) {
let ret = false;
<#if PANELVISIBLE.getRelatedItemNames()??>
<#list PANELVISIBLE.getRelatedItemNames() as detailName>
const _${detailName} = this.data.${detailName};
</#list>
</#if>
if (${P.getPartCode(PANELVISIBLE, 'DETAIL_LOGIC').code}) {
ret = true;
}
this.detailsModel.${panelitem.name}.setVisible(ret);
}
</#if>
</#list>
\ No newline at end of file
......@@ -2,6 +2,7 @@
${P.getPartCode(item,'PANEL').code}
</template>
<#assign import_block>
import { FormItemModel } from '@/model/form-detail';
import ${srfclassname('${ctrl.codeName}')}Model from './${srffilepath2(ctrl.codeName)}-${ctrl.getControlType()?lower_case}-model';
import CodeListService from "@service/app/codelist-service";
</#assign>
......@@ -48,6 +49,31 @@ import CodeListService from "@service/app/codelist-service";
*/
public codeListService:CodeListService = new CodeListService({ $store:this.$store });
/**
* 详情模型集合
*
* @type {*}
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public detailsModel: any = {
<#list ctrl.getAllPSPanelItems() as panelItems>
${panelItems.name}: new FormItemModel({ visible: <#if panelItems.getPSPanelItemGroupLogic('PANELVISIBLE')??>false<#else>true</#if>, disabled: false, enableCond: 3 }),
</#list>
};
/**
* 面板逻辑
*
* @public
* @param {{ name: string, newVal: any, oldVal: any }} { name, newVal, oldVal }
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public panelLogic({ name, newVal, oldVal }: { name: string, newVal: any, oldVal: any }): void {
<#if P.getPartCode(item,'PANEL_LOGIC').code?length gt 0>
${P.getPartCode(item,'PANEL_LOGIC').code}
</#if>
}
/**
* 数据模型对象
*
......@@ -73,6 +99,7 @@ import CodeListService from "@service/app/codelist-service";
async onInputDataChange(newVal: any, oldVal: any){
if(newVal){
await this.computedUIData(newVal);
this.panelLogic({ name: '', newVal: null, oldVal: null });
this.$forceUpdate();
}
}
......@@ -185,6 +212,27 @@ import CodeListService from "@service/app/codelist-service";
</#list>
</#if>
/**
* 界面行为
*
* @param {*} row
* @param {*} tag
* @param {*} $event
* @memberof ${srfclassname('${ctrl.codeName}')}
*/
public uiAction(row: any, tag: any, $event: any) {
<#if ctrl.getPSAppViewLogics()??>
<#list ctrl.getPSAppViewLogics() as logic>
<#if logic.getPSAppViewUIAction().getPSUIAction()??>
<#assign action = logic.getPSAppViewUIAction().getPSUIAction()>
if(Object.is('${action.getUIActionTag()}', tag)) {
this.${logic.getName()}(row, tag, $event);
}
</#if>
</#list>
</#if>
}
<#ibizinclude>
../@MACRO/CONTROL/CONTROL_BOTTOM-BASE.vue.ftl
</#ibizinclude>
......
......@@ -5,5 +5,5 @@
type="text"
<#if item.getUnitName?? && item.getUnitName()??>unit="${item.getUnitName()}"</#if>
<#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if>
@change="($event)=>{gridEditItemChange(row, column.property, $event)}">
@change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}">
</input-box>
\ No newline at end of file
<dropdown-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" <#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)=>{gridEditItemChange(row, column.property, $event)}"></dropdown-list>
\ No newline at end of file
<dropdown-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" <#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)=>{gridEditItemChange(row, column.property, $event, $index)}"></dropdown-list>
\ No newline at end of file
<app-org-select :data="data" :context="JSON.parse(JSON.stringify(context))" :fillMap="<#if item.getEditorParam('FILLMAP','') != ''>${item.getEditorParam('FILLMAP','')}<#else>{}</#if>" filter="<#if item.getEditorParam('FILTER','') != ''>${item.getEditorParam('FILTER','')}</#if>" :multiple="<#if item.getEditorParam('MULTIPLE','') != ''>${item.getEditorParam('MULTIPLE','')}</#if>" style="${editor.getEditorCssStyle()}" @formitemvaluechange="onFormItemValueChange"></app-org-select>
\ No newline at end of file
<span>单位选择</span>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=DROPDOWNLIST#ORGSELECT
\ No newline at end of file
<app-department-select :data="data" name="${editor.name}" :value="data.${editor.name}" :context="JSON.parse(JSON.stringify(context))" :fillMap="<#if item.getEditorParam('FILLMAP','') != ''>${item.getEditorParam('FILLMAP','')}<#else>{}</#if>" filter="<#if item.getEditorParam('FILTER','') != ''>${item.getEditorParam('FILTER','')}</#if>" <#if item.getEditorParam('MULTIPLE','') != ''>:multiple="${item.getEditorParam('MULTIPLE','')}"</#if> <#if item.getEditorParam('URL','') != ''>url="${item.getEditorParam('URL','')}"</#if> style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-department-select>
\ No newline at end of file
<span>部门选择</span>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=DROPDOWNLIST#DEPATMENTSELECT
\ No newline at end of file
<dropdown-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" <#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)=>{gridEditItemChange(row, column.property, $event)}"></dropdown-list>
\ No newline at end of file
<dropdown-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" <#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)=>{gridEditItemChange(row, column.property, $event, $index)}"></dropdown-list>
\ No newline at end of file
<dropdown-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}width: 100px;" <#if item.getPSCodeList()??><#assign codelist=item.getPSCodeList()>tag='${codelist.codeName}' codelistType='${codelist.getCodeListType()}'</#if> placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if> @change="($event)=>{gridEditItemChange(row, column.property, $event)}"></dropdown-list>
\ No newline at end of file
<dropdown-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}width: 100px;" <#if item.getPSCodeList()??><#assign codelist=item.getPSCodeList()>tag='${codelist.codeName}' codelistType='${codelist.getCodeListType()}'</#if> placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if> @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"></dropdown-list>
\ No newline at end of file
......@@ -9,6 +9,6 @@
<#if codelist.valueSeparator?has_content>valueSeparator="${codelist.valueSeparator}"</#if>
</#if>
placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if>
@change="($event)=>{gridEditItemChange(row, column.property, $event)}"
@change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"
style="${item.getEditorCssStyle()}">
</dropdown-list-mpicker>
\ No newline at end of file
<#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<ibiz-group-select
name="${editor.name}"
:value='data.${editor.name}'
valueitem="${editor.getValueItemName()}"
url=<#if editor.getEditorParam("url", "") != "">"${editor.getEditorParam("url", "")}"</#if>
<#if editor.getEditorParam("treeurl", "") != "">treeurl="${editor.getEditorParam("treeurl", "")}"</#if>
:multiple="<#if editor.getEditorParam("multiple", "") != "">${editor.getEditorParam("multiple", "")}<#else>true</#if>"
filter=<#if editor.getEditorParam("filter", "") != "">"${editor.getEditorParam("filter", "")}"<#else>"srforgid"</#if>
:fillmap=<#if editor.getEditorParam("fillMap", "") != "">"${editor.getEditorParam("fillMap", "")}"<#else>"{'id':'${editor.getValueItemName()}','label':'${editor.name}'}"</#if>
:disabled="detailsModel.${editor.name}.disabled"
:data="data"
:context="context"
@formitemvaluechange="onFormItemValueChange">
</ibiz-group-select>
EDITORTYPE=PICKER#EMPSELECT
\ No newline at end of file
<#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<ibiz-group-select
name="${editor.name}"
:value='data.${editor.name}'
valueitem="${editor.getValueItemName()}"
url=<#if editor.getEditorParam("url", "") != "">"${editor.getEditorParam("url", "")}"</#if>
<#if editor.getEditorParam("treeurl", "") != "">treeurl="${editor.getEditorParam("treeurl", "")}"</#if>
:multiple="<#if editor.getEditorParam("multiple", "") != "">${editor.getEditorParam("multiple", "")}<#else>true</#if>"
filter=<#if editor.getEditorParam("filter", "") != "">"${editor.getEditorParam("filter", "")}"<#else>"srforgid"</#if>
:fillmap=<#if editor.getEditorParam("fillMap", "") != "">"${editor.getEditorParam("fillMap", "")}"<#else>"{'id':'${editor.getValueItemName()}','label':'${editor.name}'}"</#if>
:disabled="detailsModel.${editor.name}.disabled"
:data="data"
:context="context"
@formitemvaluechange="onFormItemValueChange">
</ibiz-group-select>
EDITORTYPE=PICKER#EMPMULTIPLE
\ No newline at end of file
<#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<ibiz-group-select
name="${editor.name}"
:value='data.${editor.name}'
valueitem="${editor.getValueItemName()}"
url=<#if editor.getEditorParam("url", "") != "">"${editor.getEditorParam("url", "")}"</#if>
<#if editor.getEditorParam("treeurl", "") != "">treeurl="${editor.getEditorParam("treeurl", "")}"</#if>
:multiple="<#if editor.getEditorParam("multiple", "") != "">${editor.getEditorParam("multiple", "")}<#else>true</#if>"
filter=<#if editor.getEditorParam("filter", "") != "">"${editor.getEditorParam("filter", "")}"<#else>"srforgid"</#if>
:fillmap=<#if editor.getEditorParam("fillMap", "") != "">"${editor.getEditorParam("fillMap", "")}"<#else>"{'id':'${editor.getValueItemName()}','label':'${editor.name}'}"</#if>
:disabled="detailsModel.${editor.name}.disabled"
:data="data"
:context="context"
@formitemvaluechange="onFormItemValueChange">
</ibiz-group-select>
<#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<ibiz-group-select
name="${editor.name}"
:value='data.${editor.name}'
valueitem="${editor.getValueItemName()}"
url=<#if editor.getEditorParam("url", "") != "">"${editor.getEditorParam("url", "")}"</#if>
<#if editor.getEditorParam("treeurl", "") != "">treeurl="${editor.getEditorParam("treeurl", "")}"</#if>
:multiple="<#if editor.getEditorParam("multiple", "") != "">${editor.getEditorParam("multiple", "")}<#else>true</#if>"
filter=<#if editor.getEditorParam("filter", "") != "">"${editor.getEditorParam("filter", "")}"<#else>"srforgid"</#if>
:fillmap=<#if editor.getEditorParam("fillMap", "") != "">"${editor.getEditorParam("fillMap", "")}"<#else>"{'id':'${editor.getValueItemName()}','label':'${editor.name}'}"</#if>
:disabled="detailsModel.${editor.name}.disabled"
:data="data"
:context="context"
@formitemvaluechange="onFormItemValueChange">
</ibiz-group-select>
<app-org-select :data="data" :context="JSON.parse(JSON.stringify(context))" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :multiple="<#if item.getEditorParam('multiple','') != ''>${item.getEditorParam('multiple','')}<#else>false</#if>" style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-org-select>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
<app-org-select :data="data" :context="JSON.parse(JSON.stringify(context))" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :multiple="<#if item.getEditorParam('multiple','') != ''>${item.getEditorParam('multiple','')}<#else>false</#if>" style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-org-select>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
<app-org-select :data="data" :context="JSON.parse(JSON.stringify(context))" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :multiple="<#if item.getEditorParam('multiple','') != ''>${item.getEditorParam('multiple','')}<#else>false</#if>" style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-org-select>
\ No newline at end of file
<span>单位选择</span>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=PICKER#ALLORGSELECT
\ No newline at end of file
<app-org-select :data="data" :context="JSON.parse(JSON.stringify(context))" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :multiple="<#if item.getEditorParam('multiple','') != ''>${item.getEditorParam('multiple','')}<#else>false</#if>" style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-org-select>
\ No newline at end of file
<span>单位选择</span>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=PICKER#ALLORGMULTIPLE
\ No newline at end of file
<app-radio-group v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" name="${item.name}" @change="($event)=>{gridEditItemChange(row, column.property, $event)}" <#if item.isNeedCodeListConfig()??><#assign codelist=item.getPSCodeList()>tag='${codelist.codeName}' codelistType='${codelist.getCodeListType()}' </#if> style="${item.getEditorCssStyle()}"></app-radio-group>
\ No newline at end of file
<app-radio-group v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" name="${item.name}" @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}" <#if item.isNeedCodeListConfig()??><#assign codelist=item.getPSCodeList()>tag='${codelist.codeName}' codelistType='${codelist.getCodeListType()}' </#if> style="${item.getEditorCssStyle()}"></app-radio-group>
\ No newline at end of file
<app-file-upload
:formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
:data="JSON.stringify(row)"
:name='column.property'
:value="row[column.property]"
......
<app-file-upload
:formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
:data="JSON.stringify(row)"
:name='column.property'
:value="row[column.property]"
......
......@@ -14,7 +14,7 @@
</#if>
:acParams=<@getAcParams editor />
:pickupView=<@getPickupView editor />
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
style="${editor.getEditorCssStyle()}">
</app-mpicker>
</#if>
\ No newline at end of file
......@@ -14,7 +14,7 @@
</#if>
:acParams=<@getAcParams editor />
:pickupView=<@getPickupView editor />
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
style="${editor.getEditorCssStyle()}">
</app-mpicker>
</#if>
\ No newline at end of file
<app-wf-approval v-model="srfwfmemo" :service="appEntityService" :context="JSON.parse(JSON.stringify(context))" :viewparams="JSON.parse(JSON.stringify(viewparams))"></app-wf-approval>
\ No newline at end of file
<div class="ivu-input-wrapper ivu-input-wrapper-default ivu-input-type">
<textarea class="ivu-input" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" v-model="row[column.property]" style="${item.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if> @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"></textarea>
</div>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=TEXTAREA#WFAPPROVAL
\ No newline at end of file
<div class="ivu-input-wrapper ivu-input-wrapper-default ivu-input-type">
<textarea class="ivu-input" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" v-model="row[column.property]" style="${item.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if> @change="($event)=>{gridEditItemChange(row, column.property, $event)}"></textarea>
<textarea class="ivu-input" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" v-model="row[column.property]" style="${item.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if> @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"></textarea>
</div>
\ No newline at end of file
<div class="ivu-input-wrapper ivu-input-wrapper-default ivu-input-type">
<textarea class="ivu-input" rows="10" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" v-model="row[column.property]" style="${item.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if> @change="($event)=>{gridEditItemChange(row, column.property, $event)}"></textarea>
<textarea class="ivu-input" rows="10" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" v-model="row[column.property]" style="${item.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if> @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"></textarea>
</div>
\ No newline at end of file
<input-box type="password" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" v-model="row[column.property]" style="${item.getEditorCssStyle()}" @change="($event)=>{gridEditItemChange(row, column.property, $event)}"></input-box>
\ No newline at end of file
<input-box type="password" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" v-model="row[column.property]" style="${item.getEditorCssStyle()}" @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"></input-box>
\ No newline at end of file
<app-switch name='${editor.name}' :value="row[column.property]" @change="($event)=>{row[column.property] = $event;gridEditItemChange(row, column.property, $event)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-switch>
\ No newline at end of file
<app-switch name='${editor.name}' :value="row[column.property]" @change="($event)=>{row[column.property] = $event;gridEditItemChange(row, column.property, $event, $index)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-switch>
\ No newline at end of file
......@@ -5,5 +5,5 @@
type="number"
style="${item.getEditorCssStyle()}"
<#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if>
@change="($event)=>{gridEditItemChange(row, column.property, $event)}">
@change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}">
</input-box>
\ No newline at end of file
......@@ -20,7 +20,7 @@
editortype=""
:pickupView=<@getPickupView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
<@getItemRender editor />
</app-picker>
</#if>
......
......@@ -19,7 +19,7 @@
:pickupView=<@getPickupView editor />
:linkview=<@getLinkView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
</app-picker-select-view>
</#if>
</#if>
\ No newline at end of file
......@@ -21,7 +21,7 @@
:value="row[column.property]"
:pickupView=<@getPickupView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
</app-picker-select-view>
</#if>
</#if>
\ No newline at end of file
......@@ -17,6 +17,6 @@
:value="row[column.property]"
editortype="dropdown"
style="${item.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
<@getItemRender editor />
</app-picker>
\ No newline at end of file
......@@ -21,7 +21,7 @@
<#if item.getResetItemName()?? && (item.getResetItemName()?length gt 0)>
refreshitems="${item.getResetItemName()}"
</#if>
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
style="${editor.getEditorCssStyle()}">
</app-embed-picker>
</#if>
\ No newline at end of file
......@@ -21,7 +21,7 @@
:pickupView=<@getPickupView editor />
:linkview=<@getLinkView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
<@getItemRender editor />
</app-picker>
</#if>
......
......@@ -19,7 +19,7 @@
:pickupView=<@getPickupView editor />
:linkview=<@getLinkView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
</app-picker>
</#if>
</#if>
\ No newline at end of file
......@@ -18,7 +18,7 @@
editortype="pickup-no-ac"
:pickupView=<@getPickupView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
</app-picker>
</#if>
</#if>
\ No newline at end of file
<#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<ibiz-group-select
name="${editor.name}"
:value='data.${editor.name}'
valueitem="${editor.getValueItemName()}"
<#if editor.getEditorParam("MULTIPLE", false)>:multiple="true"</#if>
<#if editor.getEditorParam("FILTER", "") != "">filter="${editor.getEditorParam("FILTER", "")}"</#if>
<#if editor.getEditorParam("FILLMAP", "") != "">:fillmap='${editor.getEditorParam("FILLMAP", "")}'</#if>
:disabled="detailsModel.${editor.name}.disabled"
:data="data"
:context="context"
@formitemvaluechange="onFormItemValueChange">
</ibiz-group-select>
EDITORTYPE=PICKER#GroupSelect
\ No newline at end of file
......@@ -19,7 +19,7 @@
<#if item.getResetItemName()?? && (item.getResetItemName()?length gt 0)>
refreshitems="${item.getResetItemName()}"
</#if>
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
style="${editor.getEditorCssStyle()}">
</app-tree-picker>
</#if>
\ No newline at end of file
......@@ -16,5 +16,5 @@
editortype="linkonly"
:linkview=<@getLinkView editor />
style="${editor.getEditorCssStyle()}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}">
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}">
</app-picker>
\ No newline at end of file
<app-file-upload
:formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
:data="JSON.stringify(row)"
:name='column.property'
:value="row[column.property]"
......
......@@ -2,7 +2,7 @@
:isdrag="true"
:formState="viewState"
:ignorefieldvaluechange="false"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event)}"
@formitemvaluechange="($event)=>{onGridItemValueChange(row,$event,$index)}"
:data="JSON.stringify(row)"
:name='column.property'
:value="row[column.property]"
......
<date-picker type="datetime" :transfer="true" format="yyyy-MM-dd HH:mm:ss" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :value="row[column.property]" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val1, val2) => { row[column.property] = val1; gridEditItemChange(row, column.property, val1)}"></date-picker>
\ No newline at end of file
<date-picker type="datetime" :transfer="true" format="yyyy-MM-dd HH:mm:ss" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :value="row[column.property]" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val1, val2) => { row[column.property] = val1; gridEditItemChange(row, column.property, val1, $index)}"></date-picker>
\ No newline at end of file
<date-picker type="date" :transfer="true" format="yyyy-MM-dd" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :value="row[column.property]" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val1, val2) => { row[column.property] = val1; gridEditItemChange(row, column.property, val1)}"></date-picker>
\ No newline at end of file
<date-picker type="date" :transfer="true" format="yyyy-MM-dd" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :value="row[column.property]" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val1, val2) => { row[column.property] = val1; gridEditItemChange(row, column.property, val1, $index)}"></date-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="mm" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="mm" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val, $index)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="HH" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="HH" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val, $index)}"></time-picker>
\ No newline at end of file
<date-picker type="date" :transfer="true" format="yyyy-MM-dd" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :value="row[column.property]" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val1, val2) => { row[column.property] = val1; gridEditItemChange(row, column.property, val1)}"></date-picker>
\ No newline at end of file
<date-picker type="date" :transfer="true" format="yyyy-MM-dd" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" :value="row[column.property]" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val1, val2) => { row[column.property] = val1; gridEditItemChange(row, column.property, val1, $index)}"></date-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="HH:mm:ss" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="HH:mm:ss" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val, $index)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="HH:mm" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="HH:mm" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val, $index)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="ss" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val)}"></time-picker>
\ No newline at end of file
<time-picker :value="row[column.property]" :transfer="true" format="ss" placeholder="请选择时间..." :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}<#if item.getEditorParam('width','') == 'auto'>width:100%;</#if>" @on-change="(val) => { row[column.property] = val; gridEditItemChange(row, column.property, val, $index)}"></time-picker>
\ No newline at end of file
<app-stepper name='${editor.name}' :value="row[column.property]" @change="($event)=>{onGridItemValueChange(row,$event)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-stepper>
<app-stepper name='${editor.name}' :value="row[column.property]" @change="($event)=>{onGridItemValueChange(row,$event,$index)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-stepper>
<app-slider name='${editor.name}' :value="row[column.property]" @change="($event)=>{onGridItemValueChange(row,$event)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-slider>
\ No newline at end of file
<app-slider name='${editor.name}' :value="row[column.property]" @change="($event)=>{onGridItemValueChange(row,$event,$index)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-slider>
\ No newline at end of file
<app-rate name='${item.name}' :value="row[column.property]" @change="($event)=>{row[column.property] = $event; gridEditItemChange(row, column.property, $event)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-rate>
\ No newline at end of file
<app-rate name='${item.name}' :value="row[column.property]" @change="($event)=>{row[column.property] = $event; gridEditItemChange(row, column.property, $event, $index)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" style="${item.getEditorCssStyle()}"></app-rate>
\ No newline at end of file
<div style="${item.getEditorCssStyle()}">
<app-checkbox :value="row[column.property]" @change="($event)=>{row[column.property] = $event;gridEditItemChange(row, column.property, $event)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"></app-checkbox>
<app-checkbox :value="row[column.property]" @change="($event)=>{row[column.property] = $event;gridEditItemChange(row, column.property, $event, $index)} " :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1"></app-checkbox>
</div>
\ No newline at end of file
<app-checkbox-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" <#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="${item.name}" @change="($event)=>{gridEditItemChange(row, column.property, $event)}"></app-checkbox-list>
\ No newline at end of file
<app-checkbox-list v-model="row[column.property]" :disabled="row.srfuf === 1 ? (${item.getEnableCond()?c} & 2) !== 2 : (${item.getEnableCond()?c} & 1) !== 1" <#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="${item.name}" @change="($event)=>{gridEditItemChange(row, column.property, $event, $index)}"></app-checkbox-list>
\ No newline at end of file
<app-department-select :data="data" :context="JSON.parse(JSON.stringify(context))" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}<#else>/ibzorganizations/${orgid}/ibzdepartments/picker</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" :multiple=<#if item.getEditorParam('multiple','') != ''>"${item.getEditorParam('multiple','')}"<#else>"false"</#if> style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-department-select>
\ No newline at end of file
<span>部门选择</span>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=PICKER#DEPATMENTSELECT
\ No newline at end of file
<app-department-select :data="data" :context="JSON.parse(JSON.stringify(context))" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}<#else>/ibzorganizations/${orgid}/ibzdepartments/picker</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" :multiple=<#if item.getEditorParam('multiple','') != ''>"${item.getEditorParam('multiple','')}"<#else>"false"</#if> style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-department-select>
\ No newline at end of file
<span>部门选择</span>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=PICKER#DEPATMENTMULTIPLE
\ No newline at end of file
<app-department-select :data="data" :context="JSON.parse(JSON.stringify(context))" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}<#else>/ibzorganizations/${orgid}/ibzdepartments/picker</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" :multiple=<#if item.getEditorParam('multiple','') != ''>"${item.getEditorParam('multiple','')}"<#else>"false"</#if> style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-department-select>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=PICKER#ALLDEPATMENTSELECT
\ No newline at end of file
<app-department-select :data="data" :context="JSON.parse(JSON.stringify(context))" url="<#if item.getEditorParam('url','') != ''>${item.getEditorParam('url','')}<#else>/ibzorganizations/${orgid}/ibzdepartments/picker</#if>" filter="<#if item.getEditorParam('filter','') != ''>${item.getEditorParam('filter','')}<#else>srforgid</#if>" :fillMap="<#if item.getEditorParam('fillMap','') != ''>${item.getEditorParam('fillMap','')}<#else>{'id':'${editor.getValueItemName()}','label':'${editor.name}'}</#if>" :multiple=<#if item.getEditorParam('multiple','') != ''>"${item.getEditorParam('multiple','')}"<#else>"false"</#if> style="${editor.getEditorCssStyle()}" @select-change="onFormItemValueChange"></app-department-select>
\ No newline at end of file
<#ibizinclude>../@MACRO/PANEL/DEFAULT.vue.ftl</#ibizinclude>
\ No newline at end of file
EDITORTYPE=PICKER#ALLDEPATMENTMULTIPLE
\ No newline at end of file
......@@ -218,7 +218,7 @@ if(this.formDruipart){
if(quickGroupCodeList.tag && Object.is(quickGroupCodeList.codelistType,"STATIC")){
const codelist = this.$store.getters.getCodeList(quickGroupCodeList.tag);
if (codelist) {
this.quickGroupModel = [...JSON.parse(JSON.stringify(codelist.items))];
this.quickGroupModel = [...this.handleDynamicData(JSON.parse(JSON.stringify(codelist.items)))];
} else {
<#noparse>console.log(`----${quickGroupCodeList.tag}----代码表不存在`);</#noparse>
}
......@@ -232,6 +232,33 @@ if(this.formDruipart){
</#if>
}
/**
* 处理快速分组模型动态数据部分(%xxx%)
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public handleDynamicData(inputArray:Array<any>){
if(inputArray.length >0){
inputArray.forEach((item:any) =>{
if(item.data && Object.keys(item.data).length >0){
Object.keys(item.data).forEach((name:any) =>{
let value: any = item.data[name];
if (value && typeof(value)=='string' && value.startsWith('%') && value.endsWith('%')) {
const key = (value.substring(1, value.length - 1)).toLowerCase();
if (this.context[key]) {
value = this.context[key];
} else if(this.viewparams[key]){
value = this.viewparams[key];
}
}
item.data[name] = value;
})
}
})
}
return inputArray;
}
/**
* 快速分组值变化
*
......
......@@ -3,10 +3,22 @@
./LAYOUTPANEL_VIEW.template.ftl
</#ibizinclude>
<#assign import_block>
import CodeListService from "@service/app/codelist-service";
<#if view.getPSSysCounterRef?? && view.getPSSysCounterRef()?? && view.getPSSysCounterRef().getPSAppCounter()??>
<#assign appCounter = view.getPSSysCounterRef().getPSAppCounter() />
import ${srfclassname('${appCounter.getCodeName()}')}CounterService from '@/counter/${srffilepath2(appCounter.getCodeName())}/${srffilepath2(appCounter.getCodeName())}-counter';
</#if>
</#assign>
<#ibizinclude>
./VIEW_HEADER-BASE.vue.ftl
</#ibizinclude>
<#assign mounted_block>
<#if view.isEnableQuickGroup()>_this.loadQuickGroupModel();</#if>
</#assign>
<#ibizinclude>
./VIEW_CONTENT-BASE.vue.ftl
</#ibizinclude>
......@@ -39,6 +51,136 @@
}
}
<#if view.getPSSysCounterRef() ?? && view.getPSSysCounterRef().getPSAppCounter()??>
<#assign appCounter = view.getPSSysCounterRef().getPSAppCounter() />
/**
* ${srfclassname('${appCounter.getCodeName()}')}CounterService计数器服务对象
*
* @type {${srfclassname('${appCounter.getCodeName()}')}CounterService}
* @memberof ${srfclassname('${view.name}')}Base
*/
public ${srfclassname('${appCounter.getCodeName()}')}counterservice: ${srfclassname('${appCounter.getCodeName()}')}CounterService = new ${srfclassname('${appCounter.getCodeName()}')}CounterService({ $store: this.$store });
</#if>
<#if view.isEnableQuickGroup()>
/**
* 代码表服务对象
*
* @type {CodeListService}
* @memberof ${srfclassname('${view.name}')}Base
*/
public codeListService:CodeListService = new CodeListService({ $store: this.$store });
/**
* 快速分组数据对象
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public qucikGroupData:any;
/**
* 快速分组是否有抛值
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public isEmitQuickGroupValue:boolean = false;
/**
* 快速分组模型
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public quickGroupModel:Array<any> = [];
/**
* 加载快速分组模型
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public loadQuickGroupModel(){
<#if view.getQuickGroupPSCodeList()??>
<#assign codelist=view.getQuickGroupPSCodeList() />
let quickGroupCodeList:any = {tag:'${codelist.codeName}',codelistType:'${codelist.getCodeListType()}'};
if(quickGroupCodeList.tag && Object.is(quickGroupCodeList.codelistType,"STATIC")){
const codelist = this.$store.getters.getCodeList(quickGroupCodeList.tag);
if (codelist) {
this.quickGroupModel = [...this.handleDynamicData(JSON.parse(JSON.stringify(codelist.items)))];
} else {
<#noparse>console.log(`----${quickGroupCodeList.tag}----代码表不存在`);</#noparse>
}
}else if(quickGroupCodeList.tag && Object.is(quickGroupCodeList.codelistType,"DYNAMIC")){
this.codeListService.getItems(quickGroupCodeList.tag,{},{}).then((res:any) => {
this.quickGroupModel = res;
}).catch((error:any) => {
<#noparse>console.log(`----${quickGroupCodeList.tag}----代码表不存在`);</#noparse>
});
}
</#if>
}
/**
* 处理快速分组模型动态数据部分(%xxx%)
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public handleDynamicData(inputArray:Array<any>){
if(inputArray.length >0){
inputArray.forEach((item:any) =>{
if(item.data && Object.keys(item.data).length >0){
Object.keys(item.data).forEach((name:any) =>{
let value: any = item.data[name];
if (value && typeof(value)=='string' && value.startsWith('%') && value.endsWith('%')) {
const key = (value.substring(1, value.length - 1)).toLowerCase();
if (this.context[key]) {
value = this.context[key];
} else if(this.viewparams[key]){
value = this.viewparams[key];
}
}
item.data[name] = value;
})
}
})
}
return inputArray;
}
/**
* 快速分组值变化
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public qucikGroupValueChange($event:any){
if($event && $event.data){
this.qucikGroupData = $event.data;
if(this.isEmitQuickGroupValue){
this.onSearch($event);
}
}
this.isEmitQuickGroupValue = true;
}
</#if>
<#if view.getQuickPSDESearchForm()??>
/**
* 快速搜索栏数据对象
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public qucikFormData:any;
/**
* 快速搜索栏值变化
*
* @memberof ${srfclassname('${view.name}')}Base
*/
public qucikFormValueChange($event:any){
this.qucikFormData = $event;
this.onSearch($event);
}
</#if>
<#ibizinclude>
./VIEW_BOTTOM-BASE.vue.ftl
</#ibizinclude>
......
<#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>
../@MACRO/LAYOUTPANEL_VIEW.template.ftl
</#ibizinclude>
......
<#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=APPDEGANTTVIEW9
\ No newline at end of file
......@@ -57,6 +57,17 @@
</#if>
}
/**
* tree 部件 nodedblclick 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof ${srfclassname('${view.name}')}Base
*/
public tree_nodedblclick($event: any, $event2?: any) {
this.engine.onCtrlEvent('tree', 'nodedblclick', $event);
}
<#ibizinclude>
../@MACRO/VIEW_BOTTOM-BASE.vue.ftl
</#ibizinclude>
......
......@@ -4,12 +4,14 @@ import VueRouter from 'vue-router';
import App from '@/App.vue';
import ElementUi from 'element-ui';
import ViewUI from 'view-design';
import ibizLab from 'ibiz-vue-lib';
import { Interceptors } from '@/utils';
import {Print} from '@/utils/print';
import i18n from '@/locale'
import 'element-ui/lib/theme-chalk/index.css';
import 'view-design/dist/styles/iview.css';
import 'ibiz-vue-lib/lib/ibiz-vue-lib.css';
import '@/styles/default.less';
......@@ -30,7 +32,8 @@ Vue.config.errorHandler = function (err: any, vm: any, info: any) {
console.log(err);
}
Vue.config.productionTip = false;
Vue.use(Print)
Vue.use(Print);
Vue.use(ibizLab);
Vue.use(Vuex);
Vue.use(VueRouter);;
Vue.use(ElementUi, {
......
......@@ -19,7 +19,7 @@ module.exports = {
port: 8111,
compress: true,
disableHostCheck: true,
// proxy: "http://127.0.0.1:8080/${app.getPKGCodeName()}",
// proxy: "http://127.0.0.1:<#if app.getHttpPort?? && app.getHttpPort() == 0>8080<#else>${app.getHttpPort()?c}</#if>/",
historyApiFallback: {
rewrites: [
<#if app.getAllRefPSAppViews()??>
......
## v7.0.0-alpha.5 [2020-5-28]
### Bug修复
修复处理快速分组模型动态数据部分
修复列表,数据视图默认排序
修复门户部件flex布局
修复表格选择框列样式出现省略号
修复批删除传递参数调整
修复表单上界面行为参数传递bug
修复分页导航、编辑类视图标题
修复界面行为多主键分隔符由";"改为","
修复导航类视图宽度格式
修复图表排序
修复关系界面逻辑
修复401跳登录页清除user和token
修复树导航debug展示位置
修复菜单默认展开
修复快速搜索框bug
### 功能新增及优化
#### 模板
补充单位选择器、部门选择器、人员选择器
面板项支持偏移
应用支持自定义默认端口
门户部件图标和容器样式
表格列头图片和头部样式
表格操作列图标
表格编辑项值规则
增加树选择双击事件
增加图表分组属性计数统计(srfcount)
增加雷达图支持
#### 基础文件
补充单位选择器、部门选择器、人员选择器
修复分页导航、编辑类视图标题
修复界面行为多主键分隔符由";"改为","
修复关系界面逻辑
修复401跳登录页清除user和token
修复树导航debug展示位置
修复菜单默认展开
修复快速搜索框bug
## v7.0.0-alpha.4 [2020-5-21]
### Bug修复
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册