From 5b9d5e7c3b714b2ccb3e9e355a376e4c85bb9f8d Mon Sep 17 00:00:00 2001
From: sgj <1442489573@qq.com>
Date: 星期六, 06 十二月 2025 17:09:07 +0800
Subject: [PATCH] 添加第一版,电子巡更页面

---
 fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/add.html                |   56 +++
 fzzy-igdss-web/src/main/resources/templates/patrol/add.html                           |   67 +++
 fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolConfManager.java       |   37 ++
 fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/PatrolConf.java                    |    3 
 fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolConfController.java |  144 ++++++++
 fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolController.java     |  148 ++++++++
 fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolRecordMapper.java            |   10 
 fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolMapper.java                  |   10 
 fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/patrolConf.html         |  104 +++++
 fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolManager.java           |   38 ++
 fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolConfService.java            |   98 +++++
 fzzy-igdss-web/src/main/resources/templates/patrol/edit.html                          |   68 +++
 fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolService.java                |   68 +++
 fzzy-igdss-web/src/main/resources/templates/patrol/patrol.html                        |  118 ++++++
 fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/edit.html               |   57 +++
 fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolConfMapper.java              |   10 
 fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/BizBaseEntity.java                 |    5 
 17 files changed, 1,041 insertions(+), 0 deletions(-)

diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/BizBaseEntity.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/BizBaseEntity.java
index 0fc1ba5..67da921 100644
--- a/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/BizBaseEntity.java
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/BizBaseEntity.java
@@ -2,6 +2,7 @@
 
 import com.baomidou.mybatisplus.annotation.TableField;
 import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.common.annotation.Excel;
 import lombok.Data;
 
 import javax.persistence.*;
@@ -22,11 +23,13 @@
     private String companyId;
 
     /** 鍒涘缓浜� */
+    @Excel(name = "鍒涘缓鑰�",sort = 25)
     @Column(name = "create_by", columnDefinition = "VARCHAR(100) COMMENT '鍒涘缓浜�'", nullable = false)
     @TableField("create_by")
     private String createBy;
 
     /** 鍒涘缓鏃堕棿 */
+    @Excel(name = "鍒涘缓鏃堕棿",sort = 26, dateFormat = "yyyy-MM-dd HH:mm:ss")
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
     @Column(name = "create_time", columnDefinition = "DATETIME COMMENT '鍒涘缓鏃堕棿'", nullable = false)
     @Temporal(TemporalType.TIMESTAMP)
@@ -34,11 +37,13 @@
     private Date createTime;
 
     /** 鏇存柊浜� */
+    @Excel(name = "鏇存柊鑰�",sort = 27)
     @Column(name = "update_by", columnDefinition = "VARCHAR(100) COMMENT '鏇存柊浜�'")
     @TableField("update_by")
     private String updateBy;
 
     /** 鏇存柊鏃堕棿 */
+    @Excel(name = "鏇存柊鏃堕棿",sort = 28, dateFormat = "yyyy-MM-dd HH:mm:ss")
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
     @Column(name = "update_time", columnDefinition = "DATETIME COMMENT '鏇存柊鏃堕棿'")
     @Temporal(TemporalType.TIMESTAMP)
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/PatrolConf.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/PatrolConf.java
index 19aa3fd..5cd8850 100644
--- a/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/PatrolConf.java
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/domain/PatrolConf.java
@@ -1,6 +1,8 @@
 package com.fzzy.igds.domain;
 
+import com.baomidou.mybatisplus.annotation.IdType;
 import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
 import com.baomidou.mybatisplus.annotation.TableName;
 import lombok.Data;
 import lombok.EqualsAndHashCode;
@@ -25,6 +27,7 @@
 
     @Id
     @Column(name = "batch_id", columnDefinition = "varchar(40) COMMENT '鐝缂栧彿'")
