Selaa lähdekoodia

Merge remote-tracking branch 'origin/master'

Enford 5 vuotta sitten
vanhempi
commit
a05183edb7
21 muutettua tiedostoa jossa 1909 lisäystä ja 341 poistoa
  1. 9 0
      src/main/java/com/jeeplus/modules/projectcontentinfo/dao/ProjectReportRecordDao.java
  2. 33 5
      src/main/java/com/jeeplus/modules/projectcontentinfo/entity/ProjectReportRecord.java
  3. 20 10
      src/main/java/com/jeeplus/modules/projectcontentinfo/service/ProjectReportRecordService.java
  4. 28 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/dao/RuralProjectMessageDao.java
  5. 38 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/entity/RuralProjectRecords.java
  6. 307 4
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageService.java
  7. 213 6
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageController.java
  8. 3 0
      src/main/java/com/jeeplus/modules/wexintheorder/service/TheOrderWebService.java
  9. 41 0
      src/main/resources/mappings/modules/projectcontentinfo/ProjectReportRecordDao.xml
  10. 152 1
      src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageDao.xml
  11. 13 5
      src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordAudit.jsp
  12. 18 11
      src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordForm.jsp
  13. 2 0
      src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordModifyApply.jsp
  14. 7 1
      src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordView.jsp
  15. 265 0
      src/main/webapp/webpage/modules/ruralprojectrecords/projectReportRecord/projectReportRecordForm.jsp
  16. 297 0
      src/main/webapp/webpage/modules/ruralprojectrecords/projectReportRecord/projectReportRecordModify.jsp
  17. 189 0
      src/main/webapp/webpage/modules/ruralprojectrecords/projectReportRecord/projectReportRecordView.jsp
  18. 3 3
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/projectcontentinfo/reportForm.jsp
  19. 3 3
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/projectcontentinfo/reportModify.jsp
  20. 155 249
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/projectcontentinfo/reportView.jsp
  21. 113 43
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/ruralProjectMessageList.jsp

+ 9 - 0
src/main/java/com/jeeplus/modules/projectcontentinfo/dao/ProjectReportRecordDao.java

@@ -29,4 +29,13 @@ public interface ProjectReportRecordDao extends CrudDao<ProjectReportRecord> {
      * @return
      */
     public ProjectReportRecord getByProcessInstanceId(String processInstanceId);
+
+    /**
+     * 根据id查询Rural归档信息
+     * @param id
+     * @return
+     */
+    ProjectReportRecord getRuralProjectReportRecord(String id);
+
+    int updateRuralProjectReportRecord(ProjectReportRecord projectReportRecord);
 }

+ 33 - 5
src/main/java/com/jeeplus/modules/projectcontentinfo/entity/ProjectReportRecord.java

@@ -3,12 +3,7 @@
  */
 package com.jeeplus.modules.projectcontentinfo.entity;
 
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
 import com.fasterxml.jackson.annotation.JsonFormat;
-
 import com.google.common.collect.Lists;
 import com.jeeplus.common.persistence.ActEntity;
 import com.jeeplus.common.utils.excel.annotation.ExcelField;
@@ -19,6 +14,10 @@ import org.activiti.engine.repository.ProcessDefinition;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.activiti.engine.task.Task;
 
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+
 /**
  * 报告归档Entity
  * @author 杨帆
@@ -48,6 +47,26 @@ public class ProjectReportRecord extends ActEntity<ProjectReportRecord> {
 	private String home;
 	private User signCostOne;		// 签字造价师一
 	private User signCostTwo;		// 签字造价师二
+	private String reportId;
+	private Date accomplishDate;  //归档完成时间
+
+	private Integer type;//(1:ProjectReportRecord  2:RuralProjectReportRecord)
+
+	public Integer getType() {
+		return type;
+	}
+
+	public void setType(Integer type) {
+		this.type = type;
+	}
+
+	public String getReportId() {
+		return reportId;
+	}
+
+	public void setReportId(String reportId) {
+		this.reportId = reportId;
+	}
 
 	public ProjectReportRecord() {
 		super();
@@ -293,4 +312,13 @@ public class ProjectReportRecord extends ActEntity<ProjectReportRecord> {
 	public void setSignCostTwo(User signCostTwo) {
 		this.signCostTwo = signCostTwo;
 	}
+
+	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+	public Date getAccomplishDate() {
+		return accomplishDate;
+	}
+
+	public void setAccomplishDate(Date accomplishDate) {
+		this.accomplishDate = accomplishDate;
+	}
 }

+ 20 - 10
src/main/java/com/jeeplus/modules/projectcontentinfo/service/ProjectReportRecordService.java

@@ -3,15 +3,16 @@
  */
 package com.jeeplus.modules.projectcontentinfo.service;
 
-import java.util.*;
-
 import com.google.common.collect.Maps;
+import com.jeeplus.common.persistence.Page;
+import com.jeeplus.common.service.CrudService;
 import com.jeeplus.common.utils.MenuStatusEnum;
 import com.jeeplus.common.utils.StringUtils;
-import com.jeeplus.common.websocket.onchat.ChatServerPool;
 import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
+import com.jeeplus.modules.projectcontentinfo.dao.ProjectReportRecordDao;
 import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
+import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportRecord;
 import com.jeeplus.modules.sys.dao.WorkattachmentDao;
 import com.jeeplus.modules.sys.entity.Office;
 import com.jeeplus.modules.sys.entity.User;
@@ -30,15 +31,11 @@ import com.jeeplus.modules.workprojectnotify.util.UtilNotify;
 import org.activiti.engine.*;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.activiti.engine.task.Task;
-import org.java_websocket.WebSocket;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 
-import com.jeeplus.common.persistence.Page;
-import com.jeeplus.common.service.CrudService;
-import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportRecord;
-import com.jeeplus.modules.projectcontentinfo.dao.ProjectReportRecordDao;
+import java.util.*;
 
 /**
  * 报告归档归档Service
@@ -76,6 +73,12 @@ public class ProjectReportRecordService extends CrudService<ProjectReportRecordD
 	private ProjectReportDataService projectReportDataService;
 	public ProjectReportRecord get(String id) {
 		ProjectReportRecord projectReportRecord= super.get(id);
+		if (null == projectReportRecord){
+			projectReportRecord = dao.getRuralProjectReportRecord(id);
+			projectReportRecord.setType(2);
+		}else{
+			projectReportRecord.setType(1);
+		}
 		if (projectReportRecord!=null && StringUtils.isNotBlank(projectReportRecord.getId())){
 			Workattachment workattachment = new Workattachment();
 			workattachment.setAttachmentId(id);
@@ -90,7 +93,7 @@ public class ProjectReportRecordService extends CrudService<ProjectReportRecordD
 			User signCostTwo = UserUtils.get(projectReportRecord.getSignCostTwo().getId());
 			projectReportRecord.setSignCostTwo(signCostTwo);
 		}
-		return super.get(id);
+		return projectReportRecord;
 	}
 	public int getNumber(String reportId) {
 		String number = dao.getNumber(reportId);
@@ -376,6 +379,9 @@ public class ProjectReportRecordService extends CrudService<ProjectReportRecordD
 			saveWorkattachments(reportRecord);
 			flag = "yes";
 		}
+		projectReportRecord.setFileNum(reportRecord.getFileNum());
+		projectReportRecord.setName(reportRecord.getName());
+		projectReportRecord.setAccomplishDate(new Date());
 		User user= UserUtils.get(projectReportRecord.getCreateBy().getId());
 		//String str = "报告归档发起人:"+user.getName()+",报告归档编号:"+projectReportRecord.getRecordNum()+",报告名称:"+projectReportRecord.getReport().getName();
 		String title =  "报告名称:"+projectReportRecord.getReport().getName();
@@ -650,7 +656,11 @@ public class ProjectReportRecordService extends CrudService<ProjectReportRecordD
 				UserUtils.pushMeIm(u.getId());
 			}
 		}
-		dao.update(projectReportRecord);
+		if (1 == projectReportRecord.getType()){
+			dao.update(projectReportRecord);
+		}else if(2 == projectReportRecord.getType()){
+			dao.updateRuralProjectReportRecord(projectReportRecord);
+		}
 		return "保存审核意见成功!";
 	}
 

+ 28 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/dao/RuralProjectMessageDao.java

@@ -6,6 +6,7 @@ package com.jeeplus.modules.ruralprojectrecords.dao;
 import com.jeeplus.common.persistence.CrudDao;
 import com.jeeplus.common.persistence.annotation.MyBatisDao;
 import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
+import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportRecord;
 import com.jeeplus.modules.projectrecord.entity.ProjectRecords;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecords;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectReportData;
@@ -46,4 +47,31 @@ public interface RuralProjectMessageDao extends CrudDao<RuralProjectRecords> {
     int updateRuralProjectReportData(ProjectReportData projectReportData);
 
     int updateFileStatus(ProjectReportData projectReportData);
+
+    /**
+     * 添加归档信息
+     * @param projectReportRecord
+     * @return
+     */
+    int insertProjectReportRecord(ProjectReportRecord projectReportRecord);
+
+    /**
+     * 修改归档信息
+     * @param projectReportRecord
+     * @return
+     */
+    int updateProjectReportRecord(ProjectReportRecord projectReportRecord);
+
+    /**
+     * 更新流程实例ID
+     * @return
+     */
+    int updateProcessInstanceId(ProjectReportRecord workReimbursement);
+
+    /**
+     * 查询归档信息
+     * @param repordId
+     * @return
+     */
+    ProjectReportRecord getProjectReportRecord(String reportId);
 }

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

@@ -59,8 +59,46 @@ public class RuralProjectRecords extends ActEntity<RuralProjectRecords> {
 	private ProjectReportData reportData;//报告
 
 	private String projectReportNumber; //报告号
+	private String recodeNum; //归档申请编号
 
 	private Integer projectReportStatus; //报告状态
+	private Integer projectReportRecordStatus; //归档状态
+
+	private String prrProcessInstanceId; //归档流程号
+
+	private String prrId;
+
+	public String getPrrId() {
+		return prrId;
+	}
+
+	public void setPrrId(String prrId) {
+		this.prrId = prrId;
+	}
+
+	public String getPrrProcessInstanceId() {
+		return prrProcessInstanceId;
+	}
+
+	public void setPrrProcessInstanceId(String prrProcessInstanceId) {
+		this.prrProcessInstanceId = prrProcessInstanceId;
+	}
+
+	public String getRecodeNum() {
+		return recodeNum;
+	}
+
+	public void setRecodeNum(String recodeNum) {
+		this.recodeNum = recodeNum;
+	}
+
+	public Integer getProjectReportRecordStatus() {
+		return projectReportRecordStatus;
+	}
+
+	public void setProjectReportRecordStatus(Integer projectReportRecordStatus) {
+		this.projectReportRecordStatus = projectReportRecordStatus;
+	}
 
 	public Integer getProjectReportStatus() {
 		return projectReportStatus;

+ 307 - 4
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageService.java

@@ -11,6 +11,7 @@ import com.jeeplus.modules.isignature.service.ISignatureDocumentService;
 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;
 import com.jeeplus.modules.projectcontentinfo.entity.Projectcontentinfo;
 import com.jeeplus.modules.projectcontentinfo.service.ProjectReportDataService;
 import com.jeeplus.modules.projectrecord.entity.ProjectRecords;
@@ -58,10 +59,7 @@ import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Propagation;
 import org.springframework.transaction.annotation.Transactional;
 
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import java.util.*;
 
 /**
  * 项目列表Service
@@ -117,6 +115,8 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
     private ActivityService activityService;
     @Autowired
     private WorkActivityProcessDao workActivityProcessDao;
+    @Autowired
+    private WorkContractInfoService workContractInfoService;
 
     public RuralProjectRecords get(String id) {
         return super.get(id);
@@ -185,6 +185,7 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
             projectReportData.setCompanyId(contentinfo.getCompanyId());
             projectReportData.setOfficeId(contentinfo.getOfficeId());
             projectReportData.setProject(contentinfo.getProject());
+            projectReportData.setReportDate(new Date());
             if (com.jeeplus.common.utils.StringUtils.isBlank(projectReportData.getId())){
                 projectReportData.setFileStatus("1");
             }
@@ -276,6 +277,16 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
         return null;
     }
 
+
+    /**
+     * 根据合同id获取合同信息
+     * @param workContractId
+     * @return
+     */
+    public WorkContractInfo getProjectContractInfo(String workContractId){
+        return workContractInfoService.get(workContractId);
+    }
+
     /**
      * 审核流程
      * @param reportData
@@ -726,6 +737,277 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
     }
 
 
+    @Transactional(readOnly = false)
+    public void saveWorkattachments(ProjectReportRecord projectReportRecord) {
+        List<Workattachment> workattachments = projectReportRecord.getWorkAttachments();
+        if (workattachments!=null && workattachments.size()!=0){
+            for (Workattachment workattachment:workattachments){
+                if (workattachment.getId() == null) {
+                    continue;
+                }
+                if (workattachment.DEL_FLAG_NORMAL.equals(workattachment.getDelFlag())) {
+                    workattachment.setAttachmentId(projectReportRecord.getId());
+                    workattachment.setAttachmentFlag("99");
+                    workattachment.setAttachmentUser(UserUtils.getUser().getId());
+                    if (com.jeeplus.common.utils.StringUtils.isBlank(workattachment.getId()) || "null".equals(workattachment.getId())) {
+                        workattachment.preInsert();
+                        workattachmentDao.insert(workattachment);
+                    } else {
+                        workattachment.preUpdate();
+                        workattachmentDao.update(workattachment);
+                    }
+                } else {
+                    workattachmentDao.delete(workattachment);
+                }
+            }
+        }
+
+    }
+
+    /**
+     * 提交归档存储
+     * @param projectReportRecord
+     * @param variables
+     */
+    @Transactional(readOnly = false)
+    public String saveProjectReportRecord(ProjectReportRecord projectReportRecord, Map<String, Object> variables, String processInstanceId) {
+
+        User user = UserUtils.getUser();
+        Boolean insert = false;
+        if (com.jeeplus.common.utils.StringUtils.isBlank(projectReportRecord.getId())){
+            projectReportRecord.setCompanyId(user.getComId());
+            projectReportRecord.setOfficeId(user.getOffice().getId());
+            projectReportRecord.preInsert();
+            insert = true;
+        }
+        saveWorkattachments(projectReportRecord);
+        String title =  "报告名称:"+projectReportRecord.getReport().getName();
+        String str = "归档申请编号:"+projectReportRecord.getRecordNum()+ ",主委托方:"+projectReportRecord.getClientName()+",申请人:"+user.getName()+",所属部门:"+UserUtils.getSelectOffice().getName();
+        // 用来设置启动流程的人员ID,引擎会自动把用户ID保存到activiti:initiator中
+        identityService.setAuthenticatedUserId(user.getId());
+        // 启动流程
+        String businessKey = projectReportRecord.getId().toString();
+        Office office = UserUtils.getSelectOffice();
+        WorkActivityMenu workActivityMenu = workActivityMenuService.findByParentAndOffice("5864872f45b84acd893010e66a3db2c8", office);
+        // 启动流程
+        String processType = workActivityMenu.getProcessType();
+        StringBuffer buffer = new StringBuffer();
+        Activity activity = new Activity();
+        WorkProjectNotify workProjectNotify = UtilNotify
+                .saveNotify(projectReportRecord.getId(),
+                        null,
+                        projectReportRecord.getCompanyId(),
+                        title,
+                        str,
+                        "51",
+                        "0",
+                        "待审批",
+                        ""
+                );
+        List<User> users = new ArrayList<>();
+        if (insert) {
+            this.insert(projectReportRecord);
+        }else {
+            this.save(projectReportRecord);
+        }
+        List<User> bggdglys = UserUtils.getByRoleActivityEnname("bggdgly",3,office.getId(),"10",projectReportRecord.getCreateBy());
+        if (com.jeeplus.common.utils.StringUtils.isNotBlank(workActivityMenu.getId())) {
+            workProjectNotify.setNotifyRole("");
+            workActivityMenu = workActivityMenuService.get(workActivityMenu.getId());
+            List<Activity> activities = workActivityMenu.getActivities();
+            for (Activity a : activities) {
+                String encount = a.getEncount();
+                String enlist = a.getEnlist();
+                if (a.getRole()!=null && com.jeeplus.common.utils.StringUtils.isNotBlank(a.getRole().getEnname())){
+                    List enusers = UserUtils.getByRoleActivityEnnames(a.getRole().getEnname(),office.getId(),"10",projectReportRecord.getCreateBy());
+                    if (enusers.size()==0){
+                        projectReportRecord.setStatus("1");
+                        //this.save(projectReportRecord);
+                        return "报告归档流程审批人不能为空,角色"+a.getRole().getName()+"下无用户,请联系管理员!";
+                    }
+                    variables.put(enlist, enusers);
+                    variables.put(encount, enusers.size());
+                }
+                if (a.getDelFlag().equals("0") && a.getCount() == 1) {
+                    activity = a;
+                }
+            }
+            buffer.append(activity.getRole().getEnname());
+            if (activity != null && com.jeeplus.common.utils.StringUtils.isNotBlank(activity.getId())) {
+                //角色审批
+                if (com.jeeplus.common.utils.StringUtils.isNotBlank(activity.getRole().getEnname())) {
+                    users = UserUtils.getByRoleActivityEnnames(activity.getRole().getEnname(),office.getId(),"10",projectReportRecord.getCreateBy());
+                }
+                //人员审批
+                if (com.jeeplus.common.utils.StringUtils.isNotBlank(activity.getUser().getId())) {
+                    users.add(activity.getUser());
+                }
+            }
+            workProjectNotify.setId("");
+        } else {
+            variables.put("bggdglyList", bggdglys);
+            if (bggdglys.size()==0){
+                projectReportRecord.setStatus("1");
+                this.save(projectReportRecord);
+                return "流程审批人不能为空,报告归档管理员下无用户,请联系管理员!";
+            }
+            variables.put("bggdglycount",bggdglys.size());
+            processType = "reportRecord";
+            users.addAll(bggdglys);
+        }
+        for (User u : users){
+            workProjectNotify.setUser(u);
+            workProjectNotify.setId("");
+            workProjectNotify.setNotifyRole("档案管理员审批");
+            workProjectNotifyService
+                    .save(workProjectNotify);
+            Map<String,Object> extras = new HashMap<>();
+            extras.put("type","7001");
+            extras.put("id",workProjectNotify.getId());
+            extras.put("procDefKey","51");
+            UserUtils.pushInfoToApp(title,str,extras,u.getId());
+            UserUtils.pushIm(u.getId(),str);
+        }
+        variables.put("type", processType);
+        variables.put("busId", businessKey);
+        variables.put("title", "报告归档编号:" + projectReportRecord.getRecordNum());//设置标题;
+
+        ProcessInstance processInstance = runtimeService.startProcessInstanceByKey(processType, businessKey, variables);
+
+        projectReportRecord.setProcessInstance(processInstance);
+        if (com.jeeplus.common.utils.StringUtils.isNotBlank(processInstanceId)) {
+            workActivityProcessService.updateProcessInstanceId(processInstance.getId(),processInstanceId);
+            workActivityProcessService.deleteProcessInstanceId(processInstanceId);
+            workActivityProcessService.deleteProcessIdAuditUsers(processInstanceId);
+        }
+        ProjectReportData projectReportData =projectReportRecord.getReport();
+        projectReportData.setFileStatus("2");
+        projectReportDataService.updateFileStatus(projectReportData);
+        // 修改更新流程实例ID
+        projectReportRecord.setProcessInstanceId(processInstance.getId());
+        dao.updateProcessInstanceId(projectReportRecord);
+        List<Activity> list = workActivityMenu.getActivities();
+        if (list != null && list.size() != 0) {
+            workActivityProcessService.saveList(list, processInstance.getId());
+        } else {
+            WorkActivityProcess workActivityProcess = new WorkActivityProcess();
+            workActivityProcess.setCount(1);
+            workActivityProcess.setProcessKey(processType);
+            workActivityProcess.setProcessInstanceId(processInstance.getId());
+            workActivityProcess.setIsApproval("0");
+            workActivityProcessService.insert(workActivityProcess);
+            workActivityProcessService.insertAuditsByType(bggdglys,processInstance.getId(),1,1);
+        }
+        return "true";
+    }
+
+    @Transactional(readOnly = false)
+    public void insert(ProjectReportRecord projectReportRecord) {
+        dao.insertProjectReportRecord(projectReportRecord);
+    }
+
+    @Transactional(readOnly = false)
+    public void save(ProjectReportRecord projectReportRecord) {
+        ProjectReportData projectReportData =projectReportRecord.getReport();
+        projectReportData.setFileStatus("2");
+        //修改归档状态
+        projectReportDataService.updateFileStatus(projectReportData);
+        if (projectReportRecord.getIsNewRecord()){
+            projectReportRecord.preInsert();
+            projectReportRecord.setCreateDate(new Date());
+            dao.insertProjectReportRecord(projectReportRecord);
+        }else{
+            projectReportRecord.preUpdate();
+            //修改归档信息
+            dao.updateProjectReportRecord(projectReportRecord);
+        }
+        saveWorkattachments(projectReportRecord);
+    }
+
+
+
+    /**
+     * 归档:强制撤销
+     * @param projectReportRecord
+     */
+    @Transactional(readOnly = false)
+    public void 	cancelInvalidate(ProjectReportRecord projectReportRecord){
+        String invalidateProcessInstanceId = projectReportRecord.getProcessInstanceId();
+        //将流程图中尚未走到的task的流程追踪信息逻辑删除,添加一条"撤销"流程追踪信息
+        WorkActivityProcess process = new WorkActivityProcess();
+        process.setProcessInstanceId(projectReportRecord.getProcessInstanceId());
+        process.setIsApproval("0");
+        WorkActivityProcess workActivityProcess = new WorkActivityProcess();
+        workActivityProcess.setProcessInstanceId(projectReportRecord.getProcessInstanceId());
+        List<WorkActivityProcess> processList = workActivityProcessService.findList(workActivityProcess);
+        WorkProjectNotify notify = new WorkProjectNotify();
+        notify.setNotifyId(projectReportRecord.getId());
+        List<User> userList = workProjectNotifyService.readByNotifyId(notify);
+        if (userList!=null && userList.size()!=0) {
+            for (User u : userList) {
+                User user = UserUtils.get(u.getId());
+                UserUtils.pushMeIm(user.getId());
+            }
+        }
+        if(processList!=null && processList.size()>0){
+            for (int i =0;i<processList.size();i++) {
+                WorkActivityProcess p = processList.get(i);
+                if(com.jeeplus.common.utils.StringUtils.isNotBlank(p.getIsApproval()) && "0".equals(p.getIsApproval())){
+                    p.setIsApproval("-1");
+                    p.setDelFlag("1");
+                    workActivityProcessDao.updateDelFlagAndIsApproval(p);
+                }
+            }
+            WorkActivityProcess pro = new WorkActivityProcess();
+            pro.setId("");
+            pro.preInsert();
+            pro.setDelFlag("0");
+            pro.setRemarks("[强制撤销]");
+            pro.setProcessKey(processList.get(0).getProcessKey());
+            pro.setIsApproval("1");
+            pro.setProcessInstanceId(processList.get(0).getProcessInstanceId());
+            pro.setCount(0);
+            workActivityProcessDao.insert(pro);
+        }
+
+        //结束该流程,设为"撤销"状态
+        try {
+            actTaskService.endProcessInstance(invalidateProcessInstanceId,"报告归档-强制撤销");
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+        projectReportRecord.setStatus("3");
+        projectReportRecord.preUpdate();
+        save(projectReportRecord);
+
+    }
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 
 
 
@@ -798,7 +1080,9 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
         }else {
             projectReportDataService.save(projectReportData);
         }
+        //总工
         List<User> bzshbs = UserUtils.getByRoleActivityEnname("bzshb",3,recordsOffice.getId(),"12",projectReportData.getCreateBy());
+        //总经理
         List<User> gzrs = UserUtils.getByRoleActivityEnname("gzr",3,recordsOffice.getId(),"12",projectReportData.getCreateBy());
         if (com.jeeplus.common.utils.StringUtils.isNotBlank(workActivityMenu.getId())) {
             workProjectNotify.setNotifyRole("");
@@ -894,6 +1178,25 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
         return "true";
     }
 
+    public ProjectReportRecord getProjectReportRecord(String reportId){
+        ProjectReportRecord projectReportRecord = dao.getProjectReportRecord(reportId);
+        if (projectReportRecord!=null && com.jeeplus.common.utils.StringUtils.isNotBlank(projectReportRecord.getId())){
+            Workattachment workattachment = new Workattachment();
+            workattachment.setAttachmentId(projectReportRecord.getId());
+            workattachment.setAttachmentFlag("99");
+            projectReportRecord.setWorkAttachments(workattachmentDao.findList(workattachment));
+        }
+        if (projectReportRecord.getSignCostOne()!=null && com.jeeplus.common.utils.StringUtils.isNotBlank(projectReportRecord.getSignCostOne().getId())){
+            User signCostOne = UserUtils.get(projectReportRecord.getSignCostOne().getId());
+            projectReportRecord.setSignCostOne(signCostOne);
+        }
+        if (projectReportRecord.getSignCostTwo()!=null && com.jeeplus.common.utils.StringUtils.isNotBlank(projectReportRecord.getSignCostTwo().getId())){
+            User signCostTwo = UserUtils.get(projectReportRecord.getSignCostTwo().getId());
+            projectReportRecord.setSignCostTwo(signCostTwo);
+        }
+        return projectReportRecord;
+    }
+
 
 
 

+ 213 - 6
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageController.java

@@ -8,18 +8,21 @@ import com.jeeplus.common.web.BaseController;
 import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
+import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportRecord;
 import com.jeeplus.modules.projectcontentinfo.entity.Projectcontentinfo;
 import com.jeeplus.modules.projectcontentinfo.service.ProjectReportChangeService;
 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.service.ProjectRecordsService;
-import com.jeeplus.modules.projectreportnum.service.ProjectReportNumService;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecords;
 import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectcontentinfo;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectMessageService;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectRecordsService;
+import com.jeeplus.modules.sys.entity.MainDictDetail;
 import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.utils.DictUtils;
 import com.jeeplus.modules.sys.utils.UserUtils;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientLinkman;
 import com.jeeplus.modules.workcontractinfo.entity.WorkContractInfo;
@@ -39,8 +42,10 @@ import org.springframework.web.servlet.mvc.support.RedirectAttributes;
 
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
+import java.util.Date;
 import java.util.HashMap;
 import java.util.List;
+import java.util.Map;
 
 /**
  * 项目列表Controller
@@ -61,13 +66,13 @@ public class RuralProjectMessageController extends BaseController {
     @Autowired
     private ProjectcontentinfoService projectcontentinfoService;
     @Autowired
-    private ProjectReportNumService projectReportNumService;
-    @Autowired
     private ProjectReportChangeService projectReportChangeService;
     @Autowired
     protected HistoryService historyService;
     @Autowired
     private ActTaskService actTaskService;
+    @Autowired
+    private ProjectReportRecordService projectReportRecordService;
 
     @ModelAttribute
     public RuralProjectRecords get(@RequestParam(required=false) String id) {
@@ -167,7 +172,19 @@ public class RuralProjectMessageController extends BaseController {
         model.addAttribute("projectId", projectcontentinfo1.getProject().getId());
         model.addAttribute("id", projectcontentinfo.getId());
         model.addAttribute("projectcontentinfo", projectcontent);
-        if (projectcontentinfo.getView().contains("report")) {
+        if (StringUtils.isNotBlank(projectcontentinfo.getView()) && projectcontentinfo.getView().contains("view")) {
+            List<MainDictDetail> achievementTypes = DictUtils.getMainDictList("achievement_type");
+            if(null != achievementTypes){
+                for (MainDictDetail achievementType:achievementTypes) {
+                    if(achievementType.getValue().equals(projectReportData.getAchievementType())){
+                        projectReportData.setAchievementType(achievementType.getLabel());
+                        break;
+                    }
+                }
+            }
+            return "modules/ruralprojectrecords/ruralporjectmessage/projectcontentinfo/reportView";
+        }
+        if (StringUtils.isNotBlank(projectcontentinfo.getView()) && projectcontentinfo.getView().contains("report")) {
             if(StringUtils.isNotBlank(projectReportData.getProcessInstanceId())){
                 Act act = getByAct(projectReportData.getProcessInstanceId());
                 projectReportData.setAct(act);
@@ -292,9 +309,9 @@ public class RuralProjectMessageController extends BaseController {
             return "redirect:" + Global.getAdminPath() + "/home/?repage";
         }else {
             if (StringUtils.isNotBlank(projectcontentinfo.getEdit()) && projectcontentinfo.getEdit().equals("edit")){
-                return "redirect:"+Global.getAdminPath()+"/projectcontentinfo/projectcontentinfo/list?id="+projectcontentinfo.getId()+"&edit=edit";
+                return "redirect:" + Global.getAdminPath() + "/ruralProject/ruralProjectMessage/?repage";
             }
-            return "redirect:"+Global.getAdminPath()+"/projectcontentinfo/projectcontentinfo/?id="+projectcontentinfo.getId();
+            return "redirect:" + Global.getAdminPath() + "/ruralProject/ruralProjectMessage/?repage";
         }
 
     }
@@ -354,4 +371,194 @@ public class RuralProjectMessageController extends BaseController {
 
 
 
+
+    /**
+     * 根据信息获取归档信息并调转页面
+     */
+    @RequestMapping(value = "formRecord")
+    public String form(ProjectReportRecord projectReportRecord, Model model) throws Exception {
+        if (StringUtils.isBlank(projectReportRecord.getView()) || !projectReportRecord.getView().equals("view")){
+            if(StringUtils.isBlank(projectReportRecord.getId())){
+                projectReportRecord.setCreateDate(new Date());
+                projectReportRecord.setCreateBy(UserUtils.getUser());
+            }
+        }
+        ProjectReportData projectReportData = new ProjectReportData();
+        ProjectRecords projectRecords = new ProjectRecords();
+        projectReportData.setFileStatus("1");
+        ProjectReportData reportData = ruralProjectMessageService.getProjectReportDateByProjectId(projectReportRecord.getReportId());
+        if(null != reportData){
+            if (StringUtils.isBlank(projectReportRecord.getView()) || !projectReportRecord.getView().equals("view")){
+                int count = projectReportRecordService.getNumber(reportData.getId());
+                projectReportRecord.setRecordNum(count>9?reportData.getNumber()+"-"+count+"":reportData.getNumber()+"-"+"0"+count);
+            }else{
+                ProjectReportRecord projectReportRecordInfo =ruralProjectMessageService.getProjectReportRecord(reportData.getId());
+                MyBeanUtils.copyBeanNotNull2Bean(projectReportRecordInfo, projectReportRecord);
+            }
+        }
+        //获取项目信息
+        RuralProjectRecords ruralProjectRecords = projectRecordsService.get(projectReportRecord.getReportId());
+        MyBeanUtils.copyBeanNotNull2Bean(ruralProjectRecords, projectRecords);
+        //获取合同信息
+        WorkContractInfo projectContractInfo = ruralProjectMessageService.getProjectContractInfo(projectRecords.getWorkContractInfo().getId());
+        projectRecords.setWorkContractInfo(projectContractInfo);
+        reportData.setProject(projectRecords);
+        projectReportRecord.setReport(reportData);
+        model.addAttribute("projectReportRecord", projectReportRecord);
+        if(null != projectContractInfo){
+            if(null != projectContractInfo.getWorkClientInfoList()){
+                model.addAttribute("workClientInfoName", projectContractInfo.getWorkClientInfoList().get(0).getName());
+            }
+        }
+        if (StringUtils.isNotBlank(projectReportRecord.getView()) && projectReportRecord.getView().equals("view")){
+            return "modules/ruralprojectrecords/projectReportRecord/projectReportRecordView";
+        }else if (StringUtils.isNotBlank(projectReportRecord.getView()) && projectReportRecord.getView().equals("modiftApply")){
+            ProcessInstance processInstance = actTaskService.getProcIns(projectReportRecord.getProcessInstanceId());
+            if (processInstance!=null) {
+                Task taskInfok = actTaskService.getCurrentTaskInfo(processInstance);
+                Act act = new Act();
+                act.setTaskId(taskInfok.getId());
+                act.setTaskName(taskInfok.getName());
+                act.setProcDefId(taskInfok.getProcessDefinitionId());
+                act.setTaskDefKey(taskInfok.getTaskDefinitionKey());
+                act.setProcInsId(taskInfok.getProcessInstanceId());
+                act.setTask(taskInfok);
+                projectReportRecord.setAct(act);
+            }
+            return "modules/projectcontentinfo/projectReportRecordModiftApply";
+        }
+        return "modules/ruralprojectrecords/projectReportRecord/projectReportRecordForm";
+    }
+
+    /**
+     * 查看,增加,编辑报告归档表单页面
+     */
+    @RequestMapping(value = "formRecordModify")
+    public String formRecordModify(ProjectReportRecord projectReportRecord, Model model) {
+        projectReportRecord = projectReportRecordService.get(projectReportRecord.getId());
+        if(StringUtils.isBlank(projectReportRecord.getId())){
+            projectReportRecord.setCreateDate(new Date());
+            projectReportRecord.setCreateBy(UserUtils.getUser());
+        }
+        projectReportRecord.setView("modify");
+        model.addAttribute("projectReportRecord", projectReportRecord);
+        if (StringUtils.isNotBlank(projectReportRecord.getView()) && projectReportRecord.getView().equals("view")){
+            return "modules/ruralprojectrecords/projectReportRecord/projectReportRecordView";
+        }else if (StringUtils.isNotBlank(projectReportRecord.getView()) && projectReportRecord.getView().equals("modiftApply")){
+            ProcessInstance processInstance = actTaskService.getProcIns(projectReportRecord.getProcessInstanceId());
+            if (processInstance!=null) {
+                Task taskInfok = actTaskService.getCurrentTaskInfo(processInstance);
+                Act act = new Act();
+                act.setTaskId(taskInfok.getId());
+                act.setTaskName(taskInfok.getName());
+                act.setProcDefId(taskInfok.getProcessDefinitionId());
+                act.setTaskDefKey(taskInfok.getTaskDefinitionKey());
+                act.setProcInsId(taskInfok.getProcessInstanceId());
+                act.setTask(taskInfok);
+                projectReportRecord.setAct(act);
+            }
+            return "modules/projectcontentinfo/projectReportRecordModiftApply";
+        }
+        return "modules/ruralprojectrecords/projectReportRecord/projectReportRecordModify";
+    }
+
+
+
+
+    /**
+     * 保存报告归档
+     */
+    @RequestMapping(value = "saveRecord")
+    public String save(ProjectReportRecord projectReportRecord, Model model, RedirectAttributes redirectAttributes) throws Exception{
+        if (!beanValidator(model, projectReportRecord)){
+            return form(projectReportRecord, model);
+        }
+        try {
+            User user = projectReportRecord.getCreateBy();
+            String sta = projectReportRecord.getStatus();
+            if(user!=null && !UserUtils.getUser().getId().equals(user.getId()) && StringUtils.isNotBlank(user.getId())){
+                addMessage(redirectAttributes, "您不是申请人,无法修改");
+                return "redirect:"+Global.getAdminPath()+"/workreimbursement/workReimbursement/?repage";
+            }
+            //状态设置为审核中
+            projectReportRecord.setStatus("2");
+            String processInstanceId ="";
+            if (user!=null && StringUtils.isNotBlank(user.getId()) && StringUtils.isNotBlank(sta) && "3".equals(sta)){
+                processInstanceId = projectReportRecordService.get(projectReportRecord.getId()).getProcessInstanceId();
+            }
+            Map<String, Object> variables = new HashMap<>();
+            if(!projectReportRecord.getIsNewRecord()){//编辑表单保存
+                ProjectReportRecord t = projectReportRecordService.get(projectReportRecord.getId());//从数据库取出记录的值
+                MyBeanUtils.copyBeanNotNull2Bean(t,projectReportRecord);//将编辑表单中的非NULL值覆盖数据库记录中的值
+                if (StringUtils.isNotBlank(projectReportRecord.getView()) && projectReportRecord.getView().equals("modify")){
+                    projectReportRecord.setStatus("2");
+                }
+                ruralProjectMessageService.saveProjectReportRecord(projectReportRecord,variables,processInstanceId);//保存
+            }else {//新增表单保存
+                ruralProjectMessageService.saveProjectReportRecord(projectReportRecord,variables,processInstanceId);//保存
+            }
+            addMessage(redirectAttributes, "保存报告归档成功");
+        }catch (Exception e){
+            addMessage(redirectAttributes, "保存报告归档失败");
+        }
+        return "redirect:" + Global.getAdminPath() + "/ruralProject/ruralProjectMessage/?repage";
+    }
+
+    /**
+     * 读取单个实体流程
+     * @return
+     */
+    @RequestMapping(value = "getReportRecordProcessOne")
+    public String getReportRecordProcessOne(ProjectReportRecord projectReportRecord,Model model) {
+        model.addAttribute("processInstanceId", projectReportRecord.getProcessInstanceId());
+        return "modules/workreimbursement/workReimbursementTrack";
+    }
+
+    //报告流程审批
+    @RequestMapping(value = {"auditProjectReportRecordSave"})
+    public String auditProjectReportRecordSave(ProjectReportRecord projectReportRecord, HttpServletRequest request, HttpServletResponse response, Model model,
+                            RedirectAttributes redirectAttributes) {
+        try {
+            // 对不同环节的业务逻辑进行操作
+            List<User> users = UserUtils.getByProssType(projectReportRecord.getProcessInstanceId(),1);
+            String flag = projectReportRecord.getAct().getFlag();
+            if ("yes".equals(flag) && (users==null || users.size()==0)){
+                addMessage(redirectAttributes, "审批失败,审批人为空,请联系管理员!");
+            }else {
+                String str = projectReportRecordService.auditSave(projectReportRecord,users);
+                addMessage(redirectAttributes, str);
+            }
+        }catch (Exception e){
+            logger.error("Exception e:"+e);
+            addMessage(redirectAttributes, "报告归档流程审批失败");
+        }
+        if (StringUtils.isNotBlank(projectReportRecord.getHome()) && projectReportRecord.getHome().equals("home")){
+            return "redirect:" + Global.getAdminPath() + "/home/?repage";
+        }else {
+            //报告变更
+            Page<ProjectReportRecord> page = projectReportRecordService.findPage(new Page<ProjectReportRecord>(request, response), projectReportRecord);
+            model.addAttribute("page", page);
+            return "modules/projectcontentinfo/projectReportRecordList";
+        }
+    }
+
+    /**
+     * 报告归档:强制撤回
+     */
+    @RequestMapping("cancelInvalidate")
+    public String cancelInvalidate(ProjectReportRecord projectReportRecord,RedirectAttributes redirectAttributes){
+        projectReportRecord = projectReportRecordService.get(projectReportRecord.getId());
+        try {
+            if(projectReportRecord.getStatus().equals("5")){
+                addMessage(redirectAttributes, "报告归档已审批通过,无法撤回");
+            }else{
+                ruralProjectMessageService.cancelInvalidate(projectReportRecord);
+                addMessage(redirectAttributes, "强制撤回报告归档成功");
+            }
+        }catch (Exception e){
+            addMessage(redirectAttributes, "强制撤回报告归档失败");
+        }
+        return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessage/?repage";
+    }
+
 }

+ 3 - 0
src/main/java/com/jeeplus/modules/wexintheorder/service/TheOrderWebService.java

@@ -30,6 +30,9 @@ public class TheOrderWebService extends CrudService<TheOrderWebDao,TheOrder>{
         //获取预定时间区间
         if (null != theOrder.getScheduled()){
             theOrder.setScheduledStr(dateStr(theOrder.getScheduled()));
+        } else{
+            theOrder.setScheduledStr(dateStr(time(1)));
+            theOrder.setScheduled(time(1));
         }
         int count = dao.queryCount(theOrder);
         page.setCount(count);

+ 41 - 0
src/main/resources/mappings/modules/projectcontentinfo/ProjectReportRecordDao.xml

@@ -17,6 +17,7 @@
 		a.file_num AS "fileNum",
 		a.name AS "name",
 		a.record_date AS "recordDate",
+		a.accomplish_date AS "accomplishDate",
 		a.status AS "status",
 		a.number_count AS "numberCount",
 		a.process_instance_id AS "processInstanceId",
@@ -49,6 +50,24 @@
 		LEFT JOIN work_client_info wct on wci.client_id = wct.id
 		WHERE a.id = #{id}
 	</select>
+
+	<select id="getRuralProjectReportRecord" resultType="ProjectReportRecord" >
+		SELECT
+		<include refid="projectReportRecordColumns"/>,
+		wci.contract_num AS "contractNum",
+		wci.name AS "contractName",
+		wct.name AS "clientName",
+		d.report_date AS "report.reportDate",
+		r.project_name AS "projectName",
+		r.project_id AS "projectNum"
+		FROM rural_project_report_record a
+		<include refid="projectReportRecordJoins"/>
+		LEFT JOIN rural_project_records r ON r.id = d.project_id
+		LEFT JOIN work_contract_info wci on r.contract_id = wci.id
+		LEFT JOIN work_client_info wct on wci.client_id = wct.id
+		WHERE a.id = #{id}
+	</select>
+
 	<select id="getNumber" resultType="String" >
 		SELECT
 			number_count
@@ -214,6 +233,28 @@
 			file_num = #{fileNum},
 			name = #{name},
 			record_date = #{recordDate},
+			accomplish_date = #{accomplishDate},
+			status = #{status},
+			number_count = #{numberCount},
+			sign_cost_one = #{signCostOne.id},
+			sign_cost_two = #{signCostTwo.id},
+			process_instance_id = #{processInstanceId}
+		WHERE id = #{id}
+	</update>
+
+	<update id="updateRuralProjectReportRecord">
+		UPDATE rural_project_report_record SET
+			update_by = #{updateBy.id},
+			update_date = #{updateDate},
+			remarks = #{remarks},
+			report_id = #{report.id},
+			company_id = #{companyId},
+			office_id = #{officeId},
+			record_num = #{recordNum},
+			file_num = #{fileNum},
+			name = #{name},
+			record_date = #{recordDate},
+			accomplish_date = #{accomplishDate},
 			status = #{status},
 			number_count = #{numberCount},
 			sign_cost_one = #{signCostOne.id},

+ 152 - 1
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageDao.xml

@@ -85,6 +85,37 @@
 	<sql id="projectRecordsJoins">
 		LEFT JOIN sys_area area ON area.id = a.area_id
 	</sql>
+
+	<sql id="projectReportRecordColumns">
+		a.id AS "id",
+		a.create_by AS "createBy.id",
+		a.create_date AS "createDate",
+		a.update_by AS "updateBy.id",
+		a.update_date AS "updateDate",
+		a.remarks AS "remarks",
+		a.del_flag AS "delFlag",
+		a.report_id AS "report.id",
+		a.company_id AS "companyId",
+		a.office_id AS "officeId",
+		a.record_num AS "recordNum",
+		a.file_num AS "fileNum",
+		a.name AS "name",
+		a.record_date AS "recordDate",
+		a.accomplish_date AS "accomplishDate",
+		a.status AS "status",
+		a.number_count AS "numberCount",
+		a.process_instance_id AS "processInstanceId",
+		a.sign_cost_one AS "signCostOne.id",
+		a.sign_cost_two AS "signCostTwo.id",
+		u.name AS "createBy.name",
+		d.name AS "report.name",
+		d.number AS "report.number"
+	</sql>
+
+	<sql id="projectReportRecordJoins">
+		JOIN project_report_data d ON d.id = a.report_id
+		JOIN sys_user u ON u.id = a.create_by
+	</sql>
 	
     
 	<select id="get" resultType="RuralProjectRecords" >
@@ -182,8 +213,12 @@
 		o.top_company AS "office.name",
 		ifnull(prd.number ,"") as "projectReportNumber"
 		,ifnull(prd.status,0) as "projectReportStatus"
+		,ifnull(prr.status,0) as "projectReportRecordStatus",
+        prr.record_num as recodeNum,
+		prr.process_instance_id as prrProcessInstanceId
+		,prr.id as prrId
 		FROM rural_project_records a
-		<include refid="projectRecordsJoins"/>
+		LEFT JOIN sys_area area ON area.id = a.area_id
 
         <if test="leaderNameStr !=null and leaderNameStr !=''">
             LEFT JOIN work_project_user w on a.id = w.project_id
@@ -194,6 +229,7 @@
 		LEFT JOIN work_client_info wct on wci.client_id = wct.id
         LEFT JOIN sys_office o ON o.id = a.office_id
 		left join project_report_data prd on prd.project_id = a.id
+		left join rural_project_report_record prr on prr.report_id = prd.id
 		<where>
 			a.status = 5
 			<if test="projectId != null and projectId != ''">
@@ -250,6 +286,17 @@
             <if test="endDate !=null">
                 AND a.create_date &lt; #{endDate}
             </if>
+
+
+			<if test="projectReportStatus != null and projectReportStatus != ''">
+				AND prd.status = #{projectReportStatus}
+			</if>
+
+			<if test="projectReportRecordStatus != null and projectReportRecordStatus != ''">
+				AND prr.status = #{projectReportRecordStatus}
+			</if>
+
+
             AND  a.status != 7 AND a.del_flag = #{DEL_FLAG_NORMAL}
             <if test="sqlMap.dsf !=null and sqlMap.dsf!=''">
                AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id} )${sqlMap.dsf} )
@@ -268,6 +315,7 @@
     <select id="queryCount" resultType="int" >
         SELECT count(DISTINCT a.id)
         FROM rural_project_records a
+
         <if test="leaderNameStr !=null and leaderNameStr !=''">
             LEFT JOIN work_project_user w on a.id = w.project_id
             LEFT JOIN sys_user su on w.user_id = su.id
@@ -279,6 +327,8 @@
         <if test="workContractInfo!=null and workContractInfo.client !=null and workContractInfo.client.name !=null and workContractInfo.client.name !=''">
             LEFT JOIN work_client_info wct on wci.client_id = wct.id
         </if>
+		left join project_report_data prd on prd.project_id = a.id
+		left join rural_project_report_record prr on prr.report_id = prd.id
         <where>
             a.status = 5
             <if test="projectId != null and projectId != ''">
@@ -335,6 +385,14 @@
             <if test="endDate !=null">
                 AND a.create_date &lt; #{endDate}
             </if>
+
+			<if test="projectReportStatus != null and projectReportStatus != ''">
+				AND prd.status = #{projectReportStatus}
+			</if>
+
+			<if test="projectReportRecordStatus != null and projectReportRecordStatus != ''">
+				AND prr.status = #{projectReportRecordStatus}
+			</if>
             AND  a.status != 7 AND a.del_flag = #{DEL_FLAG_NORMAL}
             <if test="sqlMap.dsf !=null and sqlMap.dsf!=''">
                 AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id})${sqlMap.dsf} )
@@ -746,4 +804,97 @@
 			</otherwise>
 		</choose>
 	</select>
+
+
+
+
+
+
+
+	<insert id="insertProjectReportRecord">
+		INSERT INTO rural_project_report_record(
+		id,
+		create_by,
+		create_date,
+		update_by,
+		update_date,
+		remarks,
+		del_flag,
+		report_id,
+		company_id,
+		office_id,
+		record_num,
+		file_num,
+		name,
+		record_date,
+		status,
+		number_count,
+		sign_cost_one,
+		sign_cost_two,
+		process_instance_id
+		) VALUES (
+		#{id},
+		#{createBy.id},
+		#{createDate},
+		#{updateBy.id},
+		#{updateDate},
+		#{remarks},
+		#{delFlag},
+		#{report.id},
+		#{companyId},
+		#{officeId},
+		#{recordNum},
+		#{fileNum},
+		#{name},
+		#{recordDate},
+		#{status},
+		#{numberCount},
+		#{signCostOne.id},
+		#{signCostTwo.id},
+		#{processInstanceId}
+		)
+	</insert>
+
+	<update id="updateProjectReportRecord">
+		UPDATE rural_project_report_record SET
+		update_by = #{updateBy.id},
+		update_date = #{updateDate},
+		remarks = #{remarks},
+		report_id = #{report.id},
+		company_id = #{companyId},
+		office_id = #{officeId},
+		record_num = #{recordNum},
+		file_num = #{fileNum},
+		name = #{name},
+		record_date = #{recordDate},
+		status = #{status},
+		number_count = #{numberCount},
+		sign_cost_one = #{signCostOne.id},
+		sign_cost_two = #{signCostTwo.id},
+		process_instance_id = #{processInstanceId}
+		WHERE id = #{id}
+	</update>
+
+	<update id="updateProcessInstanceId">
+		UPDATE rural_project_report_record SET
+		process_instance_id = #{processInstanceId}
+		WHERE id = #{id}
+	</update>
+
+	<select id="getProjectReportRecord" resultType="ProjectReportRecord" >
+		SELECT
+		<include refid="projectReportRecordColumns"/>,
+		wci.contract_num AS "contractNum",
+		wci.name AS "contractName",
+		wct.name AS "clientName",
+		d.report_date AS "report.reportDate",
+		r.project_name AS "projectName",
+		r.project_id AS "projectNum"
+		FROM rural_project_report_record a
+		<include refid="projectReportRecordJoins"/>
+		LEFT JOIN project_records r ON r.id = d.project_id
+		LEFT JOIN work_contract_info wci on r.contract_id = wci.id
+		LEFT JOIN work_client_info wct on wci.client_id = wct.id
+		WHERE a.report_id = #{reportId}
+	</select>
 </mapper>

+ 13 - 5
src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordAudit.jsp

@@ -45,6 +45,7 @@
 	<div class="container">
 		<form:form id="inputForm" modelAttribute="projectReportRecord" action="${ctx}/projectcontentinfo/projectReportRecord/auditSave" method="post" class="form-horizontal">
 		<form:hidden path="id"/>
+		<form:hidden path="type"/>
 		<form:hidden path="home"/>
 		<form:hidden path="numberCount"/>
 		<form:hidden id="reportId" path="report.id"/>
@@ -147,23 +148,30 @@
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label">档案号:</label>
+					<label class="layui-form-label"><span class="require-item">*</span>档案号:</label>
 					<div class="layui-input-block">
-						<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.fileNum}"/>
+						<input htmlEscape="false" name="fileNum"  class="form-control required layui-input" value="${projectReportRecord.fileNum}"/>
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label">档案名称:</label>
+					<label class="layui-form-label"><span class="require-item">*</span>档案名称:</label>
 					<div class="layui-input-block">
-						<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.name}"/>
+						<input htmlEscape="false" name="name"  class="form-control required layui-input" value="${projectReportRecord.name}"/>
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label">归档时间:</label>
+					<label class="layui-form-label">提交归档时间:</label>
 					<div class="layui-input-block">
 						<input id="recordDate" name="recordDate"  htmlEscape="false" readonly="true" class="form-control  layui-input" value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
 					</div>
 				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">归档完成日期:</label>
+					<div class="layui-input-block">
+						<input id="accomplishDate" name="accomplishDate"  htmlEscape="false" readonly="true" class="form-control  layui-input"
+							   value="<fmt:formatDate value="${projectReportRecord.accomplishDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
+					</div>
+				</div>
 				<div class="layui-item layui-col-sm12  with-textarea">
 					<label class="layui-form-label">说明:</label>
 					<div class="layui-input-block">

+ 18 - 11
src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordForm.jsp

@@ -192,23 +192,30 @@
 							   value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
 					</div>
 				</div>
+					<%--<div class="layui-item layui-col-sm6">
+                        <label class="layui-form-label">档案号:</label>
+                        <div class="layui-input-block">
+                            <form:input path="fileNum" htmlEscape="false"    class="form-control  layui-input"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6">
+                        <label class="layui-form-label">档案名称:</label>
+                        <div class="layui-input-block">
+                            <form:input path="name" htmlEscape="false"    class="form-control  layui-input"/>
+                        </div>
+                    </div>--%>
 				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label">档案号:</label>
+					<label class="layui-form-label">提交归档时间:</label>
 					<div class="layui-input-block">
-						<form:input path="fileNum" htmlEscape="false"    class="form-control  layui-input"/>
-					</div>
-				</div>
-				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label">档案名称:</label>
-					<div class="layui-input-block">
-						<form:input path="name" htmlEscape="false"    class="form-control  layui-input"/>
+						<input id="recordDate" name="recordDate"  htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date required layui-input laydate-icon"
+							   value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label">归档时间:</label>
+					<label class="layui-form-label">归档完成日期:</label>
 					<div class="layui-input-block">
-						<input id="recordDate" name="recordDate"  htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date required layui-input laydate-icon"
-							   value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
+						<input id="accomplishDate" name="accomplishDate"  htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date layui-input laydate-icon"
+							   value="<fmt:formatDate value="${projectReportRecord.accomplishDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm12  with-textarea">

+ 2 - 0
src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordModifyApply.jsp

@@ -54,6 +54,7 @@
 
         function setValuee(obj){
             $("#reportId").val(obj.id);
+            $("#type").val(obj.type);
             $("#reportnumber").val(obj.number);
             $("#reportName").val(obj.name);
             $("#reportDate").val(obj.reportDate);
@@ -82,6 +83,7 @@
 	<div class="container">
 		<form:form id="inputForm" modelAttribute="projectReportRecord" action="${ctx}/projectcontentinfo/projectReportRecord/auditSave" method="post" class="form-horizontal">
 			<form:hidden path="id"/>
+			<form:hidden path="type"/>
 			<form:hidden path="home"/>
 			<form:hidden path="numberCount"/>
 			<form:hidden id="reportId" path="report.id"/>

+ 7 - 1
src/main/webapp/webpage/modules/projectcontentinfo/projectReportRecordView.jsp

@@ -114,11 +114,17 @@
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label">归档时间:</label>
+				<label class="layui-form-label">提交归档时间:</label>
 				<div class="layui-input-block">
 					<input id="recordDate" name="recordDate"  htmlEscape="false" readonly="true" class="form-control  layui-input" value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
 				</div>
 			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">归档完成日期:</label>
+				<div class="layui-input-block">
+					<input id="accomplishDate" name="accomplishDate"  htmlEscape="false" readonly="true" class="form-control  layui-input" value="<fmt:formatDate value="${projectReportRecord.accomplishDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
+				</div>
+			</div>
 			<div class="layui-item layui-col-sm12  with-textarea">
 				<label class="layui-form-label">说明:</label>
 				<div class="layui-input-block">

+ 265 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/projectReportRecord/projectReportRecordForm.jsp

@@ -0,0 +1,265 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>合同归档管理</title>
+	<meta name="decorator" content="default"/>
+	<style>
+		label.error:nth-child(2){
+			top:40px;
+			left:0;
+		}
+	</style>
+	<script type="text/javascript">
+        var validateForm;
+        function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+                if(obj == 2){
+                    $("#inputForm").attr("action","${ctx}/projectcontentinfo/projectReportRecord/store");
+                }else{
+                    $("#inputForm").attr("action","${ctx}/ruralProject/ruralProjectMessage/saveRecord");
+                }
+                $("#inputForm").submit();
+                return true;
+            }else {
+                parent.layer.msg("信息未填写完整!", {icon: 5});
+            }
+            return false;
+
+        }
+        $(document).ready(function() {
+            validateForm = $("#inputForm").validate({
+                submitHandler: function(form){
+                    loading('正在提交,请稍等...');
+                    form.submit();
+                },
+                errorContainer: "#messageBox",
+                errorPlacement: function(error, element) {
+                    $("#messageBox").text("输入有误,请先更正。");
+                    if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
+                        error.appendTo(element.parent().parent());
+                    } else {
+                        error.insertAfter(element);
+                    }
+                }
+            });
+            $("#attachment_btn").click(function () {
+                $("#attachment_file").click();
+            });
+
+        });
+        function insertTitle(tValue){
+            var list = "${projectReportRecord.workAttachments}";
+            var size = (list.split('url')).length-1;
+            var files = $("#attachment_file")[0].files;            for(var i = 0;i<files.length;i++) {                var file = files[i];
+            var attachmentId = "";
+            var attachmentFlag = "99";
+            console.log(file);
+            var timestamp=new Date().getTime();
+
+            var storeAs = "attachment-file/workContractRd/"+timestamp+"/"+file['name'];
+            var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+            var divId = "_attachment";
+            $("#addFile"+divId).show();
+            multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,size);}
+        }
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="projectReportRecord" method="post" class="form-horizontal">
+			<form:hidden path="id"/>
+			<form:hidden path="numberCount"/>
+			<form:hidden id="reportId" path="report.id"/>
+
+			<div class="form-group layui-row first lw12">
+				<div class="form-group-label"><h2>基本信息</h2></div>
+
+
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>报告编号:</label>
+					<div class="layui-input-block">
+						<form:input id="reportNumber" path="report.number" htmlEscape="false"   readonly="true" class="form-control layui-input required"/>
+					</div>
+				</div>
+
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>归档申请编号:</label>
+					<div class="layui-input-block">
+						<input id="recordNum" name="recordNum"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="${projectReportRecord.recordNum}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>签字造价师一:</label>
+					<div class="layui-input-block with-icon">
+						<sys:treeselect id="signCostOne" name="signCostOne.id" value="${projectReportRecord.signCostOne.id}" labelName="signCostOne.name" labelValue="${projectReportRecord.signCostOne.name}"
+										title="签字造价师一" url="/sys/office/treeDataAll?type=3" cssClass="form-control layui-input required" allowClear="true" notAllowSelectParent="true"/></div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>签字造价师二:</label>
+					<div class="layui-input-block with-icon">
+						<sys:treeselect id="signCostTwo" name="signCostTwo.id" value="${projectReportRecord.signCostTwo.id}" labelName="signCostTwo.name" labelValue="${projectReportRecord.signCostTwo.name}"
+										title="签字造价师二" url="/sys/office/treeDataAll?type=3" cssClass="form-control layui-input required" allowClear="true" notAllowSelectParent="true"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>报告名称:</label>
+					<div class="layui-input-block">
+						<form:input id="reportName" path="report.name" htmlEscape="false"   readonly="true" class="form-control layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>报告日期:</label>
+					<div class="layui-input-block">
+						<input id="reportDate" name="report.reportDate"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="<fmt:formatDate value="${projectReportRecord.report.reportDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>合同编号:</label>
+					<div class="layui-input-block">
+						<input id="contractNum" name="contractNum"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="${projectReportRecord.report.project.workContractInfo.contractNum}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>合同名称:</label>
+					<div class="layui-input-block">
+						<input id="contractName" name="contractName"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="${projectReportRecord.report.project.workContractInfo.name}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>主委托方:</label>
+					<div class="layui-input-block">
+						<input id="clientName" name="clientName"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="${workClientInfoName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">项目编号:</label>
+					<div class="layui-input-block">
+						<input id="projectNum" name="projectNum"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="${projectReportRecord.report.project.projectId}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>项目名称:</label>
+					<div class="layui-input-block">
+						<input id="projectName" name="projectName"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="${projectReportRecord.report.project.projectName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>归档申请人:</label>
+					<div class="layui-input-block">
+						<form:input id="cBName" path="createBy.name" htmlEscape="false" readonly="true" class="form-control  layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>申请日期:</label>
+					<div class="layui-input-block">
+						<input id="createDate" name="createDate"  htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date required layui-input laydate-icon"
+							   value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+					<%--<div class="layui-item layui-col-sm6">
+                        <label class="layui-form-label">档案号:</label>
+                        <div class="layui-input-block">
+                            <form:input path="fileNum" htmlEscape="false"    class="form-control  layui-input"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6">
+                        <label class="layui-form-label">档案名称:</label>
+                        <div class="layui-input-block">
+                            <form:input path="name" htmlEscape="false"    class="form-control  layui-input"/>
+                        </div>
+                    </div>--%>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">提交归档时间:</label>
+					<div class="layui-input-block">
+						<input id="recordDate" name="recordDate"  htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date required layui-input laydate-icon"
+							   value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">归档完成日期:</label>
+					<div class="layui-input-block">
+						<input id="accomplishDate" name="accomplishDate"  htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date layui-input laydate-icon"
+							   value="<fmt:formatDate value="${projectReportRecord.accomplishDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm12  with-textarea">
+					<label class="layui-form-label">说明:</label>
+					<div class="layui-input-block">
+						<form:textarea path="remarks" htmlEscape="false" rows="4"    class="form-control "/>
+					</div>
+				</div>
+			</div>
+			<div class="form-group layui-row">
+				<div class="form-group-label"><h2>附件信息</h2></div>
+				<div class="layui-item nav-btns">
+					<a id="attachment_btn" class="nav-btn nav-btn-add" title="添加附件"><i class="fa fa-plus"></i>&nbsp;添加附件</a>
+				</div>
+				<div id="addFile_attachment" style="display: none" class="upload-progress">
+					<span id="fileName_attachment" ></span>
+					<b><span id="baifenbi_attachment" ></span></b>
+					<div class="progress">
+						<div id="jindutiao_attachment" class="progress-bar" style="width: 0%" aria-valuenow="0">
+						</div>
+					</div>
+				</div>
+				<input id="attachment_file" type="file" name="attachment_file" multiple="multiple" style="display: none;" onChange="if(this.value)insertTitle(this.value);"/>
+				<span id="attachment_title"></span>
+				<div class="layui-item layui-col-xs12" style="padding:0 16px;">
+					<table id="upTable" class="table table-bordered table-condensed details">
+						<thead>
+						<tr>
+								<%-- <th>序号</th>--%>
+							<th>文件预览</th>
+							<th>上传人</th>
+							<th>上传时间</th>
+							<th width="150px">操作</th>
+						</tr>
+						</thead>
+						<tbody id="file_attachment">
+						<c:forEach items="${projectReportRecord.workAttachments}" var = "workClientAttachment" varStatus="status">
+							<tr>
+									<%-- <td>${status.index + 1}</td>--%>
+								<c:choose>
+									<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+										<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+									</c:when>
+									<c:otherwise>
+										<c:choose>
+											<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+											</c:when>
+											<c:otherwise>
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%')">${workClientAttachment.attachmentName}</a></td>
+											</c:otherwise>
+										</c:choose>
+									</c:otherwise>
+								</c:choose>
+								<td>${workClientAttachment.createBy.name}</td>
+								<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+								<td class="op-td">
+									<div class="op-btn-box" >
+										<a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+
+										<c:if test="${workClientAttachment.createBy.id eq fns:getUser().id}">
+											<a href="javascript:void(0)" onclick="deleteFileFromAliyun(this,'${ctx}/sys/workattachment/deleteFileFromAliyun?url=${workClientAttachment.url}&id=${workClientAttachment.id}&type=2','addFile')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>
+										</c:if>
+									</div>
+								</td>
+							</tr>
+						</c:forEach>
+						</tbody>
+					</table>
+				</div>
+			</div>
+			<div class="form-group layui-row page-end"></div>
+		</form:form>
+	</div>
+</div>
+</body>
+</html>

+ 297 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/projectReportRecord/projectReportRecordModify.jsp

@@ -0,0 +1,297 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>合同归档管理</title>
+	<meta name="decorator" content="default"/>
+	<style>
+		label.error:nth-child(2){
+			top:40px;
+			left:0;
+		}
+	</style>
+	<script type="text/javascript">
+        var validateForm;
+        function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+                if(obj == 2){
+                    $("#inputForm").attr("action","${ctx}/projectcontentinfo/projectReportRecord/store");
+                }else{
+                    $("#inputForm").attr("action","${ctx}/ruralProject/ruralProjectMessage/saveRecord");
+                }
+                $("#inputForm").submit();
+                return true;
+            }else {
+                parent.layer.msg("信息未填写完整!", {icon: 5});
+            }
+            return false;
+
+        }
+        $(document).ready(function() {
+            validateForm = $("#inputForm").validate({
+                submitHandler: function(form){
+                    loading('正在提交,请稍等...');
+                    form.submit();
+                },
+                errorContainer: "#messageBox",
+                errorPlacement: function(error, element) {
+                    $("#messageBox").text("输入有误,请先更正。");
+                    if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
+                        error.appendTo(element.parent().parent());
+                    } else {
+                        error.insertAfter(element);
+                    }
+                }
+            });
+            $("#attachment_btn").click(function () {
+                $("#attachment_file").click();
+            });
+
+        });
+        function insertTitle(tValue){
+            var list = "${projectReportRecord.workAttachments}";
+            var size = (list.split('url')).length-1;
+            var files = $("#attachment_file")[0].files;            for(var i = 0;i<files.length;i++) {                var file = files[i];
+            var attachmentId = "";
+            var attachmentFlag = "99";
+            console.log(file);
+            var timestamp=new Date().getTime();
+
+            var storeAs = "attachment-file/workContractRd/"+timestamp+"/"+file['name'];
+            var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+            var divId = "_attachment";
+            $("#addFile"+divId).show();
+            multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,size);}
+        }
+
+        function setValuee(obj){
+            $("#reportId").val(obj.id);
+            $("#reportnumber").val(obj.number);
+            $("#reportName").val(obj.name);
+            $("#reportDate").val(obj.reportDate);
+            $("#contractNum").val(obj.contractNum);
+            $("#contractName").val(obj.contractName);
+            $("#clientName").val(obj.clientName);
+            $("#projectName").val(obj.projectName);
+            $("#projectNum").val(obj.projectNum);
+            $.ajax({
+                type:'post',
+                url:'${ctx}/projectcontentinfo/projectReportRecord/getNumber',
+                data:{
+                    "reportId":obj.id
+                },
+                success:function(data){
+                    var numberCount = data.numberCount;
+                    $("#recordNum").val(obj.number+"-"+numberCount);
+                    $("#numberCount").val(numberCount);
+                }
+            })
+        }
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="projectReportRecord" method="post" class="form-horizontal">
+			<form:hidden path="id"/>
+			<form:hidden path="view"/>
+			<form:hidden path="numberCount"/>
+			<form:hidden id="reportId" path="report.id"/>
+
+			<div class="form-group layui-row first lw12">
+				<div class="form-group-label"><h2>基本信息</h2></div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>报告编号:</label>
+					<div class="layui-input-block">
+						<form:input id="reportNumber" path="report.number" htmlEscape="false"   readonly="true" class="form-control layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>归档申请编号:</label>
+					<div class="layui-input-block">
+						<div class="input-group">
+							<form:input id="recordNum" path="recordNum" htmlEscape="false"   readonly="true" class="form-control layui-input required"/>
+							<span class="input-group-btn">
+								<label class="form-status">
+									<c:choose>
+										<c:when test="${not empty projectReportRecord.status}">${fns:getDictLabel(projectReportRecord.status, 'audit_record_state', '')}
+										</c:when>
+										<c:otherwise>新添</c:otherwise>
+									</c:choose></label>
+							 </span>
+						</div>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>签字造价师一:</label>
+					<div class="layui-input-block with-icon">
+						<sys:treeselect id="signCostOne" name="signCostOne.id" value="${projectReportRecord.signCostOne.id}" labelName="signCostOne.name" labelValue="${projectReportRecord.signCostOne.name}"
+										title="签字造价师一" url="/sys/office/treeDataAll?type=3" cssClass="form-control layui-input required" allowClear="true" notAllowSelectParent="true"/></div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>签字造价师二:</label>
+					<div class="layui-input-block with-icon">
+						<sys:treeselect id="signCostTwo" name="signCostTwo.id" value="${projectReportRecord.signCostTwo.id}" labelName="signCostTwo.name" labelValue="${projectReportRecord.signCostTwo.name}"
+										title="签字造价师二" url="/sys/office/treeDataAll?type=3" cssClass="form-control layui-input required" allowClear="true" notAllowSelectParent="true"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>报告名称:</label>
+					<div class="layui-input-block">
+						<form:input id="reportName" path="report.name" htmlEscape="false"   readonly="true" class="form-control layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>报告日期:</label>
+					<div class="layui-input-block">
+						<input id="reportDate" name="report.reportDate"  htmlEscape="false" readonly="true" class="form-control  layui-input required" value="<fmt:formatDate value="${projectReportRecord.report.reportDate}" pattern="yyyy-MM-dd"/>"/>
+							<%--<input class="laydate-icondate form-control layui-input layer-date laydate-icon" id="createDate" name="createDate" value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>">--%>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>合同编号:</label>
+					<div class="layui-input-block">
+						<form:input id="contractNum" path="contractNum" htmlEscape="false" readonly="true" class="form-control  layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>合同名称:</label>
+					<div class="layui-input-block">
+						<form:input id="contractName" path="contractName" htmlEscape="false" readonly="true" class="form-control  layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>主委托方:</label>
+					<div class="layui-input-block">
+						<form:input id="clientName" path="clientName" htmlEscape="false" readonly="true" class="form-control  layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">项目编号:</label>
+					<div class="layui-input-block">
+						<form:input id="projectNum" path="projectNum" htmlEscape="false" readonly="true" class="form-control  layui-input"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>项目名称:</label>
+					<div class="layui-input-block">
+						<form:input id="projectName" path="projectName" htmlEscape="false" readonly="true" class="form-control  layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>归档申请人:</label>
+					<div class="layui-input-block">
+						<form:input id="cBName" path="createBy.name" htmlEscape="false" readonly="true" class="form-control  layui-input required"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item">*</span>申请日期:</label>
+					<div class="layui-input-block">
+						<input id="createDate" name="createDate"  htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date required layui-input laydate-icon"
+							   value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+					<%--<div class="layui-item layui-col-sm6">
+                        <label class="layui-form-label">档案号:</label>
+                        <div class="layui-input-block">
+                            <form:input path="fileNum" htmlEscape="false"    class="form-control  layui-input"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6">
+                        <label class="layui-form-label">档案名称:</label>
+                        <div class="layui-input-block">
+                            <form:input path="name" htmlEscape="false"    class="form-control  layui-input"/>
+                        </div>
+                    </div>--%>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">提交归档时间:</label>
+					<div class="layui-input-block">
+						<input id="recordDate" name="recordDate"  htmlEscape="false" readonly="true" class="form-control  layui-input" value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">归档完成日期:</label>
+					<div class="layui-input-block">
+						<input id="accomplishDate" name="accomplishDate"  htmlEscape="false" readonly="true" class="form-control  layui-input"
+							   value="<fmt:formatDate value="${projectReportRecord.accomplishDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm12  with-textarea">
+					<label class="layui-form-label">说明:</label>
+					<div class="layui-input-block">
+						<form:textarea path="remarks" htmlEscape="false" rows="4"    class="form-control "/>
+					</div>
+				</div>
+			</div>
+			<div class="form-group layui-row">
+				<div class="form-group-label"><h2>附件信息</h2></div>
+				<div class="layui-item nav-btns">
+					<a id="attachment_btn" class="nav-btn nav-btn-add" title="添加附件"><i class="fa fa-plus"></i>&nbsp;添加附件</a>
+				</div>
+				<div id="addFile_attachment" style="display: none" class="upload-progress">
+					<span id="fileName_attachment" ></span>
+					<b><span id="baifenbi_attachment" ></span></b>
+					<div class="progress">
+						<div id="jindutiao_attachment" class="progress-bar" style="width: 0%" aria-valuenow="0">
+						</div>
+					</div>
+				</div>
+				<input id="attachment_file" type="file" name="attachment_file" multiple="multiple" style="display: none;" onChange="if(this.value)insertTitle(this.value);"/>
+				<span id="attachment_title"></span>
+				<div class="layui-item layui-col-xs12" style="padding:0 16px;">
+					<table id="upTable" class="table table-bordered table-condensed details">
+						<thead>
+						<tr>
+								<%-- <th>序号</th>--%>
+							<th>文件预览</th>
+							<th>上传人</th>
+							<th>上传时间</th>
+							<th width="150px">操作</th>
+						</tr>
+						</thead>
+						<tbody id="file_attachment">
+						<c:forEach items="${projectReportRecord.workAttachments}" var = "workClientAttachment" varStatus="status">
+							<tr>
+									<%-- <td>${status.index + 1}</td>--%>
+								<c:choose>
+									<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+										<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+									</c:when>
+									<c:otherwise>
+										<c:choose>
+											<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+											</c:when>
+											<c:otherwise>
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%')">${workClientAttachment.attachmentName}</a></td>
+											</c:otherwise>
+										</c:choose>
+									</c:otherwise>
+								</c:choose>
+								<td>${workClientAttachment.createBy.name}</td>
+								<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+								<td class="op-td">
+									<div class="op-btn-box" >
+										<a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+
+										<c:if test="${workClientAttachment.createBy.id eq fns:getUser().id}">
+											<a href="javascript:void(0)" onclick="deleteFileFromAliyun(this,'${ctx}/sys/workattachment/deleteFileFromAliyun?url=${workClientAttachment.url}&id=${workClientAttachment.id}&type=2','addFile')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>
+										</c:if>
+									</div>
+								</td>
+							</tr>
+						</c:forEach>
+						</tbody>
+					</table>
+				</div>
+			</div>
+			<div class="form-group layui-row page-end"></div>
+		</form:form>
+	</div>
+</div>
+</body>
+</html>

+ 189 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/projectReportRecord/projectReportRecordView.jsp

@@ -0,0 +1,189 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>合同归档管理</title>
+	<meta name="decorator" content="default"/>
+	<script type="text/javascript">
+
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container view-form">
+		<div class="form-group layui-row first lw9">
+			<div class="form-group-label"><h2>基本信息</h2></div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报告编号:</label>
+				<div class="layui-input-block with-icon">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.report.number}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">归档申请编号:</label>
+				<div class="layui-input-block">
+					<div class="input-group">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.recordNum}"/>
+						<span class="input-group-btn">
+								<label class="form-status">
+									<c:choose>
+										<c:when test="${not empty projectReportRecord.status}">${fns:getDictLabel(projectReportRecord.status, 'audit_record_state', '')}
+										</c:when>
+										<c:otherwise>新添</c:otherwise>
+									</c:choose></label>
+							 </span>
+					</div>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">签字造价师一:</label>
+				<div class="layui-input-block">
+					<input  htmlEscape="false" readonly="true" class="form-control  layui-input" value="${projectReportRecord.signCostOne.name}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">签字造价师二:</label>
+				<div class="layui-input-block">
+					<input  htmlEscape="false" readonly="true" class="form-control  layui-input" value="${projectReportRecord.signCostTwo.name}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报告名称:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.report.name}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报告日期:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${projectReportRecord.report.reportDate}" pattern="yyyy-MM-dd"/>"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">合同编号:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.report.project.workContractInfo.contractNum}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">合同名称:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.report.project.workContractInfo.name}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">主委托方:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workClientInfoName}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">项目编号:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.report.project.projectId}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">项目名称:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.report.project.projectName}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">归档申请人:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.createBy.name}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">申请日期:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">档案号:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.fileNum}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">档案名称:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectReportRecord.name}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">提交归档时间:</label>
+				<div class="layui-input-block">
+					<input id="recordDate" name="recordDate"  htmlEscape="false" readonly="true" class="form-control  layui-input" value="<fmt:formatDate value="${projectReportRecord.createDate}" pattern="yyyy-MM-dd"/>"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">归档完成日期:</label>
+				<div class="layui-input-block">
+					<input id="accomplishDate" name="accomplishDate"  htmlEscape="false" readonly="true" class="form-control  layui-input" value="<fmt:formatDate value="${projectReportRecord.accomplishDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm12  with-textarea">
+				<label class="layui-form-label">说明:</label>
+				<div class="layui-input-block">
+					<textarea path="remarks" htmlEscape="false" readonly="true" rows="3" maxlength="20" class="form-control" >${projectReportRecord.remarks}</textarea>
+				</div>
+			</div>
+		</div>
+		<div class="form-group layui-row">
+			<div class="form-group-label"><h2>附件信息</h2></div>
+			<span id="attachment_title"></span>
+			<div class="layui-item layui-col-xs12" style="padding:0 16px;">
+				<table id="upTable" class="table table-bordered table-condensed details">
+					<thead>
+					<tr>
+						<%-- <th>序号</th>--%>
+						<th>文件预览</th>
+						<th>上传人</th>
+						<th>上传时间</th>
+						<th width="150px">操作</th>
+					</tr>
+					</thead>
+					<tbody id="file_attachment">
+					<c:forEach items="${projectReportRecord.workAttachments}" var = "workClientAttachment" varStatus="status">
+						<tr>
+								<%-- <td>${status.index + 1}</td>--%>
+							<c:choose>
+								<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+									<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+								</c:when>
+								<c:otherwise>
+									<c:choose>
+										<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+											<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+										</c:when>
+										<c:otherwise>
+											<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%')">${workClientAttachment.attachmentName}</a></td>
+										</c:otherwise>
+									</c:choose>
+								</c:otherwise>
+							</c:choose>
+							<td>${workClientAttachment.createBy.name}</td>
+							<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+							<td class="op-td">
+								<div class="op-btn-box" >
+									<a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+								</div>
+							</td>
+						</tr>
+					</c:forEach>
+					</tbody>
+				</table>
+			</div>
+		</div>
+			<div class="form-group layui-row page-end"></div>
+	</div>
+</div>
+</body>
+</html>

+ 3 - 3
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/projectcontentinfo/reportForm.jsp

@@ -74,7 +74,7 @@
                 console.log(file);
                 var timestamp = new Date().getTime();
 
-                var storeAs = "attachment-file/basedData/" + timestamp + "/" + file['name'];
+                var storeAs = "newxgccpm-test/attachment-file/basedData/" + timestamp + "/" + file['name'];
                 var uploadPath = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/" + storeAs;
                 /*将这段字符串存到数据库即可*/
                 var divId = "_attachment";
@@ -92,7 +92,7 @@
                 console.log(file);
                 var timestamp = new Date().getTime();
 
-                var storeAs = "attachment-file/basedData/" + timestamp + "/" + file['name'];
+                var storeAs = "newxgccpm-test/attachment-file/basedData/" + timestamp + "/" + file['name'];
                 var uploadPath = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/" + storeAs;
                 /*将这段字符串存到数据库即可*/
                 var divId = "_gistdata";
@@ -110,7 +110,7 @@
                 console.log(file);
                 var timestamp = new Date().getTime();
 
-                var storeAs = "attachment-file/basedData/" + timestamp + "/" + file['name'];
+                var storeAs = "newxgccpm-test/attachment-file/basedData/" + timestamp + "/" + file['name'];
                 var uploadPath = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/" + storeAs;
                 /*将这段字符串存到数据库即可*/
                 var divId = "_other";

+ 3 - 3
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/projectcontentinfo/reportModify.jsp

@@ -74,7 +74,7 @@
                 console.log(file);
                 var timestamp = new Date().getTime();
 
-                var storeAs = "attachment-file/basedData/" + timestamp + "/" + file['name'];
+                var storeAs = "newxgccpm-test/attachment-file/basedData/" + timestamp + "/" + file['name'];
                 var uploadPath = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/" + storeAs;
                 /*将这段字符串存到数据库即可*/
                 var divId = "_attachment";
@@ -92,7 +92,7 @@
                 console.log(file);
                 var timestamp = new Date().getTime();
 
-                var storeAs = "attachment-file/basedData/" + timestamp + "/" + file['name'];
+                var storeAs = "newxgccpm-test/attachment-file/basedData/" + timestamp + "/" + file['name'];
                 var uploadPath = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/" + storeAs;
                 /*将这段字符串存到数据库即可*/
                 var divId = "_gistdata";
@@ -110,7 +110,7 @@
                 console.log(file);
                 var timestamp = new Date().getTime();
 
-                var storeAs = "attachment-file/basedData/" + timestamp + "/" + file['name'];
+                var storeAs = "newxgccpm-test/attachment-file/basedData/" + timestamp + "/" + file['name'];
                 var uploadPath = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/" + storeAs;
                 /*将这段字符串存到数据库即可*/
                 var divId = "_other";

+ 155 - 249
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/projectcontentinfo/reportView.jsp

@@ -12,349 +12,254 @@
 <body>
 <div class="single-form">
 	<div class="container${container}  view-form">
+		<form:form id="inputForm" modelAttribute="projectcontentinfo" action="${ctx}/ruralProject/ruralProjectMessage/reportAudit" method="post" class="form-horizontal">
 		<div class="form-group layui-row first lw12">
 			<div class="form-group-label"><h2>基本信息</h2></div>
 			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label"><span class="require-item">*</span>报告名称:</label>
-				<div class="layui-input-block with-icon">
-					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectcontentinfo.projectReportData.name}"/>
-				</div>
-			</div>
-			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label"><span class="require-item">*</span>报告编号:</label>
-				<div class="layui-input-block">
-					<div class="input-group">
-					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectcontentinfo.projectReportData.number}"/>
-					<span class="input-group-btn">
-								<label class="form-status">
-									<c:choose>
-										<c:when test="${not empty projectcontentinfo.projectReportData.status}">${fns:getDictLabel(projectcontentinfo.projectReportData.status, 'audit_state', '')}
-										</c:when>
-										<c:otherwise>新添</c:otherwise>
-									</c:choose></label>
-							 </span>
-					</div>
-				</div>
-			</div>
-			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label"><span class="require-item">*</span>工作内容类型:</label>
-				<div class="layui-input-block">
-					<input  htmlEscape="false" readonly="true" class="form-control  layui-input" value="${fns:getContentTypeName(projectcontentinfo.projectReportData.type,"")}"/>
-				</div>
-			</div>
-			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label">成果类型:</label>
-				<div class="layui-input-block">
-					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${fns:getMainDictLabel(projectcontentinfo.projectReportData.achievementType, 'achievement_type', '')}"/>
-				</div>
-			</div>
-			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label">复核标准:</label>
-				<div class="layui-input-block">
-					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${fns:getDictLabel(projectcontentinfo.projectReportData.reviewStandard, 'reviewStandard', '')}"/>
-				</div>
-			</div>
-			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label">报告日期:</label>
-				<div class="layui-input-block">
-					<input id="provideDate" name="projectReportData.provideDate" type="text" htmlEscape="false" readonly="true" class="laydate-icondate form-control layer-date required layui-input laydate-icon"
-						   value="<fmt:formatDate value="${projectcontentinfo.projectReportData.reportDate}" pattern="yyyy-MM-dd"/>"/>
-				</div>
-			</div>
-			<%--<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label">签字造价师一:</label>
+				<label class="layui-form-label"><span class="require-item">*</span>成果类型:</label>
 				<div class="layui-input-block">
-					<input  htmlEscape="false" readonly="true" class="form-control  layui-input" value="${projectcontentinfo.projectReportData.signCostOne.name}"/>
+					<form:input path="projectReportData.achievementType" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label">签字造价师二:</label>
-				<div class="layui-input-block">
-					<input  htmlEscape="false" readonly="true" class="form-control  layui-input" value="${projectcontentinfo.projectReportData.signCostTwo.name}"/>
-				</div>
-			</div>--%>
-			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">签章类型:</label>
 				<div class="layui-input-block">
-					<input  htmlEscape="false" readonly="true" class="form-control  layui-input" value="${projectcontentinfo.projectReportData.reportType}"/>
+					<form:input path="projectReportData.ReportType" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
-			<div class="layui-item layui-col-sm6">
-				<label class="layui-form-label">归档状态:</label>
-				<div class="layui-input-block">
-					<input  htmlEscape="false" readonly="true" class="form-control  layui-input" value="${fns:getDictLabel(projectcontentinfo.projectReportData.fileStatus, 'record_state', '')}"/>
-				</div>
-			</div>
-			<c:if test="${not empty projectcontentinfo.projectReportData.invalidStatus}">
-				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label">作废原因:</label>
-					<div class="layui-input-block">
-						<textarea path="remarks" htmlEscape="false" readonly="true" rows="3" maxlength="20" class="form-control" >${projectcontentinfo.projectReportData.remarks}</textarea>
-					</div>
-				</div>
-			</c:if>
 		</div>
 		<div class="form-group layui-row first lw12">
 			<div class="form-group-label"><h2>项目信息</h2></div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">送审价(元):</label>
 				<div class="layui-input-block with-icon">
-					<input  id="projectReportData.reviewFee" readonly="true" class="form-control layui-input number" value="<fmt:formatNumber value="${projectcontentinfo.projectReportData.reviewFee}" pattern="#,##0.00#"/>" />
+					<form:input id="reviewFee" path="projectReportData.reviewFee" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">审定价(元):</label>
 				<div class="layui-input-block with-icon">
-					<input  id="projectReportData.approvalFee" readonly="true" class="form-control layui-input number" value="<fmt:formatNumber value="${projectcontentinfo.projectReportData.approvalFee}" pattern="#,##0.00#"/>" />
+					<form:input id="approvalFee" path="projectReportData.approvalFee" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">合同价(元):</label>
 				<div class="layui-input-block with-icon">
-					<input  id="projectReportData.contractFee"  readonly="true" class="form-control layui-input number" value="<fmt:formatNumber value="${projectcontentinfo.projectReportData.contractFee}" pattern="#,##0.00#"/>" />
+					<form:input id="contractFee" path="projectReportData.contractFee" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">核增核减额(元):</label>
 				<div class="layui-input-block with-icon">
-					<input id="projectReportData.verifyFee"  readonly="true" class="form-control layui-input number" value="<fmt:formatNumber value="${projectcontentinfo.projectReportData.verifyFee}" pattern="#,##0.00#"/>" />
+					<form:input id="verifyFee" path="projectReportData.verifyFee" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">核增核减率(%):</label>
 				<div class="layui-input-block with-icon">
-					<input  id="projectReportData.verifyRate"  readonly="true" class="form-control layui-input number" value="${projectcontentinfo.projectReportData.verifyRate}"/>
+					<form:input id="verifyRate" path="projectReportData.verifyRate" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">咨询标的额(元):</label>
 				<div class="layui-input-block with-icon">
-					<input  id="projectReportData.consultFee" readonly="true" class="form-control layui-input number" value="<fmt:formatNumber value="${projectcontentinfo.projectReportData.consultFee}" pattern="#,##0.00#"/>" />
+					<form:input id="consultFee" path="projectReportData.consultFee" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">土建造价(元):</label>
 				<div class="layui-input-block with-icon">
-					<input  id="projectReportData.buildingFee"  readonly="true" class="form-control layui-input number" value="<fmt:formatNumber value="${projectcontentinfo.projectReportData.buildingFee}" pattern="#,##0.00#"/>" />
+					<form:input id="buildingFee" path="projectReportData.buildingFee" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">安装造价(元):</label>
 				<div class="layui-input-block with-icon">
-					<input  id="projectReportData.installFee"  readonly="true" class="form-control layui-input number" value="<fmt:formatNumber value="${projectcontentinfo.projectReportData.installFee}" pattern="#,##0.00#"/>"/>
+					<form:input id="installFee" path="projectReportData.installFee" htmlEscape="false"  class="form-control layui-input" readonly="true"/>
 				</div>
 			</div>
 		</div>
-		<div class="form-group layui-row first lw12">
-			<div class="form-group-label"><h2>依据性资料明细</h2></div>
-			<div class="layui-item layui-col-xs12 form-table-container">
-				<table id="contentTableBase" class="table table-bordered table-condensed details">
+		<div class="form-group layui-row">
+			<div class="form-group-label"><h2>报告文件</h2></div>
+			<div id="addFile_attachment" style="display: none" class="upload-progress">
+				<span id="fileName_attachment" ></span>
+				<b><span id="baifenbi_attachment" ></span></b>
+				<div class="progress">
+					<div id="jindutiao_attachment" class="progress-bar" style="width: 0%" aria-valuenow="0">
+					</div>
+				</div>
+			</div>
+			<input id="attachment_file" type="file" name="attachment_file" multiple="multiple" style="display: none;" onChange="if(this.value)insertTitle(this.value);"/>
+			<span id="attachment_title"></span>
+			<div class="layui-item layui-col-xs12" style="padding:0 16px;">
+				<table id="upTable" class="table table-bordered table-condensed details">
 					<thead>
 					<tr>
-						<th class="hide"></th>
-						<th >资料编号</th>
-						<th >资料名称</th>
-						<th >资料类别</th>
-						<th >上传人</th>
-						<th >上传日期</th>
+						<th>文件预览</th>
+						<th>上传人</th>
+						<th>上传时间</th>
+						<th width="150px">操作</th>
 					</tr>
 					</thead>
-					<tbody id="workBaseDataList">
-					<c:forEach items="${projectcontentinfo.projectReportData.projectBasedDataList}" var="projectBasedData" varStatus="idx">
-						<tr>
-							<td class="hide">
-								<input type="hidden" id="workBaseDataList${idx.index}_id" value="${projectBasedData.id}">
-							</td>
-							<td style="text-align:center;">
-									${projectBasedData.number}
-							</td>
-							<td style="text-align:center;">
-									${projectBasedData.name}
-							</td>
-							<td style="text-align:center;">
-									${fns:getDictLabel(projectBasedData.type, 'project_document_type', '')}
-							</td>
-							<td style="text-align:center;">
-									${projectBasedData.uploadUser.name}
-							</td>
-							<td style="text-align:center;">
-								<fmt:formatDate value="${projectBasedData.uploadDate}" pattern="yyyy-MM-dd"/>
-							</td>
-						</tr>
+					<tbody id="file_attachment">
+					<c:forEach items="${projectcontentinfo.projectReportData.workAttachments}" var = "workClientAttachment" varStatus="status">
+						<c:if test="${workClientAttachment.divIdType eq '_attachment'}">
+							<tr>
+								<c:choose>
+									<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+										<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}"></td>
+									</c:when>
+									<c:otherwise>
+										<c:choose>
+											<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+											</c:when>
+											<c:otherwise>
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%')">${workClientAttachment.attachmentName}</a></td>
+											</c:otherwise>
+										</c:choose>
+									</c:otherwise>
+								</c:choose>
+								<td>${workClientAttachment.createBy.name}</td>
+								<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+								<td class="op-td">
+									<div class="op-btn-box" >
+										<a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+									</div>
+								</td>
+							</tr>
+						</c:if>
 					</c:forEach>
 					</tbody>
 				</table>
 			</div>
 		</div>
-		<div class="form-group layui-row first lw12">
-			<div class="form-group-label"><h2>依据工作内容</h2></div>
-			<!-- 表格 -->
-			<div class="layui-item layui-col-xs12" style="padding:0 16px;">
-			<table id="contentTable" class="table table-striped table-bordered table-hover table-condensed dataTables-example dataTable">
-				<thead>
-				<tr>
-					<th style="text-align: center;width:20%">工作内容编号</th>
-					<th style="text-align: center;width:20%">工作内容名称</th>
-					<th style="text-align: center;width:20%">工作内容类型</th>
-					<th style="text-align: center;width:20%">负责人</th>
-					<th style="text-align: center;width:20%">创建时间</th>
-				</tr>
-				</thead>
-				<tbody id="projectContentDataList">
-				<c:forEach items="${projectcontentinfo.projectReportData.projectContentDataList}" var="projectContentData" varStatus="index">
-					<tr>
-						<td style="text-align:center;">
-								${projectContentData.number}
-						</td>
-						<td style="text-align:center;">
-								${projectContentData.name}
-						</td>
-						<td style="text-align:center;">
-								${fns:getContentTypeName(projectContentData.type,"")}
-						</td>
-						<td style="text-align:center;">
-								${projectContentData.master.name}
-						</td>
-						<td style="text-align:center;">
-							<fmt:formatDate value="${projectContentData.createDate}" pattern="yyyy-MM-dd HH:mm:ss"/>
-						</td>
-					</tr>
-				</c:forEach>
-				</tbody>
-			</table>
-			</div>
-		</div>
+
 		<div class="form-group layui-row">
-			<div class="form-group-label"><h2>报告文件</h2></div>
+			<div class="form-group-label"><h2>依据性资料</h2></div>
+			<div id="addFile_gistdata" style="display: none" class="upload-progress">
+				<span id="fileName_gistdata" ></span>
+				<b><span id="baifenbi_gistdata" ></span></b>
+				<div class="progress">
+					<div id="jindutiao_gistdata" class="progress-bar" style="width: 0%" aria-valuenow="0">
+					</div>
+				</div>
+			</div>
+			<input id="gistdata_file" type="file" name="gistdata_file" multiple="multiple" style="display: none;" onChange="if(this.value)gistdataInsertTitle(this.value);"/>
+			<span id="gistdata_title"></span>
 			<div class="layui-item layui-col-xs12" style="padding:0 16px;">
-				<table id="upTable" class="table table-bordered table-condensed details">
+				<table id="gistdata_upTable" class="table table-bordered table-condensed details">
 					<thead>
 					<tr>
-						<%-- <th>序号</th>--%>
 						<th>文件预览</th>
 						<th>上传人</th>
 						<th>上传时间</th>
-						<th width="200px">操作</th>
+						<th width="150px">操作</th>
 					</tr>
 					</thead>
-					<tbody id="file_attachment">
+					<tbody id="file_gistdata">
 					<c:forEach items="${projectcontentinfo.projectReportData.workAttachments}" var = "workClientAttachment" varStatus="status">
-						<tr>
-								<%-- <td>${status.index + 1}</td>--%>
-							<c:choose>
-								<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
-									<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}"></td>
-								</c:when>
-								<c:otherwise>
-									<c:choose>
-										<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
-											<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
-										</c:when>
-										<c:otherwise>
-											<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%')">${workClientAttachment.attachmentName}</a></td>
-										</c:otherwise>
-									</c:choose>
-								</c:otherwise>
-							</c:choose>
-							<td>${workClientAttachment.createBy.name}</td>
-							<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
-							<td class="op-td">
-								<div class="op-btn-box" >
-                                    <c:set var="signflag" value="${fns:getSysParam('sign_flag',fns:getUser())}"/>
-                                    <c:choose>
-                                        <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'doc')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'docx')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'xls')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'xlsx')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'ppt')
-                                                           or fn:containsIgnoreCase(workClientAttachment.attachmentName,'pptx')}">
-                                            <c:if test="${not empty gzr && gzr eq 'gzr'}">
-                                                <a href="${ctx}/isignature/iSignatureDocument/sign?recordId=${workClientAttachment.id}&type=report" class="op-btn op-btn-sign" target="_blank">签章</a>
-                                            </c:if>
-                                            <a href="javascript:void(0);" onclick="openDialogView('查看电子签章信息', '${ctx}/isignature/iSignatureDocument/form?recordId=${workClientAttachment.id}','95%', '95%')" class="op-btn op-btn-view" ><i class="fa fa-search-plus"></i> 查看</a>
-                                            <c:choose>
-                                                <c:when test="${signflag == '是'}">
-                                                    <a href="javascript:location.href='${ctx}/isignature/iSignatureDocument/download?recordId=${workClientAttachment.id}'" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
-                                                </c:when>
-                                                <c:otherwise>
-                                                    <a href="javascript:location.href='${ctx}/workcontractinfo/workContractInfo/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
-                                                </c:otherwise>
-                                            </c:choose>
-                                        </c:when>
-                                        <c:otherwise>
-                                            <a href="javascript:location.href='${ctx}/workcontractinfo/workContractInfo/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
-                                        </c:otherwise>
-                                    </c:choose>
-								</div>
-							</td>
-						</tr>
+						<c:if test="${workClientAttachment.divIdType eq '_gistdata'}">
+							<tr>
+								<c:choose>
+									<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+										<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}"></td>
+									</c:when>
+									<c:otherwise>
+										<c:choose>
+											<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+											</c:when>
+											<c:otherwise>
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%')">${workClientAttachment.attachmentName}</a></td>
+											</c:otherwise>
+										</c:choose>
+									</c:otherwise>
+								</c:choose>
+								<td>${workClientAttachment.createBy.name}</td>
+								<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+								<td class="op-td">
+									<div class="op-btn-box" >
+										<a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+									</div>
+								</td>
+							</tr>
+						</c:if>
 					</c:forEach>
 					</tbody>
 				</table>
 			</div>
 		</div>
+
 		<div class="form-group layui-row">
-			<div class="form-group-label"><h2>自检</h2></div>
-			<div class="layui-item layui-col-xs12 form-table-container">
-				<table id="contentTable2" class="table details table-bordered table-condensed">
+			<div class="form-group-label"><h2>其他文件</h2></div>
+			<div id="addFile_other" style="display: none" class="upload-progress">
+				<span id="fileName_other" ></span>
+				<b><span id="baifenbi_other" ></span></b>
+				<div class="progress">
+					<div id="jindutiao_other" class="progress-bar" style="width: 0%" aria-valuenow="0">
+					</div>
+				</div>
+			</div>
+			<input id="other_file" type="file" name="other_file" multiple="multiple" style="display: none;" onChange="if(this.value)otherInsertTitle(this.value);"/>
+			<span id="other_title"></span>
+			<div class="layui-item layui-col-xs12" style="padding:0 16px;">
+				<table id="upTable_other" class="table table-bordered table-condensed details">
 					<thead>
 					<tr>
-						<th style="text-align: center;width:15%">序号</th>
-						<th style="text-align: center;width:70%">复核内容及评分标准</th>
-						<th style="text-align: center;width:15%">操作</th>
+						<th>文件预览</th>
+						<th>上传人</th>
+						<th>上传时间</th>
+						<th width="150px">操作</th>
 					</tr>
 					</thead>
-					<tbody id="projectContentDataList2">
-					<c:forEach items="${projectcontentinfo.projectReportData.projectReviewList}" var="projectReview" varStatus="index">
-						<tr>
-							<td>
-								<input id="projectReviewList${index.index}_id" name="projectReportData.projectReviewList[${index.index}].id" type="hidden" value="${projectReview.id}"/>
-								<input id="projectReviewList${index.index}_delFalg" name="projectReportData.projectReviewList[${index.index}].delFalg" type="hidden" value="1"/>
-								<input id="projectReviewList${index.index}_remarks" name="projectReportData.projectReviewList[${index.index}].remarks" type="hidden" value="${projectReview.remarks}"/>
-									${index.index + 1}
-							</td>
-							<td>
-									${projectReview.standardDetail}
-							</td>
-
-							<td>
+					<tbody id="file_other">
+					<c:forEach items="${projectcontentinfo.projectReportData.workAttachments}" var = "workClientAttachment" varStatus="status">
+						<c:if test="${workClientAttachment.divIdType eq '_other'}">
+							<tr>
 								<c:choose>
-									<c:when test="${not empty projectReview.remarks}">
-										<div class="check-ok">
-											<i class="fa fa-check"></i>
-										</div>
+									<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+															   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+										<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}"></td>
 									</c:when>
 									<c:otherwise>
-										<div id = "check1${projectReview.id}">
-										</div>
-										<div id = "check2${projectReview.id}" class="check-ok" style="display: none">
-											<i class="fa fa-check"></i>
-										</div>
+										<c:choose>
+											<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+											</c:when>
+											<c:otherwise>
+												<td><a class="attention-info" href="javascript:void(0)" onclick="preview('预览','${workClientAttachment.url}','90%','90%')">${workClientAttachment.attachmentName}</a></td>
+											</c:otherwise>
+										</c:choose>
 									</c:otherwise>
 								</c:choose>
-							</td>
-						</tr>
+								<td>${workClientAttachment.createBy.name}</td>
+								<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+								<td class="op-td">
+									<div class="op-btn-box" >
+										<a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent(encodeURIComponent('${workClientAttachment.url}'));" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+									</div>
+								</td>
+							</tr>
+						</c:if>
 					</c:forEach>
 					</tbody>
 				</table>
 			</div>
 		</div>
-		<c:if test="${not empty projectcontentinfo.projectReportData.act.procInsId}">
-		<div class="form-group layui-row">
-			<div class="form-group-label"><h2>审批意见</h2></div>
-			<div class="layui-item layui-col-xs12 with-textarea" >
-				<label class="layui-form-label">审批意见:</label>
-				<div class="layui-input-block">
-					<textarea name="projectReportData.act.comment" class="form-control" rows="4" maxlength="127" ></textarea>
-				</div>
-			</div>
-		</div>
-		</c:if>
+
+
 		<c:if test="${not empty projectcontentinfo.projectReportData.act.procInsId}">
 		<div class="form-group layui-row">
 			<div class="form-group-label"><h2>审批流程</h2></div>
@@ -365,6 +270,7 @@
 		</div>
 		</c:if>
 		<div class="form-group layui-row page-end"></div>
+		</form:form>
 	</div>
 </div>
 </body>

+ 113 - 43
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/ruralProjectMessageList.jsp

@@ -221,7 +221,7 @@
 							</div>
 						</div>
 						<div class="layui-item query athird ">
-							<label class="layui-form-label">状态:</label>
+							<label class="layui-form-label">报告状态:</label>
 							<div class="layui-input-block">
 								<form:select path="projectReportStatus" class=" form-control  simple-select">
 									<form:option value="" label=""/>
@@ -229,6 +229,15 @@
 								</form:select>
 							</div>
 						</div>
+						<div class="layui-item query athird ">
+							<label class="layui-form-label">归档状态:</label>
+							<div class="layui-input-block">
+								<form:select path="projectReportRecordStatus" class=" form-control  simple-select">
+									<form:option value="" label=""/>
+									<form:options items="${fns:getDictList('audit_state')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+								</form:select>
+							</div>
+						</div>
 						<div style="clear:both;"></div>
 					</div>
 				</form:form>
@@ -269,7 +278,11 @@
                         return "<a class=\"attention-info\" title=\"" + d.projId + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectRecords/view?id=" + d.id + "','95%', '95%')\">" + d.projId + "</a>";
                     }}
                 ,{field:'projectReportNumber', align:'center',title: '报告编号',minWidth:200,templet:function(d){
-                    	return "<span title='"+ d.contract +"'>" + d.projectReportNumber + "</span>";
+                        return "<a class=\"attention-info\" title=\"" + d.contract + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看报告信息', '${ctx}/ruralProject/ruralProjectMessage/modify?projectId=" + d.id + "&view=view','95%', '95%')\">" + d.projectReportNumber + "</a>";
+					}}
+                ,{field:'recodeNum', align:'center',title: '归档申请编号',minWidth:200,templet:function(d){
+                        return "<a class=\"attention-info\" title=\"" + d.contract + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看归档信息', '${ctx}/ruralProject/ruralProjectMessage/formRecord?reportId=" + d.id + "&view=view','95%', '95%')\">" + d.recodeNum + "</a>";
+
 					}}
                 ,{field:'contract', align:'center',title: '合同名称',minWidth:200,templet:function(d){
                     	return "<span title='"+ d.contract +"'>" + d.contract + "</span>";
@@ -281,20 +294,23 @@
                         return "<span title=\"" + d.client + "\">" + d.client + "</span>";
                     }}
                 ,{field:'createDate',align:'center', title: '创建日期',  width:80}
-                ,{align:'center', title: '状态',  width:70,templet:function(d){
-                        if(d.projectReportStatus !=5){
-                            var st = getAuditState(d.projectReportStatus);
-                            if(st.action)
-                                var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/ruralProjectMessage/getProcessOne?id=" + d.id + "&projectReportData.id=" + d.bid + "&type=2','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-                            else
-                                var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-
-                        }else {
-
-                        }
+                ,{align:'center', title: '报告状态',  width:70,templet:function(d){
+                        var st = getAuditState(d.projectReportStatus);
+                        if(st.action)
+                            var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/ruralProjectMessage/getProcessOne?id=" + d.id + "&projectReportData.id=" + d.bid + "&type=2','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                        else
+                            var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                        return xml;
+                    }}
+                ,{align:'center', title: '归档状态',  width:70,templet:function(d){
+                        var st = getAuditState(d.projectReportRecordStatus);
+                        if(st.action)
+                            var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/ruralProjectMessage/getReportRecordProcessOne?processInstanceId=" + d.prrProcessInstanceId + "','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                        else
+                            var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
                         return xml;
                     }}
-                ,{field:'op',align:'center',title:"操作",width:130,templet:function(d){
+                ,{field:'op',align:'center',title:"操作",width:200,templet:function(d){
                         ////对操作进行初始化
                         var xml="";
                         if(d.canAdd != undefined && d.canAdd =="1")
@@ -303,20 +319,45 @@
                         }
                         if(d.canedit1 != undefined && d.canedit1 =="1")
                         {
-                            xml+="<a href=\"#\" onclick=\"openDialogre('修改项目', '${ctx}/ruralProject/ruralProjectMessage/form?projectId=" + d.id +"','95%', '95%','','送审,暂存,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改报告</a>";
+                            xml+="<a href=\"#\" onclick=\"openDialogre('修改报告信息', '${ctx}/ruralProject/ruralProjectMessage/form?projectId=" + d.id +"','95%', '95%','','送审,暂存,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改报告</a>";
                         }
                         if(d.canedit2 != undefined && d.canedit2 =="1")
                         {
-                            xml+="<a href=\"#\" onclick=\"openDialogre('调整项目', '${ctx}/ruralProject/ruralProjectMessage/modify?projectId=" + d.id + "&view=report','95%', '95%','','送审,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改报告</a>";
+                            xml+="<a href=\"#\" onclick=\"openDialogre('调整报告信息', '${ctx}/ruralProject/ruralProjectMessage/modify?projectId=" + d.id + "&view=report','95%', '95%','','送审,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改报告</a>";
                         }
                         if(d.canrecall != undefined && d.canrecall =="1")
                         {
-                            xml+="<a href=\"#\" onclick=\"openDialogre('调整项目', '${ctx}/ruralProject/ruralProjectMessage/modify?projectId=" + d.id + " ','95%', '95%','','送审,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改报告</a>";
+                            xml+="<a href=\"#\" onclick=\"openDialogre('调整报告信息', '${ctx}/ruralProject/ruralProjectMessage/modify?projectId=" + d.id + " ','95%', '95%','','送审,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改报告</a>";
                         }
                         if(d.cancancel != undefined && d.cancancel =="1")
                         {
                             xml+="<a href=\"${ctx}/ruralProject/ruralProjectMessage/revoke?id=" + d.id + "&processInstanceId=" + d.procId + "\" onclick=\"return confirmx('确认要撤回该项目报告审批吗?', this.href)\" class=\"op-btn op-btn-cancel\" ><i class=\"glyphicon glyphicon-share-alt\"></i> 撤回报告</a>";
                         }
+
+
+						/*归档相关按钮*/
+						if(d.projectReportStatus == 5){
+							if(d.recordAdd != undefined && d.recordAdd =="1")
+							{
+								xml+="<a href=\"#\" onclick=\"openDialogre('新增归档信息', '${ctx}/ruralProject/ruralProjectMessage/formRecord?reportId=" + d.id +"','95%', '95%','','送审,暂存,关闭')\" class=\"op-btn layui-bg-green\" ><i class=\"fa fa-plus\"></i> 新增归档信息</a>";
+							}
+							if(d.recordedit1 != undefined && d.recordedit1 =="1")
+							{
+								xml+="<a href=\"#\" onclick=\"openDialogre('修改归档信息', '${ctx}/ruralProject/ruralProjectMessage/form?id=" + d.prrId +"','95%', '95%','','送审,暂存,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改归档信息</a>";
+							}
+							if(d.recordedit2 != undefined && d.recordedit2 =="1")
+							{
+								xml+="<a href=\"#\" onclick=\"openDialogre('调整归档信息', '${ctx}/ruralProject/ruralProjectMessage/formRecordModify?id=" + d.prrId + "&view=modify','95%', '95%','','送审,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改归档信息</a>";
+							}
+							if(d.recordrecall != undefined && d.recordrecall =="1")
+							{
+								xml+="<a href=\"#\" onclick=\"openDialogre('撤回调整归档信息', '${ctx}/ruralProject/ruralProjectMessage/formRecordModify?id=" + d.prrId + " ','95%', '95%','','送审,关闭')\" class=\"op-btn op-btn-edit\" ><i class=\"fa fa-edit\"></i> 修改归档信息</a>";
+							}
+							if(d.recordcancel != undefined && d.recordcancel =="1")
+							{
+								xml+="<a href=\"${ctx}/ruralProject/ruralProjectMessage/cancelInvalidate?id=" + d.prrId + "&processInstanceId=" + d.prrProcessInstanceId + "\" onclick=\"return confirmx('确认要撤回该报告归档审批吗?', this.href)\" class=\"op-btn op-btn-cancel\" ><i class=\"glyphicon glyphicon-share-alt\"></i> 撤回归档信息</a>";
+							}
+                        }
                         return xml;
 
                     }}
@@ -330,53 +371,82 @@
                     ,"id":"${projectRecords.id}"
                     ,"projId":"${projectRecords.projectId}"
                     ,"projectReportNumber":"${projectRecords.projectReportNumber}"
+                    ,"recodeNum":"${projectRecords.recodeNum}"
                     ,"projName":"<c:out value="${projectRecords.projectName}" escapeXml="true"/>"
                     ,"projMaster":"<c:forEach items="${projectRecords.projectLeaders}" var="leader" varStatus="status"><c:choose><c:when test="${status.last}">${leader.name}</c:when><c:otherwise>${leader.name},</c:otherwise></c:choose></c:forEach>"
                     ,"contract":"${projectRecords.workContractInfo.name}"
                     ,"client":"${projectRecords.workContractInfo.client.name}"
                     ,"createDate":"<fmt:formatDate value="${projectRecords.createDate}" pattern="yyyy-MM-dd"/>"
                     ,"projectReportStatus":"${projectRecords.projectReportStatus}"
+                    ,"projectReportRecordStatus":"${projectRecords.projectReportRecordStatus}"
+                    ,"prrProcessInstanceId":"${projectRecords.prrProcessInstanceId}"
+                    ,"prrId":"${projectRecords.prrId}"
                     ,"procId":"${projectRecords.processInstanceId}"
-                    <c:choose><c:when test="${flag == '1' or fns:getUser().id == projectRecords.createBy.id}">
+                    <c:choose>
+                        <c:when test="${flag == '1' or fns:getUser().id == projectRecords.createBy.id}">
+                            ,"canAdd":<c:choose>
+                                            <c:when test="${projectRecords.projectReportStatus == 0 }">"1"</c:when>
+                                            <c:otherwise>"0"</c:otherwise>
+                                        </c:choose>
+                            ,"canedit1":<c:choose>
+                                            <c:when test="${projectRecords.projectReportStatus == 1 }">"1"</c:when>
+                                            <c:otherwise>"0"</c:otherwise>
+                                        </c:choose>
+                            ,"canedit2":<c:choose>
+                                            <c:when test="${projectRecords.projectReportStatus == 4}">"1"</c:when>
+                                            <c:otherwise>"0"</c:otherwise>
+                                        </c:choose>
+                            ,"canrecall":<c:choose>
+                                            <c:when test="${projectRecords.projectReportStatus == 3}">"1"</c:when>
+                                            <c:otherwise>"0"</c:otherwise>
+                                        </c:choose>
 
-                    <shiro:hasPermission name="project:projectRecords:edit">
-                    ,"canAdd":<c:choose>
-                                    <c:when test="${projectRecords.projectReportStatus == 0 }">"1"</c:when>
-                                    <c:otherwise>"0"</c:otherwise>
-                                </c:choose>
-                    ,"canedit1":<c:choose>
-                                    <c:when test="${projectRecords.projectReportStatus == 1 }">"1"</c:when>
-                                    <c:otherwise>"0"</c:otherwise>
-                                </c:choose>
-                    ,"canedit2":<c:choose>
-                                    <c:when test="${projectRecords.projectReportStatus == 4}">"1"</c:when>
-                                    <c:otherwise>"0"</c:otherwise>
-                                </c:choose>
-                    ,"canrecall":<c:choose>
-                                    <c:when test="${projectRecords.projectReportStatus == 3}">"1"</c:when>
-                                    <c:otherwise>"0"</c:otherwise>
-                                </c:choose>
-                    </shiro:hasPermission>
+                            ,"cancancel":<c:choose>
+                                            <c:when test="${projectRecords.projectReportStatus == 2 && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when>
+                                            <c:otherwise>"0"</c:otherwise>
+                                        </c:choose>
 
-                    ,"cancancel":<c:choose>
-                                    <c:when test="${projectRecords.projectReportStatus == 2 && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when>
-                                    <c:otherwise>"0"</c:otherwise>
-                                </c:choose>
-                    </c:when>
+                            <%-- 归档状态 --%>
+                            ,"recordAdd":<c:choose>
+                                <c:when test="${projectRecords.projectReportRecordStatus == 0 }">"1"</c:when>
+                                <c:otherwise>"0"</c:otherwise>
+                            </c:choose>
+                            ,"recordedit1":<c:choose>
+                                <c:when test="${projectRecords.projectReportRecordStatus == 1 }">"1"</c:when>
+                                <c:otherwise>"0"</c:otherwise>
+                            </c:choose>
+                            ,"recordedit2":<c:choose>
+                                <c:when test="${projectRecords.projectReportRecordStatus == 4}">"1"</c:when>
+                                <c:otherwise>"0"</c:otherwise>
+                            </c:choose>
+                            ,"recordrecall":<c:choose>
+                                <c:when test="${projectRecords.projectReportRecordStatus == 3}">"1"</c:when>
+                                <c:otherwise>"0"</c:otherwise>
+                            </c:choose>
+                            ,"recordcancel":<c:choose>
+                                <c:when test="${projectRecords.projectReportRecordStatus == 2 && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when>
+                            <c:otherwise>"0"</c:otherwise>
+                            </c:choose>
+                        </c:when>
                     <c:otherwise>
                     ,"candel":"0"
                     ,"canedit1":"0"
                     ,"canedit2":"0"
                     ,"canrecall":"0"
                     ,"cancancel":"0"
+                    ,"recorddel":"0"
+                    ,"recordedit1":"0"
+                    ,"recordedit2":"0"
+                    ,"recordrecall":"0"
+                    ,"recordcancel":"0"
                     </c:otherwise>
                     </c:choose>
-                    <shiro:hasPermission name="project:projectRecords:edit">
+                    <%--<shiro:hasPermission name="project:projectRecords:edit">
                     ,"canedit3":<c:choose>
                                     <c:when test="${projectRecords.projectReportStatus == 5 && fn:contains(projectRecords.leaderIds,fns:getUser().id)}">"1"</c:when>
                                     <c:otherwise>"0"</c:otherwise>
                                 </c:choose>
-                    </shiro:hasPermission>
+                    </shiro:hasPermission>--%>
                 }
                 </c:forEach>
                 </c:if>