Ver código fonte

发改委领导批示

LIVE_YE 2 anos atrás
pai
commit
7406bc0664

+ 126 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/fgw/FgwLdpsController.java

@@ -0,0 +1,126 @@
+package com.ruoyi.web.controller.fgw;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+
+import com.ruoyi.system.domain.projectV2.ZsyzLdps;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.ruoyi.common.annotation.Log;
+import com.ruoyi.common.core.controller.BaseController;
+import com.ruoyi.common.core.domain.AjaxResult;
+import com.ruoyi.common.enums.BusinessType;
+import com.ruoyi.system.domain.fgw.FgwLdps;
+import com.ruoyi.system.service.fgw.IFgwLdpsService;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.common.core.page.TableDataInfo;
+
+/**
+ * 发改委_领导批示Controller
+ * 
+ * @author ruoyi
+ * @date 2023-03-24
+ */
+@RestController
+@RequestMapping("/fgw/ldps")
+public class FgwLdpsController extends BaseController
+{
+    @Autowired
+    private IFgwLdpsService fgwLdpsService;
+
+    /**
+     * 查询发改委_领导批示列表
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(FgwLdps fgwLdps)
+    {
+        startPage();
+        List<FgwLdps> list = fgwLdpsService.selectFgwLdpsList(fgwLdps);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出发改委_领导批示列表
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:export')")
+    @Log(title = "发改委_领导批示", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, FgwLdps fgwLdps)
+    {
+        List<FgwLdps> list = fgwLdpsService.selectFgwLdpsList(fgwLdps);
+        ExcelUtil<FgwLdps> util = new ExcelUtil<FgwLdps>(FgwLdps.class);
+        util.exportExcel(response, list, "发改委_领导批示数据");
+    }
+
+    /**
+     * 获取发改委_领导批示详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return success(fgwLdpsService.selectFgwLdpsById(id));
+    }
+
+    /**
+     * 查询当前账号最新的暂存数据
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:queryZc')")
+    @GetMapping(value = "/zc")
+    public AjaxResult getInfoZc(FgwLdps fgwLdps)
+    {
+        return success(fgwLdpsService.getInfoZc(fgwLdps));
+    }
+
+    /**
+     * 新增发改委_领导批示
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:add')")
+    @Log(title = "发改委_领导批示", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody FgwLdps fgwLdps)
+    {
+        return toAjax(fgwLdpsService.insertFgwLdps(fgwLdps));
+    }
+
+    /**
+     * 修改发改委_领导批示
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:edit')")
+    @Log(title = "发改委_领导批示", businessType = BusinessType.UPDATE)
+    @PostMapping("/put")
+    public AjaxResult edit(@RequestBody FgwLdps fgwLdps)
+    {
+        return toAjax(fgwLdpsService.updateFgwLdps(fgwLdps));
+    }
+
+    /**
+     * 删除发改委_领导批示
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:remove')")
+    @Log(title = "发改委_领导批示", businessType = BusinessType.DELETE)
+	@GetMapping("/delete/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(fgwLdpsService.deleteFgwLdpsByIds(ids));
+    }
+
+    /**
+     * 删除招商引资_领导批示
+     */
+    @PreAuthorize("@ss.hasPermi('fgw:ldps:remove')")
+    @GetMapping("delete")
+    public AjaxResult remove(Long id)
+    {
+        return toAjax(fgwLdpsService.deleteFgwLdpsById(id));
+    }
+}

+ 208 - 0
ruoyi-system/src/main/java/com/ruoyi/system/domain/fgw/FgwLdps.java

@@ -0,0 +1,208 @@
+package com.ruoyi.system.domain.fgw;
+
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+import com.ruoyi.common.annotation.Excel;
+import com.ruoyi.common.core.domain.BaseEntity;
+
+/**
+ * 发改委_领导批示对象 fgw_ldps
+ * 
+ * @author ruoyi
+ * @date 2023-03-24
+ */
+public class FgwLdps extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** $column.columnComment */
+    private Long id;
+
+    /** 项目ID */
+    @Excel(name = "项目ID")
+    private Long xmId;
+
+    /** 项目编号 */
+    @Excel(name = "项目编号")
+    private String xmbh;
+
+    /** 项目名称 */
+    @Excel(name = "项目名称")
+    private String xmmc;
+
+    /** 批示人id */
+    @Excel(name = "批示人id")
+    private Long psnrId;
+
+    /** 批示内容 */
+    @Excel(name = "批示内容")
+    private String psnr;
+
+    /** 暂存内容 */
+    @Excel(name = "暂存内容")
+    private String zcpsnr;
+
+    /** 部门id */
+    @Excel(name = "部门id")
+    private Long deptId;
+
+    /** 创建者 */
+    @Excel(name = "创建者")
+    private String psr;
+
+    /** 创建时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date cjsj;
+
+    /** 更新者 */
+    @Excel(name = "更新者")
+    private String xgr;
+
+    /** 更新时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date xgsj;
+
+    /** 暂存还是保存 (1:暂存,2:保存)*/
+    private String type;
+
+
+    public String getType() {
+        return type;
+    }
+
+    public void setType(String type) {
+        this.type = type;
+    }
+
+    public void setId(Long id) 
+    {
+        this.id = id;
+    }
+
+    public Long getId() 
+    {
+        return id;
+    }
+    public void setXmId(Long xmId) 
+    {
+        this.xmId = xmId;
+    }
+
+    public Long getXmId() 
+    {
+        return xmId;
+    }
+    public void setXmbh(String xmbh) 
+    {
+        this.xmbh = xmbh;
+    }
+
+    public String getXmbh() 
+    {
+        return xmbh;
+    }
+    public void setXmmc(String xmmc) 
+    {
+        this.xmmc = xmmc;
+    }
+
+    public String getXmmc() 
+    {
+        return xmmc;
+    }
+    public void setPsnrId(Long psnrId) 
+    {
+        this.psnrId = psnrId;
+    }
+
+    public Long getPsnrId() 
+    {
+        return psnrId;
+    }
+    public void setPsnr(String psnr) 
+    {
+        this.psnr = psnr;
+    }
+
+    public String getPsnr() 
+    {
+        return psnr;
+    }
+    public void setZcpsnr(String zcpsnr) 
+    {
+        this.zcpsnr = zcpsnr;
+    }
+
+    public String getZcpsnr() 
+    {
+        return zcpsnr;
+    }
+    public void setDeptId(Long deptId) 
+    {
+        this.deptId = deptId;
+    }
+
+    public Long getDeptId() 
+    {
+        return deptId;
+    }
+    public void setPsr(String psr) 
+    {
+        this.psr = psr;
+    }
+
+    public String getPsr() 
+    {
+        return psr;
+    }
+    public void setCjsj(Date cjsj) 
+    {
+        this.cjsj = cjsj;
+    }
+
+    public Date getCjsj() 
+    {
+        return cjsj;
+    }
+    public void setXgr(String xgr) 
+    {
+        this.xgr = xgr;
+    }
+
+    public String getXgr() 
+    {
+        return xgr;
+    }
+    public void setXgsj(Date xgsj) 
+    {
+        this.xgsj = xgsj;
+    }
+
+    public Date getXgsj() 
+    {
+        return xgsj;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("xmId", getXmId())
+            .append("xmbh", getXmbh())
+            .append("xmmc", getXmmc())
+            .append("psnrId", getPsnrId())
+            .append("psnr", getPsnr())
+            .append("zcpsnr", getZcpsnr())
+            .append("deptId", getDeptId())
+            .append("psr", getPsr())
+            .append("cjsj", getCjsj())
+            .append("xgr", getXgr())
+            .append("xgsj", getXgsj())
+            .append("remark", getRemark())
+            .toString();
+    }
+}

+ 25 - 1
ruoyi-system/src/main/java/com/ruoyi/system/domain/fgw/FgwXmsb.java

