Signed-off-by: wuyouming666 <2265557248@qq.com>
springboot 基础框架包括菜单管理 权限管理 用户管理 注册登录
| New file |
| | |
| | | # 默认忽略的文件
|
| | | /shelf/
|
| | | /workspace.xml
|
| | | # 数据源本地存储已忽略文件
|
| | | /dataSources/
|
| | | /dataSources.local.xml
|
| | | # 基于编辑器的 HTTP 客户端请求
|
| | | /httpRequests/
|
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?>
|
| | | <project version="4">
|
| | | <component name="CompilerConfiguration">
|
| | | <annotationProcessing>
|
| | | <profile default="true" name="Default" enabled="true" />
|
| | | <profile name="Maven default annotation processors profile" enabled="true">
|
| | | <sourceOutputDir name="target/generated-sources/annotations" />
|
| | | <sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
|
| | | <outputRelativeToContentRoot value="true" />
|
| | | <module name="canadames" />
|
| | | </profile>
|
| | | </annotationProcessing>
|
| | | <bytecodeTargetLevel>
|
| | | <module name="canadames" target="8" />
|
| | | </bytecodeTargetLevel>
|
| | | </component>
|
| | | <component name="JavacSettings">
|
| | | <option name="ADDITIONAL_OPTIONS_OVERRIDE">
|
| | | <module name="canadames" options="-parameters" />
|
| | | </option>
|
| | | </component>
|
| | | </project> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?>
|
| | | <project version="4">
|
| | | <component name="Encoding">
|
| | | <file url="file://$PROJECT_DIR$/src/main/java" charset="UTF-8" />
|
| | | <file url="file://$PROJECT_DIR$/src/main/resources" charset="UTF-8" />
|
| | | </component>
|
| | | </project> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?>
|
| | | <project version="4">
|
| | | <component name="RemoteRepositoriesConfiguration">
|
| | | <remote-repository>
|
| | | <option name="id" value="central" />
|
| | | <option name="name" value="Central Repository" />
|
| | | <option name="url" value="http://maven.aliyun.com/nexus/content/groups/public/" />
|
| | | </remote-repository>
|
| | | <remote-repository>
|
| | | <option name="id" value="central" />
|
| | | <option name="name" value="Maven Central repository" />
|
| | | <option name="url" value="https://repo1.maven.org/maven2" />
|
| | | </remote-repository>
|
| | | <remote-repository>
|
| | | <option name="id" value="jboss.community" />
|
| | | <option name="name" value="JBoss Community repository" />
|
| | | <option name="url" value="https://repository.jboss.org/nexus/content/repositories/public/" />
|
| | | </remote-repository>
|
| | | </component>
|
| | | </project> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: ch.qos.logback:logback-classic:1.2.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: ch.qos.logback:logback-core:1.2.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.2.3/logback-core-1.2.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.2.3/logback-core-1.2.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/ch/qos/logback/logback-core/1.2.3/logback-core-1.2.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: cn.hutool:hutool-all:5.5.4">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/cn/hutool/hutool-all/5.5.4/hutool-all-5.5.4.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/cn/hutool/hutool-all/5.5.4/hutool-all-5.5.4-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/cn/hutool/hutool-all/5.5.4/hutool-all-5.5.4-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.baomidou:mybatis-plus:3.2.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus/3.2.0/mybatis-plus-3.2.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus/3.2.0/mybatis-plus-3.2.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus/3.2.0/mybatis-plus-3.2.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.baomidou:mybatis-plus-annotation:3.2.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-annotation/3.2.0/mybatis-plus-annotation-3.2.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-annotation/3.2.0/mybatis-plus-annotation-3.2.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-annotation/3.2.0/mybatis-plus-annotation-3.2.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.baomidou:mybatis-plus-boot-starter:3.2.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-boot-starter/3.2.0/mybatis-plus-boot-starter-3.2.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-boot-starter/3.2.0/mybatis-plus-boot-starter-3.2.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-boot-starter/3.2.0/mybatis-plus-boot-starter-3.2.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.baomidou:mybatis-plus-core:3.2.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-core/3.2.0/mybatis-plus-core-3.2.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-core/3.2.0/mybatis-plus-core-3.2.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-core/3.2.0/mybatis-plus-core-3.2.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.baomidou:mybatis-plus-extension:3.2.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-extension/3.2.0/mybatis-plus-extension-3.2.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-extension/3.2.0/mybatis-plus-extension-3.2.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/baomidou/mybatis-plus-extension/3.2.0/mybatis-plus-extension-3.2.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.fasterxml:classmate:1.5.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/classmate/1.5.1/classmate-1.5.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/classmate/1.5.1/classmate-1.5.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/classmate/1.5.1/classmate-1.5.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.11.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-annotations/2.11.1/jackson-annotations-2.11.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-annotations/2.11.1/jackson-annotations-2.11.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-annotations/2.11.1/jackson-annotations-2.11.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.fasterxml.jackson.core:jackson-core:2.11.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-core/2.11.1/jackson-core-2.11.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-core/2.11.1/jackson-core-2.11.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-core/2.11.1/jackson-core-2.11.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.fasterxml.jackson.core:jackson-databind:2.11.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-databind/2.11.1/jackson-databind-2.11.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-databind/2.11.1/jackson-databind-2.11.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/core/jackson-databind/2.11.1/jackson-databind-2.11.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jdk8:2.11.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/datatype/jackson-datatype-jdk8/2.11.1/jackson-datatype-jdk8-2.11.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/datatype/jackson-datatype-jdk8/2.11.1/jackson-datatype-jdk8-2.11.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/datatype/jackson-datatype-jdk8/2.11.1/jackson-datatype-jdk8-2.11.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.11.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/datatype/jackson-datatype-jsr310/2.11.1/jackson-datatype-jsr310-2.11.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/datatype/jackson-datatype-jsr310/2.11.1/jackson-datatype-jsr310-2.11.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/datatype/jackson-datatype-jsr310/2.11.1/jackson-datatype-jsr310-2.11.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.fasterxml.jackson.module:jackson-module-parameter-names:2.11.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/module/jackson-module-parameter-names/2.11.1/jackson-module-parameter-names-2.11.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/module/jackson-module-parameter-names/2.11.1/jackson-module-parameter-names-2.11.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/fasterxml/jackson/module/jackson-module-parameter-names/2.11.1/jackson-module-parameter-names-2.11.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.github.jsqlparser:jsqlparser:2.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/github/jsqlparser/jsqlparser/2.1/jsqlparser-2.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/github/jsqlparser/jsqlparser/2.1/jsqlparser-2.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/github/jsqlparser/jsqlparser/2.1/jsqlparser-2.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.google.guava:guava:20.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/20.0/guava-20.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/20.0/guava-20.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/google/guava/guava/20.0/guava-20.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.jayway.jsonpath:json-path:2.4.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/jayway/jsonpath/json-path/2.4.0/json-path-2.4.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/jayway/jsonpath/json-path/2.4.0/json-path-2.4.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/jayway/jsonpath/json-path/2.4.0/json-path-2.4.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.vaadin.external.google:android-json:0.0.20131108.vaadin1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/vaadin/external/google/android-json/0.0.20131108.vaadin1/android-json-0.0.20131108.vaadin1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/vaadin/external/google/android-json/0.0.20131108.vaadin1/android-json-0.0.20131108.vaadin1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/vaadin/external/google/android-json/0.0.20131108.vaadin1/android-json-0.0.20131108.vaadin1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: com.zaxxer:HikariCP:3.4.5">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/zaxxer/HikariCP/3.4.5/HikariCP-3.4.5.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/zaxxer/HikariCP/3.4.5/HikariCP-3.4.5-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/com/zaxxer/HikariCP/3.4.5/HikariCP-3.4.5-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: commons-beanutils:commons-beanutils:1.9.4">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/commons-beanutils/commons-beanutils/1.9.4/commons-beanutils-1.9.4.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/commons-beanutils/commons-beanutils/1.9.4/commons-beanutils-1.9.4-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/commons-beanutils/commons-beanutils/1.9.4/commons-beanutils-1.9.4-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: commons-collections:commons-collections:3.2.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.jsonwebtoken:jjwt-api:0.10.7">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-api/0.10.7/jjwt-api-0.10.7.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-api/0.10.7/jjwt-api-0.10.7-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-api/0.10.7/jjwt-api-0.10.7-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.jsonwebtoken:jjwt-impl:0.10.7">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-impl/0.10.7/jjwt-impl-0.10.7.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-impl/0.10.7/jjwt-impl-0.10.7-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-impl/0.10.7/jjwt-impl-0.10.7-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.jsonwebtoken:jjwt-jackson:0.10.7">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-jackson/0.10.7/jjwt-jackson-0.10.7.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-jackson/0.10.7/jjwt-jackson-0.10.7-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/jsonwebtoken/jjwt-jackson/0.10.7/jjwt-jackson-0.10.7-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.springfox:springfox-core:2.9.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-core/2.9.2/springfox-core-2.9.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-core/2.9.2/springfox-core-2.9.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-core/2.9.2/springfox-core-2.9.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.springfox:springfox-schema:2.9.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-schema/2.9.2/springfox-schema-2.9.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-schema/2.9.2/springfox-schema-2.9.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-schema/2.9.2/springfox-schema-2.9.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.springfox:springfox-spi:2.9.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-spi/2.9.2/springfox-spi-2.9.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-spi/2.9.2/springfox-spi-2.9.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-spi/2.9.2/springfox-spi-2.9.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.springfox:springfox-spring-web:2.9.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-spring-web/2.9.2/springfox-spring-web-2.9.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-spring-web/2.9.2/springfox-spring-web-2.9.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-spring-web/2.9.2/springfox-spring-web-2.9.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.springfox:springfox-swagger2:2.9.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger2/2.9.2/springfox-swagger2-2.9.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger2/2.9.2/springfox-swagger2-2.9.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger2/2.9.2/springfox-swagger2-2.9.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.springfox:springfox-swagger-common:2.9.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger-common/2.9.2/springfox-swagger-common-2.9.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger-common/2.9.2/springfox-swagger-common-2.9.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger-common/2.9.2/springfox-swagger-common-2.9.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.springfox:springfox-swagger-ui:2.9.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger-ui/2.9.2/springfox-swagger-ui-2.9.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger-ui/2.9.2/springfox-swagger-ui-2.9.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/springfox/springfox-swagger-ui/2.9.2/springfox-swagger-ui-2.9.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.swagger:swagger-annotations:1.5.20">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/swagger/swagger-annotations/1.5.20/swagger-annotations-1.5.20.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/swagger/swagger-annotations/1.5.20/swagger-annotations-1.5.20-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/swagger/swagger-annotations/1.5.20/swagger-annotations-1.5.20-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: io.swagger:swagger-models:1.5.20">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/swagger/swagger-models/1.5.20/swagger-models-1.5.20.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/swagger/swagger-models/1.5.20/swagger-models-1.5.20-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/io/swagger/swagger-models/1.5.20/swagger-models-1.5.20-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: jakarta.activation:jakarta.activation-api:1.2.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/activation/jakarta.activation-api/1.2.2/jakarta.activation-api-1.2.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/activation/jakarta.activation-api/1.2.2/jakarta.activation-api-1.2.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/activation/jakarta.activation-api/1.2.2/jakarta.activation-api-1.2.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: jakarta.annotation:jakarta.annotation-api:1.3.5">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/annotation/jakarta.annotation-api/1.3.5/jakarta.annotation-api-1.3.5.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/annotation/jakarta.annotation-api/1.3.5/jakarta.annotation-api-1.3.5-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/annotation/jakarta.annotation-api/1.3.5/jakarta.annotation-api-1.3.5-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: jakarta.validation:jakarta.validation-api:2.0.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/validation/jakarta.validation-api/2.0.2/jakarta.validation-api-2.0.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/validation/jakarta.validation-api/2.0.2/jakarta.validation-api-2.0.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/validation/jakarta.validation-api/2.0.2/jakarta.validation-api-2.0.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: jakarta.xml.bind:jakarta.xml.bind-api:2.3.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/xml/bind/jakarta.xml.bind-api/2.3.3/jakarta.xml.bind-api-2.3.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/xml/bind/jakarta.xml.bind-api/2.3.3/jakarta.xml.bind-api-2.3.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/jakarta/xml/bind/jakarta.xml.bind-api/2.3.3/jakarta.xml.bind-api-2.3.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: junit:junit:4.13">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.13/junit-4.13.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.13/junit-4.13-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/junit/junit/4.13/junit-4.13-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: mysql:mysql-connector-java:8.0.21">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/mysql/mysql-connector-java/8.0.21/mysql-connector-java-8.0.21.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/mysql/mysql-connector-java/8.0.21/mysql-connector-java-8.0.21-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/mysql/mysql-connector-java/8.0.21/mysql-connector-java-8.0.21-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: net.bytebuddy:byte-buddy:1.10.13">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/bytebuddy/byte-buddy/1.10.13/byte-buddy-1.10.13.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/bytebuddy/byte-buddy/1.10.13/byte-buddy-1.10.13-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/bytebuddy/byte-buddy/1.10.13/byte-buddy-1.10.13-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: net.bytebuddy:byte-buddy-agent:1.10.13">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/bytebuddy/byte-buddy-agent/1.10.13/byte-buddy-agent-1.10.13.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/bytebuddy/byte-buddy-agent/1.10.13/byte-buddy-agent-1.10.13-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/bytebuddy/byte-buddy-agent/1.10.13/byte-buddy-agent-1.10.13-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: net.minidev:accessors-smart:1.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/minidev/accessors-smart/1.2/accessors-smart-1.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/minidev/accessors-smart/1.2/accessors-smart-1.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/minidev/accessors-smart/1.2/accessors-smart-1.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: net.minidev:json-smart:2.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/minidev/json-smart/2.3/json-smart-2.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/minidev/json-smart/2.3/json-smart-2.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/net/minidev/json-smart/2.3/json-smart-2.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.logging.log4j:log4j-api:2.13.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/logging/log4j/log4j-api/2.13.3/log4j-api-2.13.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/logging/log4j/log4j-api/2.13.3/log4j-api-2.13.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/logging/log4j/log4j-api/2.13.3/log4j-api-2.13.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.logging.log4j:log4j-to-slf4j:2.13.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/logging/log4j/log4j-to-slf4j/2.13.3/log4j-to-slf4j-2.13.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/logging/log4j/log4j-to-slf4j/2.13.3/log4j-to-slf4j-2.13.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/logging/log4j/log4j-to-slf4j/2.13.3/log4j-to-slf4j-2.13.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-cache:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-cache/1.5.3/shiro-cache-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-cache/1.5.3/shiro-cache-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-cache/1.5.3/shiro-cache-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-config-core:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-config-core/1.5.3/shiro-config-core-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-config-core/1.5.3/shiro-config-core-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-config-core/1.5.3/shiro-config-core-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-config-ogdl:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-config-ogdl/1.5.3/shiro-config-ogdl-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-config-ogdl/1.5.3/shiro-config-ogdl-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-config-ogdl/1.5.3/shiro-config-ogdl-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-core:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-core/1.5.3/shiro-core-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-core/1.5.3/shiro-core-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-core/1.5.3/shiro-core-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-crypto-cipher:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-cipher/1.5.3/shiro-crypto-cipher-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-cipher/1.5.3/shiro-crypto-cipher-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-cipher/1.5.3/shiro-crypto-cipher-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-crypto-core:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-core/1.5.3/shiro-crypto-core-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-core/1.5.3/shiro-crypto-core-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-core/1.5.3/shiro-crypto-core-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-crypto-hash:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-hash/1.5.3/shiro-crypto-hash-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-hash/1.5.3/shiro-crypto-hash-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-crypto-hash/1.5.3/shiro-crypto-hash-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-event:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-event/1.5.3/shiro-event-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-event/1.5.3/shiro-event-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-event/1.5.3/shiro-event-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-lang:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-lang/1.5.3/shiro-lang-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-lang/1.5.3/shiro-lang-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-lang/1.5.3/shiro-lang-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-spring:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-spring/1.5.3/shiro-spring-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-spring/1.5.3/shiro-spring-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-spring/1.5.3/shiro-spring-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-spring-boot-starter:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-spring-boot-starter/1.5.3/shiro-spring-boot-starter-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-spring-boot-starter/1.5.3/shiro-spring-boot-starter-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-spring-boot-starter/1.5.3/shiro-spring-boot-starter-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.shiro:shiro-web:1.5.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-web/1.5.3/shiro-web-1.5.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-web/1.5.3/shiro-web-1.5.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/shiro/shiro-web/1.5.3/shiro-web-1.5.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.tomcat.embed:tomcat-embed-core:9.0.37">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/tomcat/embed/tomcat-embed-core/9.0.37/tomcat-embed-core-9.0.37.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/tomcat/embed/tomcat-embed-core/9.0.37/tomcat-embed-core-9.0.37-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/tomcat/embed/tomcat-embed-core/9.0.37/tomcat-embed-core-9.0.37-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apache.tomcat.embed:tomcat-embed-websocket:9.0.37">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/tomcat/embed/tomcat-embed-websocket/9.0.37/tomcat-embed-websocket-9.0.37.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/tomcat/embed/tomcat-embed-websocket/9.0.37/tomcat-embed-websocket-9.0.37-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apache/tomcat/embed/tomcat-embed-websocket/9.0.37/tomcat-embed-websocket-9.0.37-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.apiguardian:apiguardian-api:1.1.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apiguardian/apiguardian-api/1.1.0/apiguardian-api-1.1.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apiguardian/apiguardian-api/1.1.0/apiguardian-api-1.1.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/apiguardian/apiguardian-api/1.1.0/apiguardian-api-1.1.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.assertj:assertj-core:3.16.1">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/assertj/assertj-core/3.16.1/assertj-core-3.16.1.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/assertj/assertj-core/3.16.1/assertj-core-3.16.1-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/assertj/assertj-core/3.16.1/assertj-core-3.16.1-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.glassfish:jakarta.el:3.0.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/glassfish/jakarta.el/3.0.3/jakarta.el-3.0.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/glassfish/jakarta.el/3.0.3/jakarta.el-3.0.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/glassfish/jakarta.el/3.0.3/jakarta.el-3.0.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.hamcrest:hamcrest:2.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/hamcrest/hamcrest/2.2/hamcrest-2.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/hamcrest/hamcrest/2.2/hamcrest-2.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/hamcrest/hamcrest/2.2/hamcrest-2.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.hibernate.validator:hibernate-validator:6.1.5.Final">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/hibernate/validator/hibernate-validator/6.1.5.Final/hibernate-validator-6.1.5.Final.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/hibernate/validator/hibernate-validator/6.1.5.Final/hibernate-validator-6.1.5.Final-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/hibernate/validator/hibernate-validator/6.1.5.Final/hibernate-validator-6.1.5.Final-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.jboss.logging:jboss-logging:3.4.1.Final">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/jboss/logging/jboss-logging/3.4.1.Final/jboss-logging-3.4.1.Final.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/jboss/logging/jboss-logging/3.4.1.Final/jboss-logging-3.4.1.Final-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/jboss/logging/jboss-logging/3.4.1.Final/jboss-logging-3.4.1.Final-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.junit.jupiter:junit-jupiter:5.6.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter/5.6.2/junit-jupiter-5.6.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter/5.6.2/junit-jupiter-5.6.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter/5.6.2/junit-jupiter-5.6.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.junit.jupiter:junit-jupiter-api:5.6.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-api/5.6.2/junit-jupiter-api-5.6.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-api/5.6.2/junit-jupiter-api-5.6.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-api/5.6.2/junit-jupiter-api-5.6.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.junit.jupiter:junit-jupiter-engine:5.6.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-engine/5.6.2/junit-jupiter-engine-5.6.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-engine/5.6.2/junit-jupiter-engine-5.6.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-engine/5.6.2/junit-jupiter-engine-5.6.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.junit.jupiter:junit-jupiter-params:5.6.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-params/5.6.2/junit-jupiter-params-5.6.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-params/5.6.2/junit-jupiter-params-5.6.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/jupiter/junit-jupiter-params/5.6.2/junit-jupiter-params-5.6.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.junit.platform:junit-platform-commons:1.6.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-commons/1.6.2/junit-platform-commons-1.6.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-commons/1.6.2/junit-platform-commons-1.6.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-commons/1.6.2/junit-platform-commons-1.6.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.junit.platform:junit-platform-engine:1.6.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-engine/1.6.2/junit-platform-engine-1.6.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-engine/1.6.2/junit-platform-engine-1.6.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/platform/junit-platform-engine/1.6.2/junit-platform-engine-1.6.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.junit.vintage:junit-vintage-engine:5.6.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/vintage/junit-vintage-engine/5.6.2/junit-vintage-engine-5.6.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/vintage/junit-vintage-engine/5.6.2/junit-vintage-engine-5.6.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/junit/vintage/junit-vintage-engine/5.6.2/junit-vintage-engine-5.6.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.mapstruct:mapstruct:1.2.0.Final">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mapstruct/mapstruct/1.2.0.Final/mapstruct-1.2.0.Final.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mapstruct/mapstruct/1.2.0.Final/mapstruct-1.2.0.Final-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mapstruct/mapstruct/1.2.0.Final/mapstruct-1.2.0.Final-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.mockito:mockito-core:3.3.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mockito/mockito-core/3.3.3/mockito-core-3.3.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mockito/mockito-core/3.3.3/mockito-core-3.3.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mockito/mockito-core/3.3.3/mockito-core-3.3.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.mockito:mockito-junit-jupiter:3.3.3">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mockito/mockito-junit-jupiter/3.3.3/mockito-junit-jupiter-3.3.3.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mockito/mockito-junit-jupiter/3.3.3/mockito-junit-jupiter-3.3.3-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mockito/mockito-junit-jupiter/3.3.3/mockito-junit-jupiter-3.3.3-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.mybatis:mybatis:3.5.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mybatis/mybatis/3.5.2/mybatis-3.5.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mybatis/mybatis/3.5.2/mybatis-3.5.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mybatis/mybatis/3.5.2/mybatis-3.5.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.mybatis:mybatis-spring:2.0.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mybatis/mybatis-spring/2.0.2/mybatis-spring-2.0.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mybatis/mybatis-spring/2.0.2/mybatis-spring-2.0.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/mybatis/mybatis-spring/2.0.2/mybatis-spring-2.0.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.objenesis:objenesis:2.6">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/objenesis/objenesis/2.6/objenesis-2.6.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/objenesis/objenesis/2.6/objenesis-2.6-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/objenesis/objenesis/2.6/objenesis-2.6-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.opentest4j:opentest4j:1.2.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/opentest4j/opentest4j/1.2.0/opentest4j-1.2.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/opentest4j/opentest4j/1.2.0/opentest4j-1.2.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/opentest4j/opentest4j/1.2.0/opentest4j-1.2.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.ow2.asm:asm:5.0.4">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/ow2/asm/asm/5.0.4/asm-5.0.4.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/ow2/asm/asm/5.0.4/asm-5.0.4-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/ow2/asm/asm/5.0.4/asm-5.0.4-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.owasp.encoder:encoder:1.2.2">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/owasp/encoder/encoder/1.2.2/encoder-1.2.2.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/owasp/encoder/encoder/1.2.2/encoder-1.2.2-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/owasp/encoder/encoder/1.2.2/encoder-1.2.2-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.projectlombok:lombok:1.18.12">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/projectlombok/lombok/1.18.12/lombok-1.18.12.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/projectlombok/lombok/1.18.12/lombok-1.18.12-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/projectlombok/lombok/1.18.12/lombok-1.18.12-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.skyscreamer:jsonassert:1.5.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/skyscreamer/jsonassert/1.5.0/jsonassert-1.5.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/skyscreamer/jsonassert/1.5.0/jsonassert-1.5.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/skyscreamer/jsonassert/1.5.0/jsonassert-1.5.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.slf4j:jul-to-slf4j:1.7.30">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/slf4j/jul-to-slf4j/1.7.30/jul-to-slf4j-1.7.30.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/slf4j/jul-to-slf4j/1.7.30/jul-to-slf4j-1.7.30-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/slf4j/jul-to-slf4j/1.7.30/jul-to-slf4j-1.7.30-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.slf4j:slf4j-api:1.7.30">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.30/slf4j-api-1.7.30.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.30/slf4j-api-1.7.30-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/slf4j/slf4j-api/1.7.30/slf4j-api-1.7.30-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot/2.3.2.RELEASE/spring-boot-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot/2.3.2.RELEASE/spring-boot-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot/2.3.2.RELEASE/spring-boot-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-autoconfigure:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-autoconfigure/2.3.2.RELEASE/spring-boot-autoconfigure-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-autoconfigure/2.3.2.RELEASE/spring-boot-autoconfigure-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-autoconfigure/2.3.2.RELEASE/spring-boot-autoconfigure-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-starter:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter/2.3.2.RELEASE/spring-boot-starter-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter/2.3.2.RELEASE/spring-boot-starter-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter/2.3.2.RELEASE/spring-boot-starter-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-starter-jdbc:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-jdbc/2.3.2.RELEASE/spring-boot-starter-jdbc-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-jdbc/2.3.2.RELEASE/spring-boot-starter-jdbc-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-jdbc/2.3.2.RELEASE/spring-boot-starter-jdbc-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-starter-json:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-json/2.3.2.RELEASE/spring-boot-starter-json-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-json/2.3.2.RELEASE/spring-boot-starter-json-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-json/2.3.2.RELEASE/spring-boot-starter-json-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-starter-logging:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-logging/2.3.2.RELEASE/spring-boot-starter-logging-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-logging/2.3.2.RELEASE/spring-boot-starter-logging-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-logging/2.3.2.RELEASE/spring-boot-starter-logging-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-starter-test:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-test/2.3.2.RELEASE/spring-boot-starter-test-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-test/2.3.2.RELEASE/spring-boot-starter-test-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-test/2.3.2.RELEASE/spring-boot-starter-test-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-starter-tomcat:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-tomcat/2.3.2.RELEASE/spring-boot-starter-tomcat-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-tomcat/2.3.2.RELEASE/spring-boot-starter-tomcat-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-tomcat/2.3.2.RELEASE/spring-boot-starter-tomcat-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-starter-web:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-web/2.3.2.RELEASE/spring-boot-starter-web-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-web/2.3.2.RELEASE/spring-boot-starter-web-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-starter-web/2.3.2.RELEASE/spring-boot-starter-web-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-test:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-test/2.3.2.RELEASE/spring-boot-test-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-test/2.3.2.RELEASE/spring-boot-test-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-test/2.3.2.RELEASE/spring-boot-test-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.boot:spring-boot-test-autoconfigure:2.3.2.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-test-autoconfigure/2.3.2.RELEASE/spring-boot-test-autoconfigure-2.3.2.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-test-autoconfigure/2.3.2.RELEASE/spring-boot-test-autoconfigure-2.3.2.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/boot/spring-boot-test-autoconfigure/2.3.2.RELEASE/spring-boot-test-autoconfigure-2.3.2.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.plugin:spring-plugin-core:1.2.0.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/plugin/spring-plugin-core/1.2.0.RELEASE/spring-plugin-core-1.2.0.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/plugin/spring-plugin-core/1.2.0.RELEASE/spring-plugin-core-1.2.0.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/plugin/spring-plugin-core/1.2.0.RELEASE/spring-plugin-core-1.2.0.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework.plugin:spring-plugin-metadata:1.2.0.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/plugin/spring-plugin-metadata/1.2.0.RELEASE/spring-plugin-metadata-1.2.0.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/plugin/spring-plugin-metadata/1.2.0.RELEASE/spring-plugin-metadata-1.2.0.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/plugin/spring-plugin-metadata/1.2.0.RELEASE/spring-plugin-metadata-1.2.0.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-aop:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-aop/5.2.8.RELEASE/spring-aop-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-aop/5.2.8.RELEASE/spring-aop-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-aop/5.2.8.RELEASE/spring-aop-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-beans:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-beans/5.2.8.RELEASE/spring-beans-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-beans/5.2.8.RELEASE/spring-beans-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-beans/5.2.8.RELEASE/spring-beans-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-context:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-context/5.2.8.RELEASE/spring-context-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-context/5.2.8.RELEASE/spring-context-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-context/5.2.8.RELEASE/spring-context-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-core:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-core/5.2.8.RELEASE/spring-core-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-core/5.2.8.RELEASE/spring-core-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-core/5.2.8.RELEASE/spring-core-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-expression:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-expression/5.2.8.RELEASE/spring-expression-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-expression/5.2.8.RELEASE/spring-expression-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-expression/5.2.8.RELEASE/spring-expression-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-jcl:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-jcl/5.2.8.RELEASE/spring-jcl-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-jcl/5.2.8.RELEASE/spring-jcl-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-jcl/5.2.8.RELEASE/spring-jcl-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-jdbc:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-jdbc/5.2.8.RELEASE/spring-jdbc-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-jdbc/5.2.8.RELEASE/spring-jdbc-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-jdbc/5.2.8.RELEASE/spring-jdbc-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-test:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-test/5.2.8.RELEASE/spring-test-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-test/5.2.8.RELEASE/spring-test-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-test/5.2.8.RELEASE/spring-test-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-tx:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-tx/5.2.8.RELEASE/spring-tx-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-tx/5.2.8.RELEASE/spring-tx-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-tx/5.2.8.RELEASE/spring-tx-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-web:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-web/5.2.8.RELEASE/spring-web-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-web/5.2.8.RELEASE/spring-web-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-web/5.2.8.RELEASE/spring-web-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.springframework:spring-webmvc:5.2.8.RELEASE">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-webmvc/5.2.8.RELEASE/spring-webmvc-5.2.8.RELEASE.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-webmvc/5.2.8.RELEASE/spring-webmvc-5.2.8.RELEASE-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/springframework/spring-webmvc/5.2.8.RELEASE/spring-webmvc-5.2.8.RELEASE-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.xmlunit:xmlunit-core:2.7.0">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/xmlunit/xmlunit-core/2.7.0/xmlunit-core-2.7.0.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/xmlunit/xmlunit-core/2.7.0/xmlunit-core-2.7.0-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/xmlunit/xmlunit-core/2.7.0/xmlunit-core-2.7.0-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <component name="libraryTable">
|
| | | <library name="Maven: org.yaml:snakeyaml:1.26">
|
| | | <CLASSES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/yaml/snakeyaml/1.26/snakeyaml-1.26.jar!/" />
|
| | | </CLASSES>
|
| | | <JAVADOC>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/yaml/snakeyaml/1.26/snakeyaml-1.26-javadoc.jar!/" />
|
| | | </JAVADOC>
|
| | | <SOURCES>
|
| | | <root url="jar://$MAVEN_REPOSITORY$/org/yaml/snakeyaml/1.26/snakeyaml-1.26-sources.jar!/" />
|
| | | </SOURCES>
|
| | | </library>
|
| | | </component> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?>
|
| | | <project version="4">
|
| | | <component name="MavenProjectsManager">
|
| | | <option name="originalFiles">
|
| | | <list>
|
| | | <option value="$PROJECT_DIR$/pom.xml" />
|
| | | </list>
|
| | | </option>
|
| | | </component>
|
| | | <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="11" project-jdk-type="JavaSDK" />
|
| | | </project> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?>
|
| | | <project version="4">
|
| | | <component name="ProjectModuleManager">
|
| | | <modules>
|
| | | <module fileurl="file://$PROJECT_DIR$/canadames.iml" filepath="$PROJECT_DIR$/canadames.iml" />
|
| | | </modules>
|
| | | </component>
|
| | | </project> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?>
|
| | | <module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
|
| | | <component name="FacetManager">
|
| | | <facet type="web" name="Web">
|
| | | <configuration>
|
| | | <webroots />
|
| | | <sourceRoots>
|
| | | <root url="file://$MODULE_DIR$/src/main/java" />
|
| | | <root url="file://$MODULE_DIR$/src/main/resources" />
|
| | | </sourceRoots>
|
| | | </configuration>
|
| | | </facet>
|
| | | <facet type="Spring" name="Spring">
|
| | | <configuration />
|
| | | </facet>
|
| | | </component>
|
| | | <component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8">
|
| | | <output url="file://$MODULE_DIR$/target/classes" />
|
| | | <output-test url="file://$MODULE_DIR$/target/test-classes" />
|
| | | <content url="file://$MODULE_DIR$">
|
| | | <sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
|
| | | <sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
|
| | | <sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
|
| | | <excludeFolder url="file://$MODULE_DIR$/target" />
|
| | | </content>
|
| | | <orderEntry type="inheritedJdk" />
|
| | | <orderEntry type="sourceFolder" forTests="false" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-web:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-logging:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: ch.qos.logback:logback-classic:1.2.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: ch.qos.logback:logback-core:1.2.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.logging.log4j:log4j-to-slf4j:2.13.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.logging.log4j:log4j-api:2.13.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.slf4j:jul-to-slf4j:1.7.30" level="project" />
|
| | | <orderEntry type="library" name="Maven: jakarta.annotation:jakarta.annotation-api:1.3.5" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.yaml:snakeyaml:1.26" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-json:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jdk8:2.11.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.11.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.fasterxml.jackson.module:jackson-module-parameter-names:2.11.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-tomcat:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-core:9.0.37" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.glassfish:jakarta.el:3.0.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-websocket:9.0.37" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-web:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-beans:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-webmvc:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-aop:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-context:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-expression:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" scope="RUNTIME" name="Maven: mysql:mysql-connector-java:8.0.21" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.projectlombok:lombok:1.18.12" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.springframework.boot:spring-boot-starter-test:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.springframework.boot:spring-boot-test:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.springframework.boot:spring-boot-test-autoconfigure:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: com.jayway.jsonpath:json-path:2.4.0" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: net.minidev:json-smart:2.3" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: net.minidev:accessors-smart:1.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.ow2.asm:asm:5.0.4" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: jakarta.xml.bind:jakarta.xml.bind-api:2.3.3" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: jakarta.activation:jakarta.activation-api:1.2.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.assertj:assertj-core:3.16.1" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.hamcrest:hamcrest:2.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.junit.jupiter:junit-jupiter:5.6.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.junit.jupiter:junit-jupiter-api:5.6.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.opentest4j:opentest4j:1.2.0" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.junit.platform:junit-platform-commons:1.6.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.junit.jupiter:junit-jupiter-params:5.6.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.junit.jupiter:junit-jupiter-engine:5.6.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.junit.vintage:junit-vintage-engine:5.6.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.apiguardian:apiguardian-api:1.1.0" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.junit.platform:junit-platform-engine:1.6.2" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: junit:junit:4.13" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.mockito:mockito-core:3.3.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: net.bytebuddy:byte-buddy:1.10.13" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: net.bytebuddy:byte-buddy-agent:1.10.13" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.objenesis:objenesis:2.6" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.mockito:mockito-junit-jupiter:3.3.3" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.skyscreamer:jsonassert:1.5.0" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: com.vaadin.external.google:android-json:0.0.20131108.vaadin1" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-core:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-jcl:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.springframework:spring-test:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" scope="TEST" name="Maven: org.xmlunit:xmlunit-core:2.7.0" level="project" />
|
| | | <orderEntry type="library" name="Maven: cn.hutool:hutool-all:5.5.4" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.hibernate.validator:hibernate-validator:6.1.5.Final" level="project" />
|
| | | <orderEntry type="library" name="Maven: jakarta.validation:jakarta.validation-api:2.0.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.jboss.logging:jboss-logging:3.4.1.Final" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.fasterxml:classmate:1.5.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.jsonwebtoken:jjwt-api:0.10.7" level="project" />
|
| | | <orderEntry type="library" scope="RUNTIME" name="Maven: io.jsonwebtoken:jjwt-impl:0.10.7" level="project" />
|
| | | <orderEntry type="library" scope="RUNTIME" name="Maven: io.jsonwebtoken:jjwt-jackson:0.10.7" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-databind:2.11.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.11.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-core:2.11.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-spring-boot-starter:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-spring:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-core:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-lang:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-cache:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-hash:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-core:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-cipher:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-config-core:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-config-ogdl:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: commons-beanutils:commons-beanutils:1.9.4" level="project" />
|
| | | <orderEntry type="library" name="Maven: commons-collections:commons-collections:3.2.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-event:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.apache.shiro:shiro-web:1.5.3" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.owasp.encoder:encoder:1.2.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-autoconfigure:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-boot-starter:3.2.0" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.baomidou:mybatis-plus:3.2.0" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-extension:3.2.0" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-core:3.2.0" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-annotation:3.2.0" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.github.jsqlparser:jsqlparser:2.1" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.mybatis:mybatis:3.5.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.mybatis:mybatis-spring:2.0.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-jdbc:2.3.2.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.zaxxer:HikariCP:3.4.5" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-jdbc:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework:spring-tx:5.2.8.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.springfox:springfox-swagger2:2.9.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.swagger:swagger-annotations:1.5.20" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.swagger:swagger-models:1.5.20" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.springfox:springfox-spi:2.9.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.springfox:springfox-core:2.9.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.springfox:springfox-schema:2.9.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.springfox:springfox-swagger-common:2.9.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.springfox:springfox-spring-web:2.9.2" level="project" />
|
| | | <orderEntry type="library" name="Maven: com.google.guava:guava:20.0" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.slf4j:slf4j-api:1.7.30" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.plugin:spring-plugin-core:1.2.0.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.springframework.plugin:spring-plugin-metadata:1.2.0.RELEASE" level="project" />
|
| | | <orderEntry type="library" name="Maven: org.mapstruct:mapstruct:1.2.0.Final" level="project" />
|
| | | <orderEntry type="library" name="Maven: io.springfox:springfox-swagger-ui:2.9.2" level="project" />
|
| | | </component>
|
| | | </module> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| | | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| | | <modelVersion>4.0.0</modelVersion> |
| | | |
| | | <parent> |
| | | <groupId>org.springframework.boot</groupId> |
| | | <artifactId>spring-boot-starter-parent</artifactId> |
| | | <version>2.3.2.RELEASE</version> |
| | | <relativePath/> |
| | | </parent> |
| | | |
| | | <groupId>com.canadames</groupId> |
| | | <artifactId>canadames</artifactId> |
| | | <version>0.0.1-SNAPSHOT</version> |
| | | <name>canadames</name> |
| | | <description>canadames System</description> |
| | | |
| | | <properties> |
| | | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| | | <encoding>UTF-8</encoding> |
| | | <java.version>8</java.version> |
| | | <maven.compiler.source>${java.version}</maven.compiler.source> |
| | | <maven.compiler.target>${java.version}</maven.compiler.target> |
| | | |
| | | <spring-boot.version>2.3.2.RELEASE</spring-boot.version> |
| | | </properties> |
| | | |
| | | <dependencies> |
| | | <dependency> |
| | | <groupId>org.springframework.boot</groupId> |
| | | <artifactId>spring-boot-starter-web</artifactId> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>mysql</groupId> |
| | | <artifactId>mysql-connector-java</artifactId> |
| | | <scope>runtime</scope> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.projectlombok</groupId> |
| | | <artifactId>lombok</artifactId> |
| | | <optional>true</optional> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.springframework.boot</groupId> |
| | | <artifactId>spring-boot-starter-test</artifactId> |
| | | <scope>test</scope> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>cn.hutool</groupId> |
| | | <artifactId>hutool-all</artifactId> |
| | | <version>5.5.4</version> |
| | | </dependency> |
| | | <!--参数校验--> |
| | | <dependency> |
| | | <groupId>org.hibernate.validator</groupId> |
| | | <artifactId>hibernate-validator</artifactId> |
| | | </dependency> |
| | | <!--JWT--> |
| | | <dependency> |
| | | <groupId>io.jsonwebtoken</groupId> |
| | | <artifactId>jjwt-api</artifactId> |
| | | <version>0.10.7</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>io.jsonwebtoken</groupId> |
| | | <artifactId>jjwt-impl</artifactId> |
| | | <version>0.10.7</version> |
| | | <scope>runtime</scope> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>io.jsonwebtoken</groupId> |
| | | <artifactId>jjwt-jackson</artifactId> |
| | | <version>0.10.7</version> |
| | | <scope>runtime</scope> |
| | | </dependency> |
| | | <!--shiro--> |
| | | <dependency> |
| | | <groupId>org.apache.shiro</groupId> |
| | | <artifactId>shiro-spring-boot-starter</artifactId> |
| | | <version>1.5.3</version> |
| | | </dependency> |
| | | <!--mybatis-plus--> |
| | | <dependency> |
| | | <groupId>com.baomidou</groupId> |
| | | <artifactId>mybatis-plus-boot-starter</artifactId> |
| | | <version>3.2.0</version> |
| | | </dependency> |
| | | <!-- swagger --> |
| | | <dependency> |
| | | <groupId>io.springfox</groupId> |
| | | <artifactId>springfox-swagger2</artifactId> |
| | | <version>2.9.2</version> |
| | | </dependency> |
| | | <!-- swagger-ui --> |
| | | <dependency> |
| | | <groupId>io.springfox</groupId> |
| | | <artifactId>springfox-swagger-ui</artifactId> |
| | | <version>2.9.2</version> |
| | | </dependency> |
| | | </dependencies> |
| | | |
| | | <build> |
| | | <plugins> |
| | | <plugin> |
| | | <groupId>org.springframework.boot</groupId> |
| | | <artifactId>spring-boot-maven-plugin</artifactId> |
| | | <version>${spring-boot.version}</version> |
| | | </plugin> |
| | | </plugins> |
| | | </build> |
| | | </project> |
| New file |
| | |
| | | package com.canadames; |
| | | |
| | | import org.springframework.boot.SpringApplication; |
| | | import org.springframework.boot.autoconfigure.SpringBootApplication; |
| | | |
| | | @SpringBootApplication |
| | | public class AuthorityApplication { |
| | | |
| | | public static void main(String[] args) { |
| | | SpringApplication.run(AuthorityApplication.class, args); |
| | | } |
| | | |
| | | } |
| New file |
| | |
| | | package com.canadames.advice; |
| | | |
| | | import com.canadames.entity.vo.Result; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authz.AuthorizationException; |
| | | import org.apache.shiro.authz.UnauthorizedException; |
| | | import org.springframework.web.bind.annotation.ControllerAdvice; |
| | | import org.springframework.web.bind.annotation.ExceptionHandler; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | | |
| | | import javax.servlet.http.HttpServletRequest; |
| | | |
| | | /** |
| | | * 全局异常 |
| | | */ |
| | | @Slf4j |
| | | @ControllerAdvice |
| | | public class GlobalExceptionHandler { |
| | | @ExceptionHandler(value = Exception.class) |
| | | @ResponseBody |
| | | public Result exception(HttpServletRequest req, Exception e) { |
| | | log.error("---exception Handler---Host {} invokes url {} ERROR: ", req.getRemoteHost(), req.getRequestURL(), e); |
| | | return Result.fail("系统错误,请联系网站管理员!"); |
| | | } |
| | | |
| | | @ExceptionHandler(value = RuntimeException.class) |
| | | @ResponseBody |
| | | public Result runtimeException(HttpServletRequest req, RuntimeException e) { |
| | | log.error("---runtimeException Handler---Host {} invokes url {} ERROR: ", req.getRemoteHost(), req.getRequestURL(), e); |
| | | return Result.fail(e.getMessage()); |
| | | } |
| | | |
| | | /** |
| | | * 处理Shiro权限拦截异常 |
| | | */ |
| | | @ExceptionHandler(value = {AuthorizationException.class, UnauthorizedException.class}) |
| | | @ResponseBody |
| | | public Result authorizationException(HttpServletRequest req, UnauthorizedException e) { |
| | | log.error("---authorizationException Handler---Host {} invokes url {} ERROR: ", req.getRemoteHost(), req.getRequestURL(), e); |
| | | return Result.fail("权限不足"); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.config; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor; |
| | | import org.springframework.context.annotation.Bean; |
| | | import org.springframework.context.annotation.Configuration; |
| | | |
| | | @Configuration |
| | | public class MybatisPlusConfig { |
| | | @Bean |
| | | public PaginationInterceptor paginationInterceptor() { |
| | | // 配置mybatis-plus分页插件 |
| | | PaginationInterceptor paginationInterceptor = new PaginationInterceptor(); |
| | | // 方言 |
| | | paginationInterceptor.setDialectType("mysql"); |
| | | return paginationInterceptor; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.config; |
| | | |
| | | import org.springframework.context.annotation.Bean; |
| | | import org.springframework.context.annotation.Configuration; |
| | | import springfox.documentation.builders.ApiInfoBuilder; |
| | | import springfox.documentation.builders.PathSelectors; |
| | | import springfox.documentation.builders.RequestHandlerSelectors; |
| | | import springfox.documentation.service.ApiInfo; |
| | | import springfox.documentation.service.Contact; |
| | | import springfox.documentation.spi.DocumentationType; |
| | | import springfox.documentation.spring.web.plugins.Docket; |
| | | import springfox.documentation.swagger2.annotations.EnableSwagger2; |
| | | |
| | | /** |
| | | * swagger配置 |
| | | * 项目运行后访问:http://localhost:port/swagger-ui.html |
| | | */ |
| | | @Configuration |
| | | @EnableSwagger2 |
| | | public class SwaggerConfig { |
| | | // 配置swagger2核心配置 docket |
| | | @Bean |
| | | public Docket createRestApi() { |
| | | return new Docket(DocumentationType.SWAGGER_2) // 指定api类型为swagger2 |
| | | .groupName("authority") // 分组 |
| | | .apiInfo(apiInfo()) // 用于定义api文档汇总信息 |
| | | .select() // 通过.select()方法,去配置扫描接口。RequestHandlerSelectors配置如何扫描接口 |
| | | /* |
| | | // RequestHandlerSelectors配置方法 |
| | | any() // 扫描所有,项目中的所有接口都会被扫描到 |
| | | none() // 不扫描接口 |
| | | // 通过方法上的注解扫描,如withMethodAnnotation(GetMapping.class)只扫描get请求 |
| | | withMethodAnnotation( final Class<? extends Annotation> annotation) |
| | | // 通过类上的注解扫描,如.withClassAnnotation(Controller.class)只扫描有controller注解的类中的接口 |
| | | withClassAnnotation( final Class<? extends Annotation> annotation) |
| | | basePackage( final String basePackage) // 根据包路径扫描接口 |
| | | */ |
| | | .apis(RequestHandlerSelectors.basePackage("com.canadames")) // 指定扫描包 |
| | | /* |
| | | // 配置如何通过path过滤,即这里只扫描请求以/开头的接口 |
| | | any() // 任何请求都扫描 |
| | | none() // 任何请求都不扫描 |
| | | regex(final String pathRegex) // 通过正则表达式控制 |
| | | ant(final String antPattern) // 通过ant()控制 |
| | | */ |
| | | .paths(PathSelectors.any()) // 所有controller |
| | | .build(); |
| | | } |
| | | |
| | | //构建 api文档的详细信息函数,注意这里的注解引用的是哪个 |
| | | private ApiInfo apiInfo() { |
| | | return new ApiInfoBuilder() |
| | | .title("权限管理系统 API") // 文档页标题 |
| | | .contact(new Contact("canadames", "https://jonssonyan.com", "yz808@outlook.com")) // 联系人信息 |
| | | .version("1.0") // 文档版本号 |
| | | .description("API 描述") // 描述 |
| | | .build(); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import com.canadames.entity.Category; |
| | | import com.canadames.entity.vo.CategoryVo; |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.CategoryService; |
| | | import com.canadames.service.UserService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.List; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @Api(tags = "分类") |
| | | @RequestMapping("/api/category") |
| | | public class CategoryController { |
| | | @Autowired |
| | | private CategoryService categoryService; |
| | | @Autowired |
| | | private UserService userService; |
| | | |
| | | @ApiOperation(value = "分页查询分类") |
| | | @GetMapping("/selectPage") |
| | | @RequiresPermissions({"category:select"}) |
| | | public Result selectPage(CategoryVo categoryVO) { |
| | | return Result.success(categoryService.selectPage(categoryVO)); |
| | | } |
| | | |
| | | @ApiOperation(value = "单个删除分类") |
| | | @PostMapping("/removeById") |
| | | @RequiresPermissions({"category:delete"}) |
| | | public Result removeById(@RequestBody CategoryVo categoryVO) { |
| | | List<Category> categories = categoryService.selectList(categoryVO.getId(), false); |
| | | if (CollectionUtil.isNotEmpty(categories)) return Result.fail("该分类下含有子集,不可以删除"); |
| | | List<Long> longs = userService.selectChild(SecurityUtil.getCurrentUser().getId(), true); |
| | | boolean remove = categoryService.lambdaUpdate() |
| | | .in(Category::getCreator, longs) |
| | | .eq(Category::getId, categoryVO.getId()) |
| | | .remove(); |
| | | if (remove) log.info("用户id{}删除分类{}", SecurityUtil.getCurrentUser().getId(), categoryVO.getName()); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "修改或者更新分类") |
| | | @PostMapping("/saveOrUpdate") |
| | | @RequiresPermissions({"category:update", "category:add"}) |
| | | public Result saveOrUpdate(@RequestBody Category category) { |
| | | List<Long> longs = userService.selectChild(SecurityUtil.getCurrentUser().getId(), true); |
| | | Integer count = categoryService.lambdaQuery() |
| | | .eq(Category::getName, category.getName()) |
| | | .in(Category::getCreator, longs) |
| | | .ne(category.getId() != null, Category::getId, category.getId()) |
| | | .count(); |
| | | if (count > 0) return Result.fail("该分类名称已存在"); |
| | | category.setCreator(category.getId() == null ? SecurityUtil.getCurrentUser().getId() : null); |
| | | categoryService.saveOrUpdate(category); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "查询某人创建的分类,但是排除当前选中的分类,用户修改分类使用") |
| | | @GetMapping("/select") |
| | | @RequiresPermissions({"category:select"}) |
| | | public Result select(Category category) { |
| | | List<Category> categories = categoryService.lambdaQuery() |
| | | .ne(category.getId() != null, Category::getId, category.getId()) |
| | | .eq(Category::getCreator, SecurityUtil.getCurrentUser().getId()) |
| | | .list(); |
| | | return Result.success(categories); |
| | | } |
| | | |
| | | @ApiOperation(value = "查询分类,嵌套数据结构") |
| | | @GetMapping("/selectChilds") |
| | | @RequiresPermissions({"category:select"}) |
| | | public Result selectChilds(Category category) { |
| | | return Result.success(categoryService.selectChilds(SecurityUtil.getCurrentUser().getId())); |
| | | } |
| | | |
| | | @ApiOperation(value = "通过id查询分类") |
| | | @GetMapping("/getById") |
| | | @RequiresPermissions({"category:select"}) |
| | | public Result getById(Category category) { |
| | | Category one = categoryService.lambdaQuery().eq(Category::getCreator, SecurityUtil.getCurrentUser().getId()) |
| | | .eq(Category::getId, category.getId()).one(); |
| | | return Result.success(one); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.canadames.entity.User; |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.entity.vo.UserVo; |
| | | import com.canadames.security.constant.SystemConstant; |
| | | import com.canadames.security.util.JwtUtil; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.UserService; |
| | | import com.canadames.util.ValidatorUtil; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.SecurityUtils; |
| | | import org.apache.shiro.authc.DisabledAccountException; |
| | | import org.apache.shiro.authc.ExcessiveAttemptsException; |
| | | import org.apache.shiro.authc.ExpiredCredentialsException; |
| | | 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.authz.UnauthorizedException; |
| | | import org.apache.shiro.crypto.hash.SimpleHash; |
| | | import org.apache.shiro.util.ByteSource; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.HashMap; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @Api(tags = "登录和注册") |
| | | public class DefaultController { |
| | | @Autowired |
| | | private UserService userService; |
| | | |
| | | @ApiOperation(value = "注册用户") |
| | | @PostMapping("/register") |
| | | public Result register(@RequestBody User user) { |
| | | // 校验参数 |
| | | if (StringUtils.isNotEmpty(user.getEmail())) { |
| | | ValidatorUtil.validateEntity(user); |
| | | } |
| | | |
| | | Integer integer = userService.countByUsername(user.getUsername()); |
| | | if (integer > 0) return Result.fail("用户名已经存在"); |
| | | // 通过shiro默认的加密工具类为注册用户的密码进行加密 |
| | | Object salt = ByteSource.Util.bytes(SystemConstant.JWT_SECRET_KEY); |
| | | String md5 = new SimpleHash("MD5", user.getPassword(), salt, 1024).toHex(); |
| | | user.setPassword(md5); |
| | | userService.saveOrUpdate(user); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "登录") |
| | | @PostMapping("/login") |
| | | public Result login(@RequestBody UserVo userVO) { |
| | | ValidatorUtil.validateEntity(userVO); |
| | | if (!SecurityUtils.getSubject().isAuthenticated()) { |
| | | UsernamePasswordToken usernamePasswordToken = new UsernamePasswordToken(userVO.getUsername(), userVO.getPassword(), true); |
| | | try { |
| | | // shiro验证用户名密码 |
| | | SecurityUtils.getSubject().login(usernamePasswordToken); |
| | | // 生成token |
| | | String token = JwtUtil.createToken(userVO.getUsername(), false); |
| | | // 将用户户名和token返回 |
| | | HashMap<String, String> map = new HashMap<>(); |
| | | map.put("username", userVO.getUsername()); |
| | | map.put("Authorization", token); |
| | | map.put("role_id", SecurityUtil.getCurrentUser().getRoleId().toString()); |
| | | return Result.success(map); |
| | | } catch (IncorrectCredentialsException e) { |
| | | return Result.fail("登录密码错误"); |
| | | } catch (ExcessiveAttemptsException e) { |
| | | return Result.fail("登录失败次数过多"); |
| | | } catch (LockedAccountException e) { |
| | | return Result.fail("帐号已被锁定"); |
| | | } catch (DisabledAccountException e) { |
| | | return Result.fail("帐号已被禁用"); |
| | | } catch (ExpiredCredentialsException e) { |
| | | return Result.fail("帐号已过期"); |
| | | } catch (UnknownAccountException e) { |
| | | return Result.fail("帐号不存在"); |
| | | } catch (UnauthorizedException e) { |
| | | return Result.fail("您没有得到相应的授权"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | return Result.fail("登录失败!!!"); |
| | | } |
| | | } |
| | | return Result.fail("你已经登录了"); |
| | | } |
| | | |
| | | @ApiOperation(value = "注册时校验用户名是否存在") |
| | | @GetMapping("/countUsername") |
| | | public Result countUsername(String username) { |
| | | return Result.success(userService.countByUsername(username)); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import com.canadames.entity.MenuList; |
| | | import com.canadames.entity.vo.MenuListVo; |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.MenuListService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.apache.shiro.authz.annotation.RequiresRoles; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.List; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @Api(tags = "菜单") |
| | | @RequestMapping("/api/menuList") |
| | | public class MenuListController { |
| | | @Autowired |
| | | private MenuListService menuListService; |
| | | |
| | | @ApiOperation(value = "查询菜单列表") |
| | | @GetMapping("/selectList") |
| | | @RequiresPermissions({"menuList:select"}) |
| | | public Result selectList(MenuList menuList) { |
| | | return Result.success(menuListService.selectList(SecurityUtil.getCurrentUser().getRoleId())); |
| | | } |
| | | |
| | | @ApiOperation(value = "分页查询菜单") |
| | | @GetMapping("/selectPage") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"menuList:select"}) |
| | | public Result selectPage(MenuListVo MenuListVO) { |
| | | return Result.success(menuListService.selectPage(MenuListVO)); |
| | | } |
| | | |
| | | @ApiOperation(value = "根据id删除菜单") |
| | | @PostMapping("/removeById") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"menuList:delete"}) |
| | | public Result removeById(@RequestBody MenuListVo MenuListVO) { |
| | | menuListService.removeById(MenuListVO.getId()); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "添加或者更新菜单") |
| | | @PostMapping("/saveOrUpdate") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"menuList:add", "menuList:update"}) |
| | | public Result saveOrUpdate(@RequestBody MenuList menuList) { |
| | | List<MenuList> menuLists = menuListService.lambdaQuery() |
| | | .eq(MenuList::getName, menuList.getName()) |
| | | .or() |
| | | .eq(MenuList::getRouter, menuList.getRouter()) |
| | | .ne(menuList.getId() != null, MenuList::getId, menuList.getId()) |
| | | .list(); |
| | | if (CollectionUtil.isNotEmpty(menuLists)) { |
| | | return Result.fail("菜单名称或者路由已存在"); |
| | | } |
| | | menuListService.saveOrUpdate(menuList); |
| | | return Result.success(); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import com.canadames.entity.vo.PermissionVo; |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.service.PermissionService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.apache.shiro.authz.annotation.RequiresRoles; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @Api(tags = "权限") |
| | | @RequestMapping("/api/permission") |
| | | public class PermissionController { |
| | | |
| | | @Autowired |
| | | private PermissionService permissionService; |
| | | |
| | | @ApiOperation(value = "根据id查询权限") |
| | | @GetMapping("/getById") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"permission:select"}) |
| | | public Result getById(PermissionVo permissionVO) { |
| | | return Result.success(permissionService.getById(permissionVO.getId())); |
| | | } |
| | | |
| | | @ApiOperation(value = "查询权限列表") |
| | | @GetMapping("/select") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"permission:select"}) |
| | | public Result select(PermissionVo permissionVO) { |
| | | return Result.success(permissionService.lambdaQuery().list()); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import com.canadames.entity.Role; |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.entity.vo.RoleVo; |
| | | import com.canadames.service.RoleService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.apache.shiro.authz.annotation.RequiresRoles; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @Api(tags = "角色") |
| | | @RequestMapping("/api/role") |
| | | public class RoleController { |
| | | @Autowired |
| | | private RoleService roleService; |
| | | |
| | | @ApiOperation(value = "添加或者更新角色") |
| | | @PostMapping("/saveOrUpdate") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"role:add", "role:update"}) |
| | | public Result saveOrUpdate(@RequestBody Role role) { |
| | | Integer count = roleService.lambdaQuery().eq(Role::getName, role.getName()) |
| | | .ne(role.getId() != null, Role::getId, role.getId()) |
| | | .count(); |
| | | if (count > 0) return Result.fail("已存在该角色名称"); |
| | | roleService.saveOrUpdate(role); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "根据id删除角色") |
| | | @PostMapping("/removeById") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"role:delete"}) |
| | | public Result removeById(@RequestBody RoleVo roleVO) { |
| | | roleService.removeById(roleVO.getId()); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "根据id查询角色") |
| | | @GetMapping("/getById") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"role:select"}) |
| | | public Result getById(Role role) { |
| | | return Result.success(roleService.getById(role.getId())); |
| | | } |
| | | |
| | | @ApiOperation(value = "分页查询角色") |
| | | @GetMapping("/selectPage") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"role:select"}) |
| | | public Result selectPage(RoleVo roleVO) { |
| | | return Result.success(roleService.selectPage(roleVO)); |
| | | } |
| | | |
| | | @ApiOperation(value = "查询角色列表") |
| | | @GetMapping("/select") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"role:select"}) |
| | | public Result select(RoleVo roleVO) { |
| | | return Result.success(roleService.lambdaQuery().list()); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.entity.vo.RoleMenuListVo; |
| | | import com.canadames.service.RoleMenuListService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authz.annotation.RequiresRoles; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @Api(tags = "角色和菜单关系") |
| | | @RequestMapping("/api/roleMenuList") |
| | | public class RoleMenuListController { |
| | | @Autowired |
| | | private RoleMenuListService roleMenuListService; |
| | | |
| | | @ApiOperation(value = "分页查询角色和菜单关系") |
| | | @GetMapping("/selectPage") |
| | | @RequiresRoles({"admin"}) |
| | | public Result selectPage(RoleMenuListVo roleMenuListVO) { |
| | | return Result.success(roleMenuListService.selectPage(roleMenuListVO)); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import com.canadames.entity.Permission; |
| | | import com.canadames.entity.Role; |
| | | import com.canadames.entity.RolePermission; |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.entity.vo.RolePermissionVo; |
| | | import com.canadames.service.PermissionService; |
| | | import com.canadames.service.RolePermissionService; |
| | | import com.canadames.service.RoleService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.apache.shiro.authz.annotation.RequiresRoles; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @Api(tags = "角色和权限关系") |
| | | @RequestMapping("/api/rolePermission") |
| | | public class RolePermissionController { |
| | | @Autowired |
| | | private RolePermissionService rolePermissionService; |
| | | @Autowired |
| | | private RoleService roleService; |
| | | @Autowired |
| | | private PermissionService permissionService; |
| | | |
| | | @ApiOperation(value = "添加或者更新角色和权限关系") |
| | | @PostMapping("/saveOrUpdate") |
| | | @RequiresPermissions({"rolePermission:add"}) |
| | | @RequiresRoles({"admin"}) |
| | | public Result saveOrUpdate(@RequestBody RolePermission rolePermission) { |
| | | Integer count = rolePermissionService.lambdaQuery() |
| | | .eq(RolePermission::getRoleId, rolePermission.getRoleId()) |
| | | .eq(RolePermission::getPermissionId, rolePermission.getPermissionId()) |
| | | .ne(rolePermission.getId() != null, RolePermission::getId, rolePermission.getId()) |
| | | .count(); |
| | | if (count > 0) return Result.fail("授权已存在"); |
| | | rolePermissionService.saveOrUpdate(rolePermission); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "根据id删除角色和权限关系") |
| | | @PostMapping("/removeById") |
| | | @RequiresPermissions({"rolePermission:delete"}) |
| | | @RequiresRoles({"admin"}) |
| | | public Result removeById(@RequestBody RolePermissionVo rolePermissionVO) { |
| | | rolePermissionService.removeById(rolePermissionVO.getId()); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "分页查询角色和权限关系") |
| | | @GetMapping("/selectPage") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"rolePermission:select"}) |
| | | public Result selectPage(RolePermissionVo rolePermissionVO) { |
| | | return Result.success(rolePermissionService.selectPage(rolePermissionVO)); |
| | | } |
| | | |
| | | @ApiOperation(value = "根据id查询角色和权限关系") |
| | | @GetMapping("/getById") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"rolePermission:select"}) |
| | | public Result getById(RolePermissionVo rolePermissionVO) { |
| | | RolePermission rolePermission = rolePermissionService.getById(rolePermissionVO.getId()); |
| | | if (rolePermission != null) { |
| | | Role role = roleService.getById(rolePermission.getRoleId()); |
| | | Permission permission = permissionService.getById(rolePermission.getPermissionId()); |
| | | rolePermission.setRole(role); |
| | | rolePermission.setPermission(permission); |
| | | } |
| | | return Result.success(rolePermission); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.controller; |
| | | |
| | | import com.canadames.entity.User; |
| | | import com.canadames.entity.vo.Result; |
| | | import com.canadames.entity.vo.RoleVo; |
| | | import com.canadames.entity.vo.UserVo; |
| | | import com.canadames.security.constant.SystemConstant; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.UserService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.SecurityUtils; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.apache.shiro.authz.annotation.RequiresRoles; |
| | | import org.apache.shiro.crypto.hash.SimpleHash; |
| | | import org.apache.shiro.util.ByteSource; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | @RestController |
| | | @Slf4j |
| | | @RequestMapping("/api/user") |
| | | @Api(tags = "用户") |
| | | public class UserController { |
| | | @Autowired |
| | | private UserService userService; |
| | | |
| | | @ApiOperation(value = "分页查询用户") |
| | | @GetMapping("/selectPage") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"user:select"}) |
| | | public Result selectPage(UserVo userVO) { |
| | | return Result.success(userService.selectPage(userVO)); |
| | | } |
| | | |
| | | @ApiOperation(value = "添加或或者修改用户") |
| | | @PostMapping("/saveOrUpdate") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"user:update", "user:add"}) |
| | | public Result saveOrUpdate(@RequestBody User user) { |
| | | if ("admin".equals(user.getUsername())) { |
| | | return Result.fail("管理员不可以被禁用"); |
| | | } |
| | | Integer count = userService.lambdaQuery().eq(User::getUsername, user.getUsername()) |
| | | .ne(user.getId() != null, User::getId, user.getId()) |
| | | .count(); |
| | | if (count > 0) return Result.fail("用户名已存在"); |
| | | // 通过shiro默认的加密工具类为注册用户的密码进行加密 |
| | | Object salt = ByteSource.Util.bytes(SystemConstant.JWT_SECRET_KEY); |
| | | String md5 = new SimpleHash("MD5", user.getPassword(), salt, 1024).toHex(); |
| | | user.setPassword(md5); |
| | | userService.saveOrUpdate(user); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "通过id删除用户") |
| | | @PostMapping("/removeById") |
| | | @RequiresRoles({"admin"}) |
| | | @RequiresPermissions({"user:delete"}) |
| | | public Result removeById(@RequestBody UserVo userVO) { |
| | | userService.removeById(userVO.getId()); |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation(value = "通过id查询用户") |
| | | @GetMapping("/getById") |
| | | @RequiresPermissions({"user:select"}) |
| | | public Result selectById(UserVo userVO) { |
| | | return Result.success(userService.getById(userVO.getId())); |
| | | } |
| | | |
| | | |
| | | |
| | | @ApiOperation(value = "注销登录,前提是在登录状态") |
| | | @PostMapping("/loginOut") |
| | | public Result loginOut() { |
| | | User currentUser = SecurityUtil.getCurrentUser(); |
| | | if (currentUser == null) { |
| | | return Result.fail("您暂未登录"); |
| | | } |
| | | SecurityUtils.getSubject().logout(); |
| | | return Result.success("注销成功"); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.canadames.entity.Category; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface CategoryDao extends BaseMapper<Category> { |
| | | void categoryDeleteByIds(@Param("ids") List<Long> ids); |
| | | |
| | | void categoryUpdateById(@Param("id") Long id, @Param("category") Category category); |
| | | |
| | | void categoryInsert(@Param("category") Category category); |
| | | |
| | | List<Category> findAllExceptSelf(@Param("id") Long id); |
| | | |
| | | List<Category> selectByPath(@Param("path") String path); |
| | | } |
| New file |
| | |
| | | package com.canadames.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.canadames.entity.MenuList; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface MenuListDao extends BaseMapper<MenuList> { |
| | | List<MenuList> findByParent(Long parent); |
| | | |
| | | List<MenuList> findByParentNull(); |
| | | } |
| New file |
| | |
| | | package com.canadames.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.canadames.entity.Permission; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface PermissionDao extends BaseMapper<Permission> { |
| | | } |
| New file |
| | |
| | | package com.canadames.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.canadames.entity.Role; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface RoleDao extends BaseMapper<Role> { |
| | | } |
| New file |
| | |
| | | package com.canadames.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.canadames.entity.RoleMenuList; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface RoleMenuListDao extends BaseMapper<RoleMenuList> { |
| | | } |
| New file |
| | |
| | | package com.canadames.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.canadames.entity.RolePermission; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface RolePermissionDao extends BaseMapper<RolePermission> { |
| | | } |
| New file |
| | |
| | | package com.canadames.dao; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.canadames.entity.User; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface UserDao extends BaseMapper<User> { |
| | | List<User> selectChild(@Param("path") String path); |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Date; |
| | | |
| | | @Data |
| | | public class BaseEntity { |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | @ApiModelProperty("主键") |
| | | private Long id; |
| | | @ApiModelProperty("创建时间") |
| | | private Date createTime; |
| | | @ApiModelProperty("更新时间") |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import javax.validation.constraints.NotNull; |
| | | import java.io.Serializable; |
| | | import java.util.List; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | @TableName("`category`") |
| | | @ApiModel("分类") |
| | | public class Category extends BaseEntity implements Serializable { |
| | | private static final long serialVersionUID = -5888981197198625157L; |
| | | |
| | | @ApiModelProperty("父级id") |
| | | private Long parentId; |
| | | @TableField("`path`") |
| | | @ApiModelProperty("路径") |
| | | private String path; |
| | | @ApiModelProperty("等级") |
| | | private Integer level; |
| | | @ApiModelProperty("名称") |
| | | private String name; |
| | | @ApiModelProperty("创建人") |
| | | private Long creator; |
| | | @ApiModelProperty("状态 0/下架 1/上架 默认上架") |
| | | private Integer state; // 状态 0/下架 1/上架 默认上架 |
| | | |
| | | @TableField(exist = false) |
| | | private List<Category> Categorys; |
| | | |
| | | public final void parent(@NotNull Category category) { |
| | | this.parentId = category.getId(); |
| | | this.path = (category.getPath() == null ? "" : category.getPath()) + category.getId() + "-"; |
| | | this.level = StrUtil.count(this.path, "-"); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | @TableName("`menu_list`") |
| | | @ApiModel("菜单") |
| | | public class MenuList extends BaseEntity implements Serializable { |
| | | private static final long serialVersionUID = 6371298069578228652L; |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | private Long parentId; |
| | | private String name; |
| | | private String icon; |
| | | private Integer priority; |
| | | private String router; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | |
| | | @TableField(exist = false) |
| | | private List<MenuList> menuLists; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | @TableName("`permission`") |
| | | @ApiModel("权限") |
| | | public class Permission extends BaseEntity implements Serializable { |
| | | private static final long serialVersionUID = 4551749462814959751L; |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | private String name; |
| | | private String description; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import javax.validation.constraints.NotBlank; |
| | | import java.io.Serializable; |
| | | import java.util.List; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | @TableName("`role`") |
| | | @ApiModel("角色") |
| | | public class Role extends BaseEntity implements Serializable { |
| | | private static final long serialVersionUID = 5593937318976491954L; |
| | | |
| | | @ApiModelProperty("父级id") |
| | | private String parentId; |
| | | @NotBlank |
| | | @ApiModelProperty("名称") |
| | | private String name; |
| | | @ApiModelProperty("描述") |
| | | private String description; |
| | | @ApiModelProperty("状态") |
| | | private Integer state; |
| | | |
| | | @TableField(exist = false) |
| | | private List<Permission> permissions; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | @TableName("`role_menu_list`") |
| | | @ApiModel("角色和菜单关系") |
| | | public class RoleMenuList extends BaseEntity implements Serializable { |
| | | private static final long serialVersionUID = 8055008415890637135L; |
| | | |
| | | @ApiModelProperty("角色id") |
| | | private Long roleId; |
| | | @ApiModelProperty("菜单id") |
| | | private Long menuListId; |
| | | @ApiModelProperty("状态") |
| | | private Integer state; |
| | | |
| | | @TableField(exist = false) |
| | | private Role role; |
| | | @TableField(exist = false) |
| | | private MenuList menuList; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | @TableName("`role_permission`") |
| | | @ApiModel("角色和权限关系") |
| | | public class RolePermission extends BaseEntity implements Serializable { |
| | | private static final long serialVersionUID = -3026205404689502862L; |
| | | @ApiModelProperty("角色id") |
| | | private Long roleId; |
| | | @ApiModelProperty("权限id") |
| | | private Long permissionId; |
| | | @ApiModelProperty("状态") |
| | | private Integer state; |
| | | |
| | | @TableField(exist = false) |
| | | private Role role; |
| | | @TableField(exist = false) |
| | | private Permission permission; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import javax.validation.constraints.Email; |
| | | import javax.validation.constraints.NotBlank; |
| | | import javax.validation.constraints.NotNull; |
| | | import java.io.Serializable; |
| | | import java.util.List; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | @TableName("`user`") |
| | | @ApiModel("用户") |
| | | public class User extends BaseEntity implements Serializable { |
| | | private static final long serialVersionUID = 1192800251115892576L; |
| | | private Long parentId; // 上级id |
| | | @TableField("`path`") |
| | | @ApiModelProperty("路径") |
| | | private String path; |
| | | @ApiModelProperty("等级") |
| | | private Integer level; |
| | | @ApiModelProperty("角色id") |
| | | private Long roleId; |
| | | @NotBlank(message = "用户名不能为空") |
| | | @ApiModelProperty("用户名") |
| | | private String username; |
| | | @NotBlank(message = "密码不能为空") |
| | | @ApiModelProperty("密码") |
| | | private String password; |
| | | @NotBlank(message = "邮箱不能为空") |
| | | @Email(message = "邮箱格式不正确") |
| | | @ApiModelProperty("邮箱") |
| | | private String email; |
| | | @ApiModelProperty("qq") |
| | | private String qq; |
| | | @ApiModelProperty("联系电话") |
| | | private String phone; |
| | | @ApiModelProperty("状态 0/禁止 1/正常") |
| | | private Integer state; // 状态 0/禁止 1/正常 |
| | | |
| | | |
| | | // 用户的菜单列表,不同用户通过权限控制拥有不同的菜单 |
| | | @TableField(exist = false) |
| | | private List<MenuList> menuLists; |
| | | |
| | | public final void parent(@NotNull User user) { |
| | | this.parentId = user.getId(); |
| | | this.path = (user.getPath() == null ? "" : user.getPath()) + user.getId() + "-"; |
| | | this.level = StrUtil.count(this.path, "-"); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.dto; |
| | | |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotNull; |
| | | import javax.validation.constraints.Past; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | public class BaseDto { |
| | | @NotNull |
| | | private Long pageSize = 10L; |
| | | @NotNull |
| | | private Long pageNum = 1L; |
| | | @Past |
| | | private Date startTime; |
| | | @Past |
| | | private Date endTime; |
| | | |
| | | private List<Long> ids; |
| | | |
| | | private Long id; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | @Data |
| | | public class AuthorizedUser implements Serializable { |
| | | private static final long serialVersionUID = -8152270249992675066L; |
| | | private Long id; |
| | | private String username; |
| | | private Long roleId; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotNull; |
| | | import javax.validation.constraints.Past; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | public class BaseVo { |
| | | @NotNull |
| | | private Long pageSize = 10L; |
| | | @NotNull |
| | | private Long pageNum = 1L; |
| | | @Past |
| | | private Date startTime; |
| | | @Past |
| | | private Date endTime; |
| | | |
| | | private List<Long> ids; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class CategoryVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = 4432159672935772196L; |
| | | private Long id; |
| | | private Long parentId; |
| | | private String path; |
| | | private Integer level; |
| | | private String name; |
| | | private Long creator; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import io.jsonwebtoken.Claims; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | import lombok.ToString; |
| | | |
| | | @Getter |
| | | @Setter |
| | | @ToString |
| | | public class CheckResult { |
| | | private boolean success; |
| | | private Claims claims; |
| | | private String errCode; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class MenuListVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = 3086526136023139210L; |
| | | private Long id; |
| | | private Long roleId; |
| | | private Long parentId; |
| | | private String name; |
| | | private String icon; |
| | | private Integer priority; |
| | | private String router; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class OrderVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = -3640807116600926284L; |
| | | private Long id; |
| | | private Long productId; |
| | | private Long creator; |
| | | private Long quantity; |
| | | private String subject; |
| | | private String address; |
| | | private String outTradeNo; |
| | | private String totalAmount; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class PermissionVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = -2797154122372472654L; |
| | | private Long id; |
| | | private String name; |
| | | private String description; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.math.BigDecimal; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class ProductVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = -4492232772022212494L; |
| | | private Long id; |
| | | private Long categoryId; |
| | | private String name; |
| | | private BigDecimal price; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | public class Result { |
| | | private Integer code; |
| | | private String msg; |
| | | private Object data; |
| | | |
| | | public static Result success(Object data) { |
| | | Result result = new Result(); |
| | | result.setCode(1); |
| | | result.setMsg("成功"); |
| | | result.setData(data); |
| | | return result; |
| | | } |
| | | |
| | | public static Result success() { |
| | | return success(null); |
| | | } |
| | | |
| | | public static Result fail(String msg) { |
| | | Result result = new Result(); |
| | | result.setCode(0); |
| | | result.setMsg(msg); |
| | | return result; |
| | | } |
| | | |
| | | public static Result fail(Integer code, String msg, Object object) { |
| | | Result result = new Result(); |
| | | result.setCode(0); |
| | | result.setMsg(msg); |
| | | result.setData(object); |
| | | return result; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class RoleMenuListVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = 2310103009618403876L; |
| | | private Long id; |
| | | private Long roleId; |
| | | private Long MenuListId; |
| | | private Integer state; |
| | | private Date startTime; |
| | | private Date endTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class RolePermissionVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = -4528470984796447897L; |
| | | private Long id; |
| | | private Long roleId; |
| | | private Long permissionId; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class RoleVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = 2147982144935437262L; |
| | | private Long id; |
| | | private String parentId; |
| | | private String name; |
| | | private Integer state; |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | } |
| New file |
| | |
| | | package com.canadames.entity.vo; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | import javax.validation.constraints.NotBlank; |
| | | import java.io.Serializable; |
| | | import java.util.Date; |
| | | |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @Data |
| | | public class UserVo extends BaseVo implements Serializable { |
| | | private static final long serialVersionUID = 7021223076084300328L; |
| | | private Long id; |
| | | private Long parentId; // 上级id |
| | | private Long roleId; // 角色id |
| | | @NotBlank(message = "用户名不能为空") |
| | | private String username; |
| | | @NotBlank(message = "密码不能为空") |
| | | private String password; |
| | | private String email; |
| | | private String qq; |
| | | private String phone; |
| | | private Integer state; // 状态 0/禁止 1/正常 |
| | | private Date createTime; |
| | | private Date updateTime; |
| | | |
| | | } |
| New file |
| | |
| | | package com.canadames.security; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.canadames.entity.Permission; |
| | | import com.canadames.entity.Role; |
| | | import com.canadames.entity.RolePermission; |
| | | import com.canadames.entity.User; |
| | | import com.canadames.security.entity.JwtToken; |
| | | import com.canadames.security.util.JwtUtil; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.PermissionService; |
| | | import com.canadames.service.RolePermissionService; |
| | | import com.canadames.service.RoleService; |
| | | import com.canadames.service.UserService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authc.AuthenticationException; |
| | | import org.apache.shiro.authc.AuthenticationInfo; |
| | | import org.apache.shiro.authc.AuthenticationToken; |
| | | import org.apache.shiro.authc.SimpleAuthenticationInfo; |
| | | import org.apache.shiro.authz.AuthorizationInfo; |
| | | import org.apache.shiro.authz.SimpleAuthorizationInfo; |
| | | import org.apache.shiro.realm.AuthorizingRealm; |
| | | import org.apache.shiro.subject.PrincipalCollection; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | |
| | | import java.util.HashSet; |
| | | import java.util.List; |
| | | import java.util.Set; |
| | | import java.util.stream.Collectors; |
| | | |
| | | @Slf4j |
| | | public class JWTRealm extends AuthorizingRealm { |
| | | @Autowired |
| | | private UserService userService; |
| | | @Autowired |
| | | private RolePermissionService rolePermissionService; |
| | | @Autowired |
| | | private PermissionService permissionService; |
| | | @Autowired |
| | | private RoleService roleService; |
| | | |
| | | @Override |
| | | public boolean supports(AuthenticationToken token) { |
| | | return token instanceof JwtToken; |
| | | } |
| | | |
| | | @Override |
| | | protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principalCollection) { |
| | | // 执行授权 |
| | | SimpleAuthorizationInfo authorizationInfo = new SimpleAuthorizationInfo(); |
| | | // 设置角色 |
| | | List<Role> roles = roleService.selectRoles(SecurityUtil.getCurrentUser().getRoleId(), true); |
| | | if (CollectionUtil.isEmpty(roles)) { |
| | | return null; |
| | | } |
| | | authorizationInfo.addRoles(roles.stream().map(Role::getName).collect(Collectors.toList())); |
| | | List<RolePermission> rolePermissions = rolePermissionService.lambdaQuery() |
| | | .eq(RolePermission::getState, 1) |
| | | .eq(RolePermission::getRoleId, SecurityUtil.getCurrentUser().getRoleId()).list(); |
| | | Set<Permission> set = new HashSet<>(); |
| | | for (RolePermission rolePermission : rolePermissions) { |
| | | List<Permission> permissions = permissionService.lambdaQuery().eq(Permission::getId, rolePermission.getPermissionId()).list(); |
| | | set.addAll(permissions); |
| | | } |
| | | // 设置权限 |
| | | authorizationInfo.addStringPermissions(set.stream().map(Permission::getName).collect(Collectors.toList())); |
| | | return authorizationInfo; |
| | | } |
| | | |
| | | @Override |
| | | protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken authenticationToken) throws AuthenticationException { |
| | | String token = (String) authenticationToken.getCredentials(); |
| | | // 解密获得username,用于和数据库进行对比 |
| | | String username = JwtUtil.getUsernameByToken(token); |
| | | if (StrUtil.isBlank(username)) { |
| | | throw new AuthenticationException("token认证失败!"); |
| | | } |
| | | User user = userService.selectByUsername(username); |
| | | // 判断用户 |
| | | if (user == null) { |
| | | throw new AuthenticationException("用户不存在!"); |
| | | } |
| | | if (user.getState() == 0) { |
| | | throw new AuthenticationException("账号已被禁用!"); |
| | | } |
| | | return new SimpleAuthenticationInfo(user, token, getName()); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.security; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.canadames.security.constant.SystemConstant; |
| | | import com.canadames.security.entity.JwtToken; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.SecurityUtils; |
| | | import org.apache.shiro.web.filter.authc.BasicHttpAuthenticationFilter; |
| | | import org.springframework.http.HttpStatus; |
| | | import org.springframework.web.bind.annotation.RequestMethod; |
| | | |
| | | import javax.servlet.ServletRequest; |
| | | import javax.servlet.ServletResponse; |
| | | import javax.servlet.http.Cookie; |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.PrintWriter; |
| | | |
| | | @Slf4j |
| | | public class NoSessionFilter extends BasicHttpAuthenticationFilter { |
| | | |
| | | @Override |
| | | protected boolean isAccessAllowed(ServletRequest request, ServletResponse response, Object mappedValue) { |
| | | HttpServletRequest servletRequest = (HttpServletRequest) request; |
| | | // 1.从Cookie获取token |
| | | String token = getTokenFromCookie(servletRequest); |
| | | if (StrUtil.isBlank(token)) { |
| | | // 2.从headers中获取 |
| | | token = servletRequest.getHeader(SystemConstant.TOKEN_HEADER); |
| | | } |
| | | if (StrUtil.isBlank(token)) { |
| | | // 3.从请求参数获取 |
| | | token = request.getParameter(SystemConstant.TOKEN_HEADER); |
| | | } |
| | | if (StrUtil.isBlank(token)) { |
| | | return false; |
| | | } |
| | | // 验证token |
| | | JwtToken jwtToken = new JwtToken(token); |
| | | // 提交给realm进行登入,如果错误他会抛出异常并被捕获 |
| | | // todo https://www.cnblogs.com/red-star/p/12121941.html https://blog.csdn.net/qq_43721032/article/details/110188342 |
| | | try { |
| | | SecurityUtils.getSubject().login(jwtToken); |
| | | } catch (Exception e) { |
| | | return false; |
| | | } |
| | | // 如果没有抛出异常则代表登入成功,返回true |
| | | return true; |
| | | } |
| | | |
| | | @Override |
| | | protected boolean onAccessDenied(ServletRequest request, ServletResponse response) throws Exception { |
| | | PrintWriter printWriter = response.getWriter(); |
| | | response.setCharacterEncoding("utf-8"); |
| | | printWriter.write("403"); |
| | | printWriter.flush(); |
| | | printWriter.close(); |
| | | return false; |
| | | } |
| | | |
| | | private String getTokenFromCookie(HttpServletRequest request) { |
| | | String token = null; |
| | | Cookie[] cookies = request.getCookies(); |
| | | int len = null == cookies ? 0 : cookies.length; |
| | | if (len > 0) { |
| | | for (Cookie cookie : cookies) { |
| | | if (cookie.getName().equals(SystemConstant.TOKEN_HEADER)) { |
| | | token = cookie.getValue(); |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | return token; |
| | | } |
| | | |
| | | /** |
| | | * 对跨域提供支持 |
| | | */ |
| | | @Override |
| | | protected boolean preHandle(ServletRequest request, ServletResponse response) throws Exception { |
| | | HttpServletRequest httpServletRequest = (HttpServletRequest) request; |
| | | HttpServletResponse httpServletResponse = (HttpServletResponse) response; |
| | | httpServletResponse.setHeader("Access-control-Allow-Origin", httpServletRequest.getHeader("Origin")); |
| | | httpServletResponse.setHeader("Access-Control-Allow-Methods", "GET,POST,OPTIONS,PUT,DELETE"); |
| | | httpServletResponse.setHeader("Access-Control-Allow-Headers", httpServletRequest.getHeader("Access-Control-Request-Headers")); |
| | | // 跨域时会首先发送一个option请求,这里我们给option请求直接返回正常状态 |
| | | if (httpServletRequest.getMethod().equals(RequestMethod.OPTIONS.name())) { |
| | | httpServletResponse.setStatus(HttpStatus.OK.value()); |
| | | return false; |
| | | } |
| | | return super.preHandle(request, response); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.security; |
| | | |
| | | import org.apache.shiro.subject.Subject; |
| | | import org.apache.shiro.subject.SubjectContext; |
| | | import org.apache.shiro.web.mgt.DefaultWebSubjectFactory; |
| | | |
| | | public class StatelessDefaultSubjectFactory extends DefaultWebSubjectFactory { |
| | | @Override |
| | | public Subject createSubject(SubjectContext context) { |
| | | //不创建session |
| | | context.setSessionCreationEnabled(false); |
| | | return super.createSubject(context); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.security; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import com.canadames.entity.MenuList; |
| | | import com.canadames.entity.Permission; |
| | | import com.canadames.entity.Role; |
| | | import com.canadames.entity.RoleMenuList; |
| | | import com.canadames.entity.RolePermission; |
| | | import com.canadames.entity.User; |
| | | import com.canadames.security.constant.SystemConstant; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.MenuListService; |
| | | import com.canadames.service.PermissionService; |
| | | import com.canadames.service.RoleMenuListService; |
| | | import com.canadames.service.RolePermissionService; |
| | | import com.canadames.service.RoleService; |
| | | import com.canadames.service.UserService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.authc.AuthenticationInfo; |
| | | import org.apache.shiro.authc.AuthenticationToken; |
| | | import org.apache.shiro.authc.DisabledAccountException; |
| | | import org.apache.shiro.authc.SimpleAuthenticationInfo; |
| | | import org.apache.shiro.authc.UnknownAccountException; |
| | | import org.apache.shiro.authc.UsernamePasswordToken; |
| | | import org.apache.shiro.authz.AuthorizationInfo; |
| | | import org.apache.shiro.authz.SimpleAuthorizationInfo; |
| | | import org.apache.shiro.realm.AuthorizingRealm; |
| | | import org.apache.shiro.subject.PrincipalCollection; |
| | | import org.apache.shiro.util.ByteSource; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | |
| | | import java.util.HashSet; |
| | | import java.util.List; |
| | | import java.util.Set; |
| | | import java.util.stream.Collectors; |
| | | |
| | | @Slf4j |
| | | public class UserRealm extends AuthorizingRealm { |
| | | @Autowired |
| | | private UserService userService; |
| | | @Autowired |
| | | private RolePermissionService rolePermissionService; |
| | | @Autowired |
| | | private PermissionService permissionService; |
| | | @Autowired |
| | | private RoleService roleService; |
| | | @Autowired |
| | | private MenuListService menuListService; |
| | | @Autowired |
| | | private RoleMenuListService roleMenuListService; |
| | | |
| | | @Override |
| | | protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principalCollection) { |
| | | // 执行授权 |
| | | SimpleAuthorizationInfo authorizationInfo = new SimpleAuthorizationInfo(); |
| | | // 设置角色 |
| | | List<Role> roles = roleService.selectRoles(SecurityUtil.getCurrentUser().getRoleId(), true); |
| | | if (CollectionUtil.isEmpty(roles)) { |
| | | return null; |
| | | } |
| | | authorizationInfo.addRoles(roles.stream().map(Role::getName).collect(Collectors.toList())); |
| | | List<RolePermission> rolePermissions = rolePermissionService.lambdaQuery().eq(RolePermission::getRoleId, SecurityUtil.getCurrentUser().getRoleId()) |
| | | .eq(RolePermission::getState, 1).list(); |
| | | if (CollectionUtil.isNotEmpty(rolePermissions)) { |
| | | Set<Permission> set = new HashSet<>(); |
| | | for (RolePermission rolePermission : rolePermissions) { |
| | | List<Permission> permissions = permissionService.lambdaQuery().eq(Permission::getId, rolePermission.getPermissionId()).list(); |
| | | set.addAll(permissions); |
| | | } |
| | | // 设置权限 |
| | | authorizationInfo.addStringPermissions(set.stream().map(Permission::getName).collect(Collectors.toList())); |
| | | } |
| | | return authorizationInfo; |
| | | } |
| | | |
| | | @Override |
| | | protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken authenticationToken) { |
| | | if (authenticationToken.getPrincipal() == null) { |
| | | return null; |
| | | } |
| | | // 执行认证 |
| | | UsernamePasswordToken usernamePasswordToken = (UsernamePasswordToken) authenticationToken; |
| | | User user = userService.selectByUsername(usernamePasswordToken.getUsername()); |
| | | // 判断用户 |
| | | if (user == null) { |
| | | throw new UnknownAccountException("用户不存在!"); |
| | | } |
| | | if (user.getState() == 0) { |
| | | throw new DisabledAccountException("账号已被禁用!"); |
| | | } |
| | | |
| | | // 认证成功之后设置角色关联的菜单 |
| | | List<RoleMenuList> roleMenuLists = roleMenuListService.lambdaQuery().in(RoleMenuList::getRoleId, user.getRoleId()).list(); |
| | | if (CollectionUtil.isNotEmpty(roleMenuLists)) { |
| | | List<Long> collect = roleMenuLists.stream().map(RoleMenuList::getMenuListId).collect(Collectors.toList()); |
| | | List<MenuList> menuLists = menuListService.lambdaQuery().in(CollectionUtil.isNotEmpty(collect), MenuList::getId, collect).list(); |
| | | // 认证成功之后设置角色关联的菜单 |
| | | user.setMenuLists(CollectionUtil.isNotEmpty(collect) ? menuLists : null); |
| | | } |
| | | return new SimpleAuthenticationInfo(user, user.getPassword(), ByteSource.Util.bytes(SystemConstant.JWT_SECRET_KEY), getName()); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.security.config; |
| | | |
| | | import com.canadames.security.JWTRealm; |
| | | import com.canadames.security.NoSessionFilter; |
| | | import com.canadames.security.StatelessDefaultSubjectFactory; |
| | | import com.canadames.security.UserRealm; |
| | | import org.apache.shiro.authc.credential.HashedCredentialsMatcher; |
| | | import org.apache.shiro.codec.Base64; |
| | | import org.apache.shiro.mgt.DefaultSessionStorageEvaluator; |
| | | import org.apache.shiro.mgt.DefaultSubjectDAO; |
| | | import org.apache.shiro.spring.LifecycleBeanPostProcessor; |
| | | import org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor; |
| | | import org.apache.shiro.spring.web.ShiroFilterFactoryBean; |
| | | import org.apache.shiro.web.mgt.CookieRememberMeManager; |
| | | import org.apache.shiro.web.mgt.DefaultWebSecurityManager; |
| | | import org.apache.shiro.web.servlet.SimpleCookie; |
| | | import org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator; |
| | | import org.springframework.context.annotation.Bean; |
| | | import org.springframework.context.annotation.Configuration; |
| | | import org.springframework.context.annotation.DependsOn; |
| | | |
| | | import javax.servlet.Filter; |
| | | import java.util.Arrays; |
| | | import java.util.HashMap; |
| | | import java.util.LinkedHashMap; |
| | | import java.util.Map; |
| | | |
| | | @Configuration |
| | | public class ShiroConfig { |
| | | |
| | | |
| | | /** |
| | | * Shiro生命周期处理器 |
| | | * |
| | | * @return |
| | | */ |
| | | @Bean |
| | | public LifecycleBeanPostProcessor lifecycleBeanPostProcessor() { |
| | | return new LifecycleBeanPostProcessor(); |
| | | } |
| | | |
| | | /** |
| | | * 开启Shiro的注解(如@RequiresRoles,@RequiresPermissions),需借助SpringAOP扫描使用Shiro注解的类,并在必要时进行安全逻辑验证 |
| | | * DefaultAdvisorAutoProxyCreator的顺序必须在shiroFilterFactoryBean之前,不然SecurityUtils.getSubject().getPrincipal()获取不到参数 |
| | | * |
| | | * @return |
| | | */ |
| | | @Bean |
| | | @DependsOn({"lifecycleBeanPostProcessor"}) |
| | | public DefaultAdvisorAutoProxyCreator advisorAutoProxyCreator() { |
| | | DefaultAdvisorAutoProxyCreator advisorAutoProxyCreator = new DefaultAdvisorAutoProxyCreator(); |
| | | advisorAutoProxyCreator.setProxyTargetClass(true); |
| | | return advisorAutoProxyCreator; |
| | | } |
| | | |
| | | @Bean |
| | | public AuthorizationAttributeSourceAdvisor authorizationAttributeSourceAdvisor() { |
| | | AuthorizationAttributeSourceAdvisor authorizationAttributeSourceAdvisor = new AuthorizationAttributeSourceAdvisor(); |
| | | authorizationAttributeSourceAdvisor.setSecurityManager(defaultSecurityManager()); |
| | | return authorizationAttributeSourceAdvisor; |
| | | } |
| | | |
| | | @Bean(name = "shiroFilterFactoryBean") |
| | | public ShiroFilterFactoryBean shiroFilterFactoryBean() { |
| | | ShiroFilterFactoryBean shiroFilterFactoryBean = new ShiroFilterFactoryBean(); |
| | | shiroFilterFactoryBean.setSecurityManager(defaultSecurityManager()); |
| | | |
| | | // 过滤规则 |
| | | Map<String, String> linkedHashMap = new LinkedHashMap<>(); |
| | | // 无状态登录情况下关闭了shiro中的session,导致所有需要加上authc接口请求时候都会报错, |
| | | // 所以使用@RequiresRoles,@RequiresPermissions注解,aop方式实现接口的权限校验 |
| | | |
| | | /* 添加shiro的内置过滤器,自定义url规则 |
| | | * Shiro自带拦截器配置规则 |
| | | * rest:比如/admins/user/**=rest[user],根据请求的方法,相当于/admins/user/**=perms[user:method] ,其中method为post,get,delete等 |
| | | * port:比如/admins/user/**=port[8081],当请求的url的端口不是8081是跳转到schemal://serverName:8081?queryString,其中schmal是协议http或https等,serverName是你访问的host,8081是url配置里port的端口,queryString是你访问的url里的?后面的参数 |
| | | * perms:比如/admins/user/**=perms[user:add:*],perms参数可以写多个,多个时必须加上引号,并且参数之间用逗号分割,比如/admins/user/**=perms["user:add:*,user:modify:*"],当有多个参数时必须每个参数都通过才通过,想当于isPermitedAll()方法 |
| | | * roles:比如/admins/user/**=roles[admin],参数可以写多个,多个时必须加上引号,并且参数之间用逗号分割,当有多个参数时,比如/admins/user/**=roles["admin,guest"],每个参数通过才算通过,相当于hasAllRoles()方法。//要实现or的效果看http://zgzty.blog.163.com/blog/static/83831226201302983358670/ |
| | | * anon:比如/admins/**=anon 没有参数,表示可以匿名使用 |
| | | * authc:比如/admins/user/**=authc表示需要认证才能使用,没有参数 |
| | | * authcBasic:比如/admins/user/**=authcBasic没有参数表示httpBasic认证 |
| | | * ssl:比如/admins/user/**=ssl没有参数,表示安全的url请求,协议为https |
| | | * user:比如/admins/user/**=user没有参数表示必须存在用户,当登入操作时不做检查 |
| | | * 详情见文档 http://shiro.apache.org/web.html#urls- |
| | | * */ |
| | | // 用户权限 |
| | | // linkedHashMap.put("/api/user/selectPage", "perms[user:select]"); |
| | | // linkedHashMap.put("/api/user/selectById", "perms[user:select]"); |
| | | // linkedHashMap.put("/api/user/updateById", "perms[user:update]"); |
| | | // linkedHashMap.put("/api/user/removeByIds", "perms[user:delete]"); |
| | | // // 商品权限 |
| | | // linkedHashMap.put("/api/product/deleteBatchIds", "perms[product:delete]"); |
| | | // linkedHashMap.put("/api/product/updateById", "perms[product:update]"); |
| | | // linkedHashMap.put("/api/product/insert", "perms[product:add]"); |
| | | // |
| | | // // 角色权限 |
| | | // linkedHashMap.put("/api/role/saveOrUpdate", "perms[role:add,role:update]"); |
| | | // linkedHashMap.put("/api/role/removeByIds", "perms[role:delete]"); |
| | | // linkedHashMap.put("/api/role/getById", "perms[role:select]"); |
| | | // linkedHashMap.put("/api/role/selectPage", "perms[role:select]"); |
| | | // |
| | | // // 菜单权限 |
| | | // linkedHashMap.put("/api/menuList/removeByIds", "perms[menuList:delete]"); |
| | | // linkedHashMap.put("/api/menuList/saveOrUpdate", "perms[menuList:add,menuList:update]"); |
| | | // |
| | | // // 订单权限 |
| | | // linkedHashMap.put("/api/order/deleteBatchIds", "perms[order:delete]"); |
| | | // linkedHashMap.put("/api/order/updateById", "perms[order:update]"); |
| | | // |
| | | // // 授权的权限 |
| | | // linkedHashMap.put("/api/rolePermission/saveOrUpdate", "perms[rolePermission:add]"); |
| | | // linkedHashMap.put("/api/rolePermission/removeByIds", "perms[rolePermission:delete]"); |
| | | |
| | | // 自定义过滤器 |
| | | HashMap<String, Filter> filterHashMap = new HashMap<>(); |
| | | filterHashMap.put("jwt", new NoSessionFilter()); |
| | | shiroFilterFactoryBean.setFilters(filterHashMap); |
| | | // 登录之后才可以请求的接口 |
| | | linkedHashMap.put("/api/**", "jwt"); |
| | | shiroFilterFactoryBean.setFilterChainDefinitionMap(linkedHashMap); |
| | | return shiroFilterFactoryBean; |
| | | } |
| | | |
| | | @Bean |
| | | public DefaultWebSecurityManager defaultSecurityManager() { |
| | | DefaultWebSecurityManager defaultWebSecurityManager = new DefaultWebSecurityManager(); |
| | | defaultWebSecurityManager.setRealms(Arrays.asList(userRealm(), jwtRealm())); |
| | | // 禁用shiro中的session |
| | | DefaultSubjectDAO defaultSubjectDAO = new DefaultSubjectDAO(); |
| | | DefaultSessionStorageEvaluator defaultSessionStorageEvaluator = new DefaultSessionStorageEvaluator(); |
| | | defaultSessionStorageEvaluator.setSessionStorageEnabled(false); |
| | | defaultSubjectDAO.setSessionStorageEvaluator(defaultSessionStorageEvaluator); |
| | | defaultWebSecurityManager.setSubjectDAO(defaultSubjectDAO); |
| | | defaultWebSecurityManager.setSubjectFactory(subjectFactory()); |
| | | return defaultWebSecurityManager; |
| | | } |
| | | |
| | | /** |
| | | * 登录的认证和授权 |
| | | * |
| | | * @return |
| | | */ |
| | | @Bean |
| | | public UserRealm userRealm() { |
| | | UserRealm userRealm = new UserRealm(); |
| | | userRealm.setCredentialsMatcher(hashedCredentialsMatcher()); |
| | | return userRealm; |
| | | } |
| | | |
| | | /** |
| | | * token的认证和授权 |
| | | * |
| | | * @return |
| | | */ |
| | | @Bean |
| | | public JWTRealm jwtRealm() { |
| | | return new JWTRealm(); |
| | | } |
| | | |
| | | @Bean |
| | | public StatelessDefaultSubjectFactory subjectFactory() { |
| | | return new StatelessDefaultSubjectFactory(); |
| | | } |
| | | |
| | | /* |
| | | * 凭证匹配器 由于我们的密码校验交给Shiro的SimpleAuthenticationInfo进行处理了 |
| | | */ |
| | | @Bean |
| | | public HashedCredentialsMatcher hashedCredentialsMatcher() { |
| | | HashedCredentialsMatcher hashedCredentialsMatcher = new HashedCredentialsMatcher(); |
| | | hashedCredentialsMatcher.setHashAlgorithmName("MD5");// 散列算法:这里使用MD5算法; |
| | | hashedCredentialsMatcher.setHashIterations(1024);// 散列的次数,比如散列两次,相当于MD5(MD5("")); |
| | | return hashedCredentialsMatcher; |
| | | } |
| | | |
| | | @Bean |
| | | public CookieRememberMeManager cookieRememberMeManager() { |
| | | CookieRememberMeManager cookieRememberMeManager = new CookieRememberMeManager(); |
| | | SimpleCookie simpleCookie = new SimpleCookie("rememberMe"); |
| | | simpleCookie.setMaxAge(259200000); |
| | | cookieRememberMeManager.setCookie(simpleCookie); |
| | | cookieRememberMeManager.setCipherKey(Base64.decode("6ZmI6I2j5Y+R5aSn5ZOlAA==")); |
| | | return cookieRememberMeManager; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.security.constant; |
| | | |
| | | public class SystemConstant { |
| | | |
| | | /** |
| | | * 角色的key |
| | | **/ |
| | | public static final String ROLE_CLAIMS = "rol"; |
| | | /** |
| | | * rememberMe 为 false 的时候过期时间是1个小时 |
| | | */ |
| | | public static final long EXPIRATION = 60 * 60L; |
| | | /** |
| | | * rememberMe 为 true 的时候过期时间是7天 |
| | | */ |
| | | public static final long EXPIRATION_REMEMBER = 60 * 60 * 24 * 7L; |
| | | |
| | | /** |
| | | * JWT签名密钥硬编码到应用程序代码中,应该存放在环境变量或.properties文件中。 |
| | | */ |
| | | public static final String JWT_SECRET_KEY = "C*F-JaNdRgUkXn2r5u8x/A?D(G+KbPeShVmYq3s6v9y$B&E)H@McQfTjWnZr4u7w"; |
| | | |
| | | // JWT token defaults |
| | | public static final String TOKEN_HEADER = "Authorization"; |
| | | public static final String TOKEN_TYPE = "JWT"; |
| | | } |
| New file |
| | |
| | | package com.canadames.security.entity; |
| | | |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.Data; |
| | | import org.apache.shiro.authc.AuthenticationToken; |
| | | |
| | | @Data |
| | | @AllArgsConstructor |
| | | public class JwtToken implements AuthenticationToken { |
| | | private static final long serialVersionUID = 3768999689537588845L; |
| | | private String token; |
| | | |
| | | @Override |
| | | public Object getPrincipal() { |
| | | return token; |
| | | } |
| | | |
| | | @Override |
| | | public Object getCredentials() { |
| | | return token; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.security.util; |
| | | |
| | | import com.canadames.security.constant.SystemConstant; |
| | | import io.jsonwebtoken.Claims; |
| | | import io.jsonwebtoken.Jwts; |
| | | import io.jsonwebtoken.SignatureAlgorithm; |
| | | import io.jsonwebtoken.security.Keys; |
| | | import lombok.Data; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.crypto.SecretKey; |
| | | import javax.xml.bind.DatatypeConverter; |
| | | import java.util.Date; |
| | | |
| | | @Data |
| | | @Component |
| | | @Slf4j |
| | | public class JwtUtil { |
| | | /** |
| | | * 生成足够的安全随机密钥,以适合符合规范的签名 |
| | | */ |
| | | private static byte[] apiKeySecretBytes = DatatypeConverter.parseBase64Binary(SystemConstant.JWT_SECRET_KEY); |
| | | private static SecretKey secretKey = Keys.hmacShaKeyFor(apiKeySecretBytes); |
| | | |
| | | /** |
| | | * 创建JWT |
| | | * |
| | | * @param subject 主体,用户名 |
| | | * @param isRememberMe 记住我 |
| | | * @return |
| | | */ |
| | | public static String createToken(String subject, boolean isRememberMe) { |
| | | long expiration = isRememberMe ? SystemConstant.EXPIRATION_REMEMBER : SystemConstant.EXPIRATION; |
| | | |
| | | String tokenPrefix = Jwts.builder() |
| | | .setHeaderParam("typ", SystemConstant.TOKEN_TYPE) |
| | | .signWith(secretKey, SignatureAlgorithm.HS256) // 设置加密方式 |
| | | .setIssuer("Authority") // //签发的人 |
| | | .setIssuedAt(new Date()) // 签发时间 |
| | | .setSubject(subject) // 主体 |
| | | .setExpiration(new Date(System.currentTimeMillis() + expiration * 1000)) // 有效时间 |
| | | .compact(); |
| | | return tokenPrefix; |
| | | } |
| | | |
| | | public static boolean isTokenExpired(String token) { |
| | | Date expiredDate = getTokenBody(token).getExpiration(); |
| | | return expiredDate.before(new Date()); |
| | | } |
| | | |
| | | public static String getUsernameByToken(String token) { |
| | | return getTokenBody(token).getSubject(); |
| | | } |
| | | |
| | | /** |
| | | * 解析JWT |
| | | * |
| | | * @param token |
| | | * @return |
| | | */ |
| | | private static Claims getTokenBody(String token) { |
| | | return Jwts.parser() |
| | | .setSigningKey(secretKey) |
| | | .parseClaimsJws(token) |
| | | .getBody(); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.security.util; |
| | | |
| | | import com.canadames.entity.User; |
| | | import org.apache.shiro.SecurityUtils; |
| | | import org.apache.shiro.subject.Subject; |
| | | |
| | | public class SecurityUtil { |
| | | /** |
| | | * 获取当前登录用户 |
| | | * |
| | | * @return |
| | | */ |
| | | public static User getCurrentUser() { |
| | | Subject subject = SecurityUtils.getSubject(); |
| | | if (!subject.isAuthenticated() && !subject.isRemembered()) { |
| | | throw new RuntimeException("Log current user error: UnAuthenticated subject"); |
| | | } |
| | | return (User) subject.getPrincipal(); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.canadames.entity.Category; |
| | | import com.canadames.entity.vo.CategoryVo; |
| | | |
| | | import java.util.List; |
| | | |
| | | public interface CategoryService extends IService<Category> { |
| | | /** |
| | | * 分页查询分类 |
| | | * |
| | | * @param categoryVO |
| | | * @return |
| | | */ |
| | | IPage<Category> selectPage(CategoryVo categoryVO); |
| | | |
| | | /** |
| | | * 查询子集,返回非嵌套数据结构 |
| | | * |
| | | * @param id |
| | | * @param bool 是否包含自己 |
| | | * @return |
| | | */ |
| | | List<Category> selectList(Long id, Boolean bool); |
| | | |
| | | /** |
| | | * 查询子集,不包含自己,返回非嵌套数据结构 |
| | | * |
| | | * @param id 分类的id |
| | | * @param path 分类的路径 |
| | | * @return |
| | | */ |
| | | List<Category> selectByPath(Long id, String path); |
| | | |
| | | /** |
| | | * 查询子集,返回嵌套数据结构 |
| | | * |
| | | * @return |
| | | */ |
| | | List<Category> selectChilds(Long creator); |
| | | |
| | | /** |
| | | * 查询子集,不包含自己,返回嵌套数据结构 |
| | | * |
| | | * @param id |
| | | * @return |
| | | */ |
| | | List<Category> selectChild(Long id); |
| | | } |
| New file |
| | |
| | | package com.canadames.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.canadames.entity.MenuList; |
| | | import com.canadames.entity.vo.MenuListVo; |
| | | |
| | | import java.util.List; |
| | | |
| | | public interface MenuListService extends IService<MenuList> { |
| | | /** |
| | | * 分页查询菜单 |
| | | * |
| | | * @param menuListVO |
| | | * @return |
| | | */ |
| | | IPage<MenuList> selectPage(MenuListVo menuListVO); |
| | | |
| | | /** |
| | | * 根据角色返回菜单,树状结构 |
| | | * |
| | | * @param roleId |
| | | * @return |
| | | */ |
| | | List<MenuList> selectList(Long roleId); |
| | | |
| | | /** |
| | | * 查询下级菜单,不包括自己 |
| | | * |
| | | * @param parentId |
| | | * @return |
| | | */ |
| | | List<MenuList> selectByParentId(Long parentId, List<Long> ids); |
| | | } |
| New file |
| | |
| | | package com.canadames.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.canadames.entity.Permission; |
| | | |
| | | public interface PermissionService extends IService<Permission> { |
| | | } |
| New file |
| | |
| | | package com.canadames.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.canadames.entity.RoleMenuList; |
| | | import com.canadames.entity.vo.RoleMenuListVo; |
| | | |
| | | public interface RoleMenuListService extends IService<RoleMenuList> { |
| | | IPage<RoleMenuList> selectPage(RoleMenuListVo roleMenuListVO); |
| | | } |
| New file |
| | |
| | | package com.canadames.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.canadames.entity.RolePermission; |
| | | import com.canadames.entity.vo.RolePermissionVo; |
| | | |
| | | public interface RolePermissionService extends IService<RolePermission> { |
| | | /** |
| | | * 分页查询 |
| | | * |
| | | * @param rolePermissionVO |
| | | * @return |
| | | */ |
| | | IPage<RolePermission> selectPage(RolePermissionVo rolePermissionVO); |
| | | } |
| New file |
| | |
| | | package com.canadames.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.canadames.entity.Role; |
| | | import com.canadames.entity.vo.RoleVo; |
| | | |
| | | import java.util.List; |
| | | import java.util.Set; |
| | | |
| | | public interface RoleService extends IService<Role> { |
| | | Set<Role> selectRolesByParentId(Set<Role> roles, Long id); |
| | | |
| | | List<Role> selectRoles(Long id, Boolean contain); |
| | | |
| | | IPage<Role> selectPage(RoleVo roleVO); |
| | | } |
| New file |
| | |
| | | package com.canadames.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.canadames.entity.User; |
| | | import com.canadames.entity.vo.UserVo; |
| | | |
| | | import java.util.List; |
| | | |
| | | public interface UserService extends IService<User> { |
| | | IPage<User> selectPage(UserVo userVO); |
| | | |
| | | User selectByUsername(String username); |
| | | |
| | | Integer countByUsername(String username); |
| | | |
| | | /** |
| | | * 查询用户及下级用户的id集合 |
| | | * |
| | | * @param id 用户id |
| | | * @param bool 是否包含自己 |
| | | * @return |
| | | */ |
| | | List<Long> selectChild(Long id, Boolean bool); |
| | | } |
| New file |
| | |
| | | package com.canadames.service.impl; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.canadames.dao.CategoryDao; |
| | | import com.canadames.entity.Category; |
| | | import com.canadames.entity.vo.CategoryVo; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.CategoryService; |
| | | import com.canadames.service.UserService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | |
| | | @Service |
| | | @Slf4j |
| | | public class CategoryServiceImpl extends ServiceImpl<CategoryDao, Category> implements CategoryService { |
| | | @Autowired |
| | | private UserService userService; |
| | | @Autowired |
| | | private CategoryDao categoryDao; |
| | | |
| | | @Override |
| | | public IPage<Category> selectPage(CategoryVo categoryVO) { |
| | | List<Long> longs = userService.selectChild(SecurityUtil.getCurrentUser().getId(), true); |
| | | return lambdaQuery().like(StrUtil.isNotBlank(categoryVO.getName()), Category::getName, categoryVO.getName()) |
| | | .in(Category::getCreator, longs) |
| | | .eq(null != categoryVO.getState(), Category::getState, categoryVO.getState()) |
| | | .eq(null != categoryVO.getParentId(), Category::getParentId, categoryVO.getParentId()) |
| | | .between(null != categoryVO.getStartTime() && null != categoryVO.getEndTime(), Category::getCreateTime, categoryVO.getStartTime(), categoryVO.getCreateTime()) |
| | | .orderByDesc(Category::getCreateTime) |
| | | .page(new Page<>(categoryVO.getPageNum(), categoryVO.getPageSize())); |
| | | } |
| | | |
| | | @Override |
| | | public List<Category> selectList(Long id, Boolean bool) { |
| | | Category category = getById(id); |
| | | List<Category> categories = selectByPath(category.getId(), category.getPath()); |
| | | if (bool) categories.add(category); |
| | | return categories; |
| | | } |
| | | |
| | | @Override |
| | | public List<Category> selectByPath(Long id, String path) { |
| | | return categoryDao.selectByPath((path == null ? "" : path) + id + "-"); |
| | | } |
| | | |
| | | @Override |
| | | public List<Category> selectChilds(Long creator) { |
| | | List<Long> longs = userService.selectChild(creator, true); |
| | | if (CollectionUtil.isNotEmpty(longs)) return new ArrayList<>(); |
| | | List<Category> categories = lambdaQuery() |
| | | .or(categoryLambdaQueryWrapper -> categoryLambdaQueryWrapper.isNull(Category::getParentId).or().eq(Category::getParentId, "")) |
| | | .in(Category::getCreator, longs) |
| | | .list(); |
| | | for (Category category : categories) { |
| | | List<Category> categories1 = selectChild(category.getId()); |
| | | category.setCategorys(categories1); |
| | | } |
| | | return categories; |
| | | } |
| | | |
| | | @Override |
| | | public List<Category> selectChild(Long id) { |
| | | List<Category> categoryList = lambdaQuery().eq(Category::getParentId, id).list(); |
| | | if (CollectionUtil.isEmpty(categoryList)) return null; |
| | | for (Category category1 : categoryList) { |
| | | List<Category> categoryList1 = selectChild(category1.getId()); |
| | | category1.setCategorys(categoryList1); |
| | | } |
| | | return categoryList; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.service.impl; |
| | | |
| | | import cn.hutool.core.collection.CollectionUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.canadames.dao.MenuListDao; |
| | | import com.canadames.dao.RoleMenuListDao; |
| | | import com.canadames.entity.MenuList; |
| | | import com.canadames.entity.Role; |
| | | import com.canadames.entity.RoleMenuList; |
| | | import com.canadames.entity.vo.MenuListVo; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.MenuListService; |
| | | import com.canadames.service.RoleService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | @Service |
| | | @Slf4j |
| | | public class MenuListServiceImpl extends ServiceImpl<MenuListDao, MenuList> implements MenuListService { |
| | | @Autowired |
| | | private RoleService roleService; |
| | | @Autowired |
| | | private RoleMenuListDao roleMenuListDao; |
| | | |
| | | @Override |
| | | public IPage<MenuList> selectPage(MenuListVo menuListVO) { |
| | | return lambdaQuery() |
| | | .like(StrUtil.isNotBlank(menuListVO.getName()), MenuList::getName, menuListVO.getName()) |
| | | .eq(null != menuListVO.getState(), MenuList::getState, menuListVO.getState()) |
| | | .between(null != menuListVO.getStartTime() && null != menuListVO.getEndTime(), MenuList::getCreateTime, menuListVO.getStartTime(), menuListVO.getEndTime()) |
| | | .orderByAsc(MenuList::getParentId).last(",create_time desc") |
| | | .page(new Page<>(menuListVO.getPageNum(), menuListVO.getPageSize())); |
| | | } |
| | | |
| | | @Override |
| | | public List<MenuList> selectList(Long roleId) { |
| | | List<Role> roles = roleService.selectRoles(roleId == null ? SecurityUtil.getCurrentUser().getRoleId() : roleId, true); |
| | | List<Long> ids = roles.stream().map(Role::getId).collect(Collectors.toList()); |
| | | List<RoleMenuList> roleMenuLists = roleMenuListDao.selectList(new QueryWrapper<RoleMenuList>().lambda() |
| | | .in(RoleMenuList::getRoleId, ids)); |
| | | List<Long> collect = roleMenuLists.stream().map(RoleMenuList::getMenuListId).collect(Collectors.toList()); |
| | | if (CollectionUtil.isEmpty(collect)) return new ArrayList<>(); |
| | | List<MenuList> menuLists = lambdaQuery() |
| | | .or(menuListLambdaQueryWrapper -> menuListLambdaQueryWrapper.isNull(MenuList::getParentId).or().eq(MenuList::getParentId, "")) |
| | | .in(MenuList::getId, collect) |
| | | .list(); |
| | | for (MenuList menuList : menuLists) { |
| | | List<MenuList> list = selectByParentId(menuList.getId(), collect); |
| | | menuList.setMenuLists(list); |
| | | } |
| | | return menuLists; |
| | | } |
| | | |
| | | @Override |
| | | public List<MenuList> selectByParentId(Long parentId, List<Long> ids) { |
| | | List<MenuList> list = lambdaQuery().eq(MenuList::getParentId, parentId).in(MenuList::getId, ids).list(); |
| | | if (CollectionUtil.isEmpty(list)) return null; |
| | | for (MenuList menuList : list) { |
| | | List<MenuList> menuLists = selectByParentId(menuList.getId(), ids); |
| | | menuList.setMenuLists(menuLists); |
| | | } |
| | | return list; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.canadames.dao.PermissionDao; |
| | | import com.canadames.entity.Permission; |
| | | import com.canadames.service.PermissionService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | @Service |
| | | @Slf4j |
| | | public class PermissionServiceImpl extends ServiceImpl<PermissionDao, Permission> implements PermissionService { |
| | | } |
| New file |
| | |
| | | package com.canadames.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.canadames.dao.MenuListDao; |
| | | import com.canadames.dao.RoleDao; |
| | | import com.canadames.dao.RoleMenuListDao; |
| | | import com.canadames.entity.RoleMenuList; |
| | | import com.canadames.entity.vo.RoleMenuListVo; |
| | | import com.canadames.service.RoleMenuListService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | @Service |
| | | @Slf4j |
| | | public class RoleMenuListServiceImpl extends ServiceImpl<RoleMenuListDao, RoleMenuList> implements RoleMenuListService { |
| | | @Autowired |
| | | private MenuListDao menuListDao; |
| | | @Autowired |
| | | private RoleDao roleDao; |
| | | |
| | | @Override |
| | | public IPage<RoleMenuList> selectPage(RoleMenuListVo roleMenuListVO) { |
| | | IPage<RoleMenuList> roleMenuListIPage = lambdaQuery().page(new Page<>(roleMenuListVO.getPageNum(), roleMenuListVO.getPageSize())); |
| | | roleMenuListIPage.getRecords().forEach(rm -> { |
| | | rm.setMenuList(menuListDao.selectById(rm.getMenuListId())); |
| | | rm.setRole(roleDao.selectById(rm.getRoleId())); |
| | | }); |
| | | return roleMenuListIPage; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.canadames.dao.RolePermissionDao; |
| | | import com.canadames.entity.RolePermission; |
| | | import com.canadames.entity.vo.RolePermissionVo; |
| | | import com.canadames.service.PermissionService; |
| | | import com.canadames.service.RolePermissionService; |
| | | import com.canadames.service.RoleService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | @Service |
| | | @Slf4j |
| | | public class RolePermissionServiceImpl extends ServiceImpl<RolePermissionDao, RolePermission> implements RolePermissionService { |
| | | @Autowired |
| | | private RoleService roleService; |
| | | @Autowired |
| | | private PermissionService permissionService; |
| | | |
| | | @Override |
| | | public IPage<RolePermission> selectPage(RolePermissionVo rolePermissionVO) { |
| | | IPage<RolePermission> rolePermissionIPage = lambdaQuery() |
| | | .orderByAsc(RolePermission::getRoleId) |
| | | .page(new Page<>(rolePermissionVO.getPageNum(), rolePermissionVO.getPageSize())); |
| | | rolePermissionIPage.getRecords().forEach(rolePermission -> { |
| | | rolePermission.setRole(roleService.getById(rolePermission.getRoleId())); |
| | | rolePermission.setPermission(permissionService.getById(rolePermission.getPermissionId())); |
| | | }); |
| | | return rolePermissionIPage; |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.service.impl; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.canadames.dao.RoleDao; |
| | | import com.canadames.entity.Role; |
| | | import com.canadames.entity.vo.RoleVo; |
| | | import com.canadames.service.RoleService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.HashSet; |
| | | import java.util.List; |
| | | import java.util.Set; |
| | | |
| | | @Service |
| | | @Slf4j |
| | | public class RoleServiceImpl extends ServiceImpl<RoleDao, Role> implements RoleService { |
| | | @Autowired |
| | | private RoleDao roleDao; |
| | | |
| | | @Override |
| | | public Set<Role> selectRolesByParentId(Set<Role> roles, Long id) { |
| | | List<Role> list = lambdaQuery().eq(Role::getParentId, id).eq(Role::getState, 1).list(); |
| | | roles.addAll(list); |
| | | for (Role role : list) { |
| | | Set<Role> roles1 = selectRolesByParentId(roles, role.getId()); |
| | | roles.addAll(roles1); |
| | | } |
| | | return roles; |
| | | } |
| | | |
| | | @Override |
| | | public List<Role> selectRoles(Long id, Boolean contain) { |
| | | HashSet<Role> roles = new HashSet<>(); |
| | | if (contain) { |
| | | roles.add(roleDao.selectById(id)); |
| | | } |
| | | selectRolesByParentId(roles, id); |
| | | return new ArrayList<>(roles); |
| | | } |
| | | |
| | | @Override |
| | | public IPage<Role> selectPage(RoleVo roleVO) { |
| | | return lambdaQuery() |
| | | .like(StrUtil.isNotBlank(roleVO.getName()), Role::getName, roleVO.getName()) |
| | | .page(new Page<>(roleVO.getPageNum(), roleVO.getPageSize())); |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.service.impl; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.canadames.dao.UserDao; |
| | | import com.canadames.entity.User; |
| | | import com.canadames.entity.vo.UserVo; |
| | | import com.canadames.security.util.SecurityUtil; |
| | | import com.canadames.service.UserService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | @Service |
| | | @Slf4j |
| | | public class UserServiceImpl extends ServiceImpl<UserDao, User> implements UserService { |
| | | @Autowired |
| | | private UserDao userDao; |
| | | |
| | | public IPage<User> selectPage(UserVo userVO) { |
| | | List<Long> longs = selectChild(SecurityUtil.getCurrentUser().getId(), true); |
| | | return lambdaQuery() |
| | | .in(User::getId, longs) |
| | | .like(StrUtil.isNotBlank(userVO.getUsername()), User::getUsername, userVO.getUsername()) |
| | | .like(StrUtil.isNotBlank(userVO.getEmail()), User::getEmail, userVO.getEmail()) |
| | | .like(StrUtil.isNotBlank(userVO.getQq()), User::getQq, userVO.getQq()) |
| | | .like(StrUtil.isNotBlank(userVO.getPhone()), User::getPhone, userVO.getPhone()) |
| | | .eq(null != userVO.getState(), User::getState, userVO.getState()) |
| | | .eq(null != userVO.getRoleId(), User::getRoleId, userVO.getRoleId()) |
| | | .eq(null != userVO.getParentId(), User::getParentId, userVO.getParentId()) |
| | | .between(null != userVO.getStartTime() && null != userVO.getEndTime(), User::getCreateTime, userVO.getStartTime(), userVO.getEndTime()) |
| | | .orderByAsc(User::getRoleId) |
| | | .orderByDesc(User::getCreateTime) |
| | | .page(new Page<>(userVO.getPageNum(), userVO.getPageSize())); |
| | | } |
| | | |
| | | public User selectByUsername(String username) { |
| | | return lambdaQuery().select(User::getId, User::getRoleId, User::getUsername, User::getPassword, User::getState).eq(User::getUsername, username).one(); |
| | | } |
| | | |
| | | public Integer countByUsername(String username) { |
| | | return lambdaQuery().eq(User::getUsername, username).count(); |
| | | } |
| | | |
| | | public List<Long> selectChild(Long id, Boolean bool) { |
| | | User user = getById(id); |
| | | List<User> users = userDao.selectChild(user.getPath() + user.getId() + "-"); |
| | | System.out.println(users); |
| | | List<Long> ids = users.stream().map(User::getId).collect(Collectors.toList()); |
| | | if (bool) ids.add(id); |
| | | |
| | | return ids; |
| | | |
| | | } |
| | | } |
| New file |
| | |
| | | package com.canadames.util; |
| | | |
| | | import org.hibernate.validator.HibernateValidator; |
| | | |
| | | import javax.validation.ConstraintViolation; |
| | | import javax.validation.Validation; |
| | | import javax.validation.Validator; |
| | | import java.util.Set; |
| | | |
| | | /** |
| | | * hibernate-validator校验工具类 |
| | | * 参考文档:http://docs.jboss.org/hibernate/validator/5.4/reference/en-US/html_single/ |
| | | */ |
| | | public class ValidatorUtil { |
| | | private static Validator validator; |
| | | |
| | | static { |
| | | validator = Validation.byProvider(HibernateValidator.class).configure().failFast(true).buildValidatorFactory().getValidator(); |
| | | } |
| | | |
| | | /** |
| | | * ValidatorUtil.validateEntity(role); |
| | | * 在controller接口中使用此方便校验实体参数的合法校验对象 |
| | | * |
| | | * @param object 待校验对象 |
| | | * @param groups 待校验的组 |
| | | */ |
| | | public static void validateEntity(Object object, Class<?>... groups) { |
| | | Set<ConstraintViolation<Object>> constraintViolations = validator.validate(object, groups); |
| | | if (!constraintViolations.isEmpty()) { |
| | | StringBuilder msg = new StringBuilder(); |
| | | for (ConstraintViolation<Object> constraint : constraintViolations) { |
| | | msg.append(constraint.getMessage()).append(","); |
| | | } |
| | | throw new RuntimeException(msg.toString()); |
| | | } |
| | | } |
| | | } |
| New file |
| | |
| | | #\u5B9A\u4E49\u9879\u76EE\u7AEF\u53E3 |
| | | server.port=8888 |
| | | #\u5B9A\u4E49\u9879\u76EE\u7684\u8BBF\u95EE\u76EE\u5F55 |
| | | server.servlet.context-path=/canadames |
| | | ####MyBatis-Plus\u914D\u7F6E |
| | | #\u6570\u636E\u5E93\u9A71\u52A8 |
| | | spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver |
| | | #\u6570\u636E\u5E93\u8FDE\u63A5\u5730\u5740 |
| | | spring.datasource.url=jdbc:mysql://localhost:3306/canadames?useUnicode=true&characterEncoding=utf-8&serverTimezone=Asia/Shanghai |
| | | #\u6570\u636E\u5E93\u7528\u6237\u540D |
| | | spring.datasource.username=root |
| | | #\u6570\u636E\u5E93\u7528\u6237\u5BC6\u7801 |
| | | spring.datasource.password=beibo.123/ |
| | | #\u6620\u5C04\u6587\u4EF6\u7684\u4F4D\u7F6E |
| | | mybatis-plus.mapper-locations=classpath:com/canadames/dao/*Dao.xml |
| | | #\u7C7B\u578B\u522B\u540D |
| | | mybatis-plus.type-aliases-package=com.canadames.entity |
| | | #\u914D\u7F6Esql\u6253\u5370 |
| | | logging.level.com.jonssonyanyan.dao=debug |
| | | #spring\u4E2D\u9ED8\u8BA4\u662Ftrue\uFF0C\u4E5F\u5C31\u662F\u9ED8\u8BA4\u652F\u6301\u540D\u79F0\u76F8\u540C\u7684bean\u7684\u8986\u76D6\u3002\u800Cspringboot\u4E2D\u7684\u9ED8\u8BA4\u503C\u662Ffalse\uFF0C\u4E5F\u5C31\u662F\u4E0D\u652F\u6301\u540D\u79F0\u76F8\u540C\u7684bean\u88AB\u8986\u76D6 |
| | | spring.main.allow-bean-definition-overriding=true |
| | | #\u683C\u5F0F\u5316date\u65E5\u671F\u683C\u5F0F |
| | | spring.jackson.date-format=yyyy-MM-dd HH:mm:ss |
| | | spring.jackson.time-zone=GMT+8 |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.canadames.dao.CategoryDao"> |
| | | <delete id="categoryDeleteByIds"> |
| | | delete |
| | | from `category` where id in |
| | | <foreach collection="ids" open="(" close=")" separator="," item="item"> |
| | | #{item} |
| | | </foreach> |
| | | </delete> |
| | | <update id="categoryUpdateById"> |
| | | update `category` |
| | | <set> |
| | | <if test="category.name != null and category.name != ''"> |
| | | `name` = #{category.name} |
| | | </if> |
| | | <if test="category.state != null"> |
| | | , state = #{category.state} |
| | | </if> |
| | | </set> |
| | | where id = #{id} |
| | | </update> |
| | | <insert id="categoryInsert"> |
| | | insert into `category`(`name`, `state`) |
| | | values (#{category.name}, #{category.state}) |
| | | </insert> |
| | | <select id="findAllExceptSelf" resultType="com.canadames.entity.Category"> |
| | | select id, `name`, parent, `state`, create_time |
| | | from category |
| | | <where> |
| | | <if test="id != null"> |
| | | id != #{id} |
| | | </if> |
| | | </where> |
| | | </select> |
| | | <select id="selectByPath" resultType="com.canadames.entity.Category"> |
| | | select id id, |
| | | `name` name, |
| | | creator creator, |
| | | `level` level, |
| | | create_time createTime |
| | | from category |
| | | <where> |
| | | <if test="path != null and path != ''"> |
| | | category.`path` like concat('', #{path}, '%') |
| | | </if> |
| | | </where> |
| | | </select> |
| | | </mapper> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.canadames.dao.MenuListDao"> |
| | | <select id="findByParent" resultType="com.canadames.entity.MenuList"> |
| | | select id, `name`, `path` |
| | | from menu_list |
| | | where parent = #{parent} |
| | | order by priority |
| | | </select> |
| | | <select id="findByParentNull" resultType="com.canadames.entity.MenuList"> |
| | | select id, `name`, `path` |
| | | from menu_list |
| | | where parent is null |
| | | order by priority |
| | | </select> |
| | | </mapper> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.canadames.dao.PermissionDao"> |
| | | </mapper> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.canadames.dao.RoleDao"> |
| | | </mapper> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.canadames.dao.RoleMenuListDao"> |
| | | </mapper> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.canadames.dao.RolePermissionDao"> |
| | | </mapper> |
| New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.canadames.dao.UserDao"> |
| | | <select id="selectChild" resultType="com.canadames.entity.User"> |
| | | select u.id id, |
| | | u.parent_id parentId, |
| | | u.path path, |
| | | u.level level, |
| | | u.role_id role_id, |
| | | u.username username, |
| | | u.email email, |
| | | u.qq qq, |
| | | u.phone phone, |
| | | u.state state, |
| | | u.create_time createTime |
| | | from user u |
| | | <where> |
| | | <if test="path != null and path != ''"> |
| | | u.`path` like concat('', #{path}, '%') |
| | | </if> |
| | | </where> |
| | | </select> |
| | | </mapper> |
| New file |
| | |
| | | /*
|
| | | Navicat MySQL Data Transfer
|
| | |
|
| | | Source Server : 本地
|
| | | Source Server Type : MySQL
|
| | | Source Server Version : 80022
|
| | | Source Host : localhost:3306
|
| | | Source Schema : canadames
|
| | |
|
| | | Target Server Type : MySQL
|
| | | Target Server Version : 80022
|
| | | File Encoding : 65001
|
| | |
|
| | | Date: 25/08/2023 09:02:30
|
| | | */
|
| | |
|
| | | SET NAMES utf8mb4;
|
| | | SET FOREIGN_KEY_CHECKS = 0;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Table structure for category
|
| | | -- ----------------------------
|
| | | DROP TABLE IF EXISTS `category`;
|
| | | CREATE TABLE `category` (
|
| | | `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',
|
| | | `parent_id` bigint NULL DEFAULT NULL COMMENT '父级id',
|
| | | `path` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '路径',
|
| | | `level` int NULL DEFAULT NULL COMMENT '等级',
|
| | | `name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '名称',
|
| | | `creator` bigint NULL DEFAULT NULL COMMENT '创建人',
|
| | | `state` tinyint NOT NULL DEFAULT 1 COMMENT '状态:0/下架 1/上架',
|
| | | `create_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
|
| | | `update_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间',
|
| | | PRIMARY KEY (`id`) USING BTREE
|
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '商品分类' ROW_FORMAT = Dynamic;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Records of category
|
| | | -- ----------------------------
|
| | | INSERT INTO `category` VALUES (1, NULL, NULL, NULL, '测试分类', 1, 1, '2021-11-28 15:08:32', '2021-11-28 15:08:32');
|
| | |
|
| | | -- ----------------------------
|
| | | -- Table structure for menu_list
|
| | | -- ----------------------------
|
| | | DROP TABLE IF EXISTS `menu_list`;
|
| | | CREATE TABLE `menu_list` (
|
| | | `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',
|
| | | `parent_id` bigint NULL DEFAULT NULL COMMENT '父级id',
|
| | | `name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '名称',
|
| | | `icon` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '菜单图标',
|
| | | `priority` int NULL DEFAULT NULL COMMENT '优先级',
|
| | | `router` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '路由',
|
| | | `state` tinyint NOT NULL DEFAULT 1 COMMENT '状态 1/正常',
|
| | | `create_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
|
| | | `update_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间',
|
| | | PRIMARY KEY (`id`) USING BTREE
|
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 55 CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Records of menu_list
|
| | | -- ----------------------------
|
| | | INSERT INTO `menu_list` VALUES (1, NULL, '用户管理', 'el-icon-user-solid', 1, '', 1, '2021-11-28 14:30:27', '2021-11-28 15:06:04');
|
| | | INSERT INTO `menu_list` VALUES (2, NULL, '设备管理', 'el-icon-s-flag', 2, '', 1, '2023-08-23 20:11:38', '2023-08-23 20:14:45');
|
| | | INSERT INTO `menu_list` VALUES (5, NULL, '权限管理', 'el-icon-collection-tag', 5, '', 1, '2021-11-28 14:30:27', '2021-11-28 15:06:04');
|
| | | INSERT INTO `menu_list` VALUES (6, NULL, '角色管理', 'el-icon-s-flag', 6, '', 1, '2021-11-28 14:30:27', '2021-11-28 15:06:04');
|
| | | INSERT INTO `menu_list` VALUES (7, 1, '用户列表', '', 7, 'user', 1, '2021-11-28 14:30:27', '2021-11-28 15:06:04');
|
| | | INSERT INTO `menu_list` VALUES (11, 5, '权限列表', '', 11, 'power', 1, '2021-11-28 14:30:28', '2021-11-28 15:06:04');
|
| | | INSERT INTO `menu_list` VALUES (12, 6, '角色列表', '', 12, 'role', 1, '2021-11-28 14:30:28', '2021-11-28 15:06:04');
|
| | | INSERT INTO `menu_list` VALUES (49, 2, '报警信息', '', 49, 'device/alarm', 1, '2021-11-28 14:30:28', '2023-08-24 13:42:47');
|
| | | INSERT INTO `menu_list` VALUES (50, 2, '下发参数', '', 50, 'device/parameter', 0, '2021-11-28 14:30:28', '2023-08-24 13:45:57');
|
| | | INSERT INTO `menu_list` VALUES (51, 2, '开关控制', '', 51, 'device/control', 0, '2021-11-28 14:30:28', '2023-08-24 13:46:00');
|
| | | INSERT INTO `menu_list` VALUES (53, 2, 'I/O状态', NULL, 53, 'device/iostate', 0, '2023-08-24 13:03:52', '2023-08-24 13:46:04');
|
| | |
|
| | | -- ----------------------------
|
| | | -- Table structure for permission
|
| | | -- ----------------------------
|
| | | DROP TABLE IF EXISTS `permission`;
|
| | | CREATE TABLE `permission` (
|
| | | `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',
|
| | | `name` varchar(100) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '权限标识',
|
| | | `description` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '权限描述',
|
| | | `state` tinyint NOT NULL DEFAULT 1 COMMENT '状态 1/正常',
|
| | | `create_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
|
| | | `update_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间',
|
| | | PRIMARY KEY (`id`) USING BTREE
|
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 32 CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '权限' ROW_FORMAT = Dynamic;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Records of permission
|
| | | -- ----------------------------
|
| | | INSERT INTO `permission` VALUES (1, 'user:select', '用户查询', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (2, 'user:update', '用户修改', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (3, 'user:delete', '用户删除', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (7, 'role:add', '角色添加', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (8, 'role:update', '角色修改', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (9, 'role:delete', '角色删除', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (10, 'role:select', '角色查询', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (11, 'menuList:delete', '菜单删除', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (12, 'menuList:add', '菜单添加', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (13, 'menuList:update', '菜单修改', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (16, 'rolePermission:add', '授权添加', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (17, 'rolePermission:delete', '授权删除', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (18, 'rolePermission:select', '授权查询', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (19, 'permission:select', '权限查询', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (20, 'user:add', '用户添加', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (22, 'menuList:select', '菜单查询', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (25, 'category:select', '分类查询', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (26, 'category:delete', '分类删除', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (27, 'category:update', '分类修改', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (28, 'category:add', '分类添加', 1, '2021-11-28 15:07:36', '2021-11-28 15:07:36');
|
| | | INSERT INTO `permission` VALUES (29, 'device:select', '下发参数查询', 1, '2021-11-28 15:07:36', '2023-08-24 08:48:37');
|
| | | INSERT INTO `permission` VALUES (30, 'device:add', '下发参数添加', 1, '2023-08-24 08:48:53', '2023-08-24 08:49:18');
|
| | | INSERT INTO `permission` VALUES (31, 'device:update', '下发参数修改', 1, '2023-08-24 08:49:23', '2023-08-24 08:49:44');
|
| | |
|
| | | -- ----------------------------
|
| | | -- Table structure for role
|
| | | -- ----------------------------
|
| | | DROP TABLE IF EXISTS `role`;
|
| | | CREATE TABLE `role` (
|
| | | `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',
|
| | | `parent_id` bigint NULL DEFAULT NULL COMMENT '上级角色',
|
| | | `name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '角色名称',
|
| | | `description` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '描述',
|
| | | `state` tinyint NOT NULL DEFAULT 1 COMMENT '状态 1/正常',
|
| | | `create_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
|
| | | `update_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间',
|
| | | PRIMARY KEY (`id`) USING BTREE
|
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 6 CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '角色' ROW_FORMAT = Dynamic;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Records of role
|
| | | -- ----------------------------
|
| | | INSERT INTO `role` VALUES (1, NULL, 'admin', '系统管理员', 1, '2021-01-10 22:49:17', '2021-03-29 15:19:15');
|
| | | INSERT INTO `role` VALUES (2, 1, 'user', '普通用户', 1, '2021-01-13 00:28:58', '2021-03-29 15:19:15');
|
| | | INSERT INTO `role` VALUES (5, 1, 'user3', NULL, 1, '2023-08-24 10:02:58', '2023-08-24 10:05:03');
|
| | |
|
| | | -- ----------------------------
|
| | | -- Table structure for role_menu_list
|
| | | -- ----------------------------
|
| | | DROP TABLE IF EXISTS `role_menu_list`;
|
| | | CREATE TABLE `role_menu_list` (
|
| | | `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',
|
| | | `role_id` bigint NULL DEFAULT NULL COMMENT '角色id',
|
| | | `menu_list_id` bigint NULL DEFAULT NULL COMMENT '菜单id',
|
| | | `state` tinyint NULL DEFAULT 1 COMMENT '状态 1/正常',
|
| | | `create_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
|
| | | `update_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间',
|
| | | PRIMARY KEY (`id`) USING BTREE
|
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 25 CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '角色和菜单关联表' ROW_FORMAT = Dynamic;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Records of role_menu_list
|
| | | -- ----------------------------
|
| | | INSERT INTO `role_menu_list` VALUES (1, 1, 1, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (2, 1, 2, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (3, 1, 3, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (4, 1, 4, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (5, 1, 5, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (6, 1, 6, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (7, 1, 7, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (8, 1, 8, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (9, 1, 9, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (10, 1, 10, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (11, 1, 11, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (12, 1, 12, 1, '2021-11-28 15:10:03', '2021-11-28 15:10:03');
|
| | | INSERT INTO `role_menu_list` VALUES (19, 1, 50, 1, '2023-08-24 09:13:00', '2023-08-24 09:13:00');
|
| | | INSERT INTO `role_menu_list` VALUES (20, 2, 49, 1, '2023-08-24 10:08:38', '2023-08-24 13:20:23');
|
| | | INSERT INTO `role_menu_list` VALUES (21, 2, 51, 1, '2023-08-24 10:08:56', '2023-08-24 13:20:47');
|
| | | INSERT INTO `role_menu_list` VALUES (22, 2, 52, 1, '2023-08-24 10:08:56', '2023-08-24 13:20:48');
|
| | | INSERT INTO `role_menu_list` VALUES (23, 2, 53, 1, '2023-08-24 10:08:56', '2023-08-24 13:20:51');
|
| | |
|
| | | -- ----------------------------
|
| | | -- Table structure for role_permission
|
| | | -- ----------------------------
|
| | | DROP TABLE IF EXISTS `role_permission`;
|
| | | CREATE TABLE `role_permission` (
|
| | | `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',
|
| | | `role_id` bigint NULL DEFAULT NULL COMMENT '角色id',
|
| | | `permission_id` bigint NULL DEFAULT NULL COMMENT '权限id',
|
| | | `state` tinyint NOT NULL DEFAULT 1 COMMENT '状态 1/正常',
|
| | | `create_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
|
| | | `update_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间',
|
| | | PRIMARY KEY (`id`) USING BTREE
|
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 49 CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '角色权限' ROW_FORMAT = Dynamic;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Records of role_permission
|
| | | -- ----------------------------
|
| | | INSERT INTO `role_permission` VALUES (1, 1, 1, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (2, 1, 2, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (3, 1, 3, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (7, 1, 7, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (8, 1, 8, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (9, 1, 9, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (10, 1, 10, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (11, 1, 11, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (12, 1, 12, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (13, 1, 13, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (16, 1, 16, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (17, 1, 17, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (18, 1, 18, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (19, 1, 19, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (20, 1, 20, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (22, 1, 22, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (25, 1, 25, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (26, 1, 26, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (27, 1, 27, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (28, 1, 28, 1, '2021-11-28 15:07:54', '2021-11-28 15:07:54');
|
| | | INSERT INTO `role_permission` VALUES (37, 2, 25, 1, '2021-11-28 16:30:57', '2021-11-28 16:31:04');
|
| | | INSERT INTO `role_permission` VALUES (38, 2, 26, 1, '2021-11-28 16:30:57', '2021-11-28 16:31:04');
|
| | | INSERT INTO `role_permission` VALUES (39, 2, 27, 1, '2021-11-28 16:30:57', '2021-11-28 16:31:04');
|
| | | INSERT INTO `role_permission` VALUES (40, 2, 28, 1, '2021-11-28 16:32:35', '2021-11-28 16:37:20');
|
| | | INSERT INTO `role_permission` VALUES (41, 2, 22, 1, '2021-11-28 19:57:35', '2021-11-28 19:57:35');
|
| | | INSERT INTO `role_permission` VALUES (42, 1, 30, 1, '2023-08-24 08:55:34', '2023-08-24 08:55:34');
|
| | | INSERT INTO `role_permission` VALUES (43, 1, 29, 1, '2023-08-24 08:56:15', '2023-08-24 08:56:15');
|
| | | INSERT INTO `role_permission` VALUES (44, 1, 31, 1, '2023-08-24 08:56:23', '2023-08-24 08:56:23');
|
| | | INSERT INTO `role_permission` VALUES (45, 2, 29, 1, '2023-08-24 09:59:43', '2023-08-24 09:59:43');
|
| | | INSERT INTO `role_permission` VALUES (46, 2, 30, 1, '2023-08-24 09:59:54', '2023-08-24 09:59:54');
|
| | | INSERT INTO `role_permission` VALUES (47, 2, 31, 1, '2023-08-24 10:00:02', '2023-08-24 10:00:02');
|
| | | INSERT INTO `role_permission` VALUES (48, 5, 1, 1, '2023-08-24 10:03:18', '2023-08-24 10:03:18');
|
| | |
|
| | | -- ----------------------------
|
| | | -- Table structure for user
|
| | | -- ----------------------------
|
| | | DROP TABLE IF EXISTS `user`;
|
| | | CREATE TABLE `user` (
|
| | | `id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键',
|
| | | `parent_id` bigint NOT NULL DEFAULT 1 COMMENT '上级id',
|
| | | `path` varchar(200) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '1-' COMMENT '路径',
|
| | | `level` int NOT NULL DEFAULT 1 COMMENT '等级',
|
| | | `role_id` bigint NOT NULL DEFAULT 2 COMMENT '角色id',
|
| | | `username` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户名',
|
| | | `password` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '密码',
|
| | | `email` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '邮箱',
|
| | | `qq` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT 'qq号',
|
| | | `phone` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '联系方式',
|
| | | `state` tinyint(1) NOT NULL DEFAULT 1 COMMENT '状态:0/禁止 1/正常',
|
| | | `create_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
|
| | | `update_time` datetime(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间',
|
| | | PRIMARY KEY (`id`) USING BTREE
|
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 14 CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic;
|
| | |
|
| | | -- ----------------------------
|
| | | -- Records of user
|
| | | -- ----------------------------
|
| | | INSERT INTO `user` VALUES (2, 1, '1-', 1, 2, 'user1', '601b99523f82de29f87771d5f95accdc', 'user1@qq.com', NULL, NULL, 1, '2021-11-28 14:31:39', '2021-11-28 15:09:36');
|
| | | INSERT INTO `user` VALUES (3, 1, '1-', 1, 2, 'user2', 'f403c87893db29eb71b21905b57bbd0d', 'user2@qq.com', NULL, NULL, 1, '2021-11-28 14:31:39', '2021-11-28 15:09:36');
|
| | | INSERT INTO `user` VALUES (8, 1, '1-', 1, 2, 'yyyyy', '1e150ad1105f2e75ca287425868b9cab', '2265557248@qq.com', NULL, NULL, 1, '2023-08-23 20:08:44', '2023-08-23 20:08:44');
|
| | | INSERT INTO `user` VALUES (9, 1, '1-', 1, 1, 'yttttttttttt', '3c37d269aab46b73a4ff2a43f5e34702', '666@qq.com', NULL, NULL, 1, '2023-08-23 20:35:32', '2023-08-23 20:35:32');
|
| | | INSERT INTO `user` VALUES (10, 1, '1-', 1, 2, '767655555', '500637c0d48b442a3be6d4fce12e0910', NULL, NULL, NULL, 1, '2023-08-23 20:42:58', '2023-08-23 20:42:58');
|
| | | INSERT INTO `user` VALUES (11, 1, '1-', 1, 5, 'uiuyiuy', '601b99523f82de29f87771d5f95accdc', '767676767676@qq.com', NULL, NULL, 1, '2023-08-23 20:43:42', '2023-08-23 20:43:42');
|
| | | INSERT INTO `user` VALUES (12, 1, '1-', 1, 1, 'iiiii', 'b2f0c414a5ffb6944c424bc18ae3a8a0', NULL, NULL, NULL, 1, '2023-08-24 08:01:00', '2023-08-24 16:50:38');
|
| | | INSERT INTO `user` VALUES (13, 1, '1-', 1, 2, 'user3', '500637c0d48b442a3be6d4fce12e0910', '2265557345@qq.com', NULL, NULL, 1, '2023-08-24 09:58:40', '2023-08-24 09:58:40');
|
| | | INSERT INTO `user` VALUES (14, 1, '1-', 1, 1, 'admin', 'b2f0c414a5ffb6944c424bc18ae3a8a0', NULL, NULL, NULL, 1, '2023-08-25 08:58:58', '2023-08-25 09:00:56');
|
| | |
|
| | | SET FOREIGN_KEY_CHECKS = 1;
|
| New file |
| | |
| | | package com.canadames; |
| | | |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.boot.test.context.SpringBootTest; |
| | | |
| | | @SpringBootTest |
| | | class AuthorityApplicationTests { |
| | | |
| | | @Test |
| | | void contextLoads() { |
| | | } |
| | | |
| | | } |
| New file |
| | |
| | | VUE_APP_BASE_API=/api |
| New file |
| | |
| | | .DS_Store |
| | | node_modules |
| | | /dist |
| | | |
| | | |
| | | # local env files |
| | | .env.local |
| | | .env.*.local |
| | | |
| | | # Log files |
| | | npm-debug.log* |
| | | yarn-debug.log* |
| | | yarn-error.log* |
| | | pnpm-debug.log* |
| | | |
| | | # Editor directories and files |
| | | .idea |
| | | .vscode |
| | | *.suo |
| | | *.ntvs* |
| | | *.njsproj |
| | | *.sln |
| | | *.sw? |
| New file |
| | |
| | | # Authority UI |
| | | |
| | | Spring Boot+Vue.js权限管理系统前端 |
| | | |
| | | # 作者 |
| | | |
| | | [jonssonyan](https://jonssonyan.com) |
| | | |
| | | # 开发工具 |
| | | |
| | | 1. WebStorm 2019.3.5 |
| | | |
| | | # 框架/技术 |
| | | |
| | | JavaScript / Vue.js / Element / axios |
| New file |
| | |
| | | module.exports = { |
| | | presets: [ |
| | | '@vue/cli-plugin-babel/preset' |
| | | ] |
| | | } |
| New file |
| | |
| | | { |
| | | "name": "authority-ui", |
| | | "version": "0.1.0", |
| | | "private": true, |
| | | "scripts": { |
| | | "serve": "vue-cli-service serve", |
| | | "build": "vue-cli-service build", |
| | | "lint": "vue-cli-service lint" |
| | | }, |
| | | "dependencies": { |
| | | "axios": "^0.19.2", |
| | | "core-js": "^3.6.5", |
| | | "element-ui": "^2.13.2", |
| | | "js-cookie": "^3.0.1", |
| | | "less": "^3.12.2", |
| | | "less-loader": "^6.2.0", |
| | | "vue": "^2.6.11", |
| | | "vue-i18n": "^8.26.5", |
| | | "vue-router": "^3.3.4" |
| | | }, |
| | | "devDependencies": { |
| | | "@vue/cli-plugin-babel": "~4.5.0", |
| | | "@vue/cli-plugin-eslint": "~4.5.0", |
| | | "@vue/cli-service": "~4.5.0", |
| | | "babel-eslint": "^10.1.0", |
| | | "eslint": "^6.7.2", |
| | | "eslint-plugin-vue": "^6.2.2", |
| | | "vue-template-compiler": "^2.6.11" |
| | | }, |
| | | "eslintConfig": { |
| | | "root": true, |
| | | "env": { |
| | | "node": true |
| | | }, |
| | | "extends": [ |
| | | "plugin:vue/essential", |
| | | "eslint:recommended" |
| | | ], |
| | | "parserOptions": { |
| | | "parser": "babel-eslint" |
| | | }, |
| | | "rules": {} |
| | | }, |
| | | "browserslist": [ |
| | | "> 1%", |
| | | "last 2 versions", |
| | | "not dead" |
| | | ] |
| | | } |
| New file |
| | |
| | | <!DOCTYPE html> |
| | | <html lang=""> |
| | | <head> |
| | | <meta charset="utf-8"> |
| | | <meta http-equiv="X-UA-Compatible" content="IE=edge"> |
| | | <meta name="viewport" content="width=device-width,initial-scale=1.0"> |
| | | <link rel="icon" href="<%= BASE_URL %>favicon.ico"> |
| | | <title>北玻mes系统</title> |
| | | </head> |
| | | <body> |
| | | <noscript> |
| | | <strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.</strong> |
| | | </noscript> |
| | | <div id="app"></div> |
| | | <!-- built files will be auto injected --> |
| | | </body> |
| | | </html> |
| New file |
| | |
| | | <template> |
| | | <div id="app"> |
| | | <!--路由占位符--> |
| | | <router-view/> |
| | | </div> |
| | | </template> |
| | | <script> |
| | | export default { |
| | | name: "app" |
| | | } |
| | | </script> |
| | | <style> |
| | | </style> |
| New file |
| | |
| | | import request from "../utils/request"; |
| | | |
| | | /** |
| | | * 分页查询分类 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectPage(data) { |
| | | return request({ |
| | | url: '/api/category/selectPage', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 单个删除分类 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function removeById(data) { |
| | | return request({ |
| | | url: '/api/category/removeById', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 修改或者更新分类 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function saveOrUpdate(data) { |
| | | return request({ |
| | | url: '/api/category/saveOrUpdate', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 查询某人创建的分类,但是排除当前选中的分类,用户修改分类使用 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function select(data) { |
| | | return request({ |
| | | url: '/api/category/select', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 查询分类,嵌套数据结构 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectChilds(data) { |
| | | return request({ |
| | | url: '/api/category/selectChilds', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 通过id查询分类 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function getById(data) { |
| | | return request({ |
| | | url: '/api/category/getById', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "../utils/request"; |
| | | |
| | | /** |
| | | * 查询菜单列表 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectList(data) { |
| | | return request({ |
| | | url: '/api/menuList/selectList', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 分页查询菜单 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectPage(data) { |
| | | return request({ |
| | | url: '/api/menuList/selectPage', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 根据id删除菜单 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function removeById(data) { |
| | | return request({ |
| | | url: '/api/menuList/removeById', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 添加或者更新菜单 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function saveOrUpdate(data) { |
| | | return request({ |
| | | url: '/api/menuList/saveOrUpdate', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "../utils/request"; |
| | | |
| | | /** |
| | | * 根据id查询权限 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function getById(data) { |
| | | return request({ |
| | | url: '/api/permission/getById', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 查询权限列表 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectPermission(data) { |
| | | return request({ |
| | | url: '/api/permission/select', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "../utils/request"; |
| | | |
| | | /** |
| | | * 添加或者更新角色 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function saveOrUpdate(data) { |
| | | return request({ |
| | | url: '/api/role/saveOrUpdate', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 根据id删除角色 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function removeById(data) { |
| | | return request({ |
| | | url: '/api/role/removeById', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 根据id查询角色 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function getById(data) { |
| | | return request({ |
| | | url: '/api/role/getById', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 分页查询角色 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectPage(data) { |
| | | return request({ |
| | | url: '/api/role/selectPage', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 查询角色列表 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function select(data) { |
| | | return request({ |
| | | url: '/api/role/select', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "../utils/request"; |
| | | |
| | | /** |
| | | * 分页查询角色和菜单关系 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectPage(data) { |
| | | return request({ |
| | | url: '/api/roleMenuList/selectPage', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "../utils/request"; |
| | | |
| | | /** |
| | | * 添加或者更新角色和权限关系 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function saveOrUpdate(data) { |
| | | return request({ |
| | | url: '/api/rolePermission/saveOrUpdate', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 根据id删除角色和权限关系 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function removeById(data) { |
| | | return request({ |
| | | url: '/api/rolePermission/removeById', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 分页查询角色和权限关系 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectPage(data) { |
| | | return request({ |
| | | url: '/api/rolePermission/selectPage', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 根据id查询角色和权限关系 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function getById(data) { |
| | | return request({ |
| | | url: '/api/rolePermission/getById', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| New file |
| | |
| | | import request from "../utils/request"; |
| | | |
| | | /** |
| | | *登录 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function login(data) { |
| | | return request({ |
| | | url: '/login', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 注册 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function register(data) { |
| | | return request({ |
| | | url: '/register', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 注册时校验用户名是否存在 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function countUsername(data) { |
| | | return request({ |
| | | url: '/countUsername', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 分页查询用户 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function selectPage(data) { |
| | | return request({ |
| | | url: '/api/user/selectPage', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 添加或或者修改用户 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function saveOrUpdate(data) { |
| | | return request({ |
| | | url: '/api/user/saveOrUpdate', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 通过id删除用户 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function removeById(data) { |
| | | return request({ |
| | | url: '/api/user/removeById', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 通过id查询用户 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function getById(data) { |
| | | return request({ |
| | | url: '/api/user/getById', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | export function getrole(data) { |
| | | return request({ |
| | | url: '/api/role/select', |
| | | method: 'get', |
| | | params: data |
| | | }) |
| | | } |
| | | |
| | | /** |
| | | * 注销登录,前提是在登录状态 |
| | | * @param data |
| | | * @returns {AxiosPromise} |
| | | */ |
| | | export function loginOut(data) { |
| | | return request({ |
| | | url: '/api/user/loginOut', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| New file |
| | |
| | | html, body, #app { |
| | | height: 100%; |
| | | margin: 0; |
| | | padding: 0; |
| | | box-sizing: border-box; |
| | | } |
| | | |
| | | .el-breadcrumb { |
| | | margin-bottom: 15px; |
| | | font-size: 12px; |
| | | } |
| | | |
| | | .el-card { |
| | | box-shadow: 0 1px 1px rgba(0, 0, 0, 0.15) !important; |
| | | } |
| New file |
| | |
| | | export default {
|
| | | created() {
|
| | | const localStorageLang = localStorage.getItem('preferredLanguage');
|
| | | if (localStorageLang) {
|
| | | this.$i18n.locale = localStorageLang;
|
| | | }
|
| | | },
|
| | | methods: {
|
| | | switchLanguage(lang) {
|
| | | this.$i18n.locale = lang;
|
| | | localStorage.setItem('preferredLanguage', lang);
|
| | | }
|
| | | }
|
| | | } |
| New file |
| | |
| | | import Vue from 'vue'
|
| | | import VueI18n from 'vue-i18n'
|
| | |
|
| | | // 引入语言包
|
| | | import zhCN from './locales/zh-CN.json' // 中文语言包
|
| | | import enUS from './locales/en-US.json' // 英文语言包
|
| | |
|
| | | Vue.use(VueI18n)
|
| | |
|
| | | const i18n = new VueI18n({
|
| | | locale: 'zh-CN', // 设置默认语言为中文
|
| | | messages: {
|
| | | 'zh-CN': zhCN, // 注册中文语言包
|
| | | 'en-US': enUS // 注册英文语言包
|
| | | }
|
| | | })
|
| | |
|
| | | export default i18n
|
| New file |
| | |
| | | {
|
| | | "systemTitle": "Login System",
|
| | | "usernamePlaceholder": "Please enter username",
|
| | | "passwordPlaceholder": "Please enter password",
|
| | | "loginButton": "Login",
|
| | | "registerButton": "Register",
|
| | | "resetButton": "Reset",
|
| | | "usernameRequired": "Please enter username",
|
| | | "usernameLength": "Username must be between 5 and 15 characters",
|
| | | "passwordRequired": "Please enter password",
|
| | | "passwordLength": "Password must be between 5 and 15 characters",
|
| | | "loginSuccess": "Login successful",
|
| | | "langBtnCN": "Chinese",
|
| | | "langBtnEN": "English",
|
| | | "langHome": "Home",
|
| | | "langUserManagement": "User Management",
|
| | | "langUserList": "User List",
|
| | | "langUsernamePlaceholder": "Please enter username",
|
| | | "langEmailPlaceholder": "Please enter email",
|
| | | "langSearch": "Search",
|
| | | "langAddUser": "Add User",
|
| | | "langUsername": "Username",
|
| | | "langEmail": "Email",
|
| | | "langCreateTime": "Create Time",
|
| | | "langDisabled": "Disabled",
|
| | | "langAction": "Action",
|
| | | "langEdit": "Edit",
|
| | | "langDelete": "Delete",
|
| | | "langAddUserTitle": "Add User",
|
| | | "langPassword": "Password",
|
| | | "langState": "State",
|
| | | "langSelect": "Please select",
|
| | | "langCancel": "Cancel",
|
| | | "langConfirm": "Confirm",
|
| | | "langEditUserTitle": "Edit User",
|
| | | "northglassMESsystem":"NorthGlassMesSystem",
|
| | | "exit":"exit"
|
| | | } |
| New file |
| | |
| | |
|
| | | {
|
| | | "systemTitle": "登录系统",
|
| | | "usernamePlaceholder": "请输入用户名",
|
| | | "passwordPlaceholder": "请输入密码",
|
| | | "loginButton": "登录",
|
| | | "registerButton": "注册",
|
| | | "resetButton": "重置",
|
| | | "usernameRequired": "请输入用户名",
|
| | | "usernameLength": "用户名长度在5-15个字符之间",
|
| | | "passwordRequired": "请输入密码",
|
| | | "passwordLength": "密码长度在5-15个字符之间",
|
| | | "loginSuccess": "登录成功",
|
| | | "langBtnCN": "中文",
|
| | | "langBtnEN": "English",
|
| | | "langHome": "首页",
|
| | | "langUserManagement": "用户管理",
|
| | | "langUserList": "用户列表",
|
| | | "langUsernamePlaceholder": "请输入用户名",
|
| | | "langEmailPlaceholder": "请输入邮箱",
|
| | | "langSearch": "搜索",
|
| | | "langAddUser": "添加用户",
|
| | | "langUsername": "用户名",
|
| | | "langEmail": "邮箱",
|
| | | "langCreateTime": "创建时间",
|
| | | "langDisabled": "是否禁用",
|
| | | "langAction": "操作",
|
| | | "langEdit": "修改",
|
| | | "langDelete": "删除",
|
| | | "langAddUserTitle": "添加用户",
|
| | | "langPassword": "密码",
|
| | | "langState": "状态",
|
| | | "langSelect": "请选择",
|
| | | "langCancel": "取消",
|
| | | "langConfirm": "确定",
|
| | | "langEditUserTitle": "修改用户",
|
| | | "northglassMESsystem":"北玻MES系统",
|
| | | "exit":"退出"
|
| | | }
|
| | | |
| New file |
| | |
| | | <template> |
| | | <el-container> |
| | | |
| | | <div style="width: 200px;background-color: #222f3e" :style="{width: isCollapse?'70px':'250px'}"> |
| | | <el-aside :width="isCollapse?'70px':'250px'"> |
| | | <el-col :gutter="20"> |
| | | <el-row :span="4"> |
| | | <div class="logo"> |
| | | <div class="sys-name" v-show="!isCollapse">{{ $t('northglassMESsystem') }}</div> |
| | | </div> |
| | | </el-row> |
| | | <el-row :span="20"> |
| | | <el-menu :default-active="activePath" class="el-menu-vertical-demo" |
| | | background-color="#222f3e" text-color="#fff" active-text-color="#ffd04b" |
| | | :collapse="isCollapse" :unique-opened="true" |
| | | :collapse-transition="false" :router="true"> |
| | | <!--一级菜单--> |
| | | <el-submenu :index="item.id.toString()" v-for="item in menuList" :key="item.id"> |
| | | <!--一级菜单模板区域--> |
| | | <template slot="title"> |
| | | <!--图标--> |
| | | <i :class="item.icon"></i> |
| | | <!--文本--> |
| | | <span>{{ item.name }}</span> |
| | | </template> |
| | | <!--二级菜单--> |
| | | <el-menu-item :index="'/'+menu.router" |
| | | v-for="menu in item.menuLists" :key="menu.id" |
| | | @click="saveNavState('/'+menu.router)"> |
| | | <template slot="title"> |
| | | <!--图标--> |
| | | <i :class="menu.icon"></i> |
| | | <!--文本--> |
| | | <span>{{ menu.name }}</span> |
| | | </template> |
| | | </el-menu-item> |
| | | </el-submenu> |
| | | </el-menu> |
| | | </el-row> |
| | | </el-col> |
| | | </el-aside> |
| | | </div> |
| | | <el-container> |
| | | |
| | | <el-header class="header-container"> |
| | | |
| | | <el-menu :default-active="activePath1" class="el-menu-demo" mode="horizontal" |
| | | background-color="#576574" text-color="#fff" active-text-color="#ffd04b"> |
| | | <div class="header-left"> |
| | | <el-button :icon="isCollapse ? 'el-icon-s-unfold' : 'el-icon-s-fold'" @click="toggleCollapse"></el-button> |
| | | </div> |
| | | <el-submenu index="1" class="user-icon"> |
| | | |
| | | <template slot="title"> |
| | | <el-avatar src="https://cube.elemecdn.com/0/88/03b0d39583f48206768a7534e55bcpng.png"> |
| | | </el-avatar> |
| | | </template> |
| | | <el-menu-item index="1-1" @click="logout">{{ $t('exit') }}</el-menu-item> |
| | | </el-submenu> |
| | | |
| | | </el-menu> |
| | | </el-header> |
| | | <el-main> |
| | | <router-view/> |
| | | </el-main> |
| | | </el-container> |
| | | </el-container> |
| | | </template> |
| | | |
| | | <script> |
| | | import {selectList} from '../api/menuList' |
| | | import {removeToken} from "../utils/auth"; |
| | | import LanguageMixin from '../lang/LanguageMixin' |
| | | |
| | | export default { |
| | | name: "Layout", |
| | | mixins: [LanguageMixin], |
| | | data() { |
| | | return { |
| | | |
| | | menuList: [], |
| | | isCollapse: false, |
| | | activePath: '', |
| | | activePath1: '', |
| | | menuListForm: { |
| | | pageSize: 1, |
| | | pageNum: -1 |
| | | } |
| | | } |
| | | }, |
| | | created() { |
| | | selectList(this.menuListForm).then(res => { |
| | | this.menuList = res.data |
| | | |
| | | const language = this.$i18n.locale; |
| | | if (language === 'en-US') { |
| | | this.replaceChineseWithEnglish(this.menuList); |
| | | } |
| | | // 记录上一次激活的菜单 |
| | | this.activePath = window.sessionStorage.getItem('activePath') |
| | | }); |
| | | }, |
| | | methods: { |
| | | logout: function () { |
| | | removeToken() |
| | | this.$router.push('/login') |
| | | }, |
| | | |
| | | toggleCollapse: function () { |
| | | this.isCollapse = !this.isCollapse; |
| | | }, |
| | | saveNavState: function (activePath) { |
| | | window.sessionStorage.setItem('activePath', activePath) |
| | | }, |
| | | replaceChineseWithEnglish(menuData) { |
| | | // 定义中英文对照关系对象 |
| | | const translation = { |
| | | '用户管理': 'UserManagement', |
| | | '用户列表': 'UserList', |
| | | '设备管理': 'DeviceManagement', |
| | | '报警信息': 'AlarmInformation', |
| | | '下发参数': 'ParameterSetting', |
| | | '开关控制': 'SwitchControl', |
| | | 'I/O状态': 'I/O Status', |
| | | '权限管理': 'PermissionManagement', |
| | | '权限列表': 'PermissionList', |
| | | '角色管理': 'RoleManagement', |
| | | '角色列表': 'RoleList' |
| | | // 根据实际需求继续添加对照关系 |
| | | }; |
| | | |
| | | menuData.forEach(menu => { |
| | | menu.name = translation[menu.name] || menu.name; |
| | | menu.menuLists && menu.menuLists.forEach(subMenu => { |
| | | subMenu.name = translation[subMenu.name] || subMenu.name; |
| | | }); |
| | | }); |
| | | |
| | | |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
| | | </script> |
| | | |
| | | <style scoped lang="less"> |
| | | .header-container { |
| | | display: flex; |
| | | justify-content: flex-start; |
| | | } |
| | | |
| | | .header-left { |
| | | margin-right: auto; |
| | | } |
| | | .el-aside { |
| | | height: 100vh; |
| | | background-color: #222f3e; |
| | | line-height: 200px; |
| | | } |
| | | |
| | | .el-menu-vertical-demo:not(.el-menu--collapse) { |
| | | width: 200px; |
| | | min-height: 400px; |
| | | } |
| | | |
| | | .el-menu-demo { |
| | | display: flex; |
| | | width: 100%; |
| | | height: 100%; |
| | | justify-content: flex-end; |
| | | align-items: center; |
| | | |
| | | } |
| | | |
| | | .el-menu-vertical-demo { |
| | | border: 0; |
| | | } |
| | | |
| | | .logo { |
| | | background-color: #222f3e; |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 60px; |
| | | |
| | | .sys-name { |
| | | font-size: 20px; |
| | | color: #ffffff; |
| | | margin-left: 10px; |
| | | } |
| | | } |
| | | |
| | | .el-header { |
| | | padding: 0; |
| | | background-color: #576574; |
| | | } |
| | | </style> |
| New file |
| | |
| | | import Vue from 'vue' |
| | | import App from './App.vue' |
| | | import router from './router' |
| | | import ElementUI, {Message, MessageBox} from 'element-ui'; |
| | | import 'element-ui/lib/theme-chalk/index.css'; |
| | | // 导入全局样式表 |
| | | import './assets/css/global.css' |
| | | import VueI18n from 'vue-i18n' |
| | | import zhCN from './lang/locales/zh-CN.json' // 中文语言包 |
| | | import enUS from './lang/locales/en-US.json' // 英文语言包 |
| | | |
| | | Vue.use(VueI18n) |
| | | |
| | | const i18n = new VueI18n({ |
| | | locale: 'zh-CN', // 设置默认语言为中文 |
| | | messages: { |
| | | 'zh-CN': zhCN, // 注册中文语言包 |
| | | 'en-US': enUS // 注册英文语言包 |
| | | } |
| | | }) |
| | | |
| | | Vue.use(ElementUI); |
| | | |
| | | Vue.config.productionTip = false; |
| | | |
| | | // 导入弹框提示组件 |
| | | Vue.prototype.$message = Message; |
| | | // confirm |
| | | Vue.prototype.$confirm = MessageBox.confirm; |
| | | |
| | | new Vue({ |
| | | router, |
| | | i18n, |
| | | render: h => h(App) |
| | | }).$mount('#app'); |
| New file |
| | |
| | | import Vue from 'vue' |
| | | import VueRouter from 'vue-router' |
| | | import { getToken } from "../utils/auth"; |
| | | |
| | | Vue.use(VueRouter); |
| | | |
| | | const routes = [ |
| | | { |
| | | path: '/', |
| | | redirect: '/login' |
| | | }, |
| | | { |
| | | path: '/login', |
| | | component: () => import('../views/login') |
| | | }, |
| | | { |
| | | path: '/register', |
| | | component: () => import('../views/register') |
| | | }, |
| | | { |
| | | path: '/layout', |
| | | component: () => import('../layout'), |
| | | children: [ |
| | | { |
| | | path: '/user', |
| | | component: () => import('../views/user') |
| | | }, |
| | | { |
| | | path: '', |
| | | redirect: '/home' |
| | | }, |
| | | { |
| | | path: '/home', |
| | | component: () => import('../views/home') |
| | | }, |
| | | |
| | | |
| | | { |
| | | path: '/power', |
| | | component: () => import('../views/power') |
| | | }, |
| | | { |
| | | path: '/role', |
| | | component: () => import('../views/role') |
| | | }, |
| | | { |
| | | path: '/device/parameter', |
| | | component: () => import('../views/device/parameter'), |
| | | |
| | | }, |
| | | { |
| | | path: '/device/alarm', |
| | | component: () => import('../views/device/alarm') |
| | | }, |
| | | { |
| | | path: '/device/iostate', |
| | | component: () => import('../views/device/iostate') |
| | | }, |
| | | { |
| | | path: '/device/control', |
| | | component: () => import('../views/device/control') |
| | | }, |
| | | { |
| | | path: '/Electrical/Parameter', |
| | | component: () => import('../views/Electrical/Parameter') |
| | | }, |
| | | { |
| | | path: '/Electrical/Action', |
| | | component: () => import('../views/Electrical/Action') |
| | | }, |
| | | { |
| | | path: '/Electrical/Sign', |
| | | component: () => import('../views/Electrical/Sign') |
| | | }, |
| | | { |
| | | path: '/Electrical/State', |
| | | component: () => import('../views/Electrical/State') |
| | | }, |
| | | |
| | | |
| | | |
| | | |
| | | ] |
| | | } |
| | | ]; |
| | | |
| | | const router = new VueRouter({ |
| | | routes |
| | | }); |
| | | |
| | | // 路由控制守卫,解决需要登录才可以访问的页面 |
| | | router.beforeEach((to, from, next) => { |
| | | // 如果访问的是登录或注册页面直接放行 |
| | | if (to.path === '/login' || to.path === '/register') return next(); |
| | | |
| | | // 获取token |
| | | const hasToken = getToken(); |
| | | |
| | | // 没有token则跳转到登录页面 |
| | | if (!hasToken) return next('/login'); |
| | | |
| | | // 有token则根据需要进行跳转 |
| | | if (to.path === '/') { |
| | | // 如果目标路由是根路径,则跳转到首页 |
| | | return next('/home'); |
| | | } |
| | | |
| | | // 其他情况放行 |
| | | return next(); |
| | | }); |
| | | |
| | | export default router |
| New file |
| | |
| | | import Cookies from 'js-cookie' |
| | | |
| | | const TokenKey = 'Authorization' |
| | | |
| | | /** |
| | | * 获取token |
| | | * @returns {*} |
| | | */ |
| | | export function getToken() { |
| | | return Cookies.get(TokenKey) |
| | | } |
| | | |
| | | /** |
| | | * 设置token |
| | | * @param token |
| | | * @returns {*} |
| | | */ |
| | | export function setToken(token) { |
| | | return Cookies.set(TokenKey, token) |
| | | } |
| | | |
| | | /** |
| | | * 移除token |
| | | * @returns {*} |
| | | */ |
| | | export function removeToken() { |
| | | return Cookies.remove(TokenKey) |
| | | } |
| New file |
| | |
| | | import axios from 'axios' |
| | | import {Message} from 'element-ui' |
| | | |
| | | const service = axios.create({ |
| | | baseURL: process.env.VUE_APP_BASE_API, |
| | | timeout: 5000 |
| | | }) |
| | | |
| | | service.interceptors.response.use( |
| | | response => { |
| | | const res = response.data |
| | | if (res.code !== 1) { |
| | | Message({ |
| | | message: res.msg || 'Error', |
| | | type: 'error', |
| | | duration: 5 * 1000 |
| | | }) |
| | | return Promise.reject(new Error(res.msg || 'Error')) |
| | | } else { |
| | | return res |
| | | } |
| | | }, |
| | | error => { |
| | | console.log('err' + error) |
| | | Message({ |
| | | message: error.message, |
| | | type: 'error', |
| | | duration: 5 * 1000 |
| | | }) |
| | | return Promise.reject(error) |
| | | } |
| | | ) |
| | | |
| | | export default service |
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <!--面包屑导航区域-->
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <el-breadcrumb-item :to="{ path: '/home' }">{{ $t('langHome') }}</el-breadcrumb-item>
|
| | | <el-breadcrumb-item>设备管理</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Parameter' }">参数</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Action' }">开关控制</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Sign' }">IO状态</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/State' }">报警信息</el-breadcrumb-item>
|
| | | </el-breadcrumb>
|
| | | <div>开关控制</div>
|
| | | </div>
|
| | | </template>
|
| | |
|
| | | <script>
|
| | |
|
| | |
|
| | | export default {
|
| | | name: "Action",
|
| | |
|
| | | }
|
| | |
|
| | | </script>
|
| | |
|
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | |
|
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | |
|
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <!--面包屑导航区域-->
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <el-breadcrumb-item :to="{ path: '/home' }">{{ $t('langHome') }}</el-breadcrumb-item>
|
| | | <el-breadcrumb-item>设备管理</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Parameter' }">参数</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Action' }">开关控制</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Sign' }">IO状态</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/State' }">报警信息</el-breadcrumb-item>
|
| | | </el-breadcrumb>
|
| | | <div>参数</div>
|
| | | <el-row :gutter="40" style="display: flex;flex-wrap: wrap;">
|
| | | <el-col :span="7">
|
| | | <div class="grid-content bg-purple">
|
| | | <el-input prop="sbname"></el-input>
|
| | | <el-input prop="sbdata"></el-input>
|
| | | </div>
|
| | | </el-col>
|
| | |
|
| | | </el-row>
|
| | | </div>
|
| | | </template>
|
| | |
|
| | | <script>
|
| | |
|
| | |
|
| | | export default {
|
| | | name: "Parameter",
|
| | | // data () {
|
| | | // return {
|
| | | // sbList: {
|
| | | // records: [],
|
| | | // }
|
| | | // }
|
| | | // }
|
| | | }
|
| | |
|
| | | </script>
|
| | |
|
| | | <style lang="less" scoped>
|
| | | .el-row {
|
| | | margin-bottom: 20px;
|
| | |
|
| | | &:last-child {
|
| | | margin-bottom: 0;
|
| | | }
|
| | | }
|
| | |
|
| | | .el-col {
|
| | | border-radius: 4px;
|
| | | margin: 10px;
|
| | | }
|
| | |
|
| | | .el-input {
|
| | | width: 70px;
|
| | | height: 30px;
|
| | | }
|
| | |
|
| | | .bg-purple-dark {
|
| | | background: #99a9bf;
|
| | | }
|
| | |
|
| | | .bg-purple {
|
| | | background: #d3dce6;
|
| | | }
|
| | |
|
| | | .bg-purple-light {
|
| | | background: #e5e9f2;
|
| | | }
|
| | |
|
| | | .grid-content {
|
| | | border-radius: 4px;
|
| | | min-height: 36px;
|
| | | }
|
| | |
|
| | | .row-bg {
|
| | | padding: 10px 0;
|
| | | background-color: #f9fafc;
|
| | | }
|
| | | </style>
|
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <!--面包屑导航区域-->
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <el-breadcrumb-item :to="{ path: '/home' }">{{ $t('langHome') }}</el-breadcrumb-item>
|
| | | <el-breadcrumb-item>设备管理</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Parameter' }">参数</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Action' }">开关控制</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Sign' }">IO状态</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/State' }">报警信息</el-breadcrumb-item>
|
| | | </el-breadcrumb>
|
| | | <div>IO状态</div>
|
| | | </div>
|
| | | </template>
|
| | |
|
| | | <script>
|
| | |
|
| | |
|
| | | export default {
|
| | | name: "Sign",
|
| | |
|
| | | }
|
| | |
|
| | | </script>
|
| | |
|
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | |
|
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | |
|
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <!--面包屑导航区域-->
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <el-breadcrumb-item :to="{ path: '/home' }">{{ $t('langHome') }}</el-breadcrumb-item>
|
| | | <el-breadcrumb-item>设备管理</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Parameter' }">参数</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Action' }">开关控制</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/Sign' }">IO状态</el-breadcrumb-item>
|
| | | <el-breadcrumb-item :to="{ path: '/Electrical/State' }">报警信息</el-breadcrumb-item>
|
| | | </el-breadcrumb>
|
| | | <div>报警信息</div>
|
| | | </div>
|
| | | </template>
|
| | |
|
| | | <script>
|
| | |
|
| | |
|
| | | export default {
|
| | | name: "State",
|
| | |
|
| | | }
|
| | |
|
| | | </script>
|
| | |
|
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | |
|
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | |
|
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| New file |
| | |
| | | <template>
|
| | | <div>
|
| | |
|
| | | 磨边速度:<el-input style="width: 150px" v-model="input" placeholder="请输入参数" clearable></el-input>
|
| | |
|
| | | <el-button type="primary" @click="dianji()" style="margin-left: 5px">查询</el-button>
|
| | |
|
| | | <div>
|
| | | 设备1开关:
|
| | | <el-switch v-model="kg1" @change="load()" active-color="#13ce66" active-value="true" inactive-value="false">
|
| | | </el-switch>
|
| | |
|
| | | 设备2开关:
|
| | | <el-switch v-model="kg2" @change="load()" active-color="#13ce66" active-value="true" inactive-value="false">
|
| | | </el-switch>
|
| | | </div>
|
| | | <div>
|
| | | <el-button id="deng"></el-button>
|
| | | </div>
|
| | | </div>
|
| | | </template>
|
| | | <script >
|
| | |
|
| | | export default {
|
| | | name: "Electrical",
|
| | |
|
| | | data () {
|
| | | return {
|
| | | input: "开",
|
| | | kg1: "false",
|
| | | kg2: "false"
|
| | | }
|
| | | },
|
| | | methods: {
|
| | | load () {
|
| | | if (this.input == "开") {
|
| | | this.kg1 = "true"
|
| | |
|
| | | }
|
| | | else {
|
| | | this.kg1 = "false"
|
| | |
|
| | | }
|
| | | },
|
| | | dianji () {
|
| | | this.load();
|
| | | },
|
| | |
|
| | |
|
| | | }
|
| | | }
|
| | |
|
| | | </script>
|
| | |
|
| | | <style>
|
| | | #deng {
|
| | | background: #A0A0A0;
|
| | | border: 0.1875em solid white;
|
| | | border-radius: 50%;
|
| | | height: 5em;
|
| | | width: 5em;
|
| | | box-shadow: 0.375em 0.375em 0 0 rgba(214, 214, 214, 0.125);
|
| | | }
|
| | | </style>
|
| | |
|
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | |
|
| | |
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <router-link to="/home" tag="el-button" type="text">{{ $t('langHome') }}</router-link>
|
| | | <el-button type="text">设备管理</el-button>
|
| | | <router-link to="/device/iostate" tag="el-button" type="text">IO状态</router-link>
|
| | | <router-link to="/device/alarm" tag="el-button" type="text">报警信息</router-link>
|
| | | <router-link to="/device/parameter" tag="el-button" type="text">参数下发</router-link>
|
| | | <router-link to="/device/control" tag="el-button" type="text">开关控制</router-link>
|
| | | </el-breadcrumb>
|
| | |
|
| | |
|
| | |
|
| | | <!--卡片视图区域-->
|
| | | <el-card class="el-card">
|
| | | <el-row :gutter="20">
|
| | | <!--搜索与添加区域-->
|
| | | <el-col :span="6">
|
| | | <el-input v-model="queryInfo.username" clearable @clear="getUserList">
|
| | | </el-input>
|
| | | </el-col>
|
| | | <el-col :span="6">
|
| | | <el-input v-model="queryInfo.email" clearable @clear="getUserList">
|
| | | </el-input>
|
| | | </el-col>
|
| | | <!--搜索按钮-->
|
| | | <el-col :span="4">
|
| | | <el-button type="primary" @click="getUserList">{{ $t('langSearch') }}</el-button>
|
| | | </el-col>
|
| | |
|
| | | <!--添加区域-->
|
| | | <el-col :span="4">
|
| | | <el-button type="primary" @click="showAddDialog">{{ $t('langAddUser') }}</el-button>
|
| | | </el-col>
|
| | | </el-row>
|
| | | <!--用户列表区域-->
|
| | | <el-table :data="userList.records" border stripe>
|
| | | <el-table-column label="#" type="index"></el-table-column>
|
| | | <el-table-column :label="$t('langUsername')" prop="username"></el-table-column>
|
| | | <el-table-column :label="$t('langEmail')" prop="email"></el-table-column>
|
| | | <el-table-column :label="$t('langCreateTime')" prop="createTime"></el-table-column>
|
| | | <el-table-column :label="$t('langDisabled')">
|
| | | <template slot-scope="scope">
|
| | | <el-switch :active-value="0" :inactive-value="1" v-model="scope.row.state" @change="stateChange(scope.row)">
|
| | | </el-switch>
|
| | | </template>
|
| | | </el-table-column>
|
| | | <el-table-column :label="$t('langAction')">
|
| | | <template slot-scope="scope">
|
| | | <!--修改-->
|
| | | <el-tooltip effect="dark" :content="$t('langEdit')" placement="top" :enterable="false">
|
| | | <el-button type="primary" icon="el-icon-edit" size="mini" @click="showEditDialog(scope.row.id)"></el-button>
|
| | | </el-tooltip>
|
| | | <!--删除-->
|
| | | <el-tooltip effect="dark" :content="$t('langDelete')" placement="top" :enterable="false">
|
| | | <el-button type="danger" icon="el-icon-delete" size="mini" @click="removeUserById(scope.row)"></el-button>
|
| | | </el-tooltip>
|
| | | </template>
|
| | | </el-table-column>
|
| | | </el-table>
|
| | | <!--分页区域-->
|
| | | <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
|
| | | :current-page="queryInfo.pageNum" :page-sizes="[10, 20, 30, 40]" :page-size="queryInfo.pageSize"
|
| | | layout="total, sizes, prev, pager, next, jumper" :total="userList.total">
|
| | | </el-pagination>
|
| | | </el-card>
|
| | | <!--添加用户的对话框-->
|
| | | <el-dialog :title="$t('langAddUserTitle')" :visible.sync="addDialogVisible" width="50%" @close="addDialogClosed">
|
| | | <!--内容主体区域-->
|
| | | <el-form :model="addUserForm" :rules="addUserRules" ref="addUserRef" label-width="70px">
|
| | | <el-form-item :label="$t('langUsername')" prop="username">
|
| | | <el-input v-model="addUserForm.username"></el-input>
|
| | | </el-form-item>
|
| | | <el-form-item :label="$t('langPassword')" prop="password">
|
| | | <el-input v-model="addUserForm.password" type="password"></el-input>
|
| | | </el-form-item>
|
| | | <el-form-item :label="$t('langEmail')" prop="email">
|
| | | <el-input v-model="addUserForm.email"></el-input>
|
| | | </el-form-item>
|
| | | <el-form-item :label="$t('langState')" prop="state">
|
| | | <el-select v-model="addUserForm.state">
|
| | | <el-option v-for="(item, index) in options" :key="index" :value="item.value" :label="item.label">
|
| | | </el-option>
|
| | | </el-select>
|
| | | </el-form-item>
|
| | | </el-form>
|
| | | <span slot="footer" class="dialog-footer">
|
| | | <el-button @click="addDialogVisible = false">{{ $t('langCancel') }}</el-button>
|
| | | <el-button type="primary" @click="addUser">{{ $t('langConfirm') }}</el-button>
|
| | | </span>
|
| | | </el-dialog>
|
| | | <!--修改用户的对话框-->
|
| | | <el-dialog :title="$t('langEditUserTitle')" :visible.sync="editDialogVisible" width="50%">
|
| | | <!--内容主体区域-->
|
| | | <el-form :model="editUserForm" :rules="addUserRules" ref="addCategoryRef" label-width="70px">
|
| | | <el-form-item :label="$t('langUsername')" prop="username">
|
| | | <el-input v-model="editUserForm.username" disabled></el-input>
|
| | | </el-form-item>
|
| | | <el-form-item label="角色" prop="roleId">
|
| | | <el-select filterable v-model="editUserForm.roleId" placeholder="请选择">
|
| | | <el-option v-for="item in roleList" :key="item.id" :value="item.id" :label="item.name">
|
| | | </el-option>
|
| | | </el-select>
|
| | | </el-form-item>
|
| | | <el-form-item :label="$t('langEmail')" prop="email">
|
| | | <el-input v-model="editUserForm.email"></el-input>
|
| | | </el-form-item>
|
| | | <el-form-item :label="$t('langDisabled')" prop="state">
|
| | | <el-select v-model="editUserForm.state">
|
| | | <el-option v-for="(item, index) in options" :key="index" :value="item.value" :label="item.label">
|
| | | </el-option>
|
| | | </el-select>
|
| | | </el-form-item>
|
| | | </el-form>
|
| | | <span slot="footer" class="dialog-footer">
|
| | | <el-button @click="editDialogVisible = false">{{ $t('langCancel') }}</el-button>
|
| | | <el-button type="primary" @click="editUserInfo">{{ $t('langConfirm') }}</el-button>
|
| | | </span>
|
| | | </el-dialog>
|
| | | </div>
|
| | | </template>
|
| | |
|
| | |
|
| | | <script>
|
| | | import { getById, removeById, saveOrUpdate, selectPage } from "../../api/user";
|
| | | import { select } from "../../api/role";
|
| | |
|
| | | import LanguageMixin from '../../lang/LanguageMixin'
|
| | | export default {
|
| | | name: "alarm",
|
| | | mixins: [LanguageMixin],
|
| | | data () {
|
| | | return {
|
| | | activeData: null,
|
| | | queryInfo: {
|
| | | pageNum: 1,
|
| | | pageSize: 10
|
| | | },
|
| | | userList: {
|
| | | records: [],
|
| | | total: 0,
|
| | | },
|
| | | // 添加的用户对象
|
| | | addUserForm: {
|
| | | state: 1
|
| | | },
|
| | | // 修改的用户对象
|
| | | editUserForm: {
|
| | |
|
| | | roleId: null,
|
| | | name: null,
|
| | | roleid: null,
|
| | | },
|
| | | // 添加分类的验证规则
|
| | | addUserRules: {
|
| | | roleId: null,
|
| | | username: [
|
| | | { required: true, message: '请输入用户名', trigger: 'blur' },
|
| | | { min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur' }
|
| | | ],
|
| | | password: [
|
| | | { required: true, message: '请输入密码', trigger: 'blur' },
|
| | | { min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur' }
|
| | | ],
|
| | | email: [
|
| | | { required: true, message: '请输入邮箱', trigger: 'blur' },
|
| | | { type: 'email', message: '请输入正确格式的邮箱地址', trigger: 'blur' }
|
| | | ]
|
| | | },
|
| | | // 控制添加用户弹框的显示和隐藏
|
| | | addDialogVisible: false,
|
| | | // 控制修改用户弹框的显示和隐藏
|
| | | editDialogVisible: false,
|
| | | options: [
|
| | | { label: '正常', value: 1 },
|
| | | { label: '禁用', value: 0 }
|
| | | ],
|
| | | roleList: [],
|
| | | }
|
| | | },
|
| | | created () {
|
| | | this.getUserList();
|
| | | },
|
| | | methods: {
|
| | | getUserList () {
|
| | | selectPage(this.queryInfo).then(res => {
|
| | | this.userList.records = res.data.records;
|
| | | this.userList.total = res.data.total
|
| | | });
|
| | | },
|
| | |
|
| | | showAddDialog () {
|
| | | this.addDialogVisible = true;
|
| | | },
|
| | | stateChange (info) {
|
| | | saveOrUpdate(info).then(() => {
|
| | | this.$message.success("更新状态成功")
|
| | | });
|
| | | },
|
| | | showEditDialog (id) {
|
| | | getById({ id: id }).then(res => {
|
| | | this.editUserForm = res.data;
|
| | | this.editDialogVisible = true;
|
| | | });
|
| | | select().then(res => {
|
| | | this.roleList = res.data;
|
| | | });
|
| | | },
|
| | | removeUserById (user) {
|
| | | // 弹框询问用户是否删除分类
|
| | | this.$confirm('此操作将永久删除该分类, 是否继续?', '提示', {
|
| | | confirmButtonText: '确定',
|
| | | cancelButtonText: '取消',
|
| | | type: 'warning'
|
| | | }).then(() => {
|
| | | removeById({ id: user.id }).then(() => {
|
| | | // 重新获取分类列表
|
| | | this.getUserList();
|
| | | this.$message.success("删除用户成功");
|
| | | });
|
| | | }).catch(() => {
|
| | | this.$message.info('已取消删除');
|
| | | });
|
| | | },
|
| | | handleSizeChange (newSize) {
|
| | | this.queryInfo.pageSize = newSize;
|
| | | this.getUserList()
|
| | | },
|
| | | handleCurrentChange (newPage) {
|
| | | this.queryInfo.pageNum = newPage;
|
| | | this.getUserList()
|
| | | },
|
| | | addDialogClosed () {
|
| | | this.$refs['addUserRef'].resetFields();
|
| | | },
|
| | | addUser () {
|
| | | this.$refs.addUserRef.validate(async valid => {
|
| | | if (!valid) return;
|
| | | saveOrUpdate(this.addUserForm).then(() => {
|
| | | this.$message.success("添加用户成功");
|
| | | // 隐藏添加分类对话框
|
| | | this.addDialogVisible = false;
|
| | | // 重新获取分类列表
|
| | | this.getUserList();
|
| | | });
|
| | | })
|
| | | },
|
| | | editUserInfo () {
|
| | | this.$refs.addCategoryRef.validate(async valid => {
|
| | | if (!valid) return;
|
| | |
|
| | | saveOrUpdate(this.editUserForm).then(() => {
|
| | | this.$message.success("修改用户成功");
|
| | | // 隐藏添加分类对话框
|
| | | this.editDialogVisible = false;
|
| | | // 重新获取分类列表
|
| | | this.getUserList();
|
| | | });
|
| | | })
|
| | | }
|
| | | }
|
| | | }
|
| | | </script>
|
| | |
|
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | |
|
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | |
|
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <router-link to="/home" tag="el-button" type="text">{{ $t('langHome') }}</router-link>
|
| | | <el-button type="text">设备管理</el-button>
|
| | | <router-link to="/device/iostate" tag="el-button" type="text">IO状态</router-link>
|
| | | <router-link to="/device/alarm" tag="el-button" type="text">报警信息</router-link>
|
| | | <router-link to="/device/parameter" tag="el-button" type="text">参数下发</router-link>
|
| | | <router-link to="/device/control" tag="el-button" type="text">开关控制</router-link>
|
| | | </el-breadcrumb>
|
| | | <div>开关控制</div>
|
| | | </div>
|
| | | </template>
|
| | | |
| | | <script>
|
| | |
|
| | | |
| | | export default {
|
| | | name: "control",
|
| | | |
| | | }
|
| | | |
| | | </script>
|
| | | |
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | | |
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | | |
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| | | |
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <router-link to="/home" tag="el-button" type="text">{{ $t('langHome') }}</router-link>
|
| | | <el-button type="text">设备管理</el-button>
|
| | | <router-link to="/device/iostate" tag="el-button" type="text">IO状态</router-link>
|
| | | <router-link to="/device/alarm" tag="el-button" type="text">报警信息</router-link>
|
| | | <router-link to="/device/parameter" tag="el-button" type="text">参数下发</router-link>
|
| | | <router-link to="/device/control" tag="el-button" type="text">开关控制</router-link>
|
| | | </el-breadcrumb>
|
| | | <div>IO状态</div>
|
| | | </div>
|
| | | </template>
|
| | | |
| | | <script>
|
| | |
|
| | | |
| | | export default {
|
| | | name: "iostate",
|
| | | |
| | | }
|
| | | |
| | | </script>
|
| | | |
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | | |
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | | |
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| | | |
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <!--面包屑导航区域-->
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb">
|
| | | <router-link to="/home" tag="el-button" type="text">{{ $t('langHome') }}</router-link>
|
| | | <el-button type="text">设备管理</el-button>
|
| | | <router-link to="/device/iostate" tag="el-button" type="text">IO状态</router-link>
|
| | | <router-link to="/device/alarm" tag="el-button" type="text">报警信息</router-link>
|
| | | <router-link to="/device/parameter" tag="el-button" type="text">参数下发</router-link>
|
| | | <router-link to="/device/control" tag="el-button" type="text">开关控制</router-link>
|
| | | </el-breadcrumb>
|
| | | <div>参数下发</div>
|
| | | </div>
|
| | | |
| | | </template>
|
| | |
|
| | | <script>
|
| | |
|
| | | |
| | | export default {
|
| | | name: "parameter",
|
| | | |
| | | }
|
| | | |
| | | </script>
|
| | | |
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | | |
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | | |
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| | | |
| New file |
| | |
| | | <template>
|
| | | <div class="app">
|
| | | <!--面包屑导航区域-->
|
| | | <el-breadcrumb separator-class="el-icon-arrow-right">
|
| | | <el-breadcrumb-item :to="{ path: '/home' }">首页</el-breadcrumb-item>
|
| | | |
| | | </el-breadcrumb>
|
| | | |
| | | </div>
|
| | | </template>
|
| | | |
| | | <script>
|
| | |
|
| | | |
| | | export default {
|
| | | name: "home",
|
| | | |
| | | }
|
| | | |
| | | </script>
|
| | | |
| | | <style lang="less" scoped>
|
| | | .el-table {
|
| | | margin-top: 15px;
|
| | | font-size: 12px;
|
| | | }
|
| | | |
| | | .el-pagination {
|
| | | margin-top: 15px;
|
| | | }
|
| | | |
| | | .app .el-card {
|
| | | width: 99%;
|
| | | }
|
| | | </style>
|
| | | |
| New file |
| | |
| | | <template> |
| | | <div class="login_container"> |
| | | <div class="system_title">{{ $t('systemTitle') }}</div> |
| | | <div class="login_box"> |
| | | <!--头像区域--> |
| | | <!-- <div class="avatar_box"> |
| | | <img src="../../assets/emi.png"> |
| | | </div> --> |
| | | |
| | | <!--登录表单区域--> |
| | | <el-form ref="loginFormRef" label-width="0px" class="login_form" :model="loginForm" :rules="loginFormRules"> |
| | | <!--用户名区域--> |
| | | <el-form-item prop="username"> |
| | | <el-input prefix-icon="el-icon-user" :placeholder="$t('usernamePlaceholder')" v-model="loginForm.username" type="text"></el-input> |
| | | </el-form-item> |
| | | <!--密码区域--> |
| | | <el-form-item prop="password"> |
| | | <el-input prefix-icon="el-icon-lock" v-model="loginForm.password" type="password" @keyup.enter.native="login" :placeholder="$t('passwordPlaceholder')"></el-input> |
| | | </el-form-item> |
| | | <!--按钮区域--> |
| | | <el-form-item class="btns"> |
| | | <el-button type="primary" @click="login">{{ $t('loginButton') }}</el-button> |
| | | <el-button type="primary" @click="register">{{ $t('registerButton') }}</el-button> |
| | | <el-button type="info" @click="resetLoginForm">{{ $t('resetButton') }}</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | | <!--语言切换按钮--> |
| | | <div class="language_switch"> |
| | | <el-button-group> |
| | | <el-button type="primary" @click="switchLanguage('zh-CN')">中文</el-button> |
| | | <el-button type="primary" @click="switchLanguage('en-US')">English</el-button> |
| | | </el-button-group> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | | |
| | | |
| | | |
| | | <script> |
| | | import {login} from '../../api/user' |
| | | import {setToken} from "../../utils/auth"; |
| | | import LanguageMixin from '../../lang/LanguageMixin' |
| | | |
| | | |
| | | |
| | | export default { |
| | | name: 'Login', |
| | | mixins: [LanguageMixin], |
| | | data() { |
| | | return { |
| | | // 登录表单的数据绑定对象 |
| | | loginForm: {}, |
| | | // 表单的验证规则对象 |
| | | loginFormRules: { |
| | | // 验证用户名是否合法 |
| | | username: [ |
| | | {required: true, message: '请输入用户名', trigger: 'blur'}, |
| | | {min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur'} |
| | | ], |
| | | // 验证密码是否合法 |
| | | password: [ |
| | | {required: true, message: '请输入密码', trigger: 'blur'}, |
| | | {min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur'} |
| | | ] |
| | | } |
| | | } |
| | | }, |
| | | |
| | | methods: { |
| | | // 点击重设按钮,重设登录表单 |
| | | resetLoginForm() { |
| | | this.$refs['loginFormRef'].resetFields() |
| | | }, |
| | | login() { |
| | | this.$refs.loginFormRef.validate(async valid => { |
| | | if (!valid) return; |
| | | login(this.loginForm).then(res => { |
| | | // 设置token |
| | | setToken(res.data.Authorization); |
| | | this.$router.push('/layout') |
| | | this.$message.success('登录成功'); |
| | | }); |
| | | }) |
| | | }, |
| | | register() { |
| | | this.$router.push('/register') |
| | | }, |
| | | |
| | | |
| | | |
| | | |
| | | }, |
| | | |
| | | |
| | | } |
| | | </script> |
| | | |
| | | <style lang="less" scoped> |
| | | .login_container { |
| | | background-color: #2b4b6b; |
| | | height: 100%; |
| | | } |
| | | |
| | | .login_box { |
| | | width: 450px; |
| | | height: 300px; |
| | | background-color: #fff; |
| | | border-radius: 3px; |
| | | position: absolute; |
| | | left: 50%; |
| | | top: 50%; |
| | | transform: translate(-50%, -50%); |
| | | |
| | | .avatar_box { |
| | | height: 130px; |
| | | width: 130px; |
| | | border: 1px solid #eee; |
| | | border-radius: 50%; |
| | | padding: 10px; |
| | | box-shadow: 0 0 10px #ddd; |
| | | position: absolute; |
| | | left: 50%; |
| | | transform: translate(-50%, -50%); |
| | | background-color: #fff; |
| | | |
| | | img { |
| | | width: 100%; |
| | | height: 100%; |
| | | border-radius: 50%; |
| | | background-color: #eee; |
| | | } |
| | | } |
| | | } |
| | | .system_title { |
| | | font-size: 24px; |
| | | font-weight: bold; |
| | | text-align: center; |
| | | margin-bottom: 20px; |
| | | top:50px; |
| | | } |
| | | .btns { |
| | | display: flex; |
| | | justify-content: flex-end; |
| | | } |
| | | |
| | | .login_form { |
| | | position: absolute; |
| | | bottom: 0; |
| | | width: 100%; |
| | | padding: 0 20px; |
| | | box-sizing: border-box; |
| | | } |
| | | </style> |
| New file |
| | |
| | | <template> |
| | | <div class="app"> |
| | | <!--面包屑导航区域--> |
| | | <el-breadcrumb separator-class="el-icon-arrow-right"> |
| | | <el-breadcrumb-item :to="{ path: '/home' }">首页</el-breadcrumb-item> |
| | | <el-breadcrumb-item>权限管理</el-breadcrumb-item> |
| | | <el-breadcrumb-item>权限列表</el-breadcrumb-item> |
| | | </el-breadcrumb> |
| | | <!--卡片视图区域--> |
| | | <el-card class="el-card"> |
| | | <el-row :gutter="20"> |
| | | <!--搜索与添加区域--> |
| | | <el-col :span="6"> |
| | | <el-input placeholder="请输入权限名称" v-model="queryInfo.name" clearable @clear="getPowerList()"> |
| | | <el-button slot="append" icon="el-icon-search" @click="getPowerList()"></el-button> |
| | | </el-input> |
| | | </el-col> |
| | | <!--添加区域--> |
| | | <el-col :span="4"> |
| | | <el-button type="primary" @click="showAddDialog">添加权限</el-button> |
| | | </el-col> |
| | | </el-row> |
| | | <!--权限列表区域--> |
| | | <el-table :data="powerList.records" border stripe> |
| | | <el-table-column label="#" type="index"></el-table-column> |
| | | <el-table-column label="角色" prop="role.name"></el-table-column> |
| | | <el-table-column label="权限描述" prop="permission.description"></el-table-column> |
| | | <el-table-column label="权限值" prop="permission.name"></el-table-column> |
| | | <el-table-column label="创建时间" prop="createTime"></el-table-column> |
| | | <el-table-column label="是否生效"> |
| | | <template slot-scope="scope"> |
| | | <el-switch :active-value=1 |
| | | :inactive-value=0 |
| | | v-model="scope.row.state" |
| | | @change="stateChange(scope.row)"> |
| | | </el-switch> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="操作"> |
| | | <template slot-scope="scope"> |
| | | <!--修改--> |
| | | <el-tooltip effect="dark" content="修改" placement="top" :enterable="false"> |
| | | <el-button type="primary" icon="el-icon-edit" size="mini" |
| | | @click="showEditDialog(scope.row)"></el-button> |
| | | </el-tooltip> |
| | | <!--删除--> |
| | | <el-tooltip effect="dark" content="删除" placement="top" :enterable="false"> |
| | | <el-button type="danger" icon="el-icon-delete" size="mini" |
| | | @click="removeById(scope.row)"></el-button> |
| | | </el-tooltip> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <!--分页区域--> |
| | | <el-pagination |
| | | @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange" |
| | | :current-page="queryInfo.pageNum" |
| | | :page-sizes="[10, 20, 30, 40]" |
| | | :page-size="queryInfo.pageSize" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | :total="powerList.total"> |
| | | </el-pagination> |
| | | </el-card> |
| | | <!--添加权限的对话框--> |
| | | <el-dialog |
| | | title="添加权限" |
| | | :visible.sync="addDialogVisible" |
| | | width="50%" |
| | | @close="addDialogClosed"> |
| | | <!--内容主体区域--> |
| | | <el-form :model="addPowerForm" :rules="powerRules" ref="powerRef" label-width="70px"> |
| | | <el-form-item label="角色" prop="roleId"> |
| | | <el-select filterable v-model="addPowerForm.roleId" placeholder="请选择"> |
| | | <el-option v-for="item in roleList" |
| | | :key="item.id" |
| | | :value="item.id" |
| | | :label="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="权限" prop="permissionId"> |
| | | <el-select filterable v-model="addPowerForm.permissionId" placeholder="请选择"> |
| | | <el-option v-for="item in permissionList" |
| | | :key="item.id" |
| | | :value="item.id" |
| | | :label="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="是否生效" prop="state"> |
| | | <el-select v-model="addPowerForm.state" placeholder="请选择"> |
| | | <el-option v-for="(item,index) in options" |
| | | :key="index" |
| | | :value="item.value" |
| | | :label="item.label"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addDialogVisible = false">取 消</el-button> |
| | | <el-button type="primary" @click="addPower">确 定</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!--修改权限的对话框--> |
| | | <el-dialog |
| | | title="修改权限" |
| | | :visible.sync="editDialogVisible" |
| | | width="50%"> |
| | | <!--内容主体区域--> |
| | | <el-form :model="editRoleForm" :rules="powerRules" ref="powerRef" label-width="70px"> |
| | | <el-form-item label="角色" prop="roleId"> |
| | | <el-select filterable v-model="editRoleForm.roleId" placeholder="请选择"> |
| | | <el-option v-for="item in roleList" |
| | | :key="item.id" |
| | | :value="item.id" |
| | | :label="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item filterable label="权限" prop="permissionId"> |
| | | <el-select v-model="editRoleForm.permissionId" placeholder="请选择"> |
| | | <el-option v-for="item in permissionList" |
| | | :key="item.id" |
| | | :value="item.id" |
| | | :label="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="是否生效" prop="state"> |
| | | <el-select v-model="editRoleForm.state" placeholder="请选择"> |
| | | <el-option v-for="(item,index) in options" |
| | | :key="index" |
| | | :value="item.value" |
| | | :label="item.label"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="editDialogVisible = false">取 消</el-button> |
| | | <el-button type="primary" @click="editRoleInfo">确 定</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import {getById, removeById, saveOrUpdate, selectPage} from "../../api/rolePermission"; |
| | | import {select} from "../../api/role"; |
| | | import {selectPermission} from "../../api/permission"; |
| | | |
| | | export default { |
| | | name: "Power", |
| | | data() { |
| | | return { |
| | | queryInfo: { |
| | | pageNum: 1, |
| | | pageSize: 10 |
| | | }, |
| | | powerList: { |
| | | records: [], |
| | | total: 0 |
| | | }, |
| | | // 控制添加权限弹框的显示和隐藏 |
| | | addDialogVisible: false, |
| | | // 控制修改权限对话框的显示与隐藏 |
| | | editDialogVisible: false, |
| | | // 添加的权限对象 |
| | | addPowerForm: { |
| | | roleId: null, |
| | | permissionId: null, |
| | | state: 1 |
| | | }, |
| | | // 修改的权限对象 |
| | | editRoleForm: { |
| | | roleId: null, |
| | | permissionId: null |
| | | }, |
| | | // 添加权限的验证规则 |
| | | powerRules: { |
| | | roleId: [ |
| | | {required: true, message: '请输入角色', trigger: 'blur'} |
| | | ], |
| | | permissionId: [ |
| | | {required: true, message: '请输入权限描述', trigger: 'blur'}, |
| | | ] |
| | | }, |
| | | options: [ |
| | | {label: '生效', value: 1}, |
| | | {label: '无效', value: 0} |
| | | ], |
| | | roleList: [], |
| | | permissionList: [] |
| | | } |
| | | }, |
| | | created() { |
| | | this.getPowerList(); |
| | | }, |
| | | methods: { |
| | | getPowerList() { |
| | | selectPage(this.queryInfo).then(res => { |
| | | this.powerList.total = res.data.total; |
| | | this.powerList.records = res.data.records; |
| | | }); |
| | | }, |
| | | // 监听pageSize改变的事件 |
| | | handleSizeChange(newSize) { |
| | | this.queryInfo.pageSize = newSize; |
| | | this.getPowerList() |
| | | }, |
| | | // 监听pageNum改变的事件 |
| | | handleCurrentChange(newPage) { |
| | | this.queryInfo.pageNum = newPage; |
| | | this.getPowerList() |
| | | }, |
| | | stateChange(info) { |
| | | saveOrUpdate(info).then(() => { |
| | | this.$message.success("更新状态成功") |
| | | }); |
| | | }, |
| | | // 监听添加权限对话框的关闭事件 |
| | | addDialogClosed() { |
| | | this.$refs['powerRef'].resetFields(); |
| | | }, |
| | | // 点击按钮添加新权限 |
| | | addPower() { |
| | | this.$refs.powerRef.validate(async valid => { |
| | | if (!valid) return; |
| | | // 发起添加权限的网络请求 |
| | | saveOrUpdate(this.addPowerForm).then(() => { |
| | | // 重新获取权限列表 |
| | | this.getPowerList(); |
| | | // 隐藏添加权限对话框 |
| | | this.addDialogVisible = false; |
| | | this.$message.success("添加权限成功"); |
| | | }); |
| | | }) |
| | | }, |
| | | // 展示修改权限的对话框 |
| | | showEditDialog(role) { |
| | | getById({id: role.id}).then(res => { |
| | | this.editRoleForm = res.data; |
| | | }); |
| | | select(this.addPowerForm).then(res => { |
| | | this.roleList = res.data; |
| | | }); |
| | | selectPermission(this.addPowerForm).then(res => { |
| | | this.permissionList = res.data; |
| | | }); |
| | | this.editDialogVisible = true; |
| | | }, |
| | | // 展示添加权限的对话框 |
| | | showAddDialog() { |
| | | select(this.addPowerForm).then(res => { |
| | | this.roleList = res.data; |
| | | }); |
| | | selectPermission(this.addPowerForm).then(res => { |
| | | this.permissionList = res.data; |
| | | }); |
| | | this.addDialogVisible = true; |
| | | }, |
| | | // 修改权限信息并提交 |
| | | editRoleInfo() { |
| | | this.$refs.powerRef.validate(async valid => { |
| | | if (!valid) return; |
| | | // 发起修改权限的网络请求 |
| | | saveOrUpdate(this.editRoleForm).then(() => { |
| | | // 重新获取权限列表 |
| | | this.getPowerList(); |
| | | // 隐藏添加权限对话框 |
| | | this.editDialogVisible = false; |
| | | this.$message.success("修改权限成功"); |
| | | }); |
| | | }) |
| | | }, |
| | | // 根据id删除权限信息 |
| | | removeById(power) { |
| | | // 弹框询问用户是否删除权限 |
| | | this.$confirm('此操作将永久删除该权限, 是否继续?', '提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | // 删除权限 |
| | | removeById({id: power.id}).then(() => { |
| | | // 重新获取权限列表 |
| | | this.getPowerList(); |
| | | this.$message.success("删除权限成功"); |
| | | }); |
| | | }).catch(() => { |
| | | this.$message.info('已取消删除'); |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="less" scoped> |
| | | .el-table { |
| | | margin-top: 15px; |
| | | font-size: 12px; |
| | | } |
| | | |
| | | .el-pagination { |
| | | margin-top: 15px; |
| | | } |
| | | |
| | | .app .el-card { |
| | | width: 99%; |
| | | } |
| | | </style> |
| New file |
| | |
| | | <template> |
| | | <div class="login_container"> |
| | | <div class="login_box"> |
| | | <!--头像区域--> |
| | | <div class="avatar_box"> |
| | | <img src="../../assets/emi.png"> |
| | | </div> |
| | | <el-form ref="registerRef" :model="registerForm" label-width="80px" :rules="registerRules" |
| | | class="login_form"> |
| | | <el-form-item label="用户名" prop="username"> |
| | | <el-input v-model="registerForm.username" placeholder="请输入用户名"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="密码" prop="password1"> |
| | | <el-input v-model="registerForm.password1" placeholder="请输入密码" type="password"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="确认密码" prop="password"> |
| | | <el-input v-model="registerForm.password" placeholder="请再次输入用户名" type="password"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="邮箱" prop="email"> |
| | | <el-input v-model="registerForm.email" placeholder="请输入邮箱" type="text"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="QQ" prop="qq"> |
| | | <el-input v-model="registerForm.qq" placeholder="请输入QQ" type="text"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="手机号码" prop="phone"> |
| | | <el-input v-model="registerForm.phone" placeholder="请输入手机号码" type="text"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" @click="register">注册</el-button> |
| | | <el-button @click="reset">重设</el-button> |
| | | <el-button @click="toLogin">取消</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import {register} from '../../api/user' |
| | | |
| | | export default { |
| | | name: 'Register', |
| | | data() { |
| | | // 自定义校验规则 |
| | | const validatePassword = (rule, value, callback) => { |
| | | if (this.registerForm.password1 !== this.registerForm.password) { |
| | | callback(new Error("两次输入密码不一致!")); |
| | | } else { |
| | | callback(); |
| | | } |
| | | }; |
| | | return { |
| | | registerForm: {}, |
| | | registerRules: { |
| | | username: [ |
| | | {required: true, message: '请输入用户名', trigger: 'blur'}, |
| | | {min: 5, max: 15, message: '长度在 5 到 5 个字符', trigger: 'blur'} |
| | | ], |
| | | password1: [ |
| | | {required: true, message: '请输入密码', trigger: 'blur'}, |
| | | {min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur'}, |
| | | {validator: validatePassword, trigger: "blur"} |
| | | ], |
| | | password: [ |
| | | {required: true, message: '请输入密码', trigger: 'blur'}, |
| | | {min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur'}, |
| | | {validator: validatePassword, trigger: "blur"} |
| | | ], |
| | | email: [ |
| | | {required: false, message: '请输入邮箱', trigger: 'blur'}, |
| | | {type: 'email', message: '请输入正确格式的邮箱地址', trigger: 'blur'} |
| | | ] |
| | | } |
| | | } |
| | | }, |
| | | methods: { |
| | | register() { |
| | | this.$refs.registerRef.validate(async valid => { |
| | | if (!valid) return; |
| | | register(this.registerForm).then(() => { |
| | | this.$router.push('/login') |
| | | this.$message.success('注册成功'); |
| | | }); |
| | | }) |
| | | }, |
| | | reset() { |
| | | this.$refs['registerRef'].resetFields(); |
| | | }, |
| | | toLogin() { |
| | | this.$router.push('/login') |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped lang="less"> |
| | | .login_container { |
| | | background-color: #2b4b6b; |
| | | height: 100%; |
| | | } |
| | | |
| | | .login_box { |
| | | width: 450px; |
| | | height: 550px; |
| | | background-color: #fff; |
| | | border-radius: 3px; |
| | | position: absolute; |
| | | left: 50%; |
| | | top: 50%; |
| | | transform: translate(-50%, -50%); |
| | | |
| | | .avatar_box { |
| | | height: 130px; |
| | | width: 130px; |
| | | border: 1px solid #eee; |
| | | border-radius: 50%; |
| | | padding: 10px; |
| | | box-shadow: 0 0 10px #ddd; |
| | | position: absolute; |
| | | left: 50%; |
| | | transform: translate(-50%, -50%); |
| | | background-color: #fff; |
| | | |
| | | img { |
| | | width: 100%; |
| | | height: 100%; |
| | | border-radius: 50%; |
| | | background-color: #eee; |
| | | } |
| | | } |
| | | } |
| | | |
| | | .btns { |
| | | display: flex; |
| | | justify-content: flex-end; |
| | | } |
| | | |
| | | .login_form { |
| | | position: absolute; |
| | | bottom: 0; |
| | | width: 100%; |
| | | padding: 0 20px; |
| | | box-sizing: border-box; |
| | | } |
| | | </style> |
| New file |
| | |
| | | <template> |
| | | <div class="app"> |
| | | <!--面包屑导航区域--> |
| | | <el-breadcrumb separator-class="el-icon-arrow-right"> |
| | | <el-breadcrumb-item :to="{ path: '/home' }">首页</el-breadcrumb-item> |
| | | <el-breadcrumb-item>角色管理</el-breadcrumb-item> |
| | | <el-breadcrumb-item>角色列表</el-breadcrumb-item> |
| | | </el-breadcrumb> |
| | | <!--卡片视图区域--> |
| | | <el-card class="el-card"> |
| | | <el-row :gutter="20"> |
| | | <!--搜索与添加区域--> |
| | | <el-col :span="6"> |
| | | <el-input placeholder="请输入角色名称" v-model="queryInfo.name" clearable @clear="getRoleList()"> |
| | | <el-button slot="append" icon="el-icon-search" @click="getRoleList()"></el-button> |
| | | </el-input> |
| | | </el-col> |
| | | <!--添加区域--> |
| | | <el-col :span="4"> |
| | | <el-button type="primary" @click="showAddDialog">添加角色</el-button> |
| | | </el-col> |
| | | </el-row> |
| | | <!--角色列表区域--> |
| | | <el-table :data="roleList.records" border stripe> |
| | | <el-table-column label="#" type="index"></el-table-column> |
| | | <el-table-column label="名称" prop="name"></el-table-column> |
| | | <el-table-column label="创建时间" prop="createTime"></el-table-column> |
| | | <el-table-column label="是否有效"> |
| | | <template slot-scope="scope"> |
| | | <el-switch :active-value=1 |
| | | :inactive-value=0 |
| | | v-model="scope.row.state" |
| | | @change="stateChange(scope.row)"> |
| | | </el-switch> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="操作"> |
| | | <template slot-scope="scope"> |
| | | <!--修改--> |
| | | <el-tooltip effect="dark" content="修改" placement="top" :enterable="false"> |
| | | <el-button type="primary" icon="el-icon-edit" size="mini" |
| | | @click="showEditDialog(scope.row)"></el-button> |
| | | </el-tooltip> |
| | | <!--删除--> |
| | | <el-tooltip effect="dark" content="删除" placement="top" :enterable="false"> |
| | | <el-button type="danger" icon="el-icon-delete" size="mini" |
| | | @click="removeById(scope.row)"></el-button> |
| | | </el-tooltip> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <!--分页区域--> |
| | | <el-pagination |
| | | @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange" |
| | | :current-page="queryInfo.pageNum" |
| | | :page-sizes="[10, 20, 30, 40]" |
| | | :page-size="queryInfo.pageSize" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | :total="roleList.total"> |
| | | </el-pagination> |
| | | </el-card> |
| | | <!--添加角色的对话框--> |
| | | <el-dialog |
| | | title="添加角色" |
| | | :visible.sync="addDialogVisible" |
| | | width="50%" |
| | | @close="addDialogClosed"> |
| | | <!--内容主体区域--> |
| | | <el-form :model="addRoleForm" :rules="addRoleRules" ref="addRoleRef" label-width="70px"> |
| | | <el-form-item label="名称" prop="name"> |
| | | <el-input v-model="addRoleForm.name"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="状态" prop="state"> |
| | | <el-select v-model="addRoleForm.state" placeholder="请选择"> |
| | | <el-option v-for="(item,index) in options" |
| | | :key="index" |
| | | :value="item.value" |
| | | :label="item.label"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addDialogVisible = false">取 消</el-button> |
| | | <el-button type="primary" @click="addRole">确 定</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!--修改角色的对话框--> |
| | | <el-dialog |
| | | title="修改角色" |
| | | :visible.sync="editDialogVisible" |
| | | width="50%"> |
| | | <!--内容主体区域--> |
| | | <el-form :model="editRoleForm" :rules="addRoleRules" ref="addRoleRef" label-width="70px"> |
| | | <el-form-item label="名称" prop="name"> |
| | | <el-input v-model="editRoleForm.name"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="状态" prop="state"> |
| | | <el-select v-model="editRoleForm.state" placeholder="请选择"> |
| | | <el-option v-for="(item,index) in options" |
| | | :key="index" |
| | | :value="item.value" |
| | | :label="item.label"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="editDialogVisible = false">取 消</el-button> |
| | | <el-button type="primary" @click="editRoleInfo">确 定</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import {getById, removeById, saveOrUpdate, selectPage} from "../../api/role"; |
| | | |
| | | export default { |
| | | name: "Role", |
| | | data() { |
| | | return { |
| | | queryInfo: { |
| | | pageNum: 1, |
| | | pageSize: 10 |
| | | }, |
| | | roleList: { |
| | | records: [], |
| | | total: 0 |
| | | }, |
| | | // 控制添加角色弹框的显示和隐藏 |
| | | addDialogVisible: false, |
| | | // 控制修改角色对话框的显示与隐藏 |
| | | editDialogVisible: false, |
| | | // 添加的角色对象 |
| | | addRoleForm: { |
| | | state: 1 |
| | | }, |
| | | // 修改的角色对象 |
| | | editRoleForm: {}, |
| | | // 添加角色的验证规则 |
| | | addRoleRules: { |
| | | name: [ |
| | | {required: true, message: '请输入名称', trigger: 'blur'}, |
| | | {min: 2, max: 15, message: '长度在 2 到 15 个字符', trigger: 'blur'} |
| | | ], |
| | | state: [ |
| | | {required: true, message: '请输入状态', trigger: 'blur'} |
| | | ] |
| | | }, |
| | | options: [ |
| | | {label: '有效', value: 1}, |
| | | {label: '无效', value: 0} |
| | | ] |
| | | } |
| | | }, |
| | | created() { |
| | | this.getRoleList(); |
| | | }, |
| | | methods: { |
| | | getRoleList() { |
| | | selectPage(this.queryInfo).then(res => { |
| | | this.roleList.total = res.data.total; |
| | | this.roleList.records = res.data.records; |
| | | }); |
| | | }, |
| | | // 监听pageSize改变的事件 |
| | | handleSizeChange(newSize) { |
| | | this.queryInfo.pageSize = newSize; |
| | | this.getRoleList() |
| | | }, |
| | | // 监听pageNum改变的事件 |
| | | handleCurrentChange(newPage) { |
| | | this.queryInfo.pageNum = newPage; |
| | | this.getRoleList() |
| | | }, |
| | | stateChange(info) { |
| | | saveOrUpdate(info).then(() => { |
| | | this.$message.success("更新状态成功") |
| | | |
| | | }); |
| | | }, |
| | | // 监听添加角色对话框的关闭事件 |
| | | addDialogClosed() { |
| | | this.$refs['addRoleRef'].resetFields(); |
| | | }, |
| | | // 点击按钮添加新角色 |
| | | addRole() { |
| | | this.$refs.addRoleRef.validate(async valid => { |
| | | if (!valid) return; |
| | | // 发起添加角色的网络请求 |
| | | saveOrUpdate(this.addRoleForm).then(() => { |
| | | // 重新获取角色列表 |
| | | this.getRoleList(); |
| | | // 隐藏添加角色对话框 |
| | | this.addDialogVisible = false; |
| | | this.$message.success("添加角色成功"); |
| | | }); |
| | | }) |
| | | }, |
| | | // 展示修改角色的对话框 |
| | | showEditDialog(role) { |
| | | getById({id: role.id}).then(res => { |
| | | this.editRoleForm = res.data; |
| | | this.editDialogVisible = true; |
| | | }); |
| | | }, |
| | | // 展示添加角色的对话框 |
| | | showAddDialog() { |
| | | this.addDialogVisible = true; |
| | | }, |
| | | // 修改角色信息并提交 |
| | | editRoleInfo() { |
| | | this.$refs.addRoleRef.validate(async valid => { |
| | | if (!valid) return; |
| | | // 发起修改角色的网络请求 |
| | | saveOrUpdate(this.editRoleForm).then(() => { |
| | | // 重新获取角色列表 |
| | | this.getRoleList(); |
| | | // 隐藏添加角色对话框 |
| | | this.editDialogVisible = false; |
| | | this.$message.success("修改角色成功"); |
| | | }); |
| | | }) |
| | | }, |
| | | // 根据id删除角色信息 |
| | | removeById(role) { |
| | | // 弹框询问用户是否删除角色 |
| | | this.$confirm('此操作将永久删除该角色, 是否继续?', '提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | // 删除角色 |
| | | removeById({id: role.id}).then(() => { |
| | | // 重新获取角色列表 |
| | | this.getRoleList(); |
| | | this.$message.success("删除角色成功"); |
| | | }); |
| | | }).catch(() => { |
| | | this.$message('已取消删除'); |
| | | }); |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="less" scoped> |
| | | .el-table { |
| | | margin-top: 15px; |
| | | font-size: 12px; |
| | | } |
| | | |
| | | .el-pagination { |
| | | margin-top: 15px; |
| | | } |
| | | |
| | | .app .el-card { |
| | | width: 99%; |
| | | } |
| | | </style> |
| New file |
| | |
| | | <template> |
| | | <div class="app"> |
| | | <!--面包屑导航区域--> |
| | | <el-breadcrumb separator-class="el-icon-arrow-right" class="el-breadcrumb"> |
| | | <el-breadcrumb-item :to="{ path: '/home' }">{{ $t('langHome') }}</el-breadcrumb-item> |
| | | <el-breadcrumb-item>{{ $t('langUserManagement') }}</el-breadcrumb-item> |
| | | <el-breadcrumb-item>{{ $t('langUserList') }}</el-breadcrumb-item> |
| | | </el-breadcrumb> |
| | | <!--卡片视图区域--> |
| | | <el-card class="el-card"> |
| | | <el-row :gutter="20"> |
| | | <!--搜索与添加区域--> |
| | | <el-col :span="6"> |
| | | <el-input v-model="queryInfo.username" clearable @clear="getUserList"> |
| | | </el-input> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-input v-model="queryInfo.email" clearable @clear="getUserList"> |
| | | </el-input> |
| | | </el-col> |
| | | <!--搜索按钮--> |
| | | <el-col :span="4"> |
| | | <el-button type="primary" @click="getUserList">{{ $t('langSearch') }}</el-button> |
| | | </el-col> |
| | | <!--添加区域--> |
| | | <el-col :span="4"> |
| | | <el-button type="primary" @click="showAddDialog">{{ $t('langAddUser') }}</el-button> |
| | | </el-col> |
| | | </el-row> |
| | | <!--用户列表区域--> |
| | | <el-table :data="userList.records" border stripe> |
| | | <el-table-column label="#" type="index"></el-table-column> |
| | | <el-table-column :label="$t('langUsername')" prop="username"></el-table-column> |
| | | <el-table-column :label="$t('langEmail')" prop="email"></el-table-column> |
| | | <el-table-column :label="$t('langCreateTime')" prop="createTime"></el-table-column> |
| | | <el-table-column :label="$t('langDisabled')"> |
| | | <template slot-scope="scope"> |
| | | <el-switch |
| | | :active-value="0" |
| | | :inactive-value="1" |
| | | v-model="scope.row.state" |
| | | @change="stateChange(scope.row)"> |
| | | </el-switch> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column :label="$t('langAction')"> |
| | | <template slot-scope="scope"> |
| | | <!--修改--> |
| | | <el-tooltip effect="dark" :content="$t('langEdit')" placement="top" :enterable="false"> |
| | | <el-button type="primary" icon="el-icon-edit" size="mini" |
| | | @click="showEditDialog(scope.row.id)"></el-button> |
| | | </el-tooltip> |
| | | <!--删除--> |
| | | <el-tooltip effect="dark" :content="$t('langDelete')" placement="top" :enterable="false"> |
| | | <el-button type="danger" icon="el-icon-delete" size="mini" |
| | | @click="removeUserById(scope.row)"></el-button> |
| | | </el-tooltip> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <!--分页区域--> |
| | | <el-pagination |
| | | @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange" |
| | | :current-page="queryInfo.pageNum" |
| | | :page-sizes="[10, 20, 30, 40]" |
| | | :page-size="queryInfo.pageSize" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | :total="userList.total"> |
| | | </el-pagination> |
| | | </el-card> |
| | | <!--添加用户的对话框--> |
| | | <el-dialog |
| | | :title="$t('langAddUserTitle')" |
| | | :visible.sync="addDialogVisible" |
| | | width="50%" |
| | | @close="addDialogClosed"> |
| | | <!--内容主体区域--> |
| | | <el-form :model="addUserForm" :rules="addUserRules" ref="addUserRef" label-width="70px"> |
| | | <el-form-item :label="$t('langUsername')" prop="username"> |
| | | <el-input v-model="addUserForm.username"></el-input> |
| | | </el-form-item> |
| | | <el-form-item :label="$t('langPassword')" prop="password"> |
| | | <el-input v-model="addUserForm.password" type="password"></el-input> |
| | | </el-form-item> |
| | | <el-form-item :label="$t('langEmail')" prop="email"> |
| | | <el-input v-model="addUserForm.email"></el-input> |
| | | </el-form-item> |
| | | <el-form-item :label="$t('langState')" prop="state"> |
| | | <el-select v-model="addUserForm.state" > |
| | | <el-option v-for="(item,index) in options" |
| | | :key="index" |
| | | :value="item.value" |
| | | :label="item.label"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addDialogVisible = false">{{ $t('langCancel') }}</el-button> |
| | | <el-button type="primary" @click="addUser">{{ $t('langConfirm') }}</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!--修改用户的对话框--> |
| | | <el-dialog |
| | | :title="$t('langEditUserTitle')" |
| | | :visible.sync="editDialogVisible" |
| | | width="50%"> |
| | | <!--内容主体区域--> |
| | | <el-form :model="editUserForm" :rules="addUserRules" ref="addCategoryRef" label-width="70px"> |
| | | <el-form-item :label="$t('langUsername')" prop="username"> |
| | | <el-input v-model="editUserForm.username" disabled></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="角色" prop="roleId"> |
| | | <el-select filterable v-model="editUserForm.roleId" placeholder="请选择"> |
| | | <el-option v-for="item in roleList" |
| | | :key="item.id" |
| | | :value="item.id" |
| | | :label="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item :label="$t('langEmail')" prop="email"> |
| | | <el-input v-model="editUserForm.email"></el-input> |
| | | </el-form-item> |
| | | <el-form-item :label="$t('langDisabled')" prop="state"> |
| | | <el-select v-model="editUserForm.state" > |
| | | <el-option v-for="(item,index) in options" |
| | | :key="index" |
| | | :value="item.value" |
| | | :label="item.label"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="editDialogVisible = false">{{ $t('langCancel') }}</el-button> |
| | | <el-button type="primary" @click="editUserInfo">{{ $t('langConfirm') }}</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | |
| | | <script> |
| | | import {getById, removeById, saveOrUpdate, selectPage} from "../../api/user"; |
| | | import {select} from "../../api/role"; |
| | | |
| | | import LanguageMixin from '../../lang/LanguageMixin' |
| | | export default { |
| | | name: "User", |
| | | mixins: [LanguageMixin], |
| | | data() { |
| | | return { |
| | | queryInfo: { |
| | | pageNum: 1, |
| | | pageSize: 10 |
| | | }, |
| | | userList: { |
| | | records: [], |
| | | total: 0, |
| | | }, |
| | | // 添加的用户对象 |
| | | addUserForm: { |
| | | state: 1 |
| | | }, |
| | | // 修改的用户对象 |
| | | editUserForm: { |
| | | |
| | | roleId: null, |
| | | name:null, |
| | | roleid:null, |
| | | }, |
| | | // 添加分类的验证规则 |
| | | addUserRules: { |
| | | roleId: null, |
| | | username: [ |
| | | {required: true, message: '请输入用户名', trigger: 'blur'}, |
| | | {min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur'} |
| | | ], |
| | | password: [ |
| | | {required: true, message: '请输入密码', trigger: 'blur'}, |
| | | {min: 5, max: 15, message: '长度在 5 到 15 个字符', trigger: 'blur'} |
| | | ], |
| | | email: [ |
| | | {required: true, message: '请输入邮箱', trigger: 'blur'}, |
| | | {type: 'email', message: '请输入正确格式的邮箱地址', trigger: 'blur'} |
| | | ] |
| | | }, |
| | | // 控制添加用户弹框的显示和隐藏 |
| | | addDialogVisible: false, |
| | | // 控制修改用户弹框的显示和隐藏 |
| | | editDialogVisible: false, |
| | | options: [ |
| | | {label: '正常', value: 1}, |
| | | {label: '禁用', value: 0} |
| | | ], |
| | | roleList: [], |
| | | } |
| | | }, |
| | | created() { |
| | | this.getUserList(); |
| | | }, |
| | | methods: { |
| | | getUserList() { |
| | | selectPage(this.queryInfo).then(res => { |
| | | this.userList.records = res.data.records; |
| | | this.userList.total = res.data.total |
| | | }); |
| | | }, |
| | | |
| | | showAddDialog() { |
| | | this.addDialogVisible = true; |
| | | }, |
| | | stateChange(info) { |
| | | saveOrUpdate(info).then(() => { |
| | | this.$message.success("更新状态成功") |
| | | }); |
| | | }, |
| | | showEditDialog(id) { |
| | | getById({id: id}).then(res => { |
| | | this.editUserForm = res.data; |
| | | this.editDialogVisible = true; |
| | | }); |
| | | select().then(res => { |
| | | this.roleList = res.data; |
| | | }); |
| | | }, |
| | | removeUserById(user) { |
| | | // 弹框询问用户是否删除分类 |
| | | this.$confirm('此操作将永久删除该分类, 是否继续?', '提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | removeById({id: user.id}).then(() => { |
| | | // 重新获取分类列表 |
| | | this.getUserList(); |
| | | this.$message.success("删除用户成功"); |
| | | }); |
| | | }).catch(() => { |
| | | this.$message.info('已取消删除'); |
| | | }); |
| | | }, |
| | | handleSizeChange(newSize) { |
| | | this.queryInfo.pageSize = newSize; |
| | | this.getUserList() |
| | | }, |
| | | handleCurrentChange(newPage) { |
| | | this.queryInfo.pageNum = newPage; |
| | | this.getUserList() |
| | | }, |
| | | addDialogClosed() { |
| | | this.$refs['addUserRef'].resetFields(); |
| | | }, |
| | | addUser() { |
| | | this.$refs.addUserRef.validate(async valid => { |
| | | if (!valid) return; |
| | | saveOrUpdate(this.addUserForm).then(() => { |
| | | this.$message.success("添加用户成功"); |
| | | // 隐藏添加分类对话框 |
| | | this.addDialogVisible = false; |
| | | // 重新获取分类列表 |
| | | this.getUserList(); |
| | | }); |
| | | }) |
| | | }, |
| | | editUserInfo() { |
| | | this.$refs.addCategoryRef.validate(async valid => { |
| | | if (!valid) return; |
| | | |
| | | saveOrUpdate(this.editUserForm).then(() => { |
| | | this.$message.success("修改用户成功"); |
| | | // 隐藏添加分类对话框 |
| | | this.editDialogVisible = false; |
| | | // 重新获取分类列表 |
| | | this.getUserList(); |
| | | }); |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="less" scoped> |
| | | .el-table { |
| | | margin-top: 15px; |
| | | font-size: 12px; |
| | | } |
| | | |
| | | .el-pagination { |
| | | margin-top: 15px; |
| | | } |
| | | |
| | | .app .el-card { |
| | | width: 99%; |
| | | } |
| | | </style> |
| New file |
| | |
| | | const path = require('path'); |
| | | |
| | | function resolve(dir) { |
| | | path.join(__dirname, dir); |
| | | } |
| | | |
| | | module.exports = { |
| | | devServer: { |
| | | proxy: { |
| | | '/api': { |
| | | target: `http://127.0.0.1:8888/canadames`, |
| | | changeOrigin: true, |
| | | pathRewrite: { |
| | | '^/api': '' |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | configureWebpack: { |
| | | resolve: { |
| | | extensions: ['js', 'vue'], |
| | | alias: { |
| | | '@': resolve('src') |
| | | } |
| | | } |
| | | } |
| | | } |