Administrator 1 éve
szülő
commit
49be063bb3

+ 11 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/annex/BomanAnnexController.java

@@ -45,6 +45,17 @@ public class BomanAnnexController extends BaseController
         return getDataTable(list);
     }
 
+    /**
+     * 查询附件列表
+     */
+    @GetMapping("/listNo")
+    public TableDataInfo listNo(BomanAnnex bomanAnnex)
+    {
+
+        List<BomanAnnex> list = bomanAnnexService.selectBomanAnnexList(bomanAnnex);
+        return getDataTable(list);
+    }
+
     /**
      * 导出附件列表
      */

+ 126 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/info/InfoPinglunController.java

@@ -0,0 +1,126 @@
+package com.ruoyi.web.controller.info;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+
+import com.ruoyi.common.core.domain.R;
+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.InfoPinglun;
+import com.ruoyi.system.service.IInfoPinglunService;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.common.core.page.TableDataInfo;
+
+/**
+ * 信息评论Controller
+ * 
+ * @author boman
+ * @date 2023-11-28
+ */
+@RestController
+@RequestMapping("/system/pinglun")
+public class InfoPinglunController extends BaseController
+{
+    @Autowired
+    private IInfoPinglunService infoPinglunService;
+
+    /**
+     * 查询信息评论列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:pinglun:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(InfoPinglun infoPinglun)
+    {
+        startPage();
+        List<InfoPinglun> list = infoPinglunService.selectInfoPinglunList(infoPinglun);
+        return getDataTable(list);
+    }
+
+    /**
+     * 根据附件id查询评论
+     * @param annexId
+     * @return
+     */
+    @GetMapping("/pingLun/{annexId}")
+    public AjaxResult getPingLunInfo(@PathVariable Long annexId) {
+        List<InfoPinglun> pingLunInfo = infoPinglunService.getPingLunInfo(annexId);
+        return AjaxResult.success(pingLunInfo);
+    }
+
+    /**
+     * 根据附件id查询评论滚动
+     * @param annexId
+     * @return
+     */
+    @GetMapping("/pingLun/index/{annexId}")
+    public AjaxResult getPingLunInfoIndex(@PathVariable Long annexId) {
+        List<InfoPinglun> pingLunInfo = infoPinglunService.getPingLunInfoIndex(annexId);
+        return AjaxResult.success(pingLunInfo);
+    }
+
+    /**
+     * 导出信息评论列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:pinglun:export')")
+    @Log(title = "信息评论", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, InfoPinglun infoPinglun)
+    {
+        List<InfoPinglun> list = infoPinglunService.selectInfoPinglunList(infoPinglun);
+        ExcelUtil<InfoPinglun> util = new ExcelUtil<InfoPinglun>(InfoPinglun.class);
+        util.exportExcel(response, list, "信息评论数据");
+    }
+
+    /**
+     * 获取信息评论详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('system:pinglun:query')")
+    @GetMapping(value = "/{infoPinglunId}")
+    public AjaxResult getInfo(@PathVariable("infoPinglunId") Long infoPinglunId)
+    {
+        return success(infoPinglunService.selectInfoPinglunByInfoPinglunId(infoPinglunId));
+    }
+
+    /**
+     * 新增信息评论
+     */
+    @PostMapping()
+    public AjaxResult add(@RequestBody InfoPinglun infoPinglun)
+    {
+        return toAjax(infoPinglunService.insertInfoPinglun(infoPinglun));
+    }
+
+    /**
+     * 修改信息评论
+     */
+    @PreAuthorize("@ss.hasPermi('system:pinglun:edit')")
+    @Log(title = "信息评论", businessType = BusinessType.UPDATE)
+    @PostMapping("/put")
+    public AjaxResult edit(@RequestBody InfoPinglun infoPinglun)
+    {
+        return toAjax(infoPinglunService.updateInfoPinglun(infoPinglun));
+    }
+
+    /**
+     * 删除信息评论
+     */
+    @PreAuthorize("@ss.hasPermi('system:pinglun:remove')")
+    @Log(title = "信息评论", businessType = BusinessType.DELETE)
+	@GetMapping("/delete/{infoPinglunIds}")
+    public AjaxResult remove(@PathVariable Long[] infoPinglunIds)
+    {
+        return toAjax(infoPinglunService.deleteInfoPinglunByInfoPinglunIds(infoPinglunIds));
+    }
+}

