Commit a170ee91 by xuwenhao

修改

parent 042e1a10
......@@ -205,6 +205,29 @@ public class SchoolDepartmentBudgetController extends BaseController
.createProcessInstanceQuery()//创建流程实例查询对象
.processInstanceId(instanceId)
.singleResult();
if(flag == false){
leave.setState("3");
/** 修改任务结果 */
schoolDepartmentBudgetService.updateById(leave);
/**发送模板消息到申请人,审批结果*/
LeaveResultTemplate template = new LeaveResultTemplate();
template.setFirst("您好,您的科室预算申请已回复。");
//获取申请人openId
String openId = teacherService.getOpenIdByUserId(leave.getApplyId());
template.setToUserOpenId(openId);
template.setResult(flag ? "已通过" : "已驳回");
template.setRemark("审批留言: "+ variables.get("comment"));
List<HistoricActivity> list = processService.selectHistoryList(instanceId,new HistoricActivity());
if(StringUtils.isNotNull(list) && list.size() > 0){
HistoricActivity activity = list.get(0);
template.setAuditTime(activity.getEndTime());
}
wxApiService.sendLeaveResultTemplate(template);
return AjaxResult.success("审批完成");
}
//说明流程实例结束了
if(rpi==null){
if(flag){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment