提交 85f61738 编写于 作者: tony001's avatar tony001

适配表单数据对象方式新建、更新默认值 --- fix2

上级 789179c2
......@@ -1711,8 +1711,8 @@ import { Environment } from '@/environments/environment';
public createDefault(){
<#list ctrl.getAllPSDEFormDetails() as formdetail><#t>
<#if formdetail.getCreateDV?? && formdetail.getCreateDV()??><#t>
<#if !(formdetail.getCreateDV() == '') || formdetail.getCreateDVT() == 'CURTIME'><#t>
if (this.data.hasOwnProperty('${formdetail.getCodeName()?lower_case}')) {
<#if !(formdetail.getCreateDVT() == '')><#t>
<#-- 网页请求 -->
<#if formdetail.getCreateDVT() == 'CONTEXT'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.viewparams['${formdetail.getCreateDV()}'];
......@@ -1734,6 +1734,7 @@ import { Environment } from '@/environments/environment';
<#-- 数据对象属性 -->
<#elseif formdetail.getCreateDVT() == 'PARAM'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.service?.getRemoteCopyData()?.${formdetail.getCreateDV()};
</#if>
<#else>
<#-- 默认值 -->
<#assign datatype=srfjavatype(formdetail.getStdDataType())>
......@@ -1741,7 +1742,6 @@ import { Environment } from '@/environments/environment';
</#if>
}
</#if>
</#if>
</#list>
}
......@@ -1752,8 +1752,8 @@ import { Environment } from '@/environments/environment';
public updateDefault(){
<#list ctrl.getAllPSDEFormDetails() as formdetail><#t>
<#if formdetail.getUpdateDV?? && formdetail.getUpdateDV()??><#t>
<#if !(formdetail.getUpdateDVT() == '')><#t>
if (this.data.hasOwnProperty('${formdetail.getCodeName()?lower_case}') && !this.data.${formdetail.getCodeName()?lower_case}) {
<#if !(formdetail.getUpdateDVT() == '')><#t>
<#-- 网页请求 -->
<#if formdetail.getUpdateDVT() == 'CONTEXT'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.viewparams['${formdetail.getUpdateDV()}'];
......@@ -1772,6 +1772,7 @@ import { Environment } from '@/environments/environment';
<#-- 数据对象属性 -->
<#elseif formdetail.getUpdateDVT() == 'PARAM'>
this.data['${formdetail.getCodeName()?lower_case}'] = this.service?.getRemoteCopyData()?.${formdetail.getUpdateDV()};
</#if>
<#else>
<#-- 默认值 -->
<#assign datatype=srfjavatype(formdetail.getStdDataType())>
......@@ -1779,7 +1780,6 @@ import { Environment } from '@/environments/environment';
</#if>
}
</#if>
</#if>
</#list>
}
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册