浏览代码

代码调整优化

user5 2 年之前
父节点
当前提交
399b8dd1ec
共有 46 个文件被更改,包括 2630 次插入829 次删除
  1. 6 1
      src/main/java/com/jeeplus/modules/projectmaterialstorage/dao/ProjectMaterialStorageDao.java
  2. 191 24
      src/main/java/com/jeeplus/modules/projectmaterialstorage/entity/ProjectMaterialStorage.java
  3. 88 4
      src/main/java/com/jeeplus/modules/projectmaterialstorage/entity/ProjectMaterialStorageImport.java
  4. 19 2
      src/main/java/com/jeeplus/modules/projectmaterialstorage/service/ProjectMaterialStorageService.java
  5. 100 14
      src/main/java/com/jeeplus/modules/projectmaterialstorage/web/ProjectMaterialStorageController.java
  6. 2 2
      src/main/java/com/jeeplus/modules/projectrecord/service/ProjectPlanService.java
  7. 2 2
      src/main/java/com/jeeplus/modules/projectrecord/web/ProjectPlanCostController.java
  8. 7 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/dao/RuralProjectRecordReportDao.java
  9. 1 1
      src/main/java/com/jeeplus/modules/ruralprojectrecords/dao/RuralProjectRecordsDao.java
  10. 2 2
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageAllService.java
  11. 2 2
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageService.java
  12. 1 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectRecordReportService.java
  13. 1 1
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectRecordsService.java
  14. 8 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectRecordsController.java
  15. 2 2
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectSignatureOldMessageDisposeController.java
  16. 1 0
      src/main/java/com/jeeplus/modules/statement/controller/StatementCompanyComprehensiveController.java
  17. 50 1
      src/main/java/com/jeeplus/modules/statement/entity/StatementCompanyComprehensiveInfo.java
  18. 20 2
      src/main/java/com/jeeplus/modules/statement/entity/StatementDataInfo.java
  19. 197 2
      src/main/java/com/jeeplus/modules/statement/service/StatementCompanyComprehensiveService.java
  20. 15 5
      src/main/java/com/jeeplus/modules/sys/web/LoginController.java
  21. 18 0
      src/main/java/com/jeeplus/modules/workinvoice/entity/WorkInvoice.java
  22. 27 7
      src/main/java/com/jeeplus/modules/workinvoice/entity/WorkInvoiceExport.java
  23. 100 1
      src/main/java/com/jeeplus/modules/workinvoice/service/WorkInvoiceService.java
  24. 1 0
      src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceAllController.java
  25. 5 4
      src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceTwoController.java
  26. 1 1
      src/main/resources/jeeplus.properties
  27. 165 38
      src/main/resources/mappings/modules/projectMaterialStorage/ProjectMaterialStorageDao.xml
  28. 384 308
      src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageAllDao.xml
  29. 32 2
      src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordReportDao.xml
  30. 774 209
      src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordsDao.xml
  31. 34 4
      src/main/resources/mappings/modules/statement/StatementCompanyComprehensiveDao.xml
  32. 26 10
      src/main/resources/mappings/modules/workinvoice/WorkInvoiceDao.xml
  33. 0 1
      src/main/resources/mappings/modules/workreimbursement/WorkReimbursementDao.xml
  34. 二进制
      src/main/webapp/dot/材料库处理表模板.xlsx
  35. 50 4
      src/main/webapp/webpage/modules/projectMaterialStorage/projectMaterialStorageForm.jsp
  36. 171 155
      src/main/webapp/webpage/modules/projectMaterialStorage/projectMaterialStorageList.jsp
  37. 61 5
      src/main/webapp/webpage/modules/projectMaterialStorage/projectMaterialStorageTwoForm.jsp
  38. 2 2
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/ruralCostProjectMessageList.jsp
  39. 17 5
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/all/ruralProjectMessageAllList.jsp
  40. 2 2
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/ruralProjectMessageList.jsp
  41. 16 0
      src/main/webapp/webpage/modules/statement/companyReportDataView.jsp
  42. 1 0
      src/main/webapp/webpage/modules/statement/projectReportZJList.jsp
  43. 1 1
      src/main/webapp/webpage/modules/workinvoice/workInvoiceAllList.jsp
  44. 9 1
      src/main/webapp/webpage/modules/workinvoice/workInvoiceAllTwoList.jsp
  45. 9 1
      src/main/webapp/webpage/modules/workinvoice/workInvoiceList.jsp
  46. 9 1
      src/main/webapp/webpage/modules/workinvoice/workInvoiceTwoList.jsp

+ 6 - 1
src/main/java/com/jeeplus/modules/projectmaterialstorage/dao/ProjectMaterialStorageDao.java

@@ -42,5 +42,10 @@ public interface ProjectMaterialStorageDao extends CrudDao<ProjectMaterialStorag
     /**
      * 材料库处理的批量插入
      */
-    public Integer batchInsert(@Param("projectMaterialStorageImportList")List<ProjectMaterialStorageImport> projectMaterialStorageImportList);
+    Integer batchInsert(@Param("projectMaterialStorageImportList")List<ProjectMaterialStorageImport> projectMaterialStorageImportList);
+
+
+    void deleteListById(@Param("idList")List<String> idList);
+
+    List<ProjectMaterialStorage> getByIdList(@Param("idList")List<String> idList,@Param("createBy")String createBy);
 }

+ 191 - 24
src/main/java/com/jeeplus/modules/projectmaterialstorage/entity/ProjectMaterialStorage.java

@@ -1,5 +1,6 @@
 package com.jeeplus.modules.projectmaterialstorage.entity;
 
+import com.fasterxml.jackson.annotation.JsonFormat;
 import com.google.common.collect.Lists;
 import com.jeeplus.common.persistence.DataEntity;
 import com.jeeplus.common.utils.excel.annotation.ExcelField;