@@ -100,9 +100,12 @@ public class FgwXmsb extends BaseEntity
     private Long jsDeptId;
 
     /** 申报部门id */
-    @Excel(name = "申报部门id")
     private Long deptId;
 
+    /** 申报部门 */
+    @Excel(name = "申报部门")
+    private String deptName;
+
     /** 申报人id */
     @Excel(name = "申报人id")
     private Long userId;
@@ -138,6 +141,19 @@ public class FgwXmsb extends BaseEntity
      */
     private List<FgwFj> fjList;
 
+    /***
+     * 最新的一次领导批示内容
+     */
+    private String psnr;
+
+    public String getPsnr() {
+        return psnr;
+    }
+
+    public void setPsnr(String psnr) {
+        this.psnr = psnr;
+    }
+
     public List<FgwFj> getFjList() {
         return fjList;
     }
@@ -399,6 +415,14 @@ public class FgwXmsb extends BaseEntity
         return status;
     }
 
+    public String getDeptName() {
+        return deptName;
+    }
+
+    public void setDeptName(String deptName) {
+        this.deptName = deptName;
+    }
+
     @Override
     public String toString() {
         return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)

+ 63 - 0
ruoyi-system/src/main/java/com/ruoyi/system/mapper/fgw/FgwLdpsMapper.java

