ソースを参照

上报新流程开发

user5 4 年 前
コミット
1795ce54fc
23 ファイル変更11319 行追加43 行削除
  1. 18 0
      src/main/java/com/jeeplus/modules/projectrecord/entity/ProjectRecordTreeData.java
  2. 18 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/entity/RuralProjectRecords.java
  3. 880 6
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageNewService.java
  4. 21 1
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageService.java
  5. 248 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralCostProjectMessageNewController.java
  6. 269 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageNewController.java
  7. 8 1
      src/main/java/com/jeeplus/modules/workactivity/dao/WorkActivityProcessDao.java
  8. 12 3
      src/main/java/com/jeeplus/modules/workactivity/service/WorkActivityProcessService.java
  9. 48 0
      src/main/java/com/jeeplus/modules/workprojectnotify/web/WorkProjectNotifyController.java
  10. 20 14
      src/main/resources/mappings/modules/workactivity/WorkActivityProcessDao.xml
  11. 1642 0
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/bzshbReportedAudit.jsp
  12. 1619 0
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/newReportedForm.jsp
  13. 1664 0
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/reportedAudit.jsp
  14. 1622 0
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/reportedModify.jsp
  15. 2 2
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReportedForm.jsp
  16. 2 2
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/reportedModify.jsp
  17. 9 4
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/ruralCostProjectMessageLists.jsp
  18. 1602 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedForm.jsp
  19. 1599 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedModify.jsp
  20. 2 2
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedAudit.jsp
  21. 2 2
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedForm.jsp
  22. 2 2
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedModify.jsp
  23. 10 4
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/ruralProjectMessageLists.jsp

+ 18 - 0
src/main/java/com/jeeplus/modules/projectrecord/entity/ProjectRecordTreeData.java

@@ -80,6 +80,8 @@ public class ProjectRecordTreeData extends DataEntity<ProjectRecordTreeData> {
     private Integer newRecordNotifyFlag; //新归档代办判定条件
     private String newRecordNotifyId; //新归档代办判定条件
     private Integer newRecordAuditNotifyFlag; //新归档(审批)判定条件
+    private String newReportedNotifyId; //新上报代办判定条件
+    private Integer newReportedNotifyFlag; //新上报(审批)判定条件
 
 
 
@@ -626,4 +628,20 @@ public class ProjectRecordTreeData extends DataEntity<ProjectRecordTreeData> {
     public void setPrdtProcessinstanceId(String prdtProcessinstanceId) {
         this.prdtProcessinstanceId = prdtProcessinstanceId;
     }
+
+    public String getNewReportedNotifyId() {
+        return newReportedNotifyId;
+    }
+
+    public void setNewReportedNotifyId(String newReportedNotifyId) {
+        this.newReportedNotifyId = newReportedNotifyId;
+    }
+
+    public Integer getNewReportedNotifyFlag() {
+        return newReportedNotifyFlag;
+    }
+
+    public void setNewReportedNotifyFlag(Integer newReportedNotifyFlag) {
+        this.newReportedNotifyFlag = newReportedNotifyFlag;
+    }
 }

+ 18 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/entity/RuralProjectRecords.java

@@ -196,6 +196,8 @@ public class RuralProjectRecords extends ActEntity<RuralProjectRecords> {
 	private Integer newRecordNotifyFlag; //新归档代办判定条件
 	private String newRecordNotifyId; //新归档代办判定条件
 	private Integer newRecordAuditNotifyFlag; //新归档(审批)判定条件
+	private String newReportedNotifyId; //新上报代办判定条件
+	private Integer newReportedNotifyFlag; //新上报(审批)判定条件
 
 	private Integer reportDataFlag; //报告号是否存在判定条件
 
@@ -1426,4 +1428,20 @@ public class RuralProjectRecords extends ActEntity<RuralProjectRecords> {
 	public void setReportDataFlag(Integer reportDataFlag) {
 		this.reportDataFlag = reportDataFlag;
 	}
+
+	public String getNewReportedNotifyId() {
+		return newReportedNotifyId;
+	}
+
+	public void setNewReportedNotifyId(String newReportedNotifyId) {
+		this.newReportedNotifyId = newReportedNotifyId;
+	}
+
+	public Integer getNewReportedNotifyFlag() {
+		return newReportedNotifyFlag;
+	}
+
+	public void setNewReportedNotifyFlag(Integer newReportedNotifyFlag) {
+		this.newReportedNotifyFlag = newReportedNotifyFlag;
+	}
 }

ファイルの差分が大きいため隠しています
+ 880 - 6
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageNewService.java


+ 21 - 1
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageService.java

@@ -329,6 +329,10 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
         workProjectNotify.setType("101");
         //查询所有需要当前登录人进行处理的项目信息
         List<WorkProjectNotify> newRecordNotifyList = workProjectNotifyService.findList(workProjectNotify);
+        //添加上报对应编号
+        workProjectNotify.setType("98");
+        //查询所有需要当前登录人进行处理的项目信息
+        List<WorkProjectNotify> newReportedNotifyList = workProjectNotifyService.findList(workProjectNotify);
 
         //无合同状态下,获取委托方的名称
         List<RuralProjectRecords> list = page.getList();
@@ -406,6 +410,20 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
                     break;
                 }
             }
