浏览代码

发票功能、项目上报功能、报销功能、电子签章功能调整代码提交

user5 11 月之前
父节点
当前提交
20670629e7
共有 54 个文件被更改,包括 2028 次插入281 次删除
  1. 57 0
      src/main/java/com/jeeplus/common/utils/excel/entity/CellModel.java
  2. 415 0
      src/main/java/com/jeeplus/common/utils/excel/utils/ExcelUtilInvoice.java
  3. 95 0
      src/main/java/com/jeeplus/common/utils/excel/utils/ExportExcelUtil.java
  4. 5 1
      src/main/java/com/jeeplus/modules/areaStaff/service/AreaStaffService.java
  5. 2 2
      src/main/java/com/jeeplus/modules/projectFilingBatch/web/ProjectFilingBatchController.java
  6. 42 2
      src/main/java/com/jeeplus/modules/ruralprojectrecords/service/RuralProjectMessageNewService.java
  7. 148 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/utils/RuralProjectReportedInfoUtil.java
  8. 27 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectSignatureOldMessageDisposeController.java
  9. 1 0
      src/main/java/com/jeeplus/modules/sys/dao/UserDao.java
  10. 1 0
      src/main/java/com/jeeplus/modules/sys/service/SystemService.java
  11. 4 0
      src/main/java/com/jeeplus/modules/sys/service/UserService.java
  12. 1 1
      src/main/java/com/jeeplus/modules/sys/web/RoleController.java
  13. 16 0
      src/main/java/com/jeeplus/modules/workcalendar/service/WorkCalendarTaskService.java
  14. 25 0
      src/main/java/com/jeeplus/modules/workinvoice/dao/WorkInvoiceDao.java
  15. 18 0
      src/main/java/com/jeeplus/modules/workinvoice/entity/WorkInvoice.java
  16. 274 4
      src/main/java/com/jeeplus/modules/workinvoice/service/WorkInvoiceService.java
  17. 7 4
      src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceController.java
  18. 104 0
      src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceTwoController.java
  19. 5 1
      src/main/java/com/jeeplus/modules/workprojectnotify/web/WorkProjectNotifyController.java
  20. 3 0
      src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementAllController.java
  21. 3 0
      src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementNewController.java
  22. 31 2
      src/main/java/com/jeeplus/modules/workstaff/service/WorkStaffBasicInfoService.java
  23. 3 0
      src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordsDao.xml
  24. 1 1
      src/main/resources/mappings/modules/signature/projectReport/ProjectReportSignatureDao.xml
  25. 10 1
      src/main/resources/mappings/modules/sys/UserDao.xml
  26. 99 1
      src/main/resources/mappings/modules/workinvoice/WorkInvoiceDao.xml
  27. 2 2
      src/main/resources/mappings/modules/workstaff/WorkStaffBasicInfoDao.xml
  28. 2 2
      src/main/webapp/static/common/jeeplus.js
  29. 1 1
      src/main/webapp/webpage/include/head.jsp
  30. 3 3
      src/main/webapp/webpage/modules/areaStaff/areaStaffUserForm.jsp
  31. 6 0
      src/main/webapp/webpage/modules/projectFilingBatch/projectChoiceLink.jsp
  32. 16 0
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/newReportedForm.jsp
  33. 22 1
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/reportedAudit.jsp
  34. 19 0
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedForm.jsp
  35. 17 0
      src/main/webapp/webpage/modules/ruralprojectrecords/view/reportedView.jsp
  36. 2 2
      src/main/webapp/webpage/modules/signatureManagement/electronicSignature/ElectronicSignatureList.jsp
  37. 1 1
      src/main/webapp/webpage/modules/sys/sysLogin.jsp
  38. 1 1
      src/main/webapp/webpage/modules/sys/sysLogin2.jsp
  39. 69 0
      src/main/webapp/webpage/modules/workinvoice/downloadInvoiceForm.jsp
  40. 59 2
      src/main/webapp/webpage/modules/workinvoice/workInvoiceAllList.jsp
  41. 44 0
      src/main/webapp/webpage/modules/workinvoice/workInvoiceAllTwoList.jsp
  42. 46 0
      src/main/webapp/webpage/modules/workinvoice/workInvoiceTwoList.jsp
  43. 9 7
      src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllFormAdd.jsp
  44. 2 2
      src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllFormDetail.jsp
  45. 9 7
      src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllModifyApply.jsp
  46. 2 2
      src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewAudit.jsp
  47. 9 7
      src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewFormAdd.jsp
  48. 9 7
      src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewModifyApply.jsp
  49. 2 2
      src/main/webapp/webpage/modules/workreimbursement/specific/workReimbursementSpecificAudit.jsp
  50. 9 7
      src/main/webapp/webpage/modules/workreimbursement/specific/workReimbursementSpecificModifyApply.jsp
  51. 131 108
      src/main/webapp/webpage/modules/workreimbursement/workReimbursementAllList.jsp
  52. 2 2
      src/main/webapp/webpage/modules/workreimbursement/workReimbursementFormDetail.jsp
  53. 135 93
      src/main/webapp/webpage/modules/workreimbursement/workReimbursementList.jsp
  54. 2 2
      src/main/webapp/webpage/modules/workstaff/workStaffBasicInfoList.jsp

+ 57 - 0
src/main/java/com/jeeplus/common/utils/excel/entity/CellModel.java

@@ -0,0 +1,57 @@
+package com.jeeplus.common.utils.excel.entity;
+
+public class CellModel {
+    private String cellName;
+    private int startRow;
+    private int endRow;
+    private int startColumn;
+    private int endColumn;
+
+    public CellModel(String cellName, int startRow, int endRow, int startColumn, int endColumn) {
+        this.cellName = cellName;
+        this.startRow = startRow;
+        this.endRow = endRow;
+        this.startColumn = startColumn;
+        this.endColumn = endColumn;
+    }
+
+    public String getCellName() {
+        return cellName;
+    }
+
+    public void setCellName(String cellName) {
+        this.cellName = cellName;
+    }
+
+    public int getStartRow() {
+        return startRow;
+    }
+
+    public void setStartRow(int startRow) {
+        this.startRow = startRow;
+    }
+
+    public int getEndRow() {
+        return endRow;
+    }
+
+    public void setEndRow(int endRow) {
+        this.endRow = endRow;
+    }
+
+    public int getStartColumn() {
+        return startColumn;
+    }
+
+    public void setStartColumn(int startColumn) {
+        this.startColumn = startColumn;
+    }
+
+    public int getEndColumn() {
+        return endColumn;
+    }
+
+    public void setEndColumn(int endColumn) {
+        this.endColumn = endColumn;
+    }
+}

+ 415 - 0
src/main/java/com/jeeplus/common/utils/excel/utils/ExcelUtilInvoice.java

@@ -0,0 +1,415 @@
+package com.jeeplus.common.utils.excel.utils;
+
+import com.jeeplus.common.utils.StringUtils;
+import com.jeeplus.common.utils.excel.entity.CellModel;
+import org.apache.poi.ss.usermodel.*;
+import org.apache.poi.xssf.usermodel.XSSFWorkbook;
+
+import java.io.FileOutputStream;
+import java.io.OutputStream;
+import java.util.*;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+public class ExcelUtilInvoice {
+
+    public static Map<String, List<CellModel>> generateExcelHeader() {
+        Map<String, List<CellModel>> headerMap = new HashMap<>();
+
+        // 第一行表头
+        List<CellModel> firstRow = new ArrayList<>();
+        firstRow.add(new CellModel("月份", 0, 1, 0, 0));
+        firstRow.add(new CellModel("合计收入", 0, 1, 1, 1));
+        firstRow.add(new CellModel("一部", 0, 0, 2, 3));
+        firstRow.add(new CellModel("二部", 0, 1, 4, 4));
+        firstRow.add(new CellModel("三部", 0, 1, 5, 5));
+        firstRow.add(new CellModel("四部", 0, 1, 6, 6));
+        firstRow.add(new CellModel("五部", 0, 0, 7, 10));
+        firstRow.add(new CellModel("招标部", 0, 1, 11, 11));
+        firstRow.add(new CellModel("盐城分公司", 0, 1, 12, 12));
+        firstRow.add(new CellModel("综合", 0, 1, 13, 13));
+
+        // 第二行表头
+        List<CellModel> secondRow = new ArrayList<>();
+        secondRow.add(new CellModel("本部", 1, 1, 2, 2));
+        secondRow.add(new CellModel("苏州", 1, 1, 3, 3));
+        secondRow.add(new CellModel("王晓青", 1, 1, 7, 7));
+        secondRow.add(new CellModel("孙兴华", 1, 1, 8, 8));
+        secondRow.add(new CellModel("王小国", 1, 1, 9, 9));
+        secondRow.add(new CellModel("刘万前", 1, 1, 10, 10));
+
+        headerMap.put("0", firstRow);
+        headerMap.put("1", secondRow);
+
+        return headerMap;
+    }
+
+    private static Font createFont(Workbook workbook) {
+        Font font = workbook.createFont();
+        font.setFontName("宋体");
+        font.setFontHeightInPoints((short) 12);
+        return font;
+    }
+
+    private static CellStyle createHeaderStyle(Workbook workbook) {
+        CellStyle style = workbook.createCellStyle();
+        style.setFont(createFont(workbook));
+        style.setAlignment(HorizontalAlignment.CENTER);
+        style.setVerticalAlignment(VerticalAlignment.CENTER);
+        style.setBorderTop(BorderStyle.MEDIUM);
+        style.setBorderBottom(BorderStyle.MEDIUM);
+        style.setBorderLeft(BorderStyle.MEDIUM);
+        style.setBorderRight(BorderStyle.MEDIUM);
+        return style;
+    }
+
+    private static CellStyle createDataStyle(Workbook workbook) {
+        CellStyle style = workbook.createCellStyle();
+        style.setFont(createFont(workbook));
+        style.setAlignment(HorizontalAlignment.CENTER);
+        style.setVerticalAlignment(VerticalAlignment.CENTER);
+        style.setBorderTop(BorderStyle.THIN);
+        style.setBorderBottom(BorderStyle.THIN);
+        style.setBorderLeft(BorderStyle.THIN);
+        style.setBorderRight(BorderStyle.THIN);
+        return style;
+    }
+
+    private static CellStyle createNumberStyle(Workbook workbook) {
+        CellStyle style = createDataStyle(workbook);
+        DataFormat format = workbook.createDataFormat();
+        style.setDataFormat(format.getFormat("0.00")); // 设置数字格式
+        return style;
+    }
+
+    private static CellStyle createTitleStyle(Workbook workbook) {
+        CellStyle style = workbook.createCellStyle();
+        Font font = createFont(workbook);
+        font.setBold(true);
+        font.setFontHeightInPoints((short) 12);
+        style.setFont(font);
+        style.setAlignment(HorizontalAlignment.CENTER);
+        style.setVerticalAlignment(VerticalAlignment.CENTER);
+        return style;
+    }
+
+    private static CellStyle createFillDataStyle(Workbook workbook) {
+        CellStyle style = workbook.createCellStyle();
+        style.setFont(createFont(workbook));
+        style.setAlignment(HorizontalAlignment.CENTER);
+        style.setVerticalAlignment(VerticalAlignment.CENTER);
+        return style;
+    }
+
+
+    public static void createExcelSheet(Workbook workbook, Sheet sheet, Map<String, List<CellModel>> headerMap, int headerSize, List<Map<String, String>> dataList,String year,String title) {
+        CellStyle headerStyle = createHeaderStyle(workbook);
+        CellStyle dataStyle = createDataStyle(workbook);
+        CellStyle numberStyle = createNumberStyle(workbook);
+        CellStyle titleStyle = createTitleStyle(workbook);
+        CellStyle fillStyle = createFillDataStyle(workbook);  // 这个样式没有边框
+
+        int titleMergeCols = 14;
+        List<String> fillData = Arrays.asList("年度:", year + "年");
+
+        // 创建标题行
+        Row titleRow = sheet.createRow(0);
+        titleRow.setHeightInPoints(30);  // 设置标题行高
+        Cell titleCell = titleRow.createCell(0);
+        titleCell.setCellValue(title);
+        titleCell.setCellStyle(titleStyle);
+        sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(0, 0, 0, titleMergeCols - 1));
+
+        // 创建填写数据行
+        Row fillRow = sheet.createRow(1);
+        fillRow.setHeightInPoints(25);  // 设置填写数据行高
+        for (int i = 0; i < fillData.size(); i++) {
+            Cell cell = fillRow.createCell(i);
+            cell.setCellValue(fillData.get(i));
+            cell.setCellStyle(fillStyle);
+        }
+
+        // 创建表头
+        for (int rowIndex = 0; rowIndex < headerSize; rowIndex++) {
+            List<CellModel> cellModelList = headerMap.get(String.valueOf(rowIndex));
+
+            if (cellModelList != null) {
+                for (CellModel cellModel : cellModelList) {
+                    // 合并单元格
+                    if (cellModel.getStartRow() != cellModel.getEndRow() || cellModel.getStartColumn() != cellModel.getEndColumn()) {
+                        sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(
+                                cellModel.getStartRow() + 2, cellModel.getEndRow() + 2,
+                                cellModel.getStartColumn(), cellModel.getEndColumn()));
+                    }
+
+                    // 创建单元格并设置样式
+                    for (int r = cellModel.getStartRow() + 2; r <= cellModel.getEndRow() + 2; r++) {
+                        Row mergeRow = sheet.getRow(r) != null ? sheet.getRow(r) : sheet.createRow(r);
+                        mergeRow.setHeightInPoints(20);  // 设置表头行高
+                        for (int c = cellModel.getStartColumn(); c <= cellModel.getEndColumn(); c++) {
+                            Cell cell = mergeRow.createCell(c);
+                            cell.setCellValue(cellModel.getCellName());
+                            cell.setCellStyle(headerStyle);
+                        }
+                    }
+                }
+            }
+        }
+
+        // 填充数据
+        for (int rowIndex = 0; rowIndex < dataList.size(); rowIndex++) {
+            Row row = sheet.createRow(rowIndex + headerSize + 2);
+            row.setHeightInPoints(18);  // 设置数据行高
+            Map<String, String> data = dataList.get(rowIndex);
+
+            for (Map.Entry<String, String> entry : data.entrySet()) {
+                Cell cell = row.createCell(Integer.parseInt(entry.getKey()));
+                if (StringUtils.isBlank(entry.getValue())) {
+                    cell.setCellValue(Double.parseDouble("0"));
+                } else if (isNumeric(entry.getValue())) {
+                    //浮点值
+                    cell.setCellValue(Double.parseDouble(entry.getValue()));
+                } else {
+                    //非浮点值
+                    cell.setCellValue(entry.getValue());
+                }
+                cell.setCellStyle(numberStyle);
+            }
+        }
+
+        // 自适应列宽并增加额外宽度
+        for (int i = 0; i < 14; i++) {
+            sheet.autoSizeColumn(i);
+            int currentWidth = sheet.getColumnWidth(i);
+            sheet.setColumnWidth(i, currentWidth + 1000);
+        }
+    }
+
+
+
+
+
+
+    public static void main(String[] args) {
+        try (Workbook workbook = new XSSFWorkbook()) {
+            Map<String, List<CellModel>> headerMap = generateExcelHeader();
+            int headerSize = headerMap.size();
+
+            // 示例数据
+            List<Map<String, String>> dataList = new ArrayList<>();
+            for (int i = 0; i < 10; i++) {
+                Map<String, String> data = new HashMap<>();
+                for (int j = 0; j < 14; j++) {
+                    data.put(String.valueOf(j), String.valueOf((i + 1) * (j + 1) * 10));
+                }
+                dataList.add(data);
+            }
+
+            CellStyle headerStyle = createHeaderStyle(workbook);
+            CellStyle dataStyle = createDataStyle(workbook);
+            CellStyle numberStyle = createNumberStyle(workbook);
+            CellStyle titleStyle = createTitleStyle(workbook);
+            CellStyle fillStyle = createFillDataStyle(workbook);  // 这个样式没有边框
+
+            String title = "兴光项目公司开票汇总表";
+            int titleMergeCols = 14;
+            List<String> fillData = Arrays.asList("年份:", "2024");
+
+            // 创建 Excel 表格
+            Sheet sheet = workbook.createSheet("测试表单");
+
+            // 创建标题行
+            Row titleRow = sheet.createRow(0);
+            titleRow.setHeightInPoints(30);  // 设置标题行高
+            Cell titleCell = titleRow.createCell(0);
+            titleCell.setCellValue(title);
+            titleCell.setCellStyle(titleStyle);
+            sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(0, 0, 0, titleMergeCols - 1));
+
+            // 创建填写数据行
+            Row fillRow = sheet.createRow(1);
+            fillRow.setHeightInPoints(25);  // 设置填写数据行高
+            for (int i = 0; i < fillData.size(); i++) {
+                Cell cell = fillRow.createCell(i);
+                cell.setCellValue(fillData.get(i));
+                cell.setCellStyle(fillStyle);
+            }
+
+            // 创建表头
+            for (int rowIndex = 0; rowIndex < headerSize; rowIndex++) {
+                List<CellModel> cellModelList = headerMap.get(String.valueOf(rowIndex));
+
+                if (cellModelList != null) {
+                    for (CellModel cellModel : cellModelList) {
+                        // 合并单元格
+                        if (cellModel.getStartRow() != cellModel.getEndRow() || cellModel.getStartColumn() != cellModel.getEndColumn()) {
+                            sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(
+                                    cellModel.getStartRow() + 2, cellModel.getEndRow() + 2,
+                                    cellModel.getStartColumn(), cellModel.getEndColumn()));
+                        }
+
+                        // 创建单元格并设置样式
+                        for (int r = cellModel.getStartRow() + 2; r <= cellModel.getEndRow() + 2; r++) {
+                            Row mergeRow = sheet.getRow(r) != null ? sheet.getRow(r) : sheet.createRow(r);
+                            mergeRow.setHeightInPoints(20);  // 设置表头行高
+                            for (int c = cellModel.getStartColumn(); c <= cellModel.getEndColumn(); c++) {
+                                Cell cell = mergeRow.createCell(c);
+                                cell.setCellValue(cellModel.getCellName());
+                                cell.setCellStyle(headerStyle);
+                            }
+                        }
+                    }
+                }
+            }
+
+            // 填充数据
+            for (int rowIndex = 0; rowIndex < dataList.size(); rowIndex++) {
+                Row row = sheet.createRow(rowIndex + headerSize + 2);
+                row.setHeightInPoints(18);  // 设置数据行高
+                Map<String, String> data = dataList.get(rowIndex);
+
+                for (Map.Entry<String, String> entry : data.entrySet()) {
+                    Cell cell = row.createCell(Integer.parseInt(entry.getKey()));
+                    cell.setCellValue(Double.parseDouble(entry.getValue()));
+                    cell.setCellStyle(numberStyle);
+                }
+            }
+
+            // 自适应列宽并增加额外宽度
+            for (int i = 0; i < 14; i++) {
+                sheet.autoSizeColumn(i);
+                int currentWidth = sheet.getColumnWidth(i);
+                sheet.setColumnWidth(i, currentWidth + 1000);
+            }
+
+            try (OutputStream os = new FileOutputStream("D:\\复杂表头示例.xlsx")) {
+                workbook.write(os);
+            }
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+    }
+
+
+
+
+    public static void exportInvoiceDataInfoByYear(List<Map<String, String>> dataList) {
+        try (Workbook workbook = new XSSFWorkbook()) {
+            Map<String, List<CellModel>> headerMap = generateExcelHeader();
+            int headerSize = headerMap.size();
+
+            CellStyle headerStyle = createHeaderStyle(workbook);
+            CellStyle dataStyle = createDataStyle(workbook);
+            CellStyle numberStyle = createNumberStyle(workbook);
+            CellStyle titleStyle = createTitleStyle(workbook);
+            CellStyle fillStyle = createFillDataStyle(workbook);  // 这个样式没有边框
+
+            String title = "兴光项目公司开票汇总表";
+            int titleMergeCols = 14;
+            List<String> fillData = Arrays.asList("年份:", "2024年");
+
+            // 创建 Excel 表格
+            Sheet sheet = workbook.createSheet("测试表单");
+
+            // 创建标题行
+            Row titleRow = sheet.createRow(0);
+            titleRow.setHeightInPoints(30);  // 设置标题行高
+            Cell titleCell = titleRow.createCell(0);
+            titleCell.setCellValue(title);
+            titleCell.setCellStyle(titleStyle);
+            sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(0, 0, 0, titleMergeCols - 1));
+
+            // 创建填写数据行
+            Row fillRow = sheet.createRow(1);
+            fillRow.setHeightInPoints(25);  // 设置填写数据行高
+            for (int i = 0; i < fillData.size(); i++) {
+                Cell cell = fillRow.createCell(i);
+                cell.setCellValue(fillData.get(i));
+                cell.setCellStyle(fillStyle);
+            }
+
+            // 创建表头
+            for (int rowIndex = 0; rowIndex < headerSize; rowIndex++) {
+                List<CellModel> cellModelList = headerMap.get(String.valueOf(rowIndex));
+
+                if (cellModelList != null) {
+                    for (CellModel cellModel : cellModelList) {
+                        // 合并单元格
+                        if (cellModel.getStartRow() != cellModel.getEndRow() || cellModel.getStartColumn() != cellModel.getEndColumn()) {
+                            sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(
+                                    cellModel.getStartRow() + 2, cellModel.getEndRow() + 2,
+                                    cellModel.getStartColumn(), cellModel.getEndColumn()));
+                        }
+
+                        // 创建单元格并设置样式
+                        for (int r = cellModel.getStartRow() + 2; r <= cellModel.getEndRow() + 2; r++) {
+                            Row mergeRow = sheet.getRow(r) != null ? sheet.getRow(r) : sheet.createRow(r);
+                            mergeRow.setHeightInPoints(20);  // 设置表头行高
+                            for (int c = cellModel.getStartColumn(); c <= cellModel.getEndColumn(); c++) {
+                                Cell cell = mergeRow.createCell(c);
+                                cell.setCellValue(cellModel.getCellName());
+                                cell.setCellStyle(headerStyle);
+                            }
+                        }
+                    }
+                }
+            }
+
+            // 填充数据
+            for (int rowIndex = 0; rowIndex < dataList.size(); rowIndex++) {
+                Row row = sheet.createRow(rowIndex + headerSize + 2);
+                row.setHeightInPoints(18);  // 设置数据行高
+                Map<String, String> data = dataList.get(rowIndex);
+
+                for (Map.Entry<String, String> entry : data.entrySet()) {
+                    Cell cell = row.createCell(Integer.parseInt(entry.getKey()));
+                    if(StringUtils.isBlank(entry.getValue())){
+                        cell.setCellValue(Double.parseDouble("0"));
+                    }else if(isNumeric(entry.getValue())){
+                        //浮点值
+                        cell.setCellValue(Double.parseDouble(entry.getValue()));
+                    }else {
+                        //非浮点值
+                        cell.setCellValue(entry.getValue());
+                    }
+                    cell.setCellStyle(numberStyle);
+                }
+            }
+
+            // 自适应列宽并增加额外宽度
+            for (int i = 0; i < 14; i++) {
+                sheet.autoSizeColumn(i);
+                int currentWidth = sheet.getColumnWidth(i);
+                sheet.setColumnWidth(i, currentWidth + 1000);
+            }
+
+            try (OutputStream os = new FileOutputStream("D:\\复杂表头示例.xlsx")) {
+                workbook.write(os);
+            }
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+    }
+
+
+    public static boolean isNumeric(String str) {
+        if (str == null || str.isEmpty()) {
+            return false;
+        }
+
+        String regex = "[-+]?\\d*\\.?\\d+";
+        Pattern pattern = Pattern.compile(regex);
+        Matcher matcher = pattern.matcher(str);
+
+        if (matcher.matches()) {
+            try {
+                Double.parseDouble(str);
+                return true;
+            } catch (NumberFormatException e) {
+                return false;
+            }
+        } else {
+            return false;
+        }
+    }
+}

+ 95 - 0
src/main/java/com/jeeplus/common/utils/excel/utils/ExportExcelUtil.java

@@ -0,0 +1,95 @@
+package com.jeeplus.common.utils.excel.utils;
+
+import com.jeeplus.common.utils.excel.entity.CellModel;
+import org.apache.poi.ss.usermodel.*;
+import org.apache.poi.xssf.usermodel.XSSFWorkbook;
+
+import java.util.List;
+import java.util.Map;
+
+public class ExportExcelUtil {
+
+    /**
+     * 创建Excel文件
+     *
+     * @param wb               Workbook对象
+     * @param sheetName        表单名称
+     * @param headerMap        表头数据
+     * @param headerSize       表头行数
+     * @param dataList         数据列表
+     * @param headerStyle      表头样式
+     * @param dataStyle        数据样式
+     * @param title            标题
+     * @param titleStyle       标题样式
+     * @param titleMergeCols   标题合并的列数
+     * @param fillData         填写数据行内容
+     * @param fillStyle        填写数据行样式
+     * @return Workbook对象
+     */
+    public static Workbook createExcel(Workbook wb, String sheetName, Map<String, List<CellModel>> headerMap, int headerSize, List<Map<String, String>> dataList, CellStyle headerStyle, CellStyle dataStyle, String title, CellStyle titleStyle, int titleMergeCols, List<String> fillData, CellStyle fillStyle) {
+        Sheet sheet = wb.createSheet(sheetName);
+
+        // 创建标题行
+        Row titleRow = sheet.createRow(0);
+        Cell titleCell = titleRow.createCell(0);
+        titleCell.setCellValue(title);
+        titleCell.setCellStyle(titleStyle);
+        sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(0, 0, 0, titleMergeCols - 1));
+
+        // 创建填写数据行
+        Row fillRow = sheet.createRow(1);
+        for (int i = 0; i < fillData.size(); i++) {
+            Cell cell = fillRow.createCell(i);
+            cell.setCellValue(fillData.get(i));
+            cell.setCellStyle(fillStyle);
+        }
+
+        // 创建表头
+        for (int rowIndex = 0; rowIndex < headerSize; rowIndex++) {
+            List<CellModel> cellModelList = headerMap.get(String.valueOf(rowIndex));
+
+            if (cellModelList != null) {
+                for (CellModel cellModel : cellModelList) {
+                    // 合并单元格
+                    if (cellModel.getStartRow() != cellModel.getEndRow() || cellModel.getStartColumn() != cellModel.getEndColumn()) {
+                        sheet.addMergedRegion(new org.apache.poi.ss.util.CellRangeAddress(
+                                cellModel.getStartRow() + 2, cellModel.getEndRow() + 2,
+                                cellModel.getStartColumn(), cellModel.getEndColumn()));
+                    }
+
+                    // 创建单元格并设置样式
+                    for (int r = cellModel.getStartRow() + 2; r <= cellModel.getEndRow() + 2; r++) {
+                        Row mergeRow = sheet.getRow(r) != null ? sheet.getRow(r) : sheet.createRow(r);
+                        for (int c = cellModel.getStartColumn(); c <= cellModel.getEndColumn(); c++) {
+                            Cell cell = mergeRow.createCell(c);
+                            cell.setCellValue(cellModel.getCellName());
+                            cell.setCellStyle(headerStyle);
+                        }
+                    }
+                }
+            }
+        }
+
+        // 填充数据
+        for (int rowIndex = 0; rowIndex < dataList.size(); rowIndex++) {
+            Row row = sheet.createRow(rowIndex + headerSize + 2);
+            Map<String, String> data = dataList.get(rowIndex);
+
+            for (Map.Entry<String, String> entry : data.entrySet()) {
+                Cell cell = row.createCell(Integer.parseInt(entry.getKey()));
+                cell.setCellValue(entry.getValue());
+                cell.setCellStyle(dataStyle);
+            }
+        }
+
+        // 自适应列宽
+        for (int i = 0; i < headerMap.get("0").size(); i++) {
+            sheet.autoSizeColumn(i);
+            // 手动设置宽度以确保足够宽
+            int currentWidth = sheet.getColumnWidth(i);
+            sheet.setColumnWidth(i, currentWidth + 1536); // 加上一些额外的宽度,以便更好的自适应
+        }
+
+        return wb;
+    }
+}

+ 5 - 1
src/main/java/com/jeeplus/modules/areaStaff/service/AreaStaffService.java

@@ -491,7 +491,11 @@ public class AreaStaffService  extends TreeService<AreaStaffDao, AreaStaffInfo>
                     return map;
                 }else{
                     //如果地区为空则进行地区添加和地区负责人添加
-                    AreaStaffInfo areaStaffInfo = this.saveAreaType(officeInfo, directorApplication.getArea().getId(),directorApplication);
+                    String areaId = "";
+                    if(null != directorApplication.getArea() && StringUtils.isNotBlank(directorApplication.getArea().getId())){
+                        areaId = directorApplication.getArea().getId();
+                    }
+                    AreaStaffInfo areaStaffInfo = this.saveAreaType(officeInfo, areaId,directorApplication);
 
                 }
 

+ 2 - 2
src/main/java/com/jeeplus/modules/projectFilingBatch/web/ProjectFilingBatchController.java

@@ -636,8 +636,8 @@ public class ProjectFilingBatchController extends BaseController {
         try {
             ImportExcel ei = new ImportExcel(file, 1, 0);
             List<ProjectFilingBatchImportInfo> list = ei.getDataList(ProjectFilingBatchImportInfo.class);
-            Set<String> reportNumberSet = new HashSet();
-            Set<String> prefixReportNumberSet = new HashSet();
+            LinkedHashSet<String> reportNumberSet = new LinkedHashSet();
+            LinkedHashSet<String> prefixReportNumberSet = new LinkedHashSet();
             //对数据进行处理
             //将报告号进行筛选去重
             for (ProjectFilingBatchImportInfo info : list) {

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

@@ -3906,6 +3906,11 @@ public class RuralProjectMessageNewService extends CrudService<RuralProjectMessa
                             if(!"Success".equals(client)){
                                 return "上报失败!";
                             }*/
+                            if(StringUtils.isNotBlank(reported.getS3())){
+                                if(reported.getS3().contains(",")){
+                                    reported.setS3(reported.getS3().replaceAll(",",""));
+                                }
+                            }
                             if(Double.valueOf(reported.getJingHeJianLv())>30 || Double.valueOf(reported.getJingHeJianLv())< -30 ) {
                                 //修改项目上报表中状态
                                 reported.setReportStatus(String.valueOf(ProjectStatusEnum.DISPENSE.getValue()));
@@ -3920,8 +3925,43 @@ public class RuralProjectMessageNewService extends CrudService<RuralProjectMessa
                             }else{
                                 //信用代码id
                                 String jsonUscCode = "{\"uscCode\": \"91320000746823994F\"";
-                                Map map = RuralProjectReportedInfoUtil.reportedDataManage(reported);
+                                Map map = new HashMap();
+                                //判定项目是否为加密项目,若为加密项目,则数据处理进行调整
+                                switch (reported.getSecrecy()){
+                                    case "0":
+                                        map = RuralProjectReportedInfoUtil.reportedDataManage(reported);
+                                        break;
+                                    case "1":
+                                        //如果是保密项目,先查询加密项目名称编号,并进行递增,若没有 则默认为001
+                                        //查询审核通过的最大的一个保密项目名称(编号)
+                                        String lastSecrecyProjectName = ruralProjectRecordsReportedDao.getLastSecrecyProjectName();
+                                        String secrecyProjectName = "";
+                                        if(StringUtils.isBlank(lastSecrecyProjectName)){
+                                            secrecyProjectName = "001";
+                                            reported.setSecrecyProjectName("1");
+                                        }else{
+                                            int lastSecrecyProjectNameSort = Integer.parseInt(lastSecrecyProjectName);
+                                            lastSecrecyProjectNameSort ++ ;
+                                            if(lastSecrecyProjectNameSort<10){
+                                                secrecyProjectName = "00" + lastSecrecyProjectNameSort;
+                                            }else if (lastSecrecyProjectNameSort<100){
+                                                secrecyProjectName = "0" + lastSecrecyProjectNameSort;
+                                            }else{
+                                                secrecyProjectName = "" + lastSecrecyProjectNameSort;
+                                            }
+                                            reported.setSecrecyProjectName(String.valueOf(lastSecrecyProjectNameSort));
+                                        }
+                                        //map = RuralProjectReportedInfoUtil.reportedDataSecretManage(reported,secrecyProjectName);
+                                        map = RuralProjectReportedInfoUtil.reportedDataManage(reported);
+                                        break;
+                                    default:
+                                        map = RuralProjectReportedInfoUtil.reportedDataManage(reported);
+                                        break;
+                                }
+
                                 String jsonUscData = JSONObject.toJSONString(map);
+                                //将上报省站的数据保存备份
+                                reported.setSecrecyProjectRecordJson(jsonUscData);
                                 byte[] privateKey = org.apache.commons.codec.binary.Base64.decodeBase64(PRIVATE_KEY);
                                 //客户拿到密钥将自己的数据 jsonUscData 进行非对称加密。
                                 byte[] encryptByPrivateKey = new byte[0];
@@ -3939,7 +3979,7 @@ public class RuralProjectMessageNewService extends CrudService<RuralProjectMessa
                                     e.printStackTrace();
                                 }
                                 //测试接口
-                                //String url = "http://comp.jszj.com.cn:8031/api/testAddProject";
+                                //String url = "https://comp.jszj.com.cn:8031/api/testAddProject";
                                 //正式接口
                                 String url = REPORTEDURL;
                                 //发送请求

+ 148 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/utils/RuralProjectReportedInfoUtil.java

@@ -173,6 +173,154 @@ public class RuralProjectReportedInfoUtil {
         return map;
     }
 
+
+    /**
+     * 项目上报数据处理(转map)(保密项目)
+     * @param reported
+     * @return
+     */
+    public static Map<String ,Object> reportedDataSecretManage(RuralProjectRecordsReported reported,String projectName){
+        Map<String,Object> map = new LinkedHashMap<>();
+        //工程所在省份,必填
+        map.put("projectProv",reported.getS1());
+        //工程所在地,必填
+        map.put("projectHome",reported.getS3());
+        //项目编号,必填
+        map.put("projectNum","0");
+        //项目名称,必填(项目名称进行处理,即使用001,002,003...进行代替)
+        map.put("projectName",projectName);
+        //项目分类,必填(默认 其他)
+        map.put("projectSort","99");
+        //项目标段
+        map.put("projectSection","0");
+
+        //项目代码,必填
+        map.put("projectCode","0");
+        //投资性质,必填
+        map.put("investPropCd",reported.getTouZiXZ());
+        //合同编号,必填
+        map.put("contractNum","0");
+        //合同类型,必填(默认 其他)
+        map.put("contractTypeCd","90");
+        //项目类型,必填
+        map.put("projectTypeCd",reported.getProjectType());
+        //委托单位,必填
+        map.put("entrustUnit","0");
+        //委托单位联系电话,必填
+        map.put("entrustPhone","0");
+        //造价记录编号,必填
+        map.put("recordNum","0");
+        //出具咨询报告日期,必填
+        map.put("issueReportDate",reported.getBaoGaoShuQianFaDate());
+        //造价咨询营业收入,必填
+        map.put("incomeFee",reported.getZiXunShouRu());
+
+
+
+        //负责人筛选
+        ReportedConsultant responsiblePerson = new ReportedConsultant();
+        //咨询员
+        List<ReportedConsultant> reportedConsultantList = reported.getReportedConsultantList();
+
+        Iterator iterator = reportedConsultantList.iterator();
+        while (iterator.hasNext()) {
+            ReportedConsultant data = (ReportedConsultant) iterator.next();
+            if (null == data.getId()){
+                iterator.remove();
+            }else if("1".equals(data.getRoleFlag())){
+                responsiblePerson = data;
+                iterator.remove();
+            }
+        }
+        //根据咨询员id查询咨询员姓名信息
+        User user = UserUtils.get(responsiblePerson.getZixunyuan());
+
+        if(null != user && StringUtils.isNotBlank(user.getName())){
+            //咨询项目负责人姓名,必填
+            map.put("leaderName",user.getName());
+        }else{
+            map.put("leaderName","");
+        }
+        //咨询项目负责人身份证号,必填
+        map.put("leaderLetterNum",responsiblePerson.getIdCard());
+        //咨询项目负责人完成营业收入比例(%),必填
+        map.put("leaderIncomePercent","0");
+        //咨询项目负责人完成营业收入
+        map.put("leaderIncomeMoney","0");
+
+        //添加咨询员信息
+        //map.put("staffs","");
+
+        //工程结构,必填(默认 其他)
+        map.put("projectStructCd","099");
+        //地上层数
+        map.put("floorUp","0");
+
+        //地下层数
+        map.put("floorDown","0");
+        //建筑规模,必填(默认 其他)
+        map.put("projectAreaVal","0");
+        //建筑规模单位,必填
+        map.put("projectAreaUnit", "50");
+        //工程用途,必填
+        map.put("projectUseCd","09");
+        //咨询标的额(万元),必填
+        map.put("targetFee",reported.getZiXunBDE());
+
+
+        //如果项目类型是工程结算审核
+        if(StringUtils.isNotBlank(reported.getProjectType()) && "10".equals(reported.getProjectType())){
+
+            //合同价(万元)
+            map.put("contractFee","0");
+            //送审价(万元)
+            map.put("submitAuditFee",notRequiredManage(reported.getSongShenJia()));
+            //审定价(万元)
+            map.put("fixedAuditFee","0");
+            //审核增减额
+            map.put("checkCutFee","0");
+            //审核增减率
+            map.put("checkCutLv","0");
+        }
+        //咨询项目造价包含内容说明,必填
+        map.put("projectContainContent","");
+
+        //如果项目类型是全过程
+        if(StringUtils.isNotBlank(reported.getProjectType()) && "17".equals(reported.getProjectType())){
+            //工程项目总投资(万元)
+            map.put("totalInvestment",notRequiredManage(reported.getProjectTotalInvestment()));
+            //总咨询师
+            map.put("chiefConsultant","0");
+            //咨询档案编号
+            map.put("archivesNo","0");
+
+            //作业期(起止时间) 模板:2020-12-12到2021-12-12
+            if(null != reported.getBeginDate() && null != reported.getEndDate()){
+                SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+                map.put("stage",formatter.format(reported.getBeginDate()) + "到" + formatter.format(reported.getEndDate()));
+            } else{
+                map.put("stage","");
+            }
+
+            //全过程工程咨询收入
+            map.put("wholeIncomeFee","0");
+            //工程监理收入
+            map.put("supervisorFee","0");
+            //招标代理收入
+            map.put("biddingFee","0");
+            //设计收入
+            map.put("designFee","0");
+            //其他收入
+            map.put("otherFee","0");
+        }
+        //项目状态,必填(默认给0,即暂存;2:直接上报)
+        map.put("delFlag","2");
+
+        String s = JSONObject.toJSONString(map);
+        System.out.println(s);
+        return map;
+    }
+
     /**
      * 非必填项数据处理
      * @param parameter

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

@@ -29,6 +29,7 @@ import com.jeeplus.modules.sys.utils.UserUtils;
 import com.jeeplus.modules.tools.utils.SignaturePostUtil;
 import com.jeeplus.modules.utils.SftpClientUtil;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientAttachment;
+import com.jeeplus.modules.workinvoice.service.WorkInvoiceService;
 import freemarker.template.Configuration;
 import freemarker.template.Template;
 import org.activiti.engine.HistoryService;
@@ -86,6 +87,9 @@ public class RuralProjectSignatureOldMessageDisposeController extends BaseContro
     @Autowired
     private RuralProjectMessageAllService ruralProjectMessageAllService;
 
+    @Autowired
+    private WorkInvoiceService workInvoiceService;
+
     private static final String HTTPTOP = Global.getConfig("signature_http_top");
 
     private final static String apptoken = Global.getConfig("apptoken");
@@ -695,5 +699,28 @@ public class RuralProjectSignatureOldMessageDisposeController extends BaseContro
         return map;
     }
 
+    /**
+     * 报表处理
+     * @return
+     */
+    @RequestMapping(value = "/invoiceView")
+    @ResponseBody
+    @Transactional(readOnly = false)
+    public Map<String,Object> invoiceView(){
+        Map<String,Object> map = new HashMap<>();
+        Integer year = 2024;
+        long l1 = System.currentTimeMillis();
+        logger.info("-----------公司级—月度报表(开始)------------------");
+        workInvoiceService.exportInvoiceDataInfoByYear(year);
+        logger.info("------------公司级—月度报表(结束)------------------");
+        /*logger.info("-----------超期未收款发票信息提醒通知(开始)------------------");
+        workInvoiceService.getOverDueGatheringInvoiceList();
+        logger.info("-----------超期未收款发票信息提醒通知(结束)------------------");*/
+
+        map.put("msgMonth","月度报表处理完成");
+        long l2 = System.currentTimeMillis();
+        map.put("msgdate",(l2-l1));
+        return map;
+    }
 
 }

+ 1 - 0
src/main/java/com/jeeplus/modules/sys/dao/UserDao.java

@@ -242,6 +242,7 @@ public interface UserDao extends CrudDao<User> {
 	 * @return
 	 */
 	int updateUser(User user);
+	int updateUserOfficeByUserId(@Param("officeId")String officeId , @Param("userId")String userId);
 
 	String findUserNo(String weChatId);
 

+ 1 - 0
src/main/java/com/jeeplus/modules/sys/service/SystemService.java

@@ -191,6 +191,7 @@ public class SystemService extends BaseService implements InitializingBean {
                 user.setCompany(UserUtils.getSelectCompany());
             }
         }
+        user.setLoginFlag("1");
         page.setList(userDao.findList(user));
         return page;
     }

+ 4 - 0
src/main/java/com/jeeplus/modules/sys/service/UserService.java

@@ -551,6 +551,10 @@ public class UserService extends BaseController {
      */
     public void updateUser(User user){
         userDao.updateUser(user);
+        //修改人员所属部门信息
+        if(null != user.getOffice() && StringUtils.isNotBlank(user.getOffice().getId()) && StringUtils.isNotBlank(user.getId())){
+            userDao.updateUserOfficeByUserId(user.getOffice().getId(),user.getId());
+        }
     }
 
 

+ 1 - 1
src/main/java/com/jeeplus/modules/sys/web/RoleController.java

@@ -491,7 +491,7 @@ public class RoleController extends BaseController {
 	 * @param response
 	 * @return
 	 */
-	@RequiresPermissions("sys:role:assign")
+	//@RequiresPermissions("sys:role:assign")
 	@ResponseBody
 	@RequestMapping(value = "users")
 	public List<Map<String, Object>> users(String officeId, HttpServletResponse response) {

+ 16 - 0
src/main/java/com/jeeplus/modules/workcalendar/service/WorkCalendarTaskService.java

@@ -8,6 +8,8 @@ import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectRecordsServic
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectSignatureOldMessageDisposeService;
 import com.jeeplus.modules.statement.service.StatementCompanyComprehensiveService;
 import com.jeeplus.modules.workcalendar.entity.WorkCalendar;
+import com.jeeplus.modules.workinvoice.entity.WorkInvoice;
+import com.jeeplus.modules.workinvoice.service.WorkInvoiceService;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -42,6 +44,8 @@ public class WorkCalendarTaskService  {
     private RuralProjectSignatureOldMessageDisposeService ruralProjectSignatureOldMessageDispose;
     @Autowired
     private StatementCompanyComprehensiveService statementCompanyComprehensiveService;
+    @Autowired
+    private WorkInvoiceService workInvoiceService;
 
     //@Scheduled(cron= "0 0/1 * * * ?")
     public void notifyTask() {
@@ -250,4 +254,16 @@ public class WorkCalendarTaskService  {
         logger.info("-----------B类项目批量归档长期未处理通知(结束)------------------");
     }
 
+    /**
+     * 超期未收款发票信息提醒通知(开票后超过1个月没有收款的发票数据)
+     */
+    //设置每月15号凌晨30分进行执行
+    @Scheduled(cron= "0 30 0 15 * ?")
+    @Transactional(readOnly = false)
+    public void getOverDueGatheringInvoiceList() {
+        logger.info("-----------超期未收款发票信息提醒通知(开始)------------------");
+        workInvoiceService.getOverDueGatheringInvoiceList();
+        logger.info("-----------超期未收款发票信息提醒通知(结束)------------------");
+    }
+
 }

+ 25 - 0
src/main/java/com/jeeplus/modules/workinvoice/dao/WorkInvoiceDao.java

@@ -159,4 +159,29 @@ public interface WorkInvoiceDao extends CrudDao<WorkInvoice> {
 	 * @return
 	 */
 	Integer updateElectronicInvoiceFlag(WorkInvoice workInvoice);
+
+
+	/**
+	 * 查询超期未收款的发票信息(开票日期距今超过一个月的发票信息)
+	 * @return
+	 */
+	List<WorkInvoice>  getOverDueGatheringInvoiceList(String invoiceDate);
+
+	/**
+	 * 柑橘开票起止时间和部门id查询开票金额
+	 * @param beginDate
+	 * @param endDate
+	 * @param officeId
+	 * @return
+	 */
+	String getInvoiceMoneyByMonthAndOffice(@Param("beginDate")String beginDate, @Param("endDate")String endDate , @Param("officeId")String officeId);
+
+	/**
+	 * 柑橘开票起止时间和部门id查询开票金额
+	 * @param beginDate
+	 * @param endDate
+	 * @param officeIdList
+	 * @return
+	 */
+	String getInvoiceMoneyByMonthAndOfficeList(@Param("beginDate")String beginDate, @Param("endDate")String endDate , @Param("officeIdList")List<String>officeIdList);
 }

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

@@ -115,6 +115,8 @@ public class WorkInvoice extends ActEntity<WorkInvoice> {
 	private String cancellationState; //作废状态
 	private Date auditPassDate;
 	private Date cancellationAuditPassDate;
+	private Integer adventDate; 	//未收款天数
+	private Integer year; 	//年份信息
 
 	private Integer electronicInvoiceFlag ;	//是否已经上传电子发票信息(0:未上传;1:已上传)
 
@@ -836,4 +838,20 @@ public class WorkInvoice extends ActEntity<WorkInvoice> {
 	public void setCancellationAuditPassDate(Date cancellationAuditPassDate) {
 		this.cancellationAuditPassDate = cancellationAuditPassDate;
 	}
+
+	public Integer getAdventDate() {
+		return adventDate;
+	}
+
+	public void setAdventDate(Integer adventDate) {
+		this.adventDate = adventDate;
+	}
+
+	public Integer getYear() {
+		return year;
+	}
+
+	public void setYear(Integer year) {
+		this.year = year;
+	}
 }

+ 274 - 4
src/main/java/com/jeeplus/modules/workinvoice/service/WorkInvoiceService.java

@@ -10,6 +10,7 @@ import com.jeeplus.common.service.CrudService;
 import com.jeeplus.common.utils.DateUtils;
 import com.jeeplus.common.utils.MenuStatusEnum;
 import com.jeeplus.common.utils.StringUtils;
+import com.jeeplus.common.utils.excel.utils.ExcelUtilInvoice;
 import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.act.utils.ActUtils;
 import com.jeeplus.modules.projectrecord.entity.ProjectRecords;
@@ -62,6 +63,8 @@ import org.springframework.transaction.annotation.Transactional;
 
 import java.math.BigDecimal;
 import java.math.RoundingMode;
+import java.time.LocalDate;
+import java.time.format.DateTimeFormatter;
 import java.util.*;
 
 /**
@@ -3025,6 +3028,7 @@ public class WorkInvoiceService extends CrudService<WorkInvoiceDao, WorkInvoice>
 		String officeId = UserUtils.getUser().getOffice().getId();
 		Office office = officeService.get(officeId);
 		workInvoice.setOffice(office);
+		workInvoice.setInvoiceState("5");
 		super.save(workInvoice);
 		String str = "";
 		//所属部门
@@ -3172,10 +3176,18 @@ public class WorkInvoiceService extends CrudService<WorkInvoiceDao, WorkInvoice>
 			updateWorkInvoiceInfo(workInvoice);
 		}
 		String comment = "";
-		if (workInvoice.getCancellationState().equals("9")){
-			comment = ("yes".equals(workInvoice.getAct().getFlag())?"[重新申请] ":"[已撤销] ");
-		}else {
-			comment = ("yes".equals(workInvoice.getAct().getFlag())?"[同意] ":"[驳回] ")+workInvoice.getAct().getComment();
+		if(StringUtils.isNotBlank(workInvoice.getCancellationState())){
+			if (workInvoice.getCancellationState().equals("9")){
+				comment = ("yes".equals(workInvoice.getAct().getFlag())?"[重新申请] ":"[已撤销] ");
+			}else {
+				comment = ("yes".equals(workInvoice.getAct().getFlag())?"[同意] ":"[驳回] ")+workInvoice.getAct().getComment();
+			}
+		}else{
+			if (workInvoice.getInvoiceState().equals("9")){
+				comment = ("yes".equals(workInvoice.getAct().getFlag())?"[重新申请] ":"[已撤销] ");
+			}else {
+				comment = ("yes".equals(workInvoice.getAct().getFlag())?"[同意] ":"[驳回] ")+workInvoice.getAct().getComment();
+			}
 		}
 		//yes 的时候状态为审核通过 否则为未通过
 		//6 作废审批中 9 作废驳回
@@ -3654,4 +3666,262 @@ public class WorkInvoiceService extends CrudService<WorkInvoiceDao, WorkInvoice>
 		return dao.getBankNameByNameOrId(bankName);
 	}
 
+
+	/**
+	 * 查询超期未收款的发票信息(开票日期距今超过一个月的发票信息)
+	 */
+	public void getOverDueGatheringInvoiceList(){
+		// 获取当前日期
+		LocalDate currentDate = LocalDate.now();
+
+		// 计算前一个月的日期
+		LocalDate previousMonthDate = currentDate.minusMonths(1);
+		// 格式化日期(可选)
+		DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
+		String invoiceDate = previousMonthDate.format(formatter);
+
+		List<WorkInvoice> overDueGatheringInvoiceList = workInvoiceDao.getOverDueGatheringInvoiceList(invoiceDate);
+
+		for (WorkInvoice workInvoice : overDueGatheringInvoiceList) {
+
+			List<WorkInvoiceProjectRelation> projectRelationList = dao.getProjectRelation(workInvoice.getId());
+			for (WorkInvoiceProjectRelation projectRelation: projectRelationList) {
+				if (null==projectRelation.getIsProject() || projectRelation.getIsProject()==1){
+					if(StringUtils.isBlank(projectRelation.getClientName())){
+						//无合同查找委托方信息
+						RuralProjectRecords records1 = ruralProjectRecordsService.get(projectRelation.getProjectId());
+						//无合同状态下,获取委托方的名称
+						if (records1.getWorkContractInfo() == null || null == records1.getWorkContractInfo().getClient() ||StringUtils.isBlank(records1.getWorkContractInfo().getClient().getName())){
+							ruralProjectRecordsService.queryLinkmanInfos(records1);
+							if (records1.getWorkClientLinkmanList() != null && records1.getWorkClientLinkmanList().size() > 0) {
+								WorkClientLinkman linkman = records1.getWorkClientLinkmanList().get(0);
+								projectRelation.setClientName(linkman.getClientId().getName());
+							}
+						}
+					}
+				}else if(projectRelation.getIsProject()==2){
+					projectRelation.setProjectName("内容");
+					projectRelation.setWorkContractName(projectRelation.getDetails());
+				}
+			}
+			workInvoice.setWorkInvoiceProjectRelationList(projectRelationList);
+
+			//项目名称获取
+			List<String> projectNameList = getProjectNameList(workInvoice);
+			String projectNameStr = String.join(",", projectNameList);
+			WorkProjectNotify notify = new WorkProjectNotify();
+			notify.setNotifyId(workInvoice.getId());
+
+			String notifyStr = "项目【"+ projectNameStr +"】。发票申请编号:" + workInvoice.getNumber() + "未收款。";
+			String titleStr = "项目【"+ projectNameStr +"】。发票申请编号:" + workInvoice.getNumber() + "未收款。开票距今:"+workInvoice.getAdventDate() + "天。";
+
+			//根据标题查询通知信息中是否存在未读的信息,有则进行更新并对重复数量进行+1操作
+			WorkProjectNotify byTitleAndUnread = workProjectNotifyService.getByTitleAndUnread(notifyStr,workInvoice.getCreateBy().getId());
+
+			if(null != byTitleAndUnread){
+				//将所有的被通知人的该条通知均调整为已读,然后将最后一条数据进行调整
+				workProjectNotifyService.deleteByNotifyUser(notifyStr,workInvoice.getCreateBy().getId());
+				byTitleAndUnread.setExigency("1");
+				byTitleAndUnread.setTitle(titleStr);
+				workProjectNotifyService.updateOverDueInfo(byTitleAndUnread);
+			}else{
+				workProjectNotifyService
+						.save(UtilNotify.saveNotify(workInvoice.getId(),
+								workInvoice.getCreateBy(),
+								workInvoice.getCompanyId(),
+								titleStr,
+								notifyStr,
+								"21",
+								"0",
+								"待通知",
+								""));
+			}
+		}
+	}
+
+	/**
+	 * 查询年度各部门开票金额
+	 * @param year
+	 */
+	public List<Map<String, String>> exportInvoiceDataInfoByYear(Integer year){
+		List<Map<String, String>> dataList = new ArrayList<>();
+		//查询各部门信息
+		Office firstDepartment = officeService.getByName("工程一部");
+		Office szDepartment = officeService.getByName("苏州团队");
+		Office secondDepartment = officeService.getByName("工程二部");
+		Office thirdDepartment = officeService.getByName("工程三部");
+		Office fourthDepartment = officeService.getByName("工程四部");
+		Office wxqDepartment = officeService.getByName("王晓青团队");
+		Office sxhDepartment = officeService.getByName("孙兴华团队");
+		Office wxgDepartment = officeService.getByName("王小国团队");
+		Office lwqDepartment = officeService.getByName("刘万前团队");
+		Office zbdlbDepartment = officeService.getByName("招标代理部");
+		Office ycDepartment = officeService.getByName("盐城分公司");
+
+		BigDecimal allMoneyB = new BigDecimal("0");
+		BigDecimal firstDepartmentB = new BigDecimal("0");
+		BigDecimal szDepartmentB = new BigDecimal("0");
+		BigDecimal secondDepartmentB = new BigDecimal("0");
+		BigDecimal thirdDepartmentB = new BigDecimal("0");
+		BigDecimal fourthDepartmentB = new BigDecimal("0");
+		BigDecimal wxqDepartmentB = new BigDecimal("0");
+		BigDecimal sxhDepartmentB = new BigDecimal("0");
+		BigDecimal wxgDepartmentB = new BigDecimal("0");
+		BigDecimal lwqDepartmentB = new BigDecimal("0");
+		BigDecimal zbdlbDepartmentB = new BigDecimal("0");
+		BigDecimal ycDepartmentB = new BigDecimal("0");
+		BigDecimal otherDepartmentB = new BigDecimal("0");
+
+		try {
+			//遍历月份信息
+			for (int month = 1 ;month<=12;month ++){
+				Map<String, String> data = new HashMap<>();
+				Map<String, String> dateMap = getDate(month,year);
+				//根据部门和月份信息查询每个月当前部门的所有开票数据总金额
+				//开始时间
+				String beginDate = dateMap.get("beginDate");
+				//结束时间
+				String endDate = dateMap.get("endDate");
+
+				//查看该月份开票金额总和
+				String monthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, "");
+				allMoneyB = allMoneyB.add(new BigDecimal(monthAllInvoiceMoney));
+				//查询各部门当月开票金额
+				//一部本部开票金额
+				String firstDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, firstDepartment.getId());
+				firstDepartmentB = firstDepartmentB.add(new BigDecimal(firstDepartmentMonthAllInvoiceMoney));
+				//苏州团队开票金额
+				String szDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, szDepartment.getId());
+				szDepartmentB = szDepartmentB.add(new BigDecimal(szDepartmentMonthAllInvoiceMoney));
+				//二部开票金额
+				String secondDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, secondDepartment.getId());
+				secondDepartmentB = secondDepartmentB.add(new BigDecimal(secondDepartmentMonthAllInvoiceMoney));
+				//三部开票金额
+				String thirdDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, thirdDepartment.getId());
+				thirdDepartmentB = thirdDepartmentB.add(new BigDecimal(thirdDepartmentMonthAllInvoiceMoney));
+				//四部开票金额
+				String fourthDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, fourthDepartment.getId());
+				fourthDepartmentB = fourthDepartmentB.add(new BigDecimal(fourthDepartmentMonthAllInvoiceMoney));
+				//王晓青团队开票金额
+				String wxqDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, wxqDepartment.getId());
+				wxqDepartmentB = wxqDepartmentB.add(new BigDecimal(wxqDepartmentMonthAllInvoiceMoney));
+				//孙兴华团队开票金额
+				String sxhDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, sxhDepartment.getId());
+				sxhDepartmentB = sxhDepartmentB.add(new BigDecimal(sxhDepartmentMonthAllInvoiceMoney));
+				//王小国团队开票金额
+				String wxgDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, wxgDepartment.getId());
+				wxgDepartmentB = wxgDepartmentB.add(new BigDecimal(wxgDepartmentMonthAllInvoiceMoney));
+				//刘万前团队开票金额
+				String lwqDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, lwqDepartment.getId());
+				lwqDepartmentB = lwqDepartmentB.add(new BigDecimal(lwqDepartmentMonthAllInvoiceMoney));
+				//招标代理部开票金额
+				String zbdlbDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, zbdlbDepartment.getId());
+				zbdlbDepartmentB = zbdlbDepartmentB.add(new BigDecimal(zbdlbDepartmentMonthAllInvoiceMoney));
+				//盐城分公司开票金额
+				String ycDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOffice(beginDate, endDate, ycDepartment.getId());
+				ycDepartmentB = ycDepartmentB.add(new BigDecimal(ycDepartmentMonthAllInvoiceMoney));
+
+				//查询其他部门的开票金额总和
+				List<String> otherOfficeList = Lists.newArrayList();
+				otherOfficeList.add(firstDepartment.getId());
+				otherOfficeList.add(szDepartment.getId());
+				otherOfficeList.add(secondDepartment.getId());
+				otherOfficeList.add(thirdDepartment.getId());
+				otherOfficeList.add(fourthDepartment.getId());
+				otherOfficeList.add(wxqDepartment.getId());
+				otherOfficeList.add(sxhDepartment.getId());
+				otherOfficeList.add(wxgDepartment.getId());
+				otherOfficeList.add(lwqDepartment.getId());
+				otherOfficeList.add(zbdlbDepartment.getId());
+				otherOfficeList.add(ycDepartment.getId());
+
+				//查询剩余部门当月开票金额总和
+				//盐城分公司开票金额
+				String otherDepartmentMonthAllInvoiceMoney = workInvoiceDao.getInvoiceMoneyByMonthAndOfficeList(beginDate, endDate, otherOfficeList);
+				otherDepartmentB = otherDepartmentB.add(new BigDecimal(otherDepartmentMonthAllInvoiceMoney));
+
+				data.put("0", month + "月");
+				data.put("1", monthAllInvoiceMoney);
+
+				data.put("2", firstDepartmentMonthAllInvoiceMoney);
+				data.put("3", szDepartmentMonthAllInvoiceMoney);
+				data.put("4", secondDepartmentMonthAllInvoiceMoney);
+				data.put("5", thirdDepartmentMonthAllInvoiceMoney);
+				data.put("6", fourthDepartmentMonthAllInvoiceMoney);
+				data.put("7", wxqDepartmentMonthAllInvoiceMoney);
+				data.put("8", sxhDepartmentMonthAllInvoiceMoney);
+				data.put("9", wxgDepartmentMonthAllInvoiceMoney);
+				data.put("10", lwqDepartmentMonthAllInvoiceMoney);
+				data.put("11", zbdlbDepartmentMonthAllInvoiceMoney);
+				data.put("12", ycDepartmentMonthAllInvoiceMoney);
+				data.put("13", otherDepartmentMonthAllInvoiceMoney);
+				dataList.add(data);
+			}
+
+			Map<String, String> totalData = new HashMap<>();
+			totalData.put("0", "合计");
+			totalData.put("1", allMoneyB.setScale(2, RoundingMode.HALF_UP).toString());
+
+			totalData.put("2", firstDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("3", szDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("4", secondDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("5", thirdDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("6", fourthDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("7", wxqDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("8", sxhDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("9", wxgDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("10", lwqDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("11", zbdlbDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("12", ycDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			totalData.put("13", otherDepartmentB.setScale(2, RoundingMode.HALF_UP).toString());
+			dataList.add(totalData);
+
+			//处理合计数值
+
+			//ExcelUtilInvoice.exportInvoiceDataInfoByYear(dataList);
+		}catch (Exception e){
+			System.err.println("发票汇总异常!");
+			e.printStackTrace();
+			logger.error("Exception e:"+e);
+		}
+		return dataList;
+	}
+
+	/**
+	 * 根据状态获取查询得开始和结束时间   获取精确的年月日
+	 * @param month 月份
+	 * @param year 年份
+	 * @return
+	 */
+	public Map<String,String> getDate(Integer month,Integer year){
+		Map<String,String> map = new HashMap<String,String>();
+		String beginDate = "";
+		String endDate = "";
+
+		//smallDateType  为月度时候
+		switch (month){
+			case 1:
+			case 2:
+			case 3:
+			case 4:
+			case 5:
+			case 6:
+			case 7:
+			case 8:
+			case 9:
+				beginDate = year + "-0" + month + "-01 00:00:00";
+				endDate = year + "-0" + month + "-31 23:59:59";
+				break;
+			case 10:
+			case 11:
+			case 12:
+				beginDate = year + "-" + month + "-01 00:00:00";
+				endDate = year + "-" + month + "-31 23:59:59";
+				break;
+		}
+
+		map.put("beginDate",beginDate);
+		map.put("endDate",endDate);
+		return map;
+	}
 }

+ 7 - 4
src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceController.java

@@ -17,6 +17,8 @@ import com.jeeplus.common.utils.MyBeanUtils;
 import com.jeeplus.common.utils.StringUtils;
 import com.jeeplus.common.utils.excel.ExportExcel;
 import com.jeeplus.common.utils.excel.ImportExcel;
+import com.jeeplus.common.utils.excel.entity.CellModel;
+import com.jeeplus.common.utils.excel.utils.ExcelUtilInvoice;
 import com.jeeplus.common.web.BaseController;
 import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
@@ -61,6 +63,9 @@ import org.activiti.engine.TaskService;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.activiti.engine.task.Task;
 import org.apache.commons.beanutils.BeanUtils;
+import org.apache.poi.ss.usermodel.Sheet;
+import org.apache.poi.ss.usermodel.Workbook;
+import org.apache.poi.xssf.usermodel.XSSFWorkbook;
 import org.apache.shiro.authz.annotation.Logical;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -73,12 +78,10 @@ import org.springframework.web.servlet.mvc.support.RedirectAttributes;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 import javax.validation.ConstraintViolationException;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.UnsupportedEncodingException;
+import java.io.*;
 import java.lang.reflect.InvocationTargetException;
 import java.net.URLDecoder;
+import java.net.URLEncoder;
 import java.util.*;
 
 /**

+ 104 - 0
src/main/java/com/jeeplus/modules/workinvoice/web/WorkInvoiceTwoController.java

@@ -14,6 +14,8 @@ import com.jeeplus.common.utils.MyBeanUtils;
 import com.jeeplus.common.utils.StringUtils;
 import com.jeeplus.common.utils.excel.ExportExcel;
 import com.jeeplus.common.utils.excel.ImportExcel;
+import com.jeeplus.common.utils.excel.entity.CellModel;
+import com.jeeplus.common.utils.excel.utils.ExcelUtilInvoice;
 import com.jeeplus.common.web.BaseController;
 import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
@@ -21,6 +23,7 @@ import com.jeeplus.modules.act.utils.ActUtils;
 import com.jeeplus.modules.projectrecord.entity.ProjectRecords;
 import com.jeeplus.modules.projectrecord.enums.ProjectStatusEnum;
 import com.jeeplus.modules.projectrecord.service.ProjectRecordsService;
+import com.jeeplus.modules.ruralprojectrecords.entity.RuralProjectRecords;
 import com.jeeplus.modules.ruralprojectrecords.service.RuralProjectRecordsService;
 import com.jeeplus.modules.sys.entity.MainDictDetail;
 import com.jeeplus.modules.sys.entity.Office;
@@ -56,6 +59,9 @@ import org.activiti.engine.TaskService;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.activiti.engine.task.Task;
 import org.apache.commons.beanutils.BeanUtils;
+import org.apache.poi.ss.usermodel.Sheet;
+import org.apache.poi.ss.usermodel.Workbook;
+import org.apache.poi.xssf.usermodel.XSSFWorkbook;
 import org.apache.shiro.authz.annotation.Logical;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -68,9 +74,12 @@ import org.springframework.web.servlet.mvc.support.RedirectAttributes;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 import javax.validation.ConstraintViolationException;
+import java.io.OutputStream;
 import java.io.UnsupportedEncodingException;
 import java.lang.reflect.InvocationTargetException;
 import java.net.URLDecoder;
+import java.net.URLEncoder;
+import java.time.Year;
 import java.util.*;
 
 /**
@@ -1554,4 +1563,99 @@ public class WorkInvoiceTwoController extends BaseController {
 		return "redirect:"+Global.getAdminPath()+"/workinvoiceTwo/workinvoiceTwo/?repage";
 	}
 
+
+
+	//@RequiresPermissions("workinvoice:workInvoice:export")
+	@RequestMapping(value = "exportExcel", method=RequestMethod.POST)
+	public String exportFile(String year,String view, HttpServletRequest request, HttpServletResponse response, RedirectAttributes redirectAttributes) {
+		if(StringUtils.isBlank(year)){
+			switch (view){
+				case "workInvoiceTwo":
+					return "redirect:"+Global.getAdminPath()+"/workinvoiceTwo/workinvoiceTwo/?repage";
+
+				case "workInvoiceAllTwo":
+					return "redirect:"+Global.getAdminPath()+"/workinvoiceAllTwo/workinvoiceAllTwo/?repage";
+
+				case "workInvoiceAll":
+					return "redirect:"+Global.getAdminPath()+"/workinvoiceAll/workInvoiceAll/?repage";
+
+				default:
+					return "redirect:"+Global.getAdminPath()+"/workinvoiceTwo/workinvoiceTwo/?repage";
+
+			}
+		}
+		try (Workbook workbook = new XSSFWorkbook()) {
+			Map<String, List<CellModel>> headerMap = ExcelUtilInvoice.generateExcelHeader();
+			int headerSize = headerMap.size();
+
+			// 示例数据
+			List<Map<String, String>> dataList = workInvoiceService.exportInvoiceDataInfoByYear(Integer.parseInt(year));
+
+			// 创建 Excel 表格
+			Sheet sheet = workbook.createSheet("开票汇总");
+			ExcelUtilInvoice.createExcelSheet(workbook, sheet, headerMap, headerSize, dataList,year,"兴光项目公司开票汇总表");
+
+			// 设置文件名,并进行编码
+			String fileName = year + "年兴光项目公司开票汇总表.xlsx";
+			fileName = URLEncoder.encode(fileName, "UTF-8");
+
+			// 设置响应头
+			response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet");
+			response.setHeader("Content-Disposition", "attachment; filename=" + fileName);
+			response.setHeader("Pragma", "no-cache");
+			response.setHeader("Cache-Control", "no-cache");
+			response.setDateHeader("Expires", 0);
+
+			// 将Excel写入到响应输出流
+			try (OutputStream os = response.getOutputStream()) {
+				workbook.write(os);
+			}
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+		switch (view){
+			case "workInvoiceTwo":
+				return "redirect:"+Global.getAdminPath()+"/workinvoiceTwo/workinvoiceTwo/?repage";
+
+			case "workInvoiceAllTwo":
+				return "redirect:"+Global.getAdminPath()+"/workinvoiceAllTwo/workinvoiceAllTwo/?repage";
+
+			case "workInvoiceAll":
+				return "redirect:"+Global.getAdminPath()+"/workinvoiceAll/workInvoiceAll/?repage";
+
+			default:
+				return "redirect:"+Global.getAdminPath()+"/workinvoiceTwo/workinvoiceTwo/?repage";
+
+		}
+	}
+
+	/**
+	 * 跳转归档信息导出信息页
+	 */
+	@RequestMapping(value = "skipDownloadInvoiceForm")
+	public String skipDownloadInvoiceForm(WorkInvoice workInvoice,String view, Model model) {
+		// 获取当前年份
+		int currentYear = Year.now().getValue();
+		workInvoice.setYear(currentYear);
+		model.addAttribute("workInvoice",workInvoice);
+		//查询发票涉及到的年度信息
+		List<String> yearList = generateYearList();
+		model.addAttribute("yearList",yearList);
+		model.addAttribute("view",view);
+		return "modules/workinvoice/downloadInvoiceForm";
+	}
+
+	public static List<String> generateYearList() {
+		List<String> yearList = new ArrayList<>();
+		// 获取当前年份
+		int currentYear = Year.now().getValue();
+
+		// 从 2021 年到当前年份,生成年份列表
+		for (int year = 2021; year <= currentYear; year++) {
+			yearList.add(String.valueOf(year));
+		}
+
+		return yearList;
+	}
+
 }

+ 5 - 1
src/main/java/com/jeeplus/modules/workprojectnotify/web/WorkProjectNotifyController.java

@@ -2243,7 +2243,11 @@ public class WorkProjectNotifyController extends BaseController {
 						workInvoice.setBank(bankName);
 					}
 					workInvoice.setHome("home");
-					workInvoice.setAct(getByAct(workInvoice.getCancellationProcessInstanceId()));
+					if(StringUtils.isNotBlank(workInvoice.getCancellationProcessInstanceId())){
+						workInvoice.setAct(getByAct(workInvoice.getCancellationProcessInstanceId()));
+					}else{
+						workInvoice.setAct(getByAct(workInvoice.getProcessInstanceId()));
+					}
 					String taskDefKey = workInvoice.getAct().getTaskDefKey();
 					model.addAttribute("workInvoice", workInvoice);
 					if (workProjectNotify.getRemarks().contains("待通知") || "view".equals(workProjectNotify.getView())) {

+ 3 - 0
src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementAllController.java

@@ -372,6 +372,9 @@ public class WorkReimbursementAllController extends BaseController {
 			User user=UserUtils.get(workReimbursement.getCreateBy().getId());
 			workReimbursement.setCreateBy(user);
 		}
+		if(StringUtils.isBlank(workReimbursement.getReimbursementType())){
+			workReimbursement.setReimbursementType("1");
+		}
 		model.addAttribute("workReimbursement", workReimbursement);
 		return "modules/workreimbursement/all/"+view;
 	}

+ 3 - 0
src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementNewController.java

@@ -175,6 +175,9 @@ public class WorkReimbursementNewController extends BaseController {
 			User user=UserUtils.get(workReimbursement.getCreateBy().getId());
 			workReimbursement.setCreateBy(user);
 		}
+		if(StringUtils.isBlank(workReimbursement.getReimbursementType())){
+			workReimbursement.setReimbursementType("1");
+		}
 
 		model.addAttribute("workReimbursement", workReimbursement);
 		return "modules/workreimbursement/new/"+view;

+ 31 - 2
src/main/java/com/jeeplus/modules/workstaff/service/WorkStaffBasicInfoService.java

@@ -3,6 +3,7 @@
  */
 package com.jeeplus.modules.workstaff.service;
 
+import com.google.common.collect.Lists;
 import com.google.common.collect.Maps;
 import com.jeeplus.common.bos.BOSClientUtil;
 import com.jeeplus.common.config.Global;
@@ -201,11 +202,39 @@ public class WorkStaffBasicInfoService extends CrudService<WorkStaffBasicInfoDao
             }
         }
         if(null!= workStaffBasicInfo.getOffice() && StringUtils.isNotBlank(workStaffBasicInfo.getOffice().getId())){
+            if ("一部本部".equals(workStaffBasicInfo.getOffice().getId())) {
+                List<String> officeIdList = Lists.newArrayList();
+                Office office = officeService.getByName("工程一部");
+                officeIdList.add(office.getId());
+                workStaffBasicInfo.setOfficeIdList(officeIdList);
+            } else {
+                //查询该选择节点下所有的部门Id
+                List<String> officeIdList = officeService.getChildrenOffice(workStaffBasicInfo.getOffice().getId());
+                officeIdList.add(workStaffBasicInfo.getOffice().getId());
+                if (officeIdList.size() > 0) {
+                    workStaffBasicInfo.setOfficeIdList(officeIdList);
+                }
+            }
+        }else if(null!= workStaffBasicInfo.getOffice() && StringUtils.isNotBlank(workStaffBasicInfo.getOffice().getName())){
+            if ("一部本部".equals(workStaffBasicInfo.getOffice().getName())) {
+                List<String> officeIdList = Lists.newArrayList();
+                Office office = officeService.getByName("工程一部");
+                officeIdList.add(office.getId());
+                workStaffBasicInfo.setOfficeIdList(officeIdList);
+            } else {
+                //查询该选择节点下所有的部门Id
+                List<String> officeIdList = officeService.getChildrenOffice(workStaffBasicInfo.getOffice().getName());
+                if (officeIdList.size() > 0) {
+                    workStaffBasicInfo.setOfficeIdList(officeIdList);
+                }
+            }
+        }
+        /*if(null!= workStaffBasicInfo.getOffice() && StringUtils.isNotBlank(workStaffBasicInfo.getOffice().getId())){
             //查询该选择节点下所有的部门Id
             List<String> officeIdList = officeService.getChildrenOffice(workStaffBasicInfo.getOffice().getId());
             officeIdList.add(workStaffBasicInfo.getOffice().getId());
             workStaffBasicInfo.setOfficeIdList(officeIdList);
-        }
+        }*/
 		return super.findPage(page, workStaffBasicInfo);
 	}
 	//微信
@@ -279,7 +308,7 @@ public class WorkStaffBasicInfoService extends CrudService<WorkStaffBasicInfoDao
             userService.deleteUserRoleById(workStaffBasicInfo.getUserId());
             //新增人员岗位信息
             for (String info : roleIdList) {
-                if(StringUtils.isNotBlank(info)){
+                if(StringUtils.isNotBlank(info) && !"879dc3466ce5456eae4e157ac1f7115e".equals(info) && !"6782872939fe469a8a23778c7aa99724".equals(info)){
                     userService.insertRoleByUserId(workStaffBasicInfo.getUserId(),info);
                 }
             }

+ 3 - 0
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectRecordsDao.xml

@@ -2630,6 +2630,9 @@
 			<if test="projectName != null and projectName != ''">
 				AND a.project_name like concat(concat('%',#{projectName}),'%')
 			</if>
+			<if test="projectReportNumber != null and projectReportNumber != ''">
+				AND prd.number like concat(concat('%',#{projectReportNumber}),'%')
+			</if>
 			AND (a.paper_filing_status != 10 or a.paper_filing_status is null)
 			and a.submit_money = 1
 			and a.del_flag = 0 and a.project_type in (1,2)

+ 1 - 1
src/main/resources/mappings/modules/signature/projectReport/ProjectReportSignatureDao.xml

@@ -645,7 +645,7 @@
 	</select>
 
 	<select id="getDutyPersonList" resultType="com.jeeplus.modules.sys.entity.User">
-		select z.* from (
+		select DISTINCT z.* from (
 			select y.* from (
 			SELECT
 				su.id,

+ 10 - 1
src/main/resources/mappings/modules/sys/UserDao.xml

@@ -272,6 +272,9 @@
 		<if test="mobile != null and mobile != ''">
 			AND a.mobile = #{mobile}
 		</if>
+		<if test="loginFlag != null and loginFlag != ''">
+			AND a.login_flag = #{loginFlag}
+		</if>
 		<!-- 数据范围过滤 -->
 		${sqlMap.dsf}
 		<choose>
@@ -1261,6 +1264,12 @@
 		where id = #{id}
 	</update>
 
+	<update id="updateUserOfficeByUserId">
+		update sys_user_office
+		set office_id = #{officeId}
+		where user_id = #{userId}
+	</update>
+
 	<!-- 根据登录名查询用户 -->
 	<select id="findUserByUserName" resultType="User" parameterType="User">
 		SELECT
@@ -1354,7 +1363,7 @@
 	</select>
 
 	<delete id="deleteUserRoleById">
-		delete from sys_user_role where user_id = #{userId}
+		delete from sys_user_role where user_id = #{userId} and role_id not in ('879dc3466ce5456eae4e157ac1f7115e','6782872939fe469a8a23778c7aa99724')
 	</delete>
 
 

+ 99 - 1
src/main/resources/mappings/modules/workinvoice/WorkInvoiceDao.xml

@@ -1789,7 +1789,8 @@
 	<update id="cancellationDelete">
 		UPDATE work_invoice SET
 			cancellation_process_instance_id='',
-			cancellation_state = 0
+			cancellation_state = 0,
+			invoice_state=5
 		WHERE id = #{id}
 	</update>
 
@@ -2751,4 +2752,101 @@
 			electronic_invoice_flag = #{electronicInvoiceFlag}
 		WHERE id = #{id}
 	</update>
+
+	<select id="getOverDueGatheringInvoiceList" resultType="WorkInvoice">
+		select
+		a.id AS "id",
+		a.number AS "number",
+		a.process_instance_id AS "processInstanceId",
+		a.client_id AS "client.id",
+		a.money AS "money",
+		a.money AS "moneyStr",
+		a.invoice_type AS "invoiceType",
+		(case when a.invoice_type = '1' then '专票' when a.invoice_type = '2' then '普票' else '' end) as invoiceTypeStr,
+		a.charge_type AS "chargeType",
+		a.content AS "content",
+		a.drawer_id AS "drawer.id",
+		a.office_id AS "office.id",
+		a.invoice_number AS "invoiceNumber",
+		a.invoice_date AS "invoiceDate",
+		a.drawer_name AS "drawerName",
+		a.take_date AS "takeDate",
+		a.invoice_remarks AS "invoiceRemarks",
+		a.is_invoice AS "isInvoice",
+		a.is_charge AS "isCharge",
+		a.is_invalid AS "isInvalid",
+		a.create_by AS "createBy.id",
+		a.create_date AS "createDate",
+		a.update_by AS "updateBy.id",
+		a.update_date AS "updateDate",
+		a.remarks AS "remarks",
+		a.del_flag AS "delFlag",
+		a.orUnicode AS "orUnicode",
+		a.address AS "address",
+		a.telephone AS "telephone",
+		a.bank AS "bank",
+		a.bank_number AS "bankNumber",
+		a.cancle_reason AS "cancaleReason",
+		a.invoice_state AS "invoiceState",
+		a.company_id AS "companyId",
+		a.cancle_reason AS "cancleReason",
+		a.officee_id AS "officeId",
+		a.province AS "province",
+		a.ext AS "ext",
+		a.billing_content as "billingContent",
+		a.receipt_money_date as "receiptMoneyDate",
+		a.cancellation_remark as "cancellationRemark",
+		a.account_checking_user_id as "accountCheckingUserId",
+		a.area_id as "area.id",
+		a.new_drawer_id as "newDrawerId",
+		a.new_drawer as "newDrawer",
+		a.actual_drawer_email_address as "actualDrawerEmailAddress",
+		a.actual_drawer_id as "actualDrawerId",
+		a.electronic_invoice_flag as "electronicInvoiceFlag",
+		datediff(now(), a.invoice_date) as adventDate
+		from work_invoice a
+		<where>
+			a.invoice_date &lt;= #{invoiceDate}
+			and a.del_flag = 0
+			and (a.receipt_money_date is null and a.receipt_money = 0)
+		</where>
+	</select>
+
+	<select id="getInvoiceMoneyByMonthAndOffice" resultType="java.lang.String">
+		select COALESCE(ROUND(SUM(total_money), 2), 0) from work_invoice_detail
+		<where>
+			invoice_id in (
+			select id from work_invoice
+			<where>
+				del_flag = 0
+				<if test="null != officeId and officeId != ''">
+					and office_id = #{officeId}
+				</if>
+				 and invoice_date between #{beginDate} and #{endDate}
+			</where>
+			) and del_flag = 0
+
+		</where>
+	</select>
+
+	<select id="getInvoiceMoneyByMonthAndOfficeList" resultType="java.lang.String">
+		select COALESCE(ROUND(SUM(total_money), 2), 0) from work_invoice_detail
+		<where>
+			invoice_id in (
+			select id from work_invoice
+			<where>
+				del_flag = 0
+
+				<if test="officeIdList!=null and officeIdList.size!=0">
+					and office_id not in
+					<foreach collection="officeIdList" item="officeId" separator="," open="(" close=")">
+						#{officeId}
+					</foreach>
+				</if>
+				and invoice_date between #{beginDate} and #{endDate}
+			</where>
+			) and del_flag = 0
+
+		</where>
+	</select>
 </mapper>

+ 2 - 2
src/main/resources/mappings/modules/workstaff/WorkStaffBasicInfoDao.xml

@@ -194,9 +194,9 @@
 			<if test="company != null and company.id != null and company.id != ''">
 				AND a.company_id = #{company.id}
 			</if>
-			<if test="office != null and office.id != null and office.id != ''">
+			<!--<if test="office != null and office.id != null and office.id != ''">
 				AND a.office_id = #{office.id}
-			</if>
+			</if>-->
 			<if test="office != null and office.id =='' and office.name != null and office.name != ''">
 				AND o.name like concat("%",#{office.name},"%")
 			</if>

+ 2 - 2
src/main/webapp/static/common/jeeplus.js

@@ -626,8 +626,8 @@ function getPaymentState(id)
     result.action = true;
     switch(id)
     {
-        case "0":result.label = "tempstore";result.status="未付款";result.action = false;break;
-        case "1":result.label = "signed";result.status="已付款";result.action = true;break;
+        case "0":result.label = "tempstore";result.status="未审批";result.action = false;break;
+        case "1":result.label = "signed";result.status="已审批";result.action = true;break;
         default:
             result.label = "unknown";result.status="未知";break;
     }

+ 1 - 1
src/main/webapp/webpage/include/head.jsp

@@ -36,7 +36,7 @@
 
 <!-- jeeplus -->
 <link href="${ctxStatic}/common/jeeplus.css" type="text/css" rel="stylesheet" />
-<script src="${ctxStatic}/common/jeeplus.js?19" type="text/javascript"></script>
+<script src="${ctxStatic}/common/jeeplus.js?20" type="text/javascript"></script>
 <script type="text/javascript" src="${ctxStatic}/common/openShow.js"></script>
 
 <!-- jquery ui -->

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

@@ -195,7 +195,7 @@
 						<th>电话</th>
 						<th>手机</th>
 						<th><span class="require-item">*</span>长期/临时</th>
-						<shiro:hasPermission name="sys:user:edit"><th width="80">操作</th></shiro:hasPermission>
+						<th width="80">操作</th>
 					</tr>
 					</thead>
 					<tbody>
@@ -214,9 +214,9 @@
 									<option value="1" <c:if test="${user.isTemplate=='1'}">selected</c:if>>长期</option>
 								</select>
 							</td>
-							<shiro:hasPermission name="sys:role:edit"><td class="op-td">
+							<td class="op-td">
 								<button class="btn btn-danger delete-btn">删除</button>
-							</td></shiro:hasPermission>
+							</td>
 						</tr>
 					</c:forEach>
 					</tbody>

+ 6 - 0
src/main/webapp/webpage/modules/projectFilingBatch/projectChoiceLink.jsp

@@ -70,6 +70,12 @@
 								<input name="projectName" htmlEscape="false" maxlength="50" class=" form-control layui-input"/>
 							</div>
 						</div>
+						<div class="layui-item query athird lw9">
+							<span class="layui-form-label">报告号:</span>
+							<div class="layui-input-block">
+								<input name="projectReportNumber" htmlEscape="false" maxlength="50" class=" form-control layui-input"/>
+							</div>
+						</div>
 						<div class="layui-item athird fr">
 							<div class="input-group">
 								<button id="searchReset" class="fixed-btn searchReset fr" style="margin-right: 0px;" onclick="resetSearch()">重置</button>

+ 16 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/newReportedForm.jsp

@@ -364,6 +364,14 @@
             /*$('#city').html('<option value="${ruralProjectRecordsReported.s2}">${ruralProjectRecordsReported.city}</option>')
             $('#county').html('<option value="${ruralProjectRecordsReported.s3}">${ruralProjectRecordsReported.county}</option>')
             layui.form.render("select");*/
+            var secrecy = '${ruralProjectRecordsReported.secrecy}'
+            console.log(secrecy)
+            if(secrecy == 0) {
+                $("#secrecy").attr("checked",true);
+            }else if(secrecy == 1){
+                $("#secrecy1").attr("checked",true);
+            }
+
 
             layui.use(['table','form', 'layer'], function(){
 
@@ -1224,6 +1232,14 @@
                         <form:input path="ZiXunShouRu" placeholder="请输入造价咨询营业收入" htmlEscape="false" onblur="onblurNum(this)" onkeyup="num(this)" onchange="zxChange()" class="form-control number judgment layui-input"/>
                     </div>
                 </div>
+
+                <%--<div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>是否是保密项目</label>
+                    <div class="layui-input-block">
+                        <input type="radio" title="否" name="secrecy" checked id="secrecy" value="0">
+                        <input type="radio" title="是" name="secrecy" id="secrecy1" value="1">
+                    </div>
+                </div>--%>
             </div>
 
 

+ 22 - 1
src/main/webapp/webpage/modules/ruralprojectrecords/cost/newReported/reportedAudit.jsp

@@ -168,6 +168,8 @@
                         var otherIncome = $("#otherIncome").val();
                         var ziXunShouRu = $("#ZiXunShouRu").val();
                         var total =  parseFloat(projectSupervisionIncome) + parseFloat(tenderingAgencyIncome) + parseFloat(designIncome) + parseFloat(otherIncome) + parseFloat(ziXunShouRu);
+                        console.log(parseFloat(total))
+                        console.log(parseFloat(advisoryIncome))
                         if(parseFloat(total) > parseFloat(advisoryIncome)){
                             parent.layer.msg("全过程各项收入填写不正确或不能超过全过程工程咨询收入!", {icon: 5});
                             return false;
@@ -371,6 +373,14 @@
             $('#county').html('<option value="${ruralProjectRecordsReported.s3}">${ruralProjectRecordsReported.county}</option>')
             layui.form.render("select");*/
 
+            var secrecy = '${ruralProjectRecordsReported.secrecy}'
+            console.log(secrecy)
+            if(secrecy == 0) {
+                $("#secrecy").attr("checked",true);
+            }else if(secrecy == 1){
+                $("#secrecy1").attr("checked",true);
+            }
+
             layui.use(['table','form', 'layer'], function(){
 
                 var form = layui.form;
@@ -481,12 +491,14 @@
                 }
                     //有无合同监听器
                 layui.form.on('radio(ext)', function(data){
+                    console.log("31251231231")
                     var span=data.value;
                     if(span==10){
                         $("#cityDiv").show();
                         $("#countyDiv").show();
                         $("#nullDiv").show();
                         $("#d2").hide();
+                        $("#otherProvinces").val("");
                         $('#city').html('<option value="">请选择工程所在地级市</option>')
                         $.ajax({
                             type:"post",
@@ -533,6 +545,7 @@
                         $("#cityDiv").hide();
                         $("#countyDiv").hide();
                         $("#nullDiv").hide();
+                        $("#county").val("");
                         $.ajax({
                             type:"post",
                             url:'${ctx}/ruralProject/ruralProjectMessage/getArea',
@@ -1231,6 +1244,14 @@
                         <form:input path="ZiXunShouRu" placeholder="请输入造价咨询营业收入" htmlEscape="false" onblur="onblurNum(this)" onkeyup="num(this)" onchange="zxChange()" class="form-control judgment layui-input"/>
                     </div>
                 </div>
+
+                <%--<div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>是否是保密项目</label>
+                    <div class="layui-input-block">
+                        <input type="radio" title="否" name="secrecy" checked id="secrecy" value="0">
+                        <input type="radio" title="是" name="secrecy" id="secrecy1" value="1">
+                    </div>
+                </div>--%>
             </div>
 
 
@@ -1462,7 +1483,7 @@
                     <div class="layui-item layui-col-sm6 lw6">
                         <label class="layui-form-label double-line"><span class="require-item">*</span>工程项目总投资(万元):</label>
                         <div class="layui-input-block with-icon">
-                            <form:input path="projectTotalInvestment" placeholder="请输入工程项目总投资" onkeyup="num(this)" disabled="true" htmlEscape="false"  class="form-control judgment layui-input number"/>
+                            <form:input path="projectTotalInvestment" placeholder="请输入工程项目总投资" onkeyup="num(this)" htmlEscape="false"  class="form-control judgment layui-input number"/>
                         </div>
                     </div>
                     <div class="layui-item layui-col-sm6 lw6">

+ 19 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/newReported/reportedForm.jsp

@@ -357,6 +357,15 @@
             $('#county').html('<option value="${ruralProjectRecordsReported.s3}">${ruralProjectRecordsReported.county}</option>')
             layui.form.render("select");*/
 
+
+            var secrecy = '${ruralProjectRecordsReported.secrecy}'
+            console.log(secrecy)
+            if(secrecy == 0) {
+                $("#secrecy").attr("checked",true);
+            }else if(secrecy == 1){
+                $("#secrecy1").attr("checked",true);
+            }
+
             layui.use(['table','form', 'layer'], function(){
 
                 var form = layui.form;
@@ -473,6 +482,7 @@
                         $("#countyDiv").show();
                         $("#nullDiv").show();
                         $("#d2").hide();
+                        $("#otherProvinces").val("");
                         $('#city').html('<option value="">请选择工程所在地级市</option>')
                         $.ajax({
                             type:"post",
@@ -519,6 +529,7 @@
                         $("#cityDiv").hide();
                         $("#countyDiv").hide();
                         $("#nullDiv").hide();
+                        $("#county").val("");
                         $.ajax({
                             type:"post",
                             url:'${ctx}/ruralProject/ruralProjectMessage/getArea',
@@ -1193,6 +1204,14 @@
                         <form:input path="ZiXunShouRu" placeholder="请输入造价咨询营业收入" htmlEscape="false" onblur="onblurNum(this)" onkeyup="num(this)" onchange="zxChange()" class="form-control judgment layui-input"/>
                     </div>
                 </div>
+
+                <%--<div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>是否是保密项目</label>
+                    <div class="layui-input-block">
+                        <input type="radio" title="否" name="secrecy" checked id="secrecy" value="0">
+                        <input type="radio" title="是" name="secrecy" id="secrecy1" value="1">
+                    </div>
+                </div>--%>
             </div>
 
 

+ 17 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/view/reportedView.jsp

@@ -106,6 +106,15 @@
                 var con=contents[i];
                 $(".contents_"+con+"").prop("checked",true)
             }
+
+
+            var secrecy = '${ruralProjectRecordsReported.secrecy}'
+            console.log(secrecy)
+            if(secrecy == 0) {
+                $("#secrecy").attr("checked",true);
+            }else if(secrecy == 1){
+                $("#secrecy1").attr("checked",true);
+            }
         });
     </script>
 </head>
@@ -280,6 +289,14 @@
                         <form:input path="ZiXunShouRu" placeholder="请输入造价咨询营业收入" readonly="true" htmlEscape="false" onchange="zxChange()" class="form-control required layui-input"/>
                     </div>
                 </div>
+
+                <%--<div class="layui-item layui-col-sm6 lw6">
+                    <label class="layui-form-label double-line"><span class="require-item">*</span>是否是保密项目</label>
+                    <div class="layui-input-block">
+                        <input type="radio" title="否" disabled name="secrecy" checked id="secrecy" value="0">
+                        <input type="radio" title="是" disabled name="secrecy" id="secrecy1" value="1">
+                    </div>
+                </div>--%>
             </div>
 
 

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

@@ -390,12 +390,12 @@
                             </c:if>
                         </shiro:hasPermission>
                         <button class="layui-btn layui-btn-sm" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
-                        <c:if test="${isArea != '1'}">
+                        <%--<c:if test="${isArea != '1'}">
                             <button class="layui-btn layui-btn-sm layui-bg-blue" title="地区负责人申请" onclick="openDialogDis('地区负责人申请','${ctx}/districtDirectorApplication/districtDirectorApplication/form','95%','95%')">&nbsp;地区负责人申请</button>
                         </c:if>
                         <c:if test="${isArea == '1'}">
                             <button class="layui-btn layui-btn-sm layui-bg-blue" title="地区负责人申请详情" onclick="openDialogForm('地区负责人申请详情','${ctx}/districtDirectorApplication/districtDirectorApplication/ListByCreate','95%','95%','','关闭')">&nbsp;地区负责人申请详情</button>
-                        </c:if>
+                        </c:if>--%>
 
 
                     </div>

+ 1 - 1
src/main/webapp/webpage/modules/sys/sysLogin.jsp

@@ -18,7 +18,7 @@
 	<link href="${ctxStatic}/awesome/4.4/css/font-awesome.min.css" rel="stylesheet" />
 	<!-- jeeplus -->
 	<link href="${ctxStatic}/common/jeeplus.css" type="text/css" rel="stylesheet" />
-	<script src="${ctxStatic}/common/jeeplus.js?19" type="text/javascript"></script>
+	<script src="${ctxStatic}/common/jeeplus.js?20" type="text/javascript"></script>
 	<link rel="shortcut icon" href="images/favicon.png" type="image/png">
 	<!-- text fonts -->
 	<link rel="stylesheet" href="${ctxStatic }/common/login/ace-fonts.css" />

+ 1 - 1
src/main/webapp/webpage/modules/sys/sysLogin2.jsp

@@ -16,7 +16,7 @@
 		<link href="${ctxStatic}/awesome/4.4/css/font-awesome.min.css" rel="stylesheet" />
 		<!-- jeeplus -->
 		<link href="${ctxStatic}/common/jeeplus.css" type="text/css" rel="stylesheet" />
-		<script src="${ctxStatic}/common/jeeplus.js?19" type="text/javascript"></script>
+		<script src="${ctxStatic}/common/jeeplus.js?20" type="text/javascript"></script>
 		<link rel="shortcut icon" href="images/favicon.png" type="image/png">
 		<!-- text fonts -->
 		<link rel="stylesheet" href="${ctxStatic }/common/login/ace-fonts.css" />

+ 69 - 0
src/main/webapp/webpage/modules/workinvoice/downloadInvoiceForm.jsp

@@ -0,0 +1,69 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>选择下载模板类型</title>
+	<meta name="decorator" content="default"/>
+	<script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+	<script type="text/javascript">
+
+		function doSubmit(){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+			// 获取 <select> 元素
+			var selectElement = document.getElementById('year');
+			// 获取当前选择的值
+			var selectedValue = selectElement.value;
+			if(!selectedValue){
+				parent.layer.msg("请选择需要导出汇总发票的具体年份!", {icon: 5});
+				return false;
+			}
+
+		   $("#inputForm").submit();
+		  return true;
+		}
+        var validateForm;
+		$(document).ready(function() {
+			validateForm = $("#inputFormAdd").validate({
+				submitHandler: function(form){
+					loading('正在提交,请稍等...');
+					form.submit();
+				},
+				errorContainer: "#messageBox",
+				errorPlacement: function(error, element) {
+					$("#messageBox").text("输入有误,请先更正。");
+					if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
+						error.appendTo(element.parent().parent());
+					} else {
+						error.insertAfter(element);
+					}
+				}
+			});
+			layui.use(['form', 'layer'], function () {
+				var form = layui.form;
+			})
+		});
+	</script>
+</head>
+<body>
+<div class="single-form-small">
+	<div class="container">
+		<form:form id="inputForm" modelAttribute="workInvoice" action="${ctx}/workinvoiceTwo/workinvoiceTwo/exportExcel" method="post" class="layui-form">
+			<div class="form-group layui-row first">
+				<input type="hidden" id="view" name="view" value="${view}">
+				<div class="layui-item layui-col-sm8">
+					<label class="layui-form-label double-line"><span class="require-item">*</span>导出发票年份:</label>
+					<div class="layui-input-block readOnlyFFF">
+						<select class="form-control required layui-input" id="year" name="year">
+							<option value=""></option>
+							<c:forEach items="${yearList}" var="year" varStatus="status">
+								<option value="${year}" <c:if test="${workInvoice.year eq year }">selected</c:if>>${year}</option>
+							</c:forEach>
+						</select>
+					</div>
+				</div>
+			</div>
+		</form:form>
+	</div>
+</div>
+</body>
+</html>

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

@@ -392,6 +392,46 @@
 		}
 
 
+
+
+		function downloadDialogre(title,url,width,height,target,buttons) {
+			if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+				width = 'auto';
+				height = 'auto';
+			} else {//如果是PC端,根据用户设置的width和height显示。
+
+			}
+			var split = buttons.split(",");
+			top.layer.open({
+				type: 2,
+				area: [width, height],
+				title: title,
+				maxmin: true, //开启最大化最小化按钮
+				skin:"two-btns",
+				content: url,
+				btn: split,
+				yes: function(index, layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(1) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}
+				},
+				cancel: function (index) {
+				}
+			});
+		}
+
+
 	</script>
 	<style>
 		body{
@@ -610,6 +650,10 @@
 						<shiro:hasPermission name="workinvoiceAll:workinvoiceAll:export">
 							<table:exportExcel url="${ctx}/workinvoiceAll/workInvoiceAll/export"></table:exportExcel><!-- 导出按钮 -->
 						</shiro:hasPermission>
+
+						<shiro:hasPermission name="workInvoiceTwo:workInvoiceTwo:invoiceReport">
+							<a href="javascript:void(0)" style='background-color: #FFB800' onclick="downloadDialogre('开票汇总信息导出', '${ctx}/workinvoiceTwo/workinvoiceTwo/skipDownloadInvoiceForm?view=workInvoiceAll','40%', '35%','','下载,关闭')" class="layui-btn layui-btn-sm layui-bg-blue" > 开票汇总信息导出</a>
+						</shiro:hasPermission>
 						<button class="layui-btn layui-btn-sm layui-bg-green" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
 						<div class=" layui-btn-sm" style="float: right;width: 300px">
 							<span style="color: #999999">金额汇总(开票金额):${sumMoney}(元)</span>
@@ -703,6 +747,18 @@
                             var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
                         return xml;
                     }}
+				/*,{align:'center', title: '作废状态', fixed: 'right', width:70,templet:function(d){
+						<%--var st = getAuditState(d.status);--%>
+
+						<%--var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/workinvoice/workInvoice/getProcessOne?id=" + d.id + "','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";--%>
+						<%--return xml;--%>
+						var st = getCancellationAuditState(d.cancellationStatus);
+						if(st.action)
+							var xml = "<span onclick=\"openDialogListView('发票作废流程追踪', '${ctx}/workinvoiceTwo/workinvoiceTwo/getCancellationProcess?id=" + d.id + "','"+ d.id +"','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+						else
+							var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >"+ st.status + "</span>";
+						return xml;
+					}}*/
                 ,{field:'op',align:'center',title:"操作",fixed: 'right',width:220,templet:function(d){
                         ////对操作进行初始化
                         var xml="<div class=\"layui-btn-group\">";
@@ -730,7 +786,7 @@
                         {
                             xml += "<a href=\"javascript:void(0)\" onclick=\"contractOpenDialogre('变更发票管理', '${ctx}/workinvoiceAll/workInvoiceAll/alterForm?id="+ d.id +"','95%','95%')\" class=\"op-btn op-btn-revert\" ><i class=\"fa fa-edit\"></i> 变更</a>";
                         }*/
-						if(d.modifyDetails != undefined && d.modifyDetails =="1" && d.financeFlag =="1")
+						if(d.modifyDetails != undefined && d.modifyDetails =="1" && d.financeFlag =="1" && (null == d.cancellationState || undefined == d.cancellationState || '' == d.cancellationState))
 						{
 							xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改发票明细', '${ctx}/workinvoiceAllTwo/workinvoiceAllTwo/modifyDetails?id=" + d.id + " &home=oldInfo ','"+ d.id+"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改明细</a>";
 						}
@@ -738,7 +794,7 @@
 						{
 							xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('管理员修改发票', '${ctx}/workinvoiceAll/workInvoiceAll/form?id=" + d.id + "&tabId=3','"+ d.id+"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >管理员修改</a>";
 						}
-						if(d.financeFlag != undefined && d.financeFlag =="1")
+						if(d.financeFlag != undefined && d.financeFlag =="1" && (null == d.cancellationState || undefined == d.cancellationState || '' == d.cancellationState))
 						{
 							xml +="<a href=\"javascript:void(0)\" onclick=\"receiptInvoice('发票收款', '${ctx}/workinvoiceAll/workInvoiceAll/receiptForm?id=" + d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-orange\" > 收款</a>";
 							xml+="<a href=\"${ctx}/workinvoiceAll/workInvoiceAll/saveAffirmReceipt?id=" + d.id + "\" onclick=\"return confirmx('是否确认收款?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-orange\"> 确认收款</a>";
@@ -792,6 +848,7 @@
                     ,"projectId":"${workInvoice.project.id}"
                     ,"areaName":"${workInvoice.project.county}"
                     ,"reportNumber":"${workInvoice.project.reportData.number}"
+					,"cancellationStatus":"${workInvoice.cancellationState}"
                     ,"projName":"${workInvoice.projectName}"
                     ,"clientName":"${workInvoice.client.name}"
                     ,"officeName":"${workInvoice.office.name}"

+ 44 - 0
src/main/webapp/webpage/modules/workinvoice/workInvoiceAllTwoList.jsp

@@ -477,6 +477,46 @@
 			}
 		}
 
+
+
+
+		function downloadDialogre(title,url,width,height,target,buttons) {
+			if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+				width = 'auto';
+				height = 'auto';
+			} else {//如果是PC端,根据用户设置的width和height显示。
+
+			}
+			var split = buttons.split(",");
+			top.layer.open({
+				type: 2,
+				area: [width, height],
+				title: title,
+				maxmin: true, //开启最大化最小化按钮
+				skin:"two-btns",
+				content: url,
+				btn: split,
+				yes: function(index, layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(1) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}
+				},
+				cancel: function (index) {
+				}
+			});
+		}
+
 	</script>
 	<style>
 		body{
@@ -692,6 +732,10 @@
 						<shiro:hasPermission name="workinvoiceAllTwo:workinvoiceAllTwo:export">
 							<table:exportExcel url="${ctx}/workinvoiceAllTwo/workinvoiceAllTwo/export"></table:exportExcel><!-- 导出按钮 -->
 						</shiro:hasPermission>
+
+						<shiro:hasPermission name="workInvoiceTwo:workInvoiceTwo:invoiceReport">
+							<a href="javascript:void(0)" style='background-color: #FFB800' onclick="downloadDialogre('开票汇总信息导出', '${ctx}/workinvoiceTwo/workinvoiceTwo/skipDownloadInvoiceForm?view=workInvoiceAllTwo','40%', '35%','','下载,关闭')" class="layui-btn layui-btn-sm layui-bg-blue" > 开票汇总信息导出</a>
+						</shiro:hasPermission>
 						<button class="layui-btn layui-btn-sm layui-bg-green" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
 						<div class=" layui-btn-sm" style="float: right;width: 300px">
 							<span style="color: #999999">金额汇总(开票金额):${sumMoney}(元)</span>

+ 46 - 0
src/main/webapp/webpage/modules/workinvoice/workInvoiceTwoList.jsp

@@ -183,6 +183,47 @@
 			});
 		}
 
+
+
+		function downloadDialogre(title,url,width,height,target,buttons) {
+			if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+				width = 'auto';
+				height = 'auto';
+			} else {//如果是PC端,根据用户设置的width和height显示。
+
+			}
+			var split = buttons.split(",");
+			top.layer.open({
+				type: 2,
+				area: [width, height],
+				title: title,
+				maxmin: true, //开启最大化最小化按钮
+				skin:"two-btns",
+				content: url,
+				btn: split,
+				yes: function(index, layero){
+					var body = top.layer.getChildFrame('body', index);
+					var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var inputForm = body.find('#inputForm');
+					var top_iframe;
+					if(target){
+						top_iframe = target;//如果指定了iframe,则在改frame中跳转
+					}else{
+						top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+					}
+					inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+					if(iframeWin.contentWindow.doSubmit(1) ){
+						// top.layer.close(index);//关闭对话框。
+						setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+					}
+				},
+				cancel: function (index) {
+				}
+			});
+		}
+
+
+
 		function receiptInvoice(title,url,width,height,target){
 
 			if(navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)){//如果是移动端,就使用自适应大小弹窗
@@ -734,6 +775,11 @@
 						<shiro:hasPermission name="workinvoiceTwo:workinvoiceTwo:export">
 							<table:exportExcel url="${ctx}/workinvoiceTwo/workinvoiceTwo/export"></table:exportExcel><!-- 导出按钮 -->
 						</shiro:hasPermission>
+
+						<shiro:hasPermission name="workInvoiceTwo:workInvoiceTwo:invoiceReport">
+							<a href="javascript:void(0)" style='background-color: #FFB800' onclick="downloadDialogre('开票汇总信息导出', '${ctx}/workinvoiceTwo/workinvoiceTwo/skipDownloadInvoiceForm?view=workInvoiceTwo','40%', '35%','','下载,关闭')" class="layui-btn layui-btn-sm layui-bg-blue" > 开票汇总信息导出</a>
+						</shiro:hasPermission>
+
 						<button class="layui-btn layui-btn-sm layui-bg-green" data-toggle="tooltip" data-placement="left" onclick="sortOrRefresh()" title="刷新"> 刷新</button>
 						<div class=" layui-btn-sm" style="float: right;width: 300px">
 							<span style="color: #999999">金额汇总(开票金额):${sumMoney}(元)</span>

+ 9 - 7
src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllFormAdd.jsp

@@ -29,11 +29,11 @@
             })
             var reimbursementTypeRadio = '${workReimbursement.reimbursementType}';//后端获取值
             if(undefined == reimbursementTypeRadio || null == reimbursementTypeRadio || '' == reimbursementTypeRadio || reimbursementTypeRadio == "0"){
-                document.getElementsByName("reimbursementType")[0].checked = true;
+                //document.getElementsByName("reimbursementType")[0].checked = true;
                 $(".count2").hide();
                 $(".count1").show();
             }else{
-                document.getElementsByName("reimbursementType")[1].checked = true;
+                //document.getElementsByName("reimbursementType")[1].checked = true;
                 $(".count1").hide();
                 $(".count2").show();
             }
@@ -180,15 +180,16 @@
                     flags= false;
                 }
                 //判断报销类型是否为电子报销
-                var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+                //var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+                var reimbursementType = $("#reimbursementType").val();
 
-                if(reimbursementType == '1'){
+                /*if(reimbursementType == '1'){
                     var leng = $("#file_attachment_InvoiceReimbursement tr").length;
                     if(leng === 0){
                         parent.layer.msg("请上传数电发票xml文件!", {icon: 5});
                         flags= false;
                     }
-                }
+                }*/
 
                 var electronicInvoiceArr = $("#reimbursementElectronicInvoiceVATTaxes tr:visible");
                 if(electronicInvoiceArr.length>0){
@@ -877,6 +878,7 @@
         <form:hidden path="submitterId"/>
         <input type="hidden" id="numberFlag" value="${workReimbursement.number}" />
         <input id="wId" type="hidden" value="${workReimbursement.id}">
+        <input id="reimbursementType" name="reimbursementType" type="hidden" value="${workReimbursement.reimbursementType}">
         <div class="form-group layui-row first">
             <div class="form-group-label">
                 <div style="float: right">
@@ -886,13 +888,13 @@
                 </div>
                 <h2>基础信息</h2>
             </div>
-            <div class="layui-item layui-col-sm6">
+            <%--<div class="layui-item layui-col-sm6">
                 <label class="layui-form-label"><span class="require-item">*</span>报销类型:</label>
                 <div class="layui-input-block layui-form">
                     <input type="radio" name="reimbursementType" lay-filter="reimbursementTypeRadio" title="普通报销" value="0">
                     <input type="radio" name="reimbursementType" lay-filter="reimbursementTypeRadio" title="数电发票报销" value="1">
                 </div>
-            </div>
+            </div>--%>
             <div class="layui-item layui-col-sm6">
                 <label class="layui-form-label">报销编号:</label>
                 <div class="layui-input-block">

+ 2 - 2
src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllFormDetail.jsp

@@ -136,12 +136,12 @@
             <h2>基础信息</h2>
         </div>
 
-        <div class="layui-item layui-col-sm6">
+        <%--<div class="layui-item layui-col-sm6">
             <label class="layui-form-label"><span class="require-item">*</span>报销项:</label>
             <div class="layui-input-block">
                 <input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value = "${workReimbursement.reimbursementTypeStr}"/>
             </div>
-        </div>
+        </div>--%>
 
         <div class="layui-item layui-col-sm6">
             <label class="layui-form-label">报销编号:</label>

+ 9 - 7
src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllModifyApply.jsp

@@ -29,11 +29,11 @@
 
             var reimbursementTypeRadio = '${workReimbursement.reimbursementType}';//后端获取值
             if(undefined == reimbursementTypeRadio || null == reimbursementTypeRadio || '' == reimbursementTypeRadio || reimbursementTypeRadio == "0"){
-                document.getElementsByName("reimbursementType")[0].checked = true;
+                //document.getElementsByName("reimbursementType")[0].checked = true;
                 $(".count2").hide();
                 $(".count1").show();
             }else{
-                document.getElementsByName("reimbursementType")[1].checked = true;
+                //document.getElementsByName("reimbursementType")[1].checked = true;
                 $(".count1").hide();
                 $(".count2").show();
             }
@@ -184,15 +184,16 @@
                 return false;
             }
             //判断报销类型是否为电子报销
-            var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+            //var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+            var reimbursementType = $("#reimbursementType").val();
 
-            if(reimbursementType == '1'){
+            /*if(reimbursementType == '1'){
                 var leng = $("#file_attachment_InvoiceReimbursement tr").length;
                 if(leng.length == 0){
                     parent.layer.msg("请上传数电发票xml文件!", {icon: 5});
                     flags= false;
                 }
-            }
+            }*/
 
             var electronicInvoiceArr = $("#reimbursementElectronicInvoiceVATTaxes tr:visible");
             if(electronicInvoiceArr.length>0){
@@ -957,15 +958,16 @@
     <form:hidden id="flag" path="act.flag"/>
         <input type="hidden" id="numberFlag" value="${workReimbursement.number}" />
         <input id="wId" type="hidden" value="${workReimbursement.id}">
+        <input id="reimbursementType" name="reimbursementType" type="hidden" value="${workReimbursement.reimbursementType}">
         <div class="form-group layui-row first">
             <div class="form-group-label"><h2>基础信息</h2></div>
-            <div class="layui-item layui-col-sm6">
+            <%--<div class="layui-item layui-col-sm6">
                 <label class="layui-form-label"><span class="require-item">*</span>报销项:</label>
                 <div class="layui-input-block layui-form">
                     <input type="radio" name="reimbursementType" disabled lay-filter="reimbursementTypeRadio" title="普通报销" value="0">
                     <input type="radio" name="reimbursementType" disabled lay-filter="reimbursementTypeRadio" title="数电发票报销" value="1">
                 </div>
-            </div>
+            </div>--%>
             <div class="layui-item layui-col-sm6">
                 <label class="layui-form-label">报销编号:</label>
                 <div class="layui-input-block">

+ 2 - 2
src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewAudit.jsp

@@ -138,12 +138,12 @@
 		<div class="form-group layui-row first ">
 			<div class="form-group-label"><h2>基础信息</h2></div>
 
-			<div class="layui-item layui-col-sm6">
+			<%--<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label"><span class="require-item">*</span>报销项:</label>
 				<div class="layui-input-block">
 					<input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value = "${workReimbursement.reimbursementTypeStr}"/>
 				</div>
-			</div>
+			</div>--%>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">报销编号:</label>
 				<div class="layui-input-block">

+ 9 - 7
src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewFormAdd.jsp

@@ -29,11 +29,11 @@
             })
             var reimbursementTypeRadio = '${workReimbursement.reimbursementType}';//后端获取值
             if(undefined == reimbursementTypeRadio || null == reimbursementTypeRadio || '' == reimbursementTypeRadio || reimbursementTypeRadio == "0"){
-                document.getElementsByName("reimbursementType")[0].checked = true;
+                //document.getElementsByName("reimbursementType")[0].checked = true;
                 $(".count2").hide();
                 $(".count1").show();
             }else{
-                document.getElementsByName("reimbursementType")[1].checked = true;
+                //document.getElementsByName("reimbursementType")[1].checked = true;
                 $(".count1").hide();
                 $(".count2").show();
             }
@@ -180,15 +180,16 @@
                     flags= false;
                 }
                 //判断报销类型是否为电子报销
-                var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+                //var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+                var reimbursementType = $("#reimbursementType").val();
 
-                if(reimbursementType == '1'){
+                /*if(reimbursementType == '1'){
                     var leng = $("#file_attachment_InvoiceReimbursement tr").length;
                     if(leng === 0){
                         parent.layer.msg("请上传数电发票xml文件!", {icon: 5});
                         flags= false;
                     }
-                }
+                }*/
 
                 var electronicInvoiceArr = $("#reimbursementElectronicInvoiceVATTaxes tr:visible");
                 if(electronicInvoiceArr.length>0){
@@ -877,6 +878,7 @@
         <form:hidden path="submitterId"/>
         <input type="hidden" id="numberFlag" value="${workReimbursement.number}" />
         <input id="wId" type="hidden" value="${workReimbursement.id}">
+        <input id="reimbursementType" name="reimbursementType" type="hidden" value="${workReimbursement.reimbursementType}">
         <div class="form-group layui-row first">
             <div class="form-group-label">
                 <div style="float: right">
@@ -886,13 +888,13 @@
                 </div>
                 <h2>基础信息</h2>
             </div>
-            <div class="layui-item layui-col-sm6">
+            <%--<div class="layui-item layui-col-sm6">
                 <label class="layui-form-label"><span class="require-item">*</span>报销类型:</label>
                 <div class="layui-input-block layui-form">
                     <input type="radio" name="reimbursementType" lay-filter="reimbursementTypeRadio" title="普通报销" value="0">
                     <input type="radio" name="reimbursementType" lay-filter="reimbursementTypeRadio" title="数电发票报销" value="1">
                 </div>
-            </div>
+            </div>--%>
             <div class="layui-item layui-col-sm6">
                 <label class="layui-form-label">报销编号:</label>
                 <div class="layui-input-block">

+ 9 - 7
src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewModifyApply.jsp

@@ -29,11 +29,11 @@
 
             var reimbursementTypeRadio = '${workReimbursement.reimbursementType}';//后端获取值
             if(undefined == reimbursementTypeRadio || null == reimbursementTypeRadio || '' == reimbursementTypeRadio || reimbursementTypeRadio == "0"){
-                document.getElementsByName("reimbursementType")[0].checked = true;
+                //document.getElementsByName("reimbursementType")[0].checked = true;
                 $(".count2").hide();
                 $(".count1").show();
             }else{
-                document.getElementsByName("reimbursementType")[1].checked = true;
+                //document.getElementsByName("reimbursementType")[1].checked = true;
                 $(".count1").hide();
                 $(".count2").show();
             }
@@ -184,15 +184,16 @@
                 return false;
             }
             //判断报销类型是否为电子报销
-            var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+            //var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+            var reimbursementType = $("#reimbursementType").val();
 
-            if(reimbursementType == '1'){
+            /*if(reimbursementType == '1'){
                 var leng = $("#file_attachment_InvoiceReimbursement tr").length;
                 if(leng.length == 0){
                     parent.layer.msg("请上传数电发票xml文件!", {icon: 5});
                     flags= false;
                 }
-            }
+            }*/
 
             var electronicInvoiceArr = $("#reimbursementElectronicInvoiceVATTaxes tr:visible");
             if(electronicInvoiceArr.length>0){
@@ -957,15 +958,16 @@
     <form:hidden id="flag" path="act.flag"/>
         <input type="hidden" id="numberFlag" value="${workReimbursement.number}" />
         <input id="wId" type="hidden" value="${workReimbursement.id}">
+        <input id="wId" type="hidden" value="${workReimbursement.reimbursementType}">
         <div class="form-group layui-row first">
             <div class="form-group-label"><h2>基础信息</h2></div>
-            <div class="layui-item layui-col-sm6">
+            <%--<div class="layui-item layui-col-sm6">
                 <label class="layui-form-label"><span class="require-item">*</span>报销项:</label>
                 <div class="layui-input-block layui-form">
                     <input type="radio" name="reimbursementType" disabled lay-filter="reimbursementTypeRadio" title="普通报销" value="0">
                     <input type="radio" name="reimbursementType" disabled lay-filter="reimbursementTypeRadio" title="数电发票报销" value="1">
                 </div>
-            </div>
+            </div>--%>
             <div class="layui-item layui-col-sm6">
                 <label class="layui-form-label">报销编号:</label>
                 <div class="layui-input-block">

+ 2 - 2
src/main/webapp/webpage/modules/workreimbursement/specific/workReimbursementSpecificAudit.jsp

@@ -100,12 +100,12 @@
 		<div class="form-group layui-row first ">
 			<div class="form-group-label"><h2>基础信息</h2></div>
 
-			<div class="layui-item layui-col-sm6">
+			<%--<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label"><span class="require-item">*</span>报销项:</label>
 				<div class="layui-input-block">
 					<input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value = "${workReimbursement.reimbursementTypeStr}"/>
 				</div>
-			</div>
+			</div>--%>
 			<div class="layui-item layui-col-sm6">
 				<label class="layui-form-label">报销编号:</label>
 				<div class="layui-input-block">

+ 9 - 7
src/main/webapp/webpage/modules/workreimbursement/specific/workReimbursementSpecificModifyApply.jsp

@@ -29,11 +29,11 @@
 
             var reimbursementTypeRadio = '${workReimbursement.reimbursementType}';//后端获取值
             if(undefined == reimbursementTypeRadio || null == reimbursementTypeRadio || '' == reimbursementTypeRadio || reimbursementTypeRadio == "0"){
-                document.getElementsByName("reimbursementType")[0].checked = true;
+               // document.getElementsByName("reimbursementType")[0].checked = true;
                 $(".count2").hide();
                 $(".count1").show();
             }else{
-                document.getElementsByName("reimbursementType")[1].checked = true;
+                //document.getElementsByName("reimbursementType")[1].checked = true;
                 $(".count1").hide();
                 $(".count2").show();
             }
@@ -145,15 +145,16 @@
                 return false;
             }
             //判断报销类型是否为电子报销
-            var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+            //var reimbursementType=$('input:radio[name="reimbursementType"]:checked').val();
+            var reimbursementType = $("#reimbursementType").val();
 
-            if(reimbursementType == '1'){
+            /*if(reimbursementType == '1'){
                 var leng = $("#file_attachment_InvoiceReimbursement tr").length;
                 if(leng.length == 0){
                     parent.layer.msg("请上传数电发票xml文件!", {icon: 5});
                     flags= false;
                 }
-            }
+            }*/
 
             /*var electronicInvoiceArr = $("#reimbursementElectronicInvoiceVATTaxes tr:visible");
             if(electronicInvoiceArr.length>0){
@@ -830,15 +831,16 @@
     <form:hidden id="flag" path="act.flag"/>
         <input type="hidden" id="numberFlag" value="${workReimbursement.number}" />
         <input id="wId" type="hidden" value="${workReimbursement.id}">
+        <input id="reimbursementType" name="reimbursementType" type="hidden" value="${workReimbursement.reimbursementType}">
         <div class="form-group layui-row first">
             <div class="form-group-label"><h2>基础信息</h2></div>
-            <div class="layui-item layui-col-sm6">
+            <%--<div class="layui-item layui-col-sm6">
                 <label class="layui-form-label"><span class="require-item">*</span>报销项:</label>
                 <div class="layui-input-block layui-form">
                     <input type="radio" name="reimbursementType" disabled lay-filter="reimbursementTypeRadio" title="普通报销" value="0">
                     <input type="radio" name="reimbursementType" disabled lay-filter="reimbursementTypeRadio" title="数电发票报销" value="1">
                 </div>
-            </div>
+            </div>--%>
             <div class="layui-item layui-col-sm6">
                 <label class="layui-form-label">报销编号:</label>
                 <div class="layui-input-block">

+ 131 - 108
src/main/webapp/webpage/modules/workreimbursement/workReimbursementAllList.jsp

@@ -212,118 +212,138 @@
 <script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
 <script>
     layui.use('table', function(){
+// 定义表格列
+        var tableShowView = [];
+
+        var topView = [
+            {field:'submitterId', align:'center', width:40, title: '序号'},
+            {field:'number', align:'center', title: '报销编号', width:150, templet:function(d){
+                    var xml = "<a class=\"attention-info\" href=\"javascript:void(0)\" onclick=\"openDialogListView('查看报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%','95%')\">" +
+                        "<span title=" + d.realnumber + ">" + d.number + "</span></a>";
+                    return xml;
+                }},
+
+        ];
+
+        var reimbursementTypeView = [
+            {field:'reimbursementType', align:'center', title: '报销项', width:100, templet:function(d){
+                    if (d.reimbursementType == 1 && d.reimbursementType != undefined) {
+                        return "<span title='数电发票报销'>数电发票报销</span>";
+                    } else {
+                        return "<span title='普通报销'>普通报销</span>";
+                    }
+                }},
+        ]
+
+        var middleView = [
+            {field:'businessTypeName', align:'center', title: '报销类别', width:100, templet:function(d){
+                    return "<span title='"+ d.businessTypeName +"'>" + d.businessTypeName + "</span>";
+                }},
+            {field:'projectId', align:'center', title: '报销项目', minWidth:150, templet:function(d){
+                    if (d.showView == 1 && d.showView != undefined) {
+                        return "<a class=\"attention-info\" title=\"" + d.projectId + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectView/view?id=" + d.proId +"','95%', '95%')\">" + d.projectId + "</a>";
+                    } else {
+                        return "<span title='"+ d.projectId +"'>" + d.projectId + "</span>";
+                    }
+                }},
+            {field:'projectNumber', align:'center', title: '报告号', width:100, templet:function(d){
+                    return "<span title='"+ d.projectNumber +"'>" + d.projectNumber + "</span>";
+                }},
+            {field:'handleName', align:'center', title: '经办人', width:100, templet:function(d){
+                    return "<span title='"+ d.handleName +"'>" + d.handleName + "</span>";
+                }},
+            {field:'submitterName', align:'center', title: '报销人', width:100, templet:function(d){
+                    return "<span title='"+ d.submitterName +"'>" + d.submitterName + "</span>";
+                }},
+            {field:'officeId', align:'center', title: '报销部门', width:130, templet:function(d){
+                    return "<span title='"+ d.officeId +"'>" + d.officeId + "</span>";
+                }},
+            {field:'submitterDate', align:'center', title: '报销日期', width:80},
+            {field:'money', align:'center', title: '报销金额(元)', width:150, templet:function(d){
+                    return "<span title='"+ d.money +"'>" + d.money + "</span>";
+                }},
+            {title: '状态', align:'center', width:70, templet:function(d){
+                    var st = getAuditState(d.status);
+                    var xml;
+                    if (st.action) {
+                        xml = "<span onclick=\"openDialogListView('报销单流程追踪', '${ctx}/workreimbursement/workReimbursementAll/getProcessOne?id=" + d.id + "','"+ d.id +"','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                    } else {
+                        xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                    }
+                    return xml;
+                }}
+        ]
+
+        var bottomView = [
+            {align:'center', title: '操作', width:130, templet:function(d){
+                    var xml = "<div class=\"layui-btn-group\">";
+                    if (d.notifyFlag != undefined && d.notifyFlag !=null && d.notifyFlag == 1) {
+                        xml += "<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement&pageFlag=all','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >审批</a>";
+                    }
+                    if (d.notifyFlag != undefined && d.notifyFlag !=null && d.notifyFlag == 3) {
+                        xml += "<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement&pageFlag=all','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >审批</a>";
+                    }
+                    if (d.paymentStatus != undefined && d.paymentStatus == 0 && d.paymentFlag != undefined && d.paymentFlag == 1) {
+                        xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/paymentSave?id=" + d.id + "&paymentStatus=1\" onclick=\"return confirmx('是否确认给报销编号为 " + d.number + " 的报销信息进行付款?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-blue\">付款</a>";
+                    }
+                    if (d.paymentStatus != undefined && d.paymentStatus == 1 && d.paymentFlag != undefined && d.paymentFlag == 1) {
+                        xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/paymentSave?id=" + d.id + "&paymentStatus=0\" onclick=\"return confirmx('是否确认对报销编号为 " + d.number + " 的报销信息进行撤回付款?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\">撤回付款</a>";
+                    }
+                    if (d.cancancel != undefined && d.cancancel == "1") {
+                        xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/cancelInvalidate?id=" + d.id + "\" onclick=\"return confirmx('确认要强制撤回?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\">撤回</a>";
+                    }
+                    if (d.canedit1 != undefined && d.canedit1 == "1") {
+                        xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogre('修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\">修改</a>";
+                    }
+                    if (d.canedit2 != undefined && d.canedit2 == "1") {
+                        xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\">修改</a>";
+                    }
+                    if (d.canedit3 != undefined && d.canedit3 == "1") {
+                        xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogreplay('重新申请报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id=" + d.id + "&tabId=4','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
+                    }
+                    if (d.candelete != undefined && d.candelete == "1") {
+                        xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该报销单吗?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\">删除</a>";
+                    }
+                    if (<%=admin%> && d.status == "5") {
+                        xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogreAdminModify('管理员修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
+                    }
+                    xml += "</div>";
+                    return xml;
+                }}
+        ];
+
+        var paymentStatusView = [
+            {align:'center', title: '付款状态', width:80, templet:function(d){
+                    var st = getPaymentState(d.paymentStatus);
+                    var xml;
+                    if (st.action) {
+                        if (d.paymentStatus === "1") {
+                            xml = "<span title='审批时间:"+ d.paymentDate +"' class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                        }
+                    } else {
+                        xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                    }
+                    return xml;
+                }}
+        ];
+
+// 根据 showFlag 值来决定是否添加付款状态列
+        <shiro:hasPermission name="workreimbursement:workReimbursementAll:paymentStatus">
+        topView.push(...reimbursementTypeView);
+        </shiro:hasPermission>
+        topView.push(...middleView);
+
+        <shiro:hasPermission name="workreimbursement:workReimbursementAll:paymentStatus">
+        topView.push(...paymentStatusView);
+        </shiro:hasPermission>
+        topView.push(...bottomView);
+        tableShowView.push(...topView);
+
         layui.table.render({
             limit:${ page.pageSize }
             ,elem: '#contentTable'
             ,page: false
-            ,cols: [[
-                // {checkbox: true, fixed: true},
-                {field:'submitterId',align:'center',  width:40,title: '序号'}
-                ,{field:'number',align:'center', title: '报销编号', width:150,templet:function(d){
-                        var xml = "<a class=\"attention-info\" href=\"javascript:void(0)\" onclick=\"openDialogListView('查看报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%','95%')\">" +
-                            "<span title=" + d.realnumber + ">" + d.number + "</span></a>";
-                        return xml;
-                    }}
-                ,{field:'reimbursementType',align:'center', title: '报销项', width:100,templet:function(d){
-                        if(1 == d.reimbursementType && d.reimbursementType != undefined){
-                            return "<span title='数电发票报销'>" +"数电发票报销"+ "</span>";
-                        }else{
-                            return "<span title='普通报销'>" +"普通报销"+ "</span>";
-                        }
-                    }}
-                ,{field:'businessTypeName',align:'center', title: '报销类别', width:100,templet:function(d){
-                        return "<span title='"+ d.businessTypeName +"'>" + d.businessTypeName + "</span>";
-                    }}
-                ,{field:'projectId', align:'center',title: '报销项目', minWidth:150,templet:function(d){
-                        if(1 == d.showView && d.showView != undefined){
-                            return "<a class=\"attention-info\" title=\"" + d.projectId + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectView/view?id=" + d.proId +"','95%', '95%')\">" + d.projectId + "</a>";
-                        }else{
-                            return "<span title='"+ d.projectId +"'>" +d.projectId+ "</span>";
-                        }
-                    // return "<span title='"+ d.projectId +"'>" + d.projectId + "</span>";
-                    }}
-                ,{field:'projectNumber',align:'center', title: '报告号', width:100,templet:function(d){
-                        return "<span title='"+ d.projectNumber +"'>" + d.projectNumber + "</span>";
-                    }}
-                ,{field:'handleName',align:'center', title: '经办人', width:100,templet:function(d){
-                        return "<span title='"+ d.handleName +"'>" + d.handleName + "</span>";
-                    }}
-                ,{field:'submitterName',align:'center', title: '报销人', width:100,templet:function(d){
-                        return "<span title='"+ d.submitterName +"'>" + d.submitterName + "</span>";
-                    }}
-                ,{field:'officeId',align:'center', title: '报销部门', width:130,templet:function(d){
-                        return "<span title='"+ d.officeId +"'>" + d.officeId + "</span>";
-                    }}
-                ,/*{field:'projectLeader', align:'center',title: '项目负责人', width:80,templet:function(d){
-                        return "<span title='"+ d.projectLeader +"'>" + d.projectLeader + "</span>";
-                    }}
-                ,*/{field:'submitterDate', align:'center',title: '报销日期',width:80}
-                ,{field:'money',align:'center', title: '报销金额(元)', width:150,templet:function(d){
-                        return "<span title='"+ d.money +"'>" + d.money + "</span>";
-                    }}
-                /*,{field:'taskName', align:'center',title: '审批状态',width:120}*/
-                ,{ title: '状态', align:'center',width:70,templet:function(d){
-                        <%--var st = getAuditState(d.status);--%>
-                        <%--var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/workreimbursement/workReimbursementAll/getProcessOne?id=" + d.id + "','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";--%>
-                        <%--return xml;--%>
-                        var st = getAuditState(d.status);
-                        if(st.action)
-                            var xml = "<span onclick=\"openDialogListView('报销单流程追踪', '${ctx}/workreimbursement/workReimbursementAll/getProcessOne?id=" + d.id + "','"+ d.id +"','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-                        else
-                            var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-                        return xml;
-                    }}
-                ,{align:'center', title: '付款状态',  width:80,templet:function(d){
-                        var st = getPaymentState(d.paymentStatus);
-                        if(st.action){
-                            if (d.paymentStatus==="1"){
-                                var xml = "<span title='付款时间:"+ d.paymentDate +"' class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-                            }
-                        } else{
-                            var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-                        }
-                        return xml;
-                    }}
-                // ,{fixed: 'right',align:'center', toolbar: '#op',title:"操作"}
-                ,{align:'center',title:"操作",width:130,templet:function(d){
-                        ////对操作进行初始化
-                        var xml = "<div class=\"layui-btn-group\">";
-                        if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 1)
-                        {
-                            xml+="<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement&pageFlag=all','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 审批</a>";
-                        }
-                        if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 3)
-                        {
-                            xml+="<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement&pageFlag=all','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 审批</a>";
-                        }
-                        <shiro:hasPermission name="workreimbursement:workReimbursementAll:payment">
-                            if(d.paymentStatus != undefined && d.paymentStatus !=null && "" != d.paymentStatus && d.paymentStatus == 0)
-                            {
-                                xml +="<a href=\"${ctx}/workreimbursement/workReimbursementAll/paymentSave?id=" + d.id + "&paymentStatus=1\" onclick=\"return confirmx('是否确认给报销编号为 " + d.number + " 的报销信息进行付款?', this.href)\"  class=\"layui-btn layui-btn-xs layui-bg-blue\">付款</a>";
-                            }
-                            if(d.paymentStatus != undefined && d.paymentStatus !=null && "" != d.paymentStatus && d.paymentStatus == 1)
-                            {
-                                xml +="<a href=\"${ctx}/workreimbursement/workReimbursementAll/paymentSave?id=" + d.id + "&paymentStatus=0\" onclick=\"return confirmx('是否确认对报销编号为 " + d.number + " 的报销信息进行撤回付款?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\">撤回付款</a>";
-                            }
-                        </shiro:hasPermission>
-
-                        if(d.cancancel != undefined && d.cancancel == "1")
-                            xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/cancelInvalidate?id=" + d.id + "\" onclick=\"return confirmx('确认要强制撤回?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\">撤回</a>";
-                        if(d.canedit1 != undefined && d.canedit1 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogre('修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\">修改</a>";
-                        if(d.canedit2 != undefined && d.canedit2 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\">修改</a>";
-                        if(d.canedit3 != undefined && d.canedit3 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreplay('重新申请报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id=" + d.id + "&tabId=4','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
-                        if(d.candelete != undefined && d.candelete == "1")
-                            xml +="<a href=\"${ctx}/workreimbursement/workReimbursementAll/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该报销单吗?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\">删除</a>";
-                        if(<%=admin%> && d.status == "5"){
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreAdminModify('管理员修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改</a>";
-                        }
-                        xml+="</div>"
-                        return xml;
-                    }}
-            ]]
+            ,cols: [tableShowView]
             ,data: [
                 <c:if test="${ not empty page.list}">
                 <c:forEach items="${page.list}" var="workReimbursement" varStatus="index">
@@ -384,6 +404,9 @@
                     ,"businessTypeName":"${workReimbursement.businessTypeName}"
                     ,"projectNumber":"${workReimbursement.projectName}"
                     ,"paymentStatus":"${workReimbursement.paymentStatus}"
+                    <shiro:hasPermission name="workreimbursement:workReimbursementAll:paymentStatus">
+                    ,"paymentFlag":"1"
+                    </shiro:hasPermission>
                     ,"paymentDate":"<fmt:formatDate value="${workReimbursement.paymentDate}" pattern="yyyy-MM-dd"/>"
                 }
                 </c:forEach>

+ 2 - 2
src/main/webapp/webpage/modules/workreimbursement/workReimbursementFormDetail.jsp

@@ -136,12 +136,12 @@
             <h2>基础信息</h2>
         </div>
 
-        <div class="layui-item layui-col-sm6">
+        <%--<div class="layui-item layui-col-sm6">
             <label class="layui-form-label"><span class="require-item">*</span>报销项:</label>
             <div class="layui-input-block">
                 <input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value = "${workReimbursement.reimbursementTypeStr}"/>
             </div>
-        </div>
+        </div>--%>
 
         <div class="layui-item layui-col-sm6">
             <label class="layui-form-label">报销编号:</label>

+ 135 - 93
src/main/webapp/webpage/modules/workreimbursement/workReimbursementList.jsp

@@ -256,104 +256,139 @@
 </div>
 <script src="${ctxStatic}/layer-v2.3/layui/layui.all.js" charset="utf-8"></script>
 <script>
+    // 定义表格列
+    var tableShowView = [];
+
+    var topView = [
+        {field:'submitterId', align:'center', width:40, title: '序号'},
+        {field:'number', align:'center', title: '报销编号', width:150, templet:function(d){
+                var xml = "<a class=\"attention-info\" href=\"javascript:void(0)\" onclick=\"openDialogListView('查看报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%','95%')\">" +
+                    "<span title=" + d.realnumber + ">" + d.number + "</span></a>";
+                return xml;
+            }},
+
+    ];
+
+    var reimbursementTypeView = [
+        {field:'reimbursementType', align:'center', title: '报销项', width:100, templet:function(d){
+                if (d.reimbursementType == 1 && d.reimbursementType != undefined) {
+                    return "<span title='数电发票报销'>数电发票报销</span>";
+                } else {
+                    return "<span title='普通报销'>普通报销</span>";
+                }
+            }},
+    ]
+
+    var middleView = [
+        {field:'businessTypeName', align:'center', title: '报销类别', width:100, templet:function(d){
+                return "<span title='"+ d.businessTypeName +"'>" + d.businessTypeName + "</span>";
+            }},
+        {field:'projectId', align:'center', title: '报销项目', minWidth:150, templet:function(d){
+                if (d.showView == 1 && d.showView != undefined) {
+                    return "<a class=\"attention-info\" title=\"" + d.projectId + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectView/view?id=" + d.proId +"','95%', '95%')\">" + d.projectId + "</a>";
+                } else {
+                    return "<span title='"+ d.projectId +"'>" + d.projectId + "</span>";
+                }
+            }},
+        {field:'projectNumber', align:'center', title: '报告号', width:100, templet:function(d){
+                return "<span title='"+ d.projectNumber +"'>" + d.projectNumber + "</span>";
+            }},
+        {field:'handleName', align:'center', title: '经办人', width:100, templet:function(d){
+                return "<span title='"+ d.handleName +"'>" + d.handleName + "</span>";
+            }},
+        {field:'submitterName', align:'center', title: '报销人', width:100, templet:function(d){
+                return "<span title='"+ d.submitterName +"'>" + d.submitterName + "</span>";
+            }},
+        {field:'officeId', align:'center', title: '报销部门', width:130, templet:function(d){
+                return "<span title='"+ d.officeId +"'>" + d.officeId + "</span>";
+            }},
+        {field:'submitterDate', align:'center', title: '报销日期', width:80},
+        {field:'money', align:'center', title: '报销金额(元)', width:150, templet:function(d){
+                return "<span title='"+ d.money +"'>" + d.money + "</span>";
+            }},
+        {title: '状态', align:'center', width:70, templet:function(d){
+                var st = getAuditState(d.status);
+                var xml;
+                if (st.action) {
+                    xml = "<span onclick=\"openDialogListView('报销单流程追踪', '${ctx}/workreimbursement/workReimbursementAll/getProcessOne?id=" + d.id + "','"+ d.id +"','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                } else {
+                    xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                }
+                return xml;
+            }}
+    ]
+
+    var bottomView = [
+        {align:'center', title: '操作', width:130, templet:function(d){
+                var xml = "<div class=\"layui-btn-group\">";
+                if (d.notifyFlag != undefined && d.notifyFlag !=null && d.notifyFlag == 1) {
+                    xml += "<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement&pageFlag=all','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >审批</a>";
+                }
+                if (d.notifyFlag != undefined && d.notifyFlag !=null && d.notifyFlag == 3) {
+                    xml += "<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement&pageFlag=all','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >审批</a>";
+                }
+                if (d.paymentStatus != undefined && d.paymentStatus == 0 && d.paymentFlag != undefined && d.paymentFlag == 1) {
+                    xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/paymentSave?id=" + d.id + "&paymentStatus=1\" onclick=\"return confirmx('是否确认给报销编号为 " + d.number + " 的报销信息进行付款?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-blue\">付款</a>";
+                }
+                if (d.paymentStatus != undefined && d.paymentStatus == 1 && d.paymentFlag != undefined && d.paymentFlag == 1) {
+                    xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/paymentSave?id=" + d.id + "&paymentStatus=0\" onclick=\"return confirmx('是否确认对报销编号为 " + d.number + " 的报销信息进行撤回付款?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\">撤回付款</a>";
+                }
+                if (d.cancancel != undefined && d.cancancel == "1") {
+                    xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/cancelInvalidate?id=" + d.id + "\" onclick=\"return confirmx('确认要强制撤回?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\">撤回</a>";
+                }
+                if (d.canedit1 != undefined && d.canedit1 == "1") {
+                    xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogre('修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\">修改</a>";
+                }
+                if (d.canedit2 != undefined && d.canedit2 == "1") {
+                    xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\">修改</a>";
+                }
+                if (d.canedit3 != undefined && d.canedit3 == "1") {
+                    xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogreplay('重新申请报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id=" + d.id + "&tabId=4','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
+                }
+                if (d.candelete != undefined && d.candelete == "1") {
+                    xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该报销单吗?', this.href)\" class=\"layui-btn layui-btn-xs layui-bg-red\">删除</a>";
+                }
+                if (<%=admin%> && d.status == "5") {
+                    xml += "<a href=\"javascript:void(0)\" onclick=\"openDialogreAdminModify('管理员修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
+                }
+                xml += "</div>";
+                return xml;
+            }}
+    ];
+
+    var paymentStatusView = [
+        {align:'center', title: '付款状态', width:80, templet:function(d){
+                var st = getPaymentState(d.paymentStatus);
+                var xml;
+                if (st.action) {
+                    if (d.paymentStatus === "1") {
+                        xml = "<span title='审批时间:"+ d.paymentDate +"' class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                    }
+                } else {
+                    xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
+                }
+                return xml;
+            }}
+    ];
+
+    // 根据 showFlag 值来决定是否添加付款状态列
+    <shiro:hasPermission name="workreimbursement:workReimbursementAll:paymentStatus">
+    topView.push(...reimbursementTypeView);
+    </shiro:hasPermission>
+    topView.push(...middleView);
+
+    <shiro:hasPermission name="workreimbursement:workReimbursementAll:paymentStatus">
+    topView.push(...paymentStatusView);
+    </shiro:hasPermission>
+    topView.push(...bottomView);
+    tableShowView.push(...topView);
+
     layui.use('table', function(){
         layui.table.render({
             limit:${ page.pageSize }
             ,elem: '#contentTable'
             ,page: false
-            ,cols: [[
-                // {checkbox: true, fixed: true},
-                {field:'submitterId',align:'center',  width:40,title: '序号'}
-                ,{field:'number',align:'center', title: '报销编号', width:150,templet:function(d){
-                        var xml = "<a class=\"attention-info\" href=\"javascript:void(0)\" onclick=\"openDialogListView('查看报销单', '${ctx}/workreimbursement/workReimbursement/form?id=" + d.id + "&tabId=1','"+ d.id +"','95%','95%')\">" +
-                            "<span title=" + d.realnumber + ">" + d.number + "</span></a>";
-                        return xml;
-                    }}
-                ,{field:'reimbursementType',align:'center', title: '报销项', width:100,templet:function(d){
-                        if(1 == d.reimbursementType && d.reimbursementType != undefined){
-                            return "<span title='数电发票报销'>" +"数电发票报销"+ "</span>";
-                        }else{
-                            return "<span title='普通报销'>" +"普通报销"+ "</span>";
-                        }
-                    }}
-                ,{field:'businessTypeName',align:'center', title: '报销类别', width:100,templet:function(d){
-                        return "<span title='"+ d.businessTypeName +"'>" + d.businessTypeName + "</span>";
-                    }}
-                ,{field:'projectId', align:'center',title: '报销项目', minWidth:150,templet:function(d){
-                        if(1 == d.showView && d.showView != undefined){
-                            return "<a class=\"attention-info\" title=\"" + d.projectId + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectView/view?id=" + d.proId +"','95%', '95%')\">" + d.projectId + "</a>";
-                        }else{
-                            return "<span title='"+ d.projectId +"'>" +d.projectId+ "</span>";
-                        }
-                    // return "<span title='"+ d.projectId +"'>" + d.projectId + "</span>";
-                    }}
-                ,{field:'projectNumber',align:'center', title: '报告号', width:100,templet:function(d){
-                        return "<span title='"+ d.projectNumber +"'>" + d.projectNumber + "</span>";
-                    }}
-                ,{field:'handleName',align:'center', title: '经办人', width:100,templet:function(d){
-                        return "<span title='"+ d.handleName +"'>" + d.handleName + "</span>";
-                    }}
-                ,{field:'submitterName',align:'center', title: '报销人', width:100,templet:function(d){
-                        return "<span title='"+ d.submitterName +"'>" + d.submitterName + "</span>";
-                    }}
-                ,{field:'officeId',align:'center', title: '报销部门', width:130,templet:function(d){
-                        return "<span title='"+ d.officeId +"'>" + d.officeId + "</span>";
-                    }}
-                ,/*{field:'projectLeader', align:'center',title: '项目负责人', width:80,templet:function(d){
-                        return "<span title='"+ d.projectLeader +"'>" + d.projectLeader + "</span>";
-                    }}
-                ,*/{field:'submitterDate', align:'center',title: '报销日期',width:80}
-                ,{field:'money',align:'center', title: '报销金额(元)', width:150,templet:function(d){
-                        return "<span title='"+ d.money +"'>" + d.money + "</span>";
-                    }}
-                /*,{field:'taskName', align:'center',title: '审批状态',width:120}*/
-                ,{ title: '状态', align:'center',width:70,templet:function(d){
-                        <%--var st = getAuditState(d.status);--%>
-                        <%--var xml = "<span onclick=\"openDialogView('流程追踪', '${ctx}/workreimbursement/workReimbursement/getProcessOne?id=" + d.id + "','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";--%>
-                        <%--return xml;--%>
-                        var st = getAuditState(d.status);
-                        if(st.action)
-                            var xml = "<span onclick=\"openDialogListView('流程追踪', '${ctx}/workreimbursement/workReimbursement/getProcessOne?id=" + d.id + "','"+ d.id +"','95%','95%')\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-                        else
-                            var xml = "<span style=\"cursor:default;\" class=\"status-label status-label-" + st.label + "\" >" + st.status + "</span>";
-                        return xml;
-                    }}
-                // ,{fixed: 'right',align:'center', toolbar: '#op',title:"操作"}
-                ,{align:'center',title:"操作",width:130,templet:function(d){
-                        ////对操作进行初始化
-                        var xml = "<div class=\"layui-btn-group\">";
-                        if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 1)
-                        {
-                            xml+="<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 审批</a>";
-                        }
-                        if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 3)
-                        {
-                            xml+="<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 审批</a>";
-                        }
-                        if(d.cancancel != undefined && d.cancancel == "1")
-                            xml += "<a href=\"${ctx}/workreimbursement/workReimbursement/cancelInvalidate?id=" + d.id + "\" onclick=\"return confirmx('确认要强制撤回?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\"> 撤回</a>";
-                        if(d.canedit1 != undefined && d.canedit1 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogre('修改报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改</a>";
-                        if(<%=admin%> && (d.status == "5" || d.status == "2")){
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreAdminModify('管理员修改报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改</a>";
-                        }
-                        if(d.canedit2 != undefined && d.canedit2 == "1")
-                            //判断是什么流程(新旧流程)
-                            if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 2){
-                                xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workreimbursement/workReimbursement/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
-                            }else if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 4){
-                                xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
-                            }
-
-                        if(d.canedit3 != undefined && d.canedit3 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreplay('重新申请报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id=" + d.id + "&tabId=4','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改</a>";
-                        if(d.candelete != undefined && d.candelete == "1")
-                            xml +="<a href=\"${ctx}/workreimbursement/workReimbursement/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该报销单吗?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\"> 删除</a>";
-
-                            xml+="</div>"
-                        return xml;
-                    }}
-            ]]
+            ,cols: [tableShowView]
             ,data: [
                 <c:if test="${ not empty page.list}">
                 <c:forEach items="${page.list}" var="workReimbursement" varStatus="index">
@@ -414,6 +449,13 @@
                     ,"businessTypeName":"${workReimbursement.businessTypeName}"
                     ,"projectNumber":"${workReimbursement.projectName}"
 
+                    ,"paymentStatus":"${workReimbursement.paymentStatus}"
+                    <shiro:hasPermission name="workreimbursement:workReimbursementAll:paymentStatus">
+                    ,"paymentFlag":"1"
+                    </shiro:hasPermission>
+                    ,"paymentDate":"<fmt:formatDate value="${workReimbursement.paymentDate}" pattern="yyyy-MM-dd"/>"
+
+
                 }
                 </c:forEach>
                 </c:if>

+ 2 - 2
src/main/webapp/webpage/modules/workstaff/workStaffBasicInfoList.jsp

@@ -194,7 +194,7 @@
                         <label class="layui-form-label">部门:</label>
                         <div class="layui-input-block with-icon">
                             <sys:treeselect id="office" name="office.id" value="${workStaffBasicInfo.office.id}" labelName="office.name" labelValue="${workStaffBasicInfo.office.name}"
-                                            title="部门" url="/sys/office/treeData?type=2" cssClass="form-control layui-input required" notAllowSelectParent="false" allowInput="true"/>
+                                            title="部门" url="/sys/office/treeDataAll?type=6" cssClass="form-control layui-input required" notAllowSelectParent="false" allowInput="true"/>
                         </div>
                     </div>
                     <%--<div class="layui-item query athird">
@@ -347,7 +347,7 @@
 
                         if(d.freeze != undefined && d.freeze == "1"){
                             if(d.userLoginFlag == 1){
-                                xml +="<a href=\"${ctx}/workstaff/workStaffBasicInfo/freeze?userId=" + d.userId + "\" onclick=\"return confirmx('确认要注销该人员信息吗?', this.href)\"   class=\"layui-btn layui-btn-xs layui-btn-warm\"> 注销</a>";
+                                xml +="<a href=\"${ctx}/workstaff/workStaffBasicInfo/freeze?userId=" + d.userId + "\" onclick=\"return confirmx('确认要禁用该人员信息吗?', this.href)\"   class=\"layui-btn layui-btn-xs layui-btn-warm\"> 禁用</a>";
                             }else{
                                 xml +="<a href=\"${ctx}/workstaff/workStaffBasicInfo/freeze?userId=" + d.userId + "\" onclick=\"return confirmx('确认要激活该人员信息吗?', this.href)\"   class=\"layui-btn layui-btn-xs layui-btn-normal\"> 激活</a>";
                             }