提交 eb6c6160 编写于 作者: chitanda's avatar chitanda

合并分支 'master' 到 'suyan'

Master

查看合并请求 !8
......@@ -4,15 +4,15 @@
<#assign layout = LayoutPos.getLayout()/>
</#if>
<#if layout == 'TABLE_24COL' && LayoutPos??>
<i-col <#if formmenber.getDetailType?? && formmenber.getDetailType()?? && formmenber.getDetailType() == 'DRUIPART'>v-if="detailsModel.${formmenber.name}.visible"<#else>v-show="detailsModel.${formmenber.name}.visible"</#if> :style="{<#if (formmenber.getHeight?? && formmenber.getHeight() gt 0)>'height': '${formmenber.getHeight()?c}px !important',</#if><#if (formmenber.getWidth?? && formmenber.getWidth() gt 0)>'width':'${formmenber.getWidth()?c}px !important'</#if>}" <#if LayoutPos.getColXS() != -1> :sm="{ span: ${LayoutPos.getColXS()}, offset: <#if LayoutPos.getColXSOffset() != -1>${LayoutPos.getColXSOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColSM() != -1> :md="{ span: ${LayoutPos.getColSM()}, offset: <#if LayoutPos.getColSMOffset() != -1>${LayoutPos.getColSMOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColMD() != -1> :lg="{ span: ${LayoutPos.getColMD()}, offset: <#if LayoutPos.getColMDOffset() != -1>${LayoutPos.getColMDOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColLG() != -1> :xl="{ span: ${LayoutPos.getColLG()}, offset: <#if LayoutPos.getColLGOffset() != -1>${LayoutPos.getColLGOffset()}<#else>0</#if> }"</#if>>
<i-col v-show="detailsModel.${formmenber.name}.visible" :style="{<#if (formmenber.getHeight?? && formmenber.getHeight() gt 0)>'height': '${formmenber.getHeight()?c}px !important',</#if><#if (formmenber.getWidth?? && formmenber.getWidth() gt 0)>'width':'${formmenber.getWidth()?c}px !important'</#if>}" <#if LayoutPos.getColXS() != -1> :sm="{ span: ${LayoutPos.getColXS()}, offset: <#if LayoutPos.getColXSOffset() != -1>${LayoutPos.getColXSOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColSM() != -1> :md="{ span: ${LayoutPos.getColSM()}, offset: <#if LayoutPos.getColSMOffset() != -1>${LayoutPos.getColSMOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColMD() != -1> :lg="{ span: ${LayoutPos.getColMD()}, offset: <#if LayoutPos.getColMDOffset() != -1>${LayoutPos.getColMDOffset()}<#else>0</#if> }"</#if><#if LayoutPos.getColLG() != -1> :xl="{ span: ${LayoutPos.getColLG()}, offset: <#if LayoutPos.getColLGOffset() != -1>${LayoutPos.getColLGOffset()}<#else>0</#if> }"</#if>>
${P.getPartCode(formmenber).code}
</i-col>
<#elseif layout == 'FLEX'>
<div <#if formmenber.getDetailType?? && formmenber.getDetailType()?? && formmenber.getDetailType() == 'DRUIPART'>v-if="detailsModel.${formmenber.name}.visible"<#else>v-show="detailsModel.${formmenber.name}.visible"</#if> :style="{<#if LayoutPos.getGrow() != -1>'flex-grow': '${LayoutPos.getGrow()?c}',<#if !LayoutPos.getHeight()??>'height': 0,</#if></#if><#if LayoutPos.getWidth()??>'width': '${LayoutPos.getWidth()?c}px',</#if><#if LayoutPos.getHeight()??>'height':'${LayoutPos.getHeight()?c}px'</#if>}">
<div v-show="detailsModel.${formmenber.name}.visible" :style="{<#if LayoutPos.getGrow() != -1>'flex-grow': '${LayoutPos.getGrow()?c}',<#if !LayoutPos.getHeight()??>'height': 0,</#if></#if><#if LayoutPos.getWidth()??>'width': '${LayoutPos.getWidth()?c}px',</#if><#if LayoutPos.getHeight()??>'height':'${LayoutPos.getHeight()?c}px'</#if>}">
${P.getPartCode(formmenber).code}
</div>
<#else>
<div <#if formmenber.getDetailType?? && formmenber.getDetailType()?? && formmenber.getDetailType() == 'DRUIPART'>v-if="detailsModel.${formmenber.name}.visible"<#else>v-show="detailsModel.${formmenber.name}.visible"</#if>>
<div v-show="detailsModel.${formmenber.name}.visible">
${P.getPartCode(formmenber).code}
</div>
</#if>
\ No newline at end of file
import { Http,Util,Errorlog } from '@/utils';
import ControlService from '@/widgets/control-service';
import UtilService from '@/utilservice/util-service';
<#if appde??>
import ${srfclassname('${appde.getCodeName()}')}Service from '@/service/${srffilepath2(appde.getCodeName())}/${srffilepath2(appde.getCodeName())}-service';
</#if>
......@@ -36,6 +37,15 @@ export default class ${srfclassname('${ctrl.codeName}')}Service extends ControlS
}
</#if>
/**
* 工具服务对象
*
* @protected
* @type {UtilService}
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
protected utilService: UtilService = new UtilService();
/**
* Creates an instance of ${srfclassname('${ctrl.codeName}')}Service.
*
......
......@@ -19,7 +19,6 @@ ${ctrl.render.code}
:key="'${form.name}'"
:viewState='wizardState'
:context="context"
:viewtag="viewtag"
:viewparams="viewparams"
updateAction="<#if form.getUpdatePSControlAction()?? && form.getUpdatePSControlAction().getPSAppDEMethod()??>${form.getUpdatePSControlAction().getPSAppDEMethod().getCodeName()}</#if>"
removeAction="<#if form.getRemovePSControlAction()?? && form.getRemovePSControlAction().getPSAppDEMethod()??>${form.getRemovePSControlAction().getPSAppDEMethod().getCodeName()}</#if>"
......@@ -71,14 +70,6 @@ ${ctrl.render.code}
*/
@Prop({ default: true }) public showBusyIndicator?: boolean;
/**
* 视图标识
*
* @type {string}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
@Prop() public viewtag!: string;
/**
* 状态属性
*
......@@ -340,9 +331,6 @@ ${ctrl.render.code}
public ${ctrl.name}_formload(args: any, name: string, $event2?: any) {
if(args) {
Object.assign(this.formParam, args);
if (Object.is(this.curState, 'NEXT') || Object.is(this.curState, 'PREV')) {
this.$store.commit('viewaction/setViewDataChange', { viewtag: this.viewtag, viewdatachange: true });
}
}
}
......
<#assign content>
:showBusyIndicator="${ctrl.isShowBusyIndicator()?c}"
:viewtag="viewtag"
<#if ctrl.getPSControlActions()??>
<#list ctrl.getPSControlActions() as action>
<#if action.getPSAppDEMethod?? && action.getPSAppDEMethod()??>
......
......@@ -29,7 +29,7 @@
<template v-else>
<i class='fa fa-cogs app-menu-icon'></i>
</template>
<span class='text' :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name)">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name)}}</span>
<span class='text' :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name.toLowerCase())">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name.toLowerCase())}}</span>
</template>
<template v-for="item1 in item0.items">
<template v-if="item1.items && Array.isArray(item1.items) && item1.items.length > 0">
......@@ -41,7 +41,7 @@
<template v-else-if="item1.iconcls && item1.iconcls != ''">
<i :class="[item1.iconcls, 'app-menu-icon']"></i>
</template>
<span class='text' :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name)">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name)}}</span>
<span class='text' :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name.toLowerCase())">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name.toLowerCase())}}</span>
</template>
<template v-for="item2 in item1.items">
<template v-if="item2.type =='MENUITEM'">
......@@ -53,7 +53,7 @@
<i :class="[item2.iconcls, 'app-menu-icon']"></i>
</template>
<template slot="title">
<span class="text" :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item2.name)">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item2.name)}}</span>
<span class="text" :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item2.name.toLowerCase())">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item2.name.toLowerCase())}}</span>
<template v-if="counterdata && counterdata[item2.counterid] && counterdata[item2.counterid] > 0">
<span class="pull-right">
<badge :count="counterdata[item2.counterid]" :overflow-count="9999"></badge>
......@@ -75,7 +75,7 @@
<i :class="[item1.iconcls, 'app-menu-icon']"></i>
</template>
<template slot="title">
<span class="text" :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name)">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name)}} </span>
<span class="text" :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name.toLowerCase())">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item1.name.toLowerCase())}} </span>
<template v-if="counterdata && counterdata[item1.counterid] && counterdata[item1.counterid] > 0">
<span class="pull-right">
<badge :count="counterdata[item1.counterid]" :overflow-count="9999"></badge>
......@@ -101,7 +101,7 @@
<i class='fa fa-cogs app-menu-icon'></i>
</template>
<template slot="title">
<span class="text" :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name)">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name)}}</span>
<span class="text" :title="$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name.toLowerCase())">{{$t('app.menus.${ctrl.getCodeName()?lower_case}.' + item0.name.toLowerCase())}}</span>
<template v-if="counterdata && counterdata[item0.counterid] && counterdata[item0.counterid] > 0">
<span class="pull-right">
<badge :count="counterdata[item0.counterid]" :overflow-count="9999"></badge>
......
......@@ -9,7 +9,7 @@
<img :src="item.iconcls" v-else-if="!Object.is(item.iconcls, '')"/>
<i class='fa fa-cogs' v-else></i>
</span>
<span>{{$t('app.menus.${ctrl.codeName?lower_case}.' + item.name)}}</span>
<span>{{$t('app.menus.${ctrl.codeName?lower_case}.' + item.name.toLowerCase())}}</span>
<span class="line"></span>
</p>
<p style=" display: 'flex' ">
......
......@@ -76,7 +76,6 @@ ${ctrl.render.code}
:header="header"
:plugins="calendarPlugins"
:events="searchEvents"
:displayEventTime="displayEventTime"
:customButtons="customButtons"
:validRange="validRange"
:defaultDate="defaultDate"
......@@ -197,15 +196,6 @@ FullCalendar,
*/
public selectedEventElement:any;
/**
* 是否显示事件时也显示时间
*
* @public
* @type {boolean}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public displayEventTime: boolean = <#if ctrl.getCtrlParamNames?? && ctrl.getCtrlParamNames()??><#list ctrl.getCtrlParamNames() as ctrlparam><#if ctrlparam == 'NODISPLAYTIME'>false<#else>true</#if></#list><#else>true</#if>;
/**
* 引用插件集合
*
......
......@@ -80,6 +80,48 @@ ${P.getCtrlCode('searchform', 'MODEL_CONTENT.ts').code}
name:'end',
prop:'${calendarItem.getEndTimePSDEField().getCodeName()?lower_case}'
},
<#if calendarItem.getIconPSDEField?? && calendarItem.getIconPSDEField()??>
{
name:'srficon',
prop:'${calendarItem.getIconPSDEField().getCodeName()?lower_case}'
},
</#if>
<#if calendarItem.getContentPSDEField?? && calendarItem.getContentPSDEField()??>
{
name:'srfdescription',
prop:'${calendarItem.getContentPSDEField().getCodeName()?lower_case}'
},
</#if>
<#if calendarItem.getIdPSDEField?? && calendarItem.getIdPSDEField()??>
{
name:'srfkey',
prop:'${calendarItem.getIdPSDEField().getCodeName()?lower_case}'
},
</#if>
<#if calendarItem.getTextPSDEField?? && calendarItem.getTextPSDEField()??>
{
name:'srftext',
prop:'${calendarItem.getTextPSDEField().getCodeName()?lower_case}'
},
</#if>
<#if calendarItem.getTipsPSDEField?? && calendarItem.getTipsPSDEField()??>
{
name:'srftips',
prop:'${calendarItem.getTipsPSDEField().getCodeName()?lower_case}'
},
</#if>
<#if calendarItem.getColorPSDEField?? && calendarItem.getColorPSDEField()??>
{
name:'srfcolor',
prop:'${calendarItem.getColorPSDEField().getCodeName()?lower_case}'
},
</#if>
<#if calendarItem.getBKColorPSDEField?? && calendarItem.getBKColorPSDEField()??>
{
name:'srfbkcolor',
prop:'${calendarItem.getBKColorPSDEField().getCodeName()?lower_case}'
},
</#if>
];
break;
</#if>
......
......@@ -105,11 +105,11 @@ import ${srfclassname('${_appde.getCodeName()}')}Service from '@/service/${srffi
_data.push(..._response.data);
});
// 排序
_data.sort((a:any, b:any)=>{
let dateA = new Date(Date.parse(a.start?.replace(/-/g, "/")));
let dateB = new Date(Date.parse(b.start?.replace(/-/g, "/")));
return dateA > dateB ? 1 : -1 ;
});
// _data.sort((a:any, b:any)=>{
// let dateA = new Date(Date.parse(a.start.replace(/-/g, "/")));
// let dateB = new Date(Date.parse(b.start.replace(/-/g, "/")));
// return dateA > dateB ? 1 : -1 ;
// });
let result = {status: 200, data: _data};
resolve(result);
}).catch((response: any) => {
......
......@@ -598,7 +598,7 @@ import UIService from '@/uiservice/ui-service';
public refresh_node(curContext:any,arg: any = {}, parentnode: boolean): void {
const { srfnodeid: id } = arg;
Object.assign(arg,{viewparams:this.viewparams});
const get: Promise<any> = this.service.getNodes(JSON.parse(JSON.stringify(curContext)),arg);
const get: Promise<any> = this.service.getNodes(JSON.parse(JSON.stringify(this.context)),arg);
get.then((response: any) => {
if (!response || response.status !== 200) {
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: response.info });
......
......@@ -224,8 +224,8 @@ import ${srfclassname('${node.getPSAppDataEntity().codeName}')}Service from '@se
Object.assign(treeNode, { isUseLangRes: true });
<#if node.isEnableQuickSearch()>
if(filter.srfnodefilter && !Object.is(filter.srfnodefilter,"")){
if((i18n.t(treeNode.text) as string).toUpperCase().indexOf(filter.srfnodefilter.toUpperCase())==-1)
return resolve(list);
if((i18n.t(treeNode.text) as string).toUpperCase().indexOf(filter.getSrfnodefilter().toUpperCase())==-1)
return Promise.reject();
}
</#if>
Object.assign(treeNode,{srfappctx:context});
......@@ -383,7 +383,7 @@ import ${srfclassname('${node.getPSAppDataEntity().codeName}')}Service from '@se
</#if>
<#if node.isEnableQuickSearch()>
if(filter.srfnodefilter && !Object.is(filter.srfnodefilter,"")){
if((i18n.t(treeNode.text) as string).toUpperCase().indexOf(filter.srfnodefilter.toUpperCase())==-1)
if((i18n.t(treeNode.text) as string).toUpperCase().indexOf(filter.getSrfnodefilter().toUpperCase())==-1)
return;
}
</#if>
......
......@@ -5,7 +5,7 @@
<#if ctrl.render??>
${ctrl.render.code}
<#else>
<div class="<#if ctrl.getGroupLayout?? && ctrl.getGroupLayout() == 'COLUMN'>app-data-view-group-column<#else>app-data-view-group-row</#if><#if ctrl.getPSSysCss?? && ctrl.getPSSysCss()??><#assign singleCss = ctrl.getPSSysCss()> ${singleCss.getCssName()}</#if>">
<div class="app-data-view-group<#if ctrl.getPSSysCss?? && ctrl.getPSSysCss()??><#assign singleCss = ctrl.getPSSysCss()> ${singleCss.getCssName()}</#if>">
<template v-for="(group, index) of groups">
<#if ctrl.groupRender??>
${ctrl.groupRender.code}
......@@ -20,7 +20,7 @@ ${ctrl.render.code}
</div>
</div>
</draggable>
<div v-show="group.folding" :key="group + index" class="dataview-group-content" style="<#if ctrl.getGroupWidth() gt 0>width: ${ctrl.getGroupWidth()?c}px;<#elseif ctrl.getGroupHeight() gt 0>height: ${ctrl.getGroupHeight()?c}px;<#else>flex-grow: 1;</#if>">
<div v-show="group.folding" :key="group + index" class="dataview-group-content dataview-group-kanban" style="<#if ctrl.getGroupWidth() gt 0>width: ${ctrl.getGroupWidth()?c}px;<#else>flex-grow: 1;</#if>">
<div class="dataview-group-header<#if ctrl.getGroupPSSysCss()??> ${ctrl.getGroupPSSysCss().getCssName()}</#if>">
<div class="fold-icon" @click="onClick(group,index)">
<i class="el-icon-s-fold" :title="$t('app.kanban.fold')"></i>
......@@ -29,8 +29,8 @@ ${ctrl.render.code}
{{ getGroupText(group.value) }}
</span>
<#if ctrl.getGroupPSUIActionGroup()??>
<Poptip trigger="hover" content="content" placement="<#if ctrl.getGroupLayout?? && ctrl.getGroupLayout() == 'COLUMN'>right-start<#else>bottom-end</#if>" style="float: right;">
<Icon type="<#if ctrl.getGroupLayout?? && ctrl.getGroupLayout() == 'COLUMN'>ios-more<#else>md-more</#if>" />
<Poptip trigger="hover" content="content" placement="bottom-end" style="float: right;">
<Icon type="md-more" />
<div slot="content" class="group-action">
<#if ctrl.getGroupPSUIActionGroup().getPSUIActions()??>
<#list ctrl.getGroupPSUIActionGroup().getPSUIActions() as action>
......@@ -52,18 +52,20 @@ ${ctrl.render.code}
</Poptip>
</#if>
</div>
<draggable v-if="group.items.length > 0" :list="group.items" group="${ctrl.name}" class="dataview-group-items" @change="onDragChange($event, group.value)">
<div v-for="(item, i) in group.items" :key="i" :class="{'dataview-group-item': true, 'is-select': item.isselected}" @click="handleClick(item)" @dblclick="handleDblClick(item)">
<#if ctrl.getItemPSLayoutPanel()??>
<#assign panel = ctrl.getItemPSLayoutPanel()>
<layout_${panel.getName()} name='${panel.name}' :inputData="item" @panelDataChange="($event)=>{onPanelDataChange(item,$event)}"></layout_${panel.getName()}>
<#elseif ctrl.itemRender??>
${ctrl.itemRender.code}
<#else>
{{ item.srfmajortext }}
</#if>
</div>
</draggable>
<div v-if="items.length > 0">
<draggable :list="group.items" group="${ctrl.name}" class="dataview-group-items" @change="onDragChange($event, group.value)">
<div v-for="(item, i) in group.items" :key="i" :class="{'dataview-group-item': true, 'is-select': item.isselected}" @click="handleClick(item)" @dblclick="handleDblClick(item)">
<#if ctrl.getItemPSLayoutPanel()??>
<#assign panel = ctrl.getItemPSLayoutPanel()>
<layout_${panel.getName()} name='${panel.name}' :inputData="item" @panelDataChange="($event)=>{onPanelDataChange(item,$event)}"></layout_${panel.getName()}>
<#elseif ctrl.itemRender??>
${ctrl.itemRender.code}
<#else>
{{ item.srfmajortext }}
</#if>
</div>
</draggable>
</div>
<div v-else class="app-data-empty">
<span>{{ $t('<#if langbase??>${langbase}.nodata</#if>') }}</span>
</div>
......@@ -467,8 +469,8 @@ draggable,
const post: Promise<any> = this.service.search(this.fetchAction,JSON.parse(JSON.stringify(this.context)), arg, this.showBusyIndicator);
post.then((response: any) => {
if (!response || response.status !== 200) {
if (response.data && response.data.message) {
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: response.data.message });
if (response.errorMessage) {
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: response.errorMessage });
}
return;
}
......@@ -498,7 +500,7 @@ draggable,
if (response && response.status === 401) {
return;
}
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: response.data && response.data.message ? response.data.message : "" });
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: response.errorMessage });
});
}
......
<#if ctrl.getGroupLayout?? && ctrl.getGroupLayout() == "COLUMN">
//从上往下
.app-data-view-group-column{
width: 100%;
height: 100%;
display: flex;
overflow: auto;
flex-direction: column;
.dataview-group-folading-kanban{
border: 1px solid #ddd;
text-align: center;
border-left: 0;
width: 100%;
height: 40px;
background-color: #d8d8d8;
color: #a5a5a5;
.unfold-icon {
padding: 6px 0px 0px 6px;
float: left;
font-size: 20px;
}
.dataview-group-folding{
font-size: 17px;
padding-top: 8px;
}
}
.dataview-group-content {
border: 1px solid #ddd;
flex-shrink: 0;
width: 100%;
display: flex;
.dataview-group-header {
width: 36px;
position: relative;
border-right: 1px solid #ddd;
padding: 8px 0px;
.fold-icon{
font-size: 20px;
padding: 0px 6px;
color:#a5a5a5;
position: absolute;
}
.fold-text {
writing-mode: tb;
padding: 30px 6px 0px 6px;
}
.ivu-poptip{
position: absolute;
bottom: 0px;
left: 0px;
.ivu-poptip-rel{
padding-left: 8px;
}
}
.group-action {
.group-action-item:nth-child(1) + .group-action-item {
margin-top: 5px;
}
}
}
.dataview-group-items {
display: flex;
flex-grow: 1;
height: 100%;
overflow: auto;
.dataview-group-item {
margin: 8px 0px 8px 8px;
border: 1px solid #ddd;
padding: 8px;
overflow: hidden;
}
.dataview-group-item.is-select {
border-color: #108cee;
}
}
.app-data-empty{
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
}
}
.dataview-group-content:nth-child(1) {
border-left: 1px solid #ddd;
}
.quick-action {
flex-shrink: 0;
display: flex;
.quick-action-item {
width: 37px;
height: 37px;
text-align: center;
line-height: 37px;
border: 1px solid #ddd;
border-top-width: 0;
}
.quick-action-item:nth-child(1) {
border-top-width: 1px;
}
}
.dragitems {
z-index: -1 !important;
margin: 0px !important;
border: none !important;
padding: 0px !important;
height: 0px !important;
width: 10px !important;
color: #fff;
overflow: hidden;
.app-layoutpanel {
.app-layoutpanel-container {
padding: 0px !important;
}
}
}
}
<#else>
//从左往右(默认)
.app-data-view-group-row {
.app-data-view-group {
height: 100%;
display: flex;
overflow: auto;
......@@ -224,7 +103,6 @@
}
}
}
</#if>
<#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl
</#ibizinclude>
\ No newline at end of file
......@@ -349,7 +349,7 @@ import { Environment } from '@/environments/environment';
<#if valueRule.getRuleType() == "REG">
{ <#if valueRule.getRegExCode?? && valueRule.getRegExCode()??>pattern: /${valueRule.getRegExCode()}/</#if><#if valueRule.getRuleInfo?? && valueRule.getRuleInfo()??>, message: '${valueRule.getRuleInfo()}'</#if>, trigger: 'change' },
<#elseif valueRule.getRuleType() == "SCRIPT">
{ <#if valueRule.getScriptCode?? && valueRule.getScriptCode()??>validator: (rule:any, value:any, callback:any) => { if (value === '' || value === null || value === undefined) { rule.message = '${formdetail.getCaption()} 值不能为空'; return false; } ${valueRule.getScriptCode()} }</#if><#if valueRule.getRuleInfo?? && valueRule.getRuleInfo()??>, message: '${valueRule.getRuleInfo()}'</#if>, trigger: 'change' },
{ <#if valueRule.getScriptCode?? && valueRule.getScriptCode()??>validator: (rule:any, value:any, callback:any) => { ${valueRule.getScriptCode()} }</#if><#if valueRule.getRuleInfo?? && valueRule.getRuleInfo()??>, message: '${valueRule.getRuleInfo()}'</#if>, trigger: 'change' },
</#if>
</#if>
</#if>
......@@ -1101,6 +1101,7 @@ import { Environment } from '@/environments/environment';
if(this.appStateEvent){
this.appStateEvent.unsubscribe();
}
this.formState.complete();
<#if destroyed_block??>
${destroyed_block}
</#if>
......
......@@ -86,7 +86,7 @@
<#if !uiactionDetail.isShowCaption()>
<tooltip :transfer="true" :max-width="600">
</#if>
<a v-show="scope.row.${uiaction.getUIActionTag()}.visabled" <#if !preUIAction??>:class="{'grid-first-uiaction':scope.row.${uiaction.getUIActionTag()}.visabled && scope.row.${uiaction.getUIActionTag()}.visabled}"</#if> <#if preUIAction??>:class="{'grid-uiaction-divider': ${uiactionDetail.isAddSeparator()?c} && scope.row.${preUIAction.getUIActionTag()}.visabled && scope.row.${uiaction.getUIActionTag()}.visabled}"</#if> :style="{'pointer-events':scope.row.${uiaction.getUIActionTag()}.disabled?'none':'auto','color':scope.row.${uiaction.getUIActionTag()}.disabled?'#7b7979':'#2d8cf0'}" @click="uiAction(scope.row, '${uiaction.getUIActionTag()}', $event)">
<a v-show="scope.row.${uiaction.getUIActionTag()}.visabled" <#if !preUIAction??>:class="{'grid-first-uiaction':scope.row.${uiaction.getUIActionTag()}.visabled && scope.row.${uiaction.getUIActionTag()}.visabled}"</#if> <#if preUIAction??>:class="{'grid-uiaction-divider':scope.row.${preUIAction.getUIActionTag()}.visabled && scope.row.${uiaction.getUIActionTag()}.visabled}"</#if> :style="{'pointer-events':scope.row.${uiaction.getUIActionTag()}.disabled?'none':'auto','color':scope.row.${uiaction.getUIActionTag()}.disabled?'#7b7979':'#2d8cf0'}" @click="uiAction(scope.row, '${uiaction.getUIActionTag()}', $event)">
<#-- 取消分割线标签,使用样式替代分割线 end -->
<#if uiactionDetail.isShowIcon()><i class='<#if uiaction.getIconCls?? && uiaction.getIconCls()??>${uiaction.getIconCls()}</#if>'></i></#if>
<#if uiactionDetail.isShowCaption()>{{<#if langbase??>$t('${langbase}.uiactions.${uiaction.getFullCodeName()?lower_case}')<#else>'${uiaction.getCaption()}'</#if>}}</#if>
......@@ -220,7 +220,7 @@
</#if>
<#if item.getValueFormat()?? && item.getValueFormat() != "%1$s">
<app-format-data format="${item.getValueFormat()}" :data="row.${item.getName()?lower_case}"></app-format-data>
<#elseif item.getPSDEField?? && item.getPSDEField()?? && (item.getPSDEField().getDataType() == "DECIMAL" || item.getPSDEField().getDataType() == "FLOAT" || item.getPSDEField().getDataType() == "CURRENCY" || item.getPSDEField().getDataType() == "BIGDECIMAL")>
<#elseif item.getPSDEField?? && item.getPSDEField()?? && (item.getPSDEField().getDataType() == "DECIMAL" || item.getPSDEField().getDataType() == "FLOAT" || item.getPSDEField().getDataType() == "CURRENCY")>
<app-format-data dataType="${item.getPSDEField().getDataType()}" precision="${item.getPSDEField().getPrecision()}" :data="row.${item.getName()?lower_case}"></app-format-data>
<#else>
<span>{{row.${item.getName()?lower_case}}}</span>
......
......@@ -7,7 +7,7 @@ ${ctrl.render.code}
<#else>
<div class='grid<#if ctrl.getPSSysCss?? && ctrl.getPSSysCss()??><#assign singleCss = ctrl.getPSSysCss()> ${singleCss.getCssName()}</#if>' style="height:100%">
<i-form style="height:100%;display:flex;flex-direction: column;justify-content: space-between">
<input style="display:none;" />
<input style="display:none;" />
<el-table v-if="isDisplay === true"
<#-- BEGIN:是否支持排序 -->
<#if !ctrl.isNoSort()>
......@@ -93,6 +93,8 @@ ${ctrl.render.code}
</template>
</div>
</poptip>
<i-button class="config-button" @click="saveDynaConfig">{{$t('app.gridpage.saveconfig')}}</i-button>
<i-button class="config-button" @click="resetDynaConfig">{{$t('app.gridpage.resetconfig')}}</i-button>
</span>
<#if ctrl.getBatchPSDEToolbar?? && ctrl.getBatchPSDEToolbar()??>
<span v-if="selections.length > 0" class="batch-toolbar">
......@@ -587,6 +589,14 @@ ${gridColumn.getName()}
</#if>
]
/**
* 重置表格列模型缓存
*
* @type {any[]}
* @memberof MainBase
*/
public resetColModel: any[] = [];
/**
* 表格模型集合
*
......@@ -2135,16 +2145,43 @@ ${gridColumn.getName()}
* @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public setColState() {
const _data: any = localStorage.getItem('${ctrl.getPSAppDataEntity().getName()?lower_case}_${ctrl.getCodeName()?lower_case}_${ctrl.name}');
if (_data) {
let columns = JSON.parse(_data);
columns.forEach((col: any) => {
let column = this.allColumns.find((item) => Object.is(col.name, item.name));
if (column) {
Object.assign(column, col);
}
});
}
this.resetColModel = Util.deepCopy(this.allColumns);
const viewParams: any = Util.deepCopy(this.viewparams);
Object.assign(viewParams,{utilServiceName: 'grid_dynaconfig', modelid: '${sys.getCodeName()?lower_case}_${app.getCodeName()?lower_case}_${view.getCodeName()?lower_case}_grid_${ctrl.getCodeName()?lower_case}'});
const post = this.service.loadModel('grid_dynaconfig', this.context, viewParams);
post.then((response: any) => {
if(response.status == 200 && response.data) {
const columns = response.data;
columns.forEach((col: any) => {
let column = this.allColumns.find((item) => Object.is(col.name, item.name));
if (column) {
Object.assign(column, col);
}
});
} else {
this.getColStorage();
}
}).catch(() => {
this.getColStorage();
});
}
/**
* 获取列缓存
*
* @memberof MainBase
*/
public getColStorage() {
const _data: any = localStorage.getItem('${ctrl.getPSAppDataEntity().getName()?lower_case}_${ctrl.getCodeName()?lower_case}_${ctrl.name}');
if (_data) {
let columns = JSON.parse(_data);
columns.forEach((col: any) => {
let column = this.allColumns.find((item) => Object.is(col.name, item.name));
if (column) {
Object.assign(column, col);
}
});
}
}
/**
......@@ -2170,6 +2207,36 @@ ${gridColumn.getName()}
return column.show ? true : false;
}
/**
* 保存动态表格配置
*
* @memberof MainBase
*/
public saveDynaConfig() {
const viewParams: any = Util.deepCopy(this.viewparams);
Object.assign(viewParams,{utilServiceName: 'grid_dynaconfig', modelid: '${sys.getCodeName()?lower_case}_${app.getCodeName()?lower_case}_${view.getCodeName()?lower_case}_grid_${ctrl.getCodeName()?lower_case}', model: this.allColumns});
const post = this.service.saveModel('grid_dynaconfig', this.context, viewParams);
post.then((response: any) => {
if (response.status == 200) {
this.$Message.success(this.$t('app.gridpage.message.saveconfigsuccess'));
} else {
this.$Message.error(this.$t('app.gridpage.message.saveconfigerror'));
}
}).catch(() => {
this.$Message.error(this.$t('app.gridpage.message.saveconfigerror'));
});
}
/**
* 重置动态表格配置
*
* @memberof MainBase
*/
public resetDynaConfig() {
this.allColumns = Util.deepCopy(this.resetColModel);
localStorage.setItem('dynaconfig_main_grid', JSON.stringify(this.allColumns));
}
/**
* 表格列是否自适应布局
*
......
......@@ -92,6 +92,9 @@
.page-column {
position: absolute;
left: 0;
.config-button {
margin-left: 8px;
}
}
.batch-toolbar{
position: absolute;
......
......@@ -20,6 +20,50 @@ import ${srfclassname('${aggAppDataEntity.getCodeName()}')}Service from '@/servi
../@MACRO/SERVICE/SERVICE_HEADER.ts.ftl
</#ibizinclude>
/**
* 加载数据模型
*
* @param {string} serviceName
* @param {*} context
* @param {*} viewparams
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
public loadModel(serviceName: string, context: any, viewparams: any) {
return new Promise((resolve: any, reject: any) => {
this.utilService.getService(serviceName).then((service: any) => {
service.loadModelData(JSON.stringify(context), viewparams).then((response: any) => {
resolve(response);
}).catch((response: any) => {
reject(response);
});
}).catch((response: any) => {
reject(response);
});
});
}
/**
* 保存数据模型
*
* @param {string} serviceName
* @param {*} context
* @param {*} viewparams
* @memberof ${srfclassname('${ctrl.codeName}')}Service
*/
public saveModel(serviceName: string, context: any, viewparams: any) {
return new Promise((resolve: any, reject: any) => {
this.utilService.getService(serviceName).then((service: any) => {
service.saveModelData(JSON.stringify(context),'', viewparams).then((response: any) => {
resolve(response);
}).catch((response: any) => {
reject(response);
});
}).catch((response: any) => {
reject(response);
});
});
}
/**
* 备份原生数据
*
......
因为 它太大了无法显示 源差异 。您可以改为 查看blob
<#ibizinclude>
../@MACRO/HTML/GRID.html.ftl
</#ibizinclude>
\ No newline at end of file
.grid {
flex-grow: 1;
height: 100%;
overflow: auto;
.el-table__body-wrapper::-webkit-scrollbar {
/*滚动条整体样式*/
width : 10px !important; /*高宽分别对应横竖滚动条的尺寸*/
height: 10px !important;
}
.el-table__body-wrapper::-webkit-scrollbar-thumb {
/*滚动条颜色*/
border-radius : 10px !important;
background-color: #cecece !important;
}
.el-table__body-wrapper::-webkit-scrollbar-track {
/*滚动条里面轨道*/
box-shadow : inset 0 0 5px rgba(0, 0, 0, 0.2) !important;
background : #ededed !important;
border-radius: 10px !important;
}
/*表格文字过长省略*/
.el-table th>.cell, .el-table td>.cell{
white-space: nowrap;
text-overflow: ellipsis;
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;
}
.el-table {
height: 100%;
display:flex;
flex-direction: column;
justify-content: flex-start;
.el-table__row{
.grid-uiaction-divider {
padding:0 10px 0 10px;
border-left: 1px #b3b3b3 solid;
}
.grid-first-uiaction {
padding:0 10px 0 10px;
}
}
.quick-toolbar{
display: inline-block;
button{
background: #ebf3fb;
color: #2575ca;
border: 0;
}
}
.el-tooltip{
.ivu-form-item{
margin-bottom: unset !important;
}
}
.el-table__body .edit-cell{
padding:0;
.app-form-item{
margin-top: 20px;
margin-bottom: 20px;
}
}
.el-table__header-wrapper{
min-height: 45px;
max-height: 100px;
height: auto;
}
.el-table__footer-wrapper{
min-height: 45px;
max-height: 100px;
height: auto;
}
}
.grid-pagination {
height: 50px;
padding: 6px 0px;
.page-button {
button {
padding: 0;
font-size: 16px;
min-width: 32px;
height: 32px;
margin-right: 4px;
}
}
.page-column {
position: absolute;
left: 0;
}
.batch-toolbar{
position: absolute;
left: 105px;
>.toolbar-container{
button {
font-size: 16px;
min-width: 32px;
height: 32px;
margin-right: 4px;
margin-top: 0;
margin-bottom: 0;
}
}
}
}
}
.ivu-modal-content{
.footer{
.ivu-row{
text-align: right;
}
}
}
.cell-indeterminate {
>div>label {
>span {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:before {
content: "";
position: absolute;
display: block;
background-color: #fff;
height: 2px;
transform: scale(.5);
left: 0;
right: 0;
top: 5px;
}
}
>span.is-checked {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:after {
border: 0px;
}
}
}
}
.cell-select-all {
>div>label {
>span {
.el-checkbox__inner {
background-color: #409eff;
border-color: #409eff;
}
.el-checkbox__inner:after {
box-sizing: content-box;
content: "";
border: 1px solid #fff;
border-left: 0;
border-top: 0;
height: 7px;
left: 4px;
position: absolute;
top: 1px;
transform: rotate(45deg) scaleY(1);
width: 3px;
transition: transform .15s ease-in .05s;
transform-origin: center;
}
}
}
}
<#ibizinclude>
../@MACRO/CSS/DEFAULT.less.ftl
</#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/CONTROL/CONTROL.vue.ftl
</#ibizinclude>
\ No newline at end of file
<#ibizinclude>
../@MACRO/MODEL/MODEL_HEADER.ts.ftl
</#ibizinclude>
/**
* 是否是实体数据导出
*
* @returns {any[]}
* @memberof ${srfclassname('${ctrl.getCodeName()}')}${srfclassname('${ctrl.name}')}Mode
*/
public isDEExport: boolean = false;
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof ${srfclassname('${ctrl.getCodeName()}')}${srfclassname('${ctrl.name}')}Mode
*/
public getDataItems(): any[] {
if(this.isDEExport){
return [
<#-- 实体导出数据项 -->
<#if ctrl.getPSDEDataExport?? && ctrl.getPSDEDataExport()?? && ctrl.getPSDEDataExport().getPSDEDataExportItems()??>
<#list ctrl.getPSDEDataExport().getPSDEDataExportItems() as dataitem>
{
name: '${dataitem.getName()}',
<#if dataitem.getPSDEField()??>
prop: '${dataitem.getPSDEField().getCodeName()?lower_case}',
dataType: '${dataitem.getPSDEField().getDataType()}',
</#if>
<#if ctrl.getPSDEGridEditItems()??>
<#list ctrl.getPSDEGridEditItems() as editItem>
<#if editItem.getName() == dataitem.getName()>
<#if editItem.isEditable()>
isEditable:${editItem.isEditable()?c}
</#if>
</#if>
</#list>
</#if>
},
</#list>
</#if>
]
}else{
return [
<#-- 表格数据项 -->
<#if ctrl.getPSDEGridDataItems()??>
<#list ctrl.getPSDEGridDataItems() as dataitem>
{
name: '${dataitem.getName()}',
<#if dataitem.getPSDEField()??>
prop: '${dataitem.getPSDEField().getCodeName()?lower_case}',
dataType: '${dataitem.getPSDEField().getDataType()}',
</#if>
<#if ctrl.getPSDEGridEditItems()??>
<#list ctrl.getPSDEGridEditItems() as editItem>
<#if editItem.getName() == dataitem.getName()>
<#if editItem.isEditable()>
isEditable:${editItem.isEditable()?c}
</#if>
</#if>
</#list>
</#if>
},
</#list>
</#if>
<#-- 关联主实体的主键 -->
<#if ctrl.getPSAppDataEntity()??>
<#assign appDataEntity = ctrl.getPSAppDataEntity() />
<#if appDataEntity.isMajor() == false && appDataEntity.getMinorPSAppDERSs()??>
<#list appDataEntity.getMinorPSAppDERSs() as minorAppDERSs>
<#if minorAppDERSs.getMajorPSAppDataEntity()??>
<#assign majorAppDataEntity = minorAppDERSs.getMajorPSAppDataEntity() />
{
name: '${majorAppDataEntity.getCodeName()?lower_case}',
prop: '<#if majorAppDataEntity.getPSDER1N?? && majorAppDataEntity.getPSDER1N()??>${majorAppDataEntity.getPSDER1N().getPSPickupDEField().getCodeName()?lower_case}<#else>${majorAppDataEntity.getKeyPSAppDEField().getCodeName()?lower_case}</#if>',
dataType: 'FONTKEY',
},
</#if>
</#list>
</#if>
</#if>
<#if ctrl.getPSDEGridDataItems()??>
<#list ctrl.getPSDEGridDataItems() as dataitem>
<#-- 界面主键标识 -->
<#if dataitem.getPSDEField?? && dataitem.getPSDEField()??>
<#if !P.exists("importService", dataitem.getPSDEField().getId(), "")>
<#if dataitem.getPSDEField().isKeyDEField() == true>
{
name: '${ctrl.getPSAppDataEntity().getCodeName()?lower_case}',
prop: '${dataitem.getPSDEField().getCodeName()?lower_case}',
},
</#if>
</#if>
</#if>
</#list>
</#if>
<#if view.hasPSControl('searchform')>
${P.getCtrlCode('searchform', 'MODEL_CONTENT.ts').code}
</#if>
{
name:'size',
prop:'size',
dataType: 'QUERYPARAM'
},
{
name:'query',
prop:'query',
dataType: 'QUERYPARAM'
},
{
name:'filter',
prop:'filter',
dataType: 'QUERYPARAM'
},
{
name:'page',
prop:'page',
dataType: 'QUERYPARAM'
},
{
name:'sort',
prop:'sort',
dataType: 'QUERYPARAM'
},
{
name:'srfparentdata',
prop:'srfparentdata',
dataType: 'QUERYPARAM'
},
// 前端新增修改标识,新增为"0",修改为"1"或未设值
{
name: 'srffrontuf',
prop: 'srffrontuf',
dataType: 'TEXT',
},
]
}
}
<#ibizinclude>
../@MACRO/MODEL/MODEL_BOTTOM.ts.ftl
</#ibizinclude>
\ No newline at end of file
此差异已折叠。
CTRLTYPE=GRID#FixedFirst
\ No newline at end of file
......@@ -65,12 +65,5 @@
}
}
}
// 日历视图样式特殊处理(防止刷新时日历大小发生变化并且门户部件要定高)
.decalendarview {
height: 100%;
>.view-card {
height: 100%;
}
}
}
</#if>
<#ibizinclude>../@MACRO/FUNC/PUBLIC.vue.ftl</#ibizinclude>
<cron-editor
<#-- <cron-editor
:disabled="detailsModel.${editor.name}.disabled"
placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if> />
\ No newline at end of file
placeholder=<#if item.getPlaceHolder()??>'${item.getPlaceHolder()}'<#else>'请选择...'</#if> /> -->
\ No newline at end of file
......@@ -11,10 +11,6 @@
name="${editor.name}"
:localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor />
<#if item.getPSAppDEField?? && item.getPSAppDEField()?? && item.getPSAppDEField().getStdDataType()??>
<#assign datatype = srfjavatype(item.getPSAppDEField().getStdDataType())>
valueType="<#if datatype == 'BigInteger' || datatype == 'Integer' || datatype == 'Double' || datatype == 'Decimal' || datatype == 'Float' || datatype == 'BigDecimal'>number<#else>string</#if>"
</#if>
<#if editor.getPSCodeList()??>
<#assign codelist=editor.getPSCodeList()>
tag='${codelist.codeName}'
......
......@@ -13,9 +13,7 @@
:disabled="getColumnDisabled(row,column.property)"
:rowPreview="true"
:imageOnly="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
</#if>
\ No newline at end of file
......@@ -13,7 +13,6 @@
:imageOnly="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
</#if>
\ No newline at end of file
......@@ -13,9 +13,7 @@
:disabled="getColumnDisabled(row,column.property)"
:rowPreview="true"
:imageOnly="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
</#if>
\ No newline at end of file
......@@ -11,9 +11,7 @@
:disabled="detailsModel.${item.getCodeName()}.disabled"
:rowPreview="true"
:imageOnly="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>' :exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
</#if>
\ No newline at end of file
<#if editor?? && editor.render??>
${editor.render.code}
<#else>
<input-box v-model="data.${editor.name}" :textareaId="this.$util.createUUID()" :disabled="detailsModel.${editor.name}.disabled" type='textarea' editorType="${item.getEditorType()}" textareaStyle="${editor.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if>></input-box>
<input-box v-model="data.${editor.name}" :textareaId="this.$util.createUUID()" :disabled="detailsModel.${editor.name}.disabled" type='textarea' textareaStyle="${editor.getEditorCssStyle()}" <#if item.getPlaceHolder()??> placeholder="${item.getPlaceHolder()}"</#if>></input-box>
</#if>
\ No newline at end of file
<app-address-selection :value="data.${editor.name}" <#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if> :disabled="detailsModel.${editor.name}.disabled" style="${editor.getEditorCssStyle()}"></app-address-selection>
\ No newline at end of file
<#-- <app-address-selection :value="data.${editor.name}" <#if item.getPlaceHolder()??>placeholder="${item.getPlaceHolder()}"</#if> :disabled="detailsModel.${editor.name}.disabled" style="${editor.getEditorCssStyle()}"></app-address-selection> -->
\ No newline at end of file
......@@ -12,7 +12,6 @@
:show-drag=<#if item.getEditorParam("showDrag",'') != ''>"${item.getEditorParam("showDrag",'')}"<#else>"false"</#if>
:persistence=<#if item.getEditorParam("persistence",'') != ''>"${item.getEditorParam("persistence",'')}"<#else>"false"</#if>
:show-download=<#if item.getEditorParam("showDownload",'') != ''>"${item.getEditorParam("showDownload",'')}"<#else>"false"</#if>
:disabled="detailsModel.${item.name}.disabled"
:show-delete=<#if item.getEditorParam("showDelete",'') != ''>"${item.getEditorParam("showDelete",'')}"<#else>"false"</#if>
@formitemvaluechange="onFormItemValueChange">
</disk-file-upload>
\ No newline at end of file
......@@ -14,7 +14,6 @@
:rowPreview="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
</#if>
\ No newline at end of file
......@@ -12,7 +12,6 @@
:rowPreview="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
</#if>
\ No newline at end of file
......@@ -13,4 +13,4 @@
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
\ No newline at end of file
</app-file-upload>
......@@ -12,6 +12,5 @@
:rowPreview="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
\ No newline at end of file
......@@ -10,6 +10,5 @@
:rowPreview="true"
:uploadparams='<#if editor.getEditorParam('uploadparams','') != ''>${editor.getEditorParam('uploadparams','')}<#else>{}</#if>'
:exportparams='<#if editor.getEditorParam('exportparams','') != ''>${editor.getEditorParam('exportparams','')}<#else>{}</#if>'
:multiple='<#if editor.getEditorParam('multiple','') != ''>${editor.getEditorParam('multiple','')}<#else>true</#if>'
style="${editor.getEditorCssStyle()}overflow: auto;">
</app-file-upload>
\ No newline at end of file
......@@ -6,10 +6,7 @@
:value="this.data.${editor.name}"
@change="($event)=>{this.data.${editor.name} = $event} "
:disabled="detailsModel.${editor.name}.disabled"
style="${editor.getEditorCssStyle()}"
<#if item.getEditorParam('max','') != ''>
:max="${item.getEditorParam('max','')}"
</#if>
style="${editor.getEditorCssStyle()}">
<#if item.getPSCodeList?? && item.getPSCodeList()??>
<#assign codelist=item.getPSCodeList()>
tag='${codelist.codeName}' <#t>
......@@ -18,6 +15,5 @@
valueSeparator='${codelist.getValueSeparator()}' <#t>
</#if>
</#if>
>
</app-rate>
</#if>
\ No newline at end of file
......@@ -19,6 +19,15 @@
validateStatus = xData.formValidateStatus();
}
if (!validateStatus) {
if(xData.errorMessages && xData.errorMessages.length > 0) {
let descMessage: string = '';
xData.errorMessages.forEach((message: any) => {
descMessage = descMessage + '<p>' + message.error + '<p>';
})
xData.$Notice.error({ title: (xData.$t('app.commonWords.wrong') as string), desc: descMessage });
} else {
xData.$Notice.error({ title: (xData.$t('app.commonWords.wrong') as string), desc: (xData.$t('app.formpage.valuecheckex') as string) });
}
return;
}
const startWorkFlow: Function = (param: any, localdata: any) => {
......@@ -28,7 +37,7 @@
<#if curWorkflow.isUseWFProxyApp()>
xData.wfstart(args).then((response: any) => {
<#else>
xData.wfstart(args,localdata).then((response: any) => {
xData.wfstart(args, localdata).then((response: any) => {
</#if>
<#else>
xData.wfstart(args).then((response: any) => {
......
......@@ -159,13 +159,13 @@
<#-- BEGIN:导航参数 -->
<#if curNewLogicRefView?? && curNewLogicRefView.getPSNavigateContexts?? && curNewLogicRefView.getPSNavigateContexts()??>
if(localContext && Object.keys(localContext).length >0){
let _context:any = this.$util.computedNavData(fullargs[0],this.context,this.viewparams,localContext);
let _context:any = this.$util.computedNavData(fullargs?fullargs[0]:null,this.context,this.viewparams,localContext);
Object.assign(tempContext,_context);
}
</#if>
<#if curNewLogicRefView?? && curNewLogicRefView.getPSNavigateParams?? && curNewLogicRefView.getPSNavigateParams()??>
if(localViewParam && Object.keys(localViewParam).length >0){
let _param:any = this.$util.computedNavData(fullargs[0],this.context,this.viewparams,localViewParam);
let _param:any = this.$util.computedNavData(fullargs?fullargs[0]:null,this.context,this.viewparams,localViewParam);
Object.assign(data,_param);
}
</#if>
......
......@@ -516,6 +516,7 @@ ${P.getLogicCode(uiAction, "LOGIC.vue").code}
if(this.portletStateEvent){
this.portletStateEvent.unsubscribe();
}
this.viewState.complete();
}
</#if>
</#if>
......
......@@ -165,6 +165,9 @@
}
if(linkItem && linkItem.sequenceflowview && <#noparse>this.viewRefData[`WFACTION@${linkItem.sequenceflowview}`]</#noparse>){
let tempContext:any = Util.deepCopy(this.context);
if (datas && datas.length > 0 && datas[0]['<#if view.getPSAppDataEntity()??>${view.getPSAppDataEntity().codeName?lower_case}</#if>']) {
Object.assign(tempContext, { '<#if view.getPSAppDataEntity()??>${view.getPSAppDataEntity().codeName?lower_case}</#if>': datas[0]['<#if view.getPSAppDataEntity()??>${view.getPSAppDataEntity().codeName?lower_case}</#if>'] });
}
let tempViewParam:any = {actionView:linkItem.sequenceflowview,actionForm:linkItem.sequenceflowform};
<#noparse>let targetView:any = this.viewRefData[`WFACTION@${linkItem.sequenceflowview}`];</#noparse>
const appmodal = this.$appmodal.openModal({viewname:targetView.viewname, title:(this.$t(targetView.title) as string), height: targetView.height, width: targetView.width}, tempContext,tempViewParam);
......
......@@ -107,7 +107,7 @@
let datas: any[] = [];
let xData: any = this.$refs.form;
if (xData.getDatas && xData.getDatas instanceof Function) {
datas = [...xData.getDatas()];
datas = [...xData.getDatas()];
}
const submit:Function = (submitData:any,linkItem:any) =>{
xData.wfsubmit(submitData,linkItem).then((response: any) => {
......
......@@ -171,9 +171,7 @@ if(this.viewparams.selectedData){
}
if(model.datas.length>0){
model.datas.forEach((data:any,index:any)=>{
if(Util.isEmpty(data.srfmajortext)){
Object.assign(data,{srfmajortext: data['${view.getPSAppDataEntity().getMajorPSAppDEField().getCodeName()?lower_case}']});
}
Object.assign(data,{srfmajortext: data.hasOwnProperty('srfmajortext') ? data['srfmajortext'] : data['${view.getPSAppDataEntity().getMajorPSAppDEField().getCodeName()?lower_case}']});
})
}
model.datas.forEach((item: any) => {
......
......@@ -43,7 +43,12 @@ export default class ${srfclassname('${item.getCodeName()}')} {
* @type any
* @memberof ${srfclassname('${item.getCodeName()}')}
*/
<#if item.getPredefinedType?? && item.getPredefinedType()??>
// 预定义代码表默认缓存超长时长为 60000 毫秒
public cacheTimeout:any = 60000;
<#else>
public cacheTimeout:any = ${item.getCacheTimeout()?c};
</#if>
/**
* 代码表模型对象
......
......@@ -38,6 +38,8 @@ function getAppLocale(){
nomore:"དེ་ལས་མང་བ་མི་འདུག",
other:"གཞན་དག",
valueNotEmpty:"སྟོང་མི་ཆོག",
createFailed:"གསར་འཛུགས་ཕམ་པ།",
isExist:"གནས་པ་",
},
local:{
new: "གསར་འཛུགས།",
......
......@@ -38,6 +38,8 @@ function getAppLocale(){
nomore:"No more",
other:"other",
valueNotEmpty:"The value cannot be null",
createFailed:"Create Failed",
isExist:"Exist",
},
local:{
new: "New",
......@@ -45,6 +47,8 @@ function getAppLocale(){
},
gridpage: {
choicecolumns: "Choice columns",
saveconfig: "Save the current configuration",
resetconfig: "Restoring default Settings",
refresh: "refresh",
show: "Show",
records: "records",
......@@ -59,6 +63,12 @@ function getAppLocale(){
updateAction: "The view table updateaction parameter is not configured",
loaddraftAction: "The view table loadtrafaction parameter is not configured",
},
message: {
saveconfigsuccess: "Configuration saved successfully!",
saveconfigerror: "Failed to save configuration!",
resetconfigsuccess: "Reset configuration succeeded!",
resetconfigerror: "Reset configuration failed!",
},
data: "Data",
delDataFail: "Failed to delete data",
delSuccess: "Delete successfully!",
......
......@@ -38,6 +38,8 @@ function getAppLocale(){
nomore:"没有更多了",
other:"其他",
valueNotEmpty:"值不能为空",
createFailed:"创建失败",
isExist:"已存在",
},
local:{
new: "新建",
......@@ -45,6 +47,8 @@ function getAppLocale(){
},
gridpage: {
choicecolumns: "选择列",
saveconfig: "保存当前配置",
resetconfig: "恢复默认配置",
refresh: "刷新",
show: "显示",
records: "条",
......@@ -59,6 +63,12 @@ function getAppLocale(){
updateAction: "视图表格updateAction参数未配置",
loaddraftAction: "视图表格loaddraftAction参数未配置",
},
message: {
saveconfigsuccess: "保存配置成功!",
saveconfigerror: "保存配置失败!",
resetconfigsuccess: "重置配置成功!",
resetconfigerror: "重置配置失败!",
},
data: "数据",
delDataFail: "删除数据失败",
delSuccess: "删除成功!",
......
<#ibiztemplate>
TARGET=PSSYSAPP
</#ibiztemplate>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="icon" href="./favicon.ico">
<title><#if app.getName?? && app.getName()??>${app.getName()}</#if></title>
</head>
<body>
<noscript>
<strong>We're sorry but app doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
</noscript>
<div id="app"></div>
<script src="./environments/environment.js"></script>
<script src="./assets/js/avue.min.js"></script>
</body>
</html>
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册