@@ -17,6 +18,43 @@ public class ProjectMaterialStorage extends DataEntity<ProjectMaterialStorage> {
 
     private Double price ; //材料价格
 
+
+    private String materialName; //材料名称
+    private String brand; //品牌
+    private String specifications; //规格型号
+    private String unit; //单位
+    private Double projectPriceIncludingTax; //含税工程价(元)
+    private Double marketPriceIncludingTax; //含税市场价(元)
+    private Double taxRate; //税率
+    private String explain; //产品说明
+    private String supplier; //供应商
+    private String remarks; //备注
+    private Date quotedPriceDate; //报价时间
+
+    private Date beginDate;  //开始时间
+
+    private Date endDate;  //结束时间
+
+    private Project project;  //项目
+
+    private String projectName; //项目名称
+
+    private String areaName;  //地点
+
+    private Area area;
+
+    private String projectId; //报告号
+
+
+    private String beginProjectPriceIncludingTax; //开始含税工程价(元)
+    private String endProjectPriceIncludingTax; //结束含税工程价(元)
+    private String beginMarketPriceIncludingTax; //开始含税市场价(元)
+    private String endMarketPriceIncludingTax; //结束含税市场价(元)
+    private String beginTaxRate; //开始税率
+    private String endTaxRate; //结束税率
+    private Date beginQuotedPriceDate; //开始报价时间
+    private Date endQuotedPriceDate; //结束报价时间
+
     //材料信息数据表集合
     private List<ProjectMaterialStorageImport> projectMaterialStorageList = Lists.newArrayList();
 
@@ -37,16 +75,6 @@ public class ProjectMaterialStorage extends DataEntity<ProjectMaterialStorage> {
         this.endDate = endDate;
     }
 
-    private String materialName; //材料名称
-
-    private Date beginDate;  //开始时间
-
-    private Date endDate;  //结束时间
-
-    private Project project;  //项目
-
-    private String unit; //单位
-
     public String getProjectId() {
         return projectId;
     }
@@ -55,8 +83,6 @@ public class ProjectMaterialStorage extends DataEntity<ProjectMaterialStorage> {
         this.projectId = reportId;
     }
 
-    private String projectName; //项目名称
-
     public Area getArea() {
         return area;
     }
@@ -65,12 +91,6 @@ public class ProjectMaterialStorage extends DataEntity<ProjectMaterialStorage> {
         this.area = area;
     }
 
-    private String areaName;  //地点
-
-    private Area area;
-
-    private String projectId; //报告号
-
     public String getProjectName() {
         return projectName;
     }
@@ -104,7 +124,6 @@ public class ProjectMaterialStorage extends DataEntity<ProjectMaterialStorage> {
     public ProjectMaterialStorage(String id){
         super(id);
     }
-    @ExcelField(title="价格", align=2, sort=3)
     public Double getPrice() {
         return price;
     }
@@ -130,7 +149,60 @@ public class ProjectMaterialStorage extends DataEntity<ProjectMaterialStorage> {
         this.project = project;
     }
 
-    @ExcelField(title="材料单位", align=2, sort=2)
+    public List<ProjectMaterialStorageImport> getProjectMaterialStorageList() {
+        return projectMaterialStorageList;
+    }
+
+    public void setProjectMaterialStorageList(List<ProjectMaterialStorageImport> projectMaterialStorageList) {
+        this.projectMaterialStorageList = projectMaterialStorageList;
+    }
+
+    @ExcelField(title="品牌", align=2, sort=2)
+    public String getBrand() {
+        return brand;
+    }
+
+    public void setBrand(String brand) {
+        this.brand = brand;
+    }
+
+    @ExcelField(title="规格型号", align=2, sort=3)
+    public String getSpecifications() {
+        return specifications;
+    }
+
+    public void setSpecifications(String specifications) {
+        this.specifications = specifications;
+    }
+
+    @ExcelField(title="含税工程价(元)", align=2, sort=4)
+    public Double getProjectPriceIncludingTax() {
+        return projectPriceIncludingTax;
+    }
+
+    public void setProjectPriceIncludingTax(Double projectPriceIncludingTax) {
+        this.projectPriceIncludingTax = projectPriceIncludingTax;
+    }
+
+    @ExcelField(title="含税市场价(元)", align=2, sort=5)
+    public Double getMarketPriceIncludingTax() {
+        return marketPriceIncludingTax;
+    }
+
+    public void setMarketPriceIncludingTax(Double marketPriceIncludingTax) {
+        this.marketPriceIncludingTax = marketPriceIncludingTax;
+    }
+
+    @ExcelField(title="税率", align=2, sort=6)
+    public Double getTaxRate() {
+        return taxRate;
+    }
+
+    public void setTaxRate(Double taxRate) {
+        this.taxRate = taxRate;
+    }
+
+    @ExcelField(title="材料单位", align=2, sort=7)
     public String getUnit() {
         return unit;
     }
@@ -139,11 +211,106 @@ public class ProjectMaterialStorage extends DataEntity<ProjectMaterialStorage> {
         this.unit = unit;
     }
 
-    public List<ProjectMaterialStorageImport> getProjectMaterialStorageList() {
-        return projectMaterialStorageList;
+    @ExcelField(title="产品说明", align=2, sort=8)
+    public String getExplain() {
+        return explain;
     }
 
-    public void setProjectMaterialStorageList(List<ProjectMaterialStorageImport> projectMaterialStorageList) {
-        this.projectMaterialStorageList = projectMaterialStorageList;
+    public void setExplain(String explain) {
+        this.explain = explain;
+    }
+
+    @ExcelField(title="供应商", align=2, sort=9)
+    public String getSupplier() {
+        return supplier;
+    }
+
+    public void setSupplier(String supplier) {
+        this.supplier = supplier;
+    }
+
+    @Override
+    @ExcelField(title="备注", align=2, sort=10)
+    public String getRemarks() {
+        return remarks;
+    }
+
+    @Override
+    public void setRemarks(String remarks) {
+        this.remarks = remarks;
+    }
+
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @ExcelField(title="报价时间", align=2, sort=11)
+    public Date getQuotedPriceDate() {
+        return quotedPriceDate;
+    }
+
+    public void setQuotedPriceDate(Date quotedPriceDate) {
+        this.quotedPriceDate = quotedPriceDate;
+    }
+
+    public String getBeginProjectPriceIncludingTax() {
+        return beginProjectPriceIncludingTax;
+    }
+
+    public void setBeginProjectPriceIncludingTax(String beginProjectPriceIncludingTax) {
+        this.beginProjectPriceIncludingTax = beginProjectPriceIncludingTax;
+    }
+
+    public String getEndProjectPriceIncludingTax() {
+        return endProjectPriceIncludingTax;
+    }
+
+    public void setEndProjectPriceIncludingTax(String endProjectPriceIncludingTax) {
+        this.endProjectPriceIncludingTax = endProjectPriceIncludingTax;
+    }
+
+    public String getBeginMarketPriceIncludingTax() {
+        return beginMarketPriceIncludingTax;
+    }
+
+    public void setBeginMarketPriceIncludingTax(String beginMarketPriceIncludingTax) {
+        this.beginMarketPriceIncludingTax = beginMarketPriceIncludingTax;
+    }
+
+    public String getEndMarketPriceIncludingTax() {
+        return endMarketPriceIncludingTax;
+    }
+
+    public void setEndMarketPriceIncludingTax(String endMarketPriceIncludingTax) {
+        this.endMarketPriceIncludingTax = endMarketPriceIncludingTax;
+    }
+
+    public String getBeginTaxRate() {
+        return beginTaxRate;
+    }
+
+    public void setBeginTaxRate(String beginTaxRate) {
+        this.beginTaxRate = beginTaxRate;
+    }
+
+    public String getEndTaxRate() {
+        return endTaxRate;
+    }
+
+    public void setEndTaxRate(String endTaxRate) {
+        this.endTaxRate = endTaxRate;
+    }
+
+    public Date getBeginQuotedPriceDate() {
+        return beginQuotedPriceDate;
+    }
+
+    public void setBeginQuotedPriceDate(Date beginQuotedPriceDate) {
+        this.beginQuotedPriceDate = beginQuotedPriceDate;
+    }
+
+    public Date getEndQuotedPriceDate() {
+        return endQuotedPriceDate;
+    }
+
+    public void setEndQuotedPriceDate(Date endQuotedPriceDate) {
+        this.endQuotedPriceDate = endQuotedPriceDate;
     }
 }

+ 88 - 4
src/main/java/com/jeeplus/modules/projectmaterialstorage/entity/ProjectMaterialStorageImport.java

@@ -3,6 +3,8 @@ package com.jeeplus.modules.projectmaterialstorage.entity;
 import com.jeeplus.common.persistence.DataEntity;
 import com.jeeplus.modules.project.entity.Project;
 
+import java.util.Date;
+
 /**
  * @author: 徐滕
  * @version: 2022-07-04 17:16
@@ -13,13 +15,21 @@ public class ProjectMaterialStorageImport extends DataEntity<ProjectMaterialStor
     private static final long serialVersionUID = 7692590508200431879L;
     private String projectNumber;  //报告号
 
-    private Double price ; //材料价格
-
     private String materialName; //材料名称
+    private String brand; //品牌
+    private String specifications; //规格型号
+    private String unit; //单位
+    private Double projectPriceIncludingTax; //含税工程价(元)
+    private Double marketPriceIncludingTax; //含税市场价(元)
+    private Double taxRate; //税率
+    private String explain; //产品说明
+    private String supplier; //供应商
+    private String remarks; //备注
+    private Date quotedPriceDate; //报价时间
 
-    private Project project;  //项目
+    private Double price ; //材料价格
 
-    private String unit; //单位
+    private Project project;  //项目
 
     public String getProjectNumber() {
         return projectNumber;
@@ -60,4 +70,78 @@ public class ProjectMaterialStorageImport extends DataEntity<ProjectMaterialStor
     public void setUnit(String unit) {
         this.unit = unit;
     }
+
+    public String getBrand() {
+        return brand;
+    }
+
+    public void setBrand(String brand) {
+        this.brand = brand;
+    }
+
+    public String getSpecifications() {
+        return specifications;
+    }
+
+    public void setSpecifications(String specifications) {
+        this.specifications = specifications;
+    }
+
+    public Double getProjectPriceIncludingTax() {
+        return projectPriceIncludingTax;
+    }
+
+    public void setProjectPriceIncludingTax(Double projectPriceIncludingTax) {
+        this.projectPriceIncludingTax = projectPriceIncludingTax;
+    }
+
+    public Double getMarketPriceIncludingTax() {
+        return marketPriceIncludingTax;
+    }
+
+    public void setMarketPriceIncludingTax(Double marketPriceIncludingTax) {
+        this.marketPriceIncludingTax = marketPriceIncludingTax;
+    }
+
+    public Double getTaxRate() {
+        return taxRate;
+    }
+
+    public void setTaxRate(Double taxRate) {
+        this.taxRate = taxRate;
+    }
+
+    public String getExplain() {
+        return explain;
+    }
+
+    public void setExplain(String explain) {
+        this.explain = explain;
+    }
+
+    public String getSupplier() {
+        return supplier;
+    }
+
+    public void setSupplier(String supplier) {
+        this.supplier = supplier;
+    }
+
+    @Override
+    public String getRemarks() {
+        return remarks;
+    }
+
+    @Override
+    public void setRemarks(String remarks) {
+        this.remarks = remarks;
+    }
+
+    public Date getQuotedPriceDate() {
+        return quotedPriceDate;
+    }
+
+    public void setQuotedPriceDate(Date quotedPriceDate) {
+        this.quotedPriceDate = quotedPriceDate;
+    }
 }

+ 19 - 2
src/main/java/com/jeeplus/modules/projectmaterialstorage/service/ProjectMaterialStorageService.java

@@ -79,9 +79,9 @@ public class ProjectMaterialStorageService extends CrudService<ProjectMaterialSt
         for (ProjectMaterialStorageImport projectMaterialStorageImport: projectMaterialStorageImports){
             StringBuilder stringBuilder2 = new StringBuilder();
             String str = new String();
-            str = projectMaterialStorageImport.getMaterialName()+projectMaterialStorageImport.getPrice()+projectMaterialStorageImport.getUnit();
+            str = projectMaterialStorageImport.getMaterialName()+projectMaterialStorageImport.getSpecifications()+projectMaterialStorageImport.getUnit();
             list.add(str);
-            stringBuilder2.append(projectMaterialStorageImport.getMaterialName()).append(projectMaterialStorageImport.getPrice())
+            stringBuilder2.append(projectMaterialStorageImport.getMaterialName()).append(projectMaterialStorageImport.getSpecifications())
                     .append(projectMaterialStorageImport.getUnit());
             set.add(str);
             i++;
@@ -198,4 +198,21 @@ public class ProjectMaterialStorageService extends CrudService<ProjectMaterialSt
         return page;
     }
 
+    /**
+     * 多条数据删除
+     * @param idList
+     */
+    @Transactional(readOnly = false)
+    public void deleteListById(List<String> idList){
+        dao.deleteListById(idList);
+    }
+
+    /**
+     * 根据id查询信息
+     * @param idList
+     */
+    public List<ProjectMaterialStorage> getByIdList(List<String> idList){
+        return dao.getByIdList(idList,UserUtils.getUser().getId());
+    }
+
 }

+ 100 - 14
src/main/java/com/jeeplus/modules/projectmaterialstorage/web/ProjectMaterialStorageController.java

@@ -1,5 +1,6 @@
 package com.jeeplus.modules.projectmaterialstorage.web;
 
+import com.google.common.collect.Lists;
 import com.jeeplus.common.config.Global;
 import com.jeeplus.common.persistence.Page;
 import com.jeeplus.common.utils.MyBeanUtils;
@@ -29,10 +30,7 @@ import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 import java.io.UnsupportedEncodingException;
 import java.net.URLDecoder;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
+import java.util.*;
 
 
 @Controller
@@ -98,7 +96,7 @@ public class ProjectMaterialStorageController extends BaseController {
         Iterator<ProjectMaterialStorageImport> iterator = projectMaterialStorageList2.iterator();
         while (iterator.hasNext()){
            ProjectMaterialStorageImport projectMaterialStorageImport = iterator.next();
-            if(projectMaterialStorageImport.getPrice() == null || projectMaterialStorageImport.getMaterialName() == null || projectMaterialStorageImport.getUnit()== null || "1".equals(projectMaterialStorageImport.getDelFlag())){
+            if(projectMaterialStorageImport.getSpecifications() == null || projectMaterialStorageImport.getMaterialName() == null || projectMaterialStorageImport.getUnit()== null || "1".equals(projectMaterialStorageImport.getDelFlag())){
                 iterator.remove();
             }else {
                 projectMaterialStorageList.add(projectMaterialStorageImport);
@@ -108,8 +106,8 @@ public class ProjectMaterialStorageController extends BaseController {
             projectMaterialStorageList.get(k).setProjectNumber(projectMaterialStorage.getProjectNumber());
             projectMaterialStorageList.get(k).setIsNewRecord(true);
             //       判断项目名称、材料名称、价格是否为空
-            if(projectMaterialStorageList.get(k).getProjectNumber()==null || projectMaterialStorageList.get(k).getMaterialName() ==null || projectMaterialStorageList.get(k).getPrice() == null ){
-                addMessage(redirectAttributes, "第"+i+"个项目名称、材料名称、价格等获取失败,请重试");
+            if(projectMaterialStorageList.get(k).getProjectNumber()==null || projectMaterialStorageList.get(k).getMaterialName() ==null || projectMaterialStorageList.get(k).getSpecifications() == null || projectMaterialStorageList.get(k).getUnit()== null){
+                addMessage(redirectAttributes, "第"+i+"个项目名称、材料名称、规格型号、单位等获取失败,请重试");
                 if("1".equals(pageId)){
                     return "redirect:"+Global.getAdminPath()+"/ruralProject/ruralProjectMessageAll/?repage";
                 }
@@ -138,6 +136,60 @@ public class ProjectMaterialStorageController extends BaseController {
 
 
     /**
+     * 材料库新增保存功能
+     * @param projectMaterialStorage
+     * @param model
+     * @param redirectAttributes
+     * @return
+     * @throws Exception
+     */
+    @RequestMapping(value = "storageSave")
+    public String storageSave(ProjectMaterialStorage projectMaterialStorage, Model model, RedirectAttributes redirectAttributes) throws Exception {
+        int i = 1;
+        List<ProjectMaterialStorageImport> projectMaterialStorageList = new ArrayList<ProjectMaterialStorageImport>();
+        List<ProjectMaterialStorageImport> projectMaterialStorageList2 = projectMaterialStorage.getProjectMaterialStorageList();
+
+        if(null == projectMaterialStorageList2 || projectMaterialStorageList2.size() == 0 ){
+            addMessage(redirectAttributes, "请填写材料信息");
+            return "redirect:"+Global.getAdminPath()+"/project/projectMaterialStorage/?repage";
+        }
+//        此处需要修改为迭代器形式
+        Iterator<ProjectMaterialStorageImport> iterator = projectMaterialStorageList2.iterator();
+        while (iterator.hasNext()){
+            ProjectMaterialStorageImport projectMaterialStorageImport = iterator.next();
+            if(projectMaterialStorageImport.getSpecifications() == null || projectMaterialStorageImport.getMaterialName() == null || projectMaterialStorageImport.getUnit()== null || "1".equals(projectMaterialStorageImport.getDelFlag())){
+                iterator.remove();
+            }else {
+                projectMaterialStorageList.add(projectMaterialStorageImport);
+            }
+        }
+        for(int k=0;k<projectMaterialStorageList.size();k++){
+            projectMaterialStorageList.get(k).setProjectNumber(projectMaterialStorage.getProjectId());
+            projectMaterialStorageList.get(k).setIsNewRecord(true);
+            //       判断项目名称、材料名称、价格是否为空
+            if(projectMaterialStorageList.get(k).getMaterialName() ==null || projectMaterialStorageList.get(k).getSpecifications() == null || projectMaterialStorageList.get(k).getUnit()== null){
+                addMessage(redirectAttributes, "第"+i+"个材料名称、规格型号、单位等获取失败,请重试");
+                return "redirect:"+Global.getAdminPath()+"/project/projectMaterialStorage/?repage";
+            }
+        }
+        Map map = projectMaterialStorageService.qureyCountAboutProjectMaterialStorage(projectMaterialStorageList);
+        if((map.containsKey("failure"))){
+            addMessage(redirectAttributes, map.get("failure").toString());
+            return "redirect:"+Global.getAdminPath()+"/project/projectMaterialStorage/?repage";
+        }
+
+        projectMaterialStorageService.batchSave(projectMaterialStorageList);
+        if(StringUtils.isNotBlank(projectMaterialStorage.getProjectId())){
+            RuralProjectRecords ruralProjectRecords = ruralProjectRecordsService.get(projectMaterialStorage.getProjectId());
+            //修改2代表已处理
+            ruralProjectRecords.setprojectMaterialStorageStatus("2");
+            projectMaterialStorageService.modifyProjectMaterialStorageStatus(ruralProjectRecords);
+        }
+        return "redirect:"+Global.getAdminPath()+"/project/projectMaterialStorage/?repage";
+    }
+
+
+    /**
      * 修改材料库
      */
     @RequestMapping(value = "Update")
@@ -220,7 +272,7 @@ public class ProjectMaterialStorageController extends BaseController {
             List<ProjectMaterialStorage> list = ei.getDataList(ProjectMaterialStorage.class);
             List<ProjectMaterialStorage> listAll = new ArrayList<>();
             for (ProjectMaterialStorage materialStorage : list) {
-                if(StringUtils.isNotBlank(materialStorage.getMaterialName()) && null != materialStorage.getPrice()  && null != materialStorage.getUnit() ){
+                if(StringUtils.isNotBlank(materialStorage.getMaterialName()) && null != materialStorage.getSpecifications()  && null != materialStorage.getUnit() ){
                     listAll.add(materialStorage);
                 }
             }
@@ -262,9 +314,7 @@ public class ProjectMaterialStorageController extends BaseController {
            projectMaterialStorage2  = projectMaterialStorageService.get(projectMaterialStorage.getId());
         }else{
             model.addAttribute("isAdd",isAdd);
-//            model.addAttribute("projectMaterialStorage", projectMaterialStorage2);
-//            addMessage(redirectAttributes, "参数获取失败,请联系管理员");
-            return "modules/projectMaterialStorage/projectMaterialStorageTwoForm";
+            return "modules/projectMaterialStorage/projectMaterialStorageAddForm";
         }
         if(StringUtils.isNotBlank(projectMaterialStorage.getProjectNumber())){
 
@@ -383,13 +433,49 @@ public class ProjectMaterialStorageController extends BaseController {
             addMessage(redirectAttributes, returnMap.get("message").toString());
             return "redirect:"+Global.getAdminPath()+"/project/projectMaterialStorage/?repage";
         }
-        RuralProjectRecords ruralProjectRecords = ruralProjectRecordsService.get(projectMaterialStorage.getProjectNumber());
+        if(StringUtils.isNotBlank(projectMaterialStorage.getProjectNumber())){
+            RuralProjectRecords ruralProjectRecords = ruralProjectRecordsService.get(projectMaterialStorage.getProjectNumber());
 //           修改2代表已处理
-        ruralProjectRecords.setprojectMaterialStorageStatus("2");
+            ruralProjectRecords.setprojectMaterialStorageStatus("2");
 
-        projectMaterialStorageService.modifyProjectMaterialStorageStatus(ruralProjectRecords);
+            projectMaterialStorageService.modifyProjectMaterialStorageStatus(ruralProjectRecords);
+        }
         return "redirect:"+Global.getAdminPath()+"/project/projectMaterialStorage";
     }
 
+    /**
+     * 批量删除
+     * @param listId
+     * @return
+     */
+    @RequestMapping(value = "deleteAll")
+    @ResponseBody
+    public Object deleteAll(String listId){
+        Map<String,Object> map = new HashMap<>();
+        try{
+            List<String> idList = Arrays.asList(listId.split(","));
+            List<ProjectMaterialStorage> byIdList = Lists.newArrayList();
+            //根据id查询自己创建的材料信息数量
+            if(!UserUtils.getUser().isAdmin()){
+                byIdList = projectMaterialStorageService.getByIdList(idList);
+                if(byIdList.size() < idList.size()){
+                    map.put("success",false);
+                    map.put("str","删除的材料信息保存不属于您创建的信息。请确认后重新删除");
+                }else{
+                    projectMaterialStorageService.deleteListById(idList);
+                    map.put("success",true);
+                    map.put("str","材料信息删除成功");
+                }
+            }else{
+                projectMaterialStorageService.deleteListById(idList);
+                map.put("success",true);
+                map.put("str","材料信息删除成功");
+            }
+        }catch (Exception e){
+            map.put("success",false);
+            map.put("str","删除失败");
+        }
+        return map;
+    }
 
 }

+ 2 - 2
src/main/java/com/jeeplus/modules/projectrecord/service/ProjectPlanService.java

@@ -135,9 +135,9 @@ public class ProjectPlanService extends CrudService<ProjectPlanDao, ProjectPlanI
         Date startDate=null;
         Date endDate=null;
         if (projectRecords.getStartDate()!=null){
-            startDate=new Date(projectRecords.getStartDate().toString());
+            startDate=projectRecords.getStartDate();
         }else if (projectRecords.getEndingDate()!=null){
-            endDate=new Date(projectRecords.getEndingDate().toString());
+            endDate=projectRecords.getEndingDate();
         }
         RuralProjectRecords ruralProjectRecords=new RuralProjectRecords();
         ruralProjectRecords.setId(projectRecords.getId());

+ 2 - 2
src/main/java/com/jeeplus/modules/projectrecord/web/ProjectPlanCostController.java

@@ -169,10 +169,10 @@ public class ProjectPlanCostController extends BaseController {
                     if (projectRecords.getStartDate()!=null && projectRecords.getEndingDate() !=null){
                         DateFormat format = new SimpleDateFormat("yyyy-MM-dd");//日期格式
                         if (i==0){
-                            Date date=new Date(projectRecords.getStartDate().toString());
+                            Date date=projectRecords.getStartDate();
                             projectPlan.setBeginDate(format.format(date).toString());
                         }else if((i+1)==mainDictList.size()){
-                            Date date=new Date(projectRecords.getEndingDate().toString());
+                            Date date=projectRecords.getEndingDate();
                             projectPlan.setEndDate(format.format(date).toString());
                         }
                     }

+ 7 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/dao/RuralProjectRecordReportDao.java

@@ -42,4 +42,11 @@ public interface RuralProjectRecordReportDao extends CrudDao<RuralProjectRecordR
      * @return
      */
     List<RuralProjectRecordReportInfo> findPageHome(RuralProjectRecordReportInfo ruralProjectRecordReportInfo);
+
+    /**
+     * 查询负责或登记的项目数量
+     * @param ruralProjectRecordReportInfo
+     * @return
+     */
+    long findPageHomeCount(RuralProjectRecordReportInfo ruralProjectRecordReportInfo);
 }

+ 1 - 1
src/main/java/com/jeeplus/modules/ruralprojectrecords/dao/RuralProjectRecordsDao.java

@@ -412,7 +412,7 @@ public interface RuralProjectRecordsDao extends CrudDao<RuralProjectRecords> {
     List<RuralProjectRecords> selectProjectReportDataList(@Param("ruralProjectRecords") RuralProjectRecords ruralProjectRecords, @Param("statementCompanyComprehensiveInfo")StatementCompanyComprehensiveInfo statementCompanyComprehensiveInfo,@Param("beginDate")String beginDate,@Param("endDate") String endDate);
 
     //公司级 查询项目超期信息的总条数(发送张静)
-    Integer selectProjectReportDataCount(StatementCompanyComprehensiveInfo statementCompanyComprehensiveInfo);
+    Integer selectProjectReportDataCount(@Param("ruralProjectRecords") RuralProjectRecords ruralProjectRecords, @Param("statementCompanyComprehensiveInfo")StatementCompanyComprehensiveInfo statementCompanyComprehensiveInfo,@Param("beginDate")String beginDate,@Param("endDate") String endDate);
 
     //公司级 查询项目报表(发送张静)
     List<RuralProjectRecords> selectReportZJPage(@Param("ruralProjectRecords") RuralProjectRecords ruralProjectRecords,@Param("officeId") String officeId,@Param("projectPaperFiling")String projectPaperFiling,@Param("beginDate")String beginDate,@Param("endDate") String endDate,@Param("recordState")String recordState,@Param("projectFlingBatchRelation")String projectFlingBatchRelation);

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

@@ -239,8 +239,8 @@ public class RuralProjectMessageAllService extends CrudService<RuralProjectMessa
 
         //查询负责人信息
         for (RuralProjectRecords records : recordsList) {
-            if(null != records.getRecordState() && 0 == records.getProjectReportRecordStatus()){
-                records.setProjectReportRecordStatus(records.getRecordState());
+            if(null != records.getProjectRecordStatus() && 0 == records.getProjectReportRecordStatus()){
+                records.setProjectReportRecordStatus(records.getProjectRecordStatus());
             }
             /*this.queryContractInfos(records);*/
             //获取项目负责人

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

@@ -317,8 +317,8 @@ public class RuralProjectMessageService extends CrudService<RuralProjectMessageD
 
         //查询负责人信息
         for (RuralProjectRecords records : recordsList) {
-            if(null != records.getRecordState() && 0 == records.getProjectReportRecordStatus()){
-                records.setProjectReportRecordStatus(records.getRecordState());
+            if(null != records.getProjectRecordStatus() && 0 == records.getProjectReportRecordStatus()){
+                records.setProjectReportRecordStatus(records.getProjectRecordStatus());
             }
             /*this.queryContractInfos(records);*/
             //获取项目负责人

+ 1 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectRecordReportService.java

@@ -135,6 +135,7 @@ public class RuralProjectRecordReportService extends CrudService<RuralProjectRec
         typeList.add("1");  //项目咨询
         typeList.add("2");  //造价审核
         ruralProjectRecordReportInfo.setTypeList(typeList);
+        page.setCount(dao.findPageHomeCount(ruralProjectRecordReportInfo));
         page.setList(dao.findPageHome(ruralProjectRecordReportInfo));
         return page;
     }

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

@@ -4969,7 +4969,7 @@ public class RuralProjectRecordsService extends CrudService<RuralProjectRecordsD
 		}
 		projectRecords.setPage(page);
 		List<RuralProjectRecords> recordsList = dao.selectProjectReportDataList(projectRecords,statementCompanyComprehensiveInfo,beginDate,endDate);
-		int count = dao.selectProjectReportDataCount(statementCompanyComprehensiveInfo);
+		int count = dao.selectProjectReportDataCount(projectRecords,statementCompanyComprehensiveInfo,beginDate,endDate);
 		page.setPageNo(oldPageNo);
 		page.setCount(count);
 		page.setCountFlag(false);

+ 8 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectRecordsController.java

@@ -118,6 +118,14 @@ public class RuralProjectRecordsController extends BaseController {
 		return entity;
 	}
 
+
+
+	@RequestMapping("get")
+	@ResponseBody
+	public RuralProjectRecords get(RuralProjectRecords  projectRecords){
+		return  projectRecords;
+	}
+
 	/**
 	 * 项目列表页面
 	 */

+ 2 - 2
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectSignatureOldMessageDisposeController.java

@@ -261,12 +261,12 @@ public class RuralProjectSignatureOldMessageDisposeController extends BaseContro
     @Transactional(readOnly = false)
     public Map<String,Object> projectReportedListByAdvent(){
         Map<String,Object> map = new HashMap<>();
-        /*logger.info("-----------项目超期未上报定时任务开始------------------");
+        logger.info("-----------项目超期未上报定时任务开始------------------");
         projectRecordsService.saveProjectReportedListByAdvent();
         logger.info("------------项目超期未上报定时任务结束------------------");
         logger.info("-----------项目超期未归档定时任务开始(电子归档)------------------");
         projectRecordsService.saveProjectRecordListByAdvent();
-        logger.info("------------项目超期未归档定时任务结束(电子归档)------------------");*/
+        logger.info("------------项目超期未归档定时任务结束(电子归档)------------------");
         logger.info("------------项目超期未质量符合定时任务开始--------------------");
         projectRecordsService.getJudgeAdvanceWeekNotice();
         logger.info("------------项目超期未质量符合定时任务结束--------------------");

+ 1 - 0
src/main/java/com/jeeplus/modules/statement/controller/StatementCompanyComprehensiveController.java

@@ -243,6 +243,7 @@ public class StatementCompanyComprehensiveController extends BaseController {
         model.addAttribute("field6",statementCompanyComprehensiveInfo.getField6());
         model.addAttribute("field7",statementCompanyComprehensiveInfo.getField7());
         model.addAttribute("field8",statementCompanyComprehensiveInfo.getField8());
+        model.addAttribute("field9",statementCompanyComprehensiveInfo.getField9());
 
         //这个是我删除的有需要可以补回,但是得注意projectRecords的submitmoney值
         //进行查询之后进行任何操作,返回还是查询之后的数据页面

+ 50 - 1
src/main/java/com/jeeplus/modules/statement/entity/StatementCompanyComprehensiveInfo.java

@@ -26,7 +26,12 @@ public class StatementCompanyComprehensiveInfo extends DataEntity<StatementCompa
     private String field6;          //可变字段6(项目:电子归档超期已归档)
 
     private String field7;          //可变字段7(项目:电子归档超期未上报)
-    private String field8;          //可变字段8(项目:电子归档超期已上报)
+    private String field8;          //可变字段8(项目:电子归档超期已上报;项目:超期未上报(张静))
+
+    private String field9;          //可变字段9(项目:超期已上报(张静))
+    private String field10;          //可变字段9(项目:超期已上报(张静))
+    private String field11;          //可变字段9(项目:超期已上报(张静))
+    private String field12;          //可变字段9(项目:超期已上报(张静))
     private String userName;        //用户名称
 
     public String getYear() {
@@ -173,6 +178,50 @@ public class StatementCompanyComprehensiveInfo extends DataEntity<StatementCompa
         this.field8 = field8;
     }
 
+    public String getField9() {
+        if("".equals(field9)||field9==null){
+            return "0";
+        }
+        return field9;
+    }
+
+    public void setField9(String field9) {
+        this.field9 = field9;
+    }
+
+    public String getField10() {
+        if("".equals(field10)||field10==null){
+            return "0";
+        }
+        return field10;
+    }
+
+    public void setField10(String field10) {
+        this.field10 = field10;
+    }
+
+    public String getField11() {
+        if("".equals(field11)||field11==null){
+            return "0";
+        }
+        return field11;
+    }
+
+    public void setField11(String field11) {
+        this.field11 = field11;
+    }
+
+    public String getField12() {
+        if("".equals(field12)||field12==null){
+            return "0";
+        }
+        return field12;
+    }
+
+    public void setField12(String field12) {
+        this.field12 = field12;
+    }
+
     public String getOfficeParentIds() {
         return officeParentIds;
     }

+ 20 - 2
src/main/java/com/jeeplus/modules/statement/entity/StatementDataInfo.java

@@ -18,8 +18,10 @@ public class StatementDataInfo extends DataEntity<StatementDataInfo> {
     private String officeId;        //部门id
     private String field1;          //可变字段1(项目:电子归档(超期未归档);合同:纸质归档(超期未归档))
     private String field2;          //可变字段2(项目:电子归档(超期归档);合同:纸质归档(超期归档))
-    private String field3;          //可变字段3(项目:上报(超期未上报))
-    private String field4;          //可变字段4(项目:上报(超期上报))
+    private String field3;          //可变字段3(项目:上报(超期未上报);张静(未质量符合))
+    private String field4;          //可变字段4(项目:上报(超期上报);张静(超期未质量符合))
+    private String field5;          //可变字段5(项目:上报(超期未上报)(张静))
+    private String field6;          //可变字段6(项目:上报(超期上报)(张静))
     private String userId;          //用户id
     private String officeParentIds; //部门parentIds
 
@@ -119,6 +121,22 @@ public class StatementDataInfo extends DataEntity<StatementDataInfo> {
         this.field4 = field4;
     }
 
+    public String getField5() {
+        return field5;
+    }
+
+    public void setField5(String field5) {
+        this.field5 = field5;
+    }
+
+    public String getField6() {
+        return field6;
+    }
+
+    public void setField6(String field6) {
+        this.field6 = field6;
+    }
+
     public String getUserId() {
         return userId;
     }

+ 197 - 2
src/main/java/com/jeeplus/modules/statement/service/StatementCompanyComprehensiveService.java

@@ -396,6 +396,12 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
         //查询项目超期未质量符合(超60天)信息
         List<ReportDataEntity> getOverDueProjectReportDataList = dao.getOverDueProjectReportDataList();
 
+        //超期未上报
+        List<ReportDataEntity> overDueNotReportedProjectIdListAll = dao.getOverDueNotReportedProjectAll();
+        //超期上报
+        List<ReportDataEntity> overDueReportedProjectIdListAll = dao.getOverDueReportedProjectAll(beginDate, endDate);
+
+
         //查询电子归档超期未归档项目数量(分组)
         Map<String, List<ReportDataEntity>> overDueNotRecordProjectIdListAllMap = dataMessageDispose(overDueNotRecordProjectIdListAll);
         //分组
@@ -406,6 +412,10 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
         //查询项目超期未质量符合(超60天)信息分组
         Map<String, List<ReportDataEntity>> getOverDueProjectReportDataListMap = dataMessageDispose(getOverDueProjectReportDataList);
 
+        //分组(超期未上报)
+        Map<String, List<ReportDataEntity>> overDueNotReportedProjectIdListAllMap = dataMessageDispose(overDueNotReportedProjectIdListAll);
+        //分组(超期上报)
+        Map<String, List<ReportDataEntity>> overDueReportedProjectIdListAllMap = dataMessageDispose(overDueReportedProjectIdListAll);
 
         //查询部门信息
         List<Office> officeList = dao.getOfficeListInfo();
@@ -582,6 +592,76 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
                 dao.insertStatementReportDataInfo(overDueProjectReportDataList);
             }
 
+            //查询上报超期未上报项目数量(保存到数据库)
+            //List<String> overDueNotReportedProjectIdList = dao.getOverDueNotReportedProject(officeInfo.getId());
+            List<ReportDataEntity> overDueNotReportedProjectListAll = Lists.newArrayList();
+            for (String key : overDueNotReportedProjectIdListAllMap.keySet()) {
+                if(officeInfo.getId().equals(key) || key.contains(officeInfo.getId())){
+                    List<ReportDataEntity> reportDataEntities = overDueNotReportedProjectIdListAllMap.get(key);
+                    overDueNotReportedProjectListAll.addAll(reportDataEntities);
+                    comprehensiveInfo.setField8(String.valueOf(Integer.parseInt(comprehensiveInfo.getField7()) + reportDataEntities.size()));
+                }
+
+            }
+
+            //comprehensiveInfo.setField8(String.valueOf(overDueNotReportedProjectIdListAll.size()));
+            List<StatementDataInfo> overDueNotReportedProjectList = Lists.newArrayList();
+            for (ReportDataEntity peportDataEntity : overDueNotReportedProjectListAll) {
+                String projectId = peportDataEntity.getFieldId();
+                StatementDataInfo info = new StatementDataInfo();
+                info.setStatementDate(statementDate);
+                info.setGradeType("1");
+                info.setType("1");
+                info.setYear(String.valueOf(year));
+                info.setBigDateType(bigDateType.toString());
+                info.setSmallDateType(smallDateType.toString());
+                info.setOfficeId(officeInfo.getId());
+                info.setField5(projectId);
+                overDueNotReportedProjectList.add(info);
+            }
+            if(overDueNotReportedProjectList.size()>0){
+                //每次删除之前存的数据
+                for (StatementDataInfo statementDataInfo: overDueNotReportedProjectList) {
+                    dao.deleteStatementReportDataInfo(statementDataInfo);
+                }
+                dao.insertStatementReportDataInfo(overDueNotReportedProjectList);
+            }
+            //查询上报超期上报项目数量(保存到数据库)
+            //List<String> overDueReportedProjectIdList = dao.getOverDueReportedProject(officeInfo.getId(), beginDate, endDate);
+            List<ReportDataEntity> overDueReportedProjectListAll = Lists.newArrayList();
+            for (String key : overDueReportedProjectIdListAllMap.keySet()) {
+                if(officeInfo.getId().equals(key) || key.contains(officeInfo.getId())){
+                    List<ReportDataEntity> reportDataEntities = overDueReportedProjectIdListAllMap.get(key);
+                    overDueReportedProjectListAll.addAll(reportDataEntities);
+                    comprehensiveInfo.setField9(String.valueOf(Integer.parseInt(comprehensiveInfo.getField8()) + reportDataEntities.size()));
+                }
+
+            }
+
+            //comprehensiveInfo.setField9(String.valueOf(overDueReportedProjectIdList.size()));
+            List<StatementDataInfo> overDueReportedProjectList = Lists.newArrayList();
+            for (ReportDataEntity peportDataEntity : overDueReportedProjectListAll) {
+                String projectId = peportDataEntity.getFieldId();
+                StatementDataInfo info = new StatementDataInfo();
+                info.setStatementDate(statementDate);
+                info.setGradeType("1");
+                info.setType("1");
+                info.setYear(String.valueOf(year));
+                info.setBigDateType(bigDateType.toString());
+                info.setSmallDateType(smallDateType.toString());
+                info.setOfficeId(officeInfo.getId());
+                info.setField6(projectId);
+                overDueReportedProjectList.add(info);
+            }
+            if(overDueReportedProjectList.size()>0){
+                //每次删除之前存的数据
+                for (StatementDataInfo statementDataInfo: overDueReportedProjectList) {
+                    dao.deleteStatementReportDataInfo(statementDataInfo);
+                }
+                dao.insertStatementReportDataInfo(overDueReportedProjectList);
+            }
+
+
             //数据处理并保存到数据库中
             comprehensiveInfo.preInsert();
             //每次都要删除之前的数据
@@ -751,16 +831,31 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
         //查询新增A类项目数量
         List<ReportDataEntity> projectCountByAAll = dao.getInsertProjectCountByGradeAll( "2", beginDate, endDate);
         List<ReportDataEntity> projectCountByBAll = dao.getInsertProjectCountByGradeAll( "1", beginDate, endDate);
+        //本月电子归档
         List<ReportDataEntity> getProjectCountByRecordAll = dao.getProjectCountByRecordAll(beginDate, endDate);
         List<ReportDataEntity> getProjectCountByReportedAll = dao.getProjectCountByReportedAll(beginDate, endDate);
-        //超期未归档
+        //电子归档超期未归档
         List<ReportDataEntity> overDueNotRecordProjectIdListAll = dao.getOverDueNotRecordProjectAll();
-        //超期归档
+        //电子归档超期归档
         List<ReportDataEntity> overDueRecordProjectIdListAll = dao.getOverDueRecordProjectAll(beginDate, endDate);
         //超期未上报
         List<ReportDataEntity> overDueNotReportedProjectIdListAll = dao.getOverDueNotReportedProjectAll();
         //超期上报
         List<ReportDataEntity> overDueReportedProjectIdListAll = dao.getOverDueReportedProjectAll(beginDate, endDate);
+
+
+        //查询A类项目纸质归档信息
+        List<ReportDataEntity> getProjectPaperFilingList = dao.getProjectPaperFilingList(beginDate, endDate);
+        //查询B类项目批量归档信息
+        List<ReportDataEntity> getProjectFlingBatchRelationList = dao.getProjectFlingBatchRelationList(beginDate, endDate);
+
+        //查询项目未质量符合信息
+        List<ReportDataEntity> getProjectReportDataList = dao.getProjectReportDataList();
+        //查询项目超期未质量符合(超60天)信息
+        List<ReportDataEntity> getOverDueProjectReportDataList = dao.getOverDueProjectReportDataList();
+
+
+
         //查询电子归档超期未归档项目数量(分组)
         Map<String, List<ReportDataEntity>> overDueNotRecordProjectIdListAllMap = dataMessageDispose(overDueNotRecordProjectIdListAll);
         //分组
@@ -770,6 +865,12 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
         //分组
         Map<String, List<ReportDataEntity>> overDueReportedProjectIdListAllMap = dataMessageDispose(overDueReportedProjectIdListAll);
 
+        //查询项目未质量符合信息(分组)
+        Map<String, List<ReportDataEntity>> getProjectReportDataListMap = dataMessageDispose(getProjectReportDataList);
+        //查询项目超期未质量符合(超60天)信息分组
+        Map<String, List<ReportDataEntity>> getOverDueProjectReportDataListMap = dataMessageDispose(getOverDueProjectReportDataList);
+
+
         //查询部门信息
         List<Office> officeList = dao.getOfficeListInfo();
         for (Office officeInfo : officeList) {
@@ -952,6 +1053,94 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
                 dao.insertStatementDataInfo(overDueReportedProjectList);
             }
 
+
+
+            //遍历添加A类项目纸质归档信息
+            for (ReportDataEntity reportData: getProjectPaperFilingList) {
+                if(officeInfo.getId().equals(reportData.getOfficeId()) || reportData.getOfficeParentIds().contains(officeInfo.getId())){
+                    comprehensiveInfo.setField9(String.valueOf(Integer.parseInt(comprehensiveInfo.getField9()) + reportData.getCount()));
+                }
+            }
+            //遍历添加A类项目纸质归档信息
+            for (ReportDataEntity reportData: getProjectFlingBatchRelationList) {
+                if(officeInfo.getId().equals(reportData.getOfficeId()) || reportData.getOfficeParentIds().contains(officeInfo.getId())){
+                    comprehensiveInfo.setField10(String.valueOf(Integer.parseInt(comprehensiveInfo.getField10()) + reportData.getCount()));
+                }
+            }
+
+
+            //查询项目未质量符合信息(保存到数据库)
+            List<ReportDataEntity> getProjectReportDataListAll = Lists.newArrayList();
+            for (String key : getProjectReportDataListMap.keySet()) {
+                if(officeInfo.getId().equals(key) || key.contains(officeInfo.getId())){
+                    List<ReportDataEntity> reportDataEntities = getProjectReportDataListMap.get(key);
+                    if(null != reportDataEntities) {
+                        getProjectReportDataListAll.addAll(reportDataEntities);
+                        comprehensiveInfo.setField11(String.valueOf(Integer.parseInt(comprehensiveInfo.getField11()) + reportDataEntities.size()));
+                    }
+                }
+
+            }
+
+            List<StatementDataInfo> projectReportDataProjectList = Lists.newArrayList();
+            for (ReportDataEntity peportDataEntity : getProjectReportDataListAll) {
+                String projectId = peportDataEntity.getFieldId();
+                StatementDataInfo info = new StatementDataInfo();
+                info.setStatementDate(statementDate);
+                info.setGradeType("1");
+                info.setType("1");
+                info.setYear(String.valueOf(year));
+                info.setBigDateType(bigDateType.toString());
+                info.setSmallDateType(smallDateType.toString());
+                info.setOfficeId(officeInfo.getId());
+                info.setField5(projectId);
+                projectReportDataProjectList.add(info);
+            }
+            if(projectReportDataProjectList.size()>0){
+                //每次删除之前存的数据
+                for (StatementDataInfo statementDataInfo: projectReportDataProjectList) {
+                    dao.deleteStatementDataInfo(statementDataInfo);
+                }
+                dao.insertStatementDataInfo(projectReportDataProjectList);
+            }
+
+
+            //查询项目未质量符合信息(保存到数据库)
+            List<ReportDataEntity> getOverDueProjectReportDataListAll = Lists.newArrayList();
+            for (String key : getProjectReportDataListMap.keySet()) {
+                if(officeInfo.getId().equals(key) || key.contains(officeInfo.getId())){
+                    List<ReportDataEntity> reportDataEntities = getOverDueProjectReportDataListMap.get(key);
+                    if(null != reportDataEntities){
+                        getOverDueProjectReportDataListAll.addAll(reportDataEntities);
+                        comprehensiveInfo.setField12(String.valueOf(Integer.parseInt(comprehensiveInfo.getField12()) + reportDataEntities.size()));
+                    }
+                }
+
+            }
+
+            List<StatementDataInfo> overDueProjectReportDataList = Lists.newArrayList();
+            for (ReportDataEntity peportDataEntity : getOverDueProjectReportDataListAll) {
+                String projectId = peportDataEntity.getFieldId();
+                StatementDataInfo info = new StatementDataInfo();
+                info.setStatementDate(statementDate);
+                info.setGradeType("1");
+                info.setType("1");
+                info.setYear(String.valueOf(year));
+                info.setBigDateType(bigDateType.toString());
+                info.setSmallDateType(smallDateType.toString());
+                info.setOfficeId(officeInfo.getId());
+                info.setField6(projectId);
+                overDueProjectReportDataList.add(info);
+            }
+            if(overDueProjectReportDataList.size()>0){
+                //每次删除之前存的数据
+                for (StatementDataInfo statementDataInfo: overDueProjectReportDataList) {
+                    dao.deleteStatementDataInfo(statementDataInfo);
+                }
+                dao.insertStatementDataInfo(overDueProjectReportDataList);
+            }
+
+
             //数据处理并保存到数据库中
             comprehensiveInfo.preInsert();
             //每次都要删除之前的数据
@@ -2830,6 +3019,8 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
         String xmnum5 = "0";
         String xmnum6 = "0";
         String xmnum7 = "0";
+        String xmnum8 = "0";
+        String xmnum9 = "0";
         for(StatementCompanyComprehensiveInfo info:reportFormList1){
             //转BigDecimal 处理   合计
             xmnum1 = new BigDecimal(info.getField1()).add(new BigDecimal(xmnum1)).toString();
@@ -2839,6 +3030,8 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
             xmnum5 = new BigDecimal(info.getField5()).add(new BigDecimal(xmnum5)).toString();
             xmnum6 = new BigDecimal(info.getField6()).add(new BigDecimal(xmnum6)).toString();
             xmnum7 = new BigDecimal(info.getField7()).add(new BigDecimal(xmnum7)).toString();
+            xmnum8 = new BigDecimal(info.getField8()).add(new BigDecimal(xmnum8)).toString();
+            xmnum9 = new BigDecimal(info.getField9()).add(new BigDecimal(xmnum9)).toString();
         }
         //存放到对应报表的list集合,方便页面集合展示
         StatementCompanyComprehensiveInfo xminfo = new StatementCompanyComprehensiveInfo();
@@ -2850,6 +3043,8 @@ public class StatementCompanyComprehensiveService extends CrudService<StatementC
         xminfo.setField5(xmnum5);
         xminfo.setField6(xmnum6);
         xminfo.setField7(xmnum7);
+        xminfo.setField8(xmnum8);
+        xminfo.setField9(xmnum9);
         reportFormList1.add(xminfo);
         map.put("reportFormList1",reportFormList1);
         return map;

+ 15 - 5
src/main/java/com/jeeplus/modules/sys/web/LoginController.java

@@ -421,6 +421,7 @@ public class LoginController extends BaseController{
 	 */
 	@RequestMapping(value = "${adminPath}/home")
 	public String home(String type, HttpServletRequest request, HttpServletResponse response, Model model) throws IOException {
+		long s1 = System.currentTimeMillis();
 		User user = UserUtils.getUser();
 		OaNotify oaNotify = new OaNotify();
 		oaNotify.setSelf(true);
@@ -434,7 +435,8 @@ public class LoginController extends BaseController{
 
 		//知识分享类别信息
 		List<KnowledgeSharingTypeInfo> typeInfoList = typeService.findList(new KnowledgeSharingTypeInfo());
-
+		long s2 = System.currentTimeMillis();
+		System.out.println("s2-s1: " + (s2-s1));
 
 		List<OaNotify> showNotifyList = page.getList();
 		for (OaNotify info: showNotifyList) {
@@ -520,6 +522,8 @@ public class LoginController extends BaseController{
 		JSONArray json = JSONArray.fromObject(mapList);
 		model.addAttribute("oaNotifyList", json);*/
 
+		long s3 = System.currentTimeMillis();
+		System.out.println("s3-s2: " + (s3-s2));
 		//待办事项
 		WorkProjectNotify workProjectNotify = new WorkProjectNotify();
 		workProjectNotify.setUser(user);
@@ -548,6 +552,8 @@ public class LoginController extends BaseController{
 		model.addAttribute("notifyCount1", notifyPage.getCount());//未读通知条数
 		workProjectNotify.setStatus("0");
 		workProjectNotify.setRemarks("待通知");
+		long s4 = System.currentTimeMillis();
+		System.out.println("s4-s3: " + (s4-s3));
 		//通知信息
 		Page<WorkProjectNotify> notifyPageShow = workProjectNotifyService.notifyFindPage(new Page<WorkProjectNotify>(request, response), workProjectNotify);
 		model.addAttribute("notifyShowPage", notifyPageShow.getList());
@@ -556,11 +562,13 @@ public class LoginController extends BaseController{
 
 		model.addAttribute("notifyTypeList", notifytype);//未读通知条数
 
+		long s5 = System.currentTimeMillis();
+		System.out.println("s5-s4: " + (s5-s4));
 		//我的日程
-		WorkCalendar workCalendar = new WorkCalendar();
+		/*WorkCalendar workCalendar = new WorkCalendar();
 		Page<WorkCalendar> workCalendars=workCalendarService.findHomePage(new Page<WorkCalendar>(request, response), workCalendar);
 		model.addAttribute("calendarCount", workCalendars.getList());
-		model.addAttribute("calendarPage", workCalendars.getList().size());
+		model.addAttribute("calendarPage", workCalendars.getList().size());*/
 		//model.addAttribute("calendarSize", workCalendars.getCount());
 		//我的项目
 		RuralProjectRecordReportInfo ruralProjectRecordReportInfo = new RuralProjectRecordReportInfo();
@@ -569,13 +577,15 @@ public class LoginController extends BaseController{
 		model.addAttribute("projectCount", projectPage.getList());
 		model.addAttribute("projectPage", projectPage.getList().size());
 		model.addAttribute("projectSize", projectPage.getCount());
+		long s6 = System.currentTimeMillis();
+		System.out.println("s6-s5: " + (s6-s5));
 
-		MailBox mailBox = new MailBox();
+		/*MailBox mailBox = new MailBox();
 		mailBox.setReceiver(user);
 		mailBox.setReadstatus("0");//筛选未读
 		Page<MailBox> mailPage = mailBoxService.findPage(new MailPage<MailBox>(request, response), mailBox);
 		model.addAttribute("noReadCount", mailBoxService.getCount(mailBox));
-		model.addAttribute("mailPage", mailPage.getList());
+		model.addAttribute("mailPage", mailPage.getList());*/
 		model.addAttribute("firstFlag", request.getParameter("firstFlag"));
 		return "modules/sys/sysHome";
 

+ 18 - 0
src/main/java/com/jeeplus/modules/workinvoice/entity/WorkInvoice.java

@@ -107,6 +107,8 @@ public class WorkInvoice extends ActEntity<WorkInvoice> {
 	private String proceedsMoney;    	//收款总收入
 	private String noProceedsMoney;    	//剩余应收款费用
 	private Integer workReceiptCount;    	//收款数据量
+	private Double receiptMoneyD; //已收款金额
+	private Double notReceiptMoneyD; //未收款金额
 	@Override
 	@ExcelField(title="经办人", fieldType=User.class, value="createBy.name", align=2, sort=7)
 	public User getCreateBy() {
@@ -753,4 +755,20 @@ public class WorkInvoice extends ActEntity<WorkInvoice> {
 	public void setWidTotalMoneyD(Double widTotalMoneyD) {
 		this.widTotalMoneyD = widTotalMoneyD;
 	}
+
+	public Double getReceiptMoneyD() {
+		return receiptMoneyD;
+	}
+
+	public void setReceiptMoneyD(Double receiptMoneyD) {
+		this.receiptMoneyD = receiptMoneyD;
+	}
+
+	public Double getNotReceiptMoneyD() {
+		return notReceiptMoneyD;
+	}
+
+	public void setNotReceiptMoneyD(Double notReceiptMoneyD) {
+		this.notReceiptMoneyD = notReceiptMoneyD;
+	}
 }

+ 27 - 7
src/main/java/com/jeeplus/modules/workinvoice/entity/WorkInvoiceExport.java

@@ -93,6 +93,8 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 	private String accountCheckingUserId; //对账人id
 	private String accountCheckingUserName; //对账人名称
 	private List<Workattachment> workAttachments;//附件
+	private Double receiptMoneyD; //已收款金额
+	private Double notReceiptMoneyD; //未收款金额
 
 
 	@Override
@@ -146,7 +148,7 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 		this.bankNumber = bankNumber;
 	}
 
-	@ExcelField(title="发票状态", align=2, sort=12,dictType = "invoice_audit_state")
+	@ExcelField(title="开票状态", align=2, sort=9,dictType = "invoice_audit_state")
 	public String getInvoiceState() {
 		return invoiceState;
 	}
@@ -313,7 +315,7 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 		this.moneyStr = moneyStr;
 	}
 
-	@ExcelField(title="发票类型",dictType="invoice_type", align=2, sort=8)
+	@ExcelField(title="发票类型",dictType="invoice_type", align=2, sort=10)
 	public String getInvoiceType() {
 		return invoiceType;
 	}
@@ -367,7 +369,7 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 	}
 
 	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
-	@ExcelField(title="开票日期", align=2, sort=11)
+	@ExcelField(title="开票日期", align=2, sort=8)
 	public Date getInvoiceDate() {
 		return invoiceDate;
 	}
@@ -485,7 +487,7 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 	}
 
 	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
-	@ExcelField(title="收款日期", align=2, sort=13)
+	@ExcelField(title="收款日期", align=2, sort=15)
 	public Date getReceiptMoneyDate() {
 		return receiptMoneyDate;
 	}
@@ -494,7 +496,7 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 		this.receiptMoneyDate = receiptMoneyDate;
 	}
 
-	@ExcelField(title="是否收款", align=2, sort=14)
+	@ExcelField(title="是否收款", align=2, sort=16)
 	public String getReceiptMoney() {
 		return receiptMoney;
 	}
@@ -599,7 +601,7 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 		this.accountCheckingUserName = accountCheckingUserName;
 	}
 
-	@ExcelField(title="发票编号", align=2, sort=9)
+	@ExcelField(title="发票编号", align=2, sort=11)
 	public String getWidNumber() {
 		return widNumber;
 	}
@@ -641,7 +643,7 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 		this.reportNumber = reportNumber;
 	}
 
-	@ExcelField(title="发票金额(元)", align=2, sort=10)
+	@ExcelField(title="发票金额(元)", align=2, sort=12)
 	public Double getWidTotalMoneyD() {
 		return widTotalMoneyD;
 	}
@@ -649,4 +651,22 @@ public class WorkInvoiceExport extends ActEntity<WorkInvoiceExport> {
 	public void setWidTotalMoneyD(Double widTotalMoneyD) {
 		this.widTotalMoneyD = widTotalMoneyD;
 	}
+
+	@ExcelField(title="已收款金额(元)", align=2, sort=13)
+	public Double getReceiptMoneyD() {
+		return receiptMoneyD;
+	}
+
+	public void setReceiptMoneyD(Double receiptMoneyD) {
+		this.receiptMoneyD = receiptMoneyD;
+	}
+
+	@ExcelField(title="未收款金额(元)", align=2, sort=14)
+	public Double getNotReceiptMoneyD() {
+		return notReceiptMoneyD;
+	}
+
+	public void setNotReceiptMoneyD(Double notReceiptMoneyD) {
+		this.notReceiptMoneyD = notReceiptMoneyD;
+	}
 }

+ 100 - 1
src/main/java/com/jeeplus/modules/workinvoice/service/WorkInvoiceService.java

@@ -54,11 +54,14 @@ import org.activiti.engine.*;
 import org.activiti.engine.history.HistoricProcessInstance;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.activiti.engine.task.Task;
+import org.apache.commons.collections4.CollectionUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 
+import java.math.BigDecimal;
+import java.math.RoundingMode;
 import java.util.*;
 
 /**
@@ -267,10 +270,106 @@ public class WorkInvoiceService extends CrudService<WorkInvoiceDao, WorkInvoice>
 		page.setCount(count);
 		page.setCountFlag(false);
 		workInvoice.setPage(page);
-		page.setList(dao.findListExport(workInvoice));
+		List<WorkInvoice> listExport = dao.findListExport(workInvoice);
+
+		page.setList(listExport);
 		return page;
 
 	}
+
+	/**
+	 * 导出数据处理
+	 * @param listExport
+	 */
+	public void disposeListExport(List<WorkInvoice> listExport){
+
+		//临时list 用于存储收款金额不为空的数据信息
+		List<WorkInvoice> temporaryList = Lists.newArrayList();
+		for (WorkInvoice invoice : listExport) {
+			//判定已收款金额是否为空
+			if(null != invoice.getReceiptMoneyD() && 0 != invoice.getReceiptMoneyD()){
+				temporaryList.add(invoice);
+			}
+		}
+		//判定临时list中是否有值,有值则对数据信息进行分组处理
+		List<WorkInvoice> temporaryList2 = Lists.newArrayList();
+		if(temporaryList.size()>0){
+			//对查询出来的文件数据进行分组
+			Map<String, List<WorkInvoice>> temporaryListMap = dataMessageWorkInvoiceDispose(temporaryList);
+			for (String key : temporaryListMap.keySet()) {
+				List<WorkInvoice> temporaryInvoiceList = temporaryListMap.get(key);
+				if(temporaryInvoiceList.size()>0){
+					//获取收到钱的总金额
+					BigDecimal allReceiptMoney = new BigDecimal(temporaryInvoiceList.get(0).getReceiptMoneyD());
+					allReceiptMoney = allReceiptMoney.setScale(2, RoundingMode.HALF_UP);
+					for (int i = 0 ; i<temporaryInvoiceList.size(); i++ ){
+						WorkInvoice invoice = temporaryInvoiceList.get(i);
+						BigDecimal widTotalMoney = new BigDecimal(invoice.getWidTotalMoneyD());
+						widTotalMoney = widTotalMoney.setScale(2, RoundingMode.HALF_UP);
+						if(allReceiptMoney.compareTo(widTotalMoney) == 0){  //应收款额度等于已收款额度
+							allReceiptMoney = new BigDecimal(0);
+							invoice.setNotReceiptMoneyD(0D);
+						} else if(allReceiptMoney.compareTo(widTotalMoney) == 1){  //已收款额度大于应收款额度
+							if(temporaryInvoiceList.size() == 1){
+								invoice.setReceiptMoneyD(Double.valueOf(allReceiptMoney.toString()));
+								allReceiptMoney = allReceiptMoney.subtract(widTotalMoney).setScale(2, RoundingMode.HALF_UP);
+								invoice.setNotReceiptMoneyD(Double.valueOf("-" + allReceiptMoney));
+							}else{
+								if(i == temporaryInvoiceList.size()-1){
+									invoice.setReceiptMoneyD(Double.valueOf(allReceiptMoney.toString()));
+									allReceiptMoney = allReceiptMoney.subtract(widTotalMoney).setScale(2, RoundingMode.HALF_UP);
+									invoice.setNotReceiptMoneyD(Double.valueOf("-" + allReceiptMoney));
+								}else{
+									invoice.setReceiptMoneyD(invoice.getWidTotalMoneyD());
+									allReceiptMoney = allReceiptMoney.subtract(widTotalMoney).setScale(2, RoundingMode.HALF_UP);
+									invoice.setNotReceiptMoneyD(0D);
+								}
+							}
+
+						}else{
+							BigDecimal notReceiptMoney = widTotalMoney.subtract(allReceiptMoney).setScale(2, RoundingMode.HALF_UP);
+							invoice.setReceiptMoneyD(Double.valueOf(allReceiptMoney.toString()));
+							invoice.setNotReceiptMoneyD(Double.valueOf(notReceiptMoney.toString()));
+							allReceiptMoney = new BigDecimal(0);
+						}
+						temporaryList2.add(invoice);
+					}
+				}
+			}
+
+			for (WorkInvoice invoice : temporaryList2) {
+				for (WorkInvoice info : listExport) {
+					if(invoice.getWidNumber().equals(info.getWidNumber())){
+						info.setReceiptMoneyD(invoice.getReceiptMoneyD());
+						info.setNotReceiptMoneyD(invoice.getNotReceiptMoneyD());
+						break;
+					}
+				}
+			}
+		}
+	}
+
+	private Map<String, List<WorkInvoice>> dataMessageWorkInvoiceDispose(List<WorkInvoice> list) {
+		Map<String, List<WorkInvoice>> userSignSerialMap = new HashMap<>();
+		if (CollectionUtils.isNotEmpty(list)) {
+			// 分组
+			for (WorkInvoice vo : list) {
+				List<WorkInvoice> tempList = userSignSerialMap.get(vo.getNumber());
+				/*如果取不到数据,那么直接new一个空的ArrayList**/
+				if (tempList == null) {
+					tempList = new ArrayList<>();
+					tempList.add(vo);
+					userSignSerialMap.put(vo.getNumber(), tempList);
+				}
+				else {
+					/*某个vo之前已经存放过了,则直接追加数据到原来的List里**/
+					tempList.add(vo);
+				}
+			}
+		}
+		return userSignSerialMap;
+	}
+
 	public Page<WorkInvoice> findMapPage(Page<WorkInvoice> page, WorkInvoice workInvoice) {
 		workInvoice.getSqlMap().put("dsf", dataScopeFilter(workInvoice.getCurrentUser(), "o", "u","s", MenuStatusEnum.WORK_INVOICE.getValue()));
 		if(StringUtils.isNotBlank(workInvoice.getOfficeId())){

+ 1 - 0
src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceAllController.java

@@ -784,6 +784,7 @@ public class WorkInvoiceAllController extends BaseController {
             String fileName = "发票管理"+DateUtils.getDate("yyyyMMddHHmmss")+".xlsx";
             Page<WorkInvoice> page = workInvoiceService.findListExport(new Page<WorkInvoice>(request, response, -1), workInvoice);
 			List<WorkInvoice> workInvoiceList = page.getList();
+			invoiceService.disposeListExport(workInvoiceList);
 			/*for (WorkInvoice invoice: workInvoiceList) {
 				invoice.setWorkInvoiceProjectRelationList(workInvoiceService.getProjectRelation(invoice));
 				List<String> projectNameList = workInvoiceService.getProjectNameList(invoice);

+ 5 - 4
src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceTwoController.java

@@ -172,8 +172,8 @@ public class WorkInvoiceTwoController extends BaseController {
 		//查询已通过的所有发票的开票金额总和
 		String getSumMoney = workInvoiceService.getSumMoney(workInvoice);
 		List<WorkInvoice> workInvoiceList = page.getList();
-		for (WorkInvoice invoice: workInvoiceList) {
-			/*for (WorkProjectNotify notify: notifyList) {
+		/*for (WorkInvoice invoice: workInvoiceList) {
+			*//*for (WorkProjectNotify notify: notifyList) {
 				if(notify.getNotifyId().equals(invoice.getId())){
 					invoice.setNotifyId(notify.getId());
 					if("待审批".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
@@ -181,7 +181,7 @@ public class WorkInvoiceTwoController extends BaseController {
 					}
 					break;
 				}
-			}*/
+			}*//*
 			invoice.setWorkInvoiceProjectRelationList(workInvoiceService.getProjectRelation(invoice));
 			List<String> projectNameList = workInvoiceService.getProjectNameList(invoice);
 			String projectNameStr = String.join(",", projectNameList);
@@ -199,7 +199,7 @@ public class WorkInvoiceTwoController extends BaseController {
 			}
 			String reportNumberStr = String.join(",", reportNumber);
 			invoice.setReportNumber(reportNumberStr);
-		}
+		}*/
 		model.addAttribute("page", page);
 		model.addAttribute("sumMoney", getSumMoney);
 		model.addAttribute("workInvoiceShow", workInvoice);
@@ -778,6 +778,7 @@ public class WorkInvoiceTwoController extends BaseController {
             String fileName = "发票一览表"+DateUtils.getDate("yyyyMMddHHmmss")+".xlsx";
             Page<WorkInvoice> page = workInvoiceService.findListExport(new Page<WorkInvoice>(request, response, -1), workInvoice);
 			List<WorkInvoice> workInvoiceList = page.getList();
+			workInvoiceService.disposeListExport(workInvoiceList);
 			/*for (WorkInvoice invoice: workInvoiceList) {
 				invoice.setWorkInvoiceProjectRelationList(workInvoiceService.getProjectRelation(invoice));
 				List<String> projectNameList = workInvoiceService.getProjectNameList(invoice);

+ 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://192.168.2.4:3306/simple_xg_total_process?useUnicode=true&characterEncoding=utf-8
-jdbc.url=jdbc:mysql://127.0.0.1:3306/new_ccpm?useUnicode=true&characterEncoding=utf-8
+jdbc.url=jdbc:mysql://127.0.0.1:3306/new_ccpm_2?useUnicode=true&characterEncoding=utf-8
 jdbc.username=root
 jdbc.password=root
 #jdbc.password=root

+ 165 - 38
src/main/resources/mappings/modules/projectMaterialStorage/ProjectMaterialStorageDao.xml

@@ -4,17 +4,26 @@
 
 	<sql id="projectMaterialStorageColumns">
 		a.id AS "id",
-		a.material_name  As "materialName",
-		a.price AS "price",
-		a.project_number AS "projectNumber",
 		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",
-		r.project_name as "projectName",
-		a.unit as "unit"
+		a.material_name  As "materialName",
+		a.price AS "price",
+		a.project_number as "projectNumber",
+		a.brand as "brand",
+		a.specifications as "specifications",
+		a.project_price_including_tax as "projectPriceIncludingTax",
+		a.market_price_including_tax as "marketPriceIncludingTax",
+		a.tax_rate as "taxRate",
+		a.unit as "unit",
+		a.explain as "explain",
+		a.supplier as "supplier",
+		a.remarks as "remarks",
+		a.quoted_price_date as "quotedPriceDate",
+		a.project_number AS "projectNumber",
+		r.project_name as "projectName"
 	</sql>
 
 	<sql id="projectJoins">
@@ -41,7 +50,9 @@
 
 	<select id="findList" resultType="com.jeeplus.modules.projectmaterialstorage.entity.ProjectMaterialStorage" >
 		SELECT
-		a.id,a.material_name,a.price,a.create_date as createDate,r.project_name,sys_area.name as 'areaName',a.project_number as 'projectNumber',a.unit as 'unit',prd.number as 'projectId',a.create_by as 'createBy.id'
+		<include refid="projectMaterialStorageColumns"/>
+		,prd.number as 'projectId'
+		,sys_area.name as 'areaName'
 		FROM project_material_storage a
 		left join rural_project_records as r on a.project_number = r.id
 		left join project_report_data as prd on a.project_number = prd.project_id
@@ -63,9 +74,50 @@
 			<if test="materialName != null and materialName != ''">
 				AND a.material_name like concat(concat('%',#{materialName}),'%')
 			</if>
-			<if test="areaName != null and areaName != ''">
-				AND r.area_name like concat(concat('%',#{areaName}),'%')
+			<if test="brand != null and brand != ''">
+				AND a.brand like concat(concat('%',#{brand}),'%')
+			</if>
+			<if test="specifications != null and specifications != ''">
+				AND a.specifications like concat(concat('%',#{specifications}),'%')
+			</if>
+			<if test="unit != null and unit != ''">
+				AND a.unit like concat(concat('%',#{unit}),'%')
+			</if>
+			<if test="explain != null and explain != ''">
+				AND a.explain like concat(concat('%',#{explain}),'%')
+			</if>
+			<if test="supplier != null and supplier != ''">
+				AND a.supplier like concat(concat('%',#{supplier}),'%')
+			</if>
+
+			<if test="beginProjectPriceIncludingTax !=null and beginProjectPriceIncludingTax != ''">
+				AND a.project_price_including_tax >= #{beginProjectPriceIncludingTax}
+			</if>
+			<if test="endProjectPriceIncludingTax !=null and endProjectPriceIncludingTax != ''">
+				AND a.project_price_including_tax &lt;= #{endProjectPriceIncludingTax}
+			</if>
+
+			<if test="beginMarketPriceIncludingTax !=null and beginMarketPriceIncludingTax != ''">
+				AND a.market_price_including_tax >= #{beginMarketPriceIncludingTax}
+			</if>
+			<if test="endMarketPriceIncludingTax !=null and endMarketPriceIncludingTax != ''">
+				AND a.market_price_including_tax &lt;= #{endMarketPriceIncludingTax}
+			</if>
+
+			<if test="beginTaxRate !=null and beginTaxRate != ''">
+				AND a.tax_rate >= #{beginTaxRate}
 			</if>
+			<if test="endTaxRate !=null and endTaxRate != ''">
+				AND a.tax_rate &lt;= #{endTaxRate}
+			</if>
+
+			<if test="beginQuotedPriceDate !=null">
+				AND a.quoted_price_date >= #{beginQuotedPriceDate}
+			</if>
+			<if test="endQuotedPriceDate !=null">
+				AND a.quoted_price_date &lt; #{endQuotedPriceDate}
+			</if>
+
 			<if test="beginDate !=null">
 				AND a.create_date >= #{beginDate}
 			</if>
@@ -105,40 +157,65 @@
 	<insert id="insert">
 		INSERT INTO project_material_storage(
 			id,
+			create_by,
 			create_date,
+			update_by,
+			update_date,
 			del_flag,
 			material_name,
 			price,
-			remarks,
 			project_number,
-			update_by,
-			update_date,
-			create_by,
-			unit
+			brand,
+			specifications,
+			project_price_including_tax,
+			market_price_including_tax,
+			tax_rate,
+			unit,
+			`explain`,
+			supplier,
+			remarks,
+			quoted_price_date
 		) VALUES (
 			#{id},
+			#{createBy.id},
 			#{createDate},
+			#{updateBy.id},
+			#{updateDate},
 			#{delFlag},
 			#{materialName},
 			#{price},
-			#{remarks},
 			#{projectNumber},
-			#{updateBy.id},
-			#{updateDate},
-			#{createBy.id},
-			#{unit}
+			#{brand},
+			#{specifications},
+			#{projectPriceIncludingTax},
+			#{marketPriceIncludingTax},
+			#{taxRate},
+			#{unit},
+			#{explain},
+			#{supplier},
+			#{remarks},
+			#{quotedPriceDate}
 		)
 	</insert>
 
 	<update id="update">
 		UPDATE project_material_storage SET
+			update_by = #{updateBy.id},
+			update_date = #{updateDate},
 			project_number = #{projectNumber},
 			material_name = #{materialName},
 			price = #{price},
 			del_flag = #{delFlag},
-			update_by = #{updateBy.id},
-			update_date = #{updateDate},
-			remarks = #{remarks}
+			brand = #{brand},
+			specifications = #{specifications},
+			project_price_including_tax = #{projectPriceIncludingTax},
+			market_price_including_tax = #{marketPriceIncludingTax},
+			tax_rate = #{taxRate},
+			unit = #{unit},
+			`explain` = #{explain},
+			supplier = #{supplier},
+			remarks = #{remarks},
+			quoted_price_date = #{quotedPriceDate}
 		WHERE id = #{id}
 	</update>
 
@@ -167,10 +244,16 @@
 	<select id="selectCountAboutProjectMaterialStorage" resultType="integer">
 		select count(1)
 		from project_material_storage
-		where project_number = #{projectNumber}
-		and material_name = #{materialName}
-		and price = #{price}
-		and project_number = #{projectNumber}
+		<where>
+			del_flag = 0
+			and project_number = #{projectNumber}
+			and material_name = #{materialName}
+			and specifications = #{specifications}
+			and project_number = #{projectNumber}
+			<if test="null != quotedPriceDate">
+				and quoted_price_date = #{quotedPriceDate}
+			</if>
+		</where>
 	</select>
 
 
@@ -183,7 +266,7 @@
 			a.del_flag = 0
 			and a.project_number = #{projectNumber}
 			and a.material_name = #{materialName}
-			and a.price = #{price}
+			and a.specifications = #{specifications}
 			and a.unit = #{unit}
 			<if test="id !=null and id != ''">
 				AND a.id != #{id}
@@ -194,23 +277,50 @@
 
 	<insert id="batchInsert">
 		insert into project_material_storage
-		(id,create_date,del_flag,material_name,price,remarks,project_number,update_by,update_date,create_by,unit)
+		(id,
+		create_by,
+		create_date,
+		update_by,
+		update_date,
+		del_flag,
+		material_name,
+		price,
+		project_number,
+		brand,
+		specifications,
+		project_price_including_tax,
+		market_price_including_tax,
+		tax_rate,
+		unit,
+		`explain`,
+		supplier,
+		remarks,
+		quoted_price_date)
 		values
 		<foreach collection="projectMaterialStorageImportList" item="data" separator=",">
-		(#{data.id},#{data.createDate},#{data.delFlag},#{data.materialName},#{data.price},' ',#{data.projectNumber},#{data.updateBy.id},#{data.updateDate},#{data.createBy.id},#{data.unit})
+		(#{data.id},
+		#{data.createBy.id},
+		#{data.createDate},
+		#{data.updateBy.id},
+		#{data.updateDate},
+		#{data.delFlag},
+		#{data.materialName},
+		#{data.price},
+		#{data.projectNumber},
+		#{data.brand},
+		#{data.specifications},
+		#{data.projectPriceIncludingTax},
+		#{data.marketPriceIncludingTax},
+		#{data.taxRate},
+		#{data.unit},
+		#{data.explain},
+		#{data.supplier},
+		#{data.remarks},
+		#{data.quotedPriceDate})
 		</foreach>
 	</insert>
 
 	<select id="queryCount" resultType="int">
-<!--		select count(1)-->
-<!--		from project_material_storage a-->
-<!--		<where>-->
-<!--			a.del_flag = 0-->
-<!--			AND a.del_flag = #{DEL_FLAG_NORMAL}-->
-<!--			<if test="projectId !=null">-->
-<!--				AND a.project_id like concat(concat('%',#{projectId}),'%')-->
-<!--			</if>-->
-<!--		</where>-->
 
 		SELECT
 				count(1)
@@ -252,6 +362,23 @@
 
 	</select>
 
+	<delete id="deleteListById">
+		delete from project_material_storage where id in
+		<foreach collection="idList" item="item" index="no" open="(" separator="," close=")">
+			#{item}
+		</foreach>
+	</delete>
 
+	<select id="getByIdList" resultType="com.jeeplus.modules.projectmaterialstorage.entity.ProjectMaterialStorage">
+		SELECT
+		<include refid="projectMaterialStorageColumns"/>
+		FROM project_material_storage a
+		left join rural_project_records r on a.project_number = r.id
+		WHERE a.id in
+		<foreach collection="idList" item="item" index="no" open="(" separator="," close=")">
+			#{item}
+		</foreach>
+		and a.del_flag = 0 and a.create_by = #{createBy}
+	</select>
 
 </mapper>

+ 384 - 308
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageAllDao.xml

@@ -159,6 +159,70 @@
 		a.emergency_project as "emergencyProject"
 	</sql>
 
+	<sql id="newProjectRecordsColumns">
+		a.id AS "id",
+		a.create_by AS "createBy.id",
+		a.create_date AS "createDate",
+		sua.name AS "createBy.name",
+		a.update_by AS "updateBy.id",
+		a.update_date AS "updateDate",
+		a.del_flag AS "delFlag",
+		a.contract_id AS "workContractInfo.id",
+		a.project_id AS "projectId",
+		a.project_name AS "projectName",
+		a.scale_type AS "scaleType",
+		a.scale_unit AS "scaleUnit",
+		a.scale_quantity AS "scaleQuantity",
+		a.area_id AS "area.id",
+		a.project_site AS "projectSite",
+		a.project_desc AS "projectDesc",
+		a.remarks AS "remarks",
+		a.status AS "projectStatus",
+		a.process_instance_id AS "processInstanceId",
+		a.company_id AS "company.id",
+		a.office_id AS "office.id",
+		a.alter_process_id AS "alterProcessId",
+		area.name AS "area.name",
+		a.province,
+		a.city,
+		a.area_name AS "county",
+		a.project_structure AS "projectStructure",
+		a.on_ground_num AS "onGroundNum",
+		a.under_ground_num AS "underGroundNum",
+		a.building_scale AS "buildingScale",
+		a.measuring_unit AS "measuringUnit",
+		a.project_use AS "projectUse",
+		a.install_fees AS "installFees",
+		a.building_fees AS "buildingFees",
+		a.building_percent AS "buildingPercent",
+		a.install_percent AS "installPercent",
+		a.unit_fees AS "unitFees",
+		a.building_unit_fees AS "buildingUnitFees",
+		a.install_unit_fees AS "installUnitFees",
+		a.total_fees AS "totalFees",
+		ifnull(a.reported_state,0) as "reportedState",
+		a.over_due_status as "overDueStatus",
+		ifnull(a.record_state,0) as "projectRecordStatus",
+		a.over_record_status as "overRecordStatus",
+		a.emergency_project as "emergencyProject",
+		a.attachment_project_sort as "attachmentProjectSort",
+		a.report_signature_flag as "reportSignatureFlag",
+		a.report_signature_document_id as "reportSignatureDocumentId",
+		a.report_signature_contract_id as "reportSignatureContractId",
+		a.report_signature_invalid_document_id as "reportSignatureInvalidDocumentId",
+		a.report_signature_file_name as "reportSignatureFileName",
+		a.report_signature_upload_file_user as "reportSignatureUploadFileUser.id",
+		a.report_signature_upload_date as "reportSignatureUploadDate",
+		a.quality_signature_flag as "qualitySignatureFlag",
+		a.quality_signature_document_id as "qualitySignatureDocumentId",
+		a.quality_signature_contract_id as "qualitySignatureContractId",
+		a.quality_signature_invalid_document_id as "qualitySignatureInvalidDocumentId",
+		a.quality_signature_file_name as "qualitySignatureFileName",
+		a.quality_signature_upload_file_user as "qualitySignatureUploadFileUser.id",
+		a.quality_signature_upload_date as "qualitySignatureUploadDate",
+		a.belonging_department as "belongingDepartment"
+	</sql>
+
 	<sql id="recordDownloadSql">
 		distinct(a.id) AS "id",
 		a.create_by AS "createBy.id",
@@ -347,61 +411,37 @@ END) as projectScale*/
 	</select>
 
 	<select id="findList" resultType="RuralProjectRecords" >
+		select * from (
 		SELECT
-		<include refid="projectRecordsColumns"/>
-		,a.record_state as "recordState"
+		<include refid="newProjectRecordsColumns"/>
+		,concat(ifnull( pfp.STATUS, 0 ),ifnull( ppf.STATUS, 0 )) as "downProjectReportRecordPaperFilingStatus"
+		,su.name as "leaderNameStr"
+		,su.id as "leaderNameIds"
 		,a.submit_money as "submitMoney"
-		,a.submit_scale as "submitScale"
-		,(case when a.submit_money = '1' then 'B级' when a.submit_money = '2' then 'A级' else '' end) as projectScale
-		,(case
-		when a.submit_money = '1' and prd.status = '5' then
-		'已完成'
-		when a.submit_money = '2' and prdt.status = '5' then
-		'已完成' else '未完成'
-		end) as completionStatus
 		,a.project_type as projectType,
 		wci.name AS "workContractInfo.name",
-		wci.contract_num as "workContractInfo.contractNum",
-		wci.contract_price as "workContractInfo.contractPrice",
-		sub.name as "projectMasterName",
-		sob.name as "projectMasterOffice",
 		wct.id AS "workContractInfo.client.id",
 		wct.name AS "workContractInfo.client.name",
 		o.top_company AS "office.name",
-		o.name AS "createByOffice",
 		ifnull(prd.number ,"") as "projectReportNumber"
 		,ifnull(prd.status,0) as "projectReportStatus"
 		,ifnull(prd.name,"") as "projectReportName"
-		,ifnull(prr.status,0) as "projectReportRecordStatus"
-		,prr.accomplish_date as "projectReportRecordAuditDate"
-		,(case
-		when a.submit_money = '1' then
-		ifnull(pfp.status,0)
-		when a.submit_money = '2' then
-		ifnull(prrd.status,0) else 0
-		end) as downProjectReportRecordStatus,
-		pfp.audit_pass_date as "projectFlingbatchRelationAuditPassDate",
-		(case
-		when a.submit_money = '1' and pfp.status = '5' then
-		'已归档'
-		when a.submit_money = '2' and ppf.status = '5' then
-		'已归档' else '未归档'
-		end) as downArchiveStatus,
-		/*,ifnull(prrd.status,0) as "downProjectReportRecordStatus"*/
-		prrd.file_num as recodeNum,
-		prr.process_instance_id as prrProcessInstanceId,
-		prrd.process_instance_id as prrdProcessInstanceId
+		,a.project_material_storage_status as "projectMaterialStorageStatus"
+		<choose>
+			<when test="projectReportRecordStatus  != null and projectReportRecordStatus != ''">
+				,ifnull(prr.status,#{projectReportRecordStatus}) as "projectReportRecordStatus"
+			</when>
+			<otherwise>
+				,ifnull(prr.status,0) as "projectReportRecordStatus"
+			</otherwise>
+		</choose>
+		,prr.process_instance_id as prrProcessInstanceId
 		,prd.id as prdId
 		,prr.id as prrId
-		,prrd.id as prrdId
 		,prd.audit_pass_date as auditPassDate
 		,if(date_add(prd.audit_pass_date,interval #{endingCount} day) >now(),"0","1") as reportedType
 		,ifnull(rprr.report_status,0) as "reportStatus"
 		,ifnull(rprr.sync_status,0) as "syncStatus"
-		,ifnull(pas.status,0) as "approvalSignatureStatus"
-		,ifnull(pas.process_instance_id,"") as "approvalSignatureProcessInstanceId"
-		,ifnull(prs.status,0) as "reportSignatureStatus"
-		,ifnull(prs.process_instance_id,"") as "reportSignatureProcessInstanceId"
 		,rprr.process_instance_id as "reportedProcessInstanceId"
 		,ifnull(prdt.status,0) as "projectReportStatusTwo"
 		,prdt.id as prdtId
@@ -410,53 +450,34 @@ END) as projectScale*/
 		,pmdr.process_instance_id as "pmdrProcessInstanceId"
 		,pmdr.id as pmdrId
 		,ifnull(ppf.status,0) as "paperFilingStatus"
-		,ppf.audit_pass_date as "projectPaperAuditPassDate"
 		,ppf.process_instance_id as "ppfProcessInstanceId"
 		,ppf.id as "ppfId"
-		,pfp.filing_batch as "filingBatch"
-		,pfp.box_num as "boxNum"
-		,pfp.re_box_num as "reBoxNum"
-		,pfb.id AS "FilingBatchId"
-		,(select group_concat(su.name) from work_project_user wpu left join sys_user su on su.id = wpu.user_id where wpu.project_id = a.id) as "leaderNameStr"
-		,(select group_concat(su.id) from work_project_user wpu left join sys_user su on su.id = wpu.user_id where wpu.project_id = a.id) as "leaderNameIds"
 		,pfb.process_instance_id AS "filingProcessinstanceId"
-		,pfb.filing_status AS "filingStatus"
 		,ifnull(pfp.status,0) as "filingProjectStatus"
-		,ifnull(prd.approval_fee ,"") as "approvalFee"
-		,ifnull(prd.review_fee ,"") as "reviewFee"
-		,ifnull(prd.verify_fee ,"") as "verifyFee"
-		,ifnull(prd.verify_rate ,"") as "verifyRate"
-		,prd.audit_pass_date as "reportAuditDate"
-		,prdt.audit_pass_date as "reportTwoAuditDate"
-		/*,SUM(wi.money) as "money"*/
+		,prd.audit_pass_date as "prdAuditDate"
 		,prd.ZiXunShouRu as "money"
-		,prd.signature_flag as "signatureFlag"
-		,prd.signature_contract_id as "signatureContractId"
-		,prd.signature_url as "signatureUrl"
-		,a.report_signature_flag as "reportSignatureFlag"
-		,a.report_signature_url as "reportSignatureUrl"
-		,a.report_signature_contract_id as "reportSignatureContractId"
-		,prsi.id as "prsiId"
 		,cb.case_process_id as "caseProcessId"
 		,cb.case_type as "caseType"
 		,cb.case_create_by as "caseCreateBy"
 		,if(case_status > 0 ,case_status,"0") as "caseStatus"
-		,rprr.ZiXunBDE as "ziXunBDE"
-		,rprr.accomplish_date as "projectRecordsReportedAuditPassDate"
-		,a.project_material_storage_status as "projectMaterialStorageStatus"
-		,a.attachment_project_sort as "attachmentProjectSort"
 		FROM rural_project_records a
-		left join case_base cb on a.id = cb.project_id
 		LEFT JOIN sys_area area ON area.id = a.area_id
 		left join rural_project_records_reported rprr on rprr.id = a.id
-		LEFT JOIN project_flingbatch_relation pfp on pfp.project_id=a.id and pfp.del_flag = 0
+		left join case_base cb on a.id = cb.project_id
+		/*LEFT JOIN project_flingbatch_relation pfp on pfp.project_id=a.id*/
+		left join
+		(select id,status,project_id,filing_batch from
+		(
+		select id,create_date,status,project_id,filing_batch
+		from project_flingbatch_relation order by create_date desc
+		)z
+		group by z.project_id desc
+		) pfp ON pfp.project_id = a.id
+
 		LEFT JOIN project_filingbatch pfb on pfb.id=pfp.filing_batch
 		LEFT JOIN sys_user sua on a.create_by = sua.id
-			LEFT JOIN work_project_user w on a.id = w.project_id
-			LEFT JOIN sys_user su on w.user_id = su.id
-		LEFT JOIN sys_user sub on a.project_master_id = sub.id
-		LEFT JOIN sys_office sob ON sob.id = sub.office_id
 		LEFT JOIN work_project_user w1 on a.id = w1.project_id
+		LEFT JOIN sys_user su on w1.user_id = su.id
 		LEFT JOIN work_contract_info wci on a.contract_id = wci.id
 		LEFT JOIN work_client_info wct on wci.client_id = wct.id
 		LEFT JOIN sys_office o ON o.id = a.office_id
@@ -464,24 +485,9 @@ END) as projectScale*/
 		left join project_report_data_two prdt on prdt.project_id = a.id
 		left join rural_project_report_record prr on prr.report_id = prd.id
 		LEFT JOIN project_material_defect_record pmdr on prd.id = pmdr.report_id
-		left join rural_project_report_record_down prrd on prrd.report_id = prd.id
 		left join project_paper_filing ppf on ppf.project_id = a.id
-		left join project_approval_signature pas on pas.project_id = a.id
-		left join project_report_signature prs on prs.project_id = a.id
-		left join project_report_signature_info prsi on prsi.project_report_id = prd.number
-		/*LEFT JOIN work_invoice_project_relation wip ON wip.project_id = a.id
-		LEFT JOIN work_invoice wi ON wi.id = wip.invoice_id*/
 		<where>
 			a.status = 5
-			<if test="bzshbUserId!=null and bzshbUserId!=''">
-				and prd.bzshb_user_id=#{bzshbUserId}
-			</if>
-			<if test="reportSignatureStatus!=null and reportSignatureStatus!=''">
-				and prs.status=#{reportSignatureStatus}
-			</if>
-			<if test="approvalSignatureStatus!=null and approvalSignatureStatus!=''">
-				and pas.status=#{approvalSignatureStatus}
-			</if>
 			<if test="projectId != null and projectId != ''">
 				AND a.project_id like concat('%',#{projectId},'%')
 			</if>
@@ -539,6 +545,19 @@ END) as projectScale*/
 			<if test="endDate !=null">
 				AND a.create_date &lt; #{endDate}
 			</if>
+			<if test="attachmentProjectSort !=null and attachmentProjectSort != ''">
+				AND a.attachment_project_sort = #{attachmentProjectSort}
+			</if>
+			<if test="engineeringType !=null and engineeringType !=''">
+				and a.engineering_type= #{engineeringType}
+			</if>
+
+			<if test="bzshbUserId!=null and bzshbUserId!=''">
+				and prd.bzshb_user_id=#{bzshbUserId}
+			</if>
+			<if test="projectMaterialStorageStatus !=null and projectMaterialStorageStatus!=''">
+				AND a.project_material_storage_status= #{projectMaterialStorageStatus}
+			</if>
 			<if test="emergencyProject !=null and emergencyProject != ''">
 				<choose>
 					<when test="emergencyProject == 0">
@@ -549,6 +568,23 @@ END) as projectScale*/
 					</otherwise>
 				</choose>
 			</if>
+			<if test="null != defectRecordStatus">
+				<choose>
+					<when test="defectRecordStatus == 0">
+						and pmdr.status is null
+					</when>
+					<otherwise>
+						<choose>
+							<when test="defectRecordStatus == 2">
+								and pmdr.status in (1,2,3,4,6,7)
+							</when>
+							<otherwise>
+								and pmdr.status = 5
+							</otherwise>
+						</choose>
+					</otherwise>
+				</choose>
+			</if>
 			<!--<if test="createBy != null and createBy.id !=null and createBy.id !=''">
 				AND a.create_by = #{createBy.id}
  			</if>-->
@@ -566,9 +602,6 @@ END) as projectScale*/
 								AND( /*pfp.status is null or*/ ppf.status is null )
 							</if>
 						</when>
-						<otherwise>
-							AND( (a.submit_money = 2 and ppf.status is null) or (a.submit_money = 1 and pfp.status is null) )
-						</otherwise>
 					</choose>
 				</when>
 				<otherwise>
@@ -582,9 +615,6 @@ END) as projectScale*/
 									and ppf.status = #{downProjectReportRecordStatus}
 								</if>
 							</when>
-							<otherwise>
-								AND( (a.submit_money = 2 and ppf.status = #{downProjectReportRecordStatus}) or (a.submit_money = 1 and pfp.status = #{downProjectReportRecordStatus}) )
-							</otherwise>
 						</choose>
 
 					</if>
@@ -599,18 +629,13 @@ END) as projectScale*/
 			<if test="office!=null and office.id=='' and office.name!=null and office.name!='' ">
 				and  o.name like concat('%',#{office.name},'%')
 			</if>
+
 			<if test="officeIdList!=null and officeIdList.size!=0">
 				and a.office_id in
 				<foreach collection="officeIdList" item="officeId" separator="," open="(" close=")">
 					#{officeId}
 				</foreach>
 			</if>
-			<if test="permissionOfficeIdList!=null and permissionOfficeIdList.size!=0">
-				and a.office_id in
-				<foreach collection="permissionOfficeIdList" item="officeId" separator="," open="(" close=")">
-					#{officeId}
-				</foreach>
-			</if>
 
 			<if test="reportedState !=null and reportedState !=''">
 				<choose>
@@ -623,28 +648,10 @@ END) as projectScale*/
 				</choose>
 			</if>
 
-			<if test="engineeringType !=null and engineeringType !=''">
-				and a.engineering_type= #{engineeringType}
-			</if>
-			<if test="attachmentProjectSort !=null and attachmentProjectSort !=''">
-				and a.attachment_project_sort= #{attachmentProjectSort}
-			</if>
-			<choose>
-				<when test="projectReportStatus == null">
-
-				</when>
-				<otherwise>
-					<choose>
-						<when test="projectReportStatus != 0">
-							AND prd.status = #{projectReportStatus}
-						</when>
-						<otherwise>
-							AND prd.status is null
-						</otherwise>
-					</choose>
-				</otherwise>
-			</choose>
 
+			<if test="projectReportStatus != null and projectReportStatus != ''">
+				AND prd.status = #{projectReportStatus}
+			</if>
 			<if test="submitMoney != null and submitMoney != ''">
 				AND a.submit_money = #{submitMoney}
 			</if>
@@ -694,10 +701,7 @@ END) as projectScale*/
 
 			AND  a.status != 7 AND a.del_flag = #{DEL_FLAG_NORMAL}
 			<if test="sqlMap.dsf !=null and sqlMap.dsf!=''">
-				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id})${sqlMap.dsf} )
-			</if>
-			<if test="projectMaterialStorageStatus !=null and projectMaterialStorageStatus!=''">
-				AND a.project_material_storage_status= #{projectMaterialStorageStatus}
+				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id} )${sqlMap.dsf} )
 			</if>
 		</where>
 		<choose>
@@ -708,64 +712,97 @@ END) as projectScale*/
 				ORDER BY SUBSTRING(a.project_id,-9) DESC
 			</otherwise>
 		</choose>
+		) temporarydb
+		<where>
+			1=1
+			<choose>
+				<when test="downProjectReportRecordStatus == 0">
+					<choose>
+						<when test="submitMoney !=null and submitMoney !=''">
+							<if test="submitMoney == 1">
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+							</if>
+							<if test="submitMoney == 2">
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+							</if>
+						</when>
+						<otherwise>
+							AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+						</otherwise>
+					</choose>
+				</when>
+				<otherwise>
+					<if test="downProjectReportRecordStatus!=null and downProjectReportRecordStatus !=''">
+						<choose>
+							<when test="submitMoney !=null and submitMoney !=''">
+								<if test="submitMoney == 1">
+									AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat(#{downProjectReportRecordStatus},'%'))
+								</if>
+								<if test="submitMoney == 2">
+									AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat('%',#{downProjectReportRecordStatus}))
+								</if>
+							</when>
+							<otherwise>
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat('%',#{downProjectReportRecordStatus},'%'))
+							</otherwise>
+						</choose>
+
+					</if>
+				</otherwise>
+			</choose>
+		</where>
 	</select>
 
 	<select id="findExportList" resultType="RuralProjectRecordsExport" >
+		select * from (
 		SELECT
-		<include refid="projectRecordsColumns"/>
-		,a.record_state as "recordState"
-		,a.submit_money as "submitMoney"
-		,a.submit_scale as "submitScale"
+		<include refid="newProjectRecordsColumns"/>
+		,wci.contract_num as "workContractInfo.contractNum"
+		,(select name from sys_user user where user.id=a.create_by) AS "createByName"
+		,o.name AS "createByOffice"
+		,sub.name as "projectMasterName"
 		,(case when a.submit_money = '1' then 'B级' when a.submit_money = '2' then 'A级' else '' end) as projectScale
+		,rprr.ZiXunBDE as "ziXunBDE"
+		,ifnull(prd.review_fee ,"") as "reviewFee"
+		,ifnull(prd.approval_fee ,"") as "approvalFee"
+		,ifnull(prd.verify_fee ,"") as "verifyFee"
+		,ifnull(prd.verify_rate ,"") as "verifyRate"
+
 		,(case
-		when a.submit_money = '1' and prd.status = '5' then
-		'已完成'
-		when a.submit_money = '2' and prdt.status = '5' then
-		'已完成' else '未完成'
-		end) as completionStatus
+		when a.submit_money = '1' and pfp.status = '5' then
+		'已归档'
+		when a.submit_money = '2' and ppf.status = '5' then
+		'已归档' else '未归档'
+		end) as downArchiveStatus
+
+		,concat(ifnull( pfp.STATUS, 0 ),ifnull( ppf.STATUS, 0 )) as "downProjectReportRecordPaperFilingStatus"
+		,su.name as "leaderNameStr"
+		,su.id as "leaderNameIds"
+		,a.submit_money as "submitMoney"
 		,a.project_type as projectType,
 		wci.name AS "workContractInfo.name",
-		wci.contract_num as "workContractInfo.contractNum",
-		wci.contract_price as "workContractInfo.contractPrice",
-		sub.name as "projectMasterName",
-		sob.name as "projectMasterOffice",
 		wct.id AS "workContractInfo.client.id",
 		wct.name AS "workContractInfo.client.name",
 		o.top_company AS "office.name",
-		o.name AS "createByOffice",
 		ifnull(prd.number ,"") as "projectReportNumber"
 		,ifnull(prd.status,0) as "projectReportStatus"
 		,ifnull(prd.name,"") as "projectReportName"
-		,ifnull(prr.status,0) as "projectReportRecordStatus"
-		,prr.accomplish_date as "projectReportRecordAuditDate"
-		,(case
-		when a.submit_money = '1' then
-		ifnull(pfp.status,0)
-		when a.submit_money = '2' then
-		ifnull(prrd.status,0) else 0
-		end) as downProjectReportRecordStatus,
-		pfp.audit_pass_date as "projectFlingbatchRelationAuditPassDate",
-		(case
-		when a.submit_money = '1' and pfp.status = '5' then
-		'已归档'
-		when a.submit_money = '2' and ppf.status = '5' then
-		'已归档' else '未归档'
-		end) as downArchiveStatus,
-		/*,ifnull(prrd.status,0) as "downProjectReportRecordStatus"*/
-		prrd.file_num as recodeNum,
-		prr.process_instance_id as prrProcessInstanceId,
-		prrd.process_instance_id as prrdProcessInstanceId
+		,a.project_material_storage_status as "projectMaterialStorageStatus"
+		<choose>
+			<when test="projectReportRecordStatus  != null and projectReportRecordStatus != ''">
+				,ifnull(prr.status,#{projectReportRecordStatus}) as "projectReportRecordStatus"
+			</when>
+			<otherwise>
+				,ifnull(prr.status,0) as "projectReportRecordStatus"
+			</otherwise>
+		</choose>
+		,prr.process_instance_id as prrProcessInstanceId
 		,prd.id as prdId
 		,prr.id as prrId
-		,prrd.id as prrdId
 		,prd.audit_pass_date as auditPassDate
 		,if(date_add(prd.audit_pass_date,interval #{endingCount} day) >now(),"0","1") as reportedType
 		,ifnull(rprr.report_status,0) as "reportStatus"
 		,ifnull(rprr.sync_status,0) as "syncStatus"
-		,ifnull(pas.status,0) as "approvalSignatureStatus"
-		,ifnull(pas.process_instance_id,"") as "approvalSignatureProcessInstanceId"
-		,ifnull(prs.status,0) as "reportSignatureStatus"
-		,ifnull(prs.process_instance_id,"") as "reportSignatureProcessInstanceId"
 		,rprr.process_instance_id as "reportedProcessInstanceId"
 		,ifnull(prdt.status,0) as "projectReportStatusTwo"
 		,prdt.id as prdtId
@@ -774,53 +811,35 @@ END) as projectScale*/
 		,pmdr.process_instance_id as "pmdrProcessInstanceId"
 		,pmdr.id as pmdrId
 		,ifnull(ppf.status,0) as "paperFilingStatus"
-		,ppf.audit_pass_date as "projectPaperAuditPassDate"
 		,ppf.process_instance_id as "ppfProcessInstanceId"
 		,ppf.id as "ppfId"
-		,pfp.filing_batch as "filingBatch"
-		,pfp.box_num as "boxNum"
-		,pfp.re_box_num as "reBoxNum"
-		,pfb.id AS "FilingBatchId"
-		,(select group_concat(su.name) from work_project_user wpu left join sys_user su on su.id = wpu.user_id where wpu.project_id = a.id) as "leaderNameStr"
-		,(select group_concat(su.id) from work_project_user wpu left join sys_user su on su.id = wpu.user_id where wpu.project_id = a.id) as "leaderNameIds"
 		,pfb.process_instance_id AS "filingProcessinstanceId"
-		,pfb.filing_status AS "filingStatus"
 		,ifnull(pfp.status,0) as "filingProjectStatus"
-		,ifnull(prd.approval_fee ,"") as "approvalFee"
-		,ifnull(prd.review_fee ,"") as "reviewFee"
-		,ifnull(prd.verify_fee ,"") as "verifyFee"
-		,ifnull(prd.verify_rate ,"") as "verifyRate"
-		,prd.audit_pass_date as "reportAuditDate"
-		,prdt.audit_pass_date as "reportTwoAuditDate"
-		/*,SUM(wi.money) as "money"*/
+		,prd.audit_pass_date as "prdAuditDate"
 		,prd.ZiXunShouRu as "money"
-		,prd.signature_flag as "signatureFlag"
-		,prd.signature_contract_id as "signatureContractId"
-		,prd.signature_url as "signatureUrl"
-		,a.report_signature_flag as "reportSignatureFlag"
-		,a.report_signature_url as "reportSignatureUrl"
-		,a.report_signature_contract_id as "reportSignatureContractId"
-		,prsi.id as "prsiId"
 		,cb.case_process_id as "caseProcessId"
 		,cb.case_type as "caseType"
 		,cb.case_create_by as "caseCreateBy"
 		,if(case_status > 0 ,case_status,"0") as "caseStatus"
-		,rprr.ZiXunBDE as "ziXunBDE"
-		,rprr.accomplish_date as "projectRecordsReportedAuditPassDate"
-		,a.project_material_storage_status as "projectMaterialStorageStatus"
-		,a.attachment_project_sort as "attachmentProjectSort"
 		FROM rural_project_records a
-		left join case_base cb on a.id = cb.project_id
 		LEFT JOIN sys_area area ON area.id = a.area_id
+		LEFT JOIN sys_user sub on a.project_master_id = sub.id
 		left join rural_project_records_reported rprr on rprr.id = a.id
-		LEFT JOIN project_flingbatch_relation pfp on pfp.project_id=a.id and pfp.del_flag = 0
+		left join case_base cb on a.id = cb.project_id
+		/*LEFT JOIN project_flingbatch_relation pfp on pfp.project_id=a.id*/
+		left join
+		(select id,status,project_id,filing_batch from
+		(
+		select id,create_date,status,project_id,filing_batch
+		from project_flingbatch_relation order by create_date desc
+		)z
+		group by z.project_id desc
+		) pfp ON pfp.project_id = a.id
+
 		LEFT JOIN project_filingbatch pfb on pfb.id=pfp.filing_batch
 		LEFT JOIN sys_user sua on a.create_by = sua.id
-			LEFT JOIN work_project_user w on a.id = w.project_id
-			LEFT JOIN sys_user su on w.user_id = su.id
-		LEFT JOIN sys_user sub on a.project_master_id = sub.id
-		LEFT JOIN sys_office sob ON sob.id = sub.office_id
 		LEFT JOIN work_project_user w1 on a.id = w1.project_id
+		LEFT JOIN sys_user su on w1.user_id = su.id
 		LEFT JOIN work_contract_info wci on a.contract_id = wci.id
 		LEFT JOIN work_client_info wct on wci.client_id = wct.id
 		LEFT JOIN sys_office o ON o.id = a.office_id
@@ -828,24 +847,9 @@ END) as projectScale*/
 		left join project_report_data_two prdt on prdt.project_id = a.id
 		left join rural_project_report_record prr on prr.report_id = prd.id
 		LEFT JOIN project_material_defect_record pmdr on prd.id = pmdr.report_id
-		left join rural_project_report_record_down prrd on prrd.report_id = prd.id
 		left join project_paper_filing ppf on ppf.project_id = a.id
-		left join project_approval_signature pas on pas.project_id = a.id
-		left join project_report_signature prs on prs.project_id = a.id
-		left join project_report_signature_info prsi on prsi.project_report_id = prd.number
-		/*LEFT JOIN work_invoice_project_relation wip ON wip.project_id = a.id
-		LEFT JOIN work_invoice wi ON wi.id = wip.invoice_id*/
 		<where>
 			a.status = 5
-			<if test="bzshbUserId!=null and bzshbUserId!=''">
-				and prd.bzshb_user_id=#{bzshbUserId}
-			</if>
-			<if test="reportSignatureStatus!=null and reportSignatureStatus!=''">
-				and prs.status=#{reportSignatureStatus}
-			</if>
-			<if test="approvalSignatureStatus!=null and approvalSignatureStatus!=''">
-				and pas.status=#{approvalSignatureStatus}
-			</if>
 			<if test="projectId != null and projectId != ''">
 				AND a.project_id like concat('%',#{projectId},'%')
 			</if>
@@ -903,6 +907,19 @@ END) as projectScale*/
 			<if test="endDate !=null">
 				AND a.create_date &lt; #{endDate}
 			</if>
+			<if test="attachmentProjectSort !=null and attachmentProjectSort != ''">
+				AND a.attachment_project_sort = #{attachmentProjectSort}
+			</if>
+			<if test="engineeringType !=null and engineeringType !=''">
+				and a.engineering_type= #{engineeringType}
+			</if>
+
+			<if test="bzshbUserId!=null and bzshbUserId!=''">
+				and prd.bzshb_user_id=#{bzshbUserId}
+			</if>
+			<if test="projectMaterialStorageStatus !=null and projectMaterialStorageStatus!=''">
+				AND a.project_material_storage_status= #{projectMaterialStorageStatus}
+			</if>
 			<if test="emergencyProject !=null and emergencyProject != ''">
 				<choose>
 					<when test="emergencyProject == 0">
@@ -930,9 +947,6 @@ END) as projectScale*/
 								AND( /*pfp.status is null or*/ ppf.status is null )
 							</if>
 						</when>
-						<otherwise>
-							AND( (a.submit_money = 2 and ppf.status is null) or (a.submit_money = 1 and pfp.status is null) )
-						</otherwise>
 					</choose>
 				</when>
 				<otherwise>
@@ -946,14 +960,28 @@ END) as projectScale*/
 									and ppf.status = #{downProjectReportRecordStatus}
 								</if>
 							</when>
-							<otherwise>
-								AND( (a.submit_money = 2 and ppf.status = #{downProjectReportRecordStatus}) or (a.submit_money = 1 and pfp.status = #{downProjectReportRecordStatus}) )
-							</otherwise>
 						</choose>
 
 					</if>
 				</otherwise>
 			</choose>
+			<if test="null != defectRecordStatus">
+				<choose>
+					<when test="defectRecordStatus == 0">
+						and pmdr.status is null
+					</when>
+					<otherwise>
+						<choose>
+							<when test="defectRecordStatus == 2">
+								and pmdr.status in (1,2,3,4,6,7)
+							</when>
+							<otherwise>
+								and pmdr.status = 5
+							</otherwise>
+						</choose>
+					</otherwise>
+				</choose>
+			</if>
 			<if test="reportData!=null and reportData.number !=null and reportData.number !=''">
 				and prd.number like concat('%',#{reportData.number},'%')
 			</if>
@@ -963,18 +991,13 @@ END) as projectScale*/
 			<if test="office!=null and office.id=='' and office.name!=null and office.name!='' ">
 				and  o.name like concat('%',#{office.name},'%')
 			</if>
+
 			<if test="officeIdList!=null and officeIdList.size!=0">
 				and a.office_id in
 				<foreach collection="officeIdList" item="officeId" separator="," open="(" close=")">
 					#{officeId}
 				</foreach>
 			</if>
-			<if test="permissionOfficeIdList!=null and permissionOfficeIdList.size!=0">
-				and a.office_id in
-				<foreach collection="permissionOfficeIdList" item="officeId" separator="," open="(" close=")">
-					#{officeId}
-				</foreach>
-			</if>
 
 			<if test="reportedState !=null and reportedState !=''">
 				<choose>
@@ -987,28 +1010,10 @@ END) as projectScale*/
 				</choose>
 			</if>
 
-			<if test="engineeringType !=null and engineeringType !=''">
-				and a.engineering_type= #{engineeringType}
-			</if>
-			<if test="attachmentProjectSort !=null and attachmentProjectSort !=''">
-				and a.attachment_project_sort= #{attachmentProjectSort}
-			</if>
-			<choose>
-				<when test="projectReportStatus == null">
-
-				</when>
-				<otherwise>
-					<choose>
-						<when test="projectReportStatus != 0">
-							AND prd.status = #{projectReportStatus}
-						</when>
-						<otherwise>
-							AND prd.status is null
-						</otherwise>
-					</choose>
-				</otherwise>
-			</choose>
 
+			<if test="projectReportStatus != null and projectReportStatus != ''">
+				AND prd.status = #{projectReportStatus}
+			</if>
 			<if test="submitMoney != null and submitMoney != ''">
 				AND a.submit_money = #{submitMoney}
 			</if>
@@ -1058,10 +1063,7 @@ END) as projectScale*/
 
 			AND  a.status != 7 AND a.del_flag = #{DEL_FLAG_NORMAL}
 			<if test="sqlMap.dsf !=null and sqlMap.dsf!=''">
-				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id})${sqlMap.dsf} )
-			</if>
-			<if test="projectMaterialStorageStatus !=null and projectMaterialStorageStatus!=''">
-				AND a.project_material_storage_status= #{projectMaterialStorageStatus}
+				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id} )${sqlMap.dsf} )
 			</if>
 		</where>
 		<choose>
@@ -1072,46 +1074,80 @@ END) as projectScale*/
 				ORDER BY SUBSTRING(a.project_id,-9) DESC
 			</otherwise>
 		</choose>
+		) temporarydb
+		<where>
+			1=1
+			<choose>
+				<when test="downProjectReportRecordStatus == 0">
+					<choose>
+						<when test="submitMoney !=null and submitMoney !=''">
+							<if test="submitMoney == 1">
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+							</if>
+							<if test="submitMoney == 2">
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+							</if>
+						</when>
+						<otherwise>
+							AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+						</otherwise>
+					</choose>
+				</when>
+				<otherwise>
+					<if test="downProjectReportRecordStatus!=null and downProjectReportRecordStatus !=''">
+						<choose>
+							<when test="submitMoney !=null and submitMoney !=''">
+								<if test="submitMoney == 1">
+									AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat(#{downProjectReportRecordStatus},'%'))
+								</if>
+								<if test="submitMoney == 2">
+									AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat('%',#{downProjectReportRecordStatus}))
+								</if>
+							</when>
+							<otherwise>
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat('%',#{downProjectReportRecordStatus},'%'))
+							</otherwise>
+						</choose>
+
+					</if>
+				</otherwise>
+			</choose>
+		</where>
 	</select>
 
 
-    <select id="queryCount" resultType="int" >
-		SELECT count(DISTINCT a.id)
+	<select id="queryCount" resultType="int" >
+		select count( id) from (
+		SELECT  (a.id) as id
+		,concat(ifnull( pfp.STATUS, 0 ),ifnull( ppf.STATUS, 0 )) as "downProjectReportRecordPaperFilingStatus"
 		FROM rural_project_records a
+		LEFT JOIN sys_area area ON area.id = a.area_id
+		left join rural_project_records_reported rprr on rprr.id = a.id
 		left join case_base cb on a.id = cb.project_id
+		/*LEFT JOIN project_flingbatch_relation pfp on pfp.project_id=a.id*/
+		left join
+		(select id,status,project_id,filing_batch from
+		(
+		select id,create_date,status,project_id,filing_batch
+		from project_flingbatch_relation order by create_date desc
+		)z
+		group by z.project_id desc
+		) pfp ON pfp.project_id = a.id
 
-		LEFT JOIN work_project_user w on a.id = w.project_id
-		LEFT JOIN sys_user su on w.user_id = su.id
+		LEFT JOIN project_filingbatch pfb on pfb.id=pfp.filing_batch
+		LEFT JOIN sys_user sua on a.create_by = sua.id
 		LEFT JOIN work_project_user w1 on a.id = w1.project_id
-		<if test="workContractInfo !=null">
-			LEFT JOIN work_contract_info wci on a.contract_id = wci.id
-		</if>
-		<if test="workContractInfo!=null and workContractInfo.client !=null and workContractInfo.client.name !=null and workContractInfo.client.name !=''">
-			LEFT JOIN work_client_info wct on wci.client_id = wct.id
-		</if>
+		LEFT JOIN sys_user su on w1.user_id = su.id
+		LEFT JOIN work_contract_info wci on a.contract_id = wci.id
+		LEFT JOIN work_client_info wct on wci.client_id = wct.id
+		LEFT JOIN sys_office o ON o.id = a.office_id
 		left join project_report_data prd on prd.project_id = a.id
 		left join project_report_data_two prdt on prdt.project_id = a.id
 		left join rural_project_report_record prr on prr.report_id = prd.id
 		LEFT JOIN project_material_defect_record pmdr on prd.id = pmdr.report_id
-		left join rural_project_report_record_down prrd on prrd.report_id = prd.id
-		LEFT JOIN project_flingbatch_relation pfp on pfp.project_id= a.id
-		LEFT JOIN sys_user sua on a.create_by = sua.id
 		left join project_paper_filing ppf on ppf.project_id = a.id
-		LEFT JOIN sys_office o ON o.id = a.office_id
-		left join project_approval_signature pas on pas.project_id = a.id
-		left join project_report_signature prs on prs.project_id = a.id
-		left join project_report_signature_info prsi on prsi.project_report_id = prd.number
 		<where>
 			a.status = 5
-			<if test="reportSignatureStatus!=null and reportSignatureStatus!=''">
-				and prs.status=#{reportSignatureStatus}
-			</if>
-			<if test="approvalSignatureStatus!=null and approvalSignatureStatus!=''">
-				and pas.status=#{approvalSignatureStatus}
-			</if>
-			<if test="bzshbUserId!=null and bzshbUserId!=''">
-				and prd.bzshb_user_id=#{bzshbUserId}
-			</if>
 			<if test="projectId != null and projectId != ''">
 				AND a.project_id like concat('%',#{projectId},'%')
 			</if>
@@ -1169,6 +1205,22 @@ END) as projectScale*/
 			<if test="endDate !=null">
 				AND a.create_date &lt; #{endDate}
 			</if>
+			<if test="attachmentProjectSort !=null and attachmentProjectSort != ''">
+				AND a.attachment_project_sort = #{attachmentProjectSort}
+			</if>
+			<if test="attachmentProjectSort !=null and attachmentProjectSort !=''">
+				and a.attachment_project_sort= #{attachmentProjectSort}
+			</if>
+			<if test="engineeringType !=null and engineeringType !=''">
+				and a.engineering_type= #{engineeringType}
+			</if>
+
+			<if test="bzshbUserId!=null and bzshbUserId!=''">
+				and prd.bzshb_user_id=#{bzshbUserId}
+			</if>
+			<if test="projectMaterialStorageStatus !=null and projectMaterialStorageStatus!=''">
+				AND a.project_material_storage_status= #{projectMaterialStorageStatus}
+			</if>
 			<if test="emergencyProject !=null and emergencyProject != ''">
 				<choose>
 					<when test="emergencyProject == 0">
@@ -1197,9 +1249,6 @@ END) as projectScale*/
 								AND( /*pfp.status is null or*/ ppf.status is null )
 							</if>
 						</when>
-						<otherwise>
-							AND( (a.submit_money = 2 and ppf.status is null) or (a.submit_money = 1 and pfp.status is null) )
-						</otherwise>
 					</choose>
 				</when>
 				<otherwise>
@@ -1213,56 +1262,47 @@ END) as projectScale*/
 									and ppf.status = #{downProjectReportRecordStatus}
 								</if>
 							</when>
-							<otherwise>
-								AND( (a.submit_money = 2 and ppf.status = #{downProjectReportRecordStatus}) or (a.submit_money = 1 and pfp.status = #{downProjectReportRecordStatus}) )
-							</otherwise>
 						</choose>
 
 					</if>
 				</otherwise>
 			</choose>
+
+			<if test="null != defectRecordStatus">
+				<choose>
+					<when test="defectRecordStatus == 0">
+						and pmdr.status is null
+					</when>
+					<otherwise>
+						<choose>
+							<when test="defectRecordStatus == 2">
+								and pmdr.status in (1,2,3,4,6,7)
+							</when>
+							<otherwise>
+								and pmdr.status = 5
+							</otherwise>
+						</choose>
+					</otherwise>
+				</choose>
+			</if>
 			<if test="reportData!=null and reportData.number !=null and reportData.number !=''">
 				and prd.number like concat('%',#{reportData.number},'%')
 			</if>
-			<if test="engineeringType !=null and engineeringType !=''">
-				and a.engineering_type= #{engineeringType}
-			</if>
-			<if test="attachmentProjectSort !=null and attachmentProjectSort !=''">
-				and a.attachment_project_sort= #{attachmentProjectSort}
-			</if>
 			<!--<if test="office!=null and office.id!=null and office.id!=''">
 				and  a.office_id = #{office.id}
 			</if>-->
 			<if test="office!=null and office.id=='' and office.name!=null and office.name!='' ">
 				and  o.name like concat('%',#{office.name},'%')
 			</if>
-			<if test="permissionOfficeIdList!=null and permissionOfficeIdList.size!=0">
-				and a.office_id in
-				<foreach collection="permissionOfficeIdList" item="officeId" separator="," open="(" close=")">
-					#{officeId}
-				</foreach>
-			</if>
 			<if test="officeIdList!=null and officeIdList.size!=0">
 				and a.office_id in
 				<foreach collection="officeIdList" item="officeId" separator="," open="(" close=")">
 					#{officeId}
 				</foreach>
 			</if>
-			<choose>
-				<when test="projectReportStatus == null">
-
-				</when>
-				<otherwise>
-					<choose>
-						<when test="projectReportStatus != 0">
-							AND prd.status = #{projectReportStatus}
-						</when>
-						<otherwise>
-							AND prd.status is null
-						</otherwise>
-					</choose>
-				</otherwise>
-			</choose>
+			<if test="projectReportStatus != null and projectReportStatus != ''">
+				AND prd.status = #{projectReportStatus}
+			</if>
 			<if test="reportedState !=null and reportedState !=''">
 				<choose>
 					<when test="reportedState == 0">
@@ -1322,11 +1362,47 @@ END) as projectScale*/
 			<if test="sqlMap.dsf !=null and sqlMap.dsf!=''">
 				AND ((w1.user_id = #{currentUser.id} AND w1.del_flag='0' AND a.company_id = #{currentUser.company.id})${sqlMap.dsf} )
 			</if>
-			<if test="projectMaterialStorageStatus !=null and projectMaterialStorageStatus!=''">
-				AND a.project_material_storage_status= #{projectMaterialStorageStatus}
-			</if>
+		</where>) temporarydb
+		<where>
+			1=1
+			<choose>
+				<when test="downProjectReportRecordStatus == 0">
+					<choose>
+						<when test="submitMoney !=null and submitMoney !=''">
+							<if test="submitMoney == 1">
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+							</if>
+							<if test="submitMoney == 2">
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+							</if>
+						</when>
+						<otherwise>
+							AND( temporarydb.downProjectReportRecordPaperFilingStatus = '00')
+						</otherwise>
+					</choose>
+				</when>
+				<otherwise>
+					<if test="downProjectReportRecordStatus!=null and downProjectReportRecordStatus !=''">
+						<choose>
+							<when test="submitMoney !=null and submitMoney !=''">
+								<if test="submitMoney == 1">
+									AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat(#{downProjectReportRecordStatus},'%'))
+								</if>
+								<if test="submitMoney == 2">
+									AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat('%',#{downProjectReportRecordStatus}))
+								</if>
+							</when>
+							<otherwise>
+								AND( temporarydb.downProjectReportRecordPaperFilingStatus like concat('%',#{downProjectReportRecordStatus},'%'))
+							</otherwise>
+						</choose>
+
+					</if>
+				</otherwise>
+			</choose>
 		</where>
-    </select>
+
+	</select>
 
 	<select id="findListOnUndocumentedRecordDownload" resultType="DownloadProjectRecords" >
 		SELECT

+ 32 - 2
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordReportDao.xml

@@ -3,11 +3,11 @@
 <mapper namespace="com.jeeplus.modules.ruralprojectrecords.dao.RuralProjectRecordReportDao">
     
 	<sql id="ruralProjectInfoColumns">
-		distinct a.id AS "id",
+		 a.id AS "id",
 		year(a.create_date) as "year",
 		month(a.create_date) as "month",
 		a.create_by AS "createBy.id",
-		(select name from sys_user user where user.id=a.create_by) AS "createBy.name",
+		u.name AS "createBy.name",
 		a.create_date AS "createDate",
 		a.update_by AS "updateBy.id",
 		a.update_date AS "updateDate",
@@ -199,4 +199,34 @@
 		</where>
 		ORDER BY a.create_date DESC
 	</select>
+
+	<select id="findPageHomeCount" resultType="long" >
+		SELECT
+		count(a.id)
+		FROM rural_project_records a
+		LEFT JOIN project_report_data prd ON prd.project_id = a.id
+		LEFT JOIN rural_project_report_record prr ON prr.report_id = prd.id
+		LEFT JOIN work_project_user w1 ON a.id = w1.project_id
+		<where>
+			a.del_flag = 0
+			<if test="typeList !=null and typeList !=''">
+				and project_type in
+				<foreach collection="typeList" item="id" index="index" open="(" close=")" separator=",">
+					#{id}
+				</foreach>
+			</if>
+			<!--and (
+			(((prr.status != 5 or prr.status is null) and (a.reported_state!=5 or a.reported_state is null) and date_add(prd.update_date,interval 40 day)>= now())
+			or ((prr.status != 5 or prr.status is null) and (a.reported_state!=5 or a.reported_state is null) and prd.update_date is null))
+			or ((prr.status = 5 and (a.reported_state!=5 or a.reported_state is null) and date_add(prd.update_date,interval 40 day)>= now())
+			or (prr.status = 5 and (a.reported_state!=5 or a.reported_state is null) and prd.update_date is null))
+			or (((prr.status != 5 or prr.status is null) and a.reported_state=5 and date_add(prd.update_date,interval 40 day)>= now())
+			or ((prr.status != 5 or prr.status is null) and a.reported_state=5 and prd.update_date is null))
+			)-->
+			and (a.create_by = #{createBy.id} or w1.user_id = #{createBy.id})
+			and ((prr.status != 5 or prr.status is null) or (a.reported_state is null or a.reported_state not in ('5','7')))
+			and a.status = 5
+		</where>
+		ORDER BY a.create_date DESC
+	</select>
 </mapper>

文件差异内容过多而无法显示
+ 774 - 209
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordsDao.xml


+ 34 - 4
src/main/resources/mappings/modules/statement/StatementCompanyComprehensiveDao.xml

@@ -83,7 +83,11 @@
 			field5,
 			field6,
 			field7,
-			field8
+			field8,
+			field9,
+			field10,
+			field11,
+			field12
 		) VALUES (
 			#{createDate},
 			#{year},
@@ -99,7 +103,11 @@
 			#{field5},
 			#{field6},
 			#{field7},
-			#{field8}
+			#{field8},
+			#{field9},
+			#{field10},
+			#{field11},
+			#{field12}
 
 		)
 	</insert>
@@ -684,6 +692,8 @@
 			,field2
 			,field3
 			,field4
+			,field5
+			,field6
 		)
 		VALUES
 		<foreach collection="dataList" item="data" separator=",">
@@ -700,6 +710,8 @@
 				,#{data.field2}
 				,#{data.field3}
 				,#{data.field4}
+				,#{data.field5}
+				,#{data.field6}
 			)
 		</foreach>
 	</insert>
@@ -1747,6 +1759,8 @@
 		,field2
 		,field3
 		,field4
+		,field5
+		,field6
 		)
 		VALUES
 		<foreach collection="dataList" item="data" separator=",">
@@ -1763,6 +1777,8 @@
 			,#{data.field2}
 			,#{data.field3}
 			,#{data.field4}
+			,#{data.field5}
+			,#{data.field6}
 			)
 		</foreach>
 	</insert>
@@ -1783,7 +1799,9 @@
 			field4,
 			field5,
 			field6,
-			field7
+			field7,
+			field8,
+			field9
 		) VALUES (
 			#{createDate},
 			#{year},
@@ -1798,7 +1816,9 @@
 			#{field4},
 			#{field5},
 			#{field6},
-			#{field7}
+			#{field7},
+			#{field8},
+			#{field9}
 
 		)
 	</insert>
@@ -1849,6 +1869,8 @@
 		a.field5 as "field5",
 		a.field6 as "field6",
 		a.field7 as "field7",
+		a.field8 as "field8",
+		a.field9 as "field9",
 		(select name from sys_office where id = office_id) officeName
 		from statement_audit_office_data_info a
 		<where>
@@ -1884,6 +1906,14 @@
 			<if test="field4 != null and field4 != ''">
 				and field4 = #{field4}
 			</if>
+
+			<if test="field5 != null and field5 != ''">
+				and field5 = #{field5}
+			</if>
+
+			<if test="field6 != null and field6 != ''">
+				and field6 = #{field6}
+			</if>
 		</where>
 	</delete>
 

+ 26 - 10
src/main/resources/mappings/modules/workinvoice/WorkInvoiceDao.xml

@@ -73,12 +73,10 @@
 	</sql>
 
 	<sql id="newWorkInvoiceColumns">
-		DISTINCT(a.id) AS "id",
+		(a.id) AS "id",
 		a.number AS "number",
 		a.process_instance_id AS "processInstanceId",
 		a.client_id AS "client.id",
-		a.project_id AS "project.id",
-		a.project_name AS "projectName",
 		a.money AS "money",
 		a.money AS "moneyStr",
 		a.invoice_type AS "invoiceType",
@@ -126,7 +124,7 @@
 		a.ext AS "ext",
 		a.billing_content as "billingContent",
 		p.area_name as "project.county",
-		a.receipt_money_date as "receiptMoneyDate",
+		/*a.receipt_money_date as "receiptMoneyDate",*/
 		(case when a.receipt_money = '0' then '否' when a.receipt_money = '1' then '是' when a.receipt_money = '2' then '部分收款' else '否' end) as receiptMoney,
 		a.cancellation_remark as "cancellationRemark",
 		a.account_checking_user_id as "accountCheckingUserId",
@@ -642,7 +640,24 @@
 		SELECT
 		<include refid="newWorkInvoiceColumns"/>
 		,wid.number as "widNumber"
-		,wid.total_money as "widTotalMoney"
+		,wid.total_money as "widTotalMoney",
+		(select
+		CASE
+		WHEN RIGHT( GROUP_CONCAT(is_project),1) =2 THEN GROUP_CONCAT(concat('其他:',wipr1.details))
+		WHEN RIGHT( GROUP_CONCAT(is_project),1) =1 THEN GROUP_CONCAT(rpr1.project_name)
+		ELSE '' END
+		FROM work_invoice_project_relation wipr1
+		LEFT JOIN rural_project_records rpr1 ON wipr1.project_id = rpr1.id
+		LEFT JOIN project_report_data prd1 ON prd1.project_id = wipr1.project_id
+		WHERE wipr1.invoice_id = a.id) as projectName
+		,(select
+		GROUP_CONCAT(prd1.number)
+		FROM work_invoice_project_relation wipr1
+		LEFT JOIN rural_project_records rpr1 ON wipr1.project_id = rpr1.id
+		LEFT JOIN project_report_data prd1 ON prd1.project_id = wipr1.project_id
+		WHERE wipr1.invoice_id = a.id) as reportNumber,
+		(select wir.receipt_date from work_invoice_receipt wir where wir.invoice_id = a.id order by wir.receipt_date desc limit 1 ) as "receiptMoneyDate",
+		ifnull((select sum(wir.money) from work_invoice_receipt wir where wir.invoice_id = a.id ),0) as "receiptMoneyD"
 		FROM work_invoice a
 		LEFT JOIN sys_user su ON su.id = a.create_by
 		LEFT JOIN work_client_info w ON  w.id = a.client_id
@@ -745,7 +760,7 @@
 
 
 	<select id="queryCountNew" resultType="int" >
-		SELECT count(DISTINCT(a.id))
+		SELECT count((a.id))
 		FROM work_invoice a
 		LEFT JOIN sys_user su ON su.id = a.create_by
 		LEFT JOIN work_client_info w ON  w.id = a.client_id
@@ -887,8 +902,7 @@
 		a.ext AS "ext",
 		a.billing_content as "billingContent",
 		p.area_name as "project.county",
-		a.receipt_money_date as "receiptMoneyDate",
-		(case when a.receipt_money = '0' then '否' when a.receipt_money = '1' then '是' else '否' end) as receiptMoney,
+		(case when a.receipt_money = '0' then '否' when a.receipt_money = '1' then '是' when a.receipt_money = '2' then '部分收款' else '否' end) as receiptMoney,
 		a.cancellation_remark as "cancellationRemark",
 		a.account_checking_user_id as "accountCheckingUserId",
 		a.area_id as "area.id",
@@ -912,7 +926,9 @@
 		FROM work_invoice_project_relation wipr1
 		LEFT JOIN rural_project_records rpr1 ON wipr1.project_id = rpr1.id
 		LEFT JOIN project_report_data prd1 ON prd1.project_id = wipr1.project_id
-		WHERE wipr1.invoice_id = a.id) as reportNumber
+		WHERE wipr1.invoice_id = a.id) as reportNumber,
+		(select wir.receipt_date from work_invoice_receipt wir where wir.invoice_id = a.id order by wir.receipt_date desc limit 1 ) as "receiptMoneyDate",
+		ifnull((select sum(wir.money) from work_invoice_receipt wir where wir.invoice_id = a.id ),0) as "receiptMoneyD"
 		FROM work_invoice a
 		LEFT JOIN sys_user su ON su.id = a.create_by
 		LEFT JOIN work_client_info w ON  w.id = a.client_id
@@ -1008,7 +1024,7 @@
 				ORDER BY ${page.orderBy}
 			</when>
 			<otherwise>
-				ORDER BY a.create_date DESC
+				ORDER BY a.create_date DESC,a.number desc, wid.total_money+0 desc
 			</otherwise>
 		</choose>
 	</select>

+ 0 - 1
src/main/resources/mappings/modules/workreimbursement/WorkReimbursementDao.xml

@@ -8,7 +8,6 @@
 		a.number AS "number",
 		a.business_type AS "businessType",
 		a.submitter_id AS "handleId",
-		a.submitter_id AS "submitterId",
 		a.submitter AS "submitter",
 		a.submitter_date AS "submitterDate",
 		a.project_id AS "project.id",

二进制
src/main/webapp/dot/材料库处理表模板.xlsx


+ 50 - 4
src/main/webapp/webpage/modules/projectMaterialStorage/projectMaterialStorageForm.jsp

@@ -41,6 +41,12 @@
 					}
 				}
 			});
+			laydate.render({
+				elem: '#quotedPriceDate', //目标元素。由于laydate.js封装了一个轻量级的选择器引擎,因此elem还允许你传入class、tag但必须按照这种方式 '#id .class'
+				event: 'focus', //响应事件。如果没有传入event,则按照默认的click
+				type : 'date'
+				, trigger: 'click'
+			});
 		});
 		function addRow1(list, idx, tpl, row){
 			var idx1 = $("#projectMaterialStorageList tr").length;
@@ -74,6 +80,14 @@
 					}
 				}
 			});
