提交 69d33399 编写于 作者: sq3536's avatar sq3536

Merge remote-tracking branch 'origin/dev' into dev

......@@ -71,12 +71,6 @@ public class ${item.getCodeName()}ServiceImpl extends ServiceImpl<${de.getCodeNa
</#if>
private int batchSize = 500;
<#comment>引入工作流FeignClient</#comment>
<#if de.hasPSDEWF()==true>
@Autowired
${pub.getPKGCodeName()}.util.client.IBZWFFeignClient ibzwfFeignClient;
</#if>
<#comment>输出实体行为</#comment>
<#if item.getAllPSDEActions()??>
<#list item.getAllPSDEActions() as deaction>
......@@ -401,18 +395,8 @@ public class ${item.getCodeName()}ServiceImpl extends ServiceImpl<${de.getCodeNa
public Page<<#if dedataset.isEnableGroup()>HashMap<#else>${item.getCodeName()}</#if>> search${dedataset.getCodeName()}(${item.getCodeName()}SearchContext context) {
<#if item.isEnableSQLStorage() && item.getAllPSDEDBTables()??>
<#--<#list item.getAllPSDEDBTables() as detable>-->
<#assign entityName=srfpluralize(item.getCodeName()?lower_case)>
<#if de.hasPSDEWF()==true>
//查询工作流待办数据
if(!StringUtils.isEmpty(context.getUserTaskId()) && !StringUtils.isEmpty(context.getProcessDefinitionKey())){
List<String> businessKeys= ibzwfFeignClient.getbusinesskeysByUserId("${sys.getCodeName()?lower_case}", ${pub.getPKGCodeName()}.util.security.AuthenticationUser.getAuthenticationUser().getUserid(),"${entityName}",context.getProcessDefinitionKey(),context.getUserTaskId());
if(businessKeys.size()>0){
context.getSelectCond().in("${keyfield.name?lower_case}",businessKeys);
}
else{
context.getSelectCond().apply("1<>1");
}
}
fillWFTaskContext(context);
</#if>
com.baomidou.mybatisplus.extension.plugins.pagination.Page<<#if dedataset.isEnableGroup()>HashMap<#else>${item.getCodeName()}</#if>> pages=baseMapper.search${dedataset.getCodeName()}(context.getPages(),context,context.getSelectCond());
return new PageImpl<<#if dedataset.isEnableGroup()>HashMap<#else>${item.getCodeName()}</#if>>(pages.getRecords(), context.getPageable(), pages.getTotal());
......@@ -425,6 +409,30 @@ public class ${item.getCodeName()}ServiceImpl extends ServiceImpl<${de.getCodeNa
</#list>
</#if>
<#comment>引入工作流FeignClient</#comment>
<#if de.hasPSDEWF()==true>
<#assign entityName=srfpluralize(item.getCodeName()?lower_case)>
@Autowired
${pub.getPKGCodeName()}.util.client.IBZWFFeignClient ibzwfFeignClient;
/**
* 查询工作流待办
* @param context
*/
private void fillWFTaskContext(${item.getCodeName()}SearchContext context){
if(!StringUtils.isEmpty(context.getUserTaskId()) && !StringUtils.isEmpty(context.getProcessDefinitionKey())){
List<String> businessKeys= ibzwfFeignClient.getbusinesskeysByUserId("${sys.getCodeName()?lower_case}", ${pub.getPKGCodeName()}.util.security.AuthenticationUser.getAuthenticationUser().getUserid(),"${entityName}",context.getProcessDefinitionKey(),context.getUserTaskId());
if(businessKeys.size()>0){
context.getSelectCond().in("${keyfield.name?lower_case}",businessKeys);
}
else{
context.getSelectCond().apply("1<>1");
}
}
}
</#if>
<#comment>输出自定义sql查询</#comment>
@Override
public List<JSONObject> select(String sql){
......
......@@ -3,27 +3,19 @@ TARGET=PSSYSTEM
</#ibiztemplate>
package ${pub.getPKGCodeName()}.util.client;
import ${pub.getPKGCodeName()}.util.security.AuthenticationUser;
import ${pub.getPKGCodeName()}.util.security.AuthorizationLogin;
import org.springframework.stereotype.Component;
import java.util.Map;
import java.util.List;
@Component
public class IBZWFFallback implements IBZUAAFeignClient {
public class IBZWFFallback implements IBZWFFeignClient {
@Override
public Map<String, Object> pushSystemPermissionData(Map<String, Object> systemPermissionData, String systemId) {
public List<String> getbusinesskeys(String system, String appname, String entity, String processDefinitionKey, String taskDefinitionKey) {
return null;
}
@Override
public AuthenticationUser login(AuthorizationLogin authorizationLogin) {
return null;
}
@Override
public AuthenticationUser loginByUsername(String username) {
public List<String> getbusinesskeysByUserId(String system, String userId, String entity, String processDefinitionKey, String taskDefinitionKey) {
return null;
}
}
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册