@@ -0,0 +1,63 @@
+package com.ruoyi.system.mapper.fgw;
+
+import java.util.List;
+import com.ruoyi.system.domain.fgw.FgwLdps;
+
+/**
+ * 发改委_领导批示Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-03-24
+ */
+public interface FgwLdpsMapper 
+{
+    /**
+     * 查询发改委_领导批示
+     * 
+     * @param id 发改委_领导批示主键
+     * @return 发改委_领导批示
+     */
+    public FgwLdps selectFgwLdpsById(Long id);
+
+    /**
+     * 查询发改委_领导批示列表
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 发改委_领导批示集合
+     */
+    public List<FgwLdps> selectFgwLdpsList(FgwLdps fgwLdps);
+
+    /**
+     * 新增发改委_领导批示
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 结果
+     */
+    public int insertFgwLdps(FgwLdps fgwLdps);
+
+    /**
+     * 修改发改委_领导批示
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 结果
+     */
+    public int updateFgwLdps(FgwLdps fgwLdps);
+
+    /**
+     * 删除发改委_领导批示
+     * 
+     * @param id 发改委_领导批示主键
+     * @return 结果
+     */
+    public int deleteFgwLdpsById(Long id);
+
+    /**
+     * 批量删除发改委_领导批示
+     * 
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteFgwLdpsByIds(Long[] ids);
+
+    String getInfoZc(FgwLdps fgwLdps);
+}

+ 63 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/fgw/IFgwLdpsService.java

@@ -0,0 +1,63 @@
+package com.ruoyi.system.service.fgw;
+
+import java.util.List;
+import com.ruoyi.system.domain.fgw.FgwLdps;
+
+/**
+ * 发改委_领导批示Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-03-24
+ */
+public interface IFgwLdpsService 
+{
+    /**
+     * 查询发改委_领导批示
+     * 
+     * @param id 发改委_领导批示主键
+     * @return 发改委_领导批示
+     */
+    public FgwLdps selectFgwLdpsById(Long id);
+
+    /**
+     * 查询发改委_领导批示列表
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 发改委_领导批示集合
+     */
+    public List<FgwLdps> selectFgwLdpsList(FgwLdps fgwLdps);
+
+    /**
+     * 新增发改委_领导批示
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 结果
+     */
+    public int insertFgwLdps(FgwLdps fgwLdps);
+
+    /**
+     * 修改发改委_领导批示
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 结果
+     */
+    public int updateFgwLdps(FgwLdps fgwLdps);
+
+    /**
+     * 批量删除发改委_领导批示
+     * 
+     * @param ids 需要删除的发改委_领导批示主键集合
+     * @return 结果
+     */
+    public int deleteFgwLdpsByIds(Long[] ids);
+
+    /**
+     * 删除发改委_领导批示信息
+     * 
+     * @param id 发改委_领导批示主键
+     * @return 结果
+     */
+    public int deleteFgwLdpsById(Long id);
+
+    String getInfoZc(FgwLdps fgwLdps);
+}

+ 162 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/fgw/FgwLdpsServiceImpl.java

@@ -0,0 +1,162 @@
+package com.ruoyi.system.service.impl.fgw;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import com.ruoyi.common.core.domain.entity.SysRole;
+import com.ruoyi.common.core.domain.entity.SysUser;
+import com.ruoyi.common.utils.DateUtils;
+import com.ruoyi.common.utils.SecurityUtils;
+import com.ruoyi.common.utils.StringUtils;
+import com.ruoyi.system.domain.fgw.FgwXmsb;
+import com.ruoyi.system.domain.projectV2.ZsyzSbbzb;
+import com.ruoyi.system.domain.projectV2.common.SendSmsConfig;
+import com.ruoyi.system.mapper.SysUserMapper;
+import com.ruoyi.system.mapper.fgw.FgwXmsbMapper;
+import com.ruoyi.system.mapper.projectV2.ZsyzSbbzbMapper;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.system.mapper.fgw.FgwLdpsMapper;
+import com.ruoyi.system.domain.fgw.FgwLdps;
+import com.ruoyi.system.service.fgw.IFgwLdpsService;
+
+import static com.ruoyi.common.constant.CommonConstants.LEADER;
+
+/**
+ * 发改委_领导批示Service业务层处理
+ * 
+ * @author ruoyi
+ * @date 2023-03-24
+ */
+@Service
+public class FgwLdpsServiceImpl implements IFgwLdpsService 
+{
+    @Autowired
+    private FgwLdpsMapper fgwLdpsMapper;
+    @Autowired
+    private FgwXmsbMapper fgwXmsbMapper;
+
+    /**
+     * 查询发改委_领导批示
+     * 
+     * @param id 发改委_领导批示主键
+     * @return 发改委_领导批示
+     */
+    @Override
+    public FgwLdps selectFgwLdpsById(Long id)
+    {
+        return fgwLdpsMapper.selectFgwLdpsById(id);
+    }
+
+    /**
+     * 查询发改委_领导批示列表
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 发改委_领导批示
+     */
+    @Override
+    public List<FgwLdps> selectFgwLdpsList(FgwLdps fgwLdps)
+    {
+
+        SysUser currentUser = SecurityUtils.getLoginUser().getUser();
+        String roleKey = "";
+        // 如果是超级管理员/管理员,则不过滤数据
+        List<SysRole> roles = SecurityUtils.getLoginUser().getUser().getRoles();
+        if (roles != null && roles.size() > 0) {
+            roleKey = roles.get(0).getRoleKey();
+        }
+        if (LEADER.equals(roleKey)) {
+            //判断账号权限是不是领导,领导只能看见自己的
+            fgwLdps.setPsnrId(currentUser.getUserId());
+        }
+        return fgwLdpsMapper.selectFgwLdpsList(fgwLdps);
+    }
+
+    /**
+     * 新增发改委_领导批示
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 结果
+     */
+    @Override
+    public int insertFgwLdps(FgwLdps fgwLdps)
+    {
+        //获取当前人员信息
+        SysUser user = SecurityUtils.getLoginUser().getUser();
+        fgwLdps.setDeptId(user.getDeptId());
+        fgwLdps.setPsr(user.getNickName());
+        fgwLdps.setXgr(user.getUserName());
+        fgwLdps.setPsnrId(user.getUserId());
+        fgwLdps.setXgsj(DateUtils.getNowDate());
+        fgwLdps.setCjsj(DateUtils.getNowDate());
+        if(!"1".equals(fgwLdps.getType())){
+            //修改主表中的领导批示内容
+            FgwXmsb fgwXmsb = new FgwXmsb();
+            fgwXmsb.setId(fgwLdps.getXmId());
+            fgwXmsb.setPsnr(fgwLdps.getPsnr());
+            fgwXmsbMapper.updateFgwXmsb(fgwXmsb);
+
+        }
+
+        return fgwLdpsMapper.insertFgwLdps(fgwLdps);
+    }
+
+    /**
+     * 修改发改委_领导批示
+     * 
+     * @param fgwLdps 发改委_领导批示
+     * @return 结果
+     */
+    @Override
+    public int updateFgwLdps(FgwLdps fgwLdps)
+    {
+
+        //获取当前人员信息
+        SysUser user = SecurityUtils.getLoginUser().getUser();
+        fgwLdps.setXgsj(DateUtils.getNowDate());
+        fgwLdps.setXgr(user.getUserName());
+        fgwLdps.setPsr(user.getNickName());
+        if(!"1".equals(fgwLdps.getType())){
+            fgwLdps.setZcpsnr("");
+            //修改主表中的领导批示内容
+            FgwXmsb fgwXmsb = new FgwXmsb();
+            fgwXmsb.setId(fgwLdps.getXmId());
+            fgwXmsb.setPsnr(fgwLdps.getPsnr());
+            fgwXmsbMapper.updateFgwXmsb(fgwXmsb);
+        }
+
+        return fgwLdpsMapper.updateFgwLdps(fgwLdps);
+    }
+
+    /**
+     * 批量删除发改委_领导批示
+     * 
+     * @param ids 需要删除的发改委_领导批示主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFgwLdpsByIds(Long[] ids)
+    {
+        return fgwLdpsMapper.deleteFgwLdpsByIds(ids);
+    }
+
+    /**
+     * 删除发改委_领导批示信息
+     * 
+     * @param id 发改委_领导批示主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFgwLdpsById(Long id)
+    {
+        return fgwLdpsMapper.deleteFgwLdpsById(id);
+    }
+
+    @Override
+    public String getInfoZc(FgwLdps fgwLdps) {
+        //获取当前人员信息
+        SysUser user = SecurityUtils.getLoginUser().getUser();
+        fgwLdps.setPsnrId(user.getUserId());
+        return fgwLdpsMapper.getInfoZc(fgwLdps);
+    }
+}

+ 118 - 0
ruoyi-system/src/main/resources/mapper/system/fgw/FgwLdpsMapper.xml

@@ -0,0 +1,118 @@
+<?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.fgw.FgwLdpsMapper">
+    
+    <resultMap type="FgwLdps" id="FgwLdpsResult">
+        <result property="id"    column="id"    />
+        <result property="xmId"    column="xm_id"    />
+        <result property="xmbh"    column="xmbh"    />
+        <result property="xmmc"    column="xmmc"    />
+        <result property="psnrId"    column="psnr_id"    />
+        <result property="psnr"    column="psnr"    />
+        <result property="zcpsnr"    column="zcpsnr"    />
+        <result property="deptId"    column="dept_id"    />
+        <result property="psr"    column="psr"    />
+        <result property="cjsj"    column="cjsj"    />
+        <result property="xgr"    column="xgr"    />
+        <result property="xgsj"    column="xgsj"    />
+        <result property="remark"    column="remark"    />
+    </resultMap>
+
+    <sql id="selectFgwLdpsVo">
+        select id, xm_id, xmbh, xmmc, psnr_id, psnr, zcpsnr, dept_id, psr, cjsj, xgr, xgsj, remark from fgw_ldps
+    </sql>
+
+    <select id="selectFgwLdpsList" parameterType="FgwLdps" resultMap="FgwLdpsResult">
+        <include refid="selectFgwLdpsVo"/>
+        <where>  
+            <if test="xmId != null "> and xm_id = #{xmId}</if>
+            <if test="xmbh != null  and xmbh != ''"> and xmbh = #{xmbh}</if>
+            <if test="xmmc != null  and xmmc != ''"> and xmmc = #{xmmc}</if>
+            <if test="psnrId != null "> and psnr_id = #{psnrId}</if>
+            <if test="psnr != null  and psnr != ''"> and psnr = #{psnr}</if>
+            <if test="zcpsnr != null  and zcpsnr != ''"> and zcpsnr = #{zcpsnr}</if>
+            <if test="deptId != null "> and dept_id = #{deptId}</if>
+            <if test="psr != null  and psr != ''"> and psr = #{psr}</if>
+            <if test="cjsj != null "> and cjsj = #{cjsj}</if>
+            <if test="xgr != null  and xgr != ''"> and xgr = #{xgr}</if>
+            <if test="xgsj != null "> and xgsj = #{xgsj}</if>
+        </where>
+    </select>
+    
+    <select id="selectFgwLdpsById" parameterType="Long" resultMap="FgwLdpsResult">
+        <include refid="selectFgwLdpsVo"/>
+        where id = #{id}
+    </select>
+    <select id="getInfoZc" resultMap="FgwLdpsResult">
+        <include refid="selectFgwLdpsVo"/>
+        where psnr_id = #{psnrId}
+        and xm_id = #{xmId}
+        and zcpsnr !=''
+        and zcpsnr is not null
+        and (psnr = '' or psnr is null)
+    </select>
+
+    <insert id="insertFgwLdps" parameterType="FgwLdps" useGeneratedKeys="true" keyProperty="id">
+        insert into fgw_ldps
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="xmId != null">xm_id,</if>
+            <if test="xmbh != null">xmbh,</if>
+            <if test="xmmc != null">xmmc,</if>
+            <if test="psnrId != null">psnr_id,</if>
+            <if test="psnr != null">psnr,</if>
+            <if test="zcpsnr != null">zcpsnr,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="psr != null">psr,</if>
+            <if test="cjsj != null">cjsj,</if>
+            <if test="xgr != null">xgr,</if>
+            <if test="xgsj != null">xgsj,</if>
+            <if test="remark != null">remark,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="xmId != null">#{xmId},</if>
+            <if test="xmbh != null">#{xmbh},</if>
+            <if test="xmmc != null">#{xmmc},</if>
+            <if test="psnrId != null">#{psnrId},</if>
+            <if test="psnr != null">#{psnr},</if>
+            <if test="zcpsnr != null">#{zcpsnr},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="psr != null">#{psr},</if>
+            <if test="cjsj != null">#{cjsj},</if>
+            <if test="xgr != null">#{xgr},</if>
+            <if test="xgsj != null">#{xgsj},</if>
+            <if test="remark != null">#{remark},</if>
+         </trim>
+    </insert>
+
+    <update id="updateFgwLdps" parameterType="FgwLdps">
+        update fgw_ldps
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="xmId != null">xm_id = #{xmId},</if>
+            <if test="xmbh != null">xmbh = #{xmbh},</if>
+            <if test="xmmc != null">xmmc = #{xmmc},</if>
+            <if test="psnrId != null">psnr_id = #{psnrId},</if>
+            <if test="psnr != null">psnr = #{psnr},</if>
+            <if test="zcpsnr != null">zcpsnr = #{zcpsnr},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="psr != null">psr = #{psr},</if>
+            <if test="cjsj != null">cjsj = #{cjsj},</if>
+            <if test="xgr != null">xgr = #{xgr},</if>
+            <if test="xgsj != null">xgsj = #{xgsj},</if>
+            <if test="remark != null">remark = #{remark},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteFgwLdpsById" parameterType="Long">
+        delete from fgw_ldps where id = #{id}
+    </delete>
+
+    <delete id="deleteFgwLdpsByIds" parameterType="String">
+        delete from fgw_ldps where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 10 - 1
ruoyi-system/src/main/resources/mapper/system/fgw/FgwXmsbMapper.xml

@@ -26,6 +26,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="jsdw"    column="jsdw"    />
         <result property="jsDeptId"    column="js_dept_id"    />
         <result property="deptId"    column="dept_id"    />
+        <result property="deptName"    column="dept_name"    />
         <result property="userId"    column="user_id"    />
         <result property="kgsj"    column="kgsj"    />
         <result property="ntsj"    column="ntsj"    />
@@ -38,10 +39,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="updateBy"    column="update_by"    />
         <result property="updateTime"    column="update_time"    />
         <result property="remark"    column="remark"    />
+        <result property="psnr" column="psnr"/>
     </resultMap>
 
     <sql id="selectFgwXmsbVo">
-        select id, xmmc, xmbh, xmdw, qtzrdw, qtsld, gmnr, jhkgsj, xmztz, sjbz, sczbj, zxz, ppp, rz, ndjh, sjbzzjqd, rzqd, dq, jsdw, js_dept_id, dept_id, user_id, kgsj, ntsj, ntxmtc, type, progress, status, create_by, create_time, update_by, update_time, remark from fgw_xmsb
+        select id, xmmc, xmbh, xmdw, qtzrdw, qtsld, gmnr, jhkgsj, xmztz, sjbz, sczbj, zxz, ppp, rz, ndjh, sjbzzjqd, rzqd, dq, jsdw, js_dept_id, dept_id,deptName, user_id, kgsj, ntsj, ntxmtc, type, progress, status, create_by, create_time, update_by, update_time, remark,psnr from fgw_xmsb
     </sql>
 
     <select id="selectFgwXmsbList" parameterType="FgwXmsb" resultMap="FgwXmsbResult">
@@ -67,6 +69,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="jsdw != null  and jsdw != ''"> and jsdw = #{jsdw}</if>
             <if test="jsDeptId != null "> and js_dept_id = #{jsDeptId}</if>
             <if test="deptId != null "> and dept_id = #{deptId}</if>
+            <if test="deptName != null "> and dept_name = #{deptName}</if>
             <if test="userId != null "> and user_id = #{userId}</if>
             <if test="kgsj != null "> and kgsj = #{kgsj}</if>
             <if test="ntsj != null "> and ntsj = #{ntsj}</if>
@@ -117,6 +120,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="jsdw != null">jsdw,</if>
             <if test="jsDeptId != null">js_dept_id,</if>
             <if test="deptId != null">dept_id,</if>
+            <if test="deptName != null">dept_name,</if>
             <if test="userId != null">user_id,</if>
             <if test="kgsj != null">kgsj,</if>
             <if test="ntsj != null">ntsj,</if>
@@ -129,6 +133,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="updateBy != null">update_by,</if>
             <if test="updateTime != null">update_time,</if>
             <if test="remark != null">remark,</if>
+            <if test="psnr != null">psnr,</if>
          </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="xmmc != null">#{xmmc},</if>
@@ -151,6 +156,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="jsdw != null">#{jsdw},</if>
             <if test="jsDeptId != null">#{jsDeptId},</if>
             <if test="deptId != null">#{deptId},</if>
+            <if test="deptName != null">#{deptName},</if>
             <if test="userId != null">#{userId},</if>
             <if test="kgsj != null">#{kgsj},</if>
             <if test="ntsj != null">#{ntsj},</if>
@@ -163,6 +169,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="updateBy != null">#{updateBy},</if>
             <if test="updateTime != null">#{updateTime},</if>
             <if test="remark != null">#{remark},</if>
+            <if test="psnr != null">#{psnr},</if>
          </trim>
     </insert>
 
@@ -189,6 +196,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="jsdw != null">jsdw = #{jsdw},</if>
             <if test="jsDeptId != null">js_dept_id = #{jsDeptId},</if>
             <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="deptName != null">dept_name = #{deptName},</if>
             <if test="userId != null">user_id = #{userId},</if>
             <if test="kgsj != null">kgsj = #{kgsj},</if>
             <if test="ntsj != null">ntsj = #{ntsj},</if>
@@ -201,6 +209,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="updateBy != null">update_by = #{updateBy},</if>
             <if test="updateTime != null">update_time = #{updateTime},</if>
             <if test="remark != null">remark = #{remark},</if>
+            <if test="psnr != null">psnr = #{psnr},</if>
         </trim>
         where id = #{id}
     </update>