+ 1 - 1
ruoyi-framework/src/main/java/com/ruoyi/framework/config/SecurityConfig.java

@@ -111,7 +111,7 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
                 // 过滤请求
                 .authorizeRequests()
                 // 对于登录login 注册register 验证码captchaImage 允许匿名访问
-                .antMatchers("/login", "/register", "/captchaImage","/boman/common/**","/sendSms/**").permitAll()
+                .antMatchers("/login", "/register", "/captchaImage","/boman/common/**","/sendSms/**","/system/pinglun/**").permitAll()
                 .antMatchers("/system/personnel/**", "/reservat/config/**", "/reservat/time/**","/system/reservat/**","/system/news/**","/system/annex/list").permitAll()
                 // 静态资源,可匿名访问
                 .antMatchers(HttpMethod.GET, "/", "/*.html", "/**/*.html", "/**/*.css", "/**/*.js", "/profile/**").permitAll()

+ 215 - 0
ruoyi-system/src/main/java/com/ruoyi/system/domain/InfoPinglun.java

@@ -0,0 +1,215 @@
+package com.ruoyi.system.domain;
+
+import java.util.Date;
+import java.util.List;
+
+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;
+
+/**
+ * 信息评论对象 info_pinglun
+ * 
+ * @author boman
+ * @date 2023-11-28
+ */
+public class InfoPinglun extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 信息评论id */
+    private Long infoPinglunId;
+
+    /** 附件id */
+    @Excel(name = "附件id")
+    private Long annexId;
+
+    /** 信息评论父id */
+    @Excel(name = "信息评论父id")
+    private Long infoPingLunParent;
+
+    /** 评论内容 */
+    @Excel(name = "评论内容")
+    private String infoPingLunContent;
+
+    /** 评论人id */
+    @Excel(name = "评论人id")
+    private Long infoPingLunUserId;
+
+    /** 评论人名称 */
+    @Excel(name = "评论人名称")
+    private String infoPingLunUserName;
+
+    /** 被评论人id */
+    @Excel(name = "被评论人id")
+    private Long infoPingLunQuiltUserId;
+
+    /** 被评论人名称 */
+    @Excel(name = "被评论人名称")
+    private String infoPingLunQuiltUserName;
+
+    /** 评论时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "评论时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date pingLunTime;
+
+    /** 评论类型 1:评论 2:回复 */
+    @Excel(name = "评论类型 1:评论 2:回复")
+    private String infoPingLunType;
+
+    /** 是否通过 N:未通过 Y:通过 */
+    @Excel(name = "是否通过 N:未通过 Y:通过")
+    private String infoPingLunExamine;
+
+    /** 创建部门 */
+    @Excel(name = "创建部门")
+    private Long createDept;
+
+    /**
+     * 对此评论的回复集合
+     */
+
+    private List<InfoPinglun> infoPingLunList;
+
+    public List<InfoPinglun> getInfoPingLunList() {
+        return infoPingLunList;
+    }
+
+    public void setInfoPingLunList(List<InfoPinglun> infoPingLunList) {
+        this.infoPingLunList = infoPingLunList;
+    }
+
+    public void setInfoPinglunId(Long infoPinglunId)
+    {
+        this.infoPinglunId = infoPinglunId;
+    }
+
+    public Long getInfoPinglunId() 
+    {
+        return infoPinglunId;
+    }
+    public void setAnnexId(Long annexId) 
+    {
+        this.annexId = annexId;
+    }
+
+    public Long getAnnexId() 
+    {
+        return annexId;
+    }
+    public void setInfoPingLunParent(Long infoPingLunParent) 
+    {
+        this.infoPingLunParent = infoPingLunParent;
+    }
+
+    public Long getInfoPingLunParent() 
+    {
+        return infoPingLunParent;
+    }
+    public void setInfoPingLunContent(String infoPingLunContent) 
+    {
+        this.infoPingLunContent = infoPingLunContent;
+    }
+
+    public String getInfoPingLunContent() 
+    {
+        return infoPingLunContent;
+    }
+    public void setInfoPingLunUserId(Long infoPingLunUserId) 
+    {
+        this.infoPingLunUserId = infoPingLunUserId;
+    }
+
+    public Long getInfoPingLunUserId() 
+    {
+        return infoPingLunUserId;
+    }
+    public void setInfoPingLunUserName(String infoPingLunUserName) 
+    {
+        this.infoPingLunUserName = infoPingLunUserName;
+    }
+
+    public String getInfoPingLunUserName() 
+    {
+        return infoPingLunUserName;
+    }
+    public void setInfoPingLunQuiltUserId(Long infoPingLunQuiltUserId) 
+    {
+        this.infoPingLunQuiltUserId = infoPingLunQuiltUserId;
+    }
+
+    public Long getInfoPingLunQuiltUserId() 
+    {
+        return infoPingLunQuiltUserId;
+    }
+    public void setInfoPingLunQuiltUserName(String infoPingLunQuiltUserName) 
+    {
+        this.infoPingLunQuiltUserName = infoPingLunQuiltUserName;
+    }
+
+    public String getInfoPingLunQuiltUserName() 
+    {
+        return infoPingLunQuiltUserName;
+    }
+    public void setPingLunTime(Date pingLunTime) 
+    {
+        this.pingLunTime = pingLunTime;
+    }
+
+    public Date getPingLunTime() 
+    {
+        return pingLunTime;
+    }
+    public void setInfoPingLunType(String infoPingLunType) 
+    {
+        this.infoPingLunType = infoPingLunType;
+    }
+
+    public String getInfoPingLunType() 
+    {
+        return infoPingLunType;
+    }
+    public void setInfoPingLunExamine(String infoPingLunExamine) 
+    {
+        this.infoPingLunExamine = infoPingLunExamine;
+    }
+
+    public String getInfoPingLunExamine() 
+    {
+        return infoPingLunExamine;
+    }
+    public void setCreateDept(Long createDept) 
+    {
+        this.createDept = createDept;
+    }
+
+    public Long getCreateDept() 
+    {
+        return createDept;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("infoPinglunId", getInfoPinglunId())
+            .append("annexId", getAnnexId())
+            .append("infoPingLunParent", getInfoPingLunParent())
+            .append("infoPingLunContent", getInfoPingLunContent())
+            .append("infoPingLunUserId", getInfoPingLunUserId())
+            .append("infoPingLunUserName", getInfoPingLunUserName())
+            .append("infoPingLunQuiltUserId", getInfoPingLunQuiltUserId())
+            .append("infoPingLunQuiltUserName", getInfoPingLunQuiltUserName())
+            .append("pingLunTime", getPingLunTime())
+            .append("infoPingLunType", getInfoPingLunType())
+            .append("infoPingLunExamine", getInfoPingLunExamine())
+            .append("createDept", getCreateDept())
+            .append("createBy", getCreateBy())
+            .append("createTime", getCreateTime())
+            .append("updateBy", getUpdateBy())
+            .append("updateTime", getUpdateTime())
+            .append("remark", getRemark())
+            .toString();
+    }
+}

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

@@ -0,0 +1,62 @@
+package com.ruoyi.system.mapper;
+
+import java.util.List;
+import com.ruoyi.system.domain.InfoPinglun;
+
+/**
+ * 信息评论Mapper接口
+ * 
+ * @author boman
+ * @date 2023-11-28
+ */
+public interface InfoPinglunMapper 
+{
+    /**
+     * 查询信息评论
+     * 
+     * @param infoPinglunId 信息评论主键
+     * @return 信息评论
+     */
+    public InfoPinglun selectInfoPinglunByInfoPinglunId(Long infoPinglunId);
+
+    /**
+     * 查询信息评论列表
+     * 
+     * @param infoPinglun 信息评论
+     * @return 信息评论集合
+     */
+    public List<InfoPinglun> selectInfoPinglunList(InfoPinglun infoPinglun);
+
+    /**
+     * 新增信息评论
+     * 
+     * @param infoPinglun 信息评论
+     * @return 结果
+     */
+    public int insertInfoPinglun(InfoPinglun infoPinglun);
+
+    /**
+     * 修改信息评论
+     * 
+     * @param infoPinglun 信息评论
+     * @return 结果
+     */
+    public int updateInfoPinglun(InfoPinglun infoPinglun);
+
+    /**
+     * 删除信息评论
+     * 
+     * @param infoPinglunId 信息评论主键
+     * @return 结果
+     */
+    public int deleteInfoPinglunByInfoPinglunId(Long infoPinglunId);
+    public List<InfoPinglun> selectInfoPinglunByAnnexId(Long annexId);
+
+    /**
+     * 批量删除信息评论
+     * 
+     * @param infoPinglunIds 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteInfoPinglunByInfoPinglunIds(Long[] infoPinglunIds);
+}

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

@@ -0,0 +1,63 @@
+package com.ruoyi.system.service;
+
+import java.util.List;
+import com.ruoyi.system.domain.InfoPinglun;
+
+/**
+ * 信息评论Service接口
+ * 
+ * @author boman
+ * @date 2023-11-28
+ */
+public interface IInfoPinglunService 
+{
+    /**
+     * 查询信息评论
+     * 
+     * @param infoPinglunId 信息评论主键
+     * @return 信息评论
+     */
+    public InfoPinglun selectInfoPinglunByInfoPinglunId(Long infoPinglunId);
+
+    /**
+     * 查询信息评论列表
+     * 
+     * @param infoPinglun 信息评论
+     * @return 信息评论集合
+     */
+    public List<InfoPinglun> selectInfoPinglunList(InfoPinglun infoPinglun);
+    public List<InfoPinglun> getPingLunInfo(Long annexId);
+    public List<InfoPinglun> getPingLunInfoIndex(Long annexId);
+
+    /**
+     * 新增信息评论
+     * 
+     * @param infoPinglun 信息评论
+     * @return 结果
+     */
+    public int insertInfoPinglun(InfoPinglun infoPinglun);
+
+    /**
+     * 修改信息评论
+     * 
+     * @param infoPinglun 信息评论
+     * @return 结果
+     */
+    public int updateInfoPinglun(InfoPinglun infoPinglun);
+
+    /**
+     * 批量删除信息评论
+     * 
+     * @param infoPinglunIds 需要删除的信息评论主键集合
+     * @return 结果
+     */
+    public int deleteInfoPinglunByInfoPinglunIds(Long[] infoPinglunIds);
+
+    /**
+     * 删除信息评论信息
+     * 
+     * @param infoPinglunId 信息评论主键
+     * @return 结果
+     */
+    public int deleteInfoPinglunByInfoPinglunId(Long infoPinglunId);
+}

+ 140 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/InfoPinglunServiceImpl.java

@@ -0,0 +1,140 @@
+package com.ruoyi.system.service.impl;
+
+import java.util.Comparator;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+
+import com.ruoyi.common.utils.DateUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.system.mapper.InfoPinglunMapper;
+import com.ruoyi.system.domain.InfoPinglun;
+import com.ruoyi.system.service.IInfoPinglunService;
+
+/**
+ * 信息评论Service业务层处理
+ *
+ * @author boman
+ * @date 2023-11-28
+ */
+@Service
+public class InfoPinglunServiceImpl implements IInfoPinglunService {
+    @Autowired
+    private InfoPinglunMapper infoPinglunMapper;
+
+    /**
+     * 查询信息评论
+     *
+     * @param infoPinglunId 信息评论主键
+     * @return 信息评论
+     */
+    @Override
+    public InfoPinglun selectInfoPinglunByInfoPinglunId(Long infoPinglunId) {
+        return infoPinglunMapper.selectInfoPinglunByInfoPinglunId(infoPinglunId);
+    }
+
+    /**
+     * 查询信息评论列表
+     *
+     * @param infoPinglun 信息评论
+     * @return 信息评论
+     */
+    @Override
+    public List<InfoPinglun> selectInfoPinglunList(InfoPinglun infoPinglun) {
+        return infoPinglunMapper.selectInfoPinglunList(infoPinglun);
+    }
+
+    @Override
+    public List<InfoPinglun> getPingLunInfo(Long annexId) {
+        List<InfoPinglun> infoPingLunList = infoPinglunMapper.selectInfoPinglunByAnnexId(annexId);
+        if (infoPingLunList != null && infoPingLunList.size() > 0) {
+            //根据评论类型进行分组评论类型 1:评论 2:回复
+            Map<String, List<InfoPinglun>> collect = infoPingLunList.stream().sorted(Comparator.comparing(InfoPinglun::getPingLunTime, Comparator.reverseOrder())).collect(Collectors.groupingBy(InfoPinglun::getInfoPingLunType));
+            if (collect != null && collect.size() > 0){
+                //所有评论类型的数据
+                List<InfoPinglun> infoPingLunListFather = collect.get("1");
+                //给他们找自己的回复类型的数据
+                if (infoPingLunListFather != null && infoPingLunListFather.size() > 0){
+                    for (InfoPinglun infoPinglun : infoPingLunListFather) {
+                        List<InfoPinglun> infoPinglunList = collect.get("2");
+                        //回复不是空
+                        if(infoPinglunList != null && infoPinglunList.size() > 0){
+                            Map<Long, List<InfoPinglun>> infoPingLunListParen = infoPinglunList.stream().collect(Collectors.groupingBy(InfoPinglun::getInfoPingLunParent));
+                            List<InfoPinglun> infoPinglunListCh = infoPingLunListParen.get(infoPinglun.getInfoPinglunId());
+                            if (infoPinglunListCh != null && infoPinglunListCh.size() > 0){
+                                infoPinglun.setInfoPingLunList(infoPinglunListCh.stream().sorted(Comparator.comparing(InfoPinglun::getPingLunTime, Comparator.reverseOrder())).collect(Collectors.toList()));
+                            }
+                        }
+                    }
+                }
+                return infoPingLunListFather;
+            }
+        }
+        return null;
+    }
+
+    @Override
+    public List<InfoPinglun> getPingLunInfoIndex(Long annexId) {
+        List<InfoPinglun> infoPingLunList = infoPinglunMapper.selectInfoPinglunByAnnexId(annexId);
+        if (infoPingLunList != null && infoPingLunList.size() > 0) {
+            //根据评论类型进行分组评论类型 1:评论 2:回复
+            Map<String, List<InfoPinglun>> collect = infoPingLunList.stream().sorted(Comparator.comparing(InfoPinglun::getPingLunTime, Comparator.reverseOrder())).collect(Collectors.groupingBy(InfoPinglun::getInfoPingLunType));
+            if (collect != null && collect.size() > 0){
+                //所有评论类型的数据
+                List<InfoPinglun> infoPingLunListFather = collect.get("1");
+                return infoPingLunListFather;
+            }
+        }
+        return null;
+    }
+
+    /**
+     * 新增信息评论
+     *
+     * @param infoPinglun 信息评论
+     * @return 结果
+     */
+    @Override
+    public int insertInfoPinglun(InfoPinglun infoPinglun) {
+        infoPinglun.setCreateTime(DateUtils.getNowDate());
+        infoPinglun.setInfoPingLunUserName("游客");
+        infoPinglun.setInfoPingLunQuiltUserName("游客");
+        infoPinglun.setPingLunTime(DateUtils.getNowDate());
+        return infoPinglunMapper.insertInfoPinglun(infoPinglun);
+    }
+
+    /**
+     * 修改信息评论
+     *
+     * @param infoPinglun 信息评论
+     * @return 结果
+     */
+    @Override
+    public int updateInfoPinglun(InfoPinglun infoPinglun) {
+        infoPinglun.setUpdateTime(DateUtils.getNowDate());
+        return infoPinglunMapper.updateInfoPinglun(infoPinglun);
+    }
+
+    /**
+     * 批量删除信息评论
+     *
+     * @param infoPinglunIds 需要删除的信息评论主键
+     * @return 结果
+     */
+    @Override
+    public int deleteInfoPinglunByInfoPinglunIds(Long[] infoPinglunIds) {
+        return infoPinglunMapper.deleteInfoPinglunByInfoPinglunIds(infoPinglunIds);
+    }
+
+    /**
+     * 删除信息评论信息
+     *
+     * @param infoPinglunId 信息评论主键
+     * @return 结果
+     */
+    @Override
+    public int deleteInfoPinglunByInfoPinglunId(Long infoPinglunId) {
+        return infoPinglunMapper.deleteInfoPinglunByInfoPinglunId(infoPinglunId);
+    }
+}

+ 117 - 0
ruoyi-system/src/main/resources/mapper/system/InfoPinglunMapper.xml

@@ -0,0 +1,117 @@
+<?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.InfoPinglunMapper">
+    
+    <resultMap type="InfoPinglun" id="InfoPinglunResult">
+        <result property="infoPinglunId"    column="info_pinglun_id"    />
+        <result property="annexId"    column="annex_id"    />
+        <result property="infoPingLunParent"    column="info_ping_lun_parent"    />
+        <result property="infoPingLunContent"    column="info_ping_lun_content"    />
+        <result property="infoPingLunUserId"    column="info_ping_lun_user_id"    />
+        <result property="infoPingLunUserName"    column="info_ping_lun_user_name"    />
+        <result property="infoPingLunQuiltUserId"    column="info_ping_lun_quilt_user_id"    />
+        <result property="infoPingLunQuiltUserName"    column="info_ping_lun_quilt_user_name"    />
+        <result property="pingLunTime"    column="ping_lun_time"    />
+        <result property="infoPingLunType"    column="info_ping_lun_type"    />
+        <result property="infoPingLunExamine"    column="info_ping_lun_examine"    />
+        <result property="createDept"    column="create_dept"    />
+        <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="remark"    column="remark"    />
+    </resultMap>
+
+    <sql id="selectInfoPinglunVo">
+        select info_pinglun_id, annex_id, info_ping_lun_parent, info_ping_lun_content, info_ping_lun_user_id, info_ping_lun_user_name, info_ping_lun_quilt_user_id, info_ping_lun_quilt_user_name, ping_lun_time, info_ping_lun_type, info_ping_lun_examine, create_dept, create_by, create_time, update_by, update_time, remark from info_pinglun
+    </sql>
+
+    <select id="selectInfoPinglunList" parameterType="InfoPinglun" resultMap="InfoPinglunResult">
+        <include refid="selectInfoPinglunVo"/>
+        <where>  
+            <if test="annexId != null "> and annex_id = #{annexId}</if>
+            <if test="infoPingLunParent != null "> and info_ping_lun_parent = #{infoPingLunParent}</if>
+            <if test="infoPingLunContent != null  and infoPingLunContent != ''"> and info_ping_lun_content = #{infoPingLunContent}</if>
+            <if test="infoPingLunUserId != null "> and info_ping_lun_user_id = #{infoPingLunUserId}</if>
+            <if test="infoPingLunUserName != null  and infoPingLunUserName != ''"> and info_ping_lun_user_name like concat('%', #{infoPingLunUserName}, '%')</if>
+            <if test="infoPingLunQuiltUserId != null "> and info_ping_lun_quilt_user_id = #{infoPingLunQuiltUserId}</if>
+            <if test="infoPingLunQuiltUserName != null  and infoPingLunQuiltUserName != ''"> and info_ping_lun_quilt_user_name like concat('%', #{infoPingLunQuiltUserName}, '%')</if>
+            <if test="pingLunTime != null "> and ping_lun_time = #{pingLunTime}</if>
+            <if test="infoPingLunType != null  and infoPingLunType != ''"> and info_ping_lun_type = #{infoPingLunType}</if>
+            <if test="infoPingLunExamine != null  and infoPingLunExamine != ''"> and info_ping_lun_examine = #{infoPingLunExamine}</if>
+            <if test="createDept != null "> and create_dept = #{createDept}</if>
+        </where>
+    </select>
+    
+    <select id="selectInfoPinglunByInfoPinglunId" parameterType="Long" resultMap="InfoPinglunResult">
+        <include refid="selectInfoPinglunVo"/>
+        where info_pinglun_id = #{infoPinglunId}
+    </select>
+    <select id="selectInfoPinglunByAnnexId" parameterType="Long" resultMap="InfoPinglunResult">
+        <include refid="selectInfoPinglunVo"/>
+        where annex_id = #{annexId} and info_ping_lun_examine = 'Y'
+    </select>
+
+    <insert id="insertInfoPinglun" parameterType="InfoPinglun" useGeneratedKeys="true" keyProperty="infoPinglunId">
+        insert into info_pinglun
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="annexId != null">annex_id,</if>
+            <if test="infoPingLunParent != null">info_ping_lun_parent,</if>
+            <if test="infoPingLunContent != null">info_ping_lun_content,</if>
+            <if test="infoPingLunUserId != null">info_ping_lun_user_id,</if>
+            <if test="infoPingLunUserName != null">info_ping_lun_user_name,</if>
+            <if test="infoPingLunQuiltUserId != null">info_ping_lun_quilt_user_id,</if>
+            <if test="infoPingLunQuiltUserName != null">info_ping_lun_quilt_user_name,</if>
+            <if test="pingLunTime != null">ping_lun_time,</if>
+            <if test="infoPingLunType != null">info_ping_lun_type,</if>
+            <if test="infoPingLunExamine != null">info_ping_lun_examine,</if>
+            <if test="createDept != null">create_dept,</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="remark != null">remark,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="annexId != null">#{annexId},</if>
+            <if test="infoPingLunParent != null">#{infoPingLunParent},</if>
+            <if test="infoPingLunContent != null">#{infoPingLunContent},</if>
+            <if test="infoPingLunUserId != null">#{infoPingLunUserId},</if>
+            <if test="infoPingLunUserName != null">#{infoPingLunUserName},</if>
+            <if test="infoPingLunQuiltUserId != null">#{infoPingLunQuiltUserId},</if>
+            <if test="infoPingLunQuiltUserName != null">#{infoPingLunQuiltUserName},</if>
+            <if test="pingLunTime != null">#{pingLunTime},</if>
+            <if test="infoPingLunType != null">#{infoPingLunType},</if>
+            <if test="infoPingLunExamine != null">#{infoPingLunExamine},</if>
+            <if test="createDept != null">#{createDept},</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="remark != null">#{remark},</if>
+         </trim>
+    </insert>
+
+    <update id="updateInfoPinglun" parameterType="InfoPinglun">
+        update info_pinglun
+        <trim prefix="SET" suffixOverrides=",">
+
+            <if test="infoPingLunExamine != null">info_ping_lun_examine = #{infoPingLunExamine},</if>
+
+        </trim>
+        where info_pinglun_id = #{infoPinglunId}
+    </update>
+
+    <delete id="deleteInfoPinglunByInfoPinglunId" parameterType="Long">
+        delete from info_pinglun where info_pinglun_id = #{infoPinglunId}
+    </delete>
+
+    <delete id="deleteInfoPinglunByInfoPinglunIds" parameterType="String">
+        delete from info_pinglun where info_pinglun_id in 
+        <foreach item="infoPinglunId" collection="array" open="(" separator="," close=")">
+            #{infoPinglunId}
+        </foreach>
+    </delete>
+</mapper>