+
+            //新代办修改权限处理
+            for (WorkProjectNotify notify: newReportedNotifyList) {
+                if(notify.getNotifyId().equals(records1.getId())){
+                    records1.setNewRecordNotifyId(notify.getId());
+                    if("重新申请".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
+                        records1.setNewReportedNotifyFlag(1);
+                    }
+                    if("待审批".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
+                        records1.setNewReportedNotifyFlag(1);
+                    }
+                    break;
+                }
+            }
             if (records1.getWorkContractInfo() == null) {
                 this.queryLinkmanInfos(records1);
                 if (records1.getWorkClientLinkmanList() != null && records1.getWorkClientLinkmanList().size() > 0) {
@@ -576,6 +594,8 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
         projectRecordTreeData.setNewRecordNotifyFlag(info.getNewRecordNotifyFlag());
         projectRecordTreeData.setNewRecordNotifyId(info.getNewRecordNotifyId());
         projectRecordTreeData.setNewRecordAuditNotifyFlag(info.getNewRecordAuditNotifyFlag());
+        projectRecordTreeData.setNewReportedNotifyId(info.getNewReportedNotifyId());
+        projectRecordTreeData.setNewReportedNotifyFlag(info.getNewReportedNotifyFlag());
 
         return projectRecordTreeData;
     }
@@ -3311,7 +3331,7 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
                         reported.setS2(areaCity.getId());
                         //判定区是否为空
                         if(StringUtils.isNotBlank(records.getCounty())){
-                                //判定区县级是否含有如下三个地区如果有则将该地区放入市级地区获取该地区的子集放到区级地区
+                            //判定区县级是否含有如下三个地区如果有则将该地区放入市级地区获取该地区的子集放到区级地区
                             if("沭阳县".equals(records.getCounty()) || "昆山市".equals(records.getCounty()) || "泰兴市".equals(records.getCounty())){
                                 Area district = this.getProjectReportedAreaByName(records.getCounty(), null);
                                 if(null != district) {

+ 248 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralCostProjectMessageNewController.java

@@ -10,7 +10,9 @@ import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.projectAccessory.entity.ProjectAccessoryRelationInfo;
 import com.jeeplus.modules.projectAccessory.entity.ProjectTemplateInfo;
 import com.jeeplus.modules.projectAccessory.service.ProjectTemplateService;
+import com.jeeplus.modules.projectEngineering.entity.ProjectEngineeringInfo;
 import com.jeeplus.modules.projectEngineering.service.ProjectEngineeringService;
+import com.jeeplus.modules.projectcontentinfo.dao.ProjectReportDataDao;
 import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
 import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportRecord;
 import com.jeeplus.modules.projectcontentinfo.entity.Projectcontentinfo;
@@ -19,13 +21,16 @@ import com.jeeplus.modules.projectcontentinfo.service.ProjectReportDataService;
 import com.jeeplus.modules.projectcontentinfo.service.ProjectReportRecordService;
 import com.jeeplus.modules.projectcontentinfo.service.ProjectcontentinfoService;
 import com.jeeplus.modules.projectrecord.entity.ProjectRecords;
+import com.jeeplus.modules.projectrecord.enums.ProjectStatusEnum;
 import com.jeeplus.modules.projectrecord.service.ProjectRecordsService;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecords;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecordsReported;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectcontentinfo;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralReportConsultant;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectMessageNewService;
+import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectMessageService;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectRecordsService;
+import com.jeeplus.modules.sys.entity.Area;
 import com.jeeplus.modules.sys.entity.MainDictDetail;
 import com.jeeplus.modules.sys.entity.User;
 import com.jeeplus.modules.sys.service.UserService;
@@ -83,6 +88,10 @@ public class RuralCostProjectMessageNewController extends BaseController {
     private ProjectEngineeringService engineeringService;
     @Autowired
     private ProjectReportRecordService projectReportRecordService;
+    @Autowired
+    private RuralProjectMessageService ruralProjectMessageS;
+    @Autowired
+    private ProjectReportDataDao projectReportDataDao;
 
     private static byte[] SYN_BYTE = new byte[0];
 
@@ -1235,4 +1244,243 @@ public class RuralCostProjectMessageNewController extends BaseController {
         }
         return "modules/ruralprojectrecords/record/cost/projectReportRecordModify";
     }
+
+    /**
+     * 项目上报
+     * @param projectRecords
+     * @return
+     */
+    @RequestMapping(value = "updateReported")
+    public String updateReported(RuralProjectRecords projectRecords, Model model) {
+        //查询上报信息表中是否含有数据,没有则进行获取基础数据
+        RuralProjectRecordsReported reported = ruralProjectMessageService.getRuralProjectRecordsReported(projectRecords.getId());
+        if(reported == null){
+            RuralProjectRecords records = projectRecordsService.getQueryProjectUsers(projectRecords.getId());
+            projectRecordsService.queryProjectDetail(records);
+            Projectcontentinfo projectcontentinfo1 = projectcontentinfoService.getByProjectId(projectRecords.getId());
+            ProjectReportData projectReportData = projectReportDataService.getOnRural(projectcontentinfo1.getInfoId());
+            records.setReportData(projectReportData);
+            reported = ruralProjectMessageService.disposeData(records);
+
+            //合同价送审价审定价处理
+            if(StringUtils.isNotBlank(reported.getHeTongJia())){
+                Double heTongJia = Double.valueOf(reported.getHeTongJia())/10000;
+                reported.setHeTongJia(String.format("%.2f", heTongJia));
+            }
+            if(StringUtils.isNotBlank(reported.getSongShenJia())){
+                Double songShenJia = Double.valueOf(reported.getSongShenJia())/10000;
+                reported.setSongShenJia(String.format("%.2f", songShenJia));
+            }
+            if(StringUtils.isNotBlank(reported.getShenDingJia())){
+                Double shenDingJia = Double.valueOf(reported.getShenDingJia())/10000;
+                reported.setShenDingJia(String.format("%.2f", shenDingJia));
+            }
+            if(StringUtils.isNotBlank(reported.getJingHeJianE())){
+                Double jingHeJianE = Double.valueOf(reported.getJingHeJianE())/10000;
+                reported.setJingHeJianE(String.format("%.2f", jingHeJianE));
+            }
+
+            ruralProjectMessageS.disposeProjectRecords(records,reported);
+        }
+        //根据上报id查询上报咨询员的信息
+        List<RuralReportConsultant> reportedConsultants=ruralProjectMessageS.getReportedConsultantsList(reported.getId());
+        //查询报告咨询员的信息
+        List<RuralReportConsultant> consultants=ruralProjectMessageService.getConsultantsList(projectRecords.getId());
+        List<RuralReportConsultant> consultantList = Lists.newArrayList();
+        if(reportedConsultants.size() == 0){
+            //如果上报的咨询员信息为空 则处理报告咨询员信息
+            consultantList = ruralProjectMessageS.disposeConsultant(consultants, projectRecords);
+        }else{
+            //对上报的咨询员进行处理
+            consultantList = ruralProjectMessageS.disposereportedConsultant(reportedConsultants);
+        }
+        RuralProjectRecords records = projectRecordsService.getQueryProjectUsers(reported.getProjectId());
+        /*if(StringUtils.isBlank(reported.getProjectRecordId())){
+            reported.setProjectRecordId(records.getProjectId());
+        }*/
+        model.addAttribute("ruralProjectRecordsReported", reported);
+        //查询项目信息
+        model.addAttribute("ruralProjectRecords", records);
+        model.addAttribute("consultantInfo", consultantList);
+        //获取工程类型
+        ProjectEngineeringInfo engineeringInfos=engineeringService.getProjectReportedType(reported.getPorjectUse());
+        model.addAttribute("engineeringInfo", engineeringInfos);
+        List<Area> areaList = ruralProjectMessageS.getProjectReportedAreaByParentId(reported.getS1());
+        model.addAttribute("cityList", areaList);
+        return "modules/ruralprojectrecords/cost/newReported/newReportedForm";
+    }
+
+    /**
+     * 项目上报
+     * @param projectRecords
+     * @return
+     */
+    @RequestMapping(value = "reportedModify")
+    public String reportedModify(RuralProjectRecords projectRecords, Model model) {
+        //查询上报信息表中是否含有数据,没有则进行获取基础数据
+        RuralProjectRecordsReported reported = ruralProjectMessageService.getRuralProjectRecordsReported(projectRecords.getId());
+        ProcessInstance processInstance = actTaskService.getProcIns(reported.getProcessInstanceId());
+        if (processInstance!=null) {
+            Task taskInfok = actTaskService.getCurrentTaskInfo(processInstance);
+            Act act = new Act();
+            act.setTaskId(taskInfok.getId());
+            act.setTaskName(taskInfok.getName());
+            act.setTaskDefKey(taskInfok.getTaskDefinitionKey());
+            act.setProcDefId(taskInfok.getProcessDefinitionId());
+            act.setProcInsId(taskInfok.getProcessInstanceId());
+            act.setTask(taskInfok);
+            reported.setAct(act);
+        }
+        RuralProjectRecords records = projectRecordsService.getQueryProjectUsers(reported.getProjectId());
+        //根据上报id查询上报咨询员的信息
+        List<RuralReportConsultant> reportedConsultants=ruralProjectMessageS.getReportedConsultantsList(reported.getId());
+        //对上报的咨询员进行处理
+        List<RuralReportConsultant> consultantList = ruralProjectMessageS.disposereportedConsultant(reportedConsultants);
+
+        //获取工程类型
+        ProjectEngineeringInfo engineeringInfos=engineeringService.getProjectReportedType(reported.getPorjectUse());
+        model.addAttribute("engineeringInfo", engineeringInfos);
+        List<Area> areaList = ruralProjectMessageS.getProjectReportedAreaByParentId(reported.getS1());
+        model.addAttribute("cityList", areaList);
+        //查询项目信息
+        model.addAttribute("ruralProjectRecords", records);
+        model.addAttribute("consultantInfo", consultantList);
+        model.addAttribute("ruralProjectRecordsReported", reported);
+        return "modules/ruralprojectrecords/cost/newReported/reportedModify";
+    }
+
+    /**
+     * 保存报告并提交审核
+     * @param reported
+     * @param redirectAttributes
+     * @return
+     */
+    @RequestMapping(value = "saveReported")
+    public String saveReported(RuralProjectRecordsReported reported,  RedirectAttributes redirectAttributes) throws Exception {
+        if(!BaseController.REPORTSWITCH){
+            addMessage(redirectAttributes, "项目上报失败:上报管理员已关闭上报模块");
+            return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralCostProjectMessage/?repage";
+        }
+        String str = "";
+        if(!reported.getIsNewRecord()){//编辑表单保存
+            ruralProjectMessageService.disposeList(reported);
+            RuralProjectRecordsReported t = ruralProjectMessageService.getRuralProjectRecordsReportedById(reported.getId());;//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(reported, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+            str = ruralProjectMessageService.saveReportedInfo(t, ProjectStatusEnum.IN_APRL);
+        }else{//新增表单保存
+            str = ruralProjectMessageService.saveReportedInfo(reported,ProjectStatusEnum.IN_APRL);
+        }
+
+
+        if (StringUtils.isNotBlank(str)){
+            addMessage(redirectAttributes, "项目上报失败:"+str);
+        }else {
+            addMessage(redirectAttributes, "项目上报成功");
+        }
+        return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralCostProjectMessage/?repage";
+    }
+
+    /**
+     * 保存报告并提交审核
+     * @param reported
+     * @param redirectAttributes
+     * @return
+     */
+    @RequestMapping(value = "tstore")
+    public String tstore(RuralProjectRecordsReported reported,  RedirectAttributes redirectAttributes) throws Exception {
+        if(!BaseController.REPORTSWITCH){
+            addMessage(redirectAttributes, "项目上报失败:上报管理员已关闭上报模块");
+            return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralCostProjectMessage/?repage";
+        }
+        String str = "";
+        if(!reported.getIsNewRecord()){//编辑表单保存
+            ruralProjectMessageService.disposeList(reported);
+            RuralProjectRecordsReported t = ruralProjectMessageService.getRuralProjectRecordsReportedById(reported.getId());;//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(reported, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+            str = ruralProjectMessageService.saveReportedInfo(t, ProjectStatusEnum.TSTORE);
+        }else{//新增表单保存
+            str = ruralProjectMessageService.saveReportedInfo(reported,ProjectStatusEnum.TSTORE);
+        }
+
+
+        if (StringUtils.isNotBlank(str)){
+            addMessage(redirectAttributes, "项目上报暂存失败:"+str);
+        }else {
+            addMessage(redirectAttributes, "项目上报暂存成功");
+        }
+        return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralCostProjectMessage/?repage";
+    }
+
+    /**
+     * 工单执行(完成任务)
+     * @param model
+     * @return
+     */
+    @RequestMapping(value = "auditSaveReported")
+    public String auditSaveReported(RuralProjectRecordsReported reported, Model model,
+                                    RedirectAttributes redirectAttributes) {
+        try {
+            if (!BaseController.REPORTSWITCH){
+                addMessage(redirectAttributes, "重新申请失败:上报管理员已关闭上报功能");
+                if (StringUtils.isNotBlank(reported.getHome()) && "home".equals(reported.getHome())){
+                    return "redirect:" + Global.getAdminPath() + "/home/?repage";
+                }else {
+                    return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralCostProjectMessage/?repage";
+                }
+            }
+            ruralProjectMessageService.disposeList(reported);
+            RuralProjectRecordsReported t = ruralProjectMessageService.getRuralProjectRecordsReportedById(reported.getId());;//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(reported, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+
+            String taskDefKey =  t.getAct().getTaskDefKey();
+            List<User> users = null;
+            if ("bmzr".equals(taskDefKey)){
+                users = UserUtils.getByProssType(t.getProcessInstanceId(),2);
+                if (users==null )
+                    users = UserUtils.getByRoleActivityEnname("sbglyyjla",3,t.getOffice().getId(),"4",t.getCreateBy());
+            }else if ("bzshb".equals(taskDefKey)){
+                //获取项目信息
+                ProjectRecords projectRecords = projectRecordsServices.getRuralMasters(reported.getProjectId());
+                //查询报告信息
+                ProjectReportData projectReportData = projectReportDataDao.getProjectReportData(projectRecords.getId());
+                //查询报告审核总审人员
+                User zsUser = UserUtils.get(projectReportData.getBzshbUserId());
+                users = Lists.newArrayList();
+                users.add(zsUser);
+            }else if ("modifyApply".equals(taskDefKey)){
+                //判断审核增减率
+                //判断审核增减率是否大于30%(大于则为false,否则为true)
+                if(Double.valueOf(reported.getJingHeJianLv())>30 && "10".equals(reported.getProjectType())){
+                    //获取项目信息
+                    ProjectRecords projectRecords = projectRecordsServices.getRuralMasters(reported.getProjectId());
+                    //查询报告信息
+                    ProjectReportData projectReportData = projectReportDataDao.getProjectReportData(projectRecords.getId());
+                    //查询报告审核总审人员
+                    User zsUser = UserUtils.get(projectReportData.getBzshbUserId());
+                    users = Lists.newArrayList();
+                    users.add(zsUser);
+                }else{
+                    users = UserUtils.getByRoleActivityEnname("sbglyyjla",3,t.getOffice().getId(),"4",t.getCreateBy());
+                }
+            }
+
+            String flag = reported.getAct().getFlag();
+            if ("yes".equals(flag) && (users==null || users.size()==0)){
+                addMessage(redirectAttributes, "审批失败,审批人为空,请联系管理员!");
+            }else {
+                String str = ruralProjectMessageService.auditSaveReported(t, users);
+
+                addMessage(redirectAttributes, str);
+            }
+        }catch (Exception e){
+            addMessage(redirectAttributes, "上报流程审批失败");
+            logger.error("上报流程审批失败:",e);
+        }
+
+        if (StringUtils.isNotBlank(reported.getHome()) && "home".equals(reported.getHome())){
+            return "redirect:" + Global.getAdminPath() + "/home/?repage";
+        }else {
+            return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralCostProjectMessage/?repage";
+        }
+    }
 }

+ 269 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageNewController.java

@@ -10,7 +10,9 @@ import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.projectAccessory.entity.ProjectAccessoryRelationInfo;
 import com.jeeplus.modules.projectAccessory.entity.ProjectTemplateInfo;
 import com.jeeplus.modules.projectAccessory.service.ProjectTemplateService;
+import com.jeeplus.modules.projectEngineering.entity.ProjectEngineeringInfo;
 import com.jeeplus.modules.projectEngineering.service.ProjectEngineeringService;
+import com.jeeplus.modules.projectcontentinfo.dao.ProjectReportDataDao;
 import com.jeeplus.modules.projectcontentinfo.dao.ProjectcontentinfoDao;
 import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
 import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportRecord;
@@ -20,6 +22,7 @@ import com.jeeplus.modules.projectcontentinfo.service.ProjectReportDataService;
 import com.jeeplus.modules.projectcontentinfo.service.ProjectReportRecordService;
 import com.jeeplus.modules.projectcontentinfo.service.ProjectcontentinfoService;
 import com.jeeplus.modules.projectrecord.entity.ProjectRecords;
+import com.jeeplus.modules.projectrecord.enums.ProjectStatusEnum;
 import com.jeeplus.modules.projectrecord.service.ProjectRecordsService;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecords;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecordsReported;
@@ -28,6 +31,7 @@ import com.jeeplus.modules.ruralprojectrecords.entity.RuralReportConsultant;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectMessageNewService;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectMessageService;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectRecordsService;
+import com.jeeplus.modules.sys.entity.Area;
 import com.jeeplus.modules.sys.entity.MainDictDetail;
 import com.jeeplus.modules.sys.entity.User;
 import com.jeeplus.modules.sys.service.UserService;
@@ -89,6 +93,10 @@ public class RuralProjectMessageNewController extends BaseController {
     private ProjectEngineeringService engineeringService;
     @Autowired
     private ProjectReportRecordService projectReportRecordService;
+    @Autowired
+    private RuralProjectMessageService ruralProjectMessageS;
+    @Autowired
+    private ProjectReportDataDao projectReportDataDao;
 
     private static byte[] SYN_BYTE = new byte[0];
 
@@ -1228,4 +1236,265 @@ public class RuralProjectMessageNewController extends BaseController {
         }
         return "modules/ruralprojectrecords/record/projectReportRecordModify";
     }
+
+    /**
+     * 项目上报
+     * @param projectRecords
+     * @return
+     */
+    @RequestMapping(value = "updateReported")
+    public String updateReported(RuralProjectRecords projectRecords, Model model) {
+        //查询上报信息表中是否含有数据,没有则进行获取基础数据
+        RuralProjectRecordsReported reported = ruralProjectMessageService.getRuralProjectRecordsReported(projectRecords.getId());
+        if(reported == null){
+            RuralProjectRecords records = projectRecordsService.getQueryProjectUsers(projectRecords.getId());
+            projectRecordsService.queryProjectDetail(records);
+            Projectcontentinfo projectcontentinfo1 = projectcontentinfoService.getByProjectId(projectRecords.getId());
+            ProjectReportData projectReportData = projectReportDataService.getOnRural(projectcontentinfo1.getInfoId());
+            records.setReportData(projectReportData);
+            reported = ruralProjectMessageService.disposeData(records);
+
+            //合同价送审价审定价处理
+            if(StringUtils.isNotBlank(reported.getHeTongJia())){
+                Double heTongJia = Double.valueOf(reported.getHeTongJia())/10000;
+                reported.setHeTongJia(String.format("%.2f", heTongJia));
+            }
+            if(StringUtils.isNotBlank(reported.getSongShenJia())){
+                Double songShenJia = Double.valueOf(reported.getSongShenJia())/10000;
+                reported.setSongShenJia(String.format("%.2f", songShenJia));
+            }
+            if(StringUtils.isNotBlank(reported.getShenDingJia())){
+                Double shenDingJia = Double.valueOf(reported.getShenDingJia())/10000;
+                reported.setShenDingJia(String.format("%.2f", shenDingJia));
+            }
+            if(StringUtils.isNotBlank(reported.getJingHeJianE())){
+                Double jingHeJianE = Double.valueOf(reported.getJingHeJianE())/10000;
+                reported.setJingHeJianE(String.format("%.2f", jingHeJianE));
+            }
+
+            ruralProjectMessageS.disposeProjectRecords(records,reported);
+        }
+        //根据上报id查询上报咨询员的信息
+        List<RuralReportConsultant> reportedConsultants=ruralProjectMessageS.getReportedConsultantsList(reported.getId());
+        //查询报告咨询员的信息
+        List<RuralReportConsultant> consultants=ruralProjectMessageService.getConsultantsList(projectRecords.getId());
+        List<RuralReportConsultant> consultantList = Lists.newArrayList();
+        if(reportedConsultants.size() == 0){
+            //如果上报的咨询员信息为空 则处理报告咨询员信息
+            consultantList = ruralProjectMessageS.disposeConsultant(consultants, projectRecords);
+        }else{
+            //对上报的咨询员进行处理
+            consultantList = ruralProjectMessageS.disposereportedConsultant(reportedConsultants);
+        }
+        RuralProjectRecords records = projectRecordsService.getQueryProjectUsers(reported.getProjectId());
+        /*if(StringUtils.isBlank(reported.getProjectRecordId())){
+            reported.setProjectRecordId(records.getProjectId());
+        }*/
+        model.addAttribute("ruralProjectRecordsReported", reported);
+        //查询项目信息
+        model.addAttribute("ruralProjectRecords", records);
+        model.addAttribute("consultantInfo", consultantList);
+        if(StringUtils.isBlank(reported.getS1())){
+            reported.setS1("10");
+        }
+        //获取工程类型
+        ProjectEngineeringInfo engineeringInfos=engineeringService.getProjectReportedType(reported.getPorjectUse());
+        model.addAttribute("engineeringInfo", engineeringInfos);
+        List<Area> areaList = ruralProjectMessageS.getProjectReportedAreaByParentId(reported.getS1());
+        model.addAttribute("cityList", areaList);
+        return "modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedForm";
+    }
+
+    /**
+     * 项目上报
+     * @param projectRecords
+     * @return
+     */
+    @RequestMapping(value = "reportedModify")
+    public String reportedModify(RuralProjectRecords projectRecords, Model model) {
+        //查询上报信息表中是否含有数据,没有则进行获取基础数据
+        RuralProjectRecordsReported reported = ruralProjectMessageService.getRuralProjectRecordsReported(projectRecords.getId());
+        ProcessInstance processInstance = actTaskService.getProcIns(reported.getProcessInstanceId());
+        if (processInstance!=null) {
+            Task taskInfok = actTaskService.getCurrentTaskInfo(processInstance);
+            Act act = new Act();
+            act.setTaskId(taskInfok.getId());
+            act.setTaskName(taskInfok.getName());
+            act.setTaskDefKey(taskInfok.getTaskDefinitionKey());
+            act.setProcDefId(taskInfok.getProcessDefinitionId());
+            act.setProcInsId(taskInfok.getProcessInstanceId());
+            act.setTask(taskInfok);
+            reported.setAct(act);
+        }
+        RuralProjectRecords records = projectRecordsService.getQueryProjectUsers(reported.getProjectId());
+        //根据上报id查询上报咨询员的信息
+        List<RuralReportConsultant> reportedConsultants=ruralProjectMessageS.getReportedConsultantsList(reported.getId());
+        //对上报的咨询员进行处理
+        List<RuralReportConsultant> consultantList = ruralProjectMessageS.disposereportedConsultant(reportedConsultants);
+
+        //获取工程类型
+        ProjectEngineeringInfo engineeringInfos=engineeringService.getProjectReportedType(reported.getPorjectUse());
+        model.addAttribute("engineeringInfo", engineeringInfos);
+        List<Area> areaList = ruralProjectMessageS.getProjectReportedAreaByParentId(reported.getS1());
+        model.addAttribute("cityList", areaList);
+        //查询项目信息
+        model.addAttribute("ruralProjectRecords", records);
+        model.addAttribute("consultantInfo", consultantList);
+        model.addAttribute("ruralProjectRecordsReported", reported);
+        return "modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedModify";
+    }
+
+    /**
+     * 保存报告并提交审核
+     * @param reported
+     * @param redirectAttributes
+     * @return
+     */
+    @RequestMapping(value = "saveReported")
+    public String saveReported(RuralProjectRecordsReported reported,  RedirectAttributes redirectAttributes) throws Exception {
+        if(!BaseController.REPORTSWITCH){
+            addMessage(redirectAttributes, "项目上报失败:上报管理员已关闭上报模块");
+            return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessage/?repage";
+        }
+        String str = "";
+        if(!reported.getIsNewRecord()){//编辑表单保存
+            ruralProjectMessageService.disposeList(reported);
+            RuralProjectRecordsReported t = ruralProjectMessageService.getRuralProjectRecordsReportedById(reported.getId());;//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(reported, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+            str = ruralProjectMessageService.saveReportedInfo(t, ProjectStatusEnum.IN_APRL);
+        }else{//新增表单保存
+            str = ruralProjectMessageService.saveReportedInfo(reported, ProjectStatusEnum.IN_APRL);
+        }
+
+
+        if (StringUtils.isNotBlank(str)){
+            addMessage(redirectAttributes, "项目上报失败:"+str);
+        }else {
+            addMessage(redirectAttributes, "项目上报成功");
+        }
+        return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessage/?repage";
+    }
+    /**
+     * 保存报告并提交审核
+     * @param reported
+     * @param redirectAttributes
+     * @return
+     */
+    @RequestMapping(value = "tstore")
+    public String tstore(RuralProjectRecordsReported reported,  RedirectAttributes redirectAttributes) throws Exception {
+        if(!BaseController.REPORTSWITCH){
+            addMessage(redirectAttributes, "项目上报失败:上报管理员已关闭上报模块");
+            return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessage/?repage";
+        }
+        String str = "";
+        if(!reported.getIsNewRecord()){//编辑表单保存
+            ruralProjectMessageService.disposeList(reported);
+            RuralProjectRecordsReported t = ruralProjectMessageService.getRuralProjectRecordsReportedById(reported.getId());;//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(reported, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+            str = ruralProjectMessageService.saveReportedInfo(t, ProjectStatusEnum.TSTORE);
+        }else{//新增表单保存
+            str = ruralProjectMessageService.saveReportedInfo(reported, ProjectStatusEnum.TSTORE);
+        }
+
+
+        if (StringUtils.isNotBlank(str)){
+            addMessage(redirectAttributes, "项目上报暂存失败:"+str);
+        }else {
+            addMessage(redirectAttributes, "项目上报暂存成功");
+        }
+        return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessage/?repage";
+    }
+
+    /**
+     * 工单执行(完成任务)
+     * @param model
+     * @return
+     */
+    @RequestMapping(value = "auditSaveReported")
+    public String auditSaveReported(RuralProjectRecordsReported reported, Model model,
+                                    RedirectAttributes redirectAttributes) {
+        try {
+            //判断是否关闭上报功能
+            if (!BaseController.REPORTSWITCH){
+                addMessage(redirectAttributes, "重新申请失败:上报管理员已关闭上报功能");
+                if (StringUtils.isNotBlank(reported.getHome()) && "home".equals(reported.getHome())){
+                    return "redirect:" + Global.getAdminPath() + "/home/?repage";
+                }else if (StringUtils.isNotBlank(reported.getHome()) && "notifyList".equals(reported.getHome())){
+                    return "redirect:" + Global.getAdminPath() + "/workprojectnotify/workProjectNotify/list/?repage";
+                }else {
+                    RuralProjectRecords ruralProjectRecords = projectRecordsService.get(reported.getProjectId());
+                    if(null != ruralProjectRecords){
+                        if("1".equals(ruralProjectRecords.getProjectType())){
+                            return "redirect:" + Global.getAdminPath() + "/ruralProject/ruralProjectMessage/?repage";
+                        }else if("2".equals(ruralProjectRecords.getProjectType())){
+                            return "redirect:" + Global.getAdminPath() + "/ruralProject/ruralCostProjectMessage/?repage";
+                        }
+                    }
+                    return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessage/?repage";
+                }
+            }
+            ruralProjectMessageService.disposeList(reported);
+            RuralProjectRecordsReported t = ruralProjectMessageService.getRuralProjectRecordsReportedById(reported.getId());;//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(reported, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+
+            String taskDefKey =  t.getAct().getTaskDefKey();
+            List<User> users = null;
+            if ("bmzr".equals(taskDefKey)){
+                users = UserUtils.getByProssType(t.getProcessInstanceId(),2);
+                if (users==null )
+                    users = UserUtils.getByRoleActivityEnname("sbglyyjla",3,t.getOffice().getId(),"4",t.getCreateBy());
+            }else if ("bzshb".equals(taskDefKey)){//总工审核
+                //获取项目信息
+                ProjectRecords projectRecords = projectRecordsServices.getRuralMasters(reported.getProjectId());
+                //查询报告信息
+                ProjectReportData projectReportData = projectReportDataDao.getProjectReportData(projectRecords.getId());
+                //查询报告审核总审人员
+                User zsUser = UserUtils.get(projectReportData.getBzshbUserId());
+                users = Lists.newArrayList();
+                users.add(zsUser);
+            }else if ("modifyApply".equals(taskDefKey)){
+                //判断审核增减率
+                //判断审核增减率是否大于30%(大于则为false,否则为true)
+                if(Double.valueOf(reported.getJingHeJianLv())>30 && "10".equals(reported.getProjectType())){
+                    //获取项目信息
+                    ProjectRecords projectRecords = projectRecordsServices.getRuralMasters(reported.getProjectId());
+                    //查询报告信息
+                    ProjectReportData projectReportData = projectReportDataDao.getProjectReportData(projectRecords.getId());
+                    //查询报告审核总审人员
+                    User zsUser = UserUtils.get(projectReportData.getBzshbUserId());
+                    users = Lists.newArrayList();
+                    users.add(zsUser);
+                }else{
+                    users = UserUtils.getByRoleActivityEnname("sbglyyjla",3,t.getOffice().getId(),"4",t.getCreateBy());
+                }
+            }
+
+            String flag = reported.getAct().getFlag();
+            if ("yes".equals(flag) && (users==null || users.size()==0)){
+                addMessage(redirectAttributes, "审批失败,审批人为空,请联系管理员!");
+            }else {
+                String str = ruralProjectMessageService.auditSaveReported(t, users);
+                addMessage(redirectAttributes, str);
+            }
+        }catch (Exception e){
+            addMessage(redirectAttributes, "上报流程审批失败");
+            logger.error("Exception e:"+e);
+        }
+        RuralProjectRecords ruralProjectRecords = projectRecordsService.get(reported.getProjectId());
+        if (StringUtils.isNotBlank(reported.getHome()) && "home".equals(reported.getHome())){
+            return "redirect:" + Global.getAdminPath() + "/home/?repage";
+        }else if (StringUtils.isNotBlank(reported.getHome()) && "notifyList".equals(reported.getHome())){
+            return "redirect:" + Global.getAdminPath() + "/workprojectnotify/workProjectNotify/list/?repage";
+        }else {
+            if(null != ruralProjectRecords){
+                if("1".equals(ruralProjectRecords.getProjectType())){
+                    return "redirect:" + Global.getAdminPath() + "/ruralProject/ruralProjectMessage/?repage";
+                }else if("2".equals(ruralProjectRecords.getProjectType())){
+                    return "redirect:" + Global.getAdminPath() + "/ruralProject/ruralCostProjectMessage/?repage";
+                }
+            }
+            return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessage/?repage";
+        }
+    }
+
 }

+ 8 - 1
src/main/java/com/jeeplus/modules/workactivity/dao/WorkActivityProcessDao.java

@@ -33,4 +33,11 @@ public interface WorkActivityProcessDao extends CrudDao<WorkActivityProcess> {
     int updateDelFlagAndIsApproval(WorkActivityProcess p);
     void deleteyProcess(String id);
     int updateType(@Param("processInstanceId")String processInstanceId,@Param("type")String type);
-}
+
+    /**
+     * 根据流程id删除对应人员展示信息
+     * @param processInstanceId
+     * @return
+     */
+    int deleteProcessUser(@Param("processInstanceId")String processInstanceId);
+}

+ 12 - 3
src/main/java/com/jeeplus/modules/workactivity/service/WorkActivityProcessService.java

@@ -31,7 +31,7 @@ public class WorkActivityProcessService extends CrudService<WorkActivityProcessD
 	public WorkActivityProcess get(String id) {
 		return super.get(id);
 	}
-	
+
 	public List<WorkActivityProcess> findByKeyAndCount(WorkActivityProcess workActivityProcess) {
 		return dao.findByKeyAndCount(workActivityProcess);
 	}
@@ -51,7 +51,7 @@ public class WorkActivityProcessService extends CrudService<WorkActivityProcessD
 	public Page<WorkActivityProcess> findPage(Page<WorkActivityProcess> page, WorkActivityProcess workActivityProcess) {
 		return super.findPage(page, workActivityProcess);
 	}
-	
+
 	@Transactional(readOnly = false)
 	public void save(WorkActivityProcess workActivityProcess) {
 		super.save(workActivityProcess);
@@ -298,6 +298,15 @@ public class WorkActivityProcessService extends CrudService<WorkActivityProcessD
 		dao.deleteProcessIdAuditUsers(processInstanceId);
 	}
 
+	/**
+	 * 根据流程id删除对应人员展示信息
+	 * @param processInstanceId
+	 */
+	@Transactional(readOnly = false)
+	public void deleteProcessUser(String processInstanceId) {
+		dao.deleteProcessUser(processInstanceId);
+	}
+
 	@Transactional(readOnly = false)
 	public void saveList(List<Activity> list,String processInstanceId) {
 		for (Activity activity:list){
@@ -316,7 +325,7 @@ public class WorkActivityProcessService extends CrudService<WorkActivityProcessD
 	public void delete(WorkActivityProcess workActivityProcess) {
 		super.delete(workActivityProcess);
 	}
-	
+
 	public void deleteyProcess(String id){
 		dao.deleteyProcess(id);
 	}

+ 48 - 0
src/main/java/com/jeeplus/modules/workprojectnotify/web/WorkProjectNotifyController.java

@@ -1694,6 +1694,54 @@ public class WorkProjectNotifyController extends BaseController {
 						model.addAttribute("reportedId",reported.getId());
 						return "modules/ruralprojectrecords/ruralporjectmessage/reportedView";
 					}
+				}else if ("98".equals(workProjectNotify.getType())) {    //新项目上报管理
+					RuralProjectRecordsReported reported = ruralProjectMessageService.getRuralProjectRecordsReported(workProjectNotify.getNotifyId());
+					model.addAttribute("projectTypeId",reported.getProjectType());
+					User user = UserUtils.get(reported.getXmFZR());
+					if(null != user){
+						model.addAttribute("xmFZRName",user.getName());
+					}
+
+					Act act = getByAct(reported.getProcessInstanceId());
+					reported.setAct(act);
+					if(StringUtils.isNotBlank(workProjectNotify.getHome())){
+						reported.setHome(workProjectNotify.getHome());
+					}else{
+						reported.setHome("home");
+					}
+					RuralProjectRecords records = ruralProjectRecordsService.getQueryProjectUsers(reported.getProjectId());
+					//根据上报id查询上报咨询员的信息
+					List<RuralReportConsultant> reportedConsultants=ruralProjectMessageService.getReportedConsultantsList(reported.getId());
+					//对上报的咨询员进行处理
+					List<RuralReportConsultant> consultantList = ruralProjectMessageService.disposereportedConsultant(reportedConsultants);
+
+					//获取工程类型
+					ProjectEngineeringInfo engineeringInfos=engineeringService.getProjectReportedType(reported.getPorjectUse());
+					model.addAttribute("engineeringInfo", engineeringInfos);
+					List<Area> areaList = ruralProjectMessageService.getProjectReportedAreaByParentId(reported.getS1());
+					model.addAttribute("cityList", areaList);
+					//查询项目信息
+					model.addAttribute("ruralProjectRecords", records);
+					model.addAttribute("ruralProjectRecordsReported", reported);
+					model.addAttribute("consultantInfo", consultantList);
+					if (workProjectNotify.getRemarks().contains("待通知") || "view".equals(workProjectNotify.getView())) {
+						ruralProjectMessageService.getInfoByView(reported);
+						model.addAttribute("reportedId",reported.getId());
+						return "modules/ruralprojectrecords/ruralporjectmessage/reportedView";
+					}else if (workProjectNotify.getRemarks().contains("待审批") && !"1".equals(workProjectNotify.getStatus())) {
+						model.addAttribute("identification", "projectReported");
+						model.addAttribute("identificationName","项目上报审核意见");
+						if(Double.valueOf(reported.getJingHeJianLv())>30 && "10".equals(reported.getProjectType())){
+							return "modules/ruralprojectrecords/cost/newReported/bzshbReportedAudit";
+						}
+						return "modules/ruralprojectrecords/cost/newReported/reportedAudit";
+					} else if (workProjectNotify.getRemarks().contains("重新申请") && !"1".equals(workProjectNotify.getStatus())) {
+						return "modules/ruralprojectrecords/ruralporjectmessage/reportedModify";
+					} else {
+						ruralProjectMessageService.getInfoByView(reported);
+						model.addAttribute("reportedId",reported.getId());
+						return "modules/ruralprojectrecords/ruralporjectmessage/reportedView";
+					}
 				} else if (workProjectNotify.getType().equals("131")) {    //项目计划通知
 					boolean flag = false;
 					//通过通知信息id获取项目登记对象

+ 20 - 14
src/main/resources/mappings/modules/workactivity/WorkActivityProcessDao.xml

@@ -42,7 +42,7 @@
 		a.activity_task AS "activityTask",
 		a.activity_id AS "activity.id"
 	</sql>
-	
+
 	<sql id="workActivityProcessJoins">
 	</sql>
 
@@ -51,9 +51,9 @@
 		SET del_flag = #{delFlag},is_approval = #{isApproval}
 		WHERE id = #{id}
 	</update>
-	
+
 	<select id="get" resultType="WorkActivityProcess" >
-		SELECT 
+		SELECT
 			<include refid="workActivityProcessColumns"/>
 		FROM work_activity_process a
 		<include refid="workActivityProcessJoins"/>
@@ -160,7 +160,7 @@
 	</select>
 
 	<select id="findList" resultType="WorkActivityProcess" >
-		SELECT 
+		SELECT
 			<include refid="workActivityProcessColumns"/>
 		FROM work_activity_process a
 		<include refid="workActivityProcessJoins"/>
@@ -188,15 +188,15 @@
 			</otherwise>
 		</choose>
 	</select>
-	
+
 	<select id="findAllList" resultType="WorkActivityProcess" >
-		SELECT 
+		SELECT
 			<include refid="workActivityProcessColumns"/>
 		FROM work_activity_process a
 		<include refid="workActivityProcessJoins"/>
 		<where>
 			a.del_flag = #{DEL_FLAG_NORMAL}
-		</where>		
+		</where>
 		<choose>
 			<when test="page !=null and page.orderBy != null and page.orderBy != ''">
 				ORDER BY ${page.orderBy}
@@ -206,7 +206,7 @@
 			</otherwise>
 		</choose>
 	</select>
-	
+
 	<insert id="insert">
 		INSERT INTO work_activity_process(
 			id,
@@ -238,9 +238,9 @@
 			#{activity.id}
 		)
 	</insert>
-	
+
 	<update id="update">
-		UPDATE work_activity_process SET 	
+		UPDATE work_activity_process SET
 			update_by = #{updateBy.id},
 			update_date = #{updateDate},
 			remarks = #{remarks},
@@ -283,10 +283,10 @@
 		DELETE FROM work_activity_process
 		WHERE id = #{id}
 	</update>
-	
+
 	<!--逻辑删除-->
 	<update id="deleteByLogic">
-		UPDATE work_activity_process SET 
+		UPDATE work_activity_process SET
 			del_flag = #{DEL_FLAG_DELETE}
 		WHERE id = #{id}
 	</update>
@@ -321,7 +321,7 @@
 		process_id = #{processInstanceId}
 	</update>
 
-	
+
 	<!-- 根据实体名称和字段名称和字段值获取唯一记录 -->
 	<select id="findUniqueByProperty" resultType="WorkActivityProcess" statementType="STATEMENT">
 		select * FROM work_activity_process  where ${propertyName} = '${value}'
@@ -336,4 +336,10 @@
 	UPDATE work_activity_process a SET
 			a.process_key = #{type} where a.process_instance_id=#{processInstanceId}
 	</update>
-</mapper>
+
+
+	<update id="deleteProcessUser">
+		DELETE FROM work_activity_process_user
+		WHERE process_id = #{processInstanceId}
+	</update>
+</mapper>

ファイルの差分が大きいため隠しています
+ 1642 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/bzshbReportedAudit.jsp


ファイルの差分が大きいため隠しています
+ 1619 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/newReportedForm.jsp


ファイルの差分が大きいため隠しています
+ 1664 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/reportedAudit.jsp


ファイルの差分が大きいため隠しています
+ 1622 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/reportedModify.jsp


+ 2 - 2
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReportedForm.jsp

@@ -78,13 +78,13 @@
                         }
                     }
                     //审核增减率
-                    if(!$("#JingHeJianLv").is(":hidden")){
+                    /*if(!$("#JingHeJianLv").is(":hidden")){
                         var JingHeJianLv = $("#JingHeJianLv").val();
                         if(parseFloat(JingHeJianLv) >30){
                             parent.layer.msg("审核增减率不得大于30%!", {icon: 5});
                             return false;
                         }
-                    }
+                    }*/
                     var list = [];
                     var size = $("#reportedConsultantList tr").length;
                     if(size <= 1){

+ 2 - 2
src/main/webapp/webpage/modules/ruralprojectrecords/cost/reportedModify.jsp

@@ -71,13 +71,13 @@
                     }
                 }
                 //审核增减率
-                if(!$("#JingHeJianLv").is(":hidden")){
+                /*if(!$("#JingHeJianLv").is(":hidden")){
                     var JingHeJianLv = $("#JingHeJianLv").val();
                     if(parseFloat(JingHeJianLv) >30){
                         parent.layer.msg("审核增减率不得大于30%!", {icon: 5});
                         return false;
                     }
-                }
+                }*/
                 var list = [];
                 var size = $("#reportedConsultantList tr").length;
                 if(size <= 1){

+ 9 - 4
src/main/webapp/webpage/modules/ruralprojectrecords/cost/ruralCostProjectMessageLists.jsp

@@ -1077,23 +1077,28 @@
 						if(d.syncStatus == 0){
 							if(d.reportStatus == 0){
 								if(d.reportedState == 0 || d.reportedState == 6){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessage/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #5FB878' class=\"layui-btn layui-btn-xs  layui-bg-blue\" > 上报</a>";
+									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessageNew/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #5FB878' class=\"layui-btn layui-btn-xs  layui-bg-blue\" > 上报</a>";
 									/*xml+="<a href=\"#\" onclick=\"openDialogre('上报管理', '${ctx}/ruralProject/ruralCostProjectMessage/updateReportedByPerson?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #5FB878' class=\"layui-btn layui-btn-xs  layui-bg-blue\" > 个人上报</a>";*/
 								}
 							}else{
 								if(d.reportedState == 1){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessage/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
+									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessageNew/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
 								}
 								if(d.reportedState == 2){
 									xml+="<a href=\"${ctx}/ruralProject/ruralCostProjectMessage/cancelInvalidateByReported?id=" + d.id + "&processInstanceId=" + d.reportedProcessInstanceId + "\" onclick=\"return confirmx('确认要撤回该上报审批吗?', this.href)\" class=\"layui-btn layui-btn-xs  layui-bg-red\" > 撤回上报</a>";
 								}
 								/*撤回修改*/
 								if(d.reportedState == 3){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessage/updateReported?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
+									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessageNew/updateReported?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
 								}
 								/*驳回修改*/
 								if(d.reportedState == 4){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessage/reportedModify?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改上报</a>";
+									//驳回操作
+									if(d.newReportedNotifyFlag == 1){
+										xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessageNew/reportedModify?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改上报</a>";
+									}else{
+										xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralCostProjectMessage/reportedModify?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改上报</a>";
+									}
 								}
 							}
 						}

ファイルの差分が大きいため隠しています
+ 1602 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedForm.jsp


ファイルの差分が大きいため隠しています
+ 1599 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedModify.jsp


+ 2 - 2
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedAudit.jsp

@@ -75,13 +75,13 @@
                         }
                     }
                     //审核增减率
-                    if(!$("#JingHeJianLv").is(":hidden")){
+                    /*if(!$("#JingHeJianLv").is(":hidden")){
                         var JingHeJianLv = $("#JingHeJianLv").val();
                         if(parseFloat(JingHeJianLv) >30){
                             parent.layer.msg("审核增减率不得大于30%!", {icon: 5});
                             return false;
                         }
-                    }
+                    }*/
                     var list = [];
                     var size = $("#reportedConsultantList tr").length;
                     if(size <= 1){

+ 2 - 2
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedForm.jsp

@@ -78,13 +78,13 @@
                         }
                     }
                     //审核增减率
-                    if(!$("#JingHeJianLv").is(":hidden")){
+                    /*if(!$("#JingHeJianLv").is(":hidden")){
                         var JingHeJianLv = $("#JingHeJianLv").val();
                         if(parseFloat(JingHeJianLv) >30){
                             parent.layer.msg("审核增减率不得大于30%!", {icon: 5});
                             return false;
                         }
-                    }
+                    }*/
                     var list = [];
                     var size = $("#reportedConsultantList tr").length;
                     if(size <= 1){

+ 2 - 2
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/reportedModify.jsp

@@ -71,13 +71,13 @@
                     }
                 }
                 //审核增减率
-                if(!$("#JingHeJianLv").is(":hidden")){
+                /*if(!$("#JingHeJianLv").is(":hidden")){
                     var JingHeJianLv = $("#JingHeJianLv").val();
                     if(parseFloat(JingHeJianLv) >30){
                         parent.layer.msg("审核增减率不得大于30%!", {icon: 5});
                         return false;
                     }
-                }
+                }*/
                 var list = [];
                 var size = $("#reportedConsultantList tr").length;
                 if(size <= 1){

+ 10 - 4
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/ruralProjectMessageLists.jsp

@@ -1075,23 +1075,29 @@
 						if(d.syncStatus == 0){
 							if(d.reportStatus == 0){
 								if(d.reportedState == 0 || d.reportedState == 6){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessage/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #5FB878' class=\"layui-btn layui-btn-xs layui-bg-blue\" > 上报</a>";
+									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessageNew/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #5FB878' class=\"layui-btn layui-btn-xs layui-bg-blue\" > 上报</a>";
 									/*xml+="<a href=\"#\" onclick=\"openDialogre('上报管理', '${ctx}/ruralProject/ruralProjectMessage/updateReportedByPerson?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #5FB878' class=\"layui-btn layui-btn-xs  layui-bg-blue\" > 个人上报</a>";*/
 								}
 							}else{
 								if(d.reportedState == 1){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessage/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
+									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessageNew/updateReported?id=" +  d.id + " ','95%', '95%','','上报,暂存,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
 								}
 								if(d.reportedState == 2){
 									xml+="<a href=\"${ctx}/ruralProject/ruralProjectMessage/cancelInvalidateByReported?id=" + d.id + "&processInstanceId=" + d.reportedProcessInstanceId + "\" onclick=\"return confirmx('确认要撤回该上报审批吗?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\" > 撤回上报</a>";
 								}
 								/*撤回修改*/
 								if(d.reportedState == 3){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessage/updateReported?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
+									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessageNew/updateReported?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改上报</a>";
 								}
 								/*驳回修改*/
 								if(d.reportedState == 4){
-									xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessage/reportedModify?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改上报</a>";
+									//驳回操作
+									if(d.newReportedNotifyFlag == 1){
+										xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessageNew/reportedModify?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改上报</a>";
+									}else{
+										xml+="<a href=\"#\" onclick=\"openDialogreReportSwitch('上报管理', '${ctx}/ruralProject/ruralProjectMessage/reportedModify?id=" +  d.id + " ','95%', '95%','','上报,关闭')\" style='background-color: #1E9FFF' class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改上报</a>";
+									}
+
 								}
 							}
 						}