🐛 修复了一个 BUG,shardingjdbc越界问题

This commit is contained in:
冷冷 2018-05-25 00:38:41 +08:00
parent 75c508f52a
commit 2600e457e4
2 changed files with 6 additions and 4 deletions

View File

@ -1,6 +1,7 @@
package com.github.pig.admin.common.config; package com.github.pig.admin.common.config;
import com.baomidou.mybatisplus.plugins.PaginationInterceptor; import com.baomidou.mybatisplus.plugins.PaginationInterceptor;
import com.github.pig.common.bean.interceptor.DataScopeInterceptor;
import org.mybatis.spring.annotation.MapperScan; import org.mybatis.spring.annotation.MapperScan;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
@ -27,8 +28,8 @@ public class MybatisPlusConfig {
* *
* @return DataScopeInterceptor * @return DataScopeInterceptor
*/ */
// @Bean @Bean
// public DataScopeInterceptor dataScopeInterceptor() { public DataScopeInterceptor dataScopeInterceptor() {
// return new DataScopeInterceptor(); return new DataScopeInterceptor();
// } }
} }

View File

@ -135,6 +135,7 @@
<if test="username != null and username != ''"> <if test="username != null and username != ''">
and `user`.username LIKE CONCAT('%',#{username},'%') and `user`.username LIKE CONCAT('%',#{username},'%')
</if> </if>
ORDER BY `user`.create_time DESC
</select> </select>
</mapper> </mapper>