+
+			laydate.render({
+				elem : (list+idx+"_quotedPriceDate"),
+				event: 'focus',
+				type : 'date'
+				, trigger: 'click',
+				trigger: 'click'
+			});
 		}
 		function f1(row) {
 			// window.parent.document.getElementById('opinion').value = row;
@@ -165,10 +179,18 @@
 					<thead>
 					<tr>
 						<th width="200px"><font color="red">*</font>材料名称</th>
-						<th width="200px"><font color="red">*</font>价格</th>
+						<th width="150px">品牌</th>
+						<th width="200px"><font color="red">*</font>规格型号</th>
+						<th width="100px">含税工程价(元)</th>
+						<th width="100px">含税市场价(元)</th>
+						<th width="100px">税率</th>
+						<th width="100px"><font color="red">*</font>单位</th>
+						<th width="200px">产品说明</th>
+						<th width="100px">供应商</th>
+						<th width="200px">备注</th>
 <%--						<th width="200px">单位</th>--%>
-						<th width="200px"><font color="red">*</font>单位</th>
-						<th width="200px">操作</th>
+						<th width="100px">报价时间</th>
+						<th width="100px">操作</th>
 					</tr>
 					</thead>
 					<tbody id="projectMaterialStorageList">
@@ -184,11 +206,35 @@
 							<input id="projectMaterialStorageList{{idx}}_materialName" name = "projectMaterialStorageList[{{idx}}].materialName"  type="text" value="{{row.materialName}}"  class="form-control"/>
                         </td>
                         <td>
-							<input id="projectMaterialStorageList{{idx}}_price" name = "projectMaterialStorageList[{{idx}}].price"   type="text" value="{{row.price}}"   onkeyup="num(this)" class="form-control"/>
+							<input id="projectMaterialStorageList{{idx}}_brand" name = "projectMaterialStorageList[{{idx}}].brand"  type="text" value="{{row.brand}}"  class="form-control"/>
+                        </td>
+                        <td>
+							<input id="projectMaterialStorageList{{idx}}_specifications" name = "projectMaterialStorageList[{{idx}}].specifications"  type="text" value="{{row.specifications}}"  class="form-control"/>
+                        </td>
+                        <td>
+							<input id="projectMaterialStorageList{{idx}}_projectPriceIncludingTax" name = "projectMaterialStorageList[{{idx}}].projectPriceIncludingTax"  type="text" value="{{row.projectPriceIncludingTax}}" onkeyup="num(this)"  class="form-control"/>
+                        </td>
+                        <td>
+							<input id="projectMaterialStorageList{{idx}}_marketPriceIncludingTax" name = "projectMaterialStorageList[{{idx}}].marketPriceIncludingTax"  type="text" value="{{row.marketPriceIncludingTax}}" onkeyup="num(this)"  class="form-control"/>
+                        </td>
+                        <td>
+							<input id="projectMaterialStorageList{{idx}}_taxRate" name = "projectMaterialStorageList[{{idx}}].taxRate"  type="text" value="{{row.taxRate}}" onkeyup="num(this)"  class="form-control"/>
                         </td>
                         <td>
 							<input id="projectMaterialStorageList{{idx}}_unit" name = "projectMaterialStorageList[{{idx}}].unit"  type="text" value="{{row.unit}}"  class="form-control"/>
                         </td>
+                        <td>
+							<input id="projectMaterialStorageList{{idx}}_explain" name = "projectMaterialStorageList[{{idx}}].explain"  type="text" value="{{row.explain}}"  class="form-control"/>
+                        </td>
+                        <td>
+							<input id="projectMaterialStorageList{{idx}}_supplier" name = "projectMaterialStorageList[{{idx}}].supplier"  type="text" value="{{row.supplier}}"  class="form-control"/>
+                        </td>
+                        <td>
+							<input id="projectMaterialStorageList{{idx}}_remarks" name = "projectMaterialStorageList[{{idx}}].remarks"  type="text" value="{{row.remarks}}"  class="form-control"/>
+                        </td>
+						<td>
+							<input lay-verify="date" readonly="true" placeholder="yyyy-MM-dd" autocomplete="off" id="projectMaterialStorageList{{idx}}_quotedPriceDate" name="projectMaterialStorageList[{{idx}}].quotedPriceDate" type="text" value="{{row.quotedPriceDate}}" style="text-align: center" class="form-control datetime"/>
+						</td>
                         <td class="text-center op-td" >
                             {{#delBtn}}<span class="op-btn op-btn-delete" onclick="delRow(this, '#projectMaterialStorageList{{idx}}')" title="删除"><i class="glyphicon glyphicon-remove"></i>&nbsp;删除</span>{{/delBtn}}
                         </td>

+ 171 - 155
src/main/webapp/webpage/modules/projectMaterialStorage/projectMaterialStorageList.jsp

@@ -1,5 +1,9 @@
+<%@ page import="com.jeeplus.modules.sys.utils.UserUtils" %>
 <%@ page contentType="text/html;charset=UTF-8" %>
 <%@ include file="/webpage/include/taglib.jsp"%>
+<%
+	boolean admin = UserUtils.getUser().isAdmin();
+%>
 <html>
 <head>
 	<title>材料库</title>
@@ -53,6 +57,18 @@
                 type : 'date'
 , trigger: 'click'
             });
+            laydate.render({
+                elem: '#beginQuotedPriceDate', //目标元素。由于laydate.js封装了一个轻量级的选择器引擎,因此elem还允许你传入class、tag但必须按照这种方式 '#id .class'
+                event: 'focus', //响应事件。如果没有传入event,则按照默认的click
+                type : 'date'
+, trigger: 'click'
+            });
+            laydate.render({
+                elem: '#endQuotedPriceDate', //目标元素。由于laydate.js封装了一个轻量级的选择器引擎,因此elem还允许你传入class、tag但必须按照这种方式 '#id .class'
+                event: 'focus', //响应事件。如果没有传入event,则按照默认的click
+                type : 'date'
+, trigger: 'click'
+            });
         });
 
         function reset() {
@@ -215,7 +231,7 @@
             });
         }
 	</script>
