sql =" select t1.requestname,t1.currentnodeid as nodeid,d1.nodename,t3.workflowname,h2.lastname,h2.loginid"+
" from workflow_requestbase t1\n" +
" inner join workflow_base t3 on t1.workflowid = t3.id\n" +
" left join workflow_nodebase d1 on d1.id = t1.currentnodeid "+
" left join (select id,lastname,loginid from hrmresource where status = 1 union all select id,lastname,loginid from hrmresourcemanager ) h2 on h2.id = t1.creater \n" +
" where (t1.deleted <> 1 or t1.deleted is null or t1.deleted = '')\n" +
@ -114,6 +114,55 @@ public class SendPortalWithAddDoneCmd {
if(rs.next()){
num=rs.getInt("num");
}
//判断是否为转发节点
sql="SELECT c1."+PropBean.getUfPropValue("cus_staff")+" as staffid FROM workflow_currentoperator t1 left join cus_fielddata c1 on c1.id = t1.userid and c1.scopeid= "+scopeid+" and c1.scope = '"+scope+"' WHERE t1.preisremark=1 and t1.REQUESTID=? and t1.USERID=?";
@ -150,28 +155,28 @@ public class SendPortalWithAddTodoCmd {
for(Map<String,Object>todoMap:todolist){
JSONObjecttaskObject=newJSONObject();
sql = " select count(0) num "+
" from workflow_requestbase t1\n" +
" inner join workflow_currentoperator t2 on t1.requestid = t2.requestid\n" +
" left join cus_fielddata c1 on c1.id = t2.userid and c1.scopeid= "+scopeid+" and c1.scope = '"+scope+"' "+
" left join (select id, lastname,loginid,email from hrmresource where STATUS = 1 union all select id,lastname,loginid,'' as email from hrmresourcemanager ) h1 on h1.id = t2.userid\n" +
" left join workflow_nodebase d1 on d1.id = t2.nodeid "+
" where (t1.deleted <> 1 or t1.deleted is null or t1.deleted = '')\n" +
" and t1.currentnodetype <> 3"+
" and t2.isremark in ('2','9','8')\n" +
" and t2.preisremark in ('8','9')\n" +
" and t2.islasttimes = 1\n" +
" and (t2.isprocessing = '' or t2.isprocessing is null)\n" +
" and t2.requestid = "+requestid + " and t2.userid = "+todoMap.get("id");
// " left join cus_fielddata c1 on c1.id = t2.userid and c1.scopeid= "+scopeid+" and c1.scope = '"+scope+"' "+
// " left join (select id, lastname,loginid,email from hrmresource where STATUS = 1 union all select id,lastname,loginid,'' as email from hrmresourcemanager ) h1 on h1.id = t2.userid\n" +
// " left join workflow_nodebase d1 on d1.id = t2.nodeid "+
// " where (t1.deleted <> 1 or t1.deleted is null or t1.deleted = '')\n" +
// " and t1.currentnodetype <> 3"+
// " and t2.isremark in ('2','9','8')\n" +
// " and t2.preisremark in ('8','9')\n" +
// " and t2.islasttimes = 1\n" +
// " and (t2.isprocessing = '' or t2.isprocessing is null)\n" +
// " and t2.requestid = "+requestid + " and t2.userid = "+todoMap.get("id");
sql=" select t2.userid,h1.loginid,h1.lastname,h1.email,t2.isremark,t1.requestid,t2.nodeid,d1.nodename,c1."+cus_staff+" as staffid "+
" from workflow_requestbase t1\n"+
@ -180,8 +185,10 @@ public class SendPortalWithAddTodoCmd {
" left join (select id, lastname,loginid,email from hrmresource where STATUS = 1 union all select id,lastname,loginid,'' as email from hrmresourcemanager ) h1 on h1.id = t2.userid\n"+
" left join workflow_nodebase d1 on d1.id = t2.nodeid "+
" where (t1.deleted <> 1 or t1.deleted is null or t1.deleted = '')\n"+
" and t1.currentnodetype = 3"+
" and ((t2.isremark = '8' and t2.preisremark='8') or (t2.isremark = '9' and t2.preisremark='9'))\n"+
// " and t1.currentnodetype = 3"+
// " and ((t2.isremark = '8' and t2.preisremark='8') or (t2.isremark = '9' and t2.preisremark='9'))\n" +
" and t2.isremark in ('2','9','8')\n"+
" and t2.preisremark in ('8','9')\n"+
" and t2.islasttimes = 1\n"+
" and (t2.isprocessing = '' or t2.isprocessing is null)\n"+
" and t2.requestid = "+requestid+" and t2.userid = "+todoMap.get("id");
@ -305,6 +312,11 @@ public class SendPortalWithAddTodoCmd {
@ -415,9 +419,10 @@ public class SendRemarkOperateTodoCmd extends AbstractCommandProxy<Map<String, O
requestObject.put("ticketType",ticketType);
}
sql=" select t2.userid,h1.loginid\n" +
sql=" select t2.userid,h1.loginid,c1."+cus_staff+" as staffid "+
" from workflow_requestbase t1\n"+
" inner join workflow_currentoperator t2 on t1.requestid = t2.requestid\n"+
" left join cus_fielddata c1 on c1.id = t2.userid and c1.scopeid= "+scopeid+" and c1.scope = '"+scope+"' "+
" left join (select id, lastname,loginid from hrmresource where STATUS = 1 union all select id, lastname,loginid from hrmresourcemanager ) h1 on h1.id = t2.userid\n"+
" where (t1.deleted <> 1 or t1.deleted is null or t1.deleted = '')\n"+
" and t2.isremark = '1' \n"+
@ -433,7 +438,7 @@ public class SendRemarkOperateTodoCmd extends AbstractCommandProxy<Map<String, O
StringobjectAction="0";
StringobjectType="0";
StringobjectCode=usercode;
StringobjectId="" ;
StringobjectId=rs.getString("staffid");
StringoperatorCode=usercode;
taskObject.put("objectAction",objectAction);
@ -478,5 +483,11 @@ public class SendRemarkOperateTodoCmd extends AbstractCommandProxy<Map<String, O
@ -1037,14 +1075,16 @@ public class RocketmqUtil {
StringinsertHrmjobactivitiesSql=" insert into hrmjobtitles(jobtitlemark,jobtitlename,jobactivityid,jobdepartmentid,jobtitlecode,created,creater,modified,modifier,uuid) values(?,?,?,?,?,?,?,?,?,?)";