安全通知模块->列表,新增,删除,详情接口开发

dev
WenShiJun 2024-02-23 19:04:20 +08:00
parent 6bedb9fc10
commit ba988ffb42
13 changed files with 757 additions and 133 deletions

View File

@ -0,0 +1,158 @@
package com.zcloud.controller.comprehensive;
import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.service.comprehensive.SecurityNoticeService;
import com.zcloud.service.comprehensive.SecurityReadDetailService;
import com.zcloud.service.system.UsersService;
import com.zcloud.util.DateUtil;
import com.zcloud.util.Jurisdiction;
import com.zcloud.util.Tools;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.*;
@Controller
@RequestMapping("/securitynotice")
public class SecurityNoticeController extends BaseController {
@Autowired
private SecurityNoticeService securityNoticeService;
@Autowired
private SecurityReadDetailService securityReadDetail;
@Autowired
private UsersService usersService;
//新增
@RequestMapping(value = "/add")
@ResponseBody
public Object add() throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
PageData pd = this.getPageData();
String notificationId = this.get32UUID();
pd.put("CREATOR", Jurisdiction.getUSER_ID()); // 创建人id
pd.put("CREATORNAME", Jurisdiction.getName()); // 创建人姓名
pd.put("NOTIFICATION_ID", notificationId); // 主键
pd.put("CREATETIME", DateUtil.date2Str(new Date())); // 添加时间
pd.put("POSTSTATUS", "1"); // 发布状态
pd.put("REPLYSTATUS", "0"); // 回复状态
pd.put("SIGNEDSTATUS", "0"); // 签收状态
pd.put("ISDELETE", "0");
List<PageData> notifications = securityNoticeService.getAllNotifications(pd);
Map<String, Integer> statusCount = new HashMap<>();
statusCount.put("total", notifications.size());
statusCount.put("signed", (int) notifications.stream().filter(n -> "1".equals(n.getString("SIGNEDSTATUS"))).count());
statusCount.put("replied", (int) notifications.stream().filter(n -> "1".equals(n.getString("REPLYSTATUS"))).count());
pd.put("SIGNING", statusCount.get("signed") + "/" + statusCount.get("total") + "人"); // 签收情况
pd.put("REPLY", statusCount.get("replied") + "/" + statusCount.get("total") + "人"); // 回复情况
securityNoticeService.save(pd);
String[] persons = pd.getString("PERSON").split(",");
for (String person : persons) {
pd.put("NOTIFICATION_ID", notificationId);
pd.put("PERSON", person.trim());
securityReadDetail.save(pd);
}
map.put("result", errInfo);
map.put("pd", pd);
return map;
}
//阅读情况
@RequestMapping(value = "/getAllReadDetail")
// @RequiresPermissions("hidden:list")
@ResponseBody
public Object getAllReadDetail(Page page) throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
String PRACTITIONER = pd.getString("PRACTITIONER"); // 关键词检索条件
if (Tools.notEmpty(PRACTITIONER))
pd.put("PRACTITIONER", PRACTITIONER.trim());
String PRACTITIONERTYPE = pd.getString("PRACTITIONERTYPE"); // 关键词检索条件
if (Tools.notEmpty(PRACTITIONERTYPE))
pd.put("PRACTITIONERTYPE", PRACTITIONERTYPE.trim());
String SIGNEDSTATUS = pd.getString("SIGNEDSTATUS"); // 关键词检索条件
if (Tools.notEmpty(SIGNEDSTATUS))
pd.put("SIGNEDSTATUS", SIGNEDSTATUS.trim());
String REPLYSTATUS = pd.getString("REPLYSTATUS"); // 关键词检索条件
if (Tools.notEmpty(REPLYSTATUS))
pd.put("REPLYSTATUS", REPLYSTATUS.trim());
page.setPd(pd);
List<PageData> notifications = securityReadDetail.getAllReadDetail(page);
map.put("varList", notifications);
map.put("page", page);
map.put("result", errInfo);
return map;
}
//列表
@RequestMapping(value = "/listForSecurityNotice")
// @RequiresPermissions("hidden:list")
@ResponseBody
public Object listForSecurityNotice(Page page) throws Exception {
Map<String, Object> map = new HashMap<String, Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
String TITLE = pd.getString("TITLE"); // 关键词检索条件
if (Tools.notEmpty(TITLE))
pd.put("TITLE", TITLE.trim());
String REPLYSTATUS = pd.getString("REPLYSTATUS"); // 关键词检索条件
if (Tools.notEmpty(REPLYSTATUS))
pd.put("REPLYSTATUS", REPLYSTATUS.trim());
page.setPd(pd);
List<PageData> varList = securityNoticeService.listForSecurityNotice(page); // 列出Hidden列表
map.put("varList", varList);
map.put("page", page);
map.put("result", errInfo);
return map;
}
//详情
@RequestMapping(value="/goEdit")
// @RequiresPermissions("traininginfo:edit")
@ResponseBody
public Object goEdit() throws Exception{
Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
pd = securityNoticeService.findById(pd); //根据ID读取
map.put("pd", pd);
map.put("result", errInfo);
return map;
}
/**
* @param
* @throws Exception
*/
@RequestMapping(value="/delete")
// @RequiresPermissions("traininginfo:del")
@ResponseBody
public Object delete() throws Exception{
Map<String,String> map = new HashMap<String,String>();
String errInfo = "success";
PageData pd = new PageData();
pd = this.getPageData();
pd.put("DELETOR", Jurisdiction.getUSER_ID()); //删除人id
pd.put("DELETORNAME", Jurisdiction.getUsername()); //删除人姓名
pd.put("DELETETIME", DateUtil.date2Str(new Date())); //删除时间
securityNoticeService.delete(pd);
map.put("result", errInfo); //返回结果
return map;
}
}

View File

@ -245,7 +245,7 @@ public class LoginController extends BaseController {
* id
* (0--13)
*
* @param userPd
* @param
*
*/
private String superviseDepart(PageData dpd) throws Exception {

View File

@ -0,0 +1,138 @@
package com.zcloud.entity.comprehensivemanagement;
import lombok.Data;
@Data
public class Notification {
/**
* ID
*/
private String NOTIFICATIONID;
/**
*
*/
private String TITLE;
/**
*
*/
private String LEVEL;
/**
*
*/
private String REPLY;
/**
*
*/
private String SIGNING;
/**
*
*/
private String transportationcompany;
/**
*
*/
private String PRESON;
/**
*
*/
private String NOTIFICATIONCONTENT;
/**
*
*/
private String REPLYSTATUS;
/**
*
*/
private String PRACTITIONER;
/**
*
*/
private String PRACTITIONERTYPE;
/**
*
*/
private String SIGNEDSTATUS;
/**
*
*/
private String SIGNEDDATE;
/**
*
*/
private String REPLYDATE;
/**
*
*/
private String REPLYCONTENT;
/**
*
*/
private String POSTSTATUS;
/**
*
*/
private String ISDELETE;
/**
*
*/
private String CREATOR;
/**
*
*/
private String CREATORNAME;
/**
*
*/
private String CREATETIME;
/**
* id
*/
private String OPERATOR;
/**
*
*/
private String OPERATORNAME;
/**
*
*/
private String OPERATTIME;
/**
* id
*/
private String DELETOR;
/**
*
*/
private String DELETORNAME;
/**
*
*/
private String DELETETIME;
}

View File

@ -0,0 +1,39 @@
package com.zcloud.mapper.datasource.comprehensive;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@Mapper
public interface SecurityNoticeMapper {
/**
* @param pd
* @throws Exception
*/
void save(PageData pd);
/**
*
* @param page
* @return
*/
List<PageData> datalistPage(Page page);
/**id
* @param pd
* @throws Exception
*/
PageData findById(PageData pd);
/**
* @param pd
* @throws Exception
*/
void delete(PageData pd);
List<PageData> getAllNotifications(PageData pd);
}

View File

@ -0,0 +1,13 @@
package com.zcloud.mapper.datasource.comprehensive;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
public interface SecurityReadDetailMapper {
void save(PageData pd);
List<PageData> datalistPage(Page page);
}

View File

@ -0,0 +1,24 @@
package com.zcloud.service.comprehensive;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
public interface SecurityNoticeService {
void save(PageData pd);
List<PageData> listForSecurityNotice(Page page)throws Exception;
PageData findById(PageData pd)throws Exception;
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception;
List<PageData> getAllNotifications(PageData pd);
}

View File

@ -0,0 +1,12 @@
package com.zcloud.service.comprehensive;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import java.util.List;
public interface SecurityReadDetailService {
void save(PageData pd);
List<PageData> getAllReadDetail(Page page)throws Exception;
}

View File

@ -0,0 +1,49 @@
package com.zcloud.service.comprehensive.impl;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.comprehensive.SecurityNoticeMapper;
import com.zcloud.service.comprehensive.SecurityNoticeService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
@Service
public class SecurityNoticeServiceImpl implements SecurityNoticeService {
@Resource
private SecurityNoticeMapper securityNoticeMapper;
@Override
public void save(PageData pd) {
securityNoticeMapper.save(pd);
}
@Override
public List<PageData> listForSecurityNotice(Page page) throws Exception {
return securityNoticeMapper.datalistPage(page);
}
/**id
* @param pd
*/
@Override
public PageData findById(PageData pd)throws Exception {
return securityNoticeMapper.findById(pd);
}
/**
* @param pd
* @throws Exception
*/
public void delete(PageData pd)throws Exception{
securityNoticeMapper.delete(pd);
}
@Override
public List<PageData> getAllNotifications(PageData pd) {
return securityNoticeMapper.getAllNotifications(pd);
}
}

View File

@ -0,0 +1,25 @@
package com.zcloud.service.comprehensive.impl;
import com.zcloud.entity.Page;
import com.zcloud.entity.PageData;
import com.zcloud.mapper.datasource.comprehensive.SecurityReadDetailMapper;
import com.zcloud.service.comprehensive.SecurityReadDetailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
@Service
public class SecurityReadDetailImpl implements SecurityReadDetailService {
@Autowired
private SecurityReadDetailMapper securityReadDetailMapper;
@Override
public void save(PageData pd) {
securityReadDetailMapper.save(pd);
}
@Override
public List<PageData> getAllReadDetail(Page page) {
return securityReadDetailMapper.datalistPage(page);
}
}

View File

@ -1,5 +1,5 @@
spring.application.name=integrated_traffic
server.port=8099
server.port=8093
datasource.no1.driver-class-name: com.mysql.cj.jdbc.Driver
datasource.no1.url=jdbc:mysql://192.168.0.64:3306/qa-traffic-prevention?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=utf-8

View File

@ -0,0 +1,179 @@
<?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.zcloud.mapper.datasource.comprehensive.SecurityNoticeMapper">
<!--表名 -->
<sql id="tableName">
BUS_TRAFFIC_COMPREHENSIVEMANAGEMENT_SECURITYNOTICE
</sql>
<!--数据字典表名 -->
<sql id="dicTableName">
SYS_DICTIONARIES
</sql>
<!-- 字段 -->
<sql id="Field">
f.NOTIFICATION_ID,
f.TITLE,
f.LEVEL,
f.REPLY,
f.SIGNING,
f.TRANSPORTATIONCOMPANY,
f.PERSON,
f.NOTIFICATIONCONTENT,
f.ISDELETE,
f.DELETOR,
f.DELETETIME,
f.CREATOR,
f.CREATORNAME,
f.CREATETIME,
f.OPERATOR,
f.OPERATORNAME,
f.OPERATTIME,
f.PRACTITIONER,
f.PRACTITIONERTYPE,
f.SIGNEDSTATUS,
f.SIGNEDDATE,
f.REPLYDATE,
f.REPLYCONTENT,
f.POSTSTATUS
</sql>
<!-- 字段用于新增 -->
<sql id="Field2">
NOTIFICATION_ID,
TITLE,
LEVEL,
REPLY,
SIGNING,
TRANSPORTATIONCOMPANY,
PERSON,
NOTIFICATIONCONTENT,
ISDELETE,
DELETOR,
DELETETIME,
CREATOR,
CREATORNAME,
CREATETIME,
OPERATOR,
OPERATORNAME,
OPERATTIME,
REPLYSTATUS,
PRACTITIONER,
PRACTITIONERTYPE,
SIGNEDSTATUS,
SIGNEDDATE,
REPLYDATE,
REPLYCONTENT,
POSTSTATUS
</sql>
<!-- 字段值 -->
<sql id="FieldValue">
#{NOTIFICATION_ID},
#{TITLE},
#{LEVEL},
#{REPLY},
#{SIGNING},
#{TRANSPORTATIONCOMPANY},
#{PERSON},
#{NOTIFICATIONCONTENT},
#{ISDELETE},
#{DELETOR},
#{DELETETIME},
#{CREATOR},
#{CREATORNAME},
#{CREATETIME},
#{OPERATOR},
#{OPERATORNAME},
#{OPERATTIME},
#{REPLYSTATUS},
#{PRACTITIONER},
#{PRACTITIONERTYPE},
#{SIGNEDSTATUS},
#{SIGNEDDATE},
#{REPLYDATE},
#{REPLYCONTENT},
#{POSTSTATUS}
</sql>
<!-- 新增-->
<insert id="save" parameterType="pd">
insert into
<include refid="tableName"></include>
(
<include refid="Field2"></include>
) values (
<include refid="FieldValue"></include>
)
</insert>
<!-- 删除-->
<delete id="delete" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '1',
DELETOR = #{DELETOR},
DELETETIME = #{DELETETIME}
where
NOTIFICATION_ID = #{NOTIFICATION_ID}
</delete>
<!--列表-->
<select id="datalistPage" parameterType="page" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where f.ISDELETE = '0'
<if test="pd.TITLE != null and pd.TITLE != ''"><!-- 关键词检索-通知标题 -->
and f.TITLE = #{pd.TITLE}
</if>
<if test="pd.REPLYSTATUS != null and pd.REPLYSTATUS != ''"><!-- 关键词检索-回复情况 -->
and f.REPLYSTATUS = #{pd.REPLYSTATUS}
</if>
<if test="pd.SIGNEDSTATUS != null and pd.SIGNEDSTATUS != ''"><!-- 关键词检索-签收情况 -->
and f.SIGNEDSTATUS = #{pd.SIGNEDSTATUS}
</if>
<if test="pd.PRACTITIONERTYPE != null and pd.PRACTITIONERTYPE != ''"><!-- 关键词检索-从业类型 -->
and f.PRACTITIONERTYPE = #{pd.PRACTITIONERTYPE}
</if>
<if test="pd.PRACTITIONER != null and pd.PRACTITIONER != ''"><!-- 关键词检索-从业人员 -->
and f.PRACTITIONER = #{pd.PRACTITIONER}
</if>
</select>
<select id="findById" resultType="com.zcloud.entity.PageData" parameterType="com.zcloud.entity.PageData">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where
f.NOTIFICATION_ID = #{NOTIFICATION_ID}
</select>
<select id="getAllNotifications" parameterType="page" resultType="pd">
select
<include refid="Field"></include>,
d.NAME as practitionerTypeName
from
<include refid="tableName"></include> f
left join <include refid="dicTableName"></include> d on f.PRACTITIONERTYPE = d.DICTIONARIES_ID
where f.ISDELETE = '0'
<if test="PERSON != null and PERSON != ''"><!-- 关键词检索-从业人员 -->
and f.PERSON = #{PERSON}
</if>
<if test="PRACTITIONERTYPE != null and PRACTITIONERTYPE != ''"><!-- 关键词检索-从业类型 -->
and f.PRACTITIONERTYPE = #{PRACTITIONERTYPE}
</if>
<if test="REPLYSTATUS != null and REPLYSTATUS != ''"><!-- 关键词检索-回复情况 -->
and f.REPLYSTATUS = #{REPLYSTATUS}
</if>
<if test="SIGNEDSTATUS != null and SIGNEDSTATUS != ''"><!-- 关键词检索-签收情况 -->
and f.SIGNEDSTATUS = #{SIGNEDSTATUS}
</if>
</select>
</mapper>

View File

@ -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.zcloud.mapper.datasource.comprehensive.SecurityReadDetailMapper">
<!--表名 -->
<sql id="tableName">
BUS_TRAFFIC_READ_DETAIL
</sql>
<!--数据字典表名 -->
<sql id="dicTableName">
SYS_DICTIONARIES
</sql>
<!-- 字段 -->
<sql id="Field">
f.NOTIFICATION_ID,
f.TITLE,
f.LEVEL,
f.REPLYSTATUS,
f.SIGNEDSTATUS,
f.PERSON,
f.REPLYDATE,
f.REPLYCONTENT,
f.SIGNEDDATE,
f.ISDELETE,
f.DELETOR,
f.DELETORNAME,
f.DELETETIME,
f.CREATOR,
f.CREATORNAME,
f.CREATETIME,
f.OPERATOR,
f.OPERATORNAME,
f.OPERATTIME,
f.PRACTITIONERTYPE,
f.TRANSPORTATIONCOMPANY
</sql>
<!-- 字段用于新增 -->
<sql id="Field2">
NOTIFICATION_ID,
TITLE,
LEVEL,
REPLYSTATUS,
PERSON,
SIGNEDDATE,
REPLYDATE,
REPLYCONTENT,
ISDELETE,
DELETOR,
DELETORNAME,
DELETETIME,
CREATOR,
CREATORNAME,
CREATETIME,
OPERATOR,
OPERATORNAME,
OPERATTIME,
PRACTITIONERTYPE,
SIGNEDSTATUS
</sql>
<!-- 字段值 -->
<sql id="FieldValue">
#{NOTIFICATION_ID},
#{TITLE},
#{LEVEL},
#{REPLYSTATUS},
#{PERSON},
#{SIGNEDDATE},
#{REPLYDATE},
#{REPLYCONTENT},
#{ISDELETE},
#{DELETOR},
#{DELETORNAME},
#{DELETETIME},
#{CREATOR},
#{CREATORNAME},
#{CREATETIME},
#{OPERATOR},
#{OPERATORNAME},
#{OPERATTIME},
#{PRACTITIONERTYPE},
#{SIGNEDSTATUS}
</sql>
<!-- 新增-->
<insert id="save" parameterType="pd">
insert into
<include refid="tableName"></include>
(
<include refid="Field2"></include>
) values (
<include refid="FieldValue"></include>
)
</insert>
<select id="datalistPage" parameterType="page" resultType="pd">
select
<include refid="Field"></include>,
d.NAME as practitionerTypeName
from
<include refid="tableName"></include> f
left join <include refid="dicTableName"></include> d on f.PRACTITIONERTYPE = d.DICTIONARIES_ID
where f.ISDELETE = '0'
<if test="pd.PERSON != null and pd.PERSON != ''"><!-- 关键词检索-从业人员 -->
and f.PERSON = #{pd.PERSON}
</if>
<if test="pd.PRACTITIONERTYPE != null and pd.PRACTITIONERTYPE != ''"><!-- 关键词检索-从业类型 -->
and f.PRACTITIONERTYPE = #{pd.PRACTITIONERTYPE}
</if>
<if test="pd.REPLYSTATUS != null and pd.REPLYSTATUS != ''"><!-- 关键词检索-回复情况 -->
and f.REPLYSTATUS = #{pd.REPLYSTATUS}
</if>
<if test="pd.SIGNEDSTATUS != null and pd.SIGNEDSTATUS != ''"><!-- 关键词检索-签收情况 -->
and f.SIGNEDSTATUS = #{pd.SIGNEDSTATUS}
</if>
</select>
</mapper>

View File

@ -1,131 +0,0 @@
<?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.zcloud.mapper.dsno2.mq.MqErrorMessageLogMapper">
<!--表名 -->
<sql id="tableName">
MQ_MESSAGE_ERROR_LOG
</sql>
<!--数据字典表名 -->
<sql id="dicTableName">
SYS_DICTIONARIES
</sql>
<!-- 字段 -->
<sql id="Field">
f.MESSAGE_LOG_ID,
f.ERROR_MESSAGE,
f.TIME,
f.TYPE,
f.SOURCE,
f.MESSAGE_ERROR_LOG_ID
</sql>
<!-- 字段用于新增 -->
<sql id="Field2">
MESSAGE_LOG_ID,
ERROR_MESSAGE,
TIME,
TYPE,
SOURCE,
MESSAGE_ERROR_LOG_ID
</sql>
<!-- 字段值 -->
<sql id="FieldValue">
#{MESSAGE_LOG_ID},
#{ERROR_MESSAGE},
#{TIME},
#{TYPE},
#{SOURCE},
#{MESSAGE_ERROR_LOG_ID}
</sql>
<!-- 新增-->
<insert id="save" parameterType="pd">
insert into
<include refid="tableName"></include>
(
<include refid="Field2"></include>
) values (
<include refid="FieldValue"></include>
)
</insert>
<!-- 删除-->
<delete id="delete" parameterType="pd">
update
<include refid="tableName"></include>
set
ISDELETE = '1'
where
MESSAGE_ERROR_LOG_ID = #{MESSAGE_ERROR_LOG_ID}
</delete>
<!-- 修改 -->
<update id="edit" parameterType="pd">
update
<include refid="tableName"></include>
set
MESSAGE_LOG_ID = #{MESSAGE_LOG_ID},
ERROR_MESSAGE = #{ERROR_MESSAGE},
TIME = #{TIME},
TYPE = #{TYPE},
SOURCE = #{SOURCE},
MESSAGE_ERROR_LOG_ID = MESSAGE_ERROR_LOG_ID
where
MESSAGE_ERROR_LOG_ID = #{MESSAGE_ERROR_LOG_ID}
</update>
<!-- 通过ID获取数据 -->
<select id="findById" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where
f.MESSAGE_ERROR_LOG_ID = #{MESSAGE_ERROR_LOG_ID}
</select>
<!-- 列表 -->
<select id="datalistPage" parameterType="page" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
where f.ISDELETE = '0'
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
and
(
<!-- 根据需求自己加检索条件
字段1 LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
or
字段2 LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
-->
)
</if>
</select>
<!-- 列表(全部) -->
<select id="listAll" parameterType="pd" resultType="pd">
select
<include refid="Field"></include>
from
<include refid="tableName"></include> f
</select>
<!-- 批量删除 -->
<delete id="deleteAll" parameterType="String">
update
<include refid="tableName"></include>
set
ISDELETE = '1'
where
MESSAGE_ERROR_LOG_ID in
<foreach item="item" index="index" collection="ArrayDATA_IDS" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
</mapper>