bihuisong 1 hónapja
szülő
commit
46d8e78c7e
58 módosított fájl, 9021 hozzáadás és 0 törlés
  1. 185 0
      src/main/java/com/ruoyi/system/controller/CenterdataTCommunicationController.java
  2. 143 0
      src/main/java/com/ruoyi/system/controller/CenterdataTDailyController.java
  3. 224 0
      src/main/java/com/ruoyi/system/controller/CenterdataTLeaveController.java
  4. 170 0
      src/main/java/com/ruoyi/system/controller/CenterdataTRegulationsController.java
  5. 215 0
      src/main/java/com/ruoyi/system/controller/CenterdataTReserveController.java
  6. 72 0
      src/main/java/com/ruoyi/system/domain/CenterdataTAttach.java
  7. 143 0
      src/main/java/com/ruoyi/system/domain/CenterdataTCommunication.java
  8. 101 0
      src/main/java/com/ruoyi/system/domain/CenterdataTDaily.java
  9. 147 0
      src/main/java/com/ruoyi/system/domain/CenterdataTLeave.java
  10. 133 0
      src/main/java/com/ruoyi/system/domain/CenterdataTLeaveCount.java
  11. 144 0
      src/main/java/com/ruoyi/system/domain/CenterdataTRegulations.java
  12. 121 0
      src/main/java/com/ruoyi/system/domain/CenterdataTReserve.java
  13. 23 0
      src/main/java/com/ruoyi/system/domain/bo/ReserveAppBO.java
  14. 17 0
      src/main/java/com/ruoyi/system/mapper/BaseMapper.java
  15. 82 0
      src/main/java/com/ruoyi/system/mapper/CenterdataTAttachMapper.java
  16. 60 0
      src/main/java/com/ruoyi/system/mapper/CenterdataTCommunicationMapper.java
  17. 55 0
      src/main/java/com/ruoyi/system/mapper/CenterdataTDailyMapper.java
  18. 61 0
      src/main/java/com/ruoyi/system/mapper/CenterdataTLeaveMapper.java
  19. 59 0
      src/main/java/com/ruoyi/system/mapper/CenterdataTRegulationsMapper.java
  20. 62 0
      src/main/java/com/ruoyi/system/mapper/CenterdataTReserveMapper.java
  21. 18 0
      src/main/java/com/ruoyi/system/service/IBaseService.java
  22. 73 0
      src/main/java/com/ruoyi/system/service/ICenterdataTAttachService.java
  23. 60 0
      src/main/java/com/ruoyi/system/service/ICenterdataTCommunicationService.java
  24. 55 0
      src/main/java/com/ruoyi/system/service/ICenterdataTDailyService.java
  25. 60 0
      src/main/java/com/ruoyi/system/service/ICenterdataTLeaveService.java
  26. 57 0
      src/main/java/com/ruoyi/system/service/ICenterdataTRegulationsService.java
  27. 67 0
      src/main/java/com/ruoyi/system/service/ICenterdataTReserveService.java
  28. 99 0
      src/main/java/com/ruoyi/system/service/impl/BaseServiceImpl.java
  29. 174 0
      src/main/java/com/ruoyi/system/service/impl/CenterdataTAttachServiceImpl.java
  30. 103 0
      src/main/java/com/ruoyi/system/service/impl/CenterdataTCommunicationServiceImpl.java
  31. 89 0
      src/main/java/com/ruoyi/system/service/impl/CenterdataTDailyServiceImpl.java
  32. 108 0
      src/main/java/com/ruoyi/system/service/impl/CenterdataTLeaveServiceImpl.java
  33. 156 0
      src/main/java/com/ruoyi/system/service/impl/CenterdataTRegulationsServiceImpl.java
  34. 198 0
      src/main/java/com/ruoyi/system/service/impl/CenterdataTReserveServiceImpl.java
  35. 32 0
      src/main/java/com/ruoyi/system/utils/DataConstants.java
  36. 94 0
      src/main/java/com/ruoyi/system/utils/FileUtil.java
  37. 193 0
      src/main/resources/mapper/data/CenterdataTAttachMapper.xml
  38. 189 0
      src/main/resources/mapper/data/CenterdataTCommunicationMapper.xml
  39. 122 0
      src/main/resources/mapper/data/CenterdataTDailyMapper.xml
  40. 186 0
      src/main/resources/mapper/data/CenterdataTLeaveMapper.xml
  41. 173 0
      src/main/resources/mapper/data/CenterdataTRegulationsMapper.xml
  42. 181 0
      src/main/resources/mapper/data/CenterdataTReserveMapper.xml
  43. 55 0
      system_ui/src/api/data/communication/communication.js
  44. 44 0
      system_ui/src/api/data/daily/daily.js
  45. 64 0
      system_ui/src/api/data/leave/leave.js
  46. 60 0
      system_ui/src/api/data/leave/linleader.js
  47. 55 0
      system_ui/src/api/data/regulations/regulations.js
  48. 55 0
      system_ui/src/api/data/reserve/reserve.js
  49. 248 0
      system_ui/src/api/rules/rules.js
  50. 263 0
      system_ui/src/views/components/FileUpload/index.vue
  51. 100 0
      system_ui/src/views/components/deptselector.vue
  52. 431 0
      system_ui/src/views/data/communication/index.vue
  53. 326 0
      system_ui/src/views/data/daily/index.vue
  54. 360 0
      system_ui/src/views/data/daily/index2.vue
  55. 655 0
      system_ui/src/views/data/leave/index.vue
  56. 569 0
      system_ui/src/views/data/leave/index2.vue
  57. 531 0
      system_ui/src/views/data/regulations/index.vue
  58. 501 0
      system_ui/src/views/data/reserve/index.vue

+ 185 - 0
src/main/java/com/ruoyi/system/controller/CenterdataTCommunicationController.java

@@ -0,0 +1,185 @@
+package com.ruoyi.system.controller;
+
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.ruoyi.common.security.annotation.RequiresPermissions;
+import com.ruoyi.system.domain.CenterdataTCommunication;
+import com.ruoyi.system.service.ICenterdataTCommunicationService;
+import com.ruoyi.system.utils.ExcelUtil;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+import springfox.documentation.annotations.ApiIgnore;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 通讯录Controller
+ *
+ * @author ruoyi
+ * @date 2022-06-20
+ */
+@Api(tags = "数据中心通讯录控制器")
+@RestController
+@RequestMapping("/communication")
+public class CenterdataTCommunicationController extends BaseController {
+
+    @Autowired
+    private ICenterdataTCommunicationService centerdataTCommunicationService;
+
+    /**
+     * web列表
+     * 查询通讯录列表
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "name", value = "姓名", dataType = "String", required = false),
+            @ApiImplicitParam(name = "sex", value = "性别", dataType = "String", required = false),
+            @ApiImplicitParam(name = "phone", value = "电话", dataType = "String", required = false),
+            @ApiImplicitParam(name = "mobile", value = "手机", dataType = "String", required = false),
+            @ApiImplicitParam(name = "address", value = "地址", dataType = "String", required = false),
+            @ApiImplicitParam(name = "firstLetter", value = "拼音首字母", dataType = "String", required = false),
+            @ApiImplicitParam(name = "pinyin", value = "拼音全拼", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "数据中心通讯录查询列表", notes = "数据中心通讯录查询列表")
+    @RequiresPermissions("communication:communication:list")
+    @GetMapping("/list")
+    public TableDataInfo list(CenterdataTCommunication centerdataTCommunication) {
+        startPage();
+        List<CenterdataTCommunication> list = centerdataTCommunicationService.selectCenterdataTCommunicationList(centerdataTCommunication);
+        return getDataTable(list);
+    }
+
+    /**
+     * 移动端调用
+     * 查询通讯录列表
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "name", value = "姓名", dataType = "String", required = false),
+            @ApiImplicitParam(name = "sex", value = "性别", dataType = "String", required = false),
+            @ApiImplicitParam(name = "phone", value = "电话", dataType = "String", required = false),
+            @ApiImplicitParam(name = "mobile", value = "手机", dataType = "String", required = false),
+            @ApiImplicitParam(name = "address", value = "地址", dataType = "String", required = false),
+            @ApiImplicitParam(name = "firstLetter", value = "拼音首字母", dataType = "String", required = false),
+            @ApiImplicitParam(name = "pinyin", value = "拼音全拼", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "数据中心通讯录手机端查询列表", notes = "数据中心通讯录手机端查询列表")
+    @GetMapping("/getCommunicationByDeptId")
+    public AjaxResult getCommunicationByDeptId(CenterdataTCommunication centerdataTCommunication) {
+        startPage();
+        List<Map<String, Object>> communicationByDeptId = centerdataTCommunicationService.getCommunicationByDeptId(centerdataTCommunication);
+        return AjaxResult.success(getDataTable(communicationByDeptId));
+    }
+
+    /**
+     * 导出通讯录列表
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "name", value = "姓名", dataType = "String", required = false),
+            @ApiImplicitParam(name = "sex", value = "性别", dataType = "String", required = false),
+            @ApiImplicitParam(name = "phone", value = "电话", dataType = "String", required = false),
+            @ApiImplicitParam(name = "mobile", value = "手机", dataType = "String", required = false),
+            @ApiImplicitParam(name = "address", value = "地址", dataType = "String", required = false),
+            @ApiImplicitParam(name = "firstLetter", value = "拼音首字母", dataType = "String", required = false),
+            @ApiImplicitParam(name = "pinyin", value = "拼音全拼", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "数据中心通讯录导出", notes = "数据中心通讯录导出")
+    @RequiresPermissions("communication:communication:export")
+    @Log(title = "通讯录", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, CenterdataTCommunication centerdataTCommunication) {
+        List<CenterdataTCommunication> list = centerdataTCommunicationService.selectCenterdataTCommunicationList(centerdataTCommunication);
+        ExcelUtil<CenterdataTCommunication> util = new ExcelUtil<>(CenterdataTCommunication.class);
+        util.exportExcel(response, list, "通讯录数据");
+    }
+
+    /**
+     * 获取通讯录详细信息
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true)
+    })
+    @ApiOperation(value = "数据中心通讯录获取详情", notes = "数据中心通讯录获取详情")
+    @RequiresPermissions("communication:communication:query")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") String id) {
+        return AjaxResult.success(centerdataTCommunicationService.selectCenterdataTCommunicationById(id));
+    }
+
+    /**
+     * 新增通讯录
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "name", value = "姓名", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "sex", value = "性别", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "phone", value = "电话", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "mobile", value = "手机", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "address", value = "地址", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "firstLetter", value = "拼音首字母", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "pinyin", value = "拼音全拼", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = true, paramType = "body")
+    })
+    @ApiOperation(value = "数据中心通讯录新增", notes = "数据中心通讯录新增")
+    @RequiresPermissions("communication:communication:add")
+    @Log(title = "通讯录", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@ApiIgnore @Validated @RequestBody CenterdataTCommunication centerdataTCommunication) {
+        return toAjax(centerdataTCommunicationService.insertCenterdataTCommunication(centerdataTCommunication));
+    }
+
+    /**
+     * 修改通讯录
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "name", value = "姓名", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "sex", value = "性别", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "phone", value = "电话", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "mobile", value = "手机", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "address", value = "地址", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "firstLetter", value = "拼音首字母", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "pinyin", value = "拼音全拼", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = true, paramType = "body")
+    })
+    @ApiOperation(value = "数据中心通讯录修改", notes = "数据中心通讯录修改")
+    @RequiresPermissions("communication:communication:edit")
+    @Log(title = "通讯录", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@ApiIgnore @Validated @RequestBody CenterdataTCommunication centerdataTCommunication) {
+        return toAjax(centerdataTCommunicationService.updateCenterdataTCommunication(centerdataTCommunication));
+    }
+
+    /**
+     * 删除通讯录
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "ids", value = "主键id", dataType = "String", required = true)
+    })
+    @ApiOperation(value = "数据中心通讯录删除", notes = "数据中心通讯录删除")
+    @RequiresPermissions("communication:communication:remove")
+    @Log(title = "通讯录", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable String[] ids) {
+        return toAjax(centerdataTCommunicationService.deleteCenterdataTCommunicationByIds(ids));
+    }
+
+    @ApiOperation(value = "发布/撤销通讯录", notes = "发布/撤销通讯录")
+    @PostMapping("/handlePublish")
+    public AjaxResult handlePublish(@RequestBody CenterdataTCommunication centerdataTCommunication){
+        return toAjax(centerdataTCommunicationService.handlePublish(centerdataTCommunication));
+    }
+}

+ 143 - 0
src/main/java/com/ruoyi/system/controller/CenterdataTDailyController.java

@@ -0,0 +1,143 @@
+package com.ruoyi.system.controller;
+
+import com.ruoyi.common.core.utils.poi.ExcelUtil;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.ruoyi.common.security.annotation.RequiresPermissions;
+import com.ruoyi.system.domain.CenterdataTDaily;
+import com.ruoyi.system.service.ICenterdataTDailyService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import springfox.documentation.annotations.ApiIgnore;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 日报Controller
+ *
+ * @author ruoyi
+ * @date 2022-05-01
+ */
+@Api(tags = "数据中心工作日志控制器")
+@RestController
+@RequestMapping("/daily")
+public class CenterdataTDailyController extends BaseController {
+
+    @Autowired
+    private ICenterdataTDailyService centerdataTDailyService;
+
+    /**
+     * 查询日报列表
+     * 数据中心工作日志查询列表调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "dailyType", value = "日报类型", dataType = "String", required = false),
+            @ApiImplicitParam(name = "dailyTime", value = "日报时间", dataType = "Date", required = false),
+            @ApiImplicitParam(name = "dailyTitle", value = "日报标题", dataType = "String", required = false),
+            @ApiImplicitParam(name = "dailyContent", value = "日报内容", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "数据中心工作日志查询列表", notes = "数据中心工作日志查询列表")
+    @RequiresPermissions("system:daily:list")
+    @GetMapping("/list")
+    public TableDataInfo list(CenterdataTDaily centerdataTDaily) {
+        startPage();
+        List<CenterdataTDaily> list = centerdataTDailyService.selectCenterdataTDailyList(centerdataTDaily);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出日报列表
+     * 数据中心工作日日报导出调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "dailyType", value = "日报类型", dataType = "String", required = false),
+            @ApiImplicitParam(name = "dailyTime", value = "日报时间", dataType = "Date", required = false),
+            @ApiImplicitParam(name = "dailyTitle", value = "日报标题", dataType = "String", required = false),
+            @ApiImplicitParam(name = "dailyContent", value = "日报内容", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "数据中心工作日志导出", notes = "数据中心工作日志导出")
+    @RequiresPermissions("system:daily:export")
+    @Log(title = "日报", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, CenterdataTDaily centerdataTDaily) {
+        List<CenterdataTDaily> list = centerdataTDailyService.selectCenterdataTDailyList(centerdataTDaily);
+        ExcelUtil<CenterdataTDaily> util = new ExcelUtil<>(CenterdataTDaily.class);
+        util.exportExcel(response, list, "日报数据");
+    }
+
+    /**
+     * 获取日报详细信息
+     * 数据中心日报详情调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true)
+    })
+    @ApiOperation(value = "数据中心工作日志查看详情", notes = "数据中心工作日志查看详情")
+    @RequiresPermissions("system:daily:query")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") String id) {
+        return AjaxResult.success(centerdataTDailyService.selectCenterdataTDailyById(id));
+    }
+
+    /**
+     * 新增日报
+     * 数据中心前端 无录入地方
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "dailyType", value = "日报类型", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "dailyTime", value = "日报时间", dataType = "Date", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "dailyTitle", value = "日报标题", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "dailyContent", value = "日报内容", dataType = "String", required = true, paramType = "body")
+    })
+    @ApiOperation(value = "数据中心工作日志新增", notes = "数据中心工作日志新增")
+    @RequiresPermissions("system:daily:add")
+    @Log(title = "日报", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@ApiIgnore @RequestBody CenterdataTDaily centerdataTDaily) {
+        return toAjax(centerdataTDailyService.insertCenterdataTDaily(centerdataTDaily));
+    }
+
+    /**
+     * 修改日报
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "dailyType", value = "日报类型", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "dailyTime", value = "日报时间", dataType = "Date", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "dailyTitle", value = "日报标题", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "dailyContent", value = "日报内容", dataType = "String", required = true, paramType = "body")
+    })
+    @ApiOperation(value = "数据中心工作日志修改", notes = "数据中心工作日志修改")
+    @RequiresPermissions("system:daily:edit")
+    @Log(title = "日报", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@ApiIgnore @RequestBody CenterdataTDaily centerdataTDaily) {
+        return toAjax(centerdataTDailyService.updateCenterdataTDaily(centerdataTDaily));
+    }
+
+    /**
+     * 删除日报
+     * 数据中心 工作日志删除调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "ids", value = "主键id", dataType = "String[]", required = true)
+    })
+    @ApiOperation(value = "数据中心工作日志删除", notes = "数据中心工作日志删除")
+    @RequiresPermissions("system:daily:remove")
+    @Log(title = "日报", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable String[] ids) {
+        return toAjax(centerdataTDailyService.deleteCenterdataTDailyByIds(ids));
+    }
+}

+ 224 - 0
src/main/java/com/ruoyi/system/controller/CenterdataTLeaveController.java

@@ -0,0 +1,224 @@
+package com.ruoyi.system.controller;
+
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.ruoyi.common.security.annotation.RequiresPermissions;
+import com.ruoyi.system.domain.CenterdataTLeave;
+import com.ruoyi.system.domain.CenterdataTLeaveCount;
+import com.ruoyi.system.service.ICenterdataTLeaveService;
+import com.ruoyi.system.utils.ExcelUtil;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+import springfox.documentation.annotations.ApiIgnore;
+
+import javax.servlet.http.HttpServletResponse;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+import java.util.List;
+
+
+/**
+ * 请假Controller
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+@Api(tags = "数据中心请假管理控制器")
+@RestController
+@RequestMapping("/leave")
+
+public class CenterdataTLeaveController extends BaseController {
+
+    @Autowired
+    private ICenterdataTLeaveService centerdataTLeaveService;
+
+
+    /**
+     * 查询请假列表
+     */
+    @ApiOperation(value = "数据中心请假管理列表查询", notes = "数据中心请假管理列表查询")
+    @RequiresPermissions("system:leave:list")
+    @GetMapping("/list")
+    public TableDataInfo list(CenterdataTLeave centerdataTLeave) {
+        startPage();
+        List<CenterdataTLeave> list = centerdataTLeaveService.selectCenterdataTLeaveList(centerdataTLeave);
+        return getDataTable(list);
+    }
+
+    /**
+     * 查询请假列表app
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "leaveStartTime", value = "请假开始时间", dataType = "Date", required = false),
+            @ApiImplicitParam(name = "leaveEndTime", value = "请假j结束时间", dataType = "Date", required = false),
+            @ApiImplicitParam(name = "forestLeaveStatus", value = "状态", dataType = "String", required = false),
+            @ApiImplicitParam(name = "leaveMatter", value = "请假人事由", dataType = "String", required = false),
+            @ApiImplicitParam(name = "leaveUserId", value = "请假人id", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "leaveUserName", value = "请假人姓名", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "手机端远端调用", notes = "手机端远端调用")
+    @GetMapping("/listApp")
+    public TableDataInfo listApp(CenterdataTLeave centerdataTLeave) {
+        startPage();
+        return getDataTable(centerdataTLeaveService.selectCenterdataTLeaveList(centerdataTLeave));
+    }
+
+    /**
+     * 导出请假列表
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "leaveStartTime", value = "请假开始时间", dataType = "Date", required = false),
+            @ApiImplicitParam(name = "leaveEndTime", value = "请假j结束时间", dataType = "Date", required = false),
+            @ApiImplicitParam(name = "forestLeaveStatus", value = "状态", dataType = "String", required = false),
+            @ApiImplicitParam(name = "leaveMatter", value = "请假人事由", dataType = "String", required = false),
+            @ApiImplicitParam(name = "leaveUserId", value = "请假人id", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "leaveUserName", value = "请假人姓名", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "数据中心请假管理导出", notes = "数据中心请假管理导出")
+    @RequiresPermissions("system:leave:export")
+    @Log(title = "请假", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, CenterdataTLeave centerdataTLeave) {
+        List<CenterdataTLeave> list = centerdataTLeaveService.selectCenterdataTLeaveList(centerdataTLeave);
+        ExcelUtil<CenterdataTLeave> util = new ExcelUtil<>(CenterdataTLeave.class);
+        switch (centerdataTLeave.getType()){
+            case "1":
+                util.exportExcel(response, list, "请假申请");
+                break;
+            case "2":
+                util.exportExcel(response, list, "请假消息综合查询");
+                break;
+            case "3":
+                Date leaveStartTime = centerdataTLeave.getLeaveStartTime();
+                if(null != leaveStartTime){
+                    String time = new SimpleDateFormat("yyyy-MM").format(leaveStartTime);
+                    centerdataTLeave.setTime(time);
+                }
+                List<CenterdataTLeaveCount> leaveCounts = centerdataTLeaveService.listLeaveCount(centerdataTLeave);
+                ExcelUtil<CenterdataTLeaveCount> utilCount = new ExcelUtil<>(CenterdataTLeaveCount.class);
+                utilCount.exportExcel(response, leaveCounts, "请假统计");
+                break;
+            default:
+                break;
+        }
+    }
+
+    /**
+     * 获取请假详细信息
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "数据中心请假管理详情", notes = "数据中心请假管理详情")
+    @RequiresPermissions("system:leave:query")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") String id) {
+        return AjaxResult.success(centerdataTLeaveService.selectCenterdataTLeaveById(id));
+    }
+
+    /**
+     * 获取请假详细信息
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "手机端远端调用", notes = "手机端远端调用")
+    @GetMapping(value = "/getInfoApp")
+    public AjaxResult getInfoApp(String id) {
+        return AjaxResult.success(centerdataTLeaveService.selectCenterdataTLeaveById(id));
+    }
+
+    /**
+     * 新增请假
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "leaveStartTime", value = "请假开始时间", dataType = "Date", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "leaveEndTime", value = "请假j结束时间", dataType = "Date", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "forestLeaveStatus", value = "状态", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "leaveMatter", value = "请假人事由", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "leaveUserId", value = "请假人id", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "deptId", value = "所属部门", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "leaveUserName", value = "请假人姓名", dataType = "String", required = true, paramType = "body")
+    })
+    @ApiOperation(value = "数据中心请假管理新增", notes = "数据中心请假管理新增")
+    @RequiresPermissions("system:leave:add")
+    @Log(title = "请假", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@ApiIgnore @Validated @RequestBody CenterdataTLeave centerdataTLeave) {
+        return toAjax(centerdataTLeaveService.insertCenterdataTLeave(centerdataTLeave));
+    }
+
+    /**
+     * 修改请假
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "leaveStartTime", value = "请假开始时间", dataType = "Date", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "leaveEndTime", value = "请假结束时间", dataType = "Date", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "forestLeaveStatus", value = "状态", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "leaveMatter", value = "请假人事由", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "leaveUserId", value = "请假人id", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "deptId", value = "所属部门", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "leaveUserName", value = "请假人姓名", dataType = "String", required = true, paramType = "body")
+    })
+    @ApiOperation(value = "数据中心请假管理修改", notes = "数据中心请假管理修改")
+    @RequiresPermissions("system:leave:edit")
+    @Log(title = "请假", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@ApiIgnore @Validated @RequestBody CenterdataTLeave centerdataTLeave) {
+        return toAjax(centerdataTLeaveService.updateCenterdataTLeave(centerdataTLeave));
+    }
+
+    /**
+     * 删除请假
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "ids", value = "主键id", dataType = "String", required = true)
+    })
+    @ApiOperation(value = "数据中心请假管理删除", notes = "数据中心请假管理删除")
+    @RequiresPermissions("system:leave:remove")
+    @Log(title = "请假", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable String[] ids) {
+        return toAjax(centerdataTLeaveService.deleteCenterdataTLeaveByIds(ids));
+    }
+
+    /**
+     * 更改审批状态
+     */
+    @ApiOperation(value = "数据中心请假管理更改审批状态", notes = "数据中心请假管理更改审批状态")
+    @PutMapping("/change")
+    public AjaxResult changeStatus(@RequestBody CenterdataTLeave centerdataTLeave) {
+        return toAjax(centerdataTLeaveService.changeStatus(centerdataTLeave));
+    }
+
+
+
+    /**
+     * 请假统计
+     */
+    @ApiOperation(value = "数据中心请假管理请假统计", notes = "数据中心请假管理请假统计")
+    @RequiresPermissions("system:leave:list")
+    @GetMapping("/leaveList")
+    public TableDataInfo leaveList(CenterdataTLeave centerdataTLeave) {
+        startPage();
+        Date leaveStartTime = centerdataTLeave.getLeaveStartTime();
+        if(null != leaveStartTime){
+            String time = new SimpleDateFormat("yyyy-MM").format(leaveStartTime);
+            centerdataTLeave.setTime(time);
+        }
+        List<CenterdataTLeaveCount> list = centerdataTLeaveService.listLeaveCount(centerdataTLeave);
+        return getDataTable(list);
+    }
+}

+ 170 - 0
src/main/java/com/ruoyi/system/controller/CenterdataTRegulationsController.java

@@ -0,0 +1,170 @@
+package com.ruoyi.system.controller;
+
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.ruoyi.common.security.annotation.RequiresPermissions;
+import com.ruoyi.system.domain.CenterdataTRegulations;
+import com.ruoyi.system.service.ICenterdataTRegulationsService;
+import com.ruoyi.system.utils.ExcelUtil;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+import springfox.documentation.annotations.ApiIgnore;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 政策法规Controller
+ *
+ * @author ruoyi
+ * @date 2022-05-05
+ */
+@RestController
+@RequestMapping("/regulations")
+@Api(tags = "数据中心政策法规控制器")
+public class CenterdataTRegulationsController extends BaseController {
+
+    /**
+     * 手机端远端调用
+     */
+    @Autowired
+    private ICenterdataTRegulationsService centerdataTRegulationsService;
+
+    /**
+     * 查询政策法规列表
+     * 數據中心政策法規列表調用
+     */
+    @RequiresPermissions("system:regulations:list")
+    @GetMapping("/list")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regName", value = "名称", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regIntroduction", value = "法规简介", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regOffice", value = "发文机关", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "regNumber", value = "发文号", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regTime", value = "发文时间", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "查询政策法规列表", notes = "查询政策法规列表")
+    public TableDataInfo list(CenterdataTRegulations centerdataTRegulations) {
+        startPage();
+        List<CenterdataTRegulations> list = centerdataTRegulationsService.selectCenterdataTRegulationsList(centerdataTRegulations);
+        return getDataTable(list);
+    }
+
+    @ApiOperation(value = "手机端远端调用", notes = "手机端远端调用")
+    @GetMapping(value = "/select")
+    public TableDataInfo select() {
+        startPage();
+        CenterdataTRegulations centerdataTRegulations = new CenterdataTRegulations();
+        centerdataTRegulations.setReleaseStatus("centerdata_release_status_yes");
+        List<CenterdataTRegulations> list = centerdataTRegulationsService.selectCenterdataTRegulationsList(centerdataTRegulations);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出政策法规列表
+     * 數據中心政策法规导出调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regName", value = "名称", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regIntroduction", value = "法规简介", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regOffice", value = "发文机关", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "regNumber", value = "发文号", dataType = "String", required = false),
+            @ApiImplicitParam(name = "regTime", value = "发文时间", dataType = "String", required = false)
+    })
+    @RequiresPermissions("system:regulations:export")
+    @ApiOperation(value = "政策法规导出", notes = "政策法规导出")
+    @Log(title = "政策法规", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, CenterdataTRegulations centerdataTRegulations) {
+        List<CenterdataTRegulations> list = centerdataTRegulationsService.selectCenterdataTRegulationsList(centerdataTRegulations);
+        ExcelUtil<CenterdataTRegulations> util = new ExcelUtil<>(CenterdataTRegulations.class);
+        util.exportExcel(response, list, "政策法规数据");
+    }
+
+    /**
+     * 获取政策法规详细信息
+     * <p>
+     * 數據中心政策法规回去详情调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true)
+    })
+    @RequiresPermissions("system:regulations:query")
+    @ApiOperation(value = "获取政策法规详细信息", notes = "获取政策法规详细信息")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") String id) {
+        return AjaxResult.success(centerdataTRegulationsService.selectCenterdataTRegulationsById(id));
+    }
+
+    /**
+     * 新增政策法规
+     * 數據中心政策法规新增调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "regName", value = "名称", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "regIntroduction", value = "法规简介", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "regOffice", value = "发文机关", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "regNumber", value = "发文号", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "regTime", value = "发文时间", dataType = "String", required = true, paramType = "body")
+    })
+    @RequiresPermissions("system:regulations:add")
+    @ApiOperation(value = "新增政策法规", notes = "新增政策法规")
+    @Log(title = "政策法规", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@ApiIgnore @Validated @RequestBody CenterdataTRegulations centerdataTRegulations) {
+        centerdataTRegulations.setReleaseStatus("centerdata_release_status_no");
+        return toAjax(centerdataTRegulationsService.insertCenterdataTRegulations(centerdataTRegulations));
+    }
+
+    /**
+     * 修改政策法规
+     * 數據中心政策法规修改调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "regName", value = "名称", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "regIntroduction", value = "法规简介", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "regOffice", value = "发文机关", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "regNumber", value = "发文号", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "regTime", value = "发文时间", dataType = "String", required = true, paramType = "body")
+    })
+    @ApiOperation(value = "修改政策法规", notes = "修改政策法规")
+    @RequiresPermissions("system:regulations:edit")
+    @Log(title = "政策法规", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@ApiIgnore @Validated @RequestBody CenterdataTRegulations centerdataTRegulations) {
+        return toAjax(centerdataTRegulationsService.updateCenterdataTRegulations(centerdataTRegulations));
+    }
+
+    /**
+     * 删除政策法规
+     * 數據中心政策法规删除调用
+     */
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "ids", value = "主键id", dataType = "String[]", required = true)
+    })
+    @ApiOperation(value = "删除政策法规", notes = "删除政策法规")
+    @RequiresPermissions("system:regulations:remove")
+    @Log(title = "政策法规", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable String[] ids) {
+        return toAjax(centerdataTRegulationsService.deleteCenterdataTRegulationsByIds(ids));
+    }
+
+    @ApiOperation(value = "发布/撤销政策法规", notes = "发布/撤销政策法规")
+    @PostMapping("/handlePublish")
+    public AjaxResult handlePublish(@RequestBody CenterdataTRegulations centerdataTRegulations){
+        return toAjax(centerdataTRegulationsService.handlePublish(centerdataTRegulations));
+    }
+}

+ 215 - 0
src/main/java/com/ruoyi/system/controller/CenterdataTReserveController.java

@@ -0,0 +1,215 @@
+package com.ruoyi.system.controller;
+
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.ruoyi.common.security.annotation.RequiresPermissions;
+import com.ruoyi.system.domain.CenterdataTReserve;
+import com.ruoyi.system.service.ICenterdataTReserveService;
+import com.ruoyi.system.utils.ExcelUtil;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+import springfox.documentation.annotations.ApiIgnore;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+/**
+ * 应急预案Controller
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+@RestController
+@RequestMapping("/reserve")
+@Api(tags = "数据中心应急预案控制器")
+public class CenterdataTReserveController extends BaseController {
+
+    @Autowired
+    private ICenterdataTReserveService centerdataTReserveService;
+
+    /**
+     * 查询应急预案列表
+     * 数据中心应急预案调用
+     */
+    @RequiresPermissions("system:reserve:list")
+    @GetMapping("/list")
+    @ApiOperation(value = "查询应急预案列表", notes = "查询应急预案列表")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resTitle", value = "标题", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resIntroduction", value = "简介", dataType = "String", required = false),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = false),
+            @ApiImplicitParam(name = "attachId", value = "附件id", dataType = "String", required = false)
+    })
+    public TableDataInfo list(CenterdataTReserve centerdataTReserve) {
+        startPage();
+        List<CenterdataTReserve> list = centerdataTReserveService.selectCenterdataTReserveList(centerdataTReserve);
+        return getDataTable(list);
+    }
+
+
+
+    /**
+     * 查询应急预案列表远程手机端调用
+     */
+    @GetMapping("/listapp")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resTitle", value = "标题", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resIntroduction", value = "简介", dataType = "String", required = false),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = false),
+            @ApiImplicitParam(name = "attachId", value = "附件id", dataType = "String", required = false)
+    })
+    @ApiOperation(value = "手机端远端调用", notes = "手机端远端调用")
+    public TableDataInfo listapp(CenterdataTReserve centerdataTReserve) {
+        startPage();
+        return getDataTable(centerdataTReserveService.selectCenterdataTReserveListRemoteCall(centerdataTReserve));
+    }
+
+    /**
+     * 查询应急预案下拉
+     */
+    @GetMapping("/listYuAn")
+    @ApiOperation(value = "查询应急预案下拉列表公用", notes = "查询应急预案下拉列表公用")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resTitle", value = "标题", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resIntroduction", value = "简介", dataType = "String", required = false),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = false),
+            @ApiImplicitParam(name = "attachId", value = "附件id", dataType = "String", required = false)
+    })
+    public AjaxResult listYuAn(CenterdataTReserve centerdataTReserve) {
+        return AjaxResult.success(centerdataTReserveService.selectCenterdataTReserveListRemoteCall(centerdataTReserve));
+    }
+
+    /**
+     * 查询应急预案下拉
+     * 数字农业远端调用
+     * 数字林业远端调用
+     * 数字环保远端调用
+     * 数字消防远端调用
+     * 乡村振兴远端调用
+     * 数字交通远端调用
+     */
+    @PostMapping("/listYuAnFegin")
+    @ApiOperation(value = "查询应急预案下拉列表公用远程调用", notes = "查询应急预案下拉列表公用远程调用")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "resTitle", value = "标题", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "resIntroduction", value = "简介", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "attachId", value = "附件id", dataType = "String", required = false, paramType = "body"),
+    })
+    public AjaxResult listYuAnFegin(@ApiIgnore @RequestBody CenterdataTReserve centerdataTReserve) {
+        List<CenterdataTReserve> list = centerdataTReserveService.selectCenterdataTReserveListRemoteCall(centerdataTReserve);
+        return AjaxResult.success(list);
+    }
+
+    /**
+     * 导出应急预案列表
+     * 数据中心应急预案导出调用
+     */
+    @RequiresPermissions("system:reserve:export")
+    @Log(title = "应急预案", businessType = BusinessType.EXPORT)
+    @ApiOperation(value = "导出应急预案列表", notes = "导出应急预案列表")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resTitle", value = "标题", dataType = "String", required = false),
+            @ApiImplicitParam(name = "resIntroduction", value = "简介", dataType = "String", required = false),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = false),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = false),
+            @ApiImplicitParam(name = "attachId", value = "附件id", dataType = "String", required = false)
+    })
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, CenterdataTReserve centerdataTReserve) {
+        List<CenterdataTReserve> list = centerdataTReserveService.selectCenterdataTReserveList(centerdataTReserve);
+        ExcelUtil<CenterdataTReserve> util = new ExcelUtil<>(CenterdataTReserve.class);
+        util.exportExcel(response, list, "应急预案数据");
+    }
+
+    /**
+     * 获取应急预案详细信息
+     * 数据中心应急预案详情调用
+     */
+    @ApiOperation(value = "获取应急预案详细信息", notes = "获取应急预案详细信息")
+    @ApiImplicitParams(value =
+    @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true))
+    @RequiresPermissions("system:reserve:query")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") String id) {
+        return AjaxResult.success(centerdataTReserveService.selectCenterdataTReserveById(id));
+    }
+
+    /**
+     * 新增应急预案
+     * 数据中心应急预案新增調用
+     */
+    @RequiresPermissions("system:reserve:add")
+    @ApiOperation(value = "新增应急预案", notes = "新增应急预案")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "resTitle", value = "标题", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "resIntroduction", value = "简介", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "attachId", value = "附件id", dataType = "String", required = false, paramType = "body")
+    })
+    @Log(title = "应急预案", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@ApiIgnore @Validated @RequestBody CenterdataTReserve centerdataTReserve) {
+        return toAjax(centerdataTReserveService.insertCenterdataTReserve(centerdataTReserve));
+    }
+
+    /**
+     * 修改应急预案
+     * 数据中心应急预修改调用
+     */
+    @ApiOperation(value = "修改应急预案", notes = "修改应急预案")
+    @RequiresPermissions("system:reserve:edit")
+    @Log(title = "应急预案", businessType = BusinessType.UPDATE)
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "id", value = "主键id", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "resTitle", value = "标题", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "resIntroduction", value = "简介", dataType = "String", required = false, paramType = "body"),
+            @ApiImplicitParam(name = "deptId", value = "部门id", dataType = "Long", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "deptName", value = "部门名称", dataType = "String", required = true, paramType = "body"),
+            @ApiImplicitParam(name = "attachId", value = "附件id", dataType = "String", required = false, paramType = "body")
+    })
+    @PutMapping
+    public AjaxResult edit(@ApiIgnore @Validated @RequestBody CenterdataTReserve centerdataTReserve) {
+        return toAjax(centerdataTReserveService.updateCenterdataTReserve(centerdataTReserve));
+    }
+
+    /**
+     * 删除应急预案
+     * 数据中心应急预案删除调用
+     */
+    @ApiOperation(value = "删除应急预案", notes = "删除应急预案")
+    @ApiImplicitParams(value = {
+            @ApiImplicitParam(name = "ids", value = "主键id", dataType = "String[]", required = true)
+    })
+    @RequiresPermissions("system:reserve:remove")
+    @Log(title = "应急预案", businessType = BusinessType.DELETE)
+    @DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable String[] ids) {
+        return toAjax(centerdataTReserveService.deleteCenterdataTReserveByIds(ids));
+    }
+
+    @ApiOperation(value = "发布/撤销应急预案", notes = "发布/撤销应急预案")
+    @PostMapping("/handlePublish")
+    public AjaxResult handlePublish(@RequestBody CenterdataTReserve centerdataTReserve){
+        return toAjax(centerdataTReserveService.handlePublish(centerdataTReserve));
+    }
+}

+ 72 - 0
src/main/java/com/ruoyi/system/domain/CenterdataTAttach.java

@@ -0,0 +1,72 @@
+package com.ruoyi.system.domain;
+
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.util.List;
+
+/**
+ * 附件对象 centerdata_t_attach
+ *
+ * @author ruoyi
+ * @date 2022-06-11
+ */
+@ApiModel(description = "数据中心附件实体类")
+@Data
+public class CenterdataTAttach extends BaseBusinessEntity {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 业务ID
+     */
+    @ApiModelProperty(value = "业务id", required = true)
+    @Excel(name = "业务ID")
+    private String busId;
+
+    private List<String> busIds;
+    /**
+     * 路径
+     */
+    @ApiModelProperty(value = "路径", required = false)
+    @Excel(name = "路径")
+    private String attachPath;
+
+    /**
+     * 业务类型(索引)
+     */
+    @ApiModelProperty(value = "业务类型", required = false)
+    @Excel(name = "业务类型")
+    private String busIndx;
+
+    /**
+     * 附件来源
+     */
+    @ApiModelProperty(value = "附件来源", required = false)
+    @Excel(name = "附件来源")
+    private String busSource;
+
+    /**
+     * 附件名称
+     */
+    @ApiModelProperty(value = "附件名称", required = false)
+    @Excel(name = "附件名称")
+    private String fileName;
+
+    /**
+     * 附件类型
+     */
+    @ApiModelProperty(value = "附件类型", required = false)
+    @Excel(name = "附件类型")
+    private String fileType;
+
+    /**
+     * 排序
+     */
+    @ApiModelProperty(value = "排序", required = false)
+    private int attachSorts;
+
+}

+ 143 - 0
src/main/java/com/ruoyi/system/domain/CenterdataTCommunication.java

@@ -0,0 +1,143 @@
+package com.ruoyi.system.domain;
+
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import javax.validation.constraints.NotBlank;
+
+/**
+ * 通讯录对象 centerdata_t_communication
+ *
+ * @author ruoyi
+ * @date 2022-06-20
+ */
+@Data
+@ApiModel(description = "数据中心通讯录实体类对象")
+public class CenterdataTCommunication extends BaseBusinessEntity {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键id
+     */
+    @ApiModelProperty(value = "主键id", required = false)
+    private String id;
+
+    /**
+     * 姓名
+     */
+    @ApiModelProperty(value = "姓名", required = false)
+    @Excel(name = "姓名")
+    @NotBlank(message = "姓名不能为空")
+    private String name;
+
+    /**
+     * 性别
+     */
+    @ApiModelProperty(value = "性别", required = false)
+//    @Excel(name = "性别")
+    private String sex;
+
+    /**
+     * 电话
+     */
+    @ApiModelProperty(value = "电话", required = false)
+    @Excel(name = "电话")
+    private String phone;
+
+    /**
+     * 手机
+     */
+    @ApiModelProperty(value = "手机", required = false)
+    @Excel(name = "手机")
+    @NotBlank(message = "手机不能为空")
+    private String mobile;
+
+    /**
+     * 地址
+     */
+    @ApiModelProperty(value = "地址", required = false)
+    @Excel(name = "地址")
+    private String address;
+
+    /**
+     * 拼音首字母
+     */
+    @ApiModelProperty(value = "拼音首字母", required = false)
+    @Excel(name = "拼音首字母")
+    private String firstLetter;
+
+    /**
+     * 拼音全拼
+     */
+    @ApiModelProperty(value = "拼音全拼", required = false)
+    @Excel(name = "拼音全拼")
+    private String pinyin;
+
+    /**
+     * 部门id
+     */
+    @ApiModelProperty(value = "部门id", required = false)
+
+    private Long deptId;
+
+    /**
+     * 所属部门
+     */
+    @ApiModelProperty(value = "所属部门", required = false)
+    @Excel(name = "所属部门")
+    @NotBlank(message = "所属部门不能为空")
+    private String deptName;
+
+    /**
+     * 数据状态(1-可用 2-不可用 )
+     */
+//    @Excel(name = "数据状态(1-可用 2-不可用 )")
+    private String dataStatus;
+
+
+
+    /**
+     * 手机端模糊查询
+     */
+    @ApiModelProperty(value = "模糊查询条件", required = false)
+    private String selectParam;
+
+
+
+    @Excel(name = "发布状态", dictType = "centerdata_release_status")
+    private String releaseStatus;
+
+    private String[] ids;
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("name", getName())
+                .append("sex", getSex())
+                .append("phone", getPhone())
+                .append("mobile", getMobile())
+                .append("address", getAddress())
+                .append("firstLetter", getFirstLetter())
+                .append("pinyin", getPinyin())
+                .append("deptId", getDeptId())
+                .append("deptName", getDeptName())
+                .append("dataStatus", getDataStatus())
+                .append("createBy", getCreateBy())
+                .append("createName", getCreateName())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateName", getUpdateName())
+                .append("updateTime", getUpdateTime())
+                .append("selectParam",getSelectParam())
+                .append("ids",getIds())
+                .append("releaseStatus",getReleaseStatus())
+                .toString();
+    }
+}

+ 101 - 0
src/main/java/com/ruoyi/system/domain/CenterdataTDaily.java

@@ -0,0 +1,101 @@
+package com.ruoyi.system.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.util.Date;
+
+/**
+ * 日报对象 centerdata_t_daily
+ *
+ * @author ruoyi
+ * @date 2022-05-01
+ */
+@ApiModel(description = "数据中心工作日志实体类对象")
+@Data
+public class CenterdataTDaily extends BaseBusinessEntity {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键id
+     */
+    @ApiModelProperty(value = "主键id", required = false)
+    private String id;
+
+    /**
+     * 数据状态(1-可用 2-不可用 )
+     */
+    @Excel(name = "数据状态(1-可用 2-不可用 )")
+    private String dataStatus;
+
+    /**
+     * 数据所属部门(政或党的id)
+     */
+    @Excel(name = "数据所属部门(政或党的id)")
+    private Long dataDeptId;
+
+    /**
+     * 日报类型(字典)
+     */
+    @ApiModelProperty(value = "日报类型(字典)", required = false)
+    @Excel(name = "日报类型(字典)")
+    private String dailyType;
+
+    /**
+     * 日报时间
+     */
+    @ApiModelProperty(value = "日报时间", required = false)
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "日报时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date dailyTime;
+
+    /**
+     * 日报标题
+     */
+    @ApiModelProperty(value = "日报标题", required = false)
+    @Excel(name = "日报标题")
+    private String dailyTitle;
+
+    /**
+     * 日报内容
+     */
+    @ApiModelProperty(value = "日报内容", required = false)
+    @Excel(name = "日报内容")
+    private String dailyContent;
+
+    /**
+     * 部门id
+     */
+    @ApiModelProperty(value = "部门id", required = false)
+    @Excel(name = "部门id")
+    private Long deptId;
+
+    /**
+     * 所属部门
+     */
+    @ApiModelProperty(value = "所属部门", required = false)
+    @Excel(name = "所属部门")
+    private String deptName;
+
+    private String status;
+
+    @Override
+    public String toString() {
+        return "CenterdataTDaily{" +
+                "id='" + id + '\'' +
+                ", dataStatus='" + dataStatus + '\'' +
+                ", dataDeptId=" + dataDeptId +
+                ", dailyType='" + dailyType + '\'' +
+                ", dailyTime=" + dailyTime +
+                ", dailyTitle='" + dailyTitle + '\'' +
+                ", dailyContent='" + dailyContent + '\'' +
+                ", deptId=" + deptId +
+                ", deptName='" + deptName + '\'' +
+                '}';
+    }
+}

+ 147 - 0
src/main/java/com/ruoyi/system/domain/CenterdataTLeave.java

@@ -0,0 +1,147 @@
+package com.ruoyi.system.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Getter;
+import lombok.Setter;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import javax.validation.constraints.NotBlank;
+import javax.validation.constraints.NotNull;
+import java.util.Date;
+
+/**
+ * 请假对象 centerdata_t_leave
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+@Setter
+@Getter
+@ApiModel(description = "数据中心请假管理实体类对象")
+public class CenterdataTLeave extends BaseBusinessEntity {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键id
+     */
+    @ApiModelProperty(value = "主键id", required = false)
+    private String id;
+
+    /**
+     * 数据状态(1-可用 2-不可用 )
+     */
+//    @Excel(name = "数据状态(1-可用 2-不可用 )")
+    private String dataStatus;
+
+    /**
+     * 数据所属部门(政或党的id)
+     */
+//    @Excel(name = "数据所属部门(政或党的id)")
+    private Long dataDeptId;
+
+    /**
+     * 请假开始时间
+     */
+    @ApiModelProperty(value = "请假开始时间", required = false)
+//    @JsonFormat(pattern = "yyyy-MM-dd")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
+    @NotNull(message = "请假开始时间不能为空")
+    private Date leaveStartTime;
+
+    /**
+     * 请假结束时间
+     */
+    @ApiModelProperty(value = "请假j结束时间", required = false)
+//    @JsonFormat(pattern = "yyyy-MM-dd")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
+    @NotNull(message = "请假结束时间不能为空")
+    private Date leaveEndTime;
+
+    /**
+     * 状态(字典)
+     */
+    @ApiModelProperty(value = "状态", required = false)
+    @Excel(name = "状态" , dictType = "app_leave")
+    private String forestLeaveStatus;
+
+    /**
+     * 请假事由
+     */
+    @ApiModelProperty(value = "请假事由", required = false)
+    @Excel(name = "请假事由")
+    private String leaveMatter;
+
+    /**
+     * 部门id
+     */
+//    @Excel(name = "部门id")
+    private Long deptId;
+
+    /**
+     * 所属部门
+     */
+    @Excel(name = "所属部门")
+    @NotBlank(message = "所属部门不能为空")
+    private String deptName;
+
+    /**
+     * 请假人id
+     */
+    @ApiModelProperty(value = "请假人id", required = false)
+//    @Excel(name = "请假人id")
+    private Long leaveUserId;
+
+    /**
+     * 请假人姓名
+     */
+    @ApiModelProperty(value = "请假人姓名", required = false)
+
+    @Excel(name = "请假人姓名")
+    @NotBlank(message = "请假人姓名不能为空")
+    private String leaveUserName;
+
+    private String value;
+
+    private String time;
+    /**
+     * 类型
+     */
+    private String type;
+    /**
+     * 审批人
+     */
+    private String person;
+
+
+
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .append("dataStatus", getDataStatus())
+                .append("dataDeptId", getDataDeptId())
+                .append("leaveStartTime", getLeaveStartTime())
+                .append("leaveEndTime", getLeaveEndTime())
+                .append("forestLeaveStatus", getForestLeaveStatus())
+                .append("leaveMatter", getLeaveMatter())
+                .append("deptId", getDeptId())
+                .append("deptName", getDeptName())
+                .append("leaveUserId", getLeaveUserId())
+                .append("leaveUserName", getLeaveUserName())
+                .append("updateName", getUpdateName())
+                .toString();
+    }
+}

+ 133 - 0
src/main/java/com/ruoyi/system/domain/CenterdataTLeaveCount.java

@@ -0,0 +1,133 @@
+package com.ruoyi.system.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Getter;
+import lombok.Setter;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import java.util.Date;
+
+@Setter
+@Getter
+@ApiModel(description = "数据中心请假统计实体类对象")
+public class CenterdataTLeaveCount extends BaseBusinessEntity {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键id
+     */
+    @ApiModelProperty(value = "主键id", required = false)
+    private String id;
+
+    /**
+     * 数据状态(1-可用 2-不可用 )
+     */
+//    @Excel(name = "数据状态(1-可用 2-不可用 )")
+    private String dataStatus;
+
+    /**
+     * 数据所属部门(政或党的id)
+     */
+//    @Excel(name = "数据所属部门(政或党的id)")
+    private Long dataDeptId;
+
+    /**
+     * 请假开始时间
+     */
+    @ApiModelProperty(value = "请假开始时间", required = false)
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @Excel(name = "请假时间", width = 30, dateFormat = "yyyy-MM")
+    private Date leaveStartTime;
+
+    /**
+     * 请假结束时间
+     */
+    @ApiModelProperty(value = "请假j结束时间", required = false)
+    private Date leaveEndTime;
+
+    /**
+     * 状态(字典)
+     */
+    @ApiModelProperty(value = "状态", required = false)
+    private String forestLeaveStatus;
+
+    /**
+     * 请假人事由
+     */
+    @ApiModelProperty(value = "请假人事由", required = false)
+    private String leaveMatter;
+
+    /**
+     * 请假人姓名
+     */
+    @ApiModelProperty(value = "请假人姓名", required = false)
+
+    @Excel(name = "请假人姓名")
+    private String leaveUserName;
+
+    @Excel(name = "请假次数")
+    private String value;
+
+    /**
+     * 部门id
+     */
+//    @Excel(name = "部门id")
+    private Long deptId;
+
+    /**
+     * 部门名称
+     */
+    @Excel(name = "所属部门")
+    private String deptName;
+
+    /**
+     * 请假人id
+     */
+    @ApiModelProperty(value = "请假人id", required = false)
+//    @Excel(name = "请假人id")
+    private Long leaveUserId;
+
+
+
+
+
+    private String time;
+    /**
+     * 类型
+     */
+    private String type;
+
+
+
+
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateName", getUpdateName())
+                .append("createName", getCreateName())
+                .append("updateTime", getUpdateTime())
+                .append("dataStatus", getDataStatus())
+                .append("dataDeptId", getDataDeptId())
+                .append("leaveStartTime", getLeaveStartTime())
+                .append("leaveEndTime", getLeaveEndTime())
+                .append("forestLeaveStatus", getForestLeaveStatus())
+                .append("leaveMatter", getLeaveMatter())
+                .append("deptId", getDeptId())
+                .append("deptName", getDeptName())
+                .append("leaveUserId", getLeaveUserId())
+                .append("leaveUserName", getLeaveUserName())
+                .toString();
+    }
+}
+

+ 144 - 0
src/main/java/com/ruoyi/system/domain/CenterdataTRegulations.java

@@ -0,0 +1,144 @@
+package com.ruoyi.system.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import javax.validation.constraints.NotBlank;
+import java.io.Serializable;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * 政策法规对象 centerdata_t_regulations
+ *
+ * @author ruoyi
+ * @date 2022-05-05
+ */
+@ApiModel(description = "数据中心政策法规实体类对象")
+@Data
+public class CenterdataTRegulations extends BaseBusinessEntity implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键id
+     */
+    @ApiModelProperty(value = "主键id", required = false)
+    private String id;
+
+    /**
+     * 数据状态(1-可用 2-不可用 )
+     */
+    @ApiModelProperty(value = "数据状态", required = false)
+    private String dataStatus;
+
+    /**
+     * 数据所属部门(政或党的id)
+     */
+    @ApiModelProperty(value = "数据状态", required = false)
+    private Long dataDeptId;
+
+    /**
+     * 名称
+     */
+    @ApiModelProperty(value = "名称", required = false)
+    @Excel(name = "名称")
+    @NotBlank(message = "名称不能为空")
+    private String regName;
+
+    /**
+     * 法规简介
+     */
+    @ApiModelProperty(value = "法规简介", required = false)
+    @Excel(name = "法规简介")
+    private String regIntroduction;
+
+    /**
+     * 发文机关
+     */
+    @ApiModelProperty(value = "发文机关", required = false)
+    @Excel(name = "发文机关")
+    @NotBlank(message = "发文机关不能为空")
+    private String regOffice;
+
+    /**
+     * 发文号
+     */
+    @ApiModelProperty(value = "发文号", required = false)
+    @Excel(name = "发文号")
+    @NotBlank(message = "发文号不能为空")
+    private String regNumber;
+
+    /**
+     * 发文时间
+     */
+    @ApiModelProperty(value = "发文时间", required = false)
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "发文时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date regTime;
+
+    /**
+     * 部门id
+     */
+    @ApiModelProperty(value = "部门id", required = false)
+    private Long deptId;
+
+    /**
+     * 部门名称
+     */
+    @ApiModelProperty(value = "所属部门", required = false)
+    @Excel(name = "所属部门")
+    @NotBlank(message = "所属部门不能为空")
+    private String deptName;
+
+    /**
+     * 发布状态
+     */
+    @ApiModelProperty(value="发布状态", required=false)
+    @Excel(name = "发布状态", dictType = "centerdata_release_status")
+    private String releaseStatus;
+
+    private String[] ids;
+
+    @ApiModelProperty(value = "文件名", required = false)
+    private String fileName;
+
+    @ApiModelProperty(value = "文件路径", required = false)
+    private String fileUrl;
+
+    private List<String> fileUrlList;
+    private List<String> fileNameList;
+
+    /**
+     * 附件
+     */
+    @ApiModelProperty(value = "附件id", required = false)
+    private String attachId;
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("id", getId())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .append("dataStatus", getDataStatus())
+                .append("dataDeptId", getDataDeptId())
+                .append("regName", getRegName())
+                .append("regIntroduction", getRegIntroduction())
+                .append("regOffice", getRegOffice())
+                .append("regNumber", getRegNumber())
+                .append("regTime", getRegTime())
+                .append("deptId", getDeptId())
+                .append("deptName", getDeptName())
+                .append("attachId", getAttachId())
+                .toString();
+    }
+}

+ 121 - 0
src/main/java/com/ruoyi/system/domain/CenterdataTReserve.java

@@ -0,0 +1,121 @@
+package com.ruoyi.system.domain;
+
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import javax.validation.constraints.NotBlank;
+import java.io.Serializable;
+import java.util.List;
+
+/**
+ * 应急预案对象 centerdata_t_reserve
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+@ApiModel(description = "数据中心应急预案实体类对象")
+@Data
+public class CenterdataTReserve extends BaseBusinessEntity implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键id
+     */
+    @ApiModelProperty(value = "主键id", required = false)
+    private String id;
+
+    /**
+     * 数据状态(1-可用 2-不可用 )
+     */
+    @ApiModelProperty(value = "数据状态", required = false)
+//    @Excel(name = "数据状态(1-可用 2-不可用 )")
+    private String dataStatus;
+
+    /**
+     * 数据所属部门(政或党的id)
+     */
+    @ApiModelProperty(value = "数据所属部门", required = false)
+//    @Excel(name = "数据所属部门(政或党的id)")
+    private Long dataDeptId;
+
+    /**
+     * 标题
+     */
+    @ApiModelProperty(value = "标题", required = false)
+    @Excel(name = "标题")
+    @NotBlank(message = "标题不能为空")
+    private String resTitle;
+
+    /**
+     * 简介
+     */
+    @ApiModelProperty(value = "简介", required = false)
+    @Excel(name = "简介")
+    private String resIntroduction;
+
+    /**
+     * 部门id
+     */
+    @ApiModelProperty(value = "部门id", required = false)
+    //@Excel(name = "部门id")
+    private Long deptId;
+
+    /**
+     * 所属部门
+     */
+    @ApiModelProperty(value = "所属部门", required = false)
+    @Excel(name = "所属部门")
+    @NotBlank(message = "所属部门不能为空")
+    private String deptName;
+
+    /**
+     * 附件
+     */
+    @ApiModelProperty(value = "附件", required = false)
+//    @Excel(name = "附件")
+    private String attachId;
+    @ApiModelProperty(value = "文件路径", required = false)
+
+    private String fileUrl;
+
+    private List<String> fileUrlList;
+
+    @ApiModelProperty(value = "文件名称", required = false)
+    private String fileName;
+
+    private List<String> fileNameList;
+
+    @ApiModelProperty(value="发布状态", required=false)
+    @Excel(name = "发布状态", dictType = "centerdata_release_status")
+    private String releaseStatus;
+
+    private String[] ids;
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
+                .append("ids",getIds())
+                .append("releaseStatus", getReleaseStatus())
+                .append("id", getId())
+                .append("createBy", getCreateBy())
+                .append("createTime", getCreateTime())
+                .append("updateBy", getUpdateBy())
+                .append("updateTime", getUpdateTime())
+                .append("dataStatus", getDataStatus())
+                .append("dataDeptId", getDataDeptId())
+                .append("resTitle", getResTitle())
+                .append("resIntroduction", getResIntroduction())
+                .append("deptId", getDeptId())
+                .append("deptName", getDeptName())
+                .append("attachId", getAttachId())
+                .append("fileUrlList", getFileUrlList())
+                .append("fileNameList", getFileNameList())
+                .toString();
+    }
+}

+ 23 - 0
src/main/java/com/ruoyi/system/domain/bo/ReserveAppBO.java

@@ -0,0 +1,23 @@
+package com.ruoyi.system.domain.bo;
+
+import com.ruoyi.system.domain.CenterdataTReserve;
+import lombok.Data;
+
+/**
+ * @program: ruoyi
+ * @description: yy
+ * @author: yy
+ * @create: 2022-09-21 09:57
+ **/
+@Data
+public class ReserveAppBO {
+
+    //应急预案
+    private CenterdataTReserve centerdataTReserve;
+
+    //附件路径
+    private String attachPath;
+
+    //附件名称
+    private String fileName;
+}

+ 17 - 0
src/main/java/com/ruoyi/system/mapper/BaseMapper.java

@@ -0,0 +1,17 @@
+package com.ruoyi.system.mapper;
+
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+import java.util.Map;
+
+public interface BaseMapper {
+
+    int uniqueCheck(@Param("tableName") String tableName, @Param("params") List<Map<String, String>> params);
+
+    List<Map<String, Object>> getLocationWithCamera(Object object);
+
+    List<Map<String, Object>> getCameraList(@Param("monitorDB") String monitorDB, @Param("ids") List<String> ids);
+
+    List<Map<String, Object>> getCountGroupByDept(Object object);
+}

+ 82 - 0
src/main/java/com/ruoyi/system/mapper/CenterdataTAttachMapper.java

@@ -0,0 +1,82 @@
+package com.ruoyi.system.mapper;
+
+import com.ruoyi.system.domain.CenterdataTAttach;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 附件Mapper接口
+ *
+ * @author ruoyi
+ * @date 2022-06-11
+ */
+public interface CenterdataTAttachMapper {
+
+    /**
+     * 查询附件
+     *
+     * @param busId 附件主键
+     * @return 附件
+     */
+    CenterdataTAttach selectCenterdataTAttachByBusId(String busId);
+
+    /**
+     * 查询附件列表
+     *
+     * @param centerdataTAttach 附件
+     * @return 附件集合
+     */
+    List<CenterdataTAttach> selectCenterdataTAttachList(CenterdataTAttach centerdataTAttach);
+
+    List<CenterdataTAttach> remotelistNew(CenterdataTAttach centerdataTAttach);
+
+    /**
+     * 新增附件
+     *
+     * @param centerdataTAttach 附件
+     * @return 结果
+     */
+    int insertCenterdataTAttach(CenterdataTAttach centerdataTAttach);
+
+    /**
+     * 修改附件
+     *
+     * @param centerdataTAttach 附件
+     * @return 结果
+     */
+    int updateCenterdataTAttach(CenterdataTAttach centerdataTAttach);
+
+    /**
+     * 修改事件附件
+     *
+     * @param centerdataTAttach 附件
+     * @return 结果
+     */
+    int updateEventAttach(CenterdataTAttach centerdataTAttach);
+
+    /**
+     * 删除附件
+     *
+     * @param busId 附件主键
+     * @return 结果
+     */
+    int deleteCenterdataTAttachByBusId(String busId);
+
+    List<CenterdataTAttach> listCenterdataTAttachByBusId(String busId);
+
+    List<CenterdataTAttach> urlAttch(String busId);
+
+    List<CenterdataTAttach> urlAttchMpF(String busId);
+
+    int insertEventFileLog(CenterdataTAttach res);
+
+    int insertListCenterdataTAttach(List<CenterdataTAttach> list);
+
+    List<Map<String, Object>> selectFailUpattah();
+
+    int deleteListCenterdataTAttach(@Param("busId") String busId, @Param("list") List<CenterdataTAttach> list);
+
+    List<String> selectDataAttachPathByBusId(String busId);
+}

+ 60 - 0
src/main/java/com/ruoyi/system/mapper/CenterdataTCommunicationMapper.java

@@ -0,0 +1,60 @@
+package com.ruoyi.system.mapper;
+
+
+import com.ruoyi.system.domain.CenterdataTCommunication;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 通讯录Mapper接口
+ *
+ * @author ruoyi
+ * @date 2022-06-20
+ */
+public interface CenterdataTCommunicationMapper {
+
+    /**
+     * 查询通讯录列表
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 通讯录集合
+     */
+    List<CenterdataTCommunication> selectCenterdataTCommunicationList(CenterdataTCommunication centerdataTCommunication);
+
+    /**
+     * 查询通讯录
+     *
+     * @param id 通讯录主键
+     * @return 通讯录
+     */
+    CenterdataTCommunication selectCenterdataTCommunicationById(String id);
+
+    /**
+     * 新增通讯录
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 结果
+     */
+    int insertCenterdataTCommunication(CenterdataTCommunication centerdataTCommunication);
+
+    /**
+     * 修改通讯录
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 结果
+     */
+    int updateCenterdataTCommunication(CenterdataTCommunication centerdataTCommunication);
+
+    /**
+     * 批量删除通讯录
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTCommunicationByIds(String[] ids);
+
+    List<Map<String, Object>> getCommunicationByDeptId(CenterdataTCommunication centerdataTCommunication);
+
+    int handlePublish(CenterdataTCommunication centerdataTCommunication);
+}

+ 55 - 0
src/main/java/com/ruoyi/system/mapper/CenterdataTDailyMapper.java

@@ -0,0 +1,55 @@
+package com.ruoyi.system.mapper;
+
+
+import com.ruoyi.system.domain.CenterdataTDaily;
+
+import java.util.List;
+
+/**
+ * 日报Mapper接口
+ *
+ * @author ruoyi
+ * @date 2022-05-01
+ */
+public interface CenterdataTDailyMapper {
+
+    /**
+     * 查询日报列表
+     *
+     * @param centerdataTDaily 日报
+     * @return 日报集合
+     */
+    List<CenterdataTDaily> selectCenterdataTDailyList(CenterdataTDaily centerdataTDaily);
+
+    /**
+     * 查询日报
+     *
+     * @param id 日报主键
+     * @return 日报
+     */
+    CenterdataTDaily selectCenterdataTDailyById(String id);
+
+    /**
+     * 新增日报
+     *
+     * @param centerdataTDaily 日报
+     * @return 结果
+     */
+    int insertCenterdataTDaily(CenterdataTDaily centerdataTDaily);
+
+    /**
+     * 修改日报
+     *
+     * @param centerdataTDaily 日报
+     * @return 结果
+     */
+    int updateCenterdataTDaily(CenterdataTDaily centerdataTDaily);
+
+    /**
+     * 批量删除日报
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTDailyByIds(String[] ids);
+}

+ 61 - 0
src/main/java/com/ruoyi/system/mapper/CenterdataTLeaveMapper.java

@@ -0,0 +1,61 @@
+package com.ruoyi.system.mapper;
+
+
+import com.ruoyi.system.domain.CenterdataTLeave;
+import com.ruoyi.system.domain.CenterdataTLeaveCount;
+
+import java.util.List;
+
+/**
+ * 请假Mapper接口
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+public interface CenterdataTLeaveMapper {
+
+    /**
+     * 查询请假列表
+     *
+     * @param centerdataTLeave 请假
+     * @return 请假集合
+     */
+    List<CenterdataTLeave> selectCenterdataTLeaveList(CenterdataTLeave centerdataTLeave);
+
+    /**
+     * 查询请假
+     *
+     * @param id 请假主键
+     * @return 请假
+     */
+    CenterdataTLeave selectCenterdataTLeaveById(String id);
+
+    /**
+     * 新增请假
+     *
+     * @param centerdataTLeave 请假
+     * @return 结果
+     */
+    int insertCenterdataTLeave(CenterdataTLeave centerdataTLeave);
+
+    /**
+     * 修改请假
+     *
+     * @param centerdataTLeave 请假
+     * @return 结果
+     */
+    int updateCenterdataTLeave(CenterdataTLeave centerdataTLeave);
+
+    /**
+     * 批量删除请假
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTLeaveByIds(String[] ids);
+
+    int changeStatus(CenterdataTLeave centerdataTLeave);
+
+    List<CenterdataTLeaveCount> listLeaveCount(CenterdataTLeave centerdataTLeave);
+
+}

+ 59 - 0
src/main/java/com/ruoyi/system/mapper/CenterdataTRegulationsMapper.java

@@ -0,0 +1,59 @@
+package com.ruoyi.system.mapper;
+
+
+import com.ruoyi.system.domain.CenterdataTRegulations;
+
+import java.util.List;
+
+/**
+ * 政策法规Mapper接口
+ *
+ * @author ruoyi
+ * @date 2022-05-05
+ */
+public interface CenterdataTRegulationsMapper {
+
+    /**
+     * 查询政策法规列表
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 政策法规集合
+     */
+    List<CenterdataTRegulations> selectCenterdataTRegulationsList(CenterdataTRegulations centerdataTRegulations);
+
+    /**
+     * 查询政策法规
+     *
+     * @param id 政策法规主键
+     * @return 政策法规
+     */
+    CenterdataTRegulations selectCenterdataTRegulationsById(String id);
+
+    /**
+     * 新增政策法规
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 结果
+     */
+    int insertCenterdataTRegulations(CenterdataTRegulations centerdataTRegulations);
+
+    /**
+     * 修改政策法规
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 结果
+     */
+    int updateCenterdataTRegulations(CenterdataTRegulations centerdataTRegulations);
+
+    /**
+     * 批量删除政策法规
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTRegulationsByIds(String[] ids);
+
+
+    int handlePublish(CenterdataTRegulations centerdataTRegulations);
+
+}

+ 62 - 0
src/main/java/com/ruoyi/system/mapper/CenterdataTReserveMapper.java

@@ -0,0 +1,62 @@
+package com.ruoyi.system.mapper;
+
+import com.ruoyi.system.domain.CenterdataTReserve;
+
+import java.util.List;
+
+/**
+ * 应急预案Mapper接口
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+public interface CenterdataTReserveMapper {
+
+    /**
+     * 查询应急预案列表
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 应急预案集合
+     */
+    List<CenterdataTReserve> selectCenterdataTReserveList(CenterdataTReserve centerdataTReserve);
+
+    /**
+     * 查询应急预案
+     *
+     * @param id 应急预案主键
+     * @return 应急预案
+     */
+    CenterdataTReserve selectCenterdataTReserveById(String id);
+
+    /**
+     * 新增应急预案
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 结果
+     */
+    int insertCenterdataTReserve(CenterdataTReserve centerdataTReserve);
+
+    /**
+     * 修改应急预案
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 结果
+     */
+    int updateCenterdataTReserve(CenterdataTReserve centerdataTReserve);
+
+    /**
+     * 批量删除应急预案
+     *
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTReserveByIds(String[] ids);
+
+
+    //app端查询应急预案
+    List<CenterdataTReserve> listCenterdataTReserve();
+
+    List<CenterdataTReserve> selectCenterdataTReserveListRemoteCall(CenterdataTReserve centerdataTReserve);
+
+    int handlePublish(CenterdataTReserve centerdataTReserve);
+}

+ 18 - 0
src/main/java/com/ruoyi/system/service/IBaseService.java

@@ -0,0 +1,18 @@
+package com.ruoyi.system.service;
+
+
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+
+import java.util.List;
+import java.util.Map;
+
+public interface IBaseService {
+
+    void setSookaDataBase(BaseBusinessEntity entity);
+
+    boolean uniqueCheck(String tableName, String[] keys, String[] values);
+
+    List<Map<String, Object>> getLocationWithCamera(Object object);
+
+    List<Map<String, Object>> getCountGroupByDept(Object object);
+}

+ 73 - 0
src/main/java/com/ruoyi/system/service/ICenterdataTAttachService.java

@@ -0,0 +1,73 @@
+package com.ruoyi.system.service;
+
+import com.ruoyi.system.api.domain.SysFile;
+import com.ruoyi.system.domain.CenterdataTAttach;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 附件Service接口
+ *
+ * @author ruoyi
+ * @date 2022-06-11
+ */
+public interface ICenterdataTAttachService {
+
+    /**
+     * 查询附件
+     *
+     * @param busId 附件主键
+     * @return 附件
+     */
+    CenterdataTAttach selectCenterdataTAttachByBusId(String busId);
+
+    /**
+     * 查询附件列表
+     *
+     * @param centerdataTAttach 附件
+     * @return 附件集合
+     */
+    List<CenterdataTAttach> selectCenterdataTAttachList(CenterdataTAttach centerdataTAttach);
+
+    List<CenterdataTAttach> remotelistNew(CenterdataTAttach centerdataTAttach);
+
+    /**
+     * 新增附件
+     *
+     * @param centerdataTAttach 附件
+     * @return 结果
+     */
+    int insertCenterdataTAttach(CenterdataTAttach centerdataTAttach);
+
+    /**
+     * 修改附件
+     *
+     * @param centerdataTAttach 附件
+     * @return 结果
+     */
+    int updateCenterdataTAttach(CenterdataTAttach centerdataTAttach);
+
+    /**
+     * 删除附件信息
+     *
+     * @param busId 附件主键
+     * @return 结果
+     */
+    int deleteCenterdataTAttachByBusId(String busId);
+
+    void updateEventAttach(Map<String, String> paramMap);
+
+    void updateEventAttach(CenterdataTAttach centerdataTAttach);
+
+    //新增附件List
+    int insertListCenterdataTAttach(List<CenterdataTAttach> list);
+
+    List<Map<String, Object>> selectFailUpattah();
+
+    void updateEventAttachSchedule(Map<String, Object> paramMap, SysFile sysFile);
+
+    int deleteListCenterdataTAttach(String busId, List<CenterdataTAttach> list);
+
+    List<String> selectDataAttachPathByBusId(String busId);
+}

+ 60 - 0
src/main/java/com/ruoyi/system/service/ICenterdataTCommunicationService.java

@@ -0,0 +1,60 @@
+package com.ruoyi.system.service;
+
+
+import com.ruoyi.system.domain.CenterdataTCommunication;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 通讯录Service接口
+ *
+ * @author ruoyi
+ * @date 2022-06-20
+ */
+public interface ICenterdataTCommunicationService {
+
+    /**
+     * 查询通讯录列表
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 通讯录集合
+     */
+    List<CenterdataTCommunication> selectCenterdataTCommunicationList(CenterdataTCommunication centerdataTCommunication);
+
+    /**
+     * 查询通讯录
+     *
+     * @param id 通讯录主键
+     * @return 通讯录
+     */
+    CenterdataTCommunication selectCenterdataTCommunicationById(String id);
+
+    /**
+     * 新增通讯录
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 结果
+     */
+    int insertCenterdataTCommunication(CenterdataTCommunication centerdataTCommunication);
+
+    /**
+     * 修改通讯录
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 结果
+     */
+    int updateCenterdataTCommunication(CenterdataTCommunication centerdataTCommunication);
+
+    /**
+     * 批量删除通讯录
+     *
+     * @param ids 需要删除的通讯录主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTCommunicationByIds(String[] ids);
+
+    List<Map<String, Object>> getCommunicationByDeptId(CenterdataTCommunication centerdataTCommunication);
+
+    int handlePublish(CenterdataTCommunication centerdataTCommunication);
+}

+ 55 - 0
src/main/java/com/ruoyi/system/service/ICenterdataTDailyService.java

@@ -0,0 +1,55 @@
+package com.ruoyi.system.service;
+
+
+import com.ruoyi.system.domain.CenterdataTDaily;
+
+import java.util.List;
+
+/**
+ * 日报Service接口
+ *
+ * @author ruoyi
+ * @date 2022-05-01
+ */
+public interface ICenterdataTDailyService {
+
+    /**
+     * 查询日报列表
+     *
+     * @param centerdataTDaily 日报
+     * @return 日报集合
+     */
+    List<CenterdataTDaily> selectCenterdataTDailyList(CenterdataTDaily centerdataTDaily);
+
+    /**
+     * 查询日报
+     *
+     * @param id 日报主键
+     * @return 日报
+     */
+    CenterdataTDaily selectCenterdataTDailyById(String id);
+
+    /**
+     * 新增日报
+     *
+     * @param centerdataTDaily 日报
+     * @return 结果
+     */
+    int insertCenterdataTDaily(CenterdataTDaily centerdataTDaily);
+
+    /**
+     * 修改日报
+     *
+     * @param centerdataTDaily 日报
+     * @return 结果
+     */
+    int updateCenterdataTDaily(CenterdataTDaily centerdataTDaily);
+
+    /**
+     * 批量删除日报
+     *
+     * @param ids 需要删除的日报主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTDailyByIds(String[] ids);
+}

+ 60 - 0
src/main/java/com/ruoyi/system/service/ICenterdataTLeaveService.java

@@ -0,0 +1,60 @@
+package com.ruoyi.system.service;
+
+import com.ruoyi.system.domain.CenterdataTLeave;
+import com.ruoyi.system.domain.CenterdataTLeaveCount;
+
+import java.util.List;
+
+/**
+ * 请假Service接口
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+public interface ICenterdataTLeaveService {
+
+    /**
+     * 查询请假列表
+     *
+     * @param centerdataTLeave 请假
+     * @return 请假集合
+     */
+    List<CenterdataTLeave> selectCenterdataTLeaveList(CenterdataTLeave centerdataTLeave);
+
+    /**
+     * 查询请假
+     *
+     * @param id 请假主键
+     * @return 请假
+     */
+    CenterdataTLeave selectCenterdataTLeaveById(String id);
+
+    /**
+     * 新增请假
+     *
+     * @param centerdataTLeave 请假
+     * @return 结果
+     */
+    int insertCenterdataTLeave(CenterdataTLeave centerdataTLeave);
+
+    /**
+     * 修改请假
+     *
+     * @param centerdataTLeave 请假
+     * @return 结果
+     */
+    int updateCenterdataTLeave(CenterdataTLeave centerdataTLeave);
+
+    /**
+     * 批量删除请假
+     *
+     * @param ids 需要删除的请假主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTLeaveByIds(String[] ids);
+
+    int changeStatus(CenterdataTLeave centerdataTLeave);
+
+    List<CenterdataTLeaveCount> listLeaveCount(CenterdataTLeave centerdataTLeave);
+
+}

+ 57 - 0
src/main/java/com/ruoyi/system/service/ICenterdataTRegulationsService.java

@@ -0,0 +1,57 @@
+package com.ruoyi.system.service;
+
+
+import com.ruoyi.system.domain.CenterdataTRegulations;
+
+import java.util.List;
+
+/**
+ * 政策法规Service接口
+ *
+ * @author ruoyi
+ * @date 2022-05-05
+ */
+public interface ICenterdataTRegulationsService {
+
+    /**
+     * 查询政策法规列表
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 政策法规集合
+     */
+    List<CenterdataTRegulations> selectCenterdataTRegulationsList(CenterdataTRegulations centerdataTRegulations);
+
+    /**
+     * 查询政策法规
+     *
+     * @param id 政策法规主键
+     * @return 政策法规
+     */
+    CenterdataTRegulations selectCenterdataTRegulationsById(String id);
+
+    /**
+     * 新增政策法规
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 结果
+     */
+    int insertCenterdataTRegulations(CenterdataTRegulations centerdataTRegulations);
+
+    /**
+     * 修改政策法规
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 结果
+     */
+    int updateCenterdataTRegulations(CenterdataTRegulations centerdataTRegulations);
+
+    /**
+     * 批量删除政策法规
+     *
+     * @param ids 需要删除的政策法规主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTRegulationsByIds(String[] ids);
+
+    int handlePublish(CenterdataTRegulations centerdataTRegulations);
+}

+ 67 - 0
src/main/java/com/ruoyi/system/service/ICenterdataTReserveService.java

@@ -0,0 +1,67 @@
+package com.ruoyi.system.service;
+
+
+import com.ruoyi.system.domain.CenterdataTReserve;
+import com.ruoyi.system.domain.bo.ReserveAppBO;
+
+import java.util.List;
+
+/**
+ * 应急预案Service接口
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+public interface ICenterdataTReserveService {
+
+    /**
+     * 查询应急预案列表
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 应急预案集合
+     */
+    List<CenterdataTReserve> selectCenterdataTReserveList(CenterdataTReserve centerdataTReserve);
+
+    /**
+     * 查询应急预案
+     *
+     * @param id 应急预案主键
+     * @return 应急预案
+     */
+    CenterdataTReserve selectCenterdataTReserveById(String id);
+
+    /**
+     * 新增应急预案
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 结果
+     */
+    int insertCenterdataTReserve(CenterdataTReserve centerdataTReserve);
+
+    /**
+     * 修改应急预案
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 结果
+     */
+    int updateCenterdataTReserve(CenterdataTReserve centerdataTReserve);
+
+    /**
+     * 批量删除应急预案
+     *
+     * @param ids 需要删除的应急预案主键集合
+     * @return 结果
+     */
+    int deleteCenterdataTReserveByIds(String[] ids);
+
+
+    //app端查询应急预案
+    List<CenterdataTReserve> listCenterdataTReserve();
+
+    //app端查询应急预案及附件
+    List<ReserveAppBO> listReserveApp();
+
+    List<CenterdataTReserve> selectCenterdataTReserveListRemoteCall(CenterdataTReserve centerdataTReserve);
+
+    int handlePublish(CenterdataTReserve centerdataTReserve);
+}

+ 99 - 0
src/main/java/com/ruoyi/system/service/impl/BaseServiceImpl.java

@@ -0,0 +1,99 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.common.core.utils.StringUtils;
+import com.ruoyi.common.datascope.base.domain.BaseBusinessEntity;
+import com.ruoyi.system.mapper.BaseMapper;
+import com.ruoyi.system.service.IBaseService;
+import org.apache.commons.collections4.MapUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.beans.factory.annotation.Value;
+import org.springframework.stereotype.Service;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+
+@Service
+public class BaseServiceImpl implements IBaseService {
+
+    @Value("${sooka.database.database_data:}")
+    public String database_data;
+
+    @Value("${sooka.database.database_event:}")
+    public String database_event;
+
+    @Value("${sooka.database.database_monitor:}")
+    public String database_monitor;
+
+    @Value("${sooka.database.database_system:}")
+    public String database_system;
+
+    public void setSookaDataBase(BaseBusinessEntity entity) {
+        entity.setDatabase_data(this.database_data);
+        entity.setDatabase_event(this.database_event);
+        entity.setDatabase_monitor(this.database_monitor);
+        entity.setDatabase_system(this.database_system);
+    }
+
+    protected Logger logger = LoggerFactory.getLogger(this.getClass());
+
+    @Autowired
+    private BaseMapper baseMapper;
+
+    public boolean uniqueCheck(String tableName, String[] keys, String[] values) {
+        if (StringUtils.isBlank(tableName) || StringUtils.isEmpty(keys) || StringUtils.isEmpty(values)) {
+            logger.error("参数必输校验失败");
+            return false;
+        }
+        int result = 1;
+        // 判定: keys 与 values 的长度不一致, 返回false
+        if (keys.length != values.length) {
+            logger.error("key/value长度不一致");
+        } else {
+            List<Map<String, String>> params = new ArrayList<>();
+            Map<String, String> param = null;
+            for (int i = 0; i < keys.length; i++) {
+                param = new HashMap<>();
+                param.put("key", keys[i]);
+                param.put("value", values[i]);
+                params.add(param);
+            }
+            try {
+                result = baseMapper.uniqueCheck(tableName, params);
+            } catch (Exception e) {
+                logger.error("唯一校验查询异常,请检查参数是否正确:{}", e.getMessage());
+            }
+        }
+        return 0 == result;
+    }
+
+    @Override
+    public List<Map<String, Object>> getLocationWithCamera(Object object) {
+        List<Map<String, Object>> pointList = baseMapper.getLocationWithCamera(object);
+        List<String> ids = pointList.stream().map(item -> MapUtils.getString(item, "id")).collect(Collectors.toList());
+        List<Map<String, Object>> cameraList = getCameraList(ids);
+        pointList.forEach(point -> {
+            List<Map<String, Object>> list = new ArrayList<>();
+            cameraList.forEach(camera -> {
+                if (MapUtils.getString(point, "id").equals(MapUtils.getString(camera, "businessId"))) {
+                    list.add(camera);
+                }
+            });
+            point.put("cameraList", list);
+        });
+        return pointList;
+    }
+
+    public List<Map<String, Object>> getCameraList(List<String> ids) {
+        return baseMapper.getCameraList(database_monitor, ids);
+    }
+
+    @Override
+    public List<Map<String, Object>> getCountGroupByDept(Object object) {
+        return baseMapper.getCountGroupByDept(object);
+    }
+}

+ 174 - 0
src/main/java/com/ruoyi/system/service/impl/CenterdataTAttachServiceImpl.java

@@ -0,0 +1,174 @@
+package com.ruoyi.system.service.impl;
+
+import com.alibaba.fastjson.JSON;
+import com.ruoyi.common.core.utils.DateUtils;
+import com.ruoyi.common.core.utils.SpringUtils;
+import com.ruoyi.common.core.utils.file.FilePrefixUtils;
+import com.ruoyi.system.api.RemoteFileService;
+import com.ruoyi.system.api.domain.SysFile;
+import com.ruoyi.system.domain.CenterdataTAttach;
+import com.ruoyi.system.mapper.CenterdataTAttachMapper;
+import com.ruoyi.system.service.ICenterdataTAttachService;
+import org.apache.commons.collections4.MapUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+import org.springframework.web.multipart.MultipartFile;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 附件Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-06-11
+ */
+@Service
+public class CenterdataTAttachServiceImpl extends BaseServiceImpl implements ICenterdataTAttachService {
+
+    @Autowired
+    private CenterdataTAttachMapper centerdataTAttachMapper;
+
+    /**
+     * 查询附件
+     *
+     * @param busId 附件主键
+     * @return 附件
+     */
+    @Override
+    public CenterdataTAttach selectCenterdataTAttachByBusId(String busId) {
+        return centerdataTAttachMapper.selectCenterdataTAttachByBusId(busId);
+    }
+
+    /**
+     * 查询附件列表
+     *
+     * @param centerdataTAttach 附件
+     * @return 附件
+     */
+    @Override
+    public List<CenterdataTAttach> selectCenterdataTAttachList(CenterdataTAttach centerdataTAttach) {
+        return centerdataTAttachMapper.selectCenterdataTAttachList(centerdataTAttach);
+    }
+
+    @Override
+    public List<CenterdataTAttach> remotelistNew(CenterdataTAttach centerdataTAttach) {
+        return centerdataTAttachMapper.remotelistNew(centerdataTAttach);
+    }
+
+    /**
+     * 新增附件
+     *
+     * @param centerdataTAttach 附件
+     * @return 结果
+     */
+    @Override
+    public int insertCenterdataTAttach(CenterdataTAttach centerdataTAttach) {
+        /*
+         *ImageUpload返回是全路径,数据库保存不要ip和端口号
+         */
+        if (centerdataTAttach.getAttachPath().startsWith("http")) {
+            String attachPath = centerdataTAttach.getAttachPath();
+            if (centerdataTAttach.getAttachPath().contains("Download")) {
+                int i1 = attachPath.indexOf("group=");
+                attachPath = attachPath.replace("&&path=", "/");
+                attachPath = attachPath.substring(i1 + 6);
+                centerdataTAttach.setAttachPath(attachPath);
+            } else {
+                int i1 = attachPath.indexOf('/');
+                int i2 = attachPath.indexOf('/', i1 + 1);
+                int i3 = attachPath.indexOf('/', i2 + 1);
+                centerdataTAttach.setAttachPath(centerdataTAttach.getAttachPath().substring(i3 + 1, attachPath.length()));
+            }
+        }
+        return centerdataTAttachMapper.insertCenterdataTAttach(centerdataTAttach);
+    }
+
+    /**
+     * 修改附件
+     *
+     * @param centerdataTAttach 附件
+     * @return 结果
+     */
+    @Override
+    public int updateCenterdataTAttach(CenterdataTAttach centerdataTAttach) {
+        return centerdataTAttachMapper.updateCenterdataTAttach(centerdataTAttach);
+    }
+
+    /**
+     * 删除附件信息
+     *
+     * @param busId 附件主键
+     * @return 结果
+     */
+    @Override
+    public int deleteCenterdataTAttachByBusId(String busId) {
+        return centerdataTAttachMapper.deleteCenterdataTAttachByBusId(busId);
+    }
+
+    @Transactional
+    @Override
+    public void updateEventAttach(Map<String, String> paramMap) {
+        List<CenterdataTAttach> attaches = centerdataTAttachMapper.listCenterdataTAttachByBusId(MapUtils.getString(paramMap, "busId"));
+        attaches.forEach(item -> {
+            String url = "";
+            if ("DH_1".equals(item.getBusSource())) {
+                url = FilePrefixUtils.getUrlPrefix(item.getBusSource(), paramMap) + item.getAttachPath() + "?token=" + MapUtils.getString(paramMap, "token");
+            } else {
+                url = FilePrefixUtils.getUrlPrefix(item.getBusSource(), paramMap) + item.getAttachPath();
+            }
+            MultipartFile multipartFile = FilePrefixUtils.urlToMultipartFile(url, System.currentTimeMillis() + ".jpg");
+            SysFile sysFile = SpringUtils.getBean(RemoteFileService.class).upload(multipartFile).getData();
+            item.setFileName(item.getAttachPath());
+            item.setAttachPath(sysFile.getUrl());
+            item.setBusSource("APP".equals(MapUtils.getString(paramMap, "czlx")) ? "APP" : "PC");
+            centerdataTAttachMapper.updateEventAttach(item);
+
+            setSookaDataBase(item);
+            item.setFileName(JSON.toJSONString(item));
+            item.setCreateTime(DateUtils.getNowDate());
+            centerdataTAttachMapper.insertEventFileLog(item);
+        });
+    }
+
+    @Transactional
+    @Override
+    public void updateEventAttachSchedule(Map<String, Object> paramMap, SysFile sysFile) {
+        CenterdataTAttach centerdataTAttach = new CenterdataTAttach();
+        centerdataTAttach.setFileName(MapUtils.getString(paramMap, "url"));
+        centerdataTAttach.setAttachPath(sysFile.getUrl());
+        centerdataTAttach.setBusSource("PC");
+        centerdataTAttach.setBusId(MapUtils.getString(paramMap, "busId"));
+        centerdataTAttachMapper.updateEventAttach(centerdataTAttach);
+        setSookaDataBase(centerdataTAttach);
+        centerdataTAttach.setFileName(JSON.toJSONString(centerdataTAttach));
+        centerdataTAttach.setCreateTime(DateUtils.getNowDate());
+        centerdataTAttachMapper.insertEventFileLog(centerdataTAttach);
+    }
+
+    @Override
+    public void updateEventAttach(CenterdataTAttach centerdataTAttach) {
+        centerdataTAttachMapper.updateEventAttach(centerdataTAttach);
+    }
+
+    @Override
+    public int insertListCenterdataTAttach(List<CenterdataTAttach> list) {
+        return centerdataTAttachMapper.insertListCenterdataTAttach(list);
+    }
+
+    @Override
+    public List<Map<String, Object>> selectFailUpattah() {
+        return centerdataTAttachMapper.selectFailUpattah();
+    }
+
+    @Override
+    public int deleteListCenterdataTAttach(String busId, List<CenterdataTAttach> list) {
+        return centerdataTAttachMapper.deleteListCenterdataTAttach(busId, list);
+    }
+
+    @Override
+    public List<String> selectDataAttachPathByBusId(String busId) {
+        return centerdataTAttachMapper.selectDataAttachPathByBusId(busId);
+    }
+}

+ 103 - 0
src/main/java/com/ruoyi/system/service/impl/CenterdataTCommunicationServiceImpl.java

@@ -0,0 +1,103 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.common.core.utils.DateUtils;
+import com.ruoyi.common.core.utils.uuid.IdUtils;
+import com.ruoyi.common.datascope.annotation.DataScopeMutiDept;
+import com.ruoyi.common.security.utils.SecurityUtils;
+import com.ruoyi.system.domain.CenterdataTCommunication;
+import com.ruoyi.system.mapper.CenterdataTCommunicationMapper;
+import com.ruoyi.system.service.ICenterdataTCommunicationService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 通讯录Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-06-20
+ */
+@Service
+public class CenterdataTCommunicationServiceImpl extends BaseServiceImpl implements ICenterdataTCommunicationService {
+
+    @Autowired
+    private CenterdataTCommunicationMapper centerdataTCommunicationMapper;
+
+    /**
+     * 查询通讯录列表
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 通讯录
+     */
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<CenterdataTCommunication> selectCenterdataTCommunicationList(CenterdataTCommunication centerdataTCommunication) {
+        setSookaDataBase(centerdataTCommunication);
+        return centerdataTCommunicationMapper.selectCenterdataTCommunicationList(centerdataTCommunication);
+    }
+
+    /**
+     * 查询通讯录
+     *
+     * @param id 通讯录主键
+     * @return 通讯录
+     */
+    @Override
+    public CenterdataTCommunication selectCenterdataTCommunicationById(String id) {
+        return centerdataTCommunicationMapper.selectCenterdataTCommunicationById(id);
+    }
+
+    /**
+     * 新增通讯录
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 结果
+     */
+    @Override
+    public int insertCenterdataTCommunication(CenterdataTCommunication centerdataTCommunication) {
+        centerdataTCommunication.setId(IdUtils.simpleUUID());
+        centerdataTCommunication.setCreateBy(SecurityUtils.getUserId().toString());
+        centerdataTCommunication.setCreateName(SecurityUtils.getLoginUser().getSysUser().getNickName());
+        centerdataTCommunication.setCreateTime(DateUtils.getNowDate());
+        return centerdataTCommunicationMapper.insertCenterdataTCommunication(centerdataTCommunication);
+    }
+
+    /**
+     * 修改通讯录
+     *
+     * @param centerdataTCommunication 通讯录
+     * @return 结果
+     */
+    @Override
+    public int updateCenterdataTCommunication(CenterdataTCommunication centerdataTCommunication) {
+        centerdataTCommunication.setUpdateBy(SecurityUtils.getUserId());
+        centerdataTCommunication.setUpdateName(SecurityUtils.getLoginUser().getSysUser().getNickName());
+        centerdataTCommunication.setUpdateTime(DateUtils.getNowDate());
+        return centerdataTCommunicationMapper.updateCenterdataTCommunication(centerdataTCommunication);
+    }
+
+    /**
+     * 批量删除通讯录
+     *
+     * @param ids 需要删除的通讯录主键
+     * @return 结果
+     */
+    @Override
+    public int deleteCenterdataTCommunicationByIds(String[] ids) {
+        return centerdataTCommunicationMapper.deleteCenterdataTCommunicationByIds(ids);
+    }
+
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<Map<String, Object>> getCommunicationByDeptId(CenterdataTCommunication centerdataTCommunication) {
+        setSookaDataBase(centerdataTCommunication);
+        return centerdataTCommunicationMapper.getCommunicationByDeptId(centerdataTCommunication);
+    }
+
+    @Override
+    public int handlePublish(CenterdataTCommunication centerdataTCommunication) {
+        return centerdataTCommunicationMapper.handlePublish(centerdataTCommunication);
+    }
+}

+ 89 - 0
src/main/java/com/ruoyi/system/service/impl/CenterdataTDailyServiceImpl.java

@@ -0,0 +1,89 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.common.core.utils.DateUtils;
+import com.ruoyi.common.core.utils.uuid.IdUtils;
+import com.ruoyi.common.datascope.annotation.DataScopeMutiDept;
+import com.ruoyi.common.security.utils.SecurityUtils;
+import com.ruoyi.system.domain.CenterdataTDaily;
+import com.ruoyi.system.mapper.CenterdataTDailyMapper;
+import com.ruoyi.system.service.ICenterdataTDailyService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ * 日报Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-05-01
+ */
+@Service
+public class CenterdataTDailyServiceImpl extends BaseServiceImpl implements ICenterdataTDailyService {
+
+    @Autowired
+    private CenterdataTDailyMapper centerdataTDailyMapper;
+
+    /**
+     * 查询日报列表
+     *
+     * @param centerdataTDaily 日报
+     * @return 日报
+     */
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<CenterdataTDaily> selectCenterdataTDailyList(CenterdataTDaily centerdataTDaily) {
+        setSookaDataBase(centerdataTDaily);
+        return centerdataTDailyMapper.selectCenterdataTDailyList(centerdataTDaily);
+    }
+
+    /**
+     * 查询日报
+     *
+     * @param id 日报主键
+     * @return 日报
+     */
+    @Override
+    public CenterdataTDaily selectCenterdataTDailyById(String id) {
+        return centerdataTDailyMapper.selectCenterdataTDailyById(id);
+    }
+
+    /**
+     * 新增日报
+     *
+     * @param centerdataTDaily 日报
+     * @return 结果
+     */
+    @Override
+    public int insertCenterdataTDaily(CenterdataTDaily centerdataTDaily) {
+        centerdataTDaily.setId(IdUtils.simpleUUID());
+        centerdataTDaily.setCreateBy(SecurityUtils.getUserId().toString());
+        centerdataTDaily.setCreateName(SecurityUtils.getUsername());
+        centerdataTDaily.setCreateTime(DateUtils.getNowDate());
+        return centerdataTDailyMapper.insertCenterdataTDaily(centerdataTDaily);
+    }
+
+    /**
+     * 修改日报
+     *
+     * @param centerdataTDaily 日报
+     * @return 结果
+     */
+    @Override
+    public int updateCenterdataTDaily(CenterdataTDaily centerdataTDaily) {
+        centerdataTDaily.setUpdateBy(SecurityUtils.getUserId());
+        centerdataTDaily.setUpdateTime(DateUtils.getNowDate());
+        return centerdataTDailyMapper.updateCenterdataTDaily(centerdataTDaily);
+    }
+
+    /**
+     * 批量删除日报
+     *
+     * @param ids 需要删除的日报主键
+     * @return 结果
+     */
+    @Override
+    public int deleteCenterdataTDailyByIds(String[] ids) {
+        return centerdataTDailyMapper.deleteCenterdataTDailyByIds(ids);
+    }
+}

+ 108 - 0
src/main/java/com/ruoyi/system/service/impl/CenterdataTLeaveServiceImpl.java

@@ -0,0 +1,108 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.common.core.utils.DateUtils;
+import com.ruoyi.common.core.utils.uuid.IdUtils;
+import com.ruoyi.common.datascope.annotation.DataScopeMutiDept;
+import com.ruoyi.common.security.utils.SecurityUtils;
+import com.ruoyi.system.domain.CenterdataTLeave;
+import com.ruoyi.system.domain.CenterdataTLeaveCount;
+import com.ruoyi.system.mapper.CenterdataTLeaveMapper;
+import com.ruoyi.system.service.ICenterdataTLeaveService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ * 请假Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+@Service
+public class CenterdataTLeaveServiceImpl extends BaseServiceImpl implements ICenterdataTLeaveService {
+
+    @Autowired
+    private CenterdataTLeaveMapper centerdataTLeaveMapper;
+
+
+
+    /**
+     * 查询请假列表
+     *
+     * @param centerdataTLeave 请假
+     * @return 请假
+     */
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<CenterdataTLeave> selectCenterdataTLeaveList(CenterdataTLeave centerdataTLeave) {
+        setSookaDataBase(centerdataTLeave);
+        return centerdataTLeaveMapper.selectCenterdataTLeaveList(centerdataTLeave);
+    }
+
+    /**
+     * 查询请假
+     *
+     * @param id 请假主键
+     * @return 请假
+     */
+    @Override
+    public CenterdataTLeave selectCenterdataTLeaveById(String id) {
+        return centerdataTLeaveMapper.selectCenterdataTLeaveById(id);
+    }
+
+    /**
+     * 新增请假
+     *
+     * @param centerdataTLeave 请假
+     * @return 结果
+     */
+    @Override
+    public int insertCenterdataTLeave(CenterdataTLeave centerdataTLeave) {
+        centerdataTLeave.setId(IdUtils.simpleUUID());
+        centerdataTLeave.setCreateBy(SecurityUtils.getUserId().toString());
+        centerdataTLeave.setCreateTime(DateUtils.getNowDate());
+        centerdataTLeave.setCreateName( SecurityUtils.getLoginUser().getSysUser().getNickName());
+        return centerdataTLeaveMapper.insertCenterdataTLeave(centerdataTLeave);
+    }
+
+    /**
+     * 修改请假
+     *
+     * @param centerdataTLeave 请假
+     * @return 结果
+     */
+    @Override
+    public int updateCenterdataTLeave(CenterdataTLeave centerdataTLeave) {
+        centerdataTLeave.setUpdateBy(SecurityUtils.getUserId());
+        centerdataTLeave.setUpdateTime(DateUtils.getNowDate());
+        centerdataTLeave.setUpdateName( SecurityUtils.getLoginUser().getSysUser().getNickName());
+        return centerdataTLeaveMapper.updateCenterdataTLeave(centerdataTLeave);
+    }
+
+    /**
+     * 批量删除请假
+     *
+     * @param ids 需要删除的请假主键
+     * @return 结果
+     */
+    @Override
+    public int deleteCenterdataTLeaveByIds(String[] ids) {
+        return centerdataTLeaveMapper.deleteCenterdataTLeaveByIds(ids);
+    }
+
+    @Override
+    public int changeStatus(CenterdataTLeave centerdataTLeave) {
+        centerdataTLeave.setUpdateBy(SecurityUtils.getUserId());
+        centerdataTLeave.setUpdateTime(DateUtils.getNowDate());
+        centerdataTLeave.setPerson( SecurityUtils.getLoginUser().getSysUser().getNickName());
+        return centerdataTLeaveMapper.changeStatus(centerdataTLeave);
+    }
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<CenterdataTLeaveCount> listLeaveCount(CenterdataTLeave centerdataTLeave) {
+        setSookaDataBase(centerdataTLeave);
+        return centerdataTLeaveMapper.listLeaveCount(centerdataTLeave);
+    }
+
+}

+ 156 - 0
src/main/java/com/ruoyi/system/service/impl/CenterdataTRegulationsServiceImpl.java

@@ -0,0 +1,156 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.common.core.utils.DateUtils;
+import com.ruoyi.common.core.utils.SpringUtils;
+import com.ruoyi.common.core.utils.StringUtils;
+import com.ruoyi.common.core.utils.uuid.IdUtils;
+import com.ruoyi.common.datascope.annotation.DataScopeMutiDept;
+import com.ruoyi.common.security.utils.SecurityUtils;
+import com.ruoyi.system.api.RemoteConfigService;
+import com.ruoyi.system.domain.CenterdataTAttach;
+import com.ruoyi.system.domain.CenterdataTRegulations;
+import com.ruoyi.system.mapper.CenterdataTRegulationsMapper;
+import com.ruoyi.system.service.ICenterdataTAttachService;
+import com.ruoyi.system.service.ICenterdataTRegulationsService;
+import com.ruoyi.system.utils.FileUtil;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+import static com.ruoyi.system.utils.DataConstants.DOWNLOAD_URL;
+
+/**
+ * 政策法规Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-05-05
+ */
+@Service
+public class CenterdataTRegulationsServiceImpl extends BaseServiceImpl implements ICenterdataTRegulationsService {
+
+    @Autowired
+    private CenterdataTRegulationsMapper centerdataTRegulationsMapper;
+
+    @Autowired
+    private ICenterdataTAttachService centerdataTAttachService;
+
+    /**
+     * 查询政策法规列表
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 政策法规
+     */
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<CenterdataTRegulations> selectCenterdataTRegulationsList(CenterdataTRegulations centerdataTRegulations) {
+        setSookaDataBase(centerdataTRegulations);
+        List<CenterdataTRegulations> list = centerdataTRegulationsMapper.selectCenterdataTRegulationsList(centerdataTRegulations);
+        String fileurl = SpringUtils.getBean(RemoteConfigService.class).remotegetConfigKey(DOWNLOAD_URL).getData();
+        for (CenterdataTRegulations tFile : list) {
+            if (tFile.getFileUrl() != null) {
+                StringBuilder newDiles = new StringBuilder();
+                String url = tFile.getFileUrl();
+                newDiles.append(fileurl + "Download?fileName=" + tFile.getFileName() + "&&group=" + url.substring(0, url.indexOf('/')) + "&&path=" + url.substring(url.indexOf('/') + 1));
+                tFile.setFileUrl(newDiles.toString());
+            }
+        }
+        return list;
+    }
+
+    /**
+     * 查询政策法规
+     *
+     * @param id 政策法规主键
+     * @return 政策法规
+     */
+    @Override
+    public CenterdataTRegulations selectCenterdataTRegulationsById(String id) {
+        CenterdataTRegulations centerdataTRegulations = centerdataTRegulationsMapper.selectCenterdataTRegulationsById(id);
+        if (StringUtils.isNotEmpty(centerdataTRegulations.getFileUrl())) {
+            String fileurl = SpringUtils.getBean(RemoteConfigService.class).remotegetConfigKey(DOWNLOAD_URL).getData();
+            String[] files = centerdataTRegulations.getFileUrl().split(",");
+            StringBuilder diles = new StringBuilder();
+            for (String s : files) {
+                String filename = s.substring(s.indexOf('+') + 1);
+                String url = s.substring(0, s.indexOf('+'));
+                String group = url.substring(0, url.indexOf('/'));
+                diles.append(fileurl + "Download?fileName=" + filename + "&&group=" + group + "&&path=" + url.substring(url.indexOf('/') + 1) + "+" + filename + ",");
+            }
+            String newDiles = diles.toString().substring(0, diles.toString().length() - 1);
+            centerdataTRegulations.setFileUrl(newDiles);
+        }
+        return centerdataTRegulations;
+    }
+
+    /**
+     * 新增政策法规
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 结果
+     */
+    @Override
+    public int insertCenterdataTRegulations(CenterdataTRegulations centerdataTRegulations) {
+        String bussource = "PC";
+        String busindx = "zcfg";
+        if(StringUtils.isNotEmpty(centerdataTRegulations.getFileUrlList())){
+            String attachId = IdUtils.fastSimpleUUID();
+            centerdataTRegulations.setAttachId(attachId);
+            List<CenterdataTAttach> list = FileUtil.documentProcessing(centerdataTRegulations.getId(), attachId, centerdataTRegulations.getFileUrlList(), centerdataTRegulations.getFileNameList(), bussource, busindx);
+            if (StringUtils.isNotEmpty(list)) {
+                centerdataTAttachService.insertListCenterdataTAttach(list);
+            }
+        }
+
+        centerdataTRegulations.setId(IdUtils.simpleUUID());
+        centerdataTRegulations.setCreateBy(SecurityUtils.getUserId().toString());
+        centerdataTRegulations.setCreateTime(DateUtils.getNowDate());
+        centerdataTRegulations.setCreateName(SecurityUtils.getLoginUser().getSysUser().getNickName());
+        return centerdataTRegulationsMapper.insertCenterdataTRegulations(centerdataTRegulations);
+    }
+
+    /**
+     * 修改政策法规
+     *
+     * @param centerdataTRegulations 政策法规
+     * @return 结果
+     */
+    @Override
+    public int updateCenterdataTRegulations(CenterdataTRegulations centerdataTRegulations) {
+        centerdataTRegulations.setUpdateBy(SecurityUtils.getUserId());
+        centerdataTRegulations.setUpdateTime(DateUtils.getNowDate());
+        centerdataTRegulations.setUpdateName(SecurityUtils.getLoginUser().getSysUser().getNickName());
+        String bussource = "PC";
+        String busindx = "zcfg";
+        if (StringUtils.isNotEmpty(centerdataTRegulations.getFileUrl())) {
+            centerdataTAttachService.deleteCenterdataTAttachByBusId(centerdataTRegulations.getAttachId());
+            String attachId = IdUtils.fastSimpleUUID();
+            centerdataTRegulations.setAttachId(attachId);
+            List<CenterdataTAttach> list = FileUtil.documentProcessing(centerdataTRegulations.getId(), attachId, centerdataTRegulations.getFileUrlList(), centerdataTRegulations.getFileNameList(), bussource, busindx);
+
+            if (StringUtils.isNotEmpty(list)) {
+                centerdataTAttachService.insertListCenterdataTAttach(list);
+            }
+        } else if (StringUtils.isNotEmpty(centerdataTRegulations.getAttachId())) {
+            centerdataTAttachService.deleteCenterdataTAttachByBusId(centerdataTRegulations.getAttachId());
+            centerdataTRegulations.setAttachId("");
+        }
+        return centerdataTRegulationsMapper.updateCenterdataTRegulations(centerdataTRegulations);
+    }
+
+    /**
+     * 批量删除政策法规
+     *
+     * @param ids 需要删除的政策法规主键
+     * @return 结果
+     */
+    @Override
+    public int deleteCenterdataTRegulationsByIds(String[] ids) {
+        return centerdataTRegulationsMapper.deleteCenterdataTRegulationsByIds(ids);
+    }
+
+    @Override
+    public int handlePublish(CenterdataTRegulations centerdataTRegulations) {
+        return centerdataTRegulationsMapper.handlePublish(centerdataTRegulations);
+    }
+}

+ 198 - 0
src/main/java/com/ruoyi/system/service/impl/CenterdataTReserveServiceImpl.java

@@ -0,0 +1,198 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.common.core.utils.DateUtils;
+import com.ruoyi.common.core.utils.SpringUtils;
+import com.ruoyi.common.core.utils.StringUtils;
+import com.ruoyi.common.core.utils.uuid.IdUtils;
+import com.ruoyi.common.datascope.annotation.DataScopeMutiDept;
+import com.ruoyi.common.security.utils.SecurityUtils;
+import com.ruoyi.system.api.RemoteConfigService;
+import com.ruoyi.system.domain.CenterdataTAttach;
+import com.ruoyi.system.domain.CenterdataTReserve;
+import com.ruoyi.system.domain.bo.ReserveAppBO;
+import com.ruoyi.system.mapper.CenterdataTReserveMapper;
+import com.ruoyi.system.service.ICenterdataTAttachService;
+import com.ruoyi.system.service.ICenterdataTReserveService;
+import com.ruoyi.system.utils.FileUtil;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import static com.ruoyi.system.utils.DataConstants.DOWNLOAD_URL;
+
+/**
+ * 应急预案Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-05-04
+ */
+@Service
+public class CenterdataTReserveServiceImpl extends BaseServiceImpl implements ICenterdataTReserveService {
+
+    @Autowired
+    private CenterdataTReserveMapper centerdataTReserveMapper;
+
+    @Autowired
+    private ICenterdataTAttachService centerdataTAttachService;
+
+    /**
+     * 查询应急预案列表
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 应急预案
+     */
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<CenterdataTReserve> selectCenterdataTReserveList(CenterdataTReserve centerdataTReserve) {
+        setSookaDataBase(centerdataTReserve);
+        List<CenterdataTReserve> list = centerdataTReserveMapper.selectCenterdataTReserveList(centerdataTReserve);
+        String fileurl = SpringUtils.getBean(RemoteConfigService.class).remotegetConfigKey(DOWNLOAD_URL).getData();
+        for (CenterdataTReserve tFile : list) {
+            if (tFile.getFileUrl() != null) {
+                StringBuilder newDiles = new StringBuilder();
+                String url = tFile.getFileUrl();
+                newDiles.append(fileurl + "Download?fileName=" + tFile.getFileName() + "&&group=" + url.substring(0, url.indexOf('/')) + "&&path=" + url.substring(url.indexOf('/') + 1));
+                tFile.setFileUrl(newDiles.toString());
+            }
+        }
+        return list;
+    }
+
+    /**
+     * 查询应急预案
+     *
+     * @param id 应急预案主键
+     * @return 应急预案
+     */
+    @Override
+    public CenterdataTReserve selectCenterdataTReserveById(String id) {
+        CenterdataTReserve centerdataTReserve = centerdataTReserveMapper.selectCenterdataTReserveById(id);
+        if (StringUtils.isNotEmpty(centerdataTReserve.getFileUrl())) {
+            String fileurl = SpringUtils.getBean(RemoteConfigService.class).remotegetConfigKey(DOWNLOAD_URL).getData();
+            String[] files = centerdataTReserve.getFileUrl().split(",");
+            StringBuilder diles = new StringBuilder();
+            for (String s : files) {
+                String filename = s.substring(s.indexOf('+') + 1);
+                String url = s.substring(0, s.indexOf('+'));
+                String group = url.substring(0, url.indexOf('/'));
+                diles.append(fileurl + "Download?fileName=" + filename + "&&group=" + group + "&&path=" + url.substring(url.indexOf('/') + 1) + "+" + filename + ",");
+            }
+            String newDiles = diles.toString().substring(0, diles.toString().length() - 1);
+            centerdataTReserve.setFileUrl(newDiles);
+        }
+        return centerdataTReserve;
+    }
+
+    /**
+     * 新增应急预案
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 结果
+     */
+    @Override
+    public int insertCenterdataTReserve(CenterdataTReserve centerdataTReserve) {
+        String bussource = "PC";
+        String busindx = "yjya";
+        if (StringUtils.isNotEmpty(centerdataTReserve.getFileUrlList())) {
+            String attachId = IdUtils.fastSimpleUUID();
+            centerdataTReserve.setAttachId(attachId);
+            List<CenterdataTAttach> list = FileUtil.documentProcessing(centerdataTReserve.getId(), attachId, centerdataTReserve.getFileUrlList(), centerdataTReserve.getFileNameList(), bussource, busindx);
+            if (StringUtils.isNotEmpty(list)) {
+                centerdataTAttachService.insertListCenterdataTAttach(list);
+            }
+        }
+        centerdataTReserve.setId(IdUtils.simpleUUID());
+        centerdataTReserve.setCreateBy(SecurityUtils.getUserId().toString());
+        centerdataTReserve.setCreateTime(DateUtils.getNowDate());
+        centerdataTReserve.setCreateName(SecurityUtils.getLoginUser().getSysUser().getNickName());
+        return centerdataTReserveMapper.insertCenterdataTReserve(centerdataTReserve);
+    }
+
+    /**
+     * 修改应急预案
+     *
+     * @param centerdataTReserve 应急预案
+     * @return 结果
+     */
+    @Override
+    public int updateCenterdataTReserve(CenterdataTReserve centerdataTReserve) {
+        centerdataTReserve.setUpdateBy(SecurityUtils.getUserId());
+        centerdataTReserve.setUpdateTime(DateUtils.getNowDate());
+        centerdataTReserve.setUpdateName(SecurityUtils.getLoginUser().getSysUser().getNickName());
+        String bussource = "PC";
+        String busindx = "yjya";
+        if (StringUtils.isNotEmpty(centerdataTReserve.getFileUrl())) {
+            centerdataTAttachService.deleteCenterdataTAttachByBusId(centerdataTReserve.getAttachId());
+            String attachId = IdUtils.fastSimpleUUID();
+            centerdataTReserve.setAttachId(attachId);
+            List<CenterdataTAttach> list = FileUtil.documentProcessing(centerdataTReserve.getId(), attachId, centerdataTReserve.getFileUrlList(), centerdataTReserve.getFileNameList(), bussource, busindx);
+
+            if (StringUtils.isNotEmpty(list)) {
+                centerdataTAttachService.insertListCenterdataTAttach(list);
+            }
+        } else if (StringUtils.isNotEmpty(centerdataTReserve.getAttachId())) {
+            centerdataTAttachService.deleteCenterdataTAttachByBusId(centerdataTReserve.getAttachId());
+            centerdataTReserve.setAttachId("");
+        }
+        return centerdataTReserveMapper.updateCenterdataTReserve(centerdataTReserve);
+    }
+
+    /**
+     * 批量删除应急预案
+     *
+     * @param ids 需要删除的应急预案主键
+     * @return 结果
+     */
+    @Override
+    public int deleteCenterdataTReserveByIds(String[] ids) {
+        return centerdataTReserveMapper.deleteCenterdataTReserveByIds(ids);
+    }
+
+
+    //app端查询应急预案
+    @Override
+    public List<CenterdataTReserve> listCenterdataTReserve() {
+        return centerdataTReserveMapper.listCenterdataTReserve();
+    }
+
+    //app端查询应急预案及附件
+    @Override
+    public List<ReserveAppBO> listReserveApp() {
+        List<ReserveAppBO> reserveAppBOS = new ArrayList<>();
+        List<CenterdataTReserve> centerdataTReserves = this.listCenterdataTReserve();
+        for (CenterdataTReserve centerdataTReserve : centerdataTReserves) {
+            ReserveAppBO reserveAppBO = new ReserveAppBO();
+            reserveAppBO.setCenterdataTReserve(centerdataTReserve);
+            CenterdataTAttach centerdataTAttach = centerdataTAttachService.selectCenterdataTAttachByBusId(centerdataTReserve.getAttachId());
+            reserveAppBO.setAttachPath(centerdataTAttach.getAttachPath());
+            reserveAppBO.setFileName(centerdataTAttach.getFileName());
+            reserveAppBOS.add(reserveAppBO);
+        }
+        return reserveAppBOS;
+    }
+
+
+    @DataScopeMutiDept(deptAlias = "d")
+    @Override
+    public List<CenterdataTReserve> selectCenterdataTReserveListRemoteCall(CenterdataTReserve centerdataTReserve) {
+        setSookaDataBase(centerdataTReserve);
+        List<CenterdataTReserve> list = centerdataTReserveMapper.selectCenterdataTReserveListRemoteCall(centerdataTReserve);
+        String fileurl = SpringUtils.getBean(RemoteConfigService.class).remotegetConfigKey(DOWNLOAD_URL).getData();
+        for (CenterdataTReserve tFile : list) {
+            if (tFile.getFileUrl() != null) {
+                StringBuilder newDiles = new StringBuilder();
+                String url = tFile.getFileUrl();
+                newDiles.append(fileurl + "Download?fileName=" + tFile.getFileName() + "&&group=" + url.substring(0, url.indexOf('/')) + "&&path=" + url.substring(url.indexOf('/') + 1));
+                tFile.setFileUrl(newDiles.toString());
+            }
+        }
+        return list;
+    }
+
+    @Override
+    public int handlePublish(CenterdataTReserve centerdataTReserve) {
+        return centerdataTReserveMapper.handlePublish(centerdataTReserve);
+    }
+}

+ 32 - 0
src/main/java/com/ruoyi/system/utils/DataConstants.java

@@ -0,0 +1,32 @@
+package com.ruoyi.system.utils;
+
+/**
+ * 数据中心常量池
+ */
+public class DataConstants {
+
+    private DataConstants() {
+        throw new IllegalStateException("Utility class");
+    }
+
+    public static final String FILE_URL = "fileUrl";
+
+    public static final String DOWNLOAD_URL = "downloadUrl";
+
+    public static final String ERROR_MSG = "数据已存在!";
+
+    public static final String MONTH = "month";
+
+    public static final String DAY = "day";
+
+    public static final String YEAR = "year";
+
+    public static final String CREATE_TIME = "create_time";
+
+    public static final String TITLE = "title";
+
+    public static final String CONTACTS ="contacts";
+
+    //植树造林任务管理对象-任务状态字段tree_status
+    public static final String TREE_STATUS ="tree_status";
+}

+ 94 - 0
src/main/java/com/ruoyi/system/utils/FileUtil.java

@@ -0,0 +1,94 @@
+package com.ruoyi.system.utils;
+
+import com.ruoyi.common.core.utils.StringUtils;
+import com.ruoyi.common.core.utils.file.FilePrefixUtils;
+import com.ruoyi.system.domain.CenterdataTAttach;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * 附件文件 保存前处理
+ */
+public class FileUtil {
+
+    private FileUtil() {
+        throw new IllegalStateException("Utility class");
+    }
+
+    public static List<CenterdataTAttach> documentProcessing(String id, String attachId, List<String> fileUrlsList, List<String> fileNamesList, String source, String busindx) {
+        List<CenterdataTAttach> list = new ArrayList<>();
+        // 新增逻辑
+        if (StringUtils.isBlank(id)) {
+            for (int i = 0; i < fileUrlsList.size(); i++) {
+                if (null == fileUrlsList.get(i)) {
+                    continue;
+                }
+                String fileUrl = fileUrlsList.get(i).replace(",", "");
+                String fileName = fileNamesList.get(i).replace(",", "");
+
+                CenterdataTAttach centerdataTAttach = new CenterdataTAttach();
+                String filetype = FilePrefixUtils.getUrlSuffix(fileUrlsList.get(i));
+                centerdataTAttach.setFileType(filetype);
+                centerdataTAttach.setBusId(attachId);
+                centerdataTAttach.setBusSource(source);
+                centerdataTAttach.setAttachPath(fileUrl);
+                centerdataTAttach.setBusIndx(busindx);
+                centerdataTAttach.setFileName(fileName);
+                attach(centerdataTAttach);
+                list.add(centerdataTAttach);
+            }
+        } else {
+            String fileUrl = "";
+            for (int i = 0; i < fileUrlsList.size(); i++) {
+                if (null == fileUrlsList.get(i)) {
+                    continue;
+                }
+                CenterdataTAttach centerdataTAttach = new CenterdataTAttach();
+                centerdataTAttach.setBusId(attachId);
+                if (fileUrlsList.get(i).indexOf("+") > -1 || fileUrlsList.get(i).indexOf("&&") > -1) {
+                    if (fileUrlsList.get(i).indexOf("+") > -1) {
+                        fileUrl = fileUrlsList.get(i).substring(0, fileUrlsList.get(i).indexOf("+"));
+                    } else {
+                        fileUrl = fileUrlsList.get(i);
+                    }
+                    String[] fileurls = fileUrl.split("&&");
+                    fileUrl = fileurls[1].substring(fileurls[1].indexOf("=") + 1) + "/" + fileurls[2].substring(fileurls[2].indexOf("=") + 1);
+                } else {
+                    fileUrl = fileUrlsList.get(i);
+                }
+                String fileName = fileNamesList.get(i).replace(",", "");
+                fileUrl = fileUrl.replace(",", "");
+
+                String filetype = FilePrefixUtils.getUrlSuffix(fileUrlsList.get(i));
+                centerdataTAttach.setFileType(filetype);
+                centerdataTAttach.setBusSource(source);
+                centerdataTAttach.setAttachPath(fileUrl);
+                centerdataTAttach.setBusIndx(busindx);
+                centerdataTAttach.setFileName(fileName);
+                list.add(centerdataTAttach);
+            }
+        }
+        return list;
+    }
+
+    public static void attach(CenterdataTAttach centerdataTAttach) {
+        /*
+         *ImageUpload返回是全路径,数据库保存不要ip和端口号
+         */
+        if (centerdataTAttach.getAttachPath().startsWith("http")) {
+            String attachPath = centerdataTAttach.getAttachPath();
+            if (centerdataTAttach.getAttachPath().contains("Download")) {
+                int i1 = attachPath.indexOf("group=");
+                attachPath = attachPath.replace("&&path=", "/");
+                attachPath = attachPath.substring(i1 + 6);
+                centerdataTAttach.setAttachPath(attachPath);
+            } else {
+                int i1 = attachPath.indexOf('/');
+                int i2 = attachPath.indexOf('/', i1 + 1);
+                int i3 = attachPath.indexOf('/', i2 + 1);
+                centerdataTAttach.setAttachPath(centerdataTAttach.getAttachPath().substring(i3 + 1, attachPath.length()));
+            }
+        }
+    }
+}

+ 193 - 0
src/main/resources/mapper/data/CenterdataTAttachMapper.xml

@@ -0,0 +1,193 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CenterdataTAttachMapper">
+
+    <resultMap type="com.ruoyi.system.domain.CenterdataTAttach" id="CenterdataTAttachResult">
+        <result property="busId" column="bus_id"/>
+        <result property="attachPath" column="attach_path"/>
+        <result property="busIndx" column="bus_indx"/>
+        <result property="busSource" column="bus_source"/>
+        <result property="fileName" column="file_name"/>
+        <result property="fileType" column="file_type"/>
+        <result property="createTime" column="create_time"/>
+        <result property="attachSorts" column="attach_sorts"/>
+    </resultMap>
+
+    <sql id="selectCenterdataTAttachVo">
+        select bus_id, attach_path, bus_indx,bus_source,file_name,file_type,create_time,attach_sorts from centerdata_t_attach
+    </sql>
+
+    <select id="selectCenterdataTAttachList" parameterType="com.ruoyi.system.domain.CenterdataTAttach" resultMap="CenterdataTAttachResult">
+        <include refid="selectCenterdataTAttachVo"/>
+        <where>
+            <if test="busId != null  and busId != ''">and bus_id = #{busId}</if>
+            <if test="attachPath != null  and attachPath != ''">and attach_path = #{attachPath}</if>
+            <if test="busIndx != null  and busIndx != ''">and bus_indx = #{busIndx}</if>
+            <if test="busSource != null  and busSource != ''">and bus_source = #{busSource}</if>
+        </where>
+        order by attach_sorts
+    </select>
+
+    <select id="remotelistNew" parameterType="com.ruoyi.system.domain.CenterdataTAttach" resultMap="CenterdataTAttachResult">
+        select bus_id, attach_path, bus_indx,bus_source,file_name,file_type from centerdata_t_attach
+        where bus_id in
+        <foreach item="busIds" collection="busIds" open="(" separator="," close=")">
+            #{busIds}
+        </foreach>
+        order by attach_sorts
+    </select>
+
+    <select id="selectCenterdataTAttachByBusId" parameterType="String" resultMap="CenterdataTAttachResult">
+        <include refid="selectCenterdataTAttachVo"/>
+        where bus_id = #{busId}
+    </select>
+
+    <select id="listCenterdataTAttachByBusId" parameterType="String" resultMap="CenterdataTAttachResult">
+        <include refid="selectCenterdataTAttachVo"/>
+        where bus_id = #{busId}
+    </select>
+
+    <insert id="insertCenterdataTAttach" parameterType="com.ruoyi.system.domain.CenterdataTAttach">
+        insert into centerdata_t_attach
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="busId != null">bus_id,</if>
+            <if test="attachPath != null">attach_path,</if>
+            <if test="busIndx != null">bus_indx,</if>
+            <if test="busSource != null">bus_source,</if>
+            <if test="fileName != null">file_name,</if>
+            <if test="fileType != null">file_type,</if>
+            <if test="attachSorts != null">attach_sorts,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="busId != null">#{busId},</if>
+            <if test="attachPath != null">#{attachPath},</if>
+            <if test="busIndx != null">#{busIndx},</if>
+            <if test="busSource != null">#{busSource},</if>
+            <if test="fileName != null">#{fileName},</if>
+            <if test="fileType != null">#{fileType},</if>
+            <if test="attachSorts != null">#{attachSorts},</if>
+        </trim>
+    </insert>
+
+    <update id="updateCenterdataTAttach" parameterType="com.ruoyi.system.domain.CenterdataTAttach">
+        update centerdata_t_attach
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="busIndx != null">bus_indx = #{busIndx},</if>
+            <if test="attachPath != null">attach_path = #{attachPath},</if>
+            <if test="busSource != null">bus_source = #{busSource},</if>
+            <if test="fileName != null">file_name = #{fileName},</if>
+            <if test="fileType != null">file_type = #{fileType},</if>
+            <if test="attachSorts != null">attach_sorts = #{attachSorts},</if>
+        </trim>
+        where bus_id = #{busId}
+    </update>
+
+    <update id="updateEventAttach" parameterType="com.ruoyi.system.domain.CenterdataTAttach">
+        update centerdata_t_attach
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="busIndx != null">bus_indx = #{busIndx},</if>
+            <if test="attachPath != null">attach_path = #{attachPath},</if>
+            <if test="busSource != null">bus_source = #{busSource},</if>
+            <if test="fileType != null">file_type = #{fileType},</if>
+            <if test="attachSorts != null">attach_sorts = #{attachSorts},</if>
+        </trim>
+        where bus_id = #{busId} and attach_path = #{fileName}
+    </update>
+
+    <delete id="deleteCenterdataTAttachByBusId" parameterType="String">
+        delete from centerdata_t_attach where bus_id = #{busId}
+    </delete>
+
+    <select id="urlAttch" parameterType="java.lang.String" resultType="com.ruoyi.system.domain.CenterdataTAttach">
+        select attach_path attachPath,file_name fileName,bus_source busSource
+        from centerdata_t_attach
+        where bus_id = #{busId} and attach_path not like concat('%', 'mp4', '%')
+        order by create_time,attach_sorts
+    </select>
+
+    <select id="urlAttchMpF" parameterType="java.lang.String" resultType="com.ruoyi.system.domain.CenterdataTAttach">
+        select attach_path attachPath,file_name fileName,bus_source busSource
+        from centerdata_t_attach
+        where bus_id = #{busId} and attach_path like concat('%', 'mp4', '%')
+    </select>
+
+    <insert id="insertEventFileLog" parameterType="com.ruoyi.system.domain.CenterdataTAttach">
+        insert into ${database_event}.centerevent_t_log
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="busId != null">id,</if>
+            <if test="fileName != null">log_content,</if>
+            <if test="createTime != null">create_time,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="busId != null">#{busId},</if>
+            <if test="fileName != null">#{fileName},</if>
+            <if test="createTime != null">#{createTime},</if>
+        </trim>
+    </insert>
+
+    <insert id="insertListCenterdataTAttach" parameterType="com.ruoyi.system.domain.CenterdataTAttach">
+        insert into centerdata_t_attach
+        (
+        bus_id,
+        attach_path,
+        bus_indx,
+        bus_source,
+        file_name,
+        file_type,
+        attach_sorts
+        )values
+        <foreach collection="list" item="item" index="index" open="" close="" separator=",">
+            (
+            #{item.busId},
+            #{item.attachPath},
+            #{item.busIndx},
+            #{item.busSource},
+            #{item.fileName},
+            #{item.fileType},
+            #{item.attachSorts}
+            )
+        </foreach>
+    </insert>
+
+    <select id="selectFailUpattah" resultType="map">
+        SELECT
+        ch.bus_id busId,
+        ch.attach_path url,
+        ch.bus_source BusSource,
+        a.create_time,
+        a.event_name
+        FROM
+        onest_event.centerevent_t_eventcatalogue a
+        LEFT JOIN (
+        SELECT
+        SUBSTRING_INDEX( GROUP_CONCAT( id ORDER BY create_time ), ',', 1 ) id,
+        event_code
+        FROM
+        onest_event.centerevent_t_fire_log
+        WHERE
+        DATEDIFF( NOW(), create_time ) &lt;= 30
+        GROUP BY
+        event_code
+        ) d ON a.event_code = d.event_code
+        LEFT JOIN onest_data.centerdata_t_attach ch ON ch.bus_id = d.id
+        WHERE
+        ch.attach_path NOT LIKE 'group%'
+        AND a.report_source = 'reporting_source_1'
+        AND DATEDIFF( NOW(), a.create_time ) &lt;= 30
+        AND a.event_status_value IN ('forest_event_status_2','forest_event_status_5','forest_event_status_6','forest_event_status_7')
+        order by a.create_time
+    </select>
+
+    <delete id="deleteListCenterdataTAttach" parameterType="com.ruoyi.system.domain.CenterdataTAttach">
+        delete from centerdata_t_attach where bus_id = #{busId} and attach_path in
+        <foreach collection="list" item="item" index="index" open="(" separator="," close=")">
+            #{item.attachPath}
+        </foreach>
+    </delete>
+
+    <select id="selectDataAttachPathByBusId" resultType="String" parameterType="String">
+        select attach_path from centerdata_t_attach where bus_id = #{busId} order by attach_sorts
+    </select>
+</mapper>

+ 189 - 0
src/main/resources/mapper/data/CenterdataTCommunicationMapper.xml

@@ -0,0 +1,189 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CenterdataTCommunicationMapper">
+
+    <resultMap type="com.ruoyi.system.domain.CenterdataTCommunication" id="CenterdataTCommunicationResult">
+        <result property="id" column="id"/>
+        <result property="name" column="name"/>
+        <result property="sex" column="sex"/>
+        <result property="phone" column="phone"/>
+        <result property="mobile" column="mobile"/>
+        <result property="address" column="address"/>
+        <result property="firstLetter" column="first_letter"/>
+        <result property="pinyin" column="pinyin"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="dataStatus" column="data_status"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createName" column="create_name"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateName" column="update_name"/>
+        <result property="updateTime" column="update_time"/>
+        <result property="releaseStatus" column="release_status"/>
+    </resultMap>
+
+    <sql id="selectCenterdataTCommunicationVo">
+        select id, create_by, create_name, create_time, update_by, update_name, update_time, data_status, dept_id, dept_name, name, sex, phone, mobile, address, first_letter, pinyin, release_status from centerdata_t_communication
+    </sql>
+
+    <select id="selectCenterdataTCommunicationList" parameterType="com.ruoyi.system.domain.CenterdataTCommunication"
+            resultMap="CenterdataTCommunicationResult">
+        select a.* from centerdata_t_communication a
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            <if test="createName != null  and createName != ''">and create_name like concat('%', #{createName}, '%')
+            </if>
+            <if test="updateName != null  and updateName != ''">and update_name like concat('%', #{updateName}, '%')
+            </if>
+            <if test="dataStatus != null  and dataStatus != ''">and data_status = #{dataStatus}</if>
+            <if test="dataDeptId != null ">and data_dept_id = #{dataDeptId}</if>
+            <if test="name != null  and name != ''">and name like concat('%', #{name}, '%')</if>
+            <if test="sex != null  and sex != ''">and sex = #{sex}</if>
+            <if test="phone != null  and phone != ''">and phone = #{phone}</if>
+            <if test="mobile != null  and mobile != ''">and mobile like concat('%', #{mobile}, '%')</if>
+            <if test="address != null  and address != ''">and address = #{address}</if>
+            <if test="firstLetter != null  and firstLetter != ''">and first_letter = #{firstLetter}</if>
+            <if test="pinyin != null  and pinyin != ''">and pinyin = #{pinyin}</if>
+            <if test="releaseStatus != null and releaseStatus != ''">and release_status = #{releaseStatus}</if>
+            <if test="deptId != null">
+                <choose>
+                    <when test="deptName != null and deptName == 0">
+                        and FIND_IN_SET( #{deptId}, CONCAT( d.ancestors, ",", d.dept_id) )
+                    </when>
+                    <otherwise>and d.dept_id = #{deptId}</otherwise>
+                </choose>
+            </if>
+            ${params.dataScope}
+        </where>
+        order by a.create_time desc
+    </select>
+
+    <select id="selectCenterdataTCommunicationById" parameterType="String" resultMap="CenterdataTCommunicationResult">
+        <include refid="selectCenterdataTCommunicationVo"/>
+        where id = #{id}
+    </select>
+
+    <insert id="insertCenterdataTCommunication" parameterType="com.ruoyi.system.domain.CenterdataTCommunication">
+        insert into centerdata_t_communication
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createName != null">create_name,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateName != null">update_name,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="dataStatus != null">data_status,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="deptName != null">dept_name,</if>
+            <if test="name != null">name,</if>
+            <if test="sex != null">sex,</if>
+            <if test="phone != null">phone,</if>
+            <if test="mobile != null">mobile,</if>
+            <if test="address != null">address,</if>
+            <if test="firstLetter != null">first_letter,</if>
+            <if test="pinyin != null">pinyin,</if>
+            <if test="releaseStatus != null">release_status,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createName != null">#{createName},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateName != null">#{updateName},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="dataStatus != null">#{dataStatus},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="deptName != null">#{deptName},</if>
+            <if test="name != null">#{name},</if>
+            <if test="sex != null">#{sex},</if>
+            <if test="phone != null">#{phone},</if>
+            <if test="mobile != null">#{mobile},</if>
+            <if test="address != null">#{address},</if>
+            <if test="firstLetter != null">#{firstLetter},</if>
+            <if test="pinyin != null">#{pinyin},</if>
+            <if test="releaseStatus != null">#{releaseStatus}</if>
+        </trim>
+    </insert>
+
+    <update id="updateCenterdataTCommunication" parameterType="com.ruoyi.system.domain.CenterdataTCommunication">
+        update centerdata_t_communication
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createName != null">create_name = #{createName},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateName != null">update_name = #{updateName},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="dataStatus != null">data_status = #{dataStatus},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="deptName != null">dept_name = #{deptName},</if>
+            <if test="name != null">name = #{name},</if>
+            <if test="sex != null">sex = #{sex},</if>
+            <if test="phone != null">phone = #{phone},</if>
+            <if test="mobile != null">mobile = #{mobile},</if>
+            <if test="address != null">address = #{address},</if>
+            <if test="firstLetter != null">first_letter = #{firstLetter},</if>
+            <if test="pinyin != null">pinyin = #{pinyin},</if>
+            <if test="releaseStatus != null">release_status = #{releaseStatus},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteCenterdataTCommunicationByIds" parameterType="String">
+        delete from centerdata_t_communication where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+
+
+    <select id="getCommunicationByDeptId" parameterType="com.ruoyi.system.domain.CenterdataTCommunication" resultType="java.util.Map">
+        select
+        a.id,
+        a.dept_id as parentId,
+        a.name as label,
+        a.mobile as mobile
+        from centerdata_t_communication a
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            and release_status = 'centerdata_release_status_yes'
+            <if test="createName != null  and createName != ''">and create_name like concat('%', #{createName}, '%')
+            </if>
+            <if test="updateName != null  and updateName != ''">and update_name like concat('%', #{updateName}, '%')
+            </if>
+            <if test="dataStatus != null  and dataStatus != ''">and data_status = #{dataStatus}</if>
+            <if test="deptId != null ">and a.dept_id = #{deptId}</if>
+            <if test="name != null  and name != ''">and name like concat('%', #{name}, '%')</if>
+            <if test="sex != null  and sex != ''">and sex = #{sex}</if>
+            <if test="phone != null  and phone != ''">and a.phone like concat('%', #{phone}, '%')</if>
+            <if test="mobile != null  and mobile != ''">and mobile = #{mobile}</if>
+            <if test="address != null  and address != ''">and address = #{address}</if>
+            <if test="firstLetter != null  and firstLetter != ''">and first_letter = #{firstLetter}</if>
+            <if test="pinyin != null  and pinyin != ''">and pinyin = #{pinyin}</if>
+            <if test="selectParam != null and selectParam != ''">
+                and (
+                a.name like concat('%', #{selectParam}, '%')
+                or
+                a.phone like concat('%', #{selectParam}, '%')
+                )
+            </if>
+            ${params.dataScope}
+        </where>
+        order by a.create_time desc
+    </select>
+
+
+    <update id="handlePublish" parameterType="com.ruoyi.system.domain.CenterdataTCommunication">
+        update centerdata_t_communication set release_status = #{releaseStatus}
+        where
+        id in
+        <foreach collection="ids" item="id" open="(" close=")" separator=",">
+            #{id}
+        </foreach>
+    </update>
+</mapper>

+ 122 - 0
src/main/resources/mapper/data/CenterdataTDailyMapper.xml

@@ -0,0 +1,122 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CenterdataTDailyMapper">
+
+    <resultMap type="com.ruoyi.system.domain.CenterdataTDaily" id="CenterdataTDailyResult">
+        <result property="id" column="id"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+        <result property="dataStatus" column="data_status"/>
+        <result property="dataDeptId" column="data_dept_id"/>
+        <result property="dailyType" column="daily_type"/>
+        <result property="dailyTime" column="daily_time"/>
+        <result property="dailyTitle" column="daily_title"/>
+        <result property="dailyContent" column="daily_content"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="createName" column="create_name"/>
+        <result property="status" column="status"/>
+    </resultMap>
+
+    <sql id="selectCenterdataTDailyVo">
+        select id, create_by, create_time, create_name,status,update_by, update_time, data_status, data_dept_id, daily_type, daily_time, daily_title, daily_content, dept_id, dept_name from centerdata_t_daily
+    </sql>
+
+    <select id="selectCenterdataTDailyList" parameterType="com.ruoyi.system.domain.CenterdataTDaily" resultMap="CenterdataTDailyResult">
+        select a.id, a.create_by, a.create_time, a.update_by, a.update_time,a.status, a.data_status, a.data_dept_id, a.daily_type, a.daily_time,
+        a.daily_title, a.daily_content, a.dept_id, d.dept_name,a.create_name from centerdata_t_daily a
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            <if test="dataStatus != null  and dataStatus != ''">and data_status = #{dataStatus}</if>
+            <if test="dataDeptId != null ">and data_dept_id = #{dataDeptId}</if>
+            <if test="dailyType != null  and dailyType != ''">and daily_type = #{dailyType}</if>
+            <if test="dailyTime != null ">and daily_time = #{dailyTime}</if>
+            <if test="dailyTitle != null  and dailyTitle != ''">and daily_title like concat('%',#{dailyTitle},'%') </if>
+            <if test="dailyContent != null  and dailyContent != ''">and daily_content = #{dailyContent}</if>
+            <if test="deptId != null">
+                <choose>
+                    <when test="deptName != null and deptName == 0">
+                        and FIND_IN_SET( #{deptId}, CONCAT( d.ancestors, ",", d.dept_id) )
+                    </when>
+                    <otherwise>and d.dept_id = #{deptId}</otherwise>
+                </choose>
+            </if>
+            ${params.dataScope}
+        </where>
+        order by a.create_time desc
+    </select>
+
+    <select id="selectCenterdataTDailyById" parameterType="String" resultMap="CenterdataTDailyResult">
+        <include refid="selectCenterdataTDailyVo"/>
+        where id = #{id}
+    </select>
+
+    <insert id="insertCenterdataTDaily" parameterType="com.ruoyi.system.domain.CenterdataTDaily">
+        insert into centerdata_t_daily
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="createName != null">create_name,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="dataStatus != null">data_status,</if>
+            <if test="dataDeptId != null">data_dept_id,</if>
+            <if test="dailyType != null">daily_type,</if>
+            <if test="dailyTime != null">daily_time,</if>
+            <if test="dailyTitle != null">daily_title,</if>
+            <if test="dailyContent != null">daily_content,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="deptName != null">dept_name,</if>
+            <if test="status != null">status,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="createName != null">#{createName},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="dataStatus != null">#{dataStatus},</if>
+            <if test="dataDeptId != null">#{dataDeptId},</if>
+            <if test="dailyType != null">#{dailyType},</if>
+            <if test="dailyTime != null">#{dailyTime},</if>
+            <if test="dailyTitle != null">#{dailyTitle},</if>
+            <if test="dailyContent != null">#{dailyContent},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="deptName != null">#{deptName},</if>
+            <if test="status != null">#{status},</if>
+        </trim>
+    </insert>
+
+    <update id="updateCenterdataTDaily" parameterType="com.ruoyi.system.domain.CenterdataTDaily">
+        update centerdata_t_daily
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="dataStatus != null">data_status = #{dataStatus},</if>
+            <if test="dataDeptId != null">data_dept_id = #{dataDeptId},</if>
+            <if test="dailyType != null">daily_type = #{dailyType},</if>
+            <if test="dailyTime != null">daily_time = #{dailyTime},</if>
+            <if test="dailyTitle != null">daily_title = #{dailyTitle},</if>
+            <if test="dailyContent != null">daily_content = #{dailyContent},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="deptName != null">dept_name = #{deptName},</if>
+            <if test="status != null">status = #{status},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteCenterdataTDailyByIds" parameterType="String">
+        delete from centerdata_t_daily where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 186 - 0
src/main/resources/mapper/data/CenterdataTLeaveMapper.xml

@@ -0,0 +1,186 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CenterdataTLeaveMapper">
+    <resultMap type="com.ruoyi.system.domain.CenterdataTLeave" id="CenterdataTLeaveResult">
+        <result property="id" column="id"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+        <result property="createName" column="create_name"/>
+        <result property="updateName" column="update_name"/>
+        <result property="dataStatus" column="data_status"/>
+        <result property="dataDeptId" column="data_dept_id"/>
+        <result property="leaveStartTime" column="leave_start_time"/>
+        <result property="leaveEndTime" column="leave_end_time"/>
+        <result property="forestLeaveStatus" column="forest_leave_status"/>
+        <result property="leaveMatter" column="leave_matter"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="leaveUserId" column="leave_user_id"/>
+        <result property="leaveUserName" column="leave_user_name"/>
+        <result property="value" column="value"/>
+        <result property="time" column="time"/>
+        <result property="person" column="person"/>
+    </resultMap>
+
+    <resultMap type="com.ruoyi.system.domain.CenterdataTLeaveCount" id="CenterdataTLeaveCountResult">
+        <result property="id" column="id"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+        <result property="createName" column="create_name"/>
+        <result property="updateName" column="update_name"/>
+        <result property="dataStatus" column="data_status"/>
+        <result property="dataDeptId" column="data_dept_id"/>
+        <result property="leaveStartTime" column="leave_start_time"/>
+        <result property="leaveEndTime" column="leave_end_time"/>
+        <result property="forestLeaveStatus" column="forest_leave_status"/>
+        <result property="leaveMatter" column="leave_matter"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="leaveUserId" column="leave_user_id"/>
+        <result property="leaveUserName" column="leave_user_name"/>
+        <result property="value" column="value"/>
+    </resultMap>
+
+    <sql id="selectCenterdataTLeaveVo">
+        select id, create_by, create_time, update_by, update_time, data_status, data_dept_id, leave_start_time, leave_end_time, forest_leave_status, leave_matter, dept_id, dept_name, leave_user_id, leave_user_name,update_name,create_name,person from centerdata_t_leave
+    </sql>
+
+    <select id="listLeaveCount" parameterType="com.ruoyi.system.domain.CenterdataTLeave" resultMap="CenterdataTLeaveCountResult">
+        select a.*,count(a.id) as value from centerdata_t_leave a
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            <if test="time != null ">and leave_start_time like concat( #{time}, '%')</if>
+            ${params.dataScope}
+        </where>
+        group by a.leave_user_id
+        order by a.leave_start_time desc
+    </select>
+
+    <select id="selectCenterdataTLeaveById" parameterType="String" resultMap="CenterdataTLeaveResult">
+        <include refid="selectCenterdataTLeaveVo"/>
+        where id = #{id}
+    </select>
+
+    <insert id="insertCenterdataTLeave" parameterType="com.ruoyi.system.domain.CenterdataTLeave">
+        insert into centerdata_t_leave
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="dataStatus != null">data_status,</if>
+            <if test="dataDeptId != null">data_dept_id,</if>
+            <if test="leaveStartTime != null">leave_start_time,</if>
+            <if test="leaveEndTime != null">leave_end_time,</if>
+            <if test="forestLeaveStatus != null">forest_leave_status,</if>
+            <if test="leaveMatter != null">leave_matter,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="deptName != null">dept_name,</if>
+            <if test="leaveUserId != null">leave_user_id,</if>
+            <if test="leaveUserName != null">leave_user_name,</if>
+            <if test="updateName != null">update_name,</if>
+            <if test="createName != null">create_name,</if>
+            <if test="person != null">person,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="dataStatus != null">#{dataStatus},</if>
+            <if test="dataDeptId != null">#{dataDeptId},</if>
+            <if test="leaveStartTime != null">#{leaveStartTime},</if>
+            <if test="leaveEndTime != null">#{leaveEndTime},</if>
+            <if test="forestLeaveStatus != null">#{forestLeaveStatus},</if>
+            <if test="leaveMatter != null">#{leaveMatter},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="deptName != null">#{deptName},</if>
+            <if test="leaveUserId != null">#{leaveUserId},</if>
+            <if test="leaveUserName != null">#{leaveUserName},</if>
+            <if test="updateName != null">#{updateName},</if>
+            <if test="createName != null">#{createName},</if>
+            <if test="person != null">#{person},</if>
+        </trim>
+    </insert>
+
+    <update id="updateCenterdataTLeave" parameterType="com.ruoyi.system.domain.CenterdataTLeave">
+        update centerdata_t_leave
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="dataStatus != null">data_status = #{dataStatus},</if>
+            <if test="dataDeptId != null">data_dept_id = #{dataDeptId},</if>
+            <if test="leaveStartTime != null">leave_start_time = #{leaveStartTime},</if>
+            <if test="leaveEndTime != null">leave_end_time = #{leaveEndTime},</if>
+            <if test="forestLeaveStatus != null">forest_leave_status = #{forestLeaveStatus},</if>
+            <if test="leaveMatter != null">leave_matter = #{leaveMatter},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="deptName != null">dept_name = #{deptName},</if>
+            <if test="leaveUserId != null">leave_user_id = #{leaveUserId},</if>
+            <if test="leaveUserName != null">leave_user_name = #{leaveUserName},</if>
+            <if test="updateName != null">update_name = #{updateName},</if>
+            <if test="createName != null">create_name = #{createName},</if>
+            <if test="person != null">person = #{perosn},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteCenterdataTLeaveByIds" parameterType="String">
+        delete from centerdata_t_leave where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+
+    <update id="changeStatus"   parameterType="com.ruoyi.system.domain.CenterdataTLeave">
+        update centerdata_t_leave
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="forestLeaveStatus != null">forest_leave_status = #{forestLeaveStatus},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="person != null">person = #{person},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <select id="selectCenterdataTLeaveList" parameterType="com.ruoyi.system.domain.CenterdataTLeave" resultMap="CenterdataTLeaveResult">
+        select a.* from centerdata_t_leave a
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            <if test="dataStatus != null  and dataStatus != ''">and data_status = #{dataStatus}</if>
+            <if test="dataDeptId != null ">and data_dept_id = #{dataDeptId}</if>
+            <if test="leaveStartTime != null ">and leave_start_time &gt;=  #{leaveStartTime}</if>
+            <if test="leaveEndTime != null ">and leave_end_time &lt;=  #{leaveEndTime}</if>
+            <if test="forestLeaveStatus != null  and forestLeaveStatus != ''">and forest_leave_status =
+                #{forestLeaveStatus}
+            </if>
+            <if test="leaveMatter != null  and leaveMatter != ''">and leave_matter = #{leaveMatter}</if>
+            <if test="deptId != null">
+                <choose>
+                    <when test="deptName != null and deptName == 0">
+                        and FIND_IN_SET( #{deptId}, CONCAT( d.ancestors, ",", d.dept_id) )
+                    </when>
+                    <otherwise>and d.dept_id = #{deptId}</otherwise>
+                </choose>
+            </if>
+            <if test="leaveUserId != null ">and leave_user_id = #{leaveUserId}</if>
+            <if test="leaveUserName != null  and leaveUserName != ''">and leave_user_name like concat('%',
+                #{leaveUserName}, '%')
+            </if>
+            <if test="updateName != null ">and update_name = #{updateName}</if>
+            <if test="createName != null ">and create_name = #{createName}</if>
+            ${params.dataScope}
+        </where>
+        order by a.leave_start_time desc
+    </select>
+</mapper>

+ 173 - 0
src/main/resources/mapper/data/CenterdataTRegulationsMapper.xml

@@ -0,0 +1,173 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CenterdataTRegulationsMapper">
+
+    <resultMap type="com.ruoyi.system.domain.CenterdataTRegulations" id="CenterdataTRegulationsResult">
+        <result property="id" column="id"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="createName" column="create_name"/>
+        <result property="updateName" column="update_name"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+        <result property="dataStatus" column="data_status"/>
+        <result property="dataDeptId" column="data_dept_id"/>
+        <result property="regName" column="reg_name"/>
+        <result property="regIntroduction" column="reg_introduction"/>
+        <result property="regOffice" column="reg_office"/>
+        <result property="regNumber" column="reg_number"/>
+        <result property="regTime" column="reg_time"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="attachId" column="attach_id"/>
+        <result property="fileUrl" column="fileUrl"/>
+        <result property="fileName" column="file_name"/>
+        <result property="releaseStatus" column="release_status"/>
+    </resultMap>
+
+    <sql id="selectCenterdataTRegulationsVo">
+        select id, create_by, create_time,create_name,update_name, update_by, update_time, data_status, data_dept_id, reg_name, reg_introduction, reg_office, reg_number, reg_time, dept_id, dept_name, attach_id, release_status from centerdata_t_regulations
+    </sql>
+
+    <select id="selectCenterdataTRegulationsList" parameterType="com.ruoyi.system.domain.CenterdataTRegulations"
+            resultMap="CenterdataTRegulationsResult">
+        select a.*,group_concat(b.attach_path) fileUrl,group_concat(b.file_name) as file_name
+        from centerdata_t_regulations a
+        left join centerdata_t_attach b on b.bus_id = a.attach_id
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            <if test="dataStatus != null  and dataStatus != ''">and data_status = #{dataStatus}</if>
+            <if test="dataDeptId != null ">and data_dept_id = #{dataDeptId}</if>
+            <if test="regName != null  and regName != ''">and reg_name like concat('%', #{regName}, '%')</if>
+            <if test="regIntroduction != null  and regIntroduction != ''">and reg_introduction = #{regIntroduction}</if>
+            <if test="regOffice != null  and regOffice != ''">and reg_office = #{regOffice}</if>
+            <if test="regNumber != null  and regNumber != ''">and reg_number = #{regNumber}</if>
+            <if test="regTime != null ">and reg_time = #{regTime}</if>
+            <if test="deptId != null">
+                <choose>
+                    <when test="deptName != null and deptName == 0">
+                        and FIND_IN_SET( #{deptId}, CONCAT( d.ancestors, ",", d.dept_id) )
+                    </when>
+                    <otherwise>and d.dept_id = #{deptId}</otherwise>
+                </choose>
+            </if>
+            <if test="attachId != null  and attachId != ''">and attach_id = #{attachId}</if>
+            <if test="releaseStatus != null  and releaseStatus != ''">and release_status = #{releaseStatus}</if>
+            ${params.dataScope}
+        </where>
+        group by a.id
+        order by a.create_time desc
+    </select>
+
+    <select id="selectCenterdataTRegulationsById" parameterType="String" resultMap="CenterdataTRegulationsResult">
+        SELECT
+            a.id,
+            a.create_by,
+            a.create_time,
+            a.create_name,
+            a.update_name,
+            a.update_by,
+            a.update_time,
+            a.data_status,
+            a.data_dept_id,
+            a.reg_name,
+            a.reg_introduction,
+            a.reg_office,
+            a.reg_number,
+            a.reg_time,
+            a.dept_id,
+            a.dept_name,
+            a.attach_id,
+            a.release_status,
+            group_concat(CONCAT_WS('+',b.attach_path,b.file_name)) as fileUrl
+        from centerdata_t_regulations a
+                 left join centerdata_t_attach b on a.attach_id = b.bus_id
+        where a.id = #{id}
+        group by b.bus_id
+    </select>
+
+    <insert id="insertCenterdataTRegulations" parameterType="com.ruoyi.system.domain.CenterdataTRegulations">
+        insert into centerdata_t_regulations
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="createName != null">create_name,</if>
+            <if test="updateName != null">update_name,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="dataStatus != null">data_status,</if>
+            <if test="dataDeptId != null">data_dept_id,</if>
+            <if test="regName != null">reg_name,</if>
+            <if test="regIntroduction != null">reg_introduction,</if>
+            <if test="regOffice != null">reg_office,</if>
+            <if test="regNumber != null">reg_number,</if>
+            <if test="regTime != null">reg_time,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="deptName != null">dept_name,</if>
+            <if test="attachId != null">attach_id,</if>
+            <if test="releaseStatus != null">release_status,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="createName != null">#{createName},</if>
+            <if test="updateName != null">#{updateName},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="dataStatus != null">#{dataStatus},</if>
+            <if test="dataDeptId != null">#{dataDeptId},</if>
+            <if test="regName != null">#{regName},</if>
+            <if test="regIntroduction != null">#{regIntroduction},</if>
+            <if test="regOffice != null">#{regOffice},</if>
+            <if test="regNumber != null">#{regNumber},</if>
+            <if test="regTime != null">#{regTime},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="deptName != null">#{deptName},</if>
+            <if test="attachId != null">#{attachId},</if>
+            <if test="releaseStatus != null">#{releaseStatus},</if>
+        </trim>
+    </insert>
+    <update id="updateCenterdataTRegulations" parameterType="com.ruoyi.system.domain.CenterdataTRegulations">
+        update centerdata_t_regulations
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="createName != null">create_name = #{createName},</if>
+            <if test="updateName != null">update_name = #{updateName},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="dataStatus != null">data_status = #{dataStatus},</if>
+            <if test="dataDeptId != null">data_dept_id = #{dataDeptId},</if>
+            <if test="regName != null">reg_name = #{regName},</if>
+            <if test="regIntroduction != null">reg_introduction = #{regIntroduction},</if>
+            <if test="regOffice != null">reg_office = #{regOffice},</if>
+            <if test="regNumber != null">reg_number = #{regNumber},</if>
+            <if test="regTime != null">reg_time = #{regTime},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="deptName != null">dept_name = #{deptName},</if>
+            <if test="attachId != null">attach_id = #{attachId},</if>
+            <if test="releaseStatus != null">release_status = #{releaseStatus},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteCenterdataTRegulationsByIds" parameterType="String">
+        delete from centerdata_t_regulations where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+
+    <update id="handlePublish" parameterType="com.ruoyi.system.domain.CenterdataTRegulations">
+        update centerdata_t_regulations set release_status = #{releaseStatus}
+        where
+        id in
+        <foreach item="id" collection="ids" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </update>
+</mapper>

+ 181 - 0
src/main/resources/mapper/data/CenterdataTReserveMapper.xml

@@ -0,0 +1,181 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CenterdataTReserveMapper">
+
+    <resultMap type="com.ruoyi.system.domain.CenterdataTReserve" id="CenterdataTReserveResult">
+        <result property="id" column="id"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="createName" column="create_name"/>
+        <result property="updateName" column="update_name"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+        <result property="dataStatus" column="data_status"/>
+        <result property="dataDeptId" column="data_dept_id"/>
+        <result property="resTitle" column="res_title"/>
+        <result property="resIntroduction" column="res_introduction"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="attachId" column="attach_id"/>
+        <result property="fileUrl" column="fileUrl"/>
+        <result property="fileName" column="file_name"/>
+        <result property="releaseStatus" column="release_status"/>
+    </resultMap>
+
+    <sql id="selectCenterdataTReserveVo">
+        select id, create_by, create_time,create_name,update_name, update_by, update_time, data_status, data_dept_id, res_title, res_introduction, dept_id, dept_name, attach_id, release_status from centerdata_t_reserve
+    </sql>
+
+    <select id="selectCenterdataTReserveList" parameterType="com.ruoyi.system.domain.CenterdataTReserve" resultMap="CenterdataTReserveResult">
+        select a.*,group_concat(b.attach_path) fileUrl,group_concat(b.file_name) file_name
+        from centerdata_t_reserve a
+        left join centerdata_t_attach b on b.bus_id = a.attach_id
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            <if test="dataStatus != null  and dataStatus != ''">and a.data_status = #{dataStatus}</if>
+            <if test="dataDeptId != null ">and a.data_dept_id = #{dataDeptId}</if>
+            <if test="resTitle != null  and resTitle != ''">and a.res_title like concat('%', #{resTitle}, '%')</if>
+            <if test="resIntroduction != null  and resIntroduction != ''">and a.res_introduction = #{resIntroduction}</if>
+            <if test="deptId != null">
+                <choose>
+                    <when test="deptName != null and deptName == 0">
+                        and FIND_IN_SET( #{deptId}, CONCAT( d.ancestors, ",", d.dept_id) )
+                    </when>
+                    <otherwise>and d.dept_id = #{deptId}</otherwise>
+                </choose>
+            </if>
+            <if test="attachId != null  and attachId != ''">and a.attach_id = #{attachId}</if>
+            <if test="releaseStatus != null  and releaseStatus != ''">and a.release_status = #{releaseStatus}</if>
+            ${params.dataScope}
+        </where>
+        group by a.id
+        order by a.create_time desc
+    </select>
+
+    <select id="selectCenterdataTReserveById" parameterType="String" resultMap="CenterdataTReserveResult">
+        SELECT
+            a.id,
+            a.create_by,
+            a.create_time,
+            a.update_by,
+            a.create_name,
+            a.update_name,
+            a.update_time,
+            a.data_status,
+            a.data_dept_id,
+            a.res_title,
+            a.res_introduction,
+            a.dept_id,
+            a.dept_name,
+            a.attach_id ,
+            a.release_status,
+            b.file_name,
+            group_concat(CONCAT_WS('+',b.attach_path,b.file_name)) as fileUrl
+        from centerdata_t_reserve a
+                 left join centerdata_t_attach b on a.attach_id = b.bus_id
+        where a.id = #{id}
+    </select>
+
+    <insert id="insertCenterdataTReserve" parameterType="com.ruoyi.system.domain.CenterdataTReserve">
+        insert into centerdata_t_reserve
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="createName != null">create_name,</if>
+            <if test="updateName != null">update_name,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="dataStatus != null">data_status,</if>
+            <if test="dataDeptId != null">data_dept_id,</if>
+            <if test="resTitle != null">res_title,</if>
+            <if test="resIntroduction != null">res_introduction,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="deptName != null">dept_name,</if>
+            <if test="attachId != null">attach_id,</if>
+            <if test="releaseStatus != null">release_status</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="createName != null">#{createName},</if>
+            <if test="updateName != null">#{updateName},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="dataStatus != null">#{dataStatus},</if>
+            <if test="dataDeptId != null">#{dataDeptId},</if>
+            <if test="resTitle != null">#{resTitle},</if>
+            <if test="resIntroduction != null">#{resIntroduction},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="deptName != null">#{deptName},</if>
+            <if test="attachId != null">#{attachId},</if>
+            <if test="releaseStatus != null">#{releaseStatus}</if>
+        </trim>
+    </insert>
+
+    <update id="updateCenterdataTReserve" parameterType="com.ruoyi.system.domain.CenterdataTReserve">
+        update centerdata_t_reserve
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="createName != null">create_name = #{createName},</if>
+            <if test="updateName != null">update_name = #{updateName},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="dataStatus != null">data_status = #{dataStatus},</if>
+            <if test="dataDeptId != null">data_dept_id = #{dataDeptId},</if>
+            <if test="resTitle != null">res_title = #{resTitle},</if>
+            <if test="resIntroduction != null">res_introduction = #{resIntroduction},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="deptName != null">dept_name = #{deptName},</if>
+            <if test="attachId != null">attach_id = #{attachId},</if>
+            <if test="releaseStatus != null">release_status = #{releaseStatus},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteCenterdataTReserveByIds" parameterType="String">
+        delete from centerdata_t_reserve where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+
+
+    <select id="listCenterdataTReserve" resultMap="CenterdataTReserveResult">
+        select * from centerdata_t_reserve
+    </select>
+
+    <select id="selectCenterdataTReserveListRemoteCall" parameterType="com.ruoyi.system.domain.CenterdataTReserve" resultMap="CenterdataTReserveResult">
+        select a.*,group_concat(b.attach_path) fileUrl,group_concat(b.file_name) file_name
+        from centerdata_t_reserve a
+        left join centerdata_t_attach b on b.bus_id = a.attach_id
+        left join ${database_system}.sys_dept d ON d.dept_id = a.dept_id
+        <where>
+            and a.release_status = 'centerdata_release_status_yes'
+            <if test="dataStatus != null  and dataStatus != ''">and a.data_status = #{dataStatus}</if>
+            <if test="dataDeptId != null ">and a.data_dept_id = #{dataDeptId}</if>
+            <if test="resTitle != null  and resTitle != ''">and a.res_title like concat('%', #{resTitle}, '%')</if>
+            <if test="resIntroduction != null  and resIntroduction != ''">and a.res_introduction = #{resIntroduction}</if>
+            <if test="deptId != null ">and a.dept_id = #{deptId}</if>
+            <if test="deptName != null  and deptName != ''">and a.dept_name like concat('%', #{deptName}, '%')</if>
+            <if test="attachId != null  and attachId != ''">and a.attach_id = #{attachId}</if>
+            ${params.dataScope}
+        </where>
+        group by a.id
+        order by a.create_time desc
+    </select>
+
+
+    <update id="handlePublish" parameterType="com.ruoyi.system.domain.CenterdataTReserve">
+        update centerdata_t_reserve set release_status = #{releaseStatus}
+        where
+        id in
+        <foreach item="id" collection="ids" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </update>
+</mapper>

+ 55 - 0
system_ui/src/api/data/communication/communication.js

@@ -0,0 +1,55 @@
+import request from '@/utils/request'
+
+// 查询通讯录列表
+export function listCommunication(query) {
+  return request({
+    url: '/system/communication/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询通讯录详细
+export function getCommunication(id) {
+  return request({
+    url: '/system/communication/' + id,
+    method: 'get'
+  })
+}
+
+// 新增通讯录
+export function addCommunication(data) {
+  return request({
+    url: '/system/communication',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改通讯录
+export function updateCommunication(data) {
+  return request({
+    url: '/system/communication',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除通讯录
+export function delCommunication(id) {
+  return request({
+    url: '/system/communication/' + id,
+    method: 'delete'
+  })
+}
+
+export function updateRelease(ids, releaseStatus){
+  return request({
+    url: 'system/communication/handlePublish',
+    method:'post',
+    data: {
+      "ids": ids,
+      "releaseStatus": releaseStatus
+    }
+  })
+}

+ 44 - 0
system_ui/src/api/data/daily/daily.js

@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 查询日报列表
+export function listDaily(query) {
+  return request({
+    url: '/system/daily/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询日报详细
+export function getDaily(id) {
+  return request({
+    url: '/system/daily/' + id,
+    method: 'get'
+  })
+}
+
+// 新增日报
+export function addDaily(data) {
+  return request({
+    url: '/system/daily',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改日报
+export function updateDaily(data) {
+  return request({
+    url: '/system/daily',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除日报
+export function delDaily(id) {
+  return request({
+    url: '/system/daily/' + id,
+    method: 'delete'
+  })
+}

+ 64 - 0
system_ui/src/api/data/leave/leave.js

@@ -0,0 +1,64 @@
+import request from '@/utils/request'
+
+// 查询请假列表
+export function listLeave(query) {
+  return request({
+    url: '/sooka-sponest-system/leave/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询请假详细
+export function getLeave(id) {
+  return request({
+    url: '/sooka-sponest-system/leave/' + id,
+    method: 'get'
+  })
+}
+
+// 新增请假
+export function addLeave(data) {
+  return request({
+    url: '/sooka-sponest-system/leave',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改请假
+export function updateLeave(data) {
+  return request({
+    url: '/sooka-sponest-system/leave',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除请假
+export function delLeave(id) {
+  return request({
+    url: '/sooka-sponest-system/leave/' + id,
+    method: 'delete'
+  })
+}
+export function changeStatus(id,forestLeaveStatus) {
+  return request({
+    url: '/sooka-sponest-system/leave/change',
+    method: 'put',
+    data:{
+      "id": id,
+      "forestLeaveStatus":forestLeaveStatus
+    }
+  })
+}
+
+export function listLeaveCount(query) {
+  return request({
+    url: '/sooka-sponest-system/leave/leaveList',
+    method: 'get',
+    params: query
+  })
+}
+
+

+ 60 - 0
system_ui/src/api/data/leave/linleader.js

@@ -0,0 +1,60 @@
+import request from '@/utils/request';
+
+// 查询林长管理列表
+export function listLinleader(query) {
+  return request({
+    url: '/sooka-sponest-center-data/linleader/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询林长管理详细
+export function getLinleader(id) {
+  return request({
+    url: '/sooka-sponest-center-data/linleader/' + id,
+    method: 'get'
+  })
+}
+
+// 新增林长管理
+export function addLinleader(data) {
+  return request({
+    url: '/sooka-sponest-center-data/linleader',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改林长管理
+export function updateLinleader(data) {
+  return request({
+    url: '/sooka-sponest-center-data/linleader',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除林长管理
+export function delLinleader(id) {
+  return request({
+    url: '/sooka-sponest-center-data/linleader/' + id,
+    method: 'delete'
+  })
+}
+
+export function listAllGrid(data) {
+  return request({
+    url: '/sooka-sponest-center-data/grid/listAll',
+    method: 'post',
+    data: data
+  })
+}
+
+export function selectUserList() {
+  return request({
+    url: '/sooka-sponest-system/user/userFeginlist',
+    method: 'post',
+    data:{}
+  })
+}

+ 55 - 0
system_ui/src/api/data/regulations/regulations.js

@@ -0,0 +1,55 @@
+import request from '@/utils/request'
+
+// 查询政策法规列表
+export function listRegulations(query) {
+  return request({
+    url: '/system/regulations/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询政策法规详细
+export function getRegulations(id) {
+  return request({
+    url: '/system/regulations/' + id,
+    method: 'get'
+  })
+}
+
+// 新增政策法规
+export function addRegulations(data) {
+  return request({
+    url: '/system/regulations',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改政策法规
+export function updateRegulations(data) {
+  return request({
+    url: '/system/regulations',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除政策法规
+export function delRegulations(id) {
+  return request({
+    url: '/system/regulations/' + id,
+    method: 'delete'
+  })
+}
+
+export function updateRelease(ids, releaseStatus){
+  return request({
+    url: 'system/regulations/handlePublish',
+    method:'post',
+    data: {
+      "ids": ids,
+      "releaseStatus": releaseStatus
+    }
+  })
+}

+ 55 - 0
system_ui/src/api/data/reserve/reserve.js

@@ -0,0 +1,55 @@
+import request from '@/utils/request'
+
+// 查询应急预案列表
+export function listReserve(query) {
+  return request({
+    url: '/system/reserve/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询应急预案详细
+export function getReserve(id) {
+  return request({
+    url: '/system/reserve/' + id,
+    method: 'get'
+  })
+}
+
+// 新增应急预案
+export function addReserve(data) {
+  return request({
+    url: '/system/reserve',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改应急预案
+export function updateReserve(data) {
+  return request({
+    url: '/system/reserve',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除应急预案
+export function delReserve(id) {
+  return request({
+    url: '/system/reserve/' + id,
+    method: 'delete'
+  })
+}
+
+export function updateRelease(ids, releaseStatus){
+  return request({
+    url: 'system/reserve/handlePublish',
+    method:'post',
+    data: {
+      "ids": ids,
+      "releaseStatus": releaseStatus
+    }
+  })
+}

+ 248 - 0
system_ui/src/api/rules/rules.js

@@ -0,0 +1,248 @@
+/**
+ * 验证非负整数(包含0及正整数)
+ * @param {*} rule
+ * @param {*} value
+ * @param {*} callback
+ */
+export function checkNonnegativeInteger(rule, value, callback) {
+  if (value) {
+    value += ''
+    if(/(^(0|[1-9][0-9]*)$)/.test(value)) {
+      callback()
+    } else {
+      callback(new Error('只能输入数字,数值不能为负,且不能为小数'))
+    }
+  } else {
+    callback()
+  }
+}
+
+/**
+ * 验证正整数(不包含0的正整数)
+ * @param {*} rule
+ * @param {*} value
+ * @param {*} callback
+ */
+export function checkPositiveInteger(rule, value, callback) {
+  if (value) {
+    value += ''
+    if(/(^[1-9]\d*$)/.test(value)) {
+      callback()
+    } else {
+      callback(new Error('只能输入数字,数值不能为负数或0,且不能为小数'))
+    }
+  } else {
+    callback()
+  }
+}
+
+/**
+ * 验证正数,且小数可2位(包含0及正整数)
+ * @param {*} rule
+ * @param {*} value
+ * @param {*} callback
+ */
+export function checkPositiveDecimal(rule, value, callback) {
+  if (value) {
+    value += ''
+    // if(/(^[1-9]([0-9]+)?(\.[0-9]{1,4})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/.test(value)) {
+    // if(/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9])?$)/.test(value)) {
+    if(/(^[1-9]([0-9]+)?(\.[0-9]{1,2})?$)|(^(0){1}$)|(^[0-9]\.[0-9]{1,2}$)/.test(value)) {
+      callback()
+    } else {
+      callback(new Error('只能输入数字,且数值不能为负,小数限2位'))
+    }
+  } else {
+    callback()
+  }
+}
+/**
+ * 验证正数,且小数可4位(包含0及正整数)
+ * @param {*} rule
+ * @param {*} value
+ * @param {*} callback
+ */
+export function checkPositiveDecimal4(rule, value, callback) {
+  if (value) {
+    value += ''
+    // if(/(^[1-9]([0-9]+)?(\.[0-9]{1,4})?$)|(^(0){1}$)|(^[0-9]\.[0-9]([0-9]){0,3}$)/.test(value)) {
+    if(/(^[1-9]([0-9]+)?(\.[0-9]{1,4})?$)|(^(0){1}$)|(^[0-9]\.[0-9]{1,4}$)/.test(value)) {
+      callback()
+    } else {
+      callback(new Error('只能输入数字,且数值不能为负,小数限4位'))
+    }
+  } else {
+    callback()
+  }
+}
+/**
+ * 验证手机号,座机号
+ * @param {*} rule
+ * @param {*} value
+ * @param {*} callback
+ */
+export function validPhoneMobile(rule, value, callback){
+  if (value){
+    if (value === '') {
+      callback(new Error('请输入11位手机号'));
+    } else {
+      let regPone = null;
+      let mobile = /^1(3|4|5|6|7|8|9)\d{9}$/; //最新16手机正则
+      let tel = /^(0\d{2,3}-){0,1}\d{7,8}$/; //座机
+      if (value.charAt(0) == 0) {    // charAt查找第一个字符方法,用来判断输入的是座机还是手机号
+        regPone = tel;
+      } else {
+        regPone = mobile;
+      }
+      if (!regPone.test(value)) {
+        callback(new Error("请填写11位手机号或座机号(座机格式为 区号-座机号码)"))
+      }
+      callback();
+    }
+  }else {
+    callback();
+  }
+}
+
+/**
+ * 验证经度输入范围在-180-180之间,且小数可15位
+ * @param {*} rule
+ * @param {*} value
+ * @param {*} callback
+ */
+export function checkLon(rule, value, callback) {
+  if (value) {
+    value += ''
+    if (value.match(/^(\-|\+)?(((\d|[1-9]\d|1[0-7]\d|0{1,3})\.\d{0,15})|(\d|[1-9]\d|1[0-7]\d|0{1,3})|180\.0{0,6}|180)$/)) {
+      callback()
+    } else {
+      callback(new Error('经度为-180~180,小数限15位'))
+    }
+  } else {
+    callback()
+  }
+}
+/**
+ * 验证纬度输入范围在-90~90之间,且小数可15位
+ * @param {*} rule
+ * @param {*} value
+ * @param {*} callback
+ */
+export function checkLat(rule, value, callback) {
+  if (value) {
+    value += ''
+    if (value.match(/^(\-|\+)?([0-8]?\d{1}\.\d{0,15}|90\.0{0,6}|[0-8]?\d{1}|90)$/)) {
+      callback()
+    } else {
+      callback(new Error('纬度为-90~90,小数限15位'))
+    }
+  } else {
+    callback()
+  }
+}
+
+/**
+ * 温度校验
+ * @param rule
+ * @param value
+ * @param callback
+ */
+export function checkTemperature(rule, value, callback) {
+  if (value !== '') {
+    // 判断温度是否为数字
+    if (!/^-?\d+(\.\d+)?$/.test(value)) {
+      callback(new Error('温度值必须为数字'))
+    } else {
+      // 将温度转换为数字类型,方便后续比较大小
+      const num = Number(value)
+
+      // 判断温度的范围是否在 -50 到 50 之间
+      if (num < -50 || num > 50) {
+        callback(new Error('温度范围必须在-50℃ ~ 50℃之间'))
+      } else {
+        // 判断小数部分是否超过一位
+        const reg = /(?:\.)(\d+)/
+        let match = value.match(reg)
+        if (match && match[1].length > 1) {
+          callback(new Error('小数部分只能保留一位'))
+        }
+        // 判断整数部分是否超过两位,且第一位是否为0
+        match = value.match(/^-?(\d+)/)
+        if (match && (match[1].length > 2 || (match[1].length === 2 && match[1][0] === '0'))) {
+          callback(new Error('整数部分长度不能超过2位,且第一位不能是0'))
+        } else {
+          callback()
+        }
+      }
+    }
+  } else {
+    callback(new Error('温度值不能为空'))
+  }
+}
+
+/**
+ * 车牌号校验(含新能源)
+ * @param rule
+ * @param value
+ * @param callback
+ */
+export function carPhoneValid (rule, value, callback) {
+  const plateNumber = /^([京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领A-Z]{1}[A-Z]{1}(([0-9]{5}[DF])|([DF]([A-HJ-NP-Z0-9])[0-9]{4})))|([京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领A-Z]{1}[A-Z]{1}[A-HJ-NP-Z0-9]{4}([A-HJ-NP-Z0-9挂学警港澳]{1}|[应急]{2}))$/
+  if (plateNumber.test(value)) {
+    callback()
+  } else {
+    callback(new Error('请输入正确的车牌号'))
+  }
+}
+
+/**
+ * 英文和数字校验
+ * @param rule
+ * @param value
+ * @param callback
+ */
+export function englishAndNumValid(rule, value, callback) {
+  if (value) {
+    value += ''
+    if (value.match(/^[A-Za-z0-9]{4,40}$/)) {
+      callback()
+    } else {
+      callback(new Error('只能输入英文和数字'))
+    }
+  } else {
+    callback()
+  }
+}
+/**
+ * 英文和数字校验18位
+ * @param rule
+ * @param value
+ * @param callback
+ */
+export function englishAndshibaNumValid(rule, value, callback) {
+  if (value) {
+    value += ''
+    if (value.match(/^[A-Za-z0-9]{0,18}$/)) {
+      callback()
+    } else {
+      callback(new Error('只能输入0~18位英文和数字'))
+    }
+  } else {
+    callback()
+  }
+}
+
+export function englishOnly(rule, value, callback) {
+  if (value) {
+    value += ''
+    if (value.match(/^[a-zA-Z]{2,40}$/)) {
+      callback()
+    } else {
+      callback(new Error('请输入英文,且至少两个字符'))
+    }
+  } else {
+    callback()
+  }
+}
+
+

+ 263 - 0
system_ui/src/views/components/FileUpload/index.vue

@@ -0,0 +1,263 @@
+<template>
+  <div class="upload-file">
+    <el-upload
+      multiple
+      :action="uploadFileUrl"
+      :before-upload="handleBeforeUpload"
+      :file-list="fileList"
+      :limit="limit"
+      :on-error="handleUploadError"
+      :on-exceed="handleExceed"
+      :on-success="handleUploadSuccess"
+      :show-file-list="false"
+      :headers="headers"
+      class="upload-file-uploader"
+      ref="upload"
+    >
+      <!-- 上传按钮 -->
+      <el-button size="mini" type="primary">选取文件</el-button>
+      <!-- 上传提示 -->
+      <div class="el-upload__tip" slot="tip" v-if="showTip">
+        请上传
+        <template v-if="fileSize"> 大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b></template>
+        <template v-if="fileType"> 格式为 <b style="color: #f56c6c">{{ fileType.join("/") }}</b></template>
+        的文件
+      </div>
+    </el-upload>
+
+    <!-- 文件列表 -->
+    <transition-group class="upload-file-list el-upload-list el-upload-list--text" name="el-fade-in-linear" tag="ul">
+      <li :key="file.url" class="el-upload-list__item ele-upload-list__item-content" v-for="(file, index) in fileList">
+        <el-link :href="file.url" :underline="false" target="_blank">
+          <span class="el-icon-document"> {{ file.name }} </span>
+        </el-link>
+        <div class="ele-upload-list__item-content-action">
+          <el-link :underline="false" @click="handleDelete(index)" type="danger">删除</el-link>
+        </div>
+      </li>
+    </transition-group>
+  </div>
+</template>
+
+<script>
+import {getToken} from "@/utils/auth";
+import {getConfigKey} from "@/api/system/config";
+
+export default {
+  name: "FileUpload",
+  props: {
+    setFileName: Function,
+    removeFileName: Function,
+    // 值
+    value: [String, Object, Array],
+    // 数量限制
+    limit: {
+      type: Number,
+      default: 50,
+    },
+    // 大小限制(MB)
+    fileSize: {
+      type: Number,
+      default: 50,
+    },
+    // 文件类型, 例如['png', 'jpg', 'jpeg']
+    fileType: {
+      type: Array,
+      default: () => ["doc", "xls", "ppt", "txt", "pdf"],
+    },
+    // 是否显示提示
+    isShowTip: {
+      type: Boolean,
+      default: true
+    }
+  },
+  data() {
+    return {
+      number: 0,
+      uploadList: [],
+      uploadFileUrl: process.env.VUE_APP_BASE_API + "/file/upload", // 上传的图片服务器地址
+      headers: {
+        Authorization: "Bearer " + getToken(),
+      },
+      fileList: [],
+      prefix : "",
+    };
+  },
+  watch: {
+    value: {
+      handler(val) {
+        if (val) {
+
+          if (this.value == ',' || this.value.indexOf("http") == -1 || this.value.indexOf("+") == -1) {
+            return
+          } else {
+            let values = this.value.split(",")
+            for (var i = 0; i < values.length; i++) {
+              if (values[i].indexOf("http") == -1) {
+                return
+
+              }
+
+            }
+
+
+          }
+
+          this.fileList = []
+          let temp = 1;
+          // 首先将值转为数组
+          const list = this.value.split(',');
+
+          var item1
+          for (var a = 0; a < list.length; a++) {
+            let listurl = list[a].split('+')
+            item1 = {name: listurl[1], url: listurl[0]};
+            this.fileList.push(item1)
+
+          }
+
+          return this.fileList
+          // // 然后将数组转为对象数组
+          //  this.fileList = list.map(item => {
+          //      if (typeof item === "string") {
+          //          item = {name: item, url: item};
+          //      }
+          //      // item.uid = item.uid || new Date().getTime() + temp++;
+          //      return item;
+          //  });
+        } else {
+          this.fileList = [];
+          return [];
+        }
+      },
+      deep: true,
+      immediate: true
+    }
+  },
+  computed: {
+    // 是否显示提示
+    showTip() {
+      return this.isShowTip && (this.fileType || this.fileSize);
+    },
+  },
+  created() {
+    getConfigKey("downloadUrl").then(response => {
+      this.prefix = response.msg;
+    });
+  },
+  methods: {
+
+
+    // 上传前校检格式和大小
+    handleBeforeUpload(file) {
+      // 校检文件类型
+      if (this.fileType) {
+        let fileExtension = "";
+        if (file.name.lastIndexOf(".") > -1) {
+          fileExtension = file.name.slice(file.name.lastIndexOf(".") + 1);
+        }
+        const isTypeOk = this.fileType.some((type) => {
+          if (file.type.indexOf(type) > -1) return true;
+          if (fileExtension && fileExtension.indexOf(type) > -1) return true;
+          return false;
+        });
+        if (!isTypeOk) {
+          this.$modal.msgError(`文件格式不正确, 请上传${this.fileType.join("/")}格式文件!`);
+          return false;
+        }
+      }
+      // 校检文件大小
+      if (this.fileSize) {
+        const isLt = file.size / 1024 / 1024 < this.fileSize;
+        if (!isLt) {
+          this.$modal.msgError(`上传文件大小不能超过 ${this.fileSize} MB!`);
+          return false;
+        }
+      }
+      if (file.name){
+        const isName = file.name;
+        if (isName.indexOf("+") != -1){
+          this.$modal.msgError(`上传文件的文件名中不能包含'+'!`);
+          return false;
+        }
+      }
+      this.$modal.loading("正在上传文件,请稍候...");
+      this.number++;
+      return true;
+    },
+    // 文件个数超出
+    handleExceed() {
+      this.$modal.msgError(`上传文件数量不能超过 ${this.limit} 个!`);
+    },
+    // 上传失败
+    handleUploadError(err) {
+      this.$modal.msgError("上传图片失败,请重试");
+      this.$modal.closeLoading()
+    },
+    // 上传成功回调
+    handleUploadSuccess(res) {
+      let num = res.data.url.indexOf('/');
+      let start = res.data.url.substring(0,num);
+      let end = res.data.url.substring(num+1,res.data.url.length);
+      let url = this.prefix +"Download?fileName="+res.data.webName +"&&group="+ start +"&&path=" + end;
+      this.uploadList.push({name: res.data.webName, url:url, webName: res.data.webName});
+      if (this.uploadList.length === this.number) {
+        this.fileList = this.fileList.concat(this.uploadList);
+        this.uploadList = [];
+        this.number = 0;
+        this.$emit("input", this.listToString(this.fileList));
+        console.log("ppo", this.fileList)
+        this.$modal.closeLoading();
+      }
+      this.setFileName(res.data.webName)
+    },
+    // 删除文件
+    handleDelete(index) {
+      this.fileList.splice(index, 1);
+      this.removeFileName(index)
+      // this.$emit("input", this.listToString(this.fileList));
+    },
+    // 获取文件名称
+    getFileName(name) {
+      if (name.lastIndexOf("/") > -1) {
+        return name.slice(name.lastIndexOf("/") + 1);
+      } else {
+        return "";
+      }
+    },
+    // 对象转成指定字符串分隔
+    listToString(list, separator) {
+      let strs = "";
+      separator = separator || ",";
+      for (let i in list) {
+        strs += list[i].url + separator;
+      }
+      return strs != '' ? strs.substr(0, strs.length - 1) : '';
+    }
+  }
+};
+</script>
+
+<style scoped lang="scss">
+.upload-file-uploader {
+  margin-bottom: 5px;
+}
+
+.upload-file-list .el-upload-list__item {
+  border: 1px solid #e4e7ed;
+  line-height: 2;
+  margin-bottom: 10px;
+  position: relative;
+}
+
+.upload-file-list .ele-upload-list__item-content {
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  color: inherit;
+}
+
+.ele-upload-list__item-content-action .el-link {
+  margin-right: 10px;
+}
+</style>

+ 100 - 0
system_ui/src/views/components/deptselector.vue

@@ -0,0 +1,100 @@
+<template>
+  <div>
+    <el-select id="deptSelector" v-model="selectValueProp" placeholder="请选择" @change="mychange">
+      <el-option :key="index" :value="dept" :label="dept.deptName" v-for="(dept,index) in selectList">
+      </el-option>
+    </el-select>
+  </div>
+</template>
+
+<script>
+import { getDepts } from '@/api/components/deptselector.js'
+// import { setToken } from '../plugins/auth'
+import Cookies from 'js-cookie'
+
+export default {
+  name: 'deptSelector',
+  props: {
+    setValue: Function,
+    dataDeptId :null
+  },
+  watch: {
+    dataDeptId(oldValue,newValue){
+      if(newValue!=null&&newValue!="null"){
+        this.showDepts(oldValue);
+      }
+    }
+  },
+  created() {
+    this.showDepts("");
+  },
+  data() {
+    return {
+      selectDeptCookieKey: 'Global-Dept',
+      selectValueProp: '',
+      selectList: []
+    }
+  },
+  methods: {
+    mychange: function(item) {
+      this.selectValueProp=item.deptName
+      if(this.setValue != undefined){
+        this.setValue(item)
+      }
+    },
+    showDepts(oldValue) {
+      const username = Cookies.get('username');
+      let _this = this
+      getDepts({ userName: username }).then(resp => {
+        let deptList = new Array()
+        deptList.push({deptId:"",deptName:"--请选择--"})
+        if(oldValue==""||oldValue==null){
+          _this.selectValueProp = "--请选择--"
+        }
+        let depts = resp.data.depts
+        let deptParties = resp.data.deptParties
+        for (let i = 0; i < depts.length; i++) {
+          let dept = new Object()
+          dept.deptId = depts[i].deptId
+          dept.deptName = depts[i].deptName
+          deptList.push(dept)
+        }
+        for (let i = 0; i < deptParties.length; i++) {
+          let dept = new Object()
+          dept.deptId = deptParties[i].deptId
+          dept.deptName = deptParties[i].deptName
+          deptList.push(dept)
+        }
+        _this.selectList = deptList
+        if (deptList.length == 0) {//当前用户没有部门
+          //alert("当前用户没有部门")
+          return
+        }
+        if (_this.dataDeptId != null) {
+          let isCookieExists = false
+          deptList.forEach((dept) => {
+            if (_this.dataDeptId == dept.deptId) {
+              isCookieExists = true
+              _this.selectValueProp = dept.deptName
+              _this.setValue(dept)
+            }
+          })
+          if (isCookieExists == false) {//cookie存在但当前不在那个部门了
+            _this.selectValueProp = deptList[0].deptName
+            _this.setValue(deptList[0])
+          }
+        } else {
+          _this.selectValueProp = deptList[0].deptName
+          if(_this.setValue != undefined){
+            _this.setValue(deptList[0])
+          }
+        }
+      })
+    }
+  }
+}
+</script>
+
+<style scoped>
+
+</style>

+ 431 - 0
system_ui/src/views/data/communication/index.vue

@@ -0,0 +1,431 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"  @submit.native.prevent>
+      <el-form-item label="姓名" prop="name">
+        <el-input
+          v-model="queryParams.name"
+          placeholder="请输入姓名"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="手机" prop="mobile">
+        <el-input
+          v-model="queryParams.mobile"
+          placeholder="请输入手机"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item prop="deptId">
+        <template slot="label">
+          <span @click="changeQueryType" v-if="queryParams.deptName == 0">本级及下级</span>
+          <span @click="changeQueryType" v-if="queryParams.deptName == 1">只查询本级</span>
+        </template>
+        <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
+                    placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
+        <el-input v-model="queryParams.deptName" v-if="false"/>
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['communication:communication:add']"
+        >新增
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['communication:communication:edit']"
+        >修改
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['communication:communication:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['communication:communication:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="communicationList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center"/>
+      <!-- <el-table-column label="主键id" align="center" prop="id" />
+       <el-table-column label="创建人姓名" align="center" prop="createName" />
+       <el-table-column label="更新人姓名" align="center" prop="updateName" />
+       <el-table-column label="数据状态(1-可用 2-不可用 )" align="center" prop="dataStatus" />
+       <el-table-column label="数据所属部门(政或党的id)" align="center" prop="dataDeptId" />-->
+      <el-table-column label="姓名" align="center" prop="name"/>
+      <!--<el-table-column label="性别" align="center" prop="sex"/>-->
+      <el-table-column label="电话" align="center" prop="phone"/>
+      <el-table-column label="手机" align="center" prop="mobile"/>
+      <el-table-column label="地址" align="center" prop="address"/>
+      <el-table-column label="拼音首字母" align="center" prop="firstLetter"/>
+      <el-table-column label="拼音全拼" align="center" prop="pinyin"/>
+      <el-table-column label="所属部门" align="center" prop="deptName"/>
+      <el-table-column label="发布状态" align="center" prop="varieties">
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.centerdata_release_status" :value="scope.row.releaseStatus"/>
+        </template>
+      </el-table-column>
+      <el-table-column label="创建人" align="center" prop="createName"/>
+      <el-table-column label="创建时间" align="center" prop="createTime"/>
+      <el-table-column label="修改人" align="center" prop="updateName"/>
+      <el-table-column label="修改时间" align="center" prop="updateTime"/>
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['communication:communication:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['communication:communication:remove']"
+          >删除
+          </el-button>
+          <el-button v-if="scope.row.releaseStatus == 'centerdata_release_status_yes'" size="mini" type="text" icon="el-icon-refresh-left" @click="handlePublish(scope.row)" v-hasPermi="['system:reserve:edit']">
+            撤销
+          </el-button>
+          <el-button v-else-if="scope.row.releaseStatus == 'centerdata_release_status_no'" size="mini" type="text" icon="el-icon-upload" @click="handlePublish(scope.row)" v-hasPermi="['system:reserve:edit']">
+            发布
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改通讯录对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="800px" class="form-style">
+      <el-form ref="form" :model="form" :rules="rules" label-width="100px">
+        <el-row>
+          <el-col :span="12">
+            <!-- <el-form-item label="所属部门" prop="deptId">
+               <deptselector :setValue=setDataDeptId :dataDeptId="form.deptId" :disabled="true"></deptselector>
+             </el-form-item>-->
+            <!--<el-form-item label="所属部门" prop="deptId">
+              <treeselect v-model="form.deptId" :options="deptOptions" multiple:false :show-count="true"
+                          placeholder="请选择部门" @select="hx"/>
+            </el-form-item>-->
+            <el-form-item label="所属部门" prop="deptId">
+              <treeselect v-model="form.deptId" :options="deptOptions" multiple:false :show-count="true"
+                          placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'"/>
+            </el-form-item>
+            <el-form-item label="手机" prop="mobile">
+              <el-input v-model="form.mobile" placeholder="请输入手机"  maxlength="13"/>
+            </el-form-item>
+            <el-form-item label="地址" prop="address">
+              <el-input v-model="form.address" placeholder="请输入地址" maxlength="50"/>
+            </el-form-item>
+            <el-form-item label="拼音全拼" prop="pinyin">
+              <el-input v-model="form.pinyin" placeholder="请输入拼音全拼" maxlength="40"/>
+            </el-form-item>
+          </el-col>
+
+          <el-col :span="12">
+            <el-form-item label="姓名" prop="name">
+              <el-input v-model="form.name" placeholder="请输入姓名" maxlength="20"/>
+            </el-form-item>
+            <el-form-item label="电话" prop="phone">
+              <el-input v-model="form.phone" placeholder="请输入电话"   maxlength="13"/>
+            </el-form-item>
+            <el-form-item label="拼音首字母" prop="firstLetter">
+              <el-input v-model="form.firstLetter" placeholder="请输入拼音首字母" maxlength="10"/>
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addCommunication,
+  delCommunication,
+  getCommunication,
+  listCommunication,
+  updateCommunication,
+  updateRelease
+} from "@/api/data/communication/communication";
+import deptselector from '@/views/components/deptselector.vue'
+import {englishOnly, validPhoneMobile} from "@/api/rules/rules";
+import {treeselect} from "@/api/system/dept";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+
+export default {
+  name: "Communication",
+  components: {deptselector,Treeselect},
+  dicts: ["centerdata_release_status"],
+  data() {
+    return {
+      deptOptions: [],
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 通讯录表格数据
+      communicationList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        createName: null,
+        updateName: null,
+        dataStatus: null,
+        dataDeptId: null,
+        releaseStatus: null,
+        name: null,
+        sex: null,
+        phone: null,
+        deptId: null,
+        deptName: 0,
+        mobile: null,
+        address: null,
+        firstLetter: null,
+        pinyin: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        deptId: [
+          {required: true, message: '所属部门不能为空', trigger: 'change'},
+        ],
+        name: [
+          {required: true, message: "姓名不能为空", trigger: "blur"}
+        ],
+        phone: [
+          {validator: validPhoneMobile, trigger: 'blur'}
+        ],
+        mobile: [
+          {required: true, message: "手机不能为空", trigger: "change"},
+          {validator: validPhoneMobile, trigger: 'blur'}
+        ],
+        pinyin: [
+          {validator: englishOnly, trigger: 'blur'}
+        ],
+        firstLetter: [
+          {validator: englishOnly, trigger: 'blur'}
+        ]
+      }
+    };
+  },
+  created() {
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data
+      })
+    },
+    hx(node) {
+
+      this.form.deptId = node.id
+      this.form.deptName = node.label
+    },
+    setDataDeptId(e) {
+      this.form.deptId = e.deptId
+      this.form.deptName = e.deptName
+    },
+    /** 查询通讯录列表 */
+    getList() {
+      this.loading = true;
+      listCommunication(this.queryParams).then(response => {
+        this.communicationList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        createBy: null,
+        createName: null,
+        createTime: null,
+        updateBy: null,
+        updateName: null,
+        updateTime: null,
+        dataStatus: "0",
+        deptId: null,
+        deptName: null,
+        name: null,
+        sex: null,
+        phone: null,
+        mobile: null,
+        address: null,
+        firstLetter: null,
+        pinyin: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.deptName = 0;
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length !== 1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加通讯录";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getCommunication(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改通讯录";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateCommunication(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            this.form.releaseStatus = "centerdata_release_status_no";
+            addCommunication(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否删除选中的数据?').then(function () {
+        return delCommunication(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {
+      });
+    },
+    handlePublish(row){
+      let ids = row.id || this.ids;
+      let status = "发布", releaseStatus = "centerdata_release_status_yes";
+      if(!ids.includes(",")) {
+        ids = [ids];
+        if (row.releaseStatus.includes("centerdata_release_status_yes")) {
+          status = "撤销";
+          releaseStatus = "centerdata_release_status_no";
+        }
+        this.$modal.confirm('是否' + status + '选中的数据?').then(function () {
+          return updateRelease(ids, releaseStatus);
+        }).then(() => {
+          this.getList();
+          this.$modal.msgSuccess(status + "成功");
+        }).catch((e) => {
+          console.log(e)
+        });
+      }
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('sooka-sponest-center-data/communication/export', {
+        ...this.queryParams
+      }, `通讯录_${new Date().getTime()}.xlsx`)
+    },
+    // 点击按钮修改是否只查询本级部门用户
+    changeQueryType() {
+      this.queryParams.deptName = this.queryParams.deptName == 0 ? 1 : 0;
+    }
+  }
+};
+</script>

+ 326 - 0
system_ui/src/views/data/daily/index.vue

@@ -0,0 +1,326 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" l @submit.native.prevent>
+      <el-form-item label="日报时间" prop="dailyTime">
+        <el-date-picker clearable v-model="queryParams.dailyTime" type="date" value-format="yyyy-MM-dd" placeholder="请选择日报时间"></el-date-picker>
+      </el-form-item>
+      <el-form-item label="日报标题" prop="dailyTitle">
+        <el-input v-model="queryParams.dailyTitle" placeholder="请输入日报标题" clearable @keyup.enter.native="handleQuery" />
+      </el-form-item>
+      <el-form-item prop="deptId">
+        <template slot="label">
+          <span @click="changeQueryType" v-if="queryParams.deptName === 0">本级及下级</span>
+          <span @click="changeQueryType" v-if="queryParams.deptName === 1">只查询本级</span>
+        </template>
+        <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
+                    placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
+      </el-form-item>
+      <!--<el-form-item label="部门名称" prop="deptName">
+        <el-input
+          v-model="queryParams.deptName"
+          placeholder="请输入部门名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>-->
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:daily:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:daily:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:daily:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:daily:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="dailyList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <!--<el-table-column label="日报类型(字典)" align="center" prop="dailyType" />-->
+      <el-table-column label="日报时间" align="center" prop="dailyTime" width="180">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.dailyTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="日报标题" align="center" prop="dailyTitle" />
+      <el-table-column label="日报内容" align="center" prop="dailyContent" />
+      <el-table-column label="所属部门" align="center" prop="deptName" />
+      <el-table-column label="创建人" align="center" prop="createName" />
+      <el-table-column label="审计状态" align="center" prop="status" >
+        <template slot-scope="scope">
+          <span>{{ scope.row.status === '0' ? "未审计":"已审计"}}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:daily:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:daily:remove']"
+          >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" @pagination="getList" />
+
+    <!-- 添加或修改日报对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="日报时间" prop="dailyTime">
+          <el-date-picker clearable v-model="form.dailyTime" type="date" value-format="yyyy-MM-dd" placeholder="请选择日报时间"></el-date-picker>
+        </el-form-item>
+        <el-form-item label="日报标题" prop="dailyTitle"><el-input v-model="form.dailyTitle" placeholder="请输入日报标题" maxlength="50" /></el-form-item>
+        <el-form-item label="日报内容"><editor v-model="form.dailyContent" :min-height="192" maxlength="2000" /></el-form-item>
+        <el-form-item label="所属部门" prop="deptName">
+          <treeselect v-model="form.deptId" :options="deptOptions" multiple:false :show-count="true"
+                      placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listDaily, getDaily, delDaily, addDaily, updateDaily } from '@/api/data/daily/daily';
+import {treeselect} from "@/api/system/dept";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+import deptselector from '@/views/components/deptselector.vue'
+import fileUpload from '@/views/components/FileUpload/index.vue'
+
+export default {
+  components:{
+    Treeselect,
+    deptselector,
+    fileUpload
+  },
+  name: 'Daily',
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 日报表格数据
+      dailyList: [],
+      // 弹出层标题
+      title: '',
+      // 是否显示弹出层
+      open: false,
+      // 部门树选项
+      deptOptions: [],
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        dataStatus: null,
+        dataDeptId: null,
+        dailyType: null,
+        dailyTime: null,
+        dailyTitle: null,
+        dailyContent: null,
+        deptId: null,
+        deptName: 0,
+        createName:null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {}
+    };
+  },
+  created() {
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    hx(node) {
+      this.form.deptId = node.id
+      this.form.deptName = node.label
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data;
+      });
+    },
+    /** 查询日报列表 */
+    getList() {
+      this.loading = true;
+      listDaily(this.queryParams).then(response => {
+        this.dailyList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null,
+        dataStatus: '0',
+        dataDeptId: null,
+        dailyType: null,
+        dailyTime: null,
+        dailyTitle: null,
+        dailyContent: null,
+        deptId: null,
+        deptName: null
+      };
+      this.resetForm('form');
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.deptName = 0;
+      this.resetForm('queryForm');
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id);
+      this.single = selection.length !== 1;
+      this.multiple = !selection.length;
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = '添加日报';
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids;
+      getDaily(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = '修改日报';
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs['form'].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateDaily(this.form).then(response => {
+              this.$modal.msgSuccess('修改成功');
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addDaily(this.form).then(response => {
+              this.$modal.msgSuccess('新增成功');
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal
+        .confirm('是否确认删除数据项?')
+        .then(function() {
+          return delDaily(ids);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess('删除成功');
+        })
+        .catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download(
+        'system/daily/export',
+        {
+          ...this.queryParams
+        },
+        `daily_${new Date().getTime()}.xlsx`
+      );
+    },
+    // 点击按钮修改是否只查询本级部门用户
+    changeQueryType() {
+      this.queryParams.deptName = this.queryParams.deptName === 0 ? 1 : 0;
+    }
+  }
+};
+</script>

+ 360 - 0
system_ui/src/views/data/daily/index2.vue

@@ -0,0 +1,360 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" l
+             @submit.native.prevent
+    >
+      <el-form-item label="日报时间" prop="dailyTime">
+        <el-date-picker clearable v-model="queryParams.dailyTime" type="date" value-format="yyyy-MM-dd"
+                        placeholder="请选择日报时间"
+        ></el-date-picker>
+      </el-form-item>
+      <el-form-item label="日报标题" prop="dailyTitle">
+        <el-input v-model="queryParams.dailyTitle" placeholder="请输入日报标题" clearable
+                  @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item prop="deptId">
+        <template slot="label">
+          <span @click="changeQueryType" v-if="queryParams.deptName === 0">本级及下级</span>
+          <span @click="changeQueryType" v-if="queryParams.deptName === 1">只查询本级</span>
+        </template>
+        <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
+                    placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'"
+                    style="width: 240px"
+        />
+        <el-input v-model="queryParams.deptName" v-if="false"/>
+      </el-form-item>
+      <!--<el-form-item label="部门名称" prop="deptName">
+        <el-input
+          v-model="queryParams.deptName"
+          placeholder="请输入部门名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>-->
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <!--    <el-row :gutter="10" class="mb8">-->
+    <!--      <el-col :span="1.5">-->
+    <!--        <el-button-->
+    <!--          type="primary"-->
+    <!--          plain-->
+    <!--          icon="el-icon-plus"-->
+    <!--          size="mini"-->
+    <!--          @click="handleAdd"-->
+    <!--          v-hasPermi="['system:daily:add']"-->
+    <!--        >新增</el-button>-->
+    <!--      </el-col>-->
+    <!--      <el-col :span="1.5">-->
+    <!--        <el-button-->
+    <!--          type="success"-->
+    <!--          plain-->
+    <!--          icon="el-icon-edit"-->
+    <!--          size="mini"-->
+    <!--          :disabled="single"-->
+    <!--          @click="handleUpdate"-->
+    <!--          v-hasPermi="['system:daily:edit']"-->
+    <!--        >修改</el-button>-->
+    <!--      </el-col>-->
+    <!--      <el-col :span="1.5">-->
+    <!--        <el-button-->
+    <!--          type="danger"-->
+    <!--          plain-->
+    <!--          icon="el-icon-delete"-->
+    <!--          size="mini"-->
+    <!--          :disabled="multiple"-->
+    <!--          @click="handleDelete"-->
+    <!--          v-hasPermi="['system:daily:remove']"-->
+    <!--        >删除</el-button>-->
+    <!--      </el-col>-->
+    <!--      <el-col :span="1.5">-->
+    <!--        <el-button-->
+    <!--          type="warning"-->
+    <!--          plain-->
+    <!--          icon="el-icon-download"-->
+    <!--          size="mini"-->
+    <!--          @click="handleExport"-->
+    <!--          v-hasPermi="['system:daily:export']"-->
+    <!--        >导出</el-button>-->
+    <!--      </el-col>-->
+    <!--      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>-->
+    <!--    </el-row>-->
+
+    <el-table v-loading="loading" :data="dailyList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center"/>
+      <!--<el-table-column label="日报类型(字典)" align="center" prop="dailyType" />-->
+      <el-table-column label="日报时间" align="center" prop="dailyTime" width="180">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.dailyTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="日报标题" align="center" prop="dailyTitle"/>
+      <el-table-column label="日报内容" align="center" prop="dailyContent"/>
+      <el-table-column label="所属部门" align="center" prop="deptName"/>
+      <el-table-column label="创建人" align="center" prop="createName"/>
+      <el-table-column label="审计状态" align="center" prop="status">
+        <template slot-scope="scope">
+          <span>{{ scope.row.status === '0' ? '未审计' : '已审计' }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            :disabled="scope.row.status !== '0'"
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:daily:edit']"
+          >审计
+          </el-button>
+          <!--          <el-button-->
+          <!--            size="mini"-->
+          <!--            type="text"-->
+          <!--            icon="el-icon-delete"-->
+          <!--            @click="handleDelete(scope.row)"-->
+          <!--            v-hasPermi="['system:daily:remove']"-->
+          <!--          >删除</el-button>-->
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
+                @pagination="getList"
+    />
+
+    <!-- 添加或修改日报对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="日报时间" prop="dailyTime">
+          <el-date-picker clearable v-model="form.dailyTime" type="date" value-format="yyyy-MM-dd"
+                          placeholder="请选择日报时间"
+          ></el-date-picker>
+        </el-form-item>
+        <el-form-item label="日报标题" prop="dailyTitle">
+          <el-input v-model="form.dailyTitle" placeholder="请输入日报标题" maxlength="50"/>
+        </el-form-item>
+        <el-form-item label="日报内容">
+          <editor v-model="form.dailyContent" :min-height="192" maxlength="2000"/>
+        </el-form-item>
+        <el-form-item label="所属部门" prop="deptName">
+          <el-input v-model="form.deptName" placeholder="请输入部门名称" maxlength="50"/>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listDaily, getDaily, delDaily, addDaily, updateDaily } from '@/api/data/daily/daily'
+import { treeselect } from '@/api/system/dept'
+import Treeselect from '@riophae/vue-treeselect'
+import '@riophae/vue-treeselect/dist/vue-treeselect.css'
+import deptselector from '@/views/components/deptselector.vue'
+import fileUpload from '@/views/components/FileUpload/index.vue'
+
+export default {
+  components: {
+    Treeselect,
+    deptselector,
+    fileUpload
+  },
+  name: 'Daily',
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 日报表格数据
+      dailyList: [],
+      // 弹出层标题
+      title: '',
+      // 是否显示弹出层
+      open: false,
+      // 部门树选项
+      deptOptions: [],
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        dataStatus: null,
+        dataDeptId: null,
+        dailyType: null,
+        dailyTime: null,
+        dailyTitle: null,
+        dailyContent: null,
+        deptId: null,
+        deptName: 0,
+        createName: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {}
+    }
+  },
+  created() {
+    this.getList()
+    this.getTreeselect()
+  },
+  methods: {
+    hx(node) {
+      this.form.deptId = node.id
+      this.form.deptName = node.label
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data
+      })
+    },
+    /** 查询日报列表 */
+    getList() {
+      this.loading = true
+      listDaily(this.queryParams).then(response => {
+        this.dailyList = response.rows
+        this.total = response.total
+        this.loading = false
+      })
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false
+      this.reset()
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null,
+        dataStatus: '0',
+        dataDeptId: null,
+        dailyType: null,
+        dailyTime: null,
+        dailyTitle: null,
+        dailyContent: null,
+        deptId: null,
+        deptName: null
+      }
+      this.resetForm('form')
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1
+      this.getList()
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.deptName = 0
+      this.resetForm('queryForm')
+      this.handleQuery()
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length !== 1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset()
+      this.open = true
+      this.title = '添加日报'
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      // this.reset();
+      // const id = row.id || this.ids;
+      // getDaily(id).then(response => {
+      //   this.form = response.data;
+      //   this.open = true;
+      //   this.title = '修改日报';
+      // });
+      this.$confirm('是否审计?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(() => {
+        let data = {
+          id: row.id,
+          status: '1'
+        }
+        updateDaily(data).then(response => {
+          this.$modal.msgSuccess('审计成功')
+          this.open = false
+          this.getList()
+        })
+      })
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs['form'].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateDaily(this.form).then(response => {
+              this.$modal.msgSuccess('修改成功')
+              this.open = false
+              this.getList()
+            })
+          } else {
+            addDaily(this.form).then(response => {
+              this.$modal.msgSuccess('新增成功')
+              this.open = false
+              this.getList()
+            })
+          }
+        }
+      })
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids
+      this.$modal
+        .confirm('是否确认删除数据项?')
+        .then(function() {
+          return delDaily(ids)
+        })
+        .then(() => {
+          this.getList()
+          this.$modal.msgSuccess('删除成功')
+        })
+        .catch(() => {
+        })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download(
+        'system/daily/export',
+        {
+          ...this.queryParams
+        },
+        `daily_${new Date().getTime()}.xlsx`
+      )
+    },
+    // 点击按钮修改是否只查询本级部门用户
+    changeQueryType() {
+      this.queryParams.deptName = this.queryParams.deptName === 0 ? 1 : 0
+    }
+  }
+}
+</script>

+ 655 - 0
system_ui/src/views/data/leave/index.vue

@@ -0,0 +1,655 @@
+<template>
+  <div class="app-container">
+    <el-form
+      :model="queryParams"
+      ref="queryForm"
+      size="small"
+      :inline="true"
+      v-show="showSearch"
+      @submit.native.prevent
+    >
+      <!--<el-form-item label="数据所属部门(政或党的id)" prop="dataDeptId">-->
+      <!--<el-input-->
+      <!--v-model="queryParams.dataDeptId"-->
+      <!--placeholder="请输入数据所属部门(政或党的id)"-->
+      <!--clearable-->
+      <!--@keyup.enter.native="handleQuery"-->
+      <!--/>-->
+      <!--</el-form-item>-->
+      <!--<el-form-item label="开始时间" prop="leaveStartTime" label-width="120px">-->
+      <!--<el-date-picker clearable-->
+      <!--v-model="queryParams.leaveStartTime"-->
+      <!--type="date"-->
+      <!--value-format="yyyy-MM-dd"-->
+      <!--placeholder="请选择开始时间">-->
+      <!--</el-date-picker>-->
+      <!--</el-form-item>-->
+      <!--<el-form-item label="结束时间" prop="leaveEndTime" label-width="120px">-->
+      <!--<el-date-picker clearable-->
+      <!--v-model="queryParams.leaveEndTime"-->
+      <!--type="date"-->
+      <!--value-format="yyyy-MM-dd"-->
+      <!--placeholder="请选择结束时间">-->
+      <!--</el-date-picker>-->
+      <!--</el-form-item>-->
+      <el-form-item label-width="100px" label="请假人姓名" prop="leaveUserName">
+        <el-input
+          v-model="queryParams.leaveUserName"
+          placeholder="请输入请假人姓名"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item prop="deptId">
+        <template slot="label">
+          <span @click="changeQueryType" v-if="queryParams.deptName == 0">本级及下级</span>
+          <span @click="changeQueryType" v-if="queryParams.deptName == 1">只查询本级</span>
+        </template>
+        <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
+                    placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
+        <el-input v-model="queryParams.deptName" v-if="false"/>
+      </el-form-item>
+      <!--  <el-form-item label-width="auto" label="所属部门" prop="deptName">
+        <el-input
+          v-model="queryParams.deptName"
+          placeholder="请输入所属部门"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>-->
+      <!--<el-form-item label="请假人事由" prop="leaveMatter">
+        <el-input
+          v-model="queryParams.leaveMatter"
+          placeholder="请输入请假人事由"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="部门名称" prop="deptId" >
+        <treeselect :options="deptOptions" v-model="queryParams.deptId"  :show-count="true" placeholder="请选择所属部门"
+                    @select="hxQuery"/>
+      </el-form-item>-->
+      <el-form-item>
+        <el-button
+          type="primary"
+          icon="el-icon-search"
+          size="mini"
+          @click="handleQuery"
+        >搜索</el-button
+        >
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
+        >重置</el-button
+        >
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:leave:add']"
+        >新增
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:leave:edit']"
+        >修改
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:leave:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:leave:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar
+        :showSearch.sync="showSearch"
+        @queryTable="getList"
+      ></right-toolbar>
+    </el-row>
+
+    <el-table
+      v-loading="loading"
+      :data="leaveList"
+      @selection-change="handleSelectionChange"
+    >
+      <el-table-column type="selection" width="55" align="center" />
+      <!--      <el-table-column label="主键id" align="center" prop="id" />-->
+      <!--      <el-table-column label="数据状态(1-可用 2-不可用 )" align="center" prop="dataStatus" />-->
+      <!--      <el-table-column label="数据所属部门(政或党的id)" align="center" prop="dataDeptId" />-->
+      <el-table-column
+        label="开始时间"
+        align="center"
+        prop="leaveStartTime"
+        width="180"
+      >
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.leaveStartTime, "{y}-{m}-{d} {h}:{i}:{s}") }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column
+        label="结束时间"
+        align="center"
+        prop="leaveEndTime"
+        width="180"
+      >
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.leaveEndTime, "{y}-{m}-{d} {h}:{i}:{s}") }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="状态" align="center" prop="forestLeaveStatus" >
+        <template slot-scope="scope">
+          <dict-tag
+            :options="dict.type.app_leave"
+            :value="scope.row.forestLeaveStatus"
+          />
+        </template>
+      </el-table-column>
+      <el-table-column label="请假事由" align="center" prop="leaveMatter" />
+      <el-table-column label="所属部门" align="center" prop="deptName" />
+      <el-table-column label="请假人姓名" align="center" prop="leaveUserName" />
+      <el-table-column label="创建人" align="center" prop="createName"/>
+      <el-table-column label="创建时间" align="center" prop="createTime"/>
+      <el-table-column label="修改人" align="center" prop="updateName"/>
+      <el-table-column label="修改时间" align="center" prop="updateTime"/>
+      <el-table-column
+        label="操作"
+        align="center"
+        class-name="small-padding fixed-width"
+      >
+        <template slot-scope="scope">
+          <el-button v-if="scope.row.forestLeaveStatus == 'app_leave_1'"
+                     size="mini"
+                     type="text"
+                     icon="el-icon-edit"
+                     @click="handleUpdate(scope.row)"
+                     v-hasPermi="['system:leave:edit']"
+          >修改
+          </el-button>
+          <el-button v-if="scope.row.forestLeaveStatus == 'app_leave_1'"
+                     size="mini"
+                     type="text"
+                     icon="el-icon-delete"
+                     @click="handleDelete(scope.row)"
+                     v-hasPermi="['system:leave:remove']"
+          >删除
+          </el-button>
+
+          <el-button v-if="scope.row.forestLeaveStatus == 'app_leave_1'"
+                     size="mini"
+                     type="text"
+                     icon="el-icon-edit"
+                     @click="See(scope.row)"
+                     v-hasPermi="['forest:regulations:edit']"
+          >审批
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total > 0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改请假对话框 -->
+    <el-dialog
+      :title="title"
+      :visible.sync="open"
+      label-width="600px"
+      class="form-style"
+    >
+      <el-form ref="form" :model="form" :rules="rules" label-width="120px">
+        <el-row>
+          <el-col :span="24">
+            <el-form-item label="申请人" prop="leaveUserName" class="form-style">
+              <el-select
+                v-model="form.leaveUserName"
+                filterable
+                placeholder="请选择申请人"
+              >
+                <el-option
+                  v-for="dict in userList"
+                  :key="dict.userId"
+                  :label="dict.nickName"
+                  :value="String(dict.userId)"
+                  @click.native="a(dict)"
+                ></el-option>
+              </el-select>
+            </el-form-item>
+            <el-form-item label="所属部门" prop="deptId">
+              <treeselect
+                :options="deptOptions"
+                v-model="form.deptId"
+                :show-count="true"
+                placeholder="请选择所属部门"
+                @select="hx"
+                :noResultsText="'空'"
+                :noOptionsText="'空'"
+              />
+            </el-form-item>
+            <el-form-item
+              label="开始时间"
+              prop="leaveStartTime"
+              label-width="120px"
+            >
+              <el-date-picker
+                clearable
+                v-model="form.leaveStartTime"
+                type="datetime"
+                :picker-options="pickerOptionsStart"
+                value-format="yyyy-MM-dd HH:mm:ss"
+                placeholder="请选择开始时间"
+              >
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item
+              label="结束时间"
+              prop="leaveEndTime"
+              label-width="120px"
+            >
+              <el-date-picker
+                clearable
+                v-model="form.leaveEndTime"
+                type="datetime"
+                :picker-options="pickerOptionsEnd"
+                value-format="yyyy-MM-dd HH:mm:ss"
+                placeholder="请选择结束时间"
+              >
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item
+              label="请假事由"
+              prop="leaveMatter"
+              label-width="120px"
+            >
+              <el-input
+                v-model="form.leaveMatter"
+                type="textarea"
+                placeholder="请输入内容"
+                maxlength="100"
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 审批页面 -->
+    <!--    <el-dialog-->
+    <!--      :title="title"-->
+    <!--      :visible.sync="seeopen"-->
+    <!--      width="600px"-->
+    <!--      class="form-style"-->
+    <!--    >-->
+    <!--      <el-form ref="form" :model="form" :rules="rules" label-width="120px">-->
+    <!--        <el-form-item-->
+    <!--          label="开始时间"-->
+    <!--          prop="leaveStartTime"-->
+    <!--          label-width="120px"-->
+    <!--        >-->
+    <!--          <el-date-picker-->
+    <!--            clearable-->
+    <!--            :disabled="true"-->
+    <!--            v-model="form.leaveStartTime"-->
+    <!--            type="datetime"-->
+    <!--            value-format="yyyy-MM-dd HH:mm:ss"-->
+    <!--            placeholder="请选择开始时间"-->
+    <!--          >-->
+    <!--          </el-date-picker>-->
+    <!--        </el-form-item>-->
+    <!--        <el-form-item label="结束时间" prop="leaveEndTime" label-width="120px">-->
+    <!--          <el-date-picker-->
+    <!--            clearable-->
+    <!--            :disabled="true"-->
+    <!--            v-model="form.leaveEndTime"-->
+    <!--            type="datetime"-->
+    <!--            value-format="yyyy-MM-dd HH:mm:ss"-->
+    <!--            placeholder="请选择结束时间"-->
+    <!--          >-->
+    <!--          </el-date-picker>-->
+    <!--        </el-form-item>-->
+    <!--        &lt;!&ndash;        <el-form-item label="请假事由" prop="leaveMatter">-->
+    <!--          <el-input v-model="form.leaveMatter" placeholder="请输入请假人事由" :disabled="true" maxlength="50"/>-->
+    <!--        </el-form-item>&ndash;&gt;-->
+    <!--        <el-form-item label="请假事由" prop="leaveMatter" label-width="120px">-->
+    <!--          <el-input-->
+    <!--            v-model="form.leaveMatter"-->
+    <!--            type="textarea"-->
+    <!--            placeholder="请输入内容"-->
+    <!--            maxlength="100"-->
+    <!--          />-->
+    <!--        </el-form-item>-->
+    <!--        <el-form-item label="所属部门" prop="deptId">-->
+    <!--          <treeselect-->
+    <!--            :options="deptOptions"-->
+    <!--            v-model="form.deptId"-->
+    <!--            :show-count="true"-->
+    <!--            placeholder="请选择所属部门"-->
+    <!--            @select="hx"-->
+    <!--            :disabled="true"-->
+    <!--          />-->
+    <!--        </el-form-item>-->
+    <!--        <el-form-item label="请假人姓名" prop="leaveUserName">-->
+    <!--          <el-input-->
+    <!--            v-model="form.leaveUserName"-->
+    <!--            placeholder="请输入请假人姓名"-->
+    <!--            maxlength="20"-->
+    <!--            :disabled="true"-->
+    <!--          />-->
+    <!--        </el-form-item>-->
+    <!--      </el-form>-->
+    <!--      <div slot="footer" class="dialog-footer">-->
+    <!--        <el-button type="primary" @click="agreeSel">同意</el-button>-->
+    <!--        <el-button @click="cancelSel">拒绝</el-button>-->
+    <!--      </div>-->
+    <!--    </el-dialog>-->
+  </div>
+</template>
+
+<script>
+import {
+  addLeave,
+  delLeave,
+  getLeave,
+  listLeave,
+  updateLeave,
+  changeStatus,
+} from "@/api/data/leave/leave";
+import { treeselect } from "@/api/system/dept";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+import { selectUserList } from "@/api/data/leave/linleader";
+
+export default {
+  name: "Leave",
+  components: { Treeselect },
+  dicts: ["app_leave"],
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      userList: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 请假表格数据
+      leaveList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      seeopen: false,
+      // 部门树选项
+      deptOptions: [],
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        dataStatus: null,
+        dataDeptId: null,
+        leaveStartTime: null,
+        leaveEndTime: null,
+        forestLeaveStatus: null,
+        leaveMatter: null,
+        deptId: null,
+        deptName: 0,
+        leaveUserId: null,
+        leaveUserName: null,
+        id:null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        leaveStartTime: [
+          { required: true, message: "开始时间不能为空", trigger: "blur" },
+        ],
+        leaveEndTime: [
+          { required: true, message: "结束时间不能为空", trigger: "blur" },
+        ],
+        deptId: [
+          { required: true, message: "所属部门不能为空", trigger: "change" },
+        ],
+        leaveUserName: [
+          { required: true, message: "申请人姓名不能为空", trigger: "blur" },
+        ],
+      },
+      pickerOptionsStart: {
+        disabledDate: (time) => {
+          if (this.form.leaveEndTime) {
+            return time.getTime() > new Date(this.form.leaveEndTime).getTime();
+          }
+        },
+      },
+      pickerOptionsEnd: {
+        disabledDate: (time) => {
+          return (
+            time.getTime() <
+            new Date(this.form.leaveStartTime).getTime() -
+            1 * 24 * 60 * 60 * 1000
+          );
+        },
+      },
+    };
+  },
+  created() {
+    this.queryParams.type = this.$route.query.type;
+    this.getList();
+    this.getTreeselect();
+    selectUserList().then((response) => {
+      this.userList = response.data;
+    });
+  },
+  methods: {
+    a(event) {
+      this.form.leaveUserName = event.nickName;
+      this.form.leaveUserId = event.userId;
+    },
+    /** 查询请假列表 */
+    getList() {
+      this.loading = true;
+      listLeave(this.queryParams).then((response) => {
+        this.leaveList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 拒绝按钮
+    cancelSel() {
+      this.seeopen = false;
+      this.reset();
+    },
+
+    hx(node) {
+      this.form.deptId = node.id;
+      this.form.deptName = node.label;
+      this.$refs.form.validate();
+    },
+    hxQuery(node) {
+      this.queryParams.deptId = node.id;
+    },
+    See(row) {
+      const id = row.id ;
+      let forestLeaveStatus = "app_leave_2";
+      this.$modal
+        .confirm("是否同意?")
+        .then(function () {
+          return changeStatus(id,forestLeaveStatus);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("已同意");
+        })
+        .catch(() => {});
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then((response) => {
+        this.deptOptions = response.data;
+      });
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null,
+        dataDeptId: null,
+        leaveStartTime: null,
+        leaveEndTime: null,
+        forestLeaveStatus: "app_leave_1",
+        leaveMatter: null,
+        deptId: null,
+        deptName: null,
+        leaveUserId: null,
+        leaveUserName: null,
+        type: this.queryParams.type
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.deptName = 0;
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map((item) => item.id);
+      this.single = selection.length !== 1;
+      this.multiple = !selection.length;
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加请假";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids;
+      getLeave(id).then((response) => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改请假";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate((valid) => {
+        if (valid) {
+          if (
+            new Date(this.form.leaveStartTime).getTime() >=
+            new Date(this.form.leaveEndTime).getTime()
+          ) {
+            this.$message({
+              message: "请重新确认起始时间和结束时间",
+              type: "error",
+            });
+          } else {
+            if (this.form.id != null) {
+              updateLeave(this.form).then((response) => {
+                this.$modal.msgSuccess("修改成功");
+                this.open = false;
+                this.getList();
+              });
+            } else {
+              addLeave(this.form).then((response) => {
+                this.$modal.msgSuccess("新增成功");
+                this.open = false;
+                this.getList();
+              });
+            }
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal
+        .confirm("是否删除选中的数据?")
+        .then(function () {
+          return delLeave(ids);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("删除成功");
+        })
+        .catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download(
+        "sooka-sponest-center-data/leave/export",
+        {
+          ...this.queryParams,
+        },
+        `请假申请_${new Date().getTime()}.xlsx`
+      );
+    },
+    // 点击按钮修改是否只查询本级部门用户
+    changeQueryType() {
+      this.queryParams.deptName = this.queryParams.deptName === 0 ? 1 : 0;
+    }
+  },
+};
+</script>

+ 569 - 0
system_ui/src/views/data/leave/index2.vue

@@ -0,0 +1,569 @@
+<template>
+  <div class="app-container">
+    <el-form
+      :model="queryParams"
+      ref="queryForm"
+      size="small"
+      :inline="true"
+      v-show="showSearch"
+      @submit.native.prevent
+    >
+      <!--<el-form-item label="数据所属部门(政或党的id)" prop="dataDeptId">-->
+      <!--<el-input-->
+      <!--v-model="queryParams.dataDeptId"-->
+      <!--placeholder="请输入数据所属部门(政或党的id)"-->
+      <!--clearable-->
+      <!--@keyup.enter.native="handleQuery"-->
+      <!--/>-->
+      <!--</el-form-item>-->
+      <el-form-item label-width="100px" label="请假人姓名" prop="leaveUserName">
+        <el-input
+          v-model="queryParams.leaveUserName"
+          placeholder="请输入请假人姓名"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="开始时间" prop="leaveStartTime" label-width="120px">
+        <el-date-picker clearable
+                        v-model="queryParams.leaveStartTime"
+                        type="date"
+                        value-format="yyyy-MM-dd"
+                        placeholder="请选择开始时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="结束时间" prop="leaveEndTime" label-width="120px">
+        <el-date-picker clearable
+                        v-model="queryParams.leaveEndTime"
+                        type="date"
+                        value-format="yyyy-MM-dd"
+                        placeholder="请选择结束时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item prop="deptId">
+        <template slot="label">
+          <span @click="changeQueryType" v-if="queryParams.deptName == 0">本级及下级</span>
+          <span @click="changeQueryType" v-if="queryParams.deptName == 1">只查询本级</span>
+        </template>
+        <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
+                    placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
+        <el-input v-model="queryParams.deptName" v-if="false"/>
+      </el-form-item>
+      <!--  <el-form-item label-width="auto" label="所属部门" prop="deptName">
+        <el-input
+          v-model="queryParams.deptName"
+          placeholder="请输入所属部门"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>-->
+      <!--<el-form-item label="请假人事由" prop="leaveMatter">
+        <el-input
+          v-model="queryParams.leaveMatter"
+          placeholder="请输入请假人事由"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="部门名称" prop="deptId" >
+        <treeselect :options="deptOptions" v-model="queryParams.deptId"  :show-count="true" placeholder="请选择所属部门"
+                    @select="hxQuery"/>
+      </el-form-item>-->
+      <el-form-item>
+        <el-button
+          type="primary"
+          icon="el-icon-search"
+          size="mini"
+          @click="handleQuery"
+        >搜索</el-button
+        >
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
+        >重置</el-button
+        >
+      </el-form-item>
+    </el-form>
+
+    <el-table
+      v-loading="loading"
+      :data="leaveList"
+      @selection-change="handleSelectionChange"
+    >
+      <el-table-column type="selection" width="55" align="center" />
+      <!--      <el-table-column label="主键id" align="center" prop="id" />-->
+      <!--      <el-table-column label="数据状态(1-可用 2-不可用 )" align="center" prop="dataStatus" />-->
+      <!--      <el-table-column label="数据所属部门(政或党的id)" align="center" prop="dataDeptId" />-->
+      <el-table-column
+        label="开始时间"
+        align="center"
+        prop="leaveStartTime"
+        width="180"
+      >
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.leaveStartTime, "{y}-{m}-{d} {h}:{i}:{s}") }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column
+        label="结束时间"
+        align="center"
+        prop="leaveEndTime"
+        width="180"
+      >
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.leaveEndTime, "{y}-{m}-{d} {h}:{i}:{s}") }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="状态" align="center" prop="forestLeaveStatus" >
+        <template slot-scope="scope">
+          <dict-tag
+            :options="dict.type.app_leave"
+            :value="scope.row.forestLeaveStatus"
+          />
+        </template>
+      </el-table-column>
+      <el-table-column label="请假事由" align="center" prop="leaveMatter" />
+      <el-table-column label="所属部门" align="center" prop="deptName" />
+      <el-table-column label="请假人姓名" align="center" prop="leaveUserName" />
+      <el-table-column label="创建人" align="center" prop="createName"/>
+      <el-table-column label="创建时间" align="center" prop="createTime"/>
+      <el-table-column label="修改人" align="center" prop="updateName"/>
+      <el-table-column label="修改时间" align="center" prop="updateTime"/>
+    </el-table>
+
+    <pagination
+      v-show="total > 0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改请假对话框 -->
+    <el-dialog
+      :title="title"
+      :visible.sync="open"
+      label-width="600px"
+      class="form-style"
+    >
+      <el-form ref="form" :model="form" :rules="rules" label-width="120px">
+        <el-row>
+          <el-col :span="24">
+            <el-form-item label="申请人" prop="leaveUserName" class="form-style">
+              <el-select
+                v-model="form.leaveUserName"
+                filterable
+                placeholder="请选择申请人"
+              >
+                <el-option
+                  v-for="dict in userList"
+                  :key="dict.userId"
+                  :label="dict.nickName"
+                  :value="String(dict.userId)"
+                  @click.native="a(dict)"
+                ></el-option>
+              </el-select>
+            </el-form-item>
+            <el-form-item label="所属部门" prop="deptId">
+              <treeselect
+                :options="deptOptions"
+                v-model="form.deptId"
+                :show-count="true"
+                placeholder="请选择所属部门"
+                @select="hx"
+                :noResultsText="'空'"
+                :noOptionsText="'空'"
+              />
+            </el-form-item>
+            <el-form-item
+              label="开始时间"
+              prop="leaveStartTime"
+              label-width="120px"
+            >
+              <el-date-picker
+                clearable
+                v-model="form.leaveStartTime"
+                type="datetime"
+                :picker-options="pickerOptionsStart"
+                value-format="yyyy-MM-dd HH:mm:ss"
+                placeholder="请选择开始时间"
+              >
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item
+              label="结束时间"
+              prop="leaveEndTime"
+              label-width="120px"
+            >
+              <el-date-picker
+                clearable
+                v-model="form.leaveEndTime"
+                type="datetime"
+                :picker-options="pickerOptionsEnd"
+                value-format="yyyy-MM-dd HH:mm:ss"
+                placeholder="请选择结束时间"
+              >
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item
+              label="请假事由"
+              prop="leaveMatter"
+              label-width="120px"
+            >
+              <el-input
+                v-model="form.leaveMatter"
+                type="textarea"
+                placeholder="请输入内容"
+                maxlength="100"
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 审批页面 -->
+    <!--    <el-dialog-->
+    <!--      :title="title"-->
+    <!--      :visible.sync="seeopen"-->
+    <!--      width="600px"-->
+    <!--      class="form-style"-->
+    <!--    >-->
+    <!--      <el-form ref="form" :model="form" :rules="rules" label-width="120px">-->
+    <!--        <el-form-item-->
+    <!--          label="开始时间"-->
+    <!--          prop="leaveStartTime"-->
+    <!--          label-width="120px"-->
+    <!--        >-->
+    <!--          <el-date-picker-->
+    <!--            clearable-->
+    <!--            :disabled="true"-->
+    <!--            v-model="form.leaveStartTime"-->
+    <!--            type="datetime"-->
+    <!--            value-format="yyyy-MM-dd HH:mm:ss"-->
+    <!--            placeholder="请选择开始时间"-->
+    <!--          >-->
+    <!--          </el-date-picker>-->
+    <!--        </el-form-item>-->
+    <!--        <el-form-item label="结束时间" prop="leaveEndTime" label-width="120px">-->
+    <!--          <el-date-picker-->
+    <!--            clearable-->
+    <!--            :disabled="true"-->
+    <!--            v-model="form.leaveEndTime"-->
+    <!--            type="datetime"-->
+    <!--            value-format="yyyy-MM-dd HH:mm:ss"-->
+    <!--            placeholder="请选择结束时间"-->
+    <!--          >-->
+    <!--          </el-date-picker>-->
+    <!--        </el-form-item>-->
+    <!--        &lt;!&ndash;        <el-form-item label="请假事由" prop="leaveMatter">-->
+    <!--          <el-input v-model="form.leaveMatter" placeholder="请输入请假人事由" :disabled="true" maxlength="50"/>-->
+    <!--        </el-form-item>&ndash;&gt;-->
+    <!--        <el-form-item label="请假事由" prop="leaveMatter" label-width="120px">-->
+    <!--          <el-input-->
+    <!--            v-model="form.leaveMatter"-->
+    <!--            type="textarea"-->
+    <!--            placeholder="请输入内容"-->
+    <!--            maxlength="100"-->
+    <!--          />-->
+    <!--        </el-form-item>-->
+    <!--        <el-form-item label="所属部门" prop="deptId">-->
+    <!--          <treeselect-->
+    <!--            :options="deptOptions"-->
+    <!--            v-model="form.deptId"-->
+    <!--            :show-count="true"-->
+    <!--            placeholder="请选择所属部门"-->
+    <!--            @select="hx"-->
+    <!--            :disabled="true"-->
+    <!--          />-->
+    <!--        </el-form-item>-->
+    <!--        <el-form-item label="请假人姓名" prop="leaveUserName">-->
+    <!--          <el-input-->
+    <!--            v-model="form.leaveUserName"-->
+    <!--            placeholder="请输入请假人姓名"-->
+    <!--            maxlength="20"-->
+    <!--            :disabled="true"-->
+    <!--          />-->
+    <!--        </el-form-item>-->
+    <!--      </el-form>-->
+    <!--      <div slot="footer" class="dialog-footer">-->
+    <!--        <el-button type="primary" @click="agreeSel">同意</el-button>-->
+    <!--        <el-button @click="cancelSel">拒绝</el-button>-->
+    <!--      </div>-->
+    <!--    </el-dialog>-->
+  </div>
+</template>
+
+<script>
+import {
+  addLeave,
+  delLeave,
+  getLeave,
+  listLeave,
+  updateLeave,
+  changeStatus,
+} from "@/api/data/leave/leave";
+import { treeselect } from "@/api/system/dept";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+import { selectUserList } from "@/api/data/leave/linleader";
+
+export default {
+  name: "Leave",
+  components: { Treeselect },
+  dicts: ["app_leave"],
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      userList: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 请假表格数据
+      leaveList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      seeopen: false,
+      // 部门树选项
+      deptOptions: [],
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        dataStatus: null,
+        dataDeptId: null,
+        leaveStartTime: null,
+        leaveEndTime: null,
+        forestLeaveStatus: null,
+        leaveMatter: null,
+        deptId: null,
+        deptName: 0,
+        leaveUserId: null,
+        leaveUserName: null,
+        id:null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        leaveStartTime: [
+          { required: true, message: "开始时间不能为空", trigger: "blur" },
+        ],
+        leaveEndTime: [
+          { required: true, message: "结束时间不能为空", trigger: "blur" },
+        ],
+        deptId: [
+          { required: true, message: "所属部门不能为空", trigger: "change" },
+        ],
+        leaveUserName: [
+          { required: true, message: "申请人姓名不能为空", trigger: "blur" },
+        ],
+      },
+      pickerOptionsStart: {
+        disabledDate: (time) => {
+          if (this.form.leaveEndTime) {
+            return time.getTime() > new Date(this.form.leaveEndTime).getTime();
+          }
+        },
+      },
+      pickerOptionsEnd: {
+        disabledDate: (time) => {
+          return (
+            time.getTime() <
+            new Date(this.form.leaveStartTime).getTime() -
+            1 * 24 * 60 * 60 * 1000
+          );
+        },
+      },
+    };
+  },
+  created() {
+    this.queryParams.type = this.$route.query.type;
+    this.getList();
+    this.getTreeselect();
+    selectUserList().then((response) => {
+      this.userList = response.data;
+    });
+  },
+  methods: {
+    a(event) {
+      this.form.leaveUserName = event.nickName;
+      this.form.leaveUserId = event.userId;
+    },
+    /** 查询请假列表 */
+    getList() {
+      this.loading = true;
+      listLeave(this.queryParams).then((response) => {
+        this.leaveList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 拒绝按钮
+    cancelSel() {
+      this.seeopen = false;
+      this.reset();
+    },
+
+    hx(node) {
+      this.form.deptId = node.id;
+      this.form.deptName = node.label;
+      this.$refs.form.validate();
+    },
+    hxQuery(node) {
+      this.queryParams.deptId = node.id;
+    },
+    See(row) {
+      const id = row.id ;
+      let forestLeaveStatus = "app_leave_2";
+      this.$modal
+        .confirm("是否同意?")
+        .then(function () {
+          return changeStatus(id,forestLeaveStatus);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("已同意");
+        })
+        .catch(() => {});
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then((response) => {
+        this.deptOptions = response.data;
+      });
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null,
+        dataDeptId: null,
+        leaveStartTime: null,
+        leaveEndTime: null,
+        forestLeaveStatus: "app_leave_1",
+        leaveMatter: null,
+        deptId: null,
+        deptName: null,
+        leaveUserId: null,
+        leaveUserName: null,
+        type: this.queryParams.type
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.deptName = 0;
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map((item) => item.id);
+      this.single = selection.length !== 1;
+      this.multiple = !selection.length;
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加请假";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids;
+      getLeave(id).then((response) => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改请假";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate((valid) => {
+        if (valid) {
+          if (
+            new Date(this.form.leaveStartTime).getTime() >=
+            new Date(this.form.leaveEndTime).getTime()
+          ) {
+            this.$message({
+              message: "请重新确认起始时间和结束时间",
+              type: "error",
+            });
+          } else {
+            if (this.form.id != null) {
+              updateLeave(this.form).then((response) => {
+                this.$modal.msgSuccess("修改成功");
+                this.open = false;
+                this.getList();
+              });
+            } else {
+              addLeave(this.form).then((response) => {
+                this.$modal.msgSuccess("新增成功");
+                this.open = false;
+                this.getList();
+              });
+            }
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal
+        .confirm("是否删除选中的数据?")
+        .then(function () {
+          return delLeave(ids);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("删除成功");
+        })
+        .catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download(
+        "sooka-sponest-center-data/leave/export",
+        {
+          ...this.queryParams,
+        },
+        `请假申请_${new Date().getTime()}.xlsx`
+      );
+    },
+    // 点击按钮修改是否只查询本级部门用户
+    changeQueryType() {
+      this.queryParams.deptName = this.queryParams.deptName === 0 ? 1 : 0;
+    }
+  },
+};
+</script>

+ 531 - 0
system_ui/src/views/data/regulations/index.vue

@@ -0,0 +1,531 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" @submit.native.prevent>
+      <el-form-item label="名称" prop="regName">
+        <el-input
+          v-model="queryParams.regName"
+          placeholder="请输入名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item prop="deptId">
+        <template slot="label">
+          <span @click="changeQueryType" v-if="queryParams.deptName === 0">本级及下级</span>
+          <span @click="changeQueryType" v-if="queryParams.deptName === 1">只查询本级</span>
+        </template>
+        <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
+                    placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
+        <el-input v-model="queryParams.deptName" v-if="false"/>
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:regulations:add']"
+        >新增
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:regulations:edit']"
+        >修改
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:regulations:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:regulations:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="regulationsList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center"/>
+      <!--  <el-table-column label="主键id" align="center" prop="id" />
+        <el-table-column label="数据状态(1-可用 2-不可用 )" align="center" prop="dataStatus" />-->
+      <!--  <el-table-column label="数据所属部门(政或党的id)" align="center" prop="dataDeptId" />-->
+      <el-table-column label="名称" align="center" prop="regName"/>
+      <el-table-column label="法规简介" align="center" prop="regIntroduction"/>
+      <el-table-column label="发文机关" align="center" prop="regOffice"/>
+      <el-table-column label="发文号" align="center" prop="regNumber"/>
+      <el-table-column label="发文时间" align="center" prop="regTime" width="180">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.regTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="发布状态" align="center" prop="varieties">
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.centerdata_release_status" :value="scope.row.releaseStatus"/>
+        </template>
+      </el-table-column>
+      <!-- <el-table-column label="部门id" align="center" prop="deptId" />-->
+      <el-table-column label="所属部门" align="center" prop="deptName"/>
+      <el-table-column label="创建人" align="center" prop="createName"/>
+      <el-table-column label="创建时间" align="center" prop="createTime"/>
+      <el-table-column label="修改人" align="center" prop="updateName"/>
+      <el-table-column label="修改时间" align="center" prop="updateTime"/>
+      <!-- <el-table-column label="附件" align="center" prop="attachId" />-->
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:regulations:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:regulations:remove']"
+          >删除
+          </el-button>
+          <el-button v-if="scope.row.releaseStatus == 'centerdata_release_status_yes'" size="mini" type="text" icon="el-icon-refresh-left" @click="handlePublish(scope.row)" v-hasPermi="['system:reserve:edit']">
+            撤销
+          </el-button>
+          <el-button v-else-if="scope.row.releaseStatus == 'centerdata_release_status_no'" size="mini" type="text" icon="el-icon-upload" @click="handlePublish(scope.row)" v-hasPermi="['system:reserve:edit']">
+            发布
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="See(scope.row)"
+            v-hasPermi="['forest:regulations:edit']"
+          >查看
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改政策法规对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="800px" class="form-style">
+      <el-form ref="form" :model="form" :rules="rules" label-width="120px">
+        <el-row>
+          <el-col :span="12">
+            <el-form-item label="名称" prop="regName">
+              <el-input v-model="form.regName" placeholder="请输入名称" maxlength="50"/>
+            </el-form-item>
+            <el-form-item label="所属部门" prop="deptId">
+              <treeselect v-model="form.deptId" :options="deptOptions" multiple:false :show-count="true"
+                          placeholder="请选择所属部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'"/>
+            </el-form-item>
+            <el-form-item label="发文时间" prop="regTime">
+              <el-date-picker clearable
+                              v-model="form.regTime"
+                              type="date"
+                              value-format="yyyy-MM-dd"
+                              placeholder="请选择发文时间">
+              </el-date-picker>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="发文机关" prop="regOffice">
+              <el-input v-model="form.regOffice" placeholder="请输入发文机关" maxlength="50"/>
+            </el-form-item>
+            <el-form-item label="发文号" prop="regNumber">
+              <el-input v-model="form.regNumber" placeholder="请输入发文号" maxlength="50"/>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="24">
+            <!--            <el-form-item label="法规简介" prop="regIntroduction">
+                          <editor v-model="form.regIntroduction" :min-height="192" maxlength="512"/>
+                        </el-form-item>-->
+            <el-form-item label="法规简介" prop="regIntroduction" label-width="120px">
+              <el-input v-model="form.regIntroduction" type="textarea" placeholder="请输入内容" maxlength="200"/>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="24">
+            <el-form-item label="附件" prop="attachId">
+              <fileUpload :value="[form.fileUrl,form.fileName]" v-model="form.fileUrl" :setFileName="setFileName"
+                          :removeFileName="removeFileName" :limit="1"></fileUpload>
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!--详情 -->
+    <el-dialog :title="title" :visible.sync="seeopen" width="800px" class="form-style" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="120px">
+        <el-row>
+          <el-col :span="12">
+            <el-form-item label="所属部门" prop="dataDeptId" label-width="120px">
+              <deptselector :setValue=setDataDeptId :dataDeptId="form.dataDeptId"></deptselector>
+            </el-form-item>
+            <el-form-item label="名称" prop="regName">
+              <el-input v-model="form.regName" placeholder="请输入名称" :disabled="true" maxlength="50"/>
+            </el-form-item>
+            <!--            <el-form-item label="法规简介" prop="regIntroduction">
+                          <el-input v-model="form.regIntroduction" placeholder="请输入法规简介" :disabled="true" maxlength="512"/>
+                        </el-form-item>-->
+            <el-form-item label="法规简介" prop="regIntroduction" label-width="120px">
+              <el-input v-model="form.regIntroduction" type="textarea" placeholder="请输入内容" maxlength="200"/>
+            </el-form-item>
+            <el-form-item label="发文时间" prop="regTime">
+              <el-date-picker clearable :disabled="true"
+                              v-model="form.regTime"
+                              type="date"
+                              value-format="yyyy-MM-dd"
+                              placeholder="请选择发文时间">
+              </el-date-picker>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="发文机关" prop="regOffice">
+              <el-input v-model="form.regOffice" placeholder="请输入发文机关" :disabled="true" maxlength="50"/>
+            </el-form-item>
+            <el-form-item label="发文号" prop="regNumber">
+              <el-input v-model="form.regNumber" placeholder="请输入发文号" :disabled="true" maxlength="50"/>
+            </el-form-item>
+            <el-form-item label="所属部门" prop="deptId">
+              <treeselect :options="deptOptions" v-model="form.deptId" :show-count="true" placeholder="请选择所属部门"
+                          @select="hx" :disabled="true" :noResultsText="'空'" :noOptionsText="'空'"/>
+            </el-form-item>
+            <el-form-item label="附件" prop="attachId">
+              <fileUpload @input="getUrl" v-model="form.fileUrl"></fileUpload>
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button @click="cancelSel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addRegulations,
+  delRegulations,
+  getRegulations,
+  listRegulations,
+  updateRegulations,
+  updateRelease
+} from "@/api/data/regulations/regulations";
+import {treeselect} from "@/api/system/dept";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+import deptselector from '@/views/components/deptselector.vue'
+import fileUpload from '@/views/components/FileUpload/index.vue'
+
+export default {
+  components: {
+    Treeselect,
+    deptselector,
+    fileUpload
+  },
+  name: "Regulations",
+  dicts: ["centerdata_release_status"],
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 政策法规表格数据
+      regulationsList: [],
+      fileNames: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      seeopen: false,
+      // 部门树选项
+      deptOptions: [],
+      // 查询参数
+      queryParams: {
+        releaseStatus: null,
+        pageNum: 1,
+        pageSize: 10,
+        dataStatus: null,
+        dataDeptId: null,
+        regName: null,
+        regIntroduction: null,
+        regOffice: null,
+        regNumber: null,
+        regTime: null,
+        deptId: null,
+        deptName: 0,
+        attachId: null
+      },
+      // 表单参数
+      form: {
+        dataDeptId: 0,
+        releaseStatus: 'centerdata_release_status_no',
+        fileUrl: '',
+        fileName: '',
+        fileUrlList: [],
+        fileNameList: []
+      },
+      // 表单校验
+      rules: {
+        deptId: [
+          {required: true, message: "所属部门不能为空", trigger: "change"}
+        ],
+        regName: [
+          {required: true, message: "名称不能为空", trigger: "blur"}
+        ],
+        regOffice: [
+          {required: true, message: "发文机关不能为空", trigger: "blur"}
+        ],
+        regNumber: [
+          {required: true, message: "发文号不能为空", trigger: "blur"}
+        ]
+      }
+    };
+  },
+  created() {
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    getUrl(url) {
+      alert('0');
+    },
+    setFileName(fileName) {
+      let that = this
+      that.fileNames.push(fileName)
+    },
+    removeFileName(index) {
+      let that = this
+      that.fileNames.splice(index, 1);
+      let fileurls = that.form.fileUrl.split(",")
+      fileurls.splice(index, 1)
+      that.form.fileUrl = fileurls.toString()
+    },
+    // 取消按钮
+    cancelSel() {
+      this.seeopen = false;
+      this.reset();
+    },
+    See(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getRegulations(id).then(response => {
+        this.form = response.data;
+        this.seeopen = true;
+        this.title = "查看";
+      });
+    },
+    setDataDeptId(e) {
+      this.form.dataDeptId = e.deptId
+      this.form.dataDeptName = e.deptName
+    },
+    hx(node) {
+      this.form.deptId = node.id
+      this.form.deptName = node.label
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data;
+      });
+    },
+    /** 查询政策法规列表 */
+    getList() {
+      this.loading = true;
+      listRegulations(this.queryParams).then(response => {
+        this.regulationsList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null,
+        dataStatus: "0",
+        dataDeptId: '',
+        regName: null,
+        regIntroduction: null,
+        regOffice: null,
+        regNumber: null,
+        regTime: null,
+        deptId: null,
+        deptName: 0,
+        attachId: null,
+      };
+      this.fileNames = []
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.deptName = 0;
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length !== 1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加政策法规";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getRegulations(id).then(response => {
+        const list = response.data.fileUrl.split(',');
+        var item1
+        if (response.data.fileUrl != "") {
+          for (var a = 0; a < list.length; a++) {
+            let listurl = list[a].split('+')
+            this.fileNames.push(listurl[1])
+          }
+        }
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改政策法规";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          this.form.fileName = this.fileNames.toString()
+          this.form.fileNameList = this.fileNames;
+          this.form.fileUrlList = Array.from(document.querySelectorAll('.el-upload-list__item')).map(item => item.querySelector('a').getAttribute('href'));
+          if (this.form.id != null) {
+            updateRegulations(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            this.form.releaseStatus = "centerdata_release_status_no";
+            addRegulations(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否删除选中的数据?').then(function () {
+        return delRegulations(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {
+      });
+    },
+    handlePublish(row) {
+      let ids = row.id || this.ids;
+      let status = "发布", releaseStatus = "centerdata_release_status_yes";
+      if (!ids.includes(",")) {
+        ids = [ids];
+        if (row.releaseStatus.includes("centerdata_release_status_yes")) {
+          status = "撤销";
+          releaseStatus = "centerdata_release_status_no";
+        }
+        this.$modal.confirm('是否' + status + '选中的数据?').then(function () {
+          return updateRelease(ids, releaseStatus);
+        }).then(() => {
+          this.getList();
+          this.$modal.msgSuccess(status + "成功");
+        }).catch((e) => {
+          console.log(e)
+        });
+      }
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('sooka-sponest-center-data/regulations/export', {
+        ...this.queryParams
+      }, `政策法规_${new Date().getTime()}.xlsx`)
+    },
+    // 点击按钮修改是否只查询本级部门用户
+    changeQueryType() {
+      this.queryParams.deptName = this.queryParams.deptName === 0 ? 1 : 0;
+    }
+  }
+};
+</script>

+ 501 - 0
system_ui/src/views/data/reserve/index.vue

@@ -0,0 +1,501 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" @submit.native.prevent>
+      <!--      <el-form-item label="数据所属部门(政或党的id)" prop="dataDeptId">-->
+      <!--        <el-input-->
+      <!--          v-model="queryParams.dataDeptId"-->
+      <!--          placeholder="请输入数据所属部门(政或党的id)"-->
+      <!--          clearable-->
+      <!--          @keyup.enter.native="handleQuery"-->
+      <!--        />-->
+      <!--      </el-form-item>-->
+      <el-form-item label="标题" prop="resTitle">
+        <el-input
+          v-model="queryParams.resTitle"
+          placeholder="请输入标题"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item prop="deptId">
+        <template slot="label">
+          <span @click="changeQueryType" v-if="queryParams.deptName === 0">本级及下级</span>
+          <span @click="changeQueryType" v-if="queryParams.deptName === 1">只查询本级</span>
+        </template>
+        <treeselect v-model="queryParams.deptId" :options="deptOptions" multiple:false :show-count="true"
+                    placeholder="请选择部门" @select="hx" :noResultsText="'空'" :noOptionsText="'空'" style="width: 240px"/>
+        <el-input v-model="queryParams.deptName" v-if="false"/>
+      </el-form-item>
+
+      <!-- <el-form-item label="简介" prop="resIntroduction">
+         <el-input
+           v-model="queryParams.resIntroduction"
+           placeholder="请输入简介"
+           clearable
+           @keyup.enter.native="handleQuery"
+         />
+       </el-form-item>-->
+      <!--  <el-form-item label="所属部门" prop="deptId">
+          <treeselect :options="deptOptions" v-model="queryParams.deptId"  :show-count="true" placeholder="请选择所属部门"
+                      @select="hxQuery"/>
+        </el-form-item>-->
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['system:reserve:add']"
+        >新增
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['system:reserve:edit']"
+        >修改
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['system:reserve:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['system:reserve:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="reserveList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center"/>
+      <!--      <el-table-column label="主键id" align="center" prop="id" />-->
+      <!--      <el-table-column label="数据状态(1-可用 2-不可用 )" align="center" prop="dataStatus" />-->
+      <!--      <el-table-column label="数据所属部门(政或党的id)" align="center" prop="dataDeptId" />-->
+      <el-table-column label="标题" align="center" prop="resTitle"/>
+      <el-table-column label="简介" align="center" prop="resIntroduction"/>
+      <!--      <el-table-column label="部门id" align="center" prop="deptId"/>-->
+      <el-table-column label="所属部门" align="center" prop="deptName" @select="hx"/>
+      <el-table-column label="发布状态" align="center" prop="varieties">
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.centerdata_release_status" :value="scope.row.releaseStatus"/>
+        </template>
+      </el-table-column>
+      <el-table-column label="创建人" align="center" prop="createName"/>
+      <el-table-column label="创建时间" align="center" prop="createTime"/>
+      <el-table-column label="修改人" align="center" prop="updateName"/>
+      <el-table-column label="修改时间" align="center" prop="updateTime"/>
+      <!--      <el-table-column label="附件" align="center" prop="attachId"/>-->
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['system:reserve:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['system:reserve:remove']"
+          >删除
+          </el-button>
+          <el-button v-if="scope.row.releaseStatus == 'centerdata_release_status_yes'" size="mini" type="text" icon="el-icon-refresh-left" @click="handlePublish(scope.row)" v-hasPermi="['system:reserve:edit']">
+            撤销
+          </el-button>
+          <el-button v-else-if="scope.row.releaseStatus == 'centerdata_release_status_no'" size="mini" type="text" icon="el-icon-upload" @click="handlePublish(scope.row)" v-hasPermi="['system:reserve:edit']">
+            发布
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="See(scope.row)"
+            v-hasPermi="['forest:reserve:edit']"
+          >查看
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改应急预案对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="600px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="标题" prop="resTitle">
+          <el-input v-model="form.resTitle" placeholder="请输入标题" maxlength="50"/>
+        </el-form-item>
+        <el-form-item label="所属部门" prop="deptId">
+          <treeselect :options="deptOptions" v-model="form.deptId" :show-count="true" placeholder="请选择所属部门"
+                      @select="hx" :noResultsText="'空'" :noOptionsText="'空'"/>
+        </el-form-item>
+        <!--        <el-form-item label="发布状态" prop="releaseStatus">
+                  <el-select v-model="form.releaseStatus" placeholder="请选择发布状态" filterable>
+                    <el-option
+                      v-for="dict in dict.type.centerdata_release_status"
+                      :key="dict.value"
+                      :label="dict.label"
+                      :value="dict.value"
+                    ></el-option>
+                  </el-select>
+                </el-form-item>-->
+        <!--        <el-form-item label="简介" prop="resIntroduction">
+                  <editor v-model="form.resIntroduction" :min-height="192" maxlength="512"/>
+                </el-form-item>-->
+        <el-form-item label="简介" prop="resIntroduction">
+          <el-input v-model="form.resIntroduction" type="textarea" placeholder="请输入内容" maxlength="200"/>
+        </el-form-item>
+        <el-form-item label="附件" prop="attachId">
+          <fileUpload :value="[form.fileUrl,form.fileName]" v-model="form.fileUrl" :setFileName="setFileName"
+                      :removeFileName="removeFileName" :limit="1"></fileUpload>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 详情 -->
+    <el-dialog :title="title" :visible.sync="seeopen" width="600px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+
+        <el-form-item label="标题" prop="resTitle">
+          <el-input v-model="form.resTitle" placeholder="请输入标题" :disabled="true" maxlength="50"/>
+        </el-form-item>
+
+        <!--        <el-form-item label="简介" prop="resIntroduction">
+                  <el-input v-model="form.resIntroduction" placeholder="请输入简介" :disabled="true" maxlength="512"/>
+                </el-form-item>-->
+
+        <el-form-item label="所属部门" prop="deptId">
+          <treeselect :options="deptOptions" v-model="form.deptId" :show-count="true" placeholder="请选择所属部门"
+                      @select="hx" :disabled="true" :noResultsText="'空'" :noOptionsText="'空'"/>
+        </el-form-item>
+
+        <el-form-item label="简介" prop="resIntroduction" label-width="120px">
+          <el-input v-model="form.resIntroduction" type="textarea" placeholder="请输入内容" maxlength="500"/>
+        </el-form-item>
+
+        <el-form-item label="附件" prop="attachId">
+          <fileUpload :value="form.fileUrl" @input="getUrl" v-model="form.fileUrl"></fileUpload>
+        </el-form-item>
+
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button @click="cancelSel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addReserve,
+  delReserve,
+  getReserve,
+  listReserve,
+  updateReserve,
+  updateRelease
+} from "@/api/data/reserve/reserve";
+import Treeselect from "@riophae/vue-treeselect";
+import {treeselect} from "@/api/system/dept";
+import deptselector from '@/views/components/deptselector.vue'
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+import fileUpload from '@/views/components/FileUpload/index.vue'
+
+export default {
+  name: "Reserve",
+  dicts: ["centerdata_release_status"],
+  components: {
+    Treeselect,
+    deptselector,
+    fileUpload
+  },
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 应急预案表格数据
+      reserveList: [],
+      fileNames: [],
+      // 部门树选项
+      deptOptions: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      seeopen: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        dataStatus: null,
+        dataDeptId: null,
+        resTitle: null,
+        resIntroduction: null,
+        releaseStatus: null,
+        deptId: null,
+        deptName: 0,
+        attachId: null
+      },
+      // 表单参数
+      form: {
+        dataDeptId: 0,
+        releaseStatus: 'centerdata_release_status_no',
+        fileUrl: '',
+        fileName: '',
+        fileUrlList: [],
+        fileNameList: []
+      },
+      // 表单校验
+      rules: {
+        resTitle: [
+          {required: true, message: "标题不能为空", trigger: "blur"}
+        ],
+        deptId: [
+          {required: true, message: "所属部门不能为空", trigger: "change"}
+        ]
+      }
+    };
+  },
+  created() {
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    getUrl(url) {
+      this.form.fileUrl = url;
+    },
+    setFileName(fileName) {
+      let that = this
+      that.fileNames.push(fileName)
+    },
+    removeFileName(index) {
+      let that = this
+      that.fileNames.splice(index, 1);
+      let fileurls = that.form.fileUrl.split(",")
+      fileurls.splice(index, 1)
+      that.form.fileUrl = fileurls.toString()
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data;
+      });
+    },
+    setDataDeptId(e) {
+      this.form.dataDeptId = e.deptId
+      this.form.dataDeptName = e.deptName
+    },
+    hx(node) {
+      this.form.deptId = node.id
+      this.form.deptName = node.label
+      this.$refs.form.validate()
+    },
+    /** 查询应急预案列表 */
+    getList() {
+      this.loading = true;
+      listReserve(this.queryParams).then(response => {
+        this.reserveList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 取消按钮
+    cancelSel() {
+      this.seeopen = false;
+      this.reset();
+    },
+    See(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getReserve(id).then(response => {
+        this.form = response.data;
+        this.seeopen = true;
+        this.title = "查看";
+      });
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        createBy: null,
+        createTime: null,
+        updateBy: null,
+        updateTime: null,
+        dataStatus: "0",
+        dataDeptId: null,
+        resTitle: null,
+        resIntroduction: null,
+        deptId: null,
+        deptName: null,
+        attachId: null
+      };
+      this.fileNames = []
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.queryParams.deptName = 0;
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length !== 1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加应急预案";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getReserve(id).then(response => {
+        const list = response.data.fileUrl.split(',');
+        var item1
+        if (response.data.fileUrl != "") {
+          for (var a = 0; a < list.length; a++) {
+            let listurl = list[a].split('+')
+            this.fileNames.push(listurl[1])
+          }
+        }
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改应急预案";
+      });
+    },
+
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          this.form.fileName = this.fileNames.toString()
+          this.form.fileUrlList = Array.from(document.querySelectorAll('.el-upload-list__item')).map(item => item.querySelector('a').getAttribute('href'))
+          this.form.fileNameList = this.fileNames;
+          if (this.form.id != null) {
+            updateReserve(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            this.form.releaseStatus = "centerdata_release_status_no";
+            addReserve(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否删除选中的数据?').then(function () {
+        return delReserve(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {
+      });
+    },
+
+    handlePublish(row){
+      let ids = row.id || this.ids;
+      let status = "发布", releaseStatus = "centerdata_release_status_yes";
+      if(!ids.includes(",")) {
+        ids = [ids];
+        if (row.releaseStatus.includes("centerdata_release_status_yes")) {
+          status = "撤销";
+          releaseStatus = "centerdata_release_status_no";
+        }
+        this.$modal.confirm('是否' + status + '选中的数据?').then(function () {
+          return updateRelease(ids, releaseStatus);
+        }).then(() => {
+          this.getList();
+          this.$modal.msgSuccess(status + "成功");
+        }).catch((e) => {
+          console.log(e)
+        });
+      }
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('sooka-sponest-center-data/reserve/export', {
+        ...this.queryParams
+      }, `应急预案_${new Date().getTime()}.xlsx`)
+    },
+    // 点击按钮修改是否只查询本级部门用户
+    changeQueryType() {
+      this.queryParams.deptName = this.queryParams.deptName === 0 ? 1 : 0;
+    }
+  }
+};
+</script>