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

Merge branch 'dev'

上级 920cf2d7
...@@ -877,11 +877,7 @@ import schema from 'async-validator'; ...@@ -877,11 +877,7 @@ import schema from 'async-validator';
this.load(data); this.load(data);
} }
if (Object.is('loaddraft', action)) { if (Object.is('loaddraft', action)) {
if(this.context.srfsourcekey){ this.loadDraft(data);
this.copy(this.context.srfsourcekey);
}else{
this.loadDraft(data);
}
} }
if (Object.is('save', action)) { if (Object.is('save', action)) {
this.save(data,data.showResultInfo); this.save(data,data.showResultInfo);
...@@ -947,26 +943,6 @@ import schema from 'async-validator'; ...@@ -947,26 +943,6 @@ import schema from 'async-validator';
</#if> </#if>
} }
/**
* 拷贝内容
*
* @param {*} [arg={}]
* @memberof @memberof ${srfclassname('${ctrl.codeName}')}Base
*/
public copy(srfkey: string): void {
let copyData = this.$store.getters.getCopyData(srfkey);
copyData.srfkey = Util.createUUID();
copyData.${appde.getCodeName()?lower_case} = copyData.srfkey;
copyData.${appde.getKeyPSAppDEField().getCodeName()?lower_case} = copyData.srfkey;
Object.assign(this.context,{${appde.getCodeName()?lower_case}:copyData.${appde.getCodeName()?lower_case}})
this.data = copyData;
this.$nextTick(() => {
this.formState.next({ type: 'load', data: copyData });
this.data.srfuf = '0';
this.setFormEnableCond(this.data);
});
}
/** /**
*打印 *打印
*@memberof @memberof ${srfclassname('${ctrl.codeName}')}Base *@memberof @memberof ${srfclassname('${ctrl.codeName}')}Base
...@@ -1209,6 +1185,9 @@ import schema from 'async-validator'; ...@@ -1209,6 +1185,9 @@ import schema from 'async-validator';
return; return;
} }
} }
if(this.viewparams && this.viewparams.copymode){
data.srfuf = '0';
}
const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction; const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction;
if(!action){ if(!action){
let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction"; let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction";
...@@ -1216,9 +1195,6 @@ import schema from 'async-validator'; ...@@ -1216,9 +1195,6 @@ import schema from 'async-validator';
return; return;
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
if(this.viewparams && this.viewparams.copymode){
data.srfuf = '0';
}
const post: Promise<any> = Object.is(data.srfuf, '1')?this.service.update(action, JSON.parse(JSON.stringify(this.context)),arg, this.showBusyIndicator):this.service.add(action,JSON.parse(JSON.stringify(this.context)),arg, this.showBusyIndicator); const post: Promise<any> = Object.is(data.srfuf, '1')?this.service.update(action, JSON.parse(JSON.stringify(this.context)),arg, this.showBusyIndicator):this.service.add(action,JSON.parse(JSON.stringify(this.context)),arg, this.showBusyIndicator);
post.then((response: any) => { post.then((response: any) => {
if (!response.status || response.status !== 200) { if (!response.status || response.status !== 200) {
......
...@@ -96,8 +96,8 @@ ...@@ -96,8 +96,8 @@
</page> </page>
</row> </row>
</#if> </#if>
</#if>
</i-form> </i-form>
</#if>
</div> </div>
</template> </template>
<#assign import_block> <#assign import_block>
......
...@@ -10,6 +10,10 @@ ...@@ -10,6 +10,10 @@
:localContext =<@getNavigateContext editor /> :localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor /> :localParam =<@getNavigateParams editor />
:disabled="detailsModel.${editor.name}.disabled" :disabled="detailsModel.${editor.name}.disabled"
<#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>
style="${editor.getEditorCssStyle()}width: 100px;" style="${editor.getEditorCssStyle()}width: 100px;"
<#if editor.getPSCodeList()??> <#if editor.getPSCodeList()??>
<#assign codelist=editor.getPSCodeList()> <#assign codelist=editor.getPSCodeList()>
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
:viewparams="viewparams" :viewparams="viewparams"
:localContext =<@getNavigateContext editor /> :localContext =<@getNavigateContext editor />
:localParam =<@getNavigateParams editor /> :localParam =<@getNavigateParams editor />
:disabled="detailsModel.${editor.name}.disabled" :disabled="detailsModel.${editor.name}.disabled"
<#if editor.getPSCodeList()??> <#if editor.getPSCodeList()??>
<#assign codelist=editor.getPSCodeList()> <#assign codelist=editor.getPSCodeList()>
tag='${codelist.codeName}' tag='${codelist.codeName}'
......
...@@ -8,20 +8,20 @@ ...@@ -8,20 +8,20 @@
<#-- 值格式化 start --> <#-- 值格式化 start -->
<#-- @author ljy --> <#-- @author ljy -->
<#-- @update 2020.7.13 18:08 --> <#-- @update 2020.7.13 18:08 -->
<#if item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getDataType()??> <#if item.getPSEditor()?? && item.getPSEditor().getPSEditorContainer()?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField()?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField()?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getDataType()??>
dataType="${item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getDataType()}" <#t> dataType="${item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getDataType()}" <#t>
<#if item.getUnitName()!=""> <#if item.getUnitName()!="">
unitName="${item.getUnitName()}" <#t> unitName="${item.getUnitName()}" <#t>
</#if> </#if>
</#if> </#if>
<#if item.getPSEditor().getPSEditorContainer().getPSDEFUIMode().getPSDEFFormItem().getValueFormat()?? && item.getPSEditor().getPSEditorContainer().getPSDEFUIMode().getPSDEFFormItem().getValueFormat()!= "%1$s"> <#if item.getPSEditor()?? && item.getPSEditor().getPSEditorContainer()?? && item.getPSEditor().getPSEditorContainer().getPSDEFUIMode()?? && item.getPSEditor().getPSEditorContainer().getPSDEFUIMode().getPSDEFFormItem().getValueFormat()?? && item.getPSEditor().getPSEditorContainer().getPSDEFUIMode().getPSDEFFormItem().getValueFormat()!= "%1$s">
valueFormat="${item.getPSEditor().getPSEditorContainer().getPSDEFUIMode().getPSDEFFormItem().getValueFormat()}" <#t> valueFormat="${item.getPSEditor().getPSEditorContainer().getPSDEFUIMode().getPSDEFFormItem().getValueFormat()}" <#t>
</#if> </#if>
<#-- 值格式化 end --> <#-- 值格式化 end -->
<#-- 数值精度 start --> <#-- 数值精度 start -->
<#-- @author mos --> <#-- @author mos -->
<#-- @update 2020.7.16 --> <#-- @update 2020.7.16 -->
<#if item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getPrecision??> <#if item.getPSEditor()?? && item.getPSEditor().getPSEditorContainer()?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField()?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField()?? && item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getPrecision??>
<#if item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getDataType() == 'FLOAT' && item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getPrecision() == 0> <#if item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getDataType() == 'FLOAT' && item.getPSEditor().getPSEditorContainer().getPSAppDEField().getPSDEField().getPrecision() == 0>
:precision="2" :precision="2"
<#else> <#else>
......
...@@ -9,15 +9,15 @@ export const Environment = { ...@@ -9,15 +9,15 @@ export const Environment = {
// 应用 title // 应用 title
AppTitle: '${app.getName()}', AppTitle: '${app.getName()}',
// 应用基础路径 // 应用基础路径
BaseUrl: '../', BaseUrl: '',
// 系统名称 // 系统名称
SysName: '${sys.getCodeName()}', SysName: '${sys.getCodeName()}',
// 远程登录地址,本地开发调试使用 // 远程登录地址,本地开发调试使用
RemoteLogin: 'ibizutil/login', RemoteLogin: '/ibizutil/login',
// 文件导出 // 文件导出
ExportFile: 'ibizutil/download', ExportFile: '/ibizutil/download',
// 文件上传 // 文件上传
UploadFile: 'ibizutil/upload', UploadFile: '/ibizutil/upload',
// 是否为pc端应用 // 是否为pc端应用
isAppMode:true, isAppMode:true,
//统一地址 //统一地址
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册