-	<style>
+<%--	<style>
 		body{
 			background-color:transparent;
 			filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#26FFFFFF, endColorstr=#26FFFFFF);
@@ -223,7 +239,7 @@
 			background-color:rgba(255,255,255,0);
 			height:100%;
 		}
-	</style>
+	</style>--%>
 	<script>
 
 		function notifyDialogre(title,url,width,height,target){
@@ -286,21 +302,6 @@
 	<sys:message content="${message}"/>
 	<div class="layui-row">
 		<div class="full-width fl">
-			<%--<div class="list-form-tab contentShadow shadowLTR" id="tabDiv">
-				<ul class="list-tabs" >
-					<li class="active"><a href="${ctx}/ruralProject/ruralProjectRecords/list">项目登记列表</a></li>
-					<li><a href="${ctx}/ruralProject/ruralProjectRecordsAlter/list">项目变更列表</a></li>
-				</ul>
-			</div>--%>
-
-			<%--<div class="layui-row" id="tabDiv">--%>
-			<%--<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">--%>
-			<%--<ul class="layui-tab-title">--%>
-			<%--<li class="layui-this"><a href="${ctx}/project/projectRecords/list">项目登记列表</a></li>--%>
-			<%--<li><a href="${ctx}/project/projectRecordsAlter/list">项目变更列表</a></li>--%>
-			<%--</ul>--%>
-			<%--</div>--%>
-			<%--</div>--%>
 		</div>
 		<div class="full-width fl">
 			<div class="layui-row contentShadow shadowLR" id="queryDiv">
@@ -310,89 +311,125 @@
 					<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="margin-top: 10px">
-<%--							<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>--%>
-
-							<label class="layui-form-label">项目名称</label>
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label">项目名称:</label>
 							<div class="layui-input-block">
 										<sys:gridselectprojectmaterial url="${ctx}/project/projectMaterialStorage/selectproject" id="project" name="projectNumber"  value="${projectMaterialStorage.projectName}"  title="选择所属项目" labelName="projectName" cssStyle="background-color: #fff"
 									   labelValue="${projectMaterialStorage.projectName}" cssClass="form-control required layui-input" fieldLabels="项目名称" fieldKeys="projectName" searchLabel="项目名称" searchKey="projectName"  ></sys:gridselectprojectmaterial>
 
 							</div>
 						</div>
-					<div class="commonQuery lw6">
-<%--						<div class="layui-item query athird">--%>
-<%--							<label class="layui-form-label">材料名称:</label>--%>
-<%--							<div class="layui-input-block">--%>
-<%--								<form:input path="materialName" htmlEscape="false" maxlength="64"  class=" form-control  layui-input" />--%>
-<%--						</div>--%>
-						<div class="layui-item query athird">
+						<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"/>
+								<form:input path="projectId" htmlEscape="false" placeholder="请输入报告号"  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">
+								<form:input path="materialName" htmlEscape="false" placeholder="请输入材料名称" maxlength="64"  class=" form-control  layui-input" />
 							</div>
 						</div>
-					</div>
 
-						<div class="layui-item athird">
-							<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>
-<%--								<a href="#" id="moresee"><i class="glyphicon glyphicon-menu-down"></i></a>--%>
-<%--								<button id="searchReset" class="fixed-btn searchReset fr" onclick="resetSearch()">重置</button>--%>
-<%--								<button id="searchQuery" class="fixed-btn searchQuery fr" onclick="search()">查询</button>--%>
+						<div class="input-group"  style="width: 25%">
+							<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 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">--%>
-<%--								<form:input path="projectId" htmlEscape="false" maxlength="64"  class=" form-control  layui-input"/>--%>
-<%--							</div>--%>
-<%--						</div>--%>
-						<div class="layui-item query athird">
-							<label class="layui-form-label">材料名称:</label>
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label">品牌:</label>
 							<div class="layui-input-block">
-								<form:input path="materialName" htmlEscape="false" maxlength="64"  class=" form-control  layui-input" />
+								<form:input path="brand" htmlEscape="false" placeholder="请输入品牌" maxlength="64"  class=" form-control  layui-input" />
 							</div>
 						</div>
 
-						<%--<div class="layui-item query athird">
-							<label class="layui-form-label">地点:</label>
-							<div class="layui-input-block with-icon">
-								<form:input path="areaName" htmlEscape="false" maxlength="64"  class=" form-control  layui-input"/>
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label">规格型号:</label>
+							<div class="layui-input-block">
+								<form:input path="specifications" htmlEscape="false" placeholder="请输入规格型号" maxlength="64"  class=" form-control  layui-input" />
+							</div>
+						</div>
+
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label double-line">含税工程价:</label>
+							<div class="layui-input-block">
+								<input id="beginProjectPriceIncludingTax" value="${projectMaterialStorage.beginProjectPriceIncludingTax}" name="beginProjectPriceIncludingTax" placeholder="请输入含税工程价(元)" htmlEscape="false" maxlength="64"  class="query-group form-control  layui-input">
+								<span class="group-sep">-</span>
+								<input id="endProjectPriceIncludingTax" value="${projectMaterialStorage.endProjectPriceIncludingTax}" name="endProjectPriceIncludingTax" placeholder="请输入含税工程价(元)" htmlEscape="false" maxlength="64"  class="query-group form-control  layui-input">
+							</div>
+						</div>
+
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label double-line">含税市场价:</label>
+							<div class="layui-input-block">
+								<input id="beginMarketPriceIncludingTax" value="${projectMaterialStorage.beginMarketPriceIncludingTax}" name="beginMarketPriceIncludingTax" placeholder="请输入含税市场价(元)" htmlEscape="false" maxlength="64"  class="query-group form-control  layui-input">
+								<span class="group-sep">-</span>
+								<input id="endMarketPriceIncludingTax" value="${projectMaterialStorage.endMarketPriceIncludingTax}" name="endMarketPriceIncludingTax" placeholder="请输入含税市场价(元)" htmlEscape="false" maxlength="64"  class="query-group 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">
+								<input id="beginTaxRate" name="beginTaxRate" value="${projectMaterialStorage.beginTaxRate}" placeholder="请输入利率" htmlEscape="false" maxlength="64"  class="query-group form-control  layui-input">
+								<span class="group-sep">-</span>
+								<input id="endTaxRate" name="endTaxRate" value="${projectMaterialStorage.endTaxRate}" placeholder="请输入利率" htmlEscape="false" maxlength="64"  class=" form-control layui-input query-group">
 							</div>
 						</div>
-						<div class="layui-item query athird ">
+
+						<div class="layui-item query athird" style="width: 25%">
+							<label class="layui-form-label">单位:</label>
+							<div class="layui-input-block">
+								<form:input path="unit" htmlEscape="false" placeholder="请输入单位" 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">
+								<form:input path="explain" htmlEscape="false" maxlength="64" placeholder="请输入产品名称" 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="supplier" htmlEscape="false" maxlength="64"  placeholder="请输入供应商" 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 readOnlyFFF">
+								<input id="beginQuotedPriceDate" name="beginQuotedPriceDate" placeholder="报价开始时间" type="text" readonly="readonly" maxlength="20" class="laydate-icondate form-control layer-date layui-input laydate-icon query-group"
+									   value="<fmt:formatDate value="${projectMaterialStorage.beginQuotedPriceDate}" pattern="yyyy-MM-dd"/>"/>
+								</input>
+								<span class="group-sep">-</span>
+								<input id="endQuotedPriceDate" name="endQuotedPriceDate" placeholder="报价结束时间" type="text" readonly="readonly" maxlength="20" class="laydate-icondate form-control layer-date layui-input laydate-icon query-group"
+									   value="<fmt:formatDate value="${projectMaterialStorage.endQuotedPriceDate}" pattern="yyyy-MM-dd"/>"/>
+								</input>
+							</div>
+						</div>
+
+						<div class="layui-item query athird " style="width: 25%">
 							<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="${projectRecords.beginDate}" pattern="yyyy-MM-dd"/>"/>
+								<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="${projectMaterialStorage.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="${projectRecords.endDate}" pattern="yyyy-MM-dd"/>"/>
+                                <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="${projectMaterialStorage.endDate}" pattern="yyyy-MM-dd"/>"/>
                                 </input>
 							</div>
-						</div>--%>
-<%--						<div class="layui-item query athird ">--%>
-<%--							<label class="layui-form-label">状态:</label>--%>
-<%--							<div class="layui-input-block">--%>
-<%--								<form:select path="projectStatus" class=" form-control  simple-select">--%>
-<%--									<form:option value="" label=""/>--%>
-<%--									<form:options items="${fns:getRuralDictList('rural_project_audit_state')}" itemLabel="label" itemValue="value" htmlEscape="false"/>--%>
-<%--								</form:select>--%>
-<%--							</div>--%>
-<%--						</div>--%>
+						</div>
 
 						<div style="clear:both;"></div>
 					</div>
@@ -405,18 +442,14 @@
 					<%--此处按钮样式包括 nav-btn-add nav-btn-refresh nav-btn-import nav-btn-export nav-btn-query nav-btn-reset--%>
 					<div class="layui-btn-group">
 						<table:addRow url="${ctx}/project/projectMaterialStorage/formTwoPage?isAdd=0" title="添加材料"></table:addRow><!-- 增加按钮 -->
+						<%--<shiro:hasPermission name="project:pojectMaterialsWarehouse:list">--%>
+							<button type="button" data-toggle="tooltip" data-placement="top" class="layui-btn layui-btn-sm layui-bg-red" id="delProjectMaterialStorage"> 批量删除</button>
+						<%--</shiro:hasPermission>--%>
 						<button class="layui-btn layui-btn-sm" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
 						</div>
-<%--					<shiro:hasPermission name="ruralProject:ruralProjectRecords:add">--%>
-<%--						<table:addRow url="${ctx}/ruralProject/ruralProjectRecords/form" title="项目"></table:addRow><!-- 增加按钮 -->--%>
-<%--					</shiro:hasPermission>--%>
 <%--					<shiro:hasPermission name="ruralProject:ruralProjectRecords:export">--%>
 <%--						<table:exportExcel url="${ctx}/ruralProject/ruralProjectRecords/export"></table:exportExcel><!-- 导出按钮 -->--%>
 <%--					</shiro:hasPermission>--%>
-<%--					<shiro:hasPermission name="ruralProject:ruralProjectRecords:exportAll">--%>
-<%--						<button type="button" data-toggle="tooltip" data-placement="top" class="nav-btn nav-btn-delete" id="delUser"><i class="fa fa-file-excel-o"> 批量下载</i></button>--%>
-<%--					</shiro:hasPermission>--%>
-<%--					<button class="nav-btn nav-btn-refresh" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"><i class="glyphicon glyphicon-repeat"></i>&nbsp;刷新</button>--%>
 					<div style="clear: both;"></div>
 				</div>
 				<table class="oa-table layui-table" id="contentTable1"></table>
@@ -430,7 +463,6 @@
 	<div id="changewidth"></div>
 </div>
 
-<%--<script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>--%>
 <script>
 
     layui.use('table', function(){
@@ -440,15 +472,8 @@
             ,elem: '#contentTable1'
             ,page: false
             ,cols: [[
-				//{checkbox: true, fixed: true},
+				{checkbox: true, fixed: true},
                 {field:'index',align:'center', title: '序号',width:55}
-				<%--,{field:'projName',align:'center', title: '项目名称',minWidth:100,templet:function(d){--%>
-				<%--		if(1 == d.showView && d.showView != undefined){--%>
-				<%--			return "<a class=\"attention-info\" title=\"" + d.projName + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectView/view?id=" + d.id +"','95%', '95%')\">" + d.projName + "</a>";--%>
-				<%--		}else{--%>
-				<%--			return "<span title='"+ d.projName +"'>" +d.projName+ "</span>";--%>
-				<%--		}--%>
-				<%--	}}--%>
 				,{field:'projectName',align:'center', title: '项目名称', minWidth:200,templet:function(d){
 						var xml="";
 						<shiro:hasPermission name="ruralProject:ruralProjectView:listAllView">
@@ -462,18 +487,25 @@
 											}}
 				,{field:'projectId',align:'center', title: '报告号',  width:180}
 				,{field:'materialName',align:'center', title: '材料名称',  width:150}
+				,{field:'brand',align:'center', title: '品牌',  width:100}
+				,{field:'specifications',align:'center', title: '规格型号',  width:150}
+				,{field:'projectPriceIncludingTax',align:'center', title: '含税工程价(元)',  width:130}
+				,{field:'marketPriceIncludingTax',align:'center', title: '含税市场价(元)',  width:130}
+				,{field:'taxRate',align:'center', title: '税率(%)',  width:100}
 				,{field:'unit',align:'center', title: '单位',  width:80}
-				,{field:'price',align:'center', title: '价格',  width:150}
-				// ,{field:'areaName',align:'center', title: '项目地点',  width:150}
-                ,{field:'createDate',align:'center', title: '创建日期',  width:150}
-                ,{field:'op',align:'center',title:"操作",width:240,templet:function(d){
+				,{field:'explain',align:'center', title: '产品说明',  width:150}
+				,{field:'supplier',align:'center', title: '供应商',  width:150}
+				,{field:'remarks',align:'center', title: '备注',  width:150}
+				,{field:'quotedPriceDate',align:'center', title: '报价时间',  width:100}
+				,{field:'createBy',align:'center', title: '创建人',  width:80}
+                ,{field:'createDate',align:'center', title: '创建日期',  width:100}
+                ,{field:'op',align:'center',title:"操作",width:160,templet:function(d){
                         ////对操作进行初始化
                         var xml="<div class=\"layui-btn-group\">";
-                         xml+="<a href=\"#\" onclick=\"openDialogre('修改项目', '${ctx}/project/projectMaterialStorage/formTwoPage?id=" + d.id+"&&isAdd=1" +"','95%', '95%','','提交,关闭')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改</a>";
-						 xml+="<a href=\"${ctx}/project/projectMaterialStorage/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该材料信息吗?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\"> 删除</a>";
-
-
-
+						if((d.flag != undefined && d.flag =="1") || <%=admin%>){
+							xml+="<a href=\"#\" onclick=\"openDialogre('修改', '${ctx}/project/projectMaterialStorage/formTwoPage?id=" + d.id+"&&isAdd=1" +"','95%', '95%','','提交,关闭')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改</a>";
+							xml+="<a href=\"${ctx}/project/projectMaterialStorage/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该材料信息吗?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\"> 删除</a>";
+						}
                         xml+="</div>"
                         return xml;
 
@@ -488,67 +520,31 @@
                     ,"id":"${projectMaterialStorage.id}"
 					,"projectNumber":"${projectMaterialStorage.projectNumber}"
 					,"projectId":"${projectMaterialStorage.projectId}"
-					,"unit":"${projectMaterialStorage.unit}"
 					,"materialName":"${projectMaterialStorage.materialName}"
 					,"price":"${projectMaterialStorage.price}"
                     ,"projectName":"<c:out value="${projectMaterialStorage.projectName}" escapeXml="true"/>"
 					,"areaName":"${projectMaterialStorage.areaName}"
 					,"createDate":"<fmt:formatDate value="${projectMaterialStorage.createDate}" pattern="yyyy-MM-dd"/>"
-                    <c:choose><c:when test="${flag == '1' or fns:getUser().id == projectRecords.createBy.id}">
-                    <shiro:hasPermission name="ruralProject:ruralProjectRecords:del">,"candel":	<c:choose><c:when test="${(projectRecords.projectStatus == 1 or projectRecords.projectStatus == 3 or projectRecords.projectStatus == 4) && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose></shiro:hasPermission>
-                    <shiro:hasPermission name="ruralProject:ruralProjectRecords:edit">,"canedit1":	<c:choose><c:when test="${projectRecords.projectStatus == 1 && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-                    ,"canedit2":<c:choose><c:when test="${projectRecords.projectStatus == 4 && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-                    ,"canrecall":<c:choose><c:when test="${projectRecords.projectStatus == 3 && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-                    </shiro:hasPermission>
-                    ,"cancancel":<c:choose><c:when test="${projectRecords.projectStatus == 2 && fns:getUser().id == projectRecords.createBy.id}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-
-                    ,"deleteAdmin":<c:choose><c:when test="${'1' == projectRecords.flagAdmin && projectRecords.projectStatus == 5}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-					,"modifyRecords":<c:choose><c:when test="${fns:getUser().id == projectRecords.createBy.id && '2' != projectRecords.projectReportStatus && '5' != projectRecords.projectReportStatus && projectRecords.projectStatus == 5}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-					<c:if test="${'1' == projectRecords.flagAdmin}">
-						,"reportDataFlag":<c:choose><c:when test="${'0' == projectRecords.reportDataFlag && projectRecords.projectStatus == 5}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-					</c:if>
-					<c:if test="${'0' == projectRecords.flagAdmin}">
-						,"reportDataFlag":<c:choose><c:when test="${fns:getUser().id == projectRecords.createBy.id && '0' == projectRecords.reportDataFlag && projectRecords.projectStatus == 5}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose>
-					</c:if>
-					</c:when>
-                    <c:otherwise>
-                    ,"candel":"0"
-                    ,"canedit1":"0"
-                    ,"canedit2":"0"
-                    ,"canrecall":"0"
-                    ,"cancancel":"0"
-                    ,"deleteAdmin":"0"
-                    ,"recordStatus":"0"
-                    </c:otherwise>
-                    </c:choose>
-					,"submitMoneyStr":
+					,"quotedPriceDate":"<fmt:formatDate value="${projectMaterialStorage.quotedPriceDate}" pattern="yyyy-MM-dd"/>"
+					,"brand":"${projectMaterialStorage.brand}"
+					,"specifications":"${projectMaterialStorage.specifications}"
+					,"projectPriceIncludingTax":"${projectMaterialStorage.projectPriceIncludingTax}"
+					,"marketPriceIncludingTax":"${projectMaterialStorage.marketPriceIncludingTax}"
+					,"taxRate":"${projectMaterialStorage.taxRate}"
+					,"unit":"${projectMaterialStorage.unit}"
+					,"explain":"${projectMaterialStorage.explain}"
+					,"supplier":"${projectMaterialStorage.supplier}"
+					,"remarks":"${projectMaterialStorage.remarks}"
+					,"createBy":"${projectMaterialStorage.createBy.name}"
+					,"flag":
 							<c:choose>
-							<c:when test="${'2'==projectRecords.submitMoney}">
-							"A级"
-					</c:when>
-					<c:otherwise>
-					"B级"
-					<%--<c:choose>
-                        <c:when test="${'1'==projectRecords.emergencyProject}">
-                            "B级紧急"
-                        </c:when>
-                        <c:otherwise>
-                            "B级非紧急"
-                        </c:otherwise>
-                    </c:choose>--%>
-					</c:otherwise>
-					</c:choose>
-                    <shiro:hasPermission name="ruralProject:ruralProjectRecords:edit">,"canedit3":<c:choose><c:when test="${projectRecords.projectStatus == 5 && fn:contains(projectRecords.leaderIds,fns:getUser().id)}">"1"</c:when><c:otherwise>"0"</c:otherwise></c:choose></shiro:hasPermission>
-					<shiro:hasPermission name="ruralProject:ruralProjectRecords:accessory">
-					,"recordStatus":
-					<c:choose>
-							<c:when test="${0 == projectRecords.projectReportRecordStatus && projectRecords.projectStatus != 7}">"1"</c:when>
-							<c:otherwise>"0"</c:otherwise>
-					</c:choose>
-					</shiro:hasPermission>
-					<shiro:hasPermission name="ruralProject:ruralProjectView:consultingView">
-					,"showView":1
-					</shiro:hasPermission>
+								<c:when test="${projectMaterialStorage.createBy.id eq fns:getUser().id}">
+									"1"
+								</c:when>
+								<c:otherwise>
+									"0"
+								</c:otherwise>
+							</c:choose>
                 }
                 </c:forEach>
                 </c:if>
@@ -556,7 +552,7 @@
             // ,even: true
             // ,height: 315
         });
-		$("#delUser").bind("click",function () {
+		$("#delProjectMaterialStorage").bind("click",function () {
 			//获得表格CheckBox已经选中的行的信息
 			var checkList = layui.table.checkStatus('checkboxTable').data;
 			//定义数组存放批量删除的行的id
@@ -566,10 +562,30 @@
 				listId.push(data.id);
 			});
 			if (listId.length <= 0) {
-				layer.msg("请选择需要下载的项目信息", {icon: 2})
+				layer.msg("请选择需要删除的信息", {icon: 2})
 			} else {
-				$("#searchForm").attr("action","${ctx}/ruralProject/ruralProjectRecords/exportAll?listId="+ listId);
-				$("#searchForm").submit();
+				layer.confirm('是否删除选择的数据信息?', {
+					btn: ['确认', '取消']
+					,btn1: function(index, layero){
+						$.ajax({
+							type:"post",
+							url:"${ctx}/project/projectMaterialStorage/deleteAll?listId="+ listId,
+							dataType:"json",
+							success:function(data){
+								layer.closeAll();//关闭对话框。
+								if(data.success) {
+									top.layer.msg(data.str, {icon: 1});
+									window.location.reload();
+								}else {
+									top.layer.msg(data.str, {icon: 0});
+								}
+							}
+						})
+					}
+					,btn2: function(index, layero){
+					}
+				});
+
 				return true;
 			}
 		});

+ 61 - 5
src/main/webapp/webpage/modules/projectMaterialStorage/projectMaterialStorageTwoForm.jsp

@@ -65,10 +65,16 @@
 			$("#attachment_btn").click(function () {
 				$("#attachment_file").click();
 			});
+			laydate.render({
+				elem: '#quotedPriceDate', //目标元素。由于laydate.js封装了一个轻量级的选择器引擎,因此elem还允许你传入class、tag但必须按照这种方式 '#id .class'
+				event: 'focus', //响应事件。如果没有传入event,则按照默认的click
+				type : 'date'
+				, trigger: 'click'
+			});
         });
 
 		function newSetPNumber(obj,label,ids,isProject,details){
-			$("#projectId").val(obj)
+			$("#projectNumber").val(obj)
 			$("#projectName").val(label)
 		}
 
@@ -87,13 +93,14 @@
 	<div class="container">
 		<form:form id="inputForm" modelAttribute="projectMaterialStorage" action="${ctx}/project/projectMaterialStorage/signleSave?isAdd=${isAdd}" method="post" class="layui-form">
 			<form:hidden path="id"/>
+			<form:hidden path="projectNumber"/>
 			<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 invoicetype">*</span>项目名称</label>
+					<label class="layui-form-label">项目名称</label>
 					<div class="layui-input-block">
 						<sys:gridselectprojectmaterial url="${ctx}/project/projectMaterialStorage/selectproject" id="project" name="projectName"  value="${projectMaterialStorage.projectName}"  title="选择所属项目" labelName="projectName" cssStyle="background-color: #fff"
-													  labelValue="${projectMaterialStorage.projectName}" cssClass="form-control required layui-input" fieldLabels="项目名称" fieldKeys="projectName" searchLabel="项目名称" searchKey="projectName"  ></sys:gridselectprojectmaterial>
+													  labelValue="${projectMaterialStorage.projectName}" cssClass="form-control layui-input" fieldLabels="项目名称" fieldKeys="projectName" searchLabel="项目名称" searchKey="projectName"  ></sys:gridselectprojectmaterial>
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm6">
@@ -103,15 +110,64 @@
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">品牌</label>
+					<div class="layui-input-block">
+						<form:input id="brand" path="brand" htmlEscape="false"  placeholder="请输入品牌"  class="form-control layui-input"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label"><span class="require-item invoicetype">*</span>规格型号</label>
+					<div class="layui-input-block">
+						<form:input id="specifications" path="specifications" htmlEscape="false"  placeholder="请输入规格型号"  class="form-control layui-input" required="true"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label double-line">含税工程价(元)</label>
+					<div class="layui-input-block">
+						<form:input id="projectPriceIncludingTax" path="projectPriceIncludingTax" htmlEscape="false"  placeholder="请输入含税工程价(元)"  class="form-control layui-input" onkeyup="num(this)"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label double-line">含税市场价(元)</label>
+					<div class="layui-input-block">
+						<form:input id="marketPriceIncludingTax" path="marketPriceIncludingTax" htmlEscape="false"  placeholder="请输入含税市场价(元)"  class="form-control layui-input" onkeyup="num(this)"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">税率(%)</label>
+					<div class="layui-input-block">
+						<form:input id="taxRate" path="taxRate" htmlEscape="taxRate"  placeholder="请输入税率(%)"  class="form-control layui-input" onkeyup="num(this)"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
 					<label class="layui-form-label"><span class="require-item invoicetype" >*</span>材料单位</label>
 					<div class="layui-input-block">
 						<form:input id="unit" path="unit" htmlEscape="false"  placeholder="请输入材料单位"  class="form-control required layui-input" />
 					</div>
 				</div>
 				<div class="layui-item layui-col-sm6">
-					<label class="layui-form-label"><span class="require-item invoicetype">*</span>单价(元)</label>
+					<label class="layui-form-label">产品说明</label>
+					<div class="layui-input-block">
+						<form:input id="explain" path="explain" htmlEscape="false"  placeholder="请输入产品说明"  class="form-control layui-input"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">供应商</label>
+					<div class="layui-input-block">
+						<form:input id="supplier" path="supplier" htmlEscape="false"  placeholder="请输入供应商"  class="form-control layui-input"/>
+					</div>
+				</div>
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">报价时间</label>
+					<div class="layui-input-block">
+						<input class="form-control layui-input"  style="background-color: #FFFFFF" readonly id="quotedPriceDate" name="quotedPriceDate" value="<fmt:formatDate value="${projectMaterialStorage.quotedPriceDate}" pattern="yyyy-MM-dd"/>">
+					</div>
+				</div>
+
+				<div class="layui-item layui-col-sm6">
+					<label class="layui-form-label">备注</label>
 					<div class="layui-input-block">
-						<form:input id="price" path="price" htmlEscape="false"  placeholder="请输入单价"  class="form-control required layui-input"  onkeyup="num(this)" />
+						<form:input id="remarks" path="remarks" htmlEscape="false"  placeholder="请输入备注"  class="form-control layui-input"/>
 					</div>
 				</div>
 

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

@@ -1247,11 +1247,11 @@
 <%--						<button class="layui-btn layui-btn-sm layui-bg-blue" id="btn-fold">全部折叠</button>--%>
 						<button class="layui-btn layui-btn-sm" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
 					</div>
-					<shiro:hasPermission name="ruralProject:ruralCostProjectMessage:reportSwitch">
+					<%--<shiro:hasPermission name="ruralProject:ruralCostProjectMessage:reportSwitch">
 						<div style="float: right;margin-right: 30px;">
 							<input type="checkbox" id="reportSwitch" <c:if test="${reportSwitch}">checked</c:if> lay-filter="reportSwitch" lay-skin="switch" lay-text="开启|关闭">
 						</div>
-					</shiro:hasPermission>
+					</shiro:hasPermission>--%>
 					<div style="clear: both;"></div>
 				</div>
 				<table class="oa-table layui-table" id="contentTable1" lay-filter="test"></table>

+ 17 - 5
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/all/ruralProjectMessageAllList.jsp

@@ -893,6 +893,17 @@
 								</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="defectRecordStatus" class="form-control simple-select">
+									<form:option value="" label=""/>
+									<form:option value="0" label="未发起"/>
+									<form:option value="2" label="已发起"/>
+									<form:option value="5" label="已完成"/>
+								</form:select>
+							</div>
+						</div>
 						<div style="clear:both;"></div>
 					</div>
 				</form:form>
@@ -921,11 +932,12 @@
 
 						<button class="layui-btn layui-btn-sm" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
 						<div class=" layui-btn-sm" style="float: right;width: 300px">
-							<span style="color: red">咨询营业收入:${moneyAll}(万元)</span>
+							<span style="color: #999999">咨询营业收入:${moneyAll}(万元)</span>
 						</div>
 					</div>
 					<shiro:hasPermission name="ruralProject:ruralCostProjectMessage:reportSwitch">
 						<div style="float: right;margin-right: 30px;">
+							<label class="layui-form-label double-line">上报接口启用状态:</label>
 							<input type="checkbox" id="reportSwitch" <c:if test="${reportSwitch}">checked</c:if> lay-filter="reportSwitch" lay-skin="switch" lay-text="开启|关闭">
 						</div>
 					</shiro:hasPermission>
@@ -1055,7 +1067,7 @@
 				<%--			var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";--%>
 				<%--		return xml;--%>
 				<%--	}}--%>
-				,{align:'center', title: '线下',  width:85,templet:function(d){
+				,{align:'center', title: '线下',  width:100,templet:function(d){
 						if (d.submitMoney=="1"){
 							var st = getRuralProjectArchiveState(d.downProjectReportRecordStatus);
 						}else if (d.submitMoney=="2"){
@@ -1063,9 +1075,9 @@
 						}
 						if(st.action){
 							if (d.submitMoney=="1"){
-								var xml = "<span title='批量归档时间:"+ d.projectFlingbatchRelationAuditPassDate +"' onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/ruralProjectMessage/getReportedProcess?processInstanceId=" + d.prrdProcessInstanceId + "','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+								var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/ruralCostProjectMessage/getReportedProcess?processInstanceId=" + d.prrdProcessInstanceId + "','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
 							}else if (d.submitMoney=="2"){
-								var xml = "<span title='纸质归档时间:"+ d.projectPaperAuditPassDate +"' onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/ruralProjectMessage/getReportedProcess?processInstanceId=" + d.ppfProcessInstanceId + "','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+								var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/ruralProject/ruralCostProjectMessage/getReportedProcess?processInstanceId=" + d.ppfProcessInstanceId + "','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>";
@@ -1233,7 +1245,7 @@
                     ,"view":"${projectRecords.view}"
                     ,"reportStatus":"${projectRecords.reportStatus}"
                     ,"syncStatus":"${projectRecords.syncStatus}"
-                    ,"downProjectReportRecordStatus":"${projectRecords.downProjectReportRecordStatus}"
+                    ,"downProjectReportRecordStatus":"${projectRecords.filingProjectStatus}"
                     ,"prrdProcessInstanceId":"${projectRecords.filingProcessinstanceId}"
                     ,"prrdId":"${projectRecords.prrdId}"
                     ,"emergencyProject":"${projectRecords.emergencyProject}"

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

@@ -857,11 +857,11 @@
 <%--						<button class="layui-btn layui-btn-sm layui-bg-blue" id="btn-fold">全部折叠</button>--%>
 						<button class="layui-btn layui-btn-sm layui-bg-green" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
 					</div>
-					<shiro:hasPermission name="ruralProject:ruralCostProjectMessage:reportSwitch">
+					<%--<shiro:hasPermission name="ruralProject:ruralCostProjectMessage:reportSwitch">
 						<div style="float: right;margin-right: 30px;">
 							<input type="checkbox" id="reportSwitch" <c:if test="${reportSwitch}">checked</c:if> lay-filter="reportSwitch" lay-skin="switch" lay-text="开启|关闭">
 						</div>
-					</shiro:hasPermission>
+					</shiro:hasPermission>--%>
 <%--					<button class="nav-btn nav-btn-refresh" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"><i class="glyphicon glyphicon-repeat"></i>&nbsp;刷新</button>--%>
 					<div style="clear: both;"></div>
 				</div>

+ 16 - 0
src/main/webapp/webpage/modules/statement/companyReportDataView.jsp

@@ -128,6 +128,7 @@
 				,{align:'center', title: '质量复核',colspan: 2}
 				,{align:'center', title: '电子超期未归档',colspan: 2}
 				,{align:'center', title: '纸质归档',colspan:2}
+				,{align:'center', title: '上报超期',colspan:2}
             ],
 			[
 				{field:'field6',align:'center',title:'未质量复核',templet:function(d){
@@ -173,6 +174,20 @@
 						return "<span title='"+ d.field2 +"'>" +d.field2+ "</span>";
 					}
 				}}
+				,{field:'field8',align:'center',title:'超期未上报',templet:function(d){
+					if("" != d.statementDate){
+						return "<a class=\"attention-info\" title=\"" + d.field8 + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('超期未上报', '${ctx}/statement/StatementCompanyComprehensive/projectReportDataZJList?bigDateType=" + d.bigDateType +"&smallDateType=" + d.smallDateType +"&officeId="+d.officeId+"&year="+d.year+"&field8=5','95%', '95%')\">" + d.field8 + "</a>";
+					}else{
+						return "<span title='"+ d.field8 +"'>" +d.field8+ "</span>";
+					}
+				}}
+				,{field:'field9',align:'center',title:'超期已上报',templet:function(d){
+					if("" != d.statementDate){
+						return "<a class=\"attention-info\" title=\"" + d.field9 + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('超期已上报', '${ctx}/statement/StatementCompanyComprehensive/projectReportDataZJList?bigDateType=" + d.bigDateType +"&smallDateType=" + d.smallDateType +"&officeId="+d.officeId+"&year="+d.year+"&field9=5','95%', '95%')\">" + d.field9 + "</a>";
+					}else{
+						return "<span title='"+ d.field9 +"'>" +d.field9+ "</span>";
+					}
+				}}
 			]]
             ,data: [
             		//data下是list集合,一定要这样写,不然无逗号分割会报错
@@ -194,6 +209,7 @@
 					,"field6":"${reportFormList.field6}"
 					,"field7":"${reportFormList.field7}"
 					,"field8":"${reportFormList.field8}"
+					,"field9":"${reportFormList.field9}"
 				}
 				</c:forEach>
 			]

+ 1 - 0
src/main/webapp/webpage/modules/statement/projectReportZJList.jsp

@@ -378,6 +378,7 @@
 					<input id="field6" name="field6" type="hidden" value="${field6}"/>
 					<input id="field7" name="field7" type="hidden" value="${field7}"/>
 					<input id="field8" name="field8" type="hidden" value="${field8}"/>
+					<input id="field9" name="field9" type="hidden" value="${field9}"/>
 
 					<table:sortColumn id="orderBy" name="orderBy" value="${page.orderBy}" callback="sortOrRefresh();"/><!-- 支持排序 -->
 					<div class="commonQuery lw6">

+ 1 - 1
src/main/webapp/webpage/modules/workinvoice/workInvoiceAllList.jsp

@@ -681,7 +681,7 @@
 
 				,{field:'invoiceDate',align:'center', sort:true,title: '开票日期',  width:90}
 				,{field:'receiptMoneyDate',align:'center', sort:true,title: '收款日期',  width:90}
-				,{field:'receiptMoney',align:'center', title: '是否收款',  width:80,templet:function(d){
+				,{field:'receiptMoney',align:'center', title: '是否收款',  width:90,templet:function(d){
 						if("部分收款" === d.receiptMoney || "是" === d.receiptMoney)
 							var xml = "<a class=\"status-label status-label-signed\" title=\""+ d.invoiceNum +"\"href=\"javascript:void(0);\" onclick=\"openDialogListView('查看发票管理', '${ctx}/workinvoiceAll/workInvoiceAll/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%', '95%')\">" + d.receiptMoney + "</a>";
 

+ 9 - 1
src/main/webapp/webpage/modules/workinvoice/workInvoiceAllTwoList.jsp

@@ -612,6 +612,7 @@
 										<select id="receiptMoney" name="receiptMoney" class="form-control simple-select">
 											<option value=""></option>
 											<option value="0" <c:if test="${workInvoiceShow.receiptMoney=='0'}">selected</c:if>>否</option>
+											<option value="2" <c:if test="${workInvoiceShow.receiptMoney=='2'}">selected</c:if>>部分收款</option>
 											<option value="1" <c:if test="${workInvoiceShow.receiptMoney=='1'}">selected</c:if>>是</option>
 										</select>
 									</div>
@@ -748,7 +749,14 @@
 
 				,{field:'invoiceDate',align:'center', title: '开票日期',  width:90}
 				,{field:'receiptMoneyDate',align:'center', title: '收款日期',  width:90}
-				,{field:'receiptMoney',align:'center', title: '是否收款',  width:80}
+				,{field:'receiptMoney',align:'center', title: '是否收款',  width:90,templet:function(d){
+						if("部分收款" === d.receiptMoney || "是" === d.receiptMoney)
+							var xml = "<a class=\"status-label status-label-signed\" title=\""+ d.invoiceNum +"\"href=\"javascript:void(0);\" onclick=\"openDialogListView('查看发票管理', '${ctx}/workinvoiceAll/workInvoiceAll/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%', '95%')\">" + d.receiptMoney + "</a>";
+
+						else
+							var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + d.receiptMoney + "\" >" + d.receiptMoney + "</span>";
+						return xml;
+					}}
 				,{field:'cancellation',align:'center', title: '是否作废',  width:80}
                 ,{align:'center', title: '状态', fixed: 'right', width:70,templet:function(d){
                         <%--var st = getAuditState(d.status);--%>

+ 9 - 1
src/main/webapp/webpage/modules/workinvoice/workInvoiceList.jsp

@@ -568,6 +568,7 @@
 								<select id="receiptMoney" name="receiptMoney" class="form-control simple-select">
 									<option value=""></option>
 									<option value="0" <c:if test="${workInvoiceShow.receiptMoney=='0'}">selected</c:if>>否</option>
+									<option value="2" <c:if test="${workInvoiceShow.receiptMoney=='2'}">selected</c:if>>部分收款</option>
 									<option value="1" <c:if test="${workInvoiceShow.receiptMoney=='1'}">selected</c:if>>是</option>
 								</select>
 							</div>
@@ -698,7 +699,14 @@
                 <%--    }}--%>
 				,{field:'createDate',align:'center', sort:true,title: '开票日期',  width:80}
 				,{field:'receiptMoneyDate',align:'center', sort:true,title: '收款日期',  width:80}
-				,{field:'receiptMoney',align:'center', title: '是否收款',  width:80}
+				,{field:'receiptMoney',align:'center', title: '是否收款',  width:90,templet:function(d){
+						if("部分收款" === d.receiptMoney || "是" === d.receiptMoney)
+							var xml = "<a class=\"status-label status-label-signed\" title=\""+ d.invoiceNum +"\"href=\"javascript:void(0);\" onclick=\"openDialogListView('查看发票管理', '${ctx}/workinvoiceAll/workInvoiceAll/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%', '95%')\">" + d.receiptMoney + "</a>";
+
+						else
+							var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + d.receiptMoney + "\" >" + d.receiptMoney + "</span>";
+						return xml;
+					}}
 				,{field:'cancellation',align:'center', title: '是否作废',  width:80}
                 ,{align:'center', title: '状态', fixed: 'right', width:70,templet:function(d){
                         <%--var st = getAuditState(d.status);--%>

+ 9 - 1
src/main/webapp/webpage/modules/workinvoice/workInvoiceTwoList.jsp

@@ -627,6 +627,7 @@
 									<select id="receiptMoney" name="receiptMoney" class="form-control simple-select">
 										<option value=""></option>
 										<option value="0" <c:if test="${workInvoiceShow.receiptMoney=='0'}">selected</c:if>>否</option>
+										<option value="2" <c:if test="${workInvoiceShow.receiptMoney=='2'}">selected</c:if>>部分收款</option>
 										<option value="1" <c:if test="${workInvoiceShow.receiptMoney=='1'}">selected</c:if>>是</option>
 									</select>
 								</div>
@@ -763,7 +764,14 @@
 
 				,{field:'invoiceDate',align:'center', sort:true,title: '开票日期',  width:90}
 				,{field:'receiptMoneyDate',align:'center', sort:true,title: '收款日期',  width:90}
-				,{field:'receiptMoney',align:'center', title: '是否收款',  width:80}
+				,{field:'receiptMoney',align:'center', title: '是否收款',  width:90,templet:function(d){
+						if("部分收款" === d.receiptMoney || "是" === d.receiptMoney)
+							var xml = "<a class=\"status-label status-label-signed\" title=\""+ d.invoiceNum +"\"href=\"javascript:void(0);\" onclick=\"openDialogListView('查看发票管理', '${ctx}/workinvoiceAll/workInvoiceAll/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%', '95%')\">" + d.receiptMoney + "</a>";
+
+						else
+							var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + d.receiptMoney + "\" >" + d.receiptMoney + "</span>";
+						return xml;
+					}}
 				,{field:'cancellation',align:'center', title: '是否作废',  width:80}
                 ,{align:'center', title: '状态', fixed: 'right', width:70,templet:function(d){
                         <%--var st = getAuditState(d.status);--%>