소스 검색

Merge remote-tracking branch 'origin/master'

# Conflicts:
#	src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/controller/ElectronicSignatureController.java
#	src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureList.jsp
sangwenwei 1 년 전
부모
커밋
b1872ae43f
53개의 변경된 파일18345개의 추가작업 그리고 85개의 파일을 삭제
  1. 1 1
      src/main/java/com/jeeplus/common/utils/MenuStatusEnum.java
  2. 67 0
      src/main/java/com/jeeplus/modules/areaStaff/dao/AreaStaffDao.java
  3. 176 0
      src/main/java/com/jeeplus/modules/areaStaff/entity/AreaStaffInfo.java
  4. 561 0
      src/main/java/com/jeeplus/modules/areaStaff/service/AreaStaffService.java
  5. 457 0
      src/main/java/com/jeeplus/modules/areaStaff/web/AreaStaffController.java
  6. 9 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/entity/RuralReportConsultant.java
  7. 29 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageAllService.java
  8. 1074 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageService.java
  9. 2543 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/changZhouSignature/RuralProjectMessageElectronicSealCZService.java
  10. 305 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/thread/ApprovalCZThread.java
  11. 373 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/thread/SignatureCZThread.java
  12. 299 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectSignatureCallBackController.java
  13. 1004 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/changZhouSignature/RuralProjectMessageElectronicSealCZController.java
  14. 74 3
      src/main/java/com/jeeplus/modules/signatureManagement/businessSignature/controller/BusinessSignatureController.java
  15. 29 0
      src/main/java/com/jeeplus/modules/signatureManagement/businessSignature/entity/BusinessSignatureInfo.java
  16. 85 13
      src/main/java/com/jeeplus/modules/signatureManagement/businessSignature/service/BusinessSignatureService.java
  17. 77 3
      src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/controller/ElectronicSignatureController.java
  18. 6 0
      src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/dao/ElectronicSignatureDao.java
  19. 29 0
      src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/entity/ElectronicSignatureInfo.java
  20. 13 1
      src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/service/DistrictDirectorApplicationService.java
  21. 97 12
      src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/service/ElectronicSignatureService.java
  22. 12 1
      src/main/java/com/jeeplus/modules/workfullmanage/web/WorkFullManageController.java
  23. 1 1
      src/main/resources/jeeplus.properties
  24. 317 0
      src/main/resources/mappings/modules/areaStaff/AreaStaffDao.xml
  25. 13 5
      src/main/resources/mappings/modules/signatureManagement/businessSignature/BusinessSignatureDao.xml
  26. 21 5
      src/main/resources/mappings/modules/signatureManagement/electronicSignature/ElectronicSignatureDao.xml
  27. 18 0
      src/main/webapp/WEB-INF/tags/table/addAreaStaffRow.tag
  28. 89 0
      src/main/webapp/webpage/modules/areaStaff/areaStaffForm.jsp
  29. 145 0
      src/main/webapp/webpage/modules/areaStaff/areaStaffList.jsp
  30. 108 0
      src/main/webapp/webpage/modules/areaStaff/areaStaffSecondForm.jsp
  31. 187 0
      src/main/webapp/webpage/modules/areaStaff/areaStaffUserForm.jsp
  32. 69 0
      src/main/webapp/webpage/modules/areaStaff/areaStaffView.jsp
  33. 128 0
      src/main/webapp/webpage/modules/areaStaff/selectUserToStaff.jsp
  34. 702 0
      src/main/webapp/webpage/modules/ruralprojectrecords/electronicSeal/electronicSealCZ/ruralProjectRecordsApprovalCZAudit.jsp
  35. 612 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectMessageElectronicSealCZList.jsp
  36. 1339 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsApprovalCZForm.jsp
  37. 617 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsApprovalCZModify.jsp
  38. 1249 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsApprovalCZView.jsp
  39. 572 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZAudit.jsp
  40. 1290 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZForm.jsp
  41. 623 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZModify.jsp
  42. 623 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZSzzkAudit.jsp
  43. 1255 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZView.jsp
  44. 119 1
      src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureAudit.jsp
  45. 126 1
      src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureForm.jsp
  46. 3 1
      src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureList.jsp
  47. 123 1
      src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureModify.jsp
  48. 118 1
      src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureView.jsp
  49. 132 7
      src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureAudit.jsp
  50. 143 7
      src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureForm.jsp
  51. 12 6
      src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureList.jsp
  52. 140 8
      src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureModify.jsp
  53. 131 7
      src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureView.jsp

+ 1 - 1
src/main/java/com/jeeplus/common/utils/MenuStatusEnum.java

@@ -38,6 +38,7 @@ public enum MenuStatusEnum {
     OVERALL_COST_WORK_RECORD_LIST("bac3717361294087887c9af75066e32a","全过程-造价审核-项目列表"),
     PROJECT_SIGNATURE("607c95d190dd4158bee3006899de3867","全过程-电子签章(苏州)"),
     PROJECT_SIGNATURE_YC("4008b9e2250441428cd90fd57cec8f39","电子签章(盐城)"),
+    PROJECT_SIGNATURE_CZ("7a03ccb22c424928b14540e878720365","电子签章(常州)"),
     WORK_INVOICEDETAIL("84312d6a28e948b8b7b68185cf8d4d72","发票明细"),
     WORK_INVOICEALTER("89323021918e444bae3537521046d19f","开票管理"),
     WORK_CONTRACT_INFO("b9309305d94f4ee8b66eebbcae9f2db4","合同登记"),
@@ -83,7 +84,6 @@ public enum MenuStatusEnum {
     DISPUTE_MEDIATION("c0ce72cbeb5d446a946795b0a3b7e4a4","纠纷调解"),
     ELECTRONIC_SIGNATURE("50cfb2ad32814623a976bb7776e87c12","电子用章管理"),
     EBUSINESS_SIGNATURE("976b008b2c0f402ea7015bb15665d1f4","业务用章管理"),
-    PERSON_OPINION("de550330b679418cb43165c4937afa68","个人意见"),
     END("19940722131313","废弃");
 
     private String value;

+ 67 - 0
src/main/java/com/jeeplus/modules/areaStaff/dao/AreaStaffDao.java

@@ -0,0 +1,67 @@
+package com.jeeplus.modules.areaStaff.dao;
+
+import com.jeeplus.common.persistence.TreeDao;
+import com.jeeplus.common.persistence.annotation.MyBatisDao;
+import com.jeeplus.modules.areaStaff.entity.AreaStaffInfo;
+import com.jeeplus.modules.sys.entity.Menu;
+import com.jeeplus.modules.sys.entity.User;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+import java.util.Set;
+
+/**
+ * @author: 徐滕
+ * @version: 2024-06-17 14:18
+ */
+@MyBatisDao
+public interface AreaStaffDao extends TreeDao<AreaStaffInfo> {
+
+    List<AreaStaffInfo> fingIds(@Param("parentIdSet") Set<String> parentIdSet, @Param("companyId") String companyId);
+    List<AreaStaffInfo> fingByIds(@Param("parentIdSet") Set<String> parentIdSet, @Param("companyId") String companyId, @Param("parentIds") String parentIds);
+
+    String selectOrderNum(String parentId);
+
+    List<AreaStaffInfo> getByDetail();
+
+    /**
+     * 根据areaId查询信息
+     * @param areaId
+     * @return
+     */
+    List<AreaStaffInfo> getEffectiveArea(String areaId);
+
+    /**
+     * 根据部门id查询信息
+     * @param officeId
+     * @return
+     */
+    AreaStaffInfo getOfficeInfo(String officeId);
+
+    /**
+     * 根据父节点id查询信息
+     * @param parentIdList
+     * @return
+     */
+    List<AreaStaffInfo> getByParentIdList(@Param("parentIdList") List<String> parentIdList, @Param("parentIds")String parentIds);
+
+    List<User> getUserByParentId(AreaStaffInfo info);
+
+    List<User> getUserByParentIdAndStandardDetail(AreaStaffInfo info);
+
+    Boolean outUserById(@Param("userId")String userId, @Param("parentId")String parentId);
+
+    /**
+     * 删除所有子节点信息(逻辑删除)
+     * @param info
+     */
+    void deleteChildrenByParentId(AreaStaffInfo info);
+
+
+
+    List<AreaStaffInfo> getAreaStaffInfoByParentIdAndStandardDetail(@Param("standardDetail")String standardDetail, @Param("parentId")String parentId);
+
+    List<AreaStaffInfo> getAreaStaffInfoByParentIdAndType(@Param("type")String type, @Param("parentId")String parentId);
+
+    AreaStaffInfo getMasterStateByUserId(String userId);
+}

+ 176 - 0
src/main/java/com/jeeplus/modules/areaStaff/entity/AreaStaffInfo.java

@@ -0,0 +1,176 @@
+package com.jeeplus.modules.areaStaff.entity;
+
+import com.jeeplus.common.persistence.DataEntity;
+import com.jeeplus.common.persistence.TreeEntity;
+import com.jeeplus.modules.sys.entity.Area;
+import com.jeeplus.modules.sys.entity.Menu;
+import com.jeeplus.modules.sys.entity.Office;
+import com.jeeplus.modules.sys.entity.Role;
+
+import java.util.List;
+
+/**
+ * @author: 徐滕
+ * @version: 2024-06-17 14:00
+ */
+public class AreaStaffInfo extends TreeEntity<AreaStaffInfo> {
+
+    private static final long serialVersionUID = 1L;
+    private String standardDetail;		// 标准内容
+    private String standardDetailStr;		// 标准内容
+    private String parentIds;		// 所有父ID
+    private Byte maxDeduct;		// 最多扣分
+    private String orderNum;		// 排序
+    private String companyId;   //公司id
+    private String type;    //地区负责人和地区成员判定值。负责人:master。普通员工:staff
+    private Integer proofread; //是否是校核
+    private String hierarchy; //节点所属层级
+
+
+    private String number;    //编号
+    private String name;      //名称
+    private String pid;       //父级id
+    private Area area;       //地区
+    private Office office;       //部门
+
+
+    public AreaStaffInfo() {
+        super();
+    }
+
+    public AreaStaffInfo(String id){
+        super(id);
+    }
+
+    @Override
+    public AreaStaffInfo getParent() {
+        return parent;
+    }
+
+    @Override
+    public void setParent(AreaStaffInfo parent) {
+        this.parent = parent;
+    }
+
+    public int getGrade(){
+        String[] split = this.getParentIds().split(",");
+        return split.length-1;
+    }
+
+
+    public String getStandardDetail() {
+        return standardDetail;
+    }
+
+    public void setStandardDetail(String standardDetail) {
+        this.standardDetail = standardDetail;
+    }
+
+    @Override
+    public String getParentIds() {
+        return parentIds;
+    }
+
+    @Override
+    public void setParentIds(String parentIds) {
+        this.parentIds = parentIds;
+    }
+
+    public Byte getMaxDeduct() {
+        return maxDeduct;
+    }
+
+    public void setMaxDeduct(Byte maxDeduct) {
+        this.maxDeduct = maxDeduct;
+    }
+
+    public String getOrderNum() {
+        return orderNum;
+    }
+
+    public void setOrderNum(String orderNum) {
+        this.orderNum = orderNum;
+    }
+
+    public String getCompanyId() {
+        return companyId;
+    }
+
+    public void setCompanyId(String companyId) {
+        this.companyId = companyId;
+    }
+
+    public String getType() {
+        return type;
+    }
+
+    public void setType(String type) {
+        this.type = type;
+    }
+
+    public Integer getProofread() {
+        return proofread;
+    }
+
+    public void setProofread(Integer proofread) {
+        this.proofread = proofread;
+    }
+
+    public String getNumber() {
+        return number;
+    }
+
+    public void setNumber(String number) {
+        this.number = number;
+    }
+
+    @Override
+    public String getName() {
+        return name;
+    }
+
+    @Override
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getPid() {
+        return pid;
+    }
+
+    public void setPid(String pid) {
+        this.pid = pid;
+    }
+
+    public Area getArea() {
+        return area;
+    }
+
+    public void setArea(Area area) {
+        this.area = area;
+    }
+
+    public Office getOffice() {
+        return office;
+    }
+
+    public void setOffice(Office office) {
+        this.office = office;
+    }
+
+    public String getHierarchy() {
+        return hierarchy;
+    }
+
+    public void setHierarchy(String hierarchy) {
+        this.hierarchy = hierarchy;
+    }
+
+    public String getStandardDetailStr() {
+        return standardDetailStr;
+    }
+
+    public void setStandardDetailStr(String standardDetailStr) {
+        this.standardDetailStr = standardDetailStr;
+    }
+}

+ 561 - 0
src/main/java/com/jeeplus/modules/areaStaff/service/AreaStaffService.java

@@ -0,0 +1,561 @@
+package com.jeeplus.modules.areaStaff.service;
+
+import com.google.common.collect.Lists;
+import com.jeeplus.common.persistence.Page;
+import com.jeeplus.common.service.TreeService;
+import com.jeeplus.common.utils.StringUtils;
+import com.jeeplus.modules.areaStaff.dao.AreaStaffDao;
+import com.jeeplus.modules.areaStaff.entity.AreaStaffInfo;
+import com.jeeplus.modules.signatureManagement.electronicSignature.entity.DistrictDirectorApplication;
+import com.jeeplus.modules.sys.entity.Area;
+import com.jeeplus.modules.sys.entity.Office;
+import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.service.AreaService;
+import com.jeeplus.modules.sys.service.OfficeService;
+import com.jeeplus.modules.sys.utils.UserUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.*;
+
+/**
+ * @author: 徐滕
+ * @version: 2024-06-17 14:18
+ */
+@Service
+@Transactional(readOnly = true)
+public class AreaStaffService  extends TreeService<AreaStaffDao, AreaStaffInfo> {
+
+    @Autowired
+    private OfficeService officeService;
+    @Autowired
+    private AreaService areaService;
+
+    public AreaStaffInfo get(String id) {
+        return super.get(id);
+    }
+
+    /**
+     * 查询所有数据
+     * @param workReimbursementTypeInfo
+     * @return
+     */
+    public List<AreaStaffInfo> findList(AreaStaffInfo workReimbursementTypeInfo) {
+        List<AreaStaffInfo> projectAccessoryInfoList = new ArrayList<>();
+        List<AreaStaffInfo> listReturn = Lists.newArrayList();
+        //根据条件查询数据集合
+        List<AreaStaffInfo> listAll = super.findList(workReimbursementTypeInfo);
+        Office company = UserUtils.getSelectCompany();
+        workReimbursementTypeInfo.setCompanyId(company.getId());
+        //根据条件查询数据集合
+        List<AreaStaffInfo> list = super.findList(workReimbursementTypeInfo);
+        //判断,数据不为空则添加到返回集合中
+        if (listAll!=null && listAll.size()!=0){
+            projectAccessoryInfoList.addAll(listAll);
+        }
+        //判断,数据不为空则添加到返回集合中
+        if (list!=null && list.size()!=0){
+            projectAccessoryInfoList.addAll(list);
+        }
+
+        if(projectAccessoryInfoList!=null&&projectAccessoryInfoList.size()>0&&workReimbursementTypeInfo!=null&& (StringUtils.isNotBlank(workReimbursementTypeInfo.getStandardDetail())||StringUtils.isNotBlank(workReimbursementTypeInfo.getOrderNum()))){
+            //标准内容模糊查询,查询所有父节点
+            Set<String> parentIdSet = new HashSet<>();
+            for (AreaStaffInfo projectAccessory : projectAccessoryInfoList) {
+                String parentIds = projectAccessory.getParentIds();
+                if (StringUtils.isNotBlank(parentIds)){
+                    parentIdSet.addAll(Arrays.asList(parentIds.split(",")));
+                }
+            }
+            for (AreaStaffInfo reviewStandard : projectAccessoryInfoList) {
+                parentIdSet.remove(reviewStandard.getId());
+            }
+            projectAccessoryInfoList.addAll(0,this.fingIds(parentIdSet,"0"));
+            projectAccessoryInfoList.addAll(0,this.fingIds(parentIdSet,UserUtils.getSelectCompany().getId()));
+        }
+        sortList(listReturn,projectAccessoryInfoList,"0",true);
+        return listReturn;
+    }
+
+    public static void sortList(List<AreaStaffInfo> list, List<AreaStaffInfo> sourcelist, String parentId, boolean cascade){
+        for (int i=0; i<sourcelist.size(); i++){
+            AreaStaffInfo e = sourcelist.get(i);
+            if (e.getParent()!=null && StringUtils.isNotBlank(e.getParent().getId()) && e.getParent().getId().equals(parentId)){
+                list.add(e);
+                if (cascade){
+                    // 判断是否还有子节点, 有则继续获取子节点
+                    for (int j=0; j<sourcelist.size(); j++){
+                        AreaStaffInfo child = sourcelist.get(j);
+                        if (child.getParent()!=null && StringUtils.isNotBlank(child.getParent().getId()) && child.getParent().getId().equals(e.getId())){
+                            sortList(list, sourcelist, e.getId(), true);
+                            break;
+                        }
+                    }
+                }
+            }
+        }
+    }
+
+    private List<AreaStaffInfo> fingIds(Set<String> parentIdSet, String companyId) {
+        return dao.fingIds(parentIdSet,companyId);
+    }
+    private List<AreaStaffInfo> fingByIds(Set<String> parentIdSet, String companyId, String parentIds) {
+        return dao.fingByIds(parentIdSet,companyId,parentIds);
+    }
+
+    public Page<AreaStaffInfo> findPage(Page<AreaStaffInfo> page, AreaStaffInfo workReimbursementTypeInfo) {
+        return super.findPage(page, workReimbursementTypeInfo);
+    }
+
+    @Transactional(readOnly = false)
+    public void save(AreaStaffInfo areaStaffInfo) {
+        //设置序号
+        if(areaStaffInfo.getIsNewRecord()) {
+            if(null != areaStaffInfo.getParent() && !"0".equals(areaStaffInfo.getParent().getId())){
+                areaStaffInfo.setParent(this.get(areaStaffInfo.getParent().getId()));
+            }
+            String orderNum = null;
+            //判断是否选择了父级节点。没有选择则默认为第一级别
+            if(null != areaStaffInfo.getParent()){
+                orderNum = this.selectOrderNum(areaStaffInfo.getParent().getId());
+                areaStaffInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+            }else{
+                orderNum = this.selectOrderNum("0");
+                areaStaffInfo.setCompanyId("0");
+            }
+            //判断是否有数据,没有数据则默认给编号01,有则在最大数据上递增1
+            if(null == orderNum){
+                areaStaffInfo.setOrderNum("1");
+                areaStaffInfo.setHierarchy("1");
+            }else{
+                if (StringUtils.isBlank(orderNum)) {
+                    areaStaffInfo.setOrderNum(areaStaffInfo.getParent().getOrderNum() + "01");
+                } else {
+                    areaStaffInfo.setOrderNum(String.valueOf(Integer.valueOf(orderNum) + 1));
+                }
+            }
+            if(null != areaStaffInfo.getOffice() && StringUtils.isNotBlank(areaStaffInfo.getOffice().getId())){
+                areaStaffInfo.setStandardDetail(areaStaffInfo.getOffice().getId());
+            }
+        }
+        super.save(areaStaffInfo);
+    }
+
+    /**
+     * 二级新增
+     * @param areaStaffInfo
+     */
+    @Transactional(readOnly = false)
+    public void secondSave(AreaStaffInfo areaStaffInfo) {
+        //设置序号
+        if(areaStaffInfo.getIsNewRecord()) {
+            if(null != areaStaffInfo.getParent() && !"0".equals(areaStaffInfo.getParent().getId())){
+                areaStaffInfo.setParent(this.get(areaStaffInfo.getParent().getId()));
+            }
+            String orderNum = null;
+            //判断是否选择了父级节点。没有选择则默认为第一级别
+            if(null != areaStaffInfo.getParent()){
+                orderNum = this.selectOrderNum(areaStaffInfo.getParent().getId());
+                areaStaffInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+            }else{
+                orderNum = this.selectOrderNum("0");
+                areaStaffInfo.setCompanyId("0");
+            }
+            //判断是否有数据,没有数据则默认给编号01,有则在最大数据上递增1
+            if (StringUtils.isBlank(orderNum)) {
+                areaStaffInfo.setOrderNum(areaStaffInfo.getParent().getOrderNum() + "01");
+            } else {
+                areaStaffInfo.setOrderNum(String.valueOf(Integer.valueOf(orderNum) + 1));
+            }
+            if(null != areaStaffInfo.getArea() && StringUtils.isNotBlank(areaStaffInfo.getArea().getId())){
+                areaStaffInfo.setStandardDetail(areaStaffInfo.getArea().getId());
+            }
+        }
+        //对数据进行保存
+        super.save(areaStaffInfo);
+        //添加地区负责人和区域员工分支
+        AreaStaffInfo areaMasterInfo = new AreaStaffInfo();
+        areaMasterInfo.setParent(areaStaffInfo);
+        if(StringUtils.isNotBlank(areaStaffInfo.getHierarchy())){
+            areaMasterInfo.setHierarchy(String.valueOf(Integer.parseInt(areaStaffInfo.getHierarchy()) + 1));
+        }else{
+            areaMasterInfo.setHierarchy("3");
+        }
+        areaMasterInfo.setStandardDetail("地区负责人");
+        areaMasterInfo.setType("master");
+        areaMasterInfo.setOrderNum(areaMasterInfo.getParent().getOrderNum() + "01");
+        areaMasterInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+
+        //需先查询是否存在地区负责人或地区员工节点
+        List<AreaStaffInfo> masterInfoList = dao.getAreaStaffInfoByParentIdAndStandardDetail(areaMasterInfo.getStandardDetail(),areaStaffInfo.getParent().getId());
+        if(masterInfoList.size()==0){
+            //对数据进行保存
+            super.save(areaMasterInfo);
+        }
+
+        //添加地区负责人和区域员工分支
+        AreaStaffInfo areaGeneralInfo = new AreaStaffInfo();
+        areaGeneralInfo.setParent(areaStaffInfo);
+        if(StringUtils.isNotBlank(areaStaffInfo.getHierarchy())){
+            areaGeneralInfo.setHierarchy(String.valueOf(Integer.parseInt(areaStaffInfo.getHierarchy()) + 1));
+        }else{
+            areaGeneralInfo.setHierarchy("3");
+        }
+        areaGeneralInfo.setStandardDetail("地区员工");
+        areaGeneralInfo.setType("staff");
+        areaGeneralInfo.setOrderNum(areaGeneralInfo.getParent().getOrderNum() + "01");
+        areaGeneralInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+
+        //需先查询是否存在地区负责人或地区员工节点
+        List<AreaStaffInfo> generalInfoList = dao.getAreaStaffInfoByParentIdAndStandardDetail(areaGeneralInfo.getStandardDetail(),areaStaffInfo.getParent().getId());
+        if(generalInfoList.size()==0){
+            //对数据进行保存
+            super.save(areaGeneralInfo);
+        }
+    }
+
+    @Transactional(readOnly = false)
+    public void delete(AreaStaffInfo areaStaffInfo) {
+        super.delete(areaStaffInfo);
+        //删除该节点下所有节点信息
+        dao.deleteChildrenByParentId(areaStaffInfo);
+    }
+
+
+    public String selectOrderNum(String parentId) {
+        return dao.selectOrderNum(parentId);
+    }
+
+
+    /**
+     * 查询第一级数据信息
+     * @param workReimbursementTypeInfo
+     * @return
+     */
+    public List<AreaStaffInfo> findTreeList(AreaStaffInfo workReimbursementTypeInfo) {
+        List<AreaStaffInfo> workReviewStandards = new ArrayList<>();
+        List<AreaStaffInfo> listReturn = Lists.newArrayList();
+        Office company = UserUtils.getSelectCompany();
+        workReimbursementTypeInfo.setCompanyId(company.getId());
+        List<AreaStaffInfo> listAll = super.findList(workReimbursementTypeInfo);
+        /*workReviewStandard.setCompanyId(company.getId());
+        workReviewStandard.setProofread(1);
+        List<ProjectAccessoryInfo> list = super.findList(workReviewStandard);*/
+        if (listAll!=null && listAll.size()!=0){
+            workReviewStandards.addAll(listAll);
+        }
+        /*if (list!=null && list.size()!=0){
+            workReviewStandards.addAll(list);
+        }*/
+        sortList(listReturn,workReviewStandards,"0",true);
+        this.queryProofread(listReturn);
+        return listReturn;
+    }
+
+    public void queryProofread(List<AreaStaffInfo> listReturn){
+        List<AreaStaffInfo> standards = dao.getByDetail();
+        if(standards==null||listReturn==null){
+            return;
+        }
+        for (AreaStaffInfo standard : standards) {
+            for (AreaStaffInfo reviewStandard : listReturn) {
+                if(reviewStandard!=null&&((reviewStandard.getParent()!=null&&standard.getId().equals(reviewStandard.getParent().getId()))
+                        ||standard.getId().equals(reviewStandard.getId())
+                        || (StringUtils.isNotBlank(reviewStandard.getParentIds())&&reviewStandard.getParentIds().contains(standard.getId()))
+                )){
+                    reviewStandard.setProofread(1);
+                }
+            }
+        }
+
+    }
+
+    public void circulationGetParent(AreaStaffInfo info) {
+        if(null != info.getParent() && !"0".equals(info.getParent().getId())){
+            AreaStaffInfo areaStaffInfo = this.get(info.getParent().getId());
+
+            switch (areaStaffInfo.getHierarchy()){
+                case "1":
+                    Office office = officeService.get(areaStaffInfo.getStandardDetail());
+                    areaStaffInfo.setOffice(office);
+                    break;
+                case "2":
+                    Area area = areaService.get(areaStaffInfo.getStandardDetail());
+                    areaStaffInfo.setArea(area);
+                    break;
+                case "4":
+                    break;
+                default:
+                    break;
+            }
+            info.setParent(areaStaffInfo);
+            circulationGetParent(info.getParent());
+        }
+    }
+
+    public List<Area> disposeParentArea(AreaStaffInfo info,List<Area> areaList){
+        if(null != info.getParent() && !"0".equals(info.getParent().getId())){
+            if(null != info.getParent().getArea()){
+                areaList.add(info.getParent().getArea());
+            }else{
+                disposeParentArea(info.getParent(),areaList);
+            }
+        }
+        return areaList;
+    }
+
+    public List<Office> disposeParentOffice(AreaStaffInfo info,List<Office> officeList){
+        if(null != info.getParent() && !"0".equals(info.getParent().getId())){
+            if(null != info.getParent().getOffice()){
+                officeList.add(info.getParent().getOffice());
+            }else{
+                disposeParentOffice(info.getParent(),officeList);
+            }
+        }
+        return officeList;
+    }
+
+
+    public AreaStaffInfo getEffectiveArea(String officeId,String areaId) {
+        //根据地区id查询是否存在
+        List<AreaStaffInfo> infoList = dao.getEffectiveArea(areaId);
+        for (AreaStaffInfo info : infoList) {
+            if(StringUtils.isNotBlank(info.getParentIds())){
+                String[] parentIds = info.getParentIds().split(",");
+                List<String> parentIdList = Arrays.asList(parentIds);
+                //根据parentId 查询所有父节点信息
+                List<AreaStaffInfo> byParentIdList = dao.getByParentIdList(parentIdList,info.getParentIds());
+                if(byParentIdList.size()>0){
+                    for (AreaStaffInfo areaStaffInfo : byParentIdList) {
+                        if(officeId.equals(areaStaffInfo.getStandardDetail())){
+                            return info;
+                        }
+                    }
+                }
+            }
+        }
+        return null;
+    }
+
+    public List<User> getUserByParentId(AreaStaffInfo info){
+        return dao.getUserByParentId(info);
+    }
+
+    /**
+     * 人员信息导入
+     * @param areaStaffInfo
+     * @param user
+     */
+    @Transactional(readOnly = false)
+    public User saveUser(AreaStaffInfo areaStaffInfo,User user){
+        areaStaffInfo = this.get(areaStaffInfo.getId());
+        //查询节点下是否存在该人员信息
+        areaStaffInfo.setStandardDetail(user.getId());
+        List<User> userByParentId = dao.getUserByParentIdAndStandardDetail(areaStaffInfo);
+        if(userByParentId.size()==0){
+            //添加地区负责人和区域员工分支
+            AreaStaffInfo areaMasterInfo = new AreaStaffInfo();
+            areaMasterInfo.setParent(areaStaffInfo);
+            if(StringUtils.isNotBlank(areaStaffInfo.getHierarchy())){
+                areaMasterInfo.setHierarchy(String.valueOf(Integer.parseInt(areaStaffInfo.getHierarchy()) + 1));
+            }else{
+                areaMasterInfo.setHierarchy("4");
+            }
+            areaMasterInfo.setStandardDetail(user.getId());
+            areaMasterInfo.setOrderNum(areaMasterInfo.getParent().getOrderNum() + "01");
+            areaMasterInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+
+            //对数据进行保存
+            super.save(areaMasterInfo);
+        }
+
+        return user;
+    }
+
+
+    public List<User> getUserByParentIdAndStandardDetail(AreaStaffInfo info){
+        return dao.getUserByParentIdAndStandardDetail(info);
+    }
+
+
+    @Transactional(readOnly = false)
+    public Boolean outUserById(String userId,String id){
+        return dao.outUserById(userId,id);
+    }
+
+
+    /**
+     * 申请地区负责人数据调整
+     * @param directorApplication
+     * @return
+     */
+    public Map<String,Object> disposeAreaMaster(DistrictDirectorApplication directorApplication){
+        Map<String,Object> map = new HashMap<>();
+        //判定是否存在部门信息,若存在则先验证该部门是否存在在表中
+        if(null ==directorApplication.getOffice() || StringUtils.isBlank(directorApplication.getOffice().getId())
+                || null ==directorApplication.getArea() || StringUtils.isBlank(directorApplication.getArea().getId())
+                || null ==directorApplication.getCreateBy() || StringUtils.isBlank(directorApplication.getCreateBy().getId())){
+            map.put("success",false);
+            map.put("message","申请人、申请部门或申请地区错误,无法添加地区管理员");
+            return map;
+        }
+        //获取申请人信息
+        User user = UserUtils.get(directorApplication.getCreateBy().getId());
+        if(null == user){
+            map.put("success",false);
+            map.put("message","申请人信息错误,无法添加地区管理员");
+            return map;
+        }
+
+        if(null != directorApplication.getOffice() && StringUtils.isNotBlank(directorApplication.getOffice().getId())){
+            AreaStaffInfo officeInfo = dao.getOfficeInfo(directorApplication.getOffice().getId());
+            if(null != officeInfo){
+                //如果部门不为空,则验证该部门下 的地区是否存在
+                List<AreaStaffInfo> areaInfo = dao.getAreaStaffInfoByParentIdAndStandardDetail(directorApplication.getArea().getId(), officeInfo.getId());
+                if(null != areaInfo && areaInfo.size()>0){
+                    //如果地区不为空,则查询地区下是否存在地区负责人项,若存在,则直接添加人员信息
+                    List<AreaStaffInfo> masterType = dao.getAreaStaffInfoByParentIdAndType("master", areaInfo.get(0).getId());
+                    if(null != masterType && masterType.size()>0){
+                        //查询该地区下是否已经存在该人员信息
+                        //如果地区负责人标签存在则直接添加人员信息
+                        List<AreaStaffInfo> userList = dao.getAreaStaffInfoByParentIdAndStandardDetail(user.getId(), masterType.get(0).getId());
+                        if(userList.size() == 0){
+                            this.saveUser(masterType.get(0),user);
+                        }else{
+                            map.put("success",false);
+                            map.put("message","申请人已经是该地区负责人,无法重复添加");
+                            return map;
+                        }
+                    }else{
+                        //如果地区负责人标签不存在,则需添加标签后再添加人员信息
+                        //添加地区负责人和区域员工分支
+                        AreaStaffInfo areaMasterInfo = this.saveMasterType(areaInfo.get(0));
+                        this.saveUser(areaMasterInfo,user);
+                    }
+
+                    List<AreaStaffInfo> staffType = dao.getAreaStaffInfoByParentIdAndType("staff", areaInfo.get(0).getId());
+
+                    if(null != staffType && staffType.size()>0){
+
+                    }else{
+                        //如果地区员工标签不存在,则需添加标签
+                        this.saveStaffType(areaInfo.get(0));
+                    }
+                }else{
+                    //如果地区为空则进行地区添加和地区负责人添加
+                    AreaStaffInfo areaStaffInfo = this.saveAreaType(officeInfo, directorApplication.getArea().getId());
+                    //添加地区负责人和区域员工分支
+                    AreaStaffInfo areaMasterInfo = this.saveMasterType(areaStaffInfo);
+                    //如果地区员工标签不存在,则需添加标签
+                    this.saveStaffType(areaStaffInfo);
+                    this.saveUser(areaMasterInfo,user);
+
+                }
+
+            }else{
+                //如果部门不存在,则进行新增部门信息,区域信息,地区负责人信息
+                AreaStaffInfo areaOfficeInfo = this.saveOfficeType(directorApplication.getOffice().getId());
+                //如果地区为空则进行地区添加和地区负责人添加
+                AreaStaffInfo areaStaffInfo = this.saveAreaType(areaOfficeInfo, directorApplication.getArea().getId());
+                //添加地区负责人和区域员工分支
+                AreaStaffInfo areaMasterInfo = this.saveMasterType(areaStaffInfo);
+                //如果地区员工标签不存在,则需添加标签
+                this.saveStaffType(areaStaffInfo);
+                this.saveUser(areaMasterInfo,user);
+            }
+        }
+        map.put("success",true);
+        map.put("message","添加成功");
+        return map;
+    }
+
+    /**
+     * 添加地区负责人层级参数
+     * @param areaInfo
+     * @return
+     */
+    public AreaStaffInfo saveMasterType(AreaStaffInfo areaInfo){
+        AreaStaffInfo areaMasterInfo = new AreaStaffInfo();
+        areaMasterInfo.setParent(areaInfo);
+        if(StringUtils.isNotBlank(areaInfo.getHierarchy())){
+            areaMasterInfo.setHierarchy(String.valueOf(Integer.parseInt(areaInfo.getHierarchy()) + 1));
+        }else{
+            areaMasterInfo.setHierarchy("3");
+        }
+        areaMasterInfo.setStandardDetail("地区负责人");
+        areaMasterInfo.setType("master");
+        areaMasterInfo.setOrderNum(areaMasterInfo.getParent().getOrderNum() + "01");
+        areaMasterInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+        super.save(areaMasterInfo);
+        return areaMasterInfo;
+    }
+
+
+    /**
+     * 添加地区负责人层级参数
+     * @param areaInfo
+     * @return
+     */
+    public AreaStaffInfo saveStaffType(AreaStaffInfo areaInfo){
+        AreaStaffInfo areaMasterInfo = new AreaStaffInfo();
+        areaMasterInfo.setParent(areaInfo);
+        if(StringUtils.isNotBlank(areaInfo.getHierarchy())){
+            areaMasterInfo.setHierarchy(String.valueOf(Integer.parseInt(areaInfo.getHierarchy()) + 1));
+        }else{
+            areaMasterInfo.setHierarchy("3");
+        }
+        areaMasterInfo.setStandardDetail("地区员工");
+        areaMasterInfo.setType("staff");
+        areaMasterInfo.setOrderNum(areaMasterInfo.getParent().getOrderNum() + "01");
+        areaMasterInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+        super.save(areaMasterInfo);
+        return areaMasterInfo;
+    }
+
+    /**
+     * 添加地区信息参数
+     * @param officeInfo
+     * @param areaId
+     * @return
+     */
+    public AreaStaffInfo saveAreaType(AreaStaffInfo officeInfo, String areaId){
+        AreaStaffInfo areaMasterInfo = new AreaStaffInfo();
+        areaMasterInfo.setParent(officeInfo);
+        if(StringUtils.isNotBlank(officeInfo.getHierarchy())){
+            areaMasterInfo.setHierarchy(String.valueOf(Integer.parseInt(officeInfo.getHierarchy()) + 1));
+        }else{
+            areaMasterInfo.setHierarchy("2");
+        }
+        areaMasterInfo.setStandardDetail(areaId);
+        areaMasterInfo.setOrderNum(areaMasterInfo.getParent().getOrderNum() + "01");
+        areaMasterInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+        super.save(areaMasterInfo);
+        return areaMasterInfo;
+    }
+
+    /**
+     * 添加部门信息参数
+     * @param officeId
+     * @return
+     */
+    public AreaStaffInfo saveOfficeType(String officeId){
+
+        AreaStaffInfo officeParentInfo = new AreaStaffInfo();
+        officeParentInfo.setId("0");
+        AreaStaffInfo officeInfo = new AreaStaffInfo();
+        officeInfo.setParent(officeParentInfo);
+        officeInfo.setCompanyId(UserUtils.getSelectCompany().getId());
+        officeInfo.setOrderNum("1");
+        officeInfo.setHierarchy("1");
+        officeInfo.setStandardDetail(officeId);
+
+        super.save(officeInfo);
+        return officeInfo;
+    }
+
+    public AreaStaffInfo getMasterStateByUserId(String userId){
+        return dao.getMasterStateByUserId(userId);
+    }
+
+}

+ 457 - 0
src/main/java/com/jeeplus/modules/areaStaff/web/AreaStaffController.java

@@ -0,0 +1,457 @@
+package com.jeeplus.modules.areaStaff.web;
+
+import com.google.common.collect.Lists;
+import com.google.common.collect.Maps;
+import com.jeeplus.common.config.Global;
+import com.jeeplus.common.utils.Collections3;
+import com.jeeplus.common.utils.MyBeanUtils;
+import com.jeeplus.common.utils.StringUtils;
+import com.jeeplus.common.web.BaseController;
+import com.jeeplus.modules.areaStaff.entity.AreaStaffInfo;
+import com.jeeplus.modules.areaStaff.service.AreaStaffService;
+import com.jeeplus.modules.sys.entity.Area;
+import com.jeeplus.modules.sys.entity.Office;
+import com.jeeplus.modules.sys.entity.Role;
+import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.service.AreaService;
+import com.jeeplus.modules.sys.service.OfficeService;
+import com.jeeplus.modules.sys.service.SystemService;
+import com.jeeplus.modules.sys.utils.UserUtils;
+import org.apache.shiro.authz.annotation.Logical;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.Model;
+import org.springframework.web.bind.annotation.ModelAttribute;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RequestParam;
+import org.springframework.web.bind.annotation.ResponseBody;
+import org.springframework.web.servlet.mvc.support.RedirectAttributes;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * @author: 徐滕
+ * @version: 2024-06-17 13:59
+ */
+@Controller
+@RequestMapping(value = "${adminPath}/areaStaff/areaStaff")
+public class AreaStaffController extends BaseController {
+    @Autowired
+    private AreaStaffService areaStaffService;
+    @Autowired
+    private OfficeService officeService;
+    @Autowired
+    private AreaService areaService;
+    @Autowired
+    private SystemService systemService;
+
+    @ModelAttribute
+    public AreaStaffInfo get(@RequestParam(required=false) String id) {
+        AreaStaffInfo entity = null;
+        if (StringUtils.isNotBlank(id)){
+            entity = areaStaffService.get(id);
+        }
+        if (entity == null){
+            entity = new AreaStaffInfo();
+        }
+        return entity;
+    }
+
+    /**
+     * 报销类型列表页面
+     * @param areaStaffInfo
+     * @param model
+     * @return
+     */
+    @RequiresPermissions("areaStaff:areaStaff:list")
+    @RequestMapping(value = {"list", ""})
+    public String list(AreaStaffInfo areaStaffInfo, HttpServletRequest request, HttpServletResponse response, Model model) {
+        //进行查询之后进行任何操作,返回还是查询之后的数据页面
+        if (StringUtils.isNotBlank(areaStaffInfo.getToflag())){
+            request.getSession().removeAttribute("searchReimbursementTypeInfo");
+            AreaStaffInfo searchInvoice=areaStaffInfo;
+            request.getSession().setAttribute("searchReimbursementTypeInfo",searchInvoice);
+        }else{
+            if (request.getSession().getAttribute("searchReimbursementTypeInfo")!=null){
+                areaStaffInfo= (AreaStaffInfo) request.getSession().getAttribute("searchReimbursementTypeInfo");
+                model.addAttribute("areaStaffInfo", areaStaffInfo);
+            }
+        }
+        List<AreaStaffInfo> list = areaStaffService.findList(areaStaffInfo);
+        areaStaffService.queryProofread(list);
+        model.addAttribute("list", list);
+        return "modules/areaStaff/areaStaffList";
+    }
+
+    /**
+     * 查看,增加,编辑报销类型表单页面
+     * @param areaStaffInfo
+     * @param model
+     * @return
+     */
+    @RequiresPermissions(value={"areaStaff:areaStaff:add","areaStaff:areaStaff:edit"},logical= Logical.OR)
+    @RequestMapping(value = "form")
+    public String form(AreaStaffInfo areaStaffInfo, Model model) {
+        if(areaStaffInfo!=null&&areaStaffInfo.getParent()!=null&&StringUtils.isNotBlank(areaStaffInfo.getParent().getId())){
+            AreaStaffInfo parent = areaStaffService.get(areaStaffInfo.getParent().getId());
+            areaStaffInfo.setParent(parent);
+            List<AreaStaffInfo> list = new ArrayList<>();
+            list.add(areaStaffInfo);
+            areaStaffService.queryProofread(list);
+        }else{
+            AreaStaffInfo parent = new AreaStaffInfo();
+            parent.setId("0");
+            parent.setOrderNum("0");
+            areaStaffInfo.setHierarchy("1");
+            assert areaStaffInfo != null;
+            areaStaffInfo.setParent(parent);
+            List<AreaStaffInfo> list = new ArrayList<>();
+            list.add(areaStaffInfo);
+            areaStaffService.queryProofread(list);
+        }
+        model.addAttribute("areaStaffInfo", areaStaffInfo);
+        return "modules/areaStaff/areaStaffForm";
+    }
+
+    /**
+     * 查看,增加,编辑报销类型表单页面
+     * @param areaStaffInfo
+     * @param model
+     * @return
+     */
+    @RequiresPermissions(value={"areaStaff:areaStaff:add","areaStaff:areaStaff:edit"},logical= Logical.OR)
+    @RequestMapping(value = "secondForm")
+    public String secondForm(AreaStaffInfo areaStaffInfo, Model model) {
+        if(areaStaffInfo!=null&&areaStaffInfo.getParent()!=null&&StringUtils.isNotBlank(areaStaffInfo.getParent().getId())){
+            AreaStaffInfo parent = areaStaffService.get(areaStaffInfo.getParent().getId());
+            if(StringUtils.isNotBlank(parent.getHierarchy())){
+                areaStaffInfo.setHierarchy(String.valueOf(Integer.parseInt(parent.getHierarchy()) + 1));
+            }else{
+                areaStaffInfo.setHierarchy("1");
+            }
+            if(null != parent && "0".equals(parent.getParentId())){
+                Office office = officeService.get(parent.getStandardDetail());
+                areaStaffInfo.setOffice(office);
+            }
+            areaStaffInfo.setParent(parent);
+            List<AreaStaffInfo> list = new ArrayList<>();
+            list.add(areaStaffInfo);
+            areaStaffService.queryProofread(list);
+        }else{
+            AreaStaffInfo parent = new AreaStaffInfo();
+            parent.setId("0");
+            parent.setOrderNum("0");
+            areaStaffInfo.setHierarchy("1");
+            assert areaStaffInfo != null;
+            areaStaffInfo.setParent(parent);
+            List<AreaStaffInfo> list = new ArrayList<>();
+            list.add(areaStaffInfo);
+            areaStaffService.queryProofread(list);
+        }
+        model.addAttribute("areaStaffInfo", areaStaffInfo);
+        return "modules/areaStaff/areaStaffSecondForm";
+    }
+
+    /**
+     * 查看,增加,编辑报销类型表单页面
+     * @param areaStaffInfo
+     * @param model
+     * @return
+     */
+    @RequiresPermissions(value={"areaStaff:areaStaff:add","areaStaff:areaStaff:edit"},logical= Logical.OR)
+    @RequestMapping(value = "userForm")
+    public String userForm(AreaStaffInfo areaStaffInfo, Model model) {
+        if(areaStaffInfo!=null&&areaStaffInfo.getParent()!=null&&StringUtils.isNotBlank(areaStaffInfo.getParent().getId())){
+            areaStaffInfo = areaStaffService.get(areaStaffInfo.getParent().getId());
+            List<AreaStaffInfo> list = new ArrayList<>();
+            list.add(areaStaffInfo);
+            areaStaffService.queryProofread(list);
+        }
+        areaStaffService.circulationGetParent(areaStaffInfo);
+        List<Area> areaList = Lists.newArrayList();
+        areaList = areaStaffService.disposeParentArea(areaStaffInfo,areaList);
+        if(areaList.size()>0){
+            areaStaffInfo.setArea(areaList.get(0));
+        }
+        List<Office> officeList = Lists.newArrayList();
+        officeList = areaStaffService.disposeParentOffice(areaStaffInfo,officeList);
+        if(officeList.size()>0){
+            areaStaffInfo.setOffice(officeList.get(0));
+        }
+
+        List<User> userList = areaStaffService.getUserByParentId(areaStaffInfo);
+        model.addAttribute("userList", userList);
+
+        model.addAttribute("areaStaffInfo", areaStaffInfo);
+        return "modules/areaStaff/areaStaffUserForm";
+    }
+
+    /**
+     * 查看报销类型
+     * @param areaStaffInfo
+     * @param model
+     * @return
+     */
+    @RequestMapping(value = "view")
+    public String view(AreaStaffInfo areaStaffInfo, Model model) {
+        if(areaStaffInfo!=null&&areaStaffInfo.getParent()!=null&&StringUtils.isNotBlank(areaStaffInfo.getParent().getId())){
+            AreaStaffInfo parent = areaStaffService.get(areaStaffInfo.getParent().getId());
+            areaStaffInfo.setParent(parent);
+            List<AreaStaffInfo> list = new ArrayList<>();
+            list.add(areaStaffInfo);
+            areaStaffService.queryProofread(list);
+        }
+        switch (areaStaffInfo.getHierarchy()){
+            case "1":
+                Office office = officeService.get(areaStaffInfo.getStandardDetail());
+                areaStaffInfo.setOffice(office);
+                break;
+            case "2":
+
+                office = officeService.get(areaStaffInfo.getParent().getStandardDetail());
+                areaStaffInfo.setOffice(office);
+
+                Area area = areaService.get(areaStaffInfo.getStandardDetail());
+                areaStaffInfo.setArea(area);
+                break;
+            case "4":
+                break;
+            default:
+                break;
+        }
+        model.addAttribute("areaStaffInfo", areaStaffInfo);
+        return "modules/areaStaff/areaStaffView";
+    }
+
+    /**
+     * 保存报销类型
+     * @param areaStaffInfo
+     * @param model
+     * @param redirectAttributes
+     * @return
+     * @throws Exception
+     */
+    @RequiresPermissions(value={"areaStaff:areaStaff:add","areaStaff:areaStaff:edit"},logical=Logical.OR)
+    @RequestMapping(value = "save")
+    public String save(AreaStaffInfo areaStaffInfo, Model model, RedirectAttributes redirectAttributes) throws Exception{
+        if(null == areaStaffInfo.getParent()){
+            AreaStaffInfo parentAreaStaffInfo = new AreaStaffInfo();
+            parentAreaStaffInfo.setId("0");
+            parentAreaStaffInfo.setOrderNum("0");
+            areaStaffInfo.setHierarchy("1");
+            areaStaffInfo.setParent(parentAreaStaffInfo);
+        }
+        if (!beanValidator(model, areaStaffInfo)){
+            return form(areaStaffInfo, model);
+        }
+        if(!areaStaffInfo.getIsNewRecord()){//编辑表单保存
+            AreaStaffInfo t = areaStaffService.get(areaStaffInfo.getId());//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(areaStaffInfo, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+            areaStaffService.save(t);//保存
+        }else{//新增表单保存
+            areaStaffService.save(areaStaffInfo);//保存
+        }
+        addMessage(redirectAttributes, "保存报销类型成功");
+        return "redirect:"+ Global.getAdminPath()+"/areaStaff/areaStaff/?repage";
+    }
+
+    /**
+     * 保存报销类型
+     * @param areaStaffInfo
+     * @param model
+     * @param redirectAttributes
+     * @return
+     * @throws Exception
+     */
+    @RequiresPermissions(value={"areaStaff:areaStaff:add","areaStaff:areaStaff:edit"},logical=Logical.OR)
+    @RequestMapping(value = "secondSave")
+    public String secondSave(AreaStaffInfo areaStaffInfo, Model model, RedirectAttributes redirectAttributes) throws Exception{
+        if(null == areaStaffInfo.getParent()){
+            AreaStaffInfo parentAreaStaffInfo = new AreaStaffInfo();
+            parentAreaStaffInfo.setId(areaStaffInfo.getOffice().getId());
+            parentAreaStaffInfo.setOrderNum("0");
+            areaStaffInfo.setParent(parentAreaStaffInfo);
+        }
+        if (!beanValidator(model, areaStaffInfo)){
+            return form(areaStaffInfo, model);
+        }
+
+        //查询选择的office是否存在,若存在则判定area是否存在,若存在则抛出,若不存在则进行新增
+        //查询选择的office是否存在,若不存在,则进行新增office,在新增地区
+        AreaStaffInfo effectiveArea = areaStaffService.getEffectiveArea(areaStaffInfo.getOffice().getId(), areaStaffInfo.getArea().getId());
+        if(null != effectiveArea){
+            addMessage(redirectAttributes, "该地区已经被选择,请勿重新选择");
+            return "redirect:"+ Global.getAdminPath()+"/areaStaff/areaStaff/?repage";
+        }
+
+        if(!areaStaffInfo.getIsNewRecord()){//编辑表单保存
+            AreaStaffInfo t = areaStaffService.get(areaStaffInfo.getId());//从数据库取出记录的值
+            MyBeanUtils.copyBeanNotNull2Bean(areaStaffInfo, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+            areaStaffService.secondSave(t);//保存
+        }else{//新增表单保存
+            areaStaffService.secondSave(areaStaffInfo);//保存
+        }
+        addMessage(redirectAttributes, "保存报销类型成功");
+        return "redirect:"+ Global.getAdminPath()+"/areaStaff/areaStaff/?repage";
+    }
+
+    /**
+     * 删除报销类型
+     * @param areaStaffInfo
+     * @param redirectAttributes
+     * @return
+     */
+    @RequiresPermissions("areaStaff:areaStaff:del")
+    @RequestMapping(value = "delete")
+    public String delete(AreaStaffInfo areaStaffInfo, RedirectAttributes redirectAttributes) {
+        areaStaffService.delete(areaStaffInfo);
+        addMessage(redirectAttributes, "删除地区信息成功");
+        return "redirect:"+Global.getAdminPath()+"/areaStaff/areaStaff/?repage";
+    }
+
+
+
+    /**
+     * 获取机构JSON数据。
+     *
+     * @param extId    排除的ID
+     * @return
+     */
+    @RequiresPermissions("user")
+    @ResponseBody
+    @RequestMapping(value = "treeData")
+    public List<Map<String, Object>> treeData(@RequestParam(required = false) String extId,@RequestParam(required = false) String selectName) {
+        List<Map<String, Object>> mapList = Lists.newArrayList();
+        AreaStaffInfo areaStaffInfo =new AreaStaffInfo();
+        if (null != selectName && "" != selectName){
+            areaStaffInfo.setStandardDetail(selectName);
+        }
+        List<AreaStaffInfo> list = areaStaffService.findTreeList(areaStaffInfo);
+        for (int i = 0; i < list.size(); i++) {
+            AreaStaffInfo e = list.get(i);
+            if ((StringUtils.isBlank(extId) || (extId != null && !extId.equals(e.getId()) && e.getParentIds().indexOf("," + extId + ",") == -1)) ) {
+                Map<String, Object> map = Maps.newHashMap();
+                map.put("id", e.getId());
+                map.put("pId", e.getParentId());
+                map.put("pIds", e.getParentIds());
+                map.put("name", e.getStandardDetail());
+                map.put("grade", e.getGrade());
+                mapList.add(map);
+            }
+        }
+        return mapList;
+    }
+
+    @ResponseBody
+    @RequestMapping(value = "getEffectiveArea")
+    public Map<String, Object> getEffectiveArea(String officeId,String areaId) {
+        Map<String,Object> map = new HashMap();
+        if(StringUtils.isNotBlank(officeId) && StringUtils.isNotBlank(areaId)){
+            AreaStaffInfo info = areaStaffService.getEffectiveArea(officeId,areaId);
+            if(null != info){
+                map.put("success",false);
+                map.put("message","该地区已经被选择,请勿重新选择");
+            }else{
+                map.put("success",true);
+                map.put("message","该地区可被选择");
+            }
+        }else{
+            map.put("success",false);
+            map.put("message","该地区已经被选择,请勿重新选择");
+        }
+        return map;
+    }
+
+
+    /**
+     * 查询已添加人员信息
+     * @param areaStaffInfo
+     * @param model
+     * @return
+     */
+    @RequestMapping(value = "getUserList")
+    public String selectUserToRole(AreaStaffInfo areaStaffInfo, Model model) {
+        List<User> userList = areaStaffService.getUserByParentId(areaStaffInfo);
+        model.addAttribute("areaStaffInfo", areaStaffInfo);
+        model.addAttribute("userList", userList);
+        model.addAttribute("selectIds", Collections3.extractToString(userList, "id", ","));
+        model.addAttribute("officeList", officeService.findAll());
+        return "modules/areaStaff/selectUserToStaff";
+    }
+
+
+    /**
+     * 获取公司部门人员信息
+     * @param userId
+     * @param response
+     * @return
+     */
+    @ResponseBody
+    @RequestMapping(value = "checkUserCompany")
+    public String checkUserCompany(String userId,String id,HttpServletResponse response) {
+        AreaStaffInfo areaStaffInfo = new AreaStaffInfo();
+        areaStaffInfo.setStandardDetail(userId);
+        areaStaffInfo.setId(id);
+        List<User> userList = areaStaffService.getUserByParentId(areaStaffInfo);
+        for (User user : userList) {
+            if(user.getId().equals(userId)){
+                return "true";
+            }
+        }
+        return "false";
+    }
+
+    /**
+     * 岗位分配
+     * @param areaStaffInfo
+     * @param idsArr
+     * @param redirectAttributes
+     * @return
+     */
+    @RequestMapping(value = "assignUser")
+    public String assignRole(AreaStaffInfo areaStaffInfo, String[] idsArr, RedirectAttributes redirectAttributes) {
+        StringBuilder msg = new StringBuilder();
+        int newNum = 0;
+        for (int i = 0; i < idsArr.length; i++) {
+            User user = systemService.getUser(idsArr[i]);
+            //将人员信息进行添加到对应数据节点下(需先验证是否存在重复值)
+            User saveUser = areaStaffService.saveUser(areaStaffInfo, user);
+
+            if (null != saveUser && StringUtils.isNotBlank(saveUser.getId()) && !saveUser.getId().equals("1")) {
+                msg.append(",新增用户【" + saveUser.getName() + "】成功!");
+                newNum++;
+            }else if(null == saveUser || StringUtils.isBlank(saveUser.getId())) {
+                msg.append(",新增用户【" + user.getName() + "】失败!");
+            }
+        }
+        addMessage(redirectAttributes, "已成功分配 "+newNum+" 个用户"+msg);
+        return "redirect:" + adminPath + "/areaStaff/areaStaff/userForm?parent.id="+areaStaffInfo.getId();
+    }
+
+    /**
+     * 人员信息移除
+     * @param userId
+     * @param id
+     * @param redirectAttributes
+     * @return
+     */
+    @RequestMapping(value = "outUser")
+    public String outUser(String userId,String id,String view,RedirectAttributes redirectAttributes) {
+        User user = systemService.getUser(userId);
+
+        Boolean flag = areaStaffService.outUserById(userId, id);
+        if (!flag) {
+            addMessage(redirectAttributes, "用户【" + user.getName() + "】移除失败!");
+        }else {
+            addMessage(redirectAttributes, "用户【" + user.getName() + "】移除成功!");
+        }
+        return "redirect:" + adminPath + "/areaStaff/areaStaff/userForm?parent.id=" + id;
+    }
+
+}

+ 9 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/entity/RuralReportConsultant.java

@@ -22,6 +22,7 @@ public class RuralReportConsultant extends DataEntity<RuralReportConsultant> {
     private String idCard;          //身份证号
     private Double wcyysrbl;        //完成营业收入比例( %)
     private Double wcyysr;          //完成营业收入(元)
+    private String signatureStampUrl;          //签字章
 
     public String getZixunyuanId() {
         return zixunyuanId;
@@ -142,4 +143,12 @@ public class RuralReportConsultant extends DataEntity<RuralReportConsultant> {
     public void setWcyysr(Double wcyysr) {
         this.wcyysr = wcyysr;
     }
+
+    public String getSignatureStampUrl() {
+        return signatureStampUrl;
+    }
+
+    public void setSignatureStampUrl(String signatureStampUrl) {
+        this.signatureStampUrl = signatureStampUrl;
+    }
 }

+ 29 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageAllService.java

@@ -1713,6 +1713,35 @@ public class RuralProjectMessageAllService extends CrudService<RuralProjectMessa
         return page;
     }
 
+    public Page<RuralProjectRecords> findSignatureCZPage(Page<RuralProjectRecords> page, RuralProjectRecords projectRecords) {
+        //设置数据权限
+        if(!UserUtils.getUser().isAdmin()) {
+            String dataScopeSql = dataScopeFilterOR(projectRecords.getCurrentUser(), "o", "u", "s", MenuStatusEnum.PROJECT_SIGNATURE_CZ.getValue());
+            projectRecords.getSqlMap().put("dsf", dataScopeSql);
+        }
+        //查询超期时间天数
+        List<MainDictDetail> adventCount = DictUtils.getMainDictListOnProjectAdvent("advent_count");
+        if(adventCount.size()>0){
+            //获取超期时间天数转int
+            Integer endingCount = Integer.parseInt(adventCount.get(0).getLabel());
+            projectRecords.setEndingCount(endingCount);
+        }
+        if(null!= projectRecords.getOffice() && StringUtils.isNotBlank(projectRecords.getOffice().getId())){
+            //查询该选择节点下所有的部门Id
+            List<String> officeIdList = officeService.getChildrenOffice(projectRecords.getOffice().getId());
+            officeIdList.add(projectRecords.getOffice().getId());
+            projectRecords.setOfficeIdList(officeIdList);
+        }
+
+        int count = dao.querySignatureCount(projectRecords);
+        page.setCount(count);
+        page.setCountFlag(false);
+        projectRecords.setPage(page);
+        List<RuralProjectRecords> recordsList = dao.findSignatureList(projectRecords);
+        page.setList(recordsList);
+        return page;
+    }
+
     /**
      * 根据项目id进行电子归档的批量驳回操作
      * @param projectIdList

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1074 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageService.java


파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 2543 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/changZhouSignature/RuralProjectMessageElectronicSealCZService.java


+ 305 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/thread/ApprovalCZThread.java

@@ -0,0 +1,305 @@
+package com.jeeplus.modules.ruralprojectrecords.thread;
+
+import com.alibaba.fastjson.JSON;
+import com.google.common.collect.Lists;
+import com.jeeplus.common.config.Global;
+import com.jeeplus.common.oss.OSSClientUtil;
+import com.jeeplus.common.utils.SpringContextHolder;
+import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
+import com.jeeplus.modules.projectcontentinfo.service.ProjectReportDataService;
+import com.jeeplus.modules.ruralprojectrecords.dao.RuralProjectMessageElectronicSealDao;
+import com.jeeplus.modules.ruralprojectrecords.entity.ProjectApprovalSignature;
+import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecords;
+import com.jeeplus.modules.ruralprojectrecords.enums.ProjectStatusEnum;
+import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectMessageService;
+import com.jeeplus.modules.sys.entity.Office;
+import com.jeeplus.modules.sys.entity.Workattachment;
+import com.jeeplus.modules.sys.service.WorkattachmentService;
+import com.jeeplus.modules.sys.utils.UserUtils;
+import com.jeeplus.modules.tools.utils.SignaturePostUtil;
+import com.jeeplus.modules.workactivity.service.WorkActivityProcessService;
+import com.jeeplus.modules.workprojectnotify.entity.WorkProjectNotify;
+import com.jeeplus.modules.workprojectnotify.service.WorkProjectNotifyService;
+import com.jeeplus.modules.workprojectnotify.util.UtilNotify;
+import org.apache.commons.lang3.StringUtils;
+
+import java.io.File;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * @author: 徐滕
+ * @create: 2021-12-07 16:36
+ **/
+public class ApprovalCZThread extends Thread {
+
+    private ProjectReportDataService projectReportDataService = SpringContextHolder.getBean(ProjectReportDataService.class);
+    private WorkattachmentService workattachmentService = SpringContextHolder.getBean(WorkattachmentService.class);
+    private RuralProjectMessageService ruralProjectMessageService = SpringContextHolder.getBean(RuralProjectMessageService.class);
+    private WorkActivityProcessService workActivityProcessService = SpringContextHolder.getBean(WorkActivityProcessService.class);
+    private WorkProjectNotifyService workProjectNotifyService = SpringContextHolder.getBean(WorkProjectNotifyService.class);
+    private RuralProjectMessageElectronicSealDao dao = SpringContextHolder.getBean(RuralProjectMessageElectronicSealDao.class);
+
+    private RuralProjectRecords ruralProjectRecords;
+    private ProjectApprovalSignature projectReportSignature;
+    private ProjectReportData projectReportData;
+    private Office office;
+    String documentId = "";
+
+
+    public ApprovalCZThread(RuralProjectRecords ruralProjectRecords, ProjectApprovalSignature projectReportSignature, ProjectReportData projectReportData, Office office)
+    {
+        this.ruralProjectRecords = ruralProjectRecords;
+        this.projectReportSignature = projectReportSignature;
+        this.projectReportData = projectReportData;
+        this.office = office;
+    }
+
+    public void run(){
+        Boolean bool = true;
+        String disposeResult = "";
+        //下载审定单文件
+        String deleteFile = null;
+        try {
+            //进行签章调用
+            //根据项目id查询是否已经提交过了审定单签章
+            if(null == projectReportData){
+                disposeResult = "查询不到该项目的质量复核信息";
+                bool = false;
+                notification(bool,disposeResult,"","","");
+            }
+            if(null!= projectReportData.getSignatureFlag() && 1 == projectReportData.getSignatureFlag()){
+                disposeResult = "该质量复核已经审定单盖章完成";
+                bool = false;
+                notification(bool,disposeResult,"","","");
+            }
+            if(StringUtils.isBlank(ruralProjectRecords.getProjectMasterId())){
+                disposeResult = "项目负责人为空,无法进行签章";
+                bool = false;
+                notification(bool,disposeResult,"","","");
+            }
+
+            //根据项目id和附件类型的
+            Workattachment workClientAttachment = new Workattachment();
+            workClientAttachment.setAttachmentFlag("194");
+            workClientAttachment.setAttachmentId(ruralProjectRecords.getId());
+            List<Workattachment> fileList = workattachmentService.findList(workClientAttachment);
+            if(fileList.size()>0){
+                Workattachment workattachment = fileList.get(0);
+                if(StringUtils.isBlank(workattachment.getUrl())){
+                    disposeResult = "审定单文件存储路径为空,无法进行签章操作,请驳回后重新上传审定单";
+                    bool = false;
+                    notification(bool,disposeResult,"","","");
+                }
+                //下载审定单文件
+                String path = null;
+                if(System.getProperty("os.name").toLowerCase().contains("win")){
+                    path = "D:/attachment-file/";
+                }else{
+                    path = "/attachment-file/";
+                }
+                String file = workattachment.getUrl();
+                file = file.replace("amp;","");
+                String fileName = file.substring(file.lastIndexOf("/") + 1, file.length());
+                String aliyunUrl = Global.getAliyunUrl();
+                String aliDownloadUrl = Global.getAliDownloadUrl();
+                String cons = "";
+                if (file.contains(aliyunUrl)){
+                    cons = aliyunUrl;
+                }else if (file.contains("http://gangwan-app.oss-cn-hangzhou.aliyuncs.com")){
+                    cons = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com";
+                }else {
+                    cons = aliDownloadUrl;
+                }
+                String ossKey = file.split(cons+"/")[1];
+                new OSSClientUtil().downByStreamSaveLocal(ossKey,fileName,path+fileName);
+                //将下载下来的文件转换为file文件
+                File srcFile = new File(path+fileName);
+                File verticalInvalidFile = new File(path+fileName);
+                deleteFile = path+fileName;
+
+                //截取文件名称
+                String srcFileName = srcFile.getName().substring(0,srcFile.getName().lastIndexOf("."));
+                //截取文件后缀名
+                String substring = srcFile.getName().substring(srcFile.getName().lastIndexOf(".")+1, srcFile.getName().length());
+                if(!"doc".equals(substring.toLowerCase()) && !"docx".equals(substring.toLowerCase()) && !"pdf".equals(substring.toLowerCase())){
+                    disposeResult = "请上传doc、docx或者pdf的文件进行签章操作";
+                    bool = false;
+                    notification(bool,disposeResult,"","","");
+                }
+                //获取真签单的documentId
+                HashMap hashMap = SignaturePostUtil.getDocument(srcFile);
+                String code = hashMap.get("code").toString();
+
+                if("0".equals(code)){
+                    String result = hashMap.get("result").toString();
+                    HashMap documentIdMap = JSON.parseObject(result, HashMap.class);
+                    documentId =  documentIdMap.get("documentId").toString();
+                    if("".equals(documentId)){
+                        bool = false;
+                        disposeResult = "签章文件创建失败";
+                        notification(bool,disposeResult,"","","");
+                    }else{
+                        //签章完成则进行数据的保存
+                        projectReportData.setSignatureFlag(0);
+                        projectReportData.setSignatureDocumentId(documentId);
+                        projectReportData.setSignatureInvalidDocumentId("");
+                        projectReportData.setSignatureContractId("");
+                        projectReportData.setSignatureFileName(srcFileName);
+                        projectReportData.setSignatureUploadFileUser(UserUtils.getUser());
+                        projectReportData.setSignatureUploadDate(new Date());
+                        //修改签章对应信息文件
+                        projectReportDataService.updateSignatureInfo(projectReportData);
+
+
+                        List<String> documentList = Lists.newArrayList();
+                        List<String> invalidDocumentList = Lists.newArrayList();
+                        documentList.add(documentId);
+                        //将空白单的documentId存入数据库种
+                        projectReportData.setSignatureInvalidDocumentId(String.join(",", invalidDocumentList));
+                        //根据项目id 和 documentId生成合同id
+                        HashMap contractIdHashMap = ruralProjectMessageService.getCZSignatureContractId(ruralProjectRecords.getId(), documentList,ruralProjectRecords.getProjectMasterId(),"","");
+                        String contractIdCode = contractIdHashMap.get("code").toString();
+                        String contractId = "";
+                        if("0".equals(contractIdCode)){
+                            contractId = contractIdHashMap.get("contractId").toString();
+                            if("".equals(contractId)){
+                                disposeResult = "签章文件创建失败";
+                                bool = false;
+                                notification(bool,disposeResult,"","","");
+                            }
+                        }else{
+                            bool = false;
+                            disposeResult = contractIdHashMap.get("message").toString();
+                            notification(bool,disposeResult,"","","");
+                        }
+
+                    }
+                }else{
+                    String message = hashMap.get("message").toString();
+                    bool = false;
+                    disposeResult = message;
+                    notification(bool,disposeResult,"","","");
+                }
+            }else{
+                disposeResult = "审定单文件未找到,无法进行签章操作";
+                bool = false;
+                notification(bool,disposeResult,"","","");
+            }
+        }catch (Exception e){
+            if(StringUtils.isBlank(documentId)){
+                bool = false;
+                disposeResult = e.getMessage();
+                notification(bool,disposeResult,"","","");
+            }
+        }finally {
+            if(StringUtils.isNotBlank(deleteFile)){
+                //根据路径创建文件对象
+                File file = new File(deleteFile);
+                //路径是个文件且不为空时删除文件
+                if(file.isFile()&&file.exists()){
+                    file.delete();
+                }
+            }
+        }
+
+    }
+
+    private void notification(Boolean bool,String disposeResult,String documentId,String contractId,String srcFileName){
+        if(bool){
+            //审核完成提示框
+            String title = "报告号【"+projectReportData.getNumber()+"】审定单签章审批登记完成";
+            String content = "报告号【"+projectReportData.getNumber()+"】审定单签章审批登记完成,项目编号:"+ruralProjectRecords.getProjectId();
+            if ("yes".equals(projectReportSignature.getAct().getFlag())) {
+                projectReportSignature.setStatus(ProjectStatusEnum.SIGNED.getValue());
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                workProjectNotifyService
+                        .save(UtilNotify
+                                .saveNotify(projectReportSignature.getId(),
+                                        projectReportSignature.getCreateBy(),
+                                        projectReportSignature.getCompany().getId(),
+                                        title,
+                                        content,
+                                        "194",
+                                        "0",
+                                        "待通知",
+                                        "审批通过"));
+
+            } else {
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                if (projectReportSignature.getStatus()!= ProjectStatusEnum.RECALL.getValue()){
+                    projectReportSignature.setStatus(ProjectStatusEnum.REJECTED.getValue());
+                    workProjectNotifyService
+                            .save(UtilNotify
+                                    .saveNotify(projectReportSignature.getId(),
+                                            projectReportSignature.getCreateBy(),
+                                            projectReportSignature.getCompany().getId(),
+                                            title,
+                                            content,
+                                            "194",
+                                            "0",
+                                            "待通知",
+                                            "审批通过"));
+                }
+            }
+            workActivityProcessService.deleteProcessIdAuditUsers(projectReportSignature.getProcessInstanceId());
+
+            //签章完成则进行数据的保存
+            projectReportData.setSignatureFlag(1);
+            projectReportData.setSignatureDocumentId(documentId);
+            projectReportData.setSignatureContractId(contractId);
+            projectReportData.setSignatureFileName(srcFileName);
+            projectReportData.setSignatureUploadFileUser(UserUtils.getUser());
+            projectReportData.setSignatureUploadDate(new Date());
+            //修改签章对应信息文件
+            projectReportDataService.updateSignatureInfo(projectReportData);
+
+        }else{
+            //审核完成提示框
+            String title = "报告号【"+projectReportData.getNumber()+"】审定单签章失败。原因:"+ disposeResult;
+            String content = "报告号【"+projectReportData.getNumber()+"】审定单签章失败。原因:"+ disposeResult;
+            if ("yes".equals(projectReportSignature.getAct().getFlag())) {
+                projectReportSignature.setStatus(ProjectStatusEnum.SIGNED.getValue());
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                workProjectNotifyService
+                        .save(UtilNotify
+                                .saveNotify(projectReportSignature.getId(),
+                                        projectReportSignature.getCreateBy(),
+                                        projectReportSignature.getCompany().getId(),
+                                        title,
+                                        content,
+                                        "194",
+                                        "0",
+                                        "待通知",
+                                        "审批通过"));
+            } else {
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                if (projectReportSignature.getStatus()!= ProjectStatusEnum.RECALL.getValue()){
+                    projectReportSignature.setStatus(ProjectStatusEnum.REJECTED.getValue());
+                    workProjectNotifyService
+                            .save(UtilNotify
+                                    .saveNotify(projectReportSignature.getId(),
+                                            projectReportSignature.getCreateBy(),
+                                            projectReportSignature.getCompany().getId(),
+                                            title,
+                                            content,
+                                            "194",
+                                            "0",
+                                            "待通知",
+                                            "审批通过"));
+                }
+            }
+            workActivityProcessService.deleteProcessIdAuditUsers(projectReportSignature.getProcessInstanceId());
+
+            projectReportSignature.setStatus(1);
+            dao.updateApprovalSignature(projectReportSignature);
+        }
+
+
+    }
+}

+ 373 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/thread/SignatureCZThread.java

@@ -0,0 +1,373 @@
+package com.jeeplus.modules.ruralprojectrecords.thread;
+
+import com.alibaba.fastjson.JSON;
+import com.google.common.collect.Lists;
+import com.jeeplus.common.config.Global;
+import com.jeeplus.common.oss.OSSClientUtil;
+import com.jeeplus.common.utils.SpringContextHolder;
+import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
+import com.jeeplus.modules.projectcontentinfo.service.ProjectReportDataService;
+import com.jeeplus.modules.ruralprojectrecords.dao.RuralProjectMessageElectronicSealDao;
+import com.jeeplus.modules.ruralprojectrecords.entity.ProjectReportSignature;
+import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecords;
+import com.jeeplus.modules.ruralprojectrecords.enums.ProjectStatusEnum;
+import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectMessageService;
+import com.jeeplus.modules.sys.entity.Office;
+import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.entity.Workattachment;
+import com.jeeplus.modules.sys.service.WorkattachmentService;
+import com.jeeplus.modules.sys.utils.UserUtils;
+import com.jeeplus.modules.tools.utils.SignaturePostUtil;
+import com.jeeplus.modules.workactivity.service.WorkActivityProcessService;
+import com.jeeplus.modules.workprojectnotify.entity.WorkProjectNotify;
+import com.jeeplus.modules.workprojectnotify.service.WorkProjectNotifyService;
+import com.jeeplus.modules.workprojectnotify.util.UtilNotify;
+import org.apache.commons.lang3.StringUtils;
+
+import java.io.File;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.List;
+
+/**
+ * 报告签章线程信息
+ * @author: 徐滕
+ * @create: 2021-12-07 16:36
+ **/
+public class SignatureCZThread extends Thread {
+
+    private ProjectReportDataService projectReportDataService = SpringContextHolder.getBean(ProjectReportDataService.class);
+    private WorkattachmentService workattachmentService = SpringContextHolder.getBean(WorkattachmentService.class);
+    private RuralProjectMessageService ruralProjectMessageService = SpringContextHolder.getBean(RuralProjectMessageService.class);
+    private WorkActivityProcessService workActivityProcessService = SpringContextHolder.getBean(WorkActivityProcessService.class);
+    private WorkProjectNotifyService workProjectNotifyService = SpringContextHolder.getBean(WorkProjectNotifyService.class);
+    private RuralProjectMessageElectronicSealDao dao = SpringContextHolder.getBean(RuralProjectMessageElectronicSealDao.class);
+
+    private RuralProjectRecords ruralProjectRecords;
+    private ProjectReportSignature projectReportSignature;
+    private ProjectReportData projectReportData;
+    private Office office;
+    String documentId = "";
+
+
+    public SignatureCZThread(RuralProjectRecords ruralProjectRecords, ProjectReportSignature projectReportSignature, ProjectReportData projectReportData, Office office)
+    {
+        this.ruralProjectRecords = ruralProjectRecords;
+        this.projectReportSignature = projectReportSignature;
+        this.projectReportData = projectReportData;
+        this.office = office;
+    }
+
+    public void run(){
+        Boolean bool = true;
+        String disposeResult = "";
+        //下载审定单文件
+        String deleteFile = null;
+        try {
+            //进行签章调用
+            //根据项目id查询是否已经提交过了审定单签章
+            if(null == ruralProjectRecords){
+                bool = false;
+                disposeResult =  "查询不到该项目信息";
+                notification(bool,disposeResult,"","","");
+            }
+            if(null!= ruralProjectRecords.getReportSignatureFlag() && 1 == ruralProjectRecords.getReportSignatureFlag()){
+                bool = false;
+                disposeResult =  "该项目已经报告盖章完成";
+                notification(bool,disposeResult,"","","");
+            }
+            if(StringUtils.isBlank(ruralProjectRecords.getProjectMasterId())){
+                bool = false;
+                disposeResult =  "项目负责人为空,无法进行签章";
+                notification(bool,disposeResult,"","","");
+            }
+
+            //根据项目id和附件类型的
+            Workattachment workClientAttachment = new Workattachment();
+            workClientAttachment.setAttachmentFlag("195");
+            workClientAttachment.setAttachmentId(ruralProjectRecords.getId());
+            List<Workattachment> fileList = workattachmentService.findList(workClientAttachment);
+            if(fileList.size()>0){
+                Workattachment workattachment = fileList.get(0);
+                if(StringUtils.isBlank(workattachment.getUrl())){
+                    bool = false;
+                    disposeResult =  "报告签章文件存储路径为空,无法进行签章操作,请驳回后重新上传审定单";
+                    notification(bool,disposeResult,"","","");
+                }
+                //下载审定单文件
+                String path = null;
+                if(System.getProperty("os.name").toLowerCase().contains("win")){
+                    path = "D:/attachment-file/";
+                }else{
+                    path = "/attachment-file/";
+                }
+                String file = workattachment.getUrl();
+                file = file.replace("amp;","");
+                String fileName = file.substring(file.lastIndexOf("/") + 1, file.length());
+                String aliyunUrl = Global.getAliyunUrl();
+                String aliDownloadUrl = Global.getAliDownloadUrl();
+                String cons = "";
+                if (file.contains(aliyunUrl)){
+                    cons = aliyunUrl;
+                }else if (file.contains("http://gangwan-app.oss-cn-hangzhou.aliyuncs.com")){
+                    cons = "http://gangwan-app.oss-cn-hangzhou.aliyuncs.com";
+                }else {
+                    cons = aliDownloadUrl;
+                }
+                String ossKey = file.split(cons+"/")[1];
+                new OSSClientUtil().downByStreamSaveLocal(ossKey,fileName,path+fileName);
+                //将下载下来的文件转换为file文件
+                File srcFile = new File(path+fileName);
+                deleteFile = path+fileName;
+
+                //截取文件名称
+                String srcFileName = srcFile.getName().substring(0,srcFile.getName().lastIndexOf("."));
+                //截取文件后缀名
+                String substring = srcFile.getName().substring(srcFile.getName().lastIndexOf(".")+1, srcFile.getName().length());
+                if(!"doc".equals(substring.toLowerCase()) && !"docx".equals(substring.toLowerCase()) && !"pdf".equals(substring.toLowerCase())){
+                    disposeResult =  "请上传doc、docx或者pdf的文件进行签章操作";
+                    bool = false;
+                    notification(bool,disposeResult,"","","");
+                }else{
+
+                    //获取真签单的documentId
+                    HashMap hashMap = SignaturePostUtil.getDocument(srcFile);
+                    String code = hashMap.get("code").toString();
+
+                    if("0".equals(code)){
+                        String result = hashMap.get("result").toString();
+                        HashMap documentIdMap = JSON.parseObject(result, HashMap.class);
+                        documentId =  documentIdMap.get("documentId").toString();
+                        if("".equals(documentId)){
+                            disposeResult =  "签章文件创建失败";
+                            bool = false;
+                            notification(bool,disposeResult,"","","");
+                        }else{
+                            //先将数据进行保存
+                            //签章完成则进行数据的保存
+                            ruralProjectRecords.setReportSignatureFlag(0);
+                            ruralProjectRecords.setReportSignatureDocumentId(documentId);
+                            ruralProjectRecords.setReportSignatureContractId("");
+                            ruralProjectRecords.setReportSignatureFileName(srcFileName);
+                            ruralProjectRecords.setReportSignatureUploadFileUser(UserUtils.getUser());
+                            ruralProjectRecords.setReportSignatureUploadDate(new Date());
+                            //修改签章对应信息文件
+                            projectReportDataService.updateReportSignatureInfo(ruralProjectRecords);
+
+
+
+                            List<String> documentList = Lists.newArrayList();
+                            documentList.add(documentId);
+                            //根据项目id 和 documentId生成合同id
+                            long s1 = System.currentTimeMillis();
+                            HashMap contractIdHashMap = ruralProjectMessageService.getReportCZSignatureContractId(ruralProjectRecords.getId(), documentList,ruralProjectRecords.getProjectMasterId(),"");
+                            String contractIdCode = contractIdHashMap.get("code").toString();
+                            String contractId = "";
+                            if("0".equals(contractIdCode)){
+                                contractId = contractIdHashMap.get("contractId").toString();
+                                if("".equals(contractId)){
+                                    disposeResult =  "签章文件创建失败";
+                                    bool = false;
+                                    notification(bool,disposeResult,"","","");
+                                }
+                            }else{
+                                disposeResult =  contractIdHashMap.get("message").toString();
+                                bool = false;
+                                notification(bool,disposeResult,"","","");
+                            }
+                            long s2 = System.currentTimeMillis();
+                            System.out.println("创建签章合同用时:" + (s2-s1));
+                        }
+                    }else{
+                        String message = hashMap.get("message").toString();
+                        disposeResult =  message;
+                        bool = false;
+                        notification(bool,disposeResult,"","","");
+                    }
+                }
+
+
+
+
+                //进行静默签署
+                /*long s3 = System.currentTimeMillis();
+                HashMap signbyCompanyHashMap = ruralProjectMessageService.signbyCompanyByKeyWord(contractId,documentList);
+                if(null != signbyCompanyHashMap){
+                    String signbyCompanyCode = signbyCompanyHashMap.get("code").toString();
+                    String signbyCompanyMessage = signbyCompanyHashMap.get("message").toString();
+                    if(!"0".equals(signbyCompanyCode) && (!"3001009".equals(signbyCompanyCode) || !"文件状态不是“签署中”".equals(signbyCompanyMessage))){
+                        disposeResult =  signbyCompanyMessage;
+                        bool = false;
+                    }
+                }
+                long s4 = System.currentTimeMillis();
+                System.out.println("进行静默签署用时:" + (s4-s3));*/
+                //notification(bool,disposeResult,documentId,contractId,srcFileName);
+                //将documentId 和contractId存储到质量复核对应的数据种
+            }else{
+                disposeResult =  "报告文件未找到,无法进行签章操作";
+                bool = false;
+                notification(bool,disposeResult,"","","");
+            }
+        }catch (Exception e){
+            if(StringUtils.isBlank(documentId)){
+                bool = false;
+                disposeResult = e.getMessage();
+                notification(bool,disposeResult,"","","");
+            }
+        }finally {
+            if(StringUtils.isNotBlank(deleteFile)){
+                //根据路径创建文件对象
+                File file = new File(deleteFile);
+                //路径是个文件且不为空时删除文件
+                if(file.isFile()&&file.exists()){
+                    file.delete();
+                }
+            }
+        }
+
+    }
+
+    private void notification(Boolean bool,String disposeResult,String documentId,String contractId,String srcFileName){
+        if(bool){
+            //users.add(projectReportSignature.getCreateBy());
+            //审核完成提示框
+            String title = "报告号【"+projectReportData.getNumber()+"】报告签章审批登记完成";
+            String content = "报告号【"+projectReportData.getNumber()+"】报告签章审批登记完成,项目编号:"+ruralProjectRecords.getProjectId();
+            if ("yes".equals(projectReportSignature.getAct().getFlag())) {
+                projectReportSignature.setStatus(ProjectStatusEnum.SIGNED.getValue());
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                //userList = workProjectNotifyService.readByNotifyId(notify);
+                //users.add(projectReportSignature.getCreateBy());
+                workProjectNotifyService
+                        .save(UtilNotify
+                                .saveNotify(projectReportSignature.getId(),
+                                        projectReportSignature.getCreateBy(),
+                                        projectReportSignature.getCompany().getId(),
+                                        title,
+                                        content,
+                                        "195",
+                                        "0",
+                                        "待通知",
+                                        "审批通过"));
+                //给苏州质控中的人员发送通知
+                List<User> szzks = UserUtils.getByRoleActivityEnname("szzk",3,office.getId(),"4",projectReportSignature.getCreateBy());
+                for (User szzk: szzks) {
+                    if(StringUtils.isNotBlank(szzk.getId())){
+                        workProjectNotifyService
+                                .save(UtilNotify
+                                        .saveNotify(projectReportSignature.getId(),
+                                                szzk,
+                                                projectReportSignature.getCompany().getId(),
+                                                title,
+                                                content,
+                                                "195",
+                                                "0",
+                                                "待通知",
+                                                "审批通过"));
+                    }
+                }
+
+            } else {
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                //userList = workProjectNotifyService.readByNotifyId(notify);
+                //users.add(projectReportSignature.getCreateBy());
+                if (projectReportSignature.getStatus()!= ProjectStatusEnum.RECALL.getValue()){
+                    projectReportSignature.setStatus(ProjectStatusEnum.REJECTED.getValue());
+                    workProjectNotifyService
+                            .save(UtilNotify
+                                    .saveNotify(projectReportSignature.getId(),
+                                            projectReportSignature.getCreateBy(),
+                                            projectReportSignature.getCompany().getId(),
+                                            title,
+                                            content,
+                                            "195",
+                                            "0",
+                                            "待通知",
+                                            "审批通过"));
+                }
+            }
+            workActivityProcessService.deleteProcessIdAuditUsers(projectReportSignature.getProcessInstanceId());
+
+            //签章完成则进行数据的保存
+            ruralProjectRecords.setReportSignatureFlag(1);
+            ruralProjectRecords.setReportSignatureDocumentId(documentId);
+            ruralProjectRecords.setReportSignatureContractId(contractId);
+            ruralProjectRecords.setReportSignatureFileName(srcFileName);
+            ruralProjectRecords.setReportSignatureUploadFileUser(UserUtils.getUser());
+            ruralProjectRecords.setReportSignatureUploadDate(new Date());
+            //修改签章对应信息文件
+            projectReportDataService.updateReportSignatureInfo(ruralProjectRecords);
+
+            projectReportSignature.setStatus(5);
+            dao.updateReportSignature(projectReportSignature);
+        }else{
+            //users.add(projectReportSignature.getCreateBy());
+            //审核完成提示框
+            String title = "报告号【"+projectReportData.getNumber()+"】报告签章失败。原因:"+ disposeResult;
+            String content = "报告号【"+projectReportData.getNumber()+"】报告签章失败。原因:"+ disposeResult;
+            if ("yes".equals(projectReportSignature.getAct().getFlag())) {
+                projectReportSignature.setStatus(ProjectStatusEnum.SIGNED.getValue());
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                //userList = workProjectNotifyService.readByNotifyId(notify);
+                //users.add(projectReportSignature.getCreateBy());
+                workProjectNotifyService
+                        .save(UtilNotify
+                                .saveNotify(projectReportSignature.getId(),
+                                        projectReportSignature.getCreateBy(),
+                                        projectReportSignature.getCompany().getId(),
+                                        title,
+                                        content,
+                                        "195",
+                                        "0",
+                                        "待通知",
+                                        "审批通过"));
+                //给苏州质控中的人员发送通知
+                List<User> szzks = UserUtils.getByRoleActivityEnname("szzk",3,office.getId(),"4",projectReportSignature.getCreateBy());
+                for (User szzk: szzks) {
+                    if(StringUtils.isNotBlank(szzk.getId())){
+                        workProjectNotifyService
+                                .save(UtilNotify
+                                        .saveNotify(projectReportSignature.getId(),
+                                                szzk,
+                                                projectReportSignature.getCompany().getId(),
+                                                title,
+                                                content,
+                                                "195",
+                                                "0",
+                                                "待通知",
+                                                "审批通过"));
+                    }
+                }
+            } else {
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                //userList = workProjectNotifyService.readByNotifyId(notify);
+                //users.add(projectReportSignature.getCreateBy());
+                if (projectReportSignature.getStatus()!= ProjectStatusEnum.RECALL.getValue()){
+                    projectReportSignature.setStatus(ProjectStatusEnum.REJECTED.getValue());
+                    workProjectNotifyService
+                            .save(UtilNotify
+                                    .saveNotify(projectReportSignature.getId(),
+                                            projectReportSignature.getCreateBy(),
+                                            projectReportSignature.getCompany().getId(),
+                                            title,
+                                            content,
+                                            "195",
+                                            "0",
+                                            "待通知",
+                                            "审批通过"));
+                }
+            }
+            workActivityProcessService.deleteProcessIdAuditUsers(projectReportSignature.getProcessInstanceId());
+
+            projectReportSignature.setStatus(1);
+            dao.updateReportSignature(projectReportSignature);
+        }
+
+
+    }
+}

+ 299 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectSignatureCallBackController.java

@@ -1091,4 +1091,303 @@ public class RuralProjectSignatureCallBackController extends BaseController {
         requestHeaderMap.put("x-qys-timestamp", "0");
         SignaturePostUtil.downloadZipGet(HTTPTOP + "/contract/download?contractId="+contractId,requestHeaderMap,ruralProjectRecords.getQualitySignatureFileName()+".zip","",response);
     }
+
+
+
+
+
+
+    /**
+     * 审定单签章回调操作
+     * @param presignCallBack  回调参数
+     * @return
+     */
+    @RequestMapping(value = "/getApprovalCZCoordinates", method=RequestMethod.POST)
+    public String getApprovalCZCoordinates(PresignCallBack presignCallBack, HttpServletRequest request , HttpServletResponse response) {
+        long t1 = System.currentTimeMillis();
+        //根据contractId查询对应的报告信息
+        String[] documentIds = presignCallBack.getDocumentId().split(",");
+        ProjectReportData projectReportData = null;
+        if(documentIds.length>0){
+            projectReportData = projectReportDataService.getProjectReportDataByDocumentId(documentIds[0]);
+        }else{
+            return null;
+        }
+
+        if(null == projectReportData){
+            return null;
+        }
+
+        //根据项目id查询对应的审定单数据状态是否是已经被送审或者 是否存在值
+        ProjectApprovalSignature projectApprovalSignature = ruralProjectMessageElectronicSealService.getProjectApprovalSignature(projectReportData.getProject().getId());
+
+        //根据contractId查询对应的报告信息
+        RuralProjectRecords records = projectRecordsService.get(projectReportData.getProject().getId());
+        if(StringUtils.isBlank(presignCallBack.getContractId())){
+            String title = "报告号【"+projectReportData.getNumber()+"】审定单签章失败。";
+            String content = "报告号【"+projectReportData.getNumber()+"】审定单签章失败。";
+            projectApprovalSignature.setStatus(ProjectStatusEnum.TSTORE.getValue());
+            WorkProjectNotify notify = new WorkProjectNotify();
+            notify.setNotifyId(projectApprovalSignature.getId());
+            workProjectNotifyService
+                    .save(UtilNotify
+                            .saveNotify(projectApprovalSignature.getId(),
+                                    projectApprovalSignature.getCreateBy(),
+                                    projectApprovalSignature.getCompany().getId(),
+                                    title,
+                                    content,
+                                    "194",
+                                    "0",
+                                    "待通知",
+                                    "审批通过"));
+            workActivityProcessService.deleteProcessIdAuditUsers(projectApprovalSignature.getProcessInstanceId());
+
+            projectApprovalSignature.setStatus(1);
+            dao.updateApprovalSignature(projectApprovalSignature);
+            return null;
+        }
+
+        String title = "报告号【"+projectReportData.getNumber()+"】审定单签章审批登记完成";
+        String content = "报告号【"+projectReportData.getNumber()+"】审定单签章审批登记完成,项目编号:"+records.getProjectId();
+        projectApprovalSignature.setStatus(ProjectStatusEnum.SIGNED.getValue());
+        WorkProjectNotify notify = new WorkProjectNotify();
+        notify.setNotifyId(projectApprovalSignature.getId());
+
+        //查询是否已经进行发送通知,没有发送则进行发送,否则  直接跳过
+        List<WorkProjectNotify> byTitle = workProjectNotifyService.getByTitle(title);
+        if(byTitle.size() == 0) {
+            workProjectNotifyService
+                    .save(UtilNotify
+                            .saveNotify(projectApprovalSignature.getId(),
+                                    projectApprovalSignature.getCreateBy(),
+                                    projectApprovalSignature.getCompany().getId(),
+                                    title,
+                                    content,
+                                    "194",
+                                    "0",
+                                    "待通知",
+                                    "审批通过"));
+            workActivityProcessService.deleteProcessIdAuditUsers(projectApprovalSignature.getProcessInstanceId());
+
+
+        }
+        //修改签章信息
+        //签章完成则进行数据的保存
+        projectReportData.setSignatureFlag(1);
+        projectReportData.setSignatureContractId(presignCallBack.getContractId());
+        projectReportData.setSignatureUploadDate(new Date());
+        //对文件回调路径进行处理并保存
+        String signatureUrl = null;
+        if(StringUtils.isNotBlank(presignCallBack.getStoragePath())){
+            signatureUrl = presignCallBack.getStoragePath().replace("oss:/","");
+            projectReportData.setSignatureUrl(signatureUrl);
+        }
+        //修改签章对应信息文件
+        projectReportDataService.updateSignatureInfo(projectReportData);
+
+        projectApprovalSignature.setStatus(5);
+        dao.updateApprovalSignature(projectApprovalSignature);
+        long t2 = System.currentTimeMillis();
+        System.out.println("审定单回调运行耗时:" + (t2-t1) + " 毫秒");
+
+        //将文件存储到项目审定单列表中
+        //签章完成则进行数据的保存
+
+        //将文件存储到对应的档案信息中的“咨询报告书正文”中
+        WorkClientAttachment attchment = new WorkClientAttachment();
+        attchment.setProjectId(records.getId());
+        attchment.setAttachmentId("058ef76b128a4d629acb039017f19161");
+        attchment.setDivIdType("signature");
+        //删除原有的数据信息
+        workattachmentService.deleteByAttachIdAndProject(attchment);
+        //查询原有文件的数据量
+        Integer fileCount = workattachmentService.getAttachmentCountByAttachmentIdAndProjectId(attchment);
+        if( null == fileCount){
+            fileCount = 0;
+        }
+        fileCount = fileCount + 1;
+        if(StringUtils.isNotBlank(signatureUrl)){
+            String fileName = signatureUrl.substring(signatureUrl.lastIndexOf("/")+1,signatureUrl.length());
+            String fileSuffix = fileName.substring(fileName.lastIndexOf(".")+1,fileName.length());
+            attchment.setFileSize("");
+            User user = UserUtils.get(records.getCreateBy().getId());
+            attchment.setCreateBy(user);
+            attchment.setUpdateBy(user);
+            attchment.setUrl(signatureUrl);
+            attchment.setType(fileSuffix);
+            attchment.setAttachmentUser(records.getCreateBy().getId());
+            attchment.setAttachmentName(fileName);
+            attchment.setAttachmentFlag("194");
+            attchment.setSort(fileCount.toString());
+            workattachmentService.insertOnWorkClientAttachment(attchment);
+        }
+
+
+        return null;
+    }
+    /**
+     * 报告签章签署完成回调操作(常州)
+     * @param presignCallBack  回调参数
+     * @return
+     */
+    @RequestMapping(value = "/getSignatureCZCoordinates", method=RequestMethod.POST)
+    public String getSignatureCZCoordinates(PresignCallBack presignCallBack, HttpServletRequest request , HttpServletResponse response) {
+        long t1 = System.currentTimeMillis();
+        //根据contractId查询对应的报告信息
+        String[] documentIds = presignCallBack.getDocumentId().split(",");
+        //根据contractId查询对应的报告信息
+        RuralProjectRecords records = projectRecordsService.getSignatureByDocumentId(documentIds[0]);
+        if(null == records){
+            return null;
+        }
+        ProjectReportData projectReportData = projectReportDataService.getReportDataByProjectId(records.getId());
+        ProjectReportSignature projectReportSignature = ruralProjectMessageElectronicSealService.getProjectReportSignature(records.getId());
+        //如果没有返回contractId 则进行数据暂存处理
+        if(StringUtils.isBlank(presignCallBack.getContractId())){
+            String title = "报告号【"+projectReportData.getNumber()+"】报告签章失败。请重新签章";
+            String content = "报告号【"+projectReportData.getNumber()+"】报告签章失败。请重新签章";
+            if ("yes".equals(projectReportSignature.getAct().getFlag())) {
+                projectReportSignature.setStatus(ProjectStatusEnum.TSTORE.getValue());
+                WorkProjectNotify notify = new WorkProjectNotify();
+                notify.setNotifyId(projectReportSignature.getId());
+                //查询是否已经进行发送通知,没有发送则进行发送,否则  直接跳过
+                List<WorkProjectNotify> byTitle = workProjectNotifyService.getByTitle(title);
+                if(byTitle.size() == 0) {
+                    workProjectNotifyService
+                            .save(UtilNotify
+                                    .saveNotify(projectReportSignature.getId(),
+                                            projectReportSignature.getCreateBy(),
+                                            projectReportSignature.getCompany().getId(),
+                                            title,
+                                            content,
+                                            "195",
+                                            "0",
+                                            "待通知",
+                                            "审批通过"));
+                    //给苏州质控中的人员发送通知
+                    /*List<User> szzks = UserUtils.getByRoleActivityEnname("XHMDZGS1551886525850yczk",3,projectReportSignature.getOffice().getId(),"4",projectReportSignature.getCreateBy());
+                    for (User szzk: szzks) {
+                        if(org.apache.commons.lang3.StringUtils.isNotBlank(szzk.getId())){
+                            workProjectNotifyService
+                                    .save(UtilNotify
+                                            .saveNotify(projectReportSignature.getId(),
+                                                    szzk,
+                                                    projectReportSignature.getCompany().getId(),
+                                                    title,
+                                                    content,
+                                                    "195",
+                                                    "0",
+                                                    "待通知",
+                                                    "审批通过"));
+                        }
+                    }*/
+                }
+
+            }
+
+            workActivityProcessService.deleteProcessIdAuditUsers(projectReportSignature.getProcessInstanceId());
+
+            projectReportSignature.setStatus(1);
+            dao.updateReportSignature(projectReportSignature);
+            return null;
+
+        }
+        //修改签章信息
+
+        //签章完成则进行数据的保存
+        records.setReportSignatureFlag(1);
+        records.setReportSignatureDocumentId(documentIds[0]);
+        records.setReportSignatureContractId(presignCallBack.getContractId());
+        records.setReportSignatureUploadDate(new Date());
+        //对文件回调路径进行处理并保存
+        String signatureUrl = null;
+        if(StringUtils.isNotBlank(presignCallBack.getStoragePath())){
+            signatureUrl = presignCallBack.getStoragePath().replace("oss:/","");
+            records.setReportSignatureUrl(signatureUrl);
+        }
+        //修改签章对应信息文件
+        projectReportDataService.updateReportSignatureInfo(records);
+
+        //发送通知
+        String title = "报告号【"+projectReportData.getNumber()+"】报告签章审批登记完成";
+        String content = "报告号【"+projectReportData.getNumber()+"】报告签章审批登记完成,项目编号:"+records.getProjectId();
+        projectReportSignature.setStatus(ProjectStatusEnum.SIGNED.getValue());
+        WorkProjectNotify notify = new WorkProjectNotify();
+        notify.setNotifyId(projectReportSignature.getId());
+        //查询是否已经进行发送通知,没有发送则进行发送,否则  直接跳过
+        List<WorkProjectNotify> byTitle = workProjectNotifyService.getByTitle(title);
+        if(byTitle.size() == 0) {
+            workProjectNotifyService
+                    .save(UtilNotify
+                            .saveNotify(projectReportSignature.getId(),
+                                    projectReportSignature.getCreateBy(),
+                                    projectReportSignature.getCompany().getId(),
+                                    title,
+                                    content,
+                                    "195",
+                                    "0",
+                                    "待通知",
+                                    "审批通过"));
+            //给苏州质控中的人员发送通知
+            /*List<User> szzks = UserUtils.getByRoleActivityEnnameSignature("XHMDZGS1551886525850yczk",3,projectReportSignature.getOffice().getId(),"4",projectReportSignature.getCreateBy());
+            for (User szzk: szzks) {
+                if(org.apache.commons.lang3.StringUtils.isNotBlank(szzk.getId())){
+                    workProjectNotifyService
+                            .save(UtilNotify
+                                    .saveNotify(projectReportSignature.getId(),
+                                            szzk,
+                                            projectReportSignature.getCompany().getId(),
+                                            title,
+                                            content,
+                                            "195",
+                                            "0",
+                                            "待通知",
+                                            "审批通过"));
+                }
+            }*/
+
+            workActivityProcessService.deleteProcessIdAuditUsers(projectReportSignature.getProcessInstanceId());
+
+
+        }
+        projectReportSignature.setStatus(5);
+        dao.updateReportSignature(projectReportSignature);
+
+
+
+        long t2 = System.currentTimeMillis();
+        System.out.println("报告签章回调运行耗时:" + (t2-t1) + " 毫秒");
+
+        if(StringUtils.isNotBlank(signatureUrl)) {
+            String fileName = signatureUrl.substring(signatureUrl.lastIndexOf("/")+1,signatureUrl.length());
+            //将文件存储到对应的档案信息中的“咨询报告书正文”中
+            WorkClientAttachment attchment = new WorkClientAttachment();
+            attchment.setProjectId(records.getId());
+            attchment.setAttachmentId("6c68d29ea00e4cdb8cf17fb54ee30f0f");
+            attchment.setDivIdType("signature");
+            //删除原有的数据信息
+            workattachmentService.deleteByAttachIdAndProject(attchment);
+            //查询原有文件的数据量
+            Integer fileCount = workattachmentService.getAttachmentCountByAttachmentIdAndProjectId(attchment);
+            if (null == fileCount) {
+                fileCount = 0;
+            }
+            fileCount = fileCount + 1;
+            String fileSuffix = fileName.substring(fileName.lastIndexOf(".") + 1, fileName.length());
+            attchment.setFileSize("");
+            User user = UserUtils.get(records.getCreateBy().getId());
+            attchment.setCreateBy(user);
+            attchment.setUpdateBy(user);
+            attchment.setUrl(signatureUrl);
+            attchment.setType(fileSuffix);
+            attchment.setAttachmentUser(records.getCreateBy().getId());
+            attchment.setAttachmentName(fileName);
+            attchment.setAttachmentFlag("195");
+            attchment.setSort(fileCount.toString());
+            workattachmentService.insertOnWorkClientAttachment(attchment);
+        }
+        return null;
+    }
+
+
 }

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1004 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/changZhouSignature/RuralProjectMessageElectronicSealCZController.java


+ 74 - 3
src/main/java/com/jeeplus/modules/signatureManagement/businessSignature/controller/BusinessSignatureController.java

@@ -2,15 +2,20 @@ package com.jeeplus.modules.signatureManagement.businessSignature.controller;
 
 import com.google.common.collect.Lists;
 import com.jeeplus.common.config.Global;
+import com.jeeplus.common.json.AjaxJson;
 import com.jeeplus.common.persistence.Page;
 import com.jeeplus.common.utils.MyBeanUtils;
 import com.jeeplus.common.utils.StringUtils;
 import com.jeeplus.common.utils.ThisLocalityDownloadUtil;
 import com.jeeplus.common.web.BaseController;
 import com.jeeplus.modules.act.service.ActTaskService;
+import com.jeeplus.modules.areaStaff.entity.AreaStaffInfo;
+import com.jeeplus.modules.areaStaff.service.AreaStaffService;
 import com.jeeplus.modules.ruralprojectrecords.enums.ProjectStatusEnum;
 import com.jeeplus.modules.signatureManagement.businessSignature.entity.BusinessSignatureInfo;
 import com.jeeplus.modules.signatureManagement.businessSignature.service.BusinessSignatureService;
+import com.jeeplus.modules.signatureManagement.electronicSignature.entity.ElectronicSignatureInfo;
+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;
@@ -24,13 +29,12 @@ import org.springframework.ui.Model;
 import org.springframework.web.bind.annotation.ModelAttribute;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestParam;
+import org.springframework.web.bind.annotation.ResponseBody;
 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.*;
 
 /**
  * 电子签章印章管理controller
@@ -47,6 +51,8 @@ public class BusinessSignatureController extends BaseController {
     private ActTaskService actTaskService;
     @Autowired
     protected HistoryService historyService;
+    @Autowired
+    private AreaStaffService areaStaffService;
 
     @ModelAttribute
     public BusinessSignatureInfo get(@RequestParam(required=false) String id) {
@@ -88,6 +94,16 @@ public class BusinessSignatureController extends BaseController {
         Page<BusinessSignatureInfo> page = businessSignatureService.findPage(new Page<BusinessSignatureInfo>(request, response), businessSignatureInfo);
         List<BusinessSignatureInfo> list = page.getList();
 
+        model.addAttribute("masterState", "0");
+
+        //获取当前登录人是否是地区负责人
+        User user = UserUtils.getUser();
+        if(StringUtils.isNotBlank(user.getId())){
+            AreaStaffInfo masterStateByUserId = areaStaffService.getMasterStateByUserId(user.getId());
+            if(null != masterStateByUserId){
+                model.addAttribute("masterState", "1");
+            }
+        }
 
         model.addAttribute("page", page);
         return "modules/signatureManagement/businessSignature/BusinessSignatureList";
@@ -390,5 +406,60 @@ public class BusinessSignatureController extends BaseController {
         }
     }
 
+    /**
+     * 查询工作类型
+     * @return
+     */
+    @RequestMapping("getUseType")
+    @ResponseBody
+    public AjaxJson getUseType(){
+        AjaxJson ajaxJson = new AjaxJson();
+        try {
+            List<MainDictDetail> getAchievementTypeList = businessSignatureService.getUseType();
+            List<Map<String, Object>> mapList = new ArrayList<>();
+            for (int i = 0; i < getAchievementTypeList.size(); i++) {
+                Map<String, Object> map = new HashMap<>();
+                map.put("name", getAchievementTypeList.get(i).getLabel());
+                map.put("value", getAchievementTypeList.get(i).getValue());
+                mapList.add(map);
+            }
+            ajaxJson.getBody().put("list", mapList);
+            ajaxJson.setMsg("获取数据成功");
+        } catch (Exception e) {
+            logger.error("获取数据异常!", e);
+            ajaxJson.setSuccess(false);
+            ajaxJson.setMsg("获取数据异常");
+        }
+        return ajaxJson;
+    }
+    /**
+     * 查询工作类型
+     * @return
+     */
+    @RequestMapping("getUseTypeById")
+    @ResponseBody
+    public AjaxJson getUseTypeById(String id){
+        AjaxJson ajaxJson = new AjaxJson();
+        try {
+            List<Map<String, Object>> mapList = new ArrayList<>();
+            BusinessSignatureInfo electronicSignatureInfo = businessSignatureService.get(id);
+            if(StringUtils.isNotBlank(electronicSignatureInfo.getUseType())){
+                String[] split = electronicSignatureInfo.getUseType().split(",");
+                List<String> useTypeList = Arrays.asList(split);
+                for (String s : useTypeList) {
+                    Map<String, Object> map = new HashMap<>();
+                    map.put("value", s);
+                    mapList.add(map);
+                }
+            }
+            ajaxJson.getBody().put("list", mapList);
+            ajaxJson.setMsg("获取数据成功");
+        } catch (Exception e) {
+            logger.error("获取数据异常!", e);
+            ajaxJson.setSuccess(false);
+            ajaxJson.setMsg("获取数据异常");
+        }
+        return ajaxJson;
+    }
 
 }

+ 29 - 0
src/main/java/com/jeeplus/modules/signatureManagement/businessSignature/entity/BusinessSignatureInfo.java

@@ -2,6 +2,7 @@ package com.jeeplus.modules.signatureManagement.businessSignature.entity;
 
 import com.google.common.collect.Lists;
 import com.jeeplus.common.persistence.ActEntity;
+import com.jeeplus.modules.sys.entity.Area;
 import com.jeeplus.modules.sys.entity.Office;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientAttachment;
 
@@ -25,6 +26,10 @@ public class BusinessSignatureInfo extends ActEntity<BusinessSignatureInfo> {
     private Date beginDate;   //申请开始时间
     private Date endDate;   //申请结束时间
     private String home;
+    private Area area;  //负责地区
+
+    private String useTypeStr;
+    private Integer useTypeShow;
 
 
     private List<WorkClientAttachment> workAttachments = Lists.newArrayList();//附件信息
@@ -116,4 +121,28 @@ public class BusinessSignatureInfo extends ActEntity<BusinessSignatureInfo> {
     public void setHome(String home) {
         this.home = home;
     }
+
+    public Area getArea() {
+        return area;
+    }
+
+    public void setArea(Area area) {
+        this.area = area;
+    }
+
+    public String getUseTypeStr() {
+        return useTypeStr;
+    }
+
+    public void setUseTypeStr(String useTypeStr) {
+        this.useTypeStr = useTypeStr;
+    }
+
+    public Integer getUseTypeShow() {
+        return useTypeShow;
+    }
+
+    public void setUseTypeShow(Integer useTypeShow) {
+        this.useTypeShow = useTypeShow;
+    }
 }

+ 85 - 13
src/main/java/com/jeeplus/modules/signatureManagement/businessSignature/service/BusinessSignatureService.java

@@ -6,13 +6,18 @@ import com.jeeplus.common.persistence.Page;
 import com.jeeplus.common.service.CrudService;
 import com.jeeplus.common.utils.IdGen;
 import com.jeeplus.common.utils.MenuStatusEnum;
+import com.jeeplus.common.utils.SpringContextHolder;
 import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.ruralprojectrecords.enums.ProjectStatusEnum;
 import com.jeeplus.modules.serialnum.service.SerialNumTplService;
 import com.jeeplus.modules.signatureManagement.businessSignature.dao.BusinessSignatureDao;
 import com.jeeplus.modules.signatureManagement.businessSignature.entity.BusinessSignatureInfo;
+import com.jeeplus.modules.sys.dao.MainDictDetailDao;
+import com.jeeplus.modules.sys.entity.MainDict;
+import com.jeeplus.modules.sys.entity.MainDictDetail;
 import com.jeeplus.modules.sys.entity.Office;
 import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.service.MainDictService;
 import com.jeeplus.modules.sys.service.OfficeService;
 import com.jeeplus.modules.sys.service.WorkattachmentService;
 import com.jeeplus.modules.sys.utils.DictUtils;
@@ -74,6 +79,10 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
     @Autowired
     private ActivityService activityService;
 
+    private static MainDictService mainDictService = SpringContextHolder.getBean(MainDictService.class);
+
+    private static MainDictDetailDao mainDictDetailDao = SpringContextHolder.getBean(MainDictDetailDao.class);
+
 
     public BusinessSignatureInfo get(String id) {
         if(StringUtils.isBlank(id)){
@@ -142,6 +151,10 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
             createBy = UserUtils.getUser();
         }
 
+        if(StringUtils.isBlank(businessSignatureInfo.getUseType()) && StringUtils.isNotBlank(businessSignatureInfo.getUseTypeStr())){
+            businessSignatureInfo.setUseType(businessSignatureInfo.getUseTypeStr());
+        }
+
         //添加申请编号
         /*synchronized (SYN_BYTE) {
             if (StringUtils.isBlank(businessSignatureInfo.getNumber())) {
@@ -179,6 +192,9 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
         }else {
             createBy = UserUtils.getUser();
         }
+        if(StringUtils.isBlank(businessSignatureInfo.getUseType()) && StringUtils.isNotBlank(businessSignatureInfo.getUseTypeStr())){
+            businessSignatureInfo.setUseType(businessSignatureInfo.getUseTypeStr());
+        }
 
         //添加申请编号
         /*synchronized (SYN_BYTE) {
@@ -246,9 +262,21 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
             Office office = businessSignatureInfo.getOffice();
             office = officeService.get(office.getId());
             businessSignatureInfo.setOffice(office);
-            String useTypeStr = DictUtils.getMainDictLabel(businessSignatureInfo.getUseType(), "businessSignature", "");
-            String contentStr = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr;
-            String titleStr = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr;
+
+
+            String[] split = businessSignatureInfo.getUseType().split(",");
+            List<String> useTypeList = Arrays.asList(split);
+            String useTypeStr = "";
+            List<String> useTypeStrList = Lists.newArrayList();
+            for (String useType : useTypeList) {
+
+                useTypeStr = DictUtils.getMainDictLabel(useType, "businessSignature", "");
+                useTypeStrList.add(useTypeStr);
+            }
+            useTypeStr = String.join(",", useTypeStrList);
+
+            String contentStr = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。待审批,申请人:"+ businessSignatureInfo.getCreateBy().getName() + ",申请使用场景:"+useTypeStr;
+            String titleStr = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。待审批,申请人:"+ businessSignatureInfo.getCreateBy().getName() + ",申请使用场景:"+useTypeStr;
 
             String businessKey = businessSignatureInfo.getId();
 
@@ -536,10 +564,21 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
         Office office = businessSignatureInfo.getOffice();
         office = officeService.get(office.getId());
         businessSignatureInfo.setOffice(office);
-        String useTypeStr = DictUtils.getMainDictLabel(businessSignatureInfo.getUseType(), "businessSignature", "");
-        String notifyStr = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr;
+
+        String[] split = businessSignatureInfo.getUseType().split(",");
+        List<String> useTypeList = Arrays.asList(split);
+        String useTypeStr = "";
+        List<String> useTypeStrList = Lists.newArrayList();
+        for (String useType : useTypeList) {
+
+            useTypeStr = DictUtils.getMainDictLabel(useType, "businessSignature", "");
+            useTypeStrList.add(useTypeStr);
+        }
+        useTypeStr = String.join(",", useTypeStrList);
+
+        String notifyStr = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr;
         String str = notifyStr+",创建人:"+businessSignatureInfo.getCreateBy().getName()+",所属部门:"+businessSignatureInfo.getOffice().getName();
-        String titleStr = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。待审批";
+        String titleStr = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。待审批";
         int key = 0;
         //业务逻辑对应的条件表达式
         String exp = "";
@@ -684,9 +723,8 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
         if(!state) {
             users.add(businessSignatureInfo.getCreateBy());
             //审核完成提示框
-
-            String title = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。签章申请审批完成,申请使用场景:"+useTypeStr+"。";
-            String content = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。签章申请审批完成,申请使用场景:"+useTypeStr;
+            String title = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。签章申请审批完成,申请使用场景:"+useTypeStr+"。";
+            String content = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。签章申请审批完成,申请使用场景:"+useTypeStr;
 
             if ("yes".equals(businessSignatureInfo.getAct().getFlag())) {
                 businessSignatureInfo.setStatus(ProjectStatusEnum.SIGNED.getValue());
@@ -761,8 +799,8 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
             }else {
                 if (!"yes".equals(businessSignatureInfo.getAct().getFlag())) {//驳回待办提醒
 
-                    str = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。被驳回,请选择重新申请或作废,申请使用场景:"+useTypeStr+"。";
-                    titleStr = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。被驳回,请选择重新申请或作废,申请使用场景:"+useTypeStr+"。";
+                    str = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。被驳回,请选择重新申请或作废,申请使用场景:"+useTypeStr+"。";
+                    titleStr = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。被驳回,请选择重新申请或作废,申请使用场景:"+useTypeStr+"。";
                     WorkProjectNotify notify = new WorkProjectNotify();
                     notify.setNotifyId(businessSignatureInfo.getId());
                     userList = workProjectNotifyService.readByNotifyId(notify);
@@ -780,8 +818,8 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
                     workProjectNotifyService.save(workProjectNotify);
                 } else {
                     if (StringUtils.isNotBlank(enname)) {//驳回重新申请待办信息
-                        str = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr+"。";
-                        titleStr = "业务用章申请描述:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr+"。";
+                        str = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr+"。";
+                        titleStr = "业务用章申请印章名称:"+ businessSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr+"。";
 
                         WorkProjectNotify notify = new WorkProjectNotify();
                         notify.setNotifyId(businessSignatureInfo.getId());
@@ -845,5 +883,39 @@ public class BusinessSignatureService extends CrudService<BusinessSignatureDao,
         return "保存审核意见成功!";
     }
 
+    public List<MainDictDetail> getUseType(){
+        String type = "businessSignature";
+        List<MainDictDetail> dictList=new ArrayList<>();
+        String comId=UserUtils.getSelectCompany().getId();
+        String branchId=UserUtils.getSelectBranchOffice();
+        MainDict mainDict = mainDictService.getIdByName(type);
+        try {
+            MainDictDetail mainDictDetail = new MainDictDetail();
+            if("1".equals(mainDict.getDictType())){
+                mainDictDetail.setBranchOffice(comId);
+            }else{
+                mainDictDetail.setBranchOffice(branchId);
+            }
+            mainDictDetail.setType(type);
+            dictList = mainDictDetailDao.findAchievementParentIdList(mainDictDetail);
+            return dictList;
+        } catch (Exception e) {
+            logger.error("Exception e:"+e);
+            System.out.println("获取业务字典失败!");
+        }
+        return dictList;
+    }
+
+    public List<MainDictDetail> getUseTypeById(String id){
+        List<MainDictDetail> dictList=new ArrayList<>();
+        try {
+            // dictList = workClientInfoDao.getJobTypeById(id);
+            return dictList;
+        } catch (Exception e) {
+            logger.error("Exception e:"+e);
+            e.getMessage();
+        }
+        return dictList;
+    }
 
 }

+ 77 - 3
src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/controller/ElectronicSignatureController.java

@@ -2,6 +2,7 @@ package com.jeeplus.modules.signatureManagement.electronicSignature.controller;
 
 import com.google.common.collect.Lists;
 import com.jeeplus.common.config.Global;
+import com.jeeplus.common.json.AjaxJson;
 import com.jeeplus.common.oss.OSSClientUtil;
 import com.jeeplus.common.persistence.Page;
 import com.jeeplus.common.utils.MyBeanUtils;
@@ -10,12 +11,15 @@ import com.jeeplus.common.utils.ThisLocalityDownloadUtil;
 import com.jeeplus.common.web.BaseController;
 import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
+import com.jeeplus.modules.areaStaff.entity.AreaStaffInfo;
+import com.jeeplus.modules.areaStaff.service.AreaStaffService;
 import com.jeeplus.modules.ruralprojectrecords.enums.ProjectStatusEnum;
 import com.jeeplus.modules.signature.dailyOfficeWork.entity.DailyOfficeWork;
 import com.jeeplus.modules.signatureManagement.electronicSignature.entity.DistrictDirectorApplication;
 import com.jeeplus.modules.signatureManagement.electronicSignature.entity.ElectronicSignatureInfo;
 import com.jeeplus.modules.signatureManagement.electronicSignature.service.DistrictDirectorApplicationService;
 import com.jeeplus.modules.signatureManagement.electronicSignature.service.ElectronicSignatureService;
+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;
@@ -32,13 +36,12 @@ import org.springframework.ui.Model;
 import org.springframework.web.bind.annotation.ModelAttribute;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestParam;
+import org.springframework.web.bind.annotation.ResponseBody;
 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.*;
 
 /**
  * 电子签章印章管理controller
@@ -55,6 +58,8 @@ public class ElectronicSignatureController extends BaseController {
     private ActTaskService actTaskService;
     @Autowired
     protected HistoryService historyService;
+    @Autowired
+    private AreaStaffService areaStaffService;
 
     @Autowired
     private DistrictDirectorApplicationService directorApplicationService;
@@ -98,6 +103,19 @@ public class ElectronicSignatureController extends BaseController {
         //获取电子签章印章管理
         Page<ElectronicSignatureInfo> page = electronicSignatureService.findPage(new Page<ElectronicSignatureInfo>(request, response), electronicSignatureInfo);
         List<ElectronicSignatureInfo> list = page.getList();
+
+        model.addAttribute("masterState", "0");
+
+        //获取当前登录人是否是地区负责人
+        User user = UserUtils.getUser();
+        if(StringUtils.isNotBlank(user.getId())){
+            AreaStaffInfo masterStateByUserId = areaStaffService.getMasterStateByUserId(user.getId());
+            if(null != masterStateByUserId){
+                model.addAttribute("masterState", "1");
+            }
+        }
+
+
         //查询当前登录人负责地区是否申请
         List<DistrictDirectorApplication> directorApplication=directorApplicationService.isApplyArea();
         if (null != directorApplication && directorApplication.size()>0){
@@ -386,4 +404,60 @@ public class ElectronicSignatureController extends BaseController {
     }
 
 
+    /**
+     * 查询工作类型
+     * @return
+     */
+    @RequestMapping("getUseType")
+    @ResponseBody
+    public AjaxJson getUseType(){
+        AjaxJson ajaxJson = new AjaxJson();
+        try {
+            List<MainDictDetail> getAchievementTypeList = electronicSignatureService.getUseType();
+            List<Map<String, Object>> mapList = new ArrayList<>();
+            for (int i = 0; i < getAchievementTypeList.size(); i++) {
+                Map<String, Object> map = new HashMap<>();
+                map.put("name", getAchievementTypeList.get(i).getLabel());
+                map.put("value", getAchievementTypeList.get(i).getValue());
+                mapList.add(map);
+            }
+            ajaxJson.getBody().put("list", mapList);
+            ajaxJson.setMsg("获取数据成功");
+        } catch (Exception e) {
+            logger.error("获取数据异常!", e);
+            ajaxJson.setSuccess(false);
+            ajaxJson.setMsg("获取数据异常");
+        }
+        return ajaxJson;
+    }
+    /**
+     * 查询工作类型
+     * @return
+     */
+    @RequestMapping("getUseTypeById")
+    @ResponseBody
+    public AjaxJson getUseTypeById(String id){
+        AjaxJson ajaxJson = new AjaxJson();
+        try {
+            List<Map<String, Object>> mapList = new ArrayList<>();
+            ElectronicSignatureInfo electronicSignatureInfo = electronicSignatureService.get(id);
+            if(StringUtils.isNotBlank(electronicSignatureInfo.getUseType())){
+                String[] split = electronicSignatureInfo.getUseType().split(",");
+                List<String> useTypeList = Arrays.asList(split);
+                for (String s : useTypeList) {
+                    Map<String, Object> map = new HashMap<>();
+                    map.put("value", s);
+                    mapList.add(map);
+                }
+            }
+            ajaxJson.getBody().put("list", mapList);
+            ajaxJson.setMsg("获取数据成功");
+        } catch (Exception e) {
+            logger.error("获取数据异常!", e);
+            ajaxJson.setSuccess(false);
+            ajaxJson.setMsg("获取数据异常");
+        }
+        return ajaxJson;
+    }
+
 }

+ 6 - 0
src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/dao/ElectronicSignatureDao.java

@@ -3,6 +3,10 @@ package com.jeeplus.modules.signatureManagement.electronicSignature.dao;
 import com.jeeplus.common.persistence.CrudDao;
 import com.jeeplus.common.persistence.annotation.MyBatisDao;
 import com.jeeplus.modules.signatureManagement.electronicSignature.entity.ElectronicSignatureInfo;
+import com.jeeplus.modules.sys.entity.User;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
 
 
 /**
@@ -19,4 +23,6 @@ public interface ElectronicSignatureDao extends CrudDao<ElectronicSignatureInfo>
      * @param projectReportSignature
      */
     void updateProcessIdAndStatus(ElectronicSignatureInfo projectReportSignature);
+
+    List<User> getAuditorList(@Param("useType") String useType, @Param("areaName") String areaName);
 }

+ 29 - 0
src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/entity/ElectronicSignatureInfo.java

@@ -2,6 +2,7 @@ package com.jeeplus.modules.signatureManagement.electronicSignature.entity;
 
 import com.google.common.collect.Lists;
 import com.jeeplus.common.persistence.ActEntity;
+import com.jeeplus.modules.sys.entity.Area;
 import com.jeeplus.modules.sys.entity.Office;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientAttachment;
 
@@ -25,6 +26,10 @@ public class ElectronicSignatureInfo extends ActEntity<ElectronicSignatureInfo>
     private Date beginDate;   //申请开始时间
     private Date endDate;   //申请结束时间
     private String home;
+    private Area area;  //负责地区
+
+    private String useTypeStr;
+    private Integer useTypeShow;
 
 
     private List<WorkClientAttachment> workAttachments = Lists.newArrayList();//附件信息
@@ -116,4 +121,28 @@ public class ElectronicSignatureInfo extends ActEntity<ElectronicSignatureInfo>
     public void setHome(String home) {
         this.home = home;
     }
+
+    public Area getArea() {
+        return area;
+    }
+
+    public void setArea(Area area) {
+        this.area = area;
+    }
+
+    public String getUseTypeStr() {
+        return useTypeStr;
+    }
+
+    public void setUseTypeStr(String useTypeStr) {
+        this.useTypeStr = useTypeStr;
+    }
+
+    public Integer getUseTypeShow() {
+        return useTypeShow;
+    }
+
+    public void setUseTypeShow(Integer useTypeShow) {
+        this.useTypeShow = useTypeShow;
+    }
 }

+ 13 - 1
src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/service/DistrictDirectorApplicationService.java

@@ -4,6 +4,7 @@ import com.google.common.collect.Maps;
 import com.jeeplus.common.service.CrudService;
 import com.jeeplus.common.utils.StringUtils;
 import com.jeeplus.modules.act.service.ActTaskService;
+import com.jeeplus.modules.areaStaff.service.AreaStaffService;
 import com.jeeplus.modules.serialnum.service.SerialNumTplService;
 import com.jeeplus.modules.signatureManagement.electronicSignature.dao.DistrictDirectorApplicationDao;
 import com.jeeplus.modules.signatureManagement.electronicSignature.entity.DistrictDirectorApplication;
@@ -68,6 +69,9 @@ public class DistrictDirectorApplicationService extends CrudService<DistrictDire
     @Autowired
     private AreaDao areaDao;
 
+    @Autowired
+    private AreaStaffService areaStaffService;
+
     private static byte[] SYN_BYTE = new byte[0];
 
 
@@ -121,7 +125,7 @@ public class DistrictDirectorApplicationService extends CrudService<DistrictDire
         //List<User> bmzrs = UserUtils.getByRoleActivityEnname("bmzr",2,office.getId(),"5",workInvoice.getCreateBy());
         //List<User> fpglys = UserUtils.getByRoleActivityEnname("fpgly",3,office.getId(),"5",workInvoice.getCreateBy());
         //地区申请管理员
-        List<User> dqsqgly = UserUtils.getByRoleActivityEnname("dqsqglyclkv",3,office.getId(),"5",directorApplication.getCreateBy());
+        List<User> dqsqgly = UserUtils.getByRoleActivityEnname("dqsqgly",3,office.getId(),"5",directorApplication.getCreateBy());
         long s7=System.currentTimeMillis();
         if (StringUtils.isNotBlank(workActivityMenu.getId())) {
             workProjectNotify.setNotifyRole("");
@@ -319,6 +323,14 @@ public class DistrictDirectorApplicationService extends CrudService<DistrictDire
                     taskCount = "1";
                     exp = "pass";
                     if ("yes".equals(directorApplication.getAct().getFlag())) {
+                        //审核通过处理
+                        //根据申请人的隶属部门和申请地区查询是否存在该人员信息,若不存在则进行添加
+                        Map<String, Object> stringObjectMap = areaStaffService.disposeAreaMaster(directorApplication);
+                        Boolean success = (Boolean) stringObjectMap.get("success");
+                        String message = (String) stringObjectMap.get("message");
+                        if(! success){
+                            return message;
+                        }
                         notifyRole = "地区负责人申请-"+directorApplication.getCreateBy().getName()+"-负责地区:"+directorApplication.getArea().getName()+"审核完成";
                         workActivityProcess.setIsApproval("1");
                     } else {

+ 97 - 12
src/main/java/com/jeeplus/modules/signatureManagement/electronicSignature/service/ElectronicSignatureService.java

@@ -6,6 +6,7 @@ import com.jeeplus.common.persistence.Page;
 import com.jeeplus.common.service.CrudService;
 import com.jeeplus.common.utils.IdGen;
 import com.jeeplus.common.utils.MenuStatusEnum;
+import com.jeeplus.common.utils.SpringContextHolder;
 import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.ruralprojectrecords.enums.ProjectStatusEnum;
@@ -13,8 +14,12 @@ import com.jeeplus.modules.serialnum.service.SerialNumTplService;
 import com.jeeplus.modules.signature.dailyOfficeWork.entity.DailyOfficeWork;
 import com.jeeplus.modules.signatureManagement.electronicSignature.dao.ElectronicSignatureDao;
 import com.jeeplus.modules.signatureManagement.electronicSignature.entity.ElectronicSignatureInfo;
+import com.jeeplus.modules.sys.dao.MainDictDetailDao;
+import com.jeeplus.modules.sys.entity.MainDict;
+import com.jeeplus.modules.sys.entity.MainDictDetail;
 import com.jeeplus.modules.sys.entity.Office;
 import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.service.MainDictService;
 import com.jeeplus.modules.sys.service.OfficeService;
 import com.jeeplus.modules.sys.service.WorkattachmentService;
 import com.jeeplus.modules.sys.utils.DictUtils;
@@ -76,6 +81,10 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
     @Autowired
     private ActivityService activityService;
 
+    private static MainDictService mainDictService = SpringContextHolder.getBean(MainDictService.class);
+
+    private static MainDictDetailDao mainDictDetailDao = SpringContextHolder.getBean(MainDictDetailDao.class);
+
 
     public ElectronicSignatureInfo get(String id) {
         if(StringUtils.isBlank(id)){
@@ -154,6 +163,10 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
             }
         }*/
 
+        if(StringUtils.isBlank(electronicSignatureInfo.getUseType()) && StringUtils.isNotBlank(electronicSignatureInfo.getUseTypeStr())){
+            electronicSignatureInfo.setUseType(electronicSignatureInfo.getUseTypeStr());
+        }
+
         if(StringUtils.isBlank(electronicSignatureInfo.getId())){
             electronicSignatureInfo.setCompany(UserUtils.getUser().getCompany());
             electronicSignatureInfo.setOffice(UserUtils.getUser().getOffice());
@@ -181,6 +194,9 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
         }else {
             createBy = UserUtils.getUser();
         }
+        if(StringUtils.isBlank(electronicSignatureInfo.getUseType()) && StringUtils.isNotBlank(electronicSignatureInfo.getUseTypeStr())){
+            electronicSignatureInfo.setUseType(electronicSignatureInfo.getUseTypeStr());
+        }
 
         //添加申请编号
         /*synchronized (SYN_BYTE) {
@@ -248,9 +264,20 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
             Office office = electronicSignatureInfo.getOffice();
             office = officeService.get(office.getId());
             electronicSignatureInfo.setOffice(office);
-            String useTypeStr = DictUtils.getMainDictLabel(electronicSignatureInfo.getUseType(), "electronicSignature", "");
-            String contentStr = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr;
-            String titleStr = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr;
+
+            String[] split = electronicSignatureInfo.getUseType().split(",");
+            List<String> useTypeList = Arrays.asList(split);
+            String useTypeStr = "";
+            List<String> useTypeStrList = Lists.newArrayList();
+            for (String useType : useTypeList) {
+
+                useTypeStr = DictUtils.getMainDictLabel(useType, "electronicSignature", "");
+                useTypeStrList.add(useTypeStr);
+            }
+            useTypeStr = String.join(",", useTypeStrList);
+
+            String contentStr = "电子印章申请使用场景:"+useTypeStr+"。待审批";
+            String titleStr = "电子印章申请使用场景:"+useTypeStr+"。待审批,申请人:"+ electronicSignatureInfo.getCreateBy().getName();
 
             String businessKey = electronicSignatureInfo.getId();
 
@@ -532,10 +559,23 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
         Office office = electronicSignatureInfo.getOffice();
         office = officeService.get(office.getId());
         electronicSignatureInfo.setOffice(office);
-        String useTypeStr = DictUtils.getMainDictLabel(electronicSignatureInfo.getUseType(), "electronicSignature", "");
-        String notifyStr = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr;
+
+
+
+        String[] split = electronicSignatureInfo.getUseType().split(",");
+        List<String> useTypeList = Arrays.asList(split);
+        String useTypeStr = "";
+        List<String> useTypeStrList = Lists.newArrayList();
+        for (String useType : useTypeList) {
+
+            useTypeStr = DictUtils.getMainDictLabel(useType, "electronicSignature", "");
+            useTypeStrList.add(useTypeStr);
+        }
+        useTypeStr = String.join(",", useTypeStrList);
+
+        String notifyStr = "电子印章申请使用场景:"+useTypeStr+"。待审批";
         String str = notifyStr+",创建人:"+electronicSignatureInfo.getCreateBy().getName()+",所属部门:"+electronicSignatureInfo.getOffice().getName();
-        String titleStr = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。待审批";
+        String titleStr = "电子印章申请使用场景:"+useTypeStr+"。待审批,申请人:"+ electronicSignatureInfo.getCreateBy().getName();
         int key = 0;
         //业务逻辑对应的条件表达式
         String exp = "";
@@ -667,8 +707,8 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
             users.add(electronicSignatureInfo.getCreateBy());
             //审核完成提示框
 
-            String title = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。申请审批完成,申请使用场景:"+useTypeStr+"。";
-            String content = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。申请审批完成,申请使用场景:"+useTypeStr;
+            String title = "电子印章申请使用场景:"+useTypeStr+"。申请审批完成。";
+            String content = "电子印章申请使用场景:"+useTypeStr+"。申请审批完成。";
 
             if ("yes".equals(electronicSignatureInfo.getAct().getFlag())) {
                 electronicSignatureInfo.setStatus(ProjectStatusEnum.SIGNED.getValue());
@@ -743,8 +783,8 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
             }else {
                 if (!"yes".equals(electronicSignatureInfo.getAct().getFlag())) {//驳回待办提醒
 
-                    str = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。被驳回,请选择重新申请或作废,申请使用场景:"+useTypeStr+"。";
-                    titleStr = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。被驳回,请选择重新申请或作废,申请使用场景:"+useTypeStr+"。";
+                    str = "电子印章申请使用场景:"+useTypeStr+"。被驳回,请选择重新申请或作废。";
+                    titleStr = "电子印章申请使用场景:"+useTypeStr+"。被驳回,请选择重新申请或作废。";
                     WorkProjectNotify notify = new WorkProjectNotify();
                     notify.setNotifyId(electronicSignatureInfo.getId());
                     userList = workProjectNotifyService.readByNotifyId(notify);
@@ -762,8 +802,8 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
                     workProjectNotifyService.save(workProjectNotify);
                 } else {
                     if (StringUtils.isNotBlank(enname)) {//驳回重新申请待办信息
-                        str = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr+"。";
-                        titleStr = "电子印章申请描述:"+ electronicSignatureInfo.getName()+"。待审批,申请使用场景:"+useTypeStr+"。";
+                        str = "电子印章申请使用场景:"+useTypeStr+"。待审批。";
+                        titleStr = "电子印章申请使用场景:"+useTypeStr+"。待审批,申请人:"+ electronicSignatureInfo.getCreateBy().getName();
 
                         WorkProjectNotify notify = new WorkProjectNotify();
                         notify.setNotifyId(electronicSignatureInfo.getId());
@@ -827,5 +867,50 @@ public class ElectronicSignatureService extends CrudService<ElectronicSignatureD
         return "保存审核意见成功!";
     }
 
+    /**
+     * 根据类型和负责地区查询地区负责人信息
+     * @param useType
+     * @param areaName
+     * @return
+     */
+    public List<User> getAuditorList(String useType,String areaName){
+        return dao.getAuditorList(useType,areaName);
+    }
+
+
+    public List<MainDictDetail> getUseType(){
+        String type = "electronicSignature";
+        List<MainDictDetail> dictList=new ArrayList<>();
+        String comId=UserUtils.getSelectCompany().getId();
+        String branchId=UserUtils.getSelectBranchOffice();
+        MainDict mainDict = mainDictService.getIdByName(type);
+        try {
+            MainDictDetail mainDictDetail = new MainDictDetail();
+            if("1".equals(mainDict.getDictType())){
+                mainDictDetail.setBranchOffice(comId);
+            }else{
+                mainDictDetail.setBranchOffice(branchId);
+            }
+            mainDictDetail.setType(type);
+            dictList = mainDictDetailDao.findAchievementParentIdList(mainDictDetail);
+            return dictList;
+        } catch (Exception e) {
+            logger.error("Exception e:"+e);
+            System.out.println("获取业务字典失败!");
+        }
+        return dictList;
+    }
+
+    public List<MainDictDetail> getUseTypeById(String id){
+        List<MainDictDetail> dictList=new ArrayList<>();
+        try {
+            // dictList = workClientInfoDao.getJobTypeById(id);
+            return dictList;
+        } catch (Exception e) {
+            logger.error("Exception e:"+e);
+            e.getMessage();
+        }
+        return dictList;
+    }
 
 }

+ 12 - 1
src/main/java/com/jeeplus/modules/workfullmanage/web/WorkFullManageController.java

@@ -1128,6 +1128,9 @@ public class WorkFullManageController extends BaseController {
 		}
 		//根据项目id查找报告咨询员信息
 		List<RuralReportConsultant> consultantList = ruralProjectMessageService.getConsultantsList(ruralProjectRecords.getId());
+		for (RuralReportConsultant ruralReportConsultant : consultantList) {
+			ruralReportConsultant.setSignatureStampUrl("");
+		}
 		Iterator<RuralReportConsultant> it = consultantList.iterator();
 		while(it.hasNext()){
 			RuralReportConsultant consultant = it.next();
@@ -1300,7 +1303,15 @@ public class WorkFullManageController extends BaseController {
 					if(StringUtils.isNotBlank(consultants.get(i).getZixunyuan()) && "咨询员".equals(consultants.get(i).getRole())){
 						String base64String = workFullManageService.base64String(consultants.get(i).getZixunyuan());
 						data.put("handSignature1",base64String);
-						flag ++;
+						//signatureStampUrl
+						for (RuralReportConsultant ruralReportConsultant : consultantList) {
+							if(consultants.get(i).getZixunyuanName().equals(ruralReportConsultant.getZixunyuanName())){
+								ruralReportConsultant.setSignatureStampUrl(base64String);
+								break;
+							}
+						}
+
+						//flag ++;
 					}else{
 						data.put("handSignature1",blankBase64);
 					}

+ 1 - 1
src/main/resources/jeeplus.properties

@@ -7,7 +7,7 @@ jdbc.type=mysql
 jdbc.driver=com.mysql.jdbc.Driver
 db.name=ruihuaoa-activity-data
 #jdbc.url=jdbc:mysql://8.136.152.135:3306/new_ccpm?useUnicode=true&characterEncoding=utf-8
-jdbc.url=jdbc:mysql://192.168.2.4:3306/new_ccpm?useUnicode=true&characterEncoding=utf-8
+jdbc.url=jdbc:mysql://127.0.0.1:3306/new_ccpm?useUnicode=true&characterEncoding=utf-8
 jdbc.username=root
 jdbc.password=root
 #jdbc.password=Xgcomdata10376@

+ 317 - 0
src/main/resources/mappings/modules/areaStaff/AreaStaffDao.xml

@@ -0,0 +1,317 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.jeeplus.modules.areaStaff.dao.AreaStaffDao">
+
+	<sql id="workReviewStandardColumns">
+		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.parent_id AS "parent.id",
+		a.standard_detail AS "standardDetail",
+		a.parent_ids AS "parentIds",
+		a.company_id AS "companyId",
+		a.order_num AS "orderNum",
+		a.hierarchy AS "hierarchy",
+		a.type AS "type"
+	</sql>
+
+
+	<select id="get" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo" >
+		SELECT
+		<include refid="workReviewStandardColumns"/>
+		FROM sys_area_staff a
+		WHERE a.id = #{id}
+	</select>
+
+	<select id="findList" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo" >
+		SELECT
+		<include refid="workReviewStandardColumns"/>
+		,(case when a.hierarchy = '1' then (select so.name from sys_office so where so.id = a.standard_detail)
+		when a.hierarchy = '2' then (select sa.name from sys_area sa where sa.id = a.standard_detail)
+		when a.hierarchy = '3' then a.standard_detail
+		when a.hierarchy = '4' then (select su.name from sys_user su where su.id = a.standard_detail)
+		else '' end) as standardDetailStr
+		FROM sys_area_staff a
+		<where>
+			a.del_flag = 0
+			<if test="standardDetail!=null and standardDetail != ''">
+				and a.standard_detail like concat('%',#{standardDetail},'%')
+			</if>
+			<if test="parentIds!=null and parentIds != ''">
+				and a.parent_ids like concat('%',#{parentIds},'%')
+			</if>
+			<if test="standardDetail!=null and standardDetail != ''">
+				and a.standard_detail like concat('%',#{standardDetail},'%')
+			</if>
+			<choose>
+				<when test="companyId!=null and companyId != ''">
+					and a.company_id = #{companyId}
+				</when>
+				<otherwise>
+					and a.company_id = '0'
+				</otherwise>
+			</choose>
+			<if test="orderNum != null and orderNum!=0">
+				and a.order_num = #{orderNum}
+			</if>
+		</where>
+		<choose>
+			<when test="page !=null and page.orderBy != null and page.orderBy != ''">
+				ORDER BY ${page.orderBy}
+			</when>
+			<otherwise>
+				ORDER BY a.standard_detail ='地区员工',a.standard_detail ='地区负责人',a.create_date asc
+			</otherwise>
+		</choose>
+	</select>
+
+	<select id="findAllList" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo" >
+		SELECT
+		<include refid="workReviewStandardColumns"/>
+		FROM sys_area_staff a
+		<where>
+			a.del_flag = #{DEL_FLAG_NORMAL}
+		</where>
+		<choose>
+			<when test="page !=null and page.orderBy != null and page.orderBy != ''">
+				ORDER BY ${page.orderBy}
+			</when>
+			<otherwise>
+				ORDER BY a.update_date DESC
+			</otherwise>
+		</choose>
+	</select>
+
+	<insert id="insert">
+		INSERT INTO sys_area_staff(
+			id,
+			create_by,
+			create_date,
+			update_by,
+			update_date,
+			remarks,
+			del_flag,
+			parent_id,
+			standard_detail,
+			parent_ids,
+			company_id,
+			order_num,
+			hierarchy,
+			type
+		) VALUES (
+			#{id},
+			#{createBy.id},
+			#{createDate},
+			#{updateBy.id},
+			#{updateDate},
+			#{remarks},
+			#{delFlag},
+			#{parent.id},
+			#{standardDetail},
+			#{parentIds},
+			#{companyId},
+			#{orderNum},
+			#{hierarchy},
+			#{type}
+		)
+	</insert>
+
+	<update id="update">
+		UPDATE sys_area_staff SET
+			update_by = #{updateBy.id},
+			update_date = #{updateDate},
+			remarks = #{remarks},
+			parent_id = #{parent.id},
+			standard_detail = #{standardDetail},
+			parent_ids = #{parentIds},
+			company_id = #{companyId},
+			order_num = #{orderNum}
+		WHERE id = #{id}
+	</update>
+
+
+	<!--物理删除-->
+	<update id="delete">
+		update sys_area_staff set
+		del_flag = 1
+		WHERE id = #{id} OR find_in_set(#{id},parent_ids)
+	</update>
+
+	<!--逻辑删除-->
+	<update id="deleteByLogic">
+		UPDATE sys_area_staff SET
+			del_flag = #{DEL_FLAG_DELETE}
+		WHERE id = #{id} OR find_in_set(#{id},parent_ids)
+	</update>
+
+
+	<!-- 根据实体名称和字段名称和字段值获取唯一记录 -->
+	<select id="findUniqueByProperty" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo" statementType="STATEMENT">
+		select * FROM sys_area_staff  where ${propertyName} = '${value}'
+	</select>
+
+	<select id="fingIds" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+		SELECT <include refid="workReviewStandardColumns"/>
+		FROM sys_area_staff a
+		<where>
+			<if test="parentIdSet!=null and parentIdSet.size!=0">
+				a.id in
+				<foreach collection="parentIdSet" item="parentId" separator="," open="(" close=")">
+					#{parentId}
+				</foreach>
+			</if>
+			AND del_flag ='0'
+			AND company_id = #{companyId}
+		</where>
+		ORDER BY FIELD(a.order_num,1,3,2)
+		# 		ORDER BY a.order_num
+	</select>
+	<select id="fingByIds" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+		SELECT <include refid="workReviewStandardColumns"/>
+		FROM sys_area_staff a
+		<where>
+			<if test="parentIdSet!=null and parentIdSet.size!=0">
+				a.id in
+				<foreach collection="parentIdSet" item="parentId" separator="," open="(" close=")">
+					#{parentId}
+				</foreach>
+			</if>
+			AND del_flag ='0'
+			AND company_id = #{companyId}
+			AND parent_ids like concat('%',#{parentIds},'%')
+		</where>
+		ORDER BY FIELD(a.order_num,1,3,2)
+		#         ORDER BY a.order_num
+	</select>
+
+	<select id="selectOrderNum" resultType="java.lang.String">
+        SELECT MAX(order_num) FROM sys_area_staff WHERE parent_id = #{parentId}
+    </select>
+
+	<select id="getByDetail" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+        SELECT * FROM sys_area_staff WHERE standard_detail = '标准部校核'
+    </select>
+
+	<select id="findByParentIdsLike" resultType="com.jeeplus.modules.projectAccessory.entity.ProjectAccessoryInfo">
+		SELECT
+		<include refid="workReviewStandardColumns"/>
+		FROM sys_area_staff a
+		WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND (a.parent_ids LIKE
+		<if test="dbName == 'mysql'">concat('%,',#{parentIds},',%')</if>
+		OR a.id = #{id})
+		ORDER BY FIELD(a.order_num,1,3,2)
+		# 		ORDER BY a.order_num
+	</select>
+
+
+	<select id="getEffectiveArea" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+        SELECT * FROM sys_area_staff WHERE standard_detail = #{areaId} and del_flag = 0
+    </select>
+
+
+	<select id="getOfficeInfo" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+        SELECT * FROM sys_area_staff WHERE standard_detail = #{officeId} and del_flag = 0
+    </select>
+
+
+	<select id="getByParentIdList" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+		SELECT <include refid="workReviewStandardColumns"/>
+		FROM sys_area_staff a
+		<where>
+			del_flag ='0' and
+			(<if test="parentIdList!=null and parentIdList.size!=0">
+				 a.id in
+				<foreach collection="parentIdList" item="parentId" separator="," open="(" close=")">
+					#{parentId}
+				</foreach>
+			</if>
+			or parent_ids like concat('%',#{parentIds},'%')
+			)
+		</where>
+	</select>
+
+	<select id="getUserByParentId" resultType="User">
+		select a.*,
+		s.name AS "company.name",
+		s.parent_id AS "company.parent.id",
+		s.parent_ids AS "company.parentIds",
+		s.group_id AS "company.groupId",
+		s.group_name AS "company.groupName",
+		s.useable AS "company.useable",
+		o.name AS "office.name",
+		o.top_company AS "office.topCompany",
+		o.parent_id AS "office.parent.id",
+		o.parent_ids AS "office.parentIds"
+		from sys_user a
+		left join sys_office o on a.office_id = o.id
+		left join sys_office s on a.company_id = s.id
+		where a.id in (
+		select standard_detail from sys_area_staff
+		<where>
+			parent_id = #{id} and del_flag = 0
+		</where>
+		)
+	</select>
+
+	<select id="getUserByParentIdAndStandardDetail" resultType="User">
+		select * from sys_user where id in (
+		select standard_detail from sys_area_staff
+		<where>
+			parent_id = #{id} and del_flag = 0
+			<if test="standardDetail != null and standardDetail != ''">
+				and standard_detail = #{standardDetail}
+			</if>
+		</where>
+		)
+	</select>
+
+	<select id="getAreaStaffInfoByParentIdAndStandardDetail" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+		select * from sys_area_staff
+		<where>
+			parent_id = #{parentId} and del_flag = 0
+			<if test="standardDetail != null and standardDetail != ''">
+				and standard_detail = #{standardDetail}
+			</if>
+		</where>
+	</select>
+
+	<select id="getAreaStaffInfoByParentIdAndType" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+		select * from sys_area_staff
+		<where>
+			parent_id = #{parentId} and del_flag = 0
+			<if test="type != null and type != ''">
+				and type = #{type}
+			</if>
+		</where>
+	</select>
+
+	<update id="outUserById">
+		update sys_area_staff set
+		del_flag = 1
+		where parent_id = #{parentId}
+		and standard_detail = #{userId}
+	</update>
+
+	<update id="deleteChildrenByParentId">
+		update sys_area_staff set
+		del_flag = 1
+		<where>
+			parent_ids like concat('%',#{id},'%')
+		</where>
+	</update>
+
+	<select id="getMasterStateByUserId" resultType="com.jeeplus.modules.areaStaff.entity.AreaStaffInfo">
+		select * from sys_area_staff
+		<where>
+			del_flag = 0
+			and type = 'master'
+			and id in (select parent_id from sys_area_staff where del_flag = 0 and standard_detail = #{userId})
+		</where>
+		limit 1
+	</select>
+	
+</mapper>

+ 13 - 5
src/main/resources/mappings/modules/signatureManagement/businessSignature/BusinessSignatureDao.xml

@@ -19,13 +19,16 @@
 		a.office_id as "office.id",
 		so.name as "office.name",
 		soc.name as "company.name",
-		a.company_id as "company.id"
+		a.company_id as "company.id",
+		a.area_id as "area.id",
+		sa.name as "area.name"
 	</sql>
 
 	<sql id="dailyOfficeWorkLeftColumns">
         LEFT JOIN sys_user su ON su.id = a.create_by
         LEFT JOIN sys_office so ON so.id = a.office_id
         LEFT JOIN sys_office soc ON soc.id = a.company_id
+        LEFT JOIN sys_area sa ON sa.id = a.area_id
 	</sql>
 
 	<select id="get" resultType="com.jeeplus.modules.signatureManagement.businessSignature.entity.BusinessSignatureInfo" >
@@ -49,7 +52,7 @@
 			</if>
 
 			<if test="useType != null and useType != ''">
-				AND a.use_type = #{useType}
+				AND a.use_type like concat('%',#{useType},'%')
 			</if>
 
 			<if test="createBy != null and((createBy.id != null and createBy.id != '') or (createBy.name != null and createBy.name != ''))">
@@ -103,7 +106,7 @@
 			</if>
 
 			<if test="useType != null and useType != ''">
-				AND a.use_type = #{useType}
+				AND a.use_type like concat('%',#{useType},'%')
 			</if>
 
 			<if test="createBy != null and((createBy.id != null and createBy.id != '') or (createBy.name != null and createBy.name != ''))">
@@ -153,7 +156,8 @@
 			status,
 			process_instance_id,
 			office_id,
-			company_id
+			company_id,
+			area_id
 		) VALUES (
 			#{id},
 			#{createBy.id},
@@ -168,7 +172,8 @@
 			#{status},
 			#{processInstanceId},
 			#{office.id},
-			#{company.id}
+			#{company.id},
+			#{area.id}
 		)
 	</insert>
 
@@ -192,6 +197,9 @@
 			<if test="processInstanceId != null and processInstanceId != ''">
 				,process_instance_id = #{processInstanceId}
 			</if>
+			<if test="area != null and area.id != null and area.id != ''">
+				,area_id = #{area.id}
+			</if>
 		WHERE id = #{id}
 	</update>
 

+ 21 - 5
src/main/resources/mappings/modules/signatureManagement/electronicSignature/ElectronicSignatureDao.xml

@@ -19,13 +19,16 @@
 		a.office_id as "office.id",
 		so.name as "office.name",
 		soc.name as "company.name",
-		a.company_id as "company.id"
+		a.company_id as "company.id",
+		a.area_id as "area.id",
+		sa.name as "area.name"
 	</sql>
 
 	<sql id="dailyOfficeWorkLeftColumns">
         LEFT JOIN sys_user su ON su.id = a.create_by
         LEFT JOIN sys_office so ON so.id = a.office_id
         LEFT JOIN sys_office soc ON soc.id = a.company_id
+        LEFT JOIN sys_area sa ON sa.id = a.area_id
 	</sql>
 
 	<select id="get" resultType="com.jeeplus.modules.signatureManagement.electronicSignature.entity.ElectronicSignatureInfo" >
@@ -49,7 +52,7 @@
 			</if>
 
 			<if test="useType != null and useType != ''">
-				AND a.use_type = #{useType}
+				AND a.use_type like concat('%',#{useType},'%')
 			</if>
 
 			<if test="createBy != null and((createBy.id != null and createBy.id != '') or (createBy.name != null and createBy.name != ''))">
@@ -103,7 +106,7 @@
 			</if>
 
 			<if test="useType != null and useType != ''">
-				AND a.use_type = #{useType}
+				AND a.use_type like concat('%',#{useType},'%')
 			</if>
 
 			<if test="createBy != null and((createBy.id != null and createBy.id != '') or (createBy.name != null and createBy.name != ''))">
@@ -153,7 +156,8 @@
 			status,
 			process_instance_id,
 			office_id,
-			company_id
+			company_id,
+			area_id
 		) VALUES (
 			#{id},
 			#{createBy.id},
@@ -168,7 +172,8 @@
 			#{status},
 			#{processInstanceId},
 			#{office.id},
-			#{company.id}
+			#{company.id},
+			#{area.id}
 		)
 	</insert>
 
@@ -192,6 +197,9 @@
 			<if test="processInstanceId != null and processInstanceId != ''">
 				,process_instance_id = #{processInstanceId}
 			</if>
+			<if test="area != null and area.id != null and area.id != ''">
+				,area_id = #{area.id}
+			</if>
 		WHERE id = #{id}
 	</update>
 
@@ -214,5 +222,13 @@
 		WHERE id = #{id}
 	</update>
 
+	<select id="getAuditorList" resultType="com.jeeplus.modules.sys.entity.User">
+		select su.* from signature_electronic_info a
+		left join sys_user su on su.id = a.create_by
+		left join sys_area sa on sa.id = a.area_id
+		<where>
+			a.use_type = #{useType} and sa.name = #{areaName} and a.status = 5
+		</where>
+	</select>
 
 </mapper>

+ 18 - 0
src/main/webapp/WEB-INF/tags/table/addAreaStaffRow.tag

@@ -0,0 +1,18 @@
+<%@ tag language="java" pageEncoding="UTF-8"%>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<%@ attribute name="url" type="java.lang.String" required="true"%>
+<%@ attribute name="title" type="java.lang.String" required="true"%>
+<%@ attribute name="width" type="java.lang.String" required="false"%>
+<%@ attribute name="height" type="java.lang.String" required="false"%>
+<%@ attribute name="target" type="java.lang.String" required="false"%>
+<%@ attribute name="label" type="java.lang.String" required="false"%>
+<button class="layui-btn layui-btn-sm layui-bg-blue" data-toggle="tooltip" data-placement="left" onclick="add()" title="添加">
+<%--    <i class="fa fa-plus"></i>--%>
+    ${label==null?'添加':label}
+</button>
+<%-- 使用方法: 1.将本tag写在查询的form之前;2.传入table的id和controller的url --%>
+<script type="text/javascript">
+	function add(){
+		openDialog('${title}'+"登记",encodeURI("${url}"),"${width==null?'80%':width}", "${height==null?'60%':height}","${target}");
+	}
+</script>

+ 89 - 0
src/main/webapp/webpage/modules/areaStaff/areaStaffForm.jsp

@@ -0,0 +1,89 @@
+<%@ 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{
+			top:40px;
+			left:0;
+		}
+		#standardDetail-error{
+			top:82px;
+			left:0;
+		}
+	</style>
+	<script type="text/javascript">
+		var validateForm;
+		function doSubmit(){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+		  if(validateForm.form()){
+			  $("#inputForm").submit();
+			  return true;
+		  }
+	
+		  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);
+					}
+				}
+			});
+            var edit = "${workReviewStandard.id}";
+            if(edit!=null && edit!=''){
+                $("#reviewParentButton").attr("disabled","disabled");
+            }
+            setParentInfo($("#reviewParentId").val());
+		});
+        function setParentInfo(parentId){
+            $.ajax({
+                url:"${ctx}/reimbursementType/reimbursementType/jsonData",
+                dataType:"json",
+                data:{id:parentId},
+                success:function (data) {
+                    if(data.proofread==1&&data.grade==1){
+                        $("#maxDeductTr").show();
+                    }else {
+                        $("#maxDeductTr").hide();
+                    }
+                }
+            })
+        }
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="areaStaffInfo" action="${ctx}/areaStaff/areaStaff/save" method="post" class="form-horizontal">
+		<form:hidden path="id"/>
+		<form:hidden path="companyId"/>
+			<form:hidden path="parent.id"/>
+			<form:hidden path="parent.orderNum"/>
+			<form:hidden path="hierarchy"/>
+			<div class="form-group layui-row first">
+				<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">
+						<sys:treeselectbelongingDepartment id="reviewParent" name="office.id" value="${areaStaffInfo.office.id}" labelName="office.name" labelValue="${areaStaffInfo.office.name}"
+														   cssStyle="background-color:#fff" title="归属部门" url="/sys/office/treeData?type=2" cssClass="form-control layui-input" allowClear="true" notAllowSelectParent="true"/>
+					</div>
+				</div>
+			</div>
+		</form:form>
+	</div>
+</div>
+</body>
+</html>

+ 145 - 0
src/main/webapp/webpage/modules/areaStaff/areaStaffList.jsp

@@ -0,0 +1,145 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>地区负责人管理</title>
+	<meta name="decorator" content="default"/>
+	<%@include file="/webpage/include/treetable.jsp" %>
+	<script type="text/javascript">
+		$(document).ready(function() {
+			//此处用于展示层级限制(expandLevel参数),当前即打开展示到第三层
+			$("#treeTable").treeTable({expandLevel : 3},{ expandable: true });
+		});
+	</script>
+	<style>
+		body{
+			background-color:transparent;
+			filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#26FFFFFF, endColorstr=#26FFFFFF);
+			background-color:rgba(255,255,255,0);
+			height:100%;
+		}
+	</style>
+</head>
+<body >
+<div class="wrapper wrapper-content">
+	<sys:message content="${message}"/>
+	<div class="layui-row">
+		<div class="full-width fl">
+			<div class="contentShadow layui-row" id="queryDiv">
+				<form:form id="searchForm" modelAttribute="areaStaffInfo" action="${ctx}/areaStaff/areaStaff/" method="post" class="form-inline">
+					<input id="toflag" name="toflag" type="hidden" value="1"/>
+					<%--<div class="commonQuery">
+						&lt;%&ndash;<div class="layui-item query athird">
+							<label class="layui-form-label double-line">报销内容名:</label>
+							<div class="layui-input-block with-icon">
+								<form:input path="standardDetail" htmlEscape="false" class=" form-control layui-input"></form:input>
+							</div>
+						</div>
+						<div class="layui-item query athird">
+							<label class="layui-form-label">序号:</label>
+							<div class="layui-input-block">
+								<form:input path="orderNum" htmlEscape="false" class=" form-control layui-input"></form:input>
+							</div>
+						</div>&ndash;%&gt;
+						<div class="layui-item athird">
+							<div class="layui-btn-group search-spacing">
+								<button id="searchQuery" class="layui-btn layui-btn-sm layui-bg-blue" onclick="search()">查询</button>
+								<button id="searchReset" class="layui-btn layui-btn-sm " onclick="resetSearch()">重置</button>
+							</div>
+						</div>
+						<div style="clear:both;"></div>
+					</div>--%>
+
+				</form:form>
+			</div>
+		</div>
+		<div class="full-width fl">
+			<div class="contentShadow layui-form contentDetails">
+				<div class="nav-btns">
+					<shiro:hasPermission name="areaStaff:areaStaff:add">
+                        <table:addAreaStaffRow url="${ctx}/areaStaff/areaStaff/form" title="部门"></table:addAreaStaffRow><!-- 增加按钮 -->
+                    </shiro:hasPermission>
+					<button class="layui-btn layui-btn-sm layui-bg-green" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新">&nbsp;刷新</button>
+					<div style="clear: both;"></div>
+				</div>
+
+
+				<!-- 表格 -->
+				<table id="treeTable" class="table table-bordered table-hover list-table">
+					<thead>
+					<tr>
+						<th >部门/地区/角色/人员</th>
+						<%--<th >序号</th>--%>
+						<th width="240px">操作</th>
+					</tr>
+					</thead>
+					<tbody>
+					<c:forEach items="${list}" var="areaStaffInfo">
+						<tr id="${areaStaffInfo.id}" pid="${areaStaffInfo.parent.id}">
+							<td>
+								<c:if test="${areaStaffInfo.grade == 0 || areaStaffInfo.grade ==1}">
+									<a  href="#" onclick="openDialogView('查看详情', '${ctx}/areaStaff/areaStaff/view?id=${areaStaffInfo.id}','80%', '60%')">
+										${areaStaffInfo.standardDetailStr}
+									</a>
+								</c:if>
+								<c:if test="${areaStaffInfo.grade == 2}">
+									<a  href="#" onclick="openDialogView('查看详情', '${ctx}/areaStaff/areaStaff/userForm?parent.id=${areaStaffInfo.id}','80%', '60%')">
+											${areaStaffInfo.standardDetailStr}
+									</a>
+								</c:if>
+								<c:if test="${areaStaffInfo.grade == 3}">
+									<%--<a  href="#" onclick="openDialogView('查看人员信息', '${ctx}/workstaff/workStaffBasicInfo/view?id=${areaStaffInfo.standardDetail}','80%', '60%')">--%>
+									<a  href="#" onclick="openDialogView('查看人员信息', '${ctx}/sys/user/form?id=${areaStaffInfo.standardDetail}','80%', '60%')">
+											${areaStaffInfo.standardDetailStr}
+									</a>
+								</c:if>
+							</td>
+							<%--<td style="text-align: center">
+									${areaStaffInfo.orderNum}
+							</td>--%>
+							<td class="op-td text-center">
+								<div class="op-btn-box">
+									<div class="layui-btn-group">
+										<c:if test="${areaStaffInfo.grade == 0}">
+											<shiro:hasPermission name="reimbursementType:reimbursementType:add">
+												<a href="javascript:void(0);" onclick="openDialog('添加部门地区', '${ctx}/areaStaff/areaStaff/secondForm?parent.id=${areaStaffInfo.id}','80%','60%')" class="layui-btn layui-btn-xs layui-bg-blue"> 添加地区</a>
+											</shiro:hasPermission>
+										</c:if>
+										<c:if test="${areaStaffInfo.grade ==1}">
+											<shiro:hasPermission name="reimbursementType:reimbursementType:del">
+												<a href="${ctx}/areaStaff/areaStaff/delete?id=${areaStaffInfo.id}" onclick="return confirmx('确认要删除该地区吗?同时将删除其下所有子节点和人员信息', this.href)"   class="layui-btn layui-btn-xs layui-bg-red"> 删除地区</a>
+											</shiro:hasPermission>
+										</c:if>
+										<c:if test="${areaStaffInfo.grade ==2}">
+											<shiro:hasPermission name="reimbursementType:reimbursementType:add">
+												<a href="javascript:void(0);" onclick="openDialog('添加人员信息', '${ctx}/areaStaff/areaStaff/userForm?parent.id=${areaStaffInfo.id}','80%','60%')" class="layui-btn layui-btn-xs  #16b777"> 人员管理</a>
+											</shiro:hasPermission>
+										</c:if>
+										<%--<c:if test="${areaStaffInfo.grade ==3}">
+											<shiro:hasPermission name="reimbursementType:reimbursementType:del">
+												<a href="${ctx}/areaStaff/areaStaff/delete?id=${areaStaffInfo.id}" onclick="return confirmx('确认要删除该地区人员吗?', this.href)"   class="layui-btn layui-btn-xs layui-bg-red"> 删除成员</a>
+											</shiro:hasPermission>
+										</c:if>--%>
+									</div>
+								</div>
+							</td>
+						</tr>
+					</c:forEach>
+					</tbody>
+				</table>
+
+				<!-- 分页代码 -->
+				<%--<table:page page="${page}"></table:page>--%>
+
+			</div>
+		</div>
+	</div>
+</div>
+<script>
+	resizeListWindow1();
+	$(window).resize(function(){
+		resizeListWindow1();
+	});
+</script>
+</body>
+</html>

+ 108 - 0
src/main/webapp/webpage/modules/areaStaff/areaStaffSecondForm.jsp

@@ -0,0 +1,108 @@
+<%@ 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{
+			top:40px;
+			left:0;
+		}
+		#standardDetail-error{
+			top:82px;
+			left:0;
+		}
+	</style>
+	<script type="text/javascript">
+		var validateForm;
+		function doSubmit(){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+		  if(validateForm.form()){
+			  $("#inputForm").submit();
+			  return true;
+		  }
+	
+		  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);
+					}
+				}
+			});
+            var edit = "${workReviewStandard.id}";
+            if(edit!=null && edit!=''){
+                $("#reviewParentButton").attr("disabled","disabled");
+            }
+		});
+
+
+        function setAreaValue(obj){
+			var areaId = obj.id
+			var officeId = '${areaStaffInfo.office.id}';
+			//根据地区id和部门id去查询是否已经被选择
+
+			$.ajax({
+				type: 'post',
+				url:'${ctx}/areaStaff/areaStaff/getEffectiveArea',
+				data: {"officeId":officeId,"areaId":areaId},
+				dataType: "json",
+				async: false
+			}).success(function (result) {
+				if(!result.success){
+					$("#areaId").val("")
+					$("#areaName").val("")
+					top.layer.msg(result.message, {icon: 0});
+					return false;
+				}
+			}).error(function () {
+				top.layer.msg("地区查询失败!");
+			});
+
+
+        }
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="areaStaffInfo" action="${ctx}/areaStaff/areaStaff/secondSave" method="post" class="form-horizontal">
+		<form:hidden path="id"/>
+		<form:hidden path="companyId"/>
+		<form:hidden path="parent.id"/>
+		<form:hidden path="parent.orderNum"/>
+		<form:hidden path="hierarchy"/>
+			<div class="form-group layui-row first">
+				<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">
+						<sys:treeselectbelongingDepartment disabled="disabled" id="reviewParent" name="office.id" value="${areaStaffInfo.office.id}" labelName="office.name" labelValue="${areaStaffInfo.office.name}"
+														   cssStyle="background-color:#fff" title="归属部门" url="/sys/office/treeData?type=2" cssClass="form-control layui-input" 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:treeselectStaffArea id="area" name="area.id" value="${areaStaffInfo.area.id}" labelName="area.name" labelValue="${areaStaffInfo.area.name}"
+												   cssStyle="background-color: #fff" title="区域" url="/sys/area/treeData" cssClass="form-control judgment layui-input" allowClear="true" notAllowSelectParent="false"/>
+					</div>
+				</div>
+			</div>
+		</form:form>
+	</div>
+</div>
+</body>
+</html>

+ 187 - 0
src/main/webapp/webpage/modules/areaStaff/areaStaffUserForm.jsp

@@ -0,0 +1,187 @@
+<%@ 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{
+			top:40px;
+			left:0;
+		}
+		#standardDetail-error{
+			top:82px;
+			left:0;
+		}
+	</style>
+	<script type="text/javascript">
+		var validateForm;
+		function doSubmit(){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+		  if(validateForm.form()){
+			  $("#inputForm").submit();
+			  return true;
+		  }
+	
+		  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);
+					}
+				}
+			});
+            var edit = "${workReviewStandard.id}";
+            if(edit!=null && edit!=''){
+                $("#reviewParentButton").attr("disabled","disabled");
+            }
+		});
+
+
+        function setAreaValue(obj){
+			console.log("进入area选择项")
+			console.log("进入area选择项obj:",obj)
+			var areaId = obj.id
+			var officeId = '${areaStaffInfo.office.id}';
+			//根据地区id和部门id去查询是否已经被选择
+
+			$.ajax({
+				type: 'post',
+				url:'${ctx}/areaStaff/areaStaff/getEffectiveArea',
+				data: {"officeId":officeId,"areaId":areaId},
+				dataType: "json",
+				async: false
+			}).success(function (result) {
+				if(!result.success){
+					top.layer.msg(result.message, {icon: 0});
+					return false;
+				}
+			}).error(function () {
+				top.layer.msg("地区查询失败!");
+			});
+
+
+        }
+
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="areaStaffInfo" action="${ctx}/areaStaff/areaStaff/secondSave" method="post" class="form-horizontal">
+		<form:hidden path="id"/>
+		<form:hidden path="companyId"/>
+		<form:hidden path="parent.id"/>
+		<form:hidden path="parent.orderNum"/>
+		<form:hidden path="hierarchy"/>
+			<div class="form-group layui-row first">
+				<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">
+						<sys:treeselectbelongingDepartment disabled="disabled" id="reviewParent" name="office.id" value="${areaStaffInfo.office.id}" labelName="office.name" labelValue="${areaStaffInfo.office.name}"
+														   cssStyle="background-color:#fff" title="归属部门" url="/sys/office/treeData?type=2" cssClass="form-control layui-input" 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:treeselectStaffArea disabled="disabled" id="area" name="area.id" value="${areaStaffInfo.area.id}" labelName="area.name" labelValue="${areaStaffInfo.area.name}"
+												   cssStyle="background-color: #fff" title="区域" url="/sys/area/treeData" cssClass="form-control judgment layui-input" allowClear="true" notAllowSelectParent="false"/>
+					</div>
+				</div>
+			</div>
+		</form:form>
+		<div class="form-group layui-row">
+			<div class="form-group-label"><h2>人员信息</h2></div>
+			<form id="assignRoleForm" action="${ctx}/areaStaff/areaStaff/assignUser" method="post" class="hide">
+				<input type="hidden" name="id" value="${areaStaffInfo.id}"/>
+				<input type="hidden" name="office.id" value="${areaStaffInfo.office.id}"/>
+				<input id="idsArr" type="hidden" name="idsArr" value=""/>
+			</form>
+			<div class="layui-item nav-btns">
+				<a href="javascript:void(0);" id="assignButton" class="nav-btn nav-btn-add" title="添加人员"><i class="fa fa-plus"></i>&nbsp;新增</a>
+			</div>
+			<div class="layui-item layui-col-xs12 form-table-container" >
+				<table id="contentTable" class="table table-bordered table-condensed details">
+					<thead>
+					<tr>
+						<th>归属公司</th>
+						<th>归属部门</th>
+						<th>姓名</th>
+						<th>电话</th>
+						<th>手机</th>
+						<shiro:hasPermission name="sys:user:edit"><th width="80">操作</th></shiro:hasPermission>
+					</tr>
+					</thead>
+					<tbody>
+					<c:forEach items="${userList}" var="user">
+						<tr>
+							<td>${user.company.name}</td>
+							<td>${user.office.name}</td>
+							<td>${user.name}</td>
+							<td>${user.phone}</td>
+							<td>${user.mobile}</td>
+							<shiro:hasPermission name="sys:role:edit"><td class="op-td">
+								<a href="${ctx}/areaStaff/areaStaff/outUser?userId=${user.id}&id=${areaStaffInfo.id}"
+								   onclick="return confirmx('确认要将用户<b>[${user.name}]</b>移除吗?', this.href)" class="op-btn op-btn-add"><i class="glyphicon glyphicon-remove"></i> 移除</a>
+							</td></shiro:hasPermission>
+						</tr>
+					</c:forEach>
+					</tbody>
+				</table>
+			</div>
+		</div>
+	</div>
+</div>
+
+<script type="text/javascript">
+	$("#assignButton").click(function(){
+
+		top.layer.open({
+			type: 2,
+			area: ['90%','90%'],
+			title:"选择用户",
+			skin:"two-btns",
+			maxmin: true, //开启最大化最小化按钮
+			content: "${ctx}/areaStaff/areaStaff/getUserList?id=${areaStaffInfo.id}&office.id=${areaStaffInfo.office.id}" ,
+			btn: ['确定', '关闭'],
+			yes: function(index, layero){
+				var pre_ids = layero.find("iframe")[0].contentWindow.pre_ids;
+				var ids = layero.find("iframe")[0].contentWindow.ids;
+				if(ids[0]==''){
+					ids.shift();
+					pre_ids.shift();
+				}
+				if(pre_ids.sort().toString() == ids.sort().toString()){
+					top.$.jBox.tip("未分配人员信息!", 'info');
+					return false;
+				};
+				// 执行保存
+				//loading('正在提交,请稍等...');
+				var idsArr = "";
+				for (var i = 0; i<ids.length; i++) {
+					idsArr = (idsArr + ids[i]) + (((i + 1)== ids.length) ? '':',');
+				}
+				$('#idsArr').val(idsArr);
+				$('#assignRoleForm').submit();
+				top.layer.close(index);
+			},
+			cancel: function(index){
+			}
+		});
+	});
+</script>
+</body>
+</html>

+ 69 - 0
src/main/webapp/webpage/modules/areaStaff/areaStaffView.jsp

@@ -0,0 +1,69 @@
+<%@ 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">
+		var validateForm;
+		function doSubmit(){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+		  if(validateForm.form()){
+			  $("#inputForm").submit();
+			  return true;
+		  }
+
+		  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);
+					}
+				}
+			});
+		});
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container view-form">
+		<form:form id="inputForm" modelAttribute="areaStaffInfo" action="#" method="post" class="form-horizontal">
+		<form:hidden path="id"/>
+
+			<div class="form-group layui-row first">
+				<div class="form-group-label"><h2>详情</h2></div>
+				<c:if test="${areaStaffInfo.hierarchy == 1 or areaStaffInfo.hierarchy == 2}">
+					<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:treeselectbelongingDepartment disabled="disabled" id="reviewParent" name="office.id" value="${areaStaffInfo.office.id}" labelName="office.name" labelValue="${areaStaffInfo.office.name}"
+															   cssStyle="background-color:#fff" title="归属部门" url="/sys/office/treeData?type=2" cssClass="form-control layui-input" allowClear="true" notAllowSelectParent="true"/>
+						</div>
+					</div>
+				</c:if>
+
+				<c:if test="${areaStaffInfo.hierarchy == 2 }">
+					<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:treeselectStaffArea disabled="disabled" id="area" name="area.id" value="${areaStaffInfo.area.id}" labelName="area.name" labelValue="${areaStaffInfo.area.name}"
+													 cssStyle="background-color: #fff" title="区域" url="/sys/area/treeData" cssClass="form-control judgment layui-input" allowClear="true" notAllowSelectParent="false"/>
+						</div>
+					</div>
+				</c:if>
+
+			</div>
+		</form:form>
+	</div>
+</div>
+</body>
+</html>

+ 128 - 0
src/main/webapp/webpage/modules/areaStaff/selectUserToStaff.jsp

@@ -0,0 +1,128 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>分配岗位</title>
+	<meta name="decorator" content="blank"/>
+	<%@include file="/webpage/include/treeview.jsp" %>
+	<script type="text/javascript">
+	
+		var officeTree;
+		var selectedTree;//zTree已选择对象
+		
+		// 初始化
+		$(document).ready(function(){
+			officeTree = $.fn.zTree.init($("#officeTree"), setting, officeNodes);
+			selectedTree = $.fn.zTree.init($("#selectedTree"), setting, selectedNodes);
+		});
+
+		var setting = {view: {selectedMulti:false,nameIsHTML:true,showTitle:false,dblClickExpand:false},
+				data: {simpleData: {enable: true}},
+				callback: {onClick: treeOnClick}};
+		
+		var officeNodes=[
+	            <c:forEach items="${officeList}" var="office">
+	            {id:"${office.id}",
+	             pId:"${not empty office.parent?office.parent.id:0}", 
+	             name:"${office.name}"},
+	            </c:forEach>];
+	
+		var pre_selectedNodes =[
+   		        <c:forEach items="${userList}" var="user">
+   		        {id:"${user.id}",
+   		         pId:"0",
+   		         name:"<font color='red' style='font-weight:bold;'>${user.name}</font>"},
+   		        </c:forEach>];
+		
+		var selectedNodes =[
+		        <c:forEach items="${userList}" var="user">
+		        {id:"${user.id}",
+		         pId:"0",
+		         name:"<font color='red' style='font-weight:bold;'>${user.name}</font>"},
+		        </c:forEach>];
+		
+		var pre_ids = "${selectIds}".split(",");
+		var ids = "${selectIds}".split(",");
+		//点击选择项回调
+		function treeOnClick(event, treeId, treeNode, clickFlag){
+			$.fn.zTree.getZTreeObj(treeId).expandNode(treeNode);
+			if("officeTree"==treeId){
+                officeId = treeNode.id;
+				$.get("${ctx}/sys/role/users?officeId=" + treeNode.id, function(userNodes){
+					$.fn.zTree.init($("#userTree"), setting, userNodes);
+				});
+			}
+			if("userTree"==treeId){
+				$.get("${ctx}/areaStaff/areaStaff/checkUserCompany?userId=" + treeNode.id+"&id=${areaStaffInfo.id}", function(data){
+					if(data == "false"){
+				//alert(treeNode.id + " | " + ids);
+				//alert(typeof ids[0] + " | " +  typeof treeNode.id);
+						if($.inArray(String(treeNode.id), ids)<0){
+							selectedTree.addNodes(null, treeNode);
+							ids.push(String(treeNode.id));
+						}
+					}else{
+						$.jBox.tip("该用户已存在!", 'info');
+					}
+				});
+			};
+			if("selectedTree"==treeId){
+				if($.inArray(String(treeNode.id), pre_ids)<0){
+					selectedTree.removeNode(treeNode);
+					ids.splice($.inArray(String(treeNode.id), ids), 1);
+				}else{
+					$.jBox.tip("原有成员不能清除!", 'info');
+				}
+			}
+		};
+		function clearAssign(){
+			var submit = function (v, h, f) {
+			    if (v == 'ok'){
+					var tips="";
+					if(pre_ids.sort().toString() == ids.sort().toString()){
+						tips = "未分配人员信息!";
+					}else{
+						tips = "已选人员清除成功!";
+					}
+					ids=pre_ids.slice(0);
+					selectedNodes=pre_selectedNodes;
+					$.fn.zTree.init($("#selectedTree"), setting, selectedNodes);
+			    	top.$.jBox.tip(tips, 'info');
+			    } else if (v == 'cancel'){
+			    	// 取消
+			    	top.$.jBox.tip("取消清除操作!", 'info');
+			    }
+			    return true;
+			};
+			tips="确定清除已选人员?";
+			top.$.jBox.confirm(tips, "清除确认", submit);
+		};
+	</script>
+</head>
+<body>
+<div class="single-form">
+	<div class="container">
+	<div id="assignRole" class="row" style="margin-top: 16px;">
+		<div class="col-sm-4" style="border-right: 1px solid #A8A8A8;padding: 0;margin-left: -1px;">
+			<div style="padding: 0 16px 16px 16px;" >
+				<p>所在部门:</p>
+				<div id="officeTree" class="ztree"></div>
+			</div>
+		</div>
+		<div class="col-sm-4" style="padding: 0;">
+			<div style="padding: 0 16px 16px 16px;">
+				<p>待选人员:</p>
+				<div id="userTree" class="ztree"></div>
+			</div>
+		</div>
+		<div class="col-sm-4" style="padding-left:16px;border-left: 1px solid #A8A8A8;padding: 0;margin-right: -1px;">
+			<div style="padding: 0 16px 16px 16px;">
+				<p>已选人员:</p>
+				<div id="selectedTree" class="ztree"></div>
+			</div>
+		</div>
+	</div>
+	</div>
+</div>
+</body>
+</html>

+ 702 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/electronicSeal/electronicSealCZ/ruralProjectRecordsApprovalCZAudit.jsp

@@ -0,0 +1,702 @@
+<%@ 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" src="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.js"></script>
+	<script type="text/javascript" src="${ctxStatic}/iCheck/icheck.min.js"></script>
+	<script type="text/javascript" src="${ctxStatic}/layui/layuidown.js"></script>
+	<script src="${ctxStatic}/common/html/js/script.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+
+	<script type="text/javascript">
+		var validateForm;
+		function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+				var ss= document.getElementById("iframe").contentWindow.document.getElementById("opinion").value
+				$("#opinion").val(ss);
+                if(obj == 1) {
+
+					var auditFlag = $("#auditFlag").val();
+					console.log(123123)
+					if(auditFlag != 1){
+						top.layer.msg('审定单签章未审核完成,请审核后点击同意', {icon: 0});
+						return false;
+					}
+                    $("#flag").val("yes");
+                }else {
+                    if(obj == 2){
+                        $("#flag").val("no1");
+					}else {
+                        $("#flag").val("no2");
+					}
+                }
+                $("#inputForm").submit();
+                return true;
+            }
+
+		  return false;
+		}
+		$(document).ready(function() {
+			if(null != '${signatureType}' && undefined != '${signatureType}' && '' != '${signatureType}'){
+				if("${signatureType}" == "1"){
+					$("#signaturePhotoDiv").show();
+					$("#chongming").show();
+					$("#jinshan").hide();
+					$("#custom").hide();
+				}else if("${signatureType}" == "3"){
+					$("#signaturePhotoDiv").show();
+					$("#custom").show();
+					$("#chongming").hide();
+					$("#jinshan").hide();
+
+				}
+			}
+			if("3" === '${signatureType}'){
+				getManualSignatureStatus('${projectRecords.id}')
+			}
+
+			layui.use(['form', 'layer'], function () {
+				var form = layui.form;
+				//审定单签章样式调整
+				layui.form.on('radio(signatureTypeRadio)', function(data){
+					var span=data.value;
+					if(span==1){
+						$("#signaturePhotoDiv").show();
+						$("#chongming").show();
+						$("#jinshan").hide();
+						$("#custom").hide();
+					}else if(span==3){
+						$("#signaturePhotoDiv").show();
+						$("#custom").show();
+						$("#chongming").hide();
+						$("#jinshan").hide();
+					}
+				});
+			});
+
+			var tt = $("#contractNum").val();
+			if (tt == null || tt === "") {
+				$("#divv").hide();
+				$("#divv2").show();
+				$("#divv3").hide();
+				setTimeout(function () {
+					var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+					$("#clientName").val(tt);
+				},100);
+			}else{
+				$("#divv2").hide();
+			}
+
+			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);
+					}
+				}
+			});
+
+			var contractNum = $("#contractNum").val();
+			if (contractNum == null || contractNum === "") {
+				$("#div1").hide();
+				$("#div3").hide();
+				setTimeout(function () {
+					var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+					$("#clientName").val(tt);
+				},100);
+			}
+
+			var contractInformation='${projectRecords.workContractInfo.contractInformation}'
+			if(contractInformation == "1"){
+				$("#c2").show();
+				$("#c1").hide();
+			}else{
+				$("#c2").hide();
+				$("#c1").show();
+			}
+		});
+
+        function getManualSignatureStatus(projectId){
+			$.ajax({
+				type:"post",
+				url:'${ctx}/ruralProject/electronicSeal/getManualSignatureStatus',
+				data:{"projectId": projectId},
+				dataType:"json",
+				success:function(data){
+					if(data.success) {
+						//签章按钮隐藏
+						$("#approvaButton").css("display","none");
+
+						//设置可以审核操作
+						$("#auditFlag").val(1)
+						top.layer.msg('签章已完成,请点击审核通过或驳回!', {icon: 1});
+					}
+				}
+			})
+        }
+
+        function insertTitle(tValue){
+            var files = $("#attachment_file")[0].files;
+            for(var i = 0;i<files.length;i++) {
+            	var file = files[i];
+            var attachmentId = $("#id").val();
+            var attachmentFlag = "194";
+            console.log(file);
+            var timestamp=new Date().getTime();
+
+				var storeAs = "selectronicSealApprovalCZ";
+            var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+            var divId = "_attachment";
+            $("#addFile"+divId).show();
+            multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,0);}
+        }
+
+        function addFile() {
+            $("#attachment_file").click();
+        }
+
+        function addRow(list, idx, tpl, row){
+            // var idx1 = $("#workClientLinkmanList tr").length;
+            bornTemplete(list, idx, tpl, row, idx);
+        }
+
+        function bornTemplete(list, idx, tpl, row, idx1){
+            $(list).append(Mustache.render(tpl, {
+                idx: idx, delBtn: true, row: row,
+                order:idx1 + 1
+            }));
+            $(list+idx).find("select").each(function(){
+                $(this).val($(this).attr("data-value"));
+            });
+            $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
+                var ss = $(this).attr("data-value").split(',');
+                for (var i=0; i<ss.length; i++){
+                    if($(this).val() == ss[i]){
+                        $(this).attr("checked","checked");
+                    }
+                }
+            });
+        }
+
+		function getManualSignatureUrl(projectId){
+			$.ajax({
+				type:"post",
+				url:'${ctx}/ruralProject/electronicSealCZ/getManualSignatureUrl',
+				data:{"projectId": projectId},
+				dataType:"json",
+				success:function(data){
+					if(data.success) {
+						window.open(data.contractUrl);
+						var interVal = setInterval(function (){
+									$.ajax({
+										type:"post",
+										url:'${ctx}/ruralProject/electronicSeal/getManualSignatureStatus',
+										data:{"projectId": projectId},
+										dataType:"json",
+										success:function(data){
+											if(data.success) {
+												//签章按钮隐藏
+												$("#approvaButton").css("display","none");
+												//设置可以审核操作
+												$("#auditFlag").val(1)
+												clearInterval(interVal)
+												top.layer.msg('签章已完成,请点击审核通过或驳回!', {icon: 1});
+											}
+										}
+									})
+								}
+								,3000)
+					}else {
+						top.layer.msg("签章失败!", {icon: 0});
+					}
+				}
+			})
+			return;
+		}
+	</script>
+</head>
+<body >
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="projectRecords" enctype="multipart/form-data" action="${ctx}/ruralProject/electronicSealCZ/approvalSaveAudit" method="post" class="form-horizontal layui-form">
+		<form:hidden path="id"/>
+		<form:hidden path="home"/>
+		<form:hidden path="act.taskId"/>
+		<form:hidden path="act.taskName"/>
+		<form:hidden id="taskDefKey" path="act.taskDefKey"/>
+		<form:hidden path="act.procInsId"/>
+		<form:hidden path="act.procDefId"/>
+		<form:hidden path="processInstanceId"/>
+		<form:hidden id="flag" path="act.flag"/>
+		<input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">
+		<input type="hidden" id="signatureType" name="signatureType" value="${signatureType}">
+		<input type="hidden" id="auditFlag" name="auditFlag" value="${auditFlag}">
+		<c:set var="status" value="${projectRecords.act.status}" />
+
+			<div class="form-group layui-row first">
+				<div class="form-group-label"><h2>项目合同信息</h2></div>
+				<div id="div1">
+					<div class="layui-item layui-col-sm12 lw6">
+						<label class="layui-form-label">合同编号:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false" id="contractNum"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.contractNum}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">合同名称:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.name}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6" id="c1">
+						<label class="layui-form-label double-line">合同金额(元):</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="<fmt:formatNumber value="${projectRecords.workContractInfo.contractPrice}" pattern="#,##0.00#"/>"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6" id="c2" style="display: none">
+						<label class="layui-form-label">费率描述:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" id="otherDetails"  class="form-control layui-input" value="${projectRecords.workContractInfo.otherDetails}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">委托方:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false" id="clientName" readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.client.name}"/>
+						</div>
+					</div>
+				</div>
+				<div id="divv2">
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">无合同</label>
+					</div>
+				</div>
+				<div id="div3">
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">合同类别:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" style="background-color: #f1f1f1" class="form-control layui-input" value="${fns:getMainDictLabel(projectRecords.workContractInfo.contractTypeDoc, 'contract_info_type', '')}"/>
+<%--							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.constructionProjectTypeStr}"/>--%>
+						</div>
+					</div>
+				</div>
+			</div>
+
+
+			<div class="form-group layui-row first">
+				<div class="form-group-label"><h2>项目基础信息</h2></div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">报告号:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectReportNumber}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目名称:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目编号:</label>
+					<div class="layui-input-block">
+						<div class="input-group">
+							<form:input path="projectId" htmlEscape="false"  readonly="true" class="form-control layui-input" cssStyle="background-color: #f1f1f1"/>
+							<span class="input-group-btn">
+                                <label class="form-status"><c:choose><c:when test="${not empty projectRecords.projectStatus}">${fns:getDictLabel(projectRecords.projectStatus, 'rural_project_audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                             </span>
+						</div>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目所在地:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.province}-${projectRecords.city}-${projectRecords.county}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">投资性质:</label>
+					<div class="layui-input-block">
+						<c:if test="${projectRecords.projectProperties==null}">
+							<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input"/>
+						</c:if>
+						<c:forEach  items="${fns:getMainDictList('project_properties')}" var="v">
+							<c:if test="${v.value==projectRecords.projectProperties}">
+								<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${v.label}"/>
+							</c:if>
+						</c:forEach>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">建设地点:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value="${projectRecords.projectSite}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">创建人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.createBy.name}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目责任人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.leaderNameStr}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">所属部门:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" id="officeName" class="form-control layui-input" value="${projectRecords.officeName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目负责人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.projectMasterName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">工程类型:</label>
+					<div class="layui-input-block">
+						<form:select path="engineeringType" disabled="true" style="background-color: #f1f1f1"  class="form-control simple-select">
+							<form:options items="${engineeringInfo}" itemLabel="engineeringName" itemValue="id" htmlEscape="false"/>
+						</form:select>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目等级:</label>
+					<div class="layui-input-block">
+						<c:forEach items="${fns:getMainDictListOnProjectAdvent('attachment_project_grade')}" var="v">
+							<input type="radio" disabled name="submitMoney" id="submitMoney" value="${v.value}" title="${v.label}" <c:if test="${projectRecords.submitMoney==v.value}">checked</c:if>>
+						</c:forEach>
+						<p style="color: red;font-size: 12px;">500万及500万以上为A级,500万以下为B级</p>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">送审规模(万元):</label>
+					<div class="layui-input-block">
+						<form:input path="submitScale" readonly="true" style="background-color: #f1f1f1" id="submitScale" maxlength="12" htmlEscape="false" placeholder="请输入送审规模" class="form-control layui-input number"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">工作开始日期:</label>
+					<div class="layui-input-block">
+						<input class="laydate-icondate form-control layui-input layer-date ash"  style="background-color: #f1f1f1" readonly="true" id="startDate" name="startDate" value="<fmt:formatDate value="${projectRecords.startDate}" pattern="yyyy-MM-dd"/>">
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">工作结束日期:</label>
+					<div class="layui-input-block">
+						<input class="laydate-icondate form-control layui-input layer-date "  style="background-color: #f1f1f1" readonly="true" id="endingDate" name="endingDate" value="<fmt:formatDate value="${projectRecords.endingDate}" pattern="yyyy-MM-dd"/>">
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">创建日期:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${projectRecords.createDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw7">
+					<label class="layui-form-label">项目类别:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" readonly="true"  style="background-color: #f1f1f1" class="form-control layui-input" value="${projectRecords.attachmentProjectSort}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6 with-textarea">
+					<label class="layui-form-label">工程概况:</label>
+					<div class="layui-input-block">
+						<textarea htmlEscape="false" rows="4" readonly="true"  style="background-color: #f1f1f1" maxlength="1000" class="form-control" >${projectRecords.projectDesc}</textarea>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6 with-textarea">
+					<label class="layui-form-label">备注:</label>
+					<div class="layui-input-block">
+						<textarea htmlEscape="false" rows="4" readonly="true" maxlength="1000"  style="background-color: #f1f1f1" class="form-control" >${projectRecords.remarks}</textarea>
+					</div>
+				</div>
+			</div>
+
+			<%--<c:if test="${approvalType == 1}">
+				<div class="form-group layui-row first">
+					<div class="form-group-label"><h2>审定单签章类型</h2></div>
+					<div class="layui-item layui-col-sm12 lw6 with-textarea">
+						<label class="layui-form-label double-line"><span class="require-item">*</span>审定单签章类型:</label>
+						<div class="layui-input-block with-icon">
+							<div style="overflow: hidden">
+								<input type="radio" name="signatureType" lay-filter="signatureTypeRadio" id="signatureType1" disabled title="审定单-固定" value="1" <c:if test="${signatureType == 1}">checked</c:if>>
+								<input type="radio" name="signatureType" lay-filter="signatureTypeRadio" id="signatureType3" disabled title="审定单-自定义" value="3" <c:if test="${signatureType == 3}">checked</c:if>>
+							</div>
+						</div>
+					</div>
+				</div>
+				<div class="form-group layui-row" id="signaturePhotoDiv" style="display: none">
+					<div class="layui-item nav-btns">
+						<label class="layui-form-label double-line">审定单签章模板:</label>
+						<div class="layui-upload-list" id="chongming" >
+							<img class="layui-upload-img" title="审定单固定位置自动盖章" width="200px" height="150px" id="chongmingImg" onclick="openDialogView('预览','${ctxStatic}/common/images/chongming.jpg','90%','90%')" src="${ctxStatic}/common/images/chongming.jpg">
+						</div>
+						<div class="layui-upload-list" id="custom">
+							<img class="layui-upload-img" title="审定单手动盖章" width="200px" height="150px" id="customImg" onclick="openDialogView('预览','${ctxStatic}/common/images/customSignature.jpg','90%','90%')" src="${ctxStatic}/common/images/customSignature.jpg">
+						</div>
+					</div>
+				</div>
+			</c:if>--%>
+
+			<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="contentTable" class="table table-bordered table-condensed no-bottom-margin details">
+						<thead>
+						<tr>
+							<th class="hide"></th>
+							<th width="25%">委托方</th>
+							<th width="25%">联系人姓名</th>
+							<th width="25%">联系方式1</th>
+							<th width="25%">联系方式2</th>
+						</tr>
+						</thead>
+						<tbody id="workClientLinkmanList">
+						<c:forEach items="${projectRecords.workClientLinkmanList}" var="info" varStatus="index">
+							<tr>
+								<td >
+										${info.clientId.name}
+								</td>
+								<td>
+										${info.name}
+								</td>
+								<td>
+										${info.linkPhone}
+								</td>
+								<td>
+										${info.linkMobile}
+								</td>
+							</tr>
+						</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="contentTable1" class="table table-bordered table-condensed no-bottom-margin details">
+						<thead>
+						<tr>
+							<th class="hide"></th>
+							<th width="25%">施工方单位名称</th>
+							<th width="25%">联系人姓名</th>
+							<th width="25%">联系方式1</th>
+							<th width="25%">联系方式2</th>
+						</tr>
+						</thead>
+						<tbody id="workConstructionLinkmanList">
+						<c:forEach items="${projectRecords.workConstructionLinkmanList}" var="info" varStatus="index">
+							<tr>
+								<td >
+										${info.clientId.name}
+								</td>
+								<td>
+										${info.name}
+								</td>
+								<td>
+										${info.linkPhone}
+								</td>
+								<td>
+										${info.linkMobile}
+								</td>
+							</tr>
+						</c:forEach>
+						</tbody>
+					</table>
+				</div>
+			</div>
+
+
+			<div class="form-group layui-row">
+				<c:if test="${auditFlag != 1}">
+					<div style="float: right"> <a id="approvaButton" href=javascript:void(0);  onclick="getManualSignatureUrl('${projectRecords.id}')" class="layui-btn layui-btn-sm" >审定单审核</a></div>
+				</c:if>
+				<div class="form-group-label"><h2>审定单签章附件信息</h2></div>
+				<div class="layui-item layui-col-xs12" style="padding:0 16px;">
+					<table id="listAttachment" class="table table-bordered table-condensed details">
+						<thead>
+						<tr>
+								<%-- <th>序号</th>--%>
+							<th>文件预览</th>
+							<th>上传人</th>
+							<th>上传时间</th>
+							<th width="180px">操作</th>
+						</tr>
+						</thead>
+						<tbody id="file_attachment">
+						<c:forEach items="${projectRecords.workAttachments}" var = "workClientAttachment" varStatus="status">
+							<tr>
+									<%-- <td>${status.index + 1}</td>--%>
+								<c:choose>
+									<c:when test="${projectRecords.uploadMode == 2}">
+										<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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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.temporaryUrl}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+													</c:when>
+													<c:otherwise>
+														<c:choose>
+															<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+															</c:when>
+															<c:otherwise>
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</c:otherwise>
+										</c:choose>
+									</c:when>
+									<c:otherwise>
+										<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>
+														<c:choose>
+															<c:when test="${workReimbursement.uploadMode == 2}">
+																<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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+																			</c:when>
+																			<c:otherwise>
+																				<c:choose>
+																					<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+																					</c:when>
+																					<c:otherwise>
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+																					</c:otherwise>
+																				</c:choose>
+																			</c:otherwise>
+																		</c:choose>
+																	</c:otherwise>
+																</c:choose>
+															</c:when>
+															<c:otherwise>
+																<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 href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+																			</c:when>
+																			<c:otherwise>
+																				<c:choose>
+																					<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+																					</c:when>
+																					<c:otherwise>
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+																					</c:otherwise>
+																				</c:choose>
+																			</c:otherwise>
+																		</c:choose>
+																	</c:otherwise>
+																</c:choose>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</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('${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_attachment','_attachment')" 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>
+
+
+
+	</form:form>
+		<div class="form-group-label">
+			<div style="float: right"> <a href="javascript:void(0)" style='background-color: #FFB800' onclick="openDialogre('个人模板列表', '${ctx}/auditTemplate/auditTemplate/templateList?identification=${identification}&name=${identificationName}','80%', '70%','','关闭')" class="nav-btn layui-btn layui-btn-sm" ><i class="fa fa-file-excel-o"></i> 审核意见模板列表</a></div>
+			<h2>审批意见</h2>
+		</div>
+		<iframe id="iframe" src="${ctx}/auditTemplate/auditTemplate/iframeView?identification=${identification}" name="listresult" frameborder="0" align="left" width="100%" height="300" scrolling="value"></iframe>
+			<div class="form-group layui-row">
+				<div class="form-group-label"><h2>${projectNotifyType}审批流程</h2></div>
+				<div class="layui-item layui-col-xs12 form-table-container" >
+					<act:flowChart procInsId="${processInstanceId}"/>
+					<act:histoicFlow procInsId="${processInstanceId}"/>
+				</div>
+			</div>
+	</div>
+</div>
+</body>
+</html>

+ 612 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectMessageElectronicSealCZList.jsp

@@ -0,0 +1,612 @@
+<%@ 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" src="${ctxStatic}/layui/layuidown.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
+	<script type="text/javascript">
+		$(document).ready(function() {
+
+			//搜索框收放
+			$('#moresee').click(function(){
+				if($('#moresees').is(':visible'))
+				{
+					$('#moresees').slideUp(0,resizeListWindow2);
+					$('#moresee i').removeClass("glyphicon glyphicon-menu-up").addClass("glyphicon glyphicon-menu-down");
+				}else{
+					$('#moresees').slideDown(0,resizeListWindow2);
+					$('#moresee i').removeClass("glyphicon glyphicon-menu-down").addClass("glyphicon glyphicon-menu-up");
+				}
+			});
+			laydate.render({
+				elem: '#beginDate', //目标元素。由于laydate.js封装了一个轻量级的选择器引擎,因此elem还允许你传入class、tag但必须按照这种方式 '#id .class'
+				event: 'focus', //响应事件。如果没有传入event,则按照默认的click
+				type : 'date'
+				, trigger: 'click'
+			});
+			laydate.render({
+				elem: '#endDate', //目标元素。由于laydate.js封装了一个轻量级的选择器引擎,因此elem还允许你传入class、tag但必须按照这种方式 '#id .class'
+				event: 'focus', //响应事件。如果没有传入event,则按照默认的click
+				type : 'date'
+				, trigger: 'click'
+			});
+			layui.use(['form', 'layer'], function () {
+				var form = layui.form;
+			})
+			layui.use(['dropdown', 'util', 'layer'], function () {
+				var form = layui.form;
+			})
+
+		});
+
+		function openDialog(title,url,width,height,target) {
+
+			if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+				width = 'auto';
+				height = 'auto';
+			} else {//如果是PC端,根据用户设置的width和height显示。
+
+			}
+
+			top.layer.open({
+				type: 2,
+				area: [width, height],
+				title: title,
+				maxmin: true, //开启最大化最小化按钮
+				content: url,
+				skin: 'three-btns',
+				btn: ['送审', '暂存', '关闭'],
+				btn1: function(index, layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(1) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}
+				},
+				btn2:function(index,layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(2) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}else {
+						return false;
+					}
+				},
+				btn3: function (index) {
+				}
+			});
+		}
+
+
+		function openDialogBySave(title,url,width,height,target) {
+
+			if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+				width = 'auto';
+				height = 'auto';
+			} else {//如果是PC端,根据用户设置的width和height显示。
+
+			}
+
+			top.layer.open({
+				type: 2,
+				area: [width, height],
+				title: title,
+				maxmin: true, //开启最大化最小化按钮
+				content: url,
+				skin: 'three-btns',
+				btn: ['送审', '关闭'],
+				btn1: function(index, layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(1) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}
+				},
+				btn2: function (index) {
+				}
+			});
+		}
+
+		function openDialogre(title,url,width,height,target,buttons) {
+
+			if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+				width = 'auto';
+				height = 'auto';
+			} else {//如果是PC端,根据用户设置的width和height显示。
+
+			}
+			var split = buttons.split(",");
+			top.layer.open({
+				type: 2,
+				area: [width, height],
+				title: title,
+				maxmin: true, //开启最大化最小化按钮
+				skin: 'three-btns',
+				content: url,
+				btn: split,
+				btn1: function(index, layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(1) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}
+				},
+				btn2:function(index,layero){
+					if(split.length==2){return}
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(2) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}else {
+						return false;
+					}
+				},
+				btn3: function (index) {
+				}
+			});
+		}
+
+
+		function openDialogreAudit(title,url,width,height,target){
+
+			if(navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)){//如果是移动端,就使用自适应大小弹窗
+				width='auto';
+				height='auto';
+			}else{//如果是PC端,根据用户设置的width和height显示。
+
+			}
+			top.layer.open({
+				type: 2,
+				area: [width, height],
+				title: title,
+				skin: 'three-btns',
+				maxmin: true, //开启最大化最小化按钮
+				content: url ,
+				btn: ['送审','关闭'],
+				btn1: function(index, layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(1) ){
+						top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}
+				},
+				btn2: function(index){
+				}
+			});
+		}
+
+		function show(d) {
+			////对操作进行初始化
+			var xml = '<div class=\"layui-btn-group\">';
+
+
+			if(d.falg=="1" && d.electronicSeal == "1"){
+				if(d.approvalSignatureStatus == 0){
+					xml+="<a href=\"javascript:void(0)\"  onclick=\"openDialogBySave('审定单签章申请', '${ctx}/ruralProject/electronicSealCZ/approvalForm?id=" + d.id + "','90%', '90%','')\" class=\"layui-btn layui-btn-xs layui-bg-blue\" align='center' style='height: 32px;margin-top: 5px;margin-bottom: 5px;' > 审定单签章申请</a>";
+				}else if(d.approvalSignatureStatus == 1){
+					xml+="<a href=\"#\" onclick=\"openDialogre('修改审定单签章申请', '${ctx}/ruralProject/electronicSealCZ/approvalForm?id=" + d.id + "','95%', '95%','','送审,关闭')\" class=\"layui-btn layui-btn-xs layui-bg-green\" style='height: 32px;margin-top: 5px;margin-bottom: 5px;' > 修改审定单签章申请</a>";
+				}else if(d.approvalSignatureStatus == 2){
+					xml+="<a href=\"${ctx}/ruralProject/electronicSealCZ/approvalRevoke?id=" + d.id + "&processInstanceId=" + d.procId + "\" onclick=\"return confirmx('确认要撤回该审定单签章申请吗?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\" style='height: 32px;margin-top: 5px;margin-bottom: 5px;' > 撤回</a>";
+				}else if(d.approvalSignatureStatus == 3){
+					xml+="<a href=\"#\" onclick=\"openDialogre('修改审定单签章申请', '${ctx}/ruralProject/electronicSealCZ/approvalForm?id=" + d.id + "','95%', '95%','','送审,关闭')\" class=\"layui-btn layui-btn-xs layui-bg-green\" style='height: 32px;margin-top: 5px;margin-bottom: 5px;' > 修改审定单签章申请</a>";
+				}else if(d.approvalSignatureStatus == 4){
+					xml+="<a href=\"javascript:void(0)\" onclick=\"openDialogreAudit('修改审定单签章申请', '${ctx}/ruralProject/electronicSealCZ/approvalModify?id=" + d.id + "','95%', '95%','')\" class=\"layui-btn layui-btn-xs layui-bg-green\" style='height: 32px;margin-top: 5px;margin-bottom: 5px;' > 修改审定单签章申请</a>";
+				}
+
+				if(d.reportSignatureStatus == 0){
+					xml+="<a href=\"javascript:void(0)\" onclick=\"openDialogBySave('报告签章申请', '${ctx}/ruralProject/electronicSealCZ/reportSignatureForm?id=" + d.id + "','90%', '90%','')\" class=\"layui-btn layui-btn-xs layui-bg-blue\" style='height: 32px;margin-top: 5px;margin-bottom: 5px;' > 报告签章申请</a>";
+				}else if(d.reportSignatureStatus == 1){
+					xml+="<a href=\"#\" onclick=\"openDialogre('修改报告签章申请', '${ctx}/ruralProject/electronicSealCZ/reportSignatureForm?id=" + d.id + "','95%', '95%','','送审,关闭')\" class=\"layui-btn layui-btn-xs layui-bg-green\" style='height:32px;margin-top: 5px;margin-bottom: 5px;' > 修改报告签章申请</a>";
+				}else if(d.reportSignatureStatus == 2){
+					xml+="<a href=\"${ctx}/ruralProject/electronicSealCZ/reportSignatureRevoke?id=" + d.id + "&processInstanceId=" + d.procId + "\" onclick=\"return confirmx('确认要撤回该报告签章申请吗?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\" style='height:32px;margin-top: 5px;margin-bottom: 5px;' > 撤回</a>";
+				}else if(d.reportSignatureStatus == 3){
+					xml+="<a href=\"#\" onclick=\"openDialogre('修改报告签章申请', '${ctx}/ruralProject/electronicSealCZ/reportSignatureForm?id=" + d.id + "','95%', '95%','','送审,关闭')\" class=\"layui-btn layui-btn-xs layui-bg-green\" style='height:32px;margin-top: 5px;margin-bottom: 5px;' > 修改报告签章申请</a>";
+				}else if(d.reportSignatureStatus == 4){
+					xml+="<a href=\"javascript:void(0)\" onclick=\"openDialogreAudit('修改报告签章申请', '${ctx}/ruralProject/electronicSealCZ/reportSignatureModify?id=" + d.id + "','95%', '95%','')\" class=\"layui-btn layui-btn-xs layui-bg-green\" style='height:32px;margin-top: 5px;margin-bottom: 5px' > 修改报告签章申请</a>";
+				}
+
+				if(d.prsiId != null && d.prsiId != undefined && d.prsiId != ""){
+					xml+="<a href=\"#\" onclick=\"openDialogre('修改报告签发信息', '${ctx}/ruralProject/electronicSealCZ/form?id=" + d.id +"','95%', '95%','','提交,关闭')\" class=\"layui-btn layui-btn-xs layui-bg-green\" style='height:32px;margin-top: 5px;margin-bottom: 5px;' > 修改报告信息</a>";
+				}
+				if(d.signatureDownloadUrl != null && d.signatureDownloadUrl != undefined && d.signatureDownloadUrl != ""){
+					xml+="<a href=\""+d.signatureDownloadUrl+"\" class=\"layui-btn  layui-btn-xs layui-bg-orange\" style='height:32px;margin-top: 5px;margin-bottom: 5px;'>报告下载</a>"
+				}else{
+					if(d.prsiId != null && d.prsiId != undefined && d.prsiId != ""){
+						//报告下载
+						xml+="<a href=\"${ctx}/ruralProject/electronicSealCZ/downloadMassControl?id="+ d.pidId +"\" class=\"layui-btn  layui-btn-xs layui-bg-orange\" style='height:32px;margin-top: 5px;margin-bottom: 5px;'>报告下载</a>"
+					}
+				}
+
+			}
+			if(d.approvalSignatureStatus == 5){
+				//上传审定单进行签章
+
+				if(d.approvalSignatureUrlFlag == 1){
+					xml+="<a href=\""+ d.signatureUrl +"\" class=\"layui-btn  layui-btn-xs layui-bg-orange\" style='height:32px;margin-top: 5px;margin-bottom: 5px;'>审定单签章下载</a>"
+				}else{
+					xml+="<a href=\"${ctx}/ruralProject/signatureCallBack/downLoadAttach?contractId="+ d.signatureContractId +"\" class=\"layui-btn  layui-btn-xs layui-bg-orange\" style='height:32px;margin-top: 5px;margin-bottom: 5px;'>审定单签章下载</a>"
+				}
+
+			}
+			if(d.reportSignatureStatus == 5){
+				//上传审定单进行签章
+				if(d.reportSignatureUrlFlag == 1){
+					xml+="<a href=\""+ d.reportSignatureUrl +"\" class=\"layui-btn  layui-btn-xs layui-bg-orange\" style='height:32px;margin-top: 5px;margin-bottom: 5px;'>报告签章下载</a>"
+				}else{
+					xml+="<a href=\"${ctx}/ruralProject/signatureCallBack/downLoadReportAttach?contractId="+ d.reportSignatureContractId +"\" class=\"layui-btn  layui-btn-xs layui-bg-orange\" style='height:32px;margin-top: 5px;margin-bottom: 5px;'>报告签章下载</a>"
+				}
+
+			}
+			xml+="</div>";
+			return[xml].join('');
+		}
+	</script>
+</head>
+<body>
+<div class="wrapper wrapper-content">
+	<sys:message content="${message}"/>
+	<div class="layui-row">
+		<div class="full-width fl">
+			<div class="layui-row contentShadow shadowLR" id="queryDiv">
+				<form:form id="searchForm" modelAttribute="ruralProjectRecords" action="${ctx}/ruralProject/electronicSealCZ/" method="post" class="layui-form">
+					<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
+					<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
+					<input id="toflag" name="toflag" type="hidden" value="1"/>
+					<table:sortColumn id="orderBy" name="orderBy" value="${page.orderBy}" callback="sortOrRefresh();"/><!-- 支持排序 -->
+					<div class="commonQuery lw6">
+						<div class="layui-item query athird " style="width: 25%">
+							<label class="layui-form-label">报告号:</label>
+							<div class="layui-input-block">
+								<form:input id="reportDataNumber" path="reportData.number" htmlEscape="false" maxlength="255"  class=" form-control layui-input"/>
+							</div>
+						</div>
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label">项目名称:</label>
+							<div class="layui-input-block">
+								<form:input path="projectName" htmlEscape="false" maxlength="64"  class=" form-control  layui-input"/>
+							</div>
+						</div>
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label">项目编号:</label>
+							<div class="layui-input-block with-icon">
+								<form:input path="projectId" htmlEscape="false" maxlength="64"  class=" form-control  layui-input"/>
+							</div>
+						</div>
+						<div class="layui-item athird" style="width: 25%">
+							<div class="input-group">
+								<a href="#" id="moresee"><i class="glyphicon glyphicon-menu-down"></i></a>
+								<div class="layui-btn-group search-spacing">
+									<button id="searchQuery" class="layui-btn layui-btn-sm layui-bg-blue" onclick="search()">查询</button>
+									<button id="searchReset" class="layui-btn layui-btn-sm" onclick="resetSearch()">重置</button>
+								</div>
+							</div>
+						</div>
+						<div style="    clear:both;"></div>
+					</div>
+					<div id="moresees" style="clear:both;display:none;" class="lw6">
+
+						<div class="layui-item query athird ">
+							<label class="layui-form-label">登记人:</label>
+							<div class="layui-input-block with-icon">
+								<sys:inquireselectUserNotReadolny id="createBy" name="createBy.id" value="${ruralProjectRecords.createBy.id}" labelName="createBy.name" labelValue="${ruralProjectRecords.createBy.name}" cssStyle="background-color: #fff"
+																  title="登记人" url="/sys/office/treeDataAll?type=3" cssClass="form-control layui-input" allowClear="true" notAllowSelectParent="true"/>
+							</div>
+						</div>
+						<div class="layui-item query athird ">
+							<label class="layui-form-label">项目责任人:</label>
+							<div class="layui-input-block with-icon">
+								<sys:inquireselectUserNotReadolnyTow id="leader" name="leaderId" value="${ruralProjectRecords.leaderId}" labelName="leaderNameStr" labelValue="${ruralProjectRecords.leaderNameStr}" cssStyle="background-color: #fff"
+																	 title="项目责任人" url="/sys/office/treeDataAll?type=3" cssClass="form-control layui-input" allowClear="true" notAllowSelectParent="true"/>
+							</div>
+						</div>
+						<div class="layui-item query athird">
+							<label class="layui-form-label">部门:</label>
+							<div class="layui-input-block with-icon">
+								<sys:treeselect id="office" name="office.id" value="${ruralProjectRecords.office.id}" labelName="office.name" labelValue="${ruralProjectRecords.office.name}"
+												cssStyle="background-color:#fff" title="部门" url="/sys/office/treeDataAll?type=2" cssClass="form-control layui-input" allowClear="true" notAllowSelectParent="false" />
+							</div>
+						</div>
+						<div class="layui-item query athird ">
+							<label class="layui-form-label">创建时间:</label>
+							<div class="layui-input-block readOnlyFFF">
+								<input id="beginDate" name="beginDate" placeholder="开始时间" type="text" readonly="readonly" maxlength="20" class="laydate-icondate form-control layer-date layui-input laydate-icon query-group"
+									   value="<fmt:formatDate value="${beginDate}" pattern="yyyy-MM-dd"/>"/>
+								</input>
+								<span class="group-sep">-</span>
+								<input id="endDate" name="endDate" placeholder="结束时间" type="text" readonly="readonly" maxlength="20" class="laydate-icondate form-control layer-date layui-input laydate-icon query-group"
+									   value="<fmt:formatDate value="${endDate}" pattern="yyyy-MM-dd"/>"/>
+								</input>
+							</div>
+						</div>
+
+						<div class="layui-item query athird ">
+							<label class="layui-form-label double-line">审定单申请:</label>
+							<div class="layui-input-block readOnlyFFF">
+								<form:select path="approvalSignatureStatus" class="form-control  simple-select">
+									<form:option value="" label=""/>
+									<form:options items="${fns:getDictList('signature_status')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+								</form:select>
+							</div>
+						</div>
+
+						<div class="layui-item query athird ">
+							<label class="layui-form-label double-line">报告签章申请:</label>
+							<div class="layui-input-block readOnlyFFF">
+								<form:select path="reportSignatureStatus" class="form-control  simple-select">
+									<form:option value="" label=""/>
+									<form:options items="${fns:getDictList('signature_status')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+								</form:select>
+							</div>
+						</div>
+						<div class="layui-item query athird ">
+							<label class="layui-form-label double-line">项目等级:</label>
+							<div class="layui-input-block readOnlyFFF">
+								<form:select path="submitMoney" class="form-control simple-select">
+									<form:option value="" label=""/>
+									<form:option value="2" label="A级"/>
+									<form:option value="1" label="B级"/>
+									<%--<form:option value="3" label="B级紧急"/>
+									<form:option value="1" label="B级非紧急"/>--%>
+								</form:select>
+							</div>
+						</div>
+						<div style="clear:both;"></div>
+					</div>
+				</form:form>
+			</div>
+		</div>
+
+		<div class="full-width fl">
+			<div class="layui-form contentDetails contentShadow shadowLBR">
+				<div class="nav-btns">
+					<%--此处按钮样式包括 nav-btn-add nav-btn-refresh nav-btn-import nav-btn-export nav-btn-query nav-btn-reset--%>
+					<div class="layui-btn-group">
+						<shiro:hasPermission name="ruralProject:ruralProjectMessageAll:importB">
+							<table:importExcel url="${ctx}/ruralProject/electronicSealCZ/importB"></table:importExcel><!-- 导入按钮 -->
+						</shiro:hasPermission>
+						<button class="layui-btn layui-btn-sm" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
+
+					</div>
+					<div style="clear: both;"></div>
+				</div>
+				<table class="oa-table layui-table" id="contentTable1" lay-filter="test"></table>
+
+				<!-- 分页代码 -->
+				<table:page page="${page}"></table:page>
+				<div style="clear: both;"></div>
+			</div>
+		</div>
+	</div>
+	<div id="changewidth"></div>
+</div>
+<script type="text/html" id="barDemo">
+	<a class="layui-btn layui-btn-xs" lay-event="more" style="width: 75px">请选择<i class="layui-icon layui-icon-down"></i></a>
+</script>
+<script>
+	layui.use(function() { //亦可加载特定模块:layui.use(['layer', 'laydate', function(){
+		//得到各种内置组件
+		var table = layui.table //表格
+				,dropdown = layui.dropdown //下拉菜单
+		table.on('tool(test)', function (obj) { //注:tool 是工具条事件名,test 是 table 原始容器的属性 lay-filter="对应的值"
+			var data = obj.data //获得当前行数据
+					, layEvent = obj.event; //获得 lay-event 对应的值
+			if (layEvent === 'more' && (data.falg == 1 || data.approvalSignatureStatus == 5 || data.reportSignatureStatus == 5)) {
+				//下拉菜单
+				dropdown.render({
+					elem: this //触发事件的 DOM 对象
+					, show: true //外部事件触发即显示
+					, data: [{
+						title: ''
+						, id: 'must' //此项为必填项
+						// , href: '#'
+						// , target: '_blank' 默认_self
+						, templet: show(data)
+
+					}]
+					, align: 'center' //右对齐弹出(v2.6.8 新增)
+					, style: 'box-shadow: 5px 5px 10px rgb(0 0 0 / 12%);' //设置额外样式
+				})
+			}else {
+				//下拉菜单
+				dropdown.render({
+					elem: this
+					, show: true
+					, data: [{
+						title: '当前已无可进行操作!'
+						, id: 'no'
+					}]
+					, align: 'center' //右对齐弹出(v2.6.8 新增)
+					, style: 'box-shadow: 5px 5px 10px rgb(0 0 0 / 12%);' //设置额外样式
+				})
+			}
+		});
+	})
+</script>
+<script>
+
+    layui.use('table', function(){
+        layui.table.render({
+            limit:${ page.pageSize }
+            ,elem: '#contentTable1'
+            ,page: false
+            ,cols: [[
+                // {checkbox: true, fixed: true},
+                {field:'index',align:'center',  title: '序号',width:40}
+				,{field: 'projId',align:'center', title: '项目编号/项目定义号',width:160}
+				,{field:'projName',align:'center', title: '项目名称', minWidth:250,templet:function(d){
+						var xml="";
+						xml+="<a class=\"attention-info pid\" title=\"" + d.projName + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectView/view?id=" + d.id +"','95%', '95%')\">"
+						xml+=d.projName
+						xml+="</a>";
+						return xml;
+					}}
+				,{field:'projectReportNumber',align:'center', title: '报告号',minWidth:180,templet:function(d){
+						if(""!= d.projectReportNumber){
+							return d.projectReportNumber;
+						}else{
+							return "<span title='暂无报告'  style='color: #009688'>暂无报告</span>";
+						}
+					}}
+
+				,{field: 'projMaster', align:'center', title: '责任人',width:100,templet: function(d){
+						return "<font style = 'font-size:14px;'>"+d.projMaster+"</font>";
+					}}
+
+                ,{field:'createName',align:'center', title: '登记人',  width:80}
+                ,{field: 'createDate', align:'center', title: '创建日期/打包时间',width:140,templet: function(d){
+					var date=d.createDate;
+					return "<font style = 'font-size:14px;font-weight:500;'>"+layui.util.toDateString(date,'yyyy-MM-dd')+"</font>";
+				}}
+				,{field: 'submitMoneyStr', align:'center', title: '项目等级',width:100,templet: function(d){
+						return "<font style = 'font-size:14px;'>"+d.submitMoneyStr+"</font>";
+				}}
+                ,{align:'center', title: '审定单申请',  width:90,templet:function(d){
+                        var st = getAuditState(d.approvalSignatureStatus);
+                        if(st.action)
+                            var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/electronicSealCZ/getReportedProcess?processInstanceId=" + d.approvalSignatureProcessInstanceId + "','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:130,templet:function(d){
+						var st = getAuditState(d.reportSignatureStatus);
+						if(st.action)
+							var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/electronicSealCZ/getReportedProcess?processInstanceId=" + d.reportSignatureProcessInstanceId + "','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>";
+
+						if(d.prsiId != null && d.prsiId != undefined && d.prsiId != ""){
+							xml+="<span  style='margin-left: 5px;' class=\"layui-badge layui-bg-orange\">已填</span>";
+						}
+						return xml;
+					}}
+				,{align: 'center',title: '操作',width: 170,templet:'#barDemo'}
+
+            ]]
+            ,data: [
+                <c:if test="${ not empty page.list}">
+                <c:forEach items="${page.list}" var="projectRecords" varStatus="index">
+                <c:if test="${index.index != 0}">,</c:if>
+                {
+					"index":"${index.index+1}"
+					,"id":"${projectRecords.id}"
+					,"projId":"${projectRecords.projectId}"
+					,"projectReportNumber":"${projectRecords.projectReportNumber}"
+					,"projName":"<c:out value="${projectRecords.projectName}" escapeXml="true"/>"
+					,"projMaster":"${projectRecords.leaderNameStr}"
+					<%--,"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>"--%>
+					,"contractId":"${projectRecords.workContractInfo.id}"
+					,"createName":"${projectRecords.createBy.name}"
+					,"createDate":"<fmt:formatDate value="${projectRecords.createDate}" pattern="yyyy-MM-dd"/>"
+					,"procId":"${projectRecords.processInstanceId}"
+					,"pidId":"${projectRecords.prdId}"
+
+					,"submitMoney":"${projectRecords.submitMoney}"
+					,"signatureContractId":"${projectRecords.signatureContractId}"
+					,"reportSignatureContractId":"${projectRecords.reportSignatureContractId}"
+					,"approvalSignatureStatus":"${projectRecords.approvalSignatureStatus}"
+					,"approvalSignatureProcessInstanceId":"${projectRecords.approvalSignatureProcessInstanceId}"
+					,"reportSignatureStatus":"${projectRecords.reportSignatureStatus}"
+					,"reportSignatureProcessInstanceId":"${projectRecords.reportSignatureProcessInstanceId}"
+					,"prsiId":"${projectRecords.prsiId}"
+					,"signatureDownloadUrl":"${projectRecords.signatureDownloadUrl}"
+					,"reportSignatureUrlFlag":"${projectRecords.reportSignatureUrlFlag}"
+					,"reportSignatureUrl":"${projectRecords.reportSignatureUrl}"
+					,"signatureUrl":"${projectRecords.signatureUrl}"
+					,"approvalSignatureUrlFlag":"${projectRecords.approvalSignatureUrlFlag}"
+
+					,"falg":
+							<c:choose>
+							<c:when test="${fns:getUser().id == projectRecords.leaderIds || fns:getUser().id eq projectRecords.createBy.id}">
+							"1"
+					</c:when>
+					<c:otherwise>
+					"0"
+					</c:otherwise>
+					</c:choose>
+					,"submitMoneyStr":
+							<c:choose>
+							<c:when test="${'2'==projectRecords.submitMoney}">
+							"A级"
+					</c:when>
+					<c:otherwise>
+					"B级"
+					</c:otherwise>
+					</c:choose>
+					<shiro:hasPermission name="ruralProject:electronicSealCZ:approvalForm">,"electronicSeal":<c:choose><c:when test="${fns:getUser().id == projectRecords.leaderIds || fns:getUser().id eq projectRecords.createBy.id}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose></shiro:hasPermission>
+				}
+                </c:forEach>
+                </c:if>
+            ]
+            // ,even: true
+            // ,height: 315
+        });
+    })
+
+    resizeListTable();
+    $("a").on("click",addLinkVisied);
+</script>
+<script>
+    resizeListWindow2();
+    $(window).resize(function(){
+        resizeListWindow2();
+    });
+</script>
+</body>
+</html>

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1339 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsApprovalCZForm.jsp


+ 617 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsApprovalCZModify.jsp

@@ -0,0 +1,617 @@
+<%@ 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" src="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.js"></script>
+    <script type="text/javascript" src="${ctxStatic}/iCheck/icheck.min.js"></script>
+    <script type="text/javascript" src="${ctxStatic}/layui/layuidown.js"></script>
+    <script src="${ctxStatic}/common/html/js/script.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+
+    <script type="text/javascript">
+        var validateForm;
+        function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+                var length = $("#file_attachment").find("tr").length ;
+                if(length == 0){
+                    top.layer.msg("请上传审定单签章附件", {icon: 0});
+                    return;
+                }
+                if(obj == 1) {
+                    $("#flag").val("yes");
+                }else {
+                    if(obj == 2){
+                        $("#flag").val("no1");
+                    }else {
+                        $("#flag").val("no2");
+                    }
+                }
+                $("#inputForm").submit();
+                return true;
+            }
+
+            return false;
+        }
+        $(document).ready(function() {
+
+            var tt = $("#contractNum").val();
+            if (tt == null || tt === "") {
+                $("#divv").hide();
+                $("#divv2").show();
+                $("#divv3").hide();
+                setTimeout(function () {
+                    var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+                    $("#clientName").val(tt);
+                },100);
+            }else{
+                $("#divv2").hide();
+            }
+
+            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);
+                    }
+                }
+            });
+
+            var contractNum = $("#contractNum").val();
+            if (contractNum == null || contractNum === "") {
+                $("#div1").hide();
+                $("#div3").hide();
+                setTimeout(function () {
+                    var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+                    $("#clientName").val(tt);
+                },100);
+            }
+
+            var contractInformation='${projectRecords.workContractInfo.contractInformation}'
+            if(contractInformation == "1"){
+                $("#c2").show();
+                $("#c1").hide();
+            }else{
+                $("#c2").hide();
+                $("#c1").show();
+            }
+
+            $("#attachment_btn").click(function () {
+                $("#attachment_file").click();
+            });
+        });
+
+        function insertTitle(tValue){
+            var files = $("#attachment_file")[0].files;
+            var length = $("#file_attachment").find("tr").length ;
+            if(length>0){
+                top.layer.msg("已上传审定单,审定单文件有且只能存在一条", {icon: 0});
+                return;
+            }
+            if(files.length>1){
+                top.layer.msg("只能够上传一个审定单签章文件", {icon: 0});
+                return;
+            }
+            for(var i = 0;i<files.length;i++) {
+                var file = files[i];
+                var attachTypes = "doc,docx,pdf";
+                var suffixResult = 0;
+                var fileName = file.name.lastIndexOf(".");//获取到文件名开始到最后一个“.”的长度。
+                var fileNameLength = file.name.length;//获取到文件名长度
+                var suffix = file.name.substring(fileName + 1, fileNameLength);//截取后缀名
+                suffix = suffix.toLowerCase();//后缀名转换小写
+                attachTypes = attachTypes.toLowerCase();
+                var attachTypeList = attachTypes.split(",");
+                for (var x in attachTypeList) {
+                    if(attachTypeList[x] == suffix){
+                        suffixResult = 1;
+                        break;
+                    }
+                }
+                if(suffixResult == 0 ){
+                    top.layer.msg("上传附件只能为:"+attachTypes+" 类型文件", {icon: 0});
+                    return false;
+                }
+
+                var attachmentId = $("#id").val();
+                var attachmentFlag = "194";
+                /*console.log(file);*/
+                var timestamp=new Date().getTime();
+
+                var storeAs = "selectronicSealApprovalCZ";
+                var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+                var divId = "_attachment";
+                $("#addFile"+divId).show();
+                multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,0);}
+        }
+
+        function addFile() {
+            $("#attachment_file").click();
+        }
+
+        function addRow(list, idx, tpl, row){
+            // var idx1 = $("#workClientLinkmanList tr").length;
+            bornTemplete(list, idx, tpl, row, idx);
+        }
+
+        function bornTemplete(list, idx, tpl, row, idx1){
+            $(list).append(Mustache.render(tpl, {
+                idx: idx, delBtn: true, row: row,
+                order:idx1 + 1
+            }));
+            $(list+idx).find("select").each(function(){
+                $(this).val($(this).attr("data-value"));
+            });
+            $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
+                var ss = $(this).attr("data-value").split(',');
+                for (var i=0; i<ss.length; i++){
+                    if($(this).val() == ss[i]){
+                        $(this).attr("checked","checked");
+                    }
+                }
+            });
+        }
+    </script>
+</head>
+<body >
+<div class="single-form">
+    <div class="container">
+        <form:form id="inputForm" modelAttribute="projectRecords" enctype="multipart/form-data" action="${ctx}/ruralProject/electronicSealCZ/approvalSaveAudit" method="post" class="form-horizontal layui-form">
+            <form:hidden path="id"/>
+            <form:hidden path="home"/>
+            <form:hidden path="act.taskId"/>
+            <form:hidden path="act.taskName"/>
+            <form:hidden id="taskDefKey" path="act.taskDefKey"/>
+            <form:hidden path="act.procInsId"/>
+            <form:hidden path="act.procDefId"/>
+            <form:hidden path="processInstanceId"/>
+            <form:hidden id="flag" path="act.flag"/>
+            <input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">
+            <c:set var="status" value="${projectRecords.act.status}" />
+
+            <div class="form-group layui-row first">
+                <div class="form-group-label"><h2>项目合同信息</h2></div>
+                <div id="div1">
+                    <div class="layui-item layui-col-sm12 lw6">
+                        <label class="layui-form-label">合同编号:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false" id="contractNum"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.contractNum}"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">合同名称:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.name}"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6" id="c1">
+                        <label class="layui-form-label double-line">合同金额(元):</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="<fmt:formatNumber value="${projectRecords.workContractInfo.contractPrice}" pattern="#,##0.00#"/>"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6" id="c2" style="display: none">
+                        <label class="layui-form-label">费率描述:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" id="otherDetails"  class="form-control layui-input" value="${projectRecords.workContractInfo.otherDetails}"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">委托方:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false" id="clientName" readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.client.name}"/>
+                        </div>
+                    </div>
+                </div>
+                <div id="divv2">
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">无合同</label>
+                    </div>
+                </div>
+                <div id="div3">
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">合同类别:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" style="background-color: #f1f1f1" class="form-control layui-input" value="${fns:getMainDictLabel(projectRecords.workContractInfo.contractTypeDoc, 'contract_info_type', '')}"/>
+                                <%--							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.constructionProjectTypeStr}"/>--%>
+                        </div>
+                    </div>
+                </div>
+            </div>
+
+
+            <div class="form-group layui-row first">
+                <div class="form-group-label"><h2>项目基础信息</h2></div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">报告号:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectReportNumber}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目名称:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目编号:</label>
+                    <div class="layui-input-block">
+                        <div class="input-group">
+                            <form:input path="projectId" htmlEscape="false"  readonly="true" class="form-control layui-input" cssStyle="background-color: #f1f1f1"/>
+                            <span class="input-group-btn">
+                                <label class="form-status"><c:choose><c:when test="${not empty projectRecords.projectStatus}">${fns:getDictLabel(projectRecords.projectStatus, 'rural_project_audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                             </span>
+                        </div>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目所在地:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.province}-${projectRecords.city}-${projectRecords.county}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">投资性质:</label>
+                    <div class="layui-input-block">
+                        <c:if test="${projectRecords.projectProperties==null}">
+                            <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input"/>
+                        </c:if>
+                        <c:forEach  items="${fns:getMainDictList('project_properties')}" var="v">
+                            <c:if test="${v.value==projectRecords.projectProperties}">
+                                <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${v.label}"/>
+                            </c:if>
+                        </c:forEach>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">建设地点:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value="${projectRecords.projectSite}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">创建人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.createBy.name}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目责任人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.leaderNameStr}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">所属部门:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" id="officeName" class="form-control layui-input" value="${projectRecords.officeName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目负责人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.projectMasterName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">工程类型:</label>
+                    <div class="layui-input-block">
+                        <form:select path="engineeringType" disabled="true" style="background-color: #f1f1f1"  class="form-control simple-select">
+                            <form:options items="${engineeringInfo}" itemLabel="engineeringName" itemValue="id" htmlEscape="false"/>
+                        </form:select>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目等级:</label>
+                    <div class="layui-input-block">
+                        <c:forEach items="${fns:getMainDictListOnProjectAdvent('attachment_project_grade')}" var="v">
+                            <input type="radio" disabled name="submitMoney" id="submitMoney" value="${v.value}" title="${v.label}" <c:if test="${projectRecords.submitMoney==v.value}">checked</c:if>>
+                        </c:forEach>
+                        <p style="color: red;font-size: 12px;">500万及500万以上为A级,500万以下为B级</p>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line">送审规模(万元):</label>
+                    <div class="layui-input-block">
+                        <form:input path="submitScale" readonly="true" style="background-color: #f1f1f1" id="submitScale" maxlength="12" htmlEscape="false" placeholder="请输入送审规模" class="form-control layui-input number"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line">工作开始日期:</label>
+                    <div class="layui-input-block">
+                        <input class="laydate-icondate form-control layui-input layer-date ash"  style="background-color: #f1f1f1" readonly="true" id="startDate" name="startDate" value="<fmt:formatDate value="${projectRecords.startDate}" pattern="yyyy-MM-dd"/>">
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line">工作结束日期:</label>
+                    <div class="layui-input-block">
+                        <input class="laydate-icondate form-control layui-input layer-date "  style="background-color: #f1f1f1" readonly="true" id="endingDate" name="endingDate" value="<fmt:formatDate value="${projectRecords.endingDate}" pattern="yyyy-MM-dd"/>">
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">创建日期:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${projectRecords.createDate}" pattern="yyyy-MM-dd"/>"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label">项目类别:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" readonly="true"  style="background-color: #f1f1f1" class="form-control layui-input" value="${projectRecords.attachmentProjectSort}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6 with-textarea">
+                    <label class="layui-form-label">工程概况:</label>
+                    <div class="layui-input-block">
+                        <textarea htmlEscape="false" rows="4" readonly="true"  style="background-color: #f1f1f1" maxlength="1000" class="form-control" >${projectRecords.projectDesc}</textarea>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6 with-textarea">
+                    <label class="layui-form-label">备注:</label>
+                    <div class="layui-input-block">
+                        <textarea htmlEscape="false" rows="4" readonly="true" maxlength="1000"  style="background-color: #f1f1f1" class="form-control" >${projectRecords.remarks}</textarea>
+                    </div>
+                </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="contentTable" class="table table-bordered table-condensed no-bottom-margin details">
+                        <thead>
+                        <tr>
+                            <th class="hide"></th>
+                            <th width="25%">委托方</th>
+                            <th width="25%">联系人姓名</th>
+                            <th width="25%">联系方式1</th>
+                            <th width="25%">联系方式2</th>
+                        </tr>
+                        </thead>
+                        <tbody id="workClientLinkmanList">
+                        <c:forEach items="${projectRecords.workClientLinkmanList}" var="info" varStatus="index">
+                            <tr>
+                                <td >
+                                        ${info.clientId.name}
+                                </td>
+                                <td>
+                                        ${info.name}
+                                </td>
+                                <td>
+                                        ${info.linkPhone}
+                                </td>
+                                <td>
+                                        ${info.linkMobile}
+                                </td>
+                            </tr>
+                        </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="contentTable1" class="table table-bordered table-condensed no-bottom-margin details">
+                        <thead>
+                        <tr>
+                            <th class="hide"></th>
+                            <th width="25%">施工方单位名称</th>
+                            <th width="25%">联系人姓名</th>
+                            <th width="25%">联系方式1</th>
+                            <th width="25%">联系方式2</th>
+                        </tr>
+                        </thead>
+                        <tbody id="workConstructionLinkmanList">
+                        <c:forEach items="${projectRecords.workConstructionLinkmanList}" var="info" varStatus="index">
+                            <tr>
+                                <td >
+                                        ${info.clientId.name}
+                                </td>
+                                <td>
+                                        ${info.name}
+                                </td>
+                                <td>
+                                        ${info.linkPhone}
+                                </td>
+                                <td>
+                                        ${info.linkMobile}
+                                </td>
+                            </tr>
+                        </c:forEach>
+                        </tbody>
+                    </table>
+                </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="listAttachment" class="table table-bordered table-condensed details">
+                        <thead>
+                        <tr>
+                                <%-- <th>序号</th>--%>
+                            <th>文件预览</th>
+                            <th>上传人</th>
+                            <th>上传时间</th>
+                            <th width="180px">操作</th>
+                        </tr>
+                        </thead>
+                        <tbody id="file_attachment">
+                        <c:forEach items="${projectRecords.workAttachments}" var = "workClientAttachment" varStatus="status">
+                            <tr>
+                                    <%-- <td>${status.index + 1}</td>--%>
+                                <c:choose>
+                                    <c:when test="${projectRecords.uploadMode == 2}">
+                                        <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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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.temporaryUrl}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+                                                    </c:when>
+                                                    <c:otherwise>
+                                                        <c:choose>
+                                                            <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                                <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                            </c:when>
+                                                            <c:otherwise>
+                                                                <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                            </c:otherwise>
+                                                        </c:choose>
+                                                    </c:otherwise>
+                                                </c:choose>
+                                            </c:otherwise>
+                                        </c:choose>
+                                    </c:when>
+                                    <c:otherwise>
+                                        <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>
+                                                        <c:choose>
+                                                            <c:when test="${workReimbursement.uploadMode == 2}">
+                                                                <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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+                                                                            </c:when>
+                                                                            <c:otherwise>
+                                                                                <c:choose>
+                                                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:when>
+                                                                                    <c:otherwise>
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:otherwise>
+                                                                                </c:choose>
+                                                                            </c:otherwise>
+                                                                        </c:choose>
+                                                                    </c:otherwise>
+                                                                </c:choose>
+                                                            </c:when>
+                                                            <c:otherwise>
+                                                                <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 href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+                                                                            </c:when>
+                                                                            <c:otherwise>
+                                                                                <c:choose>
+                                                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:when>
+                                                                                    <c:otherwise>
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:otherwise>
+                                                                                </c:choose>
+                                                                            </c:otherwise>
+                                                                        </c:choose>
+                                                                    </c:otherwise>
+                                                                </c:choose>
+                                                            </c:otherwise>
+                                                        </c:choose>
+                                                    </c:otherwise>
+                                                </c:choose>
+                                            </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('${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_attachment','_attachment')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>--%>
+                                            <%--													</c:if>--%>
+                                        <a href="javascript:void(0)" onclick="deleteFileFromAliyun(this,'${ctx}/sys/workattachment/deleteFileFromAliyun?url=${workClientAttachment.url}&id=${workClientAttachment.id}&type=2','addFile_attachment','_attachment')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>
+                                    </div>
+                                </td>
+                            </tr>
+                        </c:forEach>
+                        </tbody>
+                    </table>
+                </div>
+            </div>
+
+        </form:form>
+        <%--<iframe id="iframe" src="${ctx}/auditTemplate/auditTemplate/iframeView?identification=${identification}" name="listresult" frameborder="0" align="left" width="100%" height="300" scrolling="value"></iframe>--%>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>${projectNotifyType}审批流程</h2></div>
+            <div class="layui-item layui-col-xs12 form-table-container" >
+                <act:flowChart procInsId="${processInstanceId}"/>
+                <act:histoicFlow procInsId="${processInstanceId}"/>
+            </div>
+        </div>
+    </div>
+</div>
+</body>
+</html>

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1249 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsApprovalCZView.jsp


+ 572 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZAudit.jsp

@@ -0,0 +1,572 @@
+<%@ 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" src="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.js"></script>
+	<script type="text/javascript" src="${ctxStatic}/iCheck/icheck.min.js"></script>
+	<script type="text/javascript" src="${ctxStatic}/layui/layuidown.js"></script>
+	<script src="${ctxStatic}/common/html/js/script.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+
+	<script type="text/javascript">
+		var validateForm;
+		function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+				var ss= document.getElementById("iframe").contentWindow.document.getElementById("opinion").value
+				$("#opinion").val(ss);
+                if(obj == 1) {
+                    $("#flag").val("yes");
+                }else {
+                    if(obj == 2){
+                        $("#flag").val("no1");
+					}else {
+                        $("#flag").val("no2");
+					}
+                }
+                $("#inputForm").submit();
+                return true;
+            }
+
+		  return false;
+		}
+		$(document).ready(function() {
+
+			var tt = $("#contractNum").val();
+			if (tt == null || tt === "") {
+				$("#divv").hide();
+				$("#divv2").show();
+				$("#divv3").hide();
+				setTimeout(function () {
+					var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+					$("#clientName").val(tt);
+				},100);
+			}else{
+				$("#divv2").hide();
+			}
+
+			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);
+					}
+				}
+			});
+
+			var contractNum = $("#contractNum").val();
+			if (contractNum == null || contractNum === "") {
+				$("#div1").hide();
+				$("#div3").hide();
+				setTimeout(function () {
+					var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+					$("#clientName").val(tt);
+				},100);
+			}
+
+			var contractInformation='${projectRecords.workContractInfo.contractInformation}'
+			if(contractInformation == "1"){
+				$("#c2").show();
+				$("#c1").hide();
+			}else{
+				$("#c2").hide();
+				$("#c1").show();
+			}
+		});
+
+        function insertTitle(tValue){
+            var files = $("#attachment_file")[0].files;
+            for(var i = 0;i<files.length;i++) {
+            	var file = files[i];
+            var attachmentId = $("#id").val();
+            var attachmentFlag = "195";
+            console.log(file);
+            var timestamp=new Date().getTime();
+
+				var storeAs = "selectronicSealReportCZ";
+            var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+            var divId = "_attachment";
+            $("#addFile"+divId).show();
+            multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,0);}
+        }
+
+        function addFile() {
+            $("#attachment_file").click();
+        }
+
+        function addRow(list, idx, tpl, row){
+            // var idx1 = $("#workClientLinkmanList tr").length;
+            bornTemplete(list, idx, tpl, row, idx);
+        }
+
+        function bornTemplete(list, idx, tpl, row, idx1){
+            $(list).append(Mustache.render(tpl, {
+                idx: idx, delBtn: true, row: row,
+                order:idx1 + 1
+            }));
+            $(list+idx).find("select").each(function(){
+                $(this).val($(this).attr("data-value"));
+            });
+            $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
+                var ss = $(this).attr("data-value").split(',');
+                for (var i=0; i<ss.length; i++){
+                    if($(this).val() == ss[i]){
+                        $(this).attr("checked","checked");
+                    }
+                }
+            });
+        }
+	</script>
+</head>
+<body >
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="projectRecords" enctype="multipart/form-data" action="${ctx}/ruralProject/electronicSealCZ/reportSignatureSaveAudit" method="post" class="form-horizontal layui-form">
+		<form:hidden path="id"/>
+		<form:hidden path="home"/>
+		<form:hidden path="act.taskId"/>
+		<form:hidden path="act.taskName"/>
+		<form:hidden id="taskDefKey" path="act.taskDefKey"/>
+		<form:hidden path="act.procInsId"/>
+		<form:hidden path="act.procDefId"/>
+		<form:hidden path="processInstanceId"/>
+		<form:hidden id="flag" path="act.flag"/>
+		<input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">
+		<c:set var="status" value="${projectRecords.act.status}" />
+
+			<div class="form-group layui-row first">
+				<div class="form-group-label"><h2>项目合同信息</h2></div>
+				<div id="div1">
+					<div class="layui-item layui-col-sm12 lw6">
+						<label class="layui-form-label">合同编号:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false" id="contractNum"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.contractNum}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">合同名称:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.name}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6" id="c1">
+						<label class="layui-form-label double-line">合同金额(元):</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="<fmt:formatNumber value="${projectRecords.workContractInfo.contractPrice}" pattern="#,##0.00#"/>"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6" id="c2" style="display: none">
+						<label class="layui-form-label">费率描述:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" id="otherDetails"  class="form-control layui-input" value="${projectRecords.workContractInfo.otherDetails}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">委托方:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false" id="clientName" readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.client.name}"/>
+						</div>
+					</div>
+				</div>
+				<div id="divv2">
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">无合同</label>
+					</div>
+				</div>
+				<div id="div3">
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">合同类别:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" style="background-color: #f1f1f1" class="form-control layui-input" value="${fns:getMainDictLabel(projectRecords.workContractInfo.contractTypeDoc, 'contract_info_type', '')}"/>
+<%--							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.constructionProjectTypeStr}"/>--%>
+						</div>
+					</div>
+				</div>
+			</div>
+
+
+			<div class="form-group layui-row first">
+				<div class="form-group-label"><h2>项目基础信息</h2></div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">报告号:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectReportNumber}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目名称:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目编号:</label>
+					<div class="layui-input-block">
+						<div class="input-group">
+							<form:input path="projectId" htmlEscape="false"  readonly="true" class="form-control layui-input" cssStyle="background-color: #f1f1f1"/>
+							<span class="input-group-btn">
+                                <label class="form-status"><c:choose><c:when test="${not empty projectRecords.projectStatus}">${fns:getDictLabel(projectRecords.projectStatus, 'rural_project_audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                             </span>
+						</div>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目所在地:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.province}-${projectRecords.city}-${projectRecords.county}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">投资性质:</label>
+					<div class="layui-input-block">
+						<c:if test="${projectRecords.projectProperties==null}">
+							<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input"/>
+						</c:if>
+						<c:forEach  items="${fns:getMainDictList('project_properties')}" var="v">
+							<c:if test="${v.value==projectRecords.projectProperties}">
+								<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${v.label}"/>
+							</c:if>
+						</c:forEach>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">建设地点:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value="${projectRecords.projectSite}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">创建人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.createBy.name}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目责任人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.leaderNameStr}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">所属部门:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" id="officeName" class="form-control layui-input" value="${projectRecords.officeName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目负责人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.projectMasterName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">工程类型:</label>
+					<div class="layui-input-block">
+						<form:select path="engineeringType" disabled="true" style="background-color: #f1f1f1"  class="form-control simple-select">
+							<form:options items="${engineeringInfo}" itemLabel="engineeringName" itemValue="id" htmlEscape="false"/>
+						</form:select>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目等级:</label>
+					<div class="layui-input-block">
+						<c:forEach items="${fns:getMainDictListOnProjectAdvent('attachment_project_grade')}" var="v">
+							<input type="radio" disabled name="submitMoney" id="submitMoney" value="${v.value}" title="${v.label}" <c:if test="${projectRecords.submitMoney==v.value}">checked</c:if>>
+						</c:forEach>
+						<p style="color: red;font-size: 12px;">500万及500万以上为A级,500万以下为B级</p>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">送审规模(万元):</label>
+					<div class="layui-input-block">
+						<form:input path="submitScale" readonly="true" style="background-color: #f1f1f1" id="submitScale" maxlength="12" htmlEscape="false" placeholder="请输入送审规模" class="form-control layui-input number"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">工作开始日期:</label>
+					<div class="layui-input-block">
+						<input class="laydate-icondate form-control layui-input layer-date ash"  style="background-color: #f1f1f1" readonly="true" id="startDate" name="startDate" value="<fmt:formatDate value="${projectRecords.startDate}" pattern="yyyy-MM-dd"/>">
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">工作结束日期:</label>
+					<div class="layui-input-block">
+						<input class="laydate-icondate form-control layui-input layer-date "  style="background-color: #f1f1f1" readonly="true" id="endingDate" name="endingDate" value="<fmt:formatDate value="${projectRecords.endingDate}" pattern="yyyy-MM-dd"/>">
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">创建日期:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${projectRecords.createDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw7">
+					<label class="layui-form-label">项目类别:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" readonly="true"  style="background-color: #f1f1f1" class="form-control layui-input" value="${projectRecords.attachmentProjectSort}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6 with-textarea">
+					<label class="layui-form-label">工程概况:</label>
+					<div class="layui-input-block">
+						<textarea htmlEscape="false" rows="4" readonly="true"  style="background-color: #f1f1f1" maxlength="1000" class="form-control" >${projectRecords.projectDesc}</textarea>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6 with-textarea">
+					<label class="layui-form-label">备注:</label>
+					<div class="layui-input-block">
+						<textarea htmlEscape="false" rows="4" readonly="true" maxlength="1000"  style="background-color: #f1f1f1" class="form-control" >${projectRecords.remarks}</textarea>
+					</div>
+				</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="contentTable" class="table table-bordered table-condensed no-bottom-margin details">
+						<thead>
+						<tr>
+							<th class="hide"></th>
+							<th width="25%">委托方</th>
+							<th width="25%">联系人姓名</th>
+							<th width="25%">联系方式1</th>
+							<th width="25%">联系方式2</th>
+						</tr>
+						</thead>
+						<tbody id="workClientLinkmanList">
+						<c:forEach items="${projectRecords.workClientLinkmanList}" var="info" varStatus="index">
+							<tr>
+								<td >
+										${info.clientId.name}
+								</td>
+								<td>
+										${info.name}
+								</td>
+								<td>
+										${info.linkPhone}
+								</td>
+								<td>
+										${info.linkMobile}
+								</td>
+							</tr>
+						</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="contentTable1" class="table table-bordered table-condensed no-bottom-margin details">
+						<thead>
+						<tr>
+							<th class="hide"></th>
+							<th width="25%">施工方单位名称</th>
+							<th width="25%">联系人姓名</th>
+							<th width="25%">联系方式1</th>
+							<th width="25%">联系方式2</th>
+						</tr>
+						</thead>
+						<tbody id="workConstructionLinkmanList">
+						<c:forEach items="${projectRecords.workConstructionLinkmanList}" var="info" varStatus="index">
+							<tr>
+								<td >
+										${info.clientId.name}
+								</td>
+								<td>
+										${info.name}
+								</td>
+								<td>
+										${info.linkPhone}
+								</td>
+								<td>
+										${info.linkMobile}
+								</td>
+							</tr>
+						</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" style="padding:0 16px;">
+					<table id="listAttachment" class="table table-bordered table-condensed details">
+						<thead>
+						<tr>
+								<%-- <th>序号</th>--%>
+							<th>文件预览</th>
+							<th>上传人</th>
+							<th>上传时间</th>
+							<th width="180px">操作</th>
+						</tr>
+						</thead>
+						<tbody id="file_attachment">
+						<c:forEach items="${projectRecords.workAttachments}" var = "workClientAttachment" varStatus="status">
+							<tr>
+									<%-- <td>${status.index + 1}</td>--%>
+								<c:choose>
+									<c:when test="${projectRecords.uploadMode == 2}">
+										<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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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.temporaryUrl}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+													</c:when>
+													<c:otherwise>
+														<c:choose>
+															<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+															</c:when>
+															<c:otherwise>
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</c:otherwise>
+										</c:choose>
+									</c:when>
+									<c:otherwise>
+										<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>
+														<c:choose>
+															<c:when test="${workReimbursement.uploadMode == 2}">
+																<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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+																			</c:when>
+																			<c:otherwise>
+																				<c:choose>
+																					<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+																					</c:when>
+																					<c:otherwise>
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+																					</c:otherwise>
+																				</c:choose>
+																			</c:otherwise>
+																		</c:choose>
+																	</c:otherwise>
+																</c:choose>
+															</c:when>
+															<c:otherwise>
+																<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 href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+																			</c:when>
+																			<c:otherwise>
+																				<c:choose>
+																					<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+																					</c:when>
+																					<c:otherwise>
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+																					</c:otherwise>
+																				</c:choose>
+																			</c:otherwise>
+																		</c:choose>
+																	</c:otherwise>
+																</c:choose>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</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('${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_attachment','_attachment')" 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>
+
+	</form:form>
+		<div class="form-group-label">
+			<div style="float: right"> <a href="javascript:void(0)" style='background-color: #FFB800' onclick="openDialogre('个人模板列表', '${ctx}/auditTemplate/auditTemplate/templateList?identification=${identification}&name=${identificationName}','80%', '70%','','关闭')" class="nav-btn layui-btn layui-btn-sm" ><i class="fa fa-file-excel-o"></i> 审核意见模板列表</a></div>
+			<h2>审批意见</h2>
+		</div>
+		<iframe id="iframe" src="${ctx}/auditTemplate/auditTemplate/iframeView?identification=${identification}" name="listresult" frameborder="0" align="left" width="100%" height="300" scrolling="value"></iframe>
+			<div class="form-group layui-row">
+				<div class="form-group-label"><h2>${projectNotifyType}审批流程</h2></div>
+				<div class="layui-item layui-col-xs12 form-table-container" >
+					<act:flowChart procInsId="${processInstanceId}"/>
+					<act:histoicFlow procInsId="${processInstanceId}"/>
+				</div>
+			</div>
+	</div>
+</div>
+</body>
+</html>

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1290 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZForm.jsp


+ 623 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZModify.jsp

@@ -0,0 +1,623 @@
+<%@ 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" src="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.js"></script>
+    <script type="text/javascript" src="${ctxStatic}/iCheck/icheck.min.js"></script>
+    <script type="text/javascript" src="${ctxStatic}/layui/layuidown.js"></script>
+    <script src="${ctxStatic}/common/html/js/script.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+
+    <script type="text/javascript">
+        var validateForm;
+        function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+
+                var length = $("#file_attachment").find("tr").length ;
+                if(length == 0){
+                    top.layer.msg("请上传报告签章附件", {icon: 0});
+                    return;
+                }
+                //var ss= document.getElementById("iframe").contentWindow.document.getElementById("opinion").value
+                //$("#opinion").val(ss);
+                if(obj == 1) {
+                    $("#flag").val("yes");
+                }else {
+                    if(obj == 2){
+                        $("#flag").val("no1");
+                    }else {
+                        $("#flag").val("no2");
+                    }
+                }
+                $("#inputForm").submit();
+                return true;
+            }
+
+            return false;
+        }
+        $(document).ready(function() {
+
+            var tt = $("#contractNum").val();
+            if (tt == null || tt === "") {
+                $("#divv").hide();
+                $("#divv2").show();
+                $("#divv3").hide();
+                setTimeout(function () {
+                    var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+                    $("#clientName").val(tt);
+                },100);
+            }else{
+                $("#divv2").hide();
+            }
+
+            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);
+                    }
+                }
+            });
+
+            var contractNum = $("#contractNum").val();
+            if (contractNum == null || contractNum === "") {
+                $("#div1").hide();
+                $("#div3").hide();
+                setTimeout(function () {
+                    var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+                    $("#clientName").val(tt);
+                },100);
+            }
+
+            var contractInformation='${projectRecords.workContractInfo.contractInformation}'
+            if(contractInformation == "1"){
+                $("#c2").show();
+                $("#c1").hide();
+            }else{
+                $("#c2").hide();
+                $("#c1").show();
+            }
+
+            $("#attachment_btn").click(function () {
+                $("#attachment_file").click();
+            });
+        });
+
+        function insertTitle(tValue){
+            $("#flagFile").val(false);
+            var files = $("#attachment_file")[0].files;
+            var length = $("#file_attachment").find("tr").length ;
+            if(length>0){
+                top.layer.msg("已上传审定单,审定单文件有且只能存在一条", {icon: 0});
+                return;
+            }
+            if(files.length>1){
+                top.layer.msg("只能够上传一个审定单签章文件", {icon: 0});
+                return;
+            }
+            for(var i = 0;i<files.length;i++) {
+                var file = files[i];
+                var attachTypes = "doc,docx";
+                var suffixResult = 0;
+                var fileName = file.name.lastIndexOf(".");//获取到文件名开始到最后一个“.”的长度。
+                var fileNameLength = file.name.length;//获取到文件名长度
+                var suffix = file.name.substring(fileName + 1, fileNameLength);//截取后缀名
+                suffix = suffix.toLowerCase();//后缀名转换小写
+                attachTypes = attachTypes.toLowerCase();
+                var attachTypeList = attachTypes.split(",");
+                for (var x in attachTypeList) {
+                    if(attachTypeList[x] == suffix){
+                        suffixResult = 1;
+                        break;
+                    }
+                }
+                if(suffixResult == 0 ){
+                    top.layer.msg("上传附件只能为:"+attachTypes+" 类型文件", {icon: 0});
+                    return false;
+                }
+
+                var attachmentId = $("#id").val();
+                var attachmentFlag = "195";
+                /*console.log(file);*/
+                var timestamp=new Date().getTime();
+
+                var storeAs = "selectronicSealReportCZ";
+                var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+                var divId = "_attachment";
+                $("#addFile"+divId).show();
+                multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,0);}
+        }
+
+        function addFile() {
+            $("#attachment_file").click();
+        }
+
+        function addRow(list, idx, tpl, row){
+            // var idx1 = $("#workClientLinkmanList tr").length;
+            bornTemplete(list, idx, tpl, row, idx);
+        }
+
+        function bornTemplete(list, idx, tpl, row, idx1){
+            $(list).append(Mustache.render(tpl, {
+                idx: idx, delBtn: true, row: row,
+                order:idx1 + 1
+            }));
+            $(list+idx).find("select").each(function(){
+                $(this).val($(this).attr("data-value"));
+            });
+            $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
+                var ss = $(this).attr("data-value").split(',');
+                for (var i=0; i<ss.length; i++){
+                    if($(this).val() == ss[i]){
+                        $(this).attr("checked","checked");
+                    }
+                }
+            });
+        }
+    </script>
+</head>
+<body >
+<div class="single-form">
+    <div class="container">
+        <form:form id="inputForm" modelAttribute="projectRecords" enctype="multipart/form-data" action="${ctx}/ruralProject/electronicSealCZ/reportSignatureSaveAudit" method="post" class="form-horizontal layui-form">
+            <form:hidden path="id"/>
+            <form:hidden path="home"/>
+            <form:hidden path="act.taskId"/>
+            <form:hidden path="act.taskName"/>
+            <form:hidden id="taskDefKey" path="act.taskDefKey"/>
+            <form:hidden path="act.procInsId"/>
+            <form:hidden path="act.procDefId"/>
+            <form:hidden path="processInstanceId"/>
+            <form:hidden id="flag" path="act.flag"/>
+            <%--<input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">--%>
+            <c:set var="status" value="${projectRecords.act.status}" />
+
+            <div class="form-group layui-row first">
+                <div class="form-group-label"><h2>项目合同信息</h2></div>
+                <div id="div1">
+                    <div class="layui-item layui-col-sm12 lw6">
+                        <label class="layui-form-label">合同编号:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false" id="contractNum"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.contractNum}"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">合同名称:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.name}"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6" id="c1">
+                        <label class="layui-form-label double-line">合同金额(元):</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="<fmt:formatNumber value="${projectRecords.workContractInfo.contractPrice}" pattern="#,##0.00#"/>"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6" id="c2" style="display: none">
+                        <label class="layui-form-label">费率描述:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" id="otherDetails"  class="form-control layui-input" value="${projectRecords.workContractInfo.otherDetails}"/>
+                        </div>
+                    </div>
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">委托方:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false" id="clientName" readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.client.name}"/>
+                        </div>
+                    </div>
+                </div>
+                <div id="divv2">
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">无合同</label>
+                    </div>
+                </div>
+                <div id="div3">
+                    <div class="layui-item layui-col-sm6 lw6">
+                        <label class="layui-form-label">合同类别:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true" style="background-color: #f1f1f1" class="form-control layui-input" value="${fns:getMainDictLabel(projectRecords.workContractInfo.contractTypeDoc, 'contract_info_type', '')}"/>
+                                <%--							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.constructionProjectTypeStr}"/>--%>
+                        </div>
+                    </div>
+                </div>
+            </div>
+
+
+            <div class="form-group layui-row first">
+                <div class="form-group-label"><h2>项目基础信息</h2></div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">报告号:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectReportNumber}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目名称:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目编号:</label>
+                    <div class="layui-input-block">
+                        <div class="input-group">
+                            <form:input path="projectId" htmlEscape="false"  readonly="true" class="form-control layui-input" cssStyle="background-color: #f1f1f1"/>
+                            <span class="input-group-btn">
+                                <label class="form-status"><c:choose><c:when test="${not empty projectRecords.projectStatus}">${fns:getDictLabel(projectRecords.projectStatus, 'rural_project_audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                             </span>
+                        </div>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目所在地:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.province}-${projectRecords.city}-${projectRecords.county}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">投资性质:</label>
+                    <div class="layui-input-block">
+                        <c:if test="${projectRecords.projectProperties==null}">
+                            <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input"/>
+                        </c:if>
+                        <c:forEach  items="${fns:getMainDictList('project_properties')}" var="v">
+                            <c:if test="${v.value==projectRecords.projectProperties}">
+                                <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${v.label}"/>
+                            </c:if>
+                        </c:forEach>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">建设地点:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value="${projectRecords.projectSite}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">创建人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.createBy.name}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目责任人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.leaderNameStr}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">所属部门:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" id="officeName" class="form-control layui-input" value="${projectRecords.officeName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目负责人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.projectMasterName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">工程类型:</label>
+                    <div class="layui-input-block">
+                        <form:select path="engineeringType" disabled="true" style="background-color: #f1f1f1"  class="form-control simple-select">
+                            <form:options items="${engineeringInfo}" itemLabel="engineeringName" itemValue="id" htmlEscape="false"/>
+                        </form:select>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">项目等级:</label>
+                    <div class="layui-input-block">
+                        <c:forEach items="${fns:getMainDictListOnProjectAdvent('attachment_project_grade')}" var="v">
+                            <input type="radio" disabled name="submitMoney" id="submitMoney" value="${v.value}" title="${v.label}" <c:if test="${projectRecords.submitMoney==v.value}">checked</c:if>>
+                        </c:forEach>
+                        <p style="color: red;font-size: 12px;">500万及500万以上为A级,500万以下为B级</p>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line">送审规模(万元):</label>
+                    <div class="layui-input-block">
+                        <form:input path="submitScale" readonly="true" style="background-color: #f1f1f1" id="submitScale" maxlength="12" htmlEscape="false" placeholder="请输入送审规模" class="form-control layui-input number"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line">工作开始日期:</label>
+                    <div class="layui-input-block">
+                        <input class="laydate-icondate form-control layui-input layer-date ash"  style="background-color: #f1f1f1" readonly="true" id="startDate" name="startDate" value="<fmt:formatDate value="${projectRecords.startDate}" pattern="yyyy-MM-dd"/>">
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line">工作结束日期:</label>
+                    <div class="layui-input-block">
+                        <input class="laydate-icondate form-control layui-input layer-date "  style="background-color: #f1f1f1" readonly="true" id="endingDate" name="endingDate" value="<fmt:formatDate value="${projectRecords.endingDate}" pattern="yyyy-MM-dd"/>">
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">创建日期:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${projectRecords.createDate}" pattern="yyyy-MM-dd"/>"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label">项目类别:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" readonly="true"  style="background-color: #f1f1f1" class="form-control layui-input" value="${projectRecords.attachmentProjectSort}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6 with-textarea">
+                    <label class="layui-form-label">工程概况:</label>
+                    <div class="layui-input-block">
+                        <textarea htmlEscape="false" rows="4" readonly="true"  style="background-color: #f1f1f1" maxlength="1000" class="form-control" >${projectRecords.projectDesc}</textarea>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw6 with-textarea">
+                    <label class="layui-form-label">备注:</label>
+                    <div class="layui-input-block">
+                        <textarea htmlEscape="false" rows="4" readonly="true" maxlength="1000"  style="background-color: #f1f1f1" class="form-control" >${projectRecords.remarks}</textarea>
+                    </div>
+                </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="contentTable" class="table table-bordered table-condensed no-bottom-margin details">
+                        <thead>
+                        <tr>
+                            <th class="hide"></th>
+                            <th width="25%">委托方</th>
+                            <th width="25%">联系人姓名</th>
+                            <th width="25%">联系方式1</th>
+                            <th width="25%">联系方式2</th>
+                        </tr>
+                        </thead>
+                        <tbody id="workClientLinkmanList">
+                        <c:forEach items="${projectRecords.workClientLinkmanList}" var="info" varStatus="index">
+                            <tr>
+                                <td >
+                                        ${info.clientId.name}
+                                </td>
+                                <td>
+                                        ${info.name}
+                                </td>
+                                <td>
+                                        ${info.linkPhone}
+                                </td>
+                                <td>
+                                        ${info.linkMobile}
+                                </td>
+                            </tr>
+                        </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="contentTable1" class="table table-bordered table-condensed no-bottom-margin details">
+                        <thead>
+                        <tr>
+                            <th class="hide"></th>
+                            <th width="25%">施工方单位名称</th>
+                            <th width="25%">联系人姓名</th>
+                            <th width="25%">联系方式1</th>
+                            <th width="25%">联系方式2</th>
+                        </tr>
+                        </thead>
+                        <tbody id="workConstructionLinkmanList">
+                        <c:forEach items="${projectRecords.workConstructionLinkmanList}" var="info" varStatus="index">
+                            <tr>
+                                <td >
+                                        ${info.clientId.name}
+                                </td>
+                                <td>
+                                        ${info.name}
+                                </td>
+                                <td>
+                                        ${info.linkPhone}
+                                </td>
+                                <td>
+                                        ${info.linkMobile}
+                                </td>
+                            </tr>
+                        </c:forEach>
+                        </tbody>
+                    </table>
+                </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="listAttachment" class="table table-bordered table-condensed details">
+                        <thead>
+                        <tr>
+                                <%-- <th>序号</th>--%>
+                            <th>文件预览</th>
+                            <th>上传人</th>
+                            <th>上传时间</th>
+                            <th width="180px">操作</th>
+                        </tr>
+                        </thead>
+                        <tbody id="file_attachment">
+                        <c:forEach items="${projectRecords.workAttachments}" var = "workClientAttachment" varStatus="status">
+                            <tr>
+                                    <%-- <td>${status.index + 1}</td>--%>
+                                <c:choose>
+                                    <c:when test="${projectRecords.uploadMode == 2}">
+                                        <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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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.temporaryUrl}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+                                                    </c:when>
+                                                    <c:otherwise>
+                                                        <c:choose>
+                                                            <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                                <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                            </c:when>
+                                                            <c:otherwise>
+                                                                <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                            </c:otherwise>
+                                                        </c:choose>
+                                                    </c:otherwise>
+                                                </c:choose>
+                                            </c:otherwise>
+                                        </c:choose>
+                                    </c:when>
+                                    <c:otherwise>
+                                        <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>
+                                                        <c:choose>
+                                                            <c:when test="${workReimbursement.uploadMode == 2}">
+                                                                <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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+                                                                            </c:when>
+                                                                            <c:otherwise>
+                                                                                <c:choose>
+                                                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:when>
+                                                                                    <c:otherwise>
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:otherwise>
+                                                                                </c:choose>
+                                                                            </c:otherwise>
+                                                                        </c:choose>
+                                                                    </c:otherwise>
+                                                                </c:choose>
+                                                            </c:when>
+                                                            <c:otherwise>
+                                                                <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 href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+                                                                            </c:when>
+                                                                            <c:otherwise>
+                                                                                <c:choose>
+                                                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:when>
+                                                                                    <c:otherwise>
+                                                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                                                    </c:otherwise>
+                                                                                </c:choose>
+                                                                            </c:otherwise>
+                                                                        </c:choose>
+                                                                    </c:otherwise>
+                                                                </c:choose>
+                                                            </c:otherwise>
+                                                        </c:choose>
+                                                    </c:otherwise>
+                                                </c:choose>
+                                            </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('${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_attachment','_attachment')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>--%>
+                                            <%--													</c:if>--%>
+                                        <a href="javascript:void(0)" onclick="deleteFileFromAliyun(this,'${ctx}/sys/workattachment/deleteFileFromAliyun?url=${workClientAttachment.url}&id=${workClientAttachment.id}&type=2','addFile_attachment','_attachment')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>
+                                    </div>
+                                </td>
+                            </tr>
+                        </c:forEach>
+                        </tbody>
+                    </table>
+                </div>
+            </div>
+
+
+        </form:form>
+        <%--<iframe id="iframe" src="${ctx}/auditTemplate/auditTemplate/iframeView?identification=${identification}" name="listresult" frameborder="0" align="left" width="100%" height="300" scrolling="value"></iframe>--%>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>${projectNotifyType}审批流程</h2></div>
+            <div class="layui-item layui-col-xs12 form-table-container" >
+                <act:flowChart procInsId="${processInstanceId}"/>
+                <act:histoicFlow procInsId="${processInstanceId}"/>
+            </div>
+        </div>
+    </div>
+</div>
+</body>
+</html>

+ 623 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZSzzkAudit.jsp

@@ -0,0 +1,623 @@
+<%@ 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" src="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.js"></script>
+	<script type="text/javascript" src="${ctxStatic}/iCheck/icheck.min.js"></script>
+	<script type="text/javascript" src="${ctxStatic}/layui/layuidown.js"></script>
+	<script src="${ctxStatic}/common/html/js/script.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+
+	<script type="text/javascript">
+		var validateForm;
+		function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+				var ss= document.getElementById("iframe").contentWindow.document.getElementById("opinion").value
+				$("#opinion").val(ss);
+                if(obj == 1) {
+					var length = $("#file_attachment").find("tr").length ;
+					if(length == 0){
+						top.layer.msg("请上传报告签章附件", {icon: 0});
+						return;
+					}
+                    $("#flag").val("yes");
+                }else {
+                    if(obj == 2){
+                        $("#flag").val("no1");
+					}else {
+                        $("#flag").val("no2");
+					}
+                }
+                $("#inputForm").submit();
+                return true;
+            }
+
+		  return false;
+		}
+		$(document).ready(function() {
+
+			var tt = $("#contractNum").val();
+			if (tt == null || tt === "") {
+				$("#divv").hide();
+				$("#divv2").show();
+				$("#divv3").hide();
+				setTimeout(function () {
+					var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+					$("#clientName").val(tt);
+				},100);
+			}else{
+				$("#divv2").hide();
+			}
+
+			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);
+					}
+				}
+			});
+
+			var contractNum = $("#contractNum").val();
+			if (contractNum == null || contractNum === "") {
+				$("#div1").hide();
+				$("#div3").hide();
+				setTimeout(function () {
+					var tt = $("#workClientLinkmanList").find("tr").eq(0).find("td").eq(1).text().trim();
+					$("#clientName").val(tt);
+				},100);
+			}
+
+			var contractInformation='${projectRecords.workContractInfo.contractInformation}'
+			if(contractInformation == "1"){
+				$("#c2").show();
+				$("#c1").hide();
+			}else{
+				$("#c2").hide();
+				$("#c1").show();
+			}
+
+			$("#attachment_btn").click(function () {
+				$("#attachment_file").click();
+			});
+		});
+
+		function insertTitle(tValue){
+			$("#flagFile").val(false);
+			var files = $("#attachment_file")[0].files;
+			var length = $("#file_attachment").find("tr").length ;
+			if(length>1){
+				top.layer.msg("报告文件最多只能存在两条", {icon: 0});
+				return;
+			}
+			if(files.length>1){
+				top.layer.msg("一次只能上传一个报告文件", {icon: 0});
+				return;
+			}
+			for(var i = 0;i<files.length;i++) {
+				var file = files[i];
+				var attachTypes = "doc,docx";
+				var suffixResult = 0;
+				var fileName = file.name.lastIndexOf(".");//获取到文件名开始到最后一个“.”的长度。
+				var fileNameLength = file.name.length;//获取到文件名长度
+				var suffix = file.name.substring(fileName + 1, fileNameLength);//截取后缀名
+				suffix = suffix.toLowerCase();//后缀名转换小写
+				attachTypes = attachTypes.toLowerCase();
+				var attachTypeList = attachTypes.split(",");
+				for (var x in attachTypeList) {
+					if(attachTypeList[x] == suffix){
+						suffixResult = 1;
+						break;
+					}
+				}
+				if(suffixResult == 0 ){
+					top.layer.msg("上传附件只能为:"+attachTypes+" 类型文件", {icon: 0});
+					return false;
+				}
+
+				var attachmentId = $("#id").val();
+				var attachmentFlag = "195";
+				/*console.log(file);*/
+				var timestamp=new Date().getTime();
+
+				var storeAs = "selectronicSealReportCZ";
+				var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+				var divId = "_attachment";
+				$("#addFile"+divId).show();
+				multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,0);}
+		}
+
+        function addFile() {
+            $("#attachment_file").click();
+        }
+
+        function addRow(list, idx, tpl, row){
+            // var idx1 = $("#workClientLinkmanList tr").length;
+            bornTemplete(list, idx, tpl, row, idx);
+        }
+
+        function bornTemplete(list, idx, tpl, row, idx1){
+            $(list).append(Mustache.render(tpl, {
+                idx: idx, delBtn: true, row: row,
+                order:idx1 + 1
+            }));
+            $(list+idx).find("select").each(function(){
+                $(this).val($(this).attr("data-value"));
+            });
+            $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
+                var ss = $(this).attr("data-value").split(',');
+                for (var i=0; i<ss.length; i++){
+                    if($(this).val() == ss[i]){
+                        $(this).attr("checked","checked");
+                    }
+                }
+            });
+        }
+	</script>
+</head>
+<body >
+<div class="single-form">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="projectRecords" enctype="multipart/form-data" action="${ctx}/ruralProject/electronicSealCZ/reportSignatureSaveAudit" method="post" class="form-horizontal layui-form">
+		<form:hidden path="id"/>
+		<form:hidden path="home"/>
+		<form:hidden path="act.taskId"/>
+		<form:hidden path="act.taskName"/>
+		<form:hidden id="taskDefKey" path="act.taskDefKey"/>
+		<form:hidden path="act.procInsId"/>
+		<form:hidden path="act.procDefId"/>
+		<form:hidden path="processInstanceId"/>
+		<form:hidden id="flag" path="act.flag"/>
+		<input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">
+		<c:set var="status" value="${projectRecords.act.status}" />
+
+			<div class="form-group layui-row first">
+				<div class="form-group-label"><h2>项目合同信息</h2></div>
+				<div id="div1">
+					<div class="layui-item layui-col-sm12 lw6">
+						<label class="layui-form-label">合同编号:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false" id="contractNum"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.contractNum}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">合同名称:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.name}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6" id="c1">
+						<label class="layui-form-label double-line">合同金额(元):</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="<fmt:formatNumber value="${projectRecords.workContractInfo.contractPrice}" pattern="#,##0.00#"/>"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6" id="c2" style="display: none">
+						<label class="layui-form-label">费率描述:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" id="otherDetails"  class="form-control layui-input" value="${projectRecords.workContractInfo.otherDetails}"/>
+						</div>
+					</div>
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">委托方:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false" id="clientName" readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.client.name}"/>
+						</div>
+					</div>
+				</div>
+				<div id="divv2">
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">无合同</label>
+					</div>
+				</div>
+				<div id="div3">
+					<div class="layui-item layui-col-sm6 lw6">
+						<label class="layui-form-label">合同类别:</label>
+						<div class="layui-input-block">
+							<input htmlEscape="false"  readonly="true" style="background-color: #f1f1f1" class="form-control layui-input" value="${fns:getMainDictLabel(projectRecords.workContractInfo.contractTypeDoc, 'contract_info_type', '')}"/>
+<%--							<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${projectRecords.workContractInfo.constructionProjectTypeStr}"/>--%>
+						</div>
+					</div>
+				</div>
+			</div>
+
+
+			<div class="form-group layui-row first">
+				<div class="form-group-label"><h2>项目基础信息</h2></div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">报告号:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectReportNumber}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目名称:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${projectRecords.projectName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目编号:</label>
+					<div class="layui-input-block">
+						<div class="input-group">
+							<form:input path="projectId" htmlEscape="false"  readonly="true" class="form-control layui-input" cssStyle="background-color: #f1f1f1"/>
+							<span class="input-group-btn">
+                                <label class="form-status"><c:choose><c:when test="${not empty projectRecords.projectStatus}">${fns:getDictLabel(projectRecords.projectStatus, 'rural_project_audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                             </span>
+						</div>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目所在地:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.province}-${projectRecords.city}-${projectRecords.county}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">投资性质:</label>
+					<div class="layui-input-block">
+						<c:if test="${projectRecords.projectProperties==null}">
+							<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input"/>
+						</c:if>
+						<c:forEach  items="${fns:getMainDictList('project_properties')}" var="v">
+							<c:if test="${v.value==projectRecords.projectProperties}">
+								<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${v.label}"/>
+							</c:if>
+						</c:forEach>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">建设地点:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value="${projectRecords.projectSite}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">创建人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.createBy.name}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目责任人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.leaderNameStr}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">所属部门:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" id="officeName" class="form-control layui-input" value="${projectRecords.officeName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目负责人:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="${projectRecords.projectMasterName}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">工程类型:</label>
+					<div class="layui-input-block">
+						<form:select path="engineeringType" disabled="true" style="background-color: #f1f1f1"  class="form-control simple-select">
+							<form:options items="${engineeringInfo}" itemLabel="engineeringName" itemValue="id" htmlEscape="false"/>
+						</form:select>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">项目等级:</label>
+					<div class="layui-input-block">
+						<c:forEach items="${fns:getMainDictListOnProjectAdvent('attachment_project_grade')}" var="v">
+							<input type="radio" disabled name="submitMoney" id="submitMoney" value="${v.value}" title="${v.label}" <c:if test="${projectRecords.submitMoney==v.value}">checked</c:if>>
+						</c:forEach>
+						<p style="color: red;font-size: 12px;">500万及500万以上为A级,500万以下为B级</p>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">送审规模(万元):</label>
+					<div class="layui-input-block">
+						<form:input path="submitScale" readonly="true" style="background-color: #f1f1f1" id="submitScale" maxlength="12" htmlEscape="false" placeholder="请输入送审规模" class="form-control layui-input number"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">工作开始日期:</label>
+					<div class="layui-input-block">
+						<input class="laydate-icondate form-control layui-input layer-date ash"  style="background-color: #f1f1f1" readonly="true" id="startDate" name="startDate" value="<fmt:formatDate value="${projectRecords.startDate}" pattern="yyyy-MM-dd"/>">
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label double-line">工作结束日期:</label>
+					<div class="layui-input-block">
+						<input class="laydate-icondate form-control layui-input layer-date "  style="background-color: #f1f1f1" readonly="true" id="endingDate" name="endingDate" value="<fmt:formatDate value="${projectRecords.endingDate}" pattern="yyyy-MM-dd"/>">
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">创建日期:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  style="background-color: #f1f1f1" readonly="true" class="form-control layui-input" value="<fmt:formatDate value="${projectRecords.createDate}" pattern="yyyy-MM-dd"/>"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw7">
+					<label class="layui-form-label">项目类别:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false" readonly="true"  style="background-color: #f1f1f1" class="form-control layui-input" value="${projectRecords.attachmentProjectSort}"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6 with-textarea">
+					<label class="layui-form-label">工程概况:</label>
+					<div class="layui-input-block">
+						<textarea htmlEscape="false" rows="4" readonly="true"  style="background-color: #f1f1f1" maxlength="1000" class="form-control" >${projectRecords.projectDesc}</textarea>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6 lw6 with-textarea">
+					<label class="layui-form-label">备注:</label>
+					<div class="layui-input-block">
+						<textarea htmlEscape="false" rows="4" readonly="true" maxlength="1000"  style="background-color: #f1f1f1" class="form-control" >${projectRecords.remarks}</textarea>
+					</div>
+				</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="contentTable" class="table table-bordered table-condensed no-bottom-margin details">
+						<thead>
+						<tr>
+							<th class="hide"></th>
+							<th width="25%">委托方</th>
+							<th width="25%">联系人姓名</th>
+							<th width="25%">联系方式1</th>
+							<th width="25%">联系方式2</th>
+						</tr>
+						</thead>
+						<tbody id="workClientLinkmanList">
+						<c:forEach items="${projectRecords.workClientLinkmanList}" var="info" varStatus="index">
+							<tr>
+								<td >
+										${info.clientId.name}
+								</td>
+								<td>
+										${info.name}
+								</td>
+								<td>
+										${info.linkPhone}
+								</td>
+								<td>
+										${info.linkMobile}
+								</td>
+							</tr>
+						</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="contentTable1" class="table table-bordered table-condensed no-bottom-margin details">
+						<thead>
+						<tr>
+							<th class="hide"></th>
+							<th width="25%">施工方单位名称</th>
+							<th width="25%">联系人姓名</th>
+							<th width="25%">联系方式1</th>
+							<th width="25%">联系方式2</th>
+						</tr>
+						</thead>
+						<tbody id="workConstructionLinkmanList">
+						<c:forEach items="${projectRecords.workConstructionLinkmanList}" var="info" varStatus="index">
+							<tr>
+								<td >
+										${info.clientId.name}
+								</td>
+								<td>
+										${info.name}
+								</td>
+								<td>
+										${info.linkPhone}
+								</td>
+								<td>
+										${info.linkMobile}
+								</td>
+							</tr>
+						</c:forEach>
+						</tbody>
+					</table>
+				</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="listAttachment" class="table table-bordered table-condensed details">
+						<thead>
+						<tr>
+								<%-- <th>序号</th>--%>
+							<th>文件预览</th>
+							<th>上传人</th>
+							<th>上传时间</th>
+							<th width="180px">操作</th>
+						</tr>
+						</thead>
+						<tbody id="file_attachment">
+						<c:forEach items="${projectRecords.workAttachments}" var = "workClientAttachment" varStatus="status">
+							<tr>
+									<%-- <td>${status.index + 1}</td>--%>
+								<c:choose>
+									<c:when test="${projectRecords.uploadMode == 2}">
+										<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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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.temporaryUrl}','90%','90%','1')">${workClientAttachment.attachmentName}</a></td>
+													</c:when>
+													<c:otherwise>
+														<c:choose>
+															<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+															</c:when>
+															<c:otherwise>
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</c:otherwise>
+										</c:choose>
+									</c:when>
+									<c:otherwise>
+										<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>
+														<c:choose>
+															<c:when test="${workReimbursement.uploadMode == 2}">
+																<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.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','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="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+																			</c:when>
+																			<c:otherwise>
+																				<c:choose>
+																					<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+																					</c:when>
+																					<c:otherwise>
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+																					</c:otherwise>
+																				</c:choose>
+																			</c:otherwise>
+																		</c:choose>
+																	</c:otherwise>
+																</c:choose>
+															</c:when>
+															<c:otherwise>
+																<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 href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+																			</c:when>
+																			<c:otherwise>
+																				<c:choose>
+																					<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+																					</c:when>
+																					<c:otherwise>
+																						<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+																					</c:otherwise>
+																				</c:choose>
+																			</c:otherwise>
+																		</c:choose>
+																	</c:otherwise>
+																</c:choose>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</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('${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_attachment','_attachment')" 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>
+
+	</form:form>
+		<div class="form-group-label">
+			<div style="float: right"> <a href="javascript:void(0)" style='background-color: #FFB800' onclick="openDialogre('个人模板列表', '${ctx}/auditTemplate/auditTemplate/templateList?identification=${identification}&name=${identificationName}','80%', '70%','','关闭')" class="nav-btn layui-btn layui-btn-sm" ><i class="fa fa-file-excel-o"></i> 审核意见模板列表</a></div>
+			<h2>审批意见</h2>
+		</div>
+		<iframe id="iframe" src="${ctx}/auditTemplate/auditTemplate/iframeView?identification=${identification}" name="listresult" frameborder="0" align="left" width="100%" height="300" scrolling="value"></iframe>
+			<div class="form-group layui-row">
+				<div class="form-group-label"><h2>${projectNotifyType}审批流程</h2></div>
+				<div class="layui-item layui-col-xs12 form-table-container" >
+					<act:flowChart procInsId="${processInstanceId}"/>
+					<act:histoicFlow procInsId="${processInstanceId}"/>
+				</div>
+			</div>
+	</div>
+</div>
+</body>
+</html>

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1255 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/electronicSealCZ/ruralProjectRecordsReportSignatureCZView.jsp


+ 119 - 1
src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureAudit.jsp

@@ -10,6 +10,10 @@
 	<script src="${ctxStatic}/common/html/js/script.js"></script>
 	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
 	<link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+	<script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+	<script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+	<link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
 
 	<script type="text/javascript">
 		var validateForm;
@@ -52,6 +56,9 @@
 					}
 				}
 			});
+
+			//引用类型处理
+			contentDetailTypeShow();
 		});
         function insertTitle(tValue){
             var files = $("#attachment_file")[0].files;
@@ -132,11 +139,19 @@
 					</div>
 				</div>--%>
 
-				<div class="layui-item layui-col-sm6 lw7">
+				<%--<div class="layui-item layui-col-sm6 lw7">
 					<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" style="background-color: #f1f1f1" value="${businessSignatureInfo.useType}"/>
 					</div>
+				</div>--%>
+
+
+				<div class="layui-item layui-col-sm6 lw7">
+					<label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+					<div class="layui-input-block">
+						<div id="useType" style="pointer-events: none; background-color: #f1f1f1" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+					</div>
 				</div>
 
 				<div class="layui-item layui-col-sm6 lw7">
@@ -338,5 +353,108 @@
 			</div>
 	</div>
 </div>
+<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+	function contentDetailTypeShow() {
+		$.ajax({
+			type:'post',
+			url:'${ctx}/businessSignature/businessSignature/getUseType',
+			data:{
+				"type":2
+			},
+			success:function(data){
+				if(data.success) {
+					var data = data.body.list;
+					var newDataList = data;
+					var showList = [];
+					$.ajax({
+						type:'post',
+						url:'${ctx}/businessSignature/businessSignature/getUseTypeById',
+						data:{
+							"id":$("#id").val()
+						},
+						success:function(dataListById){
+
+							if(dataListById.success) {
+								var showDataList = dataListById.body.list;
+								var lists = [];
+								for (i in newDataList) {
+									for (j in showDataList) {
+										if (newDataList[i].value == showDataList[j].value) {
+											var newData = {
+												"name": newDataList[i].name,
+												"value": newDataList[i].value,
+												"selected": true
+
+											}
+											lists.push(newDataList[i].value);
+											showList.push(newData);
+											data.splice(i,1,newData);
+										}
+									}
+								}
+								if(0 == showDataList.length){
+									var useTypeShow = $("#useTypeShow").val();
+									if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+										for (i in newDataList) {
+											if (newDataList[i].value == useTypeShow) {
+												var newData = {
+													"name": newDataList[i].name,
+													"value": newDataList[i].value,
+													"selected": true
+
+												}
+												lists.push(newDataList[i].value);
+												showList.push(newData);
+												data.splice(i,1,newData);
+											}
+										}
+									}else{
+
+										var newData = {
+											"name": newDataList[0].name,
+											"value": newDataList[0].value,
+											"selected": true
+
+										}
+										lists.push(newDataList[0].value);
+										showList.push(newData);
+										//data.splice(0,1,newData);
+									}
+								}
+
+								$("#useTypeStr").val(lists);
+								xmSelect.render({
+									el: '#useType',
+									language: 'zn',
+									data:data
+								})
+							}
+						}
+					})
+				}
+			}
+		})
+	}
+
+	var useType = xmSelect.render({
+		el: '#useType',
+		language: 'zn',
+		data: [
+		]
+	})
+
+
+	document.getElementById('useType').onblur=function(){
+		var list = [];
+		//获取当前多选选中的值
+		var selectArr = useType.getValue();
+		for (var i in selectArr){
+			list.push(selectArr[i].value);
+		}
+		$("#useTypeStr").val(list);
+		console.log(list);
+	}
+</script>
 </body>
 </html>

+ 126 - 1
src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureForm.jsp

@@ -10,6 +10,10 @@
     <script src="${ctxStatic}/common/html/js/script.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+    <link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
     <style>
         #projectDesc-error{
             left:0;
@@ -47,6 +51,12 @@
         var clientCount = 0;
         function doSubmit(i){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
             if(validateForm.form()){
+
+                var useTypeStr = $("#useTypeStr").val();
+                if (useTypeStr == null || "" == useTypeStr) {
+                    parent.layer.msg("请选择引用类型!", {icon: 5});
+                    return false;
+                }
                 if(i==2){
                     $("#inputForm").attr("action","${ctx}/businessSignature/businessSignature/tstore");
                 }else{
@@ -99,6 +109,8 @@
                     }
                 }
             });
+            //引用类型处理
+            contentDetailTypeShow();
         });
 
 
@@ -158,6 +170,8 @@
         <sys:message content="${message}"/>
         <form:form id="inputForm" modelAttribute="businessSignatureInfo" action="${ctx}/businessSignature/businessSignature/save" method="post" class="form-horizontal layui-form ">
             <form:hidden path="id"/>
+            <form:hidden path="useTypeShow"/>
+            <input type="hidden" id="useTypeStr" name="useTypeStr" value="">
 
             <div class="form-group layui-row">
                 <div class="form-group-label"><h2>业务用章申请基础信息</h2></div>
@@ -179,7 +193,7 @@
                     </div>
                 </div>--%>
 
-                <div class="layui-item layui-col-sm6 lw7">
+                <%--<div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
                     <div class="layui-input-block readOnlyFFF">
                         <form:select placeholder="请选择" path="useType" lay-filter="useType" class="form-control judgment editable-select layui-input" id="useType" value="${businessSignatureInfo.useType}">
@@ -187,6 +201,14 @@
                             <form:options items="${fns:getMainDictList('businessSignature')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
                         </form:select>
                     </div>
+                </div>--%>
+
+
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+                    <div class="layui-input-block">
+                        <div id="useType" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+                    </div>
                 </div>
 
 
@@ -417,5 +439,108 @@
         </form:form>
     </div>
 </div>
+<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+    function contentDetailTypeShow() {
+        $.ajax({
+            type:'post',
+            url:'${ctx}/businessSignature/businessSignature/getUseType',
+            data:{
+                "type":2
+            },
+            success:function(data){
+                if(data.success) {
+                    var data = data.body.list;
+                    var newDataList = data;
+                    var showList = [];
+                    $.ajax({
+                        type:'post',
+                        url:'${ctx}/businessSignature/businessSignature/getUseTypeById',
+                        data:{
+                            "id":$("#id").val()
+                        },
+                        success:function(dataListById){
+
+                            if(dataListById.success) {
+                                var showDataList = dataListById.body.list;
+                                var lists = [];
+                                for (i in newDataList) {
+                                    for (j in showDataList) {
+                                        if (newDataList[i].value == showDataList[j].value) {
+                                            var newData = {
+                                                "name": newDataList[i].name,
+                                                "value": newDataList[i].value,
+                                                "selected": true
+
+                                            }
+                                            lists.push(newDataList[i].value);
+                                            showList.push(newData);
+                                            data.splice(i,1,newData);
+                                        }
+                                    }
+                                }
+                                if(0 == showDataList.length){
+                                    var useTypeShow = $("#useTypeShow").val();
+                                    if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+                                        for (i in newDataList) {
+                                            if (newDataList[i].value == useTypeShow) {
+                                                var newData = {
+                                                    "name": newDataList[i].name,
+                                                    "value": newDataList[i].value,
+                                                    "selected": true
+
+                                                }
+                                                lists.push(newDataList[i].value);
+                                                showList.push(newData);
+                                                data.splice(i,1,newData);
+                                            }
+                                        }
+                                    }else{
+
+                                        var newData = {
+                                            "name": newDataList[0].name,
+                                            "value": newDataList[0].value,
+                                            "selected": true
+
+                                        }
+                                        lists.push(newDataList[0].value);
+                                        showList.push(newData);
+                                        //data.splice(0,1,newData);
+                                    }
+                                }
+
+                                $("#useTypeStr").val(lists);
+                                xmSelect.render({
+                                    el: '#useType',
+                                    language: 'zn',
+                                    data:data
+                                })
+                            }
+                        }
+                    })
+                }
+            }
+        })
+    }
+
+    var useType = xmSelect.render({
+        el: '#useType',
+        language: 'zn',
+        data: [
+        ]
+    })
+
+
+    document.getElementById('useType').onblur=function(){
+        var list = [];
+        //获取当前多选选中的值
+        var selectArr = useType.getValue();
+        for (var i in selectArr){
+            list.push(selectArr[i].value);
+        }
+        $("#useTypeStr").val(list);
+        console.log(list);
+    }
+</script>
 </body>
 </html>

+ 3 - 1
src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureList.jsp

@@ -329,7 +329,9 @@
                 <div class="nav-btns">
                     <div class="layui-btn-group">
                         <shiro:hasPermission name="businessSignature:businessSignature:add">
-                            <table:addRow url="${ctx}/businessSignature/businessSignature/form" title="业务用章申请"></table:addRow><!-- 增加按钮 -->
+                            <c:if test="${masterState == 1}">
+                                <table:addRow url="${ctx}/businessSignature/businessSignature/form" title="业务用章申请"></table:addRow><!-- 增加按钮 -->
+                            </c:if>
                         </shiro:hasPermission>
                         <button class="layui-btn layui-btn-sm" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
                     </div>

+ 123 - 1
src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureModify.jsp

@@ -10,6 +10,10 @@
     <script src="${ctxStatic}/common/html/js/script.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+    <link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
     <style>
         #projectDesc-error{
             left:0;
@@ -47,6 +51,11 @@
         var clientCount = 0;
         function doSubmit(i){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
             if(validateForm.form()){
+                var useTypeStr = $("#useTypeStr").val();
+                if (useTypeStr == null || "" == useTypeStr) {
+                    parent.layer.msg("请选择引用类型!", {icon: 5});
+                    return false;
+                }
                 if(i==2){
                     $("#inputForm").attr("action","${ctx}/dailyOfficeWork/dailyOfficeWorkSignature/tstore");
                 }else{
@@ -97,6 +106,8 @@
                 }
             });
 
+            //引用类型处理
+            contentDetailTypeShow();
         });
 
         function insertTitle(tValue){
@@ -164,6 +175,8 @@
             <form:hidden path="processInstanceId"/>
             <form:hidden id="flag" path="act.flag"/>
             <input type="hidden" id="flagFile" value="">
+            <form:hidden path="useTypeShow"/>
+            <input type="hidden" id="useTypeStr" name="useTypeStr" value="">
 
             <div class="form-group layui-row">
                 <div class="form-group-label"><h2>业务用章申请基础信息</h2></div>
@@ -185,7 +198,7 @@
                     </div>
                 </div>--%>
 
-                <div class="layui-item layui-col-sm6 lw7">
+                <%--<div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
                     <div class="layui-input-block readOnlyFFF">
                         <form:select placeholder="请选择" path="useType" class="form-control judgment editable-select layui-input" id="useType" value="${businessSignatureInfo.useType}">
@@ -193,6 +206,12 @@
                             <form:options items="${fns:getMainDictList('businessSignature')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
                         </form:select>
                     </div>
+                </div>--%>
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+                    <div class="layui-input-block">
+                        <div id="useType" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+                    </div>
                 </div>
 
 
@@ -425,5 +444,108 @@
         </form:form>
     </div>
 </div>
+<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+    function contentDetailTypeShow() {
+        $.ajax({
+            type:'post',
+            url:'${ctx}/businessSignature/businessSignature/getUseType',
+            data:{
+                "type":2
+            },
+            success:function(data){
+                if(data.success) {
+                    var data = data.body.list;
+                    var newDataList = data;
+                    var showList = [];
+                    $.ajax({
+                        type:'post',
+                        url:'${ctx}/businessSignature/businessSignature/getUseTypeById',
+                        data:{
+                            "id":$("#id").val()
+                        },
+                        success:function(dataListById){
+
+                            if(dataListById.success) {
+                                var showDataList = dataListById.body.list;
+                                var lists = [];
+                                for (i in newDataList) {
+                                    for (j in showDataList) {
+                                        if (newDataList[i].value == showDataList[j].value) {
+                                            var newData = {
+                                                "name": newDataList[i].name,
+                                                "value": newDataList[i].value,
+                                                "selected": true
+
+                                            }
+                                            lists.push(newDataList[i].value);
+                                            showList.push(newData);
+                                            data.splice(i,1,newData);
+                                        }
+                                    }
+                                }
+                                if(0 == showDataList.length){
+                                    var useTypeShow = $("#useTypeShow").val();
+                                    if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+                                        for (i in newDataList) {
+                                            if (newDataList[i].value == useTypeShow) {
+                                                var newData = {
+                                                    "name": newDataList[i].name,
+                                                    "value": newDataList[i].value,
+                                                    "selected": true
+
+                                                }
+                                                lists.push(newDataList[i].value);
+                                                showList.push(newData);
+                                                data.splice(i,1,newData);
+                                            }
+                                        }
+                                    }else{
+
+                                        var newData = {
+                                            "name": newDataList[0].name,
+                                            "value": newDataList[0].value,
+                                            "selected": true
+
+                                        }
+                                        lists.push(newDataList[0].value);
+                                        showList.push(newData);
+                                        //data.splice(0,1,newData);
+                                    }
+                                }
+
+                                $("#useTypeStr").val(lists);
+                                xmSelect.render({
+                                    el: '#useType',
+                                    language: 'zn',
+                                    data:data
+                                })
+                            }
+                        }
+                    })
+                }
+            }
+        })
+    }
+
+    var useType = xmSelect.render({
+        el: '#useType',
+        language: 'zn',
+        data: [
+        ]
+    })
+
+
+    document.getElementById('useType').onblur=function(){
+        var list = [];
+        //获取当前多选选中的值
+        var selectArr = useType.getValue();
+        for (var i in selectArr){
+            list.push(selectArr[i].value);
+        }
+        $("#useTypeStr").val(list);
+        console.log(list);
+    }
+</script>
 </body>
 </html>

+ 118 - 1
src/main/webapp/webpage/modules/signatureManagement/businessSignature/BusinessSignatureView.jsp

@@ -10,6 +10,10 @@
     <script src="${ctxStatic}/common/html/js/script.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+    <link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
     <style>
         #projectDesc-error{
             left:0;
@@ -73,6 +77,9 @@
                 }
             });
 
+
+            //引用类型处理
+            contentDetailTypeShow();
         });
 
     </script>
@@ -101,11 +108,18 @@
                     </div>
                 </div>--%>
 
-                <div class="layui-item layui-col-sm6 lw7">
+                <%--<div class="layui-item layui-col-sm6 lw7">
                     <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" style="background-color: #f1f1f1" value="${businessSignatureInfo.useType}"/>
                     </div>
+                </div>--%>
+
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+                    <div class="layui-input-block">
+                        <div id="useType" style="pointer-events: none; background-color: #f1f1f1" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+                    </div>
                 </div>
 
                 <div class="layui-item layui-col-sm6 lw7">
@@ -292,5 +306,108 @@
         </form:form>
     </div>
 </div>
+<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+    function contentDetailTypeShow() {
+        $.ajax({
+            type:'post',
+            url:'${ctx}/businessSignature/businessSignature/getUseType',
+            data:{
+                "type":2
+            },
+            success:function(data){
+                if(data.success) {
+                    var data = data.body.list;
+                    var newDataList = data;
+                    var showList = [];
+                    $.ajax({
+                        type:'post',
+                        url:'${ctx}/businessSignature/businessSignature/getUseTypeById',
+                        data:{
+                            "id":$("#id").val()
+                        },
+                        success:function(dataListById){
+
+                            if(dataListById.success) {
+                                var showDataList = dataListById.body.list;
+                                var lists = [];
+                                for (i in newDataList) {
+                                    for (j in showDataList) {
+                                        if (newDataList[i].value == showDataList[j].value) {
+                                            var newData = {
+                                                "name": newDataList[i].name,
+                                                "value": newDataList[i].value,
+                                                "selected": true
+
+                                            }
+                                            lists.push(newDataList[i].value);
+                                            showList.push(newData);
+                                            data.splice(i,1,newData);
+                                        }
+                                    }
+                                }
+                                if(0 == showDataList.length){
+                                    var useTypeShow = $("#useTypeShow").val();
+                                    if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+                                        for (i in newDataList) {
+                                            if (newDataList[i].value == useTypeShow) {
+                                                var newData = {
+                                                    "name": newDataList[i].name,
+                                                    "value": newDataList[i].value,
+                                                    "selected": true
+
+                                                }
+                                                lists.push(newDataList[i].value);
+                                                showList.push(newData);
+                                                data.splice(i,1,newData);
+                                            }
+                                        }
+                                    }else{
+
+                                        var newData = {
+                                            "name": newDataList[0].name,
+                                            "value": newDataList[0].value,
+                                            "selected": true
+
+                                        }
+                                        lists.push(newDataList[0].value);
+                                        showList.push(newData);
+                                        //data.splice(0,1,newData);
+                                    }
+                                }
+
+                                $("#useTypeStr").val(lists);
+                                xmSelect.render({
+                                    el: '#useType',
+                                    language: 'zn',
+                                    data:data
+                                })
+                            }
+                        }
+                    })
+                }
+            }
+        })
+    }
+
+    var useType = xmSelect.render({
+        el: '#useType',
+        language: 'zn',
+        data: [
+        ]
+    })
+
+
+    document.getElementById('useType').onblur=function(){
+        var list = [];
+        //获取当前多选选中的值
+        var selectArr = useType.getValue();
+        for (var i in selectArr){
+            list.push(selectArr[i].value);
+        }
+        $("#useTypeStr").val(list);
+        console.log(list);
+    }
+</script>
 </body>
 </html>

+ 132 - 7
src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureAudit.jsp

@@ -10,6 +10,10 @@
 	<script src="${ctxStatic}/common/html/js/script.js"></script>
 	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
 	<link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+	<script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+	<script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+	<link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
 
 	<script type="text/javascript">
 		var validateForm;
@@ -52,6 +56,9 @@
 					}
 				}
 			});
+
+			//引用类型处理
+			contentDetailTypeShow();
 		});
         function insertTitle(tValue){
             var files = $("#attachment_file")[0].files;
@@ -117,12 +124,7 @@
 
 			<div class="form-group layui-row first">
 				<div class="form-group-label"><h2>电子印章申请基础信息</h2></div>
-				<div class="layui-item layui-col-sm6 lw7">
-					<label class="layui-form-label">描述:</label>
-					<div class="layui-input-block">
-						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${electronicSignatureInfo.name}"/>
-					</div>
-				</div>
+
 				<%--<div class="layui-item layui-col-sm6 lw7">
 					<label class="layui-form-label">签章编号:</label>
 					<div class="layui-input-block">
@@ -132,13 +134,27 @@
 					</div>
 				</div>--%>
 
-				<div class="layui-item layui-col-sm6 lw7">
+				<%--<div class="layui-item layui-col-sm6 lw7">
 					<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" style="background-color: #f1f1f1" value="${electronicSignatureInfo.useType}"/>
 					</div>
+				</div>--%>
+
+				<div class="layui-item layui-col-sm6 lw7">
+					<label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+					<div class="layui-input-block">
+						<div id="useType" style="pointer-events: none; background-color: #f1f1f1" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+					</div>
 				</div>
 
+				<%--<div class="layui-item layui-col-sm6 lw6">
+					<label class="layui-form-label">负责城市:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${electronicSignatureInfo.area.name}"/>
+					</div>
+				</div>--%>
+
 				<div class="layui-item layui-col-sm6 lw7">
 					<label class="layui-form-label">创建人:</label>
 					<div class="layui-input-block">
@@ -159,6 +175,12 @@
 					</div>
 				</div>
 
+				<div class="layui-item layui-col-sm6 lw7">
+					<label class="layui-form-label">描述:</label>
+					<div class="layui-input-block">
+						<input htmlEscape="false"  readonly="true" class="form-control layui-input" style="background-color: #f1f1f1" value="${electronicSignatureInfo.name}"/>
+					</div>
+				</div>
 
 				<div class="layui-item layui-col-sm12 lw7 with-textarea">
 					<label class="layui-form-label">备注:</label>
@@ -338,5 +360,108 @@
 			</div>
 	</div>
 </div>
+<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+	function contentDetailTypeShow() {
+		$.ajax({
+			type:'post',
+			url:'${ctx}/electronicSignature/electronicSignature/getUseType',
+			data:{
+				"type":2
+			},
+			success:function(data){
+				if(data.success) {
+					var data = data.body.list;
+					var newDataList = data;
+					var showList = [];
+					$.ajax({
+						type:'post',
+						url:'${ctx}/electronicSignature/electronicSignature/getUseTypeById',
+						data:{
+							"id":$("#id").val()
+						},
+						success:function(dataListById){
+
+							if(dataListById.success) {
+								var showDataList = dataListById.body.list;
+								var lists = [];
+								for (i in newDataList) {
+									for (j in showDataList) {
+										if (newDataList[i].value == showDataList[j].value) {
+											var newData = {
+												"name": newDataList[i].name,
+												"value": newDataList[i].value,
+												"selected": true
+
+											}
+											lists.push(newDataList[i].value);
+											showList.push(newData);
+											data.splice(i,1,newData);
+										}
+									}
+								}
+								if(0 == showDataList.length){
+									var useTypeShow = $("#useTypeShow").val();
+									if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+										for (i in newDataList) {
+											if (newDataList[i].value == useTypeShow) {
+												var newData = {
+													"name": newDataList[i].name,
+													"value": newDataList[i].value,
+													"selected": true
+
+												}
+												lists.push(newDataList[i].value);
+												showList.push(newData);
+												data.splice(i,1,newData);
+											}
+										}
+									}else{
+
+										var newData = {
+											"name": newDataList[0].name,
+											"value": newDataList[0].value,
+											"selected": true
+
+										}
+										lists.push(newDataList[0].value);
+										showList.push(newData);
+										//data.splice(0,1,newData);
+									}
+								}
+
+								$("#useTypeStr").val(lists);
+								xmSelect.render({
+									el: '#useType',
+									language: 'zn',
+									data:data
+								})
+							}
+						}
+					})
+				}
+			}
+		})
+	}
+
+	var useType = xmSelect.render({
+		el: '#useType',
+		language: 'zn',
+		data: [
+		]
+	})
+
+
+	document.getElementById('useType').onblur=function(){
+		var list = [];
+		//获取当前多选选中的值
+		var selectArr = useType.getValue();
+		for (var i in selectArr){
+			list.push(selectArr[i].value);
+		}
+		$("#useTypeStr").val(list);
+		console.log(list);
+	}
+</script>
 </body>
 </html>

+ 143 - 7
src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureForm.jsp

@@ -10,6 +10,10 @@
     <script src="${ctxStatic}/common/html/js/script.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+    <link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
     <style>
         #projectDesc-error{
             left:0;
@@ -47,6 +51,13 @@
         var clientCount = 0;
         function doSubmit(i){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
             if(validateForm.form()){
+
+                var useTypeStr = $("#useTypeStr").val();
+                if (useTypeStr == null || "" == useTypeStr) {
+                    parent.layer.msg("请选择引用类型!", {icon: 5});
+                    return false;
+                }
+
                 if(i==2){
                     $("#inputForm").attr("action","${ctx}/electronicSignature/electronicSignature/tstore");
                 }else{
@@ -115,6 +126,10 @@
                 }
             });
             /*useType('${electronicSignatureInfo.useType}')*/
+
+            //引用类型处理
+            contentDetailTypeShow();
+
         });
 
 
@@ -188,15 +203,11 @@
         <sys:message content="${message}"/>
         <form:form id="inputForm" modelAttribute="electronicSignatureInfo" action="${ctx}/electronicSignature/electronicSignature/save" method="post" class="form-horizontal layui-form ">
             <form:hidden path="id"/>
+            <form:hidden path="useTypeShow"/>
+            <input type="hidden" id="useTypeStr" name="useTypeStr" value="">
 
             <div class="form-group layui-row">
                 <div class="form-group-label"><h2>电子印章申请基础信息</h2></div>
-                <div class="layui-item layui-col-sm6 lw7">
-                    <label class="layui-form-label"><span class="require-item">*</span>描述:</label>
-                    <div class="layui-input-block">
-                        <form:input path="name" id="name" maxlength="255" htmlEscape="false" placeholder="请输入描述" class="form-control layui-input required"/>
-                    </div>
-                </div>
                 <%--<div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label">签章编号:</label>
                     <div class="layui-input-block">
@@ -209,7 +220,7 @@
                     </div>
                 </div>--%>
 
-                <div class="layui-item layui-col-sm6 lw7">
+                <%--<div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
                     <div class="layui-input-block readOnlyFFF">
                         <form:select placeholder="请选择" path="useType" lay-filter="useType" class="form-control judgment editable-select layui-input" id="useType" value="${electronicSignatureInfo.useType}">
@@ -217,6 +228,14 @@
                             <form:options items="${fns:getMainDictList('electronicSignature')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
                         </form:select>
                     </div>
+                </div>--%>
+
+
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+                    <div class="layui-input-block">
+                        <div id="useType" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+                    </div>
                 </div>
 
                 <%--<div id="d1" class="layui-item layui-col-sm6 lw7">
@@ -240,6 +259,13 @@
                 </div>--%>
 
 
+                <%--<div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>负责城市:</label>
+                    <div class="layui-input-block  with-icon">
+                        <sys:treeselect id="area" name="area.id" value="${electronicSignatureInfo.area.id}" labelName="area.name" labelValue="${electronicSignatureInfo.area.name}"
+                                        cssStyle="background-color:#fff"   title="负责城市" url="/sys/area/treeData" cssClass="form-control judgment layui-input" allowClear="true" notAllowSelectParent="false"/>
+                    </div>
+                </div>--%>
 
 
                 <div class="layui-item layui-col-sm6 lw7">
@@ -262,6 +288,13 @@
                     </div>
                 </div>
 
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label">描述:</label>
+                    <div class="layui-input-block">
+                        <form:input path="name" id="name" maxlength="255" htmlEscape="false" placeholder="请输入描述" class="form-control layui-input"/>
+                    </div>
+                </div>
+
                 <div class="layui-item layui-col-sm12 lw7 with-textarea">
                     <label class="layui-form-label ">备注:</label>
                     <div class="layui-input-block">
@@ -468,5 +501,108 @@
         </form:form>
     </div>
 </div>
+<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+    function contentDetailTypeShow() {
+        $.ajax({
+            type:'post',
+            url:'${ctx}/electronicSignature/electronicSignature/getUseType',
+            data:{
+                "type":2
+            },
+            success:function(data){
+                if(data.success) {
+                    var data = data.body.list;
+                    var newDataList = data;
+                    var showList = [];
+                    $.ajax({
+                        type:'post',
+                        url:'${ctx}/electronicSignature/electronicSignature/getUseTypeById',
+                        data:{
+                            "id":$("#id").val()
+                        },
+                        success:function(dataListById){
+
+                            if(dataListById.success) {
+                                var showDataList = dataListById.body.list;
+                                var lists = [];
+                                for (i in newDataList) {
+                                    for (j in showDataList) {
+                                        if (newDataList[i].value == showDataList[j].value) {
+                                            var newData = {
+                                                "name": newDataList[i].name,
+                                                "value": newDataList[i].value,
+                                                "selected": true
+
+                                            }
+                                            lists.push(newDataList[i].value);
+                                            showList.push(newData);
+                                            data.splice(i,1,newData);
+                                        }
+                                    }
+                                }
+                                if(0 == showDataList.length){
+                                    var useTypeShow = $("#useTypeShow").val();
+                                    if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+                                        for (i in newDataList) {
+                                            if (newDataList[i].value == useTypeShow) {
+                                                var newData = {
+                                                    "name": newDataList[i].name,
+                                                    "value": newDataList[i].value,
+                                                    "selected": true
+
+                                                }
+                                                lists.push(newDataList[i].value);
+                                                showList.push(newData);
+                                                data.splice(i,1,newData);
+                                            }
+                                        }
+                                    }else{
+
+                                        var newData = {
+                                            "name": newDataList[0].name,
+                                            "value": newDataList[0].value,
+                                            "selected": true
+
+                                        }
+                                        lists.push(newDataList[0].value);
+                                        showList.push(newData);
+                                        //data.splice(0,1,newData);
+                                    }
+                                }
+
+                                $("#useTypeStr").val(lists);
+                                xmSelect.render({
+                                    el: '#useType',
+                                    language: 'zn',
+                                    data:data
+                                })
+                            }
+                        }
+                    })
+                }
+            }
+        })
+    }
+
+    var useType = xmSelect.render({
+        el: '#useType',
+        language: 'zn',
+        data: [
+        ]
+    })
+
+
+    document.getElementById('useType').onblur=function(){
+        var list = [];
+        //获取当前多选选中的值
+        var selectArr = useType.getValue();
+        for (var i in selectArr){
+            list.push(selectArr[i].value);
+        }
+        $("#useTypeStr").val(list);
+        console.log(list);
+    }
+</script>
 </body>
 </html>

+ 12 - 6
src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureList.jsp

@@ -381,12 +381,16 @@
                 <div class="nav-btns">
                     <div class="layui-btn-group">
                         <shiro:hasPermission name="electronicSignature:electronicSignature:add">
-                            <table:addRow url="${ctx}/electronicSignature/electronicSignature/form" title="电子印章申请"></table:addRow><!-- 增加按钮 -->
+                            <c:if test="${masterState == 1}">
+                                <table:addRow url="${ctx}/electronicSignature/electronicSignature/form" title="电子印章申请"></table:addRow><!-- 增加按钮 -->
+                            </c:if>
                         </shiro:hasPermission>
                         <button class="layui-btn layui-btn-sm" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
-                        <c:if test="${isArea != '1'}">
+                        <c:if test="${masterState == 1 && isArea != '1'}">
                             <button class="layui-btn layui-btn-sm layui-bg-blue" title="地区负责人申请" onclick="openDialogDis('地区负责人申请','${ctx}/districtDirectorApplication/districtDirectorApplication/form','95%','95%')">&nbsp;地区负责人申请</button>
                         </c:if>
+
+
                     </div>
                     <div style="clear: both;"></div>
                 </div>
@@ -412,11 +416,12 @@
                 /*{checkbox: true, fixed: true},*/
                 {field:'index',align:'center', title: '序号',width:60}
                 /*,{field:'number',align:'center', title: '申请编号',  width:160}*/
-                ,{field:'name',align:'center', title: '描述',minWidth:200,templet:function(d){
-                        return "<a class=\"attention-info\" title=\"" + d.name + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看申请', '${ctx}/electronicSignature/electronicSignature/view?id=" + d.id +"','95%', '95%')\">" + d.name + "</a>";
-                    }}
 
-                ,{field:'useType',align:'center', title: '使用场景',  width:200}
+                ,{field:'useType',align:'center', title: '使用场景',  width:200,templet:function(d){
+                        return "<a class=\"attention-info\" title=\"" + d.useType + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看申请', '${ctx}/electronicSignature/electronicSignature/view?id=" + d.id +"','95%', '95%')\">" + d.useType + "</a>";
+                    }}
+                ,{field:'name',align:'center', title: '描述',minWidth:200}
+                /*,{field:'areaName',align:'center', title: '负责地区',  width:200}*/
                 ,{field:'createName', align:'center',title: '申请人', width:100,templet:function(d){
                         return "<span title=\"" + d.createName + "\">" + d.createName + "</span>";
                     }}
@@ -472,6 +477,7 @@
                     "index":"${index.index+1}"
                     ,"id":"${electronicSignatureInfo.id}"
                     ,"name":"<c:out value="${electronicSignatureInfo.name}" escapeXml="false"/>"
+                    ,"areaName":"<c:out value="${electronicSignatureInfo.area.name}" escapeXml="false"/>"
                     ,"useType":"${fns:getMainDictLabels(electronicSignatureInfo.useType,',','electronicSignature', '')}"
                     ,"createDate":"<fmt:formatDate value="${electronicSignatureInfo.createDate}" pattern="yyyy-MM-dd"/>"
                     ,"status":"${electronicSignatureInfo.status}"

+ 140 - 8
src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureModify.jsp

@@ -10,6 +10,10 @@
     <script src="${ctxStatic}/common/html/js/script.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+    <link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
     <style>
         #projectDesc-error{
             left:0;
@@ -47,6 +51,13 @@
         var clientCount = 0;
         function doSubmit(i){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
             if(validateForm.form()){
+
+                var useTypeStr = $("#useTypeStr").val();
+                if (useTypeStr == null || "" == useTypeStr) {
+                    parent.layer.msg("请选择引用类型!", {icon: 5});
+                    return false;
+                }
+
                 if(i==2){
                     $("#inputForm").attr("action","${ctx}/dailyOfficeWork/dailyOfficeWorkSignature/tstore");
                 }else{
@@ -97,6 +108,8 @@
                 }
             });
 
+            //引用类型处理
+            contentDetailTypeShow();
         });
 
         function insertTitle(tValue){
@@ -164,15 +177,11 @@
             <form:hidden path="processInstanceId"/>
             <form:hidden id="flag" path="act.flag"/>
             <input type="hidden" id="flagFile" value="">
+            <form:hidden path="useTypeShow"/>
+            <input type="hidden" id="useTypeStr" name="useTypeStr" value="">
 
             <div class="form-group layui-row">
                 <div class="form-group-label"><h2>电子印章申请基础信息</h2></div>
-                <div class="layui-item layui-col-sm6 lw7">
-                    <label class="layui-form-label"><span class="require-item">*</span>描述:</label>
-                    <div class="layui-input-block">
-                        <form:input path="name" id="name" maxlength="255" htmlEscape="false" placeholder="请输入描述" class="form-control layui-input required"/>
-                    </div>
-                </div>
                 <%--<div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label">签章编号:</label>
                     <div class="layui-input-block">
@@ -185,7 +194,7 @@
                     </div>
                 </div>--%>
 
-                <div class="layui-item layui-col-sm6 lw7">
+                <%--<div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
                     <div class="layui-input-block readOnlyFFF">
                         <form:select placeholder="请选择" path="useType" class="form-control judgment editable-select layui-input" id="useType" value="${electronicSignatureInfo.useType}">
@@ -193,10 +202,24 @@
                             <form:options items="${fns:getMainDictList('electronicSignature')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
                         </form:select>
                     </div>
+                </div>--%>
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+                    <div class="layui-input-block">
+                        <div id="useType" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+                    </div>
                 </div>
 
 
 
+                <%--<div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>负责城市:</label>
+                    <div class="layui-input-block  with-icon">
+                        <sys:treeselect id="area" name="area.id" value="${electronicSignatureInfo.area.id}" labelName="area.name" labelValue="${electronicSignatureInfo.area.name}"
+                                        cssStyle="background-color:#fff"   title="负责城市" url="/sys/area/treeData" cssClass="form-control judgment layui-input" allowClear="true" notAllowSelectParent="false"/>
+                    </div>
+                </div>--%>
+
 
                 <div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label">创建人:</label>
@@ -218,6 +241,13 @@
                     </div>
                 </div>
 
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label">描述:</label>
+                    <div class="layui-input-block">
+                        <form:input path="name" id="name" maxlength="255" htmlEscape="false" placeholder="请输入描述" class="form-control layui-input"/>
+                    </div>
+                </div>
+
                 <div class="layui-item layui-col-sm12 lw7 with-textarea">
                     <label class="layui-form-label ">备注:</label>
                     <div class="layui-input-block">
@@ -423,6 +453,108 @@
             <div class="form-group layui-row page-end"></div>
         </form:form>
     </div>
-</div>
+</div><script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+    function contentDetailTypeShow() {
+        $.ajax({
+            type:'post',
+            url:'${ctx}/electronicSignature/electronicSignature/getUseType',
+            data:{
+                "type":2
+            },
+            success:function(data){
+                if(data.success) {
+                    var data = data.body.list;
+                    var newDataList = data;
+                    var showList = [];
+                    $.ajax({
+                        type:'post',
+                        url:'${ctx}/electronicSignature/electronicSignature/getUseTypeById',
+                        data:{
+                            "id":$("#id").val()
+                        },
+                        success:function(dataListById){
+
+                            if(dataListById.success) {
+                                var showDataList = dataListById.body.list;
+                                var lists = [];
+                                for (i in newDataList) {
+                                    for (j in showDataList) {
+                                        if (newDataList[i].value == showDataList[j].value) {
+                                            var newData = {
+                                                "name": newDataList[i].name,
+                                                "value": newDataList[i].value,
+                                                "selected": true
+
+                                            }
+                                            lists.push(newDataList[i].value);
+                                            showList.push(newData);
+                                            data.splice(i,1,newData);
+                                        }
+                                    }
+                                }
+                                if(0 == showDataList.length){
+                                    var useTypeShow = $("#useTypeShow").val();
+                                    if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+                                        for (i in newDataList) {
+                                            if (newDataList[i].value == useTypeShow) {
+                                                var newData = {
+                                                    "name": newDataList[i].name,
+                                                    "value": newDataList[i].value,
+                                                    "selected": true
+
+                                                }
+                                                lists.push(newDataList[i].value);
+                                                showList.push(newData);
+                                                data.splice(i,1,newData);
+                                            }
+                                        }
+                                    }else{
+
+                                        var newData = {
+                                            "name": newDataList[0].name,
+                                            "value": newDataList[0].value,
+                                            "selected": true
+
+                                        }
+                                        lists.push(newDataList[0].value);
+                                        showList.push(newData);
+                                        //data.splice(0,1,newData);
+                                    }
+                                }
+
+                                $("#useTypeStr").val(lists);
+                                xmSelect.render({
+                                    el: '#useType',
+                                    language: 'zn',
+                                    data:data
+                                })
+                            }
+                        }
+                    })
+                }
+            }
+        })
+    }
+
+    var useType = xmSelect.render({
+        el: '#useType',
+        language: 'zn',
+        data: [
+        ]
+    })
+
+
+    document.getElementById('useType').onblur=function(){
+        var list = [];
+        //获取当前多选选中的值
+        var selectArr = useType.getValue();
+        for (var i in selectArr){
+            list.push(selectArr[i].value);
+        }
+        $("#useTypeStr").val(list);
+        console.log(list);
+    }
+</script>
 </body>
 </html>

+ 131 - 7
src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureView.jsp

@@ -10,6 +10,10 @@
     <script src="${ctxStatic}/common/html/js/script.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/layuidown.css"/>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script src="${ctxStatic}/layer-v2.3/layui/xmSelect.js" charset="utf-8"></script>
+    <link href="${ctxStatic}/bootstrap-select-1.12.4/css/bootstrap-select.min.css" rel="stylesheet" />
     <style>
         #projectDesc-error{
             left:0;
@@ -73,6 +77,9 @@
                 }
             });
 
+
+            //引用类型处理
+            contentDetailTypeShow();
         });
 
     </script>
@@ -86,12 +93,6 @@
 
             <div class="form-group layui-row">
                 <div class="form-group-label"><h2>电子印章申请基础信息</h2></div>
-                <div class="layui-item layui-col-sm6 lw7">
-                    <label class="layui-form-label"><span class="require-item">*</span>描述:</label>
-                    <div class="layui-input-block">
-                        <form:input path="name" id="name" maxlength="255" readonly="true" htmlEscape="false" placeholder="请输入描述" class="form-control layui-input required"/>
-                    </div>
-                </div>
                 <%--<div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label">签章编号:</label>
                     <div class="layui-input-block">
@@ -101,13 +102,27 @@
                     </div>
                 </div>--%>
 
-                <div class="layui-item layui-col-sm6 lw7">
+                <%--<div class="layui-item layui-col-sm6 lw7">
                     <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" style="background-color: #f1f1f1" value="${electronicSignatureInfo.useType}"/>
                     </div>
+                </div>--%>
+
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label"><span class="require-item">*</span>使用场景:</label>
+                    <div class="layui-input-block">
+                        <div id="useType" style="pointer-events: none; background-color: #f1f1f1" class="xm-select-demo" tabindex="0" contenteditable="true"></div>
+                    </div>
                 </div>
 
+                <%--<div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label">负责城市:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${electronicSignatureInfo.area.name}"/>
+                    </div>
+                </div>--%>
+
                 <div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label">创建人:</label>
                     <div class="layui-input-block">
@@ -127,6 +142,12 @@
                         <input id="createDate" name="createDate" htmlEscape="false"  value="<fmt:formatDate value="${electronicSignatureInfo.createDate}" pattern="yyyy-MM-dd"/>" readonly="readonly"  class="form-control judgment layui-input"/>
                     </div>
                 </div>
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label">描述:</label>
+                    <div class="layui-input-block">
+                        <form:input path="name" id="name" maxlength="255" readonly="true" htmlEscape="false" placeholder="请输入描述" class="form-control layui-input"/>
+                    </div>
+                </div>
 
                 <div class="layui-item layui-col-sm12 lw7 with-textarea">
                     <label class="layui-form-label ">备注:</label>
@@ -292,5 +313,108 @@
         </form:form>
     </div>
 </div>
+<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
+<script>
+    function contentDetailTypeShow() {
+        $.ajax({
+            type:'post',
+            url:'${ctx}/electronicSignature/electronicSignature/getUseType',
+            data:{
+                "type":2
+            },
+            success:function(data){
+                if(data.success) {
+                    var data = data.body.list;
+                    var newDataList = data;
+                    var showList = [];
+                    $.ajax({
+                        type:'post',
+                        url:'${ctx}/electronicSignature/electronicSignature/getUseTypeById',
+                        data:{
+                            "id":$("#id").val()
+                        },
+                        success:function(dataListById){
+
+                            if(dataListById.success) {
+                                var showDataList = dataListById.body.list;
+                                var lists = [];
+                                for (i in newDataList) {
+                                    for (j in showDataList) {
+                                        if (newDataList[i].value == showDataList[j].value) {
+                                            var newData = {
+                                                "name": newDataList[i].name,
+                                                "value": newDataList[i].value,
+                                                "selected": true
+
+                                            }
+                                            lists.push(newDataList[i].value);
+                                            showList.push(newData);
+                                            data.splice(i,1,newData);
+                                        }
+                                    }
+                                }
+                                if(0 == showDataList.length){
+                                    var useTypeShow = $("#useTypeShow").val();
+                                    if(undefined != useTypeShow && null != useTypeShow && '' != useTypeShow){
+                                        for (i in newDataList) {
+                                            if (newDataList[i].value == useTypeShow) {
+                                                var newData = {
+                                                    "name": newDataList[i].name,
+                                                    "value": newDataList[i].value,
+                                                    "selected": true
+
+                                                }
+                                                lists.push(newDataList[i].value);
+                                                showList.push(newData);
+                                                data.splice(i,1,newData);
+                                            }
+                                        }
+                                    }else{
+
+                                        var newData = {
+                                            "name": newDataList[0].name,
+                                            "value": newDataList[0].value,
+                                            "selected": true
+
+                                        }
+                                        lists.push(newDataList[0].value);
+                                        showList.push(newData);
+                                        //data.splice(0,1,newData);
+                                    }
+                                }
+
+                                $("#useTypeStr").val(lists);
+                                xmSelect.render({
+                                    el: '#useType',
+                                    language: 'zn',
+                                    data:data
+                                })
+                            }
+                        }
+                    })
+                }
+            }
+        })
+    }
+
+    var useType = xmSelect.render({
+        el: '#useType',
+        language: 'zn',
+        data: [
+        ]
+    })
+
+
+    document.getElementById('useType').onblur=function(){
+        var list = [];
+        //获取当前多选选中的值
+        var selectArr = useType.getValue();
+        for (var i in selectArr){
+            list.push(selectArr[i].value);
+        }
+        $("#useTypeStr").val(list);
+        console.log(list);
+    }
+</script>
 </body>
 </html>