Browse Source

Merge remote-tracking branch 'origin/master'

yue 5 years atrás
parent
commit
997f8d482b

+ 17 - 24
src/main/java/com/jeeplus/modules/act/service/ActTaskService.java

@@ -1539,7 +1539,7 @@ public class ActTaskService extends BaseService {
 	 * @param act
 	 */
 	@Transactional(readOnly = false)
-	public void specially(Act act,String fullName) {
+	public void specially(Act act) {
 		// 设置意见
 		act.setComment(("yes".equals(act.getFlag())?"[没有问题] ":"[驳回] ")+act.getComment());
 		act.preUpdate();
@@ -1553,8 +1553,8 @@ public class ActTaskService extends BaseService {
 			vars.put("operators", user.getRunUnitRole());
 		} else {
 			//驳回到项目经理人工判断问题
-			String manager2 = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:项目经理人工判断问题");
-				vars.put("processer",manager2);
+			Project user = MyActiviUtils.findUser(act.getProcInsId());
+				vars.put("processer",user.getProjectManageRole());
 		}
 //		vars.put("yes".equals(act.getFlag())?"operators":"processer",fullName);
 		vars.put("flagNo","yes".equals(act.getFlag())?false:true);
@@ -1599,12 +1599,11 @@ public class ActTaskService extends BaseService {
 		String taskDefKey = act.getTaskDefKey();
 		// 提交流程任务
 		Map<String, Object> vars = Maps.newHashMap();
+		Project user = MyActiviUtils.findUser(act.getProcInsId());
 		if ("yes".equals(flag)) {
-			Project user = MyActiviUtils.findUser(act.getProcInsId());
 			vars.put("systemfulltime", user.getDistributionSystem());
 		} else {
-			String itemClose = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:判断项目是否需要关闭");
-			vars.put("itemClose",itemClose );
+			vars.put("itemClose",user.getDistributionEngineering());
 		}
 //		vars.put("yes".equals(act.getFlag())?"systemfulltime":"itemClose","yes".equals(act.getFlag())?fullTime:fullTime);
 		vars.put("systemNo","yes".equals(act.getFlag())?false:true);
@@ -1816,19 +1815,13 @@ public class ActTaskService extends BaseService {
 		String flag = act.getFlag();
 		vars.put("sealYes", false);
 		vars.put("sealNo", false);
+		Project user = MyActiviUtils.findUser(act.getProcInsId());
 		if ("yes".equals(flag)) {
-			Project user = MyActiviUtils.findUser(act.getProcInsId());
 			vars.put("sealPerson",user.getDistributionPolicy());
 			act.setComment("[没有问题]"+act.getComment());
 			vars.put("sealYes", true);
 		} else {
-			String manager2 = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:项目经理人工判断问题");
-			String manager = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:项目经理组织交底");
-			if (manager2!=null&&manager2!="") {
-				vars.put("phasePerson",manager2);
-			}else if (manager!=null&&manager!="") {
-				vars.put("phasePerson",manager);
-			}
+			vars.put("phasePerson",user.getProjectManageRole());
 			act.setComment("[驳回]" + act.getComment());
 			vars.put("sealNo", true);
 		}
@@ -1853,8 +1846,8 @@ public class ActTaskService extends BaseService {
 			act.setComment("[没有问题]"+act.getComment());
 			vars.put("receiptYes", true);
 		} else {
-			String coveredPerson = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:上传未盖章施工方案(行政政处(城区道路))");
-			vars.put("coveredPerson",coveredPerson);
+			Project user = MyActiviUtils.findUser(act.getProcInsId());
+			vars.put("coveredPerson",user.getConstructionUnitRole());
 			act.setComment("[驳回]" + act.getComment());
 			vars.put("receiptNo", true);
 		}
@@ -1906,8 +1899,8 @@ public class ActTaskService extends BaseService {
 			act.setComment("[没有问题]"+act.getComment());
 			vars.put("singleYes", true);
 		} else {
-			String coveredPerson = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:上传未盖章施工方案(行政政处(城区道路))");
-			vars.put("coveredPerson",coveredPerson);
+			Project user = MyActiviUtils.findUser(act.getProcInsId());
+			vars.put("coveredPerson",user.getConstructionUnitRole());
 			act.setComment("[驳回]" + act.getComment());
 			vars.put("singleNo", true);
 		}
@@ -1933,8 +1926,8 @@ public class ActTaskService extends BaseService {
 			act.setComment("[没有问题]"+act.getComment());
 			vars.put("policyYes", true);
 		} else {
-			String coveredPerson = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:上传未盖章施工方案(行政政处(城区道路))");
-			vars.put("coveredPerson",coveredPerson);
+			Project user = MyActiviUtils.findUser(act.getProcInsId());
+			vars.put("coveredPerson",user.getConstructionUnitRole());
 			act.setComment("[驳回]" + act.getComment());
 			vars.put("singleNo", true);
 		}
@@ -1956,12 +1949,12 @@ public class ActTaskService extends BaseService {
         vars.put("finishYes", false);
         vars.put("finishNo", false);
         if ("yes".equals(flag)) {
-            act.setComment("[没有问题]"+act.getComment());
+            act.setComment(act.getComment());
             vars.put("finishYes", true);
         } else {
-			String coveredPerson = MyActiviUtils.findHistoryActivity(act.getProcInsId(), "交底:上传未盖章施工方案(行政政处(城区道路))");
-			vars.put("coveredPerson",coveredPerson);
-            act.setComment("[驳回]" + act.getComment());
+			Project user = MyActiviUtils.findUser(act.getProcInsId());
+			vars.put("coveredPerson",user.getConstructionUnitRole());
+            act.setComment(act.getComment());
             vars.put("finishNo", true);
         }
         // 设置意见

+ 11 - 4
src/main/java/com/jeeplus/modules/act/web/ActTaskController.java

@@ -33,6 +33,8 @@ import com.jeeplus.modules.sg.managementcenter.project.service.ProjectService;
 import com.jeeplus.modules.sg.picking.activiti.entity.PickList;
 import com.jeeplus.modules.sg.picking.activiti.entity.ShowList;
 import com.jeeplus.modules.sg.picking.activiti.service.PickIngService;
+import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.service.SystemService;
 import org.activiti.engine.HistoryService;
 import org.activiti.engine.RepositoryService;
 import org.activiti.engine.RuntimeService;
@@ -113,6 +115,9 @@ public class ActTaskController extends BaseController {
 	@Autowired
 	private PickIngService pickIngService;
 
+	@Autowired
+	private SystemService systemService;
+
 	/**
 	 * 获取待办列表
 	 * @return
@@ -826,13 +831,13 @@ public class ActTaskController extends BaseController {
 	 */
 	@ResponseBody
 	@RequestMapping(value = "speciallyTask")
-	public AjaxJson speciallyTask(Act act,String fullName,String tuser,Construction construction) {
+	public AjaxJson speciallyTask(Act act,String tuser,Construction construction) {
 		AjaxJson j = new AjaxJson();
 
 		try {
 			String comment = URLDecoder.decode(act.getComment(), "UTF-8");
 			act.setComment(comment);
-			actTaskService.specially(act,fullName);
+			actTaskService.specially(act);
 		} catch (UnsupportedEncodingException e) {
 			e.printStackTrace();
 		}
@@ -903,12 +908,14 @@ public class ActTaskController extends BaseController {
 		} catch (UnsupportedEncodingException e) {
 			e.printStackTrace();
 		}
+		Project user = MyActiviUtils.findUser(act.getProcInsId());
+		User user1 = systemService.getUserByLoginName(user.getProjectManageRole());
 		OaNotify  oaNotify = new OaNotify();
 		oaNotify.setType("1");
 		oaNotify.setTitle("施工交底结束");
 		oaNotify.setContent("施工交底结束");
 		oaNotify.setStatus("1");
-		oaNotify.setOaNotifyRecordIds("9fcadb62979e4ceab459867b37bf04bc");
+		oaNotify.setOaNotifyRecordIds(user1.getId());
 		oaNotifyService.save(oaNotify);
 		List<OaNotifyRecord> list = oaNotify.getOaNotifyRecordList();
 		for(OaNotifyRecord o : list){
@@ -917,7 +924,7 @@ public class ActTaskController extends BaseController {
 					.getBean(ServletContext.class);
 			new SystemInfoSocketHandler().sendMessageToUser(UserUtils.get(o.getUser().getId()).getLoginName(), "收到一条新通知,请到我的通知查看!");
 		}
-		j.setMsg("审批成功;已经通知项目经理,施工单位");
+		j.setMsg("审批成功;已经通知"+user.getProjectManageRole());
 		return j;
 	}
 

+ 1 - 1
src/main/webapp/webpage/modules/sg/managementcenter/activiti/departmentForm.jsp

@@ -2,7 +2,7 @@
 <%@ include file="/webpage/include/taglib.jsp"%>
 <html>
 <head>
-	<title>配网系统专职</title>
+	<title>项目关闭</title>
 	<meta name="decorator" content="ani"/>
 	<!-- SUMMERNOTE -->
 	<%@include file="/webpage/include/summernote.jsp" %>

+ 36 - 39
src/main/webapp/webpage/modules/sg/managementcenter/activiti/documentsForm.jsp

@@ -6,14 +6,15 @@
 	<meta name="decorator" content="ani"/>
 	<!-- SUMMERNOTE -->
 	<%@include file="/webpage/include/summernote.jsp" %>
+	<%@include file="sealForm.js"%>
 	<script type="text/javascript">
-		$(document).ready(function () {
-			$("#agree").click(function () {
+        $(document).ready(function () {
+            $("#agree").click(function () {
                 var pic = $("#pic").val();
-				if (pic==""||pic==null){
-				    jp.error("请上传收据");
-				    return;
-				}
+                if (pic == "" || pic == null) {
+                    jp.error("请上传收据");
+                    return;
+                }
                 var currentFileValues = $("input[name='pic']").val();
                 jp.prompt("审核通过", function (message) {
                     jp.post("${ctx}/act/task/policyPay1Task",
@@ -23,47 +24,39 @@
                             "taskDefKey": "${construction.act.taskDefKey}",
                             "procInsId": "${construction.act.procInsId}",
                             "procDefId": "${construction.act.procDefId}",
-							"pic":currentFileValues,
+                            "pic": currentFileValues,
                             "flag": "yes",
                             "comment": window.encodeURI(message)
                         },
                         function (data) {
-                            if(data.success){
+                            if (data.success) {
                                 jp.success(data.msg);
                                 jp.go("${ctx}/act/task/todo")
                             }
                         })
                 })
-			});
-			$("#no").click(function () {
-                $("#agree").click(function () {
-                    var pic = $("#pic").val();
-                    if (pic==""||pic==null){
-                        jp.error("请上传收据");
-                        return;
-                    }
-                    var currentFileValues = $("input[name='pic']").val();
-				jp.prompt("结束", function (message) {
-					jp.post("${ctx}/act/task/policyPay1Task",
-							{
-								"taskId": "${construction.act.taskId}",
-								"taskName": "${construction.act.taskName}",
-								"taskDefKey": "${construction.act.taskDefKey}",
-								"procInsId": "${construction.act.procInsId}",
-								"procDefId": "${construction.act.procDefId}",
-                                "pic":currentFileValues,
-								"flag": "no",
-								"comment": window.encodeURI(message)
-							},
-							function (data) {
-								if(data.success){
-									jp.success(data.msg);
-									jp.go("${ctx}/act/task/todo")
-								}
-							})
-				})
-			});
-		})
+            });
+            $("#no").click(function () {
+                jp.prompt("驳回", function (message) {
+                    jp.post("${ctx}/act/task/policyPay1Task",
+                        {
+                            "taskId": "${construction.act.taskId}",
+                            "taskName": "${construction.act.taskName}",
+                            "taskDefKey": "${construction.act.taskDefKey}",
+                            "procInsId": "${construction.act.procInsId}",
+                            "procDefId": "${construction.act.procDefId}",
+                            "flag": "no",
+                            "comment": window.encodeURI(message)
+                        },
+                        function (data) {
+                            if (data.success) {
+                                jp.success(data.msg);
+                                jp.go("${ctx}/act/task/todo")
+                            }
+                        })
+                })
+            })
+        })
 	</script>
 </head>
 <body>
@@ -76,9 +69,13 @@
 						<a class="panelButton"  href="#"  onclick="history.go(-1)"><i class="ti-angle-left"></i> 返回</a>
 					</h3>
 				</div>
+				<div style="margin: 0px 25px 0px 25px">
+					<table id="testPicTable"   data-toolbar="#toolbar"></table>
+				</div>
 				<div class="panel-body">
 					<form:form id="inputForm" modelAttribute="construction" action="${ctx}/managementcenter/divide/save" method="post" class="form-horizontal">
 					<form:hidden path="id"/>
+						<input type="hidden" id="procInsId" name="procInsId" value="${construction.act.procInsId}"/>
 						<table class="table table-bordered">
 							<tbody>
 							<tr>
@@ -417,7 +414,7 @@
 							<div class="col-sm-6">
 								<div class="form-group text-center">
 									<input id="agree" class="btn  btn-primary btn-lg btn-parsley" type="submit" value="审核" />&nbsp;
-									<input id="no" class="btn  btn-danger btn-lg btn-parsley" type="submit" value="结束" />
+									<input id="no" class="btn  btn-danger btn-lg btn-parsley" type="submit" value="驳回" />
 								</div>
 							</div>
 						</div>

+ 0 - 4
src/main/webapp/webpage/modules/sg/managementcenter/activiti/memberForm.jsp

@@ -9,7 +9,6 @@
 	<script type="text/javascript">
 		$(document).ready(function () {
 			$("#agree").click(function () {
-			    var systemfulltime = $("#loginName").val();
                 jp.prompt("审核通过", function (message) {
                     jp.post("${ctx}/act/task/memberTask",
                         {
@@ -18,7 +17,6 @@
                             "taskDefKey": "${construction.act.taskDefKey}",
                             "procInsId": "${construction.act.procInsId}",
                             "procDefId": "${construction.act.procDefId}",
-							"fullTime":"专职",
                             "flag": "yes",
                             "comment": window.encodeURI(message)
                         },
@@ -31,7 +29,6 @@
                 })
 			});
 			$("#no").click(function () {
-                var systemfulltime = $("#loginName").val();
 				jp.prompt("审核不通过", function (message) {
 					jp.post("${ctx}/act/task/memberTask",
 					{
@@ -40,7 +37,6 @@
 						"taskDefKey":"${construction.act.taskDefKey}",
 						"procInsId":"${construction.act.procInsId}",
 						"procDefId":"${construction.act.procDefId}",
-                        "fullTime":"专职",
 						"flag":"no",
 						"projectName":"${fns:unescapeHtml(construction.projectName)}",
 						"comment":window.encodeURI(message)

+ 5 - 0
src/main/webapp/webpage/modules/sg/managementcenter/activiti/receiptForm.jsp

@@ -6,6 +6,7 @@
 	<meta name="decorator" content="ani"/>
 	<!-- SUMMERNOTE -->
 	<%@include file="/webpage/include/summernote.jsp" %>
+	<%@include file="sealForm.js"%>
 	<script type="text/javascript">
 		$(document).ready(function () {
 			$("#agree").click(function () {
@@ -69,9 +70,13 @@
 						<a class="panelButton"  href="#"  onclick="history.go(-1)"><i class="ti-angle-left"></i> 返回</a>
 					</h3>
 				</div>
+				<div style="margin: 0px 25px 0px 25px">
+					<table id="testPicTable"   data-toolbar="#toolbar"></table>
+				</div>
 				<div class="panel-body">
 					<form:form id="inputForm" modelAttribute="construction" action="${ctx}/managementcenter/divide/save" method="post" class="form-horizontal">
 					<form:hidden path="id"/>
+						<input type="hidden" id="procInsId" name="procInsId" value="${construction.act.procInsId}"/>
 						<table class="table table-bordered">
 							<tbody>
 							<tr>

+ 5 - 0
src/main/webapp/webpage/modules/sg/managementcenter/activiti/singleForm.jsp

@@ -6,6 +6,7 @@
 	<meta name="decorator" content="ani"/>
 	<!-- SUMMERNOTE -->
 	<%@include file="/webpage/include/summernote.jsp" %>
+	<%@include file="sealForm.js"%>
 	<script type="text/javascript">
 		$(document).ready(function () {
 			$("#agree").click(function () {
@@ -69,9 +70,13 @@
 						<a class="panelButton"  href="#"  onclick="history.go(-1)"><i class="ti-angle-left"></i> 返回</a>
 					</h3>
 				</div>
+				<div style="margin: 0px 25px 0px 25px">
+					<table id="testPicTable"   data-toolbar="#toolbar"></table>
+				</div>
 				<div class="panel-body">
 					<form:form id="inputForm" modelAttribute="construction" action="${ctx}/managementcenter/divide/save" method="post" class="form-horizontal">
 					<form:hidden path="id"/>
+						<input type="hidden" id="procInsId" name="procInsId" value="${construction.act.procInsId}"/>
 						<table class="table table-bordered">
 							<tbody>
 							<tr>

+ 0 - 3
src/main/webapp/webpage/modules/sg/managementcenter/activiti/speciallyForm.jsp

@@ -9,7 +9,6 @@
 	<script type="text/javascript">
 		$(document).ready(function () {
 			$("#agree").click(function () {
-                var systemfulltime = $("#loginName").val();
                 jp.prompt("审核通过", function (message) {
                     jp.post("${ctx}/act/task/speciallyTask",
                         {
@@ -18,7 +17,6 @@
                             "taskDefKey": "${construction.act.taskDefKey}",
                             "procInsId": "${construction.act.procInsId}",
                             "procDefId": "${construction.act.procDefId}",
-                            "fullName":"运行人员",
                             "flag": "yes",
                             "comment": window.encodeURI(message)
                         },
@@ -39,7 +37,6 @@
 						"taskDefKey":"${construction.act.taskDefKey}",
 						"procInsId":"${construction.act.procInsId}",
 						"procDefId":"${construction.act.procDefId}",
-                        "fullName":"项目经理",
 						"flag":"no",
 						"projectName":"${fns:unescapeHtml(construction.projectName)}",
 						"comment":window.encodeURI(message)