Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
29e8dc5241
|
|
@ -6,7 +6,7 @@ spring:
|
||||||
druid:
|
druid:
|
||||||
# 主库数据源
|
# 主库数据源
|
||||||
master:
|
master:
|
||||||
url: jdbc:mysql://localhost:3306/ry?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true
|
url: jdbc:mysql://localhost:3306/jeesis-exam?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true
|
||||||
username: root
|
username: root
|
||||||
password: root
|
password: root
|
||||||
# 从库数据源
|
# 从库数据源
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ ruoyi:
|
||||||
# 开发环境配置
|
# 开发环境配置
|
||||||
server:
|
server:
|
||||||
# 服务端口
|
# 服务端口
|
||||||
port: 80
|
port: 8099
|
||||||
servlet:
|
servlet:
|
||||||
# 项目contextPath
|
# 项目contextPath
|
||||||
context-path: /
|
context-path: /
|
||||||
|
|
|
||||||
|
|
@ -12,54 +12,54 @@
|
||||||
</appender>
|
</appender>
|
||||||
|
|
||||||
<!-- 系统日志输出 -->
|
<!-- 系统日志输出 -->
|
||||||
<appender name="file_info" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
<!--<appender name="file_info" class="ch.qos.logback.core.rolling.RollingFileAppender">-->
|
||||||
<file>${log.path}/sys-info.log</file>
|
<!--<file>${log.path}/sys-info.log</file>-->
|
||||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
<!--<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">-->
|
||||||
<!-- 按天回滚 daily -->
|
<!--<!– 按天回滚 daily –>-->
|
||||||
<fileNamePattern>${log.path}/sys-info.%d{yyyy-MM-dd}.log</fileNamePattern>
|
<!--<fileNamePattern>${log.path}/sys-info.%d{yyyy-MM-dd}.log</fileNamePattern>-->
|
||||||
<!-- 日志最大的历史 60天 -->
|
<!--<!– 日志最大的历史 60天 –>-->
|
||||||
<maxHistory>60</maxHistory>
|
<!--<maxHistory>60</maxHistory>-->
|
||||||
</rollingPolicy>
|
<!--</rollingPolicy>-->
|
||||||
<encoder>
|
<!--<encoder>-->
|
||||||
<pattern>${log.pattern}</pattern>
|
<!--<pattern>${log.pattern}</pattern>-->
|
||||||
</encoder>
|
<!--</encoder>-->
|
||||||
<filter class="ch.qos.logback.classic.filter.LevelFilter">
|
<!--<filter class="ch.qos.logback.classic.filter.LevelFilter">-->
|
||||||
<level>INFO</level>
|
<!--<level>INFO</level>-->
|
||||||
<onMatch>ACCEPT</onMatch>
|
<!--<onMatch>ACCEPT</onMatch>-->
|
||||||
<onMismatch>DENY</onMismatch>
|
<!--<onMismatch>DENY</onMismatch>-->
|
||||||
</filter>
|
<!--</filter>-->
|
||||||
</appender>
|
<!--</appender>-->
|
||||||
|
<!---->
|
||||||
<appender name="file_error" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
<!--<appender name="file_error" class="ch.qos.logback.core.rolling.RollingFileAppender">-->
|
||||||
<file>${log.path}/sys-error.log</file>
|
<!--<file>${log.path}/sys-error.log</file>-->
|
||||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
<!--<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">-->
|
||||||
<fileNamePattern>${log.path}/sys-error.%d{yyyy-MM-dd}.log</fileNamePattern>
|
<!--<fileNamePattern>${log.path}/sys-error.%d{yyyy-MM-dd}.log</fileNamePattern>-->
|
||||||
<!-- 日志最大的历史 60天 -->
|
<!--<!– 日志最大的历史 60天 –>-->
|
||||||
<maxHistory>60</maxHistory>
|
<!--<maxHistory>60</maxHistory>-->
|
||||||
</rollingPolicy>
|
<!--</rollingPolicy>-->
|
||||||
<encoder>
|
<!--<encoder>-->
|
||||||
<pattern>${log.pattern}</pattern>
|
<!--<pattern>${log.pattern}</pattern>-->
|
||||||
</encoder>
|
<!--</encoder>-->
|
||||||
<filter class="ch.qos.logback.classic.filter.LevelFilter">
|
<!--<filter class="ch.qos.logback.classic.filter.LevelFilter">-->
|
||||||
<level>ERROR</level>
|
<!--<level>ERROR</level>-->
|
||||||
<onMatch>ACCEPT</onMatch>
|
<!--<onMatch>ACCEPT</onMatch>-->
|
||||||
<onMismatch>DENY</onMismatch>
|
<!--<onMismatch>DENY</onMismatch>-->
|
||||||
</filter>
|
<!--</filter>-->
|
||||||
</appender>
|
<!--</appender>-->
|
||||||
|
|
||||||
<!-- 用户访问日志输出 -->
|
<!-- 用户访问日志输出 -->
|
||||||
<appender name="sys-user" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
<!--<appender name="sys-user" class="ch.qos.logback.core.rolling.RollingFileAppender">-->
|
||||||
<file>${log.path}/sys-user.log</file>
|
<!--<file>${log.path}/sys-user.log</file>-->
|
||||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
<!--<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">-->
|
||||||
<!-- 按天回滚 daily -->
|
<!--<!– 按天回滚 daily –>-->
|
||||||
<fileNamePattern>${log.path}/sys-user.%d{yyyy-MM-dd}.log</fileNamePattern>
|
<!--<fileNamePattern>${log.path}/sys-user.%d{yyyy-MM-dd}.log</fileNamePattern>-->
|
||||||
<!-- 日志最大的历史 60天 -->
|
<!--<!– 日志最大的历史 60天 –>-->
|
||||||
<maxHistory>60</maxHistory>
|
<!--<maxHistory>60</maxHistory>-->
|
||||||
</rollingPolicy>
|
<!--</rollingPolicy>-->
|
||||||
<encoder>
|
<!--<encoder>-->
|
||||||
<pattern>${log.pattern}</pattern>
|
<!--<pattern>${log.pattern}</pattern>-->
|
||||||
</encoder>
|
<!--</encoder>-->
|
||||||
</appender>
|
<!--</appender>-->
|
||||||
|
|
||||||
<!-- 显示形成的sql、使用的参数、结果集 -->
|
<!-- 显示形成的sql、使用的参数、结果集 -->
|
||||||
<!--
|
<!--
|
||||||
|
|
@ -74,13 +74,13 @@
|
||||||
</root>
|
</root>
|
||||||
|
|
||||||
<!--系统操作日志-->
|
<!--系统操作日志-->
|
||||||
<root level="info">
|
<!--<root level="info">-->
|
||||||
<appender-ref ref="file_info" />
|
<!--<appender-ref ref="file_info" />-->
|
||||||
<appender-ref ref="file_error" />
|
<!--<appender-ref ref="file_error" />-->
|
||||||
</root>
|
<!--</root>-->
|
||||||
|
|
||||||
<!--系统用户操作日志-->
|
<!--系统用户操作日志-->
|
||||||
<logger name="sys-user" level="info">
|
<!--<logger name="sys-user" level="info">-->
|
||||||
<appender-ref ref="sys-user"/>
|
<!--<appender-ref ref="sys-user"/>-->
|
||||||
</logger>
|
<!--</logger>-->
|
||||||
</configuration>
|
</configuration>
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -5507,8 +5507,8 @@ del {
|
||||||
}
|
}
|
||||||
|
|
||||||
20% {
|
20% {
|
||||||
-webkit-transform: scaleY (1);
|
-webkit-transform: scaleY(1);
|
||||||
transform: scaleY (1);
|
transform: scaleY(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5556,18 +5556,18 @@ del {
|
||||||
}
|
}
|
||||||
|
|
||||||
@-webkit-keyframes sk-wanderingCubeMove {
|
@-webkit-keyframes sk-wanderingCubeMove {
|
||||||
25% {
|
25%{
|
||||||
-webkit-transform: translateX(42px) rotate(-90deg) scale(0.5);
|
-webkit-transform: translateX(42px) rotate(-90deg) scale(0.5);
|
||||||
transform: translateX(42px) rotate(-90deg) scale(0.5);
|
transform: translateX(42px) rotate(-90deg) scale(0.5);
|
||||||
}
|
}
|
||||||
|
|
||||||
50% {
|
50%{
|
||||||
/* Hack to make FF rotate in the right direction */
|
/* Hack to make FF rotate in the right direction */
|
||||||
-webkit-transform: translateX(42px) translateY(42px) rotate(-179deg);
|
-webkit-transform: translateX(42px) translateY(42px) rotate(-179deg);
|
||||||
transform: translateX(42px) translateY(42px) rotate(-179deg);
|
transform: translateX(42px) translateY(42px) rotate(-179deg);
|
||||||
}
|
}
|
||||||
|
|
||||||
50 .1 % {
|
50.1% {
|
||||||
-webkit-transform: translateX(42px) translateY(42px) rotate(-180deg);
|
-webkit-transform: translateX(42px) translateY(42px) rotate(-180deg);
|
||||||
transform: translateX(42px) translateY(42px) rotate(-180deg);
|
transform: translateX(42px) translateY(42px) rotate(-180deg);
|
||||||
}
|
}
|
||||||
|
|
@ -6661,7 +6661,7 @@ body.rtls .top-navigation .footer.fixed, body.rtls.top-navigation .footer.fixed
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
*
|
*
|
||||||
* SKIN blue 云企智联管理系统
|
* SKIN blue 云企互联管理系统
|
||||||
* NAME - blue/purple
|
* NAME - blue/purple
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -477,6 +477,10 @@
|
||||||
add: function(id) {
|
add: function(id) {
|
||||||
var url = $.common.isEmpty(id) ? $.table._option.createUrl : $.table._option.createUrl.replace("{id}", id);
|
var url = $.common.isEmpty(id) ? $.table._option.createUrl : $.table._option.createUrl.replace("{id}", id);
|
||||||
$.modal.open("添加" + $.table._option.modalName, url);
|
$.modal.open("添加" + $.table._option.modalName, url);
|
||||||
|
},
|
||||||
|
//跳转自定义
|
||||||
|
jumpModeltoUrl: function(modelName,url) {
|
||||||
|
$.modal.open(modelName, url);
|
||||||
},
|
},
|
||||||
// 修改信息
|
// 修改信息
|
||||||
edit: function(id) {
|
edit: function(id) {
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,125 @@
|
||||||
|
<?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="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" />
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/target" />
|
||||||
|
</content>
|
||||||
|
<orderEntry type="inheritedJdk" />
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
<orderEntry type="module" module-name="ruoyi-framework" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-web:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-json:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jdk8:2.9.6" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.9.6" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.fasterxml.jackson.module:jackson-module-parameter-names:2.9.6" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-tomcat:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-core:8.5.34" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-el:8.5.34" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-websocket:8.5.34" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.hibernate.validator:hibernate-validator:6.0.12.Final" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: javax.validation:validation-api:2.0.1.Final" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.jboss.logging:jboss-logging:3.3.2.Final" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.fasterxml:classmate:1.3.4" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-web:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-webmvc:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-aop:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-aop:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.aspectj:aspectjweaver:1.8.13" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.alibaba:druid-spring-boot-starter:1.1.10" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.alibaba:druid:1.1.10" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-autoconfigure:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.penggle:kaptcha:2.3.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.jhlabs:filters:2.0.235-1" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-thymeleaf:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.thymeleaf:thymeleaf-spring5:3.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.thymeleaf:thymeleaf:3.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.attoparser:attoparser:2.0.4.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.unbescape:unbescape:1.1.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.thymeleaf.extras:thymeleaf-extras-java8time:3.0.1.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-core:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-lang:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-cache:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-hash:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-core:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-cipher:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-config-core:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-config-ogdl:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: commons-beanutils:commons-beanutils:1.9.3" 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.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-spring:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-web:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-ehcache:1.4.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: net.sf.ehcache:ehcache-core:2.6.11" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.theborakompanioni:thymeleaf-extras-shiro:2.0.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: eu.bitwalker:UserAgentUtils:1.19" level="project" />
|
||||||
|
<orderEntry type="module" module-name="ruoyi-common" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.commons:commons-lang3:3.7" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-databind:2.9.6" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.9.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-core:2.9.6" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: commons-io:commons-io:2.5" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: commons-fileupload:commons-fileupload:1.3.3" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.jsoup:jsoup:1.11.3" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.poi:poi-ooxml:3.17" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.poi:poi:3.17" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: commons-codec:commons-codec:1.11" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.commons:commons-collections4:4.1" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.poi:poi-ooxml-schemas:3.17" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.xmlbeans:xmlbeans:2.6.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: stax:stax-api:1.0.1" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.virtuald:curvesapi:1.04" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.yaml:snakeyaml:1.19" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: cn.hutool:hutool-all:4.2.1" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: tk.mybatis:mapper-spring-boot-starter:2.1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: tk.mybatis:mapper-core:1.1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: javax.persistence:persistence-api:1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: tk.mybatis:mapper-base:1.1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: tk.mybatis:mapper-weekend:1.1.4.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: tk.mybatis:mapper-spring:1.1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: tk.mybatis:mapper-extra:1.1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: tk.mybatis:mapper-spring-boot-autoconfigure:2.1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.pagehelper:pagehelper-spring-boot-starter:1.2.5" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.pagehelper:pagehelper-spring-boot-autoconfigure:1.2.5" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.pagehelper:pagehelper:5.1.4" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.jsqlparser:jsqlparser:1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.github.oshi:oshi-core:3.9.1" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: net.java.dev.jna:jna:4.5.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: net.java.dev.jna:jna-platform:4.5.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-context-support:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-beans:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-context:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-expression:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-core:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-jcl:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.mybatis.spring.boot:mybatis-spring-boot-starter:1.3.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-logging:2.0.5.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.10.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.apache.logging.log4j:log4j-api:2.10.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.slf4j:jul-to-slf4j:1.7.25" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: javax.annotation:javax.annotation-api:1.3.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-jdbc:2.0.5.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: com.zaxxer:HikariCP:2.7.9" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-jdbc:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.springframework:spring-tx:5.0.9.RELEASE" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.mybatis.spring.boot:mybatis-spring-boot-autoconfigure:1.3.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.mybatis:mybatis:3.4.6" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.mybatis:mybatis-spring:1.3.2" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: mysql:mysql-connector-java:5.1.47" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: javax.servlet:javax.servlet-api:3.1.0" level="project" />
|
||||||
|
<orderEntry type="library" name="Maven: org.slf4j:slf4j-api:1.7.25" level="project" />
|
||||||
|
</component>
|
||||||
|
</module>
|
||||||
|
|
@ -1,6 +1,11 @@
|
||||||
package com.ruoyi.exam.controller;
|
package com.ruoyi.exam.controller;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Date;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
import com.ruoyi.framework.web.util.ShiroUtils;
|
||||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
|
|
@ -23,13 +28,13 @@ import com.ruoyi.common.utils.ExcelUtil;
|
||||||
* 试题分类 信息操作处理
|
* 试题分类 信息操作处理
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
@Controller
|
@Controller
|
||||||
@RequestMapping("/exam/examQuestionCategory")
|
@RequestMapping("/exam/examQuestionCategory")
|
||||||
public class ExamQuestionCategoryController extends BaseController
|
public class ExamQuestionCategoryController extends BaseController
|
||||||
{
|
{
|
||||||
private String prefix = "exam/examQuestionCategory";
|
private String prefix = "exam/examQuestionCategory";
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private IExamQuestionCategoryService examQuestionCategoryService;
|
private IExamQuestionCategoryService examQuestionCategoryService;
|
||||||
|
|
@ -38,19 +43,22 @@ public class ExamQuestionCategoryController extends BaseController
|
||||||
@GetMapping()
|
@GetMapping()
|
||||||
public String examQuestionCategory()
|
public String examQuestionCategory()
|
||||||
{
|
{
|
||||||
return prefix + "/examQuestionCategory";
|
return prefix + "/examQuestionCategory";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询试题分类列表
|
* 查询试题分类列表
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("exam:examQuestionCategory:list")
|
@RequiresPermissions("exam:examQuestionCategory:list")
|
||||||
@PostMapping("/list")
|
@GetMapping("/list")
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public TableDataInfo list(ExamQuestionCategory examQuestionCategory)
|
public List<ExamQuestionCategory> list(ExamQuestionCategory examQuestionCategory)
|
||||||
{
|
{
|
||||||
List<ExamQuestionCategory> list = examQuestionCategoryService.selectExamQuestionCategoryPage(examQuestionCategory);
|
|
||||||
return getDataTable(list);
|
List<ExamQuestionCategory> list = examQuestionCategoryService.selectExamQuestionCategoryList(examQuestionCategory);
|
||||||
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -58,22 +66,23 @@ public class ExamQuestionCategoryController extends BaseController
|
||||||
* 导出试题分类列表
|
* 导出试题分类列表
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("exam:examQuestionCategory:export")
|
@RequiresPermissions("exam:examQuestionCategory:export")
|
||||||
@PostMapping("/export")
|
@PostMapping("/export")
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult export(ExamQuestionCategory examQuestionCategory)
|
public AjaxResult export(ExamQuestionCategory examQuestionCategory)
|
||||||
{
|
{
|
||||||
List<ExamQuestionCategory> list = examQuestionCategoryService.selectExamQuestionCategoryList(examQuestionCategory);
|
List<ExamQuestionCategory> list = examQuestionCategoryService.selectExamQuestionCategoryList(examQuestionCategory);
|
||||||
ExcelUtil<ExamQuestionCategory> util = new ExcelUtil<ExamQuestionCategory>(ExamQuestionCategory.class);
|
ExcelUtil<ExamQuestionCategory> util = new ExcelUtil<ExamQuestionCategory>(ExamQuestionCategory.class);
|
||||||
return util.exportExcel(list, "examQuestionCategory");
|
return util.exportExcel(list, "examQuestionCategory");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 新增试题分类
|
* 新增试题分类
|
||||||
*/
|
*/
|
||||||
@GetMapping("/add")
|
@GetMapping("/add/{parentId}")
|
||||||
public String add()
|
public String add(@PathVariable("parentId") String parentId, ModelMap mmap)
|
||||||
{
|
{
|
||||||
return prefix + "/add";
|
mmap.put("examQuestionCategory", examQuestionCategoryService.selectExamQuestionCategoryById(parentId));
|
||||||
|
return prefix + "/add";
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -85,7 +94,9 @@ public class ExamQuestionCategoryController extends BaseController
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult addSave(ExamQuestionCategory examQuestionCategory)
|
public AjaxResult addSave(ExamQuestionCategory examQuestionCategory)
|
||||||
{
|
{
|
||||||
return toAjax(examQuestionCategoryService.insert(examQuestionCategory));
|
examQuestionCategory.setCreateBy(ShiroUtils.getLoginName());
|
||||||
|
examQuestionCategory.setCreateDate(new Date());
|
||||||
|
return toAjax(examQuestionCategoryService.insertExamQuestionCategory(examQuestionCategory));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -94,9 +105,9 @@ public class ExamQuestionCategoryController extends BaseController
|
||||||
@GetMapping("/edit/{id}")
|
@GetMapping("/edit/{id}")
|
||||||
public String edit(@PathVariable("id") String id, ModelMap mmap)
|
public String edit(@PathVariable("id") String id, ModelMap mmap)
|
||||||
{
|
{
|
||||||
ExamQuestionCategory examQuestionCategory = examQuestionCategoryService.selectById(id);
|
ExamQuestionCategory examQuestionCategory = examQuestionCategoryService.selectExamQuestionCategoryById(id);
|
||||||
mmap.put("examQuestionCategory", examQuestionCategory);
|
mmap.put("examQuestionCategory", examQuestionCategory);
|
||||||
return prefix + "/edit";
|
return prefix + "/edit";
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -108,7 +119,7 @@ public class ExamQuestionCategoryController extends BaseController
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult editSave(ExamQuestionCategory examQuestionCategory)
|
public AjaxResult editSave(ExamQuestionCategory examQuestionCategory)
|
||||||
{
|
{
|
||||||
return toAjax(examQuestionCategoryService.updateById(examQuestionCategory));
|
return toAjax(examQuestionCategoryService.updateExamQuestionCategory(examQuestionCategory));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -120,7 +131,51 @@ public class ExamQuestionCategoryController extends BaseController
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult remove(String ids)
|
public AjaxResult remove(String ids)
|
||||||
{
|
{
|
||||||
return toAjax(examQuestionCategoryService.deleteByIds(ids));
|
return toAjax(examQuestionCategoryService.deleteExamQuestionCategoryByIds(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 选择部门树
|
||||||
|
*/
|
||||||
|
@GetMapping("/selectExamQuestionCategoryTree/{examQuestionCategoryId}")
|
||||||
|
public String selectDeptTree(@PathVariable("examQuestionCategoryId") String examQuestionCategoryId, ModelMap mmap)
|
||||||
|
{
|
||||||
|
mmap.put("examQuestionCategory", examQuestionCategoryService.selectExamQuestionCategoryById(examQuestionCategoryId));
|
||||||
|
return prefix + "/tree";
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 加载列表树
|
||||||
|
*/
|
||||||
|
@GetMapping("/treeData")
|
||||||
|
@ResponseBody
|
||||||
|
public List<Map<String, Object>> treeData()
|
||||||
|
{
|
||||||
|
List<Map<String, Object>> tree = examQuestionCategoryService.selectDeptTree();
|
||||||
|
return tree;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 选择部门树
|
||||||
|
*/
|
||||||
|
@GetMapping("/treeDataForAdd")
|
||||||
|
@ResponseBody
|
||||||
|
public List<Map<String, Object>> treeDataForAdd()
|
||||||
|
{
|
||||||
|
List<Map<String, Object>> tree = examQuestionCategoryService.selectDeptTree();
|
||||||
|
List<Map<String, Object>> res = new ArrayList<>();
|
||||||
|
for (Map<String, Object> stringObjectMap : tree) {
|
||||||
|
String pId = stringObjectMap.get("pId").toString();
|
||||||
|
if(pId.equals("0")||pId.equals("1")){
|
||||||
|
res.add(stringObjectMap);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,15 +1,12 @@
|
||||||
package com.ruoyi.exam.controller;
|
package com.ruoyi.exam.controller;
|
||||||
|
|
||||||
|
import java.util.Enumeration;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.ui.ModelMap;
|
import org.springframework.ui.ModelMap;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.*;
|
||||||
import org.springframework.web.bind.annotation.PathVariable;
|
|
||||||
import org.springframework.web.bind.annotation.PostMapping;
|
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
|
||||||
import org.springframework.web.bind.annotation.ResponseBody;
|
|
||||||
import com.ruoyi.common.annotation.Log;
|
import com.ruoyi.common.annotation.Log;
|
||||||
import com.ruoyi.common.enums.BusinessType;
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
import com.ruoyi.exam.domain.ExamQuestion;
|
import com.ruoyi.exam.domain.ExamQuestion;
|
||||||
|
|
@ -19,11 +16,12 @@ import com.ruoyi.framework.web.page.TableDataInfo;
|
||||||
import com.ruoyi.common.base.AjaxResult;
|
import com.ruoyi.common.base.AjaxResult;
|
||||||
import com.ruoyi.common.utils.ExcelUtil;
|
import com.ruoyi.common.utils.ExcelUtil;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 问题 信息操作处理
|
* 问题 信息操作处理
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
@Controller
|
@Controller
|
||||||
@RequestMapping("/exam/examQuestion")
|
@RequestMapping("/exam/examQuestion")
|
||||||
|
|
@ -41,6 +39,14 @@ public class ExamQuestionController extends BaseController
|
||||||
return prefix + "/examQuestion";
|
return prefix + "/examQuestion";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping("/choiceadd/{id}")
|
||||||
|
public String addChoiceUrl(@PathVariable("id") String id, ModelMap mmap)
|
||||||
|
{
|
||||||
|
mmap.put("categoryId",id);
|
||||||
|
mmap.put("type",1);
|
||||||
|
return prefix + "/choiceadd";
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询问题列表
|
* 查询问题列表
|
||||||
*/
|
*/
|
||||||
|
|
@ -49,7 +55,7 @@ public class ExamQuestionController extends BaseController
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public TableDataInfo list(ExamQuestion examQuestion)
|
public TableDataInfo list(ExamQuestion examQuestion)
|
||||||
{
|
{
|
||||||
List<ExamQuestion> list = examQuestionService.selectExamQuestionPage(examQuestion);
|
List<ExamQuestion> list = examQuestionService.selectExamQuestionList(examQuestion);
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -83,9 +89,11 @@ public class ExamQuestionController extends BaseController
|
||||||
@Log(title = "问题", businessType = BusinessType.INSERT)
|
@Log(title = "问题", businessType = BusinessType.INSERT)
|
||||||
@PostMapping("/add")
|
@PostMapping("/add")
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult addSave(ExamQuestion examQuestion)
|
public AjaxResult addSave(ExamQuestion examQuestion,@RequestParam(value = "number", required = true) String[] number,
|
||||||
|
@RequestParam(value = "content", required = true) String[] content)
|
||||||
{
|
{
|
||||||
return toAjax(examQuestionService.insert(examQuestion));
|
|
||||||
|
return toAjax(examQuestionService.insertQuestion(examQuestion,number,content));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -94,7 +102,7 @@ public class ExamQuestionController extends BaseController
|
||||||
@GetMapping("/edit/{id}")
|
@GetMapping("/edit/{id}")
|
||||||
public String edit(@PathVariable("id") String id, ModelMap mmap)
|
public String edit(@PathVariable("id") String id, ModelMap mmap)
|
||||||
{
|
{
|
||||||
ExamQuestion examQuestion = examQuestionService.selectById(id);
|
ExamQuestion examQuestion = examQuestionService.selectExamQuestionById(id);
|
||||||
mmap.put("examQuestion", examQuestion);
|
mmap.put("examQuestion", examQuestion);
|
||||||
return prefix + "/edit";
|
return prefix + "/edit";
|
||||||
}
|
}
|
||||||
|
|
@ -108,7 +116,7 @@ public class ExamQuestionController extends BaseController
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult editSave(ExamQuestion examQuestion)
|
public AjaxResult editSave(ExamQuestion examQuestion)
|
||||||
{
|
{
|
||||||
return toAjax(examQuestionService.updateById(examQuestion));
|
return toAjax(examQuestionService.updateExamQuestion(examQuestion));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -120,7 +128,7 @@ public class ExamQuestionController extends BaseController
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult remove(String ids)
|
public AjaxResult remove(String ids)
|
||||||
{
|
{
|
||||||
return toAjax(examQuestionService.deleteByIds(ids));
|
return toAjax(examQuestionService.deleteExamQuestionByIds(ids));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ package com.ruoyi.exam.domain;
|
||||||
|
|
||||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.base.BaseEntity;
|
||||||
|
|
||||||
import javax.persistence.Id;
|
import javax.persistence.Id;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
|
@ -10,149 +11,130 @@ import java.util.Date;
|
||||||
* 试题分类表 exam_question_category
|
* 试题分类表 exam_question_category
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
public class ExamQuestionCategory
|
public class ExamQuestionCategory
|
||||||
{
|
{
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
/** */
|
/** */
|
||||||
@Id
|
@Id
|
||||||
private String id;
|
private Long id;
|
||||||
/** 分类 */
|
/** 分类 */
|
||||||
|
|
||||||
private String name;
|
private String name;
|
||||||
/** */
|
/** */
|
||||||
|
private Long parentId;
|
||||||
private String parentId;
|
|
||||||
/** */
|
/** */
|
||||||
|
|
||||||
private String parentIds;
|
private String parentIds;
|
||||||
/** 创建者 */
|
/** 创建者 */
|
||||||
|
|
||||||
private String createBy;
|
private String createBy;
|
||||||
/** 创建时间 */
|
/** 创建时间 */
|
||||||
|
|
||||||
private Date createDate;
|
private Date createDate;
|
||||||
/** 更新者 */
|
/** 更新者 */
|
||||||
|
|
||||||
private String updateBy;
|
private String updateBy;
|
||||||
/** 更新时间 */
|
/** 更新时间 */
|
||||||
|
|
||||||
private Date updateDate;
|
private Date updateDate;
|
||||||
/** 备注信息 */
|
/** 备注信息 */
|
||||||
|
|
||||||
private String remarks;
|
private String remarks;
|
||||||
/** 删除标记 */
|
/** 删除标记 */
|
||||||
|
|
||||||
private String delFlag;
|
private String delFlag;
|
||||||
|
|
||||||
/** 设置 */
|
private String orderNum;
|
||||||
public void setId(String id)
|
|
||||||
|
public String getOrderNum() {
|
||||||
|
return orderNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setOrderNum(String orderNum) {
|
||||||
|
this.orderNum = orderNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
this.id = id;
|
this.id = id;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取 */
|
public Long getId()
|
||||||
public String getId()
|
|
||||||
{
|
{
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
/** 设置分类 */
|
|
||||||
public void setName(String name)
|
public void setName(String name)
|
||||||
{
|
{
|
||||||
this.name = name;
|
this.name = name;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取分类 */
|
|
||||||
public String getName()
|
public String getName()
|
||||||
{
|
{
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
/** 设置 */
|
public void setParentId(Long parentId)
|
||||||
public void setParentId(String parentId)
|
|
||||||
{
|
{
|
||||||
this.parentId = parentId;
|
this.parentId = parentId;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取 */
|
public Long getParentId()
|
||||||
public String getParentId()
|
|
||||||
{
|
{
|
||||||
return parentId;
|
return parentId;
|
||||||
}
|
}
|
||||||
/** 设置 */
|
|
||||||
public void setParentIds(String parentIds)
|
public void setParentIds(String parentIds)
|
||||||
{
|
{
|
||||||
this.parentIds = parentIds;
|
this.parentIds = parentIds;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取 */
|
|
||||||
public String getParentIds()
|
public String getParentIds()
|
||||||
{
|
{
|
||||||
return parentIds;
|
return parentIds;
|
||||||
}
|
}
|
||||||
/** 设置创建者 */
|
|
||||||
public void setCreateBy(String createBy)
|
public void setCreateBy(String createBy)
|
||||||
{
|
{
|
||||||
this.createBy = createBy;
|
this.createBy = createBy;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取创建者 */
|
|
||||||
public String getCreateBy()
|
public String getCreateBy()
|
||||||
{
|
{
|
||||||
return createBy;
|
return createBy;
|
||||||
}
|
}
|
||||||
/** 设置创建时间 */
|
|
||||||
public void setCreateDate(Date createDate)
|
public void setCreateDate(Date createDate)
|
||||||
{
|
{
|
||||||
this.createDate = createDate;
|
this.createDate = createDate;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取创建时间 */
|
|
||||||
public Date getCreateDate()
|
public Date getCreateDate()
|
||||||
{
|
{
|
||||||
return createDate;
|
return createDate;
|
||||||
}
|
}
|
||||||
/** 设置更新者 */
|
|
||||||
public void setUpdateBy(String updateBy)
|
public void setUpdateBy(String updateBy)
|
||||||
{
|
{
|
||||||
this.updateBy = updateBy;
|
this.updateBy = updateBy;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取更新者 */
|
|
||||||
public String getUpdateBy()
|
public String getUpdateBy()
|
||||||
{
|
{
|
||||||
return updateBy;
|
return updateBy;
|
||||||
}
|
}
|
||||||
/** 设置更新时间 */
|
|
||||||
public void setUpdateDate(Date updateDate)
|
public void setUpdateDate(Date updateDate)
|
||||||
{
|
{
|
||||||
this.updateDate = updateDate;
|
this.updateDate = updateDate;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取更新时间 */
|
|
||||||
public Date getUpdateDate()
|
public Date getUpdateDate()
|
||||||
{
|
{
|
||||||
return updateDate;
|
return updateDate;
|
||||||
}
|
}
|
||||||
/** 设置备注信息 */
|
|
||||||
public void setRemarks(String remarks)
|
public void setRemarks(String remarks)
|
||||||
{
|
{
|
||||||
this.remarks = remarks;
|
this.remarks = remarks;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取备注信息 */
|
|
||||||
public String getRemarks()
|
public String getRemarks()
|
||||||
{
|
{
|
||||||
return remarks;
|
return remarks;
|
||||||
}
|
}
|
||||||
/** 设置删除标记 */
|
|
||||||
public void setDelFlag(String delFlag)
|
public void setDelFlag(String delFlag)
|
||||||
{
|
{
|
||||||
this.delFlag = delFlag;
|
this.delFlag = delFlag;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 获取删除标记 */
|
|
||||||
public String getDelFlag()
|
public String getDelFlag()
|
||||||
{
|
{
|
||||||
return delFlag;
|
return delFlag;
|
||||||
|
|
|
||||||
|
|
@ -8,10 +8,17 @@ import com.ruoyi.framework.web.base.MyMapper;
|
||||||
* 试题分类 数据层
|
* 试题分类 数据层
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
public interface ExamQuestionCategoryMapper extends MyMapper<ExamQuestionCategory>
|
public interface ExamQuestionCategoryMapper extends MyMapper<ExamQuestionCategory>
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* 查询试题分类信息
|
||||||
|
*
|
||||||
|
* @param id 试题分类ID
|
||||||
|
* @return 试题分类信息
|
||||||
|
*/
|
||||||
|
public ExamQuestionCategory selectExamQuestionCategoryById(String id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询试题分类列表
|
* 查询试题分类列表
|
||||||
|
|
@ -21,4 +28,36 @@ public interface ExamQuestionCategoryMapper extends MyMapper<ExamQuestionCatego
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestionCategory> selectExamQuestionCategoryList(ExamQuestionCategory examQuestionCategory);
|
public List<ExamQuestionCategory> selectExamQuestionCategoryList(ExamQuestionCategory examQuestionCategory);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增试题分类
|
||||||
|
*
|
||||||
|
* @param examQuestionCategory 试题分类信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertExamQuestionCategory(ExamQuestionCategory examQuestionCategory);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改试题分类
|
||||||
|
*
|
||||||
|
* @param examQuestionCategory 试题分类信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateExamQuestionCategory(ExamQuestionCategory examQuestionCategory);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除试题分类
|
||||||
|
*
|
||||||
|
* @param id 试题分类ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionCategoryById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除试题分类
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionCategoryByIds(String[] ids);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -8,10 +8,17 @@ import com.ruoyi.framework.web.base.MyMapper;
|
||||||
* 问题点评 数据层
|
* 问题点评 数据层
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
public interface ExamQuestionCommentMapper extends MyMapper<ExamQuestionComment>
|
public interface ExamQuestionCommentMapper extends MyMapper<ExamQuestionComment>
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* 查询问题点评信息
|
||||||
|
*
|
||||||
|
* @param id 问题点评ID
|
||||||
|
* @return 问题点评信息
|
||||||
|
*/
|
||||||
|
public ExamQuestionComment selectExamQuestionCommentById(String id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询问题点评列表
|
* 查询问题点评列表
|
||||||
|
|
@ -21,4 +28,36 @@ public interface ExamQuestionCommentMapper extends MyMapper<ExamQuestionComment
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestionComment> selectExamQuestionCommentList(ExamQuestionComment examQuestionComment);
|
public List<ExamQuestionComment> selectExamQuestionCommentList(ExamQuestionComment examQuestionComment);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增问题点评
|
||||||
|
*
|
||||||
|
* @param examQuestionComment 问题点评信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertExamQuestionComment(ExamQuestionComment examQuestionComment);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改问题点评
|
||||||
|
*
|
||||||
|
* @param examQuestionComment 问题点评信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateExamQuestionComment(ExamQuestionComment examQuestionComment);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除问题点评
|
||||||
|
*
|
||||||
|
* @param id 问题点评ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionCommentById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除问题点评
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionCommentByIds(String[] ids);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -8,10 +8,17 @@ import com.ruoyi.framework.web.base.MyMapper;
|
||||||
* 问题选项 数据层
|
* 问题选项 数据层
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
public interface ExamQuestionItemMapper extends MyMapper<ExamQuestionItem>
|
public interface ExamQuestionItemMapper extends MyMapper<ExamQuestionItem>
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* 查询问题选项信息
|
||||||
|
*
|
||||||
|
* @param id 问题选项ID
|
||||||
|
* @return 问题选项信息
|
||||||
|
*/
|
||||||
|
public ExamQuestionItem selectExamQuestionItemById(String id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询问题选项列表
|
* 查询问题选项列表
|
||||||
|
|
@ -21,4 +28,36 @@ public interface ExamQuestionItemMapper extends MyMapper<ExamQuestionItem>
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestionItem> selectExamQuestionItemList(ExamQuestionItem examQuestionItem);
|
public List<ExamQuestionItem> selectExamQuestionItemList(ExamQuestionItem examQuestionItem);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增问题选项
|
||||||
|
*
|
||||||
|
* @param examQuestionItem 问题选项信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertExamQuestionItem(ExamQuestionItem examQuestionItem);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改问题选项
|
||||||
|
*
|
||||||
|
* @param examQuestionItem 问题选项信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateExamQuestionItem(ExamQuestionItem examQuestionItem);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除问题选项
|
||||||
|
*
|
||||||
|
* @param id 问题选项ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionItemById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除问题选项
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionItemByIds(String[] ids);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -8,10 +8,17 @@ import com.ruoyi.framework.web.base.MyMapper;
|
||||||
* 问题 数据层
|
* 问题 数据层
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
public interface ExamQuestionMapper extends MyMapper<ExamQuestion>
|
public interface ExamQuestionMapper extends MyMapper<ExamQuestion>
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* 查询问题信息
|
||||||
|
*
|
||||||
|
* @param id 问题ID
|
||||||
|
* @return 问题信息
|
||||||
|
*/
|
||||||
|
public ExamQuestion selectExamQuestionById(String id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询问题列表
|
* 查询问题列表
|
||||||
|
|
@ -21,4 +28,36 @@ public interface ExamQuestionMapper extends MyMapper<ExamQuestion>
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestion> selectExamQuestionList(ExamQuestion examQuestion);
|
public List<ExamQuestion> selectExamQuestionList(ExamQuestion examQuestion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增问题
|
||||||
|
*
|
||||||
|
* @param examQuestion 问题信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertExamQuestion(ExamQuestion examQuestion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改问题
|
||||||
|
*
|
||||||
|
* @param examQuestion 问题信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateExamQuestion(ExamQuestion examQuestion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除问题
|
||||||
|
*
|
||||||
|
* @param id 问题ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionById(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除问题
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionByIds(String[] ids);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -2,29 +2,56 @@ package com.ruoyi.exam.service;
|
||||||
|
|
||||||
import com.ruoyi.exam.domain.ExamQuestionCategory;
|
import com.ruoyi.exam.domain.ExamQuestionCategory;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
import com.ruoyi.framework.web.base.AbstractBaseService;
|
import com.ruoyi.framework.web.base.AbstractBaseService;
|
||||||
/**
|
/**
|
||||||
* 试题分类 服务层
|
* 试题分类 服务层
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
public interface IExamQuestionCategoryService extends AbstractBaseService<ExamQuestionCategory>
|
public interface IExamQuestionCategoryService extends AbstractBaseService<ExamQuestionCategory>
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* 查询试题分类分页列表
|
* 查询试题分类信息
|
||||||
*
|
*
|
||||||
* @param examQuestionCategory 试题分类信息
|
* @param id 试题分类ID
|
||||||
* @return 试题分类集合
|
* @return 试题分类信息
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestionCategory> selectExamQuestionCategoryPage(ExamQuestionCategory examQuestionCategory);
|
public ExamQuestionCategory selectExamQuestionCategoryById(String id);
|
||||||
/**
|
|
||||||
|
/**
|
||||||
* 查询试题分类列表
|
* 查询试题分类列表
|
||||||
*
|
*
|
||||||
* @param examQuestionCategory 试题分类信息
|
* @param examQuestionCategory 试题分类信息
|
||||||
* @return 试题分类集合
|
* @return 试题分类集合
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestionCategory> selectExamQuestionCategoryList(ExamQuestionCategory examQuestionCategory);
|
public List<ExamQuestionCategory> selectExamQuestionCategoryList(ExamQuestionCategory examQuestionCategory);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增试题分类
|
||||||
|
*
|
||||||
|
* @param examQuestionCategory 试题分类信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertExamQuestionCategory(ExamQuestionCategory examQuestionCategory);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改试题分类
|
||||||
|
*
|
||||||
|
* @param examQuestionCategory 试题分类信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateExamQuestionCategory(ExamQuestionCategory examQuestionCategory);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除试题分类信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionCategoryByIds(String ids);
|
||||||
|
|
||||||
|
List<Map<String,Object>> selectDeptTree();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,24 +7,49 @@ import com.ruoyi.framework.web.base.AbstractBaseService;
|
||||||
* 问题 服务层
|
* 问题 服务层
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
public interface IExamQuestionService extends AbstractBaseService<ExamQuestion>
|
public interface IExamQuestionService extends AbstractBaseService<ExamQuestion>
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* 查询问题分页列表
|
* 查询问题信息
|
||||||
*
|
*
|
||||||
* @param examQuestion 问题信息
|
* @param id 问题ID
|
||||||
* @return 问题集合
|
* @return 问题信息
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestion> selectExamQuestionPage(ExamQuestion examQuestion);
|
public ExamQuestion selectExamQuestionById(String id);
|
||||||
/**
|
|
||||||
|
/**
|
||||||
* 查询问题列表
|
* 查询问题列表
|
||||||
*
|
*
|
||||||
* @param examQuestion 问题信息
|
* @param examQuestion 问题信息
|
||||||
* @return 问题集合
|
* @return 问题集合
|
||||||
*/
|
*/
|
||||||
public List<ExamQuestion> selectExamQuestionList(ExamQuestion examQuestion);
|
public List<ExamQuestion> selectExamQuestionList(ExamQuestion examQuestion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增问题
|
||||||
|
*
|
||||||
|
* @param examQuestion 问题信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertExamQuestion(ExamQuestion examQuestion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改问题
|
||||||
|
*
|
||||||
|
* @param examQuestion 问题信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateExamQuestion(ExamQuestion examQuestion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除问题信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteExamQuestionByIds(String ids);
|
||||||
|
|
||||||
|
int insertQuestion(ExamQuestion examQuestion, String[] number, String[] content);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,12 @@
|
||||||
package com.ruoyi.exam.service.impl;
|
package com.ruoyi.exam.service.impl;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
import com.ruoyi.common.constant.UserConstants;
|
||||||
|
import com.ruoyi.system.domain.SysDept;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import com.ruoyi.exam.mapper.ExamQuestionCategoryMapper;
|
import com.ruoyi.exam.mapper.ExamQuestionCategoryMapper;
|
||||||
|
|
@ -8,41 +14,99 @@ import com.ruoyi.exam.domain.ExamQuestionCategory;
|
||||||
import com.ruoyi.exam.service.IExamQuestionCategoryService;
|
import com.ruoyi.exam.service.IExamQuestionCategoryService;
|
||||||
import com.ruoyi.common.support.Convert;
|
import com.ruoyi.common.support.Convert;
|
||||||
import com.ruoyi.framework.web.base.AbstractBaseServiceImpl;
|
import com.ruoyi.framework.web.base.AbstractBaseServiceImpl;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 试题分类 服务层实现
|
* 试题分类 服务层实现
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
public class ExamQuestionCategoryServiceImpl extends AbstractBaseServiceImpl<ExamQuestionCategoryMapper,ExamQuestionCategory> implements IExamQuestionCategoryService
|
public class ExamQuestionCategoryServiceImpl extends AbstractBaseServiceImpl<ExamQuestionCategoryMapper, ExamQuestionCategory> implements IExamQuestionCategoryService {
|
||||||
{
|
@Autowired
|
||||||
@Autowired
|
private ExamQuestionCategoryMapper examQuestionCategoryMapper;
|
||||||
private ExamQuestionCategoryMapper examQuestionCategoryMapper;
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询试题分类信息
|
||||||
|
*
|
||||||
|
* @param id 试题分类ID
|
||||||
|
* @return 试题分类信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public ExamQuestionCategory selectExamQuestionCategoryById(String id) {
|
||||||
|
return examQuestionCategoryMapper.selectExamQuestionCategoryById(id);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询试题分类列表
|
* 查询试题分类列表
|
||||||
*
|
*
|
||||||
* @param examQuestionCategory 试题分类信息
|
* @param examQuestionCategory 试题分类信息
|
||||||
* @return 试题分类集合
|
* @return 试题分类集合
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
public List<ExamQuestionCategory> selectExamQuestionCategoryList(ExamQuestionCategory examQuestionCategory)
|
|
||||||
{
|
|
||||||
return examQuestionCategoryMapper.selectExamQuestionCategoryList(examQuestionCategory);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* 查询试题分类分页列表
|
|
||||||
*
|
|
||||||
* @param examQuestionCategory 试题分类信息
|
|
||||||
* @return 试题分类集合
|
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<ExamQuestionCategory> selectExamQuestionCategoryPage(ExamQuestionCategory examQuestionCategory)
|
public List<ExamQuestionCategory> selectExamQuestionCategoryList(ExamQuestionCategory examQuestionCategory) {
|
||||||
{
|
|
||||||
startPage();
|
startPage();
|
||||||
return examQuestionCategoryMapper.selectExamQuestionCategoryList(examQuestionCategory);
|
return examQuestionCategoryMapper.selectExamQuestionCategoryList(examQuestionCategory);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增试题分类
|
||||||
|
*
|
||||||
|
* @param examQuestionCategory 试题分类信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertExamQuestionCategory(ExamQuestionCategory examQuestionCategory) {
|
||||||
|
return examQuestionCategoryMapper.insertExamQuestionCategory(examQuestionCategory);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改试题分类
|
||||||
|
*
|
||||||
|
* @param examQuestionCategory 试题分类信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateExamQuestionCategory(ExamQuestionCategory examQuestionCategory) {
|
||||||
|
return examQuestionCategoryMapper.updateExamQuestionCategory(examQuestionCategory);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除试题分类对象
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteExamQuestionCategoryByIds(String ids) {
|
||||||
|
return examQuestionCategoryMapper.deleteExamQuestionCategoryByIds(Convert.toStrArray(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Map<String, Object>> selectDeptTree() {
|
||||||
|
List<Map<String, Object>> trees = new ArrayList<Map<String, Object>>();
|
||||||
|
List<ExamQuestionCategory> deptList = selectExamQuestionCategoryList(new ExamQuestionCategory());
|
||||||
|
trees = getTrees(deptList, false, null);
|
||||||
|
return trees;
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<Map<String, Object>> getTrees(List<ExamQuestionCategory> deptList, boolean isCheck, List<String> roleDeptList) {
|
||||||
|
List<Map<String, Object>> trees = new ArrayList<Map<String, Object>>();
|
||||||
|
for (ExamQuestionCategory dept : deptList) {
|
||||||
|
|
||||||
|
Map<String, Object> deptMap = new HashMap<String, Object>();
|
||||||
|
deptMap.put("id", dept.getId());
|
||||||
|
deptMap.put("pId", dept.getParentId());
|
||||||
|
deptMap.put("name", dept.getName());
|
||||||
|
deptMap.put("title", dept.getName());
|
||||||
|
if (isCheck) {
|
||||||
|
deptMap.put("checked", roleDeptList.contains(dept.getId() + dept.getName()));
|
||||||
|
} else {
|
||||||
|
deptMap.put("checked", false);
|
||||||
|
}
|
||||||
|
trees.add(deptMap);
|
||||||
|
}
|
||||||
|
return trees;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,12 @@
|
||||||
package com.ruoyi.exam.service.impl;
|
package com.ruoyi.exam.service.impl;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.Date;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.exam.domain.ExamQuestionItem;
|
||||||
|
import com.ruoyi.exam.mapper.ExamQuestionItemMapper;
|
||||||
|
import com.ruoyi.framework.web.util.ShiroUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import com.ruoyi.exam.mapper.ExamQuestionMapper;
|
import com.ruoyi.exam.mapper.ExamQuestionMapper;
|
||||||
|
|
@ -12,7 +18,7 @@ import com.ruoyi.framework.web.base.AbstractBaseServiceImpl;
|
||||||
* 问题 服务层实现
|
* 问题 服务层实现
|
||||||
*
|
*
|
||||||
* @author zhujj
|
* @author zhujj
|
||||||
* @date 2018-12-07
|
* @date 2018-12-06
|
||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
public class ExamQuestionServiceImpl extends AbstractBaseServiceImpl<ExamQuestionMapper,ExamQuestion> implements IExamQuestionService
|
public class ExamQuestionServiceImpl extends AbstractBaseServiceImpl<ExamQuestionMapper,ExamQuestion> implements IExamQuestionService
|
||||||
|
|
@ -20,29 +26,91 @@ public class ExamQuestionServiceImpl extends AbstractBaseServiceImpl<ExamQuestio
|
||||||
@Autowired
|
@Autowired
|
||||||
private ExamQuestionMapper examQuestionMapper;
|
private ExamQuestionMapper examQuestionMapper;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private ExamQuestionItemMapper examQuestionItemMapper;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询问题列表
|
* 查询问题信息
|
||||||
*
|
*
|
||||||
* @param examQuestion 问题信息
|
* @param id 问题ID
|
||||||
* @return 问题集合
|
* @return 问题信息
|
||||||
*/
|
*/
|
||||||
|
@Override
|
||||||
|
public ExamQuestion selectExamQuestionById(String id)
|
||||||
|
{
|
||||||
|
return examQuestionMapper.selectExamQuestionById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询问题列表
|
||||||
|
*
|
||||||
|
* @param examQuestion 问题信息
|
||||||
|
* @return 问题集合
|
||||||
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<ExamQuestion> selectExamQuestionList(ExamQuestion examQuestion)
|
public List<ExamQuestion> selectExamQuestionList(ExamQuestion examQuestion)
|
||||||
{
|
{
|
||||||
return examQuestionMapper.selectExamQuestionList(examQuestion);
|
startPage();
|
||||||
|
return examQuestionMapper.selectExamQuestionList(examQuestion);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增问题
|
||||||
|
*
|
||||||
|
* @param examQuestion 问题信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertExamQuestion(ExamQuestion examQuestion)
|
||||||
|
{
|
||||||
|
return examQuestionMapper.insertExamQuestion(examQuestion);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改问题
|
||||||
|
*
|
||||||
|
* @param examQuestion 问题信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateExamQuestion(ExamQuestion examQuestion)
|
||||||
|
{
|
||||||
|
return examQuestionMapper.updateExamQuestion(examQuestion);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除问题对象
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteExamQuestionByIds(String ids)
|
||||||
|
{
|
||||||
|
return examQuestionMapper.deleteExamQuestionByIds(Convert.toStrArray(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int insertQuestion(ExamQuestion examQuestion, String[] number, String[] content) {
|
||||||
|
Date date = new Date();
|
||||||
|
examQuestion.setCreateDate(date);
|
||||||
|
examQuestion.setCreateBy(ShiroUtils.getLoginName());
|
||||||
|
int i = examQuestionMapper.insertExamQuestion(examQuestion);
|
||||||
|
examQuestion.setCreateDate(null);
|
||||||
|
List<ExamQuestion> select = examQuestionMapper.selectExamQuestionList(examQuestion);
|
||||||
|
ExamQuestionItem examQuestionItem = new ExamQuestionItem();
|
||||||
|
for (int i1 = 0; i1 < number.length; i1++) {examQuestionItem.setContent(content[i1]);
|
||||||
|
examQuestionItem.setNumber(number[i1]);
|
||||||
|
examQuestionItem.setExamQuestionId(select.get(0).getId()+"");
|
||||||
|
examQuestionItem.setCreateDate(date);
|
||||||
|
examQuestionItem.setCreateBy(ShiroUtils.getLoginName());
|
||||||
|
examQuestionItemMapper.insertExamQuestionItem(examQuestionItem);
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
return i ;
|
||||||
}
|
}
|
||||||
/**
|
|
||||||
* 查询问题分页列表
|
|
||||||
*
|
|
||||||
* @param examQuestion 问题信息
|
|
||||||
* @return 问题集合
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
public List<ExamQuestion> selectExamQuestionPage(ExamQuestion examQuestion)
|
|
||||||
{
|
|
||||||
startPage();
|
|
||||||
return examQuestionMapper.selectExamQuestionList(examQuestion);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -15,15 +15,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<result property="updateDate" column="update_date" />
|
<result property="updateDate" column="update_date" />
|
||||||
<result property="remarks" column="remarks" />
|
<result property="remarks" column="remarks" />
|
||||||
<result property="delFlag" column="del_flag" />
|
<result property="delFlag" column="del_flag" />
|
||||||
|
<result property="orderNum" column="order_num" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectExamQuestionCategoryVo">
|
<sql id="selectExamQuestionCategoryVo">
|
||||||
id, name, parent_id, parent_ids, create_by, create_date, update_by, update_date, remarks, del_flag </sql>
|
select id, name, parent_id, parent_ids, create_by, create_date, update_by, update_date, remarks, del_flag,order_num from exam_question_category
|
||||||
|
</sql>
|
||||||
|
|
||||||
<select id="selectExamQuestionCategoryList" parameterType="ExamQuestionCategory" resultMap="ExamQuestionCategoryResult">
|
<select id="selectExamQuestionCategoryList" parameterType="ExamQuestionCategory" resultMap="ExamQuestionCategoryResult">
|
||||||
select
|
|
||||||
<include refid="selectExamQuestionCategoryVo"/>
|
<include refid="selectExamQuestionCategoryVo"/>
|
||||||
from exam_question_category
|
|
||||||
<where>
|
<where>
|
||||||
<if test="id != null and id != '' "> and id = #{id}</if>
|
<if test="id != null and id != '' "> and id = #{id}</if>
|
||||||
<if test="name != null and name != '' "> and name = #{name}</if>
|
<if test="name != null and name != '' "> and name = #{name}</if>
|
||||||
|
|
@ -38,5 +38,64 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="selectExamQuestionCategoryById" parameterType="String" resultMap="ExamQuestionCategoryResult">
|
||||||
|
<include refid="selectExamQuestionCategoryVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertExamQuestionCategory" parameterType="ExamQuestionCategory">
|
||||||
|
insert into exam_question_category
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null and id != '' ">id,</if>
|
||||||
|
<if test="name != null and name != '' ">name,</if>
|
||||||
|
<if test="parentId != null and parentId != '' ">parent_id,</if>
|
||||||
|
<if test="parentIds != null and parentIds != '' ">parent_ids,</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">create_by,</if>
|
||||||
|
<if test="createDate != null ">create_date,</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">update_by,</if>
|
||||||
|
<if test="updateDate != null ">update_date,</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">remarks,</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">del_flag,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null and id != '' ">#{id},</if>
|
||||||
|
<if test="name != null and name != '' ">#{name},</if>
|
||||||
|
<if test="parentId != null and parentId != '' ">#{parentId},</if>
|
||||||
|
<if test="parentIds != null and parentIds != '' ">#{parentIds},</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">#{createBy},</if>
|
||||||
|
<if test="createDate != null ">#{createDate},</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">#{updateBy},</if>
|
||||||
|
<if test="updateDate != null ">#{updateDate},</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">#{remarks},</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">#{delFlag},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateExamQuestionCategory" parameterType="ExamQuestionCategory">
|
||||||
|
update exam_question_category
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="name != null and name != '' ">name = #{name},</if>
|
||||||
|
<if test="parentId != null and parentId != '' ">parent_id = #{parentId},</if>
|
||||||
|
<if test="parentIds != null and parentIds != '' ">parent_ids = #{parentIds},</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">create_by = #{createBy},</if>
|
||||||
|
<if test="createDate != null ">create_date = #{createDate},</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateDate != null ">update_date = #{updateDate},</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">remarks = #{remarks},</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">del_flag = #{delFlag},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteExamQuestionCategoryById" parameterType="String">
|
||||||
|
delete from exam_question_category where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteExamQuestionCategoryByIds" parameterType="String">
|
||||||
|
delete from exam_question_category where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
@ -18,12 +18,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectExamQuestionItemVo">
|
<sql id="selectExamQuestionItemVo">
|
||||||
id, content, number, exam_question_id, create_by, create_date, update_by, update_date, remarks, del_flag </sql>
|
select id, content, number, exam_question_id, create_by, create_date, update_by, update_date, remarks, del_flag from exam_question_item
|
||||||
|
</sql>
|
||||||
|
|
||||||
<select id="selectExamQuestionItemList" parameterType="ExamQuestionItem" resultMap="ExamQuestionItemResult">
|
<select id="selectExamQuestionItemList" parameterType="ExamQuestionItem" resultMap="ExamQuestionItemResult">
|
||||||
select
|
|
||||||
<include refid="selectExamQuestionItemVo"/>
|
<include refid="selectExamQuestionItemVo"/>
|
||||||
from exam_question_item
|
|
||||||
<where>
|
<where>
|
||||||
<if test="id != null and id != '' "> and id = #{id}</if>
|
<if test="id != null and id != '' "> and id = #{id}</if>
|
||||||
<if test="content != null and content != '' "> and content = #{content}</if>
|
<if test="content != null and content != '' "> and content = #{content}</if>
|
||||||
|
|
@ -38,5 +37,64 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="selectExamQuestionItemById" parameterType="String" resultMap="ExamQuestionItemResult">
|
||||||
|
<include refid="selectExamQuestionItemVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertExamQuestionItem" parameterType="ExamQuestionItem">
|
||||||
|
insert into exam_question_item
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null and id != '' ">id,</if>
|
||||||
|
<if test="content != null and content != '' ">content,</if>
|
||||||
|
<if test="number != null and number != '' ">number,</if>
|
||||||
|
<if test="examQuestionId != null and examQuestionId != '' ">exam_question_id,</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">create_by,</if>
|
||||||
|
<if test="createDate != null ">create_date,</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">update_by,</if>
|
||||||
|
<if test="updateDate != null ">update_date,</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">remarks,</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">del_flag,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null and id != '' ">#{id},</if>
|
||||||
|
<if test="content != null and content != '' ">#{content},</if>
|
||||||
|
<if test="number != null and number != '' ">#{number},</if>
|
||||||
|
<if test="examQuestionId != null and examQuestionId != '' ">#{examQuestionId},</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">#{createBy},</if>
|
||||||
|
<if test="createDate != null ">#{createDate},</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">#{updateBy},</if>
|
||||||
|
<if test="updateDate != null ">#{updateDate},</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">#{remarks},</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">#{delFlag},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateExamQuestionItem" parameterType="ExamQuestionItem">
|
||||||
|
update exam_question_item
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="content != null and content != '' ">content = #{content},</if>
|
||||||
|
<if test="number != null and number != '' ">number = #{number},</if>
|
||||||
|
<if test="examQuestionId != null and examQuestionId != '' ">exam_question_id = #{examQuestionId},</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">create_by = #{createBy},</if>
|
||||||
|
<if test="createDate != null ">create_date = #{createDate},</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateDate != null ">update_date = #{updateDate},</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">remarks = #{remarks},</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">del_flag = #{delFlag},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteExamQuestionItemById" parameterType="String">
|
||||||
|
delete from exam_question_item where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteExamQuestionItemByIds" parameterType="String">
|
||||||
|
delete from exam_question_item where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
@ -20,12 +20,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectExamQuestionVo">
|
<sql id="selectExamQuestionVo">
|
||||||
id, title, answer, type, label, category_id, create_by, create_date, update_by, update_date, remarks, del_flag </sql>
|
select id, title, answer, type, label, category_id, create_by, create_date, update_by, update_date, remarks, del_flag from exam_question
|
||||||
|
</sql>
|
||||||
|
|
||||||
<select id="selectExamQuestionList" parameterType="ExamQuestion" resultMap="ExamQuestionResult">
|
<select id="selectExamQuestionList" parameterType="ExamQuestion" resultMap="ExamQuestionResult">
|
||||||
select
|
|
||||||
<include refid="selectExamQuestionVo"/>
|
<include refid="selectExamQuestionVo"/>
|
||||||
from exam_question
|
|
||||||
<where>
|
<where>
|
||||||
<if test="id != null and id != '' "> and id = #{id}</if>
|
<if test="id != null and id != '' "> and id = #{id}</if>
|
||||||
<if test="title != null and title != '' "> and title = #{title}</if>
|
<if test="title != null and title != '' "> and title = #{title}</if>
|
||||||
|
|
@ -42,5 +41,70 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="selectExamQuestionById" parameterType="String" resultMap="ExamQuestionResult">
|
||||||
|
<include refid="selectExamQuestionVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertExamQuestion" parameterType="ExamQuestion">
|
||||||
|
insert into exam_question
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null and id != '' ">id,</if>
|
||||||
|
<if test="title != null and title != '' ">title,</if>
|
||||||
|
<if test="answer != null and answer != '' ">answer,</if>
|
||||||
|
<if test="type != null and type != '' ">type,</if>
|
||||||
|
<if test="label != null and label != '' ">label,</if>
|
||||||
|
<if test="categoryId != null and categoryId != '' ">category_id,</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">create_by,</if>
|
||||||
|
<if test="createDate != null ">create_date,</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">update_by,</if>
|
||||||
|
<if test="updateDate != null ">update_date,</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">remarks,</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">del_flag,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null and id != '' ">#{id},</if>
|
||||||
|
<if test="title != null and title != '' ">#{title},</if>
|
||||||
|
<if test="answer != null and answer != '' ">#{answer},</if>
|
||||||
|
<if test="type != null and type != '' ">#{type},</if>
|
||||||
|
<if test="label != null and label != '' ">#{label},</if>
|
||||||
|
<if test="categoryId != null and categoryId != '' ">#{categoryId},</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">#{createBy},</if>
|
||||||
|
<if test="createDate != null ">#{createDate},</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">#{updateBy},</if>
|
||||||
|
<if test="updateDate != null ">#{updateDate},</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">#{remarks},</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">#{delFlag},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateExamQuestion" parameterType="ExamQuestion">
|
||||||
|
update exam_question
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="title != null and title != '' ">title = #{title},</if>
|
||||||
|
<if test="answer != null and answer != '' ">answer = #{answer},</if>
|
||||||
|
<if test="type != null and type != '' ">type = #{type},</if>
|
||||||
|
<if test="label != null and label != '' ">label = #{label},</if>
|
||||||
|
<if test="categoryId != null and categoryId != '' ">category_id = #{categoryId},</if>
|
||||||
|
<if test="createBy != null and createBy != '' ">create_by = #{createBy},</if>
|
||||||
|
<if test="createDate != null ">create_date = #{createDate},</if>
|
||||||
|
<if test="updateBy != null and updateBy != '' ">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateDate != null ">update_date = #{updateDate},</if>
|
||||||
|
<if test="remarks != null and remarks != '' ">remarks = #{remarks},</if>
|
||||||
|
<if test="delFlag != null and delFlag != '' ">del_flag = #{delFlag},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteExamQuestionById" parameterType="String">
|
||||||
|
delete from exam_question where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteExamQuestionByIds" parameterType="String">
|
||||||
|
delete from exam_question where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
@ -0,0 +1,140 @@
|
||||||
|
<!DOCTYPE HTML>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<head th:include="include :: header"></head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-examQuestion-add">
|
||||||
|
<div class="form-group">
|
||||||
|
<input type="hidden" id="categoryId" name="categoryId" th:value="${categoryId}">
|
||||||
|
<input type="hidden" id="type" name="type" th:value="${type}">
|
||||||
|
<label class="col-sm-3 control-label">问题标题:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="title" name="title" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">问题答案:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="answer" name="answer" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group" >
|
||||||
|
<label class="col-sm-3 control-label">问题选项:</label>
|
||||||
|
<div class="col-sm-1">
|
||||||
|
<input style="padding: 6px 10px" id="number1" name="number" class="form-control" type="text" value="A" readonly>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-7">
|
||||||
|
<input id="content1" name="content" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group" >
|
||||||
|
<label class="col-sm-3 control-label"></label>
|
||||||
|
<div class="col-sm-1">
|
||||||
|
<input style="padding: 6px 10px" id="number2" name="number" class="form-control" type="text" value="B" readonly>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-7">
|
||||||
|
<input id="content2" name="content" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group" id="addOption">
|
||||||
|
<label class="col-sm-4 control-label"></label>
|
||||||
|
<div class="col-sm-7">
|
||||||
|
<a style="text-align: center;color: #999;border: 1px #ccc dashed;display:block;height: 34px
|
||||||
|
;line-height: 34px" href="javascript:addOption();">添加选项</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!--</div>-->
|
||||||
|
|
||||||
|
<!--<div class="form-group">-->
|
||||||
|
<!--<label class="col-sm-3 control-label">标签:</label>-->
|
||||||
|
<!--<div class="col-sm-8">-->
|
||||||
|
<!--<input id="label" name="label" class="form-control" type="text">-->
|
||||||
|
<!--</div>-->
|
||||||
|
<!--</div>-->
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">备注信息:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input id="remarks" name="remarks" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<div th:include="include::footer"></div>
|
||||||
|
<script type="text/javascript">
|
||||||
|
$(function () {
|
||||||
|
if ($.validator) {
|
||||||
|
$.validator.prototype.elements = function () {
|
||||||
|
var validator = this,
|
||||||
|
rulesCache = {};
|
||||||
|
return $([]).add(this.currentForm.elements)
|
||||||
|
.filter(":input")
|
||||||
|
.not(":submit, :reset, :image, [disabled]")
|
||||||
|
.not(this.settings.ignore)
|
||||||
|
.filter(function () {
|
||||||
|
var elementIdentification = this.id || this.name;
|
||||||
|
!elementIdentification && validator.settings.debug && window.console && console.error("%o has no id nor name assigned", this);
|
||||||
|
if (elementIdentification in rulesCache || !validator.objectLength($(this).rules()))
|
||||||
|
return false;
|
||||||
|
rulesCache[elementIdentification] = true;
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
var item = ["C","D","E","F","G","H","I","G","K","L","M","N"];
|
||||||
|
var index = 0;
|
||||||
|
var prefix = ctx + "exam/examQuestion"
|
||||||
|
$("#form-examQuestion-add").validate({
|
||||||
|
rules:{
|
||||||
|
title:{
|
||||||
|
required:true,
|
||||||
|
},
|
||||||
|
content:{
|
||||||
|
required:true,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/add", $('#form-examQuestion-add').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function addOption(){
|
||||||
|
$("#addOption").before(' <div class="form-group update1" id="div'+item[index]+'"> <label class="col-sm-3 control-label"></label> <div class="col-sm-1"> ' +
|
||||||
|
'<input style="padding: 6px 10px" id="number'+item[index]+'" name="number" class="form-control update2" type="text" value="'+item[index]+'" readonly> ' +
|
||||||
|
'</div> <div class="col-sm-7"> <input name="content" class="form-control" type="text"> </div> <div class="col-sm-1"> <a class="update3" style="text-align: center;color: #999;border: 1px #ccc dashed;display:block;height: 34px;line-height: 34px" href="javascript:deleteOption(\''+item[index++]+'\');">X</a> </div></div>')
|
||||||
|
}
|
||||||
|
|
||||||
|
function deleteOption(id){
|
||||||
|
debugger
|
||||||
|
$("#div"+id).remove();
|
||||||
|
index--;
|
||||||
|
var index1 = 0;
|
||||||
|
var index2 = 0;
|
||||||
|
var index3 = 0
|
||||||
|
$(".update1").each(function(){
|
||||||
|
$(this).attr("id","div"+item[index1++])
|
||||||
|
})
|
||||||
|
$(".update2").each(function(){
|
||||||
|
$(this).attr("value",item[index2++])
|
||||||
|
})
|
||||||
|
$(".update3").each(function(){
|
||||||
|
$(this).attr("href",'javascript:deleteOption(\''+item[index3++]+'\');');
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -2,178 +2,225 @@
|
||||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<head th:include="include :: header"></head>
|
<head th:include="include :: header"></head>
|
||||||
|
<link th:href="@{/ajax/libs/jquery-layout/jquery.layout-latest.css}" rel="stylesheet"/>
|
||||||
|
<link th:href="@{/ajax/libs/jquery-ztree/3.5/css/metro/zTreeStyle.css}" rel="stylesheet"/>
|
||||||
<body class="gray-bg">
|
<body class="gray-bg">
|
||||||
|
<div class="ui-layout-west">
|
||||||
|
<div class="main-content">
|
||||||
|
<div class="box box-main">
|
||||||
|
<div class="box-header">
|
||||||
|
<div class="box-title">
|
||||||
|
<i class="fa icon-grid"></i> 题库
|
||||||
|
</div>
|
||||||
|
<div class="box-tools pull-right">
|
||||||
|
<a type="button" class="btn btn-box-tool menuItem" href="#" onclick="examQuestionCategory()"
|
||||||
|
title="题库管理"><i
|
||||||
|
class="fa fa-edit"></i></a>
|
||||||
|
<button type="button" class="btn btn-box-tool" id="btnExpand" title="展开" style="display:none;"><i
|
||||||
|
class="fa fa-chevron-up"></i></button>
|
||||||
|
<button type="button" class="btn btn-box-tool" id="btnCollapse" title="折叠"><i
|
||||||
|
class="fa fa-chevron-down"></i></button>
|
||||||
|
<button type="button" class="btn btn-box-tool" id="btnRefresh" title="刷新题库"><i
|
||||||
|
class="fa fa-refresh"></i></button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="ui-layout-content">
|
||||||
|
<div id="tree" class="ztree"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="container-div">
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-sm-12 search-collapse">
|
|
||||||
<form id="formId">
|
|
||||||
<div class="select-list">
|
|
||||||
<ul>
|
|
||||||
<li>
|
|
||||||
问题标题:<input type="text" name="title"/>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li>
|
<div class="container-div ui-layout-center">
|
||||||
问题答案:<input type="text" name="answer"/>
|
<div class="row">
|
||||||
</li>
|
<div class="col-sm-12 search-collapse">
|
||||||
|
<form id="formId">
|
||||||
|
<input type="hidden" id="categoryId" name="categoryId">
|
||||||
|
<div class="select-list">
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
问题标题:<input type="text" name="title"/>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
问题类型:<input type="text" name="type"/>
|
问题类型:<select name="type" th:with="type=${@dict.getType('exam_question_type')}">
|
||||||
</li>
|
<option value="">所有</option>
|
||||||
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||||
|
</select>
|
||||||
|
</li>
|
||||||
|
|
||||||
<li>
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
|
||||||
标签:<input type="text" name="label"/>
|
class="fa fa-search"></i> 搜索</a>
|
||||||
</li>
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
|
||||||
|
class="fa fa-refresh"></i> 重置</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
<li>
|
<div class="btn-group-sm hidden-xs" id="toolbar" role="group">
|
||||||
类别:<input type="text" name="categoryId"/>
|
<a class="btn btn-success" onclick="addChoiceQuestion()" shiro:hasPermission="exam:examQuestion:add">
|
||||||
</li>
|
<i class="fa fa-plus"></i> 添加选择题
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary btn-edit disabled" onclick="$.operate.edit()"
|
||||||
|
shiro:hasPermission="exam:examQuestion:edit">
|
||||||
|
<i class="fa fa-edit"></i> 修改
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-danger btn-del btn-del disabled" onclick="$.operate.removeAll()"
|
||||||
|
shiro:hasPermission="exam:examQuestion:remove">
|
||||||
|
<i class="fa fa-remove"></i> 删除
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="exam:examQuestion:export">
|
||||||
|
<i class="fa fa-download"></i> 导出
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-12 select-table table-striped">
|
||||||
|
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div th:include="include :: footer"></div>
|
||||||
|
<script th:src="@{/ajax/libs/jquery-layout/jquery.layout-latest.js}"></script>
|
||||||
|
<script th:src="@{/ajax/libs/jquery-ztree/3.5/js/jquery.ztree.all-3.5.js}"></script>
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var editFlag = [[${@permission.hasPermi('exam:examQuestion:edit')}]];
|
||||||
|
var removeFlag = [[${@permission.hasPermi('exam:examQuestion:remove')}]];
|
||||||
|
var prefix = ctx + "exam/examQuestion";
|
||||||
|
|
||||||
<li>
|
$(function () {
|
||||||
创建者:<input type="text" name="createBy"/>
|
$('body').layout({west__size: 185});
|
||||||
</li>
|
queryExamQuestionList();
|
||||||
|
queryExamQuestionCategoryTree();
|
||||||
|
});
|
||||||
|
|
||||||
<li>
|
function queryExamQuestionList() {
|
||||||
创建时间:<input type="text" name="createDate"/>
|
var options = {
|
||||||
</li>
|
url: prefix + "/list",
|
||||||
|
createUrl: prefix + "/add",
|
||||||
<li>
|
updateUrl: prefix + "/edit/{id}",
|
||||||
更新者:<input type="text" name="updateBy"/>
|
removeUrl: prefix + "/remove",
|
||||||
</li>
|
exportUrl: prefix + "/export",
|
||||||
|
modalName: "问题",
|
||||||
<li>
|
search: false,
|
||||||
更新时间:<input type="text" name="updateDate"/>
|
showExport: true,
|
||||||
</li>
|
columns: [{
|
||||||
|
checkbox: true
|
||||||
<li>
|
},
|
||||||
备注信息:<input type="text" name="remarks"/>
|
{
|
||||||
</li>
|
field: 'id',
|
||||||
|
title: 'ID',
|
||||||
<li>
|
sortable: true
|
||||||
删除标记:<input type="text" name="delFlag"/>
|
},
|
||||||
</li>
|
{
|
||||||
|
field: 'title',
|
||||||
<li>
|
title: '问题标题',
|
||||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
sortable: true
|
||||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
},
|
||||||
</li>
|
{
|
||||||
</ul>
|
field: 'answer',
|
||||||
</div>
|
title: '问题答案',
|
||||||
</form>
|
sortable: true
|
||||||
</div>
|
},
|
||||||
|
{
|
||||||
<div class="btn-group-sm hidden-xs" id="toolbar" role="group">
|
field: 'type',
|
||||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="exam:examQuestion:add">
|
title: '问题类型',
|
||||||
<i class="fa fa-plus"></i> 添加
|
sortable: true
|
||||||
</a>
|
},
|
||||||
<a class="btn btn-primary btn-edit disabled" onclick="$.operate.edit()" shiro:hasPermission="exam:examQuestion:edit">
|
{
|
||||||
<i class="fa fa-edit"></i> 修改
|
field: 'label',
|
||||||
</a>
|
title: '标签',
|
||||||
<a class="btn btn-danger btn-del btn-del disabled" onclick="$.operate.removeAll()" shiro:hasPermission="exam:examQuestion:remove">
|
sortable: true
|
||||||
<i class="fa fa-remove"></i> 删除
|
},
|
||||||
</a>
|
{
|
||||||
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="exam:examQuestion:export">
|
field: 'createBy',
|
||||||
<i class="fa fa-download"></i> 导出
|
title: '创建者',
|
||||||
</a>
|
sortable: true
|
||||||
</div>
|
},
|
||||||
<div class="col-sm-12 select-table table-striped">
|
{
|
||||||
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
field: 'createDate',
|
||||||
</div>
|
title: '创建时间',
|
||||||
</div>
|
sortable: true
|
||||||
</div>
|
},
|
||||||
<div th:include="include :: footer"></div>
|
{
|
||||||
<script th:inline="javascript">
|
field: 'updateBy',
|
||||||
var editFlag = [[${@permission.hasPermi('exam:examQuestion:edit')}]];
|
title: '更新者',
|
||||||
var removeFlag = [[${@permission.hasPermi('exam:examQuestion:remove')}]];
|
sortable: true
|
||||||
var prefix = ctx + "exam/examQuestion";
|
},
|
||||||
|
{
|
||||||
$(function() {
|
field: 'updateDate',
|
||||||
var options = {
|
title: '更新时间',
|
||||||
url: prefix + "/list",
|
sortable: true
|
||||||
createUrl: prefix + "/add",
|
},
|
||||||
updateUrl: prefix + "/edit/{id}",
|
{
|
||||||
removeUrl: prefix + "/remove",
|
field: 'remarks',
|
||||||
exportUrl: prefix + "/export",
|
title: '备注信息',
|
||||||
modalName: "问题",
|
sortable: true
|
||||||
search: false,
|
},
|
||||||
showExport: true,
|
{
|
||||||
columns: [{
|
title: '操作',
|
||||||
checkbox: true
|
align: 'center',
|
||||||
},
|
formatter: function (value, row, index) {
|
||||||
{
|
var actions = [];
|
||||||
field : 'id',
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||||
title : '',
|
|
||||||
visible: false
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'title',
|
|
||||||
title : '问题标题',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'answer',
|
|
||||||
title : '问题答案',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'type',
|
|
||||||
title : '问题类型',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'label',
|
|
||||||
title : '标签',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'categoryId',
|
|
||||||
title : '类别',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'createBy',
|
|
||||||
title : '创建者',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'createDate',
|
|
||||||
title : '创建时间',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'updateBy',
|
|
||||||
title : '更新者',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'updateDate',
|
|
||||||
title : '更新时间',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'remarks',
|
|
||||||
title : '备注信息',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'delFlag',
|
|
||||||
title : '删除标记',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '操作',
|
|
||||||
align: 'center',
|
|
||||||
formatter: function(value, row, index) {
|
|
||||||
var actions = [];
|
|
||||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
|
||||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||||
return actions.join('');
|
return actions.join('');
|
||||||
}
|
}
|
||||||
}]
|
}]
|
||||||
};
|
};
|
||||||
$.table.init(options);
|
$.table.init(options);
|
||||||
});
|
};
|
||||||
</script>
|
|
||||||
|
function queryExamQuestionCategoryTree() {
|
||||||
|
var url = ctx + "exam/examQuestionCategory/treeData";
|
||||||
|
var options = {
|
||||||
|
url: url,
|
||||||
|
expandLevel: 2,
|
||||||
|
onClick: zOnClick
|
||||||
|
};
|
||||||
|
$.tree.init(options);
|
||||||
|
|
||||||
|
function zOnClick(event, treeId, treeNode) {
|
||||||
|
if(treeNode.pId == 1 || treeNode.pId == 0 ||treeNode.pId == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
$("#categoryId").val(treeNode.id);
|
||||||
|
$.table.search();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
$('#btnExpand').click(function () {
|
||||||
|
$._tree.expandAll(true);
|
||||||
|
$(this).hide();
|
||||||
|
$('#btnCollapse').show();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#btnCollapse').click(function () {
|
||||||
|
$._tree.expandAll(false);
|
||||||
|
$(this).hide();
|
||||||
|
$('#btnExpand').show();
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#btnRefresh').click(function () {
|
||||||
|
queryExamQuestionCategoryTree();
|
||||||
|
});
|
||||||
|
|
||||||
|
/*用户管理-部门*/
|
||||||
|
function examQuestionCategory() {
|
||||||
|
var url = ctx + "exam/examQuestionCategory";
|
||||||
|
createMenuItem(url, "题库管理");
|
||||||
|
}
|
||||||
|
|
||||||
|
function addChoiceQuestion(){
|
||||||
|
if($("#categoryId").val() == null||$("#categoryId").val() == ''){
|
||||||
|
alert("请选择题库!")
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
var url = prefix + "/choiceadd/"+$("#categoryId").val();
|
||||||
|
$.operate.jumpModeltoUrl("添加选择题",url);
|
||||||
|
}
|
||||||
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
@ -5,60 +5,26 @@
|
||||||
<body class="white-bg">
|
<body class="white-bg">
|
||||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
<form class="form-horizontal m" id="form-examQuestionCategory-add">
|
<form class="form-horizontal m" id="form-examQuestionCategory-add">
|
||||||
|
<input id="treeId" name="parentId" type="hidden" th:value="${examQuestionCategory.id}" />
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">分类:</label>
|
<label class="col-sm-3 control-label ">上级名称:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input class="form-control" type="text" onclick="selectExamQuestionCategoryTree()" id="treeName" readonly="true" th:value="${examQuestionCategory.name}"/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">名称:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input id="name" name="name" class="form-control" type="text">
|
<input id="name" name="name" class="form-control" type="text">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">:</label>
|
|
||||||
<div class="col-sm-8">
|
|
||||||
<input id="parentId" name="parentId" class="form-control" type="text">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">:</label>
|
|
||||||
<div class="col-sm-8">
|
|
||||||
<input id="parentIds" name="parentIds" class="form-control" type="text">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">创建者:</label>
|
|
||||||
<div class="col-sm-8">
|
|
||||||
<input id="createBy" name="createBy" class="form-control" type="text">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">创建时间:</label>
|
|
||||||
<div class="col-sm-8">
|
|
||||||
<input id="createDate" name="createDate" class="form-control" type="text">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">更新者:</label>
|
|
||||||
<div class="col-sm-8">
|
|
||||||
<input id="updateBy" name="updateBy" class="form-control" type="text">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">更新时间:</label>
|
|
||||||
<div class="col-sm-8">
|
|
||||||
<input id="updateDate" name="updateDate" class="form-control" type="text">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">备注信息:</label>
|
<label class="col-sm-3 control-label">备注信息:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input id="remarks" name="remarks" class="form-control" type="text">
|
<input id="remarks" name="remarks" class="form-control" type="text">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-3 control-label">删除标记:</label>
|
|
||||||
<div class="col-sm-8">
|
|
||||||
<input id="delFlag" name="delFlag" class="form-control" type="text">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div th:include="include::footer"></div>
|
<div th:include="include::footer"></div>
|
||||||
|
|
@ -66,7 +32,7 @@
|
||||||
var prefix = ctx + "exam/examQuestionCategory"
|
var prefix = ctx + "exam/examQuestionCategory"
|
||||||
$("#form-examQuestionCategory-add").validate({
|
$("#form-examQuestionCategory-add").validate({
|
||||||
rules:{
|
rules:{
|
||||||
xxxx:{
|
name:{
|
||||||
required:true,
|
required:true,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
@ -77,6 +43,23 @@
|
||||||
$.operate.save(prefix + "/add", $('#form-examQuestionCategory-add').serialize());
|
$.operate.save(prefix + "/add", $('#form-examQuestionCategory-add').serialize());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function selectExamQuestionCategoryTree() {
|
||||||
|
var options = {
|
||||||
|
title: '分类选择',
|
||||||
|
width: "380",
|
||||||
|
url: prefix + "/selectExamQuestionCategoryTree/" + $("#treeId").val(),
|
||||||
|
callBack: doSubmit
|
||||||
|
};
|
||||||
|
$.modal.openOptions(options);
|
||||||
|
}
|
||||||
|
|
||||||
|
function doSubmit(index, layero){
|
||||||
|
var body = layer.getChildFrame('body', index);
|
||||||
|
$("#treeId").val(body.find('#treeId').val());
|
||||||
|
$("#treeName").val(body.find('#treeName').val());
|
||||||
|
layer.close(index);
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
||||||
|
|
@ -12,19 +12,19 @@
|
||||||
<input id="name" name="name" th:field="*{name}" class="form-control" type="text">
|
<input id="name" name="name" th:field="*{name}" class="form-control" type="text">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<!--<div class="form-group"> -->
|
||||||
<label class="col-sm-3 control-label">:</label>
|
<!--<label class="col-sm-3 control-label">:</label>-->
|
||||||
<div class="col-sm-8">
|
<!--<div class="col-sm-8">-->
|
||||||
<input id="parentId" name="parentId" th:field="*{parentId}" class="form-control" type="text">
|
<!--<input id="parentId" name="parentId" th:field="*{parentId}" class="form-control" type="text">-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
<div class="form-group">
|
<!--<div class="form-group"> -->
|
||||||
<label class="col-sm-3 control-label">:</label>
|
<!--<label class="col-sm-3 control-label">:</label>-->
|
||||||
<div class="col-sm-8">
|
<!--<div class="col-sm-8">-->
|
||||||
<input id="parentIds" name="parentIds" th:field="*{parentIds}" class="form-control" type="text">
|
<!--<input id="parentIds" name="parentIds" th:field="*{parentIds}" class="form-control" type="text">-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
<div class="form-group">
|
<!--<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">创建者:</label>
|
<label class="col-sm-3 control-label">创建者:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input id="createBy" name="createBy" th:field="*{createBy}" class="form-control" type="text">
|
<input id="createBy" name="createBy" th:field="*{createBy}" class="form-control" type="text">
|
||||||
|
|
@ -47,19 +47,19 @@
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input id="updateDate" name="updateDate" th:field="*{updateDate}" class="form-control" type="text">
|
<input id="updateDate" name="updateDate" th:field="*{updateDate}" class="form-control" type="text">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>-->
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-3 control-label">备注信息:</label>
|
<label class="col-sm-3 control-label">备注信息:</label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<input id="remarks" name="remarks" th:field="*{remarks}" class="form-control" type="text">
|
<input id="remarks" name="remarks" th:field="*{remarks}" class="form-control" type="text">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<!--<div class="form-group"> -->
|
||||||
<label class="col-sm-3 control-label">删除标记:</label>
|
<!--<label class="col-sm-3 control-label">删除标记:</label>-->
|
||||||
<div class="col-sm-8">
|
<!--<div class="col-sm-8">-->
|
||||||
<input id="delFlag" name="delFlag" th:field="*{delFlag}" class="form-control" type="text">
|
<!--<input id="delFlag" name="delFlag" th:field="*{delFlag}" class="form-control" type="text">-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
</div>
|
<!--</div>-->
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div th:include="include::footer"></div>
|
<div th:include="include::footer"></div>
|
||||||
|
|
|
||||||
|
|
@ -4,158 +4,122 @@
|
||||||
<head th:include="include :: header"></head>
|
<head th:include="include :: header"></head>
|
||||||
<body class="gray-bg">
|
<body class="gray-bg">
|
||||||
|
|
||||||
<div class="container-div">
|
<div class="container-div">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-sm-12 search-collapse">
|
<div class="col-sm-12 search-collapse">
|
||||||
<form id="formId">
|
<form id="formId">
|
||||||
<div class="select-list">
|
<div class="select-list">
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
分类:<input type="text" name="name"/>
|
分类:<input type="text" name="name"/>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
:<input type="text" name="parentId"/>
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.treeTable.search()"><i
|
||||||
</li>
|
class="fa fa-search"></i> 搜索</a>
|
||||||
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
|
||||||
<li>
|
class="fa fa-refresh"></i> 重置</a>
|
||||||
:<input type="text" name="parentIds"/>
|
</li>
|
||||||
</li>
|
</ul>
|
||||||
|
</div>
|
||||||
<li>
|
</form>
|
||||||
创建者:<input type="text" name="createBy"/>
|
</div>
|
||||||
</li>
|
<div class="btn-group-sm hidden-xs" id="toolbar" role="group">
|
||||||
|
<a class="btn btn-success" onclick="$.operate.add(1)" shiro:hasPermission="exam:examQuestionCategory:add">
|
||||||
<li>
|
<i class="fa fa-plus"></i> 添加
|
||||||
创建时间:<input type="text" name="createDate"/>
|
</a>
|
||||||
</li>
|
<!--<a class="btn btn-primary btn-edit disabled" onclick="$.operate.edit()"-->
|
||||||
|
<!--shiro:hasPermission="exam:examQuestionCategory:edit">-->
|
||||||
<li>
|
<!--<i class="fa fa-edit"></i> 修改-->
|
||||||
更新者:<input type="text" name="updateBy"/>
|
<!--</a>-->
|
||||||
</li>
|
<!--<a class="btn btn-danger btn-del btn-del disabled" onclick="$.operate.removeAll()"-->
|
||||||
|
<!--shiro:hasPermission="exam:examQuestionCategory:remove">-->
|
||||||
<li>
|
<!--<i class="fa fa-remove"></i> 删除-->
|
||||||
更新时间:<input type="text" name="updateDate"/>
|
<!--</a>-->
|
||||||
</li>
|
<!--<a class="btn btn-warning" onclick="$.table.exportExcel()"-->
|
||||||
|
<!--shiro:hasPermission="exam:examQuestionCategory:export">-->
|
||||||
<li>
|
<!--<i class="fa fa-download"></i> 导出-->
|
||||||
备注信息:<input type="text" name="remarks"/>
|
<!--</a>-->
|
||||||
</li>
|
</div>
|
||||||
|
<div class="col-sm-12 select-table table-striped">
|
||||||
<li>
|
<table id="bootstrap-tree-table" data-mobile-responsive="true"></table>
|
||||||
删除标记:<input type="text" name="delFlag"/>
|
</div>
|
||||||
</li>
|
</div>
|
||||||
|
</div>
|
||||||
<li>
|
<div th:include="include :: footer"></div>
|
||||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
<script th:inline="javascript">
|
||||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
var editFlag = [[${@permission.hasPermi('exam:examQuestionCategory:edit')}]];
|
||||||
</li>
|
var removeFlag = [[${@permission.hasPermi('exam:examQuestionCategory:remove')}]];
|
||||||
</ul>
|
var prefix = ctx + "exam/examQuestionCategory";
|
||||||
</div>
|
debugger
|
||||||
</form>
|
$(function () {
|
||||||
</div>
|
var options = {
|
||||||
|
code: "id",
|
||||||
<div class="btn-group-sm hidden-xs" id="toolbar" role="group">
|
parentCode: "parentId",
|
||||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="exam:examQuestionCategory:add">
|
uniqueId: "id",
|
||||||
<i class="fa fa-plus"></i> 添加
|
url: prefix + "/list",
|
||||||
</a>
|
createUrl: prefix + "/add/{id}",
|
||||||
<a class="btn btn-primary btn-edit disabled" onclick="$.operate.edit()" shiro:hasPermission="exam:examQuestionCategory:edit">
|
updateUrl: prefix + "/edit/{id}",
|
||||||
<i class="fa fa-edit"></i> 修改
|
removeUrl: prefix + "/remove",
|
||||||
</a>
|
exportUrl: prefix + "/export",
|
||||||
<a class="btn btn-danger btn-del btn-del disabled" onclick="$.operate.removeAll()" shiro:hasPermission="exam:examQuestionCategory:remove">
|
modalName: "试题分类",
|
||||||
<i class="fa fa-remove"></i> 删除
|
|
||||||
</a>
|
|
||||||
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="exam:examQuestionCategory:export">
|
|
||||||
<i class="fa fa-download"></i> 导出
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
<div class="col-sm-12 select-table table-striped">
|
|
||||||
<table id="bootstrap-table" data-mobile-responsive="true"></table>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div th:include="include :: footer"></div>
|
|
||||||
<script th:inline="javascript">
|
|
||||||
var editFlag = [[${@permission.hasPermi('exam:examQuestionCategory:edit')}]];
|
|
||||||
var removeFlag = [[${@permission.hasPermi('exam:examQuestionCategory:remove')}]];
|
|
||||||
var prefix = ctx + "exam/examQuestionCategory";
|
|
||||||
|
|
||||||
$(function() {
|
|
||||||
var options = {
|
|
||||||
url: prefix + "/list",
|
|
||||||
createUrl: prefix + "/add",
|
|
||||||
updateUrl: prefix + "/edit/{id}",
|
|
||||||
removeUrl: prefix + "/remove",
|
|
||||||
exportUrl: prefix + "/export",
|
|
||||||
modalName: "试题分类",
|
|
||||||
search: false,
|
search: false,
|
||||||
showExport: true,
|
showExport: true,
|
||||||
columns: [{
|
columns: [{
|
||||||
checkbox: true
|
field: 'selectItem',
|
||||||
},
|
radio: true
|
||||||
{
|
},
|
||||||
field : 'id',
|
{
|
||||||
title : '',
|
field: 'name',
|
||||||
visible: false
|
title: '分类',
|
||||||
},
|
align: "left"
|
||||||
{
|
},
|
||||||
field : 'name',
|
{
|
||||||
title : '分类',
|
field: 'orderNum',
|
||||||
sortable: true
|
title: '排序',
|
||||||
},
|
align: "left"
|
||||||
{
|
},
|
||||||
field : 'parentId',
|
|
||||||
title : '',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
field : 'parentIds',
|
|
||||||
title : '',
|
|
||||||
sortable: true
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
field : 'createBy',
|
field : 'createBy',
|
||||||
title : '创建者',
|
title : '创建者',
|
||||||
sortable: true
|
align: "left"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field : 'createDate',
|
field : 'createDate',
|
||||||
title : '创建时间',
|
title : '创建时间',
|
||||||
sortable: true
|
align: "left"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field : 'updateBy',
|
field : 'updateBy',
|
||||||
title : '更新者',
|
title : '更新者',
|
||||||
sortable: true
|
align: "left"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field : 'updateDate',
|
field : 'updateDate',
|
||||||
title : '更新时间',
|
title : '更新时间',
|
||||||
sortable: true
|
align: "left"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field : 'remarks',
|
field : 'remarks',
|
||||||
title : '备注信息',
|
title : '备注信息',
|
||||||
sortable: true
|
align: "left"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
field : 'delFlag',
|
title: '操作',
|
||||||
title : '删除标记',
|
align: 'left',
|
||||||
sortable: true
|
formatter: function (value, row, index) {
|
||||||
},
|
if(row.id == 1){
|
||||||
{
|
return '';
|
||||||
title: '操作',
|
}
|
||||||
align: 'center',
|
var actions = [];
|
||||||
formatter: function(value, row, index) {
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||||
var actions = [];
|
|
||||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
|
||||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||||
return actions.join('');
|
return actions.join('');
|
||||||
}
|
}
|
||||||
}]
|
}]
|
||||||
};
|
};
|
||||||
$.table.init(options);
|
$.treeTable.init(options);
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
@ -0,0 +1,48 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<head th:include="include :: header"></head>
|
||||||
|
<link th:href="@{/ajax/libs/jquery-ztree/3.5/css/metro/zTreeStyle.css}" rel="stylesheet"/>
|
||||||
|
<style>
|
||||||
|
body{height:auto;font-family: "Microsoft YaHei";}
|
||||||
|
button{font-family: "SimSun","Helvetica Neue",Helvetica,Arial;}
|
||||||
|
</style>
|
||||||
|
<body class="hold-transition box box-main">
|
||||||
|
<input id="treeId" name="treeId" type="hidden" th:value="${examQuestionCategory.id}"/>
|
||||||
|
<input id="treeName" name="treeName" type="hidden" th:value="${examQuestionCategory.name}"/>
|
||||||
|
<div class="wrapper"><div class="treeShowHideButton" onclick="$.tree.toggleSearch();">
|
||||||
|
<label id="btnShow" title="显示搜索" style="display:none;">︾</label>
|
||||||
|
<label id="btnHide" title="隐藏搜索">︽</label>
|
||||||
|
</div>
|
||||||
|
<div class="treeSearchInput" id="search">
|
||||||
|
<label for="keyword">关键字:</label><input type="text" class="empty" id="keyword" maxlength="50">
|
||||||
|
<button class="btn" id="btn" onclick="$.tree.searchNode()"> 搜索 </button>
|
||||||
|
</div>
|
||||||
|
<div class="treeExpandCollapse">
|
||||||
|
<a href="#" onclick="$.tree.expand()">展开</a> /
|
||||||
|
<a href="#" onclick="$.tree.collapse()">折叠</a>
|
||||||
|
</div>
|
||||||
|
<div id="tree" class="ztree treeselect"></div>
|
||||||
|
</div>
|
||||||
|
<div th:include="include::footer"></div>
|
||||||
|
<script th:src="@{/ajax/libs/jquery-ztree/3.5/js/jquery.ztree.all-3.5.js}"></script>
|
||||||
|
<script th:inline="javascript">
|
||||||
|
$(function() {
|
||||||
|
var url = ctx + "exam/examQuestionCategory/treeDataForAdd";
|
||||||
|
var options = {
|
||||||
|
url: url,
|
||||||
|
expandLevel: 2,
|
||||||
|
onClick : zOnClick
|
||||||
|
};
|
||||||
|
$.tree.init(options);
|
||||||
|
});
|
||||||
|
|
||||||
|
function zOnClick(event, treeId, treeNode) {
|
||||||
|
var treeId = treeNode.id;
|
||||||
|
var treeName = treeNode.name;
|
||||||
|
$("#treeId").val(treeId);
|
||||||
|
$("#treeName").val(treeName);
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -39,7 +39,7 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.ruoyi</groupId>
|
<groupId>com.ruoyi</groupId>
|
||||||
<artifactId>ruoyi-framework</artifactId>
|
<artifactId>ruoyi-framework</artifactId>
|
||||||
<version>3.0</version>
|
<version>3.1</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ package com.ruoyi.quartz.mapper;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.framework.web.base.MyMapper;
|
||||||
import com.ruoyi.quartz.domain.SysJob;
|
import com.ruoyi.quartz.domain.SysJob;
|
||||||
import com.ruoyi.quartz.domain.SysJobLog;
|
import com.ruoyi.quartz.domain.SysJobLog;
|
||||||
import tk.mybatis.mapper.common.Mapper;
|
import tk.mybatis.mapper.common.Mapper;
|
||||||
|
|
@ -11,8 +12,7 @@ import tk.mybatis.mapper.common.Mapper;
|
||||||
*
|
*
|
||||||
* @author ruoyi
|
* @author ruoyi
|
||||||
*/
|
*/
|
||||||
public interface SysJobLogMapper extends Mapper<SysJobLog>
|
public interface SysJobLogMapper extends Mapper<SysJobLog>,MyMapper<SysJobLog> {
|
||||||
{
|
|
||||||
/**
|
/**
|
||||||
* 获取quartz调度器日志的计划任务
|
* 获取quartz调度器日志的计划任务
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,8 @@
|
||||||
package com.ruoyi.quartz.mapper;
|
package com.ruoyi.quartz.mapper;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.framework.web.base.MyMapper;
|
||||||
import com.ruoyi.quartz.domain.SysJob;
|
import com.ruoyi.quartz.domain.SysJob;
|
||||||
import com.ruoyi.system.domain.SysConfig;
|
import com.ruoyi.system.domain.SysConfig;
|
||||||
import tk.mybatis.mapper.common.Mapper;
|
import tk.mybatis.mapper.common.Mapper;
|
||||||
|
|
@ -10,8 +12,7 @@ import tk.mybatis.mapper.common.Mapper;
|
||||||
*
|
*
|
||||||
* @author ruoyi
|
* @author ruoyi
|
||||||
*/
|
*/
|
||||||
public interface SysJobMapper extends Mapper<SysJob>
|
public interface SysJobMapper extends Mapper<SysJob>,MyMapper<SysJob> {
|
||||||
{
|
|
||||||
/**
|
/**
|
||||||
* 查询调度任务日志集合
|
* 查询调度任务日志集合
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -81,9 +81,9 @@
|
||||||
formatter: function(value, row, index) {
|
formatter: function(value, row, index) {
|
||||||
if (row.parentId != 0) {
|
if (row.parentId != 0) {
|
||||||
var actions = [];
|
var actions = [];
|
||||||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.deptId + '\')"><i class="fa fa-edit">编辑</i></a> ');
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit">编辑</i></a> ');
|
||||||
actions.push('<a class="btn btn-info btn-xs ' + addFlag + '" href="#" onclick="$.operate.add(\'' + row.deptId + '\')"><i class="fa fa-plus">新增</i></a> ');
|
actions.push('<a class="btn btn-info btn-xs ' + addFlag + '" href="#" onclick="$.operate.add(\'' + row.id + '\')"><i class="fa fa-plus">新增</i></a> ');
|
||||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="remove(\'' + row.deptId + '\')"><i class="fa fa-remove">删除</i></a>');
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="remove(\'' + row.id + '\')"><i class="fa fa-remove">删除</i></a>');
|
||||||
return actions.join('');
|
return actions.join('');
|
||||||
} else {
|
} else {
|
||||||
return "";
|
return "";
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue