疯狂的狮子li
2021-04-13 876a06a9cd2adfcdc390caeef50cfbfa2e8e860f
update mp化
已修改29个文件
685 ■■■■ 文件已修改
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysDept.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysDictData.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysDictType.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysMenu.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysRole.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysUser.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-framework/src/main/java/com/ruoyi/framework/config/MybatisPlusConfig.java 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysConfig.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysLogininfor.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysNotice.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysOperLog.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysPost.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysLogininforMapper.java 30 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysNoticeMapper.java 48 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysOperLogMapper.java 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysPostMapper.java 69 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysUserPostMapper.java 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysConfigServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDictTypeServiceImpl.java 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysLogininforServiceImpl.java 28 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysNoticeServiceImpl.java 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysOperLogServiceImpl.java 44 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysPostServiceImpl.java 33 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/resources/mapper/system/SysLogininforMapper.xml 38 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/resources/mapper/system/SysNoticeMapper.xml 80 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/resources/mapper/system/SysOperLogMapper.xml 75 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/resources/mapper/system/SysPostMapper.xml 83 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-system/src/main/resources/mapper/system/SysUserPostMapper.xml 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysDept.java
@@ -9,6 +9,7 @@
import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.*;
/**
@@ -21,7 +22,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_dept")
public class SysDept
public class SysDept implements Serializable
{
    private static final long serialVersionUID = 1L;
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysDictData.java
@@ -11,6 +11,7 @@
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -25,13 +26,13 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_dict_data")
public class SysDictData
public class SysDictData implements Serializable
{
    private static final long serialVersionUID = 1L;
    /** 字典编码 */
    @Excel(name = "字典编码", cellType = ColumnType.NUMERIC)
    @TableId(value = "dept_code",type = IdType.AUTO)
    @TableId(value = "dict_code",type = IdType.AUTO)
    private Long dictCode;
    /** 字典排序 */
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysDictType.java
@@ -10,6 +10,7 @@
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -23,8 +24,8 @@
@Data
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_config")
public class SysDictType
@TableName("sys_dict_type")
public class SysDictType implements Serializable
{
    private static final long serialVersionUID = 1L;
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysMenu.java
@@ -8,6 +8,7 @@
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.*;
/**
@@ -20,7 +21,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_menu")
public class SysMenu
public class SysMenu implements Serializable
{
    private static final long serialVersionUID = 1L;
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysRole.java
@@ -10,6 +10,7 @@
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -24,7 +25,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_role")
public class SysRole
public class SysRole implements Serializable
{
    private static final long serialVersionUID = 1L;
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysUser.java
@@ -15,6 +15,7 @@
import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
@@ -30,7 +31,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_user")
public class SysUser
public class SysUser implements Serializable
{
    private static final long serialVersionUID = 1L;
ruoyi-framework/src/main/java/com/ruoyi/framework/config/MybatisPlusConfig.java
@@ -2,14 +2,7 @@
import com.baomidou.mybatisplus.annotation.DbType;
import com.baomidou.mybatisplus.core.handlers.MetaObjectHandler;
import com.baomidou.mybatisplus.core.incrementer.IKeyGenerator;
import com.baomidou.mybatisplus.core.incrementer.IdentifierGenerator;
import com.baomidou.mybatisplus.core.injector.DefaultSqlInjector;
import com.baomidou.mybatisplus.core.injector.ISqlInjector;
import com.baomidou.mybatisplus.extension.incrementer.H2KeyGenerator;
import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
import com.baomidou.mybatisplus.extension.plugins.inner.BlockAttackInnerInterceptor;
import com.baomidou.mybatisplus.extension.plugins.inner.IllegalSQLInnerInterceptor;
import com.baomidou.mybatisplus.extension.plugins.inner.OptimisticLockerInnerInterceptor;
import com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor;
import com.ruoyi.framework.mybatisplus.CreateAndUpdateMetaObjectHandler;
@@ -29,7 +22,7 @@
        // 乐观锁插件
        interceptor.addInnerInterceptor(optimisticLockerInnerInterceptor());
        // 阻断插件
        interceptor.addInnerInterceptor(blockAttackInnerInterceptor());
//        interceptor.addInnerInterceptor(blockAttackInnerInterceptor());
        return interceptor;
    }
@@ -58,9 +51,9 @@
     * 如果是对全表的删除或更新操作,就会终止该操作
     * https://baomidou.com/guide/interceptor-block-attack.html
     */
    public BlockAttackInnerInterceptor blockAttackInnerInterceptor() {
        return new BlockAttackInnerInterceptor();
    }
//    public BlockAttackInnerInterceptor blockAttackInnerInterceptor() {
//        return new BlockAttackInnerInterceptor();
//    }
    /**
     * sql性能规范插件(垃圾SQL拦截)
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysConfig.java
@@ -10,6 +10,7 @@
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -24,7 +25,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_config")
public class SysConfig {
public class SysConfig implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysLogininfor.java
@@ -11,6 +11,7 @@
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -25,7 +26,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_logininfor")
public class SysLogininfor {
public class SysLogininfor implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysNotice.java
@@ -8,6 +8,7 @@
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -21,7 +22,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_notice")
public class SysNotice {
public class SysNotice implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysOperLog.java
@@ -11,6 +11,7 @@
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -25,7 +26,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_oper_log")
public class SysOperLog {
public class SysOperLog implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
@@ -50,6 +51,7 @@
    /**
     * 业务类型数组
     */
    @TableField(exist = false)
    private Integer[] businessTypes;
    /**
ruoyi-system/src/main/java/com/ruoyi/system/domain/SysPost.java
@@ -10,6 +10,7 @@
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@@ -24,7 +25,7 @@
@NoArgsConstructor
@Accessors(chain = true)
@TableName("sys_post")
public class SysPost {
public class SysPost implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysLogininforMapper.java
@@ -3,41 +3,11 @@
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.system.domain.SysLogininfor;
import java.util.List;
/**
 * 系统访问日志情况信息 数据层
 *
 * @author ruoyi
 */
public interface SysLogininforMapper extends BaseMapper<SysLogininfor> {
    /**
     * 新增系统登录日志
     *
     * @param logininfor 访问日志对象
     */
    public void insertLogininfor(SysLogininfor logininfor);
    /**
     * 查询系统登录日志集合
     *
     * @param logininfor 访问日志对象
     * @return 登录记录集合
     */
    public List<SysLogininfor> selectLogininforList(SysLogininfor logininfor);
    /**
     * 批量删除系统登录日志
     *
     * @param infoIds 需要删除的登录日志ID
     * @return 结果
     */
    public int deleteLogininforByIds(Long[] infoIds);
    /**
     * 清空系统登录日志
     *
     * @return 结果
     */
    public int cleanLogininfor();
}
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysNoticeMapper.java
@@ -3,59 +3,11 @@
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.system.domain.SysNotice;
import java.util.List;
/**
 * 通知公告表 数据层
 *
 * @author ruoyi
 */
public interface SysNoticeMapper extends BaseMapper<SysNotice> {
    /**
     * 查询公告信息
     *
     * @param noticeId 公告ID
     * @return 公告信息
     */
    public SysNotice selectNoticeById(Long noticeId);
    /**
     * 查询公告列表
     *
     * @param notice 公告信息
     * @return 公告集合
     */
    public List<SysNotice> selectNoticeList(SysNotice notice);
    /**
     * 新增公告
     *
     * @param notice 公告信息
     * @return 结果
     */
    public int insertNotice(SysNotice notice);
    /**
     * 修改公告
     *
     * @param notice 公告信息
     * @return 结果
     */
    public int updateNotice(SysNotice notice);
    /**
     * 批量删除公告
     *
     * @param noticeId 公告ID
     * @return 结果
     */
    public int deleteNoticeById(Long noticeId);
    /**
     * 批量删除公告信息
     *
     * @param noticeIds 需要删除的公告ID
     * @return 结果
     */
    public int deleteNoticeByIds(Long[] noticeIds);
}
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysOperLogMapper.java
@@ -3,47 +3,11 @@
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.system.domain.SysOperLog;
import java.util.List;
/**
 * 操作日志 数据层
 *
 * @author ruoyi
 */
public interface SysOperLogMapper extends BaseMapper<SysOperLog> {
    /**
     * 新增操作日志
     *
     * @param operLog 操作日志对象
     */
    public void insertOperlog(SysOperLog operLog);
    /**
     * 查询系统操作日志集合
     *
     * @param operLog 操作日志对象
     * @return 操作日志集合
     */
    public List<SysOperLog> selectOperLogList(SysOperLog operLog);
    /**
     * 批量删除系统操作日志
     *
     * @param operIds 需要删除的操作日志ID
     * @return 结果
     */
    public int deleteOperLogByIds(Long[] operIds);
    /**
     * 查询操作日志详细
     *
     * @param operId 操作ID
     * @return 操作日志对象
     */
    public SysOperLog selectOperLogById(Long operId);
    /**
     * 清空操作日志
     */
    public void cleanOperLog();
}
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysPostMapper.java
@@ -11,28 +11,6 @@
 * @author ruoyi
 */
public interface SysPostMapper extends BaseMapper<SysPost> {
    /**
     * 查询岗位数据集合
     *
     * @param post 岗位信息
     * @return 岗位数据集合
     */
    public List<SysPost> selectPostList(SysPost post);
    /**
     * 查询所有岗位
     *
     * @return 岗位列表
     */
    public List<SysPost> selectPostAll();
    /**
     * 通过岗位ID查询岗位信息
     *
     * @param postId 岗位ID
     * @return 角色对象信息
     */
    public SysPost selectPostById(Long postId);
    /**
     * 根据用户ID获取岗位选择框列表
@@ -50,51 +28,4 @@
     */
    public List<SysPost> selectPostsByUserName(String userName);
    /**
     * 删除岗位信息
     *
     * @param postId 岗位ID
     * @return 结果
     */
    public int deletePostById(Long postId);
    /**
     * 批量删除岗位信息
     *
     * @param postIds 需要删除的岗位ID
     * @return 结果
     */
    public int deletePostByIds(Long[] postIds);
    /**
     * 修改岗位信息
     *
     * @param post 岗位信息
     * @return 结果
     */
    public int updatePost(SysPost post);
    /**
     * 新增岗位信息
     *
     * @param post 岗位信息
     * @return 结果
     */
    public int insertPost(SysPost post);
    /**
     * 校验岗位名称
     *
     * @param postName 岗位名称
     * @return 结果
     */
    public SysPost checkPostNameUnique(String postName);
    /**
     * 校验岗位编码
     *
     * @param postCode 岗位编码
     * @return 结果
     */
    public SysPost checkPostCodeUnique(String postCode);
}
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysUserPostMapper.java
@@ -20,14 +20,6 @@
    public int deleteUserPostByUserId(Long userId);
    /**
     * 通过岗位ID查询岗位使用数量
     *
     * @param postId 岗位ID
     * @return 结果
     */
    public int countUserPostById(Long postId);
    /**
     * 批量删除用户和岗位关联
     *
     * @param ids 需要删除的数据ID
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysConfigServiceImpl.java
@@ -91,10 +91,10 @@
        lqw.eq(StrUtil.isNotBlank(config.getConfigType()), SysConfig::getConfigType, config.getConfigType());
        lqw.like(StrUtil.isNotBlank(config.getConfigKey()), SysConfig::getConfigKey, config.getConfigKey());
        Map<String, Object> params = config.getParams();
        lqw.apply(params.get("beginTime") != null,
        lqw.apply(Validator.isNotEmpty(params.get("beginTime")),
                "date_format(create_time,'%y%m%d') >= date_format(#{0},'%y%m%d')",
                params.get("beginTime"));
        lqw.apply(params.get("endTime") != null,
        lqw.apply(Validator.isNotEmpty(params.get("endTime")),
                "date_format(create_time,'%y%m%d') >= date_format(#{0},'%y%m%d')",
                params.get("endTime"));
        return baseMapper.selectList(lqw);
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java
@@ -32,8 +32,6 @@
 */
@Service
public class SysDeptServiceImpl extends ServiceImpl<SysDeptMapper, SysDept> implements ISysDeptService {
    @Autowired
    private SysDeptMapper deptMapper;
    @Autowired
    private SysRoleMapper roleMapper;
@@ -109,7 +107,7 @@
    @Override
    public List<Integer> selectDeptListByRoleId(Long roleId) {
        SysRole role = roleMapper.selectRoleById(roleId);
        return deptMapper.selectDeptListByRoleId(roleId, role.isDeptCheckStrictly());
        return baseMapper.selectDeptListByRoleId(roleId, role.isDeptCheckStrictly());
    }
    /**
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysDictTypeServiceImpl.java
@@ -2,6 +2,7 @@
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.lang.Validator;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
@@ -29,8 +30,6 @@
 */
@Service
public class SysDictTypeServiceImpl extends ServiceImpl<SysDictTypeMapper, SysDictType> implements ISysDictTypeService {
    @Autowired
    private SysDictTypeMapper dictTypeMapper;
    @Autowired
    private SysDictDataMapper dictDataMapper;
@@ -45,7 +44,7 @@
            List<SysDictData> dictDatas = dictDataMapper.selectList(
                    new LambdaQueryWrapper<SysDictData>()
                            .eq(SysDictData::getStatus, 0)
                            .eq(SysDictData::getDictType, dictType)
                            .eq(SysDictData::getDictType, dictType.getDictType())
                            .orderByAsc(SysDictData::getDictSort));
            DictUtils.setDictCache(dictType.getDictType(), dictDatas);
        }
@@ -61,13 +60,13 @@
    public List<SysDictType> selectDictTypeList(SysDictType dictType) {
        Map<String, Object> params = dictType.getParams();
        return list(new LambdaQueryWrapper<SysDictType>()
                .like(SysDictType::getDictName, dictType.getDictName())
                .eq(SysDictType::getStatus, dictType.getStatus())
                .like(SysDictType::getDictType, dictType.getDictType())
                .apply(params.get("beginTime") != null,
                .like(StrUtil.isNotBlank(dictType.getDictName()),SysDictType::getDictName, dictType.getDictName())
                .eq(StrUtil.isNotBlank(dictType.getStatus()),SysDictType::getStatus, dictType.getStatus())
                .like(StrUtil.isNotBlank(dictType.getDictType()),SysDictType::getDictType, dictType.getDictType())
                .apply(Validator.isNotEmpty(params.get("beginTime")),
                        "date_format(create_time,'%y%m%d') >= date_format({0},'%y%m%d')",
                        params.get("beginTime"))
                .apply(params.get("endTime") != null,
                .apply(Validator.isNotEmpty(params.get("endTime")),
                        "date_format(create_time,'%y%m%d') <= date_format({0},'%y%m%d')",
                        params.get("endTime")));
    }
@@ -165,7 +164,7 @@
     */
    @Override
    public int insertDictType(SysDictType dictType) {
        int row = dictTypeMapper.insert(dictType);
        int row = baseMapper.insert(dictType);
        if (row > 0) {
            DictUtils.clearDictCache();
        }
@@ -185,7 +184,7 @@
        dictDataMapper.update(null, new LambdaUpdateWrapper<SysDictData>()
                .set(SysDictData::getDictType, dictType.getDictType())
                .eq(SysDictData::getDictType, oldDict.getDictType()));
        int row = dictTypeMapper.updateById(dictType);
        int row = baseMapper.updateById(dictType);
        if (row > 0) {
            DictUtils.clearDictCache();
        }
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysLogininforServiceImpl.java
@@ -1,13 +1,17 @@
package com.ruoyi.system.service.impl;
import cn.hutool.core.lang.Validator;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.system.domain.SysLogininfor;
import com.ruoyi.system.mapper.SysLogininforMapper;
import com.ruoyi.system.service.ISysLogininforService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
/**
 * 系统访问日志情况信息 服务层处理
@@ -17,9 +21,6 @@
@Service
public class SysLogininforServiceImpl extends ServiceImpl<SysLogininforMapper, SysLogininfor> implements ISysLogininforService {
    @Autowired
    private SysLogininforMapper logininforMapper;
    /**
     * 新增系统登录日志
     *
@@ -27,7 +28,7 @@
     */
    @Override
    public void insertLogininfor(SysLogininfor logininfor) {
        logininforMapper.insertLogininfor(logininfor);
        save(logininfor);
    }
    /**
@@ -38,7 +39,18 @@
     */
    @Override
    public List<SysLogininfor> selectLogininforList(SysLogininfor logininfor) {
        return logininforMapper.selectLogininforList(logininfor);
        Map<String, Object> params = logininfor.getParams();
        return list(new LambdaQueryWrapper<SysLogininfor>()
                .like(StrUtil.isNotBlank(logininfor.getIpaddr()),SysLogininfor::getIpaddr,logininfor.getIpaddr())
                .eq(StrUtil.isNotBlank(logininfor.getStatus()),SysLogininfor::getStatus,logininfor.getStatus())
                .like(StrUtil.isNotBlank(logininfor.getUserName()),SysLogininfor::getUserName,logininfor.getUserName())
                .apply(Validator.isNotEmpty(params.get("beginTime")),
                        "date_format(login_time,'%y%m%d') &gt;= date_format({0},'%y%m%d')",
                        params.get("beginTime"))
                .apply(Validator.isNotEmpty(params.get("endTime")),
                        "date_format(login_time,'%y%m%d') &lt;= date_format({0},'%y%m%d'",
                        params.get("endTime"))
                .orderByDesc(SysLogininfor::getInfoId));
    }
    /**
@@ -49,7 +61,7 @@
     */
    @Override
    public int deleteLogininforByIds(Long[] infoIds) {
        return logininforMapper.deleteLogininforByIds(infoIds);
        return baseMapper.deleteBatchIds(Arrays.asList(infoIds));
    }
    /**
@@ -57,6 +69,6 @@
     */
    @Override
    public void cleanLogininfor() {
        logininforMapper.cleanLogininfor();
        remove(new LambdaQueryWrapper<>());
    }
}
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysNoticeServiceImpl.java
@@ -1,13 +1,15 @@
package com.ruoyi.system.service.impl;
import java.util.List;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.domain.SysNotice;
import com.ruoyi.system.mapper.SysNoticeMapper;
import com.ruoyi.system.service.ISysNoticeService;
import org.springframework.stereotype.Service;
import java.util.Arrays;
import java.util.List;
/**
 * 公告 服务层实现
@@ -16,8 +18,6 @@
 */
@Service
public class SysNoticeServiceImpl extends ServiceImpl<SysNoticeMapper, SysNotice> implements ISysNoticeService {
    @Autowired
    private SysNoticeMapper noticeMapper;
    /**
     * 查询公告信息
@@ -27,7 +27,7 @@
     */
    @Override
    public SysNotice selectNoticeById(Long noticeId) {
        return noticeMapper.selectNoticeById(noticeId);
        return getById(noticeId);
    }
    /**
@@ -38,7 +38,10 @@
     */
    @Override
    public List<SysNotice> selectNoticeList(SysNotice notice) {
        return noticeMapper.selectNoticeList(notice);
        return list(new LambdaQueryWrapper<SysNotice>()
                .like(StrUtil.isNotBlank(notice.getNoticeTitle()),SysNotice::getNoticeTitle,notice.getNoticeTitle())
                .eq(StrUtil.isNotBlank(notice.getNoticeType()),SysNotice::getNoticeType,notice.getNoticeType())
                .like(StrUtil.isNotBlank(notice.getCreateBy()),SysNotice::getCreateBy,notice.getCreateBy()));
    }
    /**
@@ -49,7 +52,7 @@
     */
    @Override
    public int insertNotice(SysNotice notice) {
        return noticeMapper.insertNotice(notice);
        return baseMapper.insert(notice);
    }
    /**
@@ -60,7 +63,7 @@
     */
    @Override
    public int updateNotice(SysNotice notice) {
        return noticeMapper.updateNotice(notice);
        return baseMapper.updateById(notice);
    }
    /**
@@ -71,7 +74,7 @@
     */
    @Override
    public int deleteNoticeById(Long noticeId) {
        return noticeMapper.deleteNoticeById(noticeId);
        return baseMapper.deleteById(noticeId);
    }
    /**
@@ -82,6 +85,6 @@
     */
    @Override
    public int deleteNoticeByIds(Long[] noticeIds) {
        return noticeMapper.deleteNoticeByIds(noticeIds);
        return baseMapper.deleteBatchIds(Arrays.asList(noticeIds));
    }
}
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysOperLogServiceImpl.java
@@ -1,13 +1,18 @@
package com.ruoyi.system.service.impl;
import java.util.List;
import cn.hutool.core.lang.Validator;
import cn.hutool.core.util.ArrayUtil;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.domain.SysOperLog;
import com.ruoyi.system.mapper.SysOperLogMapper;
import com.ruoyi.system.service.ISysOperLogService;
import org.springframework.stereotype.Service;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
/**
 * 操作日志 服务层处理
@@ -16,8 +21,6 @@
 */
@Service
public class SysOperLogServiceImpl extends ServiceImpl<SysOperLogMapper, SysOperLog> implements ISysOperLogService {
    @Autowired
    private SysOperLogMapper operLogMapper;
    /**
     * 新增操作日志
@@ -26,7 +29,7 @@
     */
    @Override
    public void insertOperlog(SysOperLog operLog) {
        operLogMapper.insertOperlog(operLog);
        save(operLog);
    }
    /**
@@ -37,7 +40,26 @@
     */
    @Override
    public List<SysOperLog> selectOperLogList(SysOperLog operLog) {
        return operLogMapper.selectOperLogList(operLog);
        Map<String, Object> params = operLog.getParams();
        return list(new LambdaQueryWrapper<SysOperLog>()
                .like(StrUtil.isNotBlank(operLog.getTitle()),SysOperLog::getTitle,operLog.getTitle())
                .eq(operLog.getBusinessType() != null && operLog.getBusinessType() > 0,
                        SysOperLog::getBusinessType,operLog.getBusinessType())
                .func(f -> {
                    if (ArrayUtil.isNotEmpty(operLog.getBusinessTypes())){
                        f.in(SysOperLog::getBusinessType, Arrays.asList(operLog.getBusinessTypes()));
                    }
                })
                .eq(operLog.getStatus() != null && operLog.getStatus() > 0,
                        SysOperLog::getStatus,operLog.getStatus())
                .like(StrUtil.isNotBlank(operLog.getOperName()),SysOperLog::getOperName,operLog.getOperName())
                .apply(Validator.isNotEmpty(params.get("beginTime")),
                        "date_format(login_time,'%y%m%d') &gt;= date_format({0},'%y%m%d')",
                        params.get("beginTime"))
                .apply(Validator.isNotEmpty(params.get("endTime")),
                        "date_format(login_time,'%y%m%d') &lt;= date_format({0},'%y%m%d'",
                        params.get("endTime"))
                .orderByDesc(SysOperLog::getOperId));
    }
    /**
@@ -48,7 +70,7 @@
     */
    @Override
    public int deleteOperLogByIds(Long[] operIds) {
        return operLogMapper.deleteOperLogByIds(operIds);
        return baseMapper.deleteBatchIds(Arrays.asList(operIds));
    }
    /**
@@ -59,7 +81,7 @@
     */
    @Override
    public SysOperLog selectOperLogById(Long operId) {
        return operLogMapper.selectOperLogById(operId);
        return getById(operId);
    }
    /**
@@ -67,6 +89,6 @@
     */
    @Override
    public void cleanOperLog() {
        operLogMapper.cleanOperLog();
        remove(new LambdaQueryWrapper<>());
    }
}
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysPostServiceImpl.java
@@ -1,16 +1,20 @@
package com.ruoyi.system.service.impl;
import cn.hutool.core.lang.Validator;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.common.constant.UserConstants;
import com.ruoyi.common.exception.CustomException;
import com.ruoyi.system.domain.SysPost;
import com.ruoyi.system.domain.SysUserPost;
import com.ruoyi.system.mapper.SysPostMapper;
import com.ruoyi.system.mapper.SysUserPostMapper;
import com.ruoyi.system.service.ISysPostService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.Arrays;
import java.util.List;
/**
@@ -20,8 +24,6 @@
 */
@Service
public class SysPostServiceImpl extends ServiceImpl<SysPostMapper, SysPost> implements ISysPostService {
    @Autowired
    private SysPostMapper postMapper;
    @Autowired
    private SysUserPostMapper userPostMapper;
@@ -34,7 +36,10 @@
     */
    @Override
    public List<SysPost> selectPostList(SysPost post) {
        return postMapper.selectPostList(post);
        return list(new LambdaQueryWrapper<SysPost>()
                .like(StrUtil.isNotBlank(post.getPostCode()), SysPost::getPostCode, post.getPostCode())
                .eq(StrUtil.isNotBlank(post.getStatus()), SysPost::getStatus, post.getStatus())
                .like(StrUtil.isNotBlank(post.getPostName()), SysPost::getPostName, post.getPostName()));
    }
    /**
@@ -44,7 +49,7 @@
     */
    @Override
    public List<SysPost> selectPostAll() {
        return postMapper.selectPostAll();
        return list();
    }
    /**
@@ -55,7 +60,7 @@
     */
    @Override
    public SysPost selectPostById(Long postId) {
        return postMapper.selectPostById(postId);
        return getById(postId);
    }
    /**
@@ -66,7 +71,7 @@
     */
    @Override
    public List<Integer> selectPostListByUserId(Long userId) {
        return postMapper.selectPostListByUserId(userId);
        return baseMapper.selectPostListByUserId(userId);
    }
    /**
@@ -78,7 +83,8 @@
    @Override
    public String checkPostNameUnique(SysPost post) {
        Long postId = Validator.isNull(post.getPostId()) ? -1L : post.getPostId();
        SysPost info = postMapper.checkPostNameUnique(post.getPostName());
        SysPost info = getOne(new LambdaQueryWrapper<SysPost>()
                .eq(SysPost::getPostName, post.getPostName()).last("limit 1"));
        if (Validator.isNotNull(info) && info.getPostId().longValue() != postId.longValue()) {
            return UserConstants.NOT_UNIQUE;
        }
@@ -94,7 +100,8 @@
    @Override
    public String checkPostCodeUnique(SysPost post) {
        Long postId = Validator.isNull(post.getPostId()) ? -1L : post.getPostId();
        SysPost info = postMapper.checkPostCodeUnique(post.getPostCode());
        SysPost info = getOne(new LambdaQueryWrapper<SysPost>()
                .eq(SysPost::getPostCode, post.getPostCode()).last("limit 1"));
        if (Validator.isNotNull(info) && info.getPostId().longValue() != postId.longValue()) {
            return UserConstants.NOT_UNIQUE;
        }
@@ -109,7 +116,7 @@
     */
    @Override
    public int countUserPostById(Long postId) {
        return userPostMapper.countUserPostById(postId);
        return userPostMapper.selectCount(new LambdaQueryWrapper<SysUserPost>().eq(SysUserPost::getPostId,postId));
    }
    /**
@@ -120,7 +127,7 @@
     */
    @Override
    public int deletePostById(Long postId) {
        return postMapper.deletePostById(postId);
        return baseMapper.deleteById(postId);
    }
    /**
@@ -138,7 +145,7 @@
                throw new CustomException(String.format("%1$s已分配,不能删除", post.getPostName()));
            }
        }
        return postMapper.deletePostByIds(postIds);
        return baseMapper.deleteBatchIds(Arrays.asList(postIds));
    }
    /**
@@ -149,7 +156,7 @@
     */
    @Override
    public int insertPost(SysPost post) {
        return postMapper.insertPost(post);
        return baseMapper.insert(post);
    }
    /**
@@ -160,6 +167,6 @@
     */
    @Override
    public int updatePost(SysPost post) {
        return postMapper.updatePost(post);
        return baseMapper.updateById(post);
    }
}
ruoyi-system/src/main/resources/mapper/system/SysLogininforMapper.xml
@@ -16,42 +16,4 @@
        <result property="loginTime" column="login_time"/>
    </resultMap>
    <insert id="insertLogininfor" parameterType="SysLogininfor">
        insert into sys_logininfor (user_name, status, ipaddr, login_location, browser, os, msg, login_time)
        values (#{userName}, #{status}, #{ipaddr}, #{loginLocation}, #{browser}, #{os}, #{msg}, sysdate())
    </insert>
    <select id="selectLogininforList" parameterType="SysLogininfor" resultMap="SysLogininforResult">
        select info_id, user_name, ipaddr, login_location, browser, os, status, msg, login_time from sys_logininfor
        <where>
            <if test="ipaddr != null and ipaddr != ''">
                AND ipaddr like concat('%', #{ipaddr}, '%')
            </if>
            <if test="status != null and status != ''">
                AND status = #{status}
            </if>
            <if test="userName != null and userName != ''">
                AND user_name like concat('%', #{userName}, '%')
            </if>
            <if test="params.beginTime != null and params.beginTime != ''"><!-- 开始时间检索 -->
                and date_format(login_time,'%y%m%d') &gt;= date_format(#{params.beginTime},'%y%m%d')
            </if>
            <if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 -->
                and date_format(login_time,'%y%m%d') &lt;= date_format(#{params.endTime},'%y%m%d')
            </if>
        </where>
        order by info_id desc
    </select>
    <delete id="deleteLogininforByIds" parameterType="Long">
        delete from sys_logininfor where info_id in
        <foreach collection="array" item="infoId" open="(" separator="," close=")">
            #{infoId}
        </foreach>
    </delete>
    <update id="cleanLogininfor">
        truncate table sys_logininfor
    </update>
</mapper> 
ruoyi-system/src/main/resources/mapper/system/SysNoticeMapper.xml
@@ -17,84 +17,4 @@
        <result property="remark" column="remark"/>
    </resultMap>
    <sql id="selectNoticeVo">
        select notice_id,
               notice_title,
               notice_type,
               cast(notice_content as char) as notice_content,
               status,
               create_by,
               create_time,
               update_by,
               update_time,
               remark
        from sys_notice
    </sql>
    <select id="selectNoticeById" parameterType="Long" resultMap="SysNoticeResult">
        <include refid="selectNoticeVo"/>
        where notice_id = #{noticeId}
    </select>
    <select id="selectNoticeList" parameterType="SysNotice" resultMap="SysNoticeResult">
        <include refid="selectNoticeVo"/>
        <where>
            <if test="noticeTitle != null and noticeTitle != ''">
                AND notice_title like concat('%', #{noticeTitle}, '%')
            </if>
            <if test="noticeType != null and noticeType != ''">
                AND notice_type = #{noticeType}
            </if>
            <if test="createBy != null and createBy != ''">
                AND create_by like concat('%', #{createBy}, '%')
            </if>
        </where>
    </select>
    <insert id="insertNotice" parameterType="SysNotice">
        insert into sys_notice (
        <if test="noticeTitle != null and noticeTitle != '' ">notice_title,</if>
        <if test="noticeType != null and noticeType != '' ">notice_type,</if>
        <if test="noticeContent != null and noticeContent != '' ">notice_content,</if>
        <if test="status != null and status != '' ">status,</if>
        <if test="remark != null and remark != ''">remark,</if>
        <if test="createBy != null and createBy != ''">create_by,</if>
        create_time
        )values(
        <if test="noticeTitle != null and noticeTitle != ''">#{noticeTitle},</if>
        <if test="noticeType != null and noticeType != ''">#{noticeType},</if>
        <if test="noticeContent != null and noticeContent != ''">#{noticeContent},</if>
        <if test="status != null and status != ''">#{status},</if>
        <if test="remark != null and remark != ''">#{remark},</if>
        <if test="createBy != null and createBy != ''">#{createBy},</if>
        sysdate()
        )
    </insert>
    <update id="updateNotice" parameterType="SysNotice">
        update sys_notice
        <set>
            <if test="noticeTitle != null and noticeTitle != ''">notice_title = #{noticeTitle},</if>
            <if test="noticeType != null and noticeType != ''">notice_type = #{noticeType},</if>
            <if test="noticeContent != null">notice_content = #{noticeContent},</if>
            <if test="status != null and status != ''">status = #{status},</if>
            <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
            update_time = sysdate()
        </set>
        where notice_id = #{noticeId}
    </update>
    <delete id="deleteNoticeById" parameterType="Long">
        delete
        from sys_notice
        where notice_id = #{noticeId}
    </delete>
    <delete id="deleteNoticeByIds" parameterType="Long">
        delete from sys_notice where notice_id in
        <foreach item="noticeId" collection="array" open="(" separator="," close=")">
            #{noticeId}
        </foreach>
    </delete>
</mapper>
ruoyi-system/src/main/resources/mapper/system/SysOperLogMapper.xml
@@ -23,79 +23,4 @@
        <result property="operTime" column="oper_time"/>
    </resultMap>
    <sql id="selectOperLogVo">
        select oper_id,
               title,
               business_type,
               method,
               request_method,
               operator_type,
               oper_name,
               dept_name,
               oper_url,
               oper_ip,
               oper_location,
               oper_param,
               json_result,
               status,
               error_msg,
               oper_time
        from sys_oper_log
    </sql>
    <insert id="insertOperlog" parameterType="SysOperLog">
        insert into sys_oper_log(title, business_type, method, request_method, operator_type, oper_name, dept_name,
                                 oper_url, oper_ip, oper_location, oper_param, json_result, status, error_msg,
                                 oper_time)
        values (#{title}, #{businessType}, #{method}, #{requestMethod}, #{operatorType}, #{operName}, #{deptName},
                #{operUrl}, #{operIp}, #{operLocation}, #{operParam}, #{jsonResult}, #{status}, #{errorMsg}, sysdate())
    </insert>
    <select id="selectOperLogList" parameterType="SysOperLog" resultMap="SysOperLogResult">
        <include refid="selectOperLogVo"/>
        <where>
            <if test="title != null and title != ''">
                AND title like concat('%', #{title}, '%')
            </if>
            <if test="businessType != null and businessType != ''">
                AND business_type = #{businessType}
            </if>
            <if test="businessTypes != null and businessTypes.length > 0">
                AND business_type in
                <foreach collection="businessTypes" item="businessType" open="(" separator="," close=")">
                    #{businessType}
                </foreach>
            </if>
            <if test="status != null">
                AND status = #{status}
            </if>
            <if test="operName != null and operName != ''">
                AND oper_name like concat('%', #{operName}, '%')
            </if>
            <if test="params.beginTime != null and params.beginTime != ''"><!-- 开始时间检索 -->
                and date_format(oper_time,'%y%m%d') &gt;= date_format(#{params.beginTime},'%y%m%d')
            </if>
            <if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 -->
                and date_format(oper_time,'%y%m%d') &lt;= date_format(#{params.endTime},'%y%m%d')
            </if>
        </where>
        order by oper_id desc
    </select>
    <delete id="deleteOperLogByIds" parameterType="Long">
        delete from sys_oper_log where oper_id in
        <foreach collection="array" item="operId" open="(" separator="," close=")">
            #{operId}
        </foreach>
    </delete>
    <select id="selectOperLogById" parameterType="Long" resultMap="SysOperLogResult">
        <include refid="selectOperLogVo"/>
        where oper_id = #{operId}
    </select>
    <update id="cleanOperLog">
        truncate table sys_oper_log
    </update>
</mapper> 
ruoyi-system/src/main/resources/mapper/system/SysPostMapper.xml
@@ -29,30 +29,6 @@
        from sys_post
    </sql>
    <select id="selectPostList" parameterType="SysPost" resultMap="SysPostResult">
        <include refid="selectPostVo"/>
        <where>
            <if test="postCode != null and postCode != ''">
                AND post_code like concat('%', #{postCode}, '%')
            </if>
            <if test="status != null and status != ''">
                AND status = #{status}
            </if>
            <if test="postName != null and postName != ''">
                AND post_name like concat('%', #{postName}, '%')
            </if>
        </where>
    </select>
    <select id="selectPostAll" resultMap="SysPostResult">
        <include refid="selectPostVo"/>
    </select>
    <select id="selectPostById" parameterType="Long" resultMap="SysPostResult">
        <include refid="selectPostVo"/>
        where post_id = #{postId}
    </select>
    <select id="selectPostListByUserId" parameterType="Long" resultType="Integer">
        select p.post_id
        from sys_post p
@@ -68,64 +44,5 @@
                 left join sys_user u on u.user_id = up.user_id
        where u.user_name = #{userName}
    </select>
    <select id="checkPostNameUnique" parameterType="String" resultMap="SysPostResult">
        <include refid="selectPostVo"/>
        where post_name=#{postName} limit 1
    </select>
    <select id="checkPostCodeUnique" parameterType="String" resultMap="SysPostResult">
        <include refid="selectPostVo"/>
        where post_code=#{postCode} limit 1
    </select>
    <update id="updatePost" parameterType="SysPost">
        update sys_post
        <set>
            <if test="postCode != null and postCode != ''">post_code = #{postCode},</if>
            <if test="postName != null and postName != ''">post_name = #{postName},</if>
            <if test="postSort != null and postSort != ''">post_sort = #{postSort},</if>
            <if test="status != null and status != ''">status = #{status},</if>
            <if test="remark != null">remark = #{remark},</if>
            <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
            update_time = sysdate()
        </set>
        where post_id = #{postId}
    </update>
    <insert id="insertPost" parameterType="SysPost" useGeneratedKeys="true" keyProperty="postId">
        insert into sys_post(
        <if test="postId != null and postId != 0">post_id,</if>
        <if test="postCode != null and postCode != ''">post_code,</if>
        <if test="postName != null and postName != ''">post_name,</if>
        <if test="postSort != null and postSort != ''">post_sort,</if>
        <if test="status != null and status != ''">status,</if>
        <if test="remark != null and remark != ''">remark,</if>
        <if test="createBy != null and createBy != ''">create_by,</if>
        create_time
        )values(
        <if test="postId != null and postId != 0">#{postId},</if>
        <if test="postCode != null and postCode != ''">#{postCode},</if>
        <if test="postName != null and postName != ''">#{postName},</if>
        <if test="postSort != null and postSort != ''">#{postSort},</if>
        <if test="status != null and status != ''">#{status},</if>
        <if test="remark != null and remark != ''">#{remark},</if>
        <if test="createBy != null and createBy != ''">#{createBy},</if>
        sysdate()
        )
    </insert>
    <delete id="deletePostById" parameterType="Long">
        delete
        from sys_post
        where post_id = #{postId}
    </delete>
    <delete id="deletePostByIds" parameterType="Long">
        delete from sys_post where post_id in
        <foreach collection="array" item="postId" open="(" separator="," close=")">
            #{postId}
        </foreach>
    </delete>
</mapper> 
ruoyi-system/src/main/resources/mapper/system/SysUserPostMapper.xml
@@ -15,12 +15,6 @@
        where user_id = #{userId}
    </delete>
    <select id="countUserPostById" resultType="Integer">
        select count(1)
        from sys_user_post
        where post_id = #{postId}
    </select>
    <delete id="deleteUserPost" parameterType="Long">
        delete from sys_user_post where user_id in
        <foreach collection="array" item="userId" open="(" separator="," close=")">