diff --git "a/d:\\springbootv2-log/springbootv2.log" "b/d:\\springbootv2-log/springbootv2.log" new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/pom.xml b/pom.xml index ad9bc5648101974e4d620e1698f6f84493cef00f..fb14723ba0ff6c1e18b79b401bae826a3d00584c 100644 --- a/pom.xml +++ b/pom.xml @@ -12,8 +12,8 @@ org.springframework.boot spring-boot-starter-parent - 2.0.0.RELEASE - + 2.2.6.RELEASE + @@ -22,6 +22,8 @@ 1.8 1.3.3 2.5 + 3.3.1 + 3.3.1 @@ -31,12 +33,6 @@ org.springframework.boot spring-boot-starter-web - - - org.mybatis.spring.boot - mybatis-spring-boot-starter - 1.3.2 - org.springframework.boot @@ -60,33 +56,28 @@ com.google.code.gson gson - - - com.github.pagehelper - pagehelper-spring-boot-starter - 1.2.5 - - - mysql - mysql-connector-java - 5.1.40 - + + + + + - + + mysql + mysql-connector-java + 8.0.19 - --> + com.alibaba druid-spring-boot-starter - 1.1.10 + 1.1.22 + org.apache.shiro @@ -216,46 +207,37 @@ qiniu-java-sdk [7.2.0, 7.2.99] - + + + + com.baomidou + mybatis-plus-boot-starter + ${mybatisplus.version} + + + com.baomidou + mybatis-plus-generator + ${mybatisplus-generator.version} + + + org.springframework.boot + spring-boot-starter-freemarker + runtime + + + + org.projectlombok + lombok + true + - + springboot_v2 - - - org.apache.maven.plugins - maven-surefire-plugin - - - true - - - - - org.mybatis.generator - mybatis-generator-maven-plugin - 1.3.7 - - - false - - false - - src/main/resources/mybatis-generator.xml - - - - mysql - mysql-connector-java - ${mysql.version} - - - - org.springframework.boot spring-boot-maven-plugin diff --git a/src/main/java/com/fc/SpringbootStart.java b/src/main/java/com/fc/SpringbootStart.java index 491665ad5da15d11fe555c9f3cb4ceda7033890b..b204dbb85a3eb45e5f266106c7136d60c5ae27a8 100644 --- a/src/main/java/com/fc/SpringbootStart.java +++ b/src/main/java/com/fc/SpringbootStart.java @@ -1,5 +1,6 @@ package com.fc; +import org.mybatis.spring.annotation.MapperScan; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; diff --git a/src/main/java/com/fc/test/MybatisPlusCodeGenerator.java b/src/main/java/com/fc/test/MybatisPlusCodeGenerator.java new file mode 100644 index 0000000000000000000000000000000000000000..16eda1fdc63f3558b4c1ad21f03fcb89be390aa2 --- /dev/null +++ b/src/main/java/com/fc/test/MybatisPlusCodeGenerator.java @@ -0,0 +1,187 @@ +package com.fc.test; + +import com.baomidou.mybatisplus.core.exceptions.MybatisPlusException; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.baomidou.mybatisplus.core.toolkit.StringUtils; +import com.baomidou.mybatisplus.extension.service.IService; +import com.baomidou.mybatisplus.generator.AutoGenerator; +import com.baomidou.mybatisplus.generator.InjectionConfig; +import com.baomidou.mybatisplus.generator.config.*; +import com.baomidou.mybatisplus.generator.config.po.TableInfo; +import com.baomidou.mybatisplus.generator.config.rules.NamingStrategy; +import com.baomidou.mybatisplus.generator.engine.FreemarkerTemplateEngine; + +import java.io.File; +import java.util.ArrayList; +import java.util.List; +import java.util.Scanner; + +/** + * Create By pencilso on 2019/5/16 + */ +public class MybatisPlusCodeGenerator { + private static final String OUT_PUT_DIR_CODE = "src/main/java"; + private static final String OUT_PUT_DIR_MAPPER = "src/main/resources/mapper/"; + + private static final String AUTHOR = "pencilso"; + + private static final String JDBC_URL = "jdbc:mysql://localhost:3306/springbootv2?useUnicode=true&useSSL=false&characterEncoding=utf8"; + + private static final String JDBC_USERNAME = "root"; + + private static final String JDBC_PASSWORD = "pencilso"; + + + private static final String TABLE_PREFIX = "t"; + + + private static final String DAO_SUPER_PACKAGE = "com.fc.test.dao"; + + /** + *

+ * 读取控制台内容 + *

+ */ + public static String scanner(String tip) { + Scanner scanner = new Scanner(System.in); + StringBuilder help = new StringBuilder(); + help.append("请输入" + tip + ":"); + System.out.println(help.toString()); + if (scanner.hasNext()) { + String ipt = scanner.next(); + if (!StringUtils.isBlank(ipt)) { + return ipt; + } + } + throw new MybatisPlusException("请输入正确的" + tip + "!"); + } + + public static void main(String[] args) { + // 代码生成器 + AutoGenerator mpg = new AutoGenerator(); + + // 全局配置 + GlobalConfig gc = new GlobalConfig(); +// String projectPath = System.getProperty("public_api.dir"); +// gc.setOutputDir("src/main/java"); + gc.setOutputDir(OUT_PUT_DIR_CODE); + gc.setAuthor(AUTHOR); + gc.setOpen(false); + + gc.setEntityName("%sModel"); + gc.setServiceName("%sService"); + gc.setServiceImplName("%sServiceImpl"); + + // swagger 注解 + gc.setSwagger2(true); + mpg.setGlobalConfig(gc); + + // 数据源配置 + DataSourceConfig dsc = new DataSourceConfig(); + dsc.setUrl(JDBC_URL); +// dsc.setSchemaName("inlan_"); + dsc.setDriverName("com.mysql.cj.jdbc.Driver"); + dsc.setUsername(JDBC_USERNAME); + dsc.setPassword(JDBC_PASSWORD); + mpg.setDataSource(dsc); + + // 包配置 + PackageConfig pc = new PackageConfig(); +// pc.setModuleName(scanner("模块名")); +// pc.setModuleName(""); + pc.setEntity("model"); + pc.setServiceImpl("service.impl"); + pc.setParent(DAO_SUPER_PACKAGE); + mpg.setPackageInfo(pc); + + // 自定义配置 + InjectionConfig cfg = new InjectionConfig() { + @Override + public void initMap() { + // to do nothing + } + }; + + // 如果模板引擎是 freemarker + String templatePath = "/templates/mapper.xml.ftl"; + // 如果模板引擎是 velocity + // String templatePath = "/templates/mapper.xml.vm"; + + // 自定义输出配置 + List focList = new ArrayList<>(); + // 自定义配置会被优先输出 + focList.add(new FileOutConfig(templatePath) { + @Override + public String outputFile(TableInfo tableInfo) { + // 自定义输出文件名 , 如果你 Entity 设置了前后缀、此处注意 xml 的名称会跟着发生变化!! + return OUT_PUT_DIR_MAPPER + tableInfo.getEntityName() + "Mapper" + StringPool.DOT_XML; + } + }); + /* + cfg.setFileCreate(new IFileCreate() { + @Override + public boolean isCreate(ConfigBuilder configBuilder, FileType fileType, String filePath) { + // 判断自定义文件夹是否需要创建 + checkDir("调用默认方法创建的目录"); + return false; + } + }); + */ + cfg.setFileOutConfigList(focList); + mpg.setCfg(cfg); + + // 配置模板 + TemplateConfig templateConfig = new TemplateConfig(); + // 配置自定义输出模板 + //指定自定义模板路径,注意不要带上.ftl/.vm, 会根据使用的模板引擎自动识别 + // templateConfig.setEntity("templates/entity2.java"); + // templateConfig.setService(); + // templateConfig.setController(); + + templateConfig.setXml(null); + mpg.setTemplate(templateConfig); + + // 策略配置 + StrategyConfig strategy = new StrategyConfig(); + strategy.setNaming(NamingStrategy.underline_to_camel); + strategy.setColumnNaming(NamingStrategy.underline_to_camel); +// strategy.setSuperEntityClass(BaseModel.class.getName()); + strategy.setEntityLombokModel(true); + strategy.setRestControllerStyle(false); + strategy.setSuperControllerClass("com.baomidou.ant.common.BaseController"); + strategy.setSuperServiceClass(IService.class.getName()); + strategy.setInclude(scanner("表名,多个英文逗号分割").split(",")); +// strategy.setSuperEntityColumns("id", "mid", "if_del", "version", "create_date", "update_date"); + strategy.setControllerMappingHyphenStyle(true); + strategy.setTablePrefix(TABLE_PREFIX); + mpg.setStrategy(strategy); + mpg.setTemplateEngine(new FreemarkerTemplateEngine()); + mpg.execute(); + + if (!StringUtils.isBlank(DAO_SUPER_PACKAGE)) { + StringBuilder stringBuilder = new StringBuilder(gc.getOutputDir()); + String[] split = DAO_SUPER_PACKAGE.split("\\."); + for (String s : split) { + stringBuilder.append("/").append(s); + } + stringBuilder.append("/controller"); + File file = new File(stringBuilder.toString()); + deleteDir(file); + } + } + + private static boolean deleteDir(File dir) { + if (dir.isDirectory()) { + String[] children = dir.list(); + //递归删除目录中的子目录下 + for (int i = 0; i < children.length; i++) { + boolean success = deleteDir(new File(dir, children[i])); + if (!success) { + return false; + } + } + } + // 目录此时为空,可以删除 + return dir.delete(); + } +} diff --git a/src/main/java/com/fc/test/common/base/BaseController.java b/src/main/java/com/fc/test/common/base/BaseController.java index 1ad86c73eacfc1fb4355bd8c967d8c137afb06ac..184389aa1ccf3a0e9ae8858f7d28c9e7ccb0a1d9 100644 --- a/src/main/java/com/fc/test/common/base/BaseController.java +++ b/src/main/java/com/fc/test/common/base/BaseController.java @@ -1,12 +1,11 @@ package com.fc.test.common.base; -import java.text.SimpleDateFormat; -import java.util.Date; - import com.fc.test.common.domain.AjaxResult; +import com.fc.test.dao.service.*; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.*; +import com.fc.test.service.QiNiuCloudService; import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.propertyeditors.CustomDateEditor; import org.springframework.stereotype.Controller; @@ -14,56 +13,72 @@ import org.springframework.ui.ModelMap; import org.springframework.web.bind.WebDataBinder; import org.springframework.web.bind.annotation.InitBinder; +import javax.validation.constraints.NotNull; +import java.text.SimpleDateFormat; +import java.util.Date; + /** * web层通用数据处理 -* @ClassName: BaseController -* @author fuce -* @date 2018年8月18日 -* + * + * @author fuce + * @ClassName: BaseController + * @date 2018年8月18日 */ @Controller -public class BaseController -{ - //系统用户 - @Autowired - public SysUserService sysUserService; - - //系统角色 - @Autowired - public SysRoleService sysRoleService; - - //权限 - @Autowired - public SysPermissionService sysPermissionService; - - //文件上传 - @Autowired - public SysFileService sysFileService; - - //文件存储 - @Autowired - public SysDatasService sysDatasService; - - //文件存储管理表 - @Autowired - public SysFileDatasService sysFileDatasService; - - //日志操作 - @Autowired - public SysOperLogService sysOperLogService; - //公告 - @Autowired - public SysNoticeService sysNoticeService; - - /*文件上传云库*/ +public class BaseController { + /** + * 系统用户 + */ + @Autowired + protected SysUserService sysUserService; + /** + * 系统角色 + */ + @Autowired + protected SysRoleService sysRoleService; + /** + * 权限 + */ + @Autowired + protected SysPermissionService sysPermissionService; + /** + * 文件上传 + */ + @Autowired + protected SysFileService sysFileService; + /** + * 文件存储 + */ + @Autowired + protected SysDatasService sysDatasService; + + /** + * 日志操作 + */ + @Autowired + protected SysOperLogService sysOperLogService; + /** + * 公告 + */ + @Autowired + protected SysNoticeService sysNoticeService; + /** + * 文件上传云库 + */ @Autowired - public QiNiuCloudService qiNiuCloudService; + protected QiNiuCloudService qiNiuCloudService; + + +// //文件存储管理表 +// @Autowired +// public SysFileDatasService sysFileDatasService; + + /** * 将前台传递过来的日期格式的字符串,自动转化为Date类型 */ @InitBinder - public void initBinder(WebDataBinder binder) - { + public void initBinder(WebDataBinder binder) { SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); dateFormat.setLenient(false); binder.registerCustomEditor(Date.class, new CustomDateEditor(dateFormat, true)); @@ -72,89 +87,89 @@ public class BaseController /** * 响应返回结果 - * + * * @param rows 影响行数 * @return 操作结果 */ - protected AjaxResult toAjax(int rows) - { + protected AjaxResult toAjax(int rows) { return rows > 0 ? success() : error(); } + /** + * 响应返回结果 + * + * @param rows 影响行数 + * @return 操作结果 + */ + protected AjaxResult toAjax(boolean rows) { + return rows ? success() : error(); + } /** * 返回成功 */ - public AjaxResult success() - { + public AjaxResult success() { return AjaxResult.success(); } /** * 返回失败消息 */ - public AjaxResult error() - { + public AjaxResult error() { return AjaxResult.error(); } /** * 返回成功消息 */ - public AjaxResult success(String message) - { + public AjaxResult success(String message) { return AjaxResult.success(message); } - + /** * 返回失败消息 */ - public AjaxResult error(String message) - { + public AjaxResult error(String message) { return AjaxResult.error(message); } /** * 返回错误码消息 */ - public AjaxResult error(int code, String message) - { + public AjaxResult error(int code, String message) { return AjaxResult.error(code, message); } - + /** * 返回object数据 */ - public AjaxResult retobject(int code, Object data) - { + public AjaxResult retobject(int code, Object data) { return AjaxResult.successData(code, data); } /** * 页面跳转 */ - public String redirect(String url) - { + public String redirect(String url) { return StringUtils.format("redirect:{}", url); } - - + + /** * 设置标题通用方法 - * @param model - */ - public void setTitle(ModelMap map,TitleVo titleVo){ - //标题 - map.put("title",titleVo.getTitle()); - map.put("parenttitle",titleVo.getParenttitle()); - //是否打开欢迎语 - map.put("isMsg",titleVo.isMsg()); - //欢迎语 - map.put("msgHTML",titleVo.getMsgHtml()); - //小控件 - map.put("isControl",titleVo.isControl()); - map.put("isribbon", titleVo.isIsribbon()); + */ + public void setTitle(ModelMap map, TitleVo titleVo) { + //标题 + map.put("title", titleVo.getTitle()); + map.put("parenttitle", titleVo.getParenttitle()); + //是否打开欢迎语 + map.put("isMsg", titleVo.isMsg()); + //欢迎语 + map.put("msgHTML", titleVo.getMsgHtml()); + //小控件 + map.put("isControl", titleVo.isControl()); + map.put("isribbon", titleVo.isIsribbon()); } - + } diff --git a/src/main/java/com/fc/test/common/base/BaseIService.java b/src/main/java/com/fc/test/common/base/BaseIService.java new file mode 100644 index 0000000000000000000000000000000000000000..a30e25776bc4f51d3f7b50be8eb8ba67a1351e93 --- /dev/null +++ b/src/main/java/com/fc/test/common/base/BaseIService.java @@ -0,0 +1,72 @@ +package com.fc.test.common.base; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.baomidou.mybatisplus.extension.service.IService; +import com.fc.test.common.interceptor.ListTableparInerceptor; +import com.fc.test.model.custom.Tablepar; +import com.fc.test.util.StringUtils; + +import java.util.List; + +/** + * @author pencilso + * @date 2020/4/22 2:57 下午 + */ +public interface BaseIService extends IService { + + + default PageInfo iPageToPageInfo(Page page) { + return new PageInfo() + .setList(page.getRecords()) + .setPageNum((int) page.getCurrent()) + .setPages((int) page.getPages()) + .setPageSize((int) page.getSize()) + .setTotal(page.getTotal()) + .setSize(page.getRecords().size()); + } + + default PageInfo listTablepar(Tablepar tablepar, String column, String searchText) { + return listTablepar(tablepar, column, searchText, null); + } + + /** + * 默认分页 + * + * @param tablepar + * @param column + * @param searchText + * @param + * @return + */ + default PageInfo listTablepar(Tablepar tablepar, String column, String searchText, ListTableparInerceptor listTableparInerceptor) { + QueryWrapper queryWrapper = new QueryWrapper<>(); + queryWrapper.orderByAsc("id"); + if (StringUtils.isNotBlank(searchText)) { + queryWrapper.like(column, searchText); + } + + if (listTableparInerceptor != null) listTableparInerceptor.call(queryWrapper); + + if (StringUtils.isNotBlank(tablepar.getOrderByColumn())) { + String underColumn = StringUtils.toUnderScoreCase(tablepar.getOrderByColumn()); + queryWrapper.orderBy(true, "asc".equals(tablepar.getIsAsc()), underColumn); + } + Page page = page(new Page<>(tablepar.getPageNum(), tablepar.getPageSize()), queryWrapper); + return iPageToPageInfo(page); + } + + /** + * 检查名字 + * + * @param column + * @param name + * @return + */ + default int checkNameUnique(String column, String name) { + QueryWrapper queryWrapper = new QueryWrapper<>(); + queryWrapper.eq(column, name); + List list = list(queryWrapper); + return list.size(); + } +} diff --git a/src/main/java/com/fc/test/common/base/PageInfo.java b/src/main/java/com/fc/test/common/base/PageInfo.java index b6085d8f065046095de5a64af293d2d7ae5ed922..546a20c3cef80732b41726108dc57f789a0a404a 100644 --- a/src/main/java/com/fc/test/common/base/PageInfo.java +++ b/src/main/java/com/fc/test/common/base/PageInfo.java @@ -1,268 +1,44 @@ package com.fc.test.common.base; +import lombok.Data; +import lombok.NoArgsConstructor; +import lombok.experimental.Accessors; + import java.io.Serializable; import java.util.List; -import com.github.pagehelper.Page; - -@SuppressWarnings({"rawtypes", "unchecked"}) +@Accessors(chain = true) +@Data +@NoArgsConstructor public class PageInfo implements Serializable { - private static final long serialVersionUID = 1L; - //当前页 - private int pageNum; - //每页的数量 - private int pageSize; - //当前页的数量 - private int size; - //由于startRow和endRow不常用,这里说个具体的用法 - //可以在页面中"显示startRow到endRow 共size条数据" - - //当前页面第一个元素在数据库中的行号 - private int startRow; - //当前页面最后一个元素在数据库中的行号 - private int endRow; - //总记录数 - private long total; - //总页数 - private int pages; - //结果集 - private List list; - //第一页 - private int firstPage; - //前一页 - private int prePage; - //下一页 - private int nextPage; - //最后一页 - private int lastPage; - - //是否为第一页 - private boolean isFirstPage = false; - //是否为最后一页 - private boolean isLastPage = false; - //是否有前一页 - private boolean hasPreviousPage = false; - //是否有下一页 - private boolean hasNextPage = false; - //导航页码数 - private int navigatePages; - //所有导航页号 - private int[] navigatepageNums; - - /** - * 包装Page对象 - * - * @param list - */ public PageInfo(List list) { - this(list, 8); + this.list = list; } + private static final long serialVersionUID = 1L; /** - * 包装Page对象 - * - * @param list page结果 - * @param navigatePages 页码数量 + * 当前页 */ - public PageInfo(List list, int navigatePages) { - if (list instanceof Page) { - Page page = (Page) list; - this.pageNum = page.getPageNum(); - this.pageSize = page.getPageSize(); - - this.total = page.getTotal(); - this.pages = page.getPages(); - this.list = page; - this.size = page.size(); - //由于结果是>startRow的,所以实际的需要+1 - if (this.size == 0) { - this.startRow = 0; - this.endRow = 0; - } else { - this.startRow = page.getStartRow() + 1; - //计算实际的endRow(最后一页的时候特殊) - this.endRow = this.startRow - 1 + this.size; - } - this.navigatePages = navigatePages; - //计算导航页 - calcNavigatepageNums(); - //计算前后页,第一页,最后一页 - calcPage(); - //判断页面边界 - judgePageBoudary(); - } - } - + private int pageNum; /** - * 计算导航页 + * 每页的数量 */ - private void calcNavigatepageNums() { - //当总页数小于或等于导航页码数时 - if (pages <= navigatePages) { - navigatepageNums = new int[pages]; - for (int i = 0; i < pages; i++) { - navigatepageNums[i] = i + 1; - } - } else { //当总页数大于导航页码数时 - navigatepageNums = new int[navigatePages]; - int startNum = pageNum - navigatePages / 2; - int endNum = pageNum + navigatePages / 2; - - if (startNum < 1) { - startNum = 1; - //(最前navigatePages页 - for (int i = 0; i < navigatePages; i++) { - navigatepageNums[i] = startNum++; - } - } else if (endNum > pages) { - endNum = pages; - //最后navigatePages页 - for (int i = navigatePages - 1; i >= 0; i--) { - navigatepageNums[i] = endNum--; - } - } else { - //所有中间页 - for (int i = 0; i < navigatePages; i++) { - navigatepageNums[i] = startNum++; - } - } - } - } - + private int pageSize; /** - * 计算前后页,第一页,最后一页 + * 当前页的数量 */ - private void calcPage() { - if (navigatepageNums != null && navigatepageNums.length > 0) { - firstPage = navigatepageNums[0]; - lastPage = navigatepageNums[navigatepageNums.length - 1]; - if (pageNum > 1) { - prePage = pageNum - 1; - } - if (pageNum < pages) { - nextPage = pageNum + 1; - } - } - } - + private int size; /** - * 判定页面边界 + * 总记录数 */ - private void judgePageBoudary() { - isFirstPage = pageNum == 1; - isLastPage = pageNum == pages; - hasPreviousPage = pageNum > 1; - hasNextPage = pageNum < pages; - } - - public void setPageNum(int pageNum) { - this.pageNum = pageNum; - } - - public int getPageNum() { - return pageNum; - } - - public int getPageSize() { - return pageSize; - } - - public int getSize() { - return size; - } - - public int getStartRow() { - return startRow; - } - - public int getEndRow() { - return endRow; - } - - public long getTotal() { - return total; - } - - public int getPages() { - return pages; - } - - public List getList() { - return list; - } - - public int getFirstPage() { - return firstPage; - } - - public int getPrePage() { - return prePage; - } - - public int getNextPage() { - return nextPage; - } - - public int getLastPage() { - return lastPage; - } - - public boolean isIsFirstPage() { - return isFirstPage; - } - - public boolean isIsLastPage() { - return isLastPage; - } - - public boolean isHasPreviousPage() { - return hasPreviousPage; - } - - public boolean isHasNextPage() { - return hasNextPage; - } - - public int getNavigatePages() { - return navigatePages; - } - - public int[] getNavigatepageNums() { - return navigatepageNums; - } - - @Override - public String toString() { - final StringBuffer sb = new StringBuffer("PageInfo{"); - sb.append("pageNum=").append(pageNum); - sb.append(", pageSize=").append(pageSize); - sb.append(", size=").append(size); - sb.append(", startRow=").append(startRow); - sb.append(", endRow=").append(endRow); - sb.append(", total=").append(total); - sb.append(", pages=").append(pages); - sb.append(", list=").append(list); - sb.append(", firstPage=").append(firstPage); - sb.append(", prePage=").append(prePage); - sb.append(", nextPage=").append(nextPage); - sb.append(", lastPage=").append(lastPage); - sb.append(", isFirstPage=").append(isFirstPage); - sb.append(", isLastPage=").append(isLastPage); - sb.append(", hasPreviousPage=").append(hasPreviousPage); - sb.append(", hasNextPage=").append(hasNextPage); - sb.append(", navigatePages=").append(navigatePages); - sb.append(", navigatepageNums="); - if (navigatepageNums == null){ - sb.append("null"); - }else { - sb.append('['); - for (int i = 0; i < navigatepageNums.length; ++i){ - sb.append(i == 0 ? "" : ", ").append(navigatepageNums[i]); - } - sb.append(']'); - } - sb.append('}'); - return sb.toString(); - } + private long total; + /** + * 总页数 + */ + private int pages; + /** + * 结果集 + */ + private List list; } \ No newline at end of file diff --git a/src/main/java/com/fc/test/common/conf/MybatisConfig.java b/src/main/java/com/fc/test/common/conf/MybatisConfig.java index a26d616c461284721f1a6cfa33ce53e7b5b81b34..bc6a0cd67ad258ceee7aabc3ec362bc24bc7dfbb 100644 --- a/src/main/java/com/fc/test/common/conf/MybatisConfig.java +++ b/src/main/java/com/fc/test/common/conf/MybatisConfig.java @@ -3,6 +3,8 @@ package com.fc.test.common.conf; import java.util.HashMap; import java.util.Map; import javax.sql.DataSource; + +import com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean; import org.apache.ibatis.session.SqlSessionFactory; import org.mybatis.spring.SqlSessionFactoryBean; import org.mybatis.spring.annotation.MapperScan; @@ -27,7 +29,7 @@ import com.fc.test.common.dataSources.DynamicDataSource; * @date 2019-12-06 21:11 */ @Configuration -@MapperScan(basePackages = "com.fc.test.mapper") +@MapperScan(basePackages = {"com.fc.test.mapper","com.fc.test.dao.mapper"}) public class MybatisConfig { @Bean @@ -45,27 +47,29 @@ public class MybatisConfig { return DruidDataSourceBuilder.create().build(); } + @Bean(name = "dynamicDataSource") @Primary - public DynamicDataSource dataSource(DataSource masterDataSource, DataSource slaveDataSource) - { + public DynamicDataSource dataSource(DataSource masterDataSource, DataSource slaveDataSource) { Map targetDataSources = new HashMap<>(); targetDataSources.put(DataSourceType.MASTER.name(), masterDataSource); - targetDataSources.put(DataSourceType.SLAVE.name(),slaveDataSource); + targetDataSources.put(DataSourceType.SLAVE.name(), slaveDataSource); return new DynamicDataSource(masterDataSource(), targetDataSources); } @Bean public SqlSessionFactory sqlSessionFactory(DynamicDataSource dynamicDataSource) throws Exception { - SqlSessionFactoryBean factoryBean = new SqlSessionFactoryBean(); - factoryBean.setDataSource(dynamicDataSource); + MybatisSqlSessionFactoryBean mybatisSqlSessionFactoryBean = new MybatisSqlSessionFactoryBean();; + mybatisSqlSessionFactoryBean.setDataSource(dynamicDataSource); + + mybatisSqlSessionFactoryBean.setDataSource(dynamicDataSource); // factoryBean.setTypeAliasesPackage(); // 设置mapper.xml的位置路径 - Resource[] resources = new PathMatchingResourcePatternResolver().getResources("classpath*:mybatis/*/*.xml"); - factoryBean.setMapperLocations(resources); - return factoryBean.getObject(); + Resource[] resources = new PathMatchingResourcePatternResolver().getResources("classpath*:/mapper/*.xml"); + mybatisSqlSessionFactoryBean.setMapperLocations(resources); + return mybatisSqlSessionFactoryBean.getObject(); } - + /** * 配置@Transactional注解事务 * @param dynamicDataSource diff --git a/src/main/java/com/fc/test/common/conf/MybatisPlusConfig.java b/src/main/java/com/fc/test/common/conf/MybatisPlusConfig.java new file mode 100644 index 0000000000000000000000000000000000000000..4a8e4240880a7712ab518ef16942f06f47c16ed3 --- /dev/null +++ b/src/main/java/com/fc/test/common/conf/MybatisPlusConfig.java @@ -0,0 +1,42 @@ +package com.fc.test.common.conf; + +import com.baomidou.mybatisplus.annotation.DbType; +import com.baomidou.mybatisplus.extension.plugins.OptimisticLockerInterceptor; +import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor; +import com.fc.test.common.interceptor.PerformanceInterceptor; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.annotation.Profile; + +/** + * @author pencilso + * @date 2020/4/22 12:18 下午 + */ +@Configuration +public class MybatisPlusConfig { + + /** + * SQL执行效率插件 + */ + @Bean + @Profile({"dev", "test"})// 设置 dev test 环境开启 + public PerformanceInterceptor performanceInterceptor() { + return new PerformanceInterceptor(); + } + /** + * mybatils plus 设置方言 + * @return + */ + @Bean + public PaginationInterceptor paginationInterceptor() { + PaginationInterceptor page = new PaginationInterceptor(); + //设置方言类型 + page.setDbType(DbType.MYSQL); + return page; + } + + @Bean + public OptimisticLockerInterceptor optimisticLockerInterceptor() { + return new OptimisticLockerInterceptor(); + } +} \ No newline at end of file diff --git a/src/main/java/com/fc/test/common/conf/PageHelperConf.java b/src/main/java/com/fc/test/common/conf/PageHelperConf.java deleted file mode 100644 index 1ae2c42f098c47cb04cba1fe5cbb9a423f93c2d7..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/common/conf/PageHelperConf.java +++ /dev/null @@ -1,36 +0,0 @@ -package com.fc.test.common.conf; - -import java.util.Properties; - -import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.Configuration; - -import com.github.pagehelper.PageHelper; - -/** -* 分页插件配置类 -* @ClassName: PageHelperConf -* @Description: TODO(这里用一句话描述这个类的作用) -* @author fuce -* @date 2018年6月3日 -* - */ -@Configuration -public class PageHelperConf { - - /** - * 分页插件处理 - * @return - */ - @Bean - public PageHelper pageHelper() { - PageHelper pageHelper = new PageHelper(); - Properties properties = new Properties(); - properties.setProperty("offsetAsPageNum", "true"); - properties.setProperty("rowBoundsWithCount", "true"); - properties.setProperty("reasonable", "true"); - properties.setProperty("dialect", "mysql"); //配置mysql数据库的方言 - pageHelper.setProperties(properties); - return pageHelper; - } -} diff --git a/src/main/java/com/fc/test/common/conf/V2Config.java b/src/main/java/com/fc/test/common/conf/V2Config.java index 2c0e5c6df299ea250092ffbd007b84b9e3f0b447..27b9b659e423d6c59aa0f7af376df25a3b0a5e39 100644 --- a/src/main/java/com/fc/test/common/conf/V2Config.java +++ b/src/main/java/com/fc/test/common/conf/V2Config.java @@ -5,141 +5,156 @@ import org.springframework.stereotype.Component; /** * 读取项目相关配置 - * + * * @author fuce */ @Component @ConfigurationProperties(prefix = "fuce") -public class V2Config -{ - /** 项目名称 */ +public class V2Config { + /** + * 项目名称 + */ private String name; - /** 版本 */ + /** + * 版本 + */ private String version; - /** 版权年份 */ + /** + * 版权年份 + */ private String copyrightYear; - /** 上传路径 */ + /** + * 上传路径 + */ private static String profile; - /** 是否开启 上传static **/ + /** + * 是否开启 上传static + **/ private static String isstatic; - /** 开启存放静态文件夹后目录 **/ + /** + * 开启存放静态文件夹后目录 + **/ private static String isroot_dir; - /** 邮箱发送smtp */ + /** + * 邮箱发送smtp + */ private static String email_smtp; - /** 发送邮箱端口 */ + /** + * 发送邮箱端口 + */ private static String email_port; - /** 发送邮箱登录账号 */ + /** + * 发送邮箱登录账号 + */ private static String email_account; - /** 发送邮箱登录密码 */ + /** + * 发送邮箱登录密码 + */ private static String email_password; - /** 演示模式 **/ + /** + * 演示模式 + **/ private static String demoEnabled; - /** 滚动验证码 **/ + /** + * 滚动验证码 + **/ private static Boolean rollVerification; - public String getName() - { + + public String getName() { return name; } - public void setName(String name) - { + public void setName(String name) { this.name = name; } - public String getVersion() - { + public String getVersion() { return version; } - public void setVersion(String version) - { + public void setVersion(String version) { this.version = version; } - public String getCopyrightYear() - { + public String getCopyrightYear() { return copyrightYear; } - public void setCopyrightYear(String copyrightYear) - { + public void setCopyrightYear(String copyrightYear) { this.copyrightYear = copyrightYear; } - public static String getProfile() - { + public static String getProfile() { return profile; } - public void setProfile(String profile) - { - V2Config.profile = profile; + public void setProfile(String profile) { + V2Config.profile = profile; } - public static String getIsstatic() { - return isstatic; - } + public static String getIsstatic() { + return isstatic; + } - public void setIsstatic(String isstatic) { - V2Config.isstatic = isstatic; - } + public void setIsstatic(String isstatic) { + V2Config.isstatic = isstatic; + } - public static String getIsroot_dir() { - return isroot_dir; - } + public static String getIsroot_dir() { + return isroot_dir; + } - public void setIsroot_dir(String isroot_dir) { - V2Config.isroot_dir = isroot_dir; - } + public void setIsroot_dir(String isroot_dir) { + V2Config.isroot_dir = isroot_dir; + } - public static String getEmail_smtp() { - return email_smtp; - } + public static String getEmail_smtp() { + return email_smtp; + } - public void setEmail_smtp(String email_smtp) { - V2Config.email_smtp = email_smtp; - } + public void setEmail_smtp(String email_smtp) { + V2Config.email_smtp = email_smtp; + } - public static String getEmail_port() { - return email_port; - } + public static String getEmail_port() { + return email_port; + } - public void setEmail_port(String email_port) { - V2Config.email_port = email_port; - } + public void setEmail_port(String email_port) { + V2Config.email_port = email_port; + } - public static String getEmail_account() { - return email_account; - } + public static String getEmail_account() { + return email_account; + } - public void setEmail_account(String email_account) { - V2Config.email_account = email_account; - } + public void setEmail_account(String email_account) { + V2Config.email_account = email_account; + } - public static String getEmail_password() { - return email_password; - } + public static String getEmail_password() { + return email_password; + } - public void setEmail_password(String email_password) { - V2Config.email_password = email_password; - } + public void setEmail_password(String email_password) { + V2Config.email_password = email_password; + } - public static String getDemoEnabled() { - return demoEnabled; - } + public static String getDemoEnabled() { + return demoEnabled; + } - public void setDemoEnabled(String demoEnabled) { - V2Config.demoEnabled = demoEnabled; - } + public void setDemoEnabled(String demoEnabled) { + V2Config.demoEnabled = demoEnabled; + } + + public static Boolean getRollVerification() { + return rollVerification; + } + + public void setRollVerification(Boolean rollVerification) { + V2Config.rollVerification = rollVerification; + } - public static Boolean getRollVerification() { - return rollVerification; - } - public void setRollVerification(Boolean rollVerification) { - V2Config.rollVerification = rollVerification; - } - - - } diff --git a/src/main/java/com/fc/test/common/interceptor/ListTableparInerceptor.java b/src/main/java/com/fc/test/common/interceptor/ListTableparInerceptor.java new file mode 100644 index 0000000000000000000000000000000000000000..21ba321cca9dfd2ee72181ea7502ba740240aaed --- /dev/null +++ b/src/main/java/com/fc/test/common/interceptor/ListTableparInerceptor.java @@ -0,0 +1,11 @@ +package com.fc.test.common.interceptor; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; + +/** + * @author pencilso + * @date 2020/4/22 4:32 下午 + */ +public interface ListTableparInerceptor { + void call(QueryWrapper queryWrapper); +} diff --git a/src/main/java/com/fc/test/common/interceptor/MyInterceptor.java b/src/main/java/com/fc/test/common/interceptor/MyInterceptor.java index 9d02c8769cdf65af519d54c242811246b45f54c0..c3a33ab531f5b228d09030f5c594c3e69f22be63 100644 --- a/src/main/java/com/fc/test/common/interceptor/MyInterceptor.java +++ b/src/main/java/com/fc/test/common/interceptor/MyInterceptor.java @@ -1,45 +1,58 @@ package com.fc.test.common.interceptor; -import java.util.ArrayList; -import java.util.List; +import java.util.*; +import java.util.stream.Collectors; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; + +import com.fc.test.dao.model.SysInterUrlModel; +import com.fc.test.dao.service.SysInterUrlService; import org.springframework.web.servlet.HandlerInterceptor; import org.springframework.web.servlet.ModelAndView; import com.fc.test.common.conf.V2Config; import com.fc.test.common.exception.demo.DemoModeException; import com.fc.test.common.spring.SpringUtils; -import com.fc.test.model.auto.SysInterUrl; -import com.fc.test.model.auto.SysInterUrlExample; -import com.fc.test.service.SysInterUrlService; import cn.hutool.core.util.StrUtil; + /** * 自定义拦截器 - * @author fc * + * @author fc */ -public class MyInterceptor implements HandlerInterceptor { - - /*************演示模式需要 start*************/ - /**需要被拦截的post请求url**/ - public static List posturllist=new ArrayList(); - /**需要被拦截的get请求url**/ - public static List geturllist=new ArrayList(); - /**注入拦截器表的service**/ - public static SysInterUrlService interUrlService= SpringUtils.getBean(SysInterUrlService.class); - /** - * 初始化静态块,避免多次创建调用 - * 需要拦截的请求集合 - */ - static { - //post - SysInterUrlExample example_post= new SysInterUrlExample(); - example_post.createCriteria().andTypeEqualTo(2); - posturllist=interUrlService.selectByExample(example_post); - //get - SysInterUrlExample example_get= new SysInterUrlExample(); - example_get.createCriteria().andTypeEqualTo(1); - geturllist= interUrlService.selectByExample(example_get); +public class MyInterceptor implements HandlerInterceptor { + + /*************演示模式需要 start*************/ + /** + * 需要被拦截的post请求url + **/ + public static List posturllist = new ArrayList(); + /** + * 需要被拦截的get请求url + **/ + public static List geturllist = new ArrayList(); + /** + * 注入拦截器表的service + **/ + public static SysInterUrlService interUrlService = SpringUtils.getBean(SysInterUrlService.class); + + /** + * 初始化静态块,避免多次创建调用 + * 需要拦截的请求集合 + */ + static { +// //post +// posturllist = interUrlService.lambdaQuery().eq(SysInterUrlModel::getType, 2).list(); +// //get +// geturllist = interUrlService.lambdaQuery().eq(SysInterUrlModel::getType, 1).list(); + + List list = interUrlService.lambdaQuery().eq(SysInterUrlModel::getType, 1).or().eq(SysInterUrlModel::getType, 2).list(); + Map> integerListMap = list.stream().collect(Collectors.groupingBy(SysInterUrlModel::getType)); + //get + geturllist = Optional.ofNullable(integerListMap.get(1)).orElseGet(ArrayList::new); + //post + posturllist = Optional.ofNullable(integerListMap.get(2)).orElseGet(ArrayList::new); + + // //用户POST请求 // posturllist.add("/UserController/add"); // posturllist.add("/UserController/remove"); @@ -114,60 +127,62 @@ public class MyInterceptor implements HandlerInterceptor { // geturllist.add("/quartz/resume"); // geturllist.add("/quartz/update"); // geturllist.add("/quartz/delete"); - - } - /*************演示模式需要 end*************/ - @Override - public void afterCompletion(HttpServletRequest arg0, HttpServletResponse arg1, Object arg2, Exception arg3)throws Exception { - // System.out.println(">>>MyInterceptor1>>>>>>>在整个请求结束之后被调用,也就是在DispatcherServlet 渲染了对应的视图之后执行(主要是用于进行资源清理工作)"); - } - - @Override - public void postHandle(HttpServletRequest arg0, HttpServletResponse arg1, Object arg2, ModelAndView arg3)throws Exception { - // System.out.println(">>>MyInterceptor1>>>>>>>请求处理之后进行调用,但是在视图被渲染之前(Controller方法调用之后)"); - } - - @Override - public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object arg2) throws Exception { - //设置前端的全局 地址,如果前端网页错乱请修改这儿 - request.setAttribute("rootPath", request.getContextPath()); - //yml里面得演示模式true 为开启 就会拉取数据拦截表进行判断符合得就拦截 - if(V2Config.getDemoEnabled().equals("true")) { - Boolean b = ifurl(request, response); - if(b) { - throw new DemoModeException(); - } - } - return true;// 只有返回true才会继续向下执行,返回false取消当前请求 - } - - /** - * 判断是否需要拦截的用于展示演示模式 - * @param request - * @param response - * @return - * @author fuce - * @Date 2019年11月11日 下午5:17:30 - */ - public Boolean ifurl(HttpServletRequest request, HttpServletResponse response) { - - //当前请求 - String requesturl=request.getRequestURI(); - if(request.getMethod().equals("POST")) { - - for (SysInterUrl sysInterUrl : posturllist) { - if(StrUtil.containsAnyIgnoreCase(requesturl, sysInterUrl.getUrl())) { - return true; - } - } - }else { - for (SysInterUrl sysInterUrl : geturllist) { - if(StrUtil.containsAnyIgnoreCase(requesturl, sysInterUrl.getUrl())) { - return true; - } - } - } - - return false; - } + + } + + /*************演示模式需要 end*************/ + @Override + public void afterCompletion(HttpServletRequest arg0, HttpServletResponse arg1, Object arg2, Exception arg3) throws Exception { + // System.out.println(">>>MyInterceptor1>>>>>>>在整个请求结束之后被调用,也就是在DispatcherServlet 渲染了对应的视图之后执行(主要是用于进行资源清理工作)"); + } + + @Override + public void postHandle(HttpServletRequest arg0, HttpServletResponse arg1, Object arg2, ModelAndView arg3) throws Exception { + // System.out.println(">>>MyInterceptor1>>>>>>>请求处理之后进行调用,但是在视图被渲染之前(Controller方法调用之后)"); + } + + @Override + public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object arg2) throws Exception { + //设置前端的全局 地址,如果前端网页错乱请修改这儿 + request.setAttribute("rootPath", request.getContextPath()); + //yml里面得演示模式true 为开启 就会拉取数据拦截表进行判断符合得就拦截 + if (V2Config.getDemoEnabled().equals("true")) { + Boolean b = ifurl(request, response); + if (b) { + throw new DemoModeException(); + } + } + return true;// 只有返回true才会继续向下执行,返回false取消当前请求 + } + + /** + * 判断是否需要拦截的用于展示演示模式 + * + * @param request + * @param response + * @return + * @author fuce + * @Date 2019年11月11日 下午5:17:30 + */ + public Boolean ifurl(HttpServletRequest request, HttpServletResponse response) { + + //当前请求 + String requesturl = request.getRequestURI(); + if (request.getMethod().equals("POST")) { + + for (SysInterUrlModel sysInterUrl : posturllist) { + if (StrUtil.containsAnyIgnoreCase(requesturl, sysInterUrl.getUrl())) { + return true; + } + } + } else { + for (SysInterUrlModel sysInterUrl : geturllist) { + if (StrUtil.containsAnyIgnoreCase(requesturl, sysInterUrl.getUrl())) { + return true; + } + } + } + + return false; + } } diff --git a/src/main/java/com/fc/test/common/interceptor/PerformanceInterceptor.java b/src/main/java/com/fc/test/common/interceptor/PerformanceInterceptor.java new file mode 100644 index 0000000000000000000000000000000000000000..82c06df34eff132dd6a467082a45e344f9e4370b --- /dev/null +++ b/src/main/java/com/fc/test/common/interceptor/PerformanceInterceptor.java @@ -0,0 +1,225 @@ +package com.fc.test.common.interceptor; + +import com.baomidou.mybatisplus.core.toolkit.*; +import lombok.Getter; +import lombok.Setter; +import lombok.experimental.Accessors; +import org.apache.ibatis.executor.statement.StatementHandler; +import org.apache.ibatis.logging.Log; +import org.apache.ibatis.logging.LogFactory; +import org.apache.ibatis.mapping.MappedStatement; +import org.apache.ibatis.plugin.*; +import org.apache.ibatis.reflection.MetaObject; +import org.apache.ibatis.reflection.SystemMetaObject; +import org.apache.ibatis.session.ResultHandler; + +import java.lang.reflect.Method; +import java.lang.reflect.Proxy; +import java.sql.Statement; +import java.util.*; + +/** + * @author pencilso + * @date 2020/4/22 12:18 下午 + */ +@Intercepts({ + @Signature(type = StatementHandler.class, method = "query", args = {Statement.class, ResultHandler.class}), + @Signature(type = StatementHandler.class, method = "update", args = {Statement.class}), + @Signature(type = StatementHandler.class, method = "batch", args = {Statement.class}) +}) +public class PerformanceInterceptor implements Interceptor { + + private static final Log logger = LogFactory.getLog(PerformanceInterceptor.class); + private static final String DruidPooledPreparedStatement = "com.alibaba.druid.pool.DruidPooledPreparedStatement"; + private static final String T4CPreparedStatement = "oracle.jdbc.driver.T4CPreparedStatement"; + private static final String OraclePreparedStatementWrapper = "oracle.jdbc.driver.OraclePreparedStatementWrapper"; + /** + * SQL 执行最大时长,超过自动停止运行,有助于发现问题。 + */ + @Setter + @Getter + @Accessors(chain = true) + private long maxTime = 0; + /** + * SQL 是否格式化 + */ + @Setter + @Getter + @Accessors(chain = true) + private boolean format = false; + /** + * 是否写入日志文件 + *

true 写入日志文件,不阻断程序执行!

+ *

超过设定的最大执行时长异常提示!

+ */ + @Setter + @Getter + @Accessors(chain = true) + private boolean writeInLog = false; + private Method oracleGetOriginalSqlMethod; + private Method druidGetSQLMethod; + + @Override + public Object intercept(Invocation invocation) throws Throwable { + Statement statement; + Object firstArg = invocation.getArgs()[0]; + if (Proxy.isProxyClass(firstArg.getClass())) { + statement = (Statement) SystemMetaObject.forObject(firstArg).getValue("h.statement"); + } else { + statement = (Statement) firstArg; + } + MetaObject stmtMetaObj = SystemMetaObject.forObject(statement); + try { + statement = (Statement) stmtMetaObj.getValue("stmt.statement"); + } catch (Exception e) { + // do nothing + } + if (stmtMetaObj.hasGetter("delegate")) { + //Hikari + try { + statement = (Statement) stmtMetaObj.getValue("delegate"); + } catch (Exception ignored) { + + } + } + + String originalSql = null; + String stmtClassName = statement.getClass().getName(); + if (DruidPooledPreparedStatement.equals(stmtClassName)) { + try { + if (druidGetSQLMethod == null) { + Class clazz = Class.forName(DruidPooledPreparedStatement); + druidGetSQLMethod = clazz.getMethod("getSql"); + } + Object stmtSql = druidGetSQLMethod.invoke(statement); + if (stmtSql instanceof String) { + originalSql = (String) stmtSql; + } + } catch (Exception e) { + e.printStackTrace(); + } + } else if (T4CPreparedStatement.equals(stmtClassName) + || OraclePreparedStatementWrapper.equals(stmtClassName)) { + try { + if (oracleGetOriginalSqlMethod != null) { + Object stmtSql = oracleGetOriginalSqlMethod.invoke(statement); + if (stmtSql instanceof String) { + originalSql = (String) stmtSql; + } + } else { + Class clazz = Class.forName(stmtClassName); + oracleGetOriginalSqlMethod = getMethodRegular(clazz, "getOriginalSql"); + if (oracleGetOriginalSqlMethod != null) { + //OraclePreparedStatementWrapper is not a public class, need set this. + oracleGetOriginalSqlMethod.setAccessible(true); + if (null != oracleGetOriginalSqlMethod) { + Object stmtSql = oracleGetOriginalSqlMethod.invoke(statement); + if (stmtSql instanceof String) { + originalSql = (String) stmtSql; + } + } + } + } + } catch (Exception e) { + //ignore + } + } + if (originalSql == null) { + originalSql = statement.toString(); + } + originalSql = originalSql.replaceAll("[\\s]+", StringPool.SPACE); + int index = indexOfSqlStart(originalSql); + if (index > 0) { + originalSql = originalSql.substring(index); + } + + // 计算执行 SQL 耗时 + long start = SystemClock.now(); + Object result = invocation.proceed(); + long timing = SystemClock.now() - start; + + // 格式化 SQL 打印执行结果 + Object target = PluginUtils.realTarget(invocation.getTarget()); + MetaObject metaObject = SystemMetaObject.forObject(target); + MappedStatement ms = (MappedStatement) metaObject.getValue("delegate.mappedStatement"); + StringBuilder formatSql = new StringBuilder() + .append(" Time:").append(timing) + .append(" ms - ID:").append(ms.getId()) + .append(StringPool.NEWLINE).append("Execute SQL:") +// .append(SqlUtils.sqlFormat(originalSql, format)).append(StringPool.NEWLINE); + .append(originalSql).append(StringPool.NEWLINE); + if (this.isWriteInLog()) { + if (this.getMaxTime() >= 1 && timing > this.getMaxTime()) { + logger.error(formatSql.toString()); + } else { + logger.debug(formatSql.toString()); + } + } else { + System.err.println(formatSql.toString()); + Assert.isFalse(this.getMaxTime() >= 1 && timing > this.getMaxTime(), + " The SQL execution time is too large, please optimize ! "); + } + return result; + } + + @Override + public Object plugin(Object target) { + if (target instanceof StatementHandler) { + return Plugin.wrap(target, this); + } + return target; + } + + @Override + public void setProperties(Properties prop) { + String maxTime = prop.getProperty("maxTime"); + String format = prop.getProperty("format"); + if (StringUtils.isNotEmpty(maxTime)) { + this.maxTime = Long.parseLong(maxTime); + } + if (StringUtils.isNotEmpty(format)) { + this.format = Boolean.valueOf(format); + } + } + + /** + * 获取此方法名的具体 Method + * + * @param clazz class 对象 + * @param methodName 方法名 + * @return 方法 + */ + public Method getMethodRegular(Class clazz, String methodName) { + if (Object.class.equals(clazz)) { + return null; + } + for (Method method : clazz.getDeclaredMethods()) { + if (method.getName().equals(methodName)) { + return method; + } + } + return getMethodRegular(clazz.getSuperclass(), methodName); + } + + /** + * 获取sql语句开头部分 + * + * @param sql ignore + * @return ignore + */ + private int indexOfSqlStart(String sql) { + String upperCaseSql = sql.toUpperCase(); + Set set = new HashSet<>(); + set.add(upperCaseSql.indexOf("SELECT ")); + set.add(upperCaseSql.indexOf("UPDATE ")); + set.add(upperCaseSql.indexOf("INSERT ")); + set.add(upperCaseSql.indexOf("DELETE ")); + set.remove(-1); + if (CollectionUtils.isEmpty(set)) { + return -1; + } + List list = new ArrayList<>(set); + list.sort(Comparator.naturalOrder()); + return list.get(0); + } +} diff --git a/src/main/java/com/fc/test/common/log/LogAspect.java b/src/main/java/com/fc/test/common/log/LogAspect.java index 3d5317cb137536eb2ca947c6a921902c13636b82..06b9dcbaf068eeea85528b3b750f1399db5f6ba5 100644 --- a/src/main/java/com/fc/test/common/log/LogAspect.java +++ b/src/main/java/com/fc/test/common/log/LogAspect.java @@ -3,6 +3,11 @@ package com.fc.test.common.log; import java.lang.reflect.Method; import java.util.Date; import java.util.Map; + +import com.fc.test.dao.model.SysOperLogModel; +import com.fc.test.dao.model.SysUserModel; +import com.fc.test.dao.service.SysOperLogService; +import lombok.RequiredArgsConstructor; import org.aspectj.lang.JoinPoint; import org.aspectj.lang.Signature; import org.aspectj.lang.annotation.AfterReturning; @@ -16,9 +21,6 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.scheduling.annotation.Async; import org.springframework.scheduling.annotation.EnableAsync; import org.springframework.stereotype.Component; -import com.fc.test.model.auto.TsysOperLog; -import com.fc.test.model.auto.TsysUser; -import com.fc.test.service.SysOperLogService; import com.fc.test.shiro.util.ShiroUtils; import com.fc.test.util.ServletUtils; import com.fc.test.util.StringUtils; @@ -26,23 +28,22 @@ import com.google.gson.Gson; /** * 操作日志记录处理 - * @author fuce + * + * @author fuce * @date: 2018年9月30日 下午1:40:33 */ @Aspect @Component @EnableAsync -public class LogAspect -{ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class LogAspect { private static final Logger log = LoggerFactory.getLogger(LogAspect.class); - @Autowired - private SysOperLogService operLogService; + private final SysOperLogService operLogService; // 配置织入点 @Pointcut("@annotation(com.fc.test.common.log.Log)") - public void logPointCut() - { + public void logPointCut() { } /** @@ -51,41 +52,36 @@ public class LogAspect * @param joinPoint 切点 */ @AfterReturning(pointcut = "logPointCut()") - public void doBefore(JoinPoint joinPoint) - { + public void doBefore(JoinPoint joinPoint) { handleLog(joinPoint, null); } /** * 拦截异常操作 - * + * * @param joinPoint * @param e */ @AfterThrowing(value = "logPointCut()", throwing = "e") - public void doAfter(JoinPoint joinPoint, Exception e) - { + public void doAfter(JoinPoint joinPoint, Exception e) { handleLog(joinPoint, e); } @Async - protected void handleLog(final JoinPoint joinPoint, final Exception e) - { - try - { + protected void handleLog(final JoinPoint joinPoint, final Exception e) { + try { // 获得注解 Log controllerLog = getAnnotationLog(joinPoint); - if (controllerLog == null) - { + if (controllerLog == null) { return; } // 获取当前的用户 - TsysUser currentUser = ShiroUtils.getUser(); + SysUserModel currentUser = ShiroUtils.getUser(); // *========数据库日志=========*// - TsysOperLog operLog = new TsysOperLog(); - + SysOperLogModel operLog = new SysOperLogModel(); + //赋值操作 /*String ip = ShiroUtils.getIp(); operLog.setOperIp(ip);*/ @@ -93,8 +89,7 @@ public class LogAspect //operLog.setOperLocation(AddressUtils.getRealAddressByIP(ip)); // 请求的地址 operLog.setOperUrl(ServletUtils.getRequest().getRequestURI()); - if (currentUser != null) - { + if (currentUser != null) { // //操作人 operLog.setOperName(currentUser.getUsername()); // if (StringUtils.isNotNull(currentUser.getDept()) @@ -104,10 +99,9 @@ public class LogAspect // } } - if (e != null) - { - //错误日志 - operLog.setErrorMsg(StringUtils.substring(e.getMessage(), 0, 2000)); + if (e != null) { + //错误日志 + operLog.setErrorMsg(StringUtils.substring(e.getMessage(), 0, 2000)); } // 设置方法名称 String className = joinPoint.getTarget().getClass().getName(); @@ -120,10 +114,8 @@ public class LogAspect //System.out.println("-----------------"); //System.out.println(new Gson().toJson(operLog)); //System.out.println("-----------------"); - operLogService.insertSelective(operLog); - } - catch (Exception exp) - { + operLogService.save(operLog); + } catch (Exception exp) { // 记录本地异常日志 log.error("==前置通知异常=="); log.error("异常信息:{}", exp.getMessage()); @@ -133,22 +125,20 @@ public class LogAspect /** * 获取注解中对方法的描述信息 用于Controller层注解 - * - * @param joinPoint 切点 + * + * @param log 切点 * @return 方法描述 * @throws Exception */ - public void getControllerMethodDescription(Log log, TsysOperLog operLog) throws Exception - { + public void getControllerMethodDescription(Log log, SysOperLogModel operLog) throws Exception { // 设置action动作 - // operLog.setAction(log.action()); + // operLog.setAction(log.action()); // 设置标题 operLog.setTitle(log.title()); // 设置channel //operLog.setChannel(log.channel()); // 是否需要保存request,参数和值 - if (log.isSaveRequestData()) - { + if (log.isSaveRequestData()) { // 获取参数的信息,传入到数据库中。 setRequestValue(operLog); } @@ -156,14 +146,12 @@ public class LogAspect /** * 获取请求的参数,放到log中 - * + * * @param operLog - * @param request */ - private void setRequestValue(TsysOperLog operLog) - { + private void setRequestValue(SysOperLogModel operLog) { Map map = ServletUtils.getRequest().getParameterMap(); - Gson gson=new Gson(); + Gson gson = new Gson(); String params = gson.toJson(map); operLog.setOperParam(StringUtils.substring(params, 0, 255)); } @@ -171,14 +159,12 @@ public class LogAspect /** * 是否存在注解,如果存在就获取 */ - private Log getAnnotationLog(JoinPoint joinPoint) throws Exception - { + private Log getAnnotationLog(JoinPoint joinPoint) throws Exception { Signature signature = joinPoint.getSignature(); MethodSignature methodSignature = (MethodSignature) signature; Method method = methodSignature.getMethod(); - if (method != null) - { + if (method != null) { return method.getAnnotation(Log.class); } return null; diff --git a/src/main/java/com/fc/test/common/quartz/AbstractQuartzJob.java b/src/main/java/com/fc/test/common/quartz/AbstractQuartzJob.java index 028289081e8341fc77bc2322d2d825f2243d34da..ad38eb04ab0698ae004ed1389264a004a67dc636 100644 --- a/src/main/java/com/fc/test/common/quartz/AbstractQuartzJob.java +++ b/src/main/java/com/fc/test/common/quartz/AbstractQuartzJob.java @@ -1,19 +1,18 @@ package com.fc.test.common.quartz; import cn.hutool.core.exceptions.ExceptionUtil; - import com.fc.test.common.spring.SpringUtils; -import com.fc.test.model.auto.SysQuartzJob; -import com.fc.test.model.auto.SysQuartzJobLog; -import com.fc.test.service.SysQuartzJobLogService; +import com.fc.test.dao.model.SysQuartzJobLogModel; +import com.fc.test.dao.model.SysQuartzJobModel; +import com.fc.test.dao.service.SysQuartzJobLogService; import com.fc.test.util.StringUtils; - import org.quartz.Job; import org.quartz.JobExecutionContext; import org.quartz.JobExecutionException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.BeanUtils; + import java.util.Date; /** @@ -35,7 +34,7 @@ public abstract class AbstractQuartzJob implements Job { @Override public void execute(JobExecutionContext context) throws JobExecutionException { - SysQuartzJob sysJob = new SysQuartzJob(); + SysQuartzJobModel sysJob = new SysQuartzJobModel(); BeanUtils.copyProperties(context.getMergedJobDataMap().get(ScheduleConstants.TASK_PROPERTIES),sysJob); try { @@ -59,7 +58,7 @@ public abstract class AbstractQuartzJob implements Job { * @param context 工作执行上下文对象 * @param sysJob 系统计划任务 */ - protected void before(JobExecutionContext context, SysQuartzJob sysJob) + protected void before(JobExecutionContext context, SysQuartzJobModel sysJob) { threadLocal.set(new Date()); } @@ -70,12 +69,12 @@ public abstract class AbstractQuartzJob implements Job { * @param context 工作执行上下文对象 * @param sysJob 系统计划任务 */ - protected void after(JobExecutionContext context, SysQuartzJob sysJob, Exception e) + protected void after(JobExecutionContext context, SysQuartzJobModel sysJob, Exception e) { Date startTime = threadLocal.get(); threadLocal.remove(); - final SysQuartzJobLog sysJobLog = new SysQuartzJobLog(); + final SysQuartzJobLogModel sysJobLog = new SysQuartzJobLogModel(); sysJobLog.setJobName(sysJob.getJobName()); sysJobLog.setJobGroup(sysJob.getJobGroup()); sysJobLog.setInvokeTarget(sysJob.getInvokeTarget()); @@ -94,7 +93,7 @@ public abstract class AbstractQuartzJob implements Job { sysJobLog.setStatus(ScheduleConstants.SUCCESS_STATUS); } // 这里获取service然后插入库中 - SpringUtils.getBean(SysQuartzJobLogService.class).insertSelective(sysJobLog); + SpringUtils.getBean(SysQuartzJobLogService.class).save(sysJobLog); } /** @@ -102,5 +101,5 @@ public abstract class AbstractQuartzJob implements Job { * @param jobExecutionContext * @param sysJob */ - protected abstract void doExecute(JobExecutionContext jobExecutionContext, SysQuartzJob sysJob) throws Exception; + protected abstract void doExecute(JobExecutionContext jobExecutionContext, SysQuartzJobModel sysJob) throws Exception; } diff --git a/src/main/java/com/fc/test/common/quartz/QuartzDisallowConcurrentExecution.java b/src/main/java/com/fc/test/common/quartz/QuartzDisallowConcurrentExecution.java index 985d58e8cf572da3275d22c78c27aa7b1274433b..59084d15a2323e221ea919d432b2187edc84f4a4 100644 --- a/src/main/java/com/fc/test/common/quartz/QuartzDisallowConcurrentExecution.java +++ b/src/main/java/com/fc/test/common/quartz/QuartzDisallowConcurrentExecution.java @@ -1,8 +1,7 @@ package com.fc.test.common.quartz; import com.fc.test.common.quartz.utils.JobInvokeUtil; -import com.fc.test.model.auto.SysQuartzJob; - +import com.fc.test.dao.model.SysQuartzJobModel; import org.quartz.DisallowConcurrentExecution; import org.quartz.JobExecutionContext; @@ -16,7 +15,7 @@ import org.quartz.JobExecutionContext; public class QuartzDisallowConcurrentExecution extends AbstractQuartzJob { @Override - protected void doExecute(JobExecutionContext context, SysQuartzJob sysJob) throws Exception + protected void doExecute(JobExecutionContext context, SysQuartzJobModel sysJob) throws Exception { JobInvokeUtil.invokeMethod(sysJob); } diff --git a/src/main/java/com/fc/test/common/quartz/QuartzJobExecution.java b/src/main/java/com/fc/test/common/quartz/QuartzJobExecution.java index 949b060c71727e289fea5809a175dbc22f4ec475..4d599ffc2667a0a9fccb5a5529812d468d4bdf7e 100644 --- a/src/main/java/com/fc/test/common/quartz/QuartzJobExecution.java +++ b/src/main/java/com/fc/test/common/quartz/QuartzJobExecution.java @@ -1,8 +1,7 @@ package com.fc.test.common.quartz; import com.fc.test.common.quartz.utils.JobInvokeUtil; -import com.fc.test.model.auto.SysQuartzJob; - +import com.fc.test.dao.model.SysQuartzJobModel; import org.quartz.JobExecutionContext; /** @@ -14,7 +13,7 @@ import org.quartz.JobExecutionContext; public class QuartzJobExecution extends AbstractQuartzJob { @Override - protected void doExecute(JobExecutionContext context, SysQuartzJob sysJob) throws Exception { + protected void doExecute(JobExecutionContext context, SysQuartzJobModel sysJob) throws Exception { JobInvokeUtil.invokeMethod(sysJob); } diff --git a/src/main/java/com/fc/test/common/quartz/QuartzSchedulerUtil.java b/src/main/java/com/fc/test/common/quartz/QuartzSchedulerUtil.java index 63824c7f88453e65aa30f5a50901f93b0d6a230b..9ef6e15c57c42c31e6763d3b4a9bab3ed4f035bc 100644 --- a/src/main/java/com/fc/test/common/quartz/QuartzSchedulerUtil.java +++ b/src/main/java/com/fc/test/common/quartz/QuartzSchedulerUtil.java @@ -1,23 +1,22 @@ package com.fc.test.common.quartz; +import com.fc.test.dao.model.SysQuartzJobModel; +import com.fc.test.dao.service.SysQuartzJobService; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.quartz.*; import org.quartz.impl.JobDetailImpl; import org.quartz.impl.matchers.GroupMatcher; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.annotation.Configuration; -import com.fc.test.model.auto.SysQuartzJob; -import com.fc.test.model.auto.SysQuartzJobExample; -import com.fc.test.service.SysQuartzJobService; -import com.fc.test.util.StringUtils; +import javax.annotation.PostConstruct; import java.util.List; import java.util.Set; -import javax.annotation.PostConstruct; - /** * @CLASSNAME QuartzConfig - * @Description Quartz配置类 + * @Description Quartz配置类 * @Auther Jan 橙寂 * @DATE 2019/9/2 0002 15:21 */ @@ -27,11 +26,11 @@ public class QuartzSchedulerUtil { @Autowired private Scheduler scheduler; @Autowired - private SysQuartzJobService sysQuartzJobService; + private SysQuartzJobService sysQuartzJobService; //这个东西可以放在配置文件中 //cron表达式 一分钟执行一次 - private final String TEST_CRON="0 0/1 * * * ?"; + private final String TEST_CRON = "0 0/1 * * * ?"; /** * 容器初始化时执行此方法 @@ -39,20 +38,18 @@ public class QuartzSchedulerUtil { */ @PostConstruct public void init() throws SchedulerException { - - List quartzJobs=sysQuartzJobService.selectByExample(new SysQuartzJobExample()); - for (SysQuartzJob job : quartzJobs) { - try { + List quartzJobs = sysQuartzJobService.list(); + for (SysQuartzJobModel job : quartzJobs) { + try { //防止因为数据问题重复创建 - if(checkJobExists(job)) - { + if (checkJobExists(job)) { deleteJob(job); } createSchedule(job); - } catch (SchedulerException e) { - e.printStackTrace(); - } - } + } catch (SchedulerException e) { + e.printStackTrace(); + } + } //这一块可以从数据库中查 // for (int i=1;i<=1;i++) // { @@ -86,89 +83,87 @@ public class QuartzSchedulerUtil { /** * 启动定时器 */ - public void start() -{ - try { - scheduler.start(); - } catch (SchedulerException e) { - e.printStackTrace(); - System.out.println("定时任务执行失败"); + public void start() { + try { + scheduler.start(); + } catch (SchedulerException e) { + e.printStackTrace(); + System.out.println("定时任务执行失败"); + } } -} /** * 创建一个定时任务 + * * @param job * @throws SchedulerException */ - private void createSchedule(SysQuartzJob job) throws SchedulerException { + private void createSchedule(SysQuartzJobModel job) throws SchedulerException { if (!checkJobExists(job)) { //获取指定的job工作类 Class jobClass = getQuartzJobClass(job); // 通过JobBuilder构建JobDetail实例,JobDetail规定只能是实现Job接口的实例 // JobDetail 是具体Job实例 - JobDetail jobDetail = JobBuilder.newJob((Class) jobClass).withIdentity(ScheduleConstants.TASK_CLASS_NAME+job.getId(),job.getJobGroup()).build(); + JobDetail jobDetail = JobBuilder.newJob((Class) jobClass).withIdentity(ScheduleConstants.TASK_CLASS_NAME + job.getId(), job.getJobGroup()).build(); // 基于表达式构建触发器 - CronScheduleBuilder cronScheduleBuilder =null; - if(StringUtils.isNotEmpty(job.getCronExpression())) { - cronScheduleBuilder = CronScheduleBuilder.cronSchedule(job.getCronExpression()); - }else { - cronScheduleBuilder = CronScheduleBuilder.cronSchedule(TEST_CRON); + CronScheduleBuilder cronScheduleBuilder = null; + if (StringUtils.isNotEmpty(job.getCronExpression())) { + cronScheduleBuilder = CronScheduleBuilder.cronSchedule(job.getCronExpression()); + } else { + cronScheduleBuilder = CronScheduleBuilder.cronSchedule(TEST_CRON); } - + // CronTrigger表达式触发器 继承于Trigger //cronScheduleBuilder.withMisfireHandlingInstructionDoNothing()错过60分钟后不在补偿 拉下的执行次数 // TriggerBuilder 用于构建触发器实例 - CronTrigger cronTrigger = TriggerBuilder.newTrigger().withIdentity(ScheduleConstants.TASK_CLASS_NAME+job.getId(),job.getJobGroup()) - .withSchedule(cronScheduleBuilder.withMisfireHandlingInstructionDoNothing()).build(); + CronTrigger cronTrigger = TriggerBuilder.newTrigger().withIdentity(ScheduleConstants.TASK_CLASS_NAME + job.getId(), job.getJobGroup()) + .withSchedule(cronScheduleBuilder.withMisfireHandlingInstructionDoNothing()).build(); //放入参数,运行时的方法可以获取 jobDetail.getJobDataMap().put(ScheduleConstants.TASK_PROPERTIES, job); scheduler.scheduleJob(jobDetail, cronTrigger); - + //如果这个工作的状态为1 - if (job.getStatus().equals(1)) - { + if (job.getStatus().equals(1)) { pauseJob(job); } } } - - /** * 修改定时任务 + * * @param job * @return * @throws SchedulerException */ - public boolean modifyJob(SysQuartzJob job) { + public boolean modifyJob(SysQuartzJobModel job) { try { //先删除 - if(checkJobExists(job)) - { + if (checkJobExists(job)) { deleteJob(job); } createSchedule(job); } catch (SchedulerException e) { e.printStackTrace(); - return false; + return false; } - return true; + return true; } /** - * 继续执行定时任务 + * 继续执行定时任务 + * * @param job * @return */ - public boolean resumeJob(SysQuartzJob job) { + public boolean resumeJob(SysQuartzJobModel job) { boolean bl = false; try { //JobKey定义了job的名称和组别 - JobKey jobKey = JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME+job.getId(), job.getJobGroup()); + JobKey jobKey = JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME + job.getId(), job.getJobGroup()); if (jobKey != null) { //继续任务 scheduler.resumeJob(jobKey); @@ -183,15 +178,16 @@ public class QuartzSchedulerUtil { } /** - * 删除定时任务 + * 删除定时任务 + * * @param job * @return */ - public boolean deleteJob(SysQuartzJob job) { + public boolean deleteJob(SysQuartzJobModel job) { boolean bl = false; try { //JobKey定义了job的名称和组别 - JobKey jobKey = JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME+job.getId(), job.getJobGroup()); + JobKey jobKey = JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME + job.getId(), job.getJobGroup()); if (jobKey != null) { //删除定时任务 scheduler.deleteJob(jobKey); @@ -204,90 +200,91 @@ public class QuartzSchedulerUtil { } return bl; } - + /** * 获取jobKey */ - public JobKey getJobKey(SysQuartzJob job) - { - return JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME + job.getId(),job.getJobGroup()); + public JobKey getJobKey(SysQuartzJobModel job) { + return JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME + job.getId(), job.getJobGroup()); } - + /** * 立即执行任务 */ - public void run(SysQuartzJob job) throws SchedulerException - { + public void run(SysQuartzJobModel job) throws SchedulerException { // 参数 JobDataMap dataMap = new JobDataMap(); dataMap.put(ScheduleConstants.TASK_PROPERTIES, job); scheduler.triggerJob(getJobKey(job), dataMap); } + /** * 暂停任务 + * * @param job * @return */ - public boolean pauseJob(SysQuartzJob job) { + public boolean pauseJob(SysQuartzJobModel job) { boolean bl = false; try { //JobKey定义了job的名称和组别 - JobKey jobKey = JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME+job.getId(), job.getJobGroup()); + JobKey jobKey = JobKey.jobKey(ScheduleConstants.TASK_CLASS_NAME + job.getId(), job.getJobGroup()); //暂停任务 if (jobKey != null) { scheduler.pauseJob(jobKey); bl = true; } } catch (SchedulerException e) { - System.out.println("暂停调度任务异常:" + e); + System.out.println("暂停调度任务异常:" + e); } catch (Exception e) { - System.out.println("暂停调度任务异常:"+ e); + System.out.println("暂停调度任务异常:" + e); } return bl; } /** * 判断定时任务是否已经存在 + * * @param job * @return * @throws SchedulerException */ - public boolean checkJobExists(SysQuartzJob job) throws SchedulerException { - TriggerKey triggerKey = TriggerKey.triggerKey(ScheduleConstants.TASK_CLASS_NAME+job.getId(), job.getJobGroup()); + public boolean checkJobExists(SysQuartzJobModel job) throws SchedulerException { + TriggerKey triggerKey = TriggerKey.triggerKey(ScheduleConstants.TASK_CLASS_NAME + job.getId(), job.getJobGroup()); return scheduler.checkExists(triggerKey); } /** * 获取定时任务的具体执行类 + * * @param sysJob * @return */ - private static Class getQuartzJobClass(SysQuartzJob sysJob) - { + private static Class getQuartzJobClass(SysQuartzJobModel sysJob) { boolean isConcurrent = "0".equals(sysJob.getConcurrent()); return isConcurrent ? QuartzJobExecution.class : QuartzDisallowConcurrentExecution.class; } - - + + public void getquartzList() throws SchedulerException { List triggerGroupNames = scheduler.getTriggerGroupNames(); for (String groupName : triggerGroupNames) { - //组装group的匹配,为了模糊获取所有的triggerKey或者jobKey - GroupMatcher groupMatcher = GroupMatcher.groupEquals(groupName); - //获取所有的triggerKey - Set triggerKeySet = scheduler.getTriggerKeys(groupMatcher); - for (TriggerKey triggerKey : triggerKeySet) { - //通过triggerKey在scheduler中获取trigger对象 - CronTrigger trigger = (CronTrigger) scheduler.getTrigger(triggerKey); - //获取trigger拥有的Job - JobKey jobKey =trigger.getJobKey(); - JobDetailImpl jobDetail2 = (JobDetailImpl) scheduler.getJobDetail(jobKey); - System.out.println(groupName); - System.out.println(jobDetail2.getName()); - System.out.println(trigger.getCronExpression()); - } + //组装group的匹配,为了模糊获取所有的triggerKey或者jobKey + GroupMatcher groupMatcher = GroupMatcher.groupEquals(groupName); + //获取所有的triggerKey + Set triggerKeySet = scheduler.getTriggerKeys(groupMatcher); + for (TriggerKey triggerKey : triggerKeySet) { + //通过triggerKey在scheduler中获取trigger对象 + CronTrigger trigger = (CronTrigger) scheduler.getTrigger(triggerKey); + //获取trigger拥有的Job + JobKey jobKey = trigger.getJobKey(); + JobDetailImpl jobDetail2 = (JobDetailImpl) scheduler.getJobDetail(jobKey); + System.out.println(groupName); + System.out.println(jobDetail2.getName()); + System.out.println(trigger.getCronExpression()); + } } } } diff --git a/src/main/java/com/fc/test/common/quartz/task/V2Task.java b/src/main/java/com/fc/test/common/quartz/task/V2Task.java index aac7272aaabcabdf6e2686cc0bfc97fb91e854a7..c11aa65da5568c47481713bf586dc0a14ef0c600 100644 --- a/src/main/java/com/fc/test/common/quartz/task/V2Task.java +++ b/src/main/java/com/fc/test/common/quartz/task/V2Task.java @@ -1,41 +1,40 @@ package com.fc.test.common.quartz.task; import java.util.Date; + +import com.fc.test.dao.service.SysUserService; +import lombok.RequiredArgsConstructor; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; -import com.fc.test.mapper.auto.TsysUserMapper; /** - *测试类 - * @CLASSNAME V2Task + * 测试类 + * + * @CLASSNAME V2Task * @Description 定时调度具体工作类 * @Auther Jan 橙寂 * @DATE 2019/9/2 0002 15:33 */ @Component("v2Task") public class V2Task { - @Autowired - private TsysUserMapper tsysUserMapper; + /** * 无参的任务 */ - public void runTask1() - { + public void runTask1() { System.out.println("正在执行定时任务,无参方法"); } /** * 有参任务 * 目前仅执行常见的数据类型 Integer Long 带L string 带 '' bool Double 带 d + * * @param a * @param b */ - public void runTask2(Integer a,Long b,String c,Boolean d,Double e) - { - //List list= tsysUserMapper.selectByExample(new TsysUserExample()); - //System.err.println("用户查询num:"+list.size()); - System.out.println("正在执行定时任务,带多个参数的方法"+a+" "+b+" "+c+" "+d+" "+e+"执行时间:"+new Date().toLocaleString()); - - + public void runTask2(Integer a, Long b, String c, Boolean d, Double e) { + //List list= tsysUserMapper.selectByExample(new TsysUserExample()); + //System.err.println("用户查询num:"+list.size()); + System.out.println("正在执行定时任务,带多个参数的方法" + a + " " + b + " " + c + " " + d + " " + e + "执行时间:" + new Date().toLocaleString()); } } diff --git a/src/main/java/com/fc/test/common/quartz/utils/JobInvokeUtil.java b/src/main/java/com/fc/test/common/quartz/utils/JobInvokeUtil.java index 1461c656351ce8a77434e972d8ba50cf1a077f07..042bf00b37c23060ea28f8f2efecfc5858d67282 100644 --- a/src/main/java/com/fc/test/common/quartz/utils/JobInvokeUtil.java +++ b/src/main/java/com/fc/test/common/quartz/utils/JobInvokeUtil.java @@ -1,7 +1,7 @@ package com.fc.test.common.quartz.utils; import com.fc.test.common.spring.SpringUtils; -import com.fc.test.model.auto.SysQuartzJob; +import com.fc.test.dao.model.SysQuartzJobModel; import com.fc.test.util.StringUtils; import java.lang.reflect.InvocationTargetException; @@ -21,7 +21,7 @@ public class JobInvokeUtil * * @param sysJob 系统任务 */ - public static void invokeMethod(SysQuartzJob sysJob) throws Exception + public static void invokeMethod(SysQuartzJobModel sysJob) throws Exception { String invokeTarget = sysJob.getInvokeTarget(); String beanName = getBeanName(invokeTarget); @@ -74,7 +74,7 @@ public class JobInvokeUtil /** * 校验是否为为class包名 * - * @param str 名称 + * @param invokeTarget 名称 * @return true是 false否 */ public static boolean isValidClassName(String invokeTarget) diff --git a/src/main/java/com/fc/test/controller/AdminController.java b/src/main/java/com/fc/test/controller/AdminController.java index d4a22dfeb1dfb02c3a1d5bc75f523c7d26c878b8..ddde29bb2b98680c87771453fcbd7a1b76e70bf4 100644 --- a/src/main/java/com/fc/test/controller/AdminController.java +++ b/src/main/java/com/fc/test/controller/AdminController.java @@ -1,30 +1,24 @@ package com.fc.test.controller; -import java.util.List; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; import com.fc.test.common.base.BaseController; import com.fc.test.common.conf.V2Config; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysNotice; -import com.fc.test.model.auto.TsysUser; +import com.fc.test.dao.model.SysNoticeModel; +import com.fc.test.dao.model.SysUserModel; import com.fc.test.model.custom.BootstrapTree; import com.fc.test.model.custom.TitleVo; import com.fc.test.shiro.util.ShiroUtils; import com.fc.test.util.StringUtils; import com.google.code.kaptcha.Constants; import io.swagger.annotations.ApiOperation; +import lombok.RequiredArgsConstructor; import org.apache.shiro.SecurityUtils; -import org.apache.shiro.authc.AuthenticationException; -import org.apache.shiro.authc.ExcessiveAttemptsException; -import org.apache.shiro.authc.IncorrectCredentialsException; -import org.apache.shiro.authc.LockedAccountException; -import org.apache.shiro.authc.UnknownAccountException; -import org.apache.shiro.authc.UsernamePasswordToken; +import org.apache.shiro.authc.*; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.apache.shiro.subject.Subject; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.ui.ModelMap; import org.springframework.web.bind.annotation.GetMapping; @@ -33,190 +27,198 @@ import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.servlet.mvc.support.RedirectAttributes; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.util.List; + /** * 后台方法 - * @ClassName: HomeController + * * @author fuce + * @ClassName: HomeController * @date 2019-10-21 00:10 - * */ @Controller @RequestMapping("/admin") -public class AdminController extends BaseController{ - private static Logger logger=LoggerFactory.getLogger(AdminController.class); - - private String prefix = "admin"; - - @ApiOperation(value="首页",notes="首页") - @GetMapping("/index") - public String index(HttpServletRequest request) { - //获取菜单栏 - BootstrapTree bootstrapTree= sysPermissionService.getbooBootstrapTreePerm(ShiroUtils.getUserId()); - request.getSession().setAttribute("bootstrapTree", bootstrapTree); - request.getSession().setAttribute("sessionUserName",ShiroUtils.getUser().getNickname()); - //获取公告信息 - List notices=sysNoticeService.getuserNoticeNotRead(ShiroUtils.getUser(),0); - request.getSession().setAttribute("notices",notices); - return prefix+"/index"; - } - - @ApiOperation(value="局部刷新区域",notes="局部刷新区域") - @GetMapping("/main") - public String main(ModelMap map) { - setTitle(map, new TitleVo("首页", "首页", true,"欢迎进入", true, false)); - return prefix+"/main"; - } - - /** - * 请求到登陆界面 - * @param request - * @return - */ - @ApiOperation(value="请求到登陆界面",notes="请求到登陆界面") - @GetMapping("/login") +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class AdminController extends BaseController { + + + private static Logger logger = LoggerFactory.getLogger(AdminController.class); + + private String prefix = "admin"; + + + @ApiOperation(value = "首页", notes = "首页") + @GetMapping("/index") + public String index(HttpServletRequest request) { + //获取菜单栏 + BootstrapTree bootstrapTree = sysPermissionService.getbooBootstrapTreePerm(ShiroUtils.getUserId()); + request.getSession().setAttribute("bootstrapTree", bootstrapTree); + request.getSession().setAttribute("sessionUserName", ShiroUtils.getUser().getNickname()); + //获取公告信息 + List notices = sysNoticeService.getuserNoticeNotRead(ShiroUtils.getUser(), 0); + request.getSession().setAttribute("notices", notices); + return prefix + "/index"; + } + + @ApiOperation(value = "局部刷新区域", notes = "局部刷新区域") + @GetMapping("/main") + public String main(ModelMap map) { + setTitle(map, new TitleVo("首页", "首页", true, "欢迎进入", true, false)); + return prefix + "/main"; + } + + /** + * 请求到登陆界面 + * + * @param request + * @return + */ + @ApiOperation(value = "请求到登陆界面", notes = "请求到登陆界面") + @GetMapping("/login") public String login(ModelMap modelMap) { try { if ((null != SecurityUtils.getSubject() && SecurityUtils.getSubject().isAuthenticated()) || SecurityUtils.getSubject().isRemembered()) { - return "redirect:/"+prefix+"/index"; + return "redirect:/" + prefix + "/index"; } else { - System.out.println("--进行登录验证..验证开始"); + System.out.println("--进行登录验证..验证开始"); - modelMap.put("RollVerification", V2Config.getRollVerification()); - System.out.println("V2Config.getRollVerification()>>>"+V2Config.getRollVerification()); + modelMap.put("RollVerification", V2Config.getRollVerification()); + System.out.println("V2Config.getRollVerification()>>>" + V2Config.getRollVerification()); return "login"; } } catch (Exception e) { - e.printStackTrace(); + e.printStackTrace(); } return "login"; } - - /** - * 用户登陆验证 - * @param user - * @param rcode - * @param redirectAttributes - * @param rememberMe - * @param model - * @param request - * @return - */ - @ApiOperation(value="用户登陆验证",notes="用户登陆验证") - @PostMapping("/login") - @ResponseBody - public AjaxResult login(TsysUser user,String code,RedirectAttributes redirectAttributes,boolean rememberMe,HttpServletRequest request) { - //ModelAndView view =new ModelAndView(); - Boolean yz=false; - if(V2Config.getRollVerification()) {//滚动验证 - yz=true; - }else {//图片验证 - String scode = (String)request.getSession().getAttribute(Constants.KAPTCHA_SESSION_KEY); - yz=StringUtils.isNotEmpty(scode)&&StringUtils.isNotEmpty(code)&&scode.equals(code); - } - //判断验证码 - if(yz){ - String userName = user.getUsername(); - Subject currentUser = SecurityUtils.getSubject(); - //是否验证通过 - if(!currentUser.isAuthenticated()) { - UsernamePasswordToken token =new UsernamePasswordToken(userName,user.getPassword()); - try { - if(rememberMe) { - token.setRememberMe(true); - } - //存入用户 - currentUser.login(token); - if(StringUtils.isNotNull(ShiroUtils.getUser())) { - //跳转到 get请求的登陆方法 - //view.setViewName("redirect:/"+prefix+"/index"); - return AjaxResult.success(); - }else { - return AjaxResult.error(500,"未知账户"); - } - }catch (UnknownAccountException uae) { - logger.info("对用户[" + userName + "]进行登录验证..验证未通过,未知账户"); - return AjaxResult.error(500,"未知账户"); - } catch (IncorrectCredentialsException ice) { - logger.info("对用户[" + userName + "]进行登录验证..验证未通过,错误的凭证"); - return AjaxResult.error(500, "用户名或密码不正确"); - } catch (LockedAccountException lae) { - logger.info("对用户[" + userName + "]进行登录验证..验证未通过,账户已锁定"); - return AjaxResult.error(500,"账户已锁定"); - } catch (ExcessiveAttemptsException eae) { - logger.info("对用户[" + userName + "]进行登录验证..验证未通过,错误次数过多"); - return AjaxResult.error(500,"用户名或密码错误次数过多"); - } catch (AuthenticationException ae) { - //通过处理Shiro的运行时AuthenticationException就可以控制用户登录失败或密码错误时的情景 - logger.info("对用户[" + userName + "]进行登录验证..验证未通过,堆栈轨迹如下"); - ae.printStackTrace(); - return AjaxResult.error(500,"用户名或密码不正确"); - } - }else { - if(StringUtils.isNotNull(ShiroUtils.getUser())) { - //跳转到 get请求的登陆方法 - //view.setViewName("redirect:/"+prefix+"/index"); - return AjaxResult.success(); - }else { - return AjaxResult.error(500,"未知账户"); - } - } - }else{ - return AjaxResult.error(500,"验证码不正确!"); - } - - } - - /** - * 退出登陆 - * @return - */ - @ApiOperation(value="退出登陆",notes="退出登陆") - @GetMapping("/Loginout") - public String LoginOut(HttpServletRequest request, HttpServletResponse response){ - //在这里执行退出系统前需要清空的数据 - Subject subject = SecurityUtils.getSubject(); - //注销 + + /** + * 用户登陆验证 + * @param user + * @param code + * @param redirectAttributes + * @param rememberMe + * @param request + * @return + */ + @ApiOperation(value = "用户登陆验证", notes = "用户登陆验证") + @PostMapping("/login") + @ResponseBody + public AjaxResult login(SysUserModel user, String code, RedirectAttributes redirectAttributes, boolean rememberMe, HttpServletRequest request) { + //ModelAndView view =new ModelAndView(); + Boolean yz = false; + if (V2Config.getRollVerification()) {//滚动验证 + yz = true; + } else {//图片验证 + String scode = (String) request.getSession().getAttribute(Constants.KAPTCHA_SESSION_KEY); + yz = StringUtils.isNotEmpty(scode) && StringUtils.isNotEmpty(code) && scode.equals(code); + } + //判断验证码 + if (yz) { + String userName = user.getUsername(); + Subject currentUser = SecurityUtils.getSubject(); + //是否验证通过 + if (!currentUser.isAuthenticated()) { + UsernamePasswordToken token = new UsernamePasswordToken(userName, user.getPassword()); + try { + if (rememberMe) { + token.setRememberMe(true); + } + //存入用户 + currentUser.login(token); + if (StringUtils.isNotNull(ShiroUtils.getUser())) { + //跳转到 get请求的登陆方法 + //view.setViewName("redirect:/"+prefix+"/index"); + return AjaxResult.success(); + } else { + return AjaxResult.error(500, "未知账户"); + } + } catch (UnknownAccountException uae) { + logger.info("对用户[" + userName + "]进行登录验证..验证未通过,未知账户"); + return AjaxResult.error(500, "未知账户"); + } catch (IncorrectCredentialsException ice) { + logger.info("对用户[" + userName + "]进行登录验证..验证未通过,错误的凭证"); + return AjaxResult.error(500, "用户名或密码不正确"); + } catch (LockedAccountException lae) { + logger.info("对用户[" + userName + "]进行登录验证..验证未通过,账户已锁定"); + return AjaxResult.error(500, "账户已锁定"); + } catch (ExcessiveAttemptsException eae) { + logger.info("对用户[" + userName + "]进行登录验证..验证未通过,错误次数过多"); + return AjaxResult.error(500, "用户名或密码错误次数过多"); + } catch (AuthenticationException ae) { + //通过处理Shiro的运行时AuthenticationException就可以控制用户登录失败或密码错误时的情景 + logger.info("对用户[" + userName + "]进行登录验证..验证未通过,堆栈轨迹如下"); + ae.printStackTrace(); + return AjaxResult.error(500, "用户名或密码不正确"); + } + } else { + if (StringUtils.isNotNull(ShiroUtils.getUser())) { + //跳转到 get请求的登陆方法 + //view.setViewName("redirect:/"+prefix+"/index"); + return AjaxResult.success(); + } else { + return AjaxResult.error(500, "未知账户"); + } + } + } else { + return AjaxResult.error(500, "验证码不正确!"); + } + + } + + /** + * 退出登陆 + * + * @return + */ + @ApiOperation(value = "退出登陆", notes = "退出登陆") + @GetMapping("/Loginout") + public String LoginOut(HttpServletRequest request, HttpServletResponse response) { + //在这里执行退出系统前需要清空的数据 + Subject subject = SecurityUtils.getSubject(); + //注销 subject.logout(); - return "redirect:/"+prefix+"/login"; - } - - - - - /****页面测试****/ - @ApiOperation(value="404页面",notes="404页面") - @GetMapping("Out404") - public String Out404(HttpServletRequest request, HttpServletResponse response){ - + return "redirect:/" + prefix + "/login"; + } + + + /****页面测试****/ + @ApiOperation(value = "404页面", notes = "404页面") + @GetMapping("Out404") + public String Out404(HttpServletRequest request, HttpServletResponse response) { + return "redirect:/error/404"; - } - - @GetMapping("Out403") - @ApiOperation(value="403页面",notes="403页面") - public String Out403(HttpServletRequest request, HttpServletResponse response){ - + } + + @GetMapping("Out403") + @ApiOperation(value = "403页面", notes = "403页面") + public String Out403(HttpServletRequest request, HttpServletResponse response) { + return "redirect:/error/403"; - } - - @ApiOperation(value="500页面",notes="500页面") - @GetMapping("Out500") - public String Out500(HttpServletRequest request, HttpServletResponse response){ - + } + + @ApiOperation(value = "500页面", notes = "500页面") + @GetMapping("Out500") + public String Out500(HttpServletRequest request, HttpServletResponse response) { + return "redirect:/error/500"; - } - - /** - * 权限测试跳转页面 - * @param request - * @param response - * @return - */ - @ApiOperation(value="权限测试跳转页面",notes="权限测试跳转页面") - @GetMapping("Outqx") - @RequiresPermissions("system:user:asd") - public String Outqx(HttpServletRequest request, HttpServletResponse response){ - + } + + /** + * 权限测试跳转页面 + * + * @param request + * @param response + * @return + */ + @ApiOperation(value = "权限测试跳转页面", notes = "权限测试跳转页面") + @GetMapping("Outqx") + @RequiresPermissions("system:user:asd") + public String Outqx(HttpServletRequest request, HttpServletResponse response) { + return "redirect:/error/500"; - } - /****页面测试EDN****/ + } + /****页面测试EDN****/ } diff --git a/src/main/java/com/fc/test/controller/admin/AutoCodeController.java b/src/main/java/com/fc/test/controller/admin/AutoCodeController.java index c8e8f5150fd893c45587ab72f2d6c6dddd9deedf..c12fc8a0cefd08be2d34511f0edf1ecc0c3adc52 100644 --- a/src/main/java/com/fc/test/controller/admin/AutoCodeController.java +++ b/src/main/java/com/fc/test/controller/admin/AutoCodeController.java @@ -4,21 +4,22 @@ import java.util.List; import javax.servlet.http.HttpServletRequest; import cn.hutool.json.JSONArray; import cn.hutool.json.JSONUtil; +import com.fc.test.dao.model.SysPermissionModel; +import com.fc.test.dao.service.SysPermissionService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.TsysPermission; import com.fc.test.model.custom.TitleVo; import com.fc.test.model.custom.TsysTables; import com.fc.test.model.custom.autocode.AutoCodeConfig; import com.fc.test.model.custom.autocode.BeanColumn; import com.fc.test.model.custom.autocode.GlobalConfig; import com.fc.test.service.GeneratorService; -import com.fc.test.service.SysPermissionService; import com.fc.test.service.SysUtilService; import com.fc.test.util.AutoCode.AutoCodeUtil; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -36,18 +37,17 @@ import org.springframework.web.bind.annotation.ResponseBody; * @author fuce * @date 2019-08-13 00:34 */ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) @Api(value = "代码自动生成") @Controller @RequestMapping("/autoCodeController") public class AutoCodeController extends BaseController { private String prefix = "admin/auto_code"; - @Autowired - private GeneratorService generatorService; - @Autowired - private SysUtilService sysUtilService; - @Autowired - private SysPermissionService sysPermissionService; + + private final GeneratorService generatorService; + private final SysUtilService sysUtilService; + private final SysPermissionService sysPermissionService; /** * 代码自动生成展示首页 @@ -64,7 +64,7 @@ public class AutoCodeController extends BaseController { String str = "单表代码生成"; setTitle(model, new TitleVo("生成", str + "管理", true, "欢迎进入" + str + "页面", true, false)); List tables = generatorService.queryList(null); - List permissions = sysPermissionService.list2(null); + List permissions = sysPermissionService.list2(null); model.addAttribute("tables", tables); model.addAttribute("permissions", permissions); return prefix + "/one"; @@ -73,7 +73,6 @@ public class AutoCodeController extends BaseController { /** * 代码自动生成全局配置 * - * @param model * @return * @author fuce * @Date 2019年8月13日 上午12:34:30 @@ -185,7 +184,6 @@ public class AutoCodeController extends BaseController { /** * 根据权限字段查询是否存在 * - * @param perms * @return * @author fuce * @Date 2019年9月1日 上午2:06:31 diff --git a/src/main/java/com/fc/test/controller/admin/DictDataController.java b/src/main/java/com/fc/test/controller/admin/DictDataController.java index bf50a4831975204446e6693772fde163bdf850f5..fe0972a56b32db2e14a7d7fb60571008f718decb 100644 --- a/src/main/java/com/fc/test/controller/admin/DictDataController.java +++ b/src/main/java/com/fc/test/controller/admin/DictDataController.java @@ -1,9 +1,13 @@ package com.fc.test.controller.admin; -import com.fc.test.model.auto.TSysDictData; -import com.fc.test.service.SysDictDataService; -import com.fc.test.service.SysDictTypeService; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysDictDataModel; +import com.fc.test.dao.service.SysDictDataService; +import com.fc.test.dao.service.SysDictTypeService; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -14,7 +18,6 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; import com.fc.test.model.custom.TableSplitResult; @@ -25,157 +28,145 @@ import io.swagger.annotations.ApiOperation; /** * 字典表Controller - * @ClassName: DictDataController + * * @author fuce + * @ClassName: DictDataController * @date 2019-11-20 22:46 */ @Api(value = "字典数据表") @Controller @RequestMapping("/DictDataController") -public class DictDataController extends BaseController{ - - private String prefix = "admin/dict_data"; - @Autowired - private SysDictDataService tSysDictDataService; - @Autowired - private SysDictTypeService sysDictTypeService; - - /** - * 分页list页面 - * @param model - * @param dictId - * @return - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:dictData:view") - public String view(ModelMap model,String dictId) - { - model.addAttribute("dictId",dictId); - String str="字典数据表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class DictDataController extends BaseController { + + private String prefix = "admin/dict_data"; + private final SysDictDataService tSysDictDataService; + private final SysDictTypeService sysDictTypeService; + + /** + * 分页list页面 + * + * @param model + * @param dictId + * @return + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:dictData:view") + public String view(ModelMap model, String dictId) { + model.addAttribute("dictId", dictId); + String str = "字典数据表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 字典数据表集合查询 - * @param tablepar - * @param searchText - * @param dictId - * @return - */ - //@Log(title = "字典数据表集合查询", action = "1") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:dictData:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText,String dictId){ - PageInfo page=tSysDictDataService.list(tablepar,searchText,dictId) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 新增跳转 - * @param modelMap - * @param dictId - * @return - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * 字典数据表集合查询 + * + * @param tablepar + * @param searchText + * @param dictId + * @return + */ + //@Log(title = "字典数据表集合查询", action = "1") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:dictData:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText, String dictId) { + final String dictType = sysDictTypeService.getById(dictId).getDictType(); + PageInfo page = tSysDictDataService.listTablepar(tablepar, "dict_value", searchText, queryWrapper -> { + queryWrapper.eq("dict_type", dictType); + }); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** + * 新增跳转 + * + * @param modelMap + * @param dictId + * @return + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap,String dictId) - { - modelMap.addAttribute("dictType",sysDictTypeService.selectByPrimaryKey(dictId).getDictType()); + public String add(ModelMap modelMap, String dictId) { + modelMap.addAttribute("dictType", sysDictTypeService.getById(dictId).getDictType()); return prefix + "/add"; } - + /** * 新增保存 + * * @param tSysDictData * @param model * @return */ - //@Log(title = "字典数据表新增", action = "1") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("system:dictData:add") - @ResponseBody - public AjaxResult add(TSysDictData tSysDictData, Model model){ - int b=tSysDictDataService.insertSelective(tSysDictData); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除 - * @param ids - * @return - */ - //@Log(title = "字典数据表删除", action = "1") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("system:dictData:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=tSysDictDataService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(TSysDictData tSysDictData){ - int b=tSysDictDataService.checkNameUnique(tSysDictData); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - TSysDictData sysDictData= tSysDictDataService.selectByPrimaryKey(id); + //@Log(title = "字典数据表新增", action = "1") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("system:dictData:add") + @ResponseBody + public AjaxResult add(SysDictDataModel tSysDictData, Model model) { + return toAjax(tSysDictDataService.save(tSysDictData)); + } + + /** + * 删除 + * + * @param ids + * @return + */ + //@Log(title = "字典数据表删除", action = "1") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("system:dictData:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(tSysDictDataService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查 + * + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysDictDataModel tSysDictData) { + int b = tSysDictDataService.checkNameUnique("dict_value", tSysDictData.getDictValue()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + SysDictDataModel sysDictData = tSysDictDataService.getById(id); mmap.put("TSysDictData", sysDictData); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "字典数据表修改", action = "1") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("system:dictData:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(TSysDictData record) - { - return toAjax(tSysDictDataService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysDictDataModel record) { + return toAjax(tSysDictDataService.updateById(record)); } - - - } diff --git a/src/main/java/com/fc/test/controller/admin/DictTypeController.java b/src/main/java/com/fc/test/controller/admin/DictTypeController.java index c8446dc655dd9d4e6fe7b268d40ad3de1a760ccf..edab6cf86a3ce008b5aadf1dd7024fce498eddd7 100644 --- a/src/main/java/com/fc/test/controller/admin/DictTypeController.java +++ b/src/main/java/com/fc/test/controller/admin/DictTypeController.java @@ -1,5 +1,11 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysDictTypeModel; +import com.fc.test.dao.service.SysDictTypeService; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -10,162 +16,148 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.TSysDictType; import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysDictTypeService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 字典类型Controller - * @ClassName: DictTypeController + * * @author fuce + * @ClassName: DictTypeController * @date 2019-11-20 22:45 */ @Api(value = "字典类型表") @Controller @RequestMapping("/DictTypeController") -public class DictTypeController extends BaseController{ - - private String prefix = "admin/dict_type"; - @Autowired - private SysDictTypeService tSysDictTypeService; - - /** - * 分页list页面 - * @param model - * @param dictId - * @return - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:dictType:view") - public String view(ModelMap model) - { - String str="字典类型表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class DictTypeController extends BaseController { + + private String prefix = "admin/dict_type"; + private final SysDictTypeService tSysDictTypeService; + + /** + * 分页list页面 + * + * @param model + * @param dictId + * @return + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:dictType:view") + public String view(ModelMap model) { + String str = "字典类型表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 字典类型表集合查询 - * @param tablepar - * @param searchText - * @return - */ - //@Log(title = "字典类型表集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:dictType:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=tSysDictTypeService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 新增跳转 - * @param modelMap - * @return - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * 字典类型表集合查询 + * + * @param tablepar + * @param searchText + * @return + */ + //@Log(title = "字典类型表集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:dictType:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = tSysDictTypeService.listTablepar(tablepar, "dict_name", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** + * 新增跳转 + * + * @param modelMap + * @return + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - + /** * 新增保存 * TODO(请说明这个方法的作用). + * * @param tSysDictType * @param model * @return */ - //@Log(title = "字典类型表新增", action = "111") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("system:dictType:add") - @ResponseBody - public AjaxResult add(TSysDictType tSysDictType,Model model){ - int b=tSysDictTypeService.insertSelective(tSysDictType); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除字典类型 - * @param ids - * @return - */ - //@Log(title = "字典类型表删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("system:dictType:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=tSysDictTypeService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查字典类型名字相同 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(TSysDictType tSysDictType){ - int b=tSysDictTypeService.checkNameUnique(tSysDictType); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("TSysDictType", tSysDictTypeService.selectByPrimaryKey(id)); + //@Log(title = "字典类型表新增", action = "111") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("system:dictType:add") + @ResponseBody + public AjaxResult add(SysDictTypeModel tSysDictType, Model model) { + return toAjax(tSysDictTypeService.save(tSysDictType)); + } + /** + * 删除字典类型 + * + * @param ids + * @return + */ + //@Log(title = "字典类型表删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("system:dictType:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(tSysDictTypeService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查字典类型名字相同 + * + * @param tSysDictType + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysDictTypeModel tSysDictType) { + int b = tSysDictTypeService.checkNameUnique("dict_name", tSysDictType.getDictName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("TSysDictType", tSysDictTypeService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "字典类型表修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("system:dictType:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(TSysDictType record) - { - return toAjax(tSysDictTypeService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysDictTypeModel record) { + return toAjax(tSysDictTypeService.updateById(record)); } - + } diff --git a/src/main/java/com/fc/test/controller/admin/EmailController.java b/src/main/java/com/fc/test/controller/admin/EmailController.java index eb8365afabc9e4945ae55cc34b5a42fe3b3681f8..dfff63fb4cf212b8c0a150c3d92a32eb80456c96 100644 --- a/src/main/java/com/fc/test/controller/admin/EmailController.java +++ b/src/main/java/com/fc/test/controller/admin/EmailController.java @@ -1,5 +1,12 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysEmailModel; +import com.fc.test.dao.service.SysEmailService; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -13,163 +20,146 @@ import org.springframework.web.bind.annotation.ResponseBody; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.TSysEmail; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.TSysEmailService; import com.fc.test.util.SimpleEmailUtil; -import com.github.pagehelper.PageInfo; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 邮件发送Controller - * @ClassName: EmailController + * * @author fuce - * @date 2019-06-10 00:39 * @version V1.0 + * @ClassName: EmailController + * @date 2019-06-10 00:39 */ @Api(value = "邮件发送Controller") @Controller @RequestMapping("/EmailController") -public class EmailController extends BaseController{ - - private String prefix = "admin/email"; - - @Autowired - private TSysEmailService tSysEmailService; - - /** - * 分页展示页面 - * @param model - * @param dictId - * @return - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:email:view") - public String view(ModelMap model) - { - String str="邮件"; - setTitle(model, new TitleVo("发送", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class EmailController extends BaseController { + + private String prefix = "admin/email"; + + private final SysEmailService sysEmailService; + + /** + * 分页展示页面 + * + * @param model + * @param model + * @return + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:email:view") + public String view(ModelMap model) { + String str = "邮件"; + setTitle(model, new TitleVo("发送", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - /** - * 分页list页面 - * @param model - * @param dictId - * @return - */ - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:email:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=tSysEmailService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** + /** + * 分页list页面 + * + * @param tablepar + * @param searchText + * @return + */ + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:email:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysEmailService.listTablepar(tablepar, "content", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** * 新增跳转 */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - - /** - * 新增 - * @param tSysEmail - * @param model - * @return - * @throws Exception - * @author fuce - */ - //@Log(title = "新增邮件", action = "1") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("system:email:add") - @ResponseBody - public AjaxResult add(TSysEmail tSysEmail,Model model) throws Exception{ - int b=tSysEmailService.insertSelective(tSysEmail); - SimpleEmailUtil.sendEmail(tSysEmail); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除邮件 - * @param ids - * @return - */ - //@Log(title = "删除邮件", action = "1") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("system:email:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=tSysEmailService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查邮件同名 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(TSysEmail tSysEmail){ - int b=tSysEmailService.checkNameUnique(tSysEmail); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("TSysEmail", tSysEmailService.selectByPrimaryKey(id)); + + /** + * 新增 + * + * @param tSysEmail + * @param model + * @return + * @throws Exception + * @author fuce + */ + //@Log(title = "新增邮件", action = "1") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("system:email:add") + @ResponseBody + public AjaxResult add(SysEmailModel tSysEmail, Model model) throws Exception { + return toAjax(sysEmailService.save(tSysEmail)); + } + + /** + * 删除邮件 + * + * @param ids + * @return + */ + //@Log(title = "删除邮件", action = "1") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("system:email:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysEmailService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查邮件同名 + * + * @param tSysEmail + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysEmailModel tSysEmail) { + int b = sysEmailService.checkNameUnique("content", tSysEmail.getContent()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("TSysEmail", sysEmailService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ - //@Log(title = "修改保存", action = "1") - @ApiOperation(value = "修改保存", notes = "修改保存") + //@Log(title = "修改保存", action = "1") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("system:email:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(TSysEmail record) - { - return toAjax(tSysEmailService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysEmailModel record) { + return toAjax(sysEmailService.updateById(record)); } - } diff --git a/src/main/java/com/fc/test/controller/admin/FileController.java b/src/main/java/com/fc/test/controller/admin/FileController.java index 95a2efb540755f3ceaabf064a1cf5faafc107abe..6cd1ad6b8681f68b38fc181aa9fc26c4b9b9d8eb 100644 --- a/src/main/java/com/fc/test/controller/admin/FileController.java +++ b/src/main/java/com/fc/test/controller/admin/FileController.java @@ -3,10 +3,19 @@ package com.fc.test.controller.admin; import java.io.IOException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; + +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysDatasModel; +import com.fc.test.dao.model.SysFileModel; +import com.fc.test.dao.service.SysFileDataService; +import com.fc.test.model.custom.TableSplitResult; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.ui.ModelMap; import org.springframework.web.bind.annotation.GetMapping; @@ -20,239 +29,220 @@ import com.fc.test.common.base.BaseController; import com.fc.test.common.conf.V2Config; import com.fc.test.common.domain.AjaxResult; import com.fc.test.common.file.FileUtils; -import com.fc.test.model.auto.TsysDatas; -import com.fc.test.model.auto.TsysFile; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; import com.fc.test.util.StringUtils; -import com.github.pagehelper.PageInfo; /** * 文件上传controller - * @author fuce + * + * @author fuce * @date: 2018年9月16日 下午4:23:50 */ @Api(value = "文件上传") @Controller @RequestMapping("/FileController") -public class FileController extends BaseController{ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class FileController extends BaseController { + private final SysFileDataService sysFileDataService; + //跳转页面参数 + private String prefix = "admin/file"; - //跳转页面参数 - private String prefix = "admin/file"; - - /** - * 分页展示页面 - * @param model - * @return - * @author fuce - * @Date 2019年11月20日 下午10:18:32 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:file:view") - public String view(ModelMap model) - { - String str="上传图片"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); + /** + * 分页展示页面 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月20日 下午10:18:32 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:file:view") + public String view(ModelMap model) { + String str = "上传图片"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 文件列表 - * @param tablepar - * @param searchText 搜索字符 - * @return - */ - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:file:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysFileService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 新增文件跳转页面 - * @return - * @author fuce - * @Date 2019年11月20日 下午10:19:03 - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * 文件列表 + * + * @param tablepar + * @param searchText 搜索字符 + * @return + */ + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:file:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysFileService.listTablepar(tablepar,"file_name", searchText); + return new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + } + + /** + * 新增文件跳转页面 + * + * @return + * @author fuce + * @Date 2019年11月20日 下午10:19:03 + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add() - { + public String add() { return prefix + "/add"; } - - - + + /** * 文件上传 + * * @param file * @return * @author fuce * @Date 2019年11月20日 下午10:18:49 */ - //@Log(title = "文件上传", action = "1") - @ApiOperation(value = "文件上传", notes = "文件上传") + //@Log(title = "文件上传", action = "1") + @ApiOperation(value = "文件上传", notes = "文件上传") @PostMapping("/upload") @ResponseBody - public AjaxResult updateAvatar(@RequestParam("file") MultipartFile file) - { - try - { - if (!file.isEmpty()) - { + public AjaxResult updateAvatar(@RequestParam("file") MultipartFile file) { + try { + if (!file.isEmpty()) { //插入文件存储表 - String id=sysDatasService.insertSelective(file); - if(id!=null){ - return AjaxResult.successData(200, id); + String id = sysDatasService.insertSelective(file); + if (id != null) { + return AjaxResult.successData(200, id); } } return error(); - } - catch (Exception e) - { + } catch (Exception e) { return error(e.getMessage()); } } - + /** * 文件添加 + * * @param file * @return */ - //@Log(title = "文件添加", action = "1") - @ApiOperation(value = "文件添加", notes = "文件添加") - @PostMapping("/add") - @RequiresPermissions("system:file:add") - @ResponseBody - public AjaxResult add(TsysFile file,String dataId){ - if(StringUtils.isNotEmpty(dataId)) { - int b=sysFileService.insertSelective(file,dataId); - if(b>0){ - return success(); - } - } - return error("请上传文件"); - } - - /** - * 删除文件 - * @param ids - * @return - */ - //@Log(title = "删除文件", action = "1") - @ApiOperation(value = "删除文件", notes = "删除文件") - @PostMapping("/remove") - @RequiresPermissions("system:file:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysFileService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - - /** - * 删除本地文件 - * @param ids - * @return - */ - //@Log(title = "删除本地文件", action = "1") - @ApiOperation(value = "删除本地文件", notes = "删除本地文件") - @PostMapping("/del_file") - @ResponseBody - public AjaxResult del_file(String ids){ - int b=sysFileService.deleteBydataFile(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - - /** - * 检查文件名字 - * @param tsysFile - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(TsysFile tsysFile){ - int b=sysFileService.checkNameUnique(tsysFile); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改文件 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("tsysFile", sysFileService.selectByPrimaryKey(id)); + //@Log(title = "文件添加", action = "1") + @ApiOperation(value = "文件添加", notes = "文件添加") + @PostMapping("/add") + @RequiresPermissions("system:file:add") + @ResponseBody + public AjaxResult add(SysFileModel file, String dataId) { + if (StringUtils.isNotEmpty(dataId)) { + boolean insertSelective = sysFileService.insertSelective(file, dataId); + if (insertSelective) { + return success(); + } + } + return error("请上传文件"); + } + + /** + * 删除文件 + * + * @param ids + * @return + */ + //@Log(title = "删除文件", action = "1") + @ApiOperation(value = "删除文件", notes = "删除文件") + @PostMapping("/remove") + @RequiresPermissions("system:file:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysFileService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + + /** + * 删除本地文件 + * + * @param ids + * @return + */ + //@Log(title = "删除本地文件", action = "1") + @ApiOperation(value = "删除本地文件", notes = "删除本地文件") + @PostMapping("/del_file") + @ResponseBody + public AjaxResult del_file(String ids) { + return toAjax(sysFileService.deleteBydataFile(ids)); + } + + + /** + * 检查文件名字 + * + * @param tsysFile + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysFileModel tsysFile) { + return sysFileService.checkNameUnique("file_name", tsysFile.getFileName()); + } + + + /** + * 修改文件 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("tsysFile", sysFileService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存文件 */ - //@Log(title = "修改保存文件", action = "1") - @ApiOperation(value = "修改保存", notes = "修改保存") + //@Log(title = "修改保存文件", action = "1") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("system:user:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(TsysFile tsysFile,String dataId) - { - return toAjax(sysFileService.updateByPrimaryKey(tsysFile,dataId)); + public AjaxResult editSave(SysFileModel tsysFile, String dataId) { + return toAjax(sysFileService.updateByPrimaryKey(tsysFile, dataId)); } - + /** * 展示文件跳转页面 */ - @ApiOperation(value = "展示文件跳转页面", notes = "展示文件跳转页面") + @ApiOperation(value = "展示文件跳转页面", notes = "展示文件跳转页面") @GetMapping("/viewfile/{id}") - public String viewfile(@PathVariable("id") String id,ModelMap mmap){ - if("Y".equals(V2Config.getIsstatic())) {//为静态目录存放的时候 - mmap.put("is_static","Y"); - }else {//为自定义存放目录的时候 - mmap.put("is_static","N"); - } - mmap.put("tsysDatas",sysFileDatasService.queryfileID(id)); + public String viewfile(@PathVariable("id") String id, ModelMap mmap) { + if ("Y".equals(V2Config.getIsstatic())) {//为静态目录存放的时候 + mmap.put("is_static", "Y"); + } else {//为自定义存放目录的时候 + mmap.put("is_static", "N"); + } + mmap.put("tsysDatas", sysFileDataService.queryfileID(id)); return prefix + "/viewfile"; } - + /** * 此功能为application.yml 下面的isstatic为N 时候需要的 * 逻辑为:根据数据库文件存放地址,读取图片流放入到里面展示 */ - @ApiOperation(value = "展示文件跳转页面", notes = "展示文件跳转页面") + @ApiOperation(value = "展示文件跳转页面", notes = "展示文件跳转页面") @GetMapping("/viewImg/{id}") - public void viewIMG(@PathVariable("id") String id,HttpServletRequest request,HttpServletResponse response){ - TsysDatas datas= sysDatasService.selectByPrimaryKey(id); - try { - FileUtils.readIMGTohtml(request, response, datas.getFilePath()); - } catch (IOException e) { - e.printStackTrace(); - } + public void viewIMG(@PathVariable("id") String id, HttpServletRequest request, HttpServletResponse response) { + SysDatasModel datas = sysDatasService.getById(id); + try { + FileUtils.readIMGTohtml(request, response, datas.getFilePath()); + } catch (IOException e) { + e.printStackTrace(); + } } - - + + } diff --git a/src/main/java/com/fc/test/controller/admin/LogController.java b/src/main/java/com/fc/test/controller/admin/LogController.java index fea26838db0f9f9d859d70487ab45433ff645af4..f2a59b90064a054f4f5eae12e28f19f2b4080b53 100644 --- a/src/main/java/com/fc/test/controller/admin/LogController.java +++ b/src/main/java/com/fc/test/controller/admin/LogController.java @@ -1,6 +1,11 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysOperLogModel; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @@ -13,79 +18,71 @@ import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.TsysOperLog; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.github.pagehelper.PageInfo; /** * 日志记录controller - * @author fuce + * + * @author fuce * @date: 2018年9月30日 下午9:28:31 */ @Controller @Api(value = "日志记录") @RequestMapping("/LogController") -public class LogController extends BaseController{ +public class LogController extends BaseController { + + //跳转页面参数 + private String prefix = "admin/log"; + + /** + * 日志记录展示页面 + * + * @param model + * @return + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:log:view") + public String view(ModelMap model) { + String str = "操作日志"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); - //跳转页面参数 - private String prefix = "admin/log"; - - /** - * 日志记录展示页面 - * @param model - * @return - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:log:view") - public String view(ModelMap model) - { - String str="操作日志"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); - return prefix + "/list"; } - - /** - * 文件列表 - * @param tablepar - * @param searchText 搜索字符 - * @return - */ - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:log:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysOperLogService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 删除日志 - * @param ids - * @return - */ - //@Log(title = "删除日志", action = "1") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("system:log:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysOperLogService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - + /** + * 文件列表 + * + * @param tablepar + * @param searchText 搜索字符 + * @return + */ + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:log:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysOperLogService.listTablepar(tablepar, "title", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + + /** + * 删除日志 + * + * @param ids + * @return + */ + //@Log(title = "删除日志", action = "1") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("system:log:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysOperLogService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + - - } diff --git a/src/main/java/com/fc/test/controller/admin/PermissionController.java b/src/main/java/com/fc/test/controller/admin/PermissionController.java index 8a5637629e7bdf75a1f8c697f0fb8b49b4fae055..9127344cee8d875f718d9a9c23f9f8991f428d99 100644 --- a/src/main/java/com/fc/test/controller/admin/PermissionController.java +++ b/src/main/java/com/fc/test/controller/admin/PermissionController.java @@ -3,12 +3,12 @@ package com.fc.test.controller.admin; import java.util.List; import com.fc.test.common.base.BaseController; +import com.fc.test.common.base.PageInfo; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.TsysPermission; +import com.fc.test.dao.model.SysPermissionModel; import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.github.pagehelper.PageInfo; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @@ -23,246 +23,241 @@ import org.springframework.web.bind.annotation.ResponseBody; /** * 权限Controller - * @author fuce + * + * @author fuce * @date: 2018年9月2日 下午8:08:21 */ @Api(value = "权限") @Controller @RequestMapping("/PermissionController") -public class PermissionController extends BaseController{ - - //跳转页面参数 - private String prefix = "admin/permission"; - - /** - * 权限列表展示 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午3:43:51 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:permission:view") - public String view(ModelMap model) - { - String str="权限"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); + +public class PermissionController extends BaseController { + + //跳转页面参数 + private String prefix = "admin/permission"; + + /** + * 权限列表展示 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午3:43:51 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:permission:view") + public String view(ModelMap model) { + String str = "权限"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 权限列表 - * @param tablepar - * @param searchText 搜索字符 - * @return - */ - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:permission:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page= sysPermissionService.list(tablepar, searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - /** - * 权限列表 - * @param tablepar - * @param searchText 搜索字符 - * @return - */ - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list2") - @ResponseBody - public Object list2(Tablepar tablepar,String searchText){ - List page= sysPermissionService.list2(searchText) ; - return page; - } - /** + + /** + * 权限列表 + * + * @param tablepar + * @param searchText 搜索字符 + * @return + */ + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:permission:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysPermissionService.listTablepar(tablepar, "name", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** + * 权限列表 + * + * @param tablepar + * @param searchText 搜索字符 + * @return + */ + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list2") + @ResponseBody + public Object list2(Tablepar tablepar, String searchText) { + List page = sysPermissionService.list2(searchText); + return page; + } + + /** * 新增权限 */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add() - { + public String add() { return prefix + "/add"; } - - + + /** * 权限添加 + * * @param role * @return */ - //@Log(title = "权限添加", action = "1") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("system:permission:add") - @ResponseBody - public AjaxResult add(TsysPermission role){ - int b= sysPermissionService.insertSelective(role); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除权限 - * @param ids - * @return - */ - //@Log(title = "删除权限", action = "1") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("system:permission:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b= sysPermissionService.deleteByPrimaryKey(ids); - if(b==1){ - return success(); - }else if(b==-1){ - return error("该权限有子权限,请先删除子权限"); - }else if(b==-2){ - return error("该权限绑定了角色,请解除角色绑定"); - }else { - return error(); - } - } - - /** - * 检查权限 - * @param TsysPermission - * @return - */ - @ApiOperation(value = "检查权限", notes = "检查权限") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(TsysPermission TsysPermission){ - int b= sysPermissionService.checkNameUnique(TsysPermission); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - /** - * 检查权限URL - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查权限URL", notes = "检查权限URL") - @PostMapping("/checkURLUnique") - @ResponseBody - public int checkURLUnique(TsysPermission tsysPermission){ - int b= sysPermissionService.checkURLUnique(tsysPermission); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - /** - * 检查权限perms字段 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查权限perms字段", notes = "检查权限perms字段") - @PostMapping("/checkPermsUnique") - @ResponseBody - public int checkPermsUnique(TsysPermission tsysPermission){ - int b= sysPermissionService.checkPermsUnique(tsysPermission); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - /** - * 修改权限 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{roleId}") - public String edit(@PathVariable("roleId") String id, ModelMap mmap) - { - //获取自己的权限信息 - TsysPermission mytsysPermission = sysPermissionService.selectByPrimaryKey(id); - //获取父权限信息 - TsysPermission pattsysPermission = sysPermissionService.selectByPrimaryKey(mytsysPermission.getPid()); + //@Log(title = "权限添加", action = "1") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("system:permission:add") + @ResponseBody + public AjaxResult add(SysPermissionModel role) { + return toAjax(sysPermissionService.save(role)); + } + + /** + * 删除权限 + * + * @param ids + * @return + */ + //@Log(title = "删除权限", action = "1") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("system:permission:remove") + @ResponseBody + public AjaxResult remove(String ids) { + int b = sysPermissionService.deleteByPrimaryKey(ids); + if (b == 1) { + return success(); + } else if (b == -1) { + return error("该权限有子权限,请先删除子权限"); + } else if (b == -2) { + return error("该权限绑定了角色,请解除角色绑定"); + } else { + return error(); + } + } + + /** + * 检查权限 + * + * @param TsysPermission + * @return + */ + @ApiOperation(value = "检查权限", notes = "检查权限") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysPermissionModel TsysPermission) { + int b = sysPermissionService.checkNameUnique("name", TsysPermission.getName()); + return b > 0 ? 1 : 0; + } + + /** + * 检查权限URL + * + * @param tsysPermission + * @return + */ + @ApiOperation(value = "检查权限URL", notes = "检查权限URL") + @PostMapping("/checkURLUnique") + @ResponseBody + public int checkURLUnique(SysPermissionModel tsysPermission) { + return sysPermissionService.checkNameUnique("url", tsysPermission.getUrl()); + } + + /** + * 检查权限perms字段 + * + * @param sysPermissionModel + * @return + */ + @ApiOperation(value = "检查权限perms字段", notes = "检查权限perms字段") + @PostMapping("/checkPermsUnique") + @ResponseBody + public int checkPermsUnique(SysPermissionModel sysPermissionModel) { + int b = sysPermissionService.checkNameUnique("perms", sysPermissionModel.getPerms()); + return b > 0 ? 1 : 0; + } + + /** + * 修改权限 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{roleId}") + public String edit(@PathVariable("roleId") String id, ModelMap mmap) { + //获取自己的权限信息 + SysPermissionModel mytsysPermission = sysPermissionService.getById(id); + //获取父权限信息 + SysPermissionModel pattsysPermission = sysPermissionService.getById(mytsysPermission.getPid()); mmap.put("TsysPermission", mytsysPermission); mmap.put("pattsysPermission", pattsysPermission); return prefix + "/edit"; } - - /** + + /** * 修改保存权限 */ - //@Log(title = "修改保存权限", action = "1") - @ApiOperation(value = "修改保存", notes = "修改保存") + //@Log(title = "修改保存权限", action = "1") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("system:permission:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(TsysPermission TsysPermission) - { - return toAjax(sysPermissionService.updateByPrimaryKey(TsysPermission)); + public AjaxResult editSave(SysPermissionModel TsysPermission) { + return toAjax(sysPermissionService.updateById(TsysPermission)); } - + /** * 获取所有的转换成bootstarp的权限数据 + * * @return */ - @ApiOperation(value = "获取所有的转换成bootstarp的权限数据", notes = "获取所有的转换成bootstarp的权限数据") + @ApiOperation(value = "获取所有的转换成bootstarp的权限数据", notes = "获取所有的转换成bootstarp的权限数据") @GetMapping("/getTreePerm") @ResponseBody - public AjaxResult getbooBootstrapTreePerm(){ - - return retobject(200, sysPermissionService.getbooBootstrapTreePerm(null)); + public AjaxResult getbooBootstrapTreePerm() { + + return retobject(200, sysPermissionService.getbooBootstrapTreePerm(null)); } - - + + /** * 根据角色id获取bootstarp 所有打勾权限 + * * @param roleId 角色id集合 * @return */ - @ApiOperation(value = "根据角色id获取bootstarp 所有打勾权限", notes = "根据角色id获取bootstarp 所有打勾权限") + @ApiOperation(value = "根据角色id获取bootstarp 所有打勾权限", notes = "根据角色id获取bootstarp 所有打勾权限") @PostMapping("/getCheckPrem") @ResponseBody - public AjaxResult getCheckPrem(String roleId){ - - return retobject(200, sysPermissionService.getCheckPrem(roleId)); + public AjaxResult getCheckPrem(String roleId) { + + return retobject(200, sysPermissionService.getCheckPrem(roleId)); } - - + + /** * 跳转到菜单树页面 + * * @return */ - @ApiOperation(value = "跳转到菜单树页面", notes = "跳转到菜单树页面") + @ApiOperation(value = "跳转到菜单树页面", notes = "跳转到菜单树页面") @GetMapping("/tree") - public String Tree(){ - return prefix + "/tree"; + public String Tree() { + return prefix + "/tree"; } - + /** * 获取菜单树 + * * @param pid 父id【没用到】 * @return */ - @ApiOperation(value = "获取菜单树", notes = "获取菜单树") + @ApiOperation(value = "获取菜单树", notes = "获取菜单树") @PostMapping("/tree/{pid}") @ResponseBody - public AjaxResult Tree(@PathVariable("pid") String pid){ - return retobject(200, sysPermissionService.getbooBootstrapTreePerm(null)); + public AjaxResult Tree(@PathVariable("pid") String pid) { + return retobject(200, sysPermissionService.getbooBootstrapTreePerm(null)); } - - + + } diff --git a/src/main/java/com/fc/test/controller/admin/ProvinceLinkageController.java b/src/main/java/com/fc/test/controller/admin/ProvinceLinkageController.java index 68553b62682f0a811d853ed0ce7702c5354d9ffd..e32e6dcbe406a7f0e05c893ea19a53863ade437a 100644 --- a/src/main/java/com/fc/test/controller/admin/ProvinceLinkageController.java +++ b/src/main/java/com/fc/test/controller/admin/ProvinceLinkageController.java @@ -1,112 +1,102 @@ package com.fc.test.controller.admin; -import java.util.List; +import com.fc.test.common.base.BaseController; +import com.fc.test.dao.model.SysAreaModel; +import com.fc.test.dao.model.SysCityModel; +import com.fc.test.dao.model.SysStreetModel; +import com.fc.test.dao.service.SysAreaService; +import com.fc.test.dao.service.SysCityService; +import com.fc.test.dao.service.SysProvinceService; +import com.fc.test.dao.service.SysStreetService; +import com.fc.test.model.custom.TitleVo; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.ui.ModelMap; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.fc.test.common.base.BaseController; -import com.fc.test.model.auto.SysArea; -import com.fc.test.model.auto.SysAreaExample; -import com.fc.test.model.auto.SysCity; -import com.fc.test.model.auto.SysCityExample; -import com.fc.test.model.auto.SysProvinceExample; -import com.fc.test.model.auto.SysStreet; -import com.fc.test.model.auto.SysStreetExample; -import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysAreaService; -import com.fc.test.service.SysCityService; -import com.fc.test.service.SysProvinceService; -import com.fc.test.service.SysStreetService; -import io.swagger.annotations.Api; -import io.swagger.annotations.ApiOperation; +import java.util.List; /** * 省份联动controller - * @ClassName: ProvinceLinkageController + * * @author fuce + * @ClassName: ProvinceLinkageController * @date 2019-10-05 11:19 */ @Api(value = "省份联动controller") @Controller @RequestMapping("/ProvinceLinkageController") -public class ProvinceLinkageController extends BaseController{ - @Autowired - private SysProvinceService sysProvinceService; - @Autowired - private SysCityService sysCityService; - @Autowired - private SysAreaService sysAreaService; - - @Autowired - private SysStreetService sysStreetService; - - private String prefix = "admin/province"; - - /** - * 分页list页面 - * @param model - * @param dictId - * @return - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - public String view(ModelMap model) - { - String str="省份联动"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); - model.addAttribute("provinceList",sysProvinceService.selectByExample(new SysProvinceExample())); +public class ProvinceLinkageController extends BaseController { + @Autowired + private SysProvinceService sysProvinceService; + @Autowired + private SysCityService sysCityService; + @Autowired + private SysAreaService sysAreaService; + @Autowired + private SysStreetService sysStreetService; + + private String prefix = "admin/province"; + + /** + * 分页list页面 + * + * @param model + * @return + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + public String view(ModelMap model) { + String str = "省份联动"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); + model.addAttribute("provinceList", sysProvinceService.list()); return prefix + "/list"; } - - /** - * 市查询 - * @param pid - * @return - */ - @ApiOperation(value = "市查询", notes = "市查询") - @GetMapping("/getCity") - @ResponseBody - public List getCity(String pid){ - SysCityExample example=new SysCityExample(); - example.createCriteria().andProvinceCodeEqualTo(pid); - return sysCityService.selectByExample(example); - - } - - /** - * 区查询 - * TODO(请说明这个方法的作用). - * @param pid - * @return - */ - @ApiOperation(value = "区查询", notes = "区查询") - @GetMapping("/getArea") - @ResponseBody - public List getArea(String pid){ - SysAreaExample example=new SysAreaExample(); - example.createCriteria().andCityCodeEqualTo(pid); - return sysAreaService.selectByExample(example); - - } - - /** - * 街道查询 - * @param pid - * @return - */ - @ApiOperation(value = "街道查询", notes = "街道查询") - @GetMapping("/getStreet") - @ResponseBody - public List getStreet(String pid){ - SysStreetExample example=new SysStreetExample(); - example.createCriteria().andAreaCodeEqualTo(pid); - return sysStreetService.selectByExample(example); - - } - - + + /** + * 市查询 + * + * @param pid + * @return + */ + @ApiOperation(value = "市查询", notes = "市查询") + @GetMapping("/getCity") + @ResponseBody + public List getCity(String pid) { + return sysCityService.lambdaQuery().eq(SysCityModel::getProvinceCode, pid).list(); + } + + /** + * 区查询 + * TODO(请说明这个方法的作用). + * + * @param pid + * @return + */ + @ApiOperation(value = "区查询", notes = "区查询") + @GetMapping("/getArea") + @ResponseBody + public List getArea(String pid) { + return sysAreaService.getByCityCode(pid); + + } + + /** + * 街道查询 + * + * @param pid + * @return + */ + @ApiOperation(value = "街道查询", notes = "街道查询") + @GetMapping("/getStreet") + @ResponseBody + public List getStreet(String pid) { + return sysStreetService.lambdaQuery().eq(SysStreetModel::getAreaCode,pid).list(); + } + + } diff --git a/src/main/java/com/fc/test/controller/admin/QuartzJobController.java b/src/main/java/com/fc/test/controller/admin/QuartzJobController.java index 6569ea1e30606cee7c49619d11119679c8541f73..381504cc4067d0059c4664aa913b4392139285a3 100644 --- a/src/main/java/com/fc/test/controller/admin/QuartzJobController.java +++ b/src/main/java/com/fc/test/controller/admin/QuartzJobController.java @@ -1,5 +1,11 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysQuartzJobModel; +import com.fc.test.dao.service.SysQuartzJobService; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.quartz.SchedulerException; import org.springframework.beans.factory.annotation.Autowired; @@ -10,190 +16,173 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysQuartzJob; import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysQuartzJobService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** - * -* @ClassName: QuartzJobController -* @author Jan 橙寂 -* @date 2019-11-20 22:49 + * @author Jan 橙寂 + * @ClassName: QuartzJobController + * @date 2019-11-20 22:49 */ @Api(value = "定时任务调度表") @Controller @RequestMapping("/SysQuartzJobController") -public class QuartzJobController extends BaseController{ - - private String prefix = "admin/sysQuartzJob"; - @Autowired - private SysQuartzJobService sysQuartzJobService; - - /** - * 展示页面 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午3:55:01 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysQuartzJob:view") - public String view(ModelMap model) - { - String str="定时任务调度表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class QuartzJobController extends BaseController { + + private String prefix = "admin/sysQuartzJob"; + private final SysQuartzJobService sysQuartzJobService; + + /** + * 展示页面 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午3:55:01 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysQuartzJob:view") + public String view(ModelMap model) { + String str = "定时任务调度表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - /** - * 定时任务调度list - * @param tablepar - * @param searchText - * @return - */ - //@Log(title = "定时任务调度表集合查询", action = "111") - @ApiOperation(value = "定时任务调度list", notes = "定时任务调度list") - @PostMapping("/list") - @RequiresPermissions("gen:sysQuartzJob:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysQuartzJobService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 新增跳转页面 - * @param modelMap - * @return - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * 定时任务调度list + * + * @param tablepar + * @param searchText + * @return + */ + //@Log(title = "定时任务调度表集合查询", action = "111") + @ApiOperation(value = "定时任务调度list", notes = "定时任务调度list") + @PostMapping("/list") + @RequiresPermissions("gen:sysQuartzJob:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysQuartzJobService.listTablepar(tablepar, "job_name", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** + * 新增跳转页面 + * + * @param modelMap + * @return + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - + /** * 新增保存 + * * @param sysQuartzJob * @return * @author fuce * @Date 2019年11月11日 下午4:00:08 */ - //@Log(title = "定时任务调度表新增", action = "111") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysQuartzJob:add") - @ResponseBody - public AjaxResult add(SysQuartzJob sysQuartzJob){ - int b=sysQuartzJobService.insertSelective(sysQuartzJob); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除 - * @param ids - * @return - */ - //@Log(title = "定时任务调度表删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysQuartzJob:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysQuartzJobService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysQuartzJob sysQuartzJob){ - int b=sysQuartzJobService.checkNameUnique(sysQuartzJob); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("SysQuartzJob", sysQuartzJobService.selectByPrimaryKey(id)); + //@Log(title = "定时任务调度表新增", action = "111") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("gen:sysQuartzJob:add") + @ResponseBody + public AjaxResult add(SysQuartzJobModel sysQuartzJob) { + return toAjax(sysQuartzJobService.save(sysQuartzJob)); + } + + /** + * 删除 + * + * @param ids + * @return + */ + //@Log(title = "定时任务调度表删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysQuartzJob:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysQuartzJobService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查 + * + * @param sysQuartzJob + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysQuartzJobModel sysQuartzJob) { + int b = sysQuartzJobService.checkNameUnique("job_name", sysQuartzJob.getJobName()); + return b > 0 ? 1 : 0; + } + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("SysQuartzJob", sysQuartzJobService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "定时任务调度表修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysQuartzJob:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysQuartzJob record) - { - return toAjax(sysQuartzJobService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysQuartzJobModel record) { + return toAjax(sysQuartzJobService.updateById(record)); } /** * 任务调度状态修改 */ - //@Log(title = "任务调度状态修改", action = "1") - @ApiOperation(value = "任务调度状态修改", notes = "任务调度状态修改") + //@Log(title = "任务调度状态修改", action = "1") + @ApiOperation(value = "任务调度状态修改", notes = "任务调度状态修改") @PostMapping("/changeStatus") @ResponseBody - public AjaxResult changeStatus(SysQuartzJob job) throws SchedulerException - { - SysQuartzJob newJob = sysQuartzJobService.selectByPrimaryKey(job.getId()); + public AjaxResult changeStatus(SysQuartzJobModel job) throws SchedulerException { + SysQuartzJobModel newJob = sysQuartzJobService.getById(job.getId()); newJob.setStatus(job.getStatus()); return toAjax(sysQuartzJobService.changeStatus(newJob)); } - + /** * 任务调度立即执行一次 */ - //@Log(title = "任务调度立即执行一次", action = "1") - @ApiOperation(value = "任务调度立即执行一次", notes = "任务调度立即执行一次") + //@Log(title = "任务调度立即执行一次", action = "1") + @ApiOperation(value = "任务调度立即执行一次", notes = "任务调度立即执行一次") @PostMapping("/run") @ResponseBody - public AjaxResult run(SysQuartzJob job) throws SchedulerException - { - SysQuartzJob newJob = sysQuartzJobService.selectByPrimaryKey(job.getId()); - sysQuartzJobService.run(newJob); + public AjaxResult run(SysQuartzJobModel job) throws SchedulerException { + SysQuartzJobModel newJob = sysQuartzJobService.getById(job.getId()); + sysQuartzJobService.run(newJob); return success(); } - + } diff --git a/src/main/java/com/fc/test/controller/admin/QuartzJobLogController.java b/src/main/java/com/fc/test/controller/admin/QuartzJobLogController.java index e9c03954b79ebc1b3cfbe77fea1ae682e84e0e3a..ce84bc02a6c0d9b56b0f7d89752bb92aecf3b922 100644 --- a/src/main/java/com/fc/test/controller/admin/QuartzJobLogController.java +++ b/src/main/java/com/fc/test/controller/admin/QuartzJobLogController.java @@ -1,5 +1,12 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysQuartzJobLogModel; +import com.fc.test.dao.service.SysQuartzJobLogService; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -9,108 +16,99 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysQuartzJobLog; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysQuartzJobLogService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 定时任务日志Controller -* @ClassName: QuartzJobLogController -* @author fuce -* @date 2019-11-20 22:51 + * + * @author fuce + * @ClassName: QuartzJobLogController + * @date 2019-11-20 22:51 */ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) @Api(value = "定时任务调度日志表") @Controller @RequestMapping("/SysQuartzJobLogController") -public class QuartzJobLogController extends BaseController{ - - private String prefix = "admin/sysQuartzJobLog"; - @Autowired - private SysQuartzJobLogService sysQuartzJobLogService; - - /** - * 展示跳转页面 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午4:01:13 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysQuartzJobLog:view") - public String view(ModelMap model) - { - String str="定时任务调度日志表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +public class QuartzJobLogController extends BaseController { + private final SysQuartzJobLogService sysQuartzJobLogService; + + private String prefix = "admin/sysQuartzJobLog"; + + /** + * 展示跳转页面 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午4:01:13 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysQuartzJobLog:view") + public String view(ModelMap model) { + String str = "定时任务调度日志表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 定时任务调度日志list - * @param tablepar - * @param searchText - * @return - * @author fuce - * @Date 2019年11月11日 下午4:01:26 - */ - //@Log(title = "定时任务调度日志表集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysQuartzJobLog:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysQuartzJobLogService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 查看详情 - * @param modelMap - * @return - * @author fuce - * @Date 2019年9月14日 下午11:50:42 - */ - @ApiOperation(value = "查看详情", notes = "查看详情") - @GetMapping("/detail/{id}") - public String detail(@PathVariable("id") String id,ModelMap modelMap) - { - SysQuartzJobLog log= sysQuartzJobLogService.selectByPrimaryKey(id); - modelMap.put("SysQuartzJobLog", log); + + /** + * 定时任务调度日志list + * + * @param tablepar + * @param searchText + * @return + * @author fuce + * @Date 2019年11月11日 下午4:01:26 + */ + //@Log(title = "定时任务调度日志表集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysQuartzJobLog:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysQuartzJobLogService.listTablepar(tablepar, "job_name", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** + * 查看详情 + * + * @param modelMap + * @return + * @author fuce + * @Date 2019年9月14日 下午11:50:42 + */ + @ApiOperation(value = "查看详情", notes = "查看详情") + @GetMapping("/detail/{id}") + public String detail(@PathVariable("id") String id, ModelMap modelMap) { + SysQuartzJobLogModel log = sysQuartzJobLogService.getById(id); + modelMap.put("SysQuartzJobLog", log); return prefix + "/detail"; - } - + } + + + /** + * 定时任务日志删除 + * + * @param ids id集合 + * @return + * @author fuce + * @Date 2019年11月20日 下午10:51:52 + */ + //@Log(title = "定时任务调度日志表删除", action = "111") + @ApiOperation(value = "定时任务日志删除", notes = "定时任务日志删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysQuartzJobLog:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysQuartzJobLogService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } - - /** - * 定时任务日志删除 - * @param ids id集合 - * @return - * @author fuce - * @Date 2019年11月20日 下午10:51:52 - */ - //@Log(title = "定时任务调度日志表删除", action = "111") - @ApiOperation(value = "定时任务日志删除", notes = "定时任务日志删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysQuartzJobLog:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysQuartzJobLogService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - - } diff --git a/src/main/java/com/fc/test/controller/admin/RoleController.java b/src/main/java/com/fc/test/controller/admin/RoleController.java index d33276a18b981067c79ffed1d49fb8b353e53f5f..5e2f4c5c008b7ad8bb4548413ede7b52b91acdab 100644 --- a/src/main/java/com/fc/test/controller/admin/RoleController.java +++ b/src/main/java/com/fc/test/controller/admin/RoleController.java @@ -1,15 +1,18 @@ package com.fc.test.controller.admin; import javax.servlet.http.HttpServletRequest; + +import com.baomidou.mybatisplus.core.toolkit.StringPool; import com.fc.test.common.base.BaseController; +import com.fc.test.common.base.PageInfo; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.TsysRole; +import com.fc.test.dao.model.SysRoleModel; import com.fc.test.model.custom.BootstrapTree; import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; import com.fc.test.shiro.util.ShiroUtils; -import com.github.pagehelper.PageInfo; +import com.fc.test.util.StringUtils; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @@ -25,151 +28,138 @@ import org.springframework.web.bind.annotation.ResponseBody; /** * 角色Controller - * @author fuce + * + * @author fuce * @date: 2018年9月2日 下午8:08:21 */ @Api(value = "用户角色") @Controller @RequestMapping("/RoleController") -public class RoleController extends BaseController{ - - - //跳转页面参数 - private String prefix = "admin/role"; - - /** - * 展示页面 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午4:01:58 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:role:view") - public String view(ModelMap model) - { - String str="角色"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +public class RoleController extends BaseController { + + + //跳转页面参数 + private String prefix = "admin/role"; + + /** + * 展示页面 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午4:01:58 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:role:view") + public String view(ModelMap model) { + String str = "角色"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 角色列表 - * @param tablepar - * @param searchText 搜索字符 - * @return - */ - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:user:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysRoleService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** + + /** + * 角色列表 + * + * @param tablepar + * @param searchText 搜索字符 + * @return + */ + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:user:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysRoleService.listTablepar(tablepar, "name", searchText); + return new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + } + + /** * 新增角色 */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add() - { + public String add() { return prefix + "/add"; } - - + + /** * 角色添加 + * * @param role * @return */ - //@Log(title = "角色添加", action = "1") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("system:user:add") - @ResponseBody - public AjaxResult add(TsysRole role,String prem){ - int b=sysRoleService.insertRoleAndPrem(role,prem); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除角色 - * @param ids - * @return - */ - //@Log(title = "删除角色", action = "1") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("system:user:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysRoleService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查角色 - * @param TsysRole - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(TsysRole tsysRole){ - int b=sysRoleService.checkNameUnique(tsysRole); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改角色 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{roleId}") - public String edit(@PathVariable("roleId") String id, ModelMap mmap) - { - mmap.put("TsysRole", sysRoleService.selectByPrimaryKey(id)); + //@Log(title = "角色添加", action = "1") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("system:user:add") + @ResponseBody + public AjaxResult add(SysRoleModel role, String prem) { + return toAjax(sysRoleService.insertRoleAndPrem(role, prem)); + } + + /** + * 删除角色 + * + * @param ids + * @return + */ + //@Log(title = "删除角色", action = "1") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("system:user:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysRoleService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查角色 + * + * @param tsysRole + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysRoleModel tsysRole) { + int b = sysRoleService.checkNameUnique("name", tsysRole.getName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改角色 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{roleId}") + public String edit(@PathVariable("roleId") String id, ModelMap mmap) { + mmap.put("TsysRole", sysRoleService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存角色 */ - //@Log(title = "修改保存角色", action = "1") - @ApiOperation(value = "修改保存", notes = "修改保存") + //@Log(title = "修改保存角色", action = "1") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("system:user:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(TsysRole tsysRole,String prem,HttpServletRequest request) - { - int i=sysRoleService.updateRoleAndPrem(tsysRole,prem); - if(i>0) { - //大于0刷新权限 - ShiroUtils.clearCachedAuthorizationInfo(); - //获取菜单栏 - BootstrapTree bootstrapTree= sysPermissionService.getbooBootstrapTreePerm(ShiroUtils.getUserId()); - request.getSession().setAttribute("bootstrapTree", bootstrapTree); - } - - return toAjax(i); + public AjaxResult editSave(SysRoleModel tsysRole, String prem, HttpServletRequest request) { + boolean updateRoleAndPrem = sysRoleService.updateRoleAndPrem(tsysRole, prem); + if (updateRoleAndPrem) { + //大于0刷新权限 + ShiroUtils.clearCachedAuthorizationInfo(); + //获取菜单栏 + BootstrapTree bootstrapTree = sysPermissionService.getbooBootstrapTreePerm(ShiroUtils.getUserId()); + request.getSession().setAttribute("bootstrapTree", bootstrapTree); + } + return toAjax(updateRoleAndPrem); } } diff --git a/src/main/java/com/fc/test/controller/admin/SysAreaController.java b/src/main/java/com/fc/test/controller/admin/SysAreaController.java index 877f89da424d6b84019a76251805f266bc6afa8a..44eccf0f1386bd5cc0d17f42c7e21013178e0a5e 100644 --- a/src/main/java/com/fc/test/controller/admin/SysAreaController.java +++ b/src/main/java/com/fc/test/controller/admin/SysAreaController.java @@ -1,5 +1,12 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysAreaModel; +import com.fc.test.dao.service.SysAreaService; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -9,166 +16,147 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysArea; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysAreaService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 地区Controller - * @ClassName: SysAreaController + * * @author fuce + * @ClassName: SysAreaController * @date 2019-11-20 22:34 */ @Api(value = "地区设置") @Controller @RequestMapping("/SysAreaController") -public class SysAreaController extends BaseController{ - - private String prefix = "admin/province/sysArea"; - @Autowired - private SysAreaService sysAreaService; - - /** - * 地区页面展示 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午4:05:04 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysArea:view") - public String view(ModelMap model) - { - String str="地区设置"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysAreaController extends BaseController { + + private String prefix = "admin/province/sysArea"; + private final SysAreaService sysAreaService; + + /** + * 地区页面展示 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午4:05:04 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysArea:view") + public String view(ModelMap model) { + String str = "地区设置"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * list集合 - * @param tablepar - * @param searchText - * @return - * @author fuce - * @Date 2019年11月11日 下午4:04:53 - */ - //@Log(title = "地区设置集合查询", action = "111") - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @PostMapping("/list") - @RequiresPermissions("gen:sysArea:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysAreaService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** + + /** + * list集合 + * + * @param tablepar + * @param searchText + * @return + * @author fuce + * @Date 2019年11月11日 下午4:04:53 + */ + //@Log(title = "地区设置集合查询", action = "111") + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @PostMapping("/list") + @RequiresPermissions("gen:sysArea:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysAreaService.listTablepar(tablepar, "area_name", searchText); + return new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + } + + /** * 新增跳转 */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - + /** * 新增保存 + * * @param sysArea * @return * @author fuce * @Date 2019年11月11日 下午4:04:41 */ - //@Log(title = "地区设置新增", action = "111") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysArea:add") - @ResponseBody - public AjaxResult add(SysArea sysArea){ - int b=sysAreaService.insertSelective(sysArea); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 地区设置删除 - * @param ids - * @return - */ - //@Log(title = "地区设置删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysArea:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysAreaService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查 - * @param SysArea - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysArea sysArea){ - int b=sysAreaService.checkNameUnique(sysArea); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") Integer id, ModelMap mmap) - { - mmap.put("SysArea", sysAreaService.selectByPrimaryKey(id)); + //@Log(title = "地区设置新增", action = "111") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("gen:sysArea:add") + @ResponseBody + public AjaxResult add(SysAreaModel sysArea) { + return toAjax(sysAreaService.save(sysArea)); + } + + /** + * 地区设置删除 + * + * @param ids + * @return + */ + //@Log(title = "地区设置删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysArea:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysAreaService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查 + * + * @param sysArea + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysAreaModel sysArea) { + int b = sysAreaService.checkNameUnique("area_name", sysArea.getAreaName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Integer id, ModelMap mmap) { + mmap.put("SysArea", sysAreaService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "地区设置修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysArea:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysArea record) - { - return toAjax(sysAreaService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysAreaModel record) { + return toAjax(sysAreaService.updateById(record)); } - - - } diff --git a/src/main/java/com/fc/test/controller/admin/SysCityController.java b/src/main/java/com/fc/test/controller/admin/SysCityController.java index 7b5c09e03d37a459ff3e70e737407b0ee534c5c9..7e6f7056e7ae750d3252839bc6b5770ee032c794 100644 --- a/src/main/java/com/fc/test/controller/admin/SysCityController.java +++ b/src/main/java/com/fc/test/controller/admin/SysCityController.java @@ -1,5 +1,11 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysCityModel; +import com.fc.test.dao.service.SysCityService; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -9,162 +15,146 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysCity; import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysCityService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 城市Controller - * @ClassName: SysCityController + * * @author fuce + * @ClassName: SysCityController * @date 2019-11-20 22:31 */ @Api(value = "城市设置") @Controller @RequestMapping("/SysCityController") -public class SysCityController extends BaseController{ - - private String prefix = "admin/province/sysCity"; - @Autowired - private SysCityService sysCityService; - - /** - * 城市设置展示跳转 - * - * @param model - * @return - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysCity:view") - public String view(ModelMap model) - { - String str="城市设置"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysCityController extends BaseController { + + private String prefix = "admin/province/sysCity"; + private final SysCityService sysCityService; + + /** + * 城市设置展示跳转 + * + * @param model + * @return + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysCity:view") + public String view(ModelMap model) { + String str = "城市设置"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 城市设置list - * @param tablepar - * @param searchText - * @return - */ - //@Log(title = "城市设置集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysCity:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysCityService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 新增跳转 - * @param modelMap - * @return - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * 城市设置list + * + * @param tablepar + * @param searchText + * @return + */ + //@Log(title = "城市设置集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysCity:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysCityService.listTablepar(tablepar, "city_name", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** + * 新增跳转 + * + * @param modelMap + * @return + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - /** - * 新增保存 - * @param sysCity - * @return - */ - //@Log(title = "城市设置新增", action = "111") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysCity:add") - @ResponseBody - public AjaxResult add(SysCity sysCity){ - int b=sysCityService.insertSelective(sysCity); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除 - * @param ids - * @return - */ - //@Log(title = "城市设置删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysCity:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysCityService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysCity sysCity){ - int b=sysCityService.checkNameUnique(sysCity); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") Integer id, ModelMap mmap) - { - mmap.put("SysCity", sysCityService.selectByPrimaryKey(id)); + + /** + * 新增保存 + * + * @param sysCity + * @return + */ + //@Log(title = "城市设置新增", action = "111") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("gen:sysCity:add") + @ResponseBody + public AjaxResult add(SysCityModel sysCity) { + return toAjax(sysCityService.save(sysCity)); + } + + /** + * 删除 + * + * @param ids + * @return + */ + //@Log(title = "城市设置删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysCity:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysCityService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查 + * + * @param tsysUser + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysCityModel sysCity) { + int b = sysCityService.checkNameUnique("city_name",sysCity.getCityName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Integer id, ModelMap mmap) { + mmap.put("SysCity", sysCityService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "城市设置修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysCity:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysCity record) - { - return toAjax(sysCityService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysCityModel record) { + return toAjax(sysCityService.updateById(record)); } - - - } diff --git a/src/main/java/com/fc/test/controller/admin/SysDepartmentController.java b/src/main/java/com/fc/test/controller/admin/SysDepartmentController.java index f0acf2b96cb1f086b4621662dac8e0c62267123f..bc786befb8078c75bb7cb6dc7e1424349c343f9c 100644 --- a/src/main/java/com/fc/test/controller/admin/SysDepartmentController.java +++ b/src/main/java/com/fc/test/controller/admin/SysDepartmentController.java @@ -1,6 +1,15 @@ package com.fc.test.controller.admin; import java.util.List; + +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.baomidou.mybatisplus.extension.conditions.query.LambdaQueryChainWrapper; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysDepartmentModel; +import com.fc.test.dao.service.SysDepartmentService; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -10,209 +19,199 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysDepartment; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysDepartmentService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @Api(value = "部门表") @Controller @RequestMapping("/SysDepartmentController") -public class SysDepartmentController extends BaseController{ - - private String prefix = "admin/sysDepartment"; - @Autowired - private SysDepartmentService sysDepartmentService; - - /** - * 分页跳转 - * @param model - * @return - * @author fuce - * @Date 2020年4月18日 下午11:48:55 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysDepartment:view") - public String view(ModelMap model) - { - String str="部门表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysDepartmentController extends BaseController { + + private String prefix = "admin/sysDepartment"; + private final SysDepartmentService sysDepartmentService; + + /** + * 分页跳转 + * + * @param model + * @return + * @author fuce + * @Date 2020年4月18日 下午11:48:55 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysDepartment:view") + public String view(ModelMap model) { + String str = "部门表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 分页查询 - * @param tablepar - * @param searchText - * @return - * @author fuce - * @Date 2020年4月18日 下午11:48:34 - */ - //@Log(title = "部门表集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysDepartment:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysDepartmentService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - @ApiOperation(value = "分页查询2", notes = "分页查询2") - @PostMapping("/list2") - @ResponseBody - public Object list2(Tablepar tablepar,String searchText){ - List page= sysDepartmentService.list2(searchText) ; - return page; - } - - /** + + /** + * 分页查询 + * + * @param tablepar + * @param searchText + * @return + * @author fuce + * @Date 2020年4月18日 下午11:48:34 + */ + //@Log(title = "部门表集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysDepartment:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysDepartmentService.listTablepar(tablepar, "dept_name", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + @ApiOperation(value = "分页查询2", notes = "分页查询2") + @PostMapping("/list2") + @ResponseBody + public Object list2(Tablepar tablepar, String searchText) { + LambdaQueryChainWrapper lambdaQueryChainWrapper = sysDepartmentService.lambdaQuery() + .orderByAsc(SysDepartmentModel::getOrderNum); + if (StringUtils.isNotBlank(searchText)) { + lambdaQueryChainWrapper.like(SysDepartmentModel::getDeptName, searchText); + } + return lambdaQueryChainWrapper.list(); + } + + /** * 新增 */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - + /** * 新增 + * * @param sysDepartment * @return * @author fuce * @Date 2020年4月18日 下午11:47:51 */ - //@Log(title = "部门表新增", action = "111") + //@Log(title = "部门表新增", action = "111") @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysDepartment:add") - @ResponseBody - public AjaxResult add(SysDepartment sysDepartment){ - int b=sysDepartmentService.insertSelective(sysDepartment); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除 - * @param ids - * @return - */ - //@Log(title = "部门表删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysDepartment:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysDepartmentService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查用户 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysDepartment sysDepartment){ - int b=sysDepartmentService.checkNameUnique(sysDepartment); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - //获取自己的权限信息 - SysDepartment mytsysPermission = sysDepartmentService.selectByPrimaryKey(id); - //获取父权限信息 - SysDepartment department = sysDepartmentService.selectByPrimaryKey(mytsysPermission.getParentId()); - if(department==null) { - department=new SysDepartment(1, "", "顶级菜单", "", "", "", 0, 1, 1); - } + @PostMapping("/add") + @RequiresPermissions("gen:sysDepartment:add") + @ResponseBody + public AjaxResult add(SysDepartmentModel sysDepartment) { + return + toAjax(sysDepartmentService.save(sysDepartment)); + } + + /** + * 删除 + * + * @param ids + * @return + */ + //@Log(title = "部门表删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysDepartment:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysDepartmentService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查用户 + * + * @param sysDepartment + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysDepartmentModel sysDepartment) { + int b = sysDepartmentService.checkNameUnique("dept_name", sysDepartment.getDeptName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + //获取自己的权限信息 + SysDepartmentModel mytsysPermission = sysDepartmentService.getById(id); + //获取父权限信息 + SysDepartmentModel department = sysDepartmentService.getById(mytsysPermission.getParentId()); + if (department == null) { + department = new SysDepartmentModel(1, "", "顶级菜单", "", "", "", 0, 1, 1); + } mmap.put("SysDepartment", mytsysPermission); mmap.put("perSysDepartment", department); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "部门表修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysDepartment:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysDepartment record) - { - return toAjax(sysDepartmentService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysDepartmentModel record) { + return toAjax(sysDepartmentService.updateById(record)); } - + + /** + * 根据主键查询 + * + * @param id + * @return + */ + @PostMapping("/get/{id}") + @ApiOperation(value = "根据id查询唯一", notes = "根据id查询唯一") + public SysDepartmentModel edit(@PathVariable("id") String id) { + return sysDepartmentService.getById(id); + } + + /** - * 根据主键查询 - * - * @param id - * @param mmap - * @return - */ - @PostMapping("/get/{id}") - @ApiOperation(value = "根据id查询唯一", notes = "根据id查询唯一") - public SysDepartment edit(@PathVariable("id") String id) { - return sysDepartmentService.selectByPrimaryKey(id); - } - - - /** * 跳转到菜单树页面 + * * @return */ - @ApiOperation(value = "跳转到菜单树页面", notes = "跳转到菜单树页面") + @ApiOperation(value = "跳转到菜单树页面", notes = "跳转到菜单树页面") @GetMapping("/tree") - public String Tree(){ - return prefix + "/tree"; + public String Tree() { + return prefix + "/tree"; } - + /** * 获取菜单树 + * * @param pid 父id【没用到】 * @return */ @ApiOperation(value = "获取菜单树", notes = "获取菜单树") @PostMapping("/tree/{pid}") @ResponseBody - public AjaxResult Tree(@PathVariable("pid") String pid){ - return retobject(200, sysDepartmentService.getbooBootstrapTreePerm()); + public AjaxResult Tree(@PathVariable("pid") String pid) { + return retobject(200, sysDepartmentService.getbooBootstrapTreePerm()); } - + } diff --git a/src/main/java/com/fc/test/controller/admin/SysInterUrlController.java b/src/main/java/com/fc/test/controller/admin/SysInterUrlController.java index 6edb8d550683506b4e914484e9d1d318fafcaef3..a6454ac3c8a86bebd9875cc875151399045294f6 100644 --- a/src/main/java/com/fc/test/controller/admin/SysInterUrlController.java +++ b/src/main/java/com/fc/test/controller/admin/SysInterUrlController.java @@ -1,5 +1,12 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysInterUrlModel; +import com.fc.test.dao.service.SysInterUrlService; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -9,196 +16,172 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysInterUrl; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysInterUrlService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @Api(value = "拦截url表") @Controller @RequestMapping("/SysInterUrlController") -public class SysInterUrlController extends BaseController{ - - private String prefix = "admin/sysInterUrl"; - @Autowired - private SysInterUrlService sysInterUrlService; - - /** - * 分页跳转 - * @param model - * @return - * @author fuce - * @Date 2020年4月18日 下午11:43:33 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysInterUrl:view") - public String view(ModelMap model) - { - String str="拦截url表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysInterUrlController extends BaseController { + + private String prefix = "admin/sysInterUrl"; + @Autowired + private SysInterUrlService sysInterUrlService; + + /** + * 分页跳转 + * + * @param model + * @return + * @author fuce + * @Date 2020年4月18日 下午11:43:33 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysInterUrl:view") + public String view(ModelMap model) { + String str = "拦截url表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 分页查询 - * @param tablepar - * @param searchText - * @return - * @author fuce - * @Date 2020年4月18日 下午11:43:42 - */ - //@Log(title = "拦截url表集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysInterUrl:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysInterUrlService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** + + /** + * 分页查询 + * + * @param tablepar + * @param searchText + * @return + * @author fuce + * @Date 2020年4月18日 下午11:43:42 + */ + //@Log(title = "拦截url表集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysInterUrl:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysInterUrlService.listTablepar(tablepar, "inter_name", searchText); + return new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + } + + /** * 新增跳转 */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - - /** - * 新增 - * @param sysInterUrl - * @return - * @author fuce - * @Date 2020年4月18日 下午11:44:30 - */ - //@Log(title = "拦截url表新增", action = "1") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysInterUrl:add") - @ResponseBody - public AjaxResult add(SysInterUrl sysInterUrl){ - int b=sysInterUrlService.insertSelective(sysInterUrl); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 复制 - * @param id - * @return - * @author fuce - * @Date 2020年4月18日 下午11:44:42 - */ - //@Log(title = "复制", action = "1") - @ApiOperation(value = "复制", notes = "复制") - @GetMapping("/copy/{id}") - @RequiresPermissions("gen:sysInterUrl:add") - @ResponseBody - public AjaxResult add(@PathVariable("id") String id){ - SysInterUrl sysInterUrl= sysInterUrlService.selectByPrimaryKey(id); - sysInterUrl.setInterName(sysInterUrl.getInterName()+"复制"); - int b=sysInterUrlService.insertSelective(sysInterUrl); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - - /** - * 删除用户 - * @param ids - * @return - */ - //@Log(title = "拦截url表删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysInterUrl:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysInterUrlService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查用户 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysInterUrl sysInterUrl){ - int b=sysInterUrlService.checkNameUnique(sysInterUrl); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("SysInterUrl", sysInterUrlService.selectByPrimaryKey(id)); + /** + * 新增 + * + * @param sysInterUrl + * @return + * @author fuce + * @Date 2020年4月18日 下午11:44:30 + */ + //@Log(title = "拦截url表新增", action = "1") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("gen:sysInterUrl:add") + @ResponseBody + public AjaxResult add(SysInterUrlModel sysInterUrl) { + return toAjax(sysInterUrlService.save(sysInterUrl)); + } + + /** + * 复制 + * + * @param id + * @return + * @author fuce + * @Date 2020年4月18日 下午11:44:42 + */ + //@Log(title = "复制", action = "1") + @ApiOperation(value = "复制", notes = "复制") + @GetMapping("/copy/{id}") + @RequiresPermissions("gen:sysInterUrl:add") + @ResponseBody + public AjaxResult add(@PathVariable("id") String id) { + SysInterUrlModel sysInterUrl = sysInterUrlService.getById(id); + sysInterUrl.setInterName(sysInterUrl.getInterName() + "复制"); + return toAjax(sysInterUrlService.save(sysInterUrl)); + } + + + /** + * 删除用户 + * + * @param ids + * @return + */ + //@Log(title = "拦截url表删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysInterUrl:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysInterUrlService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查用户 + * + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysInterUrlModel sysInterUrl) { + int b = sysInterUrlService.checkNameUnique("inter_name", sysInterUrl.getInterName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("SysInterUrl", sysInterUrlService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "拦截url表修改", action = "1") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysInterUrl:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysInterUrl record) - { - return toAjax(sysInterUrlService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysInterUrlModel record) { + return toAjax(sysInterUrlService.updateById(record)); } - + /** - * 根据主键查询 - * - * @param id - * @param mmap - * @return - */ - @PostMapping("/get/{id}") - @ApiOperation(value = "根据id查询唯一", notes = "根据id查询唯一") - public SysInterUrl edit(@PathVariable("id") String id) { - return sysInterUrlService.selectByPrimaryKey(id); - } - - - + * 根据主键查询 + * + * @param id + * @return + */ + @PostMapping("/get/{id}") + @ApiOperation(value = "根据id查询唯一", notes = "根据id查询唯一") + public SysInterUrlModel edit(@PathVariable("id") String id) { + return sysInterUrlService.getById(id); + } + + } diff --git a/src/main/java/com/fc/test/controller/admin/SysNoticeController.java b/src/main/java/com/fc/test/controller/admin/SysNoticeController.java index f134b57a1e682371232f425dfccfa3ef8f95582b..5891dba4224833b7c72b464f4cfcfe0f794bc058 100644 --- a/src/main/java/com/fc/test/controller/admin/SysNoticeController.java +++ b/src/main/java/com/fc/test/controller/admin/SysNoticeController.java @@ -1,231 +1,212 @@ - package com.fc.test.controller.admin; +package com.fc.test.controller.admin; -import org.apache.shiro.authz.annotation.RequiresPermissions; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Controller; -import org.springframework.ui.ModelMap; -import org.springframework.web.bind.annotation.GetMapping; -import org.springframework.web.bind.annotation.PathVariable; -import org.springframework.web.bind.annotation.PostMapping; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; +import com.baomidou.mybatisplus.core.toolkit.StringPool; import com.fc.test.common.base.BaseController; +import com.fc.test.common.base.PageInfo; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysNotice; +import com.fc.test.dao.model.SysNoticeModel; +import com.fc.test.dao.service.SysNoticeService; import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysNoticeService; import com.fc.test.shiro.util.ShiroUtils; - +import com.fc.test.util.StringUtils; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; +import lombok.RequiredArgsConstructor; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.*; /** * 公告Controller - * @ClassName: SysNoticeController + * * @author fuce + * @ClassName: SysNoticeController * @date 2019-11-20 22:31 */ @Api(value = "公告") @Controller @RequestMapping("/SysNoticeController") -public class SysNoticeController extends BaseController{ - - private String prefix = "admin/sysNotice"; - @Autowired - private SysNoticeService sysNoticeService; - - - /** - * 展示页面跳转 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午4:09:24 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysNotice:view") - public String view(ModelMap model) - { - String str="公告"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysNoticeController extends BaseController { + private final SysNoticeService sysNoticeService; + + private String prefix = "admin/sysNotice"; + + + /** + * 展示页面跳转 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午4:09:24 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysNotice:view") + public String view(ModelMap model) { + String str = "公告"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - /** - * list页面 - * @param tablepar - * @param searchText - * @return - * @author fuce - * @Date 2019年11月11日 下午4:09:35 - */ - //@Log(title = "公告集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysNotice:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysNoticeService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - - /** - * 对应的用户的展示页面 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午4:09:42 - */ - @ApiOperation(value = "对应的用户的展示页面", notes = "对应的用户的展示页面") - @GetMapping("/viewUser") - public String viewUser(ModelMap model) - { - String str="公告"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); + + /** + * list页面 + * + * @param tablepar + * @param searchText + * @return + * @author fuce + * @Date 2019年11月11日 下午4:09:35 + */ + //@Log(title = "公告集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysNotice:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysNoticeService.listTablepar(tablepar, searchText); + return new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + } + + + /** + * 对应的用户的展示页面 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午4:09:42 + */ + @ApiOperation(value = "对应的用户的展示页面", notes = "对应的用户的展示页面") + @GetMapping("/viewUser") + public String viewUser(ModelMap model) { + String str = "公告"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list_view"; } - /** - * 根据公告id查询跳转到公告详情页面 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "table根据公告id查询跳转到公告详情页面", notes = "table根据公告id查询跳转到公告详情页面") - @PostMapping("/viewUserlist") - @ResponseBody - public Object viewUserlist(Tablepar tablepar,String searchText) - { - - PageInfo page=sysNoticeService.list(ShiroUtils.getUser(), tablepar, searchText); - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; + + /** + * 根据公告id查询跳转到公告详情页面 + * + * @return + */ + @ApiOperation(value = "table根据公告id查询跳转到公告详情页面", notes = "table根据公告id查询跳转到公告详情页面") + @PostMapping("/viewUserlist") + @ResponseBody + public Object viewUserlist(Tablepar tablepar, String searchText) { + PageInfo sysNoticeModelPageInfo = sysNoticeService.listTablepar(ShiroUtils.getUser(), tablepar, searchText); + TableSplitResult result = new TableSplitResult(sysNoticeModelPageInfo.getPageNum(), sysNoticeModelPageInfo.getTotal(), sysNoticeModelPageInfo.getList()); + return result; } - - /** - * 新增跳转 - * @param modelMap - * @return - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * 新增跳转 + * + * @param modelMap + * @return + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - /** - * 新增保存 - * @param sysNotice - * @return - * @author fuce - * @Date 2019年11月11日 下午4:07:09 - */ - //@Log(title = "公告新增", action = "111") + + /** + * 新增保存 + * + * @param sysNotice + * @return + * @author fuce + * @Date 2019年11月11日 下午4:07:09 + */ + //@Log(title = "公告新增", action = "111") @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysNotice:add") - @ResponseBody - public AjaxResult add(SysNotice sysNotice){ - int b=sysNoticeService.insertSelective(sysNotice); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除 - * @param ids - * @return - **/ - //@Log(title = "公告删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysNotice:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysNoticeService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysNotice sysNotice){ - int b=sysNoticeService.checkNameUnique(sysNotice); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - /** - * 根据公告id查询跳转到公告详情页面 - * @param id - * @param mmap - * @return - */ - //@Log(title = "字典数据表删除", action = "1") - @ApiOperation(value = "根据公告id查询跳转到公告详情页面", notes = " 根据公告id查询跳转到公告详情页面") - @GetMapping("/viewinfo/{id}") - public String viewinfo(@PathVariable("id") String id,ModelMap mmap) - { - - String str="公告"; - setTitle(mmap, new TitleVo("详情", str+"列表", true,"欢迎进入"+str+"详情页面", true, false)); - SysNotice notice= sysNoticeService.selectByPrimaryKey(id); - mmap.addAttribute("notice", notice); - //把推送给该用户的公告设置为已读 - sysNoticeService.editUserState(id); + @PostMapping("/add") + @RequiresPermissions("gen:sysNotice:add") + @ResponseBody + public AjaxResult add(SysNoticeModel sysNotice) { + return sysNoticeService.save(sysNotice) ? success() : error(); + } + + /** + * 删除 + * + * @param ids + * @return + **/ + //@Log(title = "公告删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysNotice:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return sysNoticeService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA)) ? success() : error(); + } + + /** + * 检查 + * + * @param sysNotice + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysNoticeModel sysNotice) { + return sysNoticeService.checkNameUnique(sysNotice) > 0 ? 1 : 0; + } + + /** + * 根据公告id查询跳转到公告详情页面 + * + * @param id + * @param mmap + * @return + */ + //@Log(title = "字典数据表删除", action = "1") + @ApiOperation(value = "根据公告id查询跳转到公告详情页面", notes = " 根据公告id查询跳转到公告详情页面") + @GetMapping("/viewinfo/{id}") + public String viewinfo(@PathVariable("id") String id, ModelMap mmap) { + + String str = "公告"; + setTitle(mmap, new TitleVo("详情", str + "列表", true, "欢迎进入" + str + "详情页面", true, false)); + SysNoticeModel notice = sysNoticeService.getById(id); + mmap.addAttribute("notice", notice); + //把推送给该用户的公告设置为已读 + sysNoticeService.editUserState(id); return prefix + "/view"; } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("SysNotice", sysNoticeService.selectByPrimaryKey(id)); + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("SysNotice", sysNoticeService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "公告修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysNotice:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysNotice record) - { - return toAjax(sysNoticeService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysNoticeModel record) { + return toAjax(sysNoticeService.updateById(record)); } - - - - - } diff --git a/src/main/java/com/fc/test/controller/admin/SysPositionController.java b/src/main/java/com/fc/test/controller/admin/SysPositionController.java index 74ee4a999f2f5a12be14c2c4285a4d25a03a9f7e..f140029db0df6beb957a662dccd825be8606e0fa 100644 --- a/src/main/java/com/fc/test/controller/admin/SysPositionController.java +++ b/src/main/java/com/fc/test/controller/admin/SysPositionController.java @@ -1,167 +1,146 @@ package com.fc.test.controller.admin; -import org.apache.shiro.authz.annotation.RequiresPermissions; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Controller; -import org.springframework.ui.ModelMap; -import org.springframework.web.bind.annotation.GetMapping; -import org.springframework.web.bind.annotation.PathVariable; -import org.springframework.web.bind.annotation.PostMapping; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; +import com.baomidou.mybatisplus.core.toolkit.StringPool; import com.fc.test.common.base.BaseController; +import com.fc.test.common.base.PageInfo; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysPosition; +import com.fc.test.dao.model.SysPositionModel; +import com.fc.test.dao.service.SysPositionService; import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysPositionService; +import com.fc.test.util.StringUtils; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; +import lombok.RequiredArgsConstructor; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.*; +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) @Controller @RequestMapping("/SysPositionController") @Api(value = "岗位表") -public class SysPositionController extends BaseController{ - - private String prefix = "admin/sysPosition"; - @Autowired - private SysPositionService sysPositionService; - - /** - * list展示 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysPosition:view") - public String view(ModelMap model) - { - String str="岗位表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +public class SysPositionController extends BaseController { + private final SysPositionService sysPositionService; + + private String prefix = "admin/sysPosition"; + + /** + * list展示 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysPosition:view") + public String view(ModelMap model) { + String str = "岗位表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * 分页集合 - */ - //@Log(title = "岗位表集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysPosition:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysPositionService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** + + /** + * 分页集合 + */ + //@Log(title = "岗位表集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysPosition:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo sysPositionModelPageInfo = sysPositionService.listTablepar(tablepar, "post_name", searchText); + TableSplitResult result = new TableSplitResult(sysPositionModelPageInfo.getPageNum(), sysPositionModelPageInfo.getTotal(), sysPositionModelPageInfo.getList()); + return result; + } + + /** * 新增跳转 */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - + /** * 新增 */ - //@Log(title = "岗位表新增", action = "111") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("add") - @RequiresPermissions("gen:sysPosition:add") - @ResponseBody - public AjaxResult add(SysPosition sysPosition){ - int b=sysPositionService.insertSelective(sysPosition); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除用户 - * @param ids - * @return - */ - //@Log(title = "岗位表删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysPosition:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysPositionService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查用户 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysPosition sysPosition){ - int b=sysPositionService.checkNameUnique(sysPosition); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("SysPosition", sysPositionService.selectByPrimaryKey(id)); + //@Log(title = "岗位表新增", action = "111") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("add") + @RequiresPermissions("gen:sysPosition:add") + @ResponseBody + public AjaxResult add(SysPositionModel sysPosition) { + return toAjax(sysPositionService.save(sysPosition)); + } + + /** + * 删除用户 + * + * @param ids + * @return + */ + //@Log(title = "岗位表删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysPosition:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysPositionService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查用户 + * + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysPositionModel sysPosition) { + return sysPositionService.checkNameUnique("post_name", sysPosition.getPostName()) > 0 ? 1 : 0; + } + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("SysPosition", sysPositionService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "岗位表修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysPosition:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysPosition record) - { - return toAjax(sysPositionService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysPositionModel record) { + return toAjax(sysPositionService.updateById(record)); } - + /** - * 根据主键查询 - * - * @param id - * @param mmap - * @return - */ - @PostMapping("/get/{id}") - @ApiOperation(value = "根据id查询唯一", notes = "根据id查询唯一") - public SysPosition edit(@PathVariable("id") String id) { - return sysPositionService.selectByPrimaryKey(id); - } - - - + * 根据主键查询 + * + * @param id + * @return + */ + @PostMapping("/get/{id}") + @ApiOperation(value = "根据id查询唯一", notes = "根据id查询唯一") + public SysPositionModel edit(@PathVariable("id") String id) { + return sysPositionService.getById(id); + } + + } diff --git a/src/main/java/com/fc/test/controller/admin/SysProvinceController.java b/src/main/java/com/fc/test/controller/admin/SysProvinceController.java index 21e50a2bcb9799288d9091527141af50020c9614..aca67ef8e27757c3712ca6a399b8708331ef271a 100644 --- a/src/main/java/com/fc/test/controller/admin/SysProvinceController.java +++ b/src/main/java/com/fc/test/controller/admin/SysProvinceController.java @@ -1,5 +1,12 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysProvinceModel; +import com.fc.test.dao.service.SysProvinceService; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -9,167 +16,150 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysProvince; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysProvinceService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 省份Controller - * @ClassName: SysProvinceController + * * @author fuce + * @ClassName: SysProvinceController * @date 2019-11-20 22:32 */ @Api(value = "省份表") @Controller @RequestMapping("/SysProvinceController") -public class SysProvinceController extends BaseController{ - - private String prefix = "admin/province/sysProvince"; - @Autowired - private SysProvinceService sysProvinceService; - /** - * 展示页面跳转 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午4:10:48 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysProvince:view") - public String view(ModelMap model) - { - String str="省份表"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysProvinceController extends BaseController { + + private String prefix = "admin/province/sysProvince"; + @Autowired + private SysProvinceService sysProvinceService; + + /** + * 展示页面跳转 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午4:10:48 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysProvince:view") + public String view(ModelMap model) { + String str = "省份表"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - /** - *list查询 - * @param tablepar - * @param searchText - * @return - * @author fuce - * @Date 2019年11月11日 下午4:10:39 - */ - //@Log(title = "省份表集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysProvince:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysProvinceService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - /** - * 新增跳转 - * @param modelMap - * @return - * @author fuce - * @Date 2019年11月11日 下午4:10:20 - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * list查询 + * + * @param tablepar + * @param searchText + * @return + * @author fuce + * @Date 2019年11月11日 下午4:10:39 + */ + //@Log(title = "省份表集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysProvince:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysProvinceService.listTablepar(tablepar, "province_name", searchText); + return new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + } + + /** + * 新增跳转 + * + * @param modelMap + * @return + * @author fuce + * @Date 2019年11月11日 下午4:10:20 + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - - /** - * 新增保存 - * @param sysProvince - * @return - * @author fuce - * @Date 2019年11月11日 下午4:10:26 - */ - //@Log(title = "省份表新增", action = "111") + + /** + * 新增保存 + * + * @param sysProvince + * @return + * @author fuce + * @Date 2019年11月11日 下午4:10:26 + */ + //@Log(title = "省份表新增", action = "111") @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysProvince:add") - @ResponseBody - public AjaxResult add(SysProvince sysProvince){ - int b=sysProvinceService.insertSelective(sysProvince); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除 - * @param ids - * @return - */ - //@Log(title = "省份表删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysProvince:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysProvinceService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysProvince sysProvince){ - int b=sysProvinceService.checkNameUnique(sysProvince); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") Integer id, ModelMap mmap) - { - mmap.put("SysProvince", sysProvinceService.selectByPrimaryKey(id)); + @PostMapping("/add") + @RequiresPermissions("gen:sysProvince:add") + @ResponseBody + public AjaxResult add(SysProvinceModel sysProvince) { + return toAjax(sysProvinceService.save(sysProvince)); + } + + /** + * 删除 + * + * @param ids + * @return + */ + //@Log(title = "省份表删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysProvince:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysProvinceService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查 + * + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysProvinceModel sysProvince) { + int b = sysProvinceService.checkNameUnique("province_name", sysProvince.getProvinceName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Integer id, ModelMap mmap) { + mmap.put("SysProvince", sysProvinceService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存 */ //@Log(title = "省份表修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysProvince:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysProvince record) - { - return toAjax(sysProvinceService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysProvinceModel record) { + return toAjax(sysProvinceService.updateById(record)); } - - - - - } diff --git a/src/main/java/com/fc/test/controller/admin/SysStreetController.java b/src/main/java/com/fc/test/controller/admin/SysStreetController.java index f25d9f72ea24ba89bbc72772b43ca81deab23746..58cb3ee0b765ca27347982e6da7c8c35419173c1 100644 --- a/src/main/java/com/fc/test/controller/admin/SysStreetController.java +++ b/src/main/java/com/fc/test/controller/admin/SysStreetController.java @@ -1,5 +1,12 @@ package com.fc.test.controller.admin; +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysStreetModel; +import com.fc.test.dao.service.SysStreetService; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; @@ -9,165 +16,150 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.ResponseBody; -import com.github.pagehelper.PageInfo; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; -import com.fc.test.model.auto.SysStreet; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.fc.test.service.SysStreetService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 街道Controller - * @ClassName: SysStreetController + * * @author fuce + * @ClassName: SysStreetController * @date 2019-11-20 22:32 */ @Api(value = "街道设置") @Controller @RequestMapping("/SysStreetController") -public class SysStreetController extends BaseController{ - - private String prefix = "admin/province/sysStreet"; - @Autowired - private SysStreetService sysStreetService; - - /** - * 展示跳转 - * @param model - * @return - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("gen:sysStreet:view") - public String view(ModelMap model) - { - String str="街道设置"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysStreetController extends BaseController { + + private String prefix = "admin/province/sysStreet"; + private final SysStreetService sysStreetService; + + /** + * 展示跳转 + * + * @param model + * @return + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("gen:sysStreet:view") + public String view(ModelMap model) { + String str = "街道设置"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - /** - * list查询 - * @param tablepar - * @param searchText - * @return - */ - //@Log(title = "街道设置集合查询", action = "111") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("gen:sysStreet:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysStreetService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - - /** - * 新增跳转 - * @param modelMap - * @return - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + /** + * list查询 + * + * @param tablepar + * @param searchText + * @return + */ + //@Log(title = "街道设置集合查询", action = "111") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("gen:sysStreet:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysStreetService.listTablepar(tablepar, "street_name", searchText); + TableSplitResult result = new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + return result; + } + + /** + * 新增跳转 + * + * @param modelMap + * @return + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { + public String add(ModelMap modelMap) { return prefix + "/add"; } - + /** * 新增保存 + * * @param sysStreet * @return * @author fuce * @Date 2019年11月11日 下午4:13:37 */ - //@Log(title = "街道设置新增", action = "111") - @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("gen:sysStreet:add") - @ResponseBody - public AjaxResult add(SysStreet sysStreet){ - int b=sysStreetService.insertSelective(sysStreet); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除 - * @param ids - * @return - */ - //@Log(title = "街道设置删除", action = "111") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("gen:sysStreet:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysStreetService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkNameUnique") - @ResponseBody - public int checkNameUnique(SysStreet sysStreet){ - int b=sysStreetService.checkNameUnique(sysStreet); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("SysStreet", sysStreetService.selectByPrimaryKey(id)); + //@Log(title = "街道设置新增", action = "111") + @ApiOperation(value = "新增", notes = "新增") + @PostMapping("/add") + @RequiresPermissions("gen:sysStreet:add") + @ResponseBody + public AjaxResult add(SysStreetModel sysStreet) { + return toAjax(sysStreetService.save(sysStreet)); + } + + /** + * 删除 + * + * @param ids + * @return + */ + //@Log(title = "街道设置删除", action = "111") + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("gen:sysStreet:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysStreetService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查 + * + * @param sysStreet + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkNameUnique") + @ResponseBody + public int checkNameUnique(SysStreetModel sysStreet) { + int b = sysStreetService.checkNameUnique("street_name", sysStreet.getStreetName()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("SysStreet", sysStreetService.getById(id)); return prefix + "/edit"; } - /** - * 修改保存 - * @param record - * @return - */ + + /** + * 修改保存 + * + * @param record + * @return + */ //@Log(title = "街道设置修改", action = "111") - @ApiOperation(value = "修改保存", notes = "修改保存") + @ApiOperation(value = "修改保存", notes = "修改保存") @RequiresPermissions("gen:sysStreet:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(SysStreet record) - { - return toAjax(sysStreetService.updateByPrimaryKeySelective(record)); + public AjaxResult editSave(SysStreetModel record) { + return toAjax(sysStreetService.updateById(record)); } - - - } diff --git a/src/main/java/com/fc/test/controller/admin/UeditorController.java b/src/main/java/com/fc/test/controller/admin/UeditorController.java index 7b944b70eca9882bdff612844d1be89f3edb61b3..5778bab8ef1f29aa725d134f8532b59ad083435f 100644 --- a/src/main/java/com/fc/test/controller/admin/UeditorController.java +++ b/src/main/java/com/fc/test/controller/admin/UeditorController.java @@ -2,13 +2,14 @@ package com.fc.test.controller.admin; import java.io.IOException; import javax.servlet.http.HttpServletRequest; + +import com.fc.test.dao.model.SysDatasModel; 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 org.springframework.web.multipart.MultipartFile; import com.fc.test.common.base.BaseController; -import com.fc.test.model.auto.TsysDatas; import com.fc.test.model.custom.PublicMsg; import com.fc.test.model.custom.Ueditor; import com.fc.test.service.UeditorService; @@ -17,77 +18,72 @@ import io.swagger.annotations.ApiOperation; /** * 百度Controller - * @ClassName: UeditorController + * * @author fuce + * @ClassName: UeditorController * @date 2019-11-20 22:34 */ @Api(value = "百度编辑器") @Controller @RequestMapping("/UeditorController") -public class UeditorController extends BaseController{ - @Autowired - private UeditorService ueditorService; - - @ApiOperation(value = "百度编辑器配置", notes = "百度编辑器配置") - @RequestMapping("/ueditor") +public class UeditorController extends BaseController { + @Autowired + private UeditorService ueditorService; + + @ApiOperation(value = "百度编辑器配置", notes = "百度编辑器配置") + @RequestMapping("/ueditor") @ResponseBody - public Object ueditor(HttpServletRequest request,String action,MultipartFile upfile) { - if("config".equals(action)) { - return PublicMsg.UEDITOR_CONFIG; - } - if ("uploadimage".equals(action)) {//图片上传 - - try { - //添加文件到本地 - TsysDatas tsysDatas = ueditorService.fileDataByinsert(upfile); - //添加文件信息 - ueditorService.fileInfoByininsert(tsysDatas.getId()); - String url2=request.getScheme()+"://"+ request.getServerName()+":"+request.getLocalPort()+request.getContextPath()+"/"+tsysDatas.getFilePath(); - Ueditor ueditor = new Ueditor("SUCCESS",url2, "ssss", ""); - return ueditor; - } catch (IOException e) { - e.printStackTrace(); - } - - return null; - }if ("uploadfile".equals(action)) {//文件上传 + public Object ueditor(HttpServletRequest request, String action, MultipartFile upfile) { + if ("config".equals(action)) { + return PublicMsg.UEDITOR_CONFIG; + } + if ("uploadimage".equals(action)) {//图片上传 + try { + //添加文件到本地 + SysDatasModel sysDatasModel = ueditorService.fileDataByinsert(upfile); + //添加文件信息 + ueditorService.fileInfoByininsert(sysDatasModel.getId()); + String url2 = request.getScheme() + "://" + request.getServerName() + ":" + request.getLocalPort() + request.getContextPath() + "/" + sysDatasModel.getFilePath(); + Ueditor ueditor = new Ueditor("SUCCESS", url2, "ssss", ""); + return ueditor; + } catch (IOException e) { + e.printStackTrace(); + } - } - return PublicMsg.UeditorMsg.ERROR.get(); + return null; + } + if ("uploadfile".equals(action)) {//文件上传 + + + } + return PublicMsg.UeditorMsg.ERROR.get(); } - - //@Log(title = "图片上传", action = "1") - @ApiOperation(value = "图片上传", notes = "分页查询") - @RequestMapping(value="/imgUpload") + + //@Log(title = "图片上传", action = "1") + @ApiOperation(value = "图片上传", notes = "分页查询") + @RequestMapping(value = "/imgUpload") @ResponseBody public Ueditor imgUpload(MultipartFile upfile) { Ueditor ueditor = new Ueditor(); return ueditor; } - - - - public String updateAvatar(MultipartFile file) - { - try - { - if (!file.isEmpty()) - { + + public String updateAvatar(MultipartFile file) { + try { + if (!file.isEmpty()) { //插入文件存储表 - String id=sysDatasService.insertSelective(file); - if(id!=null){ - return id; + String id = sysDatasService.insertSelective(file); + if (id != null) { + return id; } } return null; - } - catch (Exception e) - { + } catch (Exception e) { return null; } } - + } diff --git a/src/main/java/com/fc/test/controller/admin/UserController.java b/src/main/java/com/fc/test/controller/admin/UserController.java index e8e93370a95af9fe23ae7f5e2d986116370853e6..47b117dc40eba4078f80c5625c0cb0eff5506328 100644 --- a/src/main/java/com/fc/test/controller/admin/UserController.java +++ b/src/main/java/com/fc/test/controller/admin/UserController.java @@ -1,7 +1,16 @@ package com.fc.test.controller.admin; import java.util.List; + +import com.baomidou.mybatisplus.core.toolkit.StringPool; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysRoleModel; +import com.fc.test.dao.model.SysUserModel; +import com.fc.test.model.custom.TableSplitResult; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; import org.springframework.ui.ModelMap; @@ -14,190 +23,178 @@ import org.springframework.web.bind.annotation.ResponseBody; import com.fc.test.common.base.BaseController; import com.fc.test.common.domain.AjaxResult; import com.fc.test.common.log.Log; -import com.fc.test.model.auto.TsysRole; -import com.fc.test.model.auto.TsysUser; import com.fc.test.model.custom.RoleVo; -import com.fc.test.model.custom.TableSplitResult; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TitleVo; -import com.github.pagehelper.PageInfo; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; /** * 用户Controller - * @ClassName: UserController + * * @author fuce + * @ClassName: UserController * @date 2019-11-20 22:35 */ @Api(value = "用户数据") @Controller @RequestMapping("/UserController") -public class UserController extends BaseController{ - - private String prefix = "admin/user"; - - /** - * 展示跳转页面 - * @param model - * @return - * @author fuce - * @Date 2019年11月11日 下午4:14:34 - */ - @ApiOperation(value = "分页跳转", notes = "分页跳转") - @GetMapping("/view") - @RequiresPermissions("system:user:view") - public String view(ModelMap model) - { - String str="用户"; - setTitle(model, new TitleVo("列表", str+"管理", true,"欢迎进入"+str+"页面", true, false)); +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class UserController extends BaseController { + + private String prefix = "admin/user"; + + /** + * 展示跳转页面 + * + * @param model + * @return + * @author fuce + * @Date 2019年11月11日 下午4:14:34 + */ + @ApiOperation(value = "分页跳转", notes = "分页跳转") + @GetMapping("/view") + @RequiresPermissions("system:user:view") + public String view(ModelMap model) { + String str = "用户"; + setTitle(model, new TitleVo("列表", str + "管理", true, "欢迎进入" + str + "页面", true, false)); return prefix + "/list"; } - - - /** - * list集合 - * @param tablepar - * @param searchText - * @return - * @author fuce - * @Date 2019年11月11日 下午4:14:40 - */ - //@Log(title = "分页查询", action = "1") - @ApiOperation(value = "分页查询", notes = "分页查询") - @PostMapping("/list") - @RequiresPermissions("system:user:list") - @ResponseBody - public Object list(Tablepar tablepar,String searchText){ - PageInfo page=sysUserService.list(tablepar,searchText) ; - TableSplitResult result=new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); - return result; - } - /** - * 新增跳转 - * @param modelMap - * @return - * @author fuce - * @Date 2019年11月11日 下午4:14:51 - */ - @ApiOperation(value = "新增跳转", notes = "新增跳转") + + + /** + * list集合 + * + * @param tablepar + * @param searchText + * @return + * @author fuce + * @Date 2019年11月11日 下午4:14:40 + */ + //@Log(title = "分页查询", action = "1") + @ApiOperation(value = "分页查询", notes = "分页查询") + @PostMapping("/list") + @RequiresPermissions("system:user:list") + @ResponseBody + public Object list(Tablepar tablepar, String searchText) { + PageInfo page = sysUserService.listTablepar(tablepar, "username", searchText); + return new TableSplitResult(page.getPageNum(), page.getTotal(), page.getList()); + } + + /** + * 新增跳转 + * + * @param modelMap + * @return + * @author fuce + * @Date 2019年11月11日 下午4:14:51 + */ + @ApiOperation(value = "新增跳转", notes = "新增跳转") @GetMapping("/add") - public String add(ModelMap modelMap) - { - //添加角色列表 - List tsysRoleList=sysRoleService.queryList(); - modelMap.put("tsysRoleList",tsysRoleList); + public String add(ModelMap modelMap) { + //添加角色列表 + List tsysRoleList = sysRoleService.list(); + modelMap.put("tsysRoleList", tsysRoleList); return prefix + "/add"; } - /** - * 新增保存 - * @param user - * @param model - * @param roles - * @return - * @author fuce - * @Date 2019年11月11日 下午4:14:57 - */ + + /** + * 新增保存 + * + * @param user + * @param model + * @param roles + * @return + * @author fuce + * @Date 2019年11月11日 下午4:14:57 + */ @Log(title = "用户新增", action = "111") @ApiOperation(value = "新增", notes = "新增") - @PostMapping("/add") - @RequiresPermissions("system:user:add") - @ResponseBody - public AjaxResult add(TsysUser user,Model model,@RequestParam(value="roles", required = false)List roles){ - int b=sysUserService.insertUserRoles(user,roles); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 删除用户 - * @param ids - * @return - */ + @PostMapping("/add") + @RequiresPermissions("system:user:add") + @ResponseBody + public AjaxResult add(SysUserModel user, Model model, @RequestParam(value = "roles", required = false) List roles) { + return toAjax(sysUserService.insertUserRoles(user, roles)); + } + + /** + * 删除用户 + * + * @param ids + * @return + */ //@Log(title = "删除用户", action = "1") - @ApiOperation(value = "删除", notes = "删除") - @PostMapping("/remove") - @RequiresPermissions("system:user:remove") - @ResponseBody - public AjaxResult remove(String ids){ - int b=sysUserService.deleteByPrimaryKey(ids); - if(b>0){ - return success(); - }else{ - return error(); - } - } - - /** - * 检查用户 - * @param tsysUser - * @return - */ - @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") - @PostMapping("/checkLoginNameUnique") - @ResponseBody - public int checkLoginNameUnique(TsysUser tsysUser){ - int b=sysUserService.checkLoginNameUnique(tsysUser); - if(b>0){ - return 1; - }else{ - return 0; - } - } - - - /** - * 修改用户跳转 - * @param id - * @param mmap - * @return - */ - @ApiOperation(value = "修改跳转", notes = "修改跳转") - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") String id, ModelMap mmap) - { - //查询所有角色 - List roleVos=sysUserService.getUserIsRole(id); - mmap.put("roleVos",roleVos); - mmap.put("TsysUser", sysUserService.selectByPrimaryKey(id)); + @ApiOperation(value = "删除", notes = "删除") + @PostMapping("/remove") + @RequiresPermissions("system:user:remove") + @ResponseBody + public AjaxResult remove(String ids) { + return toAjax(sysUserService.removeByIds(StringUtils.splitList(ids, StringPool.COMMA))); + } + + /** + * 检查用户 + * + * @param sysUserModel + * @return + */ + @ApiOperation(value = "检查Name唯一", notes = "检查Name唯一") + @PostMapping("/checkLoginNameUnique") + @ResponseBody + public int checkLoginNameUnique(SysUserModel sysUserModel) { + int b = sysUserService.checkNameUnique("username", sysUserModel.getUsername()); + return b > 0 ? 1 : 0; + } + + + /** + * 修改用户跳转 + * + * @param id + * @param mmap + * @return + */ + @ApiOperation(value = "修改跳转", notes = "修改跳转") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") String id, ModelMap mmap) { + //查询所有角色 + List roleVos = sysUserService.getUserIsRole(id); + mmap.put("roleVos", roleVos); + mmap.put("TsysUser", sysUserService.getById(id)); return prefix + "/edit"; } - - /** + + /** * 修改保存用户 */ - //@Log(title = "修改保存用户", action = "1") + //@Log(title = "修改保存用户", action = "1") @ApiOperation(value = "修改保存用户", notes = "修改保存用户") @RequiresPermissions("system:user:edit") @PostMapping("/edit") @ResponseBody - public AjaxResult editSave(TsysUser tsysUser,@RequestParam(value="roles", required = false)List roles) - { - return toAjax(sysUserService.updateUserRoles(tsysUser,roles)); + public AjaxResult editSave(SysUserModel tsysUser, @RequestParam(value = "roles", required = false) List roles) { + return toAjax(sysUserService.updateUserRoles(tsysUser, roles)); } - - + /** - * 修改用户密码跳转 - * @param id - * @param mmap - * @return - */ + * 修改用户密码跳转 + * + * @param id + * @param mmap + * @return + */ //@Log(title = "修改用户密码", action = "1") @ApiOperation(value = "修改用户密码跳转", notes = "修改用户密码跳转") - @GetMapping("/editPwd/{id}") - public String editPwd(@PathVariable("id") String id, ModelMap mmap) - { - mmap.put("TsysUser", sysUserService.selectByPrimaryKey(id)); + @GetMapping("/editPwd/{id}") + public String editPwd(@PathVariable("id") String id, ModelMap mmap) { + mmap.put("TsysUser", sysUserService.getById(id)); return prefix + "/editPwd"; } - /** + + /** * 修改保存用户 */ //@Log(title = "修改用户密码", action = "1") @@ -205,10 +202,9 @@ public class UserController extends BaseController{ @RequiresPermissions("system:user:editPwd") @PostMapping("/editPwd") @ResponseBody - public AjaxResult editPwdSave(TsysUser tsysUser) - { - return toAjax(sysUserService.updateUserPassword(tsysUser)); + public AjaxResult editPwdSave(SysUserModel tsysUser) { + return toAjax(sysUserService.updateById(tsysUser)); } - + } diff --git a/src/main/java/com/fc/test/dao/mapper/SysAreaMapper.java b/src/main/java/com/fc/test/dao/mapper/SysAreaMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..cac244e34b622f496502b18843b22795e1f4546c --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysAreaMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysAreaModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 地区设置 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysAreaMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysCityMapper.java b/src/main/java/com/fc/test/dao/mapper/SysCityMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..9955a04a3fa9da7dd9f963f08a447b27e5f6299b --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysCityMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysCityModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 城市设置 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysCityMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysDatasMapper.java b/src/main/java/com/fc/test/dao/mapper/SysDatasMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..ff5304b96cd6e274f70bde3cae5473b9b3fdc871 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysDatasMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysDatasModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 文件表存储表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDatasMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysDepartmentMapper.java b/src/main/java/com/fc/test/dao/mapper/SysDepartmentMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..5f3551649a67a2cbdcee21e9955c8d716330010f --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysDepartmentMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysDepartmentModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 部门表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDepartmentMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysDictDataMapper.java b/src/main/java/com/fc/test/dao/mapper/SysDictDataMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..204a156923e364947457c325d1a0639727688efc --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysDictDataMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysDictDataModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 字典数据表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDictDataMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysDictTypeMapper.java b/src/main/java/com/fc/test/dao/mapper/SysDictTypeMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..a88c3ade6f2b61b422e6b0f9e3eda7b1fe315548 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysDictTypeMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysDictTypeModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 字典类型表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDictTypeMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysEmailMapper.java b/src/main/java/com/fc/test/dao/mapper/SysEmailMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..7df2998e475f77fa8df3725507345594996b59ce --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysEmailMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysEmailModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 电子邮件 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysEmailMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysFileDataMapper.java b/src/main/java/com/fc/test/dao/mapper/SysFileDataMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..175426de2eb0c019a348595ab2a5feb44af8f36f --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysFileDataMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysFileDataModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 文件数据外键绑定表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysFileDataMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysFileMapper.java b/src/main/java/com/fc/test/dao/mapper/SysFileMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..c6fc92d72723d7c9567a490f279e5566d0245525 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysFileMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysFileModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 文件信息表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysFileMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysInterUrlMapper.java b/src/main/java/com/fc/test/dao/mapper/SysInterUrlMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..6986504aaa18dcaa448949c2fbb3a042acc95ce0 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysInterUrlMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysInterUrlModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 拦截url表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysInterUrlMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysNoticeMapper.java b/src/main/java/com/fc/test/dao/mapper/SysNoticeMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..f32e678c2400c24a22fbdfe537de4e4ee2322e80 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysNoticeMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysNoticeModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 公告 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysNoticeMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysNoticeUserMapper.java b/src/main/java/com/fc/test/dao/mapper/SysNoticeUserMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..a18aa993e094df047e848170e2dc815ab9c50123 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysNoticeUserMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysNoticeUserModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 公告_用户外键 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysNoticeUserMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysOperLogMapper.java b/src/main/java/com/fc/test/dao/mapper/SysOperLogMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..9ba533638bde0f55413203f5568d3fb26c6e434d --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysOperLogMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysOperLogModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 日志记录表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysOperLogMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysPermissionMapper.java b/src/main/java/com/fc/test/dao/mapper/SysPermissionMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..6a646cb94357a79886dd1e17d56f3ed1e4fafec5 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysPermissionMapper.java @@ -0,0 +1,32 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysPermissionModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import org.apache.ibatis.annotations.Param; + +import java.util.List; + +/** + *

+ * 权限表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysPermissionMapper extends BaseMapper { + /** + * 根据用户id查询出用户的所有权限 + * + * @param userId + * @return + */ + List findByAdminUserId(@Param("userId") String userId); + + /** + * 根据角色id查询 + * @param rolid + * @return + */ + List queryRoleId(@Param("roleid") String rolid); +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysPermissionRoleMapper.java b/src/main/java/com/fc/test/dao/mapper/SysPermissionRoleMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..20311724f1c0f978895d1c42bbb7ff04de25108b --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysPermissionRoleMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysPermissionRoleModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 角色权限中间表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysPermissionRoleMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysPositionMapper.java b/src/main/java/com/fc/test/dao/mapper/SysPositionMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..1bfd9363f9e81c5c43d47582fdc2dd7f7f21ed75 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysPositionMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysPositionModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 岗位表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysPositionMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysProvinceMapper.java b/src/main/java/com/fc/test/dao/mapper/SysProvinceMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..5b6467b7528d0b5f7e58bfed5d3af2e3677282d1 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysProvinceMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysProvinceModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 省份表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysProvinceMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysQuartzJobLogMapper.java b/src/main/java/com/fc/test/dao/mapper/SysQuartzJobLogMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..895b62077da4d92677ef6a99be8d1a2f6eb5d950 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysQuartzJobLogMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysQuartzJobLogModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 定时任务调度日志表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysQuartzJobLogMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysQuartzJobMapper.java b/src/main/java/com/fc/test/dao/mapper/SysQuartzJobMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..ea29f63182a99a8e11b7cc32233e1b7bf66cdfc7 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysQuartzJobMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysQuartzJobModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 定时任务调度表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysQuartzJobMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysRoleMapper.java b/src/main/java/com/fc/test/dao/mapper/SysRoleMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..4e8e927d97d18aa434e384156abe752c8ba0c6ba --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysRoleMapper.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysRoleModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import org.apache.ibatis.annotations.Param; + +import java.util.List; + +/** + *

+ * 角色表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysRoleMapper extends BaseMapper { + + List queryUserRole(@Param("userid") String uid); +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysRoleUserMapper.java b/src/main/java/com/fc/test/dao/mapper/SysRoleUserMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..cab1f26aca99a0b2de76b86503969d87d53ad650 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysRoleUserMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysRoleUserModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 用户角色中间表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysRoleUserMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysStreetMapper.java b/src/main/java/com/fc/test/dao/mapper/SysStreetMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..6379a5eea9d3d57a4009d0106006169e5264401d --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysStreetMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysStreetModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 街道设置 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysStreetMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/SysUserMapper.java b/src/main/java/com/fc/test/dao/mapper/SysUserMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..802d30d04de9ab7fac20df8d27c72e9c31e3519a --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/SysUserMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.SysUserModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 用户表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysUserMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/mapper/TestMapper.java b/src/main/java/com/fc/test/dao/mapper/TestMapper.java new file mode 100644 index 0000000000000000000000000000000000000000..d1dce4b37943b8aa3fc4c8d2a5ee22404221c3d7 --- /dev/null +++ b/src/main/java/com/fc/test/dao/mapper/TestMapper.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.mapper; + +import com.fc.test.dao.model.TestModel; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 测试表 Mapper 接口 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface TestMapper extends BaseMapper { + +} diff --git a/src/main/java/com/fc/test/dao/model/SysAreaModel.java b/src/main/java/com/fc/test/dao/model/SysAreaModel.java new file mode 100644 index 0000000000000000000000000000000000000000..999a4fb417cbdb26f972c28b51311cd6effcce87 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysAreaModel.java @@ -0,0 +1,86 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; + +import com.fasterxml.jackson.annotation.JsonFormat; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 地区设置 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_area") +public class SysAreaModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 区代码 + */ + private String areaCode; + + /** + * 父级市代码 + */ + private String cityCode; + + /** + * 市名称 + */ + private String areaName; + + /** + * 简称 + */ + private String shortName; + + /** + * 经度 + */ + private String lng; + + /** + * 纬度 + */ + private String lat; + + /** + * 排序 + */ + private Integer sort; + + /** + * 创建时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") + private LocalDateTime gmtCreate; + + /** + * 修改时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") + private LocalDateTime gmtModified; + + /** + * 备注 + */ + private String memo; + + /** + * 状态 + */ + private Integer dataState; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysCityModel.java b/src/main/java/com/fc/test/dao/model/SysCityModel.java new file mode 100644 index 0000000000000000000000000000000000000000..c13977a762c1c53bc5eb33307e29c10b5fa5c48e --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysCityModel.java @@ -0,0 +1,86 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; + +import com.fasterxml.jackson.annotation.JsonFormat; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 城市设置 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_city") +public class SysCityModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 市代码 + */ + private String cityCode; + + /** + * 市名称 + */ + private String cityName; + + /** + * 简称 + */ + private String shortName; + + /** + * 省代码 + */ + private String provinceCode; + + /** + * 经度 + */ + private String lng; + + /** + * 纬度 + */ + private String lat; + + /** + * 排序 + */ + private Integer sort; + + /** + * 创建时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") + private LocalDateTime gmtCreate; + + /** + * 修改时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") + private LocalDateTime gmtModified; + + /** + * 备注 + */ + private String memo; + + /** + * 状态 + */ + private Integer dataState; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysDatasModel.java b/src/main/java/com/fc/test/dao/model/SysDatasModel.java new file mode 100644 index 0000000000000000000000000000000000000000..02702135f6c6923fb82fc868b4af6f894fcd8e47 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysDatasModel.java @@ -0,0 +1,38 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; + +import java.io.Serializable; + +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 文件表存储表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_datas") +public class SysDatasModel implements Serializable { + + private static final long serialVersionUID = 1L; + private String id; + /** + * 文件地址 + */ + private String filePath; + + /** + * 后缀 + */ + private String fileSuffix; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysDepartmentModel.java b/src/main/java/com/fc/test/dao/model/SysDepartmentModel.java new file mode 100644 index 0000000000000000000000000000000000000000..49d4c65311c9e529eec6f8d9d1143300224f7b09 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysDepartmentModel.java @@ -0,0 +1,69 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableField; +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import lombok.experimental.Accessors; + +/** + *

+ * 部门表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_department") +@AllArgsConstructor +@NoArgsConstructor +public class SysDepartmentModel implements Serializable { + + private static final long serialVersionUID = 1L; + + private Integer id; + /** + * 父id + */ + private String parentId; + + /** + * 部门名称 + */ + private String deptName; + + /** + * 部门负责人 + */ + private String leader; + + /** + * 电话 + */ + private String phone; + + /** + * 邮箱 + */ + private String email; + + /** + * 状态 + */ + private Integer status; + + /** + * 排序 + */ + private Integer orderNum; + + @TableField(exist = false) + private Integer childCount; +} diff --git a/src/main/java/com/fc/test/dao/model/SysDictDataModel.java b/src/main/java/com/fc/test/dao/model/SysDictDataModel.java new file mode 100644 index 0000000000000000000000000000000000000000..e8c265594918cdf6f81f554f061d985a5e670184 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysDictDataModel.java @@ -0,0 +1,92 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 字典数据表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_dict_data") +public class SysDictDataModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 字典排序 + */ + private Integer dictSort; + + /** + * 字典标签 + */ + private String dictLabel; + + /** + * 字典键值 + */ + private String dictValue; + + /** + * 字典类型 + */ + private String dictType; + + /** + * 样式属性(其他样式扩展) + */ + private String cssClass; + + /** + * 表格回显样式 + */ + private String listClass; + + /** + * 是否默认(Y是 N否) + */ + private String isDefault; + + /** + * 状态(0正常 1停用) + */ + private String status; + + /** + * 创建者 + */ + private String createBy; + + /** + * 创建时间 + */ + private LocalDateTime createTime; + + /** + * 更新者 + */ + private String updateBy; + + /** + * 更新时间 + */ + private LocalDateTime updateTime; + + /** + * 备注 + */ + private String remark; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysDictTypeModel.java b/src/main/java/com/fc/test/dao/model/SysDictTypeModel.java new file mode 100644 index 0000000000000000000000000000000000000000..a6f3c106d1d10ea9cd6dab0bb0f472ef1f7d3330 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysDictTypeModel.java @@ -0,0 +1,67 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 字典类型表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_dict_type") +public class SysDictTypeModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 字典名称 + */ + private String dictName; + + /** + * 字典类型 + */ + private String dictType; + + /** + * 状态(0正常 1停用) + */ + private String status; + + /** + * 创建者 + */ + private String createBy; + + /** + * 创建时间 + */ + private LocalDateTime createTime; + + /** + * 更新者 + */ + private String updateBy; + + /** + * 更新时间 + */ + private LocalDateTime updateTime; + + /** + * 备注 + */ + private String remark; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysEmailModel.java b/src/main/java/com/fc/test/dao/model/SysEmailModel.java new file mode 100644 index 0000000000000000000000000000000000000000..a7d5172bf5818ddd13a449121ed0dce84866c693 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysEmailModel.java @@ -0,0 +1,57 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 电子邮件 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_email") +public class SysEmailModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 接收人电子邮件 + */ + private String receiversEmail; + + /** + * 邮件标题 + */ + private String title; + + /** + * 内容 + */ + private String content; + + /** + * 发送人id + */ + private String sendUserId; + + /** + * 发送人账号 + */ + private String sendUserName; + + /** + * 创建时间 + */ + private LocalDateTime createTime; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysFileDataModel.java b/src/main/java/com/fc/test/dao/model/SysFileDataModel.java new file mode 100644 index 0000000000000000000000000000000000000000..4b82aee2b224fec39fafea4964cb927b170db1f8 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysFileDataModel.java @@ -0,0 +1,38 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; + +import java.io.Serializable; + +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 文件数据外键绑定表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_file_data") +public class SysFileDataModel implements Serializable { + + private static final long serialVersionUID = 1L; + private String id; + /** + * 数据id + */ + private String dataId; + + /** + * 文件id + */ + private String fileId; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysFileModel.java b/src/main/java/com/fc/test/dao/model/SysFileModel.java new file mode 100644 index 0000000000000000000000000000000000000000..abdad6f301bfce7b4ef187d4d62b69b91f3a83e5 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysFileModel.java @@ -0,0 +1,68 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import java.util.Date; + +import com.fasterxml.jackson.annotation.JsonFormat; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 文件信息表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_file") +public class SysFileModel implements Serializable { + + private static final long serialVersionUID = 1L; + + private String id; + /** + * 图片名字 + */ + private String fileName; + + /** + * 创建人id + */ + private String createUserId; + + /** + * 创建人名字 + */ + private String createUserName; + + /** + * 创建时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private Date createTime; + + /** + * 修改人 + */ + private String updateUserId; + + /** + * 修改人名字 + */ + private String updateUserName; + + /** + * 修改时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private Date updateTime; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysInterUrlModel.java b/src/main/java/com/fc/test/dao/model/SysInterUrlModel.java new file mode 100644 index 0000000000000000000000000000000000000000..c54c41f388a732210803b5751ac1fc9f4765095d --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysInterUrlModel.java @@ -0,0 +1,41 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 拦截url表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_inter_url") +public class SysInterUrlModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 拦截名称 + */ + private String interName; + + /** + * 拦截url + */ + private String url; + + /** + * 类型 + */ + private Integer type; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysNoticeModel.java b/src/main/java/com/fc/test/dao/model/SysNoticeModel.java new file mode 100644 index 0000000000000000000000000000000000000000..c5da23b935cdfd23d780d832736f5d88e4b230f6 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysNoticeModel.java @@ -0,0 +1,60 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 公告 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_notice") +public class SysNoticeModel implements Serializable { + + private static final long serialVersionUID = 1L; + /** + * 主键ID + */ + private String id; + /** + * 标题 + */ + private String title; + + /** + * 内容 + */ + private String content; + + /** + * 类型 + */ + private Integer type; + + /** + * 创建人id + */ + private String createId; + + /** + * 创建人name + */ + private String createUsername; + + /** + * 发信时间 + */ + private LocalDateTime createTime; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysNoticeUserModel.java b/src/main/java/com/fc/test/dao/model/SysNoticeUserModel.java new file mode 100644 index 0000000000000000000000000000000000000000..77da600ce668c0c877e5fa014a5ebadb5ae6a63e --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysNoticeUserModel.java @@ -0,0 +1,41 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 公告_用户外键 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_notice_user") +public class SysNoticeUserModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 公告id + */ + private String noticeId; + + /** + * 用户id + */ + private String userId; + + /** + * 0未阅读 1 阅读 + */ + private Integer state; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysOperLogModel.java b/src/main/java/com/fc/test/dao/model/SysOperLogModel.java new file mode 100644 index 0000000000000000000000000000000000000000..806231c03f73c1e66a40ea8d7d7953cfcfbbb8b5 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysOperLogModel.java @@ -0,0 +1,61 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDate; +import java.io.Serializable; +import java.util.Date; + +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 日志记录表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_oper_log") +public class SysOperLogModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 标题 + */ + private String title; + + /** + * 方法 + */ + private String method; + + /** + * 操作人 + */ + private String operName; + + /** + * url + */ + private String operUrl; + + /** + * 参数 + */ + private String operParam; + + private String errorMsg; + + /** + * 操作时间 + */ + private Date operTime; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysPermissionModel.java b/src/main/java/com/fc/test/dao/model/SysPermissionModel.java new file mode 100644 index 0000000000000000000000000000000000000000..21230f1323517d78e755fb61e79c64fdd2a61099 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysPermissionModel.java @@ -0,0 +1,84 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableField; +import com.baomidou.mybatisplus.annotation.TableName; + +import java.io.Serializable; + +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 权限表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_permission") +public class SysPermissionModel implements Serializable { + + private static final long serialVersionUID = 1L; + private String id; + /** + * 权限名称 + */ + private String name; + + /** + * 权限描述 + */ + private String descripion; + + /** + * 授权链接 + */ + private String url; + + /** + * 是否跳转 0 不跳转 1跳转 + */ + private Integer isBlank; + + /** + * 父节点id + */ + private String pid; + + /** + * 权限标识 + */ + private String perms; + + /** + * 类型 0:目录 1:菜单 2:按钮 + */ + private Integer type; + + /** + * 菜单图标 + */ + private String icon; + + /** + * 排序 + */ + private Integer orderNum; + + /** + * 是否可见 + */ + private Integer visible; + + + /** + * 该字段不在数据库 + */ + @TableField(exist = false) + private Integer childCount; +} diff --git a/src/main/java/com/fc/test/dao/model/SysPermissionRoleModel.java b/src/main/java/com/fc/test/dao/model/SysPermissionRoleModel.java new file mode 100644 index 0000000000000000000000000000000000000000..f30c4be0941c976b59f25904c67daaa2842eed0c --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysPermissionRoleModel.java @@ -0,0 +1,41 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import lombok.experimental.Accessors; + +/** + *

+ * 角色权限中间表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_permission_role") +@AllArgsConstructor +@NoArgsConstructor +public class SysPermissionRoleModel implements Serializable { + + private static final long serialVersionUID = 1L; + private String id; + /** + * 角色id + */ + private String roleId; + + /** + * 权限id + */ + private String permissionId; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysPositionModel.java b/src/main/java/com/fc/test/dao/model/SysPositionModel.java new file mode 100644 index 0000000000000000000000000000000000000000..221d66a6d3ec8084c7003e6193fd672ded908055 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysPositionModel.java @@ -0,0 +1,41 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 岗位表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_position") +public class SysPositionModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 岗位名称 + */ + private String postName; + + /** + * 排序 + */ + private Integer orderNum; + + /** + * 状态 + */ + private Integer status; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysProvinceModel.java b/src/main/java/com/fc/test/dao/model/SysProvinceModel.java new file mode 100644 index 0000000000000000000000000000000000000000..26529af191c5bde48af5fdaf100ebc6a5386ea61 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysProvinceModel.java @@ -0,0 +1,77 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 省份表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_province") +public class SysProvinceModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 省份代码 + */ + private String provinceCode; + + /** + * 省份名称 + */ + private String provinceName; + + /** + * 简称 + */ + private String shortName; + + /** + * 经度 + */ + private String lng; + + /** + * 纬度 + */ + private String lat; + + /** + * 排序 + */ + private Integer sort; + + /** + * 创建时间 + */ + private LocalDateTime gmtCreate; + + /** + * 修改时间 + */ + private LocalDateTime gmtModified; + + /** + * 备注 + */ + private String memo; + + /** + * 状态 + */ + private Integer dataState; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysQuartzJobLogModel.java b/src/main/java/com/fc/test/dao/model/SysQuartzJobLogModel.java new file mode 100644 index 0000000000000000000000000000000000000000..c219050390e6ed1468b01f3db117e4a24f0a99cc --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysQuartzJobLogModel.java @@ -0,0 +1,69 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import java.util.Date; + +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 定时任务调度日志表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_quartz_job_log") +public class SysQuartzJobLogModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 任务名称 + */ + private String jobName; + + /** + * 任务组名 + */ + private String jobGroup; + + /** + * 调用目标字符串 + */ + private String invokeTarget; + + /** + * 日志信息 + */ + private String jobMessage; + + /** + * 执行状态(0正常 1失败) + */ + private Integer status; + + /** + * 异常信息 + */ + private String exceptionInfo; + + /** + * 开始时间 + */ + private Date startTime; + + /** + * 结束时间 + */ + private Date endTime; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysQuartzJobModel.java b/src/main/java/com/fc/test/dao/model/SysQuartzJobModel.java new file mode 100644 index 0000000000000000000000000000000000000000..c831f69e4c86bd5b136b4db0d3e31bd932b7a1bb --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysQuartzJobModel.java @@ -0,0 +1,61 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 定时任务调度表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_quartz_job") +public class SysQuartzJobModel implements Serializable { + + private static final long serialVersionUID = 1L; +private String id; + /** + * 任务名称 + */ + private String jobName; + + /** + * 任务组名 + */ + private String jobGroup; + + /** + * 调用目标字符串 + */ + private String invokeTarget; + + /** + * cron执行表达式 + */ + private String cronExpression; + + /** + * cron计划策略 + */ + private String misfirePolicy; + + /** + * 是否并发执行(0允许 1禁止) + */ + private String concurrent; + + /** + * 任务状态(0正常 1暂停) + */ + private Integer status; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysRoleModel.java b/src/main/java/com/fc/test/dao/model/SysRoleModel.java new file mode 100644 index 0000000000000000000000000000000000000000..d0297bb32687575c8768a9ae4b6e8f5a68e13009 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysRoleModel.java @@ -0,0 +1,37 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; + +import java.io.Serializable; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import lombok.experimental.Accessors; + +/** + *

+ * 角色表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_role") +@NoArgsConstructor +@AllArgsConstructor +public class SysRoleModel implements Serializable { + + private static final long serialVersionUID = 1L; + private String id; + /** + * 角色名称 + */ + private String name; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysRoleUserModel.java b/src/main/java/com/fc/test/dao/model/SysRoleUserModel.java new file mode 100644 index 0000000000000000000000000000000000000000..2119ad5e294c7fc304d04aa26474912c02fdbd2e --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysRoleUserModel.java @@ -0,0 +1,42 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import lombok.experimental.Accessors; +import org.apache.ibatis.annotations.Arg; + +/** + *

+ * 用户角色中间表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_role_user") +@AllArgsConstructor +@NoArgsConstructor +public class SysRoleUserModel implements Serializable { + + private static final long serialVersionUID = 1L; + private String id; + /** + * 用户id + */ + private String sysUserId; + + /** + * 角色id + */ + private String sysRoleId; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysStreetModel.java b/src/main/java/com/fc/test/dao/model/SysStreetModel.java new file mode 100644 index 0000000000000000000000000000000000000000..16dea9334aef9f78c1427eb0cee00c669fa8122d --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysStreetModel.java @@ -0,0 +1,82 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 街道设置 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_street") +public class SysStreetModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 街道代码 + */ + private String streetCode; + + /** + * 父级区代码 + */ + private String areaCode; + + /** + * 街道名称 + */ + private String streetName; + + /** + * 简称 + */ + private String shortName; + + /** + * 经度 + */ + private String lng; + + /** + * 纬度 + */ + private String lat; + + /** + * 排序 + */ + private Integer sort; + + /** + * 创建时间 + */ + private LocalDateTime gmtCreate; + + /** + * 修改时间 + */ + private LocalDateTime gmtModified; + + /** + * 备注 + */ + private String memo; + + /** + * 状态 + */ + private Integer dataState; + + +} diff --git a/src/main/java/com/fc/test/dao/model/SysUserModel.java b/src/main/java/com/fc/test/dao/model/SysUserModel.java new file mode 100644 index 0000000000000000000000000000000000000000..48575e80e5227071df7e0f0590cec1cac859149c --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/SysUserModel.java @@ -0,0 +1,45 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 用户表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_sys_user") +public class SysUserModel implements Serializable { + + private static final long serialVersionUID = 1L; + /** + * 用户id + */ + private String id; + + /** + * 用户账号 + */ + private String username; + + /** + * 用户密码 + */ + private String password; + + /** + * 昵称 + */ + private String nickname; + + +} diff --git a/src/main/java/com/fc/test/dao/model/TestModel.java b/src/main/java/com/fc/test/dao/model/TestModel.java new file mode 100644 index 0000000000000000000000000000000000000000..f4c942bca5c84ff86f171f64efe42beae3f8c257 --- /dev/null +++ b/src/main/java/com/fc/test/dao/model/TestModel.java @@ -0,0 +1,47 @@ +package com.fc.test.dao.model; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.time.LocalDateTime; +import java.io.Serializable; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.experimental.Accessors; + +/** + *

+ * 测试表 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Data +@EqualsAndHashCode(callSuper = false) +@Accessors(chain = true) +@TableName("t_test") +public class TestModel implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 名称 + */ + private String name; + + /** + * 性别 + */ + private Integer age; + + /** + * 创建时间 + */ + private LocalDateTime crateTime; + + /** + * 名字 + */ + private String tesName; + + +} diff --git a/src/main/java/com/fc/test/dao/service/SysAreaService.java b/src/main/java/com/fc/test/dao/service/SysAreaService.java new file mode 100644 index 0000000000000000000000000000000000000000..b41ec9b692930b4b9f8114866d6910d0bb299164 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysAreaService.java @@ -0,0 +1,26 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysAreaModel; +import com.baomidou.mybatisplus.extension.service.IService; + +import java.util.List; + +/** + *

+ * 地区设置 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysAreaService extends BaseIService { + + + /** + * 根据城市编码查询 + * @param cityCode + * @return + */ + List getByCityCode(String cityCode); +} diff --git a/src/main/java/com/fc/test/dao/service/SysCityService.java b/src/main/java/com/fc/test/dao/service/SysCityService.java new file mode 100644 index 0000000000000000000000000000000000000000..e82cd4c45450f43adb8f74a307311183e333ac1e --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysCityService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysCityModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 城市设置 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysCityService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysDatasService.java b/src/main/java/com/fc/test/dao/service/SysDatasService.java new file mode 100644 index 0000000000000000000000000000000000000000..78f3fcc4040b068d83fdfee40bbe2b49808d9cf3 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysDatasService.java @@ -0,0 +1,25 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysDatasModel; +import com.baomidou.mybatisplus.extension.service.IService; +import org.springframework.web.multipart.MultipartFile; + +import java.io.IOException; + +/** + *

+ * 文件表存储表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDatasService extends BaseIService { + /** + * 文件上传文件存储到文件表 + * @param file + * @return + */ + String insertSelective(MultipartFile file) throws IOException; +} diff --git a/src/main/java/com/fc/test/dao/service/SysDepartmentService.java b/src/main/java/com/fc/test/dao/service/SysDepartmentService.java new file mode 100644 index 0000000000000000000000000000000000000000..a6861467691373e32d2112fa924a1827820b602c --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysDepartmentService.java @@ -0,0 +1,23 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysDepartmentModel; +import com.baomidou.mybatisplus.extension.service.IService; +import com.fc.test.model.custom.BootstrapTree; + +/** + *

+ * 部门表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDepartmentService extends BaseIService { + /** + * 获取转换成bootstarp的权限数据 + * @return + */ + BootstrapTree getbooBootstrapTreePerm(); + +} diff --git a/src/main/java/com/fc/test/dao/service/SysDictDataService.java b/src/main/java/com/fc/test/dao/service/SysDictDataService.java new file mode 100644 index 0000000000000000000000000000000000000000..4a3ad9ecaa3d7cd0189592b6aa6c5c68eb7698d6 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysDictDataService.java @@ -0,0 +1,15 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysDictDataModel; + +/** + *

+ * 字典数据表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDictDataService extends BaseIService { +} diff --git a/src/main/java/com/fc/test/dao/service/SysDictTypeService.java b/src/main/java/com/fc/test/dao/service/SysDictTypeService.java new file mode 100644 index 0000000000000000000000000000000000000000..db9ee2fdf19ec8f0742dd348132da028785857bc --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysDictTypeService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysDictTypeModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 字典类型表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysDictTypeService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysEmailService.java b/src/main/java/com/fc/test/dao/service/SysEmailService.java new file mode 100644 index 0000000000000000000000000000000000000000..612708b3f493756ef43128b2d7352251a4111dc9 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysEmailService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysEmailModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 电子邮件 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysEmailService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysFileDataService.java b/src/main/java/com/fc/test/dao/service/SysFileDataService.java new file mode 100644 index 0000000000000000000000000000000000000000..1c5e0331bb6d90d9af66171b7a372d004c201ed6 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysFileDataService.java @@ -0,0 +1,26 @@ +package com.fc.test.dao.service; + +import com.fc.test.dao.model.SysDatasModel; +import com.fc.test.dao.model.SysFileDataModel; +import com.baomidou.mybatisplus.extension.service.IService; + +import java.util.List; + +/** + *

+ * 文件数据外键绑定表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysFileDataService extends IService { + + /** + * 根据文件列表id查询出对应的文件信息,已经支持多个图片获取 + * + * @param fileid + * @return + */ + List queryfileID(String fileid); +} diff --git a/src/main/java/com/fc/test/dao/service/SysFileService.java b/src/main/java/com/fc/test/dao/service/SysFileService.java new file mode 100644 index 0000000000000000000000000000000000000000..a82bd4545d41dafa168ae59aede8cb7cf51f6467 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysFileService.java @@ -0,0 +1,33 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysFileModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 文件信息表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysFileService extends BaseIService { + + boolean insertSelective(SysFileModel file, String dataId); + + /** + * 删除文件存储表以及数据库 + * @param ids 文件集合 1,2,3 + * @return + */ + boolean deleteBydataFile(String ids); + + /** + * 修改信息 + * @param tsysFile + * @param dataId + * @return + */ + boolean updateByPrimaryKey(SysFileModel tsysFile, String dataId); +} diff --git a/src/main/java/com/fc/test/dao/service/SysInterUrlService.java b/src/main/java/com/fc/test/dao/service/SysInterUrlService.java new file mode 100644 index 0000000000000000000000000000000000000000..d5997d10a57d9e069c7b08fc6604e0c52b1942f7 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysInterUrlService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysInterUrlModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 拦截url表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysInterUrlService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysNoticeService.java b/src/main/java/com/fc/test/dao/service/SysNoticeService.java new file mode 100644 index 0000000000000000000000000000000000000000..b597506685e6d97907cf3d0ccfc2ea4b79faefaf --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysNoticeService.java @@ -0,0 +1,61 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.model.SysNoticeModel; +import com.fc.test.dao.model.SysUserModel; +import com.fc.test.model.custom.Tablepar; + +import java.util.List; + +/** + *

+ * 公告 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysNoticeService extends BaseIService { + + /** + * 获取用户未阅读公告 + * + * @param user + * @param state 阅读状态 0未阅读 1 阅读 -1全部 + * @return + */ + List getuserNoticeNotRead(SysUserModel user, int state); + + /** + * 分页查询 + * + * @param tablepar + * @param searchText + * @return + */ + PageInfo listTablepar(Tablepar tablepar, String searchText); + + /** + * 对应用户的所有公告信息 + * + * @param sysUserModel + * @param tablepar + * @param name + * @return + */ + PageInfo listTablepar(SysUserModel sysUserModel, Tablepar tablepar, String name); + + /** + * 检查name + * @param sysNotice + * @return + */ + int checkNameUnique(SysNoticeModel sysNotice); + + /** + * 根据公告id把当前用户的公告置为以查看 + * @param id + */ + void editUserState(String noticeid); +} diff --git a/src/main/java/com/fc/test/dao/service/SysNoticeUserService.java b/src/main/java/com/fc/test/dao/service/SysNoticeUserService.java new file mode 100644 index 0000000000000000000000000000000000000000..1685ec7353735b68131dcf61c5d960b13e259f86 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysNoticeUserService.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.service; + +import com.fc.test.dao.model.SysNoticeUserModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 公告_用户外键 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysNoticeUserService extends IService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysOperLogService.java b/src/main/java/com/fc/test/dao/service/SysOperLogService.java new file mode 100644 index 0000000000000000000000000000000000000000..06d0a4ade3361660c8dc0c391780b0aaa95ce072 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysOperLogService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysOperLogModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 日志记录表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysOperLogService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysPermissionRoleService.java b/src/main/java/com/fc/test/dao/service/SysPermissionRoleService.java new file mode 100644 index 0000000000000000000000000000000000000000..33bdb5f78f9d37505da652812836f724dc1c020d --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysPermissionRoleService.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.service; + +import com.fc.test.dao.model.SysPermissionRoleModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 角色权限中间表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysPermissionRoleService extends IService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysPermissionService.java b/src/main/java/com/fc/test/dao/service/SysPermissionService.java new file mode 100644 index 0000000000000000000000000000000000000000..e5d8d973d62a20529ce36e7cb6b974573b683ed2 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysPermissionService.java @@ -0,0 +1,65 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysPermissionModel; +import com.baomidou.mybatisplus.extension.service.IService; +import com.fc.test.model.custom.BootstrapTree; + +import java.util.List; + +/** + *

+ * 权限表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysPermissionService extends BaseIService { + /** + * 获取转换成bootstarp的权限数据 + * + * @return + */ + BootstrapTree getbooBootstrapTreePerm(String userId); + + /** + * 根据用户id获取用户角色如果用户为null 获取所有权限 + * + * @return + */ + List getall(String userid); + + /** + * 根据用户id查询出用户的所有权限 + * + * @param userid + * @return + */ + List findByAdminUserId(String userid); + + List list2(String searchText); + + /** + * 根据权限字段查询是否存在 + * @param perms + * @return + */ + boolean queryLikePerms(String perms); + + /** + * 根据角色id查询权限 + * @param rolid + * @return + */ + List queryRoleId(String rolid); + + int deleteByPrimaryKey(String ids); + + /** + * 获取角色已有的Bootstarp权限 + * @param roleId + * @return + */ + BootstrapTree getCheckPrem(String roleId); +} diff --git a/src/main/java/com/fc/test/dao/service/SysPositionService.java b/src/main/java/com/fc/test/dao/service/SysPositionService.java new file mode 100644 index 0000000000000000000000000000000000000000..075896f7c60d2bbf1ae1bdccc0e3e8af3fdadf1e --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysPositionService.java @@ -0,0 +1,18 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysPositionModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 岗位表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysPositionService extends BaseIService { + + +} diff --git a/src/main/java/com/fc/test/dao/service/SysProvinceService.java b/src/main/java/com/fc/test/dao/service/SysProvinceService.java new file mode 100644 index 0000000000000000000000000000000000000000..53b7873ceb2c8fd260f9c09ce0a4ce42f0c8cdd4 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysProvinceService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysProvinceModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 省份表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysProvinceService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysQuartzJobLogService.java b/src/main/java/com/fc/test/dao/service/SysQuartzJobLogService.java new file mode 100644 index 0000000000000000000000000000000000000000..1abe2e7f2dede96e3da2c475d3d3f841e86d710c --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysQuartzJobLogService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysQuartzJobLogModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 定时任务调度日志表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysQuartzJobLogService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysQuartzJobService.java b/src/main/java/com/fc/test/dao/service/SysQuartzJobService.java new file mode 100644 index 0000000000000000000000000000000000000000..f8548dffea4f30ec27278eafe34d27dcf08bc8dc --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysQuartzJobService.java @@ -0,0 +1,50 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysQuartzJobModel; +import com.baomidou.mybatisplus.extension.service.IService; +import org.quartz.SchedulerException; + +/** + *

+ * 定时任务调度表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysQuartzJobService extends BaseIService { + /** + * 任务调度状态修改 + * + * @param newJob + * @return + */ + boolean changeStatus(SysQuartzJobModel newJob) throws SchedulerException; + + /** + * 暂停任务 + * + * @param job + * @return + * @throws SchedulerException + */ + boolean pauseJob(SysQuartzJobModel job) throws SchedulerException; + + /** + * 恢复任务 + * + * @param job + * @return + * @throws SchedulerException + */ + boolean resumeJob(SysQuartzJobModel job) throws SchedulerException; + + /** + * 立即运行任务 + * + * @param sysQuartzJob 任务 + * @throws SchedulerException + */ + void run(SysQuartzJobModel sysQuartzJob) throws SchedulerException; +} diff --git a/src/main/java/com/fc/test/dao/service/SysRoleService.java b/src/main/java/com/fc/test/dao/service/SysRoleService.java new file mode 100644 index 0000000000000000000000000000000000000000..d538cc4fcb9d4f5df2f4d961452204bf997de78c --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysRoleService.java @@ -0,0 +1,41 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysRoleModel; +import com.baomidou.mybatisplus.extension.service.IService; + +import java.util.List; + +/** + *

+ * 角色表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysRoleService extends BaseIService { + /** + * 添加角色绑定权限 + * + * @param record 角色信息 + * @param prem 权限id集合 + * @return + */ + boolean insertRoleAndPrem(SysRoleModel record, String prem); + + /** + * 修改用户角色 以及下面绑定的权限 + * + * @param record + * @return + */ + boolean updateRoleAndPrem(SysRoleModel record, String prem); + + /** + * 根据用户id查询角色 + * @param uid + * @return + */ + List queryUserRole(String uid); +} diff --git a/src/main/java/com/fc/test/dao/service/SysRoleUserService.java b/src/main/java/com/fc/test/dao/service/SysRoleUserService.java new file mode 100644 index 0000000000000000000000000000000000000000..5ef2233f49fef9aabfbb4e8f2c04bc051aef63e5 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysRoleUserService.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.service; + +import com.fc.test.dao.model.SysRoleUserModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 用户角色中间表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysRoleUserService extends IService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysStreetService.java b/src/main/java/com/fc/test/dao/service/SysStreetService.java new file mode 100644 index 0000000000000000000000000000000000000000..3862276b3bdfb491560a3c753d7f46009af20c8e --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysStreetService.java @@ -0,0 +1,17 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysStreetModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 街道设置 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysStreetService extends BaseIService { + +} diff --git a/src/main/java/com/fc/test/dao/service/SysUserService.java b/src/main/java/com/fc/test/dao/service/SysUserService.java new file mode 100644 index 0000000000000000000000000000000000000000..e8e6a55c6a9572316b012a0e4927fd8cc81e35d6 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/SysUserService.java @@ -0,0 +1,51 @@ +package com.fc.test.dao.service; + +import com.fc.test.common.base.BaseIService; +import com.fc.test.dao.model.SysUserModel; +import com.baomidou.mybatisplus.extension.service.IService; +import com.fc.test.model.custom.RoleVo; + +import java.util.List; + +/** + *

+ * 用户表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface SysUserService extends BaseIService { + /** + * 根据username 查询 + * + * @param username + * @return + */ + SysUserModel queryUserName(String username); + + /** + * 添加用户跟角色信息 + * + * @param user + * @param roles + * @return + */ + boolean insertUserRoles(SysUserModel user, List roles); + + /** + * 获取所有权限 并且增加是否有权限字段 + * + * @param id + * @return + */ + List getUserIsRole(String id); + + /** + * 修改用户信息以及角色信息 + * @param tsysUser + * @param roles + * @return + */ + boolean updateUserRoles(SysUserModel tsysUser, List roles); +} diff --git a/src/main/java/com/fc/test/dao/service/TestService.java b/src/main/java/com/fc/test/dao/service/TestService.java new file mode 100644 index 0000000000000000000000000000000000000000..558c912d8ac3b69953da27f23de9ba9180128864 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/TestService.java @@ -0,0 +1,16 @@ +package com.fc.test.dao.service; + +import com.fc.test.dao.model.TestModel; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 测试表 服务类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +public interface TestService extends IService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysAreaServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysAreaServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..7549b60beb5807e85ded222a4ac84c53d691d6c9 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysAreaServiceImpl.java @@ -0,0 +1,26 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysAreaModel; +import com.fc.test.dao.mapper.SysAreaMapper; +import com.fc.test.dao.service.SysAreaService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +import java.util.List; + +/** + *

+ * 地区设置 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysAreaServiceImpl extends ServiceImpl implements SysAreaService { + + @Override + public List getByCityCode(String cityCode) { + return lambdaQuery().eq(SysAreaModel::getCityCode, cityCode).list(); + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysCityServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysCityServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..64d0668db6dde57ed0b84b4eda3d2400fa5da3b3 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysCityServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysCityModel; +import com.fc.test.dao.mapper.SysCityMapper; +import com.fc.test.dao.service.SysCityService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 城市设置 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysCityServiceImpl extends ServiceImpl implements SysCityService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysDatasServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysDatasServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..f1ff35965915cf0990f50edb4bc231361154fe67 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysDatasServiceImpl.java @@ -0,0 +1,57 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.common.conf.V2Config; +import com.fc.test.common.file.FileUploadUtils; +import com.fc.test.dao.model.SysDatasModel; +import com.fc.test.dao.mapper.SysDatasMapper; +import com.fc.test.dao.service.SysDatasService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.util.SnowflakeIdWorker; +import com.fc.test.util.StringUtils; +import org.springframework.stereotype.Service; +import org.springframework.web.multipart.MultipartFile; + +import java.io.IOException; + +/** + *

+ * 文件表存储表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysDatasServiceImpl extends ServiceImpl implements SysDatasService { + + @Override + public String insertSelective(MultipartFile file) throws IOException { + //文件上传获取文件名字 + String files = FileUploadUtils.upload(file); + //补充完整url地址 + String filesURL = ""; + if ("Y".equals(V2Config.getIsstatic())) { + filesURL = V2Config.getIsroot_dir() + files; + } else { + filesURL = V2Config.getProfile() + files; + } + String fileName = file.getOriginalFilename(); + // 获得文件后缀名称 + String suffixName = fileName.substring(fileName.lastIndexOf(".")).toLowerCase(); + if (StringUtils.isEmpty(suffixName)) { + //如果没有后缀默认后缀 + suffixName = FileUploadUtils.IMAGE_JPG_EXTENSION; + } + + SysDatasModel record = new SysDatasModel(); + //添加雪花主键id + record.setId(SnowflakeIdWorker.getUUID()); + record.setFilePath(filesURL); + record.setFileSuffix(suffixName); + if (save(record)) { + return record.getId(); + } else { + return null; + } + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysDepartmentServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysDepartmentServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..586335487cf25c19e9d7d8a5bceeeac4005a5d2b --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysDepartmentServiceImpl.java @@ -0,0 +1,66 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysDepartmentModel; +import com.fc.test.dao.mapper.SysDepartmentMapper; +import com.fc.test.dao.service.SysDepartmentService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.model.custom.BootstrapTree; +import org.springframework.stereotype.Service; + +import java.util.ArrayList; +import java.util.List; + +/** + *

+ * 部门表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysDepartmentServiceImpl extends ServiceImpl implements SysDepartmentService { + + @Override + public BootstrapTree getbooBootstrapTreePerm() { + List treeList = new ArrayList(); + List menuList = getall(); + treeList = getbooBootstrapTreePerm(menuList, "0"); + if (treeList != null && treeList.size() == 1) { + return treeList.get(0); + } + return new BootstrapTree("菜单", "fa fa-home", "", "-1", "###", 0, treeList, "", 0); + } + + /** + * 获取树 + * @param menuList + * @param parentId + * @return + */ + private static List getbooBootstrapTreePerm(List menuList, String parentId){ + List treeList = new ArrayList<>(); + List childList = null; + for(SysDepartmentModel p : menuList) { + p.setParentId(p.getParentId()==null||p.getParentId().trim().equals("")? "0":p.getParentId()); + if(p.getParentId().trim().equals(parentId)) { + if(p.getChildCount()!=null&&p.getChildCount()>0) { + childList = getbooBootstrapTreePerm(menuList, String.valueOf(p.getId())); + } + BootstrapTree bootstrapTree = new BootstrapTree(p.getDeptName(), "", "", String.valueOf(p.getId()), "",0,childList,p.getDeptName(),p.getStatus()); + treeList.add(bootstrapTree); + childList = null; + } + } + return treeList.size() >0 ? treeList : null; + } + + /** + * 根据用户id获取用户角色如果用户为null 获取所有权限 + * + * @return + */ + public List getall() { + return lambdaQuery().orderByAsc(SysDepartmentModel::getOrderNum).list(); + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysDictDataServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysDictDataServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..46c9dd17c70a232d8bd98983e976fff20439251b --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysDictDataServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysDictDataModel; +import com.fc.test.dao.mapper.SysDictDataMapper; +import com.fc.test.dao.service.SysDictDataService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 字典数据表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysDictDataServiceImpl extends ServiceImpl implements SysDictDataService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysDictTypeServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysDictTypeServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..d0b9a01ecff0c243c0080e5d2da65617f24d86a6 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysDictTypeServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysDictTypeModel; +import com.fc.test.dao.mapper.SysDictTypeMapper; +import com.fc.test.dao.service.SysDictTypeService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 字典类型表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysDictTypeServiceImpl extends ServiceImpl implements SysDictTypeService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysEmailServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysEmailServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..416d85a506687f24729dcc985bb31aeea863c5a3 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysEmailServiceImpl.java @@ -0,0 +1,44 @@ +package com.fc.test.dao.service.impl; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.fc.test.common.base.PageInfo; +import com.fc.test.common.interceptor.ListTableparInerceptor; +import com.fc.test.dao.model.SysEmailModel; +import com.fc.test.dao.mapper.SysEmailMapper; +import com.fc.test.dao.service.SysEmailService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.model.custom.Tablepar; +import com.fc.test.util.StringUtils; +import org.springframework.stereotype.Service; + +/** + *

+ * 电子邮件 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysEmailServiceImpl extends ServiceImpl implements SysEmailService { + +// @Override +// public PageInfo listTablepar(Tablepar tablepar, String column, String searchText, ListTableparInerceptor listTableparInerceptor) { +// System.out.println("SysEmailServiceImpl........"); +// QueryWrapper queryWrapper = new QueryWrapper<>(); +// queryWrapper.orderByAsc("id"); +// if (StringUtils.isNotBlank(searchText)) { +// queryWrapper.like(column, searchText); +// } +// +// if (listTableparInerceptor != null) listTableparInerceptor.call(queryWrapper); +// +// if (StringUtils.isNotBlank(tablepar.getOrderByColumn())) { +// String underColumn = StringUtils.toUnderScoreCase(tablepar.getOrderByColumn()); +// queryWrapper.orderBy(true, "asc".equals(tablepar.getIsAsc()), underColumn); +// } +// Page page = page(new Page<>(tablepar.getPageNum(), tablepar.getPageSize()), queryWrapper); +// return iPageToPageInfo(page); +// } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysFileDataServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysFileDataServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..84def883173cfcfd9256733bf6834600da5e17bf --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysFileDataServiceImpl.java @@ -0,0 +1,37 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysDatasModel; +import com.fc.test.dao.model.SysFileDataModel; +import com.fc.test.dao.mapper.SysFileDataMapper; +import com.fc.test.dao.service.SysDatasService; +import com.fc.test.dao.service.SysFileDataService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.util.*; +import java.util.stream.Collectors; + +/** + *

+ * 文件数据外键绑定表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysFileDataServiceImpl extends ServiceImpl implements SysFileDataService { + private final SysDatasService sysDatasService; + + @Override + public List queryfileID(String fileid) { + List sysFileDataModels = lambdaQuery().eq(SysFileDataModel::getFileId, fileid).list(); + if (sysFileDataModels.isEmpty()) return Collections.emptyList(); + Set dataIds = sysFileDataModels.stream().map(SysFileDataModel::getDataId).collect(Collectors.toSet()); + return sysDatasService.lambdaQuery().in(SysDatasModel::getId, dataIds).list(); + + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysFileServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysFileServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..841ff55b05832494b976fba85ee4745964ef3904 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysFileServiceImpl.java @@ -0,0 +1,120 @@ +package com.fc.test.dao.service.impl; + +import cn.hutool.core.io.FileUtil; +import com.fc.test.common.conf.V2Config; +import com.fc.test.common.support.Convert; +import com.fc.test.dao.model.SysDatasModel; +import com.fc.test.dao.model.SysFileDataModel; +import com.fc.test.dao.model.SysFileModel; +import com.fc.test.dao.mapper.SysFileMapper; +import com.fc.test.dao.service.SysDatasService; +import com.fc.test.dao.service.SysFileDataService; +import com.fc.test.dao.service.SysFileService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.shiro.util.ShiroUtils; +import com.fc.test.util.SnowflakeIdWorker; +import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.util.ClassUtils; + +import java.util.Date; +import java.util.List; + +/** + *

+ * 文件信息表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysFileServiceImpl extends ServiceImpl implements SysFileService { + private final SysFileDataService sysFileDataService; + private final SysDatasService sysDatasService; + + @Transactional + @Override + public boolean insertSelective(SysFileModel record, String dataId) { + //插入创建人id + record.setCreateUserId(ShiroUtils.getUserId()); + //插入创建人name + record.setCreateUserName(ShiroUtils.getLoginName()); + //插入创建时间 + record.setCreateTime(new Date()); + //添加雪花主键id + record.setId(SnowflakeIdWorker.getUUID()); + //插入关联表 + SysFileDataModel tsysFileData = new SysFileDataModel(); + tsysFileData.setId(SnowflakeIdWorker.getUUID()); + tsysFileData.setFileId(record.getId()); + tsysFileData.setDataId(dataId); + if (sysFileDataService.save(tsysFileData)) { + throw new RuntimeException("保存文件数据失败"); + } + if (save(record)) { + throw new RuntimeException("保存文件失败"); + } + return true; + } + + @Override + public boolean deleteBydataFile(String ids) { + List lista = Convert.toListStrArray(ids); + List sysDatasModels = sysDatasService.lambdaQuery().in(SysDatasModel::getId, lista).list(); + //删除本地文件 + sysDatasModels.forEach(it -> { + deletefile(it.getFilePath()); + sysDatasService.removeById(it.getId()); + }); + return true; + } + + @Override + public boolean updateByPrimaryKey(SysFileModel record, String dataId) { + //获取旧数据 + SysFileModel old_data = getById(record.getId()); + + //删除绑定数据 + sysFileDataService.lambdaUpdate() + .eq(SysFileDataModel::getFileId, record.getId()) + .remove(); + + + //插入关联表 + SysFileDataModel tsysFileData = new SysFileDataModel(); + tsysFileData.setId(SnowflakeIdWorker.getUUID()); + tsysFileData.setFileId(record.getId()); + tsysFileData.setDataId(dataId); + if (!sysFileDataService.save(tsysFileData)) { + throw new RuntimeException("插入关联信息失败!"); + } + + //修改旧数据 + //插入修改人id + old_data.setUpdateUserId(ShiroUtils.getUserId()); + //插入修改人name + old_data.setUpdateUserName(ShiroUtils.getLoginName()); + //插入修改时间 + old_data.setUpdateTime(new Date()); + if (!updateById(old_data)) { + throw new RuntimeException("修改数据失败"); + } + return true; + } + + /** + * 删除本地文件方法 + */ + public void deletefile(String filePath) { + if ("Y".equals(V2Config.getIsstatic())) { + String url = ClassUtils.getDefaultClassLoader().getResource("").getPath() + filePath; + FileUtil.del(url); + } else { + FileUtil.del(filePath); + } + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysInterUrlServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysInterUrlServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..a0194939a7e68880768d0b8d7572259b0968a247 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysInterUrlServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysInterUrlModel; +import com.fc.test.dao.mapper.SysInterUrlMapper; +import com.fc.test.dao.service.SysInterUrlService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 拦截url表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysInterUrlServiceImpl extends ServiceImpl implements SysInterUrlService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysNoticeServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysNoticeServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..9edbeb7155492e04ac7d1be4ee16c230a508ae69 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysNoticeServiceImpl.java @@ -0,0 +1,97 @@ +package com.fc.test.dao.service.impl; + +import com.baomidou.mybatisplus.extension.conditions.query.LambdaQueryChainWrapper; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.common.base.PageInfo; +import com.fc.test.dao.mapper.SysNoticeMapper; +import com.fc.test.dao.model.SysNoticeModel; +import com.fc.test.dao.model.SysNoticeUserModel; +import com.fc.test.dao.model.SysUserModel; +import com.fc.test.dao.service.SysNoticeService; +import com.fc.test.dao.service.SysNoticeUserService; +import com.fc.test.model.custom.Tablepar; +import com.fc.test.shiro.util.ShiroUtils; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.util.Collections; +import java.util.List; +import java.util.Set; +import java.util.stream.Collectors; + +/** + *

+ * 公告 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +@Service +public class SysNoticeServiceImpl extends ServiceImpl implements SysNoticeService { + private final SysNoticeUserService sysNoticeUserService; + + + @Override + public List getuserNoticeNotRead(SysUserModel user, int state) { + LambdaQueryChainWrapper lambdaQueryChainWrapper = sysNoticeUserService.lambdaQuery().eq(SysNoticeUserModel::getUserId, user.getId()); + //阅读状态 + if (-1 != state) lambdaQueryChainWrapper.eq(SysNoticeUserModel::getState, state); + //查询列表 + List sysNoticeUserModelList = lambdaQueryChainWrapper.list(); + //查询到的数据为空 直接返回空集合 + if (sysNoticeUserModelList.isEmpty()) return Collections.emptyList(); + + Set noticeIds = sysNoticeUserModelList.stream().map(SysNoticeUserModel::getNoticeId).collect(Collectors.toSet()); + return lambdaQuery().in(SysNoticeModel::getId, noticeIds).list(); + } + + @Override + public PageInfo listTablepar(Tablepar tablepar, String searchText) { + LambdaQueryChainWrapper lambdaQuery = lambdaQuery().orderByAsc(SysNoticeModel::getId); + if (StringUtils.isNotEmpty(searchText)) { + lambdaQuery.like(SysNoticeModel::getTitle, searchText); + } + Page page = page(new Page<>(tablepar.getPageNum(), tablepar.getPageSize()), lambdaQuery); + return iPageToPageInfo(page); + } + + @Override + public PageInfo listTablepar(SysUserModel sysUserModel, Tablepar tablepar, String name) { + //查询未阅读的公告用户外键 + List sysNoticeUserModels = sysNoticeUserService.lambdaQuery().eq(SysNoticeUserModel::getUserId, sysUserModel.getId()).list(); + if (sysNoticeUserModels.isEmpty()) { + return new PageInfo(Collections.emptyList()); + } + + Set noticeIds = sysNoticeUserModels.stream().map(SysNoticeUserModel::getNoticeId).collect(Collectors.toSet()); + + LambdaQueryChainWrapper lambdaQuery = lambdaQuery().orderByAsc(SysNoticeModel::getId).in(SysNoticeModel::getId, noticeIds); + if (StringUtils.isNotBlank(name)) { + lambdaQuery.like(SysNoticeModel::getTitle, name); + } + //分页查询 + Page sysNoticeModelPage = page(new Page<>(tablepar.getPageNum(), tablepar.getPageSize()), lambdaQuery); + return iPageToPageInfo(sysNoticeModelPage); + } + + @Override + public int checkNameUnique(SysNoticeModel sysNotice) { + return lambdaQuery().eq(SysNoticeModel::getTitle, sysNotice.getTitle()).list().size(); + } + + @Override + public void editUserState(String noticeid) { + SysNoticeUserModel sysNoticeUserModel = new SysNoticeUserModel(); + sysNoticeUserModel.setState(1); + //更新 + sysNoticeUserService.lambdaUpdate() + .eq(SysNoticeUserModel::getNoticeId, noticeid) + .eq(SysNoticeUserModel::getUserId, ShiroUtils.getUserId()) + .update(sysNoticeUserModel); + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysNoticeUserServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysNoticeUserServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..6516bf75e2fc27ccdc395a9a5f09eeaae13fe844 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysNoticeUserServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysNoticeUserModel; +import com.fc.test.dao.mapper.SysNoticeUserMapper; +import com.fc.test.dao.service.SysNoticeUserService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 公告_用户外键 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysNoticeUserServiceImpl extends ServiceImpl implements SysNoticeUserService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysOperLogServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysOperLogServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..5e53ae423d9d76a582c60fe2be41b43505a5913d --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysOperLogServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysOperLogModel; +import com.fc.test.dao.mapper.SysOperLogMapper; +import com.fc.test.dao.service.SysOperLogService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 日志记录表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysOperLogServiceImpl extends ServiceImpl implements SysOperLogService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysPermissionRoleServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysPermissionRoleServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..c6576bd137dac14e62c5b4314bcd4184f46b4aa9 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysPermissionRoleServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysPermissionRoleModel; +import com.fc.test.dao.mapper.SysPermissionRoleMapper; +import com.fc.test.dao.service.SysPermissionRoleService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 角色权限中间表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysPermissionRoleServiceImpl extends ServiceImpl implements SysPermissionRoleService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysPermissionServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysPermissionServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..e43e25cf8db657b6a928c9583047fef857ed9cc7 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysPermissionServiceImpl.java @@ -0,0 +1,179 @@ +package com.fc.test.dao.service.impl; + +import com.baomidou.mybatisplus.extension.conditions.query.LambdaQueryChainWrapper; +import com.fc.test.common.support.Convert; +import com.fc.test.dao.model.SysPermissionModel; +import com.fc.test.dao.mapper.SysPermissionMapper; +import com.fc.test.dao.model.SysPermissionRoleModel; +import com.fc.test.dao.service.SysPermissionRoleService; +import com.fc.test.dao.service.SysPermissionService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.model.custom.BootstrapTree; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + *

+ * 权限表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +@Service +public class SysPermissionServiceImpl extends ServiceImpl implements SysPermissionService { + private final SysPermissionRoleService sysPermissionRoleService; + + @Override + public BootstrapTree getbooBootstrapTreePerm(String userId) { + List treeList = new ArrayList(); + List menuList = getall(userId); + treeList = getbooBootstrapTreePerm(menuList, "0"); + if (treeList != null && treeList.size() == 1) { + return treeList.get(0); + } + return new BootstrapTree("菜单", "fa fa-home", "", "-1", "###", 0, treeList, "", 0); + } + + /** + * 获取树 + * + * @param menuList + * @param parentId + * @return + */ + private static List getbooBootstrapTreePerm(List menuList, String parentId) { + List treeList = new ArrayList<>(); + List childList = null; + for (SysPermissionModel p : menuList) { + p.setPid(p.getPid() == null || p.getPid().trim().equals("") ? "0" : p.getPid()); + if (p.getPid().trim().equals(parentId)) { + if (p.getChildCount() != null && p.getChildCount() > 0) { + childList = getbooBootstrapTreePerm(menuList, String.valueOf(p.getId())); + } + BootstrapTree bootstrapTree = new BootstrapTree(p.getName(), p.getIcon(), "", String.valueOf(p.getId()), p.getUrl(), p.getIsBlank(), childList, p.getPerms(), p.getVisible()); + treeList.add(bootstrapTree); + childList = null; + } + } + return treeList.size() > 0 ? treeList : null; + } + + @Override + public List getall(String userid) { + if (StringUtils.isEmpty(userid)) { + return lambdaQuery().orderByAsc(SysPermissionModel::getOrderNum).list(); + } + return findByAdminUserId(userid); + } + + + @Override + public List findByAdminUserId(String userid) { + return baseMapper.findByAdminUserId(userid); + } + + @Override + public List list2(String searchText) { + LambdaQueryChainWrapper lambdaQueryChainWrapper = lambdaQuery().orderByAsc(SysPermissionModel::getOrderNum); + if (StringUtils.isNotBlank(searchText)) { + lambdaQueryChainWrapper.like(SysPermissionModel::getName, searchText); + } + return lambdaQueryChainWrapper.list(); + } + + @Override + public boolean queryLikePerms(String perms) { + List list = lambdaQuery().like(SysPermissionModel::getPerms, "gen:" + perms).list(); + return !list.isEmpty(); + } + + @Override + public List queryRoleId(String rolid) { + return baseMapper.queryRoleId(rolid); + } + + @Override + public int deleteByPrimaryKey(String ids) { + //转成集合 + List lista = Convert.toListStrArray(ids); + + List sysPermissionRoleModels = sysPermissionRoleService.lambdaQuery().in(SysPermissionRoleModel::getPermissionId, lista).list(); + //判断角色是否删除去除 + if (sysPermissionRoleModels.size() > 0) {//有角色外键 + return -2; + } + + //判断是否有子集 + List sysPermissionModels = lambdaQuery().in(SysPermissionModel::getId, lista).list(); + boolean flag = !sysPermissionModels.isEmpty(); + if (flag) { + //有子集 无法删除 + return -1; + } else { + //删除操作 + boolean remove = lambdaUpdate().in(SysPermissionModel::getId, lista).remove(); + return remove ? 1 : 0; + } + } + + @Override + public BootstrapTree getCheckPrem(String roleId) { + Map map = new HashMap(); + //设置选中 + map.put("checked", true); + //设置展开 + //map.put("expanded", true); + // 获取角色的权限 + List myTsysPermissions = queryRoleId(roleId); + // 获取所有的权限 + BootstrapTree sysPermissions = getbooBootstrapTreePerm(null); + iterationCheckPre(sysPermissions, myTsysPermissions, map); + return sysPermissions; + } + /** + * 循环迭代获取所有权限 + * @param pboostrapTree + * @param myTsysPermissions + * @param map + */ + public void iterationCheckPre(BootstrapTree pboostrapTree, List myTsysPermissions, Map map) { + if(null!=pboostrapTree) { + if (ifpermissions(myTsysPermissions, pboostrapTree)) { + pboostrapTree.setState(map); + } + List bootstrapTreeList = pboostrapTree.getNodes(); + if(null!=bootstrapTreeList&&!bootstrapTreeList.isEmpty()) { + for(BootstrapTree bootstrapTree : bootstrapTreeList) { + if (ifpermissions(myTsysPermissions, bootstrapTree)) {// 菜单栏设置 + bootstrapTree.setState(map); + } + //检查子节点 + iterationCheckPre(bootstrapTree, myTsysPermissions, map); + } + } + } + } + /** + * 判断权限是否有权限 + * @param myTsysPermissions + * @param sysPermission + */ + public Boolean ifpermissions(List myTsysPermissions, BootstrapTree sysPermission){ + for (SysPermissionModel mytsysPermission : myTsysPermissions) { + if(sysPermission.getId().equals(mytsysPermission.getId())){ + return true; + } + } + return false; + } + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysPositionServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysPositionServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..429a56bb5f22225b6dc8fc4cf608e1b543c79674 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysPositionServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysPositionModel; +import com.fc.test.dao.mapper.SysPositionMapper; +import com.fc.test.dao.service.SysPositionService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 岗位表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysPositionServiceImpl extends ServiceImpl implements SysPositionService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysProvinceServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysProvinceServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..e147d2522a3ba10bdce300626dd97afbb1ba556c --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysProvinceServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysProvinceModel; +import com.fc.test.dao.mapper.SysProvinceMapper; +import com.fc.test.dao.service.SysProvinceService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 省份表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysProvinceServiceImpl extends ServiceImpl implements SysProvinceService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysQuartzJobLogServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysQuartzJobLogServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..efab371018923c52bd8bd931f218c4ba06fe9f51 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysQuartzJobLogServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysQuartzJobLogModel; +import com.fc.test.dao.mapper.SysQuartzJobLogMapper; +import com.fc.test.dao.service.SysQuartzJobLogService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 定时任务调度日志表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysQuartzJobLogServiceImpl extends ServiceImpl implements SysQuartzJobLogService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysQuartzJobServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysQuartzJobServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..5e1a4719612c2e25828bd72e3361e8b0b8fd40b0 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysQuartzJobServiceImpl.java @@ -0,0 +1,80 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.common.quartz.QuartzSchedulerUtil; +import com.fc.test.common.quartz.ScheduleConstants; +import com.fc.test.dao.model.SysQuartzJobModel; +import com.fc.test.dao.mapper.SysQuartzJobMapper; +import com.fc.test.dao.service.SysQuartzJobService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import lombok.RequiredArgsConstructor; +import org.quartz.SchedulerException; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +/** + *

+ * 定时任务调度表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysQuartzJobServiceImpl extends ServiceImpl implements SysQuartzJobService { + @Autowired + private QuartzSchedulerUtil scheduler; + + @Transactional + @Override + public boolean changeStatus(SysQuartzJobModel newJob) throws SchedulerException { + Integer status = newJob.getStatus(); + if (ScheduleConstants.Status.NORMAL.getValue().equals(status)) { + if (resumeJob(newJob)) { + throw new RuntimeException("修改任务调度状态失败!"); + } + } else if (ScheduleConstants.Status.PAUSE.getValue().equals(status)) { + if (pauseJob(newJob)) { + throw new RuntimeException("修改任务调度状态失败!"); + } + } + return true; + } + + /** + * 暂停任务 + * + * @param job 调度信息 + */ + @Override + public boolean pauseJob(SysQuartzJobModel job) throws SchedulerException { + job.setStatus(ScheduleConstants.Status.PAUSE.getValue()); + //job.setUpdateBy(ShiroUtils.getLoginName()); + if (updateById(job)) { + scheduler.pauseJob(job); + return true; + } else { + return false; + } + } + + /** + * 恢复任务 + * + * @param job 调度信息 + */ + @Override + public boolean resumeJob(SysQuartzJobModel job) throws SchedulerException { + job.setStatus(ScheduleConstants.Status.NORMAL.getValue()); + if (updateById(job)) { + scheduler.resumeJob(job); + return true; + } + return false; + } + + @Override + public void run(SysQuartzJobModel sysQuartzJob) throws SchedulerException { + scheduler.run(sysQuartzJob); + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysRoleServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysRoleServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..56996399a6607f0dc393540056f0f0a77f1ace53 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysRoleServiceImpl.java @@ -0,0 +1,67 @@ +package com.fc.test.dao.service.impl; + +import cn.hutool.core.util.RandomUtil; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.common.support.Convert; +import com.fc.test.dao.mapper.SysRoleMapper; +import com.fc.test.dao.model.SysPermissionRoleModel; +import com.fc.test.dao.model.SysRoleModel; +import com.fc.test.dao.service.SysPermissionRoleService; +import com.fc.test.dao.service.SysRoleService; +import com.fc.test.util.SnowflakeIdWorker; +import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import java.util.LinkedList; +import java.util.List; + +/** + *

+ * 角色表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +@Service +public class SysRoleServiceImpl extends ServiceImpl implements SysRoleService { + private final SysPermissionRoleService sysPermissionRoleService; + + @Transactional + @Override + public boolean insertRoleAndPrem(SysRoleModel record, String prem) { + //添加雪花主键id + String roleid = SnowflakeIdWorker.getUUID(); + record.setId(roleid); + //添加权限 + List prems = Convert.toListStrArray(prem); + for (String premid : prems) { + SysPermissionRoleModel tsysPermissionRole = new SysPermissionRoleModel(RandomUtil.randomUUID(), roleid, premid); + sysPermissionRoleService.save(tsysPermissionRole); + } + return save(record); + } + + @Transactional + @Override + public boolean updateRoleAndPrem(SysRoleModel record, String prem) { + boolean remove = sysPermissionRoleService.lambdaUpdate() + .eq(SysPermissionRoleModel::getRoleId, record.getId()) + .remove(); + List prems = Convert.toListStrArray(prem); + if (prems.isEmpty()) return true; + LinkedList sysPermissionRoleModels = new LinkedList(); + prems.forEach(it -> { + sysPermissionRoleModels.add(new SysPermissionRoleModel(RandomUtil.randomUUID(), record.getId(), it)); + }); + return sysPermissionRoleService.saveBatch(sysPermissionRoleModels); + } + + @Override + public List queryUserRole(String uid) { + return baseMapper.queryUserRole(uid); + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysRoleUserServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysRoleUserServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..df38739f2cede3914a4c75788792c1511869da57 --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysRoleUserServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysRoleUserModel; +import com.fc.test.dao.mapper.SysRoleUserMapper; +import com.fc.test.dao.service.SysRoleUserService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 用户角色中间表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysRoleUserServiceImpl extends ServiceImpl implements SysRoleUserService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysStreetServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysStreetServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..52ccba33e258fd22f32fe9ac67b3710db9d0eaab --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysStreetServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysStreetModel; +import com.fc.test.dao.mapper.SysStreetMapper; +import com.fc.test.dao.service.SysStreetService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 街道设置 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class SysStreetServiceImpl extends ServiceImpl implements SysStreetService { + +} diff --git a/src/main/java/com/fc/test/dao/service/impl/SysUserServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/SysUserServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..bdd46e7996bc9eb983ca508539a5f04db9a579de --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/SysUserServiceImpl.java @@ -0,0 +1,100 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.SysRoleModel; +import com.fc.test.dao.model.SysRoleUserModel; +import com.fc.test.dao.model.SysUserModel; +import com.fc.test.dao.mapper.SysUserMapper; +import com.fc.test.dao.service.SysRoleService; +import com.fc.test.dao.service.SysRoleUserService; +import com.fc.test.dao.service.SysUserService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.fc.test.model.custom.RoleVo; +import com.fc.test.util.MD5Util; +import com.fc.test.util.SnowflakeIdWorker; +import com.fc.test.util.StringUtils; +import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.List; + +/** + *

+ * 用户表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) +public class SysUserServiceImpl extends ServiceImpl implements SysUserService { + private final SysRoleUserService sysRoleUserService; + private final SysRoleService sysRoleService; + + @Override + public SysUserModel queryUserName(String username) { + return lambdaQuery().eq(SysUserModel::getUsername, username).one(); + } + + @Override + public boolean insertUserRoles(SysUserModel record, List roles) { + String userid = SnowflakeIdWorker.getUUID(); + record.setId(userid); + if (StringUtils.isNotEmpty(roles)) { + for (String rolesid : roles) { + SysRoleUserModel roleUser = new SysRoleUserModel(SnowflakeIdWorker.getUUID(), userid, rolesid); + sysRoleUserService.save(roleUser); + } + } + + //密码加密 + record.setPassword(MD5Util.encode(record.getPassword())); + return save(record); + } + + @Override + public List getUserIsRole(String userid) { + List list = new ArrayList(); + //查询出我的权限 + List myRoles = sysRoleService.queryUserRole(userid); + //查询系统所有的角色 + List sysRoleModels = sysRoleService.list(); + if (sysRoleModels.isEmpty()) return Collections.emptyList(); + sysRoleModels.forEach(it -> { + boolean isflag = false; + RoleVo roleVo = new RoleVo(it.getId(), it.getName(), isflag); + for (SysRoleModel myRole : myRoles) { + if (it.getId().equals(myRole.getId())) { + isflag = true; + break; + } + } + if (isflag) { + roleVo.setIscheck(true); + list.add(roleVo); + } else { + list.add(roleVo); + } + }); + return list; + } + + @Override + public boolean updateUserRoles(SysUserModel record, List roles) { + //先删除这个用户的所有角色 + sysRoleUserService.lambdaUpdate().eq(SysRoleUserModel::getSysUserId, record.getId()).remove(); + if (roles == null || roles.isEmpty()) return true; + + List newRoles = new ArrayList<>(roles.size()); + roles.forEach(it -> { + SysRoleUserModel sysRoleUserModel = new SysRoleUserModel(SnowflakeIdWorker.getUUID(), record.getId(), it); + newRoles.add(sysRoleUserModel); + }); + //添加新的角色信息 + return sysRoleUserService.saveBatch(newRoles); + } +} diff --git a/src/main/java/com/fc/test/dao/service/impl/TestServiceImpl.java b/src/main/java/com/fc/test/dao/service/impl/TestServiceImpl.java new file mode 100644 index 0000000000000000000000000000000000000000..bb96f74e26601b6e773f9da6a55a7cb6169642bb --- /dev/null +++ b/src/main/java/com/fc/test/dao/service/impl/TestServiceImpl.java @@ -0,0 +1,20 @@ +package com.fc.test.dao.service.impl; + +import com.fc.test.dao.model.TestModel; +import com.fc.test.dao.mapper.TestMapper; +import com.fc.test.dao.service.TestService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 测试表 服务实现类 + *

+ * + * @author pencilso + * @since 2020-04-22 + */ +@Service +public class TestServiceImpl extends ServiceImpl implements TestService { + +} diff --git a/src/main/java/com/fc/test/mapper/auto/SysAreaMapper.java b/src/main/java/com/fc/test/mapper/auto/SysAreaMapper.java deleted file mode 100644 index 070f8514bfc1d3f79cedbafd4eccf93b50b22aab..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysAreaMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysArea; -import com.fc.test.model.auto.SysAreaExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface SysAreaMapper { - long countByExample(SysAreaExample example); - - int deleteByExample(SysAreaExample example); - - int deleteByPrimaryKey(Integer id); - - int insert(SysArea record); - - int insertSelective(SysArea record); - - List selectByExample(SysAreaExample example); - - SysArea selectByPrimaryKey(Integer id); - - int updateByExampleSelective(@Param("record") SysArea record, @Param("example") SysAreaExample example); - - int updateByExample(@Param("record") SysArea record, @Param("example") SysAreaExample example); - - int updateByPrimaryKeySelective(SysArea record); - - int updateByPrimaryKey(SysArea record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysCityMapper.java b/src/main/java/com/fc/test/mapper/auto/SysCityMapper.java deleted file mode 100644 index aa08dd7b354f5f37a8ab753b1527d0c46152bede..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysCityMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysCity; -import com.fc.test.model.auto.SysCityExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface SysCityMapper { - long countByExample(SysCityExample example); - - int deleteByExample(SysCityExample example); - - int deleteByPrimaryKey(Integer id); - - int insert(SysCity record); - - int insertSelective(SysCity record); - - List selectByExample(SysCityExample example); - - SysCity selectByPrimaryKey(Integer id); - - int updateByExampleSelective(@Param("record") SysCity record, @Param("example") SysCityExample example); - - int updateByExample(@Param("record") SysCity record, @Param("example") SysCityExample example); - - int updateByPrimaryKeySelective(SysCity record); - - int updateByPrimaryKey(SysCity record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysDepartmentMapper.java b/src/main/java/com/fc/test/mapper/auto/SysDepartmentMapper.java deleted file mode 100644 index cc3acf62dc145a197a6c18d63dba7d154be0d284..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysDepartmentMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysDepartment; -import com.fc.test.model.auto.SysDepartmentExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 部门表 SysDepartmentMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-17 13:12:58 - */ -public interface SysDepartmentMapper { - - long countByExample(SysDepartmentExample example); - - int deleteByExample(SysDepartmentExample example); - - int deleteByPrimaryKey(Integer id); - - int insert(SysDepartment record); - - int insertSelective(SysDepartment record); - - List selectByExample(SysDepartmentExample example); - - SysDepartment selectByPrimaryKey(Integer id); - - int updateByExampleSelective(@Param("record") SysDepartment record, @Param("example") SysDepartmentExample example); - - int updateByExample(@Param("record") SysDepartment record, @Param("example") SysDepartmentExample example); - - int updateByPrimaryKeySelective(SysDepartment record); - - int updateByPrimaryKey(SysDepartment record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysInterUrlMapper.java b/src/main/java/com/fc/test/mapper/auto/SysInterUrlMapper.java deleted file mode 100644 index b072791b74a6e068ddd17eccaa2cacc755d65bb9..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysInterUrlMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysInterUrl; -import com.fc.test.model.auto.SysInterUrlExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 拦截url表 SysInterUrlMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-01-05 01:48:22 - */ -public interface SysInterUrlMapper { - - long countByExample(SysInterUrlExample example); - - int deleteByExample(SysInterUrlExample example); - - int deleteByPrimaryKey(String id); - - int insert(SysInterUrl record); - - int insertSelective(SysInterUrl record); - - List selectByExample(SysInterUrlExample example); - - SysInterUrl selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") SysInterUrl record, @Param("example") SysInterUrlExample example); - - int updateByExample(@Param("record") SysInterUrl record, @Param("example") SysInterUrlExample example); - - int updateByPrimaryKeySelective(SysInterUrl record); - - int updateByPrimaryKey(SysInterUrl record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysNoticeMapper.java b/src/main/java/com/fc/test/mapper/auto/SysNoticeMapper.java deleted file mode 100644 index c4e546be4d1b73b1ed8d5431a5262525d9a63fa5..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysNoticeMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysNotice; -import com.fc.test.model.auto.SysNoticeExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 公告 SysNoticeMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 01:38:44 - */ -public interface SysNoticeMapper { - - long countByExample(SysNoticeExample example); - - int deleteByExample(SysNoticeExample example); - - int deleteByPrimaryKey(String id); - - int insert(SysNotice record); - - int insertSelective(SysNotice record); - - List selectByExample(SysNoticeExample example); - - SysNotice selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") SysNotice record, @Param("example") SysNoticeExample example); - - int updateByExample(@Param("record") SysNotice record, @Param("example") SysNoticeExample example); - - int updateByPrimaryKeySelective(SysNotice record); - - int updateByPrimaryKey(SysNotice record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysNoticeUserMapper.java b/src/main/java/com/fc/test/mapper/auto/SysNoticeUserMapper.java deleted file mode 100644 index b6aaf00f51fdb3746bc6aaf32c74d1e14b1154d1..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysNoticeUserMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysNoticeUser; -import com.fc.test.model.auto.SysNoticeUserExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 公告_用户外键 SysNoticeUserMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 02:12:54 - */ -public interface SysNoticeUserMapper { - - long countByExample(SysNoticeUserExample example); - - int deleteByExample(SysNoticeUserExample example); - - int deleteByPrimaryKey(String id); - - int insert(SysNoticeUser record); - - int insertSelective(SysNoticeUser record); - - List selectByExample(SysNoticeUserExample example); - - SysNoticeUser selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") SysNoticeUser record, @Param("example") SysNoticeUserExample example); - - int updateByExample(@Param("record") SysNoticeUser record, @Param("example") SysNoticeUserExample example); - - int updateByPrimaryKeySelective(SysNoticeUser record); - - int updateByPrimaryKey(SysNoticeUser record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysPositionMapper.java b/src/main/java/com/fc/test/mapper/auto/SysPositionMapper.java deleted file mode 100644 index a403ab6d4e593034724ae726e5815f1b6d56f82e..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysPositionMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysPosition; -import com.fc.test.model.auto.SysPositionExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 岗位表 SysPositionMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-16 23:46:24 - */ -public interface SysPositionMapper { - - long countByExample(SysPositionExample example); - - int deleteByExample(SysPositionExample example); - - int deleteByPrimaryKey(String id); - - int insert(SysPosition record); - - int insertSelective(SysPosition record); - - List selectByExample(SysPositionExample example); - - SysPosition selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") SysPosition record, @Param("example") SysPositionExample example); - - int updateByExample(@Param("record") SysPosition record, @Param("example") SysPositionExample example); - - int updateByPrimaryKeySelective(SysPosition record); - - int updateByPrimaryKey(SysPosition record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysProvinceMapper.java b/src/main/java/com/fc/test/mapper/auto/SysProvinceMapper.java deleted file mode 100644 index 87bef57159514cac9014c530f2f43f682b7b86bf..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysProvinceMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysProvince; -import com.fc.test.model.auto.SysProvinceExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface SysProvinceMapper { - long countByExample(SysProvinceExample example); - - int deleteByExample(SysProvinceExample example); - - int deleteByPrimaryKey(Integer id); - - int insert(SysProvince record); - - int insertSelective(SysProvince record); - - List selectByExample(SysProvinceExample example); - - SysProvince selectByPrimaryKey(Integer id); - - int updateByExampleSelective(@Param("record") SysProvince record, @Param("example") SysProvinceExample example); - - int updateByExample(@Param("record") SysProvince record, @Param("example") SysProvinceExample example); - - int updateByPrimaryKeySelective(SysProvince record); - - int updateByPrimaryKey(SysProvince record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysQuartzJobLogMapper.java b/src/main/java/com/fc/test/mapper/auto/SysQuartzJobLogMapper.java deleted file mode 100644 index ac339c9f3b1db7f5f07b6b6f1507f59981245352..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysQuartzJobLogMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysQuartzJobLog; -import com.fc.test.model.auto.SysQuartzJobLogExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 定时任务调度日志表 SysQuartzJobLogMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:42 - */ -public interface SysQuartzJobLogMapper { - - long countByExample(SysQuartzJobLogExample example); - - int deleteByExample(SysQuartzJobLogExample example); - - int deleteByPrimaryKey(String id); - - int insert(SysQuartzJobLog record); - - int insertSelective(SysQuartzJobLog record); - - List selectByExample(SysQuartzJobLogExample example); - - SysQuartzJobLog selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") SysQuartzJobLog record, @Param("example") SysQuartzJobLogExample example); - - int updateByExample(@Param("record") SysQuartzJobLog record, @Param("example") SysQuartzJobLogExample example); - - int updateByPrimaryKeySelective(SysQuartzJobLog record); - - int updateByPrimaryKey(SysQuartzJobLog record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysQuartzJobMapper.java b/src/main/java/com/fc/test/mapper/auto/SysQuartzJobMapper.java deleted file mode 100644 index 087de99b28d3cd7f5000d8e42adc1af28565bddb..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysQuartzJobMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysQuartzJob; -import com.fc.test.model.auto.SysQuartzJobExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 定时任务调度表 SysQuartzJobMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:35 - */ -public interface SysQuartzJobMapper { - - long countByExample(SysQuartzJobExample example); - - int deleteByExample(SysQuartzJobExample example); - - int deleteByPrimaryKey(String id); - - int insert(SysQuartzJob record); - - int insertSelective(SysQuartzJob record); - - List selectByExample(SysQuartzJobExample example); - - SysQuartzJob selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") SysQuartzJob record, @Param("example") SysQuartzJobExample example); - - int updateByExample(@Param("record") SysQuartzJob record, @Param("example") SysQuartzJobExample example); - - int updateByPrimaryKeySelective(SysQuartzJob record); - - int updateByPrimaryKey(SysQuartzJob record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/SysStreetMapper.java b/src/main/java/com/fc/test/mapper/auto/SysStreetMapper.java deleted file mode 100644 index 33a3d9a0e1917709e1cce561123a25ca7a13deb4..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/SysStreetMapper.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.SysStreet; -import com.fc.test.model.auto.SysStreetExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 街道设置 SysStreetMapper - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-10-05 01:02:28 - */ -public interface SysStreetMapper { - - long countByExample(SysStreetExample example); - - int deleteByExample(SysStreetExample example); - - int deleteByPrimaryKey(Integer id); - - int insert(SysStreet record); - - int insertSelective(SysStreet record); - - List selectByExample(SysStreetExample example); - - SysStreet selectByPrimaryKey(Integer id); - - int updateByExampleSelective(@Param("record") SysStreet record, @Param("example") SysStreetExample example); - - int updateByExample(@Param("record") SysStreet record, @Param("example") SysStreetExample example); - - int updateByPrimaryKeySelective(SysStreet record); - - int updateByPrimaryKey(SysStreet record); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TSysDictDataMapper.java b/src/main/java/com/fc/test/mapper/auto/TSysDictDataMapper.java deleted file mode 100644 index 6e954a89a031c6e942f93a5f692e928973dd43d3..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TSysDictDataMapper.java +++ /dev/null @@ -1,33 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TSysDictData; -import com.fc.test.model.auto.TSysDictDataExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 字典数据表 - * - * @author 一休 - * @email 438081243@qq.com - * @date 2019-09-08 00:10:43 - */ -public interface TSysDictDataMapper { - long countByExample(TSysDictDataExample example); - - int deleteByExample(TSysDictDataExample example); - - int insert(TSysDictData record); - - int insertSelective(TSysDictData record); - - List selectByExample(TSysDictDataExample example); - - int updateByExampleSelective(@Param("record") TSysDictData record, @Param("example") TSysDictDataExample example); - - int updateByExample(@Param("record") TSysDictData record, @Param("example") TSysDictDataExample example); - - TSysDictData selectByPrimaryKey(String id); - - int updateByPrimaryKeySelective(TSysDictData record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TSysDictTypeMapper.java b/src/main/java/com/fc/test/mapper/auto/TSysDictTypeMapper.java deleted file mode 100644 index ed0c3c73e4bc1622392416d27385eab052e6d45d..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TSysDictTypeMapper.java +++ /dev/null @@ -1,37 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TSysDictType; -import com.fc.test.model.auto.TSysDictTypeExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -/** - * 字典类型表 - * - * @author 一休 - * @email 438081243@qq.com - * @date 2019-09-05 12:34:25 - */ -public interface TSysDictTypeMapper { - long countByExample(TSysDictTypeExample example); - - int deleteByExample(TSysDictTypeExample example); - - int deleteByPrimaryKey(String id); - - int insert(TSysDictType record); - - int insertSelective(TSysDictType record); - - List selectByExample(TSysDictTypeExample example); - - TSysDictType selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TSysDictType record, @Param("example") TSysDictTypeExample example); - - int updateByExample(@Param("record") TSysDictType record, @Param("example") TSysDictTypeExample example); - - int updateByPrimaryKeySelective(TSysDictType record); - - int updateByPrimaryKey(TSysDictType record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TSysEmailMapper.java b/src/main/java/com/fc/test/mapper/auto/TSysEmailMapper.java deleted file mode 100644 index d431601d7dba84cfc86edff57ea4d6ac6cc6ed8b..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TSysEmailMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TSysEmail; -import com.fc.test.model.auto.TSysEmailExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TSysEmailMapper { - long countByExample(TSysEmailExample example); - - int deleteByExample(TSysEmailExample example); - - int deleteByPrimaryKey(String id); - - int insert(TSysEmail record); - - int insertSelective(TSysEmail record); - - List selectByExample(TSysEmailExample example); - - TSysEmail selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TSysEmail record, @Param("example") TSysEmailExample example); - - int updateByExample(@Param("record") TSysEmail record, @Param("example") TSysEmailExample example); - - int updateByPrimaryKeySelective(TSysEmail record); - - int updateByPrimaryKey(TSysEmail record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TSysRoleUserMapper.java b/src/main/java/com/fc/test/mapper/auto/TSysRoleUserMapper.java deleted file mode 100644 index 1573f88771010485cb24769ac079994f48d3e11a..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TSysRoleUserMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TSysRoleUser; -import com.fc.test.model.auto.TSysRoleUserExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TSysRoleUserMapper { - int countByExample(TSysRoleUserExample example); - - int deleteByExample(TSysRoleUserExample example); - - int deleteByPrimaryKey(String id); - - int insert(TSysRoleUser record); - - int insertSelective(TSysRoleUser record); - - List selectByExample(TSysRoleUserExample example); - - TSysRoleUser selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TSysRoleUser record, @Param("example") TSysRoleUserExample example); - - int updateByExample(@Param("record") TSysRoleUser record, @Param("example") TSysRoleUserExample example); - - int updateByPrimaryKeySelective(TSysRoleUser record); - - int updateByPrimaryKey(TSysRoleUser record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysDatasMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysDatasMapper.java deleted file mode 100644 index 7914479a49d727f3a9c6bad3e75d73ead44af763..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysDatasMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TsysDatas; -import com.fc.test.model.auto.TsysDatasExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TsysDatasMapper { - int countByExample(TsysDatasExample example); - - int deleteByExample(TsysDatasExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysDatas record); - - int insertSelective(TsysDatas record); - - List selectByExample(TsysDatasExample example); - - TsysDatas selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysDatas record, @Param("example") TsysDatasExample example); - - int updateByExample(@Param("record") TsysDatas record, @Param("example") TsysDatasExample example); - - int updateByPrimaryKeySelective(TsysDatas record); - - int updateByPrimaryKey(TsysDatas record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysFileDataMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysFileDataMapper.java deleted file mode 100644 index 86edc97ab5b3e799bcc6be9e56b6bba6b9b365b0..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysFileDataMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TsysFileData; -import com.fc.test.model.auto.TsysFileDataExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TsysFileDataMapper { - int countByExample(TsysFileDataExample example); - - int deleteByExample(TsysFileDataExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysFileData record); - - int insertSelective(TsysFileData record); - - List selectByExample(TsysFileDataExample example); - - TsysFileData selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysFileData record, @Param("example") TsysFileDataExample example); - - int updateByExample(@Param("record") TsysFileData record, @Param("example") TsysFileDataExample example); - - int updateByPrimaryKeySelective(TsysFileData record); - - int updateByPrimaryKey(TsysFileData record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysFileMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysFileMapper.java deleted file mode 100644 index a41afdedc24ce0bc59c7ef851e544641dc6223b4..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysFileMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TsysFile; -import com.fc.test.model.auto.TsysFileExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TsysFileMapper { - int countByExample(TsysFileExample example); - - int deleteByExample(TsysFileExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysFile record); - - int insertSelective(TsysFile record); - - List selectByExample(TsysFileExample example); - - TsysFile selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysFile record, @Param("example") TsysFileExample example); - - int updateByExample(@Param("record") TsysFile record, @Param("example") TsysFileExample example); - - int updateByPrimaryKeySelective(TsysFile record); - - int updateByPrimaryKey(TsysFile record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysOperLogMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysOperLogMapper.java deleted file mode 100644 index e5d63cc1868957b809e87b65f0be8ac05d02484d..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysOperLogMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TsysOperLog; -import com.fc.test.model.auto.TsysOperLogExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TsysOperLogMapper { - int countByExample(TsysOperLogExample example); - - int deleteByExample(TsysOperLogExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysOperLog record); - - int insertSelective(TsysOperLog record); - - List selectByExample(TsysOperLogExample example); - - TsysOperLog selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysOperLog record, @Param("example") TsysOperLogExample example); - - int updateByExample(@Param("record") TsysOperLog record, @Param("example") TsysOperLogExample example); - - int updateByPrimaryKeySelective(TsysOperLog record); - - int updateByPrimaryKey(TsysOperLog record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysPermissionMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysPermissionMapper.java deleted file mode 100644 index ba1943277c8006ad03d9c44bd0a373f41cb836e8..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysPermissionMapper.java +++ /dev/null @@ -1,31 +0,0 @@ -package com.fc.test.mapper.auto; - -import java.util.List; - -import com.fc.test.model.auto.TsysPermission; -import com.fc.test.model.auto.TsysPermissionExample; -import org.apache.ibatis.annotations.Param; - -public interface TsysPermissionMapper { - long countByExample(TsysPermissionExample example); - - int deleteByExample(TsysPermissionExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysPermission record); - - int insertSelective(TsysPermission record); - - List selectByExample(TsysPermissionExample example); - - TsysPermission selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysPermission record, @Param("example") TsysPermissionExample example); - - int updateByExample(@Param("record") TsysPermission record, @Param("example") TsysPermissionExample example); - - int updateByPrimaryKeySelective(TsysPermission record); - - int updateByPrimaryKey(TsysPermission record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysPermissionRoleMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysPermissionRoleMapper.java deleted file mode 100644 index 10c5537fb18b66ff8f57493dcb1e200d9c8e3b17..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysPermissionRoleMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TsysPermissionRole; -import com.fc.test.model.auto.TsysPermissionRoleExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TsysPermissionRoleMapper { - int countByExample(TsysPermissionRoleExample example); - - int deleteByExample(TsysPermissionRoleExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysPermissionRole record); - - int insertSelective(TsysPermissionRole record); - - List selectByExample(TsysPermissionRoleExample example); - - TsysPermissionRole selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysPermissionRole record, @Param("example") TsysPermissionRoleExample example); - - int updateByExample(@Param("record") TsysPermissionRole record, @Param("example") TsysPermissionRoleExample example); - - int updateByPrimaryKeySelective(TsysPermissionRole record); - - int updateByPrimaryKey(TsysPermissionRole record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysRoleMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysRoleMapper.java deleted file mode 100644 index ca0dada0ee9cd333a75c595417157e8424198169..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysRoleMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TsysRole; -import com.fc.test.model.auto.TsysRoleExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TsysRoleMapper { - int countByExample(TsysRoleExample example); - - int deleteByExample(TsysRoleExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysRole record); - - int insertSelective(TsysRole record); - - List selectByExample(TsysRoleExample example); - - TsysRole selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysRole record, @Param("example") TsysRoleExample example); - - int updateByExample(@Param("record") TsysRole record, @Param("example") TsysRoleExample example); - - int updateByPrimaryKeySelective(TsysRole record); - - int updateByPrimaryKey(TsysRole record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/auto/TsysUserMapper.java b/src/main/java/com/fc/test/mapper/auto/TsysUserMapper.java deleted file mode 100644 index c4b2ab986a91b2d77e91172dc88dbc508b27218a..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/auto/TsysUserMapper.java +++ /dev/null @@ -1,30 +0,0 @@ -package com.fc.test.mapper.auto; - -import com.fc.test.model.auto.TsysUser; -import com.fc.test.model.auto.TsysUserExample; -import java.util.List; -import org.apache.ibatis.annotations.Param; - -public interface TsysUserMapper { - long countByExample(TsysUserExample example); - - int deleteByExample(TsysUserExample example); - - int deleteByPrimaryKey(String id); - - int insert(TsysUser record); - - int insertSelective(TsysUser record); - - List selectByExample(TsysUserExample example); - - TsysUser selectByPrimaryKey(String id); - - int updateByExampleSelective(@Param("record") TsysUser record, @Param("example") TsysUserExample example); - - int updateByExample(@Param("record") TsysUser record, @Param("example") TsysUserExample example); - - int updateByPrimaryKeySelective(TsysUser record); - - int updateByPrimaryKey(TsysUser record); -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/custom/PermissionDao.java b/src/main/java/com/fc/test/mapper/custom/PermissionDao.java deleted file mode 100644 index 1cb56cdc15366bd40e0bbcb0dd5e03694f86ead2..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/custom/PermissionDao.java +++ /dev/null @@ -1,31 +0,0 @@ -package com.fc.test.mapper.custom; - -import java.util.List; - -import com.fc.test.model.auto.TsysPermission; - -public interface PermissionDao { - /** - * 查询全部权限 - * @return - */ - List findAll(); - - /** - * 根据用户id查询出用户的所有权限 - * @param userId - * @return - */ - List findByAdminUserId(String userId); - - /** - * 根据角色id查询权限 - * @param roleid - * @return - */ - List queryRoleId(String roleid); - - - - -} diff --git a/src/main/java/com/fc/test/mapper/custom/RoleDao.java b/src/main/java/com/fc/test/mapper/custom/RoleDao.java deleted file mode 100644 index c002c6aec17b8f0861cf2434dbd06475ef9d4a7c..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/custom/RoleDao.java +++ /dev/null @@ -1,22 +0,0 @@ - -package com.fc.test.mapper.custom; - -import java.util.List; - -import com.fc.test.model.auto.TsysRole; - -/** - * 角色Dao - * @ClassName: RoleDao - * @author fuce - * @date 2018年8月25日 - * - */ -public interface RoleDao { - /** - * 根据用户id查询角色 - * @param userid - * @return - */ - public List queryUserRole(String userid); -} diff --git a/src/main/java/com/fc/test/mapper/custom/TsysDatasDao.java b/src/main/java/com/fc/test/mapper/custom/TsysDatasDao.java deleted file mode 100644 index 35c936bd4f85fc978f6704577fb5d46461e41f9c..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/custom/TsysDatasDao.java +++ /dev/null @@ -1,13 +0,0 @@ -package com.fc.test.mapper.custom; - -import java.util.List; - -import org.apache.ibatis.annotations.Param; - -import com.fc.test.model.auto.TsysDatas; - -public interface TsysDatasDao { - - public List selectByPrimaryKeys(@Param("ids") List ids); - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/mapper/custom/TsysUserDao.java b/src/main/java/com/fc/test/mapper/custom/TsysUserDao.java deleted file mode 100644 index bada66d630494dc0fca3f0ffa4494ab2dac470af..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/mapper/custom/TsysUserDao.java +++ /dev/null @@ -1,18 +0,0 @@ -package com.fc.test.mapper.custom; - -import com.fc.test.model.auto.TsysUser; - -/** - * @ClassName: TsysUserDao - * @author fuce - * @date 2018年8月25日 - * - */ -public interface TsysUserDao { - /** - * 根据用户名字查询用户 - * @param username - * @return - */ - public TsysUser queryUserName(String username); -} diff --git a/src/main/java/com/fc/test/model/auto/SysArea.java b/src/main/java/com/fc/test/model/auto/SysArea.java deleted file mode 100644 index 2ee6ed0d8920c0e0156a57b0cc409386da2ac835..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysArea.java +++ /dev/null @@ -1,151 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; - -import com.fasterxml.jackson.annotation.JsonFormat; - -public class SysArea implements Serializable { - private Integer id; - - private String areaCode; - - private String cityCode; - - private String areaName; - - private String shortName; - - private String lng; - - private String lat; - - private Integer sort; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtCreate; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtModified; - - private String memo; - - private Integer dataState; - - private static final long serialVersionUID = 1L; - - public SysArea(Integer id, String areaCode, String cityCode, String areaName, String shortName, String lng, String lat, Integer sort, Date gmtCreate, Date gmtModified, String memo, Integer dataState) { - this.id = id; - this.areaCode = areaCode; - this.cityCode = cityCode; - this.areaName = areaName; - this.shortName = shortName; - this.lng = lng; - this.lat = lat; - this.sort = sort; - this.gmtCreate = gmtCreate; - this.gmtModified = gmtModified; - this.memo = memo; - this.dataState = dataState; - } - - public SysArea() { - super(); - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getAreaCode() { - return areaCode; - } - - public void setAreaCode(String areaCode) { - this.areaCode = areaCode == null ? null : areaCode.trim(); - } - - public String getCityCode() { - return cityCode; - } - - public void setCityCode(String cityCode) { - this.cityCode = cityCode == null ? null : cityCode.trim(); - } - - public String getAreaName() { - return areaName; - } - - public void setAreaName(String areaName) { - this.areaName = areaName == null ? null : areaName.trim(); - } - - public String getShortName() { - return shortName; - } - - public void setShortName(String shortName) { - this.shortName = shortName == null ? null : shortName.trim(); - } - - public String getLng() { - return lng; - } - - public void setLng(String lng) { - this.lng = lng == null ? null : lng.trim(); - } - - public String getLat() { - return lat; - } - - public void setLat(String lat) { - this.lat = lat == null ? null : lat.trim(); - } - - public Integer getSort() { - return sort; - } - - public void setSort(Integer sort) { - this.sort = sort; - } - - public Date getGmtCreate() { - return gmtCreate; - } - - public void setGmtCreate(Date gmtCreate) { - this.gmtCreate = gmtCreate; - } - - public Date getGmtModified() { - return gmtModified; - } - - public void setGmtModified(Date gmtModified) { - this.gmtModified = gmtModified; - } - - public String getMemo() { - return memo; - } - - public void setMemo(String memo) { - this.memo = memo == null ? null : memo.trim(); - } - - public Integer getDataState() { - return dataState; - } - - public void setDataState(Integer dataState) { - this.dataState = dataState; - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysAreaExample.java b/src/main/java/com/fc/test/model/auto/SysAreaExample.java deleted file mode 100644 index 0f4d2295ef7bb207d3c070d669e72d76761dfa49..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysAreaExample.java +++ /dev/null @@ -1,991 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -public class SysAreaExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysAreaExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(Integer value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(Integer value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(Integer value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(Integer value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(Integer value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(Integer value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(Integer value1, Integer value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(Integer value1, Integer value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andAreaCodeIsNull() { - addCriterion("area_code is null"); - return (Criteria) this; - } - - public Criteria andAreaCodeIsNotNull() { - addCriterion("area_code is not null"); - return (Criteria) this; - } - - public Criteria andAreaCodeEqualTo(String value) { - addCriterion("area_code =", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotEqualTo(String value) { - addCriterion("area_code <>", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeGreaterThan(String value) { - addCriterion("area_code >", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeGreaterThanOrEqualTo(String value) { - addCriterion("area_code >=", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeLessThan(String value) { - addCriterion("area_code <", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeLessThanOrEqualTo(String value) { - addCriterion("area_code <=", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeLike(String value) { - addCriterion("area_code like", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotLike(String value) { - addCriterion("area_code not like", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeIn(List values) { - addCriterion("area_code in", values, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotIn(List values) { - addCriterion("area_code not in", values, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeBetween(String value1, String value2) { - addCriterion("area_code between", value1, value2, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotBetween(String value1, String value2) { - addCriterion("area_code not between", value1, value2, "areaCode"); - return (Criteria) this; - } - - public Criteria andCityCodeIsNull() { - addCriterion("city_code is null"); - return (Criteria) this; - } - - public Criteria andCityCodeIsNotNull() { - addCriterion("city_code is not null"); - return (Criteria) this; - } - - public Criteria andCityCodeEqualTo(String value) { - addCriterion("city_code =", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotEqualTo(String value) { - addCriterion("city_code <>", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeGreaterThan(String value) { - addCriterion("city_code >", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeGreaterThanOrEqualTo(String value) { - addCriterion("city_code >=", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeLessThan(String value) { - addCriterion("city_code <", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeLessThanOrEqualTo(String value) { - addCriterion("city_code <=", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeLike(String value) { - addCriterion("city_code like", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotLike(String value) { - addCriterion("city_code not like", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeIn(List values) { - addCriterion("city_code in", values, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotIn(List values) { - addCriterion("city_code not in", values, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeBetween(String value1, String value2) { - addCriterion("city_code between", value1, value2, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotBetween(String value1, String value2) { - addCriterion("city_code not between", value1, value2, "cityCode"); - return (Criteria) this; - } - - public Criteria andAreaNameIsNull() { - addCriterion("area_name is null"); - return (Criteria) this; - } - - public Criteria andAreaNameIsNotNull() { - addCriterion("area_name is not null"); - return (Criteria) this; - } - - public Criteria andAreaNameEqualTo(String value) { - addCriterion("area_name =", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameNotEqualTo(String value) { - addCriterion("area_name <>", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameGreaterThan(String value) { - addCriterion("area_name >", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameGreaterThanOrEqualTo(String value) { - addCriterion("area_name >=", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameLessThan(String value) { - addCriterion("area_name <", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameLessThanOrEqualTo(String value) { - addCriterion("area_name <=", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameLike(String value) { - addCriterion("area_name like", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameNotLike(String value) { - addCriterion("area_name not like", value, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameIn(List values) { - addCriterion("area_name in", values, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameNotIn(List values) { - addCriterion("area_name not in", values, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameBetween(String value1, String value2) { - addCriterion("area_name between", value1, value2, "areaName"); - return (Criteria) this; - } - - public Criteria andAreaNameNotBetween(String value1, String value2) { - addCriterion("area_name not between", value1, value2, "areaName"); - return (Criteria) this; - } - - public Criteria andShortNameIsNull() { - addCriterion("short_name is null"); - return (Criteria) this; - } - - public Criteria andShortNameIsNotNull() { - addCriterion("short_name is not null"); - return (Criteria) this; - } - - public Criteria andShortNameEqualTo(String value) { - addCriterion("short_name =", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotEqualTo(String value) { - addCriterion("short_name <>", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThan(String value) { - addCriterion("short_name >", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThanOrEqualTo(String value) { - addCriterion("short_name >=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThan(String value) { - addCriterion("short_name <", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThanOrEqualTo(String value) { - addCriterion("short_name <=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLike(String value) { - addCriterion("short_name like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotLike(String value) { - addCriterion("short_name not like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameIn(List values) { - addCriterion("short_name in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotIn(List values) { - addCriterion("short_name not in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameBetween(String value1, String value2) { - addCriterion("short_name between", value1, value2, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotBetween(String value1, String value2) { - addCriterion("short_name not between", value1, value2, "shortName"); - return (Criteria) this; - } - - public Criteria andLngIsNull() { - addCriterion("lng is null"); - return (Criteria) this; - } - - public Criteria andLngIsNotNull() { - addCriterion("lng is not null"); - return (Criteria) this; - } - - public Criteria andLngEqualTo(String value) { - addCriterion("lng =", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotEqualTo(String value) { - addCriterion("lng <>", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThan(String value) { - addCriterion("lng >", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThanOrEqualTo(String value) { - addCriterion("lng >=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThan(String value) { - addCriterion("lng <", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThanOrEqualTo(String value) { - addCriterion("lng <=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLike(String value) { - addCriterion("lng like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotLike(String value) { - addCriterion("lng not like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngIn(List values) { - addCriterion("lng in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotIn(List values) { - addCriterion("lng not in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngBetween(String value1, String value2) { - addCriterion("lng between", value1, value2, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotBetween(String value1, String value2) { - addCriterion("lng not between", value1, value2, "lng"); - return (Criteria) this; - } - - public Criteria andLatIsNull() { - addCriterion("lat is null"); - return (Criteria) this; - } - - public Criteria andLatIsNotNull() { - addCriterion("lat is not null"); - return (Criteria) this; - } - - public Criteria andLatEqualTo(String value) { - addCriterion("lat =", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotEqualTo(String value) { - addCriterion("lat <>", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThan(String value) { - addCriterion("lat >", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThanOrEqualTo(String value) { - addCriterion("lat >=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThan(String value) { - addCriterion("lat <", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThanOrEqualTo(String value) { - addCriterion("lat <=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLike(String value) { - addCriterion("lat like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotLike(String value) { - addCriterion("lat not like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatIn(List values) { - addCriterion("lat in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotIn(List values) { - addCriterion("lat not in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatBetween(String value1, String value2) { - addCriterion("lat between", value1, value2, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotBetween(String value1, String value2) { - addCriterion("lat not between", value1, value2, "lat"); - return (Criteria) this; - } - - public Criteria andSortIsNull() { - addCriterion("sort is null"); - return (Criteria) this; - } - - public Criteria andSortIsNotNull() { - addCriterion("sort is not null"); - return (Criteria) this; - } - - public Criteria andSortEqualTo(Integer value) { - addCriterion("sort =", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotEqualTo(Integer value) { - addCriterion("sort <>", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThan(Integer value) { - addCriterion("sort >", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThanOrEqualTo(Integer value) { - addCriterion("sort >=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThan(Integer value) { - addCriterion("sort <", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThanOrEqualTo(Integer value) { - addCriterion("sort <=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortIn(List values) { - addCriterion("sort in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotIn(List values) { - addCriterion("sort not in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortBetween(Integer value1, Integer value2) { - addCriterion("sort between", value1, value2, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotBetween(Integer value1, Integer value2) { - addCriterion("sort not between", value1, value2, "sort"); - return (Criteria) this; - } - - public Criteria andGmtCreateIsNull() { - addCriterion("gmt_create is null"); - return (Criteria) this; - } - - public Criteria andGmtCreateIsNotNull() { - addCriterion("gmt_create is not null"); - return (Criteria) this; - } - - public Criteria andGmtCreateEqualTo(Date value) { - addCriterion("gmt_create =", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotEqualTo(Date value) { - addCriterion("gmt_create <>", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThan(Date value) { - addCriterion("gmt_create >", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_create >=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThan(Date value) { - addCriterion("gmt_create <", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThanOrEqualTo(Date value) { - addCriterion("gmt_create <=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateIn(List values) { - addCriterion("gmt_create in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotIn(List values) { - addCriterion("gmt_create not in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateBetween(Date value1, Date value2) { - addCriterion("gmt_create between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotBetween(Date value1, Date value2) { - addCriterion("gmt_create not between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIsNull() { - addCriterion("gmt_modified is null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIsNotNull() { - addCriterion("gmt_modified is not null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedEqualTo(Date value) { - addCriterion("gmt_modified =", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotEqualTo(Date value) { - addCriterion("gmt_modified <>", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThan(Date value) { - addCriterion("gmt_modified >", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_modified >=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThan(Date value) { - addCriterion("gmt_modified <", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThanOrEqualTo(Date value) { - addCriterion("gmt_modified <=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIn(List values) { - addCriterion("gmt_modified in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotIn(List values) { - addCriterion("gmt_modified not in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedBetween(Date value1, Date value2) { - addCriterion("gmt_modified between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotBetween(Date value1, Date value2) { - addCriterion("gmt_modified not between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - public Criteria andMemoIsNull() { - addCriterion("memo is null"); - return (Criteria) this; - } - - public Criteria andMemoIsNotNull() { - addCriterion("memo is not null"); - return (Criteria) this; - } - - public Criteria andMemoEqualTo(String value) { - addCriterion("memo =", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotEqualTo(String value) { - addCriterion("memo <>", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThan(String value) { - addCriterion("memo >", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThanOrEqualTo(String value) { - addCriterion("memo >=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThan(String value) { - addCriterion("memo <", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThanOrEqualTo(String value) { - addCriterion("memo <=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLike(String value) { - addCriterion("memo like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotLike(String value) { - addCriterion("memo not like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoIn(List values) { - addCriterion("memo in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotIn(List values) { - addCriterion("memo not in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoBetween(String value1, String value2) { - addCriterion("memo between", value1, value2, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotBetween(String value1, String value2) { - addCriterion("memo not between", value1, value2, "memo"); - return (Criteria) this; - } - - public Criteria andDataStateIsNull() { - addCriterion("data_state is null"); - return (Criteria) this; - } - - public Criteria andDataStateIsNotNull() { - addCriterion("data_state is not null"); - return (Criteria) this; - } - - public Criteria andDataStateEqualTo(Integer value) { - addCriterion("data_state =", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotEqualTo(Integer value) { - addCriterion("data_state <>", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThan(Integer value) { - addCriterion("data_state >", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThanOrEqualTo(Integer value) { - addCriterion("data_state >=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThan(Integer value) { - addCriterion("data_state <", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThanOrEqualTo(Integer value) { - addCriterion("data_state <=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateIn(List values) { - addCriterion("data_state in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotIn(List values) { - addCriterion("data_state not in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateBetween(Integer value1, Integer value2) { - addCriterion("data_state between", value1, value2, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotBetween(Integer value1, Integer value2) { - addCriterion("data_state not between", value1, value2, "dataState"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysCity.java b/src/main/java/com/fc/test/model/auto/SysCity.java deleted file mode 100644 index 9d8950951a0499525b8c7ebe8ee37a9a76f45150..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysCity.java +++ /dev/null @@ -1,151 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; - -import com.fasterxml.jackson.annotation.JsonFormat; - -public class SysCity implements Serializable { - private Integer id; - - private String cityCode; - - private String cityName; - - private String shortName; - - private String provinceCode; - - private String lng; - - private String lat; - - private Integer sort; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtCreate; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtModified; - - private String memo; - - private Integer dataState; - - private static final long serialVersionUID = 1L; - - public SysCity(Integer id, String cityCode, String cityName, String shortName, String provinceCode, String lng, String lat, Integer sort, Date gmtCreate, Date gmtModified, String memo, Integer dataState) { - this.id = id; - this.cityCode = cityCode; - this.cityName = cityName; - this.shortName = shortName; - this.provinceCode = provinceCode; - this.lng = lng; - this.lat = lat; - this.sort = sort; - this.gmtCreate = gmtCreate; - this.gmtModified = gmtModified; - this.memo = memo; - this.dataState = dataState; - } - - public SysCity() { - super(); - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getCityCode() { - return cityCode; - } - - public void setCityCode(String cityCode) { - this.cityCode = cityCode == null ? null : cityCode.trim(); - } - - public String getCityName() { - return cityName; - } - - public void setCityName(String cityName) { - this.cityName = cityName == null ? null : cityName.trim(); - } - - public String getShortName() { - return shortName; - } - - public void setShortName(String shortName) { - this.shortName = shortName == null ? null : shortName.trim(); - } - - public String getProvinceCode() { - return provinceCode; - } - - public void setProvinceCode(String provinceCode) { - this.provinceCode = provinceCode == null ? null : provinceCode.trim(); - } - - public String getLng() { - return lng; - } - - public void setLng(String lng) { - this.lng = lng == null ? null : lng.trim(); - } - - public String getLat() { - return lat; - } - - public void setLat(String lat) { - this.lat = lat == null ? null : lat.trim(); - } - - public Integer getSort() { - return sort; - } - - public void setSort(Integer sort) { - this.sort = sort; - } - - public Date getGmtCreate() { - return gmtCreate; - } - - public void setGmtCreate(Date gmtCreate) { - this.gmtCreate = gmtCreate; - } - - public Date getGmtModified() { - return gmtModified; - } - - public void setGmtModified(Date gmtModified) { - this.gmtModified = gmtModified; - } - - public String getMemo() { - return memo; - } - - public void setMemo(String memo) { - this.memo = memo == null ? null : memo.trim(); - } - - public Integer getDataState() { - return dataState; - } - - public void setDataState(Integer dataState) { - this.dataState = dataState; - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysCityExample.java b/src/main/java/com/fc/test/model/auto/SysCityExample.java deleted file mode 100644 index 1a1244c221ea06115a01470acaf4499bc15a11eb..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysCityExample.java +++ /dev/null @@ -1,991 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -public class SysCityExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysCityExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(Integer value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(Integer value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(Integer value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(Integer value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(Integer value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(Integer value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(Integer value1, Integer value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(Integer value1, Integer value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andCityCodeIsNull() { - addCriterion("city_code is null"); - return (Criteria) this; - } - - public Criteria andCityCodeIsNotNull() { - addCriterion("city_code is not null"); - return (Criteria) this; - } - - public Criteria andCityCodeEqualTo(String value) { - addCriterion("city_code =", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotEqualTo(String value) { - addCriterion("city_code <>", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeGreaterThan(String value) { - addCriterion("city_code >", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeGreaterThanOrEqualTo(String value) { - addCriterion("city_code >=", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeLessThan(String value) { - addCriterion("city_code <", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeLessThanOrEqualTo(String value) { - addCriterion("city_code <=", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeLike(String value) { - addCriterion("city_code like", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotLike(String value) { - addCriterion("city_code not like", value, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeIn(List values) { - addCriterion("city_code in", values, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotIn(List values) { - addCriterion("city_code not in", values, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeBetween(String value1, String value2) { - addCriterion("city_code between", value1, value2, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityCodeNotBetween(String value1, String value2) { - addCriterion("city_code not between", value1, value2, "cityCode"); - return (Criteria) this; - } - - public Criteria andCityNameIsNull() { - addCriterion("city_name is null"); - return (Criteria) this; - } - - public Criteria andCityNameIsNotNull() { - addCriterion("city_name is not null"); - return (Criteria) this; - } - - public Criteria andCityNameEqualTo(String value) { - addCriterion("city_name =", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameNotEqualTo(String value) { - addCriterion("city_name <>", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameGreaterThan(String value) { - addCriterion("city_name >", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameGreaterThanOrEqualTo(String value) { - addCriterion("city_name >=", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameLessThan(String value) { - addCriterion("city_name <", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameLessThanOrEqualTo(String value) { - addCriterion("city_name <=", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameLike(String value) { - addCriterion("city_name like", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameNotLike(String value) { - addCriterion("city_name not like", value, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameIn(List values) { - addCriterion("city_name in", values, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameNotIn(List values) { - addCriterion("city_name not in", values, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameBetween(String value1, String value2) { - addCriterion("city_name between", value1, value2, "cityName"); - return (Criteria) this; - } - - public Criteria andCityNameNotBetween(String value1, String value2) { - addCriterion("city_name not between", value1, value2, "cityName"); - return (Criteria) this; - } - - public Criteria andShortNameIsNull() { - addCriterion("short_name is null"); - return (Criteria) this; - } - - public Criteria andShortNameIsNotNull() { - addCriterion("short_name is not null"); - return (Criteria) this; - } - - public Criteria andShortNameEqualTo(String value) { - addCriterion("short_name =", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotEqualTo(String value) { - addCriterion("short_name <>", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThan(String value) { - addCriterion("short_name >", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThanOrEqualTo(String value) { - addCriterion("short_name >=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThan(String value) { - addCriterion("short_name <", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThanOrEqualTo(String value) { - addCriterion("short_name <=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLike(String value) { - addCriterion("short_name like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotLike(String value) { - addCriterion("short_name not like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameIn(List values) { - addCriterion("short_name in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotIn(List values) { - addCriterion("short_name not in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameBetween(String value1, String value2) { - addCriterion("short_name between", value1, value2, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotBetween(String value1, String value2) { - addCriterion("short_name not between", value1, value2, "shortName"); - return (Criteria) this; - } - - public Criteria andProvinceCodeIsNull() { - addCriterion("province_code is null"); - return (Criteria) this; - } - - public Criteria andProvinceCodeIsNotNull() { - addCriterion("province_code is not null"); - return (Criteria) this; - } - - public Criteria andProvinceCodeEqualTo(String value) { - addCriterion("province_code =", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotEqualTo(String value) { - addCriterion("province_code <>", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeGreaterThan(String value) { - addCriterion("province_code >", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeGreaterThanOrEqualTo(String value) { - addCriterion("province_code >=", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeLessThan(String value) { - addCriterion("province_code <", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeLessThanOrEqualTo(String value) { - addCriterion("province_code <=", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeLike(String value) { - addCriterion("province_code like", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotLike(String value) { - addCriterion("province_code not like", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeIn(List values) { - addCriterion("province_code in", values, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotIn(List values) { - addCriterion("province_code not in", values, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeBetween(String value1, String value2) { - addCriterion("province_code between", value1, value2, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotBetween(String value1, String value2) { - addCriterion("province_code not between", value1, value2, "provinceCode"); - return (Criteria) this; - } - - public Criteria andLngIsNull() { - addCriterion("lng is null"); - return (Criteria) this; - } - - public Criteria andLngIsNotNull() { - addCriterion("lng is not null"); - return (Criteria) this; - } - - public Criteria andLngEqualTo(String value) { - addCriterion("lng =", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotEqualTo(String value) { - addCriterion("lng <>", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThan(String value) { - addCriterion("lng >", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThanOrEqualTo(String value) { - addCriterion("lng >=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThan(String value) { - addCriterion("lng <", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThanOrEqualTo(String value) { - addCriterion("lng <=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLike(String value) { - addCriterion("lng like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotLike(String value) { - addCriterion("lng not like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngIn(List values) { - addCriterion("lng in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotIn(List values) { - addCriterion("lng not in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngBetween(String value1, String value2) { - addCriterion("lng between", value1, value2, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotBetween(String value1, String value2) { - addCriterion("lng not between", value1, value2, "lng"); - return (Criteria) this; - } - - public Criteria andLatIsNull() { - addCriterion("lat is null"); - return (Criteria) this; - } - - public Criteria andLatIsNotNull() { - addCriterion("lat is not null"); - return (Criteria) this; - } - - public Criteria andLatEqualTo(String value) { - addCriterion("lat =", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotEqualTo(String value) { - addCriterion("lat <>", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThan(String value) { - addCriterion("lat >", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThanOrEqualTo(String value) { - addCriterion("lat >=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThan(String value) { - addCriterion("lat <", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThanOrEqualTo(String value) { - addCriterion("lat <=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLike(String value) { - addCriterion("lat like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotLike(String value) { - addCriterion("lat not like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatIn(List values) { - addCriterion("lat in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotIn(List values) { - addCriterion("lat not in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatBetween(String value1, String value2) { - addCriterion("lat between", value1, value2, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotBetween(String value1, String value2) { - addCriterion("lat not between", value1, value2, "lat"); - return (Criteria) this; - } - - public Criteria andSortIsNull() { - addCriterion("sort is null"); - return (Criteria) this; - } - - public Criteria andSortIsNotNull() { - addCriterion("sort is not null"); - return (Criteria) this; - } - - public Criteria andSortEqualTo(Integer value) { - addCriterion("sort =", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotEqualTo(Integer value) { - addCriterion("sort <>", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThan(Integer value) { - addCriterion("sort >", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThanOrEqualTo(Integer value) { - addCriterion("sort >=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThan(Integer value) { - addCriterion("sort <", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThanOrEqualTo(Integer value) { - addCriterion("sort <=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortIn(List values) { - addCriterion("sort in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotIn(List values) { - addCriterion("sort not in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortBetween(Integer value1, Integer value2) { - addCriterion("sort between", value1, value2, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotBetween(Integer value1, Integer value2) { - addCriterion("sort not between", value1, value2, "sort"); - return (Criteria) this; - } - - public Criteria andGmtCreateIsNull() { - addCriterion("gmt_create is null"); - return (Criteria) this; - } - - public Criteria andGmtCreateIsNotNull() { - addCriterion("gmt_create is not null"); - return (Criteria) this; - } - - public Criteria andGmtCreateEqualTo(Date value) { - addCriterion("gmt_create =", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotEqualTo(Date value) { - addCriterion("gmt_create <>", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThan(Date value) { - addCriterion("gmt_create >", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_create >=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThan(Date value) { - addCriterion("gmt_create <", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThanOrEqualTo(Date value) { - addCriterion("gmt_create <=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateIn(List values) { - addCriterion("gmt_create in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotIn(List values) { - addCriterion("gmt_create not in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateBetween(Date value1, Date value2) { - addCriterion("gmt_create between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotBetween(Date value1, Date value2) { - addCriterion("gmt_create not between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIsNull() { - addCriterion("gmt_modified is null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIsNotNull() { - addCriterion("gmt_modified is not null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedEqualTo(Date value) { - addCriterion("gmt_modified =", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotEqualTo(Date value) { - addCriterion("gmt_modified <>", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThan(Date value) { - addCriterion("gmt_modified >", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_modified >=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThan(Date value) { - addCriterion("gmt_modified <", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThanOrEqualTo(Date value) { - addCriterion("gmt_modified <=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIn(List values) { - addCriterion("gmt_modified in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotIn(List values) { - addCriterion("gmt_modified not in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedBetween(Date value1, Date value2) { - addCriterion("gmt_modified between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotBetween(Date value1, Date value2) { - addCriterion("gmt_modified not between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - public Criteria andMemoIsNull() { - addCriterion("memo is null"); - return (Criteria) this; - } - - public Criteria andMemoIsNotNull() { - addCriterion("memo is not null"); - return (Criteria) this; - } - - public Criteria andMemoEqualTo(String value) { - addCriterion("memo =", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotEqualTo(String value) { - addCriterion("memo <>", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThan(String value) { - addCriterion("memo >", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThanOrEqualTo(String value) { - addCriterion("memo >=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThan(String value) { - addCriterion("memo <", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThanOrEqualTo(String value) { - addCriterion("memo <=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLike(String value) { - addCriterion("memo like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotLike(String value) { - addCriterion("memo not like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoIn(List values) { - addCriterion("memo in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotIn(List values) { - addCriterion("memo not in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoBetween(String value1, String value2) { - addCriterion("memo between", value1, value2, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotBetween(String value1, String value2) { - addCriterion("memo not between", value1, value2, "memo"); - return (Criteria) this; - } - - public Criteria andDataStateIsNull() { - addCriterion("data_state is null"); - return (Criteria) this; - } - - public Criteria andDataStateIsNotNull() { - addCriterion("data_state is not null"); - return (Criteria) this; - } - - public Criteria andDataStateEqualTo(Integer value) { - addCriterion("data_state =", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotEqualTo(Integer value) { - addCriterion("data_state <>", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThan(Integer value) { - addCriterion("data_state >", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThanOrEqualTo(Integer value) { - addCriterion("data_state >=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThan(Integer value) { - addCriterion("data_state <", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThanOrEqualTo(Integer value) { - addCriterion("data_state <=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateIn(List values) { - addCriterion("data_state in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotIn(List values) { - addCriterion("data_state not in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateBetween(Integer value1, Integer value2) { - addCriterion("data_state between", value1, value2, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotBetween(Integer value1, Integer value2) { - addCriterion("data_state not between", value1, value2, "dataState"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysDepartment.java b/src/main/java/com/fc/test/model/auto/SysDepartment.java deleted file mode 100644 index 4b2bcf0345c65f295523827b20eb01531530fa97..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysDepartment.java +++ /dev/null @@ -1,145 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; - -import java.lang.Integer; - -/** - * 部门表 SysDepartment - * - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-17 13:12:58 - */ -@ApiModel(value = "SysDepartment", description = "部门表") -public class SysDepartment implements Serializable { - - private static final long serialVersionUID = 1L; - - /** id **/ - @ApiModelProperty(value = "id") - private Integer id; - - /** 父id **/ - @ApiModelProperty(value = "父id") - private String parentId; - - /** 部门名称 **/ - @ApiModelProperty(value = "部门名称") - private String deptName; - - /** 部门负责人 **/ - @ApiModelProperty(value = "部门负责人") - private String leader; - - /** 电话 **/ - @ApiModelProperty(value = "电话") - private String phone; - - /** 邮箱 **/ - @ApiModelProperty(value = "邮箱") - private String email; - - /** 状态 **/ - @ApiModelProperty(value = "状态") - private Integer status; - - /** 排序 **/ - @ApiModelProperty(value = "排序") - private Integer orderNum; - - private Integer childCount; - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getParentId() { - return parentId; - } - - public void setParentId(String parentId) { - this.parentId = parentId; - } - - public String getDeptName() { - return deptName; - } - - public void setDeptName(String deptName) { - this.deptName = deptName; - } - - public String getLeader() { - return leader; - } - - public void setLeader(String leader) { - this.leader = leader; - } - - public String getPhone() { - return phone; - } - - public void setPhone(String phone) { - this.phone = phone; - } - - public String getEmail() { - return email; - } - - public void setEmail(String email) { - this.email = email; - } - - public Integer getStatus() { - return status; - } - - public void setStatus(Integer status) { - this.status = status; - } - - public Integer getOrderNum() { - return orderNum; - } - - public void setOrderNum(Integer orderNum) { - this.orderNum = orderNum; - } - - public Integer getChildCount() { - return childCount; - } - - public void setChildCount(Integer childCount) { - this.childCount = childCount; - } - - public SysDepartment() { - super(); - } - - public SysDepartment(Integer id, String parentId, String deptName, String leader, String phone, String email, - Integer status, Integer orderNum, Integer childCount) { - this.id = id; - this.parentId = parentId; - this.deptName = deptName; - this.leader = leader; - this.phone = phone; - this.email = email; - this.status = status; - this.orderNum = orderNum; - this.childCount = childCount; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysDepartmentExample.java b/src/main/java/com/fc/test/model/auto/SysDepartmentExample.java deleted file mode 100644 index e61d8a3729cbdc74e0c604800ca44ce4f0bea8f7..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysDepartmentExample.java +++ /dev/null @@ -1,775 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -/** - * 部门表 SysDepartmentExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-17 13:12:58 - */ -public class SysDepartmentExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysDepartmentExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(Integer value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(Integer value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(Integer value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(Integer value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(Integer value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(Integer value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(Integer value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(Integer value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(Integer value1, Integer value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(Integer value1, Integer value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andParentIdIsNull() { - addCriterion("parent_id is null"); - return (Criteria) this; - } - - public Criteria andParentIdIsNotNull() { - addCriterion("parent_id is not null"); - return (Criteria) this; - } - - public Criteria andParentIdEqualTo(String value) { - addCriterion("parent_id =", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdNotEqualTo(String value) { - addCriterion("parent_id <>", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdGreaterThan(String value) { - addCriterion("parent_id >", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdGreaterThanOrEqualTo(String value) { - addCriterion("parent_id >=", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdLessThan(String value) { - addCriterion("parent_id <", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdLessThanOrEqualTo(String value) { - addCriterion("parent_id <=", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdLike(String value) { - addCriterion("parent_id like", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdNotLike(String value) { - addCriterion("parent_id not like", value, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdIn(List values) { - addCriterion("parent_id in", values, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdNotIn(List values) { - addCriterion("parent_id not in", values, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdBetween(String value1, String value2) { - addCriterion("parent_id between", value1, value2, "parentId"); - return (Criteria) this; - } - - public Criteria andParentIdNotBetween(String value1, String value2) { - addCriterion("parent_id not between", value1, value2, "parentId"); - return (Criteria) this; - } - - - public Criteria andDeptNameIsNull() { - addCriterion("dept_name is null"); - return (Criteria) this; - } - - public Criteria andDeptNameIsNotNull() { - addCriterion("dept_name is not null"); - return (Criteria) this; - } - - public Criteria andDeptNameEqualTo(String value) { - addCriterion("dept_name =", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameNotEqualTo(String value) { - addCriterion("dept_name <>", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameGreaterThan(String value) { - addCriterion("dept_name >", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameGreaterThanOrEqualTo(String value) { - addCriterion("dept_name >=", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameLessThan(String value) { - addCriterion("dept_name <", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameLessThanOrEqualTo(String value) { - addCriterion("dept_name <=", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameLike(String value) { - addCriterion("dept_name like", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameNotLike(String value) { - addCriterion("dept_name not like", value, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameIn(List values) { - addCriterion("dept_name in", values, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameNotIn(List values) { - addCriterion("dept_name not in", values, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameBetween(String value1, String value2) { - addCriterion("dept_name between", value1, value2, "deptName"); - return (Criteria) this; - } - - public Criteria andDeptNameNotBetween(String value1, String value2) { - addCriterion("dept_name not between", value1, value2, "deptName"); - return (Criteria) this; - } - - - public Criteria andLeaderIsNull() { - addCriterion("leader is null"); - return (Criteria) this; - } - - public Criteria andLeaderIsNotNull() { - addCriterion("leader is not null"); - return (Criteria) this; - } - - public Criteria andLeaderEqualTo(String value) { - addCriterion("leader =", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderNotEqualTo(String value) { - addCriterion("leader <>", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderGreaterThan(String value) { - addCriterion("leader >", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderGreaterThanOrEqualTo(String value) { - addCriterion("leader >=", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderLessThan(String value) { - addCriterion("leader <", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderLessThanOrEqualTo(String value) { - addCriterion("leader <=", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderLike(String value) { - addCriterion("leader like", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderNotLike(String value) { - addCriterion("leader not like", value, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderIn(List values) { - addCriterion("leader in", values, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderNotIn(List values) { - addCriterion("leader not in", values, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderBetween(String value1, String value2) { - addCriterion("leader between", value1, value2, "leader"); - return (Criteria) this; - } - - public Criteria andLeaderNotBetween(String value1, String value2) { - addCriterion("leader not between", value1, value2, "leader"); - return (Criteria) this; - } - - - public Criteria andPhoneIsNull() { - addCriterion("phone is null"); - return (Criteria) this; - } - - public Criteria andPhoneIsNotNull() { - addCriterion("phone is not null"); - return (Criteria) this; - } - - public Criteria andPhoneEqualTo(String value) { - addCriterion("phone =", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneNotEqualTo(String value) { - addCriterion("phone <>", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneGreaterThan(String value) { - addCriterion("phone >", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneGreaterThanOrEqualTo(String value) { - addCriterion("phone >=", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneLessThan(String value) { - addCriterion("phone <", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneLessThanOrEqualTo(String value) { - addCriterion("phone <=", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneLike(String value) { - addCriterion("phone like", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneNotLike(String value) { - addCriterion("phone not like", value, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneIn(List values) { - addCriterion("phone in", values, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneNotIn(List values) { - addCriterion("phone not in", values, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneBetween(String value1, String value2) { - addCriterion("phone between", value1, value2, "phone"); - return (Criteria) this; - } - - public Criteria andPhoneNotBetween(String value1, String value2) { - addCriterion("phone not between", value1, value2, "phone"); - return (Criteria) this; - } - - - public Criteria andEmailIsNull() { - addCriterion("email is null"); - return (Criteria) this; - } - - public Criteria andEmailIsNotNull() { - addCriterion("email is not null"); - return (Criteria) this; - } - - public Criteria andEmailEqualTo(String value) { - addCriterion("email =", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailNotEqualTo(String value) { - addCriterion("email <>", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailGreaterThan(String value) { - addCriterion("email >", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailGreaterThanOrEqualTo(String value) { - addCriterion("email >=", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailLessThan(String value) { - addCriterion("email <", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailLessThanOrEqualTo(String value) { - addCriterion("email <=", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailLike(String value) { - addCriterion("email like", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailNotLike(String value) { - addCriterion("email not like", value, "email"); - return (Criteria) this; - } - - public Criteria andEmailIn(List values) { - addCriterion("email in", values, "email"); - return (Criteria) this; - } - - public Criteria andEmailNotIn(List values) { - addCriterion("email not in", values, "email"); - return (Criteria) this; - } - - public Criteria andEmailBetween(String value1, String value2) { - addCriterion("email between", value1, value2, "email"); - return (Criteria) this; - } - - public Criteria andEmailNotBetween(String value1, String value2) { - addCriterion("email not between", value1, value2, "email"); - return (Criteria) this; - } - - - public Criteria andStatusIsNull() { - addCriterion("status is null"); - return (Criteria) this; - } - - public Criteria andStatusIsNotNull() { - addCriterion("status is not null"); - return (Criteria) this; - } - - public Criteria andStatusEqualTo(Integer value) { - addCriterion("status =", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotEqualTo(Integer value) { - addCriterion("status <>", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThan(Integer value) { - addCriterion("status >", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThanOrEqualTo(Integer value) { - addCriterion("status >=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThan(Integer value) { - addCriterion("status <", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThanOrEqualTo(Integer value) { - addCriterion("status <=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLike(Integer value) { - addCriterion("status like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotLike(Integer value) { - addCriterion("status not like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusIn(List values) { - addCriterion("status in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotIn(List values) { - addCriterion("status not in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusBetween(Integer value1, Integer value2) { - addCriterion("status between", value1, value2, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotBetween(Integer value1, Integer value2) { - addCriterion("status not between", value1, value2, "status"); - return (Criteria) this; - } - - - public Criteria andOrderNumIsNull() { - addCriterion("order_num is null"); - return (Criteria) this; - } - - public Criteria andOrderNumIsNotNull() { - addCriterion("order_num is not null"); - return (Criteria) this; - } - - public Criteria andOrderNumEqualTo(Integer value) { - addCriterion("order_num =", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotEqualTo(Integer value) { - addCriterion("order_num <>", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumGreaterThan(Integer value) { - addCriterion("order_num >", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumGreaterThanOrEqualTo(Integer value) { - addCriterion("order_num >=", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLessThan(Integer value) { - addCriterion("order_num <", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLessThanOrEqualTo(Integer value) { - addCriterion("order_num <=", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLike(Integer value) { - addCriterion("order_num like", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotLike(Integer value) { - addCriterion("order_num not like", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumIn(List values) { - addCriterion("order_num in", values, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotIn(List values) { - addCriterion("order_num not in", values, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumBetween(Integer value1, Integer value2) { - addCriterion("order_num between", value1, value2, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotBetween(Integer value1, Integer value2) { - addCriterion("order_num not between", value1, value2, "orderNum"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysInterUrl.java b/src/main/java/com/fc/test/model/auto/SysInterUrl.java deleted file mode 100644 index 7b7faf9232439e6520bbeb4bae9f7d3bfc3f0571..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysInterUrl.java +++ /dev/null @@ -1,88 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; - -import java.lang.Integer; - -/** - * 拦截url表 SysInterUrl - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-01-05 01:48:22 - */ - @ApiModel(value="SysInterUrl", description="拦截url表") -public class SysInterUrl implements Serializable { - - private static final long serialVersionUID = 1L; - - - /** 主键 **/ - @ApiModelProperty(value = "主键") -private String id; - - /** 拦截名称 **/ - @ApiModelProperty(value = "拦截名称") -private String interName; - - /** 拦截url **/ - @ApiModelProperty(value = "拦截url") -private String url; - - /** 类型 **/ - @ApiModelProperty(value = "类型") -private Integer type; - - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id; - } - - - public String getInterName() { - return interName; - } - - public void setInterName(String interName) { - this.interName = interName; - } - - - public String getUrl() { - return url; - } - - public void setUrl(String url) { - this.url = url; - } - - - public Integer getType() { - return type; - } - - public void setType(Integer type) { - this.type = type; - } - - - public SysInterUrl() { - super(); - } - - - public SysInterUrl(String id,String interName,String url,Integer type) { - - this.id = id; - this.interName = interName; - this.url = url; - this.type = type; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysInterUrlExample.java b/src/main/java/com/fc/test/model/auto/SysInterUrlExample.java deleted file mode 100644 index 2d74a2d9ce8d8ce1508435f415c6c0b9dcad629f..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysInterUrlExample.java +++ /dev/null @@ -1,492 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -/** - * 拦截url表 SysInterUrlExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-01-05 01:48:22 - */ -public class SysInterUrlExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysInterUrlExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andInterNameIsNull() { - addCriterion("inter_name is null"); - return (Criteria) this; - } - - public Criteria andInterNameIsNotNull() { - addCriterion("inter_name is not null"); - return (Criteria) this; - } - - public Criteria andInterNameEqualTo(String value) { - addCriterion("inter_name =", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameNotEqualTo(String value) { - addCriterion("inter_name <>", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameGreaterThan(String value) { - addCriterion("inter_name >", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameGreaterThanOrEqualTo(String value) { - addCriterion("inter_name >=", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameLessThan(String value) { - addCriterion("inter_name <", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameLessThanOrEqualTo(String value) { - addCriterion("inter_name <=", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameLike(String value) { - addCriterion("inter_name like", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameNotLike(String value) { - addCriterion("inter_name not like", value, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameIn(List values) { - addCriterion("inter_name in", values, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameNotIn(List values) { - addCriterion("inter_name not in", values, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameBetween(String value1, String value2) { - addCriterion("inter_name between", value1, value2, "interName"); - return (Criteria) this; - } - - public Criteria andInterNameNotBetween(String value1, String value2) { - addCriterion("inter_name not between", value1, value2, "interName"); - return (Criteria) this; - } - - - public Criteria andUrlIsNull() { - addCriterion("url is null"); - return (Criteria) this; - } - - public Criteria andUrlIsNotNull() { - addCriterion("url is not null"); - return (Criteria) this; - } - - public Criteria andUrlEqualTo(String value) { - addCriterion("url =", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotEqualTo(String value) { - addCriterion("url <>", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlGreaterThan(String value) { - addCriterion("url >", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlGreaterThanOrEqualTo(String value) { - addCriterion("url >=", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlLessThan(String value) { - addCriterion("url <", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlLessThanOrEqualTo(String value) { - addCriterion("url <=", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlLike(String value) { - addCriterion("url like", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotLike(String value) { - addCriterion("url not like", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlIn(List values) { - addCriterion("url in", values, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotIn(List values) { - addCriterion("url not in", values, "url"); - return (Criteria) this; - } - - public Criteria andUrlBetween(String value1, String value2) { - addCriterion("url between", value1, value2, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotBetween(String value1, String value2) { - addCriterion("url not between", value1, value2, "url"); - return (Criteria) this; - } - - - public Criteria andTypeIsNull() { - addCriterion("type is null"); - return (Criteria) this; - } - - public Criteria andTypeIsNotNull() { - addCriterion("type is not null"); - return (Criteria) this; - } - - public Criteria andTypeEqualTo(Integer value) { - addCriterion("type =", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotEqualTo(Integer value) { - addCriterion("type <>", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeGreaterThan(Integer value) { - addCriterion("type >", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeGreaterThanOrEqualTo(Integer value) { - addCriterion("type >=", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLessThan(Integer value) { - addCriterion("type <", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLessThanOrEqualTo(Integer value) { - addCriterion("type <=", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLike(Integer value) { - addCriterion("type like", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotLike(Integer value) { - addCriterion("type not like", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeIn(List values) { - addCriterion("type in", values, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotIn(List values) { - addCriterion("type not in", values, "type"); - return (Criteria) this; - } - - public Criteria andTypeBetween(Integer value1, Integer value2) { - addCriterion("type between", value1, value2, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotBetween(Integer value1, Integer value2) { - addCriterion("type not between", value1, value2, "type"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysNotice.java b/src/main/java/com/fc/test/model/auto/SysNotice.java deleted file mode 100644 index cf053e99bea44c2137636bbd9c42b2f53423a2c9..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysNotice.java +++ /dev/null @@ -1,122 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; -import com.fasterxml.jackson.annotation.JsonFormat; -import java.lang.Integer; - -/** - * 公告 SysNotice - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 01:38:44 - */ -public class SysNotice implements Serializable { - - private static final long serialVersionUID = 1L; - - - /** 主键 **/ - private String id; - - /** 标题 **/ - private String title; - - /** 内容 **/ - private String content; - - /** 类型 **/ - private Integer type; - - /** 创建人id **/ - private String createId; - - /** 创建人name **/ - private String createUsername; - - /** 发信时间 **/ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date createTime; - - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id; - } - - - public String getTitle() { - return title; - } - - public void setTitle(String title) { - this.title = title; - } - - - public String getContent() { - return content; - } - - public void setContent(String content) { - this.content = content; - } - - - public Integer getType() { - return type; - } - - public void setType(Integer type) { - this.type = type; - } - - - public String getCreateId() { - return createId; - } - - public void setCreateId(String createId) { - this.createId = createId; - } - - - public String getCreateUsername() { - return createUsername; - } - - public void setCreateUsername(String createUsername) { - this.createUsername = createUsername; - } - - - public Date getCreateTime() { - return createTime; - } - - public void setCreateTime(Date createTime) { - this.createTime = createTime; - } - - - public SysNotice() { - super(); - } - - - public SysNotice(String id,String title,String content,Integer type,String createId,String createUsername,Date createTime) { - - this.id = id; - this.title = title; - this.content = content; - this.type = type; - this.createId = createId; - this.createUsername = createUsername; - this.createTime = createTime; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysNoticeExample.java b/src/main/java/com/fc/test/model/auto/SysNoticeExample.java deleted file mode 100644 index 7bcdaa6e0546c4fc680e90de2db1706acbb2f528..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysNoticeExample.java +++ /dev/null @@ -1,705 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -/** - * 公告 SysNoticeExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 01:38:44 - */ -public class SysNoticeExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysNoticeExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andTitleIsNull() { - addCriterion("title is null"); - return (Criteria) this; - } - - public Criteria andTitleIsNotNull() { - addCriterion("title is not null"); - return (Criteria) this; - } - - public Criteria andTitleEqualTo(String value) { - addCriterion("title =", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotEqualTo(String value) { - addCriterion("title <>", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleGreaterThan(String value) { - addCriterion("title >", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleGreaterThanOrEqualTo(String value) { - addCriterion("title >=", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLessThan(String value) { - addCriterion("title <", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLessThanOrEqualTo(String value) { - addCriterion("title <=", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLike(String value) { - addCriterion("title like", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotLike(String value) { - addCriterion("title not like", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleIn(List values) { - addCriterion("title in", values, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotIn(List values) { - addCriterion("title not in", values, "title"); - return (Criteria) this; - } - - public Criteria andTitleBetween(String value1, String value2) { - addCriterion("title between", value1, value2, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotBetween(String value1, String value2) { - addCriterion("title not between", value1, value2, "title"); - return (Criteria) this; - } - - - public Criteria andContentIsNull() { - addCriterion("content is null"); - return (Criteria) this; - } - - public Criteria andContentIsNotNull() { - addCriterion("content is not null"); - return (Criteria) this; - } - - public Criteria andContentEqualTo(String value) { - addCriterion("content =", value, "content"); - return (Criteria) this; - } - - public Criteria andContentNotEqualTo(String value) { - addCriterion("content <>", value, "content"); - return (Criteria) this; - } - - public Criteria andContentGreaterThan(String value) { - addCriterion("content >", value, "content"); - return (Criteria) this; - } - - public Criteria andContentGreaterThanOrEqualTo(String value) { - addCriterion("content >=", value, "content"); - return (Criteria) this; - } - - public Criteria andContentLessThan(String value) { - addCriterion("content <", value, "content"); - return (Criteria) this; - } - - public Criteria andContentLessThanOrEqualTo(String value) { - addCriterion("content <=", value, "content"); - return (Criteria) this; - } - - public Criteria andContentLike(String value) { - addCriterion("content like", value, "content"); - return (Criteria) this; - } - - public Criteria andContentNotLike(String value) { - addCriterion("content not like", value, "content"); - return (Criteria) this; - } - - public Criteria andContentIn(List values) { - addCriterion("content in", values, "content"); - return (Criteria) this; - } - - public Criteria andContentNotIn(List values) { - addCriterion("content not in", values, "content"); - return (Criteria) this; - } - - public Criteria andContentBetween(String value1, String value2) { - addCriterion("content between", value1, value2, "content"); - return (Criteria) this; - } - - public Criteria andContentNotBetween(String value1, String value2) { - addCriterion("content not between", value1, value2, "content"); - return (Criteria) this; - } - - - public Criteria andTypeIsNull() { - addCriterion("type is null"); - return (Criteria) this; - } - - public Criteria andTypeIsNotNull() { - addCriterion("type is not null"); - return (Criteria) this; - } - - public Criteria andTypeEqualTo(Integer value) { - addCriterion("type =", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotEqualTo(Integer value) { - addCriterion("type <>", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeGreaterThan(Integer value) { - addCriterion("type >", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeGreaterThanOrEqualTo(Integer value) { - addCriterion("type >=", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLessThan(Integer value) { - addCriterion("type <", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLessThanOrEqualTo(Integer value) { - addCriterion("type <=", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLike(Integer value) { - addCriterion("type like", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotLike(Integer value) { - addCriterion("type not like", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeIn(List values) { - addCriterion("type in", values, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotIn(List values) { - addCriterion("type not in", values, "type"); - return (Criteria) this; - } - - public Criteria andTypeBetween(Integer value1, Integer value2) { - addCriterion("type between", value1, value2, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotBetween(Integer value1, Integer value2) { - addCriterion("type not between", value1, value2, "type"); - return (Criteria) this; - } - - - public Criteria andCreateIdIsNull() { - addCriterion("create_id is null"); - return (Criteria) this; - } - - public Criteria andCreateIdIsNotNull() { - addCriterion("create_id is not null"); - return (Criteria) this; - } - - public Criteria andCreateIdEqualTo(String value) { - addCriterion("create_id =", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdNotEqualTo(String value) { - addCriterion("create_id <>", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdGreaterThan(String value) { - addCriterion("create_id >", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdGreaterThanOrEqualTo(String value) { - addCriterion("create_id >=", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdLessThan(String value) { - addCriterion("create_id <", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdLessThanOrEqualTo(String value) { - addCriterion("create_id <=", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdLike(String value) { - addCriterion("create_id like", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdNotLike(String value) { - addCriterion("create_id not like", value, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdIn(List values) { - addCriterion("create_id in", values, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdNotIn(List values) { - addCriterion("create_id not in", values, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdBetween(String value1, String value2) { - addCriterion("create_id between", value1, value2, "createId"); - return (Criteria) this; - } - - public Criteria andCreateIdNotBetween(String value1, String value2) { - addCriterion("create_id not between", value1, value2, "createId"); - return (Criteria) this; - } - - - public Criteria andCreateUsernameIsNull() { - addCriterion("create_username is null"); - return (Criteria) this; - } - - public Criteria andCreateUsernameIsNotNull() { - addCriterion("create_username is not null"); - return (Criteria) this; - } - - public Criteria andCreateUsernameEqualTo(String value) { - addCriterion("create_username =", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameNotEqualTo(String value) { - addCriterion("create_username <>", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameGreaterThan(String value) { - addCriterion("create_username >", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameGreaterThanOrEqualTo(String value) { - addCriterion("create_username >=", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameLessThan(String value) { - addCriterion("create_username <", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameLessThanOrEqualTo(String value) { - addCriterion("create_username <=", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameLike(String value) { - addCriterion("create_username like", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameNotLike(String value) { - addCriterion("create_username not like", value, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameIn(List values) { - addCriterion("create_username in", values, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameNotIn(List values) { - addCriterion("create_username not in", values, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameBetween(String value1, String value2) { - addCriterion("create_username between", value1, value2, "createUsername"); - return (Criteria) this; - } - - public Criteria andCreateUsernameNotBetween(String value1, String value2) { - addCriterion("create_username not between", value1, value2, "createUsername"); - return (Criteria) this; - } - - - public Criteria andCreateTimeIsNull() { - addCriterion("create_time is null"); - return (Criteria) this; - } - - public Criteria andCreateTimeIsNotNull() { - addCriterion("create_time is not null"); - return (Criteria) this; - } - - public Criteria andCreateTimeEqualTo(Date value) { - addCriterion("create_time =", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotEqualTo(Date value) { - addCriterion("create_time <>", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThan(Date value) { - addCriterion("create_time >", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("create_time >=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThan(Date value) { - addCriterion("create_time <", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThanOrEqualTo(Date value) { - addCriterion("create_time <=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLike(Date value) { - addCriterion("create_time like", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotLike(Date value) { - addCriterion("create_time not like", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeIn(List values) { - addCriterion("create_time in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotIn(List values) { - addCriterion("create_time not in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeBetween(Date value1, Date value2) { - addCriterion("create_time between", value1, value2, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotBetween(Date value1, Date value2) { - addCriterion("create_time not between", value1, value2, "createTime"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysNoticeUser.java b/src/main/java/com/fc/test/model/auto/SysNoticeUser.java deleted file mode 100644 index 429a4edb351131070596b46ea600823008092227..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysNoticeUser.java +++ /dev/null @@ -1,80 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.lang.Integer; - -/** - * 公告_用户外键 SysNoticeUser - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 02:12:54 - */ -public class SysNoticeUser implements Serializable { - - private static final long serialVersionUID = 1L; - - - /** 主键 **/ - private String id; - - /** 公告id **/ - private String noticeId; - - /** 用户id **/ - private String userId; - - /** 0未阅读 1 阅读 **/ - private Integer state; - - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id; - } - - - public String getNoticeId() { - return noticeId; - } - - public void setNoticeId(String noticeId) { - this.noticeId = noticeId; - } - - - public String getUserId() { - return userId; - } - - public void setUserId(String userId) { - this.userId = userId; - } - - - public Integer getState() { - return state; - } - - public void setState(Integer state) { - this.state = state; - } - - - public SysNoticeUser() { - super(); - } - - - public SysNoticeUser(String id,String noticeId,String userId,Integer state) { - - this.id = id; - this.noticeId = noticeId; - this.userId = userId; - this.state = state; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysNoticeUserExample.java b/src/main/java/com/fc/test/model/auto/SysNoticeUserExample.java deleted file mode 100644 index 5bdb8be12c88ed8b8175f49f967c3fb12854a922..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysNoticeUserExample.java +++ /dev/null @@ -1,491 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -/** - * 公告_用户外键 SysNoticeUserExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 02:12:54 - */ -public class SysNoticeUserExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysNoticeUserExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andNoticeIdIsNull() { - addCriterion("notice_id is null"); - return (Criteria) this; - } - - public Criteria andNoticeIdIsNotNull() { - addCriterion("notice_id is not null"); - return (Criteria) this; - } - - public Criteria andNoticeIdEqualTo(String value) { - addCriterion("notice_id =", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdNotEqualTo(String value) { - addCriterion("notice_id <>", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdGreaterThan(String value) { - addCriterion("notice_id >", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdGreaterThanOrEqualTo(String value) { - addCriterion("notice_id >=", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdLessThan(String value) { - addCriterion("notice_id <", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdLessThanOrEqualTo(String value) { - addCriterion("notice_id <=", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdLike(String value) { - addCriterion("notice_id like", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdNotLike(String value) { - addCriterion("notice_id not like", value, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdIn(List values) { - addCriterion("notice_id in", values, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdNotIn(List values) { - addCriterion("notice_id not in", values, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdBetween(String value1, String value2) { - addCriterion("notice_id between", value1, value2, "noticeId"); - return (Criteria) this; - } - - public Criteria andNoticeIdNotBetween(String value1, String value2) { - addCriterion("notice_id not between", value1, value2, "noticeId"); - return (Criteria) this; - } - - - public Criteria andUserIdIsNull() { - addCriterion("user_id is null"); - return (Criteria) this; - } - - public Criteria andUserIdIsNotNull() { - addCriterion("user_id is not null"); - return (Criteria) this; - } - - public Criteria andUserIdEqualTo(String value) { - addCriterion("user_id =", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdNotEqualTo(String value) { - addCriterion("user_id <>", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdGreaterThan(String value) { - addCriterion("user_id >", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdGreaterThanOrEqualTo(String value) { - addCriterion("user_id >=", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdLessThan(String value) { - addCriterion("user_id <", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdLessThanOrEqualTo(String value) { - addCriterion("user_id <=", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdLike(String value) { - addCriterion("user_id like", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdNotLike(String value) { - addCriterion("user_id not like", value, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdIn(List values) { - addCriterion("user_id in", values, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdNotIn(List values) { - addCriterion("user_id not in", values, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdBetween(String value1, String value2) { - addCriterion("user_id between", value1, value2, "userId"); - return (Criteria) this; - } - - public Criteria andUserIdNotBetween(String value1, String value2) { - addCriterion("user_id not between", value1, value2, "userId"); - return (Criteria) this; - } - - - public Criteria andStateIsNull() { - addCriterion("state is null"); - return (Criteria) this; - } - - public Criteria andStateIsNotNull() { - addCriterion("state is not null"); - return (Criteria) this; - } - - public Criteria andStateEqualTo(Integer value) { - addCriterion("state =", value, "state"); - return (Criteria) this; - } - - public Criteria andStateNotEqualTo(Integer value) { - addCriterion("state <>", value, "state"); - return (Criteria) this; - } - - public Criteria andStateGreaterThan(Integer value) { - addCriterion("state >", value, "state"); - return (Criteria) this; - } - - public Criteria andStateGreaterThanOrEqualTo(Integer value) { - addCriterion("state >=", value, "state"); - return (Criteria) this; - } - - public Criteria andStateLessThan(Integer value) { - addCriterion("state <", value, "state"); - return (Criteria) this; - } - - public Criteria andStateLessThanOrEqualTo(Integer value) { - addCriterion("state <=", value, "state"); - return (Criteria) this; - } - - public Criteria andStateLike(Integer value) { - addCriterion("state like", value, "state"); - return (Criteria) this; - } - - public Criteria andStateNotLike(Integer value) { - addCriterion("state not like", value, "state"); - return (Criteria) this; - } - - public Criteria andStateIn(List values) { - addCriterion("state in", values, "state"); - return (Criteria) this; - } - - public Criteria andStateNotIn(List values) { - addCriterion("state not in", values, "state"); - return (Criteria) this; - } - - public Criteria andStateBetween(Integer value1, Integer value2) { - addCriterion("state between", value1, value2, "state"); - return (Criteria) this; - } - - public Criteria andStateNotBetween(Integer value1, Integer value2) { - addCriterion("state not between", value1, value2, "state"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysPosition.java b/src/main/java/com/fc/test/model/auto/SysPosition.java deleted file mode 100644 index 5ebfe4fb3608b9a1b344e989676d7be70f9bcd4c..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysPosition.java +++ /dev/null @@ -1,82 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import io.swagger.annotations.ApiModel; -import io.swagger.annotations.ApiModelProperty; - -import java.lang.Integer; - -/** - * 岗位表 SysPosition - * - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-16 23:46:24 - */ -@ApiModel(value = "SysPosition", description = "岗位表") -public class SysPosition implements Serializable { - - private static final long serialVersionUID = 1L; - - /** 主键 **/ - @ApiModelProperty(value = "主键") - private String id; - - /** 岗位名称 **/ - @ApiModelProperty(value = "岗位名称") - private String postName; - - /** 排序 **/ - @ApiModelProperty(value = "排序") - private Integer orderNum; - - /** 状态 **/ - @ApiModelProperty(value = "状态") - private Integer status; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id; - } - - public String getPostName() { - return postName; - } - - public void setPostName(String postName) { - this.postName = postName; - } - - public Integer getOrderNum() { - return orderNum; - } - - public void setOrderNum(Integer orderNum) { - this.orderNum = orderNum; - } - - public Integer getStatus() { - return status; - } - - public void setStatus(Integer status) { - this.status = status; - } - - public SysPosition() { - super(); - } - - public SysPosition(String id, String postName, Integer orderNum, Integer status) { - - this.id = id; - this.postName = postName; - this.orderNum = orderNum; - this.status = status; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysPositionExample.java b/src/main/java/com/fc/test/model/auto/SysPositionExample.java deleted file mode 100644 index 157ed8a2e80c9622e6ba6e61bd048e82d72d2ad2..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysPositionExample.java +++ /dev/null @@ -1,491 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -/** - * 岗位表 SysPositionExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-16 23:46:24 - */ -public class SysPositionExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysPositionExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andPostNameIsNull() { - addCriterion("post_name is null"); - return (Criteria) this; - } - - public Criteria andPostNameIsNotNull() { - addCriterion("post_name is not null"); - return (Criteria) this; - } - - public Criteria andPostNameEqualTo(String value) { - addCriterion("post_name =", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameNotEqualTo(String value) { - addCriterion("post_name <>", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameGreaterThan(String value) { - addCriterion("post_name >", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameGreaterThanOrEqualTo(String value) { - addCriterion("post_name >=", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameLessThan(String value) { - addCriterion("post_name <", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameLessThanOrEqualTo(String value) { - addCriterion("post_name <=", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameLike(String value) { - addCriterion("post_name like", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameNotLike(String value) { - addCriterion("post_name not like", value, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameIn(List values) { - addCriterion("post_name in", values, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameNotIn(List values) { - addCriterion("post_name not in", values, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameBetween(String value1, String value2) { - addCriterion("post_name between", value1, value2, "postName"); - return (Criteria) this; - } - - public Criteria andPostNameNotBetween(String value1, String value2) { - addCriterion("post_name not between", value1, value2, "postName"); - return (Criteria) this; - } - - - public Criteria andOrderNumIsNull() { - addCriterion("order_num is null"); - return (Criteria) this; - } - - public Criteria andOrderNumIsNotNull() { - addCriterion("order_num is not null"); - return (Criteria) this; - } - - public Criteria andOrderNumEqualTo(Integer value) { - addCriterion("order_num =", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotEqualTo(Integer value) { - addCriterion("order_num <>", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumGreaterThan(Integer value) { - addCriterion("order_num >", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumGreaterThanOrEqualTo(Integer value) { - addCriterion("order_num >=", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLessThan(Integer value) { - addCriterion("order_num <", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLessThanOrEqualTo(Integer value) { - addCriterion("order_num <=", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLike(Integer value) { - addCriterion("order_num like", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotLike(Integer value) { - addCriterion("order_num not like", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumIn(List values) { - addCriterion("order_num in", values, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotIn(List values) { - addCriterion("order_num not in", values, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumBetween(Integer value1, Integer value2) { - addCriterion("order_num between", value1, value2, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotBetween(Integer value1, Integer value2) { - addCriterion("order_num not between", value1, value2, "orderNum"); - return (Criteria) this; - } - - - public Criteria andStatusIsNull() { - addCriterion("status is null"); - return (Criteria) this; - } - - public Criteria andStatusIsNotNull() { - addCriterion("status is not null"); - return (Criteria) this; - } - - public Criteria andStatusEqualTo(Integer value) { - addCriterion("status =", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotEqualTo(Integer value) { - addCriterion("status <>", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThan(Integer value) { - addCriterion("status >", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThanOrEqualTo(Integer value) { - addCriterion("status >=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThan(Integer value) { - addCriterion("status <", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThanOrEqualTo(Integer value) { - addCriterion("status <=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLike(Integer value) { - addCriterion("status like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotLike(Integer value) { - addCriterion("status not like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusIn(List values) { - addCriterion("status in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotIn(List values) { - addCriterion("status not in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusBetween(Integer value1, Integer value2) { - addCriterion("status between", value1, value2, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotBetween(Integer value1, Integer value2) { - addCriterion("status not between", value1, value2, "status"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysProvince.java b/src/main/java/com/fc/test/model/auto/SysProvince.java deleted file mode 100644 index bc57878ece5a6a84c5eab2e77aae1f22acd10ae6..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysProvince.java +++ /dev/null @@ -1,140 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; - -import com.fasterxml.jackson.annotation.JsonFormat; - -public class SysProvince implements Serializable { - private Integer id; - - private String provinceCode; - - private String provinceName; - - private String shortName; - - private String lng; - - private String lat; - - private Integer sort; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtCreate; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtModified; - - private String memo; - - private Integer dataState; - - private static final long serialVersionUID = 1L; - - public SysProvince(Integer id, String provinceCode, String provinceName, String shortName, String lng, String lat, Integer sort, Date gmtCreate, Date gmtModified, String memo, Integer dataState) { - this.id = id; - this.provinceCode = provinceCode; - this.provinceName = provinceName; - this.shortName = shortName; - this.lng = lng; - this.lat = lat; - this.sort = sort; - this.gmtCreate = gmtCreate; - this.gmtModified = gmtModified; - this.memo = memo; - this.dataState = dataState; - } - - public SysProvince() { - super(); - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getProvinceCode() { - return provinceCode; - } - - public void setProvinceCode(String provinceCode) { - this.provinceCode = provinceCode == null ? null : provinceCode.trim(); - } - - public String getProvinceName() { - return provinceName; - } - - public void setProvinceName(String provinceName) { - this.provinceName = provinceName == null ? null : provinceName.trim(); - } - - public String getShortName() { - return shortName; - } - - public void setShortName(String shortName) { - this.shortName = shortName == null ? null : shortName.trim(); - } - - public String getLng() { - return lng; - } - - public void setLng(String lng) { - this.lng = lng == null ? null : lng.trim(); - } - - public String getLat() { - return lat; - } - - public void setLat(String lat) { - this.lat = lat == null ? null : lat.trim(); - } - - public Integer getSort() { - return sort; - } - - public void setSort(Integer sort) { - this.sort = sort; - } - - public Date getGmtCreate() { - return gmtCreate; - } - - public void setGmtCreate(Date gmtCreate) { - this.gmtCreate = gmtCreate; - } - - public Date getGmtModified() { - return gmtModified; - } - - public void setGmtModified(Date gmtModified) { - this.gmtModified = gmtModified; - } - - public String getMemo() { - return memo; - } - - public void setMemo(String memo) { - this.memo = memo == null ? null : memo.trim(); - } - - public Integer getDataState() { - return dataState; - } - - public void setDataState(Integer dataState) { - this.dataState = dataState; - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysProvinceExample.java b/src/main/java/com/fc/test/model/auto/SysProvinceExample.java deleted file mode 100644 index 8e84cd62a22f1e257c6eef37bbbc1f41dd72a54c..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysProvinceExample.java +++ /dev/null @@ -1,921 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -public class SysProvinceExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysProvinceExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(Integer value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(Integer value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(Integer value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(Integer value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(Integer value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(Integer value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(Integer value1, Integer value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(Integer value1, Integer value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andProvinceCodeIsNull() { - addCriterion("province_code is null"); - return (Criteria) this; - } - - public Criteria andProvinceCodeIsNotNull() { - addCriterion("province_code is not null"); - return (Criteria) this; - } - - public Criteria andProvinceCodeEqualTo(String value) { - addCriterion("province_code =", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotEqualTo(String value) { - addCriterion("province_code <>", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeGreaterThan(String value) { - addCriterion("province_code >", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeGreaterThanOrEqualTo(String value) { - addCriterion("province_code >=", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeLessThan(String value) { - addCriterion("province_code <", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeLessThanOrEqualTo(String value) { - addCriterion("province_code <=", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeLike(String value) { - addCriterion("province_code like", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotLike(String value) { - addCriterion("province_code not like", value, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeIn(List values) { - addCriterion("province_code in", values, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotIn(List values) { - addCriterion("province_code not in", values, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeBetween(String value1, String value2) { - addCriterion("province_code between", value1, value2, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceCodeNotBetween(String value1, String value2) { - addCriterion("province_code not between", value1, value2, "provinceCode"); - return (Criteria) this; - } - - public Criteria andProvinceNameIsNull() { - addCriterion("province_name is null"); - return (Criteria) this; - } - - public Criteria andProvinceNameIsNotNull() { - addCriterion("province_name is not null"); - return (Criteria) this; - } - - public Criteria andProvinceNameEqualTo(String value) { - addCriterion("province_name =", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameNotEqualTo(String value) { - addCriterion("province_name <>", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameGreaterThan(String value) { - addCriterion("province_name >", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameGreaterThanOrEqualTo(String value) { - addCriterion("province_name >=", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameLessThan(String value) { - addCriterion("province_name <", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameLessThanOrEqualTo(String value) { - addCriterion("province_name <=", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameLike(String value) { - addCriterion("province_name like", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameNotLike(String value) { - addCriterion("province_name not like", value, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameIn(List values) { - addCriterion("province_name in", values, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameNotIn(List values) { - addCriterion("province_name not in", values, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameBetween(String value1, String value2) { - addCriterion("province_name between", value1, value2, "provinceName"); - return (Criteria) this; - } - - public Criteria andProvinceNameNotBetween(String value1, String value2) { - addCriterion("province_name not between", value1, value2, "provinceName"); - return (Criteria) this; - } - - public Criteria andShortNameIsNull() { - addCriterion("short_name is null"); - return (Criteria) this; - } - - public Criteria andShortNameIsNotNull() { - addCriterion("short_name is not null"); - return (Criteria) this; - } - - public Criteria andShortNameEqualTo(String value) { - addCriterion("short_name =", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotEqualTo(String value) { - addCriterion("short_name <>", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThan(String value) { - addCriterion("short_name >", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThanOrEqualTo(String value) { - addCriterion("short_name >=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThan(String value) { - addCriterion("short_name <", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThanOrEqualTo(String value) { - addCriterion("short_name <=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLike(String value) { - addCriterion("short_name like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotLike(String value) { - addCriterion("short_name not like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameIn(List values) { - addCriterion("short_name in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotIn(List values) { - addCriterion("short_name not in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameBetween(String value1, String value2) { - addCriterion("short_name between", value1, value2, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotBetween(String value1, String value2) { - addCriterion("short_name not between", value1, value2, "shortName"); - return (Criteria) this; - } - - public Criteria andLngIsNull() { - addCriterion("lng is null"); - return (Criteria) this; - } - - public Criteria andLngIsNotNull() { - addCriterion("lng is not null"); - return (Criteria) this; - } - - public Criteria andLngEqualTo(String value) { - addCriterion("lng =", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotEqualTo(String value) { - addCriterion("lng <>", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThan(String value) { - addCriterion("lng >", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThanOrEqualTo(String value) { - addCriterion("lng >=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThan(String value) { - addCriterion("lng <", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThanOrEqualTo(String value) { - addCriterion("lng <=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLike(String value) { - addCriterion("lng like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotLike(String value) { - addCriterion("lng not like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngIn(List values) { - addCriterion("lng in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotIn(List values) { - addCriterion("lng not in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngBetween(String value1, String value2) { - addCriterion("lng between", value1, value2, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotBetween(String value1, String value2) { - addCriterion("lng not between", value1, value2, "lng"); - return (Criteria) this; - } - - public Criteria andLatIsNull() { - addCriterion("lat is null"); - return (Criteria) this; - } - - public Criteria andLatIsNotNull() { - addCriterion("lat is not null"); - return (Criteria) this; - } - - public Criteria andLatEqualTo(String value) { - addCriterion("lat =", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotEqualTo(String value) { - addCriterion("lat <>", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThan(String value) { - addCriterion("lat >", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThanOrEqualTo(String value) { - addCriterion("lat >=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThan(String value) { - addCriterion("lat <", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThanOrEqualTo(String value) { - addCriterion("lat <=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLike(String value) { - addCriterion("lat like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotLike(String value) { - addCriterion("lat not like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatIn(List values) { - addCriterion("lat in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotIn(List values) { - addCriterion("lat not in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatBetween(String value1, String value2) { - addCriterion("lat between", value1, value2, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotBetween(String value1, String value2) { - addCriterion("lat not between", value1, value2, "lat"); - return (Criteria) this; - } - - public Criteria andSortIsNull() { - addCriterion("sort is null"); - return (Criteria) this; - } - - public Criteria andSortIsNotNull() { - addCriterion("sort is not null"); - return (Criteria) this; - } - - public Criteria andSortEqualTo(Integer value) { - addCriterion("sort =", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotEqualTo(Integer value) { - addCriterion("sort <>", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThan(Integer value) { - addCriterion("sort >", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThanOrEqualTo(Integer value) { - addCriterion("sort >=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThan(Integer value) { - addCriterion("sort <", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThanOrEqualTo(Integer value) { - addCriterion("sort <=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortIn(List values) { - addCriterion("sort in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotIn(List values) { - addCriterion("sort not in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortBetween(Integer value1, Integer value2) { - addCriterion("sort between", value1, value2, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotBetween(Integer value1, Integer value2) { - addCriterion("sort not between", value1, value2, "sort"); - return (Criteria) this; - } - - public Criteria andGmtCreateIsNull() { - addCriterion("gmt_create is null"); - return (Criteria) this; - } - - public Criteria andGmtCreateIsNotNull() { - addCriterion("gmt_create is not null"); - return (Criteria) this; - } - - public Criteria andGmtCreateEqualTo(Date value) { - addCriterion("gmt_create =", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotEqualTo(Date value) { - addCriterion("gmt_create <>", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThan(Date value) { - addCriterion("gmt_create >", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_create >=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThan(Date value) { - addCriterion("gmt_create <", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThanOrEqualTo(Date value) { - addCriterion("gmt_create <=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateIn(List values) { - addCriterion("gmt_create in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotIn(List values) { - addCriterion("gmt_create not in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateBetween(Date value1, Date value2) { - addCriterion("gmt_create between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotBetween(Date value1, Date value2) { - addCriterion("gmt_create not between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIsNull() { - addCriterion("gmt_modified is null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIsNotNull() { - addCriterion("gmt_modified is not null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedEqualTo(Date value) { - addCriterion("gmt_modified =", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotEqualTo(Date value) { - addCriterion("gmt_modified <>", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThan(Date value) { - addCriterion("gmt_modified >", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_modified >=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThan(Date value) { - addCriterion("gmt_modified <", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThanOrEqualTo(Date value) { - addCriterion("gmt_modified <=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIn(List values) { - addCriterion("gmt_modified in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotIn(List values) { - addCriterion("gmt_modified not in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedBetween(Date value1, Date value2) { - addCriterion("gmt_modified between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotBetween(Date value1, Date value2) { - addCriterion("gmt_modified not between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - public Criteria andMemoIsNull() { - addCriterion("memo is null"); - return (Criteria) this; - } - - public Criteria andMemoIsNotNull() { - addCriterion("memo is not null"); - return (Criteria) this; - } - - public Criteria andMemoEqualTo(String value) { - addCriterion("memo =", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotEqualTo(String value) { - addCriterion("memo <>", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThan(String value) { - addCriterion("memo >", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThanOrEqualTo(String value) { - addCriterion("memo >=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThan(String value) { - addCriterion("memo <", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThanOrEqualTo(String value) { - addCriterion("memo <=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLike(String value) { - addCriterion("memo like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotLike(String value) { - addCriterion("memo not like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoIn(List values) { - addCriterion("memo in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotIn(List values) { - addCriterion("memo not in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoBetween(String value1, String value2) { - addCriterion("memo between", value1, value2, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotBetween(String value1, String value2) { - addCriterion("memo not between", value1, value2, "memo"); - return (Criteria) this; - } - - public Criteria andDataStateIsNull() { - addCriterion("data_state is null"); - return (Criteria) this; - } - - public Criteria andDataStateIsNotNull() { - addCriterion("data_state is not null"); - return (Criteria) this; - } - - public Criteria andDataStateEqualTo(Integer value) { - addCriterion("data_state =", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotEqualTo(Integer value) { - addCriterion("data_state <>", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThan(Integer value) { - addCriterion("data_state >", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThanOrEqualTo(Integer value) { - addCriterion("data_state >=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThan(Integer value) { - addCriterion("data_state <", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThanOrEqualTo(Integer value) { - addCriterion("data_state <=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateIn(List values) { - addCriterion("data_state in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotIn(List values) { - addCriterion("data_state not in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateBetween(Integer value1, Integer value2) { - addCriterion("data_state between", value1, value2, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotBetween(Integer value1, Integer value2) { - addCriterion("data_state not between", value1, value2, "dataState"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysQuartzJob.java b/src/main/java/com/fc/test/model/auto/SysQuartzJob.java deleted file mode 100644 index 17722825a49703bed1f9c818f71f366fd081d7f8..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysQuartzJob.java +++ /dev/null @@ -1,132 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.lang.Integer; - -/** - * 定时任务调度表 SysQuartzJob - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:35 - */ -public class SysQuartzJob implements Serializable { - - private static final long serialVersionUID = 1L; - - - /** id **/ - private String id; - - /** 任务名称 **/ - private String jobName; - - /** 任务组名 **/ - private String jobGroup; - - /** 调用目标字符串 **/ - private String invokeTarget; - - /** cron执行表达式 **/ - private String cronExpression; - - /** cron计划策略 **/ - private String misfirePolicy; - - /** 是否并发执行(0允许 1禁止) **/ - private String concurrent; - - /** 任务状态(0正常 1暂停) **/ - private Integer status; - - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id; - } - - - public String getJobName() { - return jobName; - } - - public void setJobName(String jobName) { - this.jobName = jobName; - } - - - public String getJobGroup() { - return jobGroup; - } - - public void setJobGroup(String jobGroup) { - this.jobGroup = jobGroup; - } - - - public String getInvokeTarget() { - return invokeTarget; - } - - public void setInvokeTarget(String invokeTarget) { - this.invokeTarget = invokeTarget; - } - - - public String getCronExpression() { - return cronExpression; - } - - public void setCronExpression(String cronExpression) { - this.cronExpression = cronExpression; - } - - - public String getMisfirePolicy() { - return misfirePolicy; - } - - public void setMisfirePolicy(String misfirePolicy) { - this.misfirePolicy = misfirePolicy; - } - - - public String getConcurrent() { - return concurrent; - } - - public void setConcurrent(String concurrent) { - this.concurrent = concurrent; - } - - - public Integer getStatus() { - return status; - } - - public void setStatus(Integer status) { - this.status = status; - } - - - public SysQuartzJob() { - super(); - } - - - public SysQuartzJob(String id,String jobName,String jobGroup,String invokeTarget,String cronExpression,String misfirePolicy,String concurrent,Integer status) { - - this.id = id; - this.jobName = jobName; - this.jobGroup = jobGroup; - this.invokeTarget = invokeTarget; - this.cronExpression = cronExpression; - this.misfirePolicy = misfirePolicy; - this.concurrent = concurrent; - this.status = status; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysQuartzJobExample.java b/src/main/java/com/fc/test/model/auto/SysQuartzJobExample.java deleted file mode 100644 index f4991bb38719346e4d5a84bb144f2e7c8c1927f0..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysQuartzJobExample.java +++ /dev/null @@ -1,775 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -/** - * 定时任务调度表 SysQuartzJobExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:35 - */ -public class SysQuartzJobExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysQuartzJobExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andJobNameIsNull() { - addCriterion("job_name is null"); - return (Criteria) this; - } - - public Criteria andJobNameIsNotNull() { - addCriterion("job_name is not null"); - return (Criteria) this; - } - - public Criteria andJobNameEqualTo(String value) { - addCriterion("job_name =", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotEqualTo(String value) { - addCriterion("job_name <>", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameGreaterThan(String value) { - addCriterion("job_name >", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameGreaterThanOrEqualTo(String value) { - addCriterion("job_name >=", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameLessThan(String value) { - addCriterion("job_name <", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameLessThanOrEqualTo(String value) { - addCriterion("job_name <=", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameLike(String value) { - addCriterion("job_name like", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotLike(String value) { - addCriterion("job_name not like", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameIn(List values) { - addCriterion("job_name in", values, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotIn(List values) { - addCriterion("job_name not in", values, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameBetween(String value1, String value2) { - addCriterion("job_name between", value1, value2, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotBetween(String value1, String value2) { - addCriterion("job_name not between", value1, value2, "jobName"); - return (Criteria) this; - } - - - public Criteria andJobGroupIsNull() { - addCriterion("job_group is null"); - return (Criteria) this; - } - - public Criteria andJobGroupIsNotNull() { - addCriterion("job_group is not null"); - return (Criteria) this; - } - - public Criteria andJobGroupEqualTo(String value) { - addCriterion("job_group =", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotEqualTo(String value) { - addCriterion("job_group <>", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupGreaterThan(String value) { - addCriterion("job_group >", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupGreaterThanOrEqualTo(String value) { - addCriterion("job_group >=", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupLessThan(String value) { - addCriterion("job_group <", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupLessThanOrEqualTo(String value) { - addCriterion("job_group <=", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupLike(String value) { - addCriterion("job_group like", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotLike(String value) { - addCriterion("job_group not like", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupIn(List values) { - addCriterion("job_group in", values, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotIn(List values) { - addCriterion("job_group not in", values, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupBetween(String value1, String value2) { - addCriterion("job_group between", value1, value2, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotBetween(String value1, String value2) { - addCriterion("job_group not between", value1, value2, "jobGroup"); - return (Criteria) this; - } - - - public Criteria andInvokeTargetIsNull() { - addCriterion("invoke_target is null"); - return (Criteria) this; - } - - public Criteria andInvokeTargetIsNotNull() { - addCriterion("invoke_target is not null"); - return (Criteria) this; - } - - public Criteria andInvokeTargetEqualTo(String value) { - addCriterion("invoke_target =", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotEqualTo(String value) { - addCriterion("invoke_target <>", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetGreaterThan(String value) { - addCriterion("invoke_target >", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetGreaterThanOrEqualTo(String value) { - addCriterion("invoke_target >=", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetLessThan(String value) { - addCriterion("invoke_target <", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetLessThanOrEqualTo(String value) { - addCriterion("invoke_target <=", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetLike(String value) { - addCriterion("invoke_target like", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotLike(String value) { - addCriterion("invoke_target not like", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetIn(List values) { - addCriterion("invoke_target in", values, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotIn(List values) { - addCriterion("invoke_target not in", values, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetBetween(String value1, String value2) { - addCriterion("invoke_target between", value1, value2, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotBetween(String value1, String value2) { - addCriterion("invoke_target not between", value1, value2, "invokeTarget"); - return (Criteria) this; - } - - - public Criteria andCronExpressionIsNull() { - addCriterion("cron_expression is null"); - return (Criteria) this; - } - - public Criteria andCronExpressionIsNotNull() { - addCriterion("cron_expression is not null"); - return (Criteria) this; - } - - public Criteria andCronExpressionEqualTo(String value) { - addCriterion("cron_expression =", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionNotEqualTo(String value) { - addCriterion("cron_expression <>", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionGreaterThan(String value) { - addCriterion("cron_expression >", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionGreaterThanOrEqualTo(String value) { - addCriterion("cron_expression >=", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionLessThan(String value) { - addCriterion("cron_expression <", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionLessThanOrEqualTo(String value) { - addCriterion("cron_expression <=", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionLike(String value) { - addCriterion("cron_expression like", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionNotLike(String value) { - addCriterion("cron_expression not like", value, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionIn(List values) { - addCriterion("cron_expression in", values, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionNotIn(List values) { - addCriterion("cron_expression not in", values, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionBetween(String value1, String value2) { - addCriterion("cron_expression between", value1, value2, "cronExpression"); - return (Criteria) this; - } - - public Criteria andCronExpressionNotBetween(String value1, String value2) { - addCriterion("cron_expression not between", value1, value2, "cronExpression"); - return (Criteria) this; - } - - - public Criteria andMisfirePolicyIsNull() { - addCriterion("misfire_policy is null"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyIsNotNull() { - addCriterion("misfire_policy is not null"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyEqualTo(String value) { - addCriterion("misfire_policy =", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyNotEqualTo(String value) { - addCriterion("misfire_policy <>", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyGreaterThan(String value) { - addCriterion("misfire_policy >", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyGreaterThanOrEqualTo(String value) { - addCriterion("misfire_policy >=", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyLessThan(String value) { - addCriterion("misfire_policy <", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyLessThanOrEqualTo(String value) { - addCriterion("misfire_policy <=", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyLike(String value) { - addCriterion("misfire_policy like", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyNotLike(String value) { - addCriterion("misfire_policy not like", value, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyIn(List values) { - addCriterion("misfire_policy in", values, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyNotIn(List values) { - addCriterion("misfire_policy not in", values, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyBetween(String value1, String value2) { - addCriterion("misfire_policy between", value1, value2, "misfirePolicy"); - return (Criteria) this; - } - - public Criteria andMisfirePolicyNotBetween(String value1, String value2) { - addCriterion("misfire_policy not between", value1, value2, "misfirePolicy"); - return (Criteria) this; - } - - - public Criteria andConcurrentIsNull() { - addCriterion("concurrent is null"); - return (Criteria) this; - } - - public Criteria andConcurrentIsNotNull() { - addCriterion("concurrent is not null"); - return (Criteria) this; - } - - public Criteria andConcurrentEqualTo(String value) { - addCriterion("concurrent =", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentNotEqualTo(String value) { - addCriterion("concurrent <>", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentGreaterThan(String value) { - addCriterion("concurrent >", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentGreaterThanOrEqualTo(String value) { - addCriterion("concurrent >=", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentLessThan(String value) { - addCriterion("concurrent <", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentLessThanOrEqualTo(String value) { - addCriterion("concurrent <=", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentLike(String value) { - addCriterion("concurrent like", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentNotLike(String value) { - addCriterion("concurrent not like", value, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentIn(List values) { - addCriterion("concurrent in", values, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentNotIn(List values) { - addCriterion("concurrent not in", values, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentBetween(String value1, String value2) { - addCriterion("concurrent between", value1, value2, "concurrent"); - return (Criteria) this; - } - - public Criteria andConcurrentNotBetween(String value1, String value2) { - addCriterion("concurrent not between", value1, value2, "concurrent"); - return (Criteria) this; - } - - - public Criteria andStatusIsNull() { - addCriterion("status is null"); - return (Criteria) this; - } - - public Criteria andStatusIsNotNull() { - addCriterion("status is not null"); - return (Criteria) this; - } - - public Criteria andStatusEqualTo(Integer value) { - addCriterion("status =", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotEqualTo(Integer value) { - addCriterion("status <>", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThan(Integer value) { - addCriterion("status >", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThanOrEqualTo(Integer value) { - addCriterion("status >=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThan(Integer value) { - addCriterion("status <", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThanOrEqualTo(Integer value) { - addCriterion("status <=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLike(Integer value) { - addCriterion("status like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotLike(Integer value) { - addCriterion("status not like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusIn(List values) { - addCriterion("status in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotIn(List values) { - addCriterion("status not in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusBetween(Integer value1, Integer value2) { - addCriterion("status between", value1, value2, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotBetween(Integer value1, Integer value2) { - addCriterion("status not between", value1, value2, "status"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysQuartzJobLog.java b/src/main/java/com/fc/test/model/auto/SysQuartzJobLog.java deleted file mode 100644 index a0a6d1ec7cb9b1ff48d30ce302ca093d22efb685..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysQuartzJobLog.java +++ /dev/null @@ -1,149 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; -import com.fasterxml.jackson.annotation.JsonFormat; -import java.lang.Integer; - -/** - * 定时任务调度日志表 SysQuartzJobLog - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:42 - */ -public class SysQuartzJobLog implements Serializable { - - private static final long serialVersionUID = 1L; - - - /** 主键 **/ - private String id; - - /** 任务名称 **/ - private String jobName; - - /** 任务组名 **/ - private String jobGroup; - - /** 调用目标字符串 **/ - private String invokeTarget; - - /** 日志信息 **/ - private String jobMessage; - - /** 执行状态(0正常 1失败) **/ - private Integer status; - - /** 异常信息 **/ - private String exceptionInfo; - - /** 开始时间 **/ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date startTime; - - /** 结束时间 **/ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date endTime; - - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id; - } - - - public String getJobName() { - return jobName; - } - - public void setJobName(String jobName) { - this.jobName = jobName; - } - - - public String getJobGroup() { - return jobGroup; - } - - public void setJobGroup(String jobGroup) { - this.jobGroup = jobGroup; - } - - - public String getInvokeTarget() { - return invokeTarget; - } - - public void setInvokeTarget(String invokeTarget) { - this.invokeTarget = invokeTarget; - } - - - public String getJobMessage() { - return jobMessage; - } - - public void setJobMessage(String jobMessage) { - this.jobMessage = jobMessage; - } - - - public Integer getStatus() { - return status; - } - - public void setStatus(Integer status) { - this.status = status; - } - - - public String getExceptionInfo() { - return exceptionInfo; - } - - public void setExceptionInfo(String exceptionInfo) { - this.exceptionInfo = exceptionInfo; - } - - - public Date getStartTime() { - return startTime; - } - - public void setStartTime(Date startTime) { - this.startTime = startTime; - } - - - public Date getEndTime() { - return endTime; - } - - public void setEndTime(Date endTime) { - this.endTime = endTime; - } - - - public SysQuartzJobLog() { - super(); - } - - - public SysQuartzJobLog(String id,String jobName,String jobGroup,String invokeTarget,String jobMessage,Integer status,String exceptionInfo,Date startTime,Date endTime) { - - this.id = id; - this.jobName = jobName; - this.jobGroup = jobGroup; - this.invokeTarget = invokeTarget; - this.jobMessage = jobMessage; - this.status = status; - this.exceptionInfo = exceptionInfo; - this.startTime = startTime; - this.endTime = endTime; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysQuartzJobLogExample.java b/src/main/java/com/fc/test/model/auto/SysQuartzJobLogExample.java deleted file mode 100644 index 7d8c67bdc5a0d1fb68e8b85de6f2fdad42a0a29e..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysQuartzJobLogExample.java +++ /dev/null @@ -1,847 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -/** - * 定时任务调度日志表 SysQuartzJobLogExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:42 - */ -public class SysQuartzJobLogExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysQuartzJobLogExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andJobNameIsNull() { - addCriterion("job_name is null"); - return (Criteria) this; - } - - public Criteria andJobNameIsNotNull() { - addCriterion("job_name is not null"); - return (Criteria) this; - } - - public Criteria andJobNameEqualTo(String value) { - addCriterion("job_name =", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotEqualTo(String value) { - addCriterion("job_name <>", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameGreaterThan(String value) { - addCriterion("job_name >", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameGreaterThanOrEqualTo(String value) { - addCriterion("job_name >=", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameLessThan(String value) { - addCriterion("job_name <", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameLessThanOrEqualTo(String value) { - addCriterion("job_name <=", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameLike(String value) { - addCriterion("job_name like", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotLike(String value) { - addCriterion("job_name not like", value, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameIn(List values) { - addCriterion("job_name in", values, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotIn(List values) { - addCriterion("job_name not in", values, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameBetween(String value1, String value2) { - addCriterion("job_name between", value1, value2, "jobName"); - return (Criteria) this; - } - - public Criteria andJobNameNotBetween(String value1, String value2) { - addCriterion("job_name not between", value1, value2, "jobName"); - return (Criteria) this; - } - - - public Criteria andJobGroupIsNull() { - addCriterion("job_group is null"); - return (Criteria) this; - } - - public Criteria andJobGroupIsNotNull() { - addCriterion("job_group is not null"); - return (Criteria) this; - } - - public Criteria andJobGroupEqualTo(String value) { - addCriterion("job_group =", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotEqualTo(String value) { - addCriterion("job_group <>", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupGreaterThan(String value) { - addCriterion("job_group >", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupGreaterThanOrEqualTo(String value) { - addCriterion("job_group >=", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupLessThan(String value) { - addCriterion("job_group <", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupLessThanOrEqualTo(String value) { - addCriterion("job_group <=", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupLike(String value) { - addCriterion("job_group like", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotLike(String value) { - addCriterion("job_group not like", value, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupIn(List values) { - addCriterion("job_group in", values, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotIn(List values) { - addCriterion("job_group not in", values, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupBetween(String value1, String value2) { - addCriterion("job_group between", value1, value2, "jobGroup"); - return (Criteria) this; - } - - public Criteria andJobGroupNotBetween(String value1, String value2) { - addCriterion("job_group not between", value1, value2, "jobGroup"); - return (Criteria) this; - } - - - public Criteria andInvokeTargetIsNull() { - addCriterion("invoke_target is null"); - return (Criteria) this; - } - - public Criteria andInvokeTargetIsNotNull() { - addCriterion("invoke_target is not null"); - return (Criteria) this; - } - - public Criteria andInvokeTargetEqualTo(String value) { - addCriterion("invoke_target =", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotEqualTo(String value) { - addCriterion("invoke_target <>", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetGreaterThan(String value) { - addCriterion("invoke_target >", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetGreaterThanOrEqualTo(String value) { - addCriterion("invoke_target >=", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetLessThan(String value) { - addCriterion("invoke_target <", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetLessThanOrEqualTo(String value) { - addCriterion("invoke_target <=", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetLike(String value) { - addCriterion("invoke_target like", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotLike(String value) { - addCriterion("invoke_target not like", value, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetIn(List values) { - addCriterion("invoke_target in", values, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotIn(List values) { - addCriterion("invoke_target not in", values, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetBetween(String value1, String value2) { - addCriterion("invoke_target between", value1, value2, "invokeTarget"); - return (Criteria) this; - } - - public Criteria andInvokeTargetNotBetween(String value1, String value2) { - addCriterion("invoke_target not between", value1, value2, "invokeTarget"); - return (Criteria) this; - } - - - public Criteria andJobMessageIsNull() { - addCriterion("job_message is null"); - return (Criteria) this; - } - - public Criteria andJobMessageIsNotNull() { - addCriterion("job_message is not null"); - return (Criteria) this; - } - - public Criteria andJobMessageEqualTo(String value) { - addCriterion("job_message =", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageNotEqualTo(String value) { - addCriterion("job_message <>", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageGreaterThan(String value) { - addCriterion("job_message >", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageGreaterThanOrEqualTo(String value) { - addCriterion("job_message >=", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageLessThan(String value) { - addCriterion("job_message <", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageLessThanOrEqualTo(String value) { - addCriterion("job_message <=", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageLike(String value) { - addCriterion("job_message like", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageNotLike(String value) { - addCriterion("job_message not like", value, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageIn(List values) { - addCriterion("job_message in", values, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageNotIn(List values) { - addCriterion("job_message not in", values, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageBetween(String value1, String value2) { - addCriterion("job_message between", value1, value2, "jobMessage"); - return (Criteria) this; - } - - public Criteria andJobMessageNotBetween(String value1, String value2) { - addCriterion("job_message not between", value1, value2, "jobMessage"); - return (Criteria) this; - } - - - public Criteria andStatusIsNull() { - addCriterion("status is null"); - return (Criteria) this; - } - - public Criteria andStatusIsNotNull() { - addCriterion("status is not null"); - return (Criteria) this; - } - - public Criteria andStatusEqualTo(Integer value) { - addCriterion("status =", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotEqualTo(Integer value) { - addCriterion("status <>", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThan(Integer value) { - addCriterion("status >", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThanOrEqualTo(Integer value) { - addCriterion("status >=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThan(Integer value) { - addCriterion("status <", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLessThanOrEqualTo(Integer value) { - addCriterion("status <=", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusLike(Integer value) { - addCriterion("status like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotLike(Integer value) { - addCriterion("status not like", value, "status"); - return (Criteria) this; - } - - public Criteria andStatusIn(List values) { - addCriterion("status in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotIn(List values) { - addCriterion("status not in", values, "status"); - return (Criteria) this; - } - - public Criteria andStatusBetween(Integer value1, Integer value2) { - addCriterion("status between", value1, value2, "status"); - return (Criteria) this; - } - - public Criteria andStatusNotBetween(Integer value1, Integer value2) { - addCriterion("status not between", value1, value2, "status"); - return (Criteria) this; - } - - - public Criteria andExceptionInfoIsNull() { - addCriterion("exception_info is null"); - return (Criteria) this; - } - - public Criteria andExceptionInfoIsNotNull() { - addCriterion("exception_info is not null"); - return (Criteria) this; - } - - public Criteria andExceptionInfoEqualTo(String value) { - addCriterion("exception_info =", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoNotEqualTo(String value) { - addCriterion("exception_info <>", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoGreaterThan(String value) { - addCriterion("exception_info >", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoGreaterThanOrEqualTo(String value) { - addCriterion("exception_info >=", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoLessThan(String value) { - addCriterion("exception_info <", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoLessThanOrEqualTo(String value) { - addCriterion("exception_info <=", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoLike(String value) { - addCriterion("exception_info like", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoNotLike(String value) { - addCriterion("exception_info not like", value, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoIn(List values) { - addCriterion("exception_info in", values, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoNotIn(List values) { - addCriterion("exception_info not in", values, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoBetween(String value1, String value2) { - addCriterion("exception_info between", value1, value2, "exceptionInfo"); - return (Criteria) this; - } - - public Criteria andExceptionInfoNotBetween(String value1, String value2) { - addCriterion("exception_info not between", value1, value2, "exceptionInfo"); - return (Criteria) this; - } - - - public Criteria andStartTimeIsNull() { - addCriterion("start_time is null"); - return (Criteria) this; - } - - public Criteria andStartTimeIsNotNull() { - addCriterion("start_time is not null"); - return (Criteria) this; - } - - public Criteria andStartTimeEqualTo(Date value) { - addCriterion("start_time =", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeNotEqualTo(Date value) { - addCriterion("start_time <>", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeGreaterThan(Date value) { - addCriterion("start_time >", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeGreaterThanOrEqualTo(Date value) { - addCriterion("start_time >=", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeLessThan(Date value) { - addCriterion("start_time <", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeLessThanOrEqualTo(Date value) { - addCriterion("start_time <=", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeLike(Date value) { - addCriterion("start_time like", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeNotLike(Date value) { - addCriterion("start_time not like", value, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeIn(List values) { - addCriterion("start_time in", values, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeNotIn(List values) { - addCriterion("start_time not in", values, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeBetween(Date value1, Date value2) { - addCriterion("start_time between", value1, value2, "startTime"); - return (Criteria) this; - } - - public Criteria andStartTimeNotBetween(Date value1, Date value2) { - addCriterion("start_time not between", value1, value2, "startTime"); - return (Criteria) this; - } - - - public Criteria andEndTimeIsNull() { - addCriterion("end_time is null"); - return (Criteria) this; - } - - public Criteria andEndTimeIsNotNull() { - addCriterion("end_time is not null"); - return (Criteria) this; - } - - public Criteria andEndTimeEqualTo(Date value) { - addCriterion("end_time =", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeNotEqualTo(Date value) { - addCriterion("end_time <>", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeGreaterThan(Date value) { - addCriterion("end_time >", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeGreaterThanOrEqualTo(Date value) { - addCriterion("end_time >=", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeLessThan(Date value) { - addCriterion("end_time <", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeLessThanOrEqualTo(Date value) { - addCriterion("end_time <=", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeLike(Date value) { - addCriterion("end_time like", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeNotLike(Date value) { - addCriterion("end_time not like", value, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeIn(List values) { - addCriterion("end_time in", values, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeNotIn(List values) { - addCriterion("end_time not in", values, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeBetween(Date value1, Date value2) { - addCriterion("end_time between", value1, value2, "endTime"); - return (Criteria) this; - } - - public Criteria andEndTimeNotBetween(Date value1, Date value2) { - addCriterion("end_time not between", value1, value2, "endTime"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysStreet.java b/src/main/java/com/fc/test/model/auto/SysStreet.java deleted file mode 100644 index 10e10ca95c3d5182341c11a397675674431dbfd8..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysStreet.java +++ /dev/null @@ -1,188 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; -import com.fasterxml.jackson.annotation.JsonFormat; -import java.lang.Integer; - -/** - * 街道设置 SysStreet - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-10-05 01:02:28 - */ -public class SysStreet implements Serializable { - - private static final long serialVersionUID = 1L; - - - /** 自增列 **/ - private Integer id; - - /** 街道代码 **/ - private String streetCode; - - /** 父级区代码 **/ - private String areaCode; - - /** 街道名称 **/ - private String streetName; - - /** 简称 **/ - private String shortName; - - /** 经度 **/ - private String lng; - - /** 纬度 **/ - private String lat; - - /** 排序 **/ - private Integer sort; - - /** 创建时间 **/ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtCreate; - - /** 修改时间 **/ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date gmtModified; - - /** 备注 **/ - private String memo; - - /** 状态 **/ - private Integer dataState; - - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - - public String getStreetCode() { - return streetCode; - } - - public void setStreetCode(String streetCode) { - this.streetCode = streetCode; - } - - - public String getAreaCode() { - return areaCode; - } - - public void setAreaCode(String areaCode) { - this.areaCode = areaCode; - } - - - public String getStreetName() { - return streetName; - } - - public void setStreetName(String streetName) { - this.streetName = streetName; - } - - - public String getShortName() { - return shortName; - } - - public void setShortName(String shortName) { - this.shortName = shortName; - } - - - public String getLng() { - return lng; - } - - public void setLng(String lng) { - this.lng = lng; - } - - - public String getLat() { - return lat; - } - - public void setLat(String lat) { - this.lat = lat; - } - - - public Integer getSort() { - return sort; - } - - public void setSort(Integer sort) { - this.sort = sort; - } - - - public Date getGmtCreate() { - return gmtCreate; - } - - public void setGmtCreate(Date gmtCreate) { - this.gmtCreate = gmtCreate; - } - - - public Date getGmtModified() { - return gmtModified; - } - - public void setGmtModified(Date gmtModified) { - this.gmtModified = gmtModified; - } - - - public String getMemo() { - return memo; - } - - public void setMemo(String memo) { - this.memo = memo; - } - - - public Integer getDataState() { - return dataState; - } - - public void setDataState(Integer dataState) { - this.dataState = dataState; - } - - - public SysStreet() { - super(); - } - - - public SysStreet(Integer id,String streetCode,String areaCode,String streetName,String shortName,String lng,String lat,Integer sort,Date gmtCreate,Date gmtModified,String memo,Integer dataState) { - - this.id = id; - this.streetCode = streetCode; - this.areaCode = areaCode; - this.streetName = streetName; - this.shortName = shortName; - this.lng = lng; - this.lat = lat; - this.sort = sort; - this.gmtCreate = gmtCreate; - this.gmtModified = gmtModified; - this.memo = memo; - this.dataState = dataState; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/SysStreetExample.java b/src/main/java/com/fc/test/model/auto/SysStreetExample.java deleted file mode 100644 index 98c53fe26008c5cbd3ece3e84e9174af0aa148a1..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/SysStreetExample.java +++ /dev/null @@ -1,1060 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -/** - * 街道设置 SysStreetExample - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-10-05 01:02:28 - */ -public class SysStreetExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public SysStreetExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(Integer value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(Integer value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(Integer value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(Integer value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(Integer value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(Integer value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(Integer value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(Integer value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(Integer value1, Integer value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(Integer value1, Integer value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - - public Criteria andStreetCodeIsNull() { - addCriterion("street_code is null"); - return (Criteria) this; - } - - public Criteria andStreetCodeIsNotNull() { - addCriterion("street_code is not null"); - return (Criteria) this; - } - - public Criteria andStreetCodeEqualTo(String value) { - addCriterion("street_code =", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeNotEqualTo(String value) { - addCriterion("street_code <>", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeGreaterThan(String value) { - addCriterion("street_code >", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeGreaterThanOrEqualTo(String value) { - addCriterion("street_code >=", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeLessThan(String value) { - addCriterion("street_code <", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeLessThanOrEqualTo(String value) { - addCriterion("street_code <=", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeLike(String value) { - addCriterion("street_code like", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeNotLike(String value) { - addCriterion("street_code not like", value, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeIn(List values) { - addCriterion("street_code in", values, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeNotIn(List values) { - addCriterion("street_code not in", values, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeBetween(String value1, String value2) { - addCriterion("street_code between", value1, value2, "streetCode"); - return (Criteria) this; - } - - public Criteria andStreetCodeNotBetween(String value1, String value2) { - addCriterion("street_code not between", value1, value2, "streetCode"); - return (Criteria) this; - } - - - public Criteria andAreaCodeIsNull() { - addCriterion("area_code is null"); - return (Criteria) this; - } - - public Criteria andAreaCodeIsNotNull() { - addCriterion("area_code is not null"); - return (Criteria) this; - } - - public Criteria andAreaCodeEqualTo(String value) { - addCriterion("area_code =", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotEqualTo(String value) { - addCriterion("area_code <>", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeGreaterThan(String value) { - addCriterion("area_code >", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeGreaterThanOrEqualTo(String value) { - addCriterion("area_code >=", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeLessThan(String value) { - addCriterion("area_code <", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeLessThanOrEqualTo(String value) { - addCriterion("area_code <=", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeLike(String value) { - addCriterion("area_code like", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotLike(String value) { - addCriterion("area_code not like", value, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeIn(List values) { - addCriterion("area_code in", values, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotIn(List values) { - addCriterion("area_code not in", values, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeBetween(String value1, String value2) { - addCriterion("area_code between", value1, value2, "areaCode"); - return (Criteria) this; - } - - public Criteria andAreaCodeNotBetween(String value1, String value2) { - addCriterion("area_code not between", value1, value2, "areaCode"); - return (Criteria) this; - } - - - public Criteria andStreetNameIsNull() { - addCriterion("street_name is null"); - return (Criteria) this; - } - - public Criteria andStreetNameIsNotNull() { - addCriterion("street_name is not null"); - return (Criteria) this; - } - - public Criteria andStreetNameEqualTo(String value) { - addCriterion("street_name =", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameNotEqualTo(String value) { - addCriterion("street_name <>", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameGreaterThan(String value) { - addCriterion("street_name >", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameGreaterThanOrEqualTo(String value) { - addCriterion("street_name >=", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameLessThan(String value) { - addCriterion("street_name <", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameLessThanOrEqualTo(String value) { - addCriterion("street_name <=", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameLike(String value) { - addCriterion("street_name like", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameNotLike(String value) { - addCriterion("street_name not like", value, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameIn(List values) { - addCriterion("street_name in", values, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameNotIn(List values) { - addCriterion("street_name not in", values, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameBetween(String value1, String value2) { - addCriterion("street_name between", value1, value2, "streetName"); - return (Criteria) this; - } - - public Criteria andStreetNameNotBetween(String value1, String value2) { - addCriterion("street_name not between", value1, value2, "streetName"); - return (Criteria) this; - } - - - public Criteria andShortNameIsNull() { - addCriterion("short_name is null"); - return (Criteria) this; - } - - public Criteria andShortNameIsNotNull() { - addCriterion("short_name is not null"); - return (Criteria) this; - } - - public Criteria andShortNameEqualTo(String value) { - addCriterion("short_name =", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotEqualTo(String value) { - addCriterion("short_name <>", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThan(String value) { - addCriterion("short_name >", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameGreaterThanOrEqualTo(String value) { - addCriterion("short_name >=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThan(String value) { - addCriterion("short_name <", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLessThanOrEqualTo(String value) { - addCriterion("short_name <=", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameLike(String value) { - addCriterion("short_name like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotLike(String value) { - addCriterion("short_name not like", value, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameIn(List values) { - addCriterion("short_name in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotIn(List values) { - addCriterion("short_name not in", values, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameBetween(String value1, String value2) { - addCriterion("short_name between", value1, value2, "shortName"); - return (Criteria) this; - } - - public Criteria andShortNameNotBetween(String value1, String value2) { - addCriterion("short_name not between", value1, value2, "shortName"); - return (Criteria) this; - } - - - public Criteria andLngIsNull() { - addCriterion("lng is null"); - return (Criteria) this; - } - - public Criteria andLngIsNotNull() { - addCriterion("lng is not null"); - return (Criteria) this; - } - - public Criteria andLngEqualTo(String value) { - addCriterion("lng =", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotEqualTo(String value) { - addCriterion("lng <>", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThan(String value) { - addCriterion("lng >", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngGreaterThanOrEqualTo(String value) { - addCriterion("lng >=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThan(String value) { - addCriterion("lng <", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLessThanOrEqualTo(String value) { - addCriterion("lng <=", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngLike(String value) { - addCriterion("lng like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotLike(String value) { - addCriterion("lng not like", value, "lng"); - return (Criteria) this; - } - - public Criteria andLngIn(List values) { - addCriterion("lng in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotIn(List values) { - addCriterion("lng not in", values, "lng"); - return (Criteria) this; - } - - public Criteria andLngBetween(String value1, String value2) { - addCriterion("lng between", value1, value2, "lng"); - return (Criteria) this; - } - - public Criteria andLngNotBetween(String value1, String value2) { - addCriterion("lng not between", value1, value2, "lng"); - return (Criteria) this; - } - - - public Criteria andLatIsNull() { - addCriterion("lat is null"); - return (Criteria) this; - } - - public Criteria andLatIsNotNull() { - addCriterion("lat is not null"); - return (Criteria) this; - } - - public Criteria andLatEqualTo(String value) { - addCriterion("lat =", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotEqualTo(String value) { - addCriterion("lat <>", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThan(String value) { - addCriterion("lat >", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatGreaterThanOrEqualTo(String value) { - addCriterion("lat >=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThan(String value) { - addCriterion("lat <", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLessThanOrEqualTo(String value) { - addCriterion("lat <=", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatLike(String value) { - addCriterion("lat like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotLike(String value) { - addCriterion("lat not like", value, "lat"); - return (Criteria) this; - } - - public Criteria andLatIn(List values) { - addCriterion("lat in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotIn(List values) { - addCriterion("lat not in", values, "lat"); - return (Criteria) this; - } - - public Criteria andLatBetween(String value1, String value2) { - addCriterion("lat between", value1, value2, "lat"); - return (Criteria) this; - } - - public Criteria andLatNotBetween(String value1, String value2) { - addCriterion("lat not between", value1, value2, "lat"); - return (Criteria) this; - } - - - public Criteria andSortIsNull() { - addCriterion("sort is null"); - return (Criteria) this; - } - - public Criteria andSortIsNotNull() { - addCriterion("sort is not null"); - return (Criteria) this; - } - - public Criteria andSortEqualTo(Integer value) { - addCriterion("sort =", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotEqualTo(Integer value) { - addCriterion("sort <>", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThan(Integer value) { - addCriterion("sort >", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortGreaterThanOrEqualTo(Integer value) { - addCriterion("sort >=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThan(Integer value) { - addCriterion("sort <", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLessThanOrEqualTo(Integer value) { - addCriterion("sort <=", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortLike(Integer value) { - addCriterion("sort like", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotLike(Integer value) { - addCriterion("sort not like", value, "sort"); - return (Criteria) this; - } - - public Criteria andSortIn(List values) { - addCriterion("sort in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotIn(List values) { - addCriterion("sort not in", values, "sort"); - return (Criteria) this; - } - - public Criteria andSortBetween(Integer value1, Integer value2) { - addCriterion("sort between", value1, value2, "sort"); - return (Criteria) this; - } - - public Criteria andSortNotBetween(Integer value1, Integer value2) { - addCriterion("sort not between", value1, value2, "sort"); - return (Criteria) this; - } - - - public Criteria andGmtCreateIsNull() { - addCriterion("gmt_create is null"); - return (Criteria) this; - } - - public Criteria andGmtCreateIsNotNull() { - addCriterion("gmt_create is not null"); - return (Criteria) this; - } - - public Criteria andGmtCreateEqualTo(Date value) { - addCriterion("gmt_create =", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotEqualTo(Date value) { - addCriterion("gmt_create <>", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThan(Date value) { - addCriterion("gmt_create >", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_create >=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThan(Date value) { - addCriterion("gmt_create <", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLessThanOrEqualTo(Date value) { - addCriterion("gmt_create <=", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateLike(Date value) { - addCriterion("gmt_create like", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotLike(Date value) { - addCriterion("gmt_create not like", value, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateIn(List values) { - addCriterion("gmt_create in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotIn(List values) { - addCriterion("gmt_create not in", values, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateBetween(Date value1, Date value2) { - addCriterion("gmt_create between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - public Criteria andGmtCreateNotBetween(Date value1, Date value2) { - addCriterion("gmt_create not between", value1, value2, "gmtCreate"); - return (Criteria) this; - } - - - public Criteria andGmtModifiedIsNull() { - addCriterion("gmt_modified is null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIsNotNull() { - addCriterion("gmt_modified is not null"); - return (Criteria) this; - } - - public Criteria andGmtModifiedEqualTo(Date value) { - addCriterion("gmt_modified =", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotEqualTo(Date value) { - addCriterion("gmt_modified <>", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThan(Date value) { - addCriterion("gmt_modified >", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedGreaterThanOrEqualTo(Date value) { - addCriterion("gmt_modified >=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThan(Date value) { - addCriterion("gmt_modified <", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLessThanOrEqualTo(Date value) { - addCriterion("gmt_modified <=", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedLike(Date value) { - addCriterion("gmt_modified like", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotLike(Date value) { - addCriterion("gmt_modified not like", value, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedIn(List values) { - addCriterion("gmt_modified in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotIn(List values) { - addCriterion("gmt_modified not in", values, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedBetween(Date value1, Date value2) { - addCriterion("gmt_modified between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - public Criteria andGmtModifiedNotBetween(Date value1, Date value2) { - addCriterion("gmt_modified not between", value1, value2, "gmtModified"); - return (Criteria) this; - } - - - public Criteria andMemoIsNull() { - addCriterion("memo is null"); - return (Criteria) this; - } - - public Criteria andMemoIsNotNull() { - addCriterion("memo is not null"); - return (Criteria) this; - } - - public Criteria andMemoEqualTo(String value) { - addCriterion("memo =", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotEqualTo(String value) { - addCriterion("memo <>", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThan(String value) { - addCriterion("memo >", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoGreaterThanOrEqualTo(String value) { - addCriterion("memo >=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThan(String value) { - addCriterion("memo <", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLessThanOrEqualTo(String value) { - addCriterion("memo <=", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoLike(String value) { - addCriterion("memo like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotLike(String value) { - addCriterion("memo not like", value, "memo"); - return (Criteria) this; - } - - public Criteria andMemoIn(List values) { - addCriterion("memo in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotIn(List values) { - addCriterion("memo not in", values, "memo"); - return (Criteria) this; - } - - public Criteria andMemoBetween(String value1, String value2) { - addCriterion("memo between", value1, value2, "memo"); - return (Criteria) this; - } - - public Criteria andMemoNotBetween(String value1, String value2) { - addCriterion("memo not between", value1, value2, "memo"); - return (Criteria) this; - } - - - public Criteria andDataStateIsNull() { - addCriterion("data_state is null"); - return (Criteria) this; - } - - public Criteria andDataStateIsNotNull() { - addCriterion("data_state is not null"); - return (Criteria) this; - } - - public Criteria andDataStateEqualTo(Integer value) { - addCriterion("data_state =", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotEqualTo(Integer value) { - addCriterion("data_state <>", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThan(Integer value) { - addCriterion("data_state >", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateGreaterThanOrEqualTo(Integer value) { - addCriterion("data_state >=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThan(Integer value) { - addCriterion("data_state <", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLessThanOrEqualTo(Integer value) { - addCriterion("data_state <=", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateLike(Integer value) { - addCriterion("data_state like", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotLike(Integer value) { - addCriterion("data_state not like", value, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateIn(List values) { - addCriterion("data_state in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotIn(List values) { - addCriterion("data_state not in", values, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateBetween(Integer value1, Integer value2) { - addCriterion("data_state between", value1, value2, "dataState"); - return (Criteria) this; - } - - public Criteria andDataStateNotBetween(Integer value1, Integer value2) { - addCriterion("data_state not between", value1, value2, "dataState"); - return (Criteria) this; - } - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysDictData.java b/src/main/java/com/fc/test/model/auto/TSysDictData.java deleted file mode 100644 index 63be7a1c52db16ddd22b426b3ebfe654d2c0dd07..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysDictData.java +++ /dev/null @@ -1,221 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; - -import org.apache.commons.lang3.builder.ToStringBuilder; -import org.apache.commons.lang3.builder.ToStringStyle; - -import com.fasterxml.jackson.annotation.JsonFormat; - -/** - * 字典数据表 - * - * @author 一休 - * @email 438081243@qq.com - * @date 2019-09-08 00:10:43 - */ -public class TSysDictData implements Serializable { - - private static final long serialVersionUID = 1L; - - /** - * 字典数据表id - */ - private String id; - - /** - * 字典排序 - */ - private Integer dictSort; - - /** - * 字典标签 - */ - private String dictLabel; - - /** - * 字典键值 - */ - private String dictValue; - - /** - * 字典类型 - */ - private String dictType; - - /** - * 样式属性(其他样式扩展) - */ - private String cssClass; - - /** - * 表格回显样式 - */ - private String listClass; - - /** - * 是否默认(Y是 N否) - */ - private String isDefault; - - /** - * 状态(0正常 1停用) - */ - private String status; - - /** - * 创建者 - */ - private String createBy; - - /** - * 创建时间 - */ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") - private Date createTime; - - /** - * 更新者 - */ - private String updateBy; - - /** - * 更新时间 - */ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") - private Date updateTime; - - /** - * 备注 - */ - private String remark; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public Integer getDictSort() { - return dictSort; - } - - public void setDictSort(Integer dictSort) { - this.dictSort = dictSort; - } - - public String getDictLabel() { - return dictLabel; - } - - public void setDictLabel(String dictLabel) { - this.dictLabel = dictLabel == null ? null : dictLabel.trim(); - } - - public String getDictValue() { - return dictValue; - } - - public void setDictValue(String dictValue) { - this.dictValue = dictValue == null ? null : dictValue.trim(); - } - - public String getDictType() { - return dictType; - } - - public void setDictType(String dictType) { - this.dictType = dictType == null ? null : dictType.trim(); - } - - public String getCssClass() { - return cssClass; - } - - public void setCssClass(String cssClass) { - this.cssClass = cssClass == null ? null : cssClass.trim(); - } - - public String getListClass() { - return listClass; - } - - public void setListClass(String listClass) { - this.listClass = listClass == null ? null : listClass.trim(); - } - - public String getIsDefault() { - return isDefault; - } - - public void setIsDefault(String isDefault) { - this.isDefault = isDefault == null ? null : isDefault.trim(); - } - - public String getStatus() { - return status; - } - - public void setStatus(String status) { - this.status = status == null ? null : status.trim(); - } - - public String getCreateBy() { - return createBy; - } - - public void setCreateBy(String createBy) { - this.createBy = createBy == null ? null : createBy.trim(); - } - - public Date getCreateTime() { - return createTime; - } - - public void setCreateTime(Date createTime) { - this.createTime = createTime; - } - - public String getUpdateBy() { - return updateBy; - } - - public void setUpdateBy(String updateBy) { - this.updateBy = updateBy == null ? null : updateBy.trim(); - } - - public Date getUpdateTime() { - return updateTime; - } - - public void setUpdateTime(Date updateTime) { - this.updateTime = updateTime; - } - - public String getRemark() { - return remark; - } - - public void setRemark(String remark) { - this.remark = remark == null ? null : remark.trim(); - } - - public TSysDictData() { - super(); - } - - @Override - public String toString() { - return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE).append("id", getId()) - .append("dictSort", getDictSort()).append("dictLabel", getDictLabel()) - .append("dictValue", getDictValue()).append("dictType", getDictType()).append("cssClass", getCssClass()) - .append("listClass", getListClass()).append("isDefault", getIsDefault()).append("status", getStatus()) - .append("createBy", getCreateBy()).append("createTime", getCreateTime()) - .append("updateBy", getUpdateBy()).append("updateTime", getUpdateTime()).append("remark", getRemark()) - .toString(); - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysDictDataExample.java b/src/main/java/com/fc/test/model/auto/TSysDictDataExample.java deleted file mode 100644 index 7be00f7b538d0975bb9b40e7805a1fda6df8a785..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysDictDataExample.java +++ /dev/null @@ -1,1275 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -/** - * 字典数据表 - * - * @author 一休 - * @email 438081243@qq.com - * @date 2019-09-08 00:10:43 - */ -public class TSysDictDataExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TSysDictDataExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andDictCodeIsNull() { - addCriterion("dict_code is null"); - return (Criteria) this; - } - - public Criteria andDictCodeIsNotNull() { - addCriterion("dict_code is not null"); - return (Criteria) this; - } - - public Criteria andDictCodeEqualTo(String value) { - addCriterion("dict_code =", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeNotEqualTo(String value) { - addCriterion("dict_code <>", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeGreaterThan(String value) { - addCriterion("dict_code >", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeGreaterThanOrEqualTo(String value) { - addCriterion("dict_code >=", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeLessThan(String value) { - addCriterion("dict_code <", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeLessThanOrEqualTo(String value) { - addCriterion("dict_code <=", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeLike(String value) { - addCriterion("dict_code like", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeNotLike(String value) { - addCriterion("dict_code not like", value, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeIn(List values) { - addCriterion("dict_code in", values, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeNotIn(List values) { - addCriterion("dict_code not in", values, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeBetween(String value1, String value2) { - addCriterion("dict_code between", value1, value2, "dictCode"); - return (Criteria) this; - } - - public Criteria andDictCodeNotBetween(String value1, String value2) { - addCriterion("dict_code not between", value1, value2, "dictCode"); - return (Criteria) this; - } - - - public Criteria andDictSortIsNull() { - addCriterion("dict_sort is null"); - return (Criteria) this; - } - - public Criteria andDictSortIsNotNull() { - addCriterion("dict_sort is not null"); - return (Criteria) this; - } - - public Criteria andDictSortEqualTo(Integer value) { - addCriterion("dict_sort =", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortNotEqualTo(Integer value) { - addCriterion("dict_sort <>", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortGreaterThan(Integer value) { - addCriterion("dict_sort >", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortGreaterThanOrEqualTo(Integer value) { - addCriterion("dict_sort >=", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortLessThan(Integer value) { - addCriterion("dict_sort <", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortLessThanOrEqualTo(Integer value) { - addCriterion("dict_sort <=", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortLike(Integer value) { - addCriterion("dict_sort like", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortNotLike(Integer value) { - addCriterion("dict_sort not like", value, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortIn(List values) { - addCriterion("dict_sort in", values, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortNotIn(List values) { - addCriterion("dict_sort not in", values, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortBetween(Integer value1, Integer value2) { - addCriterion("dict_sort between", value1, value2, "dictSort"); - return (Criteria) this; - } - - public Criteria andDictSortNotBetween(Integer value1, Integer value2) { - addCriterion("dict_sort not between", value1, value2, "dictSort"); - return (Criteria) this; - } - - - public Criteria andDictLabelIsNull() { - addCriterion("dict_label is null"); - return (Criteria) this; - } - - public Criteria andDictLabelIsNotNull() { - addCriterion("dict_label is not null"); - return (Criteria) this; - } - - public Criteria andDictLabelEqualTo(String value) { - addCriterion("dict_label =", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelNotEqualTo(String value) { - addCriterion("dict_label <>", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelGreaterThan(String value) { - addCriterion("dict_label >", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelGreaterThanOrEqualTo(String value) { - addCriterion("dict_label >=", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelLessThan(String value) { - addCriterion("dict_label <", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelLessThanOrEqualTo(String value) { - addCriterion("dict_label <=", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelLike(String value) { - addCriterion("dict_label like", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelNotLike(String value) { - addCriterion("dict_label not like", value, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelIn(List values) { - addCriterion("dict_label in", values, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelNotIn(List values) { - addCriterion("dict_label not in", values, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelBetween(String value1, String value2) { - addCriterion("dict_label between", value1, value2, "dictLabel"); - return (Criteria) this; - } - - public Criteria andDictLabelNotBetween(String value1, String value2) { - addCriterion("dict_label not between", value1, value2, "dictLabel"); - return (Criteria) this; - } - - - public Criteria andDictValueIsNull() { - addCriterion("dict_value is null"); - return (Criteria) this; - } - - public Criteria andDictValueIsNotNull() { - addCriterion("dict_value is not null"); - return (Criteria) this; - } - - public Criteria andDictValueEqualTo(String value) { - addCriterion("dict_value =", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueNotEqualTo(String value) { - addCriterion("dict_value <>", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueGreaterThan(String value) { - addCriterion("dict_value >", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueGreaterThanOrEqualTo(String value) { - addCriterion("dict_value >=", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueLessThan(String value) { - addCriterion("dict_value <", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueLessThanOrEqualTo(String value) { - addCriterion("dict_value <=", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueLike(String value) { - addCriterion("dict_value like", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueNotLike(String value) { - addCriterion("dict_value not like", value, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueIn(List values) { - addCriterion("dict_value in", values, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueNotIn(List values) { - addCriterion("dict_value not in", values, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueBetween(String value1, String value2) { - addCriterion("dict_value between", value1, value2, "dictValue"); - return (Criteria) this; - } - - public Criteria andDictValueNotBetween(String value1, String value2) { - addCriterion("dict_value not between", value1, value2, "dictValue"); - return (Criteria) this; - } - - - public Criteria andDictTypeIsNull() { - addCriterion("dict_type is null"); - return (Criteria) this; - } - - public Criteria andDictTypeIsNotNull() { - addCriterion("dict_type is not null"); - return (Criteria) this; - } - - public Criteria andDictTypeEqualTo(String value) { - addCriterion("dict_type =", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotEqualTo(String value) { - addCriterion("dict_type <>", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeGreaterThan(String value) { - addCriterion("dict_type >", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeGreaterThanOrEqualTo(String value) { - addCriterion("dict_type >=", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeLessThan(String value) { - addCriterion("dict_type <", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeLessThanOrEqualTo(String value) { - addCriterion("dict_type <=", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeLike(String value) { - addCriterion("dict_type like", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotLike(String value) { - addCriterion("dict_type not like", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeIn(List values) { - addCriterion("dict_type in", values, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotIn(List values) { - addCriterion("dict_type not in", values, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeBetween(String value1, String value2) { - addCriterion("dict_type between", value1, value2, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotBetween(String value1, String value2) { - addCriterion("dict_type not between", value1, value2, "dictType"); - return (Criteria) this; - } - - - public Criteria andCssClassIsNull() { - addCriterion("css_class is null"); - return (Criteria) this; - } - - public Criteria andCssClassIsNotNull() { - addCriterion("css_class is not null"); - return (Criteria) this; - } - - public Criteria andCssClassEqualTo(String value) { - addCriterion("css_class =", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassNotEqualTo(String value) { - addCriterion("css_class <>", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassGreaterThan(String value) { - addCriterion("css_class >", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassGreaterThanOrEqualTo(String value) { - addCriterion("css_class >=", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassLessThan(String value) { - addCriterion("css_class <", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassLessThanOrEqualTo(String value) { - addCriterion("css_class <=", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassLike(String value) { - addCriterion("css_class like", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassNotLike(String value) { - addCriterion("css_class not like", value, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassIn(List values) { - addCriterion("css_class in", values, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassNotIn(List values) { - addCriterion("css_class not in", values, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassBetween(String value1, String value2) { - addCriterion("css_class between", value1, value2, "cssClass"); - return (Criteria) this; - } - - public Criteria andCssClassNotBetween(String value1, String value2) { - addCriterion("css_class not between", value1, value2, "cssClass"); - return (Criteria) this; - } - - - public Criteria andListClassIsNull() { - addCriterion("list_class is null"); - return (Criteria) this; - } - - public Criteria andListClassIsNotNull() { - addCriterion("list_class is not null"); - return (Criteria) this; - } - - public Criteria andListClassEqualTo(String value) { - addCriterion("list_class =", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassNotEqualTo(String value) { - addCriterion("list_class <>", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassGreaterThan(String value) { - addCriterion("list_class >", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassGreaterThanOrEqualTo(String value) { - addCriterion("list_class >=", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassLessThan(String value) { - addCriterion("list_class <", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassLessThanOrEqualTo(String value) { - addCriterion("list_class <=", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassLike(String value) { - addCriterion("list_class like", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassNotLike(String value) { - addCriterion("list_class not like", value, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassIn(List values) { - addCriterion("list_class in", values, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassNotIn(List values) { - addCriterion("list_class not in", values, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassBetween(String value1, String value2) { - addCriterion("list_class between", value1, value2, "listClass"); - return (Criteria) this; - } - - public Criteria andListClassNotBetween(String value1, String value2) { - addCriterion("list_class not between", value1, value2, "listClass"); - return (Criteria) this; - } - - - public Criteria andIsDefaultIsNull() { - addCriterion("is_default is null"); - return (Criteria) this; - } - - public Criteria andIsDefaultIsNotNull() { - addCriterion("is_default is not null"); - return (Criteria) this; - } - - public Criteria andIsDefaultEqualTo(String value) { - addCriterion("is_default =", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultNotEqualTo(String value) { - addCriterion("is_default <>", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultGreaterThan(String value) { - addCriterion("is_default >", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultGreaterThanOrEqualTo(String value) { - addCriterion("is_default >=", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultLessThan(String value) { - addCriterion("is_default <", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultLessThanOrEqualTo(String value) { - addCriterion("is_default <=", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultLike(String value) { - addCriterion("is_default like", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultNotLike(String value) { - addCriterion("is_default not like", value, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultIn(List values) { - addCriterion("is_default in", values, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultNotIn(List values) { - addCriterion("is_default not in", values, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultBetween(String value1, String value2) { - addCriterion("is_default between", value1, value2, "isDefault"); - return (Criteria) this; - } - - public Criteria andIsDefaultNotBetween(String value1, String value2) { - addCriterion("is_default not between", value1, value2, "isDefault"); - return (Criteria) this; - } - - - public Criteria andStatusIsNull() { - addCriterion("status is null"); - return (Criteria) this; - } - - public Criteria andStatusIsNotNull() { - addCriterion("status is not null"); - return (Criteria) this; - } - - public Criteria andStatusEqualTo(String value) { - addCriterion("status =", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotEqualTo(String value) { - addCriterion("status <>", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThan(String value) { - addCriterion("status >", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThanOrEqualTo(String value) { - addCriterion("status >=", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusLessThan(String value) { - addCriterion("status <", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusLessThanOrEqualTo(String value) { - addCriterion("status <=", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusLike(String value) { - addCriterion("status like", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotLike(String value) { - addCriterion("status not like", value, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusIn(List values) { - addCriterion("status in", values, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotIn(List values) { - addCriterion("status not in", values, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusBetween(String value1, String value2) { - addCriterion("status between", value1, value2, "dataStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotBetween(String value1, String value2) { - addCriterion("status not between", value1, value2, "dataStatus"); - return (Criteria) this; - } - - - public Criteria andCreateByIsNull() { - addCriterion("create_by is null"); - return (Criteria) this; - } - - public Criteria andCreateByIsNotNull() { - addCriterion("create_by is not null"); - return (Criteria) this; - } - - public Criteria andCreateByEqualTo(String value) { - addCriterion("create_by =", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotEqualTo(String value) { - addCriterion("create_by <>", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByGreaterThan(String value) { - addCriterion("create_by >", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByGreaterThanOrEqualTo(String value) { - addCriterion("create_by >=", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByLessThan(String value) { - addCriterion("create_by <", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByLessThanOrEqualTo(String value) { - addCriterion("create_by <=", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByLike(String value) { - addCriterion("create_by like", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotLike(String value) { - addCriterion("create_by not like", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByIn(List values) { - addCriterion("create_by in", values, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotIn(List values) { - addCriterion("create_by not in", values, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByBetween(String value1, String value2) { - addCriterion("create_by between", value1, value2, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotBetween(String value1, String value2) { - addCriterion("create_by not between", value1, value2, "createBy"); - return (Criteria) this; - } - - - public Criteria andCreateTimeIsNull() { - addCriterion("create_time is null"); - return (Criteria) this; - } - - public Criteria andCreateTimeIsNotNull() { - addCriterion("create_time is not null"); - return (Criteria) this; - } - - public Criteria andCreateTimeEqualTo(Date value) { - addCriterion("create_time =", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotEqualTo(Date value) { - addCriterion("create_time <>", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThan(Date value) { - addCriterion("create_time >", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("create_time >=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThan(Date value) { - addCriterion("create_time <", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThanOrEqualTo(Date value) { - addCriterion("create_time <=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLike(Date value) { - addCriterion("create_time like", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotLike(Date value) { - addCriterion("create_time not like", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeIn(List values) { - addCriterion("create_time in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotIn(List values) { - addCriterion("create_time not in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeBetween(Date value1, Date value2) { - addCriterion("create_time between", value1, value2, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotBetween(Date value1, Date value2) { - addCriterion("create_time not between", value1, value2, "createTime"); - return (Criteria) this; - } - - - public Criteria andUpdateByIsNull() { - addCriterion("update_by is null"); - return (Criteria) this; - } - - public Criteria andUpdateByIsNotNull() { - addCriterion("update_by is not null"); - return (Criteria) this; - } - - public Criteria andUpdateByEqualTo(String value) { - addCriterion("update_by =", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotEqualTo(String value) { - addCriterion("update_by <>", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByGreaterThan(String value) { - addCriterion("update_by >", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByGreaterThanOrEqualTo(String value) { - addCriterion("update_by >=", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByLessThan(String value) { - addCriterion("update_by <", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByLessThanOrEqualTo(String value) { - addCriterion("update_by <=", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByLike(String value) { - addCriterion("update_by like", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotLike(String value) { - addCriterion("update_by not like", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByIn(List values) { - addCriterion("update_by in", values, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotIn(List values) { - addCriterion("update_by not in", values, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByBetween(String value1, String value2) { - addCriterion("update_by between", value1, value2, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotBetween(String value1, String value2) { - addCriterion("update_by not between", value1, value2, "updateBy"); - return (Criteria) this; - } - - - public Criteria andUpdateTimeIsNull() { - addCriterion("update_time is null"); - return (Criteria) this; - } - - public Criteria andUpdateTimeIsNotNull() { - addCriterion("update_time is not null"); - return (Criteria) this; - } - - public Criteria andUpdateTimeEqualTo(Date value) { - addCriterion("update_time =", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotEqualTo(Date value) { - addCriterion("update_time <>", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeGreaterThan(Date value) { - addCriterion("update_time >", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("update_time >=", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLessThan(Date value) { - addCriterion("update_time <", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { - addCriterion("update_time <=", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLike(Date value) { - addCriterion("update_time like", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotLike(Date value) { - addCriterion("update_time not like", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeIn(List values) { - addCriterion("update_time in", values, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotIn(List values) { - addCriterion("update_time not in", values, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeBetween(Date value1, Date value2) { - addCriterion("update_time between", value1, value2, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { - addCriterion("update_time not between", value1, value2, "updateTime"); - return (Criteria) this; - } - - - public Criteria andRemarkIsNull() { - addCriterion("remark is null"); - return (Criteria) this; - } - - public Criteria andRemarkIsNotNull() { - addCriterion("remark is not null"); - return (Criteria) this; - } - - public Criteria andRemarkEqualTo(String value) { - addCriterion("remark =", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotEqualTo(String value) { - addCriterion("remark <>", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkGreaterThan(String value) { - addCriterion("remark >", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkGreaterThanOrEqualTo(String value) { - addCriterion("remark >=", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkLessThan(String value) { - addCriterion("remark <", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkLessThanOrEqualTo(String value) { - addCriterion("remark <=", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkLike(String value) { - addCriterion("remark like", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotLike(String value) { - addCriterion("remark not like", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkIn(List values) { - addCriterion("remark in", values, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotIn(List values) { - addCriterion("remark not in", values, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkBetween(String value1, String value2) { - addCriterion("remark between", value1, value2, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotBetween(String value1, String value2) { - addCriterion("remark not between", value1, value2, "remark"); - return (Criteria) this; - } - - - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysDictType.java b/src/main/java/com/fc/test/model/auto/TSysDictType.java deleted file mode 100644 index 04d704507962b0d864c0af0c6325c54d83fe68a3..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysDictType.java +++ /dev/null @@ -1,148 +0,0 @@ - -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; -import com.fasterxml.jackson.annotation.JsonFormat; -/** - * 字典类型表 - * - * @author 一休 - * @email 438081243@qq.com - * @date 2019-09-05 12:34:25 - */ -public class TSysDictType implements Serializable { - - private static final long serialVersionUID = 1L; - - /** 主键 **/ - private String id; - - /** 字典名称 **/ - private String dictName; - - /** 字典类型 **/ - private String dictType; - - /** 状态(0正常 1停用) **/ - private Character status; - - /** 创建者 **/ - private String createBy; - - /** 创建时间 **/ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date createTime; - - /** 更新者 **/ - private String updateBy; - - /** 更新时间 **/ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date updateTime; - - /** 备注 **/ - private String remark; - - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id; - } - - - public String getDictName() { - return dictName; - } - - public void setDictName(String dictName) { - this.dictName = dictName; - } - - - public String getDictType() { - return dictType; - } - - public void setDictType(String dictType) { - this.dictType = dictType; - } - - - public Character getStatus() { - return status; - } - - public void setStatus(Character status) { - this.status = status; - } - - - public String getCreateBy() { - return createBy; - } - - public void setCreateBy(String createBy) { - this.createBy = createBy; - } - - - public Date getCreateTime() { - return createTime; - } - - public void setCreateTime(Date createTime) { - this.createTime = createTime; - } - - - public String getUpdateBy() { - return updateBy; - } - - public void setUpdateBy(String updateBy) { - this.updateBy = updateBy; - } - - - public Date getUpdateTime() { - return updateTime; - } - - public void setUpdateTime(Date updateTime) { - this.updateTime = updateTime; - } - - - public String getRemark() { - return remark; - } - - public void setRemark(String remark) { - this.remark = remark; - } - - - public TSysDictType() { - super(); - } - - - public TSysDictType(String id,String dictName,String dictType,Character status,String createBy,Date createTime,String updateBy,Date updateTime,String remark) { - - this.id = id; - this.dictName = dictName; - this.dictType = dictType; - this.status = status; - this.createBy = createBy; - this.createTime = createTime; - this.updateBy = updateBy; - this.updateTime = updateTime; - this.remark = remark; - - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysDictTypeExample.java b/src/main/java/com/fc/test/model/auto/TSysDictTypeExample.java deleted file mode 100644 index 360a0b1d130b28a7a7901e5d4db1a037b40a5cfb..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysDictTypeExample.java +++ /dev/null @@ -1,849 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -/** - * 字典类型表 - * - * @author 一休 - * @email 438081243@qq.com - * @date 2019-09-05 12:34:25 - */ -public class TSysDictTypeExample { - - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TSysDictTypeExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andDictNameIsNull() { - addCriterion("dict_name is null"); - return (Criteria) this; - } - - public Criteria andDictNameIsNotNull() { - addCriterion("dict_name is not null"); - return (Criteria) this; - } - - public Criteria andDictNameEqualTo(String value) { - addCriterion("dict_name =", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameNotEqualTo(String value) { - addCriterion("dict_name <>", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameGreaterThan(String value) { - addCriterion("dict_name >", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameGreaterThanOrEqualTo(String value) { - addCriterion("dict_name >=", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameLessThan(String value) { - addCriterion("dict_name <", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameLessThanOrEqualTo(String value) { - addCriterion("dict_name <=", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameLike(String value) { - addCriterion("dict_name like", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameNotLike(String value) { - addCriterion("dict_name not like", value, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameIn(List values) { - addCriterion("dict_name in", values, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameNotIn(List values) { - addCriterion("dict_name not in", values, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameBetween(String value1, String value2) { - addCriterion("dict_name between", value1, value2, "dictName"); - return (Criteria) this; - } - - public Criteria andDictNameNotBetween(String value1, String value2) { - addCriterion("dict_name not between", value1, value2, "dictName"); - return (Criteria) this; - } - - - public Criteria andDictTypeIsNull() { - addCriterion("dict_type is null"); - return (Criteria) this; - } - - public Criteria andDictTypeIsNotNull() { - addCriterion("dict_type is not null"); - return (Criteria) this; - } - - public Criteria andDictTypeEqualTo(String value) { - addCriterion("dict_type =", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotEqualTo(String value) { - addCriterion("dict_type <>", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeGreaterThan(String value) { - addCriterion("dict_type >", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeGreaterThanOrEqualTo(String value) { - addCriterion("dict_type >=", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeLessThan(String value) { - addCriterion("dict_type <", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeLessThanOrEqualTo(String value) { - addCriterion("dict_type <=", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeLike(String value) { - addCriterion("dict_type like", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotLike(String value) { - addCriterion("dict_type not like", value, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeIn(List values) { - addCriterion("dict_type in", values, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotIn(List values) { - addCriterion("dict_type not in", values, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeBetween(String value1, String value2) { - addCriterion("dict_type between", value1, value2, "dictType"); - return (Criteria) this; - } - - public Criteria andDictTypeNotBetween(String value1, String value2) { - addCriterion("dict_type not between", value1, value2, "dictType"); - return (Criteria) this; - } - - - public Criteria andStatusIsNull() { - addCriterion("status is null"); - return (Criteria) this; - } - - public Criteria andStatusIsNotNull() { - addCriterion("status is not null"); - return (Criteria) this; - } - - public Criteria andStatusEqualTo(String value) { - addCriterion("status =", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotEqualTo(String value) { - addCriterion("status <>", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThan(String value) { - addCriterion("status >", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusGreaterThanOrEqualTo(String value) { - addCriterion("status >=", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusLessThan(String value) { - addCriterion("status <", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusLessThanOrEqualTo(String value) { - addCriterion("status <=", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusLike(String value) { - addCriterion("status like", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotLike(String value) { - addCriterion("status not like", value, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusIn(List values) { - addCriterion("status in", values, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotIn(List values) { - addCriterion("status not in", values, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusBetween(String value1, String value2) { - addCriterion("status between", value1, value2, "typeStatus"); - return (Criteria) this; - } - - public Criteria andStatusNotBetween(String value1, String value2) { - addCriterion("status not between", value1, value2, "typeStatus"); - return (Criteria) this; - } - - - public Criteria andCreateByIsNull() { - addCriterion("create_by is null"); - return (Criteria) this; - } - - public Criteria andCreateByIsNotNull() { - addCriterion("create_by is not null"); - return (Criteria) this; - } - - public Criteria andCreateByEqualTo(String value) { - addCriterion("create_by =", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotEqualTo(String value) { - addCriterion("create_by <>", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByGreaterThan(String value) { - addCriterion("create_by >", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByGreaterThanOrEqualTo(String value) { - addCriterion("create_by >=", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByLessThan(String value) { - addCriterion("create_by <", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByLessThanOrEqualTo(String value) { - addCriterion("create_by <=", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByLike(String value) { - addCriterion("create_by like", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotLike(String value) { - addCriterion("create_by not like", value, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByIn(List values) { - addCriterion("create_by in", values, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotIn(List values) { - addCriterion("create_by not in", values, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByBetween(String value1, String value2) { - addCriterion("create_by between", value1, value2, "createBy"); - return (Criteria) this; - } - - public Criteria andCreateByNotBetween(String value1, String value2) { - addCriterion("create_by not between", value1, value2, "createBy"); - return (Criteria) this; - } - - - public Criteria andCreateTimeIsNull() { - addCriterion("create_time is null"); - return (Criteria) this; - } - - public Criteria andCreateTimeIsNotNull() { - addCriterion("create_time is not null"); - return (Criteria) this; - } - - public Criteria andCreateTimeEqualTo(Date value) { - addCriterion("create_time =", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotEqualTo(Date value) { - addCriterion("create_time <>", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThan(Date value) { - addCriterion("create_time >", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("create_time >=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThan(Date value) { - addCriterion("create_time <", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThanOrEqualTo(Date value) { - addCriterion("create_time <=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLike(Date value) { - addCriterion("create_time like", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotLike(Date value) { - addCriterion("create_time not like", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeIn(List values) { - addCriterion("create_time in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotIn(List values) { - addCriterion("create_time not in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeBetween(Date value1, Date value2) { - addCriterion("create_time between", value1, value2, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotBetween(Date value1, Date value2) { - addCriterion("create_time not between", value1, value2, "createTime"); - return (Criteria) this; - } - - - public Criteria andUpdateByIsNull() { - addCriterion("update_by is null"); - return (Criteria) this; - } - - public Criteria andUpdateByIsNotNull() { - addCriterion("update_by is not null"); - return (Criteria) this; - } - - public Criteria andUpdateByEqualTo(String value) { - addCriterion("update_by =", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotEqualTo(String value) { - addCriterion("update_by <>", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByGreaterThan(String value) { - addCriterion("update_by >", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByGreaterThanOrEqualTo(String value) { - addCriterion("update_by >=", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByLessThan(String value) { - addCriterion("update_by <", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByLessThanOrEqualTo(String value) { - addCriterion("update_by <=", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByLike(String value) { - addCriterion("update_by like", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotLike(String value) { - addCriterion("update_by not like", value, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByIn(List values) { - addCriterion("update_by in", values, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotIn(List values) { - addCriterion("update_by not in", values, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByBetween(String value1, String value2) { - addCriterion("update_by between", value1, value2, "updateBy"); - return (Criteria) this; - } - - public Criteria andUpdateByNotBetween(String value1, String value2) { - addCriterion("update_by not between", value1, value2, "updateBy"); - return (Criteria) this; - } - - - public Criteria andUpdateTimeIsNull() { - addCriterion("update_time is null"); - return (Criteria) this; - } - - public Criteria andUpdateTimeIsNotNull() { - addCriterion("update_time is not null"); - return (Criteria) this; - } - - public Criteria andUpdateTimeEqualTo(Date value) { - addCriterion("update_time =", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotEqualTo(Date value) { - addCriterion("update_time <>", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeGreaterThan(Date value) { - addCriterion("update_time >", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("update_time >=", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLessThan(Date value) { - addCriterion("update_time <", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { - addCriterion("update_time <=", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLike(Date value) { - addCriterion("update_time like", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotLike(Date value) { - addCriterion("update_time not like", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeIn(List values) { - addCriterion("update_time in", values, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotIn(List values) { - addCriterion("update_time not in", values, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeBetween(Date value1, Date value2) { - addCriterion("update_time between", value1, value2, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { - addCriterion("update_time not between", value1, value2, "updateTime"); - return (Criteria) this; - } - - - public Criteria andRemarkIsNull() { - addCriterion("remark is null"); - return (Criteria) this; - } - - public Criteria andRemarkIsNotNull() { - addCriterion("remark is not null"); - return (Criteria) this; - } - - public Criteria andRemarkEqualTo(String value) { - addCriterion("remark =", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotEqualTo(String value) { - addCriterion("remark <>", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkGreaterThan(String value) { - addCriterion("remark >", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkGreaterThanOrEqualTo(String value) { - addCriterion("remark >=", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkLessThan(String value) { - addCriterion("remark <", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkLessThanOrEqualTo(String value) { - addCriterion("remark <=", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkLike(String value) { - addCriterion("remark like", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotLike(String value) { - addCriterion("remark not like", value, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkIn(List values) { - addCriterion("remark in", values, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotIn(List values) { - addCriterion("remark not in", values, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkBetween(String value1, String value2) { - addCriterion("remark between", value1, value2, "remark"); - return (Criteria) this; - } - - public Criteria andRemarkNotBetween(String value1, String value2) { - addCriterion("remark not between", value1, value2, "remark"); - return (Criteria) this; - } - - - - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysEmail.java b/src/main/java/com/fc/test/model/auto/TSysEmail.java deleted file mode 100644 index 06e39bc23cd638237636840d2602a99922a4b4fd..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysEmail.java +++ /dev/null @@ -1,94 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; -import java.util.Date; - -import com.fasterxml.jackson.annotation.JsonFormat; - -public class TSysEmail implements Serializable { - private String id; - - private String receiversEmail; - - private String title; - - private String content; - - private String sendUserId; - - private String sendUserName; - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date createTime; - - private static final long serialVersionUID = 1L; - - public TSysEmail(String id, String receiversEmail, String title, String content, String sendUserId, String sendUserName, Date createTime) { - this.id = id; - this.receiversEmail = receiversEmail; - this.title = title; - this.content = content; - this.sendUserId = sendUserId; - this.sendUserName = sendUserName; - this.createTime = createTime; - } - - public TSysEmail() { - super(); - } - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getReceiversEmail() { - return receiversEmail; - } - - public void setReceiversEmail(String receiversEmail) { - this.receiversEmail = receiversEmail == null ? null : receiversEmail.trim(); - } - - public String getTitle() { - return title; - } - - public void setTitle(String title) { - this.title = title == null ? null : title.trim(); - } - - public String getContent() { - return content; - } - - public void setContent(String content) { - this.content = content == null ? null : content.trim(); - } - - public String getSendUserId() { - return sendUserId; - } - - public void setSendUserId(String sendUserId) { - this.sendUserId = sendUserId == null ? null : sendUserId.trim(); - } - - public String getSendUserName() { - return sendUserName; - } - - public void setSendUserName(String sendUserName) { - this.sendUserName = sendUserName == null ? null : sendUserName.trim(); - } - - public Date getCreateTime() { - return createTime; - } - - public void setCreateTime(Date createTime) { - this.createTime = createTime; - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysEmailExample.java b/src/main/java/com/fc/test/model/auto/TSysEmailExample.java deleted file mode 100644 index f73437d6d87449cca97cc16734f8b4313a0fec12..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysEmailExample.java +++ /dev/null @@ -1,681 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -public class TSysEmailExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TSysEmailExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andReceiversEmailIsNull() { - addCriterion("receivers_email is null"); - return (Criteria) this; - } - - public Criteria andReceiversEmailIsNotNull() { - addCriterion("receivers_email is not null"); - return (Criteria) this; - } - - public Criteria andReceiversEmailEqualTo(String value) { - addCriterion("receivers_email =", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailNotEqualTo(String value) { - addCriterion("receivers_email <>", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailGreaterThan(String value) { - addCriterion("receivers_email >", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailGreaterThanOrEqualTo(String value) { - addCriterion("receivers_email >=", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailLessThan(String value) { - addCriterion("receivers_email <", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailLessThanOrEqualTo(String value) { - addCriterion("receivers_email <=", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailLike(String value) { - addCriterion("receivers_email like", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailNotLike(String value) { - addCriterion("receivers_email not like", value, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailIn(List values) { - addCriterion("receivers_email in", values, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailNotIn(List values) { - addCriterion("receivers_email not in", values, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailBetween(String value1, String value2) { - addCriterion("receivers_email between", value1, value2, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andReceiversEmailNotBetween(String value1, String value2) { - addCriterion("receivers_email not between", value1, value2, "receiversEmail"); - return (Criteria) this; - } - - public Criteria andTitleIsNull() { - addCriterion("title is null"); - return (Criteria) this; - } - - public Criteria andTitleIsNotNull() { - addCriterion("title is not null"); - return (Criteria) this; - } - - public Criteria andTitleEqualTo(String value) { - addCriterion("title =", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotEqualTo(String value) { - addCriterion("title <>", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleGreaterThan(String value) { - addCriterion("title >", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleGreaterThanOrEqualTo(String value) { - addCriterion("title >=", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLessThan(String value) { - addCriterion("title <", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLessThanOrEqualTo(String value) { - addCriterion("title <=", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLike(String value) { - addCriterion("title like", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotLike(String value) { - addCriterion("title not like", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleIn(List values) { - addCriterion("title in", values, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotIn(List values) { - addCriterion("title not in", values, "title"); - return (Criteria) this; - } - - public Criteria andTitleBetween(String value1, String value2) { - addCriterion("title between", value1, value2, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotBetween(String value1, String value2) { - addCriterion("title not between", value1, value2, "title"); - return (Criteria) this; - } - - public Criteria andContentIsNull() { - addCriterion("content is null"); - return (Criteria) this; - } - - public Criteria andContentIsNotNull() { - addCriterion("content is not null"); - return (Criteria) this; - } - - public Criteria andContentEqualTo(String value) { - addCriterion("content =", value, "content"); - return (Criteria) this; - } - - public Criteria andContentNotEqualTo(String value) { - addCriterion("content <>", value, "content"); - return (Criteria) this; - } - - public Criteria andContentGreaterThan(String value) { - addCriterion("content >", value, "content"); - return (Criteria) this; - } - - public Criteria andContentGreaterThanOrEqualTo(String value) { - addCriterion("content >=", value, "content"); - return (Criteria) this; - } - - public Criteria andContentLessThan(String value) { - addCriterion("content <", value, "content"); - return (Criteria) this; - } - - public Criteria andContentLessThanOrEqualTo(String value) { - addCriterion("content <=", value, "content"); - return (Criteria) this; - } - - public Criteria andContentLike(String value) { - addCriterion("content like", value, "content"); - return (Criteria) this; - } - - public Criteria andContentNotLike(String value) { - addCriterion("content not like", value, "content"); - return (Criteria) this; - } - - public Criteria andContentIn(List values) { - addCriterion("content in", values, "content"); - return (Criteria) this; - } - - public Criteria andContentNotIn(List values) { - addCriterion("content not in", values, "content"); - return (Criteria) this; - } - - public Criteria andContentBetween(String value1, String value2) { - addCriterion("content between", value1, value2, "content"); - return (Criteria) this; - } - - public Criteria andContentNotBetween(String value1, String value2) { - addCriterion("content not between", value1, value2, "content"); - return (Criteria) this; - } - - public Criteria andSendUserIdIsNull() { - addCriterion("send_user_id is null"); - return (Criteria) this; - } - - public Criteria andSendUserIdIsNotNull() { - addCriterion("send_user_id is not null"); - return (Criteria) this; - } - - public Criteria andSendUserIdEqualTo(String value) { - addCriterion("send_user_id =", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdNotEqualTo(String value) { - addCriterion("send_user_id <>", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdGreaterThan(String value) { - addCriterion("send_user_id >", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdGreaterThanOrEqualTo(String value) { - addCriterion("send_user_id >=", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdLessThan(String value) { - addCriterion("send_user_id <", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdLessThanOrEqualTo(String value) { - addCriterion("send_user_id <=", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdLike(String value) { - addCriterion("send_user_id like", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdNotLike(String value) { - addCriterion("send_user_id not like", value, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdIn(List values) { - addCriterion("send_user_id in", values, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdNotIn(List values) { - addCriterion("send_user_id not in", values, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdBetween(String value1, String value2) { - addCriterion("send_user_id between", value1, value2, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserIdNotBetween(String value1, String value2) { - addCriterion("send_user_id not between", value1, value2, "sendUserId"); - return (Criteria) this; - } - - public Criteria andSendUserNameIsNull() { - addCriterion("send_user_name is null"); - return (Criteria) this; - } - - public Criteria andSendUserNameIsNotNull() { - addCriterion("send_user_name is not null"); - return (Criteria) this; - } - - public Criteria andSendUserNameEqualTo(String value) { - addCriterion("send_user_name =", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameNotEqualTo(String value) { - addCriterion("send_user_name <>", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameGreaterThan(String value) { - addCriterion("send_user_name >", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameGreaterThanOrEqualTo(String value) { - addCriterion("send_user_name >=", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameLessThan(String value) { - addCriterion("send_user_name <", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameLessThanOrEqualTo(String value) { - addCriterion("send_user_name <=", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameLike(String value) { - addCriterion("send_user_name like", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameNotLike(String value) { - addCriterion("send_user_name not like", value, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameIn(List values) { - addCriterion("send_user_name in", values, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameNotIn(List values) { - addCriterion("send_user_name not in", values, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameBetween(String value1, String value2) { - addCriterion("send_user_name between", value1, value2, "sendUserName"); - return (Criteria) this; - } - - public Criteria andSendUserNameNotBetween(String value1, String value2) { - addCriterion("send_user_name not between", value1, value2, "sendUserName"); - return (Criteria) this; - } - - public Criteria andCreateTimeIsNull() { - addCriterion("create_time is null"); - return (Criteria) this; - } - - public Criteria andCreateTimeIsNotNull() { - addCriterion("create_time is not null"); - return (Criteria) this; - } - - public Criteria andCreateTimeEqualTo(Date value) { - addCriterion("create_time =", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotEqualTo(Date value) { - addCriterion("create_time <>", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThan(Date value) { - addCriterion("create_time >", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("create_time >=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThan(Date value) { - addCriterion("create_time <", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThanOrEqualTo(Date value) { - addCriterion("create_time <=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeIn(List values) { - addCriterion("create_time in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotIn(List values) { - addCriterion("create_time not in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeBetween(Date value1, Date value2) { - addCriterion("create_time between", value1, value2, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotBetween(Date value1, Date value2) { - addCriterion("create_time not between", value1, value2, "createTime"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysRoleUser.java b/src/main/java/com/fc/test/model/auto/TSysRoleUser.java deleted file mode 100644 index 7a6b820b30d9ca6c7ccead064ea5d077e648dc20..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysRoleUser.java +++ /dev/null @@ -1,50 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; - -public class TSysRoleUser implements Serializable { - private String id; - - private String sysUserId; - - private String sysRoleId; - - private static final long serialVersionUID = 1L; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getSysUserId() { - return sysUserId; - } - - public void setSysUserId(String sysUserId) { - this.sysUserId = sysUserId == null ? null : sysUserId.trim(); - } - - public String getSysRoleId() { - return sysRoleId; - } - - public void setSysRoleId(String sysRoleId) { - this.sysRoleId = sysRoleId == null ? null : sysRoleId.trim(); - } - - public TSysRoleUser() { - super(); - } - - public TSysRoleUser(String id, String sysUserId, String sysRoleId) { - super(); - this.id = id; - this.sysUserId = sysUserId; - this.sysRoleId = sysRoleId; - } - - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TSysRoleUserExample.java b/src/main/java/com/fc/test/model/auto/TSysRoleUserExample.java deleted file mode 100644 index d0187b72a023fb08f649a1accd85d9015bfdba96..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TSysRoleUserExample.java +++ /dev/null @@ -1,410 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -public class TSysRoleUserExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TSysRoleUserExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andSysUserIdIsNull() { - addCriterion("sys_user_id is null"); - return (Criteria) this; - } - - public Criteria andSysUserIdIsNotNull() { - addCriterion("sys_user_id is not null"); - return (Criteria) this; - } - - public Criteria andSysUserIdEqualTo(String value) { - addCriterion("sys_user_id =", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdNotEqualTo(String value) { - addCriterion("sys_user_id <>", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdGreaterThan(String value) { - addCriterion("sys_user_id >", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdGreaterThanOrEqualTo(String value) { - addCriterion("sys_user_id >=", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdLessThan(String value) { - addCriterion("sys_user_id <", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdLessThanOrEqualTo(String value) { - addCriterion("sys_user_id <=", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdLike(String value) { - addCriterion("sys_user_id like", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdNotLike(String value) { - addCriterion("sys_user_id not like", value, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdIn(List values) { - addCriterion("sys_user_id in", values, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdNotIn(List values) { - addCriterion("sys_user_id not in", values, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdBetween(String value1, String value2) { - addCriterion("sys_user_id between", value1, value2, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysUserIdNotBetween(String value1, String value2) { - addCriterion("sys_user_id not between", value1, value2, "sysUserId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdIsNull() { - addCriterion("sys_role_id is null"); - return (Criteria) this; - } - - public Criteria andSysRoleIdIsNotNull() { - addCriterion("sys_role_id is not null"); - return (Criteria) this; - } - - public Criteria andSysRoleIdEqualTo(String value) { - addCriterion("sys_role_id =", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdNotEqualTo(String value) { - addCriterion("sys_role_id <>", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdGreaterThan(String value) { - addCriterion("sys_role_id >", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdGreaterThanOrEqualTo(String value) { - addCriterion("sys_role_id >=", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdLessThan(String value) { - addCriterion("sys_role_id <", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdLessThanOrEqualTo(String value) { - addCriterion("sys_role_id <=", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdLike(String value) { - addCriterion("sys_role_id like", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdNotLike(String value) { - addCriterion("sys_role_id not like", value, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdIn(List values) { - addCriterion("sys_role_id in", values, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdNotIn(List values) { - addCriterion("sys_role_id not in", values, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdBetween(String value1, String value2) { - addCriterion("sys_role_id between", value1, value2, "sysRoleId"); - return (Criteria) this; - } - - public Criteria andSysRoleIdNotBetween(String value1, String value2) { - addCriterion("sys_role_id not between", value1, value2, "sysRoleId"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysDatas.java b/src/main/java/com/fc/test/model/auto/TsysDatas.java deleted file mode 100644 index ecf873594e2c9143ff82f96e48dc244f92f9c293..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysDatas.java +++ /dev/null @@ -1,47 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; - -public class TsysDatas implements Serializable { - private String id; - - private String filePath; - - private String fileSuffix; - - private static final long serialVersionUID = 1L; - - public TsysDatas(String id, String filePath, String fileSuffix) { - this.id = id; - this.filePath = filePath; - this.fileSuffix = fileSuffix; - } - - public TsysDatas() { - super(); - } - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getFilePath() { - return filePath; - } - - public void setFilePath(String filePath) { - this.filePath = filePath == null ? null : filePath.trim(); - } - - public String getFileSuffix() { - return fileSuffix; - } - - public void setFileSuffix(String fileSuffix) { - this.fileSuffix = fileSuffix == null ? null : fileSuffix.trim(); - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysDatasExample.java b/src/main/java/com/fc/test/model/auto/TsysDatasExample.java deleted file mode 100644 index 38ac2b658e8344179241875ce2219c1923ceee4b..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysDatasExample.java +++ /dev/null @@ -1,410 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -public class TsysDatasExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysDatasExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andFilePathIsNull() { - addCriterion("file_path is null"); - return (Criteria) this; - } - - public Criteria andFilePathIsNotNull() { - addCriterion("file_path is not null"); - return (Criteria) this; - } - - public Criteria andFilePathEqualTo(String value) { - addCriterion("file_path =", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathNotEqualTo(String value) { - addCriterion("file_path <>", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathGreaterThan(String value) { - addCriterion("file_path >", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathGreaterThanOrEqualTo(String value) { - addCriterion("file_path >=", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathLessThan(String value) { - addCriterion("file_path <", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathLessThanOrEqualTo(String value) { - addCriterion("file_path <=", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathLike(String value) { - addCriterion("file_path like", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathNotLike(String value) { - addCriterion("file_path not like", value, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathIn(List values) { - addCriterion("file_path in", values, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathNotIn(List values) { - addCriterion("file_path not in", values, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathBetween(String value1, String value2) { - addCriterion("file_path between", value1, value2, "filePath"); - return (Criteria) this; - } - - public Criteria andFilePathNotBetween(String value1, String value2) { - addCriterion("file_path not between", value1, value2, "filePath"); - return (Criteria) this; - } - - public Criteria andFileSuffixIsNull() { - addCriterion("file_suffix is null"); - return (Criteria) this; - } - - public Criteria andFileSuffixIsNotNull() { - addCriterion("file_suffix is not null"); - return (Criteria) this; - } - - public Criteria andFileSuffixEqualTo(String value) { - addCriterion("file_suffix =", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixNotEqualTo(String value) { - addCriterion("file_suffix <>", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixGreaterThan(String value) { - addCriterion("file_suffix >", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixGreaterThanOrEqualTo(String value) { - addCriterion("file_suffix >=", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixLessThan(String value) { - addCriterion("file_suffix <", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixLessThanOrEqualTo(String value) { - addCriterion("file_suffix <=", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixLike(String value) { - addCriterion("file_suffix like", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixNotLike(String value) { - addCriterion("file_suffix not like", value, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixIn(List values) { - addCriterion("file_suffix in", values, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixNotIn(List values) { - addCriterion("file_suffix not in", values, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixBetween(String value1, String value2) { - addCriterion("file_suffix between", value1, value2, "fileSuffix"); - return (Criteria) this; - } - - public Criteria andFileSuffixNotBetween(String value1, String value2) { - addCriterion("file_suffix not between", value1, value2, "fileSuffix"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysFile.java b/src/main/java/com/fc/test/model/auto/TsysFile.java deleted file mode 100644 index b1d40e410f00eb0d4866307eb94019df7158953e..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysFile.java +++ /dev/null @@ -1,107 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.Date; - -import com.fasterxml.jackson.annotation.JsonFormat; - -public class TsysFile { - private String id; - - private String fileName; - - private String createUserId; - - private String createUserName; - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date createTime; - - private String updateUserId; - - private String updateUserName; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date updateTime; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getFileName() { - return fileName; - } - - public void setFileName(String fileName) { - this.fileName = fileName == null ? null : fileName.trim(); - } - - public String getCreateUserId() { - return createUserId; - } - - public void setCreateUserId(String createUserId) { - this.createUserId = createUserId == null ? null : createUserId.trim(); - } - - public String getCreateUserName() { - return createUserName; - } - - public void setCreateUserName(String createUserName) { - this.createUserName = createUserName == null ? null : createUserName.trim(); - } - - public Date getCreateTime() { - return createTime; - } - - public void setCreateTime(Date createTime) { - this.createTime = createTime; - } - - public String getUpdateUserId() { - return updateUserId; - } - - public void setUpdateUserId(String updateUserId) { - this.updateUserId = updateUserId == null ? null : updateUserId.trim(); - } - - public String getUpdateUserName() { - return updateUserName; - } - - public void setUpdateUserName(String updateUserName) { - this.updateUserName = updateUserName == null ? null : updateUserName.trim(); - } - - public Date getUpdateTime() { - return updateTime; - } - - public void setUpdateTime(Date updateTime) { - this.updateTime = updateTime; - } - - public TsysFile() { - super(); - } - - public TsysFile(String id, String fileName, String createUserId, String createUserName, Date createTime, - String updateUserId, String updateUserName, Date updateTime) { - super(); - this.id = id; - this.fileName = fileName; - this.createUserId = createUserId; - this.createUserName = createUserName; - this.createTime = createTime; - this.updateUserId = updateUserId; - this.updateUserName = updateUserName; - this.updateTime = updateTime; - } - - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysFileData.java b/src/main/java/com/fc/test/model/auto/TsysFileData.java deleted file mode 100644 index 1bd71bc553c44a7aa8423835c35eb0c084d78fe9..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysFileData.java +++ /dev/null @@ -1,33 +0,0 @@ -package com.fc.test.model.auto; - -public class TsysFileData { - private String id; - - private String dataId; - - private String fileId; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getDataId() { - return dataId; - } - - public void setDataId(String dataId) { - this.dataId = dataId == null ? null : dataId.trim(); - } - - public String getFileId() { - return fileId; - } - - public void setFileId(String fileId) { - this.fileId = fileId == null ? null : fileId.trim(); - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysFileDataExample.java b/src/main/java/com/fc/test/model/auto/TsysFileDataExample.java deleted file mode 100644 index 8dd5a1766a17a186439b868a8a20d6a4f0251770..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysFileDataExample.java +++ /dev/null @@ -1,410 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -public class TsysFileDataExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysFileDataExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andDataIdIsNull() { - addCriterion("data_id is null"); - return (Criteria) this; - } - - public Criteria andDataIdIsNotNull() { - addCriterion("data_id is not null"); - return (Criteria) this; - } - - public Criteria andDataIdEqualTo(String value) { - addCriterion("data_id =", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdNotEqualTo(String value) { - addCriterion("data_id <>", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdGreaterThan(String value) { - addCriterion("data_id >", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdGreaterThanOrEqualTo(String value) { - addCriterion("data_id >=", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdLessThan(String value) { - addCriterion("data_id <", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdLessThanOrEqualTo(String value) { - addCriterion("data_id <=", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdLike(String value) { - addCriterion("data_id like", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdNotLike(String value) { - addCriterion("data_id not like", value, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdIn(List values) { - addCriterion("data_id in", values, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdNotIn(List values) { - addCriterion("data_id not in", values, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdBetween(String value1, String value2) { - addCriterion("data_id between", value1, value2, "dataId"); - return (Criteria) this; - } - - public Criteria andDataIdNotBetween(String value1, String value2) { - addCriterion("data_id not between", value1, value2, "dataId"); - return (Criteria) this; - } - - public Criteria andFileIdIsNull() { - addCriterion("file_id is null"); - return (Criteria) this; - } - - public Criteria andFileIdIsNotNull() { - addCriterion("file_id is not null"); - return (Criteria) this; - } - - public Criteria andFileIdEqualTo(String value) { - addCriterion("file_id =", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdNotEqualTo(String value) { - addCriterion("file_id <>", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdGreaterThan(String value) { - addCriterion("file_id >", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdGreaterThanOrEqualTo(String value) { - addCriterion("file_id >=", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdLessThan(String value) { - addCriterion("file_id <", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdLessThanOrEqualTo(String value) { - addCriterion("file_id <=", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdLike(String value) { - addCriterion("file_id like", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdNotLike(String value) { - addCriterion("file_id not like", value, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdIn(List values) { - addCriterion("file_id in", values, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdNotIn(List values) { - addCriterion("file_id not in", values, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdBetween(String value1, String value2) { - addCriterion("file_id between", value1, value2, "fileId"); - return (Criteria) this; - } - - public Criteria andFileIdNotBetween(String value1, String value2) { - addCriterion("file_id not between", value1, value2, "fileId"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysFileExample.java b/src/main/java/com/fc/test/model/auto/TsysFileExample.java deleted file mode 100644 index 4c98008ee9ffb9ce88992b0cf72549feb1beec3e..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysFileExample.java +++ /dev/null @@ -1,741 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -public class TsysFileExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysFileExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andFileNameIsNull() { - addCriterion("file_name is null"); - return (Criteria) this; - } - - public Criteria andFileNameIsNotNull() { - addCriterion("file_name is not null"); - return (Criteria) this; - } - - public Criteria andFileNameEqualTo(String value) { - addCriterion("file_name =", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameNotEqualTo(String value) { - addCriterion("file_name <>", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameGreaterThan(String value) { - addCriterion("file_name >", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameGreaterThanOrEqualTo(String value) { - addCriterion("file_name >=", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameLessThan(String value) { - addCriterion("file_name <", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameLessThanOrEqualTo(String value) { - addCriterion("file_name <=", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameLike(String value) { - addCriterion("file_name like", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameNotLike(String value) { - addCriterion("file_name not like", value, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameIn(List values) { - addCriterion("file_name in", values, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameNotIn(List values) { - addCriterion("file_name not in", values, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameBetween(String value1, String value2) { - addCriterion("file_name between", value1, value2, "fileName"); - return (Criteria) this; - } - - public Criteria andFileNameNotBetween(String value1, String value2) { - addCriterion("file_name not between", value1, value2, "fileName"); - return (Criteria) this; - } - - public Criteria andCreateUserIdIsNull() { - addCriterion("create_user_id is null"); - return (Criteria) this; - } - - public Criteria andCreateUserIdIsNotNull() { - addCriterion("create_user_id is not null"); - return (Criteria) this; - } - - public Criteria andCreateUserIdEqualTo(String value) { - addCriterion("create_user_id =", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdNotEqualTo(String value) { - addCriterion("create_user_id <>", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdGreaterThan(String value) { - addCriterion("create_user_id >", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdGreaterThanOrEqualTo(String value) { - addCriterion("create_user_id >=", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdLessThan(String value) { - addCriterion("create_user_id <", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdLessThanOrEqualTo(String value) { - addCriterion("create_user_id <=", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdLike(String value) { - addCriterion("create_user_id like", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdNotLike(String value) { - addCriterion("create_user_id not like", value, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdIn(List values) { - addCriterion("create_user_id in", values, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdNotIn(List values) { - addCriterion("create_user_id not in", values, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdBetween(String value1, String value2) { - addCriterion("create_user_id between", value1, value2, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserIdNotBetween(String value1, String value2) { - addCriterion("create_user_id not between", value1, value2, "createUserId"); - return (Criteria) this; - } - - public Criteria andCreateUserNameIsNull() { - addCriterion("create_user_name is null"); - return (Criteria) this; - } - - public Criteria andCreateUserNameIsNotNull() { - addCriterion("create_user_name is not null"); - return (Criteria) this; - } - - public Criteria andCreateUserNameEqualTo(String value) { - addCriterion("create_user_name =", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameNotEqualTo(String value) { - addCriterion("create_user_name <>", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameGreaterThan(String value) { - addCriterion("create_user_name >", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameGreaterThanOrEqualTo(String value) { - addCriterion("create_user_name >=", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameLessThan(String value) { - addCriterion("create_user_name <", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameLessThanOrEqualTo(String value) { - addCriterion("create_user_name <=", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameLike(String value) { - addCriterion("create_user_name like", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameNotLike(String value) { - addCriterion("create_user_name not like", value, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameIn(List values) { - addCriterion("create_user_name in", values, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameNotIn(List values) { - addCriterion("create_user_name not in", values, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameBetween(String value1, String value2) { - addCriterion("create_user_name between", value1, value2, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateUserNameNotBetween(String value1, String value2) { - addCriterion("create_user_name not between", value1, value2, "createUserName"); - return (Criteria) this; - } - - public Criteria andCreateTimeIsNull() { - addCriterion("create_time is null"); - return (Criteria) this; - } - - public Criteria andCreateTimeIsNotNull() { - addCriterion("create_time is not null"); - return (Criteria) this; - } - - public Criteria andCreateTimeEqualTo(Date value) { - addCriterion("create_time =", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotEqualTo(Date value) { - addCriterion("create_time <>", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThan(Date value) { - addCriterion("create_time >", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("create_time >=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThan(Date value) { - addCriterion("create_time <", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeLessThanOrEqualTo(Date value) { - addCriterion("create_time <=", value, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeIn(List values) { - addCriterion("create_time in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotIn(List values) { - addCriterion("create_time not in", values, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeBetween(Date value1, Date value2) { - addCriterion("create_time between", value1, value2, "createTime"); - return (Criteria) this; - } - - public Criteria andCreateTimeNotBetween(Date value1, Date value2) { - addCriterion("create_time not between", value1, value2, "createTime"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdIsNull() { - addCriterion("update_user_id is null"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdIsNotNull() { - addCriterion("update_user_id is not null"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdEqualTo(String value) { - addCriterion("update_user_id =", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdNotEqualTo(String value) { - addCriterion("update_user_id <>", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdGreaterThan(String value) { - addCriterion("update_user_id >", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdGreaterThanOrEqualTo(String value) { - addCriterion("update_user_id >=", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdLessThan(String value) { - addCriterion("update_user_id <", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdLessThanOrEqualTo(String value) { - addCriterion("update_user_id <=", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdLike(String value) { - addCriterion("update_user_id like", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdNotLike(String value) { - addCriterion("update_user_id not like", value, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdIn(List values) { - addCriterion("update_user_id in", values, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdNotIn(List values) { - addCriterion("update_user_id not in", values, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdBetween(String value1, String value2) { - addCriterion("update_user_id between", value1, value2, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserIdNotBetween(String value1, String value2) { - addCriterion("update_user_id not between", value1, value2, "updateUserId"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameIsNull() { - addCriterion("update_user_name is null"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameIsNotNull() { - addCriterion("update_user_name is not null"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameEqualTo(String value) { - addCriterion("update_user_name =", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameNotEqualTo(String value) { - addCriterion("update_user_name <>", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameGreaterThan(String value) { - addCriterion("update_user_name >", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameGreaterThanOrEqualTo(String value) { - addCriterion("update_user_name >=", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameLessThan(String value) { - addCriterion("update_user_name <", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameLessThanOrEqualTo(String value) { - addCriterion("update_user_name <=", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameLike(String value) { - addCriterion("update_user_name like", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameNotLike(String value) { - addCriterion("update_user_name not like", value, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameIn(List values) { - addCriterion("update_user_name in", values, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameNotIn(List values) { - addCriterion("update_user_name not in", values, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameBetween(String value1, String value2) { - addCriterion("update_user_name between", value1, value2, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateUserNameNotBetween(String value1, String value2) { - addCriterion("update_user_name not between", value1, value2, "updateUserName"); - return (Criteria) this; - } - - public Criteria andUpdateTimeIsNull() { - addCriterion("update_time is null"); - return (Criteria) this; - } - - public Criteria andUpdateTimeIsNotNull() { - addCriterion("update_time is not null"); - return (Criteria) this; - } - - public Criteria andUpdateTimeEqualTo(Date value) { - addCriterion("update_time =", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotEqualTo(Date value) { - addCriterion("update_time <>", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeGreaterThan(Date value) { - addCriterion("update_time >", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { - addCriterion("update_time >=", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLessThan(Date value) { - addCriterion("update_time <", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { - addCriterion("update_time <=", value, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeIn(List values) { - addCriterion("update_time in", values, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotIn(List values) { - addCriterion("update_time not in", values, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeBetween(Date value1, Date value2) { - addCriterion("update_time between", value1, value2, "updateTime"); - return (Criteria) this; - } - - public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { - addCriterion("update_time not between", value1, value2, "updateTime"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysOperLog.java b/src/main/java/com/fc/test/model/auto/TsysOperLog.java deleted file mode 100644 index 73e343504d42e556e54c6c9be46945f37c79c729..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysOperLog.java +++ /dev/null @@ -1,88 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.Date; - -import com.fasterxml.jackson.annotation.JsonFormat; - -public class TsysOperLog { - private String id; - - private String title; - - private String method; - - private String operName; - - private String operUrl; - - private String operParam; - - private String errorMsg; - - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date operTime; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getTitle() { - return title; - } - - public void setTitle(String title) { - this.title = title == null ? null : title.trim(); - } - - public String getMethod() { - return method; - } - - public void setMethod(String method) { - this.method = method == null ? null : method.trim(); - } - - public String getOperName() { - return operName; - } - - public void setOperName(String operName) { - this.operName = operName == null ? null : operName.trim(); - } - - public String getOperUrl() { - return operUrl; - } - - public void setOperUrl(String operUrl) { - this.operUrl = operUrl == null ? null : operUrl.trim(); - } - - public String getOperParam() { - return operParam; - } - - public void setOperParam(String operParam) { - this.operParam = operParam == null ? null : operParam.trim(); - } - - public String getErrorMsg() { - return errorMsg; - } - - public void setErrorMsg(String errorMsg) { - this.errorMsg = errorMsg == null ? null : errorMsg.trim(); - } - - public Date getOperTime() { - return operTime; - } - - public void setOperTime(Date operTime) { - this.operTime = operTime; - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysOperLogExample.java b/src/main/java/com/fc/test/model/auto/TsysOperLogExample.java deleted file mode 100644 index a27d7a18a1b40ddd23a7bfea4079db6cf1a4c662..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysOperLogExample.java +++ /dev/null @@ -1,778 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.Date; -import java.util.Iterator; -import java.util.List; - -public class TsysOperLogExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysOperLogExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - protected void addCriterionForJDBCDate(String condition, Date value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - addCriterion(condition, new java.sql.Date(value.getTime()), property); - } - - protected void addCriterionForJDBCDate(String condition, List values, String property) { - if (values == null || values.size() == 0) { - throw new RuntimeException("Value list for " + property + " cannot be null or empty"); - } - List dateList = new ArrayList(); - Iterator iter = values.iterator(); - while (iter.hasNext()) { - dateList.add(new java.sql.Date(iter.next().getTime())); - } - addCriterion(condition, dateList, property); - } - - protected void addCriterionForJDBCDate(String condition, Date value1, Date value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - addCriterion(condition, new java.sql.Date(value1.getTime()), new java.sql.Date(value2.getTime()), property); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andTitleIsNull() { - addCriterion("title is null"); - return (Criteria) this; - } - - public Criteria andTitleIsNotNull() { - addCriterion("title is not null"); - return (Criteria) this; - } - - public Criteria andTitleEqualTo(String value) { - addCriterion("title =", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotEqualTo(String value) { - addCriterion("title <>", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleGreaterThan(String value) { - addCriterion("title >", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleGreaterThanOrEqualTo(String value) { - addCriterion("title >=", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLessThan(String value) { - addCriterion("title <", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLessThanOrEqualTo(String value) { - addCriterion("title <=", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleLike(String value) { - addCriterion("title like", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotLike(String value) { - addCriterion("title not like", value, "title"); - return (Criteria) this; - } - - public Criteria andTitleIn(List values) { - addCriterion("title in", values, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotIn(List values) { - addCriterion("title not in", values, "title"); - return (Criteria) this; - } - - public Criteria andTitleBetween(String value1, String value2) { - addCriterion("title between", value1, value2, "title"); - return (Criteria) this; - } - - public Criteria andTitleNotBetween(String value1, String value2) { - addCriterion("title not between", value1, value2, "title"); - return (Criteria) this; - } - - public Criteria andMethodIsNull() { - addCriterion("method is null"); - return (Criteria) this; - } - - public Criteria andMethodIsNotNull() { - addCriterion("method is not null"); - return (Criteria) this; - } - - public Criteria andMethodEqualTo(String value) { - addCriterion("method =", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodNotEqualTo(String value) { - addCriterion("method <>", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodGreaterThan(String value) { - addCriterion("method >", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodGreaterThanOrEqualTo(String value) { - addCriterion("method >=", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodLessThan(String value) { - addCriterion("method <", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodLessThanOrEqualTo(String value) { - addCriterion("method <=", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodLike(String value) { - addCriterion("method like", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodNotLike(String value) { - addCriterion("method not like", value, "method"); - return (Criteria) this; - } - - public Criteria andMethodIn(List values) { - addCriterion("method in", values, "method"); - return (Criteria) this; - } - - public Criteria andMethodNotIn(List values) { - addCriterion("method not in", values, "method"); - return (Criteria) this; - } - - public Criteria andMethodBetween(String value1, String value2) { - addCriterion("method between", value1, value2, "method"); - return (Criteria) this; - } - - public Criteria andMethodNotBetween(String value1, String value2) { - addCriterion("method not between", value1, value2, "method"); - return (Criteria) this; - } - - public Criteria andOperNameIsNull() { - addCriterion("oper_name is null"); - return (Criteria) this; - } - - public Criteria andOperNameIsNotNull() { - addCriterion("oper_name is not null"); - return (Criteria) this; - } - - public Criteria andOperNameEqualTo(String value) { - addCriterion("oper_name =", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameNotEqualTo(String value) { - addCriterion("oper_name <>", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameGreaterThan(String value) { - addCriterion("oper_name >", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameGreaterThanOrEqualTo(String value) { - addCriterion("oper_name >=", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameLessThan(String value) { - addCriterion("oper_name <", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameLessThanOrEqualTo(String value) { - addCriterion("oper_name <=", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameLike(String value) { - addCriterion("oper_name like", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameNotLike(String value) { - addCriterion("oper_name not like", value, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameIn(List values) { - addCriterion("oper_name in", values, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameNotIn(List values) { - addCriterion("oper_name not in", values, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameBetween(String value1, String value2) { - addCriterion("oper_name between", value1, value2, "operName"); - return (Criteria) this; - } - - public Criteria andOperNameNotBetween(String value1, String value2) { - addCriterion("oper_name not between", value1, value2, "operName"); - return (Criteria) this; - } - - public Criteria andOperUrlIsNull() { - addCriterion("oper_url is null"); - return (Criteria) this; - } - - public Criteria andOperUrlIsNotNull() { - addCriterion("oper_url is not null"); - return (Criteria) this; - } - - public Criteria andOperUrlEqualTo(String value) { - addCriterion("oper_url =", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlNotEqualTo(String value) { - addCriterion("oper_url <>", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlGreaterThan(String value) { - addCriterion("oper_url >", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlGreaterThanOrEqualTo(String value) { - addCriterion("oper_url >=", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlLessThan(String value) { - addCriterion("oper_url <", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlLessThanOrEqualTo(String value) { - addCriterion("oper_url <=", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlLike(String value) { - addCriterion("oper_url like", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlNotLike(String value) { - addCriterion("oper_url not like", value, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlIn(List values) { - addCriterion("oper_url in", values, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlNotIn(List values) { - addCriterion("oper_url not in", values, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlBetween(String value1, String value2) { - addCriterion("oper_url between", value1, value2, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperUrlNotBetween(String value1, String value2) { - addCriterion("oper_url not between", value1, value2, "operUrl"); - return (Criteria) this; - } - - public Criteria andOperParamIsNull() { - addCriterion("oper_param is null"); - return (Criteria) this; - } - - public Criteria andOperParamIsNotNull() { - addCriterion("oper_param is not null"); - return (Criteria) this; - } - - public Criteria andOperParamEqualTo(String value) { - addCriterion("oper_param =", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamNotEqualTo(String value) { - addCriterion("oper_param <>", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamGreaterThan(String value) { - addCriterion("oper_param >", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamGreaterThanOrEqualTo(String value) { - addCriterion("oper_param >=", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamLessThan(String value) { - addCriterion("oper_param <", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamLessThanOrEqualTo(String value) { - addCriterion("oper_param <=", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamLike(String value) { - addCriterion("oper_param like", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamNotLike(String value) { - addCriterion("oper_param not like", value, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamIn(List values) { - addCriterion("oper_param in", values, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamNotIn(List values) { - addCriterion("oper_param not in", values, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamBetween(String value1, String value2) { - addCriterion("oper_param between", value1, value2, "operParam"); - return (Criteria) this; - } - - public Criteria andOperParamNotBetween(String value1, String value2) { - addCriterion("oper_param not between", value1, value2, "operParam"); - return (Criteria) this; - } - - public Criteria andErrorMsgIsNull() { - addCriterion("error_msg is null"); - return (Criteria) this; - } - - public Criteria andErrorMsgIsNotNull() { - addCriterion("error_msg is not null"); - return (Criteria) this; - } - - public Criteria andErrorMsgEqualTo(String value) { - addCriterion("error_msg =", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgNotEqualTo(String value) { - addCriterion("error_msg <>", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgGreaterThan(String value) { - addCriterion("error_msg >", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgGreaterThanOrEqualTo(String value) { - addCriterion("error_msg >=", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgLessThan(String value) { - addCriterion("error_msg <", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgLessThanOrEqualTo(String value) { - addCriterion("error_msg <=", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgLike(String value) { - addCriterion("error_msg like", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgNotLike(String value) { - addCriterion("error_msg not like", value, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgIn(List values) { - addCriterion("error_msg in", values, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgNotIn(List values) { - addCriterion("error_msg not in", values, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgBetween(String value1, String value2) { - addCriterion("error_msg between", value1, value2, "errorMsg"); - return (Criteria) this; - } - - public Criteria andErrorMsgNotBetween(String value1, String value2) { - addCriterion("error_msg not between", value1, value2, "errorMsg"); - return (Criteria) this; - } - - public Criteria andOperTimeIsNull() { - addCriterion("oper_time is null"); - return (Criteria) this; - } - - public Criteria andOperTimeIsNotNull() { - addCriterion("oper_time is not null"); - return (Criteria) this; - } - - public Criteria andOperTimeEqualTo(Date value) { - addCriterionForJDBCDate("oper_time =", value, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeNotEqualTo(Date value) { - addCriterionForJDBCDate("oper_time <>", value, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeGreaterThan(Date value) { - addCriterionForJDBCDate("oper_time >", value, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeGreaterThanOrEqualTo(Date value) { - addCriterionForJDBCDate("oper_time >=", value, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeLessThan(Date value) { - addCriterionForJDBCDate("oper_time <", value, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeLessThanOrEqualTo(Date value) { - addCriterionForJDBCDate("oper_time <=", value, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeIn(List values) { - addCriterionForJDBCDate("oper_time in", values, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeNotIn(List values) { - addCriterionForJDBCDate("oper_time not in", values, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeBetween(Date value1, Date value2) { - addCriterionForJDBCDate("oper_time between", value1, value2, "operTime"); - return (Criteria) this; - } - - public Criteria andOperTimeNotBetween(Date value1, Date value2) { - addCriterionForJDBCDate("oper_time not between", value1, value2, "operTime"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysPermission.java b/src/main/java/com/fc/test/model/auto/TsysPermission.java deleted file mode 100644 index 72e1e2974eeda9576aa5725abea1d8c1fc5efa6f..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysPermission.java +++ /dev/null @@ -1,147 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; - -public class TsysPermission implements Serializable { - private String id; - - private String name; - - private String descripion; - - private String url; - - private Integer isBlank; - - private String pid; - - private String perms; - - private Integer type; - - private String icon; - - private Integer orderNum; - - private Integer visible; - - private Integer childCount; - - private static final long serialVersionUID = 1L; - - public TsysPermission(String id, String name, String descripion, String url, Integer isBlank, String pid, String perms, Integer type, String icon, Integer orderNum, Integer visible, Integer childCount) { - this.id = id; - this.name = name; - this.descripion = descripion; - this.url = url; - this.isBlank = isBlank; - this.pid = pid; - this.perms = perms; - this.type = type; - this.icon = icon; - this.orderNum = orderNum; - this.visible=visible; - this.childCount = childCount; - } - - public TsysPermission() { - super(); - } - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name == null ? null : name.trim(); - } - - public String getDescripion() { - return descripion; - } - - public void setDescripion(String descripion) { - this.descripion = descripion == null ? null : descripion.trim(); - } - - public String getUrl() { - return url; - } - - public void setUrl(String url) { - this.url = url == null ? null : url.trim(); - } - - public Integer getIsBlank() { - return isBlank; - } - - public void setIsBlank(Integer isBlank) { - this.isBlank = isBlank; - } - - public String getPid() { - return pid; - } - - public void setPid(String pid) { - this.pid = pid == null ? null : pid.trim(); - } - - public String getPerms() { - return perms; - } - - public void setPerms(String perms) { - this.perms = perms == null ? null : perms.trim(); - } - - public Integer getType() { - return type; - } - - public void setType(Integer type) { - this.type = type; - } - - public String getIcon() { - return icon; - } - - public void setIcon(String icon) { - this.icon = icon == null ? null : icon.trim(); - } - - public Integer getOrderNum() { - return orderNum; - } - - public void setOrderNum(Integer orderNum) { - this.orderNum = orderNum; - } - - public Integer getChildCount() { - return childCount; - } - - public void setChildCount(Integer childCount) { - this.childCount = childCount; - } - - public Integer getVisible() { - return visible; - } - - public void setVisible(Integer visible) { - this.visible = visible; - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysPermissionExample.java b/src/main/java/com/fc/test/model/auto/TsysPermissionExample.java deleted file mode 100644 index 4b0322681e9eebec41134626dd8fd290b7b5243b..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysPermissionExample.java +++ /dev/null @@ -1,930 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -public class TsysPermissionExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysPermissionExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andNameIsNull() { - addCriterion("name is null"); - return (Criteria) this; - } - - public Criteria andNameIsNotNull() { - addCriterion("name is not null"); - return (Criteria) this; - } - - public Criteria andNameEqualTo(String value) { - addCriterion("name =", value, "name"); - return (Criteria) this; - } - - public Criteria andNameNotEqualTo(String value) { - addCriterion("name <>", value, "name"); - return (Criteria) this; - } - - public Criteria andNameGreaterThan(String value) { - addCriterion("name >", value, "name"); - return (Criteria) this; - } - - public Criteria andNameGreaterThanOrEqualTo(String value) { - addCriterion("name >=", value, "name"); - return (Criteria) this; - } - - public Criteria andNameLessThan(String value) { - addCriterion("name <", value, "name"); - return (Criteria) this; - } - - public Criteria andNameLessThanOrEqualTo(String value) { - addCriterion("name <=", value, "name"); - return (Criteria) this; - } - - public Criteria andNameLike(String value) { - addCriterion("name like", value, "name"); - return (Criteria) this; - } - - public Criteria andNameNotLike(String value) { - addCriterion("name not like", value, "name"); - return (Criteria) this; - } - - public Criteria andNameIn(List values) { - addCriterion("name in", values, "name"); - return (Criteria) this; - } - - public Criteria andNameNotIn(List values) { - addCriterion("name not in", values, "name"); - return (Criteria) this; - } - - public Criteria andNameBetween(String value1, String value2) { - addCriterion("name between", value1, value2, "name"); - return (Criteria) this; - } - - public Criteria andNameNotBetween(String value1, String value2) { - addCriterion("name not between", value1, value2, "name"); - return (Criteria) this; - } - - public Criteria andDescripionIsNull() { - addCriterion("descripion is null"); - return (Criteria) this; - } - - public Criteria andDescripionIsNotNull() { - addCriterion("descripion is not null"); - return (Criteria) this; - } - - public Criteria andDescripionEqualTo(String value) { - addCriterion("descripion =", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionNotEqualTo(String value) { - addCriterion("descripion <>", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionGreaterThan(String value) { - addCriterion("descripion >", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionGreaterThanOrEqualTo(String value) { - addCriterion("descripion >=", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionLessThan(String value) { - addCriterion("descripion <", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionLessThanOrEqualTo(String value) { - addCriterion("descripion <=", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionLike(String value) { - addCriterion("descripion like", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionNotLike(String value) { - addCriterion("descripion not like", value, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionIn(List values) { - addCriterion("descripion in", values, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionNotIn(List values) { - addCriterion("descripion not in", values, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionBetween(String value1, String value2) { - addCriterion("descripion between", value1, value2, "descripion"); - return (Criteria) this; - } - - public Criteria andDescripionNotBetween(String value1, String value2) { - addCriterion("descripion not between", value1, value2, "descripion"); - return (Criteria) this; - } - - public Criteria andUrlIsNull() { - addCriterion("url is null"); - return (Criteria) this; - } - - public Criteria andUrlIsNotNull() { - addCriterion("url is not null"); - return (Criteria) this; - } - - public Criteria andUrlEqualTo(String value) { - addCriterion("url =", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotEqualTo(String value) { - addCriterion("url <>", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlGreaterThan(String value) { - addCriterion("url >", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlGreaterThanOrEqualTo(String value) { - addCriterion("url >=", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlLessThan(String value) { - addCriterion("url <", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlLessThanOrEqualTo(String value) { - addCriterion("url <=", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlLike(String value) { - addCriterion("url like", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotLike(String value) { - addCriterion("url not like", value, "url"); - return (Criteria) this; - } - - public Criteria andUrlIn(List values) { - addCriterion("url in", values, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotIn(List values) { - addCriterion("url not in", values, "url"); - return (Criteria) this; - } - - public Criteria andUrlBetween(String value1, String value2) { - addCriterion("url between", value1, value2, "url"); - return (Criteria) this; - } - - public Criteria andUrlNotBetween(String value1, String value2) { - addCriterion("url not between", value1, value2, "url"); - return (Criteria) this; - } - - public Criteria andIsBlankIsNull() { - addCriterion("is_blank is null"); - return (Criteria) this; - } - - public Criteria andIsBlankIsNotNull() { - addCriterion("is_blank is not null"); - return (Criteria) this; - } - - public Criteria andIsBlankEqualTo(Integer value) { - addCriterion("is_blank =", value, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankNotEqualTo(Integer value) { - addCriterion("is_blank <>", value, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankGreaterThan(Integer value) { - addCriterion("is_blank >", value, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankGreaterThanOrEqualTo(Integer value) { - addCriterion("is_blank >=", value, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankLessThan(Integer value) { - addCriterion("is_blank <", value, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankLessThanOrEqualTo(Integer value) { - addCriterion("is_blank <=", value, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankIn(List values) { - addCriterion("is_blank in", values, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankNotIn(List values) { - addCriterion("is_blank not in", values, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankBetween(Integer value1, Integer value2) { - addCriterion("is_blank between", value1, value2, "isBlank"); - return (Criteria) this; - } - - public Criteria andIsBlankNotBetween(Integer value1, Integer value2) { - addCriterion("is_blank not between", value1, value2, "isBlank"); - return (Criteria) this; - } - - public Criteria andPidIsNull() { - addCriterion("pid is null"); - return (Criteria) this; - } - - public Criteria andPidIsNotNull() { - addCriterion("pid is not null"); - return (Criteria) this; - } - - public Criteria andPidEqualTo(String value) { - addCriterion("pid =", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidNotEqualTo(String value) { - addCriterion("pid <>", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidGreaterThan(String value) { - addCriterion("pid >", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidGreaterThanOrEqualTo(String value) { - addCriterion("pid >=", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidLessThan(String value) { - addCriterion("pid <", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidLessThanOrEqualTo(String value) { - addCriterion("pid <=", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidLike(String value) { - addCriterion("pid like", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidNotLike(String value) { - addCriterion("pid not like", value, "pid"); - return (Criteria) this; - } - - public Criteria andPidIn(List values) { - addCriterion("pid in", values, "pid"); - return (Criteria) this; - } - - public Criteria andPidNotIn(List values) { - addCriterion("pid not in", values, "pid"); - return (Criteria) this; - } - - public Criteria andPidBetween(String value1, String value2) { - addCriterion("pid between", value1, value2, "pid"); - return (Criteria) this; - } - - public Criteria andPidNotBetween(String value1, String value2) { - addCriterion("pid not between", value1, value2, "pid"); - return (Criteria) this; - } - - public Criteria andPermsIsNull() { - addCriterion("perms is null"); - return (Criteria) this; - } - - public Criteria andPermsIsNotNull() { - addCriterion("perms is not null"); - return (Criteria) this; - } - - public Criteria andPermsEqualTo(String value) { - addCriterion("perms =", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsNotEqualTo(String value) { - addCriterion("perms <>", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsGreaterThan(String value) { - addCriterion("perms >", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsGreaterThanOrEqualTo(String value) { - addCriterion("perms >=", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsLessThan(String value) { - addCriterion("perms <", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsLessThanOrEqualTo(String value) { - addCriterion("perms <=", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsLike(String value) { - addCriterion("perms like", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsNotLike(String value) { - addCriterion("perms not like", value, "perms"); - return (Criteria) this; - } - - public Criteria andPermsIn(List values) { - addCriterion("perms in", values, "perms"); - return (Criteria) this; - } - - public Criteria andPermsNotIn(List values) { - addCriterion("perms not in", values, "perms"); - return (Criteria) this; - } - - public Criteria andPermsBetween(String value1, String value2) { - addCriterion("perms between", value1, value2, "perms"); - return (Criteria) this; - } - - public Criteria andPermsNotBetween(String value1, String value2) { - addCriterion("perms not between", value1, value2, "perms"); - return (Criteria) this; - } - - public Criteria andTypeIsNull() { - addCriterion("type is null"); - return (Criteria) this; - } - - public Criteria andTypeIsNotNull() { - addCriterion("type is not null"); - return (Criteria) this; - } - - public Criteria andTypeEqualTo(Integer value) { - addCriterion("type =", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotEqualTo(Integer value) { - addCriterion("type <>", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeGreaterThan(Integer value) { - addCriterion("type >", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeGreaterThanOrEqualTo(Integer value) { - addCriterion("type >=", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLessThan(Integer value) { - addCriterion("type <", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeLessThanOrEqualTo(Integer value) { - addCriterion("type <=", value, "type"); - return (Criteria) this; - } - - public Criteria andTypeIn(List values) { - addCriterion("type in", values, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotIn(List values) { - addCriterion("type not in", values, "type"); - return (Criteria) this; - } - - public Criteria andTypeBetween(Integer value1, Integer value2) { - addCriterion("type between", value1, value2, "type"); - return (Criteria) this; - } - - public Criteria andTypeNotBetween(Integer value1, Integer value2) { - addCriterion("type not between", value1, value2, "type"); - return (Criteria) this; - } - - public Criteria andIconIsNull() { - addCriterion("icon is null"); - return (Criteria) this; - } - - public Criteria andIconIsNotNull() { - addCriterion("icon is not null"); - return (Criteria) this; - } - - public Criteria andIconEqualTo(String value) { - addCriterion("icon =", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconNotEqualTo(String value) { - addCriterion("icon <>", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconGreaterThan(String value) { - addCriterion("icon >", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconGreaterThanOrEqualTo(String value) { - addCriterion("icon >=", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconLessThan(String value) { - addCriterion("icon <", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconLessThanOrEqualTo(String value) { - addCriterion("icon <=", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconLike(String value) { - addCriterion("icon like", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconNotLike(String value) { - addCriterion("icon not like", value, "icon"); - return (Criteria) this; - } - - public Criteria andIconIn(List values) { - addCriterion("icon in", values, "icon"); - return (Criteria) this; - } - - public Criteria andIconNotIn(List values) { - addCriterion("icon not in", values, "icon"); - return (Criteria) this; - } - - public Criteria andIconBetween(String value1, String value2) { - addCriterion("icon between", value1, value2, "icon"); - return (Criteria) this; - } - - public Criteria andIconNotBetween(String value1, String value2) { - addCriterion("icon not between", value1, value2, "icon"); - return (Criteria) this; - } - - public Criteria andOrderNumIsNull() { - addCriterion("order_num is null"); - return (Criteria) this; - } - - public Criteria andOrderNumIsNotNull() { - addCriterion("order_num is not null"); - return (Criteria) this; - } - - public Criteria andOrderNumEqualTo(Integer value) { - addCriterion("order_num =", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotEqualTo(Integer value) { - addCriterion("order_num <>", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumGreaterThan(Integer value) { - addCriterion("order_num >", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumGreaterThanOrEqualTo(Integer value) { - addCriterion("order_num >=", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLessThan(Integer value) { - addCriterion("order_num <", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumLessThanOrEqualTo(Integer value) { - addCriterion("order_num <=", value, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumIn(List values) { - addCriterion("order_num in", values, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotIn(List values) { - addCriterion("order_num not in", values, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumBetween(Integer value1, Integer value2) { - addCriterion("order_num between", value1, value2, "orderNum"); - return (Criteria) this; - } - - public Criteria andOrderNumNotBetween(Integer value1, Integer value2) { - addCriterion("order_num not between", value1, value2, "orderNum"); - return (Criteria) this; - } - - public Criteria andVisibleIsNull() { - addCriterion("visible is null"); - return (Criteria) this; - } - - public Criteria andVisibleIsNotNull() { - addCriterion("visible is not null"); - return (Criteria) this; - } - - public Criteria andVisibleEqualTo(Integer value) { - addCriterion("visible =", value, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleNotEqualTo(Integer value) { - addCriterion("visible <>", value, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleGreaterThan(Integer value) { - addCriterion("visible >", value, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleGreaterThanOrEqualTo(Integer value) { - addCriterion("visible >=", value, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleLessThan(Integer value) { - addCriterion("visible <", value, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleLessThanOrEqualTo(Integer value) { - addCriterion("visible <=", value, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleIn(List values) { - addCriterion("visible in", values, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleNotIn(List values) { - addCriterion("visible not in", values, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleBetween(Integer value1, Integer value2) { - addCriterion("visible between", value1, value2, "visible"); - return (Criteria) this; - } - - public Criteria andVisibleNotBetween(Integer value1, Integer value2) { - addCriterion("visible not between", value1, value2, "visible"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysPermissionRole.java b/src/main/java/com/fc/test/model/auto/TsysPermissionRole.java deleted file mode 100644 index 9bfdeb08747d2c0640b78e0c7479f668ecbbb802..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysPermissionRole.java +++ /dev/null @@ -1,50 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; - -public class TsysPermissionRole implements Serializable { - private String id; - - private String roleId; - - private String permissionId; - - private static final long serialVersionUID = 1L; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getRoleId() { - return roleId; - } - - public void setRoleId(String roleId) { - this.roleId = roleId == null ? null : roleId.trim(); - } - - public String getPermissionId() { - return permissionId; - } - - public void setPermissionId(String permissionId) { - this.permissionId = permissionId == null ? null : permissionId.trim(); - } - - public TsysPermissionRole(String id, String roleId, String permissionId) { - super(); - this.id = id; - this.roleId = roleId; - this.permissionId = permissionId; - } - - public TsysPermissionRole() { - super(); - } - - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysPermissionRoleExample.java b/src/main/java/com/fc/test/model/auto/TsysPermissionRoleExample.java deleted file mode 100644 index 2f7216df2875da259a44687c0ed62a31e7ce8788..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysPermissionRoleExample.java +++ /dev/null @@ -1,410 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -public class TsysPermissionRoleExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysPermissionRoleExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andRoleIdIsNull() { - addCriterion("role_id is null"); - return (Criteria) this; - } - - public Criteria andRoleIdIsNotNull() { - addCriterion("role_id is not null"); - return (Criteria) this; - } - - public Criteria andRoleIdEqualTo(String value) { - addCriterion("role_id =", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdNotEqualTo(String value) { - addCriterion("role_id <>", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdGreaterThan(String value) { - addCriterion("role_id >", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdGreaterThanOrEqualTo(String value) { - addCriterion("role_id >=", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdLessThan(String value) { - addCriterion("role_id <", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdLessThanOrEqualTo(String value) { - addCriterion("role_id <=", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdLike(String value) { - addCriterion("role_id like", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdNotLike(String value) { - addCriterion("role_id not like", value, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdIn(List values) { - addCriterion("role_id in", values, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdNotIn(List values) { - addCriterion("role_id not in", values, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdBetween(String value1, String value2) { - addCriterion("role_id between", value1, value2, "roleId"); - return (Criteria) this; - } - - public Criteria andRoleIdNotBetween(String value1, String value2) { - addCriterion("role_id not between", value1, value2, "roleId"); - return (Criteria) this; - } - - public Criteria andPermissionIdIsNull() { - addCriterion("permission_id is null"); - return (Criteria) this; - } - - public Criteria andPermissionIdIsNotNull() { - addCriterion("permission_id is not null"); - return (Criteria) this; - } - - public Criteria andPermissionIdEqualTo(String value) { - addCriterion("permission_id =", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdNotEqualTo(String value) { - addCriterion("permission_id <>", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdGreaterThan(String value) { - addCriterion("permission_id >", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdGreaterThanOrEqualTo(String value) { - addCriterion("permission_id >=", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdLessThan(String value) { - addCriterion("permission_id <", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdLessThanOrEqualTo(String value) { - addCriterion("permission_id <=", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdLike(String value) { - addCriterion("permission_id like", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdNotLike(String value) { - addCriterion("permission_id not like", value, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdIn(List values) { - addCriterion("permission_id in", values, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdNotIn(List values) { - addCriterion("permission_id not in", values, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdBetween(String value1, String value2) { - addCriterion("permission_id between", value1, value2, "permissionId"); - return (Criteria) this; - } - - public Criteria andPermissionIdNotBetween(String value1, String value2) { - addCriterion("permission_id not between", value1, value2, "permissionId"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysRole.java b/src/main/java/com/fc/test/model/auto/TsysRole.java deleted file mode 100644 index 5ec8c484635f87bb14e682a75d6fd6bc1aca95c4..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysRole.java +++ /dev/null @@ -1,38 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; - -public class TsysRole implements Serializable { - private String id; - - private String name; - - private static final long serialVersionUID = 1L; - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name == null ? null : name.trim(); - } - - public TsysRole(String id, String name) { - super(); - this.id = id; - this.name = name; - } - - public TsysRole() { - super(); - } - -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysRoleExample.java b/src/main/java/com/fc/test/model/auto/TsysRoleExample.java deleted file mode 100644 index 1d1808a311e713bec77c337a67679890be265bb8..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysRoleExample.java +++ /dev/null @@ -1,340 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -public class TsysRoleExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysRoleExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andNameIsNull() { - addCriterion("name is null"); - return (Criteria) this; - } - - public Criteria andNameIsNotNull() { - addCriterion("name is not null"); - return (Criteria) this; - } - - public Criteria andNameEqualTo(String value) { - addCriterion("name =", value, "name"); - return (Criteria) this; - } - - public Criteria andNameNotEqualTo(String value) { - addCriterion("name <>", value, "name"); - return (Criteria) this; - } - - public Criteria andNameGreaterThan(String value) { - addCriterion("name >", value, "name"); - return (Criteria) this; - } - - public Criteria andNameGreaterThanOrEqualTo(String value) { - addCriterion("name >=", value, "name"); - return (Criteria) this; - } - - public Criteria andNameLessThan(String value) { - addCriterion("name <", value, "name"); - return (Criteria) this; - } - - public Criteria andNameLessThanOrEqualTo(String value) { - addCriterion("name <=", value, "name"); - return (Criteria) this; - } - - public Criteria andNameLike(String value) { - addCriterion("name like", value, "name"); - return (Criteria) this; - } - - public Criteria andNameNotLike(String value) { - addCriterion("name not like", value, "name"); - return (Criteria) this; - } - - public Criteria andNameIn(List values) { - addCriterion("name in", values, "name"); - return (Criteria) this; - } - - public Criteria andNameNotIn(List values) { - addCriterion("name not in", values, "name"); - return (Criteria) this; - } - - public Criteria andNameBetween(String value1, String value2) { - addCriterion("name between", value1, value2, "name"); - return (Criteria) this; - } - - public Criteria andNameNotBetween(String value1, String value2) { - addCriterion("name not between", value1, value2, "name"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysUser.java b/src/main/java/com/fc/test/model/auto/TsysUser.java deleted file mode 100644 index 1fe95816570834c2ed93ac72aabb94162d1eefdf..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysUser.java +++ /dev/null @@ -1,58 +0,0 @@ -package com.fc.test.model.auto; - -import java.io.Serializable; - -public class TsysUser implements Serializable { - private String id; - - private String username; - - private String password; - - private String nickname; - - private static final long serialVersionUID = 1L; - - public TsysUser(String id, String username, String password, String nickname) { - this.id = id; - this.username = username; - this.password = password; - this.nickname = nickname; - } - - public TsysUser() { - super(); - } - - public String getId() { - return id; - } - - public void setId(String id) { - this.id = id == null ? null : id.trim(); - } - - public String getUsername() { - return username; - } - - public void setUsername(String username) { - this.username = username == null ? null : username.trim(); - } - - public String getPassword() { - return password; - } - - public void setPassword(String password) { - this.password = password == null ? null : password.trim(); - } - - public String getNickname() { - return nickname; - } - - public void setNickname(String nickname) { - this.nickname = nickname == null ? null : nickname.trim(); - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/auto/TsysUserExample.java b/src/main/java/com/fc/test/model/auto/TsysUserExample.java deleted file mode 100644 index 2c7e8ad8f3a55f1502e7f3c84c05f76aa5e7fd7c..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/model/auto/TsysUserExample.java +++ /dev/null @@ -1,480 +0,0 @@ -package com.fc.test.model.auto; - -import java.util.ArrayList; -import java.util.List; - -public class TsysUserExample { - protected String orderByClause; - - protected boolean distinct; - - protected List oredCriteria; - - public TsysUserExample() { - oredCriteria = new ArrayList(); - } - - public void setOrderByClause(String orderByClause) { - this.orderByClause = orderByClause; - } - - public String getOrderByClause() { - return orderByClause; - } - - public void setDistinct(boolean distinct) { - this.distinct = distinct; - } - - public boolean isDistinct() { - return distinct; - } - - public List getOredCriteria() { - return oredCriteria; - } - - public void or(Criteria criteria) { - oredCriteria.add(criteria); - } - - public Criteria or() { - Criteria criteria = createCriteriaInternal(); - oredCriteria.add(criteria); - return criteria; - } - - public Criteria createCriteria() { - Criteria criteria = createCriteriaInternal(); - if (oredCriteria.size() == 0) { - oredCriteria.add(criteria); - } - return criteria; - } - - protected Criteria createCriteriaInternal() { - Criteria criteria = new Criteria(); - return criteria; - } - - public void clear() { - oredCriteria.clear(); - orderByClause = null; - distinct = false; - } - - protected abstract static class GeneratedCriteria { - protected List criteria; - - protected GeneratedCriteria() { - super(); - criteria = new ArrayList(); - } - - public boolean isValid() { - return criteria.size() > 0; - } - - public List getAllCriteria() { - return criteria; - } - - public List getCriteria() { - return criteria; - } - - protected void addCriterion(String condition) { - if (condition == null) { - throw new RuntimeException("Value for condition cannot be null"); - } - criteria.add(new Criterion(condition)); - } - - protected void addCriterion(String condition, Object value, String property) { - if (value == null) { - throw new RuntimeException("Value for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value)); - } - - protected void addCriterion(String condition, Object value1, Object value2, String property) { - if (value1 == null || value2 == null) { - throw new RuntimeException("Between values for " + property + " cannot be null"); - } - criteria.add(new Criterion(condition, value1, value2)); - } - - public Criteria andIdIsNull() { - addCriterion("id is null"); - return (Criteria) this; - } - - public Criteria andIdIsNotNull() { - addCriterion("id is not null"); - return (Criteria) this; - } - - public Criteria andIdEqualTo(String value) { - addCriterion("id =", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotEqualTo(String value) { - addCriterion("id <>", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThan(String value) { - addCriterion("id >", value, "id"); - return (Criteria) this; - } - - public Criteria andIdGreaterThanOrEqualTo(String value) { - addCriterion("id >=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThan(String value) { - addCriterion("id <", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLessThanOrEqualTo(String value) { - addCriterion("id <=", value, "id"); - return (Criteria) this; - } - - public Criteria andIdLike(String value) { - addCriterion("id like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdNotLike(String value) { - addCriterion("id not like", value, "id"); - return (Criteria) this; - } - - public Criteria andIdIn(List values) { - addCriterion("id in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdNotIn(List values) { - addCriterion("id not in", values, "id"); - return (Criteria) this; - } - - public Criteria andIdBetween(String value1, String value2) { - addCriterion("id between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andIdNotBetween(String value1, String value2) { - addCriterion("id not between", value1, value2, "id"); - return (Criteria) this; - } - - public Criteria andUsernameIsNull() { - addCriterion("username is null"); - return (Criteria) this; - } - - public Criteria andUsernameIsNotNull() { - addCriterion("username is not null"); - return (Criteria) this; - } - - public Criteria andUsernameEqualTo(String value) { - addCriterion("username =", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameNotEqualTo(String value) { - addCriterion("username <>", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameGreaterThan(String value) { - addCriterion("username >", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameGreaterThanOrEqualTo(String value) { - addCriterion("username >=", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameLessThan(String value) { - addCriterion("username <", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameLessThanOrEqualTo(String value) { - addCriterion("username <=", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameLike(String value) { - addCriterion("username like", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameNotLike(String value) { - addCriterion("username not like", value, "username"); - return (Criteria) this; - } - - public Criteria andUsernameIn(List values) { - addCriterion("username in", values, "username"); - return (Criteria) this; - } - - public Criteria andUsernameNotIn(List values) { - addCriterion("username not in", values, "username"); - return (Criteria) this; - } - - public Criteria andUsernameBetween(String value1, String value2) { - addCriterion("username between", value1, value2, "username"); - return (Criteria) this; - } - - public Criteria andUsernameNotBetween(String value1, String value2) { - addCriterion("username not between", value1, value2, "username"); - return (Criteria) this; - } - - public Criteria andPasswordIsNull() { - addCriterion("password is null"); - return (Criteria) this; - } - - public Criteria andPasswordIsNotNull() { - addCriterion("password is not null"); - return (Criteria) this; - } - - public Criteria andPasswordEqualTo(String value) { - addCriterion("password =", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordNotEqualTo(String value) { - addCriterion("password <>", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordGreaterThan(String value) { - addCriterion("password >", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordGreaterThanOrEqualTo(String value) { - addCriterion("password >=", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordLessThan(String value) { - addCriterion("password <", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordLessThanOrEqualTo(String value) { - addCriterion("password <=", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordLike(String value) { - addCriterion("password like", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordNotLike(String value) { - addCriterion("password not like", value, "password"); - return (Criteria) this; - } - - public Criteria andPasswordIn(List values) { - addCriterion("password in", values, "password"); - return (Criteria) this; - } - - public Criteria andPasswordNotIn(List values) { - addCriterion("password not in", values, "password"); - return (Criteria) this; - } - - public Criteria andPasswordBetween(String value1, String value2) { - addCriterion("password between", value1, value2, "password"); - return (Criteria) this; - } - - public Criteria andPasswordNotBetween(String value1, String value2) { - addCriterion("password not between", value1, value2, "password"); - return (Criteria) this; - } - - public Criteria andNicknameIsNull() { - addCriterion("nickname is null"); - return (Criteria) this; - } - - public Criteria andNicknameIsNotNull() { - addCriterion("nickname is not null"); - return (Criteria) this; - } - - public Criteria andNicknameEqualTo(String value) { - addCriterion("nickname =", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameNotEqualTo(String value) { - addCriterion("nickname <>", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameGreaterThan(String value) { - addCriterion("nickname >", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameGreaterThanOrEqualTo(String value) { - addCriterion("nickname >=", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameLessThan(String value) { - addCriterion("nickname <", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameLessThanOrEqualTo(String value) { - addCriterion("nickname <=", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameLike(String value) { - addCriterion("nickname like", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameNotLike(String value) { - addCriterion("nickname not like", value, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameIn(List values) { - addCriterion("nickname in", values, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameNotIn(List values) { - addCriterion("nickname not in", values, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameBetween(String value1, String value2) { - addCriterion("nickname between", value1, value2, "nickname"); - return (Criteria) this; - } - - public Criteria andNicknameNotBetween(String value1, String value2) { - addCriterion("nickname not between", value1, value2, "nickname"); - return (Criteria) this; - } - } - - public static class Criteria extends GeneratedCriteria { - - protected Criteria() { - super(); - } - } - - public static class Criterion { - private String condition; - - private Object value; - - private Object secondValue; - - private boolean noValue; - - private boolean singleValue; - - private boolean betweenValue; - - private boolean listValue; - - private String typeHandler; - - public String getCondition() { - return condition; - } - - public Object getValue() { - return value; - } - - public Object getSecondValue() { - return secondValue; - } - - public boolean isNoValue() { - return noValue; - } - - public boolean isSingleValue() { - return singleValue; - } - - public boolean isBetweenValue() { - return betweenValue; - } - - public boolean isListValue() { - return listValue; - } - - public String getTypeHandler() { - return typeHandler; - } - - protected Criterion(String condition) { - super(); - this.condition = condition; - this.typeHandler = null; - this.noValue = true; - } - - protected Criterion(String condition, Object value, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.typeHandler = typeHandler; - if (value instanceof List) { - this.listValue = true; - } else { - this.singleValue = true; - } - } - - protected Criterion(String condition, Object value) { - this(condition, value, null); - } - - protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { - super(); - this.condition = condition; - this.value = value; - this.secondValue = secondValue; - this.typeHandler = typeHandler; - this.betweenValue = true; - } - - protected Criterion(String condition, Object value, Object secondValue) { - this(condition, value, secondValue, null); - } - } -} \ No newline at end of file diff --git a/src/main/java/com/fc/test/model/custom/PermissionTreeModelVo.java b/src/main/java/com/fc/test/model/custom/PermissionTreeModelVo.java index d5b148b283a2a42030af6f5594cf9f21af920931..fb84d9bef35da10a2883f581cc6168e4075458fe 100644 --- a/src/main/java/com/fc/test/model/custom/PermissionTreeModelVo.java +++ b/src/main/java/com/fc/test/model/custom/PermissionTreeModelVo.java @@ -1,8 +1,8 @@ package com.fc.test.model.custom; -import java.util.List; +import com.fc.test.dao.model.SysPermissionModel; -import com.fc.test.model.auto.TsysPermission; +import java.util.List; /** * 权限树 @@ -10,15 +10,15 @@ import com.fc.test.model.auto.TsysPermission; * @date: 2018年9月8日 下午6:40:29 */ public class PermissionTreeModelVo { - private TsysPermission tsysPermission; + private SysPermissionModel tsysPermission; List childList;//子类 - public TsysPermission getTsysPermission() { + public SysPermissionModel getTsysPermission() { return tsysPermission; } - public void setTsysPermission(TsysPermission tsysPermission) { + public void setTsysPermission(SysPermissionModel tsysPermission) { this.tsysPermission = tsysPermission; } @@ -30,7 +30,7 @@ public class PermissionTreeModelVo { this.childList = childList; } - public PermissionTreeModelVo(TsysPermission tsysPermission, + public PermissionTreeModelVo(SysPermissionModel tsysPermission, List childList) { super(); this.tsysPermission = tsysPermission; diff --git a/src/main/java/com/fc/test/model/custom/RoleVo.java b/src/main/java/com/fc/test/model/custom/RoleVo.java index 5cf2cf94823ef32434572f47c0ed9fd8708ed903..4da135ace0b113942d08b22112dae6284882d4e9 100644 --- a/src/main/java/com/fc/test/model/custom/RoleVo.java +++ b/src/main/java/com/fc/test/model/custom/RoleVo.java @@ -1,13 +1,13 @@ package com.fc.test.model.custom; -import com.fc.test.model.auto.TsysRole; +import com.fc.test.dao.model.SysRoleModel; /** * 角色自定义数据 * @author fuce * @date: 2018年9月8日 上午12:18:59 */ -public class RoleVo extends TsysRole{ +public class RoleVo extends SysRoleModel { private static final long serialVersionUID = 1L; private boolean ischeck;//判断是否又这个权限 diff --git a/src/main/java/com/fc/test/service/DictService.java b/src/main/java/com/fc/test/service/DictService.java deleted file mode 100644 index a6d4e1423b07a385ad6dc28b766e547fd896c369..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/DictService.java +++ /dev/null @@ -1,54 +0,0 @@ -package com.fc.test.service; - -import java.util.ArrayList; -import java.util.List; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; - -import com.fc.test.mapper.auto.TSysDictDataMapper; -import com.fc.test.model.auto.TSysDictData; -import com.fc.test.model.auto.TSysDictDataExample; - -@Service("dict") -public class DictService { - @Autowired - private TSysDictDataMapper tSysDictDataMapper; - - /** - * 根据字典类型查询字典数据信息 - * - * @param dictType 字典类型 - * @return 参数键值 - */ - public List getType(String dictType) { - TSysDictDataExample example=new TSysDictDataExample(); - if(dictType!=null) { - example.createCriteria().andDictTypeEqualTo(dictType); - return tSysDictDataMapper.selectByExample(example); - } - return new ArrayList(); - } - - /** - * 根据字典类型和字典键值查询字典数据信息 - * - * @param dictType - * 字典类型 - * @param dictValue - * 字典键值 - * @return 字典标签 - */ - public String getLabel(String dictType, String dictValue) { - - TSysDictDataExample example=new TSysDictDataExample(); - if(dictType!=null&&dictValue!=null) { - example.createCriteria().andDictTypeEqualTo(dictType).andDictValueEqualTo(dictValue); - List dictDatas=tSysDictDataMapper.selectByExample(example); - if(dictDatas.size()>0) { - return dictDatas.get(0).getDictLabel(); - } - } - return ""; - } -} diff --git a/src/main/java/com/fc/test/service/GeneratorService.java b/src/main/java/com/fc/test/service/GeneratorService.java index 3846ae577c239f8b0328a0c7d1a57e74e0cea076..69555587d755a4728faef8fefcf2081d6a3fa4eb 100644 --- a/src/main/java/com/fc/test/service/GeneratorService.java +++ b/src/main/java/com/fc/test/service/GeneratorService.java @@ -1,15 +1,15 @@ package com.fc.test.service; -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; +import cn.hutool.json.JSONUtil; +import com.fc.test.common.base.PageInfo; import com.fc.test.mapper.auto.GeneratorMapper; import com.fc.test.model.custom.Tablepar; import com.fc.test.model.custom.TsysTables; import com.fc.test.model.custom.autocode.BeanColumn; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import cn.hutool.json.JSONUtil; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.util.List; /** @@ -30,12 +30,14 @@ public class GeneratorService { * @param pageSize * @return */ - public PageInfo list(Tablepar tablepar,String searchText){ - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= generatorMapper.queryList(searchText); - PageInfo pageInfo = new PageInfo(list); - - return pageInfo; + public PageInfo list(Tablepar tablepar, String searchText){ +// PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); +// List list= generatorMapper.queryList(searchText); +// PageInfo pageInfo = new PageInfo(list); +// +// return pageInfo; + //TODO 自动生成代码 + return null; } diff --git a/src/main/java/com/fc/test/service/SysAreaService.java b/src/main/java/com/fc/test/service/SysAreaService.java deleted file mode 100644 index 82c16e3dfd85a4b575e6b7c7eec9c02f52f3b491..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysAreaService.java +++ /dev/null @@ -1,128 +0,0 @@ -package com.fc.test.service; - -import java.util.Arrays; -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysAreaMapper; -import com.fc.test.model.auto.SysArea; -import com.fc.test.model.auto.SysAreaExample; -import com.fc.test.model.custom.Tablepar; - -/** - * 地区设置 SysAreaService - * @Title: SysAreaService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-10-04 21:47:38   - **/ -@Service -public class SysAreaService { - @Autowired - private SysAreaMapper sysAreaMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - - SysAreaExample testExample=new SysAreaExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andAreaNameLike("%"+name+"%"); - } - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysAreaMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - - return pageInfo; - } - - - public int deleteByPrimaryKey(String ids) { - Integer[] integers = Convert.toIntArray(",", ids); - List stringB = Arrays.asList(integers); - SysAreaExample example=new SysAreaExample(); - example.createCriteria().andIdIn(stringB); - return sysAreaMapper.deleteByExample(example); - } - - - - public SysArea selectByPrimaryKey(Integer id) { - - return sysAreaMapper.selectByPrimaryKey(id); - } - - - - public int updateByPrimaryKeySelective(SysArea record) { - return sysAreaMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - - public int insertSelective(SysArea record) { - //添加雪花主键id - record.setId(null); - return sysAreaMapper.insertSelective(record); - } - - - - public int updateByExampleSelective(SysArea record, SysAreaExample example) { - - return sysAreaMapper.updateByExampleSelective(record, example); - } - - - - public int updateByExample(SysArea record, SysAreaExample example) { - - return sysAreaMapper.updateByExample(record, example); - } - - - public List selectByExample(SysAreaExample example) { - - return sysAreaMapper.selectByExample(example); - } - - - - public long countByExample(SysAreaExample example) { - - return sysAreaMapper.countByExample(example); - } - - - - public int deleteByExample(SysAreaExample example) { - - return sysAreaMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysArea - * @return - */ - public int checkNameUnique(SysArea sysArea){ - SysAreaExample example=new SysAreaExample(); - example.createCriteria().andAreaNameEqualTo(sysArea.getAreaName()); - List list=sysAreaMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/SysCityService.java b/src/main/java/com/fc/test/service/SysCityService.java deleted file mode 100644 index eb52f8e812497e4d0a14c1c2c0a097899db875f9..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysCityService.java +++ /dev/null @@ -1,126 +0,0 @@ -package com.fc.test.service; - -import java.util.Arrays; -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysCityMapper; -import com.fc.test.model.auto.SysCity; -import com.fc.test.model.auto.SysCityExample; -import com.fc.test.model.custom.Tablepar; - -/** - * 城市设置 SysCityService - * @Title: SysCityService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-10-04 21:15:13   - **/ -@Service -public class SysCityService { - @Autowired - private SysCityMapper sysCityMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysCityExample testExample=new SysCityExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andCityNameLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysCityMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - - public int deleteByPrimaryKey(String ids) { - Integer[] integers = Convert.toIntArray(",", ids); - List stringB = Arrays.asList(integers); - SysCityExample example=new SysCityExample(); - example.createCriteria().andIdIn(stringB); - return sysCityMapper.deleteByExample(example); - } - - - - public SysCity selectByPrimaryKey(Integer id) { - return sysCityMapper.selectByPrimaryKey(id); - } - - - - public int updateByPrimaryKeySelective(SysCity record) { - return sysCityMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - - public int insertSelective(SysCity record) { - //添加雪花主键id - record.setId(null); - return sysCityMapper.insertSelective(record); - } - - - - public int updateByExampleSelective(SysCity record, SysCityExample example) { - - return sysCityMapper.updateByExampleSelective(record, example); - } - - - - public int updateByExample(SysCity record, SysCityExample example) { - - return sysCityMapper.updateByExample(record, example); - } - - - public List selectByExample(SysCityExample example) { - - return sysCityMapper.selectByExample(example); - } - - - - public long countByExample(SysCityExample example) { - - return sysCityMapper.countByExample(example); - } - - - - public int deleteByExample(SysCityExample example) { - - return sysCityMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysCity - * @return - */ - public int checkNameUnique(SysCity sysCity){ - SysCityExample example=new SysCityExample(); - example.createCriteria().andCityNameEqualTo(sysCity.getCityName()); - List list=sysCityMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/SysDatasService.java b/src/main/java/com/fc/test/service/SysDatasService.java deleted file mode 100644 index 75fedcfe904fee4504cbe916f742de1105ae7162..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysDatasService.java +++ /dev/null @@ -1,158 +0,0 @@ -package com.fc.test.service; - -import java.io.IOException; -import java.util.List; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.web.multipart.MultipartFile; - -import com.fc.test.common.base.BaseService; -import com.fc.test.common.conf.V2Config; -import com.fc.test.common.file.FileUploadUtils; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TsysDatasMapper; -import com.fc.test.model.auto.TsysDatas; -import com.fc.test.model.auto.TsysDatasExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; -import com.fc.test.util.StringUtils; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; - -@Service -public class SysDatasService implements BaseService{ - - - @Autowired - private TsysDatasMapper tsysDatasMapper; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String searchText){ - TsysDatasExample testExample=new TsysDatasExample(); - testExample.setOrderByClause("id+0 DESC"); - if(searchText!=null&&!"".equals(searchText)){ - testExample.createCriteria().andIdLike("%"+searchText+"%"); - } - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tsysDatasMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - TsysDatasExample example=new TsysDatasExample(); - example.createCriteria().andIdIn(lista); - return tsysDatasMapper.deleteByExample(example); - } - - - - - - - /** - * 文件上传文件存储到文件表 - * @param record - * @param fileURL - * @return 主键 - * @throws IOException - */ - public String insertSelective(MultipartFile file) throws IOException { - //文件上传获取文件名字 - String files = FileUploadUtils.upload(file); - //补充完整url地址 - String filesURL=""; - if ("Y".equals(V2Config.getIsstatic())) { - filesURL=V2Config.getIsroot_dir()+files; - }else { - filesURL=V2Config.getProfile()+files; - } - String fileName=file.getOriginalFilename(); - // 获得文件后缀名称 - String suffixName = fileName.substring(fileName.lastIndexOf(".")).toLowerCase(); - if(StringUtils.isEmpty(suffixName)) { - //如果没有后缀默认后缀 - suffixName=FileUploadUtils.IMAGE_JPG_EXTENSION; - } - - TsysDatas record=new TsysDatas(); - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - record.setFilePath(filesURL); - record.setFileSuffix(suffixName); - if(tsysDatasMapper.insertSelective(record)>0) - { - return record.getId(); - } - return null; - } - - @Override - public int insertSelective(TsysDatas record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - return tsysDatasMapper.insertSelective(record); - } - - @Override - public TsysDatas selectByPrimaryKey(String id) { - - return tsysDatasMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TsysDatas record) { - return tsysDatasMapper.updateByPrimaryKeySelective(record); - } - - public int updateByPrimaryKey(TsysDatas record) { - return tsysDatasMapper.updateByPrimaryKey(record); - } - - - @Override - public int updateByExampleSelective(TsysDatas record, TsysDatasExample example) { - - return tsysDatasMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TsysDatas record, TsysDatasExample example) { - - return tsysDatasMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TsysDatasExample example) { - - return tsysDatasMapper.selectByExample(example); - } - - - @Override - public long countByExample(TsysDatasExample example) { - - return tsysDatasMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TsysDatasExample example) { - - return tsysDatasMapper.deleteByExample(example); - } - - - -} diff --git a/src/main/java/com/fc/test/service/SysDepartmentService.java b/src/main/java/com/fc/test/service/SysDepartmentService.java deleted file mode 100644 index 511125c4466c1f4ce64d7575766d5116ba760970..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysDepartmentService.java +++ /dev/null @@ -1,201 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import java.util.Map; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashMap; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import cn.hutool.core.util.StrUtil; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysDepartmentMapper; -import com.fc.test.model.auto.SysDepartment; -import com.fc.test.model.auto.SysDepartmentExample; -import com.fc.test.model.auto.TsysPermission; -import com.fc.test.model.auto.TsysPermissionExample; -import com.fc.test.model.custom.BootstrapTree; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.StringUtils; - -/** - * 部门表 SysDepartmentService - * - * @Title: SysDepartmentService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-17 13:12:58   - **/ -@Service -public class SysDepartmentService implements BaseService { - @Autowired - private SysDepartmentMapper sysDepartmentMapper; - - /** - * 分页查询 - * - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar, String name) { - SysDepartmentExample testExample = new SysDepartmentExample(); - testExample.setOrderByClause("id ASC"); - if (name != null && !"".equals(name)) { - testExample.createCriteria().andDeptNameLike("%" + name + "%"); - } - if (StrUtil.isNotEmpty(tablepar.getOrderByColumn())) { - testExample.setOrderByClause( - StringUtils.toUnderScoreCase(tablepar.getOrderByColumn()) + " " + tablepar.getIsAsc()); - } - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list = sysDepartmentMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - public List list2(String searchText) { - SysDepartmentExample testExample = new SysDepartmentExample(); - testExample.setOrderByClause("order_num is null ASC,order_num ASC"); - if (searchText != null && !"".equals(searchText)) { - testExample.createCriteria().andDeptNameLike("%" + searchText + "%"); - } - List list = sysDepartmentMapper.selectByExample(testExample); - return list; - } - - @Override - public int deleteByPrimaryKey(String ids) { - - Integer[] integers = Convert.toIntArray(",", ids); - List stringB = Arrays.asList(integers); - SysDepartmentExample example = new SysDepartmentExample(); - example.createCriteria().andIdIn(stringB); - return sysDepartmentMapper.deleteByExample(example); - - } - - @Override - public SysDepartment selectByPrimaryKey(String id) { - - Integer id1 = Integer.valueOf(id); - return sysDepartmentMapper.selectByPrimaryKey(id1); - - } - - @Override - public int updateByPrimaryKeySelective(SysDepartment record) { - return sysDepartmentMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - @Override - public int insertSelective(SysDepartment record) { - - record.setId(null); - - return sysDepartmentMapper.insertSelective(record); - } - - @Override - public int updateByExampleSelective(SysDepartment record, SysDepartmentExample example) { - - return sysDepartmentMapper.updateByExampleSelective(record, example); - } - - @Override - public int updateByExample(SysDepartment record, SysDepartmentExample example) { - - return sysDepartmentMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysDepartmentExample example) { - - return sysDepartmentMapper.selectByExample(example); - } - - @Override - public long countByExample(SysDepartmentExample example) { - - return sysDepartmentMapper.countByExample(example); - } - - @Override - public int deleteByExample(SysDepartmentExample example) { - - return sysDepartmentMapper.deleteByExample(example); - } - - /** - * 检查name - * - * @param sysDepartment - * @return - */ - public int checkNameUnique(SysDepartment sysDepartment) { - SysDepartmentExample example = new SysDepartmentExample(); - example.createCriteria().andDeptNameEqualTo(sysDepartment.getDeptName()); - List list = sysDepartmentMapper.selectByExample(example); - return list.size(); - } - - - - /** - * 获取树 - * @param menuList - * @param parentId - * @return - */ - private static List getbooBootstrapTreePerm(List menuList, String parentId){ - List treeList = new ArrayList<>(); - List childList = null; - for(SysDepartment p : menuList) { - p.setParentId(p.getParentId()==null||p.getParentId().trim().equals("")? "0":p.getParentId()); - if(p.getParentId().trim().equals(parentId)) { - if(p.getChildCount()!=null&&p.getChildCount()>0) { - childList = getbooBootstrapTreePerm(menuList, String.valueOf(p.getId())); - } - BootstrapTree bootstrapTree = new BootstrapTree(p.getDeptName(), "", "", String.valueOf(p.getId()), "",0,childList,p.getDeptName(),p.getStatus()); - treeList.add(bootstrapTree); - childList = null; - } - } - return treeList.size() >0 ? treeList : null; - } - - /** - * 获取转换成bootstarp的权限数据 - * @return - */ - public BootstrapTree getbooBootstrapTreePerm(){ - List treeList = new ArrayList(); - List menuList = getall(); - treeList = getbooBootstrapTreePerm(menuList,"0"); - if(treeList!=null&&treeList.size()==1) { - return treeList.get(0); - } - return new BootstrapTree("菜单", "fa fa-home", "", "-1","###",0,treeList,"",0); - } - - - /** - * 根据用户id获取用户角色如果用户为null 获取所有权限 - * @return - */ - public List getall(){ - SysDepartmentExample example = new SysDepartmentExample(); - example.setOrderByClause("order_num asc"); - return sysDepartmentMapper.selectByExample(example); - - } - -} diff --git a/src/main/java/com/fc/test/service/SysDictDataService.java b/src/main/java/com/fc/test/service/SysDictDataService.java deleted file mode 100644 index e1565f19cde27d37f8a86bc6571436d0d9d8fd20..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysDictDataService.java +++ /dev/null @@ -1,151 +0,0 @@ -package com.fc.test.service; - -import java.util.Date; -import java.util.List; - -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TSysDictDataMapper; -import com.fc.test.mapper.auto.TSysDictTypeMapper; -import com.fc.test.model.auto.TSysDictData; -import com.fc.test.model.auto.TSysDictDataExample; -import com.fc.test.model.auto.TSysDictType; -import com.fc.test.shiro.util.ShiroUtils; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 字典数据表Service -* @Title: TSysDictDataService.java  -* @Package com.fc.test.service  -* @author 一休 -* @email 438081243@qq.com -* @date 2019-09-08 00:10:43   - */ -@Service -public class SysDictDataService implements BaseService{ - @Autowired - private TSysDictDataMapper tSysDictDataMapper; - @Autowired - private TSysDictTypeMapper tSysDictTypeMapper; - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name,String dictId){ - TSysDictDataExample testExample=new TSysDictDataExample(); - testExample.setOrderByClause("dict_sort ASC"); - if(dictId!=null&&!"".equals(dictId)){ - TSysDictType dictType= tSysDictTypeMapper.selectByPrimaryKey(dictId); - if(dictType!=null) { - testExample.createCriteria().andDictTypeEqualTo(dictType.getDictType()); - } - } - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andDictValueLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tSysDictDataMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - - @Override - public int deleteByPrimaryKey(String ids) { - List lista= Convert.toListStrArray(ids); - TSysDictDataExample example=new TSysDictDataExample(); - example.createCriteria().andIdIn(lista); - return tSysDictDataMapper.deleteByExample(example); - } - - /** - * 添加 - */ - @Override - public int insertSelective(TSysDictData record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - record.setCreateTime(new Date()); - record.setUpdateTime(new Date()); - record.setCreateBy(ShiroUtils.getUser().getUsername()); - return tSysDictDataMapper.insertSelective(record); - } - - @Override - public TSysDictData selectByPrimaryKey(String id) { - return tSysDictDataMapper.selectByPrimaryKey(id); - } - - @Override - public int updateByPrimaryKeySelective(TSysDictData record) { - record.setUpdateTime(new Date()); - record.setUpdateBy(ShiroUtils.getUser().getUsername()); - return tSysDictDataMapper.updateByPrimaryKeySelective(record); - } - - - @Override - public int updateByExampleSelective(TSysDictData record, TSysDictDataExample example) { - - return tSysDictDataMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TSysDictData record, TSysDictDataExample example) { - - return tSysDictDataMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TSysDictDataExample example) { - - return tSysDictDataMapper.selectByExample(example); - } - - - @Override - public long countByExample(TSysDictDataExample example) { - - return tSysDictDataMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TSysDictDataExample example) { - - return tSysDictDataMapper.deleteByExample(example); - } - - /** - * 检查name - * @param TSysDictData - * @return - */ - public int checkNameUnique(TSysDictData tSysDictData){ - TSysDictDataExample example=new TSysDictDataExample(); - example.createCriteria().andDictValueEqualTo(tSysDictData.getDictValue()); - List list=tSysDictDataMapper.selectByExample(example); - return list.size(); - } - - /** - * 批量删除 - * @param dictIds - * @author fuce - * @Date 2019年9月9日 上午12:40:52 - */ - public void deleteByPrimaryDictIds(List dictIds) { - TSysDictDataExample example=new TSysDictDataExample(); - example.createCriteria().andIdIn(dictIds); - tSysDictDataMapper.deleteByExample(example); - } -} diff --git a/src/main/java/com/fc/test/service/SysDictTypeService.java b/src/main/java/com/fc/test/service/SysDictTypeService.java deleted file mode 100644 index d7dc8ea9f94f0936d207026c3da96cc38f6d9f2b..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysDictTypeService.java +++ /dev/null @@ -1,152 +0,0 @@ -package com.fc.test.service; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; -import com.fc.test.shiro.util.ShiroUtils; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TSysDictDataMapper; -import com.fc.test.mapper.auto.TSysDictTypeMapper; -import com.fc.test.model.auto.TSysDictDataExample; -import com.fc.test.model.auto.TSysDictType; -import com.fc.test.model.auto.TSysDictTypeExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 字典类型表Service -* @Title: TSysDictTypeService.java  -* @Package com.fc.test.service  -* @author 一休 -* @email 438081243@qq.com -* @date 2019-09-05 12:34:25   - */ -@Service -public class SysDictTypeService implements BaseService{ - @Autowired - private TSysDictTypeMapper tSysDictTypeMapper; - @Autowired - private TSysDictDataMapper tSysDictDataMapper; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - TSysDictTypeExample testExample=new TSysDictTypeExample(); - testExample.setOrderByClause("id+0 desc"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andDictNameLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tSysDictTypeMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - @Transactional - public int deleteByPrimaryKey(String ids) { - //查询type数据得data中DictType有哪些 - List lista=Convert.toListStrArray(ids); - TSysDictTypeExample example=new TSysDictTypeExample(); - example.createCriteria().andIdIn(lista); - List dictTypes=tSysDictTypeMapper.selectByExample(example); - //在删除type下面得data数据 - List datatypes=new ArrayList(); - for (TSysDictType tSysDictType : dictTypes) { - - datatypes.add(tSysDictType.getDictType()); - } - TSysDictDataExample dictDataExample=new TSysDictDataExample(); - dictDataExample.createCriteria().andDictTypeIn(datatypes); - tSysDictDataMapper.deleteByExample(dictDataExample); - //在删除type数据 - tSysDictTypeMapper.deleteByExample(example); - return 1; - } - - - @Override - public TSysDictType selectByPrimaryKey(String id) { - - return tSysDictTypeMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TSysDictType record) { - record.setUpdateTime(new Date()); - record.setUpdateBy(ShiroUtils.getUser().getUsername()); - return tSysDictTypeMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - @Override - public int insertSelective(TSysDictType record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - record.setCreateTime(new Date()); - record.setUpdateTime(new Date()); - record.setCreateBy(ShiroUtils.getUser().getUsername()); - - return tSysDictTypeMapper.insertSelective(record); - } - - - @Override - public int updateByExampleSelective(TSysDictType record, TSysDictTypeExample example) { - - return tSysDictTypeMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TSysDictType record, TSysDictTypeExample example) { - - return tSysDictTypeMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TSysDictTypeExample example) { - - return tSysDictTypeMapper.selectByExample(example); - } - - - @Override - public long countByExample(TSysDictTypeExample example) { - - return tSysDictTypeMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TSysDictTypeExample example) { - - return tSysDictTypeMapper.deleteByExample(example); - } - - /** - * 检查name - * @param TSysDictType - * @return - */ - public int checkNameUnique(TSysDictType tSysDictType){ - TSysDictTypeExample example=new TSysDictTypeExample(); - example.createCriteria().andDictNameEqualTo(tSysDictType.getDictName()); - List list=tSysDictTypeMapper.selectByExample(example); - return list.size(); - } -} diff --git a/src/main/java/com/fc/test/service/SysFileDatasService.java b/src/main/java/com/fc/test/service/SysFileDatasService.java deleted file mode 100644 index 161a7ddbbcc397b18eb3b0f2be5a2802e3e46639..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysFileDatasService.java +++ /dev/null @@ -1,100 +0,0 @@ -package com.fc.test.service; - -import java.util.ArrayList; -import java.util.List; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; - -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TsysDatasMapper; -import com.fc.test.mapper.auto.TsysFileDataMapper; -import com.fc.test.model.auto.TsysDatas; -import com.fc.test.model.auto.TsysFileData; -import com.fc.test.model.auto.TsysFileDataExample; -import com.fc.test.util.SnowflakeIdWorker; - -@Service -public class SysFileDatasService implements BaseService{ - - @Autowired - private TsysFileDataMapper tsysFileDataMapper; - @Autowired - private TsysDatasMapper tsysDatasMapper; - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - TsysFileDataExample example=new TsysFileDataExample(); - example.createCriteria().andIdIn(lista); - return tsysFileDataMapper.deleteByExample(example); - } - - @Override - public int insertSelective(TsysFileData record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - return tsysFileDataMapper.insertSelective(record); - } - - @Override - public TsysFileData selectByPrimaryKey(String id) { - - return tsysFileDataMapper.selectByPrimaryKey(id); - } - - @Override - public int updateByPrimaryKeySelective(TsysFileData record) { - - return tsysFileDataMapper.updateByPrimaryKeySelective(record); - } - - @Override - public int updateByExampleSelective(TsysFileData record, - TsysFileDataExample example) { - - return tsysFileDataMapper.updateByPrimaryKeySelective(record); - } - - @Override - public int updateByExample(TsysFileData record, TsysFileDataExample example) { - - return tsysFileDataMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TsysFileDataExample example) { - - return tsysFileDataMapper.selectByExample(example); - } - - @Override - public long countByExample(TsysFileDataExample example) { - - return tsysFileDataMapper.countByExample(example); - } - - @Override - public int deleteByExample(TsysFileDataExample example) { - - return tsysFileDataMapper.deleteByExample(example); - } - - /** - * 根据文件列表id查询出对应的文件信息,已经支持多个图片获取 - * @param fileid - * @return - */ - public List queryfileID(String fileid){ - List list=new ArrayList(); - TsysFileDataExample fileDataExample=new TsysFileDataExample(); - fileDataExample.createCriteria().andFileIdEqualTo(fileid); - List fileDatas=tsysFileDataMapper.selectByExample(fileDataExample); - for (TsysFileData tsysFileData : fileDatas) { - list.add(tsysDatasMapper.selectByPrimaryKey(tsysFileData.getDataId())); - } - return list; - } - -} diff --git a/src/main/java/com/fc/test/service/SysFileService.java b/src/main/java/com/fc/test/service/SysFileService.java deleted file mode 100644 index f5eadae47adec7ccd5d3ad0bdc5273a6b78dda1b..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysFileService.java +++ /dev/null @@ -1,252 +0,0 @@ -package com.fc.test.service; - -import java.util.Date; -import java.util.List; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; -import org.springframework.util.ClassUtils; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.conf.V2Config; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TsysDatasMapper; -import com.fc.test.mapper.auto.TsysFileDataMapper; -import com.fc.test.mapper.auto.TsysFileMapper; -import com.fc.test.mapper.custom.TsysDatasDao; -import com.fc.test.model.auto.TsysDatas; -import com.fc.test.model.auto.TsysDatasExample; -import com.fc.test.model.auto.TsysFile; -import com.fc.test.model.auto.TsysFileData; -import com.fc.test.model.auto.TsysFileDataExample; -import com.fc.test.model.auto.TsysFileExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.shiro.util.ShiroUtils; -import com.fc.test.util.SnowflakeIdWorker; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; - -import cn.hutool.core.io.FileUtil; - -@Service -public class SysFileService implements BaseService{ - - //文件信息mapper - @Autowired - private TsysFileMapper tsysFileMapper; - //文件存储关联mapper - @Autowired - private TsysFileDataMapper tsysFileDataMapper; - //自定义文件dao - @Autowired - private TsysDatasDao tsysDatasDao; - //文件存储mapper - @Autowired - private TsysDatasMapper tsysDatasMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String searchText){ - TsysFileExample testExample=new TsysFileExample(); - testExample.setOrderByClause("id+0 DESC"); - if(searchText!=null&&!"".equals(searchText)){ - testExample.createCriteria().andFileNameLike("%"+searchText+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tsysFileMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - /** - * 删除文件信息全部 - * @param ids 文件集合 1,2,3 - */ - @Transactional - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - //删除本地文件 - List datas=tsysDatasDao.selectByPrimaryKeys(lista); - for (TsysDatas tsysDatas : datas) { - deletefile(tsysDatas.getFilePath()); - //删除文件存储表 - tsysDatasMapper.deleteByPrimaryKey(tsysDatas.getId()); - - } - //删除数据库 - TsysFileExample example=new TsysFileExample(); - example.createCriteria().andIdIn(lista); - tsysFileMapper.deleteByExample(example); - - //删除关联表 - TsysFileDataExample fileDataExample=new TsysFileDataExample(); - fileDataExample.createCriteria().andFileIdIn(lista); - int i=tsysFileDataMapper.deleteByExample(fileDataExample); - return i; - } - - /** - * 删除文件存储表以及数据库 - * @param ids 文件集合 1,2,3 - */ - public int deleteBydataFile(String ids) { - List lista=Convert.toListStrArray(ids); - //删除本地文件 - TsysDatasExample example=new TsysDatasExample(); - example.createCriteria().andIdIn(lista); - List datas=tsysDatasMapper.selectByExample(example); - - for (TsysDatas tsysDatas : datas) { - deletefile(tsysDatas.getFilePath()); - //删除文件存储表 - tsysDatasMapper.deleteByPrimaryKey(tsysDatas.getId()); - } - //删除数据库 - return tsysDatasMapper.deleteByExample(example); - } - - - /** - *删除本地文件方法 - */ - public void deletefile(String filePath) { - if("Y".equals(V2Config.getIsstatic())) { - String url=ClassUtils.getDefaultClassLoader().getResource("").getPath()+filePath; - - FileUtil.del(url); - }else { - FileUtil.del(filePath); - } - - - } - - - - @Transactional - public int insertSelective(TsysFile record,String dataId) { - //插入创建人id - record.setCreateUserId(ShiroUtils.getUserId()); - //插入创建人name - record.setCreateUserName(ShiroUtils.getLoginName()); - //插入创建时间 - record.setCreateTime(new Date()); - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - //插入关联表 - TsysFileData tsysFileData=new TsysFileData(); - tsysFileData.setId(SnowflakeIdWorker.getUUID()); - tsysFileData.setFileId(record.getId()); - tsysFileData.setDataId(dataId); - tsysFileDataMapper.insert(tsysFileData); - return tsysFileMapper.insertSelective(record); - } - - @Override - public TsysFile selectByPrimaryKey(String id) { - - return tsysFileMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TsysFile record) { - return tsysFileMapper.updateByPrimaryKeySelective(record); - } - - /** - * 修改信息 - * @param record - * @return - */ - @Transactional - public int updateByPrimaryKey(TsysFile record,String dataId) { - //获取旧数据 - TsysFile old_data=tsysFileMapper.selectByPrimaryKey(record.getId()); - - //删除绑定数据 - TsysFileDataExample fileDataExample=new TsysFileDataExample(); - fileDataExample.createCriteria().andFileIdEqualTo(record.getId()); - tsysFileDataMapper.deleteByExample(fileDataExample); - - - //插入关联表 - TsysFileData tsysFileData=new TsysFileData(); - tsysFileData.setId(SnowflakeIdWorker.getUUID()); - tsysFileData.setFileId(record.getId()); - tsysFileData.setDataId(dataId); - tsysFileDataMapper.insert(tsysFileData); - - //修改旧数据 - //插入修改人id - old_data.setUpdateUserId(ShiroUtils.getUserId()); - //插入修改人name - old_data.setUpdateUserName(ShiroUtils.getLoginName()); - //插入修改时间 - old_data.setUpdateTime(new Date()); - - - return tsysFileMapper.updateByPrimaryKey(old_data); - } - - - @Override - public int updateByExampleSelective(TsysFile record, TsysFileExample example) { - - return tsysFileMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TsysFile record, TsysFileExample example) { - - return tsysFileMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TsysFileExample example) { - - return tsysFileMapper.selectByExample(example); - } - - - @Override - public long countByExample(TsysFileExample example) { - - return tsysFileMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TsysFileExample example) { - - return tsysFileMapper.deleteByExample(example); - } - - /** - * 检查文件名字 - * @param TsysFile - * @return - */ - public int checkNameUnique(TsysFile tsysFile){ - TsysFileExample example=new TsysFileExample(); - example.createCriteria().andFileNameEqualTo(tsysFile.getFileName()); - List list=tsysFileMapper.selectByExample(example); - return list.size(); - } - - - //无用 - @Override - public int insertSelective(TsysFile record) { - - return tsysFileMapper.insertSelective(record); - } - -} diff --git a/src/main/java/com/fc/test/service/SysInterUrlService.java b/src/main/java/com/fc/test/service/SysInterUrlService.java deleted file mode 100644 index 07da891f943c2c2175491f1d6e13e3a1c22e3a00..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysInterUrlService.java +++ /dev/null @@ -1,135 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysInterUrlMapper; -import com.fc.test.model.auto.SysInterUrl; -import com.fc.test.model.auto.SysInterUrlExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 拦截url表 SysInterUrlService - * @Title: SysInterUrlService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-01-05 01:48:22   - **/ -@Service -public class SysInterUrlService implements BaseService{ - @Autowired - private SysInterUrlMapper sysInterUrlMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysInterUrlExample testExample=new SysInterUrlExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andInterNameLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysInterUrlMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - public int deleteByPrimaryKey(String ids) { - - List lista=Convert.toListStrArray(ids); - SysInterUrlExample example=new SysInterUrlExample(); - example.createCriteria().andIdIn(lista); - return sysInterUrlMapper.deleteByExample(example); - - - } - - - @Override - public SysInterUrl selectByPrimaryKey(String id) { - - return sysInterUrlMapper.selectByPrimaryKey(id); - - } - - - @Override - public int updateByPrimaryKeySelective(SysInterUrl record) { - return sysInterUrlMapper.updateByPrimaryKeySelective(record); - } - - - /** - * 添加 - */ - @Override - public int insertSelective(SysInterUrl record) { - - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - - - return sysInterUrlMapper.insertSelective(record); - } - - - @Override - public int updateByExampleSelective(SysInterUrl record, SysInterUrlExample example) { - - return sysInterUrlMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(SysInterUrl record, SysInterUrlExample example) { - - return sysInterUrlMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysInterUrlExample example) { - - return sysInterUrlMapper.selectByExample(example); - } - - - @Override - public long countByExample(SysInterUrlExample example) { - - return sysInterUrlMapper.countByExample(example); - } - - - @Override - public int deleteByExample(SysInterUrlExample example) { - - return sysInterUrlMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysInterUrl - * @return - */ - public int checkNameUnique(SysInterUrl sysInterUrl){ - SysInterUrlExample example=new SysInterUrlExample(); - example.createCriteria().andInterNameEqualTo(sysInterUrl.getInterName()); - List list=sysInterUrlMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/SysNoticeService.java b/src/main/java/com/fc/test/service/SysNoticeService.java deleted file mode 100644 index 258f7f04bcec048dcd67ca1d3b13d4e8ed3368df..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysNoticeService.java +++ /dev/null @@ -1,248 +0,0 @@ -package com.fc.test.service; - -import java.util.ArrayList; -import java.util.Date; -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; - -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysNoticeMapper; -import com.fc.test.mapper.auto.SysNoticeUserMapper; -import com.fc.test.model.auto.SysNotice; -import com.fc.test.model.auto.SysNoticeExample; -import com.fc.test.model.auto.SysNoticeUser; -import com.fc.test.model.auto.SysNoticeUserExample; -import com.fc.test.model.auto.SysNoticeUserExample.Criteria; -import com.fc.test.model.auto.TsysUser; -import com.fc.test.model.auto.TsysUserExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.shiro.util.ShiroUtils; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 公告 SysNoticeService - * @Title: SysNoticeService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 01:38:44   - **/ -@Service -public class SysNoticeService implements BaseService{ - @Autowired - private SysNoticeMapper sysNoticeMapper; - @Autowired - private SysUserService sysUserService; - @Autowired - private SysNoticeUserService sysNoticeUserService; - @Autowired - private SysNoticeUserMapper sysNoticeUserMapper; - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysNoticeExample testExample=new SysNoticeExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andTitleLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysNoticeMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - - - /** - * 对应用户的所有公告信息 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(TsysUser tsysUser,Tablepar tablepar,String name){ - //查询未阅读的公告用户外键 - SysNoticeUserExample sysNoticeUserExample=new SysNoticeUserExample(); - Criteria criteria= sysNoticeUserExample.createCriteria(); - criteria.andUserIdEqualTo(tsysUser.getId()); - List noticeUsers= sysNoticeUserMapper.selectByExample(sysNoticeUserExample); - if(noticeUsers!=null&¬iceUsers.size()>0) { - //查询对应的公告列表 - List ids=new ArrayList(); - for (SysNoticeUser sysNoticeUser : noticeUsers) { - ids.add(sysNoticeUser.getNoticeId()); - } - - //分页查询对应用户的所有公告信息 - SysNoticeExample testExample=new SysNoticeExample(); - testExample.setOrderByClause("id desc"); - com.fc.test.model.auto.SysNoticeExample.Criteria criteria1= testExample.createCriteria(); - if(name!=null&&!"".equals(name)){ - criteria1.andTitleLike("%"+name+"%"); - } - - criteria1.andIdIn(ids); - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysNoticeMapper.selectByExample(testExample); - - PageInfo pageInfo = new PageInfo(list); - - return pageInfo; - } - - return new PageInfo(); - - - } - - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - SysNoticeExample example=new SysNoticeExample(); - example.createCriteria().andIdIn(lista); - return sysNoticeMapper.deleteByExample(example); - } - - - @Override - public SysNotice selectByPrimaryKey(String id) { - - return sysNoticeMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(SysNotice record) { - return sysNoticeMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - @Override - @Transactional - public int insertSelective(SysNotice record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - //添加创建人id - record.setCreateId(ShiroUtils.getUserId()); - //添加创建人 - record.setCreateUsername(ShiroUtils.getLoginName()); - //添加创建时间 - record.setCreateTime(new Date()); - sysNoticeMapper.insertSelective(record); - //给所有人添加公告状态 - List list= sysUserService.selectByExample(new TsysUserExample()); - for (TsysUser tsysUser : list) { - SysNoticeUser noticeUser=new SysNoticeUser(null, record.getId(), tsysUser.getId(), 0); - sysNoticeUserService.insertSelective(noticeUser); - } - return 1; - } - - - @Override - public int updateByExampleSelective(SysNotice record, SysNoticeExample example) { - - return sysNoticeMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(SysNotice record, SysNoticeExample example) { - - return sysNoticeMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysNoticeExample example) { - - return sysNoticeMapper.selectByExample(example); - } - - - @Override - public long countByExample(SysNoticeExample example) { - - return sysNoticeMapper.countByExample(example); - } - - - @Override - public int deleteByExample(SysNoticeExample example) { - - return sysNoticeMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysNotice - * @return - */ - public int checkNameUnique(SysNotice sysNotice){ - SysNoticeExample example=new SysNoticeExample(); - example.createCriteria().andTitleEqualTo(sysNotice.getTitle()); - List list=sysNoticeMapper.selectByExample(example); - return list.size(); - } - - /** - * 获取用户未阅读公告 - * @param tsysUser - * @param state 阅读状态 0未阅读 1 阅读 -1全部 - * @return - * @author fuce - * @Date 2019年9月8日 上午3:36:21 - */ - public List getuserNoticeNotRead(TsysUser tsysUser,int state){ - List notices=new ArrayList<>(); - //查询未阅读的公告用户外键 - SysNoticeUserExample sysNoticeUserExample=new SysNoticeUserExample(); - Criteria criteria= sysNoticeUserExample.createCriteria(); - criteria.andUserIdEqualTo(tsysUser.getId()); - if(-1!=state) { - criteria.andStateEqualTo(state); - } - List noticeUsers= sysNoticeUserMapper.selectByExample(sysNoticeUserExample); - if(noticeUsers!=null&¬iceUsers.size()>0) { - //查询对应的公告列表 - List ids=new ArrayList(); - for (SysNoticeUser sysNoticeUser : noticeUsers) { - ids.add(sysNoticeUser.getNoticeId()); - } - SysNoticeExample noticeExample = new SysNoticeExample(); - noticeExample.createCriteria().andIdIn(ids); - notices=sysNoticeMapper.selectByExample(noticeExample); - } - return notices; - } - - - /** - * 根据公告id把当前用户的公告置为以查看 - * @param noticeid - * @author fuce - * @Date 2019年9月8日 下午7:14:19 - */ - public void editUserState(String noticeid) { - //SysNoticeUser - SysNoticeUserExample sysNoticeUserExample=new SysNoticeUserExample(); - sysNoticeUserExample.createCriteria().andNoticeIdEqualTo(noticeid).andUserIdEqualTo(ShiroUtils.getUserId()); - List noticeUsers= sysNoticeUserMapper.selectByExample(sysNoticeUserExample); - for (SysNoticeUser sysNoticeUser : noticeUsers) { - sysNoticeUser.setState(1); - sysNoticeUserMapper.updateByPrimaryKey(sysNoticeUser); - } - } - -} diff --git a/src/main/java/com/fc/test/service/SysNoticeUserService.java b/src/main/java/com/fc/test/service/SysNoticeUserService.java deleted file mode 100644 index a4dd21c2b75a901c37a823afd8c32304cd83ebbd..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysNoticeUserService.java +++ /dev/null @@ -1,125 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysNoticeUserMapper; -import com.fc.test.model.auto.SysNoticeUser; -import com.fc.test.model.auto.SysNoticeUserExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 公告_用户外键 SysNoticeUserService - * @Title: SysNoticeUserService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-08 02:12:54   - **/ -@Service -public class SysNoticeUserService implements BaseService{ - @Autowired - private SysNoticeUserMapper sysNoticeUserMapper; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysNoticeUserExample testExample=new SysNoticeUserExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andUserIdLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysNoticeUserMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - SysNoticeUserExample example=new SysNoticeUserExample(); - example.createCriteria().andIdIn(lista); - return sysNoticeUserMapper.deleteByExample(example); - } - - - @Override - public SysNoticeUser selectByPrimaryKey(String id) { - - return sysNoticeUserMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(SysNoticeUser record) { - return sysNoticeUserMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - @Override - public int insertSelective(SysNoticeUser record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - return sysNoticeUserMapper.insertSelective(record); - } - - - @Override - public int updateByExampleSelective(SysNoticeUser record, SysNoticeUserExample example) { - - return sysNoticeUserMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(SysNoticeUser record, SysNoticeUserExample example) { - - return sysNoticeUserMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysNoticeUserExample example) { - - return sysNoticeUserMapper.selectByExample(example); - } - - - @Override - public long countByExample(SysNoticeUserExample example) { - - return sysNoticeUserMapper.countByExample(example); - } - - - @Override - public int deleteByExample(SysNoticeUserExample example) { - - return sysNoticeUserMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysNoticeUser - * @return - */ - public int checkNameUnique(SysNoticeUser sysNoticeUser){ - SysNoticeUserExample example=new SysNoticeUserExample(); - example.createCriteria().andUserIdEqualTo(sysNoticeUser.getUserId()); - List list=sysNoticeUserMapper.selectByExample(example); - return list.size(); - } - -} diff --git a/src/main/java/com/fc/test/service/SysOperLogService.java b/src/main/java/com/fc/test/service/SysOperLogService.java deleted file mode 100644 index 9f82b94484209a362d5163c60036d0f178143c97..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysOperLogService.java +++ /dev/null @@ -1,112 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TsysOperLogMapper; -import com.fc.test.model.auto.TsysOperLog; -import com.fc.test.model.auto.TsysOperLogExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; - -@Service -public class SysOperLogService implements BaseService{ - - //文件mapper - @Autowired - private TsysOperLogMapper tsysOperLogMapper; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String searchText){ - TsysOperLogExample testExample=new TsysOperLogExample(); - testExample.setOrderByClause("id+0 DESC"); - if(searchText!=null&&!"".equals(searchText)){ - testExample.createCriteria().andTitleLike("%"+searchText+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tsysOperLogMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - TsysOperLogExample example=new TsysOperLogExample(); - example.createCriteria().andIdIn(lista); - return tsysOperLogMapper.deleteByExample(example); - } - - - - - - - @Override - public TsysOperLog selectByPrimaryKey(String id) { - - return tsysOperLogMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TsysOperLog record) { - return tsysOperLogMapper.updateByPrimaryKeySelective(record); - } - - - - - @Override - public int updateByExampleSelective(TsysOperLog record, TsysOperLogExample example) { - - return tsysOperLogMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TsysOperLog record, TsysOperLogExample example) { - - return tsysOperLogMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TsysOperLogExample example) { - - return tsysOperLogMapper.selectByExample(example); - } - - - @Override - public long countByExample(TsysOperLogExample example) { - - return tsysOperLogMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TsysOperLogExample example) { - - return tsysOperLogMapper.deleteByExample(example); - } - - - - @Override - public int insertSelective(TsysOperLog record) { - record.setId(SnowflakeIdWorker.getUUID()); - return tsysOperLogMapper.insertSelective(record); - } - -} diff --git a/src/main/java/com/fc/test/service/SysPermissionService.java b/src/main/java/com/fc/test/service/SysPermissionService.java deleted file mode 100644 index 9ba9ddefab0f044e372651bf8296806b6e28da1c..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysPermissionService.java +++ /dev/null @@ -1,365 +0,0 @@ -package com.fc.test.service; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TsysPermissionMapper; -import com.fc.test.mapper.auto.TsysPermissionRoleMapper; -import com.fc.test.mapper.custom.PermissionDao; -import com.fc.test.model.auto.TsysPermission; -import com.fc.test.model.auto.TsysPermissionExample; -import com.fc.test.model.auto.TsysPermissionRole; -import com.fc.test.model.auto.TsysPermissionRoleExample; -import com.fc.test.model.custom.BootstrapTree; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; -import com.fc.test.util.StringUtils; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; - -@Service -public class SysPermissionService implements BaseService{ - - //权限mapper - @Autowired - private TsysPermissionMapper tsysPermissionMapper; - - //权限自定义dao - @Autowired - private PermissionDao permissionDao; - //权限角色关联表 - @Autowired - private TsysPermissionRoleMapper permissionRoleMapper; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar, String searchText){ - TsysPermissionExample testExample=new TsysPermissionExample(); - testExample.setOrderByClause("order_num is null ASC,order_num ASC"); - if(searchText!=null&&!"".equals(searchText)){ - testExample.createCriteria().andNameLike("%"+searchText+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tsysPermissionMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - public List list2(String searchText){ - TsysPermissionExample testExample=new TsysPermissionExample(); - testExample.setOrderByClause("order_num is null ASC,order_num ASC"); - if(searchText!=null&&!"".equals(searchText)){ - testExample.createCriteria().andNameLike("%"+searchText+"%"); - } - List list= tsysPermissionMapper.selectByExample(testExample); - return list; - } - - - @Override - public int deleteByPrimaryKey(String ids) { - //转成集合 - List lista=Convert.toListStrArray(ids); - - - //判断角色是否删除去除 - TsysPermissionRoleExample permissionRoleExample=new TsysPermissionRoleExample(); - permissionRoleExample.createCriteria().andPermissionIdIn(lista); - List tsysPermissionRoles=permissionRoleMapper.selectByExample(permissionRoleExample); - if(tsysPermissionRoles.size()>0) {//有角色外键 - return -2; - } - - //判断是否有子集 - TsysPermissionExample example=new TsysPermissionExample(); - example.createCriteria().andIdIn(lista); - List tsysPermissions = tsysPermissionMapper.selectByExample(example); - boolean lag=false; - for (TsysPermission tsysPermission : tsysPermissions) { - if(tsysPermission.getChildCount()>0) { - lag=true; - } - } - if(lag) {//有子集 无法删除 - return -1; - }else {//删除操作 - int i=tsysPermissionMapper.deleteByExample(example); - if(i>0) {//删除成功 - return 1; - }else {//删除失败 - return 0; - } - - } - } - - - - @Override - public int insertSelective(TsysPermission record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - //判断为目录的时候添加父id为0 - if(record!=null&&record.getType()==0){ - record.setPid("1"); - } - //默认设置不跳转 - if(record.getIsBlank()==null) { - record.setIsBlank(0); - } - return tsysPermissionMapper.insertSelective(record); - } - - @Override - public TsysPermission selectByPrimaryKey(String id) { - - return tsysPermissionMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TsysPermission record) { - //默认设置不跳转 - if(record.getIsBlank()==null) { - record.setIsBlank(0); - } - return tsysPermissionMapper.updateByPrimaryKeySelective(record); - } - - public int updateByPrimaryKey(TsysPermission record) { - //默认设置不跳转 - if(record.getIsBlank()==null) { - record.setIsBlank(0); - } - return tsysPermissionMapper.updateByPrimaryKey(record); - } - - - @Override - public int updateByExampleSelective(TsysPermission record, TsysPermissionExample example) { - //默认设置不跳转 - if(record.getIsBlank()==null) { - record.setIsBlank(0); - } - return tsysPermissionMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TsysPermission record, TsysPermissionExample example) { - //默认设置不跳转 - if(record.getIsBlank()==null) { - record.setIsBlank(0); - } - return tsysPermissionMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TsysPermissionExample example) { - - return tsysPermissionMapper.selectByExample(example); - } - - - @Override - public long countByExample(TsysPermissionExample example) { - - return tsysPermissionMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TsysPermissionExample example) { - - return tsysPermissionMapper.deleteByExample(example); - } - - /** - * 检查权限名字 - * @param tsysUser - * @return - */ - public int checkNameUnique(TsysPermission tsysPermission){ - TsysPermissionExample example=new TsysPermissionExample(); - example.createCriteria().andNameEqualTo(tsysPermission.getName()); - List list=tsysPermissionMapper.selectByExample(example); - return list.size(); - } - - /** - * 检查权限URL - * @param tsysUser - * @return - */ - public int checkURLUnique(TsysPermission tsysPermission){ - TsysPermissionExample example=new TsysPermissionExample(); - example.createCriteria().andUrlEqualTo(tsysPermission.getUrl()); - List list=tsysPermissionMapper.selectByExample(example); - return list.size(); - } - - /** - * 检查权限perms字段 - * @param tsysUser - * @return - */ - public int checkPermsUnique(TsysPermission tsysPermission){ - TsysPermissionExample example=new TsysPermissionExample(); - example.createCriteria().andPermsEqualTo(tsysPermission.getPerms()); - List list=tsysPermissionMapper.selectByExample(example); - return list.size(); - } - - - /** - * 根据父id 以及类型查询权限子集 - * @param pid - * @return - */ - public List queryPid(String pid, int type){ - TsysPermissionExample example=new TsysPermissionExample(); - example.createCriteria().andPidEqualTo(pid).andTypeEqualTo(type); - return tsysPermissionMapper.selectByExample(example); - } - - /** - * 获取转换成bootstarp的权限数据 - * @return - */ - public BootstrapTree getbooBootstrapTreePerm(String userid){ - List treeList = new ArrayList(); - List menuList = getall(userid); - treeList = getbooBootstrapTreePerm(menuList,"0"); - if(treeList!=null&&treeList.size()==1) { - return treeList.get(0); - } - return new BootstrapTree("菜单", "fa fa-home", "", "-1","###",0,treeList,"",0); - } - - - - /** - * 获取树 - * @param menuList - * @param parentId - * @return - */ - private static List getbooBootstrapTreePerm(List menuList, String parentId){ - List treeList = new ArrayList<>(); - List childList = null; - for(TsysPermission p : menuList) { - p.setPid(p.getPid()==null||p.getPid().trim().equals("")?"0":p.getPid()); - if(p.getPid().trim().equals(parentId)) { - if(p.getChildCount()!=null&&p.getChildCount()>0) { - childList = getbooBootstrapTreePerm(menuList, String.valueOf(p.getId())); - } - BootstrapTree bootstrapTree = new BootstrapTree(p.getName(), p.getIcon(), "", String.valueOf(p.getId()), p.getUrl(),p.getIsBlank(),childList,p.getPerms(),p.getVisible()); - treeList.add(bootstrapTree); - childList = null; - } - } - return treeList.size() >0 ? treeList : null; - } - - /** - * 根据用户id获取用户角色如果用户为null 获取所有权限 - * @return - */ - public List getall(String userid){ - if(StringUtils.isEmpty(userid)) { - TsysPermissionExample example = new TsysPermissionExample(); - example.setOrderByClause("order_num asc"); - return tsysPermissionMapper.selectByExample(example); - } - return permissionDao.findByAdminUserId(userid); - } - - - - - - /** - * 判断权限是否有权限 - * @param myTsysPermissions - * @param sysPermission - */ - public Boolean ifpermissions(List myTsysPermissions, BootstrapTree sysPermission){ - for (TsysPermission mytsysPermission : myTsysPermissions) { - if(sysPermission.getId().equals(mytsysPermission.getId())){ - return true; - } - } - return false; - } - - - /** - * 获取角色已有的Bootstarp权限 - * @return - */ - public BootstrapTree getCheckPrem(String roleid) { - Map map = new HashMap(); - //设置选中 - map.put("checked", true); - //设置展开 - //map.put("expanded", true); - // 获取角色的权限 - List myTsysPermissions = permissionDao.queryRoleId(roleid); - // 获取所有的权限 - BootstrapTree sysPermissions = getbooBootstrapTreePerm(null); - iterationCheckPre(sysPermissions, myTsysPermissions, map); - return sysPermissions; - - } - - /** - * 循环迭代获取所有权限 - * @param pboostrapTree - * @param myTsysPermissions - * @param map - */ - public void iterationCheckPre(BootstrapTree pboostrapTree, List myTsysPermissions, Map map) { - if(null!=pboostrapTree) { - if (ifpermissions(myTsysPermissions, pboostrapTree)) { - pboostrapTree.setState(map); - } - List bootstrapTreeList = pboostrapTree.getNodes(); - if(null!=bootstrapTreeList&&!bootstrapTreeList.isEmpty()) { - for(BootstrapTree bootstrapTree : bootstrapTreeList) { - if (ifpermissions(myTsysPermissions, bootstrapTree)) {// 菜单栏设置 - bootstrapTree.setState(map); - } - //检查子节点 - iterationCheckPre(bootstrapTree, myTsysPermissions, map); - } - } - } - } - - /** - * 根据权限字段查询是否存在 - * @param perms - * @return - * @author fuce - * @Date 2019年9月1日 上午2:06:31 - */ - public Boolean queryLikePerms(String perms){ - TsysPermissionExample example=new TsysPermissionExample(); - example.createCriteria().andPermsLike("%gen:"+perms+"%"); - List list= tsysPermissionMapper.selectByExample(example); - return list.size() > 0; - } - - -} diff --git a/src/main/java/com/fc/test/service/SysPositionService.java b/src/main/java/com/fc/test/service/SysPositionService.java deleted file mode 100644 index 478264e741141a8f3f592fbf32394819a736d6e4..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysPositionService.java +++ /dev/null @@ -1,142 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import cn.hutool.core.util.StrUtil; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysPositionMapper; -import com.fc.test.model.auto.SysPosition; -import com.fc.test.model.auto.SysPositionExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; -import com.fc.test.util.StringUtils; - -/** - * 岗位表 SysPositionService - * @Title: SysPositionService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2020-04-16 23:46:24   - **/ -@Service -public class SysPositionService implements BaseService{ - @Autowired - private SysPositionMapper sysPositionMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysPositionExample testExample=new SysPositionExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andPostNameLike("%"+name+"%"); - } - - if(StrUtil.isNotEmpty(tablepar.getOrderByColumn())) { - testExample.setOrderByClause(StringUtils.toUnderScoreCase(tablepar.getOrderByColumn()) +" "+tablepar.getIsAsc()); - } - - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysPositionMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - public int deleteByPrimaryKey(String ids) { - - List lista=Convert.toListStrArray(ids); - SysPositionExample example=new SysPositionExample(); - example.createCriteria().andIdIn(lista); - return sysPositionMapper.deleteByExample(example); - - - } - - - @Override - public SysPosition selectByPrimaryKey(String id) { - - return sysPositionMapper.selectByPrimaryKey(id); - - } - - - @Override - public int updateByPrimaryKeySelective(SysPosition record) { - return sysPositionMapper.updateByPrimaryKeySelective(record); - } - - - /** - * 添加 - */ - @Override - public int insertSelective(SysPosition record) { - - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - - - return sysPositionMapper.insertSelective(record); - } - - - @Override - public int updateByExampleSelective(SysPosition record, SysPositionExample example) { - - return sysPositionMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(SysPosition record, SysPositionExample example) { - - return sysPositionMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysPositionExample example) { - - return sysPositionMapper.selectByExample(example); - } - - - @Override - public long countByExample(SysPositionExample example) { - - return sysPositionMapper.countByExample(example); - } - - - @Override - public int deleteByExample(SysPositionExample example) { - - return sysPositionMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysPosition - * @return - */ - public int checkNameUnique(SysPosition sysPosition){ - SysPositionExample example=new SysPositionExample(); - example.createCriteria().andPostNameEqualTo(sysPosition.getPostName()); - List list=sysPositionMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/SysProvinceService.java b/src/main/java/com/fc/test/service/SysProvinceService.java deleted file mode 100644 index 1bd4fa28d9c4021e88ba2b7424a4502cc2c331ad..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysProvinceService.java +++ /dev/null @@ -1,126 +0,0 @@ -package com.fc.test.service; - -import java.util.Arrays; -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysProvinceMapper; -import com.fc.test.model.auto.SysProvince; -import com.fc.test.model.auto.SysProvinceExample; -import com.fc.test.model.custom.Tablepar; - -/** - * 省份表 SysProvinceService - * @Title: SysProvinceService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-10-04 19:56:15   - **/ -@Service -public class SysProvinceService{ - @Autowired - private SysProvinceMapper sysProvinceMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysProvinceExample testExample=new SysProvinceExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andProvinceNameLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysProvinceMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - - public int deleteByPrimaryKey(String ids) { - Integer[] integers = Convert.toIntArray(",", ids); - List stringB = Arrays.asList(integers); - SysProvinceExample example=new SysProvinceExample(); - example.createCriteria().andIdIn(stringB); - return sysProvinceMapper.deleteByExample(example); - } - - - - public SysProvince selectByPrimaryKey(Integer id) { - - return sysProvinceMapper.selectByPrimaryKey(id); - } - - - - public int updateByPrimaryKeySelective(SysProvince record) { - return sysProvinceMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - public int insertSelective(SysProvince record) { - //添加主键id - record.setId(null); - return sysProvinceMapper.insertSelective(record); - } - - - - public int updateByExampleSelective(SysProvince record, SysProvinceExample example) { - - return sysProvinceMapper.updateByExampleSelective(record, example); - } - - - - public int updateByExample(SysProvince record, SysProvinceExample example) { - - return sysProvinceMapper.updateByExample(record, example); - } - - - public List selectByExample(SysProvinceExample example) { - - return sysProvinceMapper.selectByExample(example); - } - - - - public long countByExample(SysProvinceExample example) { - - return sysProvinceMapper.countByExample(example); - } - - - - public int deleteByExample(SysProvinceExample example) { - - return sysProvinceMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysProvince - * @return - */ - public int checkNameUnique(SysProvince sysProvince){ - SysProvinceExample example=new SysProvinceExample(); - example.createCriteria().andProvinceNameEqualTo(sysProvince.getProvinceName()); - List list=sysProvinceMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/SysQuartzJobLogService.java b/src/main/java/com/fc/test/service/SysQuartzJobLogService.java deleted file mode 100644 index cc07bcbdb01b6ac98ce857d9470a6fea0bbe2a7e..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysQuartzJobLogService.java +++ /dev/null @@ -1,127 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysQuartzJobLogMapper; -import com.fc.test.model.auto.SysQuartzJobLog; -import com.fc.test.model.auto.SysQuartzJobLogExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 定时任务调度日志表 SysQuartzJobLogService - * @Title: SysQuartzJobLogService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:42   - **/ -@Service -public class SysQuartzJobLogService implements BaseService{ - @Autowired - private SysQuartzJobLogMapper sysQuartzJobLogMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysQuartzJobLogExample testExample=new SysQuartzJobLogExample(); - testExample.setOrderByClause("id DESC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andJobNameLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysQuartzJobLogMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - SysQuartzJobLogExample example=new SysQuartzJobLogExample(); - example.createCriteria().andIdIn(lista); - return sysQuartzJobLogMapper.deleteByExample(example); - } - - - @Override - public SysQuartzJobLog selectByPrimaryKey(String id) { - - return sysQuartzJobLogMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(SysQuartzJobLog record) { - return sysQuartzJobLogMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - @Override - public int insertSelective(SysQuartzJobLog record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - return sysQuartzJobLogMapper.insertSelective(record); - } - - - @Override - public int updateByExampleSelective(SysQuartzJobLog record, SysQuartzJobLogExample example) { - - return sysQuartzJobLogMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(SysQuartzJobLog record, SysQuartzJobLogExample example) { - - return sysQuartzJobLogMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysQuartzJobLogExample example) { - - return sysQuartzJobLogMapper.selectByExample(example); - } - - - @Override - public long countByExample(SysQuartzJobLogExample example) { - - return sysQuartzJobLogMapper.countByExample(example); - } - - - @Override - public int deleteByExample(SysQuartzJobLogExample example) { - - return sysQuartzJobLogMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysQuartzJobLog - * @return - */ - public int checkNameUnique(SysQuartzJobLog sysQuartzJobLog){ - SysQuartzJobLogExample example=new SysQuartzJobLogExample(); - example.createCriteria().andJobNameEqualTo(sysQuartzJobLog.getJobName()); - List list=sysQuartzJobLogMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/SysQuartzJobService.java b/src/main/java/com/fc/test/service/SysQuartzJobService.java deleted file mode 100644 index b0b24028d1968b0924714cf6eaba69ab50b62c5c..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysQuartzJobService.java +++ /dev/null @@ -1,204 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import org.quartz.SchedulerException; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.quartz.QuartzSchedulerUtil; -import com.fc.test.common.quartz.ScheduleConstants; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysQuartzJobMapper; -import com.fc.test.model.auto.SysQuartzJob; -import com.fc.test.model.auto.SysQuartzJobExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 定时任务调度表 SysQuartzJobService - * @Title: SysQuartzJobService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-09-13 00:03:35   - **/ -@Service -public class SysQuartzJobService implements BaseService{ - @Autowired - private SysQuartzJobMapper sysQuartzJobMapper; - @Autowired - private QuartzSchedulerUtil scheduler; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysQuartzJobExample testExample=new SysQuartzJobExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andJobNameLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysQuartzJobMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - SysQuartzJobExample example=new SysQuartzJobExample(); - example.createCriteria().andIdIn(lista); - return sysQuartzJobMapper.deleteByExample(example); - } - - - @Override - public SysQuartzJob selectByPrimaryKey(String id) { - - return sysQuartzJobMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(SysQuartzJob record) { - return sysQuartzJobMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - @Override - public int insertSelective(SysQuartzJob record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - return sysQuartzJobMapper.insertSelective(record); - } - - - @Override - public int updateByExampleSelective(SysQuartzJob record, SysQuartzJobExample example) { - - return sysQuartzJobMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(SysQuartzJob record, SysQuartzJobExample example) { - - return sysQuartzJobMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysQuartzJobExample example) { - - return sysQuartzJobMapper.selectByExample(example); - } - - - @Override - public long countByExample(SysQuartzJobExample example) { - - return sysQuartzJobMapper.countByExample(example); - } - - - @Override - public int deleteByExample(SysQuartzJobExample example) { - - return sysQuartzJobMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysQuartzJob - * @return - */ - public int checkNameUnique(SysQuartzJob sysQuartzJob){ - SysQuartzJobExample example=new SysQuartzJobExample(); - example.createCriteria().andJobNameEqualTo(sysQuartzJob.getJobName()); - List list=sysQuartzJobMapper.selectByExample(example); - return list.size(); - } - - - /** - * 恢复任务 - * - * @param job 调度信息 - */ - @Transactional - public int resumeJob(SysQuartzJob job) throws SchedulerException - { - job.setStatus(ScheduleConstants.Status.NORMAL.getValue()); - int rows = sysQuartzJobMapper.updateByPrimaryKeySelective(job); - if (rows > 0) - { - scheduler.resumeJob(job); - } - return rows; - } - - - /** - * 暂停任务 - * - * @param job 调度信息 - */ - @Transactional - public int pauseJob(SysQuartzJob job) throws SchedulerException - { - job.setStatus(ScheduleConstants.Status.PAUSE.getValue()); - //job.setUpdateBy(ShiroUtils.getLoginName()); - int rows = sysQuartzJobMapper.updateByPrimaryKeySelective(job); - if (rows > 0) - { - scheduler.pauseJob(job); - } - return rows; - } - - /** - * 任务调度状态修改 - * - * @param job 调度信息 - */ - @Transactional - public int changeStatus(SysQuartzJob job) throws SchedulerException - { - int rows = 0; - Integer status = job.getStatus(); - if (ScheduleConstants.Status.NORMAL.getValue().equals(status)) - { - rows = resumeJob(job); - } - else if (ScheduleConstants.Status.PAUSE.getValue().equals(status)) - { - rows = pauseJob(job); - } - return rows; - } - - - /** - * 立即运行任务 - * - * @param job 调度信息 - */ - @Transactional - public void run(SysQuartzJob job) throws SchedulerException - { - - scheduler.run(job); - - } - - -} diff --git a/src/main/java/com/fc/test/service/SysRoleService.java b/src/main/java/com/fc/test/service/SysRoleService.java deleted file mode 100644 index 350f558b0342f7f92ddc67c2429c5cbeee45df9b..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysRoleService.java +++ /dev/null @@ -1,201 +0,0 @@ -package com.fc.test.service; - -import java.util.List; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; -import cn.hutool.core.util.RandomUtil; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TsysPermissionRoleMapper; -import com.fc.test.mapper.auto.TsysRoleMapper; -import com.fc.test.mapper.custom.RoleDao; -import com.fc.test.model.auto.TsysPermissionRole; -import com.fc.test.model.auto.TsysPermissionRoleExample; -import com.fc.test.model.auto.TsysRole; -import com.fc.test.model.auto.TsysRoleExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.SnowflakeIdWorker; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; - -@Service -public class SysRoleService implements BaseService { - //角色mapper - @Autowired - private TsysRoleMapper tsysRoleMapper; - //自定义角色dao - @Autowired - private RoleDao roleDao; - //自动生成的权限角色映射mapper - @Autowired - private TsysPermissionRoleMapper tsysPermissionRoleMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String searchText){ - TsysRoleExample testExample=new TsysRoleExample(); - testExample.setOrderByClause("id+0 DESC"); - if(searchText!=null&&!"".equals(searchText)){ - testExample.createCriteria().andNameLike("%"+searchText+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tsysRoleMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - /** - * 查询全部角色集合 - * @return - */ - public List queryList(){ - TsysRoleExample tsysRoleExample=new TsysRoleExample(); - return tsysRoleMapper.selectByExample(tsysRoleExample); - } - - - /** - * - */ - @Override - @Transactional - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - //先删除角色下面的所有权限 - TsysPermissionRoleExample permissionRoleExample=new TsysPermissionRoleExample(); - permissionRoleExample.createCriteria().andRoleIdIn(lista); - tsysPermissionRoleMapper.deleteByExample(permissionRoleExample); - //在删除角色 - TsysRoleExample example=new TsysRoleExample(); - example.createCriteria().andIdIn(lista); - return tsysRoleMapper.deleteByExample(example); - } - - - - @Override - public int insertSelective(TsysRole record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - return tsysRoleMapper.insertSelective(record); - } - - /** - * 添加角色绑定权限 - * @param record 角色信息 - * @param prem 权限id集合 - * @return - */ - @Transactional - public int insertRoleAndPrem(TsysRole record,String prem) { - //添加雪花主键id - String roleid=SnowflakeIdWorker.getUUID(); - record.setId(roleid); - //添加权限 - List prems=Convert.toListStrArray(prem); - for (String premid : prems) { - TsysPermissionRole tsysPermissionRole=new TsysPermissionRole(RandomUtil.randomUUID() , roleid, premid); - tsysPermissionRoleMapper.insertSelective(tsysPermissionRole); - } - return tsysRoleMapper.insertSelective(record); - } - - @Override - public TsysRole selectByPrimaryKey(String id) { - - return tsysRoleMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TsysRole record) { - return tsysRoleMapper.updateByPrimaryKeySelective(record); - } - - /** - * 修改用户角色 以及下面绑定的权限 - * @param record - * @return - */ - @Transactional - public int updateRoleAndPrem(TsysRole record,String prem) { - //先删除角色下面的所有权限 - TsysPermissionRoleExample permissionRoleExample=new TsysPermissionRoleExample(); - permissionRoleExample.createCriteria().andRoleIdEqualTo(record.getId()); - tsysPermissionRoleMapper.deleteByExample(permissionRoleExample); - //添加权限关联 - List prems=Convert.toListStrArray(prem); - for (String pre : prems) { - TsysPermissionRole permissionRole=new TsysPermissionRole(RandomUtil.randomUUID(), record.getId(), pre); - tsysPermissionRoleMapper.insertSelective(permissionRole); - } - - return tsysRoleMapper.updateByPrimaryKeySelective(record); - } - - - - @Override - public int updateByExampleSelective(TsysRole record, TsysRoleExample example) { - - return tsysRoleMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TsysRole record, TsysRoleExample example) { - - return tsysRoleMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TsysRoleExample example) { - - return tsysRoleMapper.selectByExample(example); - } - - - @Override - public long countByExample(TsysRoleExample example) { - - return tsysRoleMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TsysRoleExample example) { - - return tsysRoleMapper.deleteByExample(example); - } - - /** - * 检查角色name - * @param tsysUser - * @return - */ - public int checkNameUnique(TsysRole tsysRole){ - TsysRoleExample example=new TsysRoleExample(); - example.createCriteria().andNameEqualTo(tsysRole.getName()); - List list=tsysRoleMapper.selectByExample(example); - return list.size(); - } - - - /** - * 根据用户id查询角色 - * @param userid - * @return - */ - public List queryUserRole(String userid){ - return roleDao.queryUserRole(userid); - } - -} diff --git a/src/main/java/com/fc/test/service/SysStreetService.java b/src/main/java/com/fc/test/service/SysStreetService.java deleted file mode 100644 index 437b3f17c3d90f44be6e89713f8b5cf909311922..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysStreetService.java +++ /dev/null @@ -1,134 +0,0 @@ -package com.fc.test.service; - -import java.util.List; -import java.util.Arrays; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.SysStreetMapper; -import com.fc.test.model.auto.SysStreet; -import com.fc.test.model.auto.SysStreetExample; -import com.fc.test.model.custom.Tablepar; - -/** - * 街道设置 SysStreetService - * @Title: SysStreetService.java  - * @Package com.fc.test.service  - * @author fuce_自动生成 - * @email 115889198@qq.com - * @date 2019-10-05 01:02:28   - **/ -@Service -public class SysStreetService implements BaseService{ - @Autowired - private SysStreetMapper sysStreetMapper; - - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - SysStreetExample testExample=new SysStreetExample(); - testExample.setOrderByClause("id ASC"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andStreetNameLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= sysStreetMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - public int deleteByPrimaryKey(String ids) { - - Integer[] integers = Convert.toIntArray(",", ids); - List stringB = Arrays.asList(integers); - SysStreetExample example=new SysStreetExample(); - example.createCriteria().andIdIn(stringB); - return sysStreetMapper.deleteByExample(example); - - - } - - - @Override - public SysStreet selectByPrimaryKey(String id) { - - Integer id1 = Integer.valueOf(id); - return sysStreetMapper.selectByPrimaryKey(id1); - - } - - - @Override - public int updateByPrimaryKeySelective(SysStreet record) { - return sysStreetMapper.updateByPrimaryKeySelective(record); - } - - - /** - * 添加 - */ - @Override - public int insertSelective(SysStreet record) { - record.setId(null); - - return sysStreetMapper.insertSelective(record); - } - - - @Override - public int updateByExampleSelective(SysStreet record, SysStreetExample example) { - - return sysStreetMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(SysStreet record, SysStreetExample example) { - - return sysStreetMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(SysStreetExample example) { - - return sysStreetMapper.selectByExample(example); - } - - - @Override - public long countByExample(SysStreetExample example) { - - return sysStreetMapper.countByExample(example); - } - - - @Override - public int deleteByExample(SysStreetExample example) { - - return sysStreetMapper.deleteByExample(example); - } - - /** - * 检查name - * @param sysStreet - * @return - */ - public int checkNameUnique(SysStreet sysStreet){ - SysStreetExample example=new SysStreetExample(); - example.createCriteria().andStreetNameEqualTo(sysStreet.getStreetName()); - List list=sysStreetMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/SysUserService.java b/src/main/java/com/fc/test/service/SysUserService.java deleted file mode 100644 index 84bab2a47ab7a6df4a2c33b4661fccdd49f93525..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/SysUserService.java +++ /dev/null @@ -1,246 +0,0 @@ -package com.fc.test.service; - -import java.util.ArrayList; -import java.util.List; - -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; - -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TSysRoleUserMapper; -import com.fc.test.mapper.auto.TsysRoleMapper; -import com.fc.test.mapper.auto.TsysUserMapper; -import com.fc.test.mapper.custom.RoleDao; -import com.fc.test.model.auto.TSysRoleUser; -import com.fc.test.model.auto.TSysRoleUserExample; -import com.fc.test.model.auto.TsysRole; -import com.fc.test.model.auto.TsysRoleExample; -import com.fc.test.model.auto.TsysUser; -import com.fc.test.model.auto.TsysUserExample; -import com.fc.test.model.custom.RoleVo; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.util.MD5Util; -import com.fc.test.util.SnowflakeIdWorker; -import com.fc.test.util.StringUtils; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; - -/** - * 系统用户 - * @ClassName: SysUserService - * @author fuce - * @date 2018年8月26日 - * - */ -@Service -public class SysUserService implements BaseService{ - //生成的用户dao - @Autowired - private TsysUserMapper tsysUserMapper; - - //生成的角色用户dao - @Autowired - private TSysRoleUserMapper tSysRoleUserMapper; - - //自定义角色dao - @Autowired - private RoleDao roleDao; - - //自动生成的角色dao - @Autowired - private TsysRoleMapper tsysRoleMapper; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String username){ - TsysUserExample testExample=new TsysUserExample(); - testExample.setOrderByClause("id+0 DESC"); - if(username!=null&&!"".equals(username)){ - testExample.createCriteria().andUsernameLike("%"+username+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tsysUserMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - TsysUserExample example=new TsysUserExample(); - example.createCriteria().andIdIn(lista); - return tsysUserMapper.deleteByExample(example); - } - - /** - * 添加用户 - */ - @Override - public int insertSelective(TsysUser record) { - return tsysUserMapper.insertSelective(record); - } - - /** - * 添加用户跟角色信息 - * @param record - * @param roles - * @return - */ - @Transactional - public int insertUserRoles(TsysUser record,List roles) { - String userid=SnowflakeIdWorker.getUUID(); - record.setId(userid); - if(StringUtils.isNotEmpty(roles)){ - for (String rolesid : roles) { - TSysRoleUser roleUser=new TSysRoleUser(SnowflakeIdWorker.getUUID(), userid,rolesid); - tSysRoleUserMapper.insertSelective(roleUser); - } - } - - //密码加密 - record.setPassword(MD5Util.encode(record.getPassword())); - return tsysUserMapper.insertSelective(record); - } - - @Override - public TsysUser selectByPrimaryKey(String id) { - - return tsysUserMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TsysUser record) { - record.setPassword(MD5Util.encode(record.getPassword())); - return tsysUserMapper.updateByPrimaryKeySelective(record); - } - - - - - - @Override - public int updateByExampleSelective(TsysUser record, TsysUserExample example) { - - return tsysUserMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TsysUser record, TsysUserExample example) { - - return tsysUserMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TsysUserExample example) { - - return tsysUserMapper.selectByExample(example); - } - - - @Override - public long countByExample(TsysUserExample example) { - - return tsysUserMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TsysUserExample example) { - - return tsysUserMapper.deleteByExample(example); - } - - /** - * 检查用户name - * @param tsysUser - * @return - */ - public int checkLoginNameUnique(TsysUser tsysUser){ - TsysUserExample example=new TsysUserExample(); - example.createCriteria().andUsernameEqualTo(tsysUser.getUsername()); - List list=tsysUserMapper.selectByExample(example); - - return list.size(); - } - - /** - * 获取所有权限 并且增加是否有权限字段 - * @return - */ - public List getUserIsRole(String userid){ - List list=new ArrayList(); - //查询出我的权限 - List myRoles= roleDao.queryUserRole(userid); - TsysRoleExample tsysRoleExample=new TsysRoleExample(); - //查询系统所有的角色 - List tsysRoles=tsysRoleMapper.selectByExample(tsysRoleExample); - if(StringUtils.isNotEmpty(tsysRoles)){ - for (TsysRole tsysRole : tsysRoles) { - Boolean isflag=false; - RoleVo roleVo=new RoleVo(tsysRole.getId(),tsysRole.getName(), isflag); - for (TsysRole myRole : myRoles) { - if(tsysRole.getId().equals(myRole.getId())){ - isflag=true; - break; - } - } - if(isflag){ - roleVo.setIscheck(true); - list.add(roleVo); - }else{ - list.add(roleVo); - } - } - } - return list; - } - - - /** - * 修改用户密码 - * @param record - * @return - */ - public int updateUserPassword(TsysUser record) { - record.setPassword(MD5Util.encode(record.getPassword())); - //修改用户信息 - return tsysUserMapper.updateByPrimaryKeySelective(record); - } - - - /** - * 修改用户信息以及角色信息 - * @param record - * @param roles - * @return - */ - @Transactional - public int updateUserRoles(TsysUser record,List roles) { - //先删除这个用户的所有角色 - TSysRoleUserExample tSysRoleUserExample=new TSysRoleUserExample(); - tSysRoleUserExample.createCriteria().andSysUserIdEqualTo(record.getId()); - tSysRoleUserMapper.deleteByExample(tSysRoleUserExample); - if(roles!=null) { - //添加新的角色信息 - for (String role : roles) { - TSysRoleUser tSysRoleUser= new TSysRoleUser(SnowflakeIdWorker.getUUID(), record.getId(), role); - tSysRoleUserMapper.insertSelective(tSysRoleUser); - } - } - //修改用户信息 - return 1; - } - - - -} diff --git a/src/main/java/com/fc/test/service/TSysEmailService.java b/src/main/java/com/fc/test/service/TSysEmailService.java deleted file mode 100644 index f95e0dc385a0e0c4ca5659a38da4e04ebd5e63ef..0000000000000000000000000000000000000000 --- a/src/main/java/com/fc/test/service/TSysEmailService.java +++ /dev/null @@ -1,139 +0,0 @@ -package com.fc.test.service; - -import java.util.Date; -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.github.pagehelper.PageHelper; -import com.github.pagehelper.PageInfo; -import com.fc.test.common.base.BaseService; -import com.fc.test.common.support.Convert; -import com.fc.test.mapper.auto.TSysEmailMapper; -import com.fc.test.model.auto.TSysEmail; -import com.fc.test.model.auto.TSysEmailExample; -import com.fc.test.model.custom.Tablepar; -import com.fc.test.shiro.util.ShiroUtils; -import com.fc.test.util.SnowflakeIdWorker; - -/** - * 电子邮件Service -* @Title: TSysEmailService.java  -* @Package com.fc.test.service  -* @author fuce -* @email 87766867@qq.com -* @date 2019-06-30 00:49:49   - */ -@Service -public class TSysEmailService implements BaseService{ - @Autowired - private TSysEmailMapper tSysEmailMapper; - - /** - * 分页查询 - * @param pageNum - * @param pageSize - * @return - */ - public PageInfo list(Tablepar tablepar,String name){ - TSysEmailExample testExample=new TSysEmailExample(); - testExample.setOrderByClause("id desc"); - if(name!=null&&!"".equals(name)){ - testExample.createCriteria().andContentLike("%"+name+"%"); - } - - PageHelper.startPage(tablepar.getPageNum(), tablepar.getPageSize()); - List list= tSysEmailMapper.selectByExample(testExample); - PageInfo pageInfo = new PageInfo(list); - return pageInfo; - } - - @Override - public int deleteByPrimaryKey(String ids) { - List lista=Convert.toListStrArray(ids); - TSysEmailExample example=new TSysEmailExample(); - example.createCriteria().andIdIn(lista); - return tSysEmailMapper.deleteByExample(example); - } - - - @Override - public TSysEmail selectByPrimaryKey(String id) { - - return tSysEmailMapper.selectByPrimaryKey(id); - } - - - @Override - public int updateByPrimaryKeySelective(TSysEmail record) { - return tSysEmailMapper.updateByPrimaryKeySelective(record); - } - - /** - * 添加 - */ - @Override - public int insertSelective(TSysEmail record) { - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - record.setSendUserId(ShiroUtils.getUserId()); - record.setSendUserName(ShiroUtils.getLoginName()); - record.setCreateTime(new Date()); - return tSysEmailMapper.insertSelective(record); - } - - - - - - - - - - - @Override - public int updateByExampleSelective(TSysEmail record, TSysEmailExample example) { - - return tSysEmailMapper.updateByExampleSelective(record, example); - } - - - @Override - public int updateByExample(TSysEmail record, TSysEmailExample example) { - - return tSysEmailMapper.updateByExample(record, example); - } - - @Override - public List selectByExample(TSysEmailExample example) { - - return tSysEmailMapper.selectByExample(example); - } - - - @Override - public long countByExample(TSysEmailExample example) { - - return tSysEmailMapper.countByExample(example); - } - - - @Override - public int deleteByExample(TSysEmailExample example) { - - return tSysEmailMapper.deleteByExample(example); - } - - /** - * 检查name - * @param TSysEmail - * @return - */ - public int checkNameUnique(TSysEmail tSysEmail){ - TSysEmailExample example=new TSysEmailExample(); - example.createCriteria().andContentEqualTo(tSysEmail.getContent()); - List list=tSysEmailMapper.selectByExample(example); - return list.size(); - } - - -} diff --git a/src/main/java/com/fc/test/service/UeditorService.java b/src/main/java/com/fc/test/service/UeditorService.java index e9fd82a14a245321b90b1586b9391ec4a3382941..9b5c9e8aba65eebf32d5cde5e80b02e89ac2d607 100644 --- a/src/main/java/com/fc/test/service/UeditorService.java +++ b/src/main/java/com/fc/test/service/UeditorService.java @@ -1,98 +1,102 @@ package com.fc.test.service; -import java.io.IOException; -import java.util.Date; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; -import org.springframework.web.multipart.MultipartFile; import com.fc.test.common.conf.V2Config; import com.fc.test.common.file.FileUploadUtils; -import com.fc.test.mapper.auto.TsysDatasMapper; -import com.fc.test.mapper.auto.TsysFileDataMapper; -import com.fc.test.mapper.auto.TsysFileMapper; -import com.fc.test.model.auto.TsysDatas; -import com.fc.test.model.auto.TsysFile; -import com.fc.test.model.auto.TsysFileData; +import com.fc.test.dao.model.SysDatasModel; +import com.fc.test.dao.model.SysFileDataModel; +import com.fc.test.dao.model.SysFileModel; +import com.fc.test.dao.service.SysDatasService; +import com.fc.test.dao.service.SysFileDataService; +import com.fc.test.dao.service.SysFileService; import com.fc.test.shiro.util.ShiroUtils; import com.fc.test.util.SnowflakeIdWorker; +import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.web.multipart.MultipartFile; + +import java.io.IOException; +import java.util.Date; /** * 百度文件上传service - * @ClassName: UeditorService - * @author: fc - * @date: 2019年6月30日 下午5:51:43 * + * @ClassName: UeditorService + * @author: fc + * @date: 2019年6月30日 下午5:51:43 */ +@RequiredArgsConstructor(onConstructor = @__(@Autowired)) @Service public class UeditorService { - @Autowired - private TsysFileDataMapper tsysFileDataMapper; - - //文件存储mapper - @Autowired - private TsysDatasMapper tsysDatasMapper; - //文件信息mapper - @Autowired - private TsysFileMapper tsysFileMapper; + /** + * 文件存储 + */ + private final SysFileDataService sysFileDataService; + /** + * 文件存储服务 + */ + private final SysDatasService sysDatasService; + /** + * 文件信息 + */ + private final SysFileService sysFileService; + - /** - * 文件上传文件存储到文件表 - * @param record - * @param fileURL - * @return TsysDatas - * @throws IOException - */ - public TsysDatas fileDataByinsert(MultipartFile file) throws IOException { - //文件上传获取文件名字 + * 文件上传文件存储到文件表 + * + * @return TsysDatas + * @throws IOException + */ + public SysDatasModel fileDataByinsert(MultipartFile file) throws IOException { + //文件上传获取文件名字 String files = FileUploadUtils.upload(file); //补充完整url地址 - String filesURL=""; + String filesURL = ""; if ("Y".equals(V2Config.getIsstatic())) { - filesURL=V2Config.getIsroot_dir()+files; - }else { - filesURL=V2Config.getProfile()+files; - } - - - TsysDatas record=new TsysDatas(); - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - record.setFilePath(filesURL); - if(tsysDatasMapper.insertSelective(record)>0) - { - return record; - } - return null; - } - - + filesURL = V2Config.getIsroot_dir() + files; + } else { + filesURL = V2Config.getProfile() + files; + } + + + SysDatasModel record = new SysDatasModel(); + //添加雪花主键id + record.setId(SnowflakeIdWorker.getUUID()); + record.setFilePath(filesURL); + if (sysDatasService.save(record)) { + return record; + } + return null; + } + + /** * 添加文件信息 */ @Transactional - public TsysFileData fileInfoByininsert(String dataId) { - TsysFile record=new TsysFile(); - record.setFileName("百度富文本上传"); - //插入创建人id - record.setCreateUserId(ShiroUtils.getUserId()); - //插入创建人name - record.setCreateUserName(ShiroUtils.getLoginName()); - //插入创建时间 - record.setCreateTime(new Date()); - //添加雪花主键id - record.setId(SnowflakeIdWorker.getUUID()); - //插入关联表 - TsysFileData tsysFileData=new TsysFileData(); - tsysFileData.setId(SnowflakeIdWorker.getUUID()); - tsysFileData.setFileId(record.getId()); - tsysFileData.setDataId(dataId); - tsysFileDataMapper.insert(tsysFileData); - int i= tsysFileMapper.insertSelective(record); - if(i>0) { - return tsysFileData; - } - return null; - } + public SysFileDataModel fileInfoByininsert(String dataId) { + SysFileModel record = new SysFileModel(); + record.setFileName("百度富文本上传"); + //插入创建人id + record.setCreateUserId(ShiroUtils.getUserId()); + //插入创建人name + record.setCreateUserName(ShiroUtils.getLoginName()); + //插入创建时间 + record.setCreateTime(new Date()); + //添加雪花主键id + record.setId(SnowflakeIdWorker.getUUID()); + //插入关联表 + SysFileDataModel tsysFileData = new SysFileDataModel(); + tsysFileData.setId(SnowflakeIdWorker.getUUID()); + tsysFileData.setFileId(record.getId()); + tsysFileData.setDataId(dataId); + sysFileDataService.save(tsysFileData); + if (sysFileService.save(record)) { + return tsysFileData; + } else { + return null; + } + } } diff --git a/src/main/java/com/fc/test/shiro/config/ShiroConfig.java b/src/main/java/com/fc/test/shiro/config/ShiroConfig.java index 10ed1f928cbace93ce530b60f3dd735ed38a99f1..765dc390cf9eac52987ee4d9482e5f4324b0705f 100644 --- a/src/main/java/com/fc/test/shiro/config/ShiroConfig.java +++ b/src/main/java/com/fc/test/shiro/config/ShiroConfig.java @@ -1,5 +1,7 @@ package com.fc.test.shiro.config; +import at.pollux.thymeleaf.shiro.dialect.ShiroDialect; +import com.fc.test.shiro.service.MyShiroRealm; import org.apache.shiro.authc.credential.HashedCredentialsMatcher; import org.apache.shiro.cache.CacheManager; import org.apache.shiro.cache.MemoryConstrainedCacheManager; @@ -15,8 +17,6 @@ import org.apache.shiro.web.servlet.SimpleCookie; import org.apache.shiro.web.session.mgt.DefaultWebSessionManager; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; -import com.fc.test.shiro.service.MyShiroRealm; -import at.pollux.thymeleaf.shiro.dialect.ShiroDialect; /** @@ -49,7 +49,7 @@ public class ShiroConfig { shiroFilterFactoryBean.setSecurityManager(securityManager); return shiroFilterFactoryBean; } - + /** * web应用管理配置 * @param shiroRealm @@ -91,7 +91,7 @@ public class ShiroConfig { hashedCredentialsMatcher.setHashIterations(1);//加密次数 return hashedCredentialsMatcher; } - + /** * 记住我的配置 * @return @@ -114,7 +114,7 @@ public class ShiroConfig { MemoryConstrainedCacheManager cacheManager=new MemoryConstrainedCacheManager();//使用内存缓存 return cacheManager; } - + /** * 配置realm,用于认证和授权 * @param hashedCredentialsMatcher @@ -127,7 +127,7 @@ public class ShiroConfig { shiroRealm.setCredentialsMatcher(hashedCredentialsMatcher); return shiroRealm; } - + /** * 启用shiro方言,这样能在页面上使用shiro标签 * @return @@ -136,7 +136,7 @@ public class ShiroConfig { public ShiroDialect shiroDialect() { return new ShiroDialect(); } - + /** * 启用shiro注解 *加入注解的使用,不加入这个注解不生效 @@ -147,6 +147,6 @@ public class ShiroConfig { advisor.setSecurityManager(securityManager); return advisor; } - + } diff --git a/src/main/java/com/fc/test/shiro/service/MyShiroRealm.java b/src/main/java/com/fc/test/shiro/service/MyShiroRealm.java index e73e60a0ff94ad72d036a723aa8108acf8670303..81e52387e33a6b9fa07fab0daf8bcac53d465c6d 100644 --- a/src/main/java/com/fc/test/shiro/service/MyShiroRealm.java +++ b/src/main/java/com/fc/test/shiro/service/MyShiroRealm.java @@ -1,12 +1,11 @@ package com.fc.test.shiro.service; -import java.util.List; -import com.fc.test.mapper.custom.PermissionDao; -import com.fc.test.mapper.custom.RoleDao; -import com.fc.test.mapper.custom.TsysUserDao; -import com.fc.test.model.auto.TsysPermission; -import com.fc.test.model.auto.TsysRole; -import com.fc.test.model.auto.TsysUser; +import com.fc.test.dao.model.SysPermissionModel; +import com.fc.test.dao.model.SysRoleModel; +import com.fc.test.dao.model.SysUserModel; +import com.fc.test.dao.service.SysPermissionService; +import com.fc.test.dao.service.SysRoleService; +import com.fc.test.dao.service.SysUserService; import com.fc.test.util.StringUtils; import org.apache.shiro.SecurityUtils; import org.apache.shiro.authc.AuthenticationException; @@ -21,94 +20,96 @@ import org.apache.shiro.subject.PrincipalCollection; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import java.util.List; + /** * 身份校验核心类 - * - * @ClassName: MyShiroRealm + * * @author fuce + * @ClassName: MyShiroRealm * @date 2018年8月25日 - * */ -@Service public class MyShiroRealm extends AuthorizingRealm { - - @Autowired - private TsysUserDao tsysUserDao; - - @Autowired - private PermissionDao permissionDao;//权限dao - - @Autowired - private RoleDao roleDao ;//角色dao - - - /** - * 认证登陆 - */ - @SuppressWarnings("unused") - @Override - protected AuthenticationInfo doGetAuthenticationInfo( - AuthenticationToken token) throws AuthenticationException { - - //加这一步的目的是在Post请求的时候会先进认证,然后在到请求 + @Autowired + private SysUserService sysUserService; + /** + * 权限dao + */ + @Autowired + private SysPermissionService sysPermissionService; + /** + * 角色dao + */ + @Autowired + private SysRoleService roleDao; + + + /** + * 认证登陆 + */ + @SuppressWarnings("unused") + @Override + protected AuthenticationInfo doGetAuthenticationInfo( + AuthenticationToken token) throws AuthenticationException { + + //加这一步的目的是在Post请求的时候会先进认证,然后在到请求 if (token.getPrincipal() == null) { return null; } - String username = (String) token.getPrincipal(); - String password = new String((char[]) token.getCredentials()); - // 通过username从数据库中查找 User对象,如果找到,没找到. - // 实际项目中,这里可以根据实际情况做缓存,如果不做,Shiro自己也是有时间间隔机制,2分钟内不会重复执行该方法 - TsysUser userInfo = tsysUserDao.queryUserName(username); + String username = (String) token.getPrincipal(); + String password = new String((char[]) token.getCredentials()); + // 通过username从数据库中查找 User对象,如果找到,没找到. + // 实际项目中,这里可以根据实际情况做缓存,如果不做,Shiro自己也是有时间间隔机制,2分钟内不会重复执行该方法 + SysUserModel userInfo = sysUserService.queryUserName(username); // System.out.println(userInfo); // System.out.println("----->>userInfo=" + userInfo.getUsername() + "---"+ userInfo.getPassword()); - if (userInfo == null) - return null; - else{ - SimpleAuthenticationInfo authenticationInfo = new SimpleAuthenticationInfo( - userInfo, // 用户对象 - userInfo.getPassword(), // 密码 - getName() // realm name - ); - return authenticationInfo; - } - - } - - /** + if (userInfo == null) + return null; + else { + SimpleAuthenticationInfo authenticationInfo = new SimpleAuthenticationInfo( + userInfo, // 用户对象 + userInfo.getPassword(), // 密码 + getName() // realm name + ); + return authenticationInfo; + } + + } + + /** * 授权查询回调函数, 进行鉴权但缓存中无用户的授权信息时调用. */ - @Override - protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principals) { - //System.out.println("权限配置-->MyShiroRealm.doGetAuthorizationInfo()"); - if(principals == null){ - throw new AuthorizationException("principals should not be null"); - } - SimpleAuthorizationInfo authorizationInfo = new SimpleAuthorizationInfo(); - TsysUser userinfo = (TsysUser)principals.getPrimaryPrincipal(); - String uid=userinfo.getId(); - List tsysRoles= roleDao.queryUserRole(uid); - for(TsysRole userrole:tsysRoles){ - //System.out.println("角色名字:"+gson.toJson(userrole)); - String rolid=userrole.getId();//角色id - authorizationInfo.addRole(userrole.getName());//添加角色名字 - List permissions=permissionDao.queryRoleId(rolid); - for(TsysPermission p:permissions){ - //System.out.println("角色下面的权限:"+gson.toJson(p)); - if(StringUtils.isNotEmpty(p.getPerms())){ - authorizationInfo.addStringPermission(p.getPerms()); - } - - } - } - - return authorizationInfo; - } - - /** + @Override + protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principals) { + //System.out.println("权限配置-->MyShiroRealm.doGetAuthorizationInfo()"); + if (principals == null) { + throw new AuthorizationException("principals should not be null"); + } + SimpleAuthorizationInfo authorizationInfo = new SimpleAuthorizationInfo(); + SysUserModel userinfo = (SysUserModel) principals.getPrimaryPrincipal(); + String uid = userinfo.getId(); + List tsysRoles = roleDao.queryUserRole(uid); + for (SysRoleModel userrole : tsysRoles) { + //System.out.println("角色名字:"+gson.toJson(userrole)); + String rolid = userrole.getId();//角色id + authorizationInfo.addRole(userrole.getName());//添加角色名字 + List permissions = sysPermissionService.queryRoleId(rolid); + for (SysPermissionModel p : permissions) { + //System.out.println("角色下面的权限:"+gson.toJson(p)); + if (StringUtils.isNotEmpty(p.getPerms())) { + authorizationInfo.addStringPermission(p.getPerms()); + } + + } + } + + return authorizationInfo; + } + + /** * 清理缓存权限 */ - public void clearCachedAuthorizationInfo() - { + public void clearCachedAuthorizationInfo() { this.clearCachedAuthorizationInfo(SecurityUtils.getSubject().getPrincipals()); } diff --git a/src/main/java/com/fc/test/shiro/util/ShiroUtils.java b/src/main/java/com/fc/test/shiro/util/ShiroUtils.java index 6ad80e4f2af77f884a47170536ff36f84e4f0efd..0c35682dcb9f15b70a7c4243b7982367ed65b1e3 100644 --- a/src/main/java/com/fc/test/shiro/util/ShiroUtils.java +++ b/src/main/java/com/fc/test/shiro/util/ShiroUtils.java @@ -1,84 +1,86 @@ package com.fc.test.shiro.util; +import com.fc.test.dao.model.SysUserModel; +import com.fc.test.shiro.service.MyShiroRealm; +import com.fc.test.util.BeanUtils; +import com.fc.test.util.StringUtils; import org.apache.shiro.SecurityUtils; import org.apache.shiro.mgt.RealmSecurityManager; import org.apache.shiro.session.Session; import org.apache.shiro.subject.PrincipalCollection; import org.apache.shiro.subject.SimplePrincipalCollection; import org.apache.shiro.subject.Subject; -import com.fc.test.model.auto.TsysUser; -import com.fc.test.shiro.service.MyShiroRealm; -import com.fc.test.util.BeanUtils; -import com.fc.test.util.StringUtils; + +import java.util.Optional; /** * shiro 工具类 - * + * * @author fuce */ public class ShiroUtils { - private ShiroUtils(){} - + private ShiroUtils() { + } + /** * 获取shiro subject + * * @return * @author fuce * @Date 2019年11月21日 上午10:00:55 */ - public static Subject getSubjct() - { + public static Subject getSubjct() { return SecurityUtils.getSubject(); } - + /** * 获取登录session + * * @return * @author fuce * @Date 2019年11月21日 上午10:00:41 */ - public static Session getSession() - { + public static Session getSession() { return SecurityUtils.getSubject().getSession(); } /** * 退出登录 + * * @author fuce * @Date 2019年11月21日 上午10:00:24 */ - public static void logout() - { + public static void logout() { getSubjct().logout(); } - + /** * 获取登录用户model + * * @return * @author fuce * @Date 2019年11月21日 上午10:00:10 */ - public static TsysUser getUser() - { - TsysUser user = null; + public static SysUserModel getUser() { + SysUserModel user = null; Object obj = getSubjct().getPrincipal(); - if (StringUtils.isNotNull(obj)) - { - user = new TsysUser(); + if (StringUtils.isNotNull(obj)) { + user = new SysUserModel(); BeanUtils.copyBeanProp(user, obj); } return user; } - + /** * set用户 + * * @param user * @author fuce * @Date 2019年11月21日 上午9:59:52 */ - public static void setUser(TsysUser user) - { + public static void setUser(SysUserModel user) { Subject subject = getSubjct(); PrincipalCollection principalCollection = subject.getPrincipals(); String realmName = principalCollection.getRealmNames().iterator().next(); @@ -86,68 +88,61 @@ public class ShiroUtils { // 重新加载Principal subject.runAs(newPrincipalCollection); } - + /** * 清除授权信息 + * * @author fuce * @Date 2019年11月21日 上午9:59:37 */ - public static void clearCachedAuthorizationInfo() - { + public static void clearCachedAuthorizationInfo() { RealmSecurityManager rsm = (RealmSecurityManager) SecurityUtils.getSecurityManager(); MyShiroRealm realm = (MyShiroRealm) rsm.getRealms().iterator().next(); realm.clearCachedAuthorizationInfo(); } - + /** * 获取登录用户id + * * @return * @author fuce * @Date 2019年11月21日 上午9:58:55 */ - public static String getUserId() - { - TsysUser tsysUser = getUser(); - if (tsysUser == null || tsysUser.getId() == null){ - throw new RuntimeException("用户不存在!"); - } - return tsysUser.getId().trim(); + public static String getUserId() { + SysUserModel sysUserModel = getUser(); + return Optional.ofNullable(sysUserModel).map(SysUserModel::getId).orElseThrow(() -> new RuntimeException("用户不存在")); } /** * 获取登录用户name + * * @return * @author fuce * @Date 2019年11月21日 上午9:58:48 */ - public static String getLoginName() - { - TsysUser tsysUser = getUser(); - if (tsysUser == null){ - throw new RuntimeException("用户不存在!"); - } - return tsysUser.getUsername(); + public static String getLoginName() { + return Optional.ofNullable(getUser()).map(SysUserModel::getUsername).orElseThrow(() -> new RuntimeException("用户不存在")); } - + /** * 获取登录用户ip + * * @return * @author fuce * @Date 2019年11月21日 上午9:58:26 */ - public static String getIp() - { + public static String getIp() { return getSubjct().getSession().getHost(); } - + /** * 获取登录用户sessionid + * * @return * @author fuce * @Date 2019年11月21日 上午9:58:37 */ - public static String getSessionId() - { + public static String getSessionId() { return String.valueOf(getSubjct().getSession().getId()); } } diff --git a/src/main/java/com/fc/test/util/SimpleEmailUtil.java b/src/main/java/com/fc/test/util/SimpleEmailUtil.java index bd2b9639eed3231b73e6515f5c1e2c3635295112..a1f4e70fd67aba6fc01a4ffba2e55948d15a1c4c 100644 --- a/src/main/java/com/fc/test/util/SimpleEmailUtil.java +++ b/src/main/java/com/fc/test/util/SimpleEmailUtil.java @@ -19,11 +19,12 @@ import javax.mail.internet.InternetAddress; import javax.mail.internet.MimeBodyPart; import javax.mail.internet.MimeMessage; import javax.mail.internet.MimeMultipart; + +import com.fc.test.dao.model.SysEmailModel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import com.fc.test.common.conf.V2Config; -import com.fc.test.model.auto.TSysEmail; import com.fc.test.model.custom.email.MailSenderInfo; import com.fc.test.model.custom.email.MyAuthenticator; @@ -111,7 +112,7 @@ public class SimpleEmailUtil { // 设置HTML内容 html.setContent(mailInfo.getContent(), "text/html; charset=utf-8"); mainPart.addBodyPart(html); - + // 遍历添加附件 if (fileList != null && fileList.size() > 0) { @@ -123,8 +124,8 @@ public class SimpleEmailUtil { mainPart.addBodyPart(attachmentBodyPart); } } - - + + // 将MiniMultipart对象设置为邮件内容 mailMessage.setContent(mainPart); //保存邮件 @@ -133,8 +134,8 @@ public class SimpleEmailUtil { Transport.send(mailMessage); return true; } - - public static void sendEmail(TSysEmail tSysEmail) throws Exception { + + public static void sendEmail(SysEmailModel sysEmailModel) throws Exception { // 这个类主要是设置邮件 MailSenderInfo mailInfo = new MailSenderInfo(); mailInfo.setMailServerHost(V2Config.getEmail_smtp()); @@ -144,9 +145,9 @@ public class SimpleEmailUtil { mailInfo.setUserName(V2Config.getEmail_account()); mailInfo.setPassword(V2Config.getEmail_password());// 您的邮箱密码 mailInfo.setFromAddress(mailInfo.getUserName());//发件人地址 - mailInfo.setToAddress(tSysEmail.getReceiversEmail());//收件人地址 - mailInfo.setSubject(tSysEmail.getTitle()); - mailInfo.setContent(tSysEmail.getContent()); + mailInfo.setToAddress(sysEmailModel.getReceiversEmail());//收件人地址 + mailInfo.setSubject(sysEmailModel.getTitle()); + mailInfo.setContent(sysEmailModel.getContent()); // 这个类主要来发送邮件 SimpleEmailUtil sms = new SimpleEmailUtil(); // sms.sendTextMail(mailInfo);//发送文体格式 diff --git a/src/main/java/com/fc/test/util/StringUtils.java b/src/main/java/com/fc/test/util/StringUtils.java index 0cb7aaa23129dc17b3931cdddb08f6bda82c46ae..e214fd8a625fce2bff624746243222a381c90c35 100644 --- a/src/main/java/com/fc/test/util/StringUtils.java +++ b/src/main/java/com/fc/test/util/StringUtils.java @@ -1,193 +1,181 @@ package com.fc.test.util; +import java.io.Serializable; +import java.util.Arrays; import java.util.Collection; +import java.util.List; import java.util.Map; import org.apache.commons.lang.WordUtils; import org.apache.commons.lang.text.StrBuilder; import com.fc.test.common.support.StrFormatter; - +import org.springframework.util.Assert; /** * 字符串工具类 - * + * * @author fc */ -public class StringUtils extends org.apache.commons.lang3.StringUtils -{ - /** 空字符串 */ +public class StringUtils extends org.apache.commons.lang3.StringUtils { + /** + * 空字符串 + */ private static final String NULLSTR = ""; - /** 下划线 */ + /** + * 下划线 + */ private static final char SEPARATOR = '_'; /** * 获取参数不为空值 - * + * * @param value defaultValue 要判断的value * @return value 返回值 */ - public static T nvl(T value, T defaultValue) - { + public static T nvl(T value, T defaultValue) { return value != null ? value : defaultValue; } /** * * 判断一个Collection是否为空, 包含List,Set,Queue - * + * * @param coll 要判断的Collection * @return true:为空 false:非空 */ - public static boolean isEmpty(Collection coll) - { + public static boolean isEmpty(Collection coll) { return isNull(coll) || coll.isEmpty(); } /** * * 判断一个Collection是否非空,包含List,Set,Queue - * + * * @param coll 要判断的Collection * @return true:非空 false:空 */ - public static boolean isNotEmpty(Collection coll) - { + public static boolean isNotEmpty(Collection coll) { return !isEmpty(coll); } /** * * 判断一个对象数组是否为空 - * + * * @param objects 要判断的对象数组 - ** @return true:为空 false:非空 + * * @return true:为空 false:非空 */ - public static boolean isEmpty(Object[] objects) - { + public static boolean isEmpty(Object[] objects) { return isNull(objects) || (objects.length == 0); } /** * * 判断一个对象数组是否非空 - * + * * @param objects 要判断的对象数组 * @return true:非空 false:空 */ - public static boolean isNotEmpty(Object[] objects) - { + public static boolean isNotEmpty(Object[] objects) { return !isEmpty(objects); } /** * * 判断一个Map是否为空 - * + * * @param map 要判断的Map * @return true:为空 false:非空 */ - public static boolean isEmpty(Map map) - { + public static boolean isEmpty(Map map) { return isNull(map) || map.isEmpty(); } /** * * 判断一个Map是否为空 - * + * * @param map 要判断的Map * @return true:非空 false:空 */ - public static boolean isNotEmpty(Map map) - { + public static boolean isNotEmpty(Map map) { return !isEmpty(map); } /** * * 判断一个字符串是否为空串 - * + * * @param str String * @return true:为空 false:非空 */ - public static boolean isEmpty(String str) - { + public static boolean isEmpty(String str) { return isNull(str) || NULLSTR.equals(str.trim()); } /** * * 判断一个字符串是否为非空串 - * + * * @param str String * @return true:非空串 false:空串 */ - public static boolean isNotEmpty(String str) - { + public static boolean isNotEmpty(String str) { return !isEmpty(str); } /** * * 判断一个对象是否为空 - * + * * @param object Object * @return true:为空 false:非空 */ - public static boolean isNull(Object object) - { + public static boolean isNull(Object object) { return object == null; } /** * * 判断一个对象是否非空 - * + * * @param object Object * @return true:非空 false:空 */ - public static boolean isNotNull(Object object) - { + public static boolean isNotNull(Object object) { return !isNull(object); } /** * * 判断一个对象是否是数组类型(Java基本型别的数组) - * + * * @param object 对象 * @return true:是数组 false:不是数组 */ - public static boolean isArray(Object object) - { + public static boolean isArray(Object object) { return isNotNull(object) && object.getClass().isArray(); } /** * 去空格 */ - public static String trim(String str) - { + public static String trim(String str) { return (str == null ? "" : str.trim()); } /** * 截取字符串 - * - * @param str 字符串 + * + * @param str 字符串 * @param start 开始 * @return 结果 */ - public static String substring(final String str, int start) - { - if (str == null) - { + public static String substring(final String str, int start) { + if (str == null) { return NULLSTR; } - if (start < 0) - { + if (start < 0) { start = str.length() + start; } - if (start < 0) - { + if (start < 0) { start = 0; } - if (start > str.length()) - { + if (start > str.length()) { return NULLSTR; } @@ -196,44 +184,36 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils /** * 截取字符串 - * - * @param str 字符串 + * + * @param str 字符串 * @param start 开始 - * @param end 结束 + * @param end 结束 * @return 结果 */ - public static String substring(final String str, int start, int end) - { - if (str == null) - { + public static String substring(final String str, int start, int end) { + if (str == null) { return NULLSTR; } - if (end < 0) - { + if (end < 0) { end = str.length() + end; } - if (start < 0) - { + if (start < 0) { start = str.length() + start; } - if (end > str.length()) - { + if (end > str.length()) { end = str.length(); } - if (start > end) - { + if (start > end) { return NULLSTR; } - if (start < 0) - { + if (start < 0) { start = 0; } - if (end < 0) - { + if (end < 0) { end = 0; } @@ -248,15 +228,13 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils * 通常使用:format("this is {} for {}", "a", "b") -> this is a for b
* 转义{}: format("this is \\{} for {}", "a", "b") -> this is \{} for a
* 转义\: format("this is \\\\{} for {}", "a", "b") -> this is \a for b
- * + * * @param template 文本模板,被替换的部分用 {} 表示 - * @param params 参数值 + * @param params 参数值 * @return 格式化后的文本 */ - public static String format(String template, Object... params) - { - if (isEmpty(params) || isEmpty(template)) - { + public static String format(String template, Object... params) { + if (isEmpty(params) || isEmpty(template)) { return template; } return StrFormatter.format(template, params); @@ -265,11 +243,9 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils /** * 驼峰首字符小写 NameVc>>nameVc */ - public static String uncapitalize(String str) - { + public static String uncapitalize(String str) { int strLen; - if (str == null || (strLen = str.length()) == 0) - { + if (str == null || (strLen = str.length()) == 0) { return str; } return new StrBuilder(strLen).append(Character.toLowerCase(str.charAt(0))).append(str.substring(1)).toString(); @@ -278,35 +254,27 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils /** * 驼峰命名转下划线 nameVc>>name_vc */ - public static String toUnderScoreCase(String s) - { - if (s == null) - { + public static String toUnderScoreCase(String s) { + if (s == null) { return null; } StringBuilder sb = new StringBuilder(); boolean upperCase = false; - for (int i = 0; i < s.length(); i++) - { + for (int i = 0; i < s.length(); i++) { char c = s.charAt(i); boolean nextUpperCase = true; - if (i < (s.length() - 1)) - { + if (i < (s.length() - 1)) { nextUpperCase = Character.isUpperCase(s.charAt(i + 1)); } - if ((i > 0) && Character.isUpperCase(c)) - { - if (!upperCase || !nextUpperCase) - { + if ((i > 0) && Character.isUpperCase(c)) { + if (!upperCase || !nextUpperCase) { sb.append(SEPARATOR); } upperCase = true; - } - else - { + } else { upperCase = false; } @@ -318,54 +286,44 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils /** * 是否包含字符串 - * - * @param str 验证字符串 + * + * @param str 验证字符串 * @param strs 字符串组 * @return 包含返回true */ - public static boolean inStringIgnoreCase(String str, String... strs) - { - if (str != null && strs != null) - { - for (String s : strs) - { - if (str.equalsIgnoreCase(trim(s))) - { + public static boolean inStringIgnoreCase(String str, String... strs) { + if (str != null && strs != null) { + for (String s : strs) { + if (str.equalsIgnoreCase(trim(s))) { return true; } } } return false; } - - + + /** * 将下划线大写方式命名的字符串转换为驼峰式。如果转换前的下划线大写方式命名的字符串为空,则返回空字符串。 例如:HELLO_WORLD->HelloWorld - * + * * @param name 转换前的下划线大写方式命名的字符串 * @return 转换后的驼峰式命名的字符串 */ - public static String convertToCamelCase(String name) - { + public static String convertToCamelCase(String name) { StringBuilder result = new StringBuilder(); // 快速检查 - if (name == null || name.isEmpty()) - { + if (name == null || name.isEmpty()) { // 没必要转换 return ""; - } - else if (!name.contains("_")) - { + } else if (!name.contains("_")) { // 不含下划线,仅将首字母大写 return name.substring(0, 1).toUpperCase() + name.substring(1); } // 用下划线将原始字符串分割 String[] camels = name.split("_"); - for (String camel : camels) - { + for (String camel : camels) { // 跳过原始字符串中开头、结尾的下换线或双重下划线 - if (camel.isEmpty()) - { + if (camel.isEmpty()) { continue; } // 首字母大写 @@ -374,6 +332,7 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils } return result.toString(); } + /** * 首字母大写 * @@ -384,6 +343,7 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils name = name.substring(0, 1).toUpperCase() + name.substring(1); return name; } + /** * 首字母小写 * @@ -395,7 +355,7 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils return name; } - + /** * 将下划线转化为大写 * @@ -404,7 +364,7 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils * @return */ public static String upperCase_(String name, boolean firstCase) { - if(isEmpty(name)){ + if (isEmpty(name)) { return ""; } String[] s = name.split("_"); @@ -412,57 +372,82 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils for (String s1 : s) { stringBuffer.append(s1.substring(0, 1).toUpperCase() + s1.substring(1)); } - if(!firstCase){ + if (!firstCase) { return firstLowerCase(stringBuffer.toString()); } return stringBuffer.toString(); } - + /** * get方法名字转成 t_b_abc>>tBAbc + * * @param str * @return * @author fuce * @Date 2020年1月30日 下午11:55:54 */ public static String toFUNName(String str) { - StringBuffer buffer=new StringBuffer(); - String name=str; - if(name.contains("_")) { - // 用下划线将原始字符串分割 + StringBuffer buffer = new StringBuffer(); + String name = str; + if (name.contains("_")) { + // 用下划线将原始字符串分割 String[] camels = name.split("_"); - boolean b=true; - + boolean b = true; + for (String str1 : camels) { - if(str1.length()==1&&b) { - b=false; - buffer.append(str1); - }else { - buffer.append(StringUtils.firstUpperCase(str1)); - } - - } - }else { - buffer.append(StringUtils.firstUpperCase(name)); - } - return buffer.toString(); + if (str1.length() == 1 && b) { + b = false; + buffer.append(str1); + } else { + buffer.append(StringUtils.firstUpperCase(str1)); + } + + } + } else { + buffer.append(StringUtils.firstUpperCase(name)); + } + return buffer.toString(); } /** * 列名转换成Java属性名 */ public static String columnToJava(String columnName) { - return WordUtils.capitalizeFully(columnName, new char[]{'_'}).replace("_", "" ); + return WordUtils.capitalizeFully(columnName, new char[]{'_'}).replace("_", ""); } - - + + /** * 表名转换成Java类名 */ public static String tableToJava(String tableName, String tablePrefix) { if (StringUtils.isNotBlank(tablePrefix)) { - tableName = tableName.replaceFirst(tablePrefix, "" ); + tableName = tableName.replaceFirst(tablePrefix, ""); } return columnToJava(tableName); } + + /** + * 分割成数组 + * + * @param context 要分割的内容 + * @param regex 分割符 + * @return + */ + public static String[] splitArray(String context, String regex) { + Assert.isTrue(StringUtils.isBlank(context), "splitArray context can not be null"); + Assert.isTrue(StringUtils.isBlank(regex), "splitArray regex can not be null"); + return context.split(regex); + } + + /** + * 分割成集合 + * @param context + * @param regex + * @return + */ + public static List splitList(String context, String regex) { + return Arrays.asList(splitArray(context, regex)); + } + } \ No newline at end of file diff --git a/src/main/resources/application-dev.yml b/src/main/resources/application-dev.yml index c640b2f68cd38c9ebd19afd080b23246a6836fc2..7b30c857ab23a6517331ddb2b735b5b4c68a71b3 100644 --- a/src/main/resources/application-dev.yml +++ b/src/main/resources/application-dev.yml @@ -2,20 +2,20 @@ spring: datasource: type: com.alibaba.druid.pool.DruidDataSource - driverClassName: com.mysql.jdbc.Driver + driverClassName: com.mysql.cj.jdbc.Driver #druid连接池配置 druid: #主库数据源 master: url: jdbc:mysql://localhost:3306/springbootv2?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false username: root - password: root + password: pencilso #备数据源 #关闭 slave: enabled: false url: jdbc:mysql://localhost:3306/springbootv3?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false username: root - password: root + password: pencilso #配置初始化连接数大小 initial-size: 10 # 最大连接数 diff --git a/src/main/resources/application-prod.yml b/src/main/resources/application-prod.yml index 6c49eb60b3f7b0a43bebb31b4afba34192fd2cc9..2596dadd6c208bc3c8fb6b95f68046079e31b566 100644 --- a/src/main/resources/application-prod.yml +++ b/src/main/resources/application-prod.yml @@ -10,13 +10,13 @@ spring: master: url: jdbc:mysql://localhost:3306/springbootv2?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false username: root - password: root + password: pencilso #备数据源 #关闭 slave: enabled: false url: jdbc:mysql://localhost:3306/springbootv3?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false username: root - password: root + password: pencilso #配置初始化连接数大小 initial-size: 10 # 最大连接数 diff --git a/src/main/resources/mybatis/custom/SysUtilMapper.xml b/src/main/resources/mapper/SysAreaModelMapper.xml similarity index 46% rename from src/main/resources/mybatis/custom/SysUtilMapper.xml rename to src/main/resources/mapper/SysAreaModelMapper.xml index 673e57e75759091e2bcbb615decc4d8e5f27c65a..e4c929fc71d587b933c0c6b08950e28321ed949f 100644 --- a/src/main/resources/mybatis/custom/SysUtilMapper.xml +++ b/src/main/resources/mapper/SysAreaModelMapper.xml @@ -1,9 +1,5 @@ - - - - - - ${sql} - - - \ No newline at end of file + + + + + diff --git a/src/main/resources/mapper/SysCityModelMapper.xml b/src/main/resources/mapper/SysCityModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..789787e3bf3e5efe6a2b08b8478710dd1052c9b2 --- /dev/null +++ b/src/main/resources/mapper/SysCityModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysDatasModelMapper.xml b/src/main/resources/mapper/SysDatasModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..c756b1f077fe3ccd30d6e4a7c236c3655d73c8cc --- /dev/null +++ b/src/main/resources/mapper/SysDatasModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysDepartmentModelMapper.xml b/src/main/resources/mapper/SysDepartmentModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..34bb56cc9eae245c7e1893082bf0145e898efcc3 --- /dev/null +++ b/src/main/resources/mapper/SysDepartmentModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysDictDataModelMapper.xml b/src/main/resources/mapper/SysDictDataModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..3e776a8f728bf207eef9622b97ceb6419917da1c --- /dev/null +++ b/src/main/resources/mapper/SysDictDataModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysDictTypeModelMapper.xml b/src/main/resources/mapper/SysDictTypeModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..43e4a67b50d22b6ce333aa04f9260494d20eaa76 --- /dev/null +++ b/src/main/resources/mapper/SysDictTypeModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysEmailModelMapper.xml b/src/main/resources/mapper/SysEmailModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..c5cc7666e87c2ad3787066883f1248ea7754483a --- /dev/null +++ b/src/main/resources/mapper/SysEmailModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysFileDataModelMapper.xml b/src/main/resources/mapper/SysFileDataModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..325c4c9f77c6ff9937c9fb4041a1b209b9cddc42 --- /dev/null +++ b/src/main/resources/mapper/SysFileDataModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysFileModelMapper.xml b/src/main/resources/mapper/SysFileModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..1b150e9e6a54e30ede07cc868c2ce1fcc14288b5 --- /dev/null +++ b/src/main/resources/mapper/SysFileModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysInterUrlModelMapper.xml b/src/main/resources/mapper/SysInterUrlModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..5230c1ae85e7c271b32d93f6ff44463233372604 --- /dev/null +++ b/src/main/resources/mapper/SysInterUrlModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysNoticeModelMapper.xml b/src/main/resources/mapper/SysNoticeModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..776b9b256d270b2aefed074271f036b608cc9b3b --- /dev/null +++ b/src/main/resources/mapper/SysNoticeModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysNoticeUserModelMapper.xml b/src/main/resources/mapper/SysNoticeUserModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..53780caabc86bbf7189625bf6b4d2cb97c0d7dd2 --- /dev/null +++ b/src/main/resources/mapper/SysNoticeUserModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysOperLogModelMapper.xml b/src/main/resources/mapper/SysOperLogModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..9cd64c2b845a34f90ec8e745f8019bc1406a0c6d --- /dev/null +++ b/src/main/resources/mapper/SysOperLogModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysPermissionModelMapper.xml b/src/main/resources/mapper/SysPermissionModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..163e57c0044a5cfa48ec5c78924df753a77ea16f --- /dev/null +++ b/src/main/resources/mapper/SysPermissionModelMapper.xml @@ -0,0 +1,21 @@ + + + + + + + diff --git a/src/main/resources/mapper/SysPermissionRoleModelMapper.xml b/src/main/resources/mapper/SysPermissionRoleModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..300e7b9f154203b602e68ea213b859cc22f24705 --- /dev/null +++ b/src/main/resources/mapper/SysPermissionRoleModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysPositionModelMapper.xml b/src/main/resources/mapper/SysPositionModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..00d457a576bb10dcf2c3194b06ebf5aec42123c7 --- /dev/null +++ b/src/main/resources/mapper/SysPositionModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysProvinceModelMapper.xml b/src/main/resources/mapper/SysProvinceModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..671c8da73d9979076bac6da615afb414473cfea9 --- /dev/null +++ b/src/main/resources/mapper/SysProvinceModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysQuartzJobLogModelMapper.xml b/src/main/resources/mapper/SysQuartzJobLogModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..68a18047105e0b68993bbad530c494a820e45abc --- /dev/null +++ b/src/main/resources/mapper/SysQuartzJobLogModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysQuartzJobModelMapper.xml b/src/main/resources/mapper/SysQuartzJobModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..64f621f6405141adb6fd2c7ecef6bb87fbbdcbc5 --- /dev/null +++ b/src/main/resources/mapper/SysQuartzJobModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysRoleModelMapper.xml b/src/main/resources/mapper/SysRoleModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..45921532e7341546002b239b2f3fbc8590f51a7b --- /dev/null +++ b/src/main/resources/mapper/SysRoleModelMapper.xml @@ -0,0 +1,10 @@ + + + + + + diff --git a/src/main/resources/mapper/SysRoleUserModelMapper.xml b/src/main/resources/mapper/SysRoleUserModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..70e0dfe75d18c23f90ff665d7643ff872d8c722c --- /dev/null +++ b/src/main/resources/mapper/SysRoleUserModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysStreetModelMapper.xml b/src/main/resources/mapper/SysStreetModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..ae225830f3d0723ef509cb1f9061315a8bafaff7 --- /dev/null +++ b/src/main/resources/mapper/SysStreetModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/SysUserModelMapper.xml b/src/main/resources/mapper/SysUserModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..0bb01b0507d4f1ba3d41dabd7dcc4f5bc8bd11dc --- /dev/null +++ b/src/main/resources/mapper/SysUserModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mapper/TestModelMapper.xml b/src/main/resources/mapper/TestModelMapper.xml new file mode 100644 index 0000000000000000000000000000000000000000..1ae7d5e49f8665f61f3f88047a47a43c5f572913 --- /dev/null +++ b/src/main/resources/mapper/TestModelMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/resources/mybatis/auto/SysAreaMapper.xml b/src/main/resources/mybatis/auto/SysAreaMapper.xml deleted file mode 100644 index 452e6bae14253e0f0a17fa991d08f024d8aa7b7c..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysAreaMapper.xml +++ /dev/null @@ -1,325 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, area_code, city_code, area_name, short_name, lng, lat, sort, gmt_create, gmt_modified, - memo, data_state - - - - - delete from t_sys_area - where id = #{id,jdbcType=INTEGER} - - - delete from t_sys_area - - - - - - insert into t_sys_area (id, area_code, city_code, - area_name, short_name, lng, - lat, sort, gmt_create, - gmt_modified, memo, data_state - ) - values (#{id,jdbcType=INTEGER}, #{areaCode,jdbcType=VARCHAR}, #{cityCode,jdbcType=VARCHAR}, - #{areaName,jdbcType=VARCHAR}, #{shortName,jdbcType=VARCHAR}, #{lng,jdbcType=VARCHAR}, - #{lat,jdbcType=VARCHAR}, #{sort,jdbcType=INTEGER}, #{gmtCreate,jdbcType=TIMESTAMP}, - #{gmtModified,jdbcType=TIMESTAMP}, #{memo,jdbcType=VARCHAR}, #{dataState,jdbcType=INTEGER} - ) - - - insert into t_sys_area - - - id, - - - area_code, - - - city_code, - - - area_name, - - - short_name, - - - lng, - - - lat, - - - sort, - - - gmt_create, - - - gmt_modified, - - - memo, - - - data_state, - - - - - #{id,jdbcType=INTEGER}, - - - #{areaCode,jdbcType=VARCHAR}, - - - #{cityCode,jdbcType=VARCHAR}, - - - #{areaName,jdbcType=VARCHAR}, - - - #{shortName,jdbcType=VARCHAR}, - - - #{lng,jdbcType=VARCHAR}, - - - #{lat,jdbcType=VARCHAR}, - - - #{sort,jdbcType=INTEGER}, - - - #{gmtCreate,jdbcType=TIMESTAMP}, - - - #{gmtModified,jdbcType=TIMESTAMP}, - - - #{memo,jdbcType=VARCHAR}, - - - #{dataState,jdbcType=INTEGER}, - - - - - - update t_sys_area - - - id = #{record.id,jdbcType=INTEGER}, - - - area_code = #{record.areaCode,jdbcType=VARCHAR}, - - - city_code = #{record.cityCode,jdbcType=VARCHAR}, - - - area_name = #{record.areaName,jdbcType=VARCHAR}, - - - short_name = #{record.shortName,jdbcType=VARCHAR}, - - - lng = #{record.lng,jdbcType=VARCHAR}, - - - lat = #{record.lat,jdbcType=VARCHAR}, - - - sort = #{record.sort,jdbcType=INTEGER}, - - - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{record.memo,jdbcType=VARCHAR}, - - - data_state = #{record.dataState,jdbcType=INTEGER}, - - - - - - - - update t_sys_area - set id = #{record.id,jdbcType=INTEGER}, - area_code = #{record.areaCode,jdbcType=VARCHAR}, - city_code = #{record.cityCode,jdbcType=VARCHAR}, - area_name = #{record.areaName,jdbcType=VARCHAR}, - short_name = #{record.shortName,jdbcType=VARCHAR}, - lng = #{record.lng,jdbcType=VARCHAR}, - lat = #{record.lat,jdbcType=VARCHAR}, - sort = #{record.sort,jdbcType=INTEGER}, - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - memo = #{record.memo,jdbcType=VARCHAR}, - data_state = #{record.dataState,jdbcType=INTEGER} - - - - - - update t_sys_area - - - area_code = #{areaCode,jdbcType=VARCHAR}, - - - city_code = #{cityCode,jdbcType=VARCHAR}, - - - area_name = #{areaName,jdbcType=VARCHAR}, - - - short_name = #{shortName,jdbcType=VARCHAR}, - - - lng = #{lng,jdbcType=VARCHAR}, - - - lat = #{lat,jdbcType=VARCHAR}, - - - sort = #{sort,jdbcType=INTEGER}, - - - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{memo,jdbcType=VARCHAR}, - - - data_state = #{dataState,jdbcType=INTEGER}, - - - where id = #{id,jdbcType=INTEGER} - - - update t_sys_area - set area_code = #{areaCode,jdbcType=VARCHAR}, - city_code = #{cityCode,jdbcType=VARCHAR}, - area_name = #{areaName,jdbcType=VARCHAR}, - short_name = #{shortName,jdbcType=VARCHAR}, - lng = #{lng,jdbcType=VARCHAR}, - lat = #{lat,jdbcType=VARCHAR}, - sort = #{sort,jdbcType=INTEGER}, - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - memo = #{memo,jdbcType=VARCHAR}, - data_state = #{dataState,jdbcType=INTEGER} - where id = #{id,jdbcType=INTEGER} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysCityMapper.xml b/src/main/resources/mybatis/auto/SysCityMapper.xml deleted file mode 100644 index f1cb21a2581c136b08dc34b617f7329b19ff3e20..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysCityMapper.xml +++ /dev/null @@ -1,325 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, city_code, city_name, short_name, province_code, lng, lat, sort, gmt_create, - gmt_modified, memo, data_state - - - - - delete from t_sys_city - where id = #{id,jdbcType=INTEGER} - - - delete from t_sys_city - - - - - - insert into t_sys_city (id, city_code, city_name, - short_name, province_code, lng, - lat, sort, gmt_create, - gmt_modified, memo, data_state - ) - values (#{id,jdbcType=INTEGER}, #{cityCode,jdbcType=VARCHAR}, #{cityName,jdbcType=VARCHAR}, - #{shortName,jdbcType=VARCHAR}, #{provinceCode,jdbcType=VARCHAR}, #{lng,jdbcType=VARCHAR}, - #{lat,jdbcType=VARCHAR}, #{sort,jdbcType=INTEGER}, #{gmtCreate,jdbcType=TIMESTAMP}, - #{gmtModified,jdbcType=TIMESTAMP}, #{memo,jdbcType=VARCHAR}, #{dataState,jdbcType=INTEGER} - ) - - - insert into t_sys_city - - - id, - - - city_code, - - - city_name, - - - short_name, - - - province_code, - - - lng, - - - lat, - - - sort, - - - gmt_create, - - - gmt_modified, - - - memo, - - - data_state, - - - - - #{id,jdbcType=INTEGER}, - - - #{cityCode,jdbcType=VARCHAR}, - - - #{cityName,jdbcType=VARCHAR}, - - - #{shortName,jdbcType=VARCHAR}, - - - #{provinceCode,jdbcType=VARCHAR}, - - - #{lng,jdbcType=VARCHAR}, - - - #{lat,jdbcType=VARCHAR}, - - - #{sort,jdbcType=INTEGER}, - - - #{gmtCreate,jdbcType=TIMESTAMP}, - - - #{gmtModified,jdbcType=TIMESTAMP}, - - - #{memo,jdbcType=VARCHAR}, - - - #{dataState,jdbcType=INTEGER}, - - - - - - update t_sys_city - - - id = #{record.id,jdbcType=INTEGER}, - - - city_code = #{record.cityCode,jdbcType=VARCHAR}, - - - city_name = #{record.cityName,jdbcType=VARCHAR}, - - - short_name = #{record.shortName,jdbcType=VARCHAR}, - - - province_code = #{record.provinceCode,jdbcType=VARCHAR}, - - - lng = #{record.lng,jdbcType=VARCHAR}, - - - lat = #{record.lat,jdbcType=VARCHAR}, - - - sort = #{record.sort,jdbcType=INTEGER}, - - - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{record.memo,jdbcType=VARCHAR}, - - - data_state = #{record.dataState,jdbcType=INTEGER}, - - - - - - - - update t_sys_city - set id = #{record.id,jdbcType=INTEGER}, - city_code = #{record.cityCode,jdbcType=VARCHAR}, - city_name = #{record.cityName,jdbcType=VARCHAR}, - short_name = #{record.shortName,jdbcType=VARCHAR}, - province_code = #{record.provinceCode,jdbcType=VARCHAR}, - lng = #{record.lng,jdbcType=VARCHAR}, - lat = #{record.lat,jdbcType=VARCHAR}, - sort = #{record.sort,jdbcType=INTEGER}, - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - memo = #{record.memo,jdbcType=VARCHAR}, - data_state = #{record.dataState,jdbcType=INTEGER} - - - - - - update t_sys_city - - - city_code = #{cityCode,jdbcType=VARCHAR}, - - - city_name = #{cityName,jdbcType=VARCHAR}, - - - short_name = #{shortName,jdbcType=VARCHAR}, - - - province_code = #{provinceCode,jdbcType=VARCHAR}, - - - lng = #{lng,jdbcType=VARCHAR}, - - - lat = #{lat,jdbcType=VARCHAR}, - - - sort = #{sort,jdbcType=INTEGER}, - - - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{memo,jdbcType=VARCHAR}, - - - data_state = #{dataState,jdbcType=INTEGER}, - - - where id = #{id,jdbcType=INTEGER} - - - update t_sys_city - set city_code = #{cityCode,jdbcType=VARCHAR}, - city_name = #{cityName,jdbcType=VARCHAR}, - short_name = #{shortName,jdbcType=VARCHAR}, - province_code = #{provinceCode,jdbcType=VARCHAR}, - lng = #{lng,jdbcType=VARCHAR}, - lat = #{lat,jdbcType=VARCHAR}, - sort = #{sort,jdbcType=INTEGER}, - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - memo = #{memo,jdbcType=VARCHAR}, - data_state = #{dataState,jdbcType=INTEGER} - where id = #{id,jdbcType=INTEGER} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysDepartmentMapper.xml b/src/main/resources/mybatis/auto/SysDepartmentMapper.xml deleted file mode 100644 index 79247a13484418f6a00feb8999fe57301b63503d..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysDepartmentMapper.xml +++ /dev/null @@ -1,318 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - parent_id, - dept_name, - leader, - phone, - email, - status, - order_num, - (select count(1) from t_sys_department where parent_id=a.id) childcount - - - - - - delete from t_sys_department - where id = #{id,jdbcType=INTEGER} - - - delete from t_sys_department - - - - - - - insert into t_sys_department ( - id, - parent_id, - dept_name, - leader, - phone, - email, - status, - order_num - ) - values ( - #{id,jdbcType=INTEGER}, - #{parentId,jdbcType=VARCHAR}, - #{deptName,jdbcType=VARCHAR}, - #{leader,jdbcType=VARCHAR}, - #{phone,jdbcType=VARCHAR}, - #{email,jdbcType=VARCHAR}, - #{status,jdbcType=INTEGER}, - #{orderNum,jdbcType=INTEGER} - ) - - - - insert into t_sys_department - - - - id, - - - - - parent_id, - - - - - dept_name, - - - - - leader, - - - - - phone, - - - - - email, - - - - - status, - - - - - order_num, - - - - - - #{id,jdbcType=INTEGER}, - - - #{parentId,jdbcType=VARCHAR}, - - - #{deptName,jdbcType=VARCHAR}, - - - #{leader,jdbcType=VARCHAR}, - - - #{phone,jdbcType=VARCHAR}, - - - #{email,jdbcType=VARCHAR}, - - - #{status,jdbcType=INTEGER}, - - - #{orderNum,jdbcType=INTEGER}, - - - - - - - - update t_sys_department - - - id = #{record.id,jdbcType=INTEGER}, - - - parent_id = #{record.parentId,jdbcType=VARCHAR}, - - - dept_name = #{record.deptName,jdbcType=VARCHAR}, - - - leader = #{record.leader,jdbcType=VARCHAR}, - - - phone = #{record.phone,jdbcType=VARCHAR}, - - - email = #{record.email,jdbcType=VARCHAR}, - - - status = #{record.status,jdbcType=INTEGER}, - - - order_num = #{record.orderNum,jdbcType=INTEGER}, - - - - - - - - - - - update t_sys_department - set - id = #{record.id,jdbcType=INTEGER}, - parent_id = #{record.parentId,jdbcType=VARCHAR}, - dept_name = #{record.deptName,jdbcType=VARCHAR}, - leader = #{record.leader,jdbcType=VARCHAR}, - phone = #{record.phone,jdbcType=VARCHAR}, - email = #{record.email,jdbcType=VARCHAR}, - status = #{record.status,jdbcType=INTEGER}, - order_num = #{record.orderNum,jdbcType=INTEGER} - - - - - - - - update t_sys_department - - - parent_id = #{parentId,jdbcType=VARCHAR}, - - - dept_name = #{deptName,jdbcType=VARCHAR}, - - - leader = #{leader,jdbcType=VARCHAR}, - - - phone = #{phone,jdbcType=VARCHAR}, - - - email = #{email,jdbcType=VARCHAR}, - - - status = #{status,jdbcType=INTEGER}, - - - order_num = #{orderNum,jdbcType=INTEGER}, - - - where - id = #{id,jdbcType=INTEGER} - - - - - - - update t_sys_department - set - parent_id = #{parentId,jdbcType=VARCHAR}, - dept_name = #{deptName,jdbcType=VARCHAR}, - leader = #{leader,jdbcType=VARCHAR}, - phone = #{phone,jdbcType=VARCHAR}, - email = #{email,jdbcType=VARCHAR}, - status = #{status,jdbcType=INTEGER}, - order_num = #{orderNum,jdbcType=INTEGER} - where - id = #{id,jdbcType=INTEGER} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysInterUrlMapper.xml b/src/main/resources/mybatis/auto/SysInterUrlMapper.xml deleted file mode 100644 index 1ba089c8871bbc5a46a69b89ea29a7947948840b..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysInterUrlMapper.xml +++ /dev/null @@ -1,236 +0,0 @@ - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - inter_name, - url, - type - - - - - - delete from t_sys_inter_url - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_inter_url - - - - - - - insert into t_sys_inter_url ( - id, - inter_name, - url, - type - ) - values ( - #{id,jdbcType=VARCHAR}, - #{interName,jdbcType=VARCHAR}, - #{url,jdbcType=VARCHAR}, - #{type,jdbcType=INTEGER} - ) - - - - insert into t_sys_inter_url - - - - id, - - - - - inter_name, - - - - - url, - - - - - type, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{interName,jdbcType=VARCHAR}, - - - #{url,jdbcType=VARCHAR}, - - - #{type,jdbcType=INTEGER}, - - - - - - - - update t_sys_inter_url - - - id = #{record.id,jdbcType=VARCHAR}, - - - inter_name = #{record.interName,jdbcType=VARCHAR}, - - - url = #{record.url,jdbcType=VARCHAR}, - - - type = #{record.type,jdbcType=INTEGER}, - - - - - - - - - - - update t_sys_inter_url - set - id = #{record.id,jdbcType=VARCHAR}, - inter_name = #{record.interName,jdbcType=VARCHAR}, - url = #{record.url,jdbcType=VARCHAR}, - type = #{record.type,jdbcType=INTEGER} - - - - - - - - update t_sys_inter_url - - - inter_name = #{interName,jdbcType=VARCHAR}, - - - url = #{url,jdbcType=VARCHAR}, - - - type = #{type,jdbcType=INTEGER}, - - - where - id = #{id,jdbcType=VARCHAR} - - - - - - - update t_sys_inter_url - set - inter_name = #{interName,jdbcType=VARCHAR}, - url = #{url,jdbcType=VARCHAR}, - type = #{type,jdbcType=INTEGER} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysNoticeMapper.xml b/src/main/resources/mybatis/auto/SysNoticeMapper.xml deleted file mode 100644 index 872cb818adc29079014db6dc20d0f9d97090f496..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysNoticeMapper.xml +++ /dev/null @@ -1,296 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - title, - content, - type, - create_id, - create_username, - create_time - - - - - - delete from t_sys_notice - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_notice - - - - - - - insert into t_sys_notice ( - id, - title, - content, - type, - create_id, - create_username, - create_time - ) - values ( - #{id,jdbcType=VARCHAR}, - #{title,jdbcType=VARCHAR}, - #{content,jdbcType=VARCHAR}, - #{type,jdbcType=INTEGER}, - #{createId,jdbcType=VARCHAR}, - #{createUsername,jdbcType=VARCHAR}, - #{createTime,jdbcType=TIMESTAMP} - ) - - - - insert into t_sys_notice - - - - id, - - - - - title, - - - - - content, - - - - - type, - - - - - create_id, - - - - - create_username, - - - - - create_time, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{title,jdbcType=VARCHAR}, - - - #{content,jdbcType=VARCHAR}, - - - #{type,jdbcType=INTEGER}, - - - #{createId,jdbcType=VARCHAR}, - - - #{createUsername,jdbcType=VARCHAR}, - - - #{createTime,jdbcType=TIMESTAMP}, - - - - - - - - update t_sys_notice - - - id = #{record.id,jdbcType=VARCHAR}, - - - title = #{record.title,jdbcType=VARCHAR}, - - - content = #{record.content,jdbcType=VARCHAR}, - - - type = #{record.type,jdbcType=INTEGER}, - - - create_id = #{record.createId,jdbcType=VARCHAR}, - - - create_username = #{record.createUsername,jdbcType=VARCHAR}, - - - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - - - - - - - - - - - update t_sys_notice - set - id = #{record.id,jdbcType=VARCHAR}, - title = #{record.title,jdbcType=VARCHAR}, - content = #{record.content,jdbcType=VARCHAR}, - type = #{record.type,jdbcType=INTEGER}, - create_id = #{record.createId,jdbcType=VARCHAR}, - create_username = #{record.createUsername,jdbcType=VARCHAR}, - create_time = #{record.createTime,jdbcType=TIMESTAMP} - - - - - - - - update t_sys_notice - - - title = #{title,jdbcType=VARCHAR}, - - - content = #{content,jdbcType=VARCHAR}, - - - type = #{type,jdbcType=INTEGER}, - - - create_id = #{createId,jdbcType=VARCHAR}, - - - create_username = #{createUsername,jdbcType=VARCHAR}, - - - create_time = #{createTime,jdbcType=TIMESTAMP}, - - - where - id = #{id,jdbcType=VARCHAR} - - - - - - - update t_sys_notice - set - title = #{title,jdbcType=VARCHAR}, - content = #{content,jdbcType=VARCHAR}, - type = #{type,jdbcType=INTEGER}, - create_id = #{createId,jdbcType=VARCHAR}, - create_username = #{createUsername,jdbcType=VARCHAR}, - create_time = #{createTime,jdbcType=TIMESTAMP} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysNoticeUserMapper.xml b/src/main/resources/mybatis/auto/SysNoticeUserMapper.xml deleted file mode 100644 index 9ebaf96098de82ff9c79fe2a0f8803bd0b81c4c3..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysNoticeUserMapper.xml +++ /dev/null @@ -1,236 +0,0 @@ - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - notice_id, - user_id, - state - - - - - - delete from t_sys_notice_user - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_notice_user - - - - - - - insert into t_sys_notice_user ( - id, - notice_id, - user_id, - state - ) - values ( - #{id,jdbcType=VARCHAR}, - #{noticeId,jdbcType=VARCHAR}, - #{userId,jdbcType=VARCHAR}, - #{state,jdbcType=INTEGER} - ) - - - - insert into t_sys_notice_user - - - - id, - - - - - notice_id, - - - - - user_id, - - - - - state, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{noticeId,jdbcType=VARCHAR}, - - - #{userId,jdbcType=VARCHAR}, - - - #{state,jdbcType=INTEGER}, - - - - - - - - update t_sys_notice_user - - - id = #{record.id,jdbcType=VARCHAR}, - - - notice_id = #{record.noticeId,jdbcType=VARCHAR}, - - - user_id = #{record.userId,jdbcType=VARCHAR}, - - - state = #{record.state,jdbcType=INTEGER}, - - - - - - - - - - - update t_sys_notice_user - set - id = #{record.id,jdbcType=VARCHAR}, - notice_id = #{record.noticeId,jdbcType=VARCHAR}, - user_id = #{record.userId,jdbcType=VARCHAR}, - state = #{record.state,jdbcType=INTEGER} - - - - - - - - update t_sys_notice_user - - - notice_id = #{noticeId,jdbcType=VARCHAR}, - - - user_id = #{userId,jdbcType=VARCHAR}, - - - state = #{state,jdbcType=INTEGER}, - - - where - id = #{id,jdbcType=VARCHAR} - - - - - - - update t_sys_notice_user - set - notice_id = #{noticeId,jdbcType=VARCHAR}, - user_id = #{userId,jdbcType=VARCHAR}, - state = #{state,jdbcType=INTEGER} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysPositionMapper.xml b/src/main/resources/mybatis/auto/SysPositionMapper.xml deleted file mode 100644 index 940226e051a6a2cc9b252faf6266e46fbee29a57..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysPositionMapper.xml +++ /dev/null @@ -1,236 +0,0 @@ - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - post_name, - order_num, - status - - - - - - delete from t_sys_position - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_position - - - - - - - insert into t_sys_position ( - id, - post_name, - order_num, - status - ) - values ( - #{id,jdbcType=VARCHAR}, - #{postName,jdbcType=VARCHAR}, - #{orderNum,jdbcType=INTEGER}, - #{status,jdbcType=INTEGER} - ) - - - - insert into t_sys_position - - - - id, - - - - - post_name, - - - - - order_num, - - - - - status, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{postName,jdbcType=VARCHAR}, - - - #{orderNum,jdbcType=INTEGER}, - - - #{status,jdbcType=INTEGER}, - - - - - - - - update t_sys_position - - - id = #{record.id,jdbcType=VARCHAR}, - - - post_name = #{record.postName,jdbcType=VARCHAR}, - - - order_num = #{record.orderNum,jdbcType=INTEGER}, - - - status = #{record.status,jdbcType=INTEGER}, - - - - - - - - - - - update t_sys_position - set - id = #{record.id,jdbcType=VARCHAR}, - post_name = #{record.postName,jdbcType=VARCHAR}, - order_num = #{record.orderNum,jdbcType=INTEGER}, - status = #{record.status,jdbcType=INTEGER} - - - - - - - - update t_sys_position - - - post_name = #{postName,jdbcType=VARCHAR}, - - - order_num = #{orderNum,jdbcType=INTEGER}, - - - status = #{status,jdbcType=INTEGER}, - - - where - id = #{id,jdbcType=VARCHAR} - - - - - - - update t_sys_position - set - post_name = #{postName,jdbcType=VARCHAR}, - order_num = #{orderNum,jdbcType=INTEGER}, - status = #{status,jdbcType=INTEGER} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysProvinceMapper.xml b/src/main/resources/mybatis/auto/SysProvinceMapper.xml deleted file mode 100644 index 529398abef3fe8ad3cddbf0a1703020d4885ea22..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysProvinceMapper.xml +++ /dev/null @@ -1,308 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, province_code, province_name, short_name, lng, lat, sort, gmt_create, gmt_modified, - memo, data_state - - - - - delete from t_sys_province - where id = #{id,jdbcType=INTEGER} - - - delete from t_sys_province - - - - - - insert into t_sys_province (id, province_code, province_name, - short_name, lng, lat, - sort, gmt_create, gmt_modified, - memo, data_state) - values (#{id,jdbcType=INTEGER}, #{provinceCode,jdbcType=VARCHAR}, #{provinceName,jdbcType=VARCHAR}, - #{shortName,jdbcType=VARCHAR}, #{lng,jdbcType=VARCHAR}, #{lat,jdbcType=VARCHAR}, - #{sort,jdbcType=INTEGER}, #{gmtCreate,jdbcType=TIMESTAMP}, #{gmtModified,jdbcType=TIMESTAMP}, - #{memo,jdbcType=VARCHAR}, #{dataState,jdbcType=INTEGER}) - - - insert into t_sys_province - - - id, - - - province_code, - - - province_name, - - - short_name, - - - lng, - - - lat, - - - sort, - - - gmt_create, - - - gmt_modified, - - - memo, - - - data_state, - - - - - #{id,jdbcType=INTEGER}, - - - #{provinceCode,jdbcType=VARCHAR}, - - - #{provinceName,jdbcType=VARCHAR}, - - - #{shortName,jdbcType=VARCHAR}, - - - #{lng,jdbcType=VARCHAR}, - - - #{lat,jdbcType=VARCHAR}, - - - #{sort,jdbcType=INTEGER}, - - - #{gmtCreate,jdbcType=TIMESTAMP}, - - - #{gmtModified,jdbcType=TIMESTAMP}, - - - #{memo,jdbcType=VARCHAR}, - - - #{dataState,jdbcType=INTEGER}, - - - - - - update t_sys_province - - - id = #{record.id,jdbcType=INTEGER}, - - - province_code = #{record.provinceCode,jdbcType=VARCHAR}, - - - province_name = #{record.provinceName,jdbcType=VARCHAR}, - - - short_name = #{record.shortName,jdbcType=VARCHAR}, - - - lng = #{record.lng,jdbcType=VARCHAR}, - - - lat = #{record.lat,jdbcType=VARCHAR}, - - - sort = #{record.sort,jdbcType=INTEGER}, - - - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{record.memo,jdbcType=VARCHAR}, - - - data_state = #{record.dataState,jdbcType=INTEGER}, - - - - - - - - update t_sys_province - set id = #{record.id,jdbcType=INTEGER}, - province_code = #{record.provinceCode,jdbcType=VARCHAR}, - province_name = #{record.provinceName,jdbcType=VARCHAR}, - short_name = #{record.shortName,jdbcType=VARCHAR}, - lng = #{record.lng,jdbcType=VARCHAR}, - lat = #{record.lat,jdbcType=VARCHAR}, - sort = #{record.sort,jdbcType=INTEGER}, - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - memo = #{record.memo,jdbcType=VARCHAR}, - data_state = #{record.dataState,jdbcType=INTEGER} - - - - - - update t_sys_province - - - province_code = #{provinceCode,jdbcType=VARCHAR}, - - - province_name = #{provinceName,jdbcType=VARCHAR}, - - - short_name = #{shortName,jdbcType=VARCHAR}, - - - lng = #{lng,jdbcType=VARCHAR}, - - - lat = #{lat,jdbcType=VARCHAR}, - - - sort = #{sort,jdbcType=INTEGER}, - - - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{memo,jdbcType=VARCHAR}, - - - data_state = #{dataState,jdbcType=INTEGER}, - - - where id = #{id,jdbcType=INTEGER} - - - update t_sys_province - set province_code = #{provinceCode,jdbcType=VARCHAR}, - province_name = #{provinceName,jdbcType=VARCHAR}, - short_name = #{shortName,jdbcType=VARCHAR}, - lng = #{lng,jdbcType=VARCHAR}, - lat = #{lat,jdbcType=VARCHAR}, - sort = #{sort,jdbcType=INTEGER}, - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - memo = #{memo,jdbcType=VARCHAR}, - data_state = #{dataState,jdbcType=INTEGER} - where id = #{id,jdbcType=INTEGER} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysQuartzJobLogMapper.xml b/src/main/resources/mybatis/auto/SysQuartzJobLogMapper.xml deleted file mode 100644 index bfc9811a6a096576bcda013864ceaad2c69d151e..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysQuartzJobLogMapper.xml +++ /dev/null @@ -1,336 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - job_name, - job_group, - invoke_target, - job_message, - status, - exception_info, - start_time, - end_time - - - - - - delete from t_sys_quartz_job_log - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_quartz_job_log - - - - - - - insert into t_sys_quartz_job_log ( - id, - job_name, - job_group, - invoke_target, - job_message, - status, - exception_info, - start_time, - end_time - ) - values ( - #{id,jdbcType=VARCHAR}, - #{jobName,jdbcType=VARCHAR}, - #{jobGroup,jdbcType=VARCHAR}, - #{invokeTarget,jdbcType=VARCHAR}, - #{jobMessage,jdbcType=VARCHAR}, - #{status,jdbcType=INTEGER}, - #{exceptionInfo,jdbcType=VARCHAR}, - #{startTime,jdbcType=TIMESTAMP}, - #{endTime,jdbcType=TIMESTAMP} - ) - - - - insert into t_sys_quartz_job_log - - - - id, - - - - - job_name, - - - - - job_group, - - - - - invoke_target, - - - - - job_message, - - - - - status, - - - - - exception_info, - - - - - start_time, - - - - - end_time, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{jobName,jdbcType=VARCHAR}, - - - #{jobGroup,jdbcType=VARCHAR}, - - - #{invokeTarget,jdbcType=VARCHAR}, - - - #{jobMessage,jdbcType=VARCHAR}, - - - #{status,jdbcType=INTEGER}, - - - #{exceptionInfo,jdbcType=VARCHAR}, - - - #{startTime,jdbcType=TIMESTAMP}, - - - #{endTime,jdbcType=TIMESTAMP}, - - - - - - - - update t_sys_quartz_job_log - - - id = #{record.id,jdbcType=VARCHAR}, - - - job_name = #{record.jobName,jdbcType=VARCHAR}, - - - job_group = #{record.jobGroup,jdbcType=VARCHAR}, - - - invoke_target = #{record.invokeTarget,jdbcType=VARCHAR}, - - - job_message = #{record.jobMessage,jdbcType=VARCHAR}, - - - status = #{record.status,jdbcType=INTEGER}, - - - exception_info = #{record.exceptionInfo,jdbcType=VARCHAR}, - - - start_time = #{record.startTime,jdbcType=TIMESTAMP}, - - - end_time = #{record.endTime,jdbcType=TIMESTAMP}, - - - - - - - - - - - update t_sys_quartz_job_log - set - id = #{record.id,jdbcType=VARCHAR}, - job_name = #{record.jobName,jdbcType=VARCHAR}, - job_group = #{record.jobGroup,jdbcType=VARCHAR}, - invoke_target = #{record.invokeTarget,jdbcType=VARCHAR}, - job_message = #{record.jobMessage,jdbcType=VARCHAR}, - status = #{record.status,jdbcType=INTEGER}, - exception_info = #{record.exceptionInfo,jdbcType=VARCHAR}, - start_time = #{record.startTime,jdbcType=TIMESTAMP}, - end_time = #{record.endTime,jdbcType=TIMESTAMP} - - - - - - - - update t_sys_quartz_job_log - - - job_name = #{jobName,jdbcType=VARCHAR}, - - - job_group = #{jobGroup,jdbcType=VARCHAR}, - - - invoke_target = #{invokeTarget,jdbcType=VARCHAR}, - - - job_message = #{jobMessage,jdbcType=VARCHAR}, - - - status = #{status,jdbcType=INTEGER}, - - - exception_info = #{exceptionInfo,jdbcType=VARCHAR}, - - - start_time = #{startTime,jdbcType=TIMESTAMP}, - - - end_time = #{endTime,jdbcType=TIMESTAMP}, - - - where - id = #{id,jdbcType=VARCHAR} - - - - - - - update t_sys_quartz_job_log - set - job_name = #{jobName,jdbcType=VARCHAR}, - job_group = #{jobGroup,jdbcType=VARCHAR}, - invoke_target = #{invokeTarget,jdbcType=VARCHAR}, - job_message = #{jobMessage,jdbcType=VARCHAR}, - status = #{status,jdbcType=INTEGER}, - exception_info = #{exceptionInfo,jdbcType=VARCHAR}, - start_time = #{startTime,jdbcType=TIMESTAMP}, - end_time = #{endTime,jdbcType=TIMESTAMP} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysQuartzJobMapper.xml b/src/main/resources/mybatis/auto/SysQuartzJobMapper.xml deleted file mode 100644 index 2640f2388a5f67bc696bca9953520b65e92e8bc7..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysQuartzJobMapper.xml +++ /dev/null @@ -1,314 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - job_name, - job_group, - invoke_target, - cron_expression, - misfire_policy, - concurrent, - status - - - - - - delete from t_sys_quartz_job - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_quartz_job - - - - - - - insert into t_sys_quartz_job ( - id, - job_name, - job_group, - invoke_target, - cron_expression, - misfire_policy, - concurrent, - status - ) - values ( - #{id,jdbcType=VARCHAR}, - #{jobName,jdbcType=VARCHAR}, - #{jobGroup,jdbcType=VARCHAR}, - #{invokeTarget,jdbcType=VARCHAR}, - #{cronExpression,jdbcType=VARCHAR}, - #{misfirePolicy,jdbcType=VARCHAR}, - #{concurrent,jdbcType=VARCHAR}, - #{status,jdbcType=INTEGER} - ) - - - - insert into t_sys_quartz_job - - - - id, - - - - - job_name, - - - - - job_group, - - - - - invoke_target, - - - - - cron_expression, - - - - - misfire_policy, - - - - - concurrent, - - - - - status, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{jobName,jdbcType=VARCHAR}, - - - #{jobGroup,jdbcType=VARCHAR}, - - - #{invokeTarget,jdbcType=VARCHAR}, - - - #{cronExpression,jdbcType=VARCHAR}, - - - #{misfirePolicy,jdbcType=VARCHAR}, - - - #{concurrent,jdbcType=VARCHAR}, - - - #{status,jdbcType=INTEGER}, - - - - - - - - update t_sys_quartz_job - - - id = #{record.id,jdbcType=VARCHAR}, - - - job_name = #{record.jobName,jdbcType=VARCHAR}, - - - job_group = #{record.jobGroup,jdbcType=VARCHAR}, - - - invoke_target = #{record.invokeTarget,jdbcType=VARCHAR}, - - - cron_expression = #{record.cronExpression,jdbcType=VARCHAR}, - - - misfire_policy = #{record.misfirePolicy,jdbcType=VARCHAR}, - - - concurrent = #{record.concurrent,jdbcType=VARCHAR}, - - - status = #{record.status,jdbcType=INTEGER}, - - - - - - - - - - - update t_sys_quartz_job - set - id = #{record.id,jdbcType=VARCHAR}, - job_name = #{record.jobName,jdbcType=VARCHAR}, - job_group = #{record.jobGroup,jdbcType=VARCHAR}, - invoke_target = #{record.invokeTarget,jdbcType=VARCHAR}, - cron_expression = #{record.cronExpression,jdbcType=VARCHAR}, - misfire_policy = #{record.misfirePolicy,jdbcType=VARCHAR}, - concurrent = #{record.concurrent,jdbcType=VARCHAR}, - status = #{record.status,jdbcType=INTEGER} - - - - - - - - update t_sys_quartz_job - - - job_name = #{jobName,jdbcType=VARCHAR}, - - - job_group = #{jobGroup,jdbcType=VARCHAR}, - - - invoke_target = #{invokeTarget,jdbcType=VARCHAR}, - - - cron_expression = #{cronExpression,jdbcType=VARCHAR}, - - - misfire_policy = #{misfirePolicy,jdbcType=VARCHAR}, - - - concurrent = #{concurrent,jdbcType=VARCHAR}, - - - status = #{status,jdbcType=INTEGER}, - - - where id = #{id,jdbcType=VARCHAR} - - - - - - update t_sys_quartz_job - set - job_name = #{jobName,jdbcType=VARCHAR}, - job_group = #{jobGroup,jdbcType=VARCHAR}, - invoke_target = #{invokeTarget,jdbcType=VARCHAR}, - cron_expression = #{cronExpression,jdbcType=VARCHAR}, - misfire_policy = #{misfirePolicy,jdbcType=VARCHAR}, - concurrent = #{concurrent,jdbcType=VARCHAR}, - status = #{status,jdbcType=INTEGER} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/SysStreetMapper.xml b/src/main/resources/mybatis/auto/SysStreetMapper.xml deleted file mode 100644 index 7529785a598885e351722096fd6eff577c6d8927..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/SysStreetMapper.xml +++ /dev/null @@ -1,396 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - street_code, - area_code, - street_name, - short_name, - lng, - lat, - sort, - gmt_create, - gmt_modified, - memo, - data_state - - - - - - delete from t_sys_street - where id = #{id,jdbcType=INTEGER} - - - delete from t_sys_street - - - - - - - insert into t_sys_street ( - id, - street_code, - area_code, - street_name, - short_name, - lng, - lat, - sort, - gmt_create, - gmt_modified, - memo, - data_state - ) - values ( - #{id,jdbcType=INTEGER}, - #{streetCode,jdbcType=VARCHAR}, - #{areaCode,jdbcType=VARCHAR}, - #{streetName,jdbcType=VARCHAR}, - #{shortName,jdbcType=VARCHAR}, - #{lng,jdbcType=VARCHAR}, - #{lat,jdbcType=VARCHAR}, - #{sort,jdbcType=INTEGER}, - #{gmtCreate,jdbcType=TIMESTAMP}, - #{gmtModified,jdbcType=TIMESTAMP}, - #{memo,jdbcType=VARCHAR}, - #{dataState,jdbcType=INTEGER} - ) - - - - insert into t_sys_street - - - - id, - - - - - street_code, - - - - - area_code, - - - - - street_name, - - - - - short_name, - - - - - lng, - - - - - lat, - - - - - sort, - - - - - gmt_create, - - - - - gmt_modified, - - - - - memo, - - - - - data_state, - - - - - - #{id,jdbcType=INTEGER}, - - - #{streetCode,jdbcType=VARCHAR}, - - - #{areaCode,jdbcType=VARCHAR}, - - - #{streetName,jdbcType=VARCHAR}, - - - #{shortName,jdbcType=VARCHAR}, - - - #{lng,jdbcType=VARCHAR}, - - - #{lat,jdbcType=VARCHAR}, - - - #{sort,jdbcType=INTEGER}, - - - #{gmtCreate,jdbcType=TIMESTAMP}, - - - #{gmtModified,jdbcType=TIMESTAMP}, - - - #{memo,jdbcType=VARCHAR}, - - - #{dataState,jdbcType=INTEGER}, - - - - - - - - update t_sys_street - - - id = #{record.id,jdbcType=INTEGER}, - - - street_code = #{record.streetCode,jdbcType=VARCHAR}, - - - area_code = #{record.areaCode,jdbcType=VARCHAR}, - - - street_name = #{record.streetName,jdbcType=VARCHAR}, - - - short_name = #{record.shortName,jdbcType=VARCHAR}, - - - lng = #{record.lng,jdbcType=VARCHAR}, - - - lat = #{record.lat,jdbcType=VARCHAR}, - - - sort = #{record.sort,jdbcType=INTEGER}, - - - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{record.memo,jdbcType=VARCHAR}, - - - data_state = #{record.dataState,jdbcType=INTEGER}, - - - - - - - - - - - update t_sys_street - set - id = #{record.id,jdbcType=INTEGER}, - street_code = #{record.streetCode,jdbcType=VARCHAR}, - area_code = #{record.areaCode,jdbcType=VARCHAR}, - street_name = #{record.streetName,jdbcType=VARCHAR}, - short_name = #{record.shortName,jdbcType=VARCHAR}, - lng = #{record.lng,jdbcType=VARCHAR}, - lat = #{record.lat,jdbcType=VARCHAR}, - sort = #{record.sort,jdbcType=INTEGER}, - gmt_create = #{record.gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{record.gmtModified,jdbcType=TIMESTAMP}, - memo = #{record.memo,jdbcType=VARCHAR}, - data_state = #{record.dataState,jdbcType=INTEGER} - - - - - - - - update t_sys_street - - - street_code = #{streetCode,jdbcType=VARCHAR}, - - - area_code = #{areaCode,jdbcType=VARCHAR}, - - - street_name = #{streetName,jdbcType=VARCHAR}, - - - short_name = #{shortName,jdbcType=VARCHAR}, - - - lng = #{lng,jdbcType=VARCHAR}, - - - lat = #{lat,jdbcType=VARCHAR}, - - - sort = #{sort,jdbcType=INTEGER}, - - - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - - - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - - - memo = #{memo,jdbcType=VARCHAR}, - - - data_state = #{dataState,jdbcType=INTEGER}, - - - where - id = #{id,jdbcType=INTEGER} - - - - - - - update t_sys_street - set - street_code = #{streetCode,jdbcType=VARCHAR}, - area_code = #{areaCode,jdbcType=VARCHAR}, - street_name = #{streetName,jdbcType=VARCHAR}, - short_name = #{shortName,jdbcType=VARCHAR}, - lng = #{lng,jdbcType=VARCHAR}, - lat = #{lat,jdbcType=VARCHAR}, - sort = #{sort,jdbcType=INTEGER}, - gmt_create = #{gmtCreate,jdbcType=TIMESTAMP}, - gmt_modified = #{gmtModified,jdbcType=TIMESTAMP}, - memo = #{memo,jdbcType=VARCHAR}, - data_state = #{dataState,jdbcType=INTEGER} - where - id = #{id,jdbcType=INTEGER} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TSysDictDataMapper.xml b/src/main/resources/mybatis/auto/TSysDictDataMapper.xml deleted file mode 100644 index b336c0553a61232023312d98909c0f2603bd2a19..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TSysDictDataMapper.xml +++ /dev/null @@ -1,437 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - dict_sort, - dict_label, - dict_value, - dict_type, - css_class, - list_class, - is_default, - status, - create_by, - create_time, - update_by, - update_time, - remark - - - - - - delete from t_sys_dict_data - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_dict_data - - - - - - - insert into t_sys_dict_data ( - id, - dict_sort, - dict_label, - dict_value, - dict_type, - css_class, - list_class, - is_default, - status, - create_by, - create_time, - update_by, - update_time, - remark - ) - values ( - #{id,jdbcType=VARCHAR}, - #{dictSort,jdbcType=INTEGER}, - #{dictLabel,jdbcType=VARCHAR}, - #{dictValue,jdbcType=VARCHAR}, - #{dictType,jdbcType=VARCHAR}, - #{cssClass,jdbcType=VARCHAR}, - #{listClass,jdbcType=VARCHAR}, - #{isDefault,jdbcType=CHAR}, - #{status,jdbcType=CHAR}, - #{createBy,jdbcType=VARCHAR}, - #{createTime,jdbcType=TIMESTAMP}, - #{updateBy,jdbcType=VARCHAR}, - #{updateTime,jdbcType=TIMESTAMP}, - #{remark,jdbcType=VARCHAR} - ) - - - - insert into t_sys_dict_data - - - - id, - - - - - dict_sort, - - - - - dict_label, - - - - - dict_value, - - - - - dict_type, - - - - - css_class, - - - - - list_class, - - - - - is_default, - - - - - status, - - - - - create_by, - - - - - create_time, - - - - - update_by, - - - - - update_time, - - - - - remark, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{dictSort,jdbcType=INTEGER}, - - - #{dictLabel,jdbcType=VARCHAR}, - - - #{dictValue,jdbcType=VARCHAR}, - - - #{dictType,jdbcType=VARCHAR}, - - - #{cssClass,jdbcType=VARCHAR}, - - - #{listClass,jdbcType=VARCHAR}, - - - #{isDefault,jdbcType=CHAR}, - - - #{status,jdbcType=CHAR}, - - - #{createBy,jdbcType=VARCHAR}, - - - #{createTime,jdbcType=TIMESTAMP}, - - - #{updateBy,jdbcType=VARCHAR}, - - - #{updateTime,jdbcType=TIMESTAMP}, - - - #{remark,jdbcType=VARCHAR}, - - - - - - - - update t_sys_dict_data - - - id = #{record.id,jdbcType=VARCHAR}, - - - dict_sort = #{record.dictSort,jdbcType=INTEGER}, - - - dict_label = #{record.dictLabel,jdbcType=VARCHAR}, - - - dict_value = #{record.dictValue,jdbcType=VARCHAR}, - - - dict_type = #{record.dictType,jdbcType=VARCHAR}, - - - css_class = #{record.cssClass,jdbcType=VARCHAR}, - - - list_class = #{record.listClass,jdbcType=VARCHAR}, - - - is_default = #{record.isDefault,jdbcType=CHAR}, - - - status = #{record.status,jdbcType=CHAR}, - - - create_by = #{record.createBy,jdbcType=VARCHAR}, - - - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - - - update_by = #{record.updateBy,jdbcType=VARCHAR}, - - - update_time = #{record.updateTime,jdbcType=TIMESTAMP}, - - - remark = #{record.remark,jdbcType=VARCHAR}, - - - - - - - - - - - update t_sys_dict_data - set - id = #{record.id,jdbcType=VARCHAR}, - dict_sort = #{record.dictSort,jdbcType=INTEGER}, - dict_label = #{record.dictLabel,jdbcType=VARCHAR}, - dict_value = #{record.dictValue,jdbcType=VARCHAR}, - dict_type = #{record.dictType,jdbcType=VARCHAR}, - css_class = #{record.cssClass,jdbcType=VARCHAR}, - list_class = #{record.listClass,jdbcType=VARCHAR}, - is_default = #{record.isDefault,jdbcType=CHAR}, - status = #{record.status,jdbcType=CHAR}, - create_by = #{record.createBy,jdbcType=VARCHAR}, - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - update_by = #{record.updateBy,jdbcType=VARCHAR}, - update_time = #{record.updateTime,jdbcType=TIMESTAMP}, - remark = #{record.remark,jdbcType=VARCHAR} - - - - - - - - update t_sys_dict_data - - - - dict_sort = #{dictSort,jdbcType=INTEGER}, - - - dict_label = #{dictLabel,jdbcType=VARCHAR}, - - - dict_value = #{dictValue,jdbcType=VARCHAR}, - - - dict_type = #{dictType,jdbcType=VARCHAR}, - - - css_class = #{cssClass,jdbcType=VARCHAR}, - - - list_class = #{listClass,jdbcType=VARCHAR}, - - - is_default = #{isDefault,jdbcType=CHAR}, - - - status = #{status,jdbcType=CHAR}, - - - create_by = #{createBy,jdbcType=VARCHAR}, - - - create_time = #{createTime,jdbcType=TIMESTAMP}, - - - update_by = #{updateBy,jdbcType=VARCHAR}, - - - update_time = #{updateTime,jdbcType=TIMESTAMP}, - - - remark = #{remark,jdbcType=VARCHAR}, - - - where - id = #{id,jdbcType=VARCHAR} - - - - - - - update t_sys_dict_data - set - dict_sort = #{dictSort,jdbcType=INTEGER}, - dict_label = #{dictLabel,jdbcType=VARCHAR}, - dict_value = #{dictValue,jdbcType=VARCHAR}, - dict_type = #{dictType,jdbcType=VARCHAR}, - css_class = #{cssClass,jdbcType=VARCHAR}, - list_class = #{listClass,jdbcType=VARCHAR}, - is_default = #{isDefault,jdbcType=CHAR}, - status = #{status,jdbcType=CHAR}, - create_by = #{createBy,jdbcType=VARCHAR}, - create_time = #{createTime,jdbcType=TIMESTAMP}, - update_by = #{updateBy,jdbcType=VARCHAR}, - update_time = #{updateTime,jdbcType=TIMESTAMP}, - remark = #{remark,jdbcType=VARCHAR} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TSysDictTypeMapper.xml b/src/main/resources/mybatis/auto/TSysDictTypeMapper.xml deleted file mode 100644 index d8a44023e1b22d04e5c88e6a04c27ca02ed94fe7..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TSysDictTypeMapper.xml +++ /dev/null @@ -1,336 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, - dict_name, - dict_type, - status, - create_by, - create_time, - update_by, - update_time, - remark - - - - - - delete from t_sys_dict_type - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_dict_type - - - - - - - insert into t_sys_dict_type ( - id, - dict_name, - dict_type, - status, - create_by, - create_time, - update_by, - update_time, - remark - ) - values ( - #{id,jdbcType=VARCHAR}, - #{dictName,jdbcType=VARCHAR}, - #{dictType,jdbcType=VARCHAR}, - #{status,jdbcType=CHAR}, - #{createBy,jdbcType=VARCHAR}, - #{createTime,jdbcType=TIMESTAMP}, - #{updateBy,jdbcType=VARCHAR}, - #{updateTime,jdbcType=TIMESTAMP}, - #{remark,jdbcType=VARCHAR} - ) - - - - insert into t_sys_dict_type - - - - id, - - - - - dict_name, - - - - - dict_type, - - - - - status, - - - - - create_by, - - - - - create_time, - - - - - update_by, - - - - - update_time, - - - - - remark, - - - - - - #{id,jdbcType=VARCHAR}, - - - #{dictName,jdbcType=VARCHAR}, - - - #{dictType,jdbcType=VARCHAR}, - - - #{status,jdbcType=CHAR}, - - - #{createBy,jdbcType=VARCHAR}, - - - #{createTime,jdbcType=TIMESTAMP}, - - - #{updateBy,jdbcType=VARCHAR}, - - - #{updateTime,jdbcType=TIMESTAMP}, - - - #{remark,jdbcType=VARCHAR}, - - - - - - - - update t_sys_dict_type - - - id = #{record.id,jdbcType=VARCHAR}, - - - dict_name = #{record.dictName,jdbcType=VARCHAR}, - - - dict_type = #{record.dictType,jdbcType=VARCHAR}, - - - status = #{record.status,jdbcType=CHAR}, - - - create_by = #{record.createBy,jdbcType=VARCHAR}, - - - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - - - update_by = #{record.updateBy,jdbcType=VARCHAR}, - - - update_time = #{record.updateTime,jdbcType=TIMESTAMP}, - - - remark = #{record.remark,jdbcType=VARCHAR}, - - - - - - - - - - - update t_sys_dict_type - set - id = #{record.id,jdbcType=VARCHAR}, - dict_name = #{record.dictName,jdbcType=VARCHAR}, - dict_type = #{record.dictType,jdbcType=VARCHAR}, - status = #{record.status,jdbcType=CHAR}, - create_by = #{record.createBy,jdbcType=VARCHAR}, - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - update_by = #{record.updateBy,jdbcType=VARCHAR}, - update_time = #{record.updateTime,jdbcType=TIMESTAMP}, - remark = #{record.remark,jdbcType=VARCHAR} - - - - - - - - update t_sys_dict_type - - - dict_name = #{dictName,jdbcType=VARCHAR}, - - - dict_type = #{dictType,jdbcType=VARCHAR}, - - - status = #{status,jdbcType=CHAR}, - - - create_by = #{createBy,jdbcType=VARCHAR}, - - - create_time = #{createTime,jdbcType=TIMESTAMP}, - - - update_by = #{updateBy,jdbcType=VARCHAR}, - - - update_time = #{updateTime,jdbcType=TIMESTAMP}, - - - remark = #{remark,jdbcType=VARCHAR}, - - - where - id = #{id,jdbcType=VARCHAR} - - - - - - - update t_sys_dict_type - set - dict_name = #{dictName,jdbcType=VARCHAR}, - dict_type = #{dictType,jdbcType=VARCHAR}, - status = #{status,jdbcType=CHAR}, - create_by = #{createBy,jdbcType=VARCHAR}, - create_time = #{createTime,jdbcType=TIMESTAMP}, - update_by = #{updateBy,jdbcType=VARCHAR}, - update_time = #{updateTime,jdbcType=TIMESTAMP}, - remark = #{remark,jdbcType=VARCHAR} - where - id = #{id,jdbcType=VARCHAR} - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TSysEmailMapper.xml b/src/main/resources/mybatis/auto/TSysEmailMapper.xml deleted file mode 100644 index 09dea76ef1ce4276d56920a2802586e0f13bb9ac..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TSysEmailMapper.xml +++ /dev/null @@ -1,245 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, receivers_email, title, content, send_user_id, send_user_name, create_time - - - - - delete from t_sys_email - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_email - - - - - - insert into t_sys_email (id, receivers_email, title, - content, send_user_id, send_user_name, - create_time) - values (#{id,jdbcType=VARCHAR}, #{receiversEmail,jdbcType=VARCHAR}, #{title,jdbcType=VARCHAR}, - #{content,jdbcType=VARCHAR}, #{sendUserId,jdbcType=VARCHAR}, #{sendUserName,jdbcType=VARCHAR}, - #{createTime,jdbcType=TIMESTAMP}) - - - insert into t_sys_email - - - id, - - - receivers_email, - - - title, - - - content, - - - send_user_id, - - - send_user_name, - - - create_time, - - - - - #{id,jdbcType=VARCHAR}, - - - #{receiversEmail,jdbcType=VARCHAR}, - - - #{title,jdbcType=VARCHAR}, - - - #{content,jdbcType=VARCHAR}, - - - #{sendUserId,jdbcType=VARCHAR}, - - - #{sendUserName,jdbcType=VARCHAR}, - - - #{createTime,jdbcType=TIMESTAMP}, - - - - - - update t_sys_email - - - id = #{record.id,jdbcType=VARCHAR}, - - - receivers_email = #{record.receiversEmail,jdbcType=VARCHAR}, - - - title = #{record.title,jdbcType=VARCHAR}, - - - content = #{record.content,jdbcType=VARCHAR}, - - - send_user_id = #{record.sendUserId,jdbcType=VARCHAR}, - - - send_user_name = #{record.sendUserName,jdbcType=VARCHAR}, - - - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - - - - - - - - update t_sys_email - set id = #{record.id,jdbcType=VARCHAR}, - receivers_email = #{record.receiversEmail,jdbcType=VARCHAR}, - title = #{record.title,jdbcType=VARCHAR}, - content = #{record.content,jdbcType=VARCHAR}, - send_user_id = #{record.sendUserId,jdbcType=VARCHAR}, - send_user_name = #{record.sendUserName,jdbcType=VARCHAR}, - create_time = #{record.createTime,jdbcType=TIMESTAMP} - - - - - - update t_sys_email - - - receivers_email = #{receiversEmail,jdbcType=VARCHAR}, - - - title = #{title,jdbcType=VARCHAR}, - - - content = #{content,jdbcType=VARCHAR}, - - - send_user_id = #{sendUserId,jdbcType=VARCHAR}, - - - send_user_name = #{sendUserName,jdbcType=VARCHAR}, - - - create_time = #{createTime,jdbcType=TIMESTAMP}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_email - set receivers_email = #{receiversEmail,jdbcType=VARCHAR}, - title = #{title,jdbcType=VARCHAR}, - content = #{content,jdbcType=VARCHAR}, - send_user_id = #{sendUserId,jdbcType=VARCHAR}, - send_user_name = #{sendUserName,jdbcType=VARCHAR}, - create_time = #{createTime,jdbcType=TIMESTAMP} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TSysRoleUserMapper.xml b/src/main/resources/mybatis/auto/TSysRoleUserMapper.xml deleted file mode 100644 index f42e547c23f5c7397ebb5aabe7687d8913cf8dd1..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TSysRoleUserMapper.xml +++ /dev/null @@ -1,181 +0,0 @@ - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, sys_user_id, sys_role_id - - - - - delete from t_sys_role_user - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_role_user - - - - - - insert into t_sys_role_user (id, sys_user_id, sys_role_id - ) - values (#{id,jdbcType=VARCHAR}, #{sysUserId,jdbcType=VARCHAR}, #{sysRoleId,jdbcType=VARCHAR} - ) - - - insert into t_sys_role_user - - - id, - - - sys_user_id, - - - sys_role_id, - - - - - #{id,jdbcType=VARCHAR}, - - - #{sysUserId,jdbcType=VARCHAR}, - - - #{sysRoleId,jdbcType=VARCHAR}, - - - - - - update t_sys_role_user - - - id = #{record.id,jdbcType=VARCHAR}, - - - sys_user_id = #{record.sysUserId,jdbcType=VARCHAR}, - - - sys_role_id = #{record.sysRoleId,jdbcType=VARCHAR}, - - - - - - - - update t_sys_role_user - set id = #{record.id,jdbcType=VARCHAR}, - sys_user_id = #{record.sysUserId,jdbcType=VARCHAR}, - sys_role_id = #{record.sysRoleId,jdbcType=VARCHAR} - - - - - - update t_sys_role_user - - - sys_user_id = #{sysUserId,jdbcType=VARCHAR}, - - - sys_role_id = #{sysRoleId,jdbcType=VARCHAR}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_role_user - set sys_user_id = #{sysUserId,jdbcType=VARCHAR}, - sys_role_id = #{sysRoleId,jdbcType=VARCHAR} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysDatasMapper.xml b/src/main/resources/mybatis/auto/TsysDatasMapper.xml deleted file mode 100644 index b813c658a2e63f2fbdee784b940569467611a064..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysDatasMapper.xml +++ /dev/null @@ -1,179 +0,0 @@ - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, file_path, file_suffix - - - - - delete from t_sys_datas - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_datas - - - - - - insert into t_sys_datas (id, file_path, file_suffix) - values (#{id,jdbcType=VARCHAR}, #{filePath,jdbcType=VARCHAR}, #{fileSuffix,jdbcType=VARCHAR}) - - - insert into t_sys_datas - - - id, - - - file_path, - - - file_suffix, - - - - - #{id,jdbcType=VARCHAR}, - - - #{filePath,jdbcType=VARCHAR}, - - - #{fileSuffix,jdbcType=VARCHAR}, - - - - - - update t_sys_datas - - - id = #{record.id,jdbcType=VARCHAR}, - - - file_path = #{record.filePath,jdbcType=VARCHAR}, - - - file_suffix = #{record.fileSuffix,jdbcType=VARCHAR}, - - - - - - - - update t_sys_datas - set id = #{record.id,jdbcType=VARCHAR}, - file_path = #{record.filePath,jdbcType=VARCHAR}, - file_suffix = #{record.fileSuffix,jdbcType=VARCHAR} - - - - - - update t_sys_datas - - - file_path = #{filePath,jdbcType=VARCHAR}, - - - file_suffix = #{fileSuffix,jdbcType=VARCHAR}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_datas - set file_path = #{filePath,jdbcType=VARCHAR}, - file_suffix = #{fileSuffix,jdbcType=VARCHAR} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysFileDataMapper.xml b/src/main/resources/mybatis/auto/TsysFileDataMapper.xml deleted file mode 100644 index 26bdb78d2d1ff3fd472b109ac4ed8d2dc29813ab..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysFileDataMapper.xml +++ /dev/null @@ -1,181 +0,0 @@ - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, data_id, file_id - - - - - delete from t_sys_file_data - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_file_data - - - - - - insert into t_sys_file_data (id, data_id, file_id - ) - values (#{id,jdbcType=VARCHAR}, #{dataId,jdbcType=VARCHAR}, #{fileId,jdbcType=VARCHAR} - ) - - - insert into t_sys_file_data - - - id, - - - data_id, - - - file_id, - - - - - #{id,jdbcType=VARCHAR}, - - - #{dataId,jdbcType=VARCHAR}, - - - #{fileId,jdbcType=VARCHAR}, - - - - - - update t_sys_file_data - - - id = #{record.id,jdbcType=VARCHAR}, - - - data_id = #{record.dataId,jdbcType=VARCHAR}, - - - file_id = #{record.fileId,jdbcType=VARCHAR}, - - - - - - - - update t_sys_file_data - set id = #{record.id,jdbcType=VARCHAR}, - data_id = #{record.dataId,jdbcType=VARCHAR}, - file_id = #{record.fileId,jdbcType=VARCHAR} - - - - - - update t_sys_file_data - - - data_id = #{dataId,jdbcType=VARCHAR}, - - - file_id = #{fileId,jdbcType=VARCHAR}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_file_data - set data_id = #{dataId,jdbcType=VARCHAR}, - file_id = #{fileId,jdbcType=VARCHAR} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysFileMapper.xml b/src/main/resources/mybatis/auto/TsysFileMapper.xml deleted file mode 100644 index 65616b52f4ee8026e16af8ac29f29b9f319d176c..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysFileMapper.xml +++ /dev/null @@ -1,259 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, file_name, create_user_id, create_user_name, create_time, update_user_id, update_user_name, - update_time - - - - - delete from t_sys_file - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_file - - - - - - insert into t_sys_file (id, file_name, create_user_id, - create_user_name, create_time, update_user_id, - update_user_name, update_time) - values (#{id,jdbcType=VARCHAR}, #{fileName,jdbcType=VARCHAR}, #{createUserId,jdbcType=VARCHAR}, - #{createUserName,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateUserId,jdbcType=VARCHAR}, - #{updateUserName,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}) - - - insert into t_sys_file - - - id, - - - file_name, - - - create_user_id, - - - create_user_name, - - - create_time, - - - update_user_id, - - - update_user_name, - - - update_time, - - - - - #{id,jdbcType=VARCHAR}, - - - #{fileName,jdbcType=VARCHAR}, - - - #{createUserId,jdbcType=VARCHAR}, - - - #{createUserName,jdbcType=VARCHAR}, - - - #{createTime,jdbcType=TIMESTAMP}, - - - #{updateUserId,jdbcType=VARCHAR}, - - - #{updateUserName,jdbcType=VARCHAR}, - - - #{updateTime,jdbcType=TIMESTAMP}, - - - - - - update t_sys_file - - - id = #{record.id,jdbcType=VARCHAR}, - - - file_name = #{record.fileName,jdbcType=VARCHAR}, - - - create_user_id = #{record.createUserId,jdbcType=VARCHAR}, - - - create_user_name = #{record.createUserName,jdbcType=VARCHAR}, - - - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - - - update_user_id = #{record.updateUserId,jdbcType=VARCHAR}, - - - update_user_name = #{record.updateUserName,jdbcType=VARCHAR}, - - - update_time = #{record.updateTime,jdbcType=TIMESTAMP}, - - - - - - - - update t_sys_file - set id = #{record.id,jdbcType=VARCHAR}, - file_name = #{record.fileName,jdbcType=VARCHAR}, - create_user_id = #{record.createUserId,jdbcType=VARCHAR}, - create_user_name = #{record.createUserName,jdbcType=VARCHAR}, - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - update_user_id = #{record.updateUserId,jdbcType=VARCHAR}, - update_user_name = #{record.updateUserName,jdbcType=VARCHAR}, - update_time = #{record.updateTime,jdbcType=TIMESTAMP} - - - - - - update t_sys_file - - - file_name = #{fileName,jdbcType=VARCHAR}, - - - create_user_id = #{createUserId,jdbcType=VARCHAR}, - - - create_user_name = #{createUserName,jdbcType=VARCHAR}, - - - create_time = #{createTime,jdbcType=TIMESTAMP}, - - - update_user_id = #{updateUserId,jdbcType=VARCHAR}, - - - update_user_name = #{updateUserName,jdbcType=VARCHAR}, - - - update_time = #{updateTime,jdbcType=TIMESTAMP}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_file - set file_name = #{fileName,jdbcType=VARCHAR}, - create_user_id = #{createUserId,jdbcType=VARCHAR}, - create_user_name = #{createUserName,jdbcType=VARCHAR}, - create_time = #{createTime,jdbcType=TIMESTAMP}, - update_user_id = #{updateUserId,jdbcType=VARCHAR}, - update_user_name = #{updateUserName,jdbcType=VARCHAR}, - update_time = #{updateTime,jdbcType=TIMESTAMP} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysOperLogMapper.xml b/src/main/resources/mybatis/auto/TsysOperLogMapper.xml deleted file mode 100644 index 096583976ae6aa7a0bdb47cf4526693fe824ddf5..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysOperLogMapper.xml +++ /dev/null @@ -1,258 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, title, method, oper_name, oper_url, oper_param, error_msg, oper_time - - - - - delete from t_sys_oper_log - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_oper_log - - - - - - insert into t_sys_oper_log (id, title, method, - oper_name, oper_url, oper_param, - error_msg, oper_time) - values (#{id,jdbcType=VARCHAR}, #{title,jdbcType=VARCHAR}, #{method,jdbcType=VARCHAR}, - #{operName,jdbcType=VARCHAR}, #{operUrl,jdbcType=VARCHAR}, #{operParam,jdbcType=VARCHAR}, - #{errorMsg,jdbcType=VARCHAR}, #{operTime,jdbcType=DATE}) - - - insert into t_sys_oper_log - - - id, - - - title, - - - method, - - - oper_name, - - - oper_url, - - - oper_param, - - - error_msg, - - - oper_time, - - - - - #{id,jdbcType=VARCHAR}, - - - #{title,jdbcType=VARCHAR}, - - - #{method,jdbcType=VARCHAR}, - - - #{operName,jdbcType=VARCHAR}, - - - #{operUrl,jdbcType=VARCHAR}, - - - #{operParam,jdbcType=VARCHAR}, - - - #{errorMsg,jdbcType=VARCHAR}, - - - #{operTime,jdbcType=DATE}, - - - - - - update t_sys_oper_log - - - id = #{record.id,jdbcType=VARCHAR}, - - - title = #{record.title,jdbcType=VARCHAR}, - - - method = #{record.method,jdbcType=VARCHAR}, - - - oper_name = #{record.operName,jdbcType=VARCHAR}, - - - oper_url = #{record.operUrl,jdbcType=VARCHAR}, - - - oper_param = #{record.operParam,jdbcType=VARCHAR}, - - - error_msg = #{record.errorMsg,jdbcType=VARCHAR}, - - - oper_time = #{record.operTime,jdbcType=DATE}, - - - - - - - - update t_sys_oper_log - set id = #{record.id,jdbcType=VARCHAR}, - title = #{record.title,jdbcType=VARCHAR}, - method = #{record.method,jdbcType=VARCHAR}, - oper_name = #{record.operName,jdbcType=VARCHAR}, - oper_url = #{record.operUrl,jdbcType=VARCHAR}, - oper_param = #{record.operParam,jdbcType=VARCHAR}, - error_msg = #{record.errorMsg,jdbcType=VARCHAR}, - oper_time = #{record.operTime,jdbcType=DATE} - - - - - - update t_sys_oper_log - - - title = #{title,jdbcType=VARCHAR}, - - - method = #{method,jdbcType=VARCHAR}, - - - oper_name = #{operName,jdbcType=VARCHAR}, - - - oper_url = #{operUrl,jdbcType=VARCHAR}, - - - oper_param = #{operParam,jdbcType=VARCHAR}, - - - error_msg = #{errorMsg,jdbcType=VARCHAR}, - - - oper_time = #{operTime,jdbcType=DATE}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_oper_log - set title = #{title,jdbcType=VARCHAR}, - method = #{method,jdbcType=VARCHAR}, - oper_name = #{operName,jdbcType=VARCHAR}, - oper_url = #{operUrl,jdbcType=VARCHAR}, - oper_param = #{operParam,jdbcType=VARCHAR}, - error_msg = #{errorMsg,jdbcType=VARCHAR}, - oper_time = #{operTime,jdbcType=DATE} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysPermissionRoleMapper.xml b/src/main/resources/mybatis/auto/TsysPermissionRoleMapper.xml deleted file mode 100644 index 683684630b1cf5c6e113a29b98f568659f4e8020..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysPermissionRoleMapper.xml +++ /dev/null @@ -1,181 +0,0 @@ - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, role_id, permission_id - - - - - delete from t_sys_permission_role - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_permission_role - - - - - - insert into t_sys_permission_role (id, role_id, permission_id - ) - values (#{id,jdbcType=VARCHAR}, #{roleId,jdbcType=VARCHAR}, #{permissionId,jdbcType=VARCHAR} - ) - - - insert into t_sys_permission_role - - - id, - - - role_id, - - - permission_id, - - - - - #{id,jdbcType=VARCHAR}, - - - #{roleId,jdbcType=VARCHAR}, - - - #{permissionId,jdbcType=VARCHAR}, - - - - - - update t_sys_permission_role - - - id = #{record.id,jdbcType=VARCHAR}, - - - role_id = #{record.roleId,jdbcType=VARCHAR}, - - - permission_id = #{record.permissionId,jdbcType=VARCHAR}, - - - - - - - - update t_sys_permission_role - set id = #{record.id,jdbcType=VARCHAR}, - role_id = #{record.roleId,jdbcType=VARCHAR}, - permission_id = #{record.permissionId,jdbcType=VARCHAR} - - - - - - update t_sys_permission_role - - - role_id = #{roleId,jdbcType=VARCHAR}, - - - permission_id = #{permissionId,jdbcType=VARCHAR}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_permission_role - set role_id = #{roleId,jdbcType=VARCHAR}, - permission_id = #{permissionId,jdbcType=VARCHAR} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysPremissionMapper.xml b/src/main/resources/mybatis/auto/TsysPremissionMapper.xml deleted file mode 100644 index 1b484914342bb867bcf46c7961b1143bd1027471..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysPremissionMapper.xml +++ /dev/null @@ -1,308 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, name, descripion, url, is_blank, pid, perms, type, icon, order_num, visible, (select count(1) from t_sys_permission where pid=a.id) childcount - - - - - delete from t_sys_permission - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_permission - - - - - - insert into t_sys_permission (id, name, descripion, - url, is_blank, pid, - perms, type, icon, - order_num, visible) - values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{descripion,jdbcType=VARCHAR}, - #{url,jdbcType=VARCHAR}, #{isBlank,jdbcType=INTEGER}, #{pid,jdbcType=VARCHAR}, - #{perms,jdbcType=VARCHAR}, #{type,jdbcType=INTEGER}, #{icon,jdbcType=VARCHAR}, - #{orderNum,jdbcType=INTEGER}, #{visible,jdbcType=INTEGER}) - - - insert into t_sys_permission - - - id, - - - name, - - - descripion, - - - url, - - - is_blank, - - - pid, - - - perms, - - - type, - - - icon, - - - order_num, - - - visible, - - - - - #{id,jdbcType=VARCHAR}, - - - #{name,jdbcType=VARCHAR}, - - - #{descripion,jdbcType=VARCHAR}, - - - #{url,jdbcType=VARCHAR}, - - - #{isBlank,jdbcType=INTEGER}, - - - #{pid,jdbcType=VARCHAR}, - - - #{perms,jdbcType=VARCHAR}, - - - #{type,jdbcType=INTEGER}, - - - #{icon,jdbcType=VARCHAR}, - - - #{orderNum,jdbcType=INTEGER}, - - - #{visible,jdbcType=INTEGER}, - - - - - - update t_sys_permission - - - id = #{record.id,jdbcType=VARCHAR}, - - - name = #{record.name,jdbcType=VARCHAR}, - - - descripion = #{record.descripion,jdbcType=VARCHAR}, - - - url = #{record.url,jdbcType=VARCHAR}, - - - is_blank = #{record.isBlank,jdbcType=INTEGER}, - - - pid = #{record.pid,jdbcType=VARCHAR}, - - - perms = #{record.perms,jdbcType=VARCHAR}, - - - type = #{record.type,jdbcType=INTEGER}, - - - icon = #{record.icon,jdbcType=VARCHAR}, - - - order_num = #{record.orderNum,jdbcType=INTEGER}, - - - visible = #{record.visible,jdbcType=INTEGER}, - - - - - - - - update t_sys_permission - set id = #{record.id,jdbcType=VARCHAR}, - name = #{record.name,jdbcType=VARCHAR}, - descripion = #{record.descripion,jdbcType=VARCHAR}, - url = #{record.url,jdbcType=VARCHAR}, - is_blank = #{record.isBlank,jdbcType=INTEGER}, - pid = #{record.pid,jdbcType=VARCHAR}, - perms = #{record.perms,jdbcType=VARCHAR}, - type = #{record.type,jdbcType=INTEGER}, - icon = #{record.icon,jdbcType=VARCHAR}, - order_num = #{record.orderNum,jdbcType=INTEGER}, - visible = #{record.visible,jdbcType=INTEGER} - - - - - - update t_sys_permission - - - name = #{name,jdbcType=VARCHAR}, - - - descripion = #{descripion,jdbcType=VARCHAR}, - - - url = #{url,jdbcType=VARCHAR}, - - - is_blank = #{isBlank,jdbcType=INTEGER}, - - - pid = #{pid,jdbcType=VARCHAR}, - - - perms = #{perms,jdbcType=VARCHAR}, - - - type = #{type,jdbcType=INTEGER}, - - - icon = #{icon,jdbcType=VARCHAR}, - - - order_num = #{orderNum,jdbcType=INTEGER}, - - - visible = #{visible,jdbcType=INTEGER}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_permission - set name = #{name,jdbcType=VARCHAR}, - descripion = #{descripion,jdbcType=VARCHAR}, - url = #{url,jdbcType=VARCHAR}, - is_blank = #{isBlank,jdbcType=INTEGER}, - pid = #{pid,jdbcType=VARCHAR}, - perms = #{perms,jdbcType=VARCHAR}, - type = #{type,jdbcType=INTEGER}, - icon = #{icon,jdbcType=VARCHAR}, - order_num = #{orderNum,jdbcType=INTEGER}, - visible = #{visible,jdbcType=INTEGER} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysRoleMapper.xml b/src/main/resources/mybatis/auto/TsysRoleMapper.xml deleted file mode 100644 index 853d160b366bccb3878c6923d4a15fd61fa50992..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysRoleMapper.xml +++ /dev/null @@ -1,164 +0,0 @@ - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, name - - - - - delete from t_sys_role - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_role - - - - - - insert into t_sys_role (id, name) - values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}) - - - insert into t_sys_role - - - id, - - - name, - - - - - #{id,jdbcType=VARCHAR}, - - - #{name,jdbcType=VARCHAR}, - - - - - - update t_sys_role - - - id = #{record.id,jdbcType=VARCHAR}, - - - name = #{record.name,jdbcType=VARCHAR}, - - - - - - - - update t_sys_role - set id = #{record.id,jdbcType=VARCHAR}, - name = #{record.name,jdbcType=VARCHAR} - - - - - - update t_sys_role - - - name = #{name,jdbcType=VARCHAR}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_role - set name = #{name,jdbcType=VARCHAR} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/auto/TsysUserMapper.xml b/src/main/resources/mybatis/auto/TsysUserMapper.xml deleted file mode 100644 index c4f6299d8a9773e4cb30e3c90e74ce78952148df..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/auto/TsysUserMapper.xml +++ /dev/null @@ -1,198 +0,0 @@ - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - - - - - - - - - id, username, password, nickname - - - - - delete from t_sys_user - where id = #{id,jdbcType=VARCHAR} - - - delete from t_sys_user - - - - - - insert into t_sys_user (id, username, password, - nickname) - values (#{id,jdbcType=VARCHAR}, #{username,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR}, - #{nickname,jdbcType=VARCHAR}) - - - insert into t_sys_user - - - id, - - - username, - - - password, - - - nickname, - - - - - #{id,jdbcType=VARCHAR}, - - - #{username,jdbcType=VARCHAR}, - - - #{password,jdbcType=VARCHAR}, - - - #{nickname,jdbcType=VARCHAR}, - - - - - - update t_sys_user - - - id = #{record.id,jdbcType=VARCHAR}, - - - username = #{record.username,jdbcType=VARCHAR}, - - - password = #{record.password,jdbcType=VARCHAR}, - - - nickname = #{record.nickname,jdbcType=VARCHAR}, - - - - - - - - update t_sys_user - set id = #{record.id,jdbcType=VARCHAR}, - username = #{record.username,jdbcType=VARCHAR}, - password = #{record.password,jdbcType=VARCHAR}, - nickname = #{record.nickname,jdbcType=VARCHAR} - - - - - - update t_sys_user - - - username = #{username,jdbcType=VARCHAR}, - - - password = #{password,jdbcType=VARCHAR}, - - - nickname = #{nickname,jdbcType=VARCHAR}, - - - where id = #{id,jdbcType=VARCHAR} - - - update t_sys_user - set username = #{username,jdbcType=VARCHAR}, - password = #{password,jdbcType=VARCHAR}, - nickname = #{nickname,jdbcType=VARCHAR} - where id = #{id,jdbcType=VARCHAR} - - \ No newline at end of file diff --git a/src/main/resources/mybatis/custom/GeneratorMapper.xml b/src/main/resources/mybatis/custom/GeneratorMapper.xml deleted file mode 100644 index 8e98664f5b040d0feb38132efda6db8a3f460401..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/custom/GeneratorMapper.xml +++ /dev/null @@ -1,111 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/custom/TsysDatasMapper.xml b/src/main/resources/mybatis/custom/TsysDatasMapper.xml deleted file mode 100644 index 626adb920447f8858f7f53672e687a1f14fb6a10..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/custom/TsysDatasMapper.xml +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - id, file_path - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/custom/TsysPremissionMapper.xml b/src/main/resources/mybatis/custom/TsysPremissionMapper.xml deleted file mode 100644 index f15dacda3233529211e7861fbbcd92bcb53479fb..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/custom/TsysPremissionMapper.xml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - - - - - - - - - - - - - - - id, name, descripion, url, pid, perms, type, icon, order_num - - - - - - - - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/custom/TsysRoleMapper.xml b/src/main/resources/mybatis/custom/TsysRoleMapper.xml deleted file mode 100644 index 72e60c0144ee30d27cece4fc65a274d8c2c9cb3d..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/custom/TsysRoleMapper.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - id, name - - - \ No newline at end of file diff --git a/src/main/resources/mybatis/custom/TsysUserMapper.xml b/src/main/resources/mybatis/custom/TsysUserMapper.xml deleted file mode 100644 index b6be540290317b9fe5fe57d87f3526a0d9e45482..0000000000000000000000000000000000000000 --- a/src/main/resources/mybatis/custom/TsysUserMapper.xml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - \ No newline at end of file diff --git a/src/test/java/test/SpringbootTest.java b/src/test/java/test/SpringbootTest.java index 7dc7f7d0e5e1e2961edc2b164e45800d88cbd1e7..b388704afc811533ee2aa877c9cfde56b67b0d4c 100644 --- a/src/test/java/test/SpringbootTest.java +++ b/src/test/java/test/SpringbootTest.java @@ -1,100 +1,81 @@ package test; -import java.io.File; -import java.io.Writer; -import java.lang.annotation.Annotation; -import java.lang.reflect.Method; -import java.util.HashMap; -import java.util.Map; - -import org.junit.Test; +import com.fc.SpringbootStart; import org.junit.runner.RunWith; -import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.junit4.SpringRunner; -import org.thymeleaf.TemplateEngine; -import org.thymeleaf.context.Context; -import org.thymeleaf.context.IContext; -import org.thymeleaf.templateresolver.ClassLoaderTemplateResolver; -import com.fc.SpringbootStart; -import com.fc.test.common.spring.SpringUtils; -import com.fc.test.mapper.auto.GeneratorMapper; -import com.fc.test.mapper.custom.TsysUserDao; - -import cn.hutool.core.io.file.FileWriter; -import cn.hutool.json.JSONUtil; @RunWith(SpringRunner.class) @SpringBootTest(classes = SpringbootStart.class, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) public class SpringbootTest { +// +// @Autowired +// private GeneratorMapper generatorMapper; +// +// +// +// +// +// @Test +// public void test(){ +// /*PermissionTreeModelVo modelVo= sysPremissionService.queryTreePrem(); +// Gson gson=new Gson(); +// System.out.println(); +// System.out.println(gson.toJson(modelVo)); +// System.out.println();*/ +// +// //System.out.println(JSONUtil.toJsonStr(generatorMapper.queryColumns2("t_test"))); +// +// +// TsysUserDao dao= SpringUtils.getBean(TsysUserDao.class); +// +// Method[] methods= dao.getClass().getMethods(); +// for (Method method : methods) { +// Annotation[] annotations= method.getAnnotations(); +// +// for (Annotation annotation : annotations) { +// System.out.println(annotation.toString()); +// +// Method[] methods2= annotations.getClass().getDeclaredMethods(); +// for (Method method2 : methods2) { +// Annotation[] annotations2= method2.getAnnotations(); +// for (Annotation annotation2 : annotations2) { +// System.out.println("annotation2>>"+annotation2.toString()); +// } +// } +// } +// } +// +// System.out.println(dao.queryUserName("admin").getUsername()); +// } +// +// public void main() { +// //创建模版加载器 +// ClassLoaderTemplateResolver resolver = new ClassLoaderTemplateResolver(); +// resolver.setPrefix("templates/"); //模板文件的所在目录 +// resolver.setSuffix(".TEXT"); //模板文件后缀 +// //创建模板引擎 +// TemplateEngine templateEngine = new TemplateEngine(); +// //将加载器放入模板引擎 +// templateEngine.setTemplateResolver(resolver); +// //创建字符输出流并且自定义输出文件的位置和文件名 +// // FileWriter writer = new FileWriter("d:/index.html"); +// //创建Context对象(存放Model) +// Context context = new Context(); +// //放入数据 +// Map map=new HashMap(); +// map.put("hello4","444"); +// map.put("hello2","2222"); +// context.setVariable("hello","111111111"); +// context.setVariable("items",map); +// //创建静态文件,"text"是模板html名字 +// +// System.out.println(templateEngine.process("example", context)) ; +// +// } + - @Autowired - private GeneratorMapper generatorMapper; - - - - - - @Test - public void test(){ - /*PermissionTreeModelVo modelVo= sysPremissionService.queryTreePrem(); - Gson gson=new Gson(); - System.out.println(); - System.out.println(gson.toJson(modelVo)); - System.out.println();*/ - - //System.out.println(JSONUtil.toJsonStr(generatorMapper.queryColumns2("t_test"))); - - - TsysUserDao dao= SpringUtils.getBean(TsysUserDao.class); - - Method[] methods= dao.getClass().getMethods(); - for (Method method : methods) { - Annotation[] annotations= method.getAnnotations(); - - for (Annotation annotation : annotations) { - System.out.println(annotation.toString()); - - Method[] methods2= annotations.getClass().getDeclaredMethods(); - for (Method method2 : methods2) { - Annotation[] annotations2= method2.getAnnotations(); - for (Annotation annotation2 : annotations2) { - System.out.println("annotation2>>"+annotation2.toString()); - } - } - } - } - - System.out.println(dao.queryUserName("admin").getUsername()); - } - - public void main() { - //创建模版加载器 - ClassLoaderTemplateResolver resolver = new ClassLoaderTemplateResolver(); - resolver.setPrefix("templates/"); //模板文件的所在目录 - resolver.setSuffix(".TEXT"); //模板文件后缀 - //创建模板引擎 - TemplateEngine templateEngine = new TemplateEngine(); - //将加载器放入模板引擎 - templateEngine.setTemplateResolver(resolver); - //创建字符输出流并且自定义输出文件的位置和文件名 - // FileWriter writer = new FileWriter("d:/index.html"); - //创建Context对象(存放Model) - Context context = new Context(); - //放入数据 - Map map=new HashMap(); - map.put("hello4","444"); - map.put("hello2","2222"); - context.setVariable("hello","111111111"); - context.setVariable("items",map); - //创建静态文件,"text"是模板html名字 - - System.out.println(templateEngine.process("example", context)) ; - - } - - }