提交 e7844396 编写于 作者: WodahsOrez's avatar WodahsOrez

lxm--执行之前,执行之后逻辑附加--fix2

上级 da89d21c
...@@ -161,9 +161,9 @@ import ${srfclassname('${singleLogic.getCodeName()}')}Logic from '@/service/${sr ...@@ -161,9 +161,9 @@ import ${srfclassname('${singleLogic.getCodeName()}')}Logic from '@/service/${sr
<#if singleAppMethod.getMethodType() == "SELECT"> <#if singleAppMethod.getMethodType() == "SELECT">
<#-- if(context.${item.getCodeName()?lower_case}){ --> <#-- if(context.${item.getCodeName()?lower_case}){ -->
<#if singleServiceApi.getRequestMethod() == 'PUT' || singleServiceApi.getRequestMethod() == 'POST'> <#if singleServiceApi.getRequestMethod() == 'PUT' || singleServiceApi.getRequestMethod() == 'POST'>
let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,data,isloading); let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,data,isloading);
<#else> <#else>
let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,isloading); let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,isloading);
</#if> </#if>
<#-- } --> <#-- } -->
<#-- 方法类型为FETCH --> <#-- 方法类型为FETCH -->
...@@ -186,17 +186,17 @@ import ${srfclassname('${singleLogic.getCodeName()}')}Logic from '@/service/${sr ...@@ -186,17 +186,17 @@ import ${srfclassname('${singleLogic.getCodeName()}')}Logic from '@/service/${sr
<#-- GET --> <#-- GET -->
<#if singleServiceApi.getRequestMethod() == "GET"> <#if singleServiceApi.getRequestMethod() == "GET">
<#-- if(context.${item.getCodeName()?lower_case}){ --> <#-- if(context.${item.getCodeName()?lower_case}){ -->
let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,isloading); let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,isloading);
<@setStore appEntity=item /> <@setStore appEntity=item />
<#-- } --> <#-- } -->
<#elseif singleServiceApi.getRequestMethod() == "POST"> <#elseif singleServiceApi.getRequestMethod() == "POST">
<#-- REMOVE --> <#-- REMOVE -->
<#-- if(context.${item.getCodeName()?lower_case}){ --> <#-- if(context.${item.getCodeName()?lower_case}){ -->
let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,data,isloading); let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,data,isloading);
<#-- } --> <#-- } -->
<#else> <#else>
<#-- if(context.${item.getCodeName()?lower_case}){ --> <#-- if(context.${item.getCodeName()?lower_case}){ -->
let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,isloading); let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,isloading);
<#-- } --> <#-- } -->
</#if> </#if>
<#-- 指定属性情况end --> <#-- 指定属性情况end -->
...@@ -241,7 +241,7 @@ import ${srfclassname('${singleLogic.getCodeName()}')}Logic from '@/service/${sr ...@@ -241,7 +241,7 @@ import ${srfclassname('${singleLogic.getCodeName()}')}Logic from '@/service/${sr
</#if> </#if>
<#else> <#else>
<#-- if(context.${item.getCodeName()?lower_case}){ --> <#-- if(context.${item.getCodeName()?lower_case}){ -->
let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,data,isloading); let res:any = await Http.getInstance().${singleServiceApi.getRequestMethod()?lower_case}(`/${srfpluralize(item.codeName)?lower_case}/<#noparse>$</#noparse>{context.${item.getCodeName()?lower_case}}<#if singleServiceApi.getRequestPath()??>${singleServiceApi.getRequestPath()}</#if>`,data,isloading);
<#-- } --> <#-- } -->
</#if> </#if>
<#-- 提交对象数据情况end --> <#-- 提交对象数据情况end -->
...@@ -501,8 +501,8 @@ export default class ${srfclassname('${item.getCodeName()}')}ServiceBase extends ...@@ -501,8 +501,8 @@ export default class ${srfclassname('${item.getCodeName()}')}ServiceBase extends
<#if appdeAction.getBeforePSDEActionLogics?? && appdeAction.getBeforePSDEActionLogics()??> <#if appdeAction.getBeforePSDEActionLogics?? && appdeAction.getBeforePSDEActionLogics()??>
<#list appdeAction.getBeforePSDEActionLogics() as actionlogic> <#list appdeAction.getBeforePSDEActionLogics() as actionlogic>
<#assign appdelogic = actionlogic.getPSDELogic() /> <#assign appdelogic = actionlogic.getPSDELogic() />
let ${appdelogic.getCodeName()?lower_case}:${srfclassname('${appdelogic.getCodeName()}')}Logic = new ${srfclassname('${appdelogic.getCodeName()}')}Logic({context:JSON.parse(JSON.stringify(context)),data:JSON.parse(JSON.stringify(data))}); let ${appdelogic.getCodeName()?lower_case}:${srfclassname('${appdelogic.getCodeName()}')}Logic = new ${srfclassname('${appdelogic.getCodeName()}')}Logic({context:JSON.parse(JSON.stringify(context)),data:JSON.parse(JSON.stringify(data))});
data = await ${appdelogic.getCodeName()?lower_case}.onExecute(JSON.parse(JSON.stringify(context)),JSON.parse(JSON.stringify(data)),isloading?true:false); data = await ${appdelogic.getCodeName()?lower_case}.onExecute(JSON.parse(JSON.stringify(context)),JSON.parse(JSON.stringify(data)),isloading?true:false);
</#list> </#list>
</#if> </#if>
<#-- END: 执行之前逻辑附加 --> <#-- END: 执行之前逻辑附加 -->
...@@ -520,8 +520,8 @@ export default class ${srfclassname('${item.getCodeName()}')}ServiceBase extends ...@@ -520,8 +520,8 @@ export default class ${srfclassname('${item.getCodeName()}')}ServiceBase extends
<#if appdeAction.getAfterPSDEActionLogics?? && appdeAction.getAfterPSDEActionLogics()??> <#if appdeAction.getAfterPSDEActionLogics?? && appdeAction.getAfterPSDEActionLogics()??>
<#list appdeAction.getAfterPSDEActionLogics() as actionlogic> <#list appdeAction.getAfterPSDEActionLogics() as actionlogic>
<#assign appdelogic = actionlogic.getPSDELogic() /> <#assign appdelogic = actionlogic.getPSDELogic() />
let ${appdelogic.getCodeName()?lower_case}:${srfclassname('${appdelogic.getCodeName()}')}Logic = new ${srfclassname('${appdelogic.getCodeName()}')}Logic({context:JSON.parse(JSON.stringify(context)),data:JSON.parse(JSON.stringify(res))}); let ${appdelogic.getCodeName()?lower_case}:${srfclassname('${appdelogic.getCodeName()}')}Logic = new ${srfclassname('${appdelogic.getCodeName()}')}Logic({context:JSON.parse(JSON.stringify(context)),data:JSON.parse(JSON.stringify(res))});
res = await ${appdelogic.getCodeName()?lower_case}.onExecute(JSON.parse(JSON.stringify(context)),JSON.parse(JSON.stringify(res)),isloading?true:false); res = await ${appdelogic.getCodeName()?lower_case}.onExecute(JSON.parse(JSON.stringify(context)),JSON.parse(JSON.stringify(res)),isloading?true:false);
</#list> </#list>
</#if> </#if>
<#-- END: 执行之后逻辑附加 --> <#-- END: 执行之后逻辑附加 -->
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册