|
@@ -726,6 +726,34 @@ public class McYdServiceImpl implements McYdService {
|
|
}
|
|
}
|
|
return McR.errorParam("参数缺失!");
|
|
return McR.errorParam("参数缺失!");
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ public McR approveTask(Map map) {
|
|
|
|
+ String pid = getString(map.get("pid"));
|
|
|
|
+ MDC.put("MDC_KEY_PID",pid);
|
|
|
|
+
|
|
|
|
+ String outResult = UtilMap.getString(map, "outResult");
|
|
|
|
+ String userId = UtilMap.getString(map, "userId");
|
|
|
|
+
|
|
|
|
+ String processInstanceId = UtilMap.getString(map, "processInstanceId");
|
|
|
|
+ Long taskId = UtilMap.getLong(map, "taskId");
|
|
|
|
+
|
|
|
|
+ Map body = new HashMap();
|
|
|
|
+
|
|
|
|
+ body.put("outResult",outResult);//AGREE:同意 DISAGREE:拒绝。
|
|
|
|
+ body.put("appType",ydConf.getAppType());
|
|
|
|
+ body.put("systemToken",ydConf.getSystemToken());
|
|
|
|
+ body.put("remark",outResult);//审批意见
|
|
|
|
+ body.put("processInstanceId",processInstanceId);//审批实例id
|
|
|
|
+ body.put("userId",userId);//用户userid
|
|
|
|
+ body.put("taskId",taskId);//任务id
|
|
|
|
+
|
|
|
|
+ //审批
|
|
|
|
+ DDR_New ddrNew = (DDR_New) UtilHttp.doPost("https://api.dingtalk.com/v1.0/yida/tasks/execute", ddClient.initTokenHeader(), body, DDR_New.class);
|
|
|
|
+
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+
|
|
public String sendNotification(String access_token, List<String> userid_list, List<String> dept_id_list, boolean to_all_user, Map msg, String agent_id) {
|
|
public String sendNotification(String access_token, List<String> userid_list, List<String> dept_id_list, boolean to_all_user, Map msg, String agent_id) {
|
|
Map body = UtilMap.map("agent_id, to_all_user, msg", new Object[]{agent_id, to_all_user, msg});
|
|
Map body = UtilMap.map("agent_id, to_all_user, msg", new Object[]{agent_id, to_all_user, msg});
|
|
if (UtilList.isNotEmpty(userid_list)) {
|
|
if (UtilList.isNotEmpty(userid_list)) {
|