+    @TableId(value = "batch_id", type = IdType.NONE)
     @TableField("batch_id")
     private String batchId;
 
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolConfMapper.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolConfMapper.java
new file mode 100644
index 0000000..0ae5dd3
--- /dev/null
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolConfMapper.java
@@ -0,0 +1,10 @@
+package com.fzzy.igds.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fzzy.igds.domain.PatrolConf;
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface PatrolConfMapper extends BaseMapper<PatrolConf> {
+
+}
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolMapper.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolMapper.java
new file mode 100644
index 0000000..a9d3a78
--- /dev/null
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolMapper.java
@@ -0,0 +1,10 @@
+package com.fzzy.igds.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fzzy.igds.domain.Patrol;
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface PatrolMapper extends BaseMapper<Patrol> {
+
+}
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolRecordMapper.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolRecordMapper.java
new file mode 100644
index 0000000..16b4e92
--- /dev/null
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/mapper/PatrolRecordMapper.java
@@ -0,0 +1,10 @@
+package com.fzzy.igds.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fzzy.igds.domain.PatrolRecord;
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface PatrolRecordMapper extends BaseMapper<PatrolRecord> {
+
+}
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolConfService.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolConfService.java
new file mode 100644
index 0000000..643000f
--- /dev/null
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolConfService.java
@@ -0,0 +1,98 @@
+package com.fzzy.igds.service;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.fzzy.igds.domain.PatrolConf;
+import com.fzzy.igds.mapper.PatrolConfMapper;
+import com.fzzy.igds.utils.ContextUtil;
+import com.ruoyi.common.core.text.Convert;
+import com.ruoyi.common.utils.StringUtils;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+
+import javax.annotation.Resource;
+import java.util.List;
+
+@Slf4j
+@Service
+public class PatrolConfService {
+
+    @Resource
+    private PatrolConfMapper patrolConfMapper;
+
+    /**
+     * 鏌ヨ鍒楄〃鏁版嵁
+     *
+     * @param param 鏌ヨ鍙傛暟
+     * @return 鏁版嵁鍒楄〃
+     */
+    public List<PatrolConf> selectList(PatrolConf param) {
+        QueryWrapper<PatrolConf> queryWrapper = getQueryWrapper(param);
+        return patrolConfMapper.selectList(queryWrapper);
+    }
+
+    /**
+     * 灏佽鏌ヨ鏉′欢
+     *
+     * @param param 鏌ヨ鍙傛暟
+     * @return 鏌ヨ鏋勯�犲櫒
+     */
+    public QueryWrapper<PatrolConf> getQueryWrapper(PatrolConf param) {
+        QueryWrapper<PatrolConf> queryWrapper = new QueryWrapper<>();
+
+        // 璁剧疆鍏徃ID骞朵綔涓烘煡璇㈡潯浠�
+        param.setCompanyId(ContextUtil.getCompanyId());
+        queryWrapper.eq("company_id", param.getCompanyId());
+
+
+
+        // 鎸夊垱寤烘椂闂村�掑簭鎺掑簭
+        queryWrapper.orderByDesc("create_time");
+
+        return queryWrapper;
+    }
+
+    /**
+     * 鏍规嵁ID鏌ヨ璇︽儏
+     *
+     * @param id 涓婚敭ID
+     * @return 瀹炰綋瀵硅薄
+     */
+    public PatrolConf selectById(String id) {
+        return patrolConfMapper.selectById(id);
+    }
+
+    /**
+     * 鎻掑叆鏂版暟鎹�
+     *
+     * @param param 鏁版嵁瀹炰綋
+     * @return 褰卞搷琛屾暟
+     */
+    public int insertData(PatrolConf param) {
+        if (StringUtils.isEmpty(param.getBatchId())) {
+            param.setBatchId(ContextUtil.generateId());
+        }
+        return patrolConfMapper.insert(param);
+    }
+
+    /**
+     * 鏇存柊宸叉湁鏁版嵁
+     *
+     * @param param 鏁版嵁瀹炰綋
+     * @return 褰卞搷琛屾暟
+     */
+    public int updateData(PatrolConf param) {
+        return patrolConfMapper.updateById(param);
+    }
+
+    /**
+     * 鍒犻櫎鎸囧畾ID鐨勬暟鎹�
+     *
+     * @param ids       瑕佸垹闄ょ殑璁板綍ID闆嗗悎锛堥�楀彿鍒嗛殧锛�
+     */
+    public void deleteDataById( String ids) {
+        String[] recordIds = Convert.toStrArray(ids);
+        for (String recordId : recordIds) {
+            patrolConfMapper.deleteById(recordId);
+        }
+    }
+}
diff --git a/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolService.java b/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolService.java
new file mode 100644
index 0000000..c46149a
--- /dev/null
+++ b/fzzy-igdss-core/src/main/java/com/fzzy/igds/service/PatrolService.java
@@ -0,0 +1,68 @@
+package com.fzzy.igds.service;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.fzzy.igds.domain.Patrol;
+import com.fzzy.igds.mapper.PatrolMapper;
+import com.fzzy.igds.utils.ContextUtil;
+import com.ruoyi.common.core.text.Convert;
+import com.ruoyi.common.utils.StringUtils;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+
+import javax.annotation.Resource;
+import java.util.List;
+
+@Slf4j
+@Service
+public class PatrolService {
+
+    @Resource
+    private PatrolMapper patrolMapper;
+
+    public List<Patrol> selectList(Patrol param) {
+        QueryWrapper<Patrol> queryWrapper = getQueryWrapper(param);
+        return patrolMapper.selectList(queryWrapper);
+    }
+
+    /**
+     * 灏佽鏌ヨ鏉′欢
+     *
+     * @param param
+     */
+    public QueryWrapper<Patrol> getQueryWrapper(Patrol param) {
+        QueryWrapper<Patrol> queryWrapper = new QueryWrapper<>();
+
+        param.setCompanyId(ContextUtil.getCompanyId());
+        queryWrapper.eq("company_id", param.getCompanyId());
+
+        if (StringUtils.isNotBlank(param.getDeptId())) {
+            queryWrapper.eq("dept_id", param.getDeptId());
+        }
+        queryWrapper.orderByDesc("create_time");
+
+        return queryWrapper;
+    }
+
+    public Patrol selectById(String id) {
+        return patrolMapper.selectById(id);
+    }
+
+    public int insertData(Patrol param) {
+        if (StringUtils.isEmpty(param.getId())) {
+            param.setId(ContextUtil.generateId());
+        }
+        return patrolMapper.insert(param);
+    }
+
+    public int updateData(Patrol param) {
+        return patrolMapper.updateById(param);
+    }
+
+    public void deleteDataById( String ids) {
+        String[] recordIds = Convert.toStrArray(ids);
+        for (String recordId : recordIds) {
+            patrolMapper.deleteById(recordId);
+        }
+    }
+
+}
diff --git a/fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolConfController.java b/fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolConfController.java
new file mode 100644
index 0000000..8d257b2
--- /dev/null
+++ b/fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolConfController.java
@@ -0,0 +1,144 @@
+package com.fzzy.sys.controller.patrol;
+
+import com.fzzy.igds.domain.PatrolConf;
+import com.fzzy.igds.utils.ContextUtil;
+import com.fzzy.sys.manager.patrol.PatrolConfManager;
+import com.ruoyi.common.annotation.Log;
+import com.ruoyi.common.core.controller.BaseController;
+import com.ruoyi.common.core.domain.AjaxResult;
+import com.ruoyi.common.core.page.TableDataInfo;
+import com.ruoyi.common.enums.BusinessType;
+import com.ruoyi.common.utils.ShiroUtils;
+import com.ruoyi.common.utils.StringUtils;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.ModelMap;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import javax.annotation.Resource;
+import java.util.Date;
+import java.util.List;
+
+@Controller
+@RequestMapping("/patrol/patrolConf")
+public class PatrolConfController extends BaseController {
+
+    private static final String prefix = "patrol/patrolConf";
+
+    @Resource
+    private PatrolConfManager patrolConfManager;
+
+    /**
+     * 宸℃洿閰嶇疆椤甸潰
+     */
+    @RequiresPermissions("web:patrol:patrolConf:view")
+    @GetMapping()
+    public String patrolConf() {
+        return prefix + "/patrolConf";
+    }
+
+    /**
+     * 鏌ヨ宸℃洿閰嶇疆鍒楄〃
+     */
+    @RequiresPermissions("web:patrol:patrolConf:list")
+    @PostMapping("/list")
+    @ResponseBody
+    public TableDataInfo list(PatrolConf param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        startPage();
+        List<PatrolConf> list = patrolConfManager.selectList(param);
+        return getDataTable(list);
+    }
+
+    /**
+     * 瀵煎嚭宸℃洿閰嶇疆鍒楄〃
+     */
+    @Log(title = "宸℃洿閰嶇疆绠$悊", businessType = BusinessType.EXPORT)
+    @RequiresPermissions("web:patrol:patrolConf:export")
+    @PostMapping("/export")
+    @ResponseBody
+    public AjaxResult export(PatrolConf param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        List<PatrolConf> list = patrolConfManager.selectList(param);
+        ExcelUtil<PatrolConf> util = new ExcelUtil<>(PatrolConf.class);
+        return util.exportExcel(list, "宸℃洿閰嶇疆鏁版嵁");
+    }
+
+    /**
+     * 鏂板宸℃洿閰嶇疆椤甸潰
+     */
+    @GetMapping("/add")
+    public String add(ModelMap mmap) {
+        return prefix + "/add";
+    }
+
+    /**
+     * 鏂板宸℃洿閰嶇疆鏁版嵁
+     */
+    @RequiresPermissions("web:patrol:patrolConf:add")
+    @Log(title = "宸℃洿閰嶇疆绠$悊", businessType = BusinessType.INSERT)
+    @PostMapping("/add")
+    @ResponseBody
+    public AjaxResult addSave(@Validated PatrolConf param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        param.setCreateBy(getLoginName());
+        param.setCreateTime(new Date());
+        if (StringUtils.isEmpty(param.getBatchId())) {
+            param.setBatchId(ContextUtil.generateId());
+        }
+        return toAjax(patrolConfManager.insertData(param));
+    }
+
+    /**
+     * 淇敼宸℃洿閰嶇疆椤甸潰
+     */
+    @RequiresPermissions("web:patrol:patrolConf:edit")
+    @GetMapping("/edit/{id}")
+    public String edit(@PathVariable("id") String id, ModelMap mmap) {
+        PatrolConf record = patrolConfManager.selectById(id);
+        mmap.put("patrolConf", record);
+        return prefix + "/edit";
+    }
+
+    /**
+     * 淇敼宸℃洿閰嶇疆鏁版嵁
+     */
+    @RequiresPermissions("web:patrol:patrolConf:edit")
+    @Log(title = "宸℃洿閰嶇疆绠$悊", businessType = BusinessType.UPDATE)
+    @PostMapping("/edit")
+    @ResponseBody
+    public AjaxResult editSave(@Validated PatrolConf param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        param.setUpdateBy(getLoginName());
+        param.setUpdateTime(new Date());
+        PatrolConf patrolConf = patrolConfManager.selectById(param.getBatchId());
+        if (patrolConf == null) {
+            param.setBatchId(ContextUtil.generateId());
+            return toAjax(patrolConfManager.insertData(param));
+        }
+
+        return toAjax(patrolConfManager.updateData(param));
+    }
+
+    /**
+     * 鍒犻櫎宸℃洿閰嶇疆鏁版嵁
+     */
+    @RequiresPermissions("web:patrol:patrolConf:remove")
+    @Log(title = "宸℃洿閰嶇疆绠$悊", businessType = BusinessType.DELETE)
+    @PostMapping("/remove")
+    @ResponseBody
+    public AjaxResult remove(String ids) {
+        patrolConfManager.deleteDataById( ids);
+        return success();
+    }
+}
diff --git a/fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolController.java b/fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolController.java
new file mode 100644
index 0000000..2fd5edd
--- /dev/null
+++ b/fzzy-igdss-web/src/main/java/com/fzzy/sys/controller/patrol/PatrolController.java
@@ -0,0 +1,148 @@
+package com.fzzy.sys.controller.patrol;
+
+import com.fzzy.igds.domain.Patrol;
+import com.fzzy.igds.utils.ContextUtil;
+import com.fzzy.sys.manager.patrol.PatrolManager;
+import com.ruoyi.common.annotation.Log;
+import com.ruoyi.common.core.controller.BaseController;
+import com.ruoyi.common.core.domain.AjaxResult;
+import com.ruoyi.common.core.page.TableDataInfo;
+import com.ruoyi.common.enums.BusinessType;
+import com.ruoyi.common.utils.ShiroUtils;
+import com.ruoyi.common.utils.StringUtils;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.ModelMap;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import javax.annotation.Resource;
+import java.util.Date;
+import java.util.List;
+
+@Controller
+@RequestMapping("/patrol")
+public class PatrolController extends BaseController {
+
+    private static final String prefix = "patrol";
+
+    @Resource
+    private PatrolManager patrolManager;
+
+    /**
+     * 鐢靛瓙宸℃洿椤甸潰
+     *
+     * @author sgj
+     * @date 2025/12/06
+     */
+    @RequiresPermissions("web:patrol:view")
+    @GetMapping()
+    public String patrol() {
+        return prefix + "/patrol";
+    }
+
+    /**
+     * 鏌ヨ鐢靛瓙宸℃洿鍒楄〃
+     */
+    @RequiresPermissions("web:patrol:list")
+    @PostMapping("/list")
+    @ResponseBody
+    public TableDataInfo list(Patrol param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        startPage();
+        List<Patrol> list = patrolManager.selectList(param);
+        return getDataTable(list);
+    }
+
+    /**
+     * 瀵煎嚭鐢靛瓙宸℃洿鍒楄〃
+     */
+    @Log(title = "鐢靛瓙宸℃洿绠$悊", businessType = BusinessType.EXPORT)
+    @RequiresPermissions("web:patrol:export")
+    @PostMapping("/export")
+    @ResponseBody
+    public AjaxResult export(Patrol param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        List<Patrol> list = patrolManager.selectList(param);
+        ExcelUtil<Patrol> util = new ExcelUtil<>(Patrol.class);
+        return util.exportExcel(list, "鐢靛瓙宸℃洿鏁版嵁");
+    }
+
+    /**
+     * 鏂板鐢靛瓙宸℃洿椤甸潰
+     */
+    @GetMapping("/add")
+    public String add(ModelMap mmap) {
+        return prefix + "/add";
+    }
+
+    /**
+     * 鏂板鐢靛瓙宸℃洿鏁版嵁
+     */
+    @RequiresPermissions("web:patrol:add")
+    @Log(title = "鐢靛瓙宸℃洿绠$悊", businessType = BusinessType.INSERT)
+    @PostMapping("/add")
+    @ResponseBody
+    public AjaxResult addSave(@Validated Patrol param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        param.setCreateBy(getLoginName());
+        param.setCreateTime(new Date());
+        if (StringUtils.isEmpty(param.getId())) {
+            param.setId(ContextUtil.generateId());
+        }
+        return toAjax(patrolManager.insertData(param));
+    }
+
+    /**
+     * 淇敼鐢靛瓙宸℃洿椤甸潰
+     */
+    @RequiresPermissions("web:patrol:edit")
+    @GetMapping("/edit/{id}")
+    public String edit(@PathVariable("id") String id, ModelMap mmap) {
+        String companyId = ShiroUtils.getLoginUserCompanyId();
+        Patrol record = patrolManager.selectById(id);
+        mmap.put("patrol", record);
+        return prefix + "/edit";
+    }
+
+    /**
+     * 淇敼鐢靛瓙宸℃洿鏁版嵁
+     */
+    @RequiresPermissions("web:patrol:edit")
+    @Log(title = "鐢靛瓙宸℃洿绠$悊", businessType = BusinessType.UPDATE)
+    @PostMapping("/edit")
+    @ResponseBody
+    public AjaxResult editSave(@Validated Patrol param) {
+        if (null == param.getCompanyId()) {
+            param.setCompanyId(ShiroUtils.getLoginUserCompanyId());
+        }
+        param.setUpdateBy(getLoginName());
+        param.setUpdateTime(new Date());
+        Patrol patrol = patrolManager.selectById(param.getId());
+        if (patrol == null) {
+            param.setId(ContextUtil.generateId());
+            return toAjax(patrolManager.insertData(param));
+        }
+
+        return toAjax(patrolManager.updateData(param));
+    }
+
+    /**
+     * 鍒犻櫎鐢靛瓙宸℃洿鏁版嵁
+     */
+    @RequiresPermissions("web:patrol:remove")
+    @Log(title = "鐢靛瓙宸℃洿绠$悊", businessType = BusinessType.DELETE)
+    @PostMapping("/remove")
+    @ResponseBody
+    public AjaxResult remove(String ids) {
+        patrolManager.deleteDataById(ids);
+        return success();
+    }
+}
diff --git a/fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolConfManager.java b/fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolConfManager.java
new file mode 100644
index 0000000..492066a
--- /dev/null
+++ b/fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolConfManager.java
@@ -0,0 +1,37 @@
+package com.fzzy.sys.manager.patrol;
+
+import com.fzzy.igds.domain.PatrolConf;
+import com.fzzy.igds.service.PatrolConfService;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Component;
+
+import javax.annotation.Resource;
+import java.util.List;
+
+@Slf4j
+@Component
+public class PatrolConfManager {
+
+    @Resource
+    private PatrolConfService patrolConfService;
+
+    public List<PatrolConf> selectList(PatrolConf param) {
+        return patrolConfService.selectList(param);
+    }
+
+    public PatrolConf selectById(String id) {
+        return patrolConfService.selectById(id);
+    }
+
+    public int insertData(PatrolConf param) {
+        return patrolConfService.insertData(param);
+    }
+
+    public int updateData(PatrolConf param) {
+        return patrolConfService.updateData(param);
+    }
+
+    public void deleteDataById( String ids) {
+        patrolConfService.deleteDataById( ids);
+    }
+}
diff --git a/fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolManager.java b/fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolManager.java
new file mode 100644
index 0000000..af3068e
--- /dev/null
+++ b/fzzy-igdss-web/src/main/java/com/fzzy/sys/manager/patrol/PatrolManager.java
@@ -0,0 +1,38 @@
+package com.fzzy.sys.manager.patrol;
+
+import com.fzzy.igds.domain.Patrol;
+import com.fzzy.igds.service.PatrolService;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Component;
+
+import javax.annotation.Resource;
+import java.util.List;
+
+@Slf4j
+@Component
+public class PatrolManager {
+
+    @Resource
+    private PatrolService patrolService;
+
+    public List<Patrol> selectList(Patrol param) {
+        return patrolService.selectList(param);
+    }
+
+    public Patrol selectById( String id) {
+        return patrolService.selectById( id);
+    }
+
+    public int insertData(Patrol param) {
+        return patrolService.insertData(param);
+    }
+
+    public int updateData(Patrol param) {
+        return patrolService.updateData(param);
+    }
+
+    public void deleteDataById( String ids) {
+         patrolService.deleteDataById(ids);
+    }
+
+}
diff --git a/fzzy-igdss-web/src/main/resources/templates/patrol/add.html b/fzzy-igdss-web/src/main/resources/templates/patrol/add.html
new file mode 100644
index 0000000..18722c7
--- /dev/null
+++ b/fzzy-igdss-web/src/main/resources/templates/patrol/add.html
@@ -0,0 +1,67 @@
+<!DOCTYPE html>
+<html lang="zh" xmlns:th="http://www.thymeleaf.org">
+<head>
+    <th:block th:include="include :: header('鏂板鐢靛瓙宸℃洿淇℃伅')"/>
+    <th:block th:include="include :: select2-css"/>
+</head>
+<body>
+<div class="main-content">
+    <form id="form-patrol-add" class="form-horizontal">
+        <input name="deptId" type="hidden" id="treeId"/>
+
+        <div class="row">
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">鎵�灞炲簱鍖猴細</label>
+                    <div class="col-sm-8">
+                        <input name="deptId" placeholder="璇疯緭鍏ュ悕绉�" class="form-control " type="text" maxlength="100"
+                               required>
+                    </div>
+                </div>
+            </div>
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label">鐝缂栧彿锛�</label>
+                    <div class="col-sm-8">
+                        <input name="batchId" id="batchId" placeholder="璇疯緭鍏�" class="form-control " type="text"
+                               maxlength="30">
+                    </div>
+                </div>
+            </div>
+        </div>
+        <div class="row">
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">宸¢�讳汉锛�</label>
+                    <div class="col-sm-8">
+                        <input name="userName" id="userName" placeholder="璇疯緭鍏�" class="form-control " type="text"
+                               maxlength="30" required>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </form>
+</div>
+<th:block th:include="include :: footer"/>
+<th:block th:include="include :: select2-js"/>
+<script>
+    var prefix = ctx + "patrol";
+
+    $("#form-cabinet-add").validate({
+        onkeyup: false,
+        rules: {},
+        messages: {},
+        focusCleanup: true
+    });
+
+    // 纭畾鎸夐挳 鎻愪氦鏁版嵁
+    function submitHandler() {
+        if ($.validate.form()) {
+            $.operate.save(prefix + "/add", $('#form-patrol-add').serialize());
+        }
+    }
+
+
+</script>
+</body>
+</html>
\ No newline at end of file
diff --git a/fzzy-igdss-web/src/main/resources/templates/patrol/edit.html b/fzzy-igdss-web/src/main/resources/templates/patrol/edit.html
new file mode 100644
index 0000000..0575c76
--- /dev/null
+++ b/fzzy-igdss-web/src/main/resources/templates/patrol/edit.html
@@ -0,0 +1,68 @@
+<!DOCTYPE html>
+<html lang="zh" xmlns:th="http://www.thymeleaf.org">
+<head>
+    <th:block th:include="include :: header('淇敼鐢靛瓙宸℃洿淇℃伅')"/>
+    <th:block th:include="include :: select2-css"/>
+</head>
+<body class="white-bg">
+<div class="wrapper wrapper-content animated fadeInRight ibox-content">
+    <form class="form-horizontal m" id="form-patrol-edit" th:object="${patrol}">
+        <input id="id" name="id" th:field="*{id}" type="hidden">
+        <div class="row">
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">鎵�灞炲簱鍖猴細</label>
+                    <div class="col-sm-8">
+                        <input name="deptId" placeholder="璇疯緭鍏ュ悕绉�" th:field="*{deptId}" class="form-control " type="text"
+                               maxlength="100"
+                               required>
+                    </div>
+                </div>
+            </div>
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label">鐝缂栧彿锛�</label>
+                    <div class="col-sm-8">
+                        <input name="batchId" id="batchId" th:field="*{batchId}" placeholder="璇疯緭鍏�" class="form-control "
+                               type="text" maxlength="30">
+                    </div>
+                </div>
+            </div>
+        </div>
+        <div class="row">
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">宸¢�讳汉锛�</label>
+                    <div class="col-sm-8">
+                        <input name="userName" id="userName" th:field="*{userName}" placeholder="璇疯緭鍏�" class="form-control "
+                               type="text"
+                               maxlength="30" required>
+                    </div>
+                </div>
+            </div>
+        </div>
+
+    </form>
+</div>
+<th:block th:include="include :: footer"/>
+<th:block th:include="include :: select2-js"/>
+<script type="text/javascript">
+
+    var prefix = ctx + "patrol";
+
+
+    $("#form-cabinet-edit").validate({
+        onkeyup: false,
+        rules: {},
+        messages: {},
+        focusCleanup: true
+    });
+
+    function submitHandler() {
+        if ($.validate.form()) {
+            $.operate.save(prefix + "/edit", $('#form-patrol-edit').serialize());
+        }
+    }
+</script>
+</body>
+</html>
diff --git a/fzzy-igdss-web/src/main/resources/templates/patrol/patrol.html b/fzzy-igdss-web/src/main/resources/templates/patrol/patrol.html
new file mode 100644
index 0000000..1ec189f
--- /dev/null
+++ b/fzzy-igdss-web/src/main/resources/templates/patrol/patrol.html
@@ -0,0 +1,118 @@
+<!DOCTYPE html>
+<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
+<head>
+    <th:block th:include="include :: header('鍙傛暟鍒楄〃')" />
+    <th:block th:include="include :: select2-css" />
+</head>
+<body class="gray-bg">
+<div class="container-div">
+    <div class="row">
+        <div class="col-sm-12 search-collapse">
+            <form id="property-form">
+                <div class="select-list">
+                    <ul>
+                        <li>
+                            鍚嶇О锛�<input type="text" name="name"/>
+                        </li>
+                        <li>
+                            <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;鎼滅储</a>
+                            <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;閲嶇疆</a>
+                        </li>
+                    </ul>
+                </div>
+            </form>
+        </div>
+
+        <div class="btn-group-sm" id="toolbar" role="group">
+            <a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="web:patrol:add">
+                <i class="fa fa-plus"></i> 鏂板
+            </a>
+            <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="web:patrol:edit">
+                <i class="fa fa-edit"></i> 淇敼
+            </a>
+            <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="web:patrol:remove">
+                <i class="fa fa-remove"></i> 鍒犻櫎
+            </a>
+            <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="web:patrol:export">
+                <i class="fa fa-download"></i> 瀵煎嚭
+            </a>
+            <a class="btn btn-success" onclick="openPatrolConf()" shiro:hasPermission="web:patrol:patrolConf:edit">
+                <i class="fa fa-plus"></i> 宸℃洿閰嶇疆
+            </a>
+        </div>
+        <div class="col-sm-12 select-table table-striped">
+            <table id="bootstrap-table"></table>
+        </div>
+    </div>
+</div>
+<th:block th:include="include :: footer" />
+<th:block th:include="include :: select2-js" />
+<script th:inline="javascript">
+    var editFlag = [[${@permission.hasPermi('web:patrol:edit')}]];
+    var removeFlag = [[${@permission.hasPermi('web:patrol:remove')}]];
+    var prefix = ctx + "patrol";
+
+    $(function() {
+
+        var options = {
+            url: prefix + "/list",
+            createUrl: prefix + "/add",
+            updateUrl: prefix + "/edit/{id}",
+            removeUrl: prefix + "/remove",
+            exportUrl: prefix + "/export",
+            sortName: "id",
+            sortOrder: "asc",
+            modalName: "鍙傛暟",
+            columns: [{
+                checkbox: true
+            },
+                {
+                    field: 'id',
+                    title: '涓婚敭',
+                    visible: false,
+                },
+                {
+                    field: 'deptId',
+                    title: '鎵�灞炲簱鍖�',
+                    align: 'left',
+                    // formatter: function(value, row, index) {
+                    //     return $.table.tooltip(value);
+                    // }
+                },
+                {
+                    field: 'batchId',
+                    title: '鐝缂栧彿',
+                    align: 'left',
+                    // formatter: function(value, row, index) {
+                    //     return $.table.tooltip(value);
+                    // }
+                },
+                {
+                    field: 'userName',
+                    title: '宸¢�讳汉',
+                    // formatter: function(value, row, index) {
+                    //     return $.table.tooltip(value);
+                    // }
+                },
+                {
+                    title: '鎿嶄綔',
+                    align: 'center',
+                    formatter: function(value, row, index) {
+                        var actions = [];
+                        actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>缂栬緫</a> ');
+                        actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>鍒犻櫎</a>');
+                        return actions.join('');
+                    }
+                }]
+        };
+        $.table.init(options);
+    });
+
+    function openPatrolConf() {
+        var url = ctx + "patrol/patrolConf";
+        $.modal.openTab("宸℃洿閰嶇疆", url);
+    }
+
+</script>
+</body>
+</html>
\ No newline at end of file
diff --git a/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/add.html b/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/add.html
new file mode 100644
index 0000000..6737a72
--- /dev/null
+++ b/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/add.html
@@ -0,0 +1,56 @@
+<!DOCTYPE html>
+<html lang="zh" xmlns:th="http://www.thymeleaf.org">
+<head>
+    <th:block th:include="include :: header('鏂板宸℃洿閰嶇疆')"/>
+    <th:block th:include="include :: select2-css"/>
+</head>
+<body>
+<div class="main-content">
+    <form id="form-patrol-add" class="form-horizontal">
+        <input name="deptId" type="hidden" id="treeId"/>
+
+        <div class="row">
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">鐝鍚嶇О锛�</label>
+                    <div class="col-sm-8">
+                        <input name="batchName" id="batchName" placeholder="璇疯緭鍏�" class="form-control " type="text"
+                               maxlength="30" required>
+                    </div>
+                </div>
+            </div>
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">宸¢�讳汉锛�</label>
+                    <div class="col-sm-8">
+                        <input name="userName" id="userName" placeholder="璇疯緭鍏�" class="form-control " type="text"
+                               maxlength="30" required>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </form>
+</div>
+<th:block th:include="include :: footer"/>
+<th:block th:include="include :: select2-js"/>
+<script>
+    var prefix = ctx + "patrol/patrolConf";
+
+    $("#form-cabinet-add").validate({
+        onkeyup: false,
+        rules: {},
+        messages: {},
+        focusCleanup: true
+    });
+
+    // 纭畾鎸夐挳 鎻愪氦鏁版嵁
+    function submitHandler() {
+        if ($.validate.form()) {
+            $.operate.save(prefix + "/add", $('#form-patrol-add').serialize());
+        }
+    }
+
+
+</script>
+</body>
+</html>
\ No newline at end of file
diff --git a/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/edit.html b/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/edit.html
new file mode 100644
index 0000000..0ad8922
--- /dev/null
+++ b/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/edit.html
@@ -0,0 +1,57 @@
+<!DOCTYPE html>
+<html lang="zh" xmlns:th="http://www.thymeleaf.org">
+<head>
+    <th:block th:include="include :: header('淇敼宸℃洿閰嶇疆')"/>
+    <th:block th:include="include :: select2-css"/>
+</head>
+<body class="white-bg">
+<div class="wrapper wrapper-content animated fadeInRight ibox-content">
+    <form class="form-horizontal m" id="form-patrol-edit" th:object="${patrolConf}">
+        <input id="id" name="id" th:field="*{batchId}" type="hidden">
+        <div class="row">
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">鐝鍚嶇О锛�</label>
+                    <div class="col-sm-8">
+                        <input name="batchName" id="batchName" th:field="*{batchName}" placeholder="璇疯緭鍏�" class="form-control "
+                               type="text"
+                               maxlength="30" required>
+                    </div>
+                </div>
+            </div>
+            <div class="col-sm-6">
+                <div class="form-group">
+                    <label class="col-sm-4 control-label is-required">宸¢�讳汉锛�</label>
+                    <div class="col-sm-8">
+                        <input name="userName" id="userName" th:field="*{userName}" placeholder="璇疯緭鍏�" class="form-control "
+                               type="text"
+                               maxlength="30" required>
+                    </div>
+                </div>
+            </div>
+        </div>
+
+    </form>
+</div>
+<th:block th:include="include :: footer"/>
+<th:block th:include="include :: select2-js"/>
+<script type="text/javascript">
+
+    var prefix = ctx + "patrol/patrolConf";
+
+
+    $("#form-cabinet-edit").validate({
+        onkeyup: false,
+        rules: {},
+        messages: {},
+        focusCleanup: true
+    });
+
+    function submitHandler() {
+        if ($.validate.form()) {
+            $.operate.save(prefix + "/edit", $('#form-patrol-edit').serialize());
+        }
+    }
+</script>
+</body>
+</html>
diff --git a/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/patrolConf.html b/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/patrolConf.html
new file mode 100644
index 0000000..c5b0637
--- /dev/null
+++ b/fzzy-igdss-web/src/main/resources/templates/patrol/patrolConf/patrolConf.html
@@ -0,0 +1,104 @@
+<!DOCTYPE html>
+<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
+<head>
+    <th:block th:include="include :: header('鍙傛暟鍒楄〃')" />
+    <th:block th:include="include :: select2-css" />
+</head>
+<body class="gray-bg">
+<div class="container-div">
+    <div class="row">
+        <div class="col-sm-12 search-collapse">
+            <form id="property-form">
+                <div class="select-list">
+                    <ul>
+                        <li>
+                            鍚嶇О锛�<input type="text" name="name"/>
+                        </li>
+                        <li>
+                            <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;鎼滅储</a>
+                            <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;閲嶇疆</a>
+                        </li>
+                    </ul>
+                </div>
+            </form>
+        </div>
+
+        <div class="btn-group-sm" id="toolbar" role="group">
+            <a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="web:patrol:patrolConf:add">
+                <i class="fa fa-plus"></i> 鏂板
+            </a>
+            <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="web:patrol:patrolConf:edit">
+                <i class="fa fa-edit"></i> 淇敼
+            </a>
+            <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="web:patrol:patrolConf:remove">
+                <i class="fa fa-remove"></i> 鍒犻櫎
+            </a>
+            <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="web:patrol:patrolConf:export">
+                <i class="fa fa-download"></i> 瀵煎嚭
+            </a>
+        </div>
+        <div class="col-sm-12 select-table table-striped">
+            <table id="bootstrap-table"></table>
+        </div>
+    </div>
+</div>
+<th:block th:include="include :: footer" />
+<th:block th:include="include :: select2-js" />
+<script th:inline="javascript">
+    var editFlag = [[${@permission.hasPermi('web:patrol:patrolConf:edit')}]];
+    var removeFlag = [[${@permission.hasPermi('web:patrol:patrolConf:remove')}]];
+    var prefix = ctx + "patrol/patrolConf";
+
+    $(function() {
+
+        var options = {
+            url: prefix + "/list",
+            createUrl: prefix + "/add",
+            updateUrl: prefix + "/edit/{id}",
+            removeUrl: prefix + "/remove",
+            exportUrl: prefix + "/export",
+            sortName: "batchId",
+            sortOrder: "asc",
+            modalName: "鍙傛暟",
+            columns: [{
+                checkbox: true
+            },
+                {
+                    field: 'batchId',
+                    title: '涓婚敭',
+                    visible: false,
+                },
+                {
+                    field: 'batchName',
+                    title: '鐝鍚嶇О',
+                    align: 'left',
+                    // formatter: function(value, row, index) {
+                    //     return $.table.tooltip(value);
+                    // }
+                },
+                {
+                    field: 'userName',
+                    title: '宸¢�讳汉',
+                    // formatter: function(value, row, index) {
+                    //     return $.table.tooltip(value);
+                    // }
+                },
+                {
+                    title: '鎿嶄綔',
+                    align: 'center',
+                    formatter: function(value, row, index) {
+                        var actions = [];
+                        actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.batchId + '\')"><i class="fa fa-edit"></i>缂栬緫</a> ');
+                        actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.batchId + '\')"><i class="fa fa-remove"></i>鍒犻櫎</a>');
+                        return actions.join('');
+                    }
+                }]
+        };
+        $.table.init(options);
+    });
+
+
+
+</script>
+</body>
+</html>
\ No newline at end of file

--
Gitblit v1.9.3