去除class文件

parent f93daf42
#Updated by: CN=admin/O=Vanke
#Thu Feb 16 15:49:29 CST 2006
#cookie.domain=.vanke.com
#token.expiration=30
#domino.secret=BTfa8F+HwNejYEGtuZSJTWOZ/t8\=
#Updated by: CN=admin/O=Vanke
#Thu Feb 16 15:49:29 CST 2006
cookie.domain=.kingdee.com
token.expiration=30
domino.secret=BTfa8F+HwNejYEGtuZSJTWOZ/t8\=
<?xml version="1.0" encoding="UTF-8"?>
<ehcache updateCheck="false" name="defaultCache">
<diskStore path="java.io.tmpdir/ejweb/mcache" />
<!-- 默认缓存配置. -->
<defaultCache maxEntriesLocalHeap="100" eternal="false" timeToIdleSeconds="300" timeToLiveSeconds="600"
overflowToDisk="true" maxEntriesLocalDisk="100000" />
<!-- 系统缓存 -->
<cache name="sysCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true"/>
<!-- 用户缓存 -->
<cache name="userCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true"/>
<!-- 工作流模块缓存 -->
<cache name="actCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true"/>
<!-- 内容管理模块缓存
<cache name="cmsCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true"/> -->
<!-- 系统活动会话缓存 -->
<cache name="activeSessionsCache" maxEntriesLocalHeap="10000" overflowToDisk="true"
eternal="true" timeToLiveSeconds="0" timeToIdleSeconds="0"
diskPersistent="true" diskExpiryThreadIntervalSeconds="600"/>
<!-- 简单页面缓存
<cache name="SimplePageCachingFilter" maxEntriesLocalHeap="100" eternal="false" overflowToDisk="true"
timeToIdleSeconds="120" timeToLiveSeconds="120" memoryStoreEvictionPolicy="LFU"/> -->
</ehcache>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<ehcache updateCheck="false" name="defaultCache">
<!--
<cacheManagerPeerProviderFactory class="net.sf.ehcache.distribution.RMICacheManagerPeerProviderFactory"
properties="peerDiscovery=manual, socketTimeoutMillis=2000, rmiUrls=//localhost:40001/defaultCache" />
<cacheManagerPeerListenerFactory class="net.sf.ehcache.distribution.RMICacheManagerPeerListenerFactory"
properties="hostName=localhost, port=40000, socketTimeoutMillis=2000"/> -->
<cacheManagerPeerProviderFactory class="net.sf.ehcache.distribution.RMICacheManagerPeerProviderFactory"
properties="peerDiscovery=automatic,multicastGroupAddress=230.0.0.1, multicastGroupPort=4446" />
<cacheManagerPeerListenerFactory class="net.sf.ehcache.distribution.RMICacheManagerPeerListenerFactory" />
<diskStore path="java.io.tmpdir/ejweb/mcache" />
<!-- 默认缓存配置. -->
<defaultCache maxEntriesLocalHeap="100" eternal="false" timeToIdleSeconds="300" timeToLiveSeconds="600"
overflowToDisk="true" maxEntriesLocalDisk="100000" >
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory"
properties="replicatePuts=false,replicateUpdatesViaCopy=false"/>
</defaultCache>
<!-- 系统缓存 -->
<cache name="sysCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true">
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory"/>
</cache>
<!-- 用户缓存 -->
<cache name="userCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true">
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory"/>
</cache>
<!-- 工作流模块缓存 -->
<cache name="actCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true">
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory"/>
</cache>
<!-- 内容管理模块缓存
<cache name="cmsCache" maxEntriesLocalHeap="100" eternal="true" overflowToDisk="true">
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory"/>
</cache> -->
<!-- 系统活动会话缓存 -->
<cache name="activeSessionsCache" maxEntriesLocalHeap="10000" overflowToDisk="true"
eternal="true" timeToLiveSeconds="0" timeToIdleSeconds="0"
diskPersistent="true" diskExpiryThreadIntervalSeconds="600">
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory"
properties="replicateAsynchronously=true, replicatePuts=true, replicateUpdates=true,
replicateUpdatesViaCopy=false, replicateRemovals=true "/>
</cache>
<!-- 简单页面缓存
<cache name="SimplePageCachingFilter" maxEntriesLocalHeap="100" eternal="false" overflowToDisk="true"
timeToIdleSeconds="120" timeToLiveSeconds="120" memoryStoreEvictionPolicy="LFU">
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory"
properties="replicateAsynchronously=true, replicatePuts=true, replicateUpdates=true,
replicateUpdatesViaCopy=false, replicateRemovals=true "/>
</cache> -->
</ehcache>
\ No newline at end of file
#============================#
#===== System settings ======#
#============================#
#\u4ea7\u54c1\u4fe1\u606f\u8bbe\u7f6e
productName=\u76d1\u5bdf\u5ba1\u8ba1\u7ba1\u7406\u7cfb\u7edf
copyrightYear=2017
version=V1.2.6
# \u5BFC\u822A\u6A21\u5F0F 0 OR 1(Default 0)
tabMode=0
#\u6f14\u793a\u6a21\u5f0f: \u4e0d\u80fd\u64cd\u4f5c\u548c\u4fdd\u5b58\u7684\u6a21\u5757\uff1a sys: area/office/user/role/menu/dict, cms: site/category
demoMode=false
#\u7ba1\u7406\u57fa\u7840\u8def\u5f84, \u9700\u540c\u6b65\u4fee\u6539\uff1aweb.xml
adminPath=/admin
#\u524d\u7aef\u57fa\u7840\u8def\u5f84
frontPath=/web
#\u7f51\u7ad9URL\u540e\u7f00
urlSuffix=.html
#\u662f\u5426\u4e0d\u5141\u8bb8\u5237\u65b0\u4e3b\u9875\uff0c\u4e0d\u5141\u8bb8\u60c5\u51b5\u4e0b\uff0c\u5237\u65b0\u4e3b\u9875\u4f1a\u5bfc\u81f4\u91cd\u65b0\u767b\u5f55
notAllowRefreshIndex=false
#\u662f\u5426\u5141\u8bb8\u591a\u8d26\u53f7\u540c\u65f6\u767b\u5f55
user.multiAccountLogin=true
#\u5206\u9875\u914d\u7f6e
page.pageSize=30
#\u7855\u6b63\u7ec4\u4ef6\u662f\u5426\u4f7f\u7528\u7f13\u5b58
supcan.useCache=false
#\u901a\u77e5\u95f4\u9694\u65f6\u95f4\u8bbe\u7f6e, \u5355\u4f4d\uff1a\u6beb\u79d2, 30s=30000ms, 60s=60000ms
oa.notify.remind.interval=60000
#============================#
#==== Framework settings ====#
#============================#
#\u4f1a\u8bdd\u8d85\u65f6\uff0c \u5355\u4f4d\uff1a\u6beb\u79d2\uff0c 20m=1200000ms, 30m=1800000ms, 60m=3600000ms
session.sessionTimeout=2800000
#\u4f1a\u8bdd\u6e05\u7406\u95f4\u9694\u65f6\u95f4\uff0c \u5355\u4f4d\uff1a\u6beb\u79d2\uff0c2m=120000ms\u3002
session.sessionTimeoutClean=220000
#\u7f13\u5b58\u8bbe\u7f6e
ehcache.configFile=cache/ehcache-local.xml
#ehcache.configFile=cache/ehcache-rmi.xml
#\u7d22\u5f15\u9875\u8def\u5f84
web.view.index=/admin
#\u89c6\u56fe\u6587\u4ef6\u5b58\u653e\u8def\u5f84
web.view.prefix=/WEB-INF/views/
web.view.suffix=.jsp
#\u6700\u5927\u6587\u4ef6\u4e0a\u4f20\u9650\u5236\uff0c\u5355\u4f4d\u5b57\u8282. 10M=10*1024*1024(B)=10485760 bytes\uff0c\u9700\u540c\u6b65\u4fee\u6539\uff1ackfinder.xml
web.maxUploadSize=10485760
#\u65e5\u5fd7\u62e6\u622a\u8bbe\u7f6e\uff0c\u6392\u9664\u7684URI\uff1b\u5305\u542b @RequestMapping\u6ce8\u89e3\u7684value\u3002\uff08\u5df2\u4f5c\u5e9f\uff09
#web.logInterceptExcludeUri=/, /login, /sys/menu/tree, /sys/menu/treeData, /oa/oaNotify/self/count
#web.logInterceptIncludeRequestMapping=save, delete, import, updateSort
#\u9759\u6001\u6587\u4ef6\u540e\u7f00
web.staticFile=.css,.js,.png,.jpg,.gif,.jpeg,.bmp,.ico,.swf,.psd,.htc,.htm,.html,.crx,.xpi,.exe,.ipa,.apk
#\u4e0a\u4f20\u6587\u4ef6\u7edd\u5bf9\u8def\u5f84, \u8def\u5f84\u4e2d\u4e0d\u5141\u8bb8\u5305\u542b\u201cuserfiles\u201d
#userfiles.basedir=D:/jeesite
userfiles.prefix=static
#\u5de5\u7a0b\u8def\u5f84\uff0c\u5728\u4ee3\u7801\u751f\u6210\u65f6\u83b7\u53d6\u4e0d\u5230\u5de5\u7a0b\u8def\u5f84\u65f6\uff0c\u53ef\u518d\u6b64\u6307\u5b9a\u7edd\u5bf9\u8def\u5f84\u3002
#projectPath=D\:\\workspace\\jeesite
# The Upload File DIR, Must End With File Separator
file.upload.dir=/home/static/report/
#file.upload.dir=/mnt/sunac/
## file.upload.dir=D:\\WorkSapce\\JEESpace\\ejweb-api-1.0\\files\\
#file.upload.dir=/D:/uploads/
# Max Upload File Size: (default 30M=30*1024*1024(B)=31457280 bytes)
file.max.upload.size=31457280
# The File Path Date Format(default yyyyMM)
file.path.format={yyyy}{mm}{dd}
# The Prefix Of File Name Date Format(default is empty)(Deprecated)
# example:HHmmss
# file.prefix.filename.format=
# The Allow File Extension
file.allow.extensions=.png;.jpg;.gif;.jpeg;.ico;
# The Image File Extension
file.image.extensions=.png;.jpg;.jpeg;
# The Allow Create Thumbnail Image(default true)
# The Thumbnail Path Is: file.upload.dir+thumbs+image path
file.image.thumb.is.allow=true
# The Thumbnail width And height(default 640x640)
file.image.thumb.width=640
file.image.thumb.height=640
# The Prefix Url
#file.prefix.url=http://123.56.146.81:8808/
#file.prefix.url=http://192.168.7.210:8081/
#ڴʽ
#file.prefix.url=http://192.168.2.62:8082/
file.prefix.url=http://report.sunac.com.cn:8899/static/report/
# The Prefix separator
file.upload.path.separator = /
# The Push Server Config
push.server.url=http://123.56.146.81:1880/v1/
faq.base.api=http://localhost:8182/sunac-core-api
user.office.name=\u5929\u6d25
\ No newline at end of file
#MySQL Database Config(The All Config Is Must)
db.table.prefix=sunac_
#jdbc.type=mysql
#jdbc.driver.class=com.mysql.jdbc.Driver
#jdbc.url=jdbc:mysql://123.56.146.7:3306/sunac_report?useUnicode=true&characterEncoding=utf-8
#jdbc.username=reportuser
#jdbc.password=$R@20$7
#融创测试数据库
#jdbc.type=oracle
#jdbc.driver.class=oracle.jdbc.driver.OracleDriver
#jdbc.url=jdbc:oracle:thin:@192.168.7.16:1521:EASUAT
#jdbc.username= eas7533
#jdbc.password= sunac
#正式数据库
#jdbc.type=oracle
#jdbc.driver.class=oracle.jdbc.driver.OracleDriver
#jdbc.url=jdbc:oracle:thin:@192.168.2.24:1521:eas1
#jdbc.username= easdba
#jdbc.password= Sunac_1918
#
#本地测试库
jdbc.type=mysql
jdbc.driver.class=com.mysql.jdbc.Driver
jdbc.url=jdbc\:mysql\://localhost\:3306/sunac_report?useUnicode\=true&characterEncoding\=utf-8
jdbc.username=root
jdbc.password=123456
#初始化连接
jdbc.initialSize=0
#连接池的最大活动个数
jdbc.maxActive=20
#没有人用连接的时候,最大闲置的连接个数。
jdbc.maxIdle=100
#没有人用连接的时候,最小闲置的连接个数。
jdbc.minIdle=0
#超时等待时间以毫秒为单位
jdbc.maxWait=10000
#是否自动回收超时连接
jdbc.removeAbandoned=true
#设置被遗弃的连接的超时的时间(以秒数为单位),即当一个连接被遗弃的时间超过设置的时间,则它会自动转换成可利用的连接。默认的超时时间是300秒。
jdbc.removeAbandonedTimeout=60
#是否在自动回收超时连接的时候打印连接的超时错误
jdbc.logAbandoned=true
#给出一条简单的sql语句进行验证
jdbc.validationQuery=SELECT 1 FROM DUAL
#在取出连接时进行有效验证
jdbc.testOnBorrow=true
\ No newline at end of file
url = LDAP://192.168.2.159:3060/
basedn = dc=sunac,dc=com,dc=cn
userdn = cn=oudadmin
userPassword = Abcd1234
\ No newline at end of file
# Output pattern : date [thread] priority category - message FATAL 0 ERROR 3 WARN 4 INFO 6 DEBUG 7
log4j.rootLogger=DEBUG, Console, RollingFile
#Console
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
log4j.appender.Console.layout.ConversionPattern=%d %-5p [%c{5}] - %m%n
#RollingFile
log4j.appender.RollingFile=org.apache.log4j.DailyRollingFileAppender
log4j.appender.RollingFile.File=../logs/jeesite/jeesite.log
log4j.appender.RollingFile.layout=org.apache.log4j.PatternLayout
log4j.appender.RollingFile.layout.ConversionPattern=%d [%t] %-5p [%c] - %m%n
#log4j.logger.java.sql=DEBUG
#Springframework level
#log4j.logger.org.springframework=ERROR
#Hibernate level
#log4j.logger.org.hibernate=ERROR
#log4j.logger.org.hibernate.cache.ehcache.AbstractEhcacheRegionFactory=ERROR
#log4j.logger.org.hibernate.search.impl.ConfigContext=ERROR
#log4j.logger.net.sf.ehcache.config.CacheConfiguration=ERROR
#Project defalult level
#log4j.logger.org.activiti.engine.impl.persistence=DEBUG
#log4j.logger.org.apache.shiro=DEBUG
log4j.loggercom.ejweb=DEBUG
log4j.loggercom.ejweb.core.security.shiro=WARN
log4j.loggercom.ejweb.core.utils.JedisUtils=WARN
log4j.loggercom.ejweb.modules.sys.web.LoginController=WARN
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.front.sso.dao.SsoDao">
<select id="checkSso" resultType="Integer" parameterType="String">
SELECT
count(*)
FROM
ct_bbtc_sys_user su
WHERE
su.login_name = #{username}
AND del_flag = '0'
</select>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.front.upload.dao.FrontUploadDao">
<sql id="fileColumns">
id,
app_code,
session_id,
clientip,
module,
md5,
name,
input_name,
path,
thumbs,
extesion,
summary,
size,
width,
orientataion,
height
</sql>
<insert id="addUploadFile" useGeneratedKeys="true" keyProperty="id">
INSERT INTO ct_bbtc_upload_files(
<include refid="fileColumns"/>
) VALUES(
#{id},
#{appCode},
#{sessionId},
#{clientip},
#{module},
#{md5},
#{name},
#{inputName},
#{path},
#{thumbs},
#{extesion},
#{summary},
#{size},
#{width},
#{orientataion},
#{height}
)
</insert>
<select id="getUploadEntityByPath" resultType="com.ejweb.modules.upload.entity.UploadEntity">
SELECT
<include refid="fileColumns"/>
FROM ct_bbtc_upload_files
WHERE path = #{code}
<if test="dbName == 'oracle'"> AND rownum &lt;= 1</if>
ORDER BY created DESC
<if test="dbName == 'mysql'"> limit 1</if>
</select>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.front.report.dao.FrontReportDao">
<sql id="reportColumns">
id,
report_project,
report_city,
report_time,
report_content,
report_person_name,
report_person_tel,
report_person_email,
report_source,
report_status,
supplement_company,
supplement_department,
supplement_informant,
supplement_title,
supplement_type,
supplement_area,
supplement_project,
supplement_content,
deal_person_name,
deal_result,
exchange_before_user,
exchange_after_user,
create_by,
create_date,
update_by,
update_date
</sql>
<insert id="insertReport" useGeneratedKeys="true" keyProperty="id">
INSERT INTO ct_bbtc_report(
id,
report_project,
report_city,
report_time,
report_content,
report_person_name,
report_person_tel,
report_person_email,
report_source,
report_status,
supplement_informant,
supplement_title,
exchange_before_user,
exchange_after_user,
create_by,
create_date,
update_by,
update_date,
oa_name,
report_ip,
ip_city,
report_participants,
report_insider,
report_suggestion,
report_Date,
report_site,
report_qq,
report_weixin
) VALUES(
#{id},
#{reportProject},
#{reportCity},
#{reportTime},
#{reportContent},
#{reportPersonName},
#{reportPersonTel},
#{reportPersonEmail},
#{reportSource},
#{reportStatus},
#{supplementInformant},
#{supplementTitle},
#{exchangeBeforeUser},
#{exchangeAfterUser},
#{createBy},
#{createDate},
#{updateBy},
#{updateDate},
#{oaName},
#{reportIp},
#{ipCity},
#{participants},
#{insider},
#{suggestion},
#{reportDate},
#{site},
#{qq},
#{weixin}
)
</insert>
<insert id="insertReportAttachment">
INSERT INTO ct_bbtc_report_attachment(
id,
report_id,
attachment_name,
attachment_path,
attachment_size,
attachment_type
)VALUES(
#{id},
#{reportId},
#{attachmentName},
#{attachmentPath},
#{attachmentSize},
#{attachmentType}
)
</insert>
<select id="getUser" parameterType="com.ejweb.modules.sys.entity.User" resultType="com.ejweb.modules.sys.entity.User">
SELECT u.id
FROM ct_bbtc_sys_user u
LEFT JOIN ct_bbtc_sys_user2role u2r ON u2r.user_id = u.id
LEFT JOIN ct_bbtc_sys_role r ON r.id = u2r.role_id
WHERE r.enname = 'admin' AND u.del_flag = 0
<if test="dbName == 'oracle'"> AND rownum &lt;= 1</if>
<if test="dbName == 'mysql'"> limit 1</if>
</select>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.report.dao.CtBbtcBusCategoryDao">
<sql id="ctBbtcBusCategoryColumns">
a.id AS "id",
a.number AS "number",
a.name AS "name",
a.type AS "type.id",
b.name AS "typeName",
a.ctBbtcGroup AS "ctBbtcGroup"
</sql>
<sql id="ctBbtcBusCategoryJoins">
LEFT JOIN ct_bbtc_bus_type b on b.id = a.type
</sql>
<select id="get" resultType="CtBbtcBusCategory">
SELECT
<include refid="ctBbtcBusCategoryColumns"/>
FROM ct_bbtc_bus_category a
<include refid="ctBbtcBusCategoryJoins"/>
WHERE a.id = #{id}
</select>
<select id="getByTypeId" resultType="CtBbtcBusCategory">
SELECT
<include refid="ctBbtcBusCategoryColumns"/>
FROM ct_bbtc_bus_category a
<include refid="ctBbtcBusCategoryJoins"/>
WHERE a.type = #{typeId}
</select>
<select id="findList" resultType="CtBbtcBusCategory">
SELECT
<include refid="ctBbtcBusCategoryColumns"/>
FROM ct_bbtc_bus_category a
<include refid="ctBbtcBusCategoryJoins"/>
<where>
<if test="name != null and name != ''">
AND a.name LIKE
<if test="dbName == 'oracle'">'%'||#{name}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{name}+'%'</if>
<if test="dbName == 'mysql'">concat('%',#{name},'%')</if>
</if>
</where>
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
</otherwise>
</choose>
</select>
<select id="findAllList" resultType="CtBbtcBusCategory">
SELECT
<include refid="ctBbtcBusCategoryColumns"/>
FROM ct_bbtc_bus_category a
<include refid="ctBbtcBusCategoryJoins"/>
<where>
</where>
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
</otherwise>
</choose>
</select>
<insert id="insert">
INSERT INTO ct_bbtc_bus_category(
id,
number,
name,
type,
ctBbtcGroup
) VALUES (
#{id},
#{number},
#{name},
#{type.id},
#{ctBbtcGroup}
)
</insert>
<update id="update">
UPDATE ct_bbtc_bus_category SET
number = #{number},
name = #{name},
type = #{type.id},
ctBbtcGroup=#{ctBbtcGroup}
WHERE id = #{id}
</update>
<update id="delete">
DELETE FROM ct_bbtc_bus_category
WHERE id = #{id}
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.report.dao.CtBbtcBusTypeDao">
<sql id="ctBbtcBusTypeColumns">
a.id AS "id",
a.number AS "number",
a.name AS "name",
a.supplement_group AS "group",
b.label AS "groupName"
</sql>
<sql id="ctBbtcBusTypeJoins">
LEFT JOIN ct_bbtc_sys_dict b on b.id = a.supplement_group
</sql>
<select id="get" resultType="CtBbtcBusType">
SELECT
<include refid="ctBbtcBusTypeColumns"/>
FROM ct_bbtc_bus_type a
<include refid="ctBbtcBusTypeJoins"/>
WHERE a.id = #{id}
</select>
<select id="findList" resultType="CtBbtcBusType">
SELECT
<include refid="ctBbtcBusTypeColumns"/>
FROM ct_bbtc_bus_type a
<include refid="ctBbtcBusTypeJoins"/>
<where>
<if test="name != null and name != ''">
AND a.name LIKE
<if test="dbName == 'oracle'">'%'||#{name}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{name}+'%'</if>
<if test="dbName == 'mysql'">concat('%',#{name},'%')</if>
</if>
</where>
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
</otherwise>
</choose>
</select>
<select id="getByGroupId" resultType="CtBbtcBusType">
SELECT
<include refid="ctBbtcBusTypeColumns"/>
FROM ct_bbtc_bus_type a
<include refid="ctBbtcBusTypeJoins"/>
WHERE a.supplement_group = #{groupId}
</select>
<select id="findAllList" resultType="CtBbtcBusType">
SELECT
<include refid="ctBbtcBusTypeColumns"/>
FROM ct_bbtc_bus_type a
<include refid="ctBbtcBusTypeJoins"/>
<where>
</where>
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
</otherwise>
</choose>
</select>
<insert id="insert">
INSERT INTO ct_bbtc_bus_type(
id,
number,
name,
supplement_group
) VALUES (
#{id},
#{number},
#{name},
#{group}
)
</insert>
<update id="update">
UPDATE ct_bbtc_bus_type SET
number = #{number},
name = #{name},
supplement_group = #{group}
WHERE id = #{id}
</update>
<update id="delete">
DELETE FROM ct_bbtc_bus_type
WHERE id = #{id}
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.report.dao.CtBbtcRegionDao">
<sql id="ctBbtcRegionColumns">
a.id AS "id",
a.number AS "number",
a.name AS "name",
a.supplement_group AS "group",
b.label AS "groupName"
</sql>
<sql id="ctBbtcRegionJoins">
LEFT JOIN ct_bbtc_sys_dict b on b.id = a.supplement_group
</sql>
<select id="get" resultType="CtBbtcRegion">
SELECT
<include refid="ctBbtcRegionColumns"/>
FROM ct_bbtc_region a
<include refid="ctBbtcRegionJoins"/>
WHERE a.id = #{id}
</select>
<select id="getByGroupId" resultType="CtBbtcRegion">
SELECT
<include refid="ctBbtcRegionColumns"/>
FROM ct_bbtc_region a
<include refid="ctBbtcRegionJoins"/>
WHERE a.supplement_group = #{groupId}
</select>
<select id="findList" resultType="CtBbtcRegion">
SELECT
<include refid="ctBbtcRegionColumns"/>
FROM ct_bbtc_region a
<include refid="ctBbtcRegionJoins"/>
<where>
<if test="name != null and name != ''">
AND a.name LIKE
<if test="dbName == 'oracle'">'%'||#{name}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{name}+'%'</if>
<if test="dbName == 'mysql'">concat('%',#{name},'%')</if>
</if>
</where>
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
</otherwise>
</choose>
</select>
<select id="findAllList" resultType="CtBbtcRegion">
SELECT
<include refid="ctBbtcRegionColumns"/>
FROM ct_bbtc_region a
<include refid="ctBbtcRegionJoins"/>
<where>
</where>
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
</otherwise>
</choose>
</select>
<insert id="insert">
INSERT INTO ct_bbtc_region(
id,
number,
name,
supplement_group
) VALUES (
#{id},
#{number},
#{name},
#{group}
)
</insert>
<update id="update">
UPDATE ct_bbtc_region SET
number = #{number},
name = #{name},
supplement_group = #{group}
WHERE id = #{id}
</update>
<update id="delete">
DELETE FROM ct_bbtc_region
WHERE id = #{id}
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.report.dao.ReportDao">
<sql id="reportColumns">
r.id AS "id",
r.report_project AS "reportProject",
r.report_city AS "reportCity",
r.report_time AS "reportTime",
r.report_content AS "reportContent",
r.report_person_name AS "reportPersonName",
r.report_person_tel AS "reportPersonTel",
r.report_person_email AS "reportPersonEmail",
r.report_source AS "reportSource",
r.report_status AS "reportStatus",
r.supplement_company AS "supplementCompany",
r.supplement_department AS "supplementDepartment",
r.supplement_informant AS "supplementInformant",
r.supplement_title AS "supplementTitle",
/*r.supplement_type AS "supplementType",*/
ct.name AS "transferDepartment",
r.transferGroup AS "transferGroup",
/*r.supplement_area AS "supplementArea",*/
r.supplement_project AS "supplementProject",
r.supplement_content AS "supplementContent",
r.deal_person_name AS "dealPersonName",
r.deal_result AS "dealResult",
r.exchange_before_user AS "exchangeBeforeUser",
r.exchange_after_user AS "exchangeAfterUser",
r.exchange_type AS "exchangeType",
r.create_by AS "createBy",
r.create_date AS "createDate",
r.update_by AS "updateBy",
r.update_date AS "updateDate",
r.oa_name AS "oaname",
r.report_ip AS "reportIp",
r.ip_city AS "ipCity",
r.is_send_email AS "isSendEmail",
su.area AS "oaarea",
r.report_participants AS "participants",
r.report_insider AS "insider",
r.report_suggestion AS "suggestion",
r.report_Date AS "reportDate",
r.report_site AS "site",
r.report_qq AS "qq",
r.report_weixin AS "weixin",
r.report_ifClue AS "ifClue" ,
r.supplement_group AS "supplementGroup",
r.supplement_category AS "supplementCategory",
r.supplement_type AS "supplementType"
</sql>
<sql id="reportJoins">
LEFT JOIN ct_bbtc_report_attachment ra ON r.id = ra.report_id
</sql>
<select id="get" parameterType="ReportEntity" resultType="ReportEntity">
SELECT
<include refid="reportColumns"/>
,su.name AS "transferName"
,cr.name AS "supplementArea"
FROM ct_bbtc_report r
LEFT JOIN ct_bbtc_sys_user su ON r.exchange_after_user = su.id
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
/* LEFT JOIN ct_bbtc_bus_type CT
ON R.supplement_group = CT.supplement_group
LEFT JOIN ct_bbtc_bus_category CC
ON R.supplement_type = CC.type*/
WHERE r.id = #{id}
</select>
<select id="findList" parameterType="ReportEntity" resultType="ReportEntity">
SELECT
<include refid="reportColumns"/>
,su.name AS "transferName"
,cr.name AS "supplementArea"
FROM CT_BBTC_REPORT R
LEFT JOIN CT_BBTC_SYS_USER SU
ON R.create_by = SU.ID
LEFT JOIN CT_BBTC_SYS_USER2ROLE UR
ON UR.USER_ID = SU.ID
LEFT JOIN CT_BBTC_SYS_ROLE RL
ON RL.ID = UR.ROLE_ID
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
<where>
1 = 1
<if test="isAdmin == null and isFzAdmin == null">
AND r.exchange_after_user = #{exchangeAfterUser} AND r.create_by != #{exchangeAfterUser}
</if>
<if test="isAdmin != null">
AND (su.role_id='1'or su.role_id='2')
</if>
<if test="isFzAdmin != null">
AND ((R.EXCHANGE_BEFORE_USER = #{exchangeBeforeUser} OR
R.EXCHANGE_AFTER_USER = #{exchangeBeforeUser}
OR R.CREATE_BY = #{exchangeBeforeUser})) AND SU.AREA IS NULL
</if>
<if test="reportStatus != null and reportStatus != ''">
AND r.report_status = #{reportStatus}
</if>
<if test="supplementTitle != null and supplementTitle != ''">
AND r.supplement_title LIKE
<if test="dbName == 'oracle'">'%'||#{supplementTitle}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementTitle}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementTitle}, '%')</if>
</if>
<if test="reportProject != null and reportProject != ''">
AND (r.report_project LIKE
<if test="dbName == 'oracle'">'%'||#{reportProject}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportProject}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportProject}, '%')</if>
OR r.supplement_department LIKE
<if test="dbName == 'oracle'">'%'||#{reportProject}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportProject}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportProject}, '%')</if>
)
</if>
<if test="reportTimeFrom != null and reportTimeFrom != ''">
AND r.report_time &gt;= #{reportTimeFrom}
</if>
<if test="reportTimeTo != null and reportTimeTo != ''">
AND r.report_time &lt;= #{reportTimeTo}|| ' 23:59:59'
</if>
<if test="reportPersonName != null and reportPersonName != ''">
AND r.report_person_name LIKE
<if test="dbName == 'oracle'">'%'||#{reportPersonName}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportPersonName}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportPersonName}, '%')</if>
</if>
<if test="reportPersonTel != null and reportPersonTel != ''">
AND r.report_person_tel LIKE
<if test="dbName == 'oracle'">'%'||#{reportPersonTel}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportPersonTel}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportPersonTel}, '%')</if>
</if>
<if test="supplementType != null and supplementType != ''">
AND r.supplement_type LIKE
<if test="dbName == 'oracle'">'%'||#{supplementType}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementType}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementType}, '%')</if>
</if>
<if test="dealResult != null and dealResult != ''">
AND r.deal_result = #{dealResult}
</if>
<if test="supplementInformant != null and supplementInformant != ''">
AND r.supplement_informant LIKE
<if test="dbName == 'oracle'">'%'||#{supplementInformant}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementInformant}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementInformant}, '%')</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="supplementArea != null and supplementArea != ''">
AND r.supplement_area = #{supplementArea}
</if>
<if test="supplementCategory != null and supplementCategory != ''">
AND r.supplement_category LIKE
<if test="dbName == 'oracle'">'%'||#{supplementCategory}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementCategory}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementCategory}, '%')</if>
</if>
<if test="transferGroup != null and transferGroup != ''">
AND r.transferGroup = #{transferGroup}
</if>
<if test="transferDepartment != null and transferDepartment != ''">
AND r.transfer_department LIKE
<if test="dbName == 'oracle'">'%'||#{transferDepartment}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{transferDepartment}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{transferDepartment}, '%')</if>
</if>
<if test="reportSource != null and reportSource != ''">
AND r.report_source = #{reportSource}
</if>
<if test="selectExchangeAfterUser != null and selectExchangeAfterUser != ''">
AND r.exchange_after_user = #{selectExchangeAfterUser}
</if>
<if test="oaname != null and oaname != ''">
AND r.oa_name = #{oaname}
</if>
<choose>
<when test="flage != null and flage != ''">
AND r.deal_result = 7
</when>
<otherwise>
AND ( r.deal_result != 7 OR r.deal_result IS NULL )
</otherwise>
</choose>
</where>
ORDER BY r.update_date DESC
</select>
<select id="findListByCheck" parameterType="ReportEntity" resultType="ReportEntity">
SELECT
<include refid="reportColumns"/>
,su.name AS "transferName"
,cr.name AS "supplementArea"
FROM CT_BBTC_REPORT R
LEFT JOIN CT_BBTC_SYS_USER SU
ON R.CREATE_BY = SU.ID
LEFT JOIN CT_BBTC_SYS_USER2ROLE UR
ON UR.USER_ID = SU.ID
LEFT JOIN CT_BBTC_SYS_ROLE RL
ON RL.ID = UR.ROLE_ID
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
<where>
1 = 1
<if test="supplementType != null and supplementType != ''">
AND r.supplement_type LIKE
<if test="dbName == 'oracle'">'%'||#{supplementType}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementType}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementType}, '%')</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="supplementArea != null and supplementArea != ''">
AND r.supplement_area = #{supplementArea}
</if>
<if test="supplementCategory != null and supplementCategory != ''">
AND r.supplement_category LIKE
<if test="dbName == 'oracle'">'%'||#{supplementCategory}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementCategory}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementCategory}, '%')</if>
</if>
<if test="transferGroup != null and transferGroup != ''">
AND r.transferGroup = #{transferGroup}
</if>
<if test="transferDepartment != null and transferDepartment != ''">
AND r.transfer_department LIKE
<if test="dbName == 'oracle'">'%'||#{transferDepartment}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{transferDepartment}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{transferDepartment}, '%')</if>
</if>
</where>
</select>
<select id="findQyList" parameterType="ReportEntity" resultType="ReportEntity">
SELECT
<include refid="reportColumns"/>
,su.name AS "transferName"
,cr.name AS "supplementArea"
FROM ct_bbtc_report r
LEFT JOIN ct_bbtc_sys_user su ON r.create_by = su.id
LEFT JOIN CT_BBTC_SYS_USER2ROLE UR ON UR.USER_ID = su.ID
LEFT JOIN CT_BBTC_SYS_ROLE RL
ON RL.ID = UR.ROLE_ID
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
/* LEFT JOIN ct_bbtc_bus_type CT
ON R.supplement_group = CT.supplement_group
LEFT JOIN ct_bbtc_bus_category CC
ON R.supplement_type = CC.type*/
<where>
1 = 1
<if test="isAdmin == null and isFzAdmin == null">
AND r.exchange_after_user = #{exchangeAfterUser} AND r.create_by = #{exchangeAfterUser}
</if>
<if test="isAdmin != null">
AND su.area IN ('North China',
'BeiJing',
'ShangHai',
'SouthWest',
'SouthEast',
'Central China',
'GuangShen',
'Hainan',
'Group',
'PropertyGroup')
</if>
<if test="isFzAdmin != null">
AND r.Exchange_After_User = #{exchangeBeforeUser}
AND r.create_by != #{exchangeBeforeUser}
AND su.area IN ('North China',
'BeiJing',
'ShangHai',
'SouthWest',
'SouthEast',
'Central China',
'GuangShen',
'Hainan',
'Group',
'PropertyGroup')
</if>
<if test="reportStatus != null and reportStatus != ''">
AND r.report_status = #{reportStatus}
</if>
<if test="supplementTitle != null and supplementTitle != ''">
AND r.supplement_title LIKE
<if test="dbName == 'oracle'">'%'||#{supplementTitle}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementTitle}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementTitle}, '%')</if>
</if>
<if test="reportProject != null and reportProject != ''">
AND (r.report_project LIKE
<if test="dbName == 'oracle'">'%'||#{reportProject}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportProject}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportProject}, '%')</if>
OR r.supplement_department LIKE
<if test="dbName == 'oracle'">'%'||#{reportProject}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportProject}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportProject}, '%')</if>
)
</if>
<if test="reportTimeFrom != null and reportTimeFrom != ''">
AND r.report_time &gt;= #{reportTimeFrom}
</if>
<if test="reportTimeTo != null and reportTimeTo != ''">
AND r.report_time &lt;= #{reportTimeTo}|| ' 23:59:59'
</if>
<if test="reportPersonName != null and reportPersonName != ''">
AND r.report_person_name LIKE
<if test="dbName == 'oracle'">'%'||#{reportPersonName}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportPersonName}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportPersonName}, '%')</if>
</if>
<if test="reportPersonTel != null and reportPersonTel != ''">
AND r.report_person_tel LIKE
<if test="dbName == 'oracle'">'%'||#{reportPersonTel}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{reportPersonTel}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{reportPersonTel}, '%')</if>
</if>
<if test="supplementType != null and supplementType != ''">
AND r.supplement_type LIKE
<if test="dbName == 'oracle'">'%'||#{supplementType}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementType}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementType}, '%')</if>
</if>
<if test="dealResult != null and dealResult != ''">
AND r.deal_result = #{dealResult}
</if>
<if test="supplementInformant != null and supplementInformant != ''">
AND r.supplement_informant LIKE
<if test="dbName == 'oracle'">'%'||#{supplementInformant}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementInformant}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementInformant}, '%')</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="supplementArea != null and supplementArea != ''">
AND r.supplement_area = #{supplementArea}
</if>
<if test="supplementCategory != null and supplementCategory != ''">
AND r.supplement_category = #{supplementCategory}
</if>
<if test="supplementCategory != null and supplementCategory != ''">
AND r.supplement_category LIKE
<if test="dbName == 'oracle'">'%'||#{supplementCategory}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{supplementCategory}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{supplementCategory}, '%')</if>
</if>
<if test="transferGroup != null and transferGroup != ''">
AND r.transferGroup = #{transferGroup}
</if>
<if test="transferDepartment != null and transferDepartment != ''">
AND r.transfer_department LIKE
<if test="dbName == 'oracle'">'%'||#{transferDepartment}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{transferDepartment}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{transferDepartment}, '%')</if>
</if>
<if test="reportSource != null and reportSource != ''">
AND r.report_source = #{reportSource}
</if>
<if test="selectExchangeAfterUser != null and selectExchangeAfterUser != ''">
AND r.exchange_after_user = #{selectExchangeAfterUser}
</if>
<if test="oaname != null and oaname != ''">
AND r.oa_name = #{oaname}
</if>
<choose>
<when test="flage != null and flage != ''">
AND r.deal_result = 7
</when>
<otherwise>
AND ( r.deal_result != 7 OR r.deal_result IS NULL )
</otherwise>
</choose>
</where>
ORDER BY r.update_date DESC
</select>
<select id="findAllList" parameterType="ReportEntity" resultType="ReportEntity">
SELECT
<include refid="reportColumns"/>
,cr.name AS "supplementArea"
FROM ct_bbtc_report r
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
/* LEFT JOIN ct_bbtc_bus_type CT
ON R.supplement_group = CT.supplement_group
LEFT JOIN ct_bbtc_bus_category CC
ON R.supplement_type = CC.type*/
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
ORDER BY r.update_date DESC
</otherwise>
</choose>
</select>
<select id="findRole" parameterType="User" resultType="String">
SELECT
sr.name AS "roleName"
FROM ct_bbtc_sys_role sr
LEFT JOIN ct_bbtc_sys_user2role sur ON sr.id = sur.role_id
LEFT JOIN ct_bbtc_sys_user su ON su.id = sur.user_id
WHERE su.id = #{id}
</select>
<select id="getAttachmentInfo" resultType="ReportAttachmentEntity">
SELECT
ra.attachment_name,
ra.attachment_path
FROM ct_bbtc_report_attachment ra
WHERE ra.report_id = #{reportId}
AND ra.attachment_type = #{attachmentType}
</select>
<insert id="addReport">
INSERT INTO ct_bbtc_report(
id,
report_project,
report_city,
report_time,
report_content,
report_person_name,
report_person_tel,
report_person_email,
report_source,
report_status,
supplement_informant,
supplement_title,
exchange_before_user,
exchange_after_user ,
exchange_type,
create_by,
create_date,
update_by,
update_date,
oa_name,
report_ip,
ip_city,
report_participants,
report_insider,
report_suggestion,
report_Date,
report_site,
report_qq,
report_weixin
) VALUES (
#{id},
#{reportProject},
#{reportCity},
#{reportTime},
#{reportContent},
#{reportPersonName},
#{reportPersonTel},
#{reportPersonEmail},
#{reportSource},
#{reportStatus},
#{supplementInformant},
#{supplementTitle},
#{exchangeBeforeUser},
#{exchangeAfterUser},
#{exchangeType},
#{createBy.id},
#{createDate},
#{updateBy.id},
#{updateDate},
#{oaname},
#{reportIp},
#{ipCity},
#{participants},
#{insider},
#{suggestion},
#{reportDate},
#{site},
#{qq},
#{weixin}
)
</insert>
<insert id="addReportAttachment">
INSERT INTO ct_bbtc_report_attachment(
id,
report_id,
attachment_name,
attachment_path,
attachment_size,
attachment_type
) VALUES (
#{id},
#{reportId},
#{attachmentName},
#{attachmentPath},
#{attachmentSize},
#{attachmentType}
)
</insert>
<update id="addTrack">
UPDATE ct_bbtc_report SET
supplement_informant = #{supplementInformant},
supplement_type = #{supplementType},
transferGroup=#{transferGroup},
transfer_department=#{transferDepartment},
supplement_area = #{supplementArea},
supplement_project = #{supplementProject},
supplement_content = #{supplementContent},
deal_person_name = #{dealPersonName},
exchange_before_user = #{exchangeBeforeUser},
exchange_after_user = #{exchangeAfterUser},
exchange_type = #{exchangeType},
report_ifClue = #{ifClue},
deal_result = #{dealResult},
update_by = #{updateBy.id},
update_date = #{updateDate},
supplement_group=#{supplementGroup},
supplement_category=#{supplementCategory}
<if test="transTime != null ">
,transTime=#{transTime}
</if>
WHERE id = #{id}
</update>
<update id="updateReportStatus">
UPDATE ct_bbtc_report SET
report_status = #{reportStatus}
WHERE id = #{id}
</update>
<select id="findUser" parameterType="User" resultType="User">
SELECT
su.id AS "id",
su.no AS "no",
su.name AS "name",
su.login_name AS "loginName",
su.mobile AS "mobile",
so1.name AS "company.name",
so2.name AS "office.name",
sp.position_name AS "position.name",
sr.name AS "role.name",
<if test="dbName == 'oracle'">NVL (sac. NAME, NULL) || '-' || NVL (sao. NAME, NULL) AS "devision"</if>
<if test="dbName == 'mysql'">CONCAT(IFNULL(sac.name,""),"-",IFNULL(sao.name,"")) AS "devision"</if>
FROM
ct_bbtc_sys_user su
LEFT JOIN ct_bbtc_sys_office so1 ON so1.id = su.company_id
LEFT JOIN ct_bbtc_sys_office so2 ON so2.id = su.office_id
LEFT JOIN ct_bbtc_sys_user2position sup ON sup.user_id = su.id
LEFT JOIN ct_bbtc_sys_position sp ON sp.id = sup.position_id
LEFT JOIN ct_bbtc_sys_user2role sur ON su.id = sur.user_id
LEFT JOIN ct_bbtc_sys_role sr ON sr.id = sur.role_id
LEFT JOIN ct_bbtc_sys_area sac ON sac.id = so1.area_id
LEFT JOIN ct_bbtc_sys_area sao ON sao.id = so2.area_id
<where>
1 = 1 AND su.del_flag = 0
<if test="no != null and no != ''">
AND su.no LIKE
<if test="dbName == 'oracle'">'%'||#{no}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{no}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{no}, '%')</if>
</if>
<if test="name != null and name != ''">
AND su.name LIKE
<if test="dbName == 'oracle'">'%'||#{name}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{name}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{name}, '%')</if>
</if>
<if test="mobile != null and mobile != ''">
AND su.mobile LIKE
<if test="dbName == 'oracle'">'%'||#{mobile}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{mobile}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{mobile}, '%')</if>
</if>
<if test="company != null and company.id != null and company.id != ''">
AND so1.id = #{company.id}
</if>
<if test="office != null and office.id != null and office.id != ''">
AND so2.id = #{office.id}
</if>
<if test="position != null and position.name != null and position.name != ''">
AND sp.position_name = #{position.name}
</if>
<if test="loginName != null and loginName != ''">
AND su.login_name LIKE
<if test="dbName == 'oracle'">'%'||#{loginName}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{loginName}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{loginName}, '%')</if>
</if>
</where>
ORDER BY su.update_date DESC
</select>
<select id="getOfficeList" parameterType="Office" resultType="Office">
SELECT
so.id AS "id",
<if test="dbName == 'oracle'">so.name||'('||(SELECT s.name FROM ct_bbtc_sys_office s WHERE s.id =
so.parent_id)||')' AS "name"
</if>
<if test="dbName == 'mysql'">CONCAT(so.name,'(',(SELECT s.name FROM ct_bbtc_sys_office s WHERE s.id =
so.parent_id),')') AS "name"
</if>
FROM ct_bbtc_sys_office so
WHERE so.type = '2'
</select>
<select id="getCompanyList" resultType="Office">
SELECT
so.id AS "id",
so.name AS "name"
FROM ct_bbtc_sys_office so
WHERE so.type = '1'
</select>
<select id="getPositionList" resultType="Position">
SELECT
position_code AS "id",
position_name AS "positionName"
FROM ct_bbtc_sys_position
</select>
<insert id="addReportNotice">
INSERT INTO ct_bbtc_report_notice(
id,
report_id,
title,
send_time,
send_from_id,
send_to_id,
status,
create_by,
create_date,
update_by,
update_date
) VALUES (
#{id},
#{reportId},
#{title},
#{sendTime},
#{sendFromId},
#{sendToId},
#{status},
#{createBy},
#{createDate},
#{updateBy},
#{updateDate}
)
</insert>
<update id="updateReportNotice">
UPDATE ct_bbtc_report_notice SET
id = #{id},
report_id = #{reportId},
title = #{title},
send_time = #{sendTime},
send_from_id = #{sendFromId},
send_to_id = #{sendToId},
status = #{status},
create_by = #{createBy},
create_date = #{createDate},
update_by = #{updateBy},
update_date = #{updateDate}
WHERE report_id = #{reportId}
</update>
<select id="findReportNotice" resultType="com.ejweb.modules.workbench.entity.ReportNotice">
SELECT * FROM ct_bbtc_report_notice rn
LEFT JOIN ct_bbtc_report r ON rn.report_id = r.id
WHERE rn.report_id = #{id}
AND r.exchange_type = #{exchangeType}
</select>
<select id="findAdmin" parameterType="Office" resultType="String">
SELECT
su.id
FROM
ct_bbtc_sys_user su
LEFT JOIN ct_bbtc_sys_user2role sur ON su.id = sur.user_id
LEFT JOIN ct_bbtc_sys_role sr ON sr.id = sur.role_id
WHERE
sr.name = '系统管理员'
AND SU.DEL_FLAG = '0'
</select>
<insert id="addRecord">
INSERT INTO ct_bbtc_report_exchange_his(
id,
report_id,
old_user_id,
new_user_id,
exchange_type,
exchange_time
) VALUES (
#{id},
#{reportId},
#{oldUserId},
#{newUserId},
#{exchangeType},
#{exchangeTime}
)
</insert>
<select id="getReportStatus" parameterType="com.ejweb.modules.workbench.Bean.WorkbenchBean"
resultType="java.util.HashMap">
select REPORT_STATUS,COUNT(REPORT_STATUS)
FROM ct_bbtc_report r
/* LEFT JOIN ct_bbtc_region CR
ON R.supplement_group = CR.supplement_group*/
WHERE 1=1
<if test="isAdmin != null">
AND exchange_after_user = #{isAdmin}
</if>
<if test="startDate != null">
<if test="dbName == 'oracle'">AND create_date >= to_date(#{startDate}, 'yyyy-MM-dd')</if>
<if test="dbName == 'mysql'">AND DATE(create_date) >= #{startDate}</if>
</if>
<if test="endDate != null">
<if test="dbName == 'oracle'">AND create_date &lt;= to_date( #{endDate}|| ' 23:59:59', 'yyyy-MM-dd
hh24:mi:ss')
</if>
<if test="dbName == 'mysql'">AND DATE(create_date) &lt;= #{endDate}</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="area != null and area !=''">
AND r.supplement_area=#{area}
</if>
GROUP BY report_status
</select>
<select id="getReportResult" parameterType="com.ejweb.modules.workbench.Bean.WorkbenchBean"
resultType="java.util.HashMap">
select DEAL_RESULT,COUNT(DEAL_RESULT)
FROM ct_bbtc_report r
/* LEFT JOIN ct_bbtc_region CR
ON R.supplement_group = CR.supplement_group*/
WHERE 1 = 1
<if test="isAdmin != null">
AND exchange_after_user = #{isAdmin}
</if>
<if test="startDate != null">
<if test="dbName == 'oracle'">AND create_date >= to_date(#{startDate}, 'yyyy-MM-dd')</if>
<if test="dbName == 'mysql'">AND DATE(create_date) >= #{startDate}</if>
</if>
<if test="endDate != null">
<if test="dbName == 'oracle'">AND create_date &lt;= to_date( #{endDate}|| ' 23:59:59', 'yyyy-MM-dd
hh24:mi:ss')
</if>
<if test="dbName == 'mysql'">AND DATE(create_date) &lt;= #{endDate}</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="area != null and area !=''">
AND r.supplement_area=#{area}
</if>
GROUP BY deal_result
</select>
<select id="getTotal" parameterType="com.ejweb.modules.workbench.Bean.WorkbenchBean" resultType="java.util.HashMap">
select report_source,COUNT(report_source)
FROM ct_bbtc_report r
/* LEFT JOIN ct_bbtc_region CR
ON R.supplement_group = CR.supplement_group*/
WHERE 1=1
<if test="isAdmin != null">
AND exchange_after_user = #{isAdmin}
</if>
<if test="startDate != null">
<if test="dbName == 'oracle'">AND create_date >= to_date(#{startDate}, 'yyyy-MM-dd')</if>
<if test="dbName == 'mysql'">AND DATE(create_date) >= #{startDate}</if>
</if>
<if test="endDate != null">
<if test="dbName == 'oracle'">AND create_date &lt;= to_date( #{endDate}|| ' 23:59:59', 'yyyy-MM-dd
hh24:mi:ss')
</if>
<if test="dbName == 'mysql'">AND DATE(create_date) &lt;= #{endDate}</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="area != null and area !=''">
AND r.supplement_area=#{area}
</if>
GROUP BY report_source
</select>
<select id="getReportType" parameterType="com.ejweb.modules.workbench.Bean.WorkbenchBean"
resultType="java.util.HashMap">
SELECT
SUM(CASE WHEN supplement_type||',' LIKE '1,%' OR supplement_type||',' LIKE '%,1,%' THEN 1 ELSE 0 END) AS
"sale",
SUM(CASE WHEN supplement_type||',' LIKE '2,%' OR supplement_type||',' LIKE '%,2,%' THEN 1 ELSE 0 END) AS
"project",
SUM(CASE WHEN supplement_type||',' LIKE '3,%' OR supplement_type||',' LIKE '%,3,%' THEN 1 ELSE 0 END) AS
"cost",
SUM(CASE WHEN supplement_type||',' LIKE '4,%' OR supplement_type||',' LIKE '%,4,%' THEN 1 ELSE 0 END) AS
"forMining",
SUM(CASE WHEN supplement_type||',' LIKE '5,%' OR supplement_type||',' LIKE '%,5,%' THEN 1 ELSE 0 END) AS
"finance",
SUM(CASE WHEN supplement_type||',' LIKE '6,%' OR supplement_type||',' LIKE '%,6,%' THEN 1 ELSE 0 END) AS
"forensic",
SUM(CASE WHEN supplement_type||',' LIKE '7,%' OR supplement_type||',' LIKE '%,7,%' THEN 1 ELSE 0 END) AS
"administration",
SUM(CASE WHEN supplement_type||',' LIKE '8,%' OR supplement_type||',' LIKE '%,8,%' THEN 1 ELSE 0 END) AS
"manpower",
SUM(CASE WHEN supplement_type||',' LIKE '9,%' OR supplement_type||',' LIKE '%,9,%' THEN 1 ELSE 0 END) AS
"development",
SUM(CASE WHEN supplement_type||',' LIKE '10,%' OR supplement_type||',' LIKE '%,10,%' THEN 1 ELSE 0 END) AS
"rAndD",
SUM(CASE WHEN supplement_type||',' LIKE '11,%' OR supplement_type||',' LIKE '%,11,%' THEN 1 ELSE 0 END) AS
"iAndD",
SUM(CASE WHEN supplement_type||',' LIKE '12,%' OR supplement_type||',' LIKE '%,12,%' THEN 1 ELSE 0 END) AS
"Other",
SUM(CASE WHEN supplement_type||',' LIKE '13,%' OR supplement_type||',' LIKE '%,13,%' THEN 1 ELSE 0 END) AS
"propertyManagement",
SUM(CASE WHEN supplement_type||',' LIKE '14,%' OR supplement_type||',' LIKE '%,14,%' THEN 1 ELSE 0 END) AS
"hotelManagement",
SUM(CASE WHEN supplement_type||',' LIKE '15,%' OR supplement_type||',' LIKE '%,15,%' THEN 1 ELSE 0 END) AS
"businessManagement"
FROM ct_bbtc_report r
/* LEFT JOIN ct_bbtc_region CR
ON R.supplement_group = CR.supplement_group*/
WHERE 1=1
<if test="isAdmin != null">
AND exchange_after_user = #{isAdmin}
</if>
<if test="startDate != null">
<if test="dbName == 'oracle'">AND create_date >= to_date(#{startDate}, 'yyyy-MM-dd')</if>
<if test="dbName == 'mysql'">AND DATE(create_date) >= #{startDate}</if>
</if>
<if test="endDate != null">
<if test="dbName == 'oracle'">AND create_date &lt;= to_date( #{endDate}|| ' 23:59:59', 'yyyy-MM-dd
hh24:mi:ss')
</if>
<if test="dbName == 'mysql'">AND DATE(create_date) &lt;= #{endDate}</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="area != null and area !=''">
AND r.supplement_area=#{area}
</if>
</select>
<select id="getRepList" parameterType="com.ejweb.modules.workbench.Bean.WorkbenchBean" resultType="com.ejweb.modules.report.entity.ReportEntity">
SELECT * FROM(
SELECT
r.id AS "id",
r.report_project AS "reportProject",
r.report_city AS "reportCity",
r.report_time AS "reportTime",
r.report_content AS "reportContent",
r.report_person_name AS "reportPersonName",
r.report_person_tel AS "reportPersonTel",
r.report_person_email AS "reportPersonEmail",
r.report_source AS "reportSource",
r.report_status AS "reportStatus",
r.supplement_company AS "supplementCompany",
r.supplement_department AS "supplementDepartment",
r.supplement_informant AS "supplementInformant",
r.supplement_title AS "supplementTitle",
r.supplement_type AS "supplementType",
r.supplement_group AS "supplementGroup",
r.supplement_category AS "supplementCategory",
r.supplement_project AS "supplementProject",
r.supplement_content AS "supplementContent",
r.deal_person_name AS "dealPersonName",
r.deal_result AS "dealResult",
r.exchange_before_user AS "exchangeBeforeUser",
r.exchange_after_user AS "exchangeAfterUser",
r.exchange_type AS "exchangeType",
r.create_by AS "createBy",
r.create_date AS "createDate",
r.update_by AS "updateBy",
r.update_date AS "updateDate"
,cr.name AS "supplementArea"
FROM ct_bbtc_report r
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
<where>
r.report_status = #{processStatus}
<if test="isAdmin != null">
AND r.exchange_after_user = #{isAdmin}
</if>
<if test="startDate != null">
<if test="dbName == 'oracle'">AND create_date >= to_date(#{startDate}, 'yyyy-MM-dd')</if>
<if test="dbName == 'mysql'">AND DATE(create_date) >= #{startDate}</if>
</if>
<if test="endDate != null">
<if test="dbName == 'oracle'">AND create_date &lt;= to_date( #{endDate}|| ' 23:59:59', 'yyyy-MM-dd
hh24:mi:ss')
</if>
<if test="dbName == 'mysql'">AND DATE(create_date) &lt;= #{endDate}</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="area != null and area !=''">
AND r.supplement_area=#{area}
</if>
</where>
order by r.create_date desc
) AS W
<if test="dbName == 'oracle'">rownum &lt;= 10</if>
<if test="dbName == 'mysql'">limit 0,10</if>
</select>
<select id="getChooseReportList" parameterType="com.ejweb.modules.report.entity.ReportEntity"
resultType="com.ejweb.modules.report.entity.ReportEntity">
SELECT
r.id AS "id",
r.report_project AS "reportProject",
r.report_time AS "reportTime",
r.report_person_name AS "reportPersonName",
r.report_person_tel AS "reportPersonTel",
r.report_status AS "reportStatus",
r.supplement_title AS "supplementTitle",
r.supplement_type AS "supplementType",
r.supplement_group AS "supplementGroup",
r.supplement_category AS "supplementCategory",
r.supplement_department AS "supplementDepartment",
r.supplement_informant AS "supplementInformant",
r.deal_person_name AS "dealPersonName",
r.deal_result AS "dealResult",
r.exchange_type AS "exchangeType",
su.name AS "transferName"
,cr.name AS "supplementArea"
FROM ct_bbtc_report r
LEFT JOIN ct_bbtc_sys_user su ON r.exchange_after_user = su.id
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
<where>
1 = 1
<if test="exchangeAfterUser != null and exchangeAfterUser != ''">
AND r.exchange_after_user = #{exchangeAfterUser}
</if>
<!-- <if test="dealPersonName != null and dealPersonName != ''">
AND r.deal_person_name LIKE
'%${dealPersonName}%'
/* CONCAT('%', #{dealPersonName}, '%')*/
'%'#{dealPersonName}'%'
</if>-->
<if test="dealPersonName != null and dealPersonName != ''">
AND r.deal_person_name LIKE
<if test="dbName == 'oracle'">'%'||#{dealPersonName}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{dealPersonName}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{dealPersonName}, '%')</if>
</if>
</where>
ORDER BY r.update_date DESC
</select>
<update id="updateExchangeUser">
UPDATE ct_bbtc_report SET
exchange_after_user = #{exchangeAfterUser},
exchange_type = #{exchangeType},
update_by = #{updateBy.id},
update_date = #{updateDate}
WHERE id = #{id}
</update>
<select id="findExchangeUser" resultType="String">
SELECT c.EXCHANGE_AFTER_USER FROM CT_BBTC_REPORT c WHERE c.ID = #{id}
</select>
<update id="updateIsSendEmail">
UPDATE ct_bbtc_report SET
is_send_email = '1'
WHERE id = #{reportId}
</update>
<update id="updateConclusion">
UPDATE ct_bbtc_report SET
report_status= '3',
deal_result = #{dealResult},
<if test="transferDepartment =='6'">
transfer_department = #{transferDepartment}
</if>
<if test="transferDepartment !='6'">
transfer_department = ''
</if>
WHERE id = #{id}
</update>
<update id="againUpdateConclusion">
UPDATE ct_bbtc_report SET
report_status= '1'
WHERE id = #{id}
</update>
<update id="cluesUpdateConclusion">
UPDATE ct_bbtc_report SET
report_status= '4'
WHERE id = #{id}
</update>
<select id="getTotalNum" parameterType="com.ejweb.modules.workbench.Bean.WorkbenchBean" resultType="Integer">
SELECT count(*) AS "totalCount"
FROM ct_bbtc_report r
LEFT JOIN ct_bbtc_region CR
ON r.supplement_area = CR.id
LEFT JOIN ct_bbtc_bus_type CT
ON r.transfer_department = CT.id
WHERE 1 = 1
<if test="isAdmin != null">
AND exchange_after_user = #{isAdmin}
</if>
<if test="startDate != null">
<if test="dbName == 'oracle'">AND create_date >= to_date(#{startDate}, 'yyyy-MM-dd')</if>
<if test="dbName == 'mysql'">AND DATE(create_date) >= #{startDate}</if>
</if>
<if test="endDate != null">
<if test="dbName == 'oracle'">AND create_date &lt;= to_date( #{endDate}|| ' 23:59:59', 'yyyy-MM-dd
hh24:mi:ss')
</if>
<if test="dbName == 'mysql'">AND DATE(create_date) &lt;= #{endDate}</if>
</if>
<if test="supplementGroup != null and supplementGroup != ''">
AND r.supplement_group = #{supplementGroup}
</if>
<if test="area != null and area !=''">
AND r.supplement_area=#{area}
</if>
</select>
<delete id="deleteConclusion">
delete from ct_bbtc_report
where id = #{id}
</delete>
<delete id="deleteNotice">
delete from CT_BBTC_REPORT_NOTICE
where report_id = #{id}
</delete>
<select id="selectExchangeAfterUser" parameterType="ReportEntity" resultType="String">
SELECT
su.name
FROM
ct_bbtc_sys_user su
WHERE
su.id=#{report}
</select>
<select id="findAllUserList" resultType="User">
SELECT id AS ID,
id AS value,
name AS label
from ct_bbtc_sys_user
where del_flag = 0
</select>
<update id="updateReportByClueTime" parameterType="ReportEntity" >
UPDATE ct_bbtc_report SET
report_status= '3',
deal_result='2'
WHERE where day(transTime) = day(#{transTime}) /* 比较日期数相同就行 */
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="com.ejweb.modules.reportAttachment.dao.ReportAttachmentMapper" >
<resultMap id="BaseResultMap" type="com.ejweb.modules.reportAttachment.entity.ReportAttachment" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="report_id" property="reportId" jdbcType="VARCHAR" />
<result column="attachment_name" property="attachmentName" jdbcType="VARCHAR" />
<result column="attachment_path" property="attachmentPath" jdbcType="VARCHAR" />
<result column="attachment_size" property="attachmentSize" jdbcType="INTEGER" />
<result column="attachment_type" property="attachmentType" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, report_id, attachment_name, attachment_path, attachment_size, attachment_type
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from ct_bbtc_report_attachment
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from ct_bbtc_report_attachment
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.ejweb.modules.reportAttachment.entity.ReportAttachment" >
insert into ct_bbtc_report_attachment (id, report_id, attachment_name,
attachment_path, attachment_size, attachment_type
)
values (#{id,jdbcType=VARCHAR}, #{reportId,jdbcType=VARCHAR}, #{attachmentName,jdbcType=VARCHAR},
#{attachmentPath,jdbcType=VARCHAR}, #{attachmentSize,jdbcType=INTEGER}, #{attachmentType,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.ejweb.modules.reportAttachment.entity.ReportAttachment" >
insert into ct_bbtc_report_attachment
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="reportId != null" >
report_id,
</if>
<if test="attachmentName != null" >
attachment_name,
</if>
<if test="attachmentPath != null" >
attachment_path,
</if>
<if test="attachmentSize != null" >
attachment_size,
</if>
<if test="attachmentType != null" >
attachment_type,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="reportId != null" >
#{reportId,jdbcType=VARCHAR},
</if>
<if test="attachmentName != null" >
#{attachmentName,jdbcType=VARCHAR},
</if>
<if test="attachmentPath != null" >
#{attachmentPath,jdbcType=VARCHAR},
</if>
<if test="attachmentSize != null" >
#{attachmentSize,jdbcType=INTEGER},
</if>
<if test="attachmentType != null" >
#{attachmentType,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.ejweb.modules.reportAttachment.entity.ReportAttachment" >
update ct_bbtc_report_attachment
<set >
<if test="reportId != null" >
report_id = #{reportId,jdbcType=VARCHAR},
</if>
<if test="attachmentName != null" >
attachment_name = #{attachmentName,jdbcType=VARCHAR},
</if>
<if test="attachmentPath != null" >
attachment_path = #{attachmentPath,jdbcType=VARCHAR},
</if>
<if test="attachmentSize != null" >
attachment_size = #{attachmentSize,jdbcType=INTEGER},
</if>
<if test="attachmentType != null" >
attachment_type = #{attachmentType,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.ejweb.modules.reportAttachment.entity.ReportAttachment" >
update ct_bbtc_report_attachment
set report_id = #{reportId,jdbcType=VARCHAR},
attachment_name = #{attachmentName,jdbcType=VARCHAR},
attachment_path = #{attachmentPath,jdbcType=VARCHAR},
attachment_size = #{attachmentSize,jdbcType=INTEGER},
attachment_type = #{attachmentType,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.sys.dao.AreaDao">
<sql id="areaColumns">
a.id,
a.parent_id AS "parent.id",
a.parent_ids,
a.code,
a.name,
a.sort,
a.type,
a.remarks,
a.create_by AS "createBy.id",
a.create_date,
a.update_by AS "updateBy.id",
a.update_date,
a.del_flag,
p.name AS "parent.name"
</sql>
<sql id="areaJoins">
LEFT JOIN ct_bbtc_sys_office p ON p.id = a.parent_id
</sql>
<select id="get" resultType="Area">
SELECT
<include refid="areaColumns"/>
FROM ct_bbtc_sys_area a
<include refid="areaJoins"/>
WHERE a.id = #{id}
</select>
<select id="findList" resultType="Area">
SELECT
<include refid="areaColumns"/>
FROM ct_bbtc_sys_area a
<include refid="areaJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
<!-- 数据范围过滤 -->
${sqlMap.dsf}
OR a.id = #{currentUser.office.area.id}
ORDER BY a.code
</select>
<select id="findAllList" resultType="Area">
SELECT
<include refid="areaColumns"/>
FROM ct_bbtc_sys_area a
<include refid="areaJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
ORDER BY a.code
</select>
<select id="findByParentIdsLike" resultType="Area">
SELECT
a.id,
a.parent_id AS "parent.id",
a.parent_ids
FROM ct_bbtc_sys_area a
WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND a.parent_ids LIKE #{parentIds}
ORDER BY a.code
</select>
<insert id="insert">
INSERT INTO ct_bbtc_sys_area(
id,
parent_id,
parent_ids,
code,
name,
sort,
type,
create_by,
create_date,
update_by,
update_date,
remarks,
del_flag
) VALUES (
#{id},
#{parent.id},
#{parentIds},
#{code},
#{name},
#{sort},
#{type},
#{createBy.id},
#{createDate},
#{updateBy.id},
#{updateDate},
#{remarks},
#{delFlag}
)
</insert>
<update id="update">
UPDATE ct_bbtc_sys_area SET
parent_id = #{parent.id},
parent_ids = #{parentIds},
code = #{code},
name = #{name},
sort = #{sort},
type = #{type},
update_by = #{updateBy.id},
update_date = #{updateDate},
remarks = #{remarks}
WHERE id = #{id}
</update>
<update id="updateParentIds">
UPDATE ct_bbtc_sys_area SET
parent_id = #{parent.id},
parent_ids = #{parentIds}
WHERE id = #{id}
</update>
<update id="delete">
UPDATE ct_bbtc_sys_area SET
del_flag = #{DEL_FLAG_DELETE}
WHERE id = #{id} OR parent_ids LIKE
<if test="dbName == 'oracle'">'%,'||#{id}||',%'</if>
<if test="dbName == 'mssql'">'%,'+#{id}+',%'</if>
<if test="dbName == 'mysql'">CONCAT('%,', #{id}, ',%')</if>
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.sys.dao.DictDao">
<select id="get" resultType="Dict">
SELECT
*
FROM ct_bbtc_sys_dict
WHERE id = #{id}
</select>
<select id="findList" resultType="Dict">
SELECT
*
FROM ct_bbtc_sys_dict
WHERE del_flag = #{DEL_FLAG_NORMAL}
<if test="type != null and type != ''">
AND type = #{type}
</if>
<if test="description != null and description != ''">
AND description LIKE
<if test="dbName == 'oracle'">'%'||#{description}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{description}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{description}, '%')</if>
</if>
ORDER BY type, sort, update_date DESC
</select>
<select id="findAllList" resultType="Dict">
SELECT
*
FROM ct_bbtc_sys_dict
WHERE del_flag = #{DEL_FLAG_NORMAL}
ORDER BY type, sort, update_date DESC
</select>
<select id="findTypeList" resultType="string">
SELECT
type
FROM ct_bbtc_sys_dict
WHERE del_flag = #{DEL_FLAG_NORMAL}
GROUP BY type
ORDER BY type
</select>
<insert id="insert">
INSERT INTO ct_bbtc_sys_dict(
id,
value,
label,
type,
description,
sort,
create_by,
create_date,
update_by,
update_date,
remarks,
del_flag
) VALUES (
#{id},
#{value},
#{label},
#{type},
#{description},
#{sort},
#{createBy.id},
#{createDate},
#{updateBy.id},
#{updateDate},
#{remarks},
#{delFlag}
)
</insert>
<update id="update">
UPDATE ct_bbtc_sys_dict SET
value = #{value},
label = #{label},
type = #{type},
description = #{description},
sort = #{sort},
update_by = #{updateBy.id},
update_date = #{updateDate},
remarks = #{remarks}
WHERE id = #{id}
</update>
<update id="delete">
UPDATE ct_bbtc_sys_dict SET
del_flag = #{DEL_FLAG_DELETE}
WHERE id = #{id}
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.sys.dao.LogDao">
<select id="findList" resultType="Log">
SELECT
a.*,
u.id AS "createBy.id",
u.name AS "createBy.name",
c.name AS "createBy.company.name",
o.name AS "createBy.office.name"
FROM ct_bbtc_sys_log a
LEFT JOIN ct_bbtc_sys_user u ON u.id = a.create_by
LEFT JOIN ct_bbtc_sys_office c ON c.id = u.company_id
LEFT JOIN ct_bbtc_sys_office o ON o.id = u.office_id
WHERE a.create_date BETWEEN #{beginDate} AND #{endDate}
<if test="title != null and title != ''">
AND a.title LIKE
<if test="dbName == 'oracle'">'%'||#{title}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{title}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{title}, '%')</if>
</if>
<if test="createBy != null and createBy.id != null and createBy.id != ''">
AND a.create_by = #{createBy.id}
</if>
<if test="requestUri != null and requestUri != ''">
AND a.request_uri LIKE
<if test="dbName == 'oracle'">'%'||#{requestUri}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{requestUri}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{requestUri}, '%')</if>
</if>
<if test="exception != null and exception != ''">
AND a.type = #{TYPE_EXCEPTION}
</if>
ORDER BY a.create_date DESC
</select>
<insert id="insert">
INSERT INTO ct_bbtc_sys_log(
id,
type,
title,
create_by,
create_date,
remote_addr,
user_agent,
request_uri,
method,
params,
exception
) VALUES (
#{id},
#{type},
#{title},
#{createBy.id},
#{createDate},
#{remoteAddr},
#{userAgent},
#{requestUri},
#{method},
#{params},
#{exception}
)
</insert>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.sys.dao.MenuDao">
<sql id="menuColumns">
a.id,
a.parent_id AS "parent.id",
a.parent_ids,
a.name,
a.href,
a.target,
a.icon,
a.sort,
a.is_show,
a.permission,
a.remarks,
a.create_by AS "createBy.id",
a.create_date,
a.update_by AS "updateBy.id",
a.update_date,
a.del_flag,
p.name AS "parent.name"
</sql>
<sql id="menuJoins">
LEFT JOIN ct_bbtc_sys_menu p
ON p.id = a.parent_id
</sql>
<select id="get" resultType="Menu">
SELECT
<include refid="menuColumns"/>
FROM ct_bbtc_sys_menu a
<include refid="menuJoins"/>
WHERE a.id = #{id}
</select>
<select id="findAllList" resultType="Menu">
SELECT
<include refid="menuColumns"/>
FROM ct_bbtc_sys_menu a
<include refid="menuJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
ORDER BY a.sort
</select>
<select id="findByParentIdsLike" resultType="Menu">
SELECT
a.id,
a.parent_id AS "parent.id",
a.parent_ids
FROM ct_bbtc_sys_menu a
WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND a.parent_ids LIKE #{parentIds}
ORDER BY a.sort
</select>
<select id="findByUserId" resultType="Menu">
SELECT DISTINCT
<include refid="menuColumns"/>
FROM ct_bbtc_sys_menu a
LEFT JOIN ct_bbtc_sys_menu p ON p.id = a.parent_id
JOIN ct_bbtc_sys_menu2role rm ON rm.menu_id = a.id
JOIN ct_bbtc_sys_role r ON r.id = rm.role_id AND r.useable='1'
JOIN ct_bbtc_sys_user2role ur ON ur.role_id = r.id
JOIN ct_bbtc_sys_user u ON u.id = ur.user_id AND u.id = #{userId}
WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND r.del_flag = #{DEL_FLAG_NORMAL} AND u.del_flag = #{DEL_FLAG_NORMAL}
ORDER BY a.sort
</select>
<insert id="insert">
INSERT INTO ct_bbtc_sys_menu(
id,
parent_id,
parent_ids,
name,
href,
target,
icon,
sort,
is_show,
permission,
create_by,
create_date,
update_by,
update_date,
remarks,
del_flag
) VALUES (
#{id},
#{parent.id},
#{parentIds},
#{name},
#{href},
#{target},
#{icon},
#{sort},
#{isShow},
#{permission},
#{createBy.id},
#{createDate},
#{updateBy.id},
#{updateDate},
#{remarks},
#{delFlag}
)
</insert>
<update id="update">
UPDATE ct_bbtc_sys_menu SET
parent_id = #{parent.id},
parent_ids = #{parentIds},
name = #{name},
href = #{href},
target = #{target},
icon = #{icon},
sort = #{sort},
is_show = #{isShow},
permission = #{permission},
update_by = #{updateBy.id},
update_date = #{updateDate},
remarks = #{remarks}
WHERE id = #{id}
</update>
<update id="updateParentIds">
UPDATE ct_bbtc_sys_menu SET
parent_id = #{parent.id},
parent_ids = #{parentIds}
WHERE id = #{id}
</update>
<update id="updateSort">
UPDATE ct_bbtc_sys_menu SET
sort = #{sort}
WHERE id = #{id}
</update>
<update id="delete">
UPDATE ct_bbtc_sys_menu SET
del_flag = #{DEL_FLAG_DELETE}
WHERE id = #{id} OR parent_ids LIKE
<if test="dbName == 'oracle'">'%,'||#{id}||',%'</if>
<if test="dbName == 'mssql'">'%,'+#{id}+',%'</if>
<if test="dbName == 'mysql'">CONCAT('%,', #{id}, ',%')</if>
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.sys.dao.OfficeDao">
<sql id="officeColumns">
a.id,
a.parent_id AS "parent.id",
a.parent_ids,
a.area_id AS "area.id",
a.code,
a.name,
a.sort,
a.type,
a.grade,
a.USEABLE AS "useable",
a.address,
a.zip_code,
a.master,
a.phone,
a.fax,
a.email,
a.remarks,
a.create_by AS "createBy.id",
a.create_date,
a.update_by AS "updateBy.id",
a.update_date,
a.del_flag,
a.useable AS useable,
a.primary_person AS "primaryPerson.id",
a.deputy_person AS "deputyPerson.id",
p.name AS "parent.name",
p.code AS "parent.code",
ar.name AS "area.name",
ar.parent_ids AS "area.parentIds",
pp.name AS "primaryPerson.name",
dp.name AS "deputyPerson.name"
</sql>
<sql id="officeJoins">
LEFT JOIN ct_bbtc_sys_office p ON p.id = a.parent_id
LEFT JOIN ct_bbtc_sys_area ar ON ar.id = a.area_id
LEFT JOIN ct_bbtc_sys_user pp ON pp.id = a.primary_person
LEFT JOIN ct_bbtc_sys_user dp ON dp.id = a.deputy_person
</sql>
<select id="get" resultType="Office">
SELECT
<include refid="officeColumns"/>
FROM ct_bbtc_sys_office a
<include refid="officeJoins"/>
WHERE a.id = #{id}
</select>
<select id="findList" resultType="Office">
SELECT
<include refid="officeColumns"/>
FROM ct_bbtc_sys_office a
<include refid="officeJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
<!-- 数据范围过滤 -->
${sqlMap.dsf}
OR a.id = #{currentUser.office.id}
ORDER BY a.code
</select>
<select id="findAllList" resultType="Office">
SELECT
<include refid="officeColumns"/>
FROM ct_bbtc_sys_office a
<include refid="officeJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
ORDER BY a.code
</select>
<select id="findByParentIdsLike" resultType="Office">
SELECT
<include refid="officeColumns"/>
FROM ct_bbtc_sys_office a
<include refid="officeJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND a.parent_ids LIKE #{parentIds}
ORDER BY a.code
</select>
<!-- zhujf start-->
<select id="findByParentId" resultType="Office">
SELECT
<include refid="officeColumns"/>
FROM ct_bbtc_sys_office a
<include refid="officeJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND a.parent_id = #{parent.id}
ORDER BY a.code
</select>
<!-- zhujf end-->
<select id="findByOfficeName" resultType="Office">
SELECT
<include refid="officeColumns"/>
FROM ct_bbtc_sys_office a
<include refid="officeJoins"/>
WHERE a.del_flag = '0' AND a.name = #{officeName}
</select>
<select id="getCompany" parameterType="Office" resultType="Office">
SELECT
<include refid="officeColumns"/>
FROM ct_bbtc_sys_office a
<include refid="officeJoins"/>
WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND a.parent_id='1'
<if test="dbName == 'oracle'"> AND rownum &lt;= 1</if>
<if test="dbName == 'mysql'"> limit 1</if>
</select>
<insert id="insert">
INSERT INTO ct_bbtc_sys_office(
id,
parent_id,
parent_ids,
area_id,
code,
name,
sort,
type,
grade,
address,
zip_code,
master,
phone,
fax,
email,
create_by,
create_date,
update_by,
update_date,
remarks,
del_flag,
useable,
primary_person,
deputy_person
) VALUES (
#{id},
#{parent.id},
#{parentIds},
#{area.id},
#{code},
#{name},
#{sort},
#{type},
#{grade},
#{address},
#{zipCode},
#{master},
#{phone},
#{fax},
#{email},
#{createBy.id},
#{createDate},
#{updateBy.id},
#{updateDate},
#{remarks},
#{delFlag},
#{useable},
#{primaryPerson.id},
#{deputyPerson.id}
)
</insert>
<update id="update">
UPDATE ct_bbtc_sys_office SET
parent_id = #{parent.id},
parent_ids = #{parentIds},
area_id = #{area.id},
code = #{code},
name = #{name},
type = #{type},
grade = #{grade},
address = #{address},
zip_code = #{zipCode},
master = #{master},
phone = #{phone},
fax = #{fax},
email = #{email},
update_by = #{updateBy.id},
update_date = #{updateDate},
remarks = #{remarks},
useable=#{useable},
primary_person=#{primaryPerson.id},
deputy_person=#{deputyPerson.id}
WHERE id = #{id}
</update>
<update id="updateParentIds">
UPDATE ct_bbtc_sys_office SET
parent_id = #{parent.id},
parent_ids = #{parentIds}
WHERE id = #{id}
</update>
<update id="delete">
UPDATE ct_bbtc_sys_office SET
del_flag = #{DEL_FLAG_DELETE}
WHERE id = #{id} OR parent_ids LIKE
<if test="dbName == 'oracle'">'%,'||#{id}||',%'</if>
<if test="dbName == 'mssql'">'%,'+#{id}+',%'</if>
<if test="dbName == 'mysql'">CONCAT('%,', #{id}, ',%')</if>
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.sys.dao.RoleDao">
<resultMap id="roleResult" type="Role">
<id property="id" column="id" />
<result property="name" column="name" />
<result property="enname" column="enname" />
<result property="roleType" column="roleType" />
<result property="dataScope" column="dataScope" />
<result property="remarks" column="remarks" />
<result property="useable" column="useable" />
<result property="sysData" column="sysData" /><!--
<collection property="userList" ofType="User">
<id property="id" column="userList.id" />
<id property="loginName" column="userList.loginName" />
<id property="name" column="userList.name" />
<id property="email" column="userList.email" />
<id property="phone" column="userList.phone" />
<id property="mobile" column="userList.mobile" />
<id property="office.name" column="userList.office.name" />
<id property="company.name" column="userList.company.name" />
</collection> -->
<collection property="menuList" ofType="Menu">
<id property="id" column="menuList.id" />
</collection>
<collection property="officeList" ofType="Office">
<id property="id" column="officeList.id" />
</collection>
</resultMap>
<sql id="roleColumns">
a.id,
a.office_id AS "office.id",
a.name,
a.enname,
a.role_type AS roleType,
a.data_scope AS dataScope,
a.remarks,
a.create_by AS "createBy.id",
a.create_date,
a.update_by AS "updateBy.id",
a.update_date,
a.del_flag,
o.name AS "office.name",
o.code,
a.useable AS useable,
a.un_checked,
a.is_sys AS sysData
</sql>
<select id="get" resultMap="roleResult">
SELECT
<include refid="roleColumns"/>,<!--
ur.user_id AS "userList.id",
u.login_name AS "userList.loginName",
u.name AS "userList.name",
u.email AS "userList.email",
u.phone AS "userList.phone",
u.mobile AS "userList.mobile",
uc.name AS "userList.company.name",
uo.name AS "userList.office.name", -->
rm.menu_id AS "menuList.id",
ro.office_id AS "officeList.id"
FROM ct_bbtc_sys_role a
LEFT JOIN ct_bbtc_sys_office o
ON o.id = a.office_id<!--
LEFT JOIN ct_bbtc_sys_user2role ur ON ur.role_id = a.id
LEFT JOIN ct_bbtc_sys_user u ON u.id = ur.user_id
LEFT JOIN ct_bbtc_sys_office uc ON uc.id = u.company_id
LEFT JOIN ct_bbtc_sys_office uo ON uo.id = u.office_id -->
LEFT JOIN ct_bbtc_sys_menu2role rm
ON rm.role_id = a.id
LEFT JOIN ct_bbtc_sys_office2role ro
ON ro.role_id = a.id
WHERE a.id = #{id}
</select>
<select id="getByName" resultType="Role">
SELECT
<include refid="roleColumns"/>
FROM ct_bbtc_sys_role a
JOIN ct_bbtc_sys_office o ON o.id = a.office_id
WHERE a.name = #{name} AND a.del_flag = #{DEL_FLAG_NORMAL}
</select>
<select id="getByEnname" resultType="Role">
SELECT
<include refid="roleColumns"/>
FROM ct_bbtc_sys_role a
JOIN ct_bbtc_sys_office o ON o.id = a.office_id
WHERE a.enname = #{enname} AND a.del_flag = #{DEL_FLAG_NORMAL}
</select>
<select id="findList" resultMap="roleResult">
SELECT <!-- DISTINCT -->
<include refid="roleColumns"/>,
ro.office_id AS "officeList.id"
FROM ct_bbtc_sys_role a
LEFT JOIN ct_bbtc_sys_office o ON o.id = a.office_id
LEFT JOIN ct_bbtc_sys_user2role ur ON ur.role_id = a.id
LEFT JOIN ct_bbtc_sys_user u ON u.id = ur.user_id
LEFT JOIN ct_bbtc_sys_office2role ro ON ro.role_id = a.id
WHERE a.del_flag = #{DEL_FLAG_NORMAL} AND a.useable=#{useable}
<if test="user != null and user.id != null and user.id != ''">
AND u.id = #{user.id}
</if>
<if test="user != null and user.loginName != null and user.loginName != ''">
AND u.login_name = #{user.loginName}
</if>
<!-- 数据范围过滤 -->
${sqlMap.dsf}
ORDER BY o.code, a.name
</select>
<select id="findAllList" resultType="Role">
SELECT
<include refid="roleColumns"/>
FROM ct_bbtc_sys_role a
LEFT JOIN ct_bbtc_sys_office o ON o.id = a.office_id
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
<if test="unChecked != null and unChecked != ''">
AND a.un_checked = #{unChecked}
</if>
ORDER BY o.code, a.name
</select>
<insert id="insert">
INSERT INTO ct_bbtc_sys_role(
id,
office_id,
name,
enname,
role_type,
data_scope,
create_by,
create_date,
update_by,
update_date,
remarks,
del_flag,
is_sys,
useable
) VALUES (
#{id},
#{office.id},
#{name},
#{enname},
#{roleType},
#{dataScope},
#{createBy.id},
#{createDate},
#{updateBy.id},
#{updateDate},
#{remarks},
#{delFlag},
#{sysData},
#{useable}
)
</insert>
<update id="update">
UPDATE ct_bbtc_sys_role SET
office_id = #{office.id},
name = #{name},
enname = #{enname},
role_type = #{roleType},
data_scope = #{dataScope},
update_by = #{updateBy.id},
update_date = #{updateDate},
remarks = #{remarks},
is_sys = #{sysData},
useable = #{useable}
WHERE id = #{id}
</update>
<delete id="deleteRoleMenu">
DELETE FROM ct_bbtc_sys_menu2role WHERE role_id = #{id}
</delete>
<insert id="insertRoleMenu">
INSERT INTO ct_bbtc_sys_menu2role(role_id, menu_id)
<foreach collection="menuList" item="menu" separator=" union all ">
SELECT #{id}, #{menu.id}
<if test="dbName != 'mssql'">
FROM dual
</if>
</foreach>
</insert>
<delete id="deleteRoleOffice">
DELETE FROM ct_bbtc_sys_office2role WHERE role_id = #{id}
</delete>
<insert id="insertRoleOffice">
INSERT INTO ct_bbtc_sys_office2role(role_id, office_id)
<foreach collection="officeList" item="office" separator=" union all ">
SELECT #{id}, #{office.id}
<if test="dbName != 'mssql'">
FROM dual
</if>
</foreach>
</insert>
<update id="delete">
UPDATE ct_bbtc_sys_role SET
del_flag = #{DEL_FLAG_DELETE}
WHERE id = #{id}
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.sys.dao.SysUserDao">
<!-- <resultMap id="userResult" type="User">
<id property="id" column="id" />
<result property="company.id" column="company.id" />
<result property="office.id" column="office.id" />
<result property="loginName" column="login_name" />
<result property="password" column="password" />
<result property="no" column="no" />
<result property="name" column="name" />
<result property="email" column="email" />
<result property="phone" column="phone" />
<result property="mobile" column="mobile" />
<result property="userType" column="user_type" />
<result property="loginIp" column="login_ip" />
<result property="loginDate" column="login_date" />
<result property="remarks" column="remarks" />
<result property="loginFlag" column="loginFlag" />
<result property="photo" column="photo" />
<result property="createBy.id" column="createBy.id" />
<result property="createDate" column="create_date" />
<result property="updateBy.id" column="updateBy.id" />
<result property="updateDate" column="update_date" />
<result property="company.name" column="company.name" />
<result property="company.parentId" column="company.parentId" />
<result property="company.parentIds" column="company.parentIds" />
<result property="company.area.id" column="company.area.id" />
<result property="company.area.name" column="company.area.name" />
<result property="company.area.parentId" column="company.area.parentId" />
<result property="company.area.parentIds" column="company.area.parentIds" />
<result property="company.primaryPerson.id" column="company.primaryPerson.id" />
<result property="company.primaryPerson.name" column="company.primaryPerson.name" />
<result property="company.deputyPerson.id" column="company.deputyPerson.id" />
<result property="company.deputyPerson.name" column="company.deputyPerson.name" />
<result property="office.name" column="office.name" />
<result property="office.parentId" column="office.parentId" />
<result property="office.parentIds" column="office.parentIds" />
<result property="office.area.id" column="office.area.id" />
<result property="office.area.name" column="office.area.name" />
<result property="office.area.parentId" column="office.area.parentId" />
<result property="office.area.parentIds" column="office.area.parentIds" />
<result property="office.primaryPerson.id" column="office.primaryPerson.id" />
<result property="office.primaryPerson.name" column="office.primaryPerson.name" />
<result property="office.deputyPerson.id" column="office.deputyPerson.id" />
<result property="office.deputyPerson.name" column="office.deputyPerson.name" />
<collection property="roleList" ofType="Role">
<id property="id" column="roleList.id" />
<result property="office.id" column="roleList.office.id" />
<result property="name" column="roleList.name" />
<result property="enname" column="roleList.enname" />
<result property="roleType" column="roleList.roleType" />
<result property="dataScope" column="roleList.dataScope" />
<collection property="officeList" ofType="Office">
<id property="id" column="roleList.officeList.id" />
</collection>
</collection>
</resultMap> -->
<sql id="userColumns">
a.id,
a.company_id AS "company.id",
a.office_id AS "office.id",
a.login_name,
a.password,
a.no,
a.area,
a.name,
a.email,
a.phone,
a.mobile,
a.user_type,
a.login_ip,
a.login_date,
a.remarks,
a.login_flag,
a.photo,
a.create_by AS "createBy.id",
a.create_date,
a.update_by AS "updateBy.id",
a.update_date,
a.del_flag,
a.supplement_group AS supplementGroup,
c.name AS "company.name",
c.parent_id AS "company.parent.id",
c.parent_ids AS "company.parentIds",
ca.id AS "company.area.id",
ca.name AS "company.area.name",
ca.parent_id AS "company.area.parent.id",
ca.parent_ids AS "company.area.parentIds",
o.name AS "office.name",
o.parent_id AS "office.parent.id",
o.parent_ids AS "office.parentIds",
oa.id AS "office.area.id",
oa.name AS "office.area.name",
oa.parent_id AS "office.area.parent.id",
oa.parent_ids AS "office.area.parentIds",
cu.id AS "company.primaryPerson.id",
cu.name AS "company.primaryPerson.name",
cu2.id AS "company.deputyPerson.id",
cu2.name AS "company.deputyPerson.name",
ou.id AS "office.primaryPerson.id",
ou.name AS "office.primaryPerson.name",
ou2.id AS "office.deputyPerson.id",
ou2.name AS "office.deputyPerson.name"
<!-- ,
r.id AS "roleList.id",
r.office_id AS "roleList.office.id",
r.name AS "roleList.name",
r.enname AS "roleList.enname",
r.role_type AS "roleList.roleType",
r.data_scope AS "roleList.dataScope" -->
</sql>
<sql id="userJoins">
LEFT JOIN ct_bbtc_sys_office c ON c.id = a.company_id
LEFT JOIN ct_bbtc_sys_area ca ON ca.id = c.area_id
LEFT JOIN ct_bbtc_sys_office o ON o.id = a.office_id
LEFT JOIN ct_bbtc_sys_area oa ON oa.id = o.area_id
LEFT JOIN ct_bbtc_sys_user cu ON cu.id = c.primary_person
LEFT JOIN ct_bbtc_sys_user cu2 ON cu2.id = c.deputy_person
LEFT JOIN ct_bbtc_sys_user ou ON ou.id = o.primary_person
LEFT JOIN ct_bbtc_sys_user ou2 ON ou2.id = o.deputy_person
<!--
LEFT JOIN ct_bbtc_sys_user2role ur ON ur.user_id = a.id
LEFT JOIN ct_bbtc_sys_role r ON r.id = ur.role_id
-->
</sql>
<!-- 根据编号获得用户 -->
<select id="get" resultType="User">
SELECT
<include refid="userColumns"/>
FROM ct_bbtc_sys_user a
<include refid="userJoins"/>
WHERE a.id = #{id}
</select>
<!-- 根据登录名查询用户 -->
<select id="getByLoginName" resultType="User" parameterType="User">
SELECT
<include refid="userColumns"/><!-- ,
ro.office_id AS "roleList.officeList.id" -->
FROM ct_bbtc_sys_user a
<include refid="userJoins"/><!--
LEFT JOIN ct_bbtc_sys_office2role ro ON ro.role_id = r.id -->
WHERE a.login_name = #{loginName} AND a.del_flag = #{DEL_FLAG_NORMAL}
</select>
<!-- 分页查询用户信息 -->
<select id="findList" resultType="User">
SELECT
role.id AS roleId,
cr.name AS areaName,
<include refid="userColumns"/>
FROM ct_bbtc_sys_user a
<include refid="userJoins"/>
LEFT JOIN ct_bbtc_region CR ON a.area = CR.id
<if test="role != null and role.id != null and role.id != ''">
JOIN ct_bbtc_sys_user2role ur ON ur.user_id = a.id AND ur.role_id = #{role.id}
</if>
LEFT JOIN ct_bbtc_sys_user2role ur ON ur.user_id = a.id
LEFT JOIN ct_bbtc_sys_role role ON ur.role_id = role.id
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
<if test="company != null and company.id != null and company.id != ''">
AND (c.id = #{company.id} OR c.parent_ids LIKE
<if test="dbName == 'oracle'">'%,'||#{company.id}||',%')</if>
<if test="dbName == 'mssql'">'%,'+#{company.id}+',%')</if>
<if test="dbName == 'mysql'">CONCAT('%,', #{company.id}, ',%'))</if>
</if>
<if test="office != null and office.id != null and office.id != ''">
AND (o.id = #{office.id} OR o.parent_ids LIKE
<if test="dbName == 'oracle'">'%,'||#{office.id}||',%')</if>
<if test="dbName == 'mssql'">'%,'+#{office.id}+',%')</if>
<if test="dbName == 'mysql'">CONCAT('%,', #{office.id}, ',%'))</if>
</if>
<!-- 如果不是超级管理员,则不显示超级管理员用户 -->
<if test="!currentUser.admin">
AND a.id != '1'
</if>
<if test="loginName != null and loginName != ''">
AND a.login_name like
<if test="dbName == 'oracle'">'%'||#{loginName}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{loginName}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{loginName}, '%')</if>
</if>
<if test="name != null and name != ''">
AND a.name like
<if test="dbName == 'oracle'">'%'||#{name}||'%'</if>
<if test="dbName == 'mssql'">'%'+#{name}+'%'</if>
<if test="dbName == 'mysql'">CONCAT('%', #{name}, '%')</if>
</if>
<!-- 数据范围过滤 -->
${sqlMap.dsf}
<choose>
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
ORDER BY ${page.orderBy}
</when>
<otherwise>
ORDER BY a.create_date DESC,c.code, o.code, a.name
</otherwise>
</choose>
</select>
<!-- 根据OfficeId获取用户(树查询用户时用) -->
<select id="findUserByOfficeId" resultType="User" useCache="true">
SELECT
a.id, a.name, a.login_name
FROM ct_bbtc_sys_user a
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
AND a.office_id = #{office.id}
ORDER BY a.name
</select>
<!-- 查询全部用户 -->
<select id="findAllList" resultType="User">
SELECT
cr.name AS areaName,
<include refid="userColumns"/>
FROM ct_bbtc_sys_user a
<include refid="userJoins"/>
LEFT JOIN ct_bbtc_region CR ON a.area = CR.id
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
ORDER BY c.code, o.code, a.name
</select>
<!-- 查询全部用户数目 -->
<select id="findAllCount" resultType="long">
SELECT
COUNT(1)
FROM ct_bbtc_sys_user a
WHERE a.del_flag = #{DEL_FLAG_NORMAL}
</select>
<!-- 插入用户 -->
<insert id="insert">
INSERT INTO ct_bbtc_sys_user(
id,
company_id,
office_id,
login_name,
password,
no,
name,
area,
email,
phone,
mobile,
user_type,
create_by,
create_date,
update_by,
update_date,
remarks,
login_flag,
photo,
del_flag,
supplement_group
) VALUES (
#{id},
#{company.id},
#{office.id},
#{loginName},
#{password},
#{no},
#{name},
#{area},
#{email},
#{phone},
#{mobile},
#{userType},
#{createBy.id},
#{createDate},
#{updateBy.id},
#{updateDate},
#{remarks},
#{loginFlag},
#{photo},
#{delFlag},
#{supplementGroup}
)
</insert>
<insert id="insertOfficeName">
INSERT INTO ct_bbtc_sys_user_profiles(
user_id,
office_name,
device_update
) VALUES (
#{id},
#{officeName},
CURRENT_TIMESTAMP
)
</insert>
<!-- 更新用户 -->
<update id="update">
UPDATE ct_bbtc_sys_user SET
company_id = #{company.id},
office_id = #{office.id},
login_name = #{loginName},
password = #{password},
no = #{no},
name = #{name},
area=#{area},
email = #{email},
phone = #{phone},
mobile = #{mobile},
user_type = #{userType},
update_by = #{updateBy.id},
update_date = #{updateDate},
remarks = #{remarks},
login_flag = #{loginFlag},
photo = #{photo},
supplement_group=#{supplementGroup}
WHERE id = #{id}
</update>
<!-- 删除用户和角色关联表数据 -->
<delete id="deleteUserRole">
DELETE FROM ct_bbtc_sys_user2role WHERE user_id = #{id}
</delete>
<!-- 插入用户和角色关联表数据 -->
<insert id="insertUserRole">
INSERT INTO ct_bbtc_sys_user2role(user_id, role_id)
<foreach collection="roleList" item="role" separator=" union all ">
SELECT #{id}, #{role.id}
<if test="dbName != 'mssql'">
FROM dual
</if>
</foreach>
</insert>
<!-- 更新用户信息 -->
<update id="updateUserInfo">
UPDATE ct_bbtc_sys_user SET
email = #{email},
phone = #{phone},
mobile = #{mobile},
update_by = #{updateBy.id},
update_date = #{updateDate},
remarks = #{remarks},
photo = #{photo}
WHERE id = #{id}
</update>
<!-- 更新用户密码 -->
<update id="updatePasswordById">
UPDATE ct_bbtc_sys_user SET
password = #{password}
WHERE id = #{id}
</update>
<!-- 更新登录信息,如登录IP、登录时间 -->
<update id="updateLoginInfo">
UPDATE ct_bbtc_sys_user SET
login_ip = #{loginIp},
login_Date = #{loginDate}
WHERE id = #{id}
</update>
<!-- 逻辑删除用户 -->
<update id="delete">
UPDATE ct_bbtc_sys_user SET
del_flag = #{DEL_FLAG_DELETE}
WHERE id = #{id}
</update>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.upload.dao.UploadDao">
<sql id="fileColumns">
id,
app_code,
session_id,
clientip,
module,
md5,
name,
input_name,
path,
thumbs,
extesion,
summary,
size,
width,
height,
orientation
</sql>
<insert id="addUploadFile" useGeneratedKeys="true" keyProperty="id">
INSERT INTO ct_bbtc_upload_files(
<include refid="fileColumns"/>
) VALUES(
#{fileId},
#{appCode},
#{sessionId},
#{clientip},
#{module},
#{md5},
#{name},
#{inputName},
#{path},
#{thumbs},
#{extesion},
#{summary},
#{size},
#{width},
#{height},
#{orientation}
)
</insert>
<select id="getFileByPath" resultType="com.ejweb.modules.upload.entity.UploadEntity">
SELECT orientation FROM ct_bbtc_upload_files
WHERE #{path} LIKE
<if test="dbName == 'oracle'"> '%'|| path|| '%'</if>
<if test="dbName == 'mysql'"> CONCAT('%', path, '%')</if>
</select>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.workbench.dao.ReportNoticeDao">
<select id="findList" parameterType="ReportNoticeEntity" resultType="ReportNoticeEntity">
SELECT
c.*, CU.name AS "sendFromName"
FROM
CT_BBTC_REPORT_NOTICE c
LEFT JOIN CT_BBTC_SYS_USER cu ON c.send_from_id = cu.id
WHERE c.send_to_id = #{sendToId}
ORDER BY
c.send_time DESC
</select>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="com.ejweb.modules.workbench.dao.ReportNoticeMapper" >
<resultMap id="BaseResultMap" type="com.ejweb.modules.workbench.entity.ReportNotice" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="report_id" property="reportId" jdbcType="VARCHAR" />
<result column="title" property="title" jdbcType="VARCHAR" />
<result column="send_time" property="sendTime" jdbcType="VARCHAR" />
<result column="send_from_id" property="sendFromId" jdbcType="VARCHAR" />
<result column="send_to_id" property="sendToId" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="create_by" property="createBy" jdbcType="VARCHAR" />
<result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
<result column="update_by" property="updateBy" jdbcType="VARCHAR" />
<result column="update_date" property="updateDate" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, report_id, title, send_time, send_from_id, send_to_id, status, create_by, create_date, update_by,
update_date
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from ct_bbtc_report_notice
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from ct_bbtc_report_notice
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.ejweb.modules.workbench.entity.ReportNotice" >
insert into ct_bbtc_report_notice (id, title, send_time,
send_from_id, send_to_id, status,
create_by, create_date, update_by,
update_date)
values (#{id,jdbcType=VARCHAR}, #{title,jdbcType=VARCHAR}, #{sendTime,jdbcType=VARCHAR},
#{sendFromId,jdbcType=VARCHAR}, #{sendToId,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR},
#{createBy,jdbcType=VARCHAR}, #{createDate,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR},
#{updateDate,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.ejweb.modules.workbench.entity.ReportNotice" >
insert into ct_bbtc_report_notice
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="title != null" >
title,
</if>
<if test="sendTime != null" >
send_time,
</if>
<if test="sendFromId != null" >
send_from_id,
</if>
<if test="sendToId != null" >
send_to_id,
</if>
<if test="status != null" >
status,
</if>
<if test="createBy != null" >
create_by,
</if>
<if test="createDate != null" >
create_date,
</if>
<if test="updateBy != null" >
update_by,
</if>
<if test="updateDate != null" >
update_date,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="title != null" >
#{title,jdbcType=VARCHAR},
</if>
<if test="sendTime != null" >
#{sendTime,jdbcType=VARCHAR},
</if>
<if test="sendFromId != null" >
#{sendFromId,jdbcType=VARCHAR},
</if>
<if test="sendToId != null" >
#{sendToId,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="createBy != null" >
#{createBy,jdbcType=VARCHAR},
</if>
<if test="createDate != null" >
#{createDate,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null" >
#{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateDate != null" >
#{updateDate,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.ejweb.modules.workbench.entity.ReportNotice" >
update ct_bbtc_report_notice
<set >
<if test="title != null" >
title = #{title,jdbcType=VARCHAR},
</if>
<if test="sendTime != null" >
send_time = #{sendTime,jdbcType=VARCHAR},
</if>
<if test="sendFromId != null" >
send_from_id = #{sendFromId,jdbcType=VARCHAR},
</if>
<if test="sendToId != null" >
send_to_id = #{sendToId,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="createBy != null" >
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if test="createDate != null" >
create_date = #{createDate,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null" >
update_by = #{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateDate != null" >
update_date = #{updateDate,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.ejweb.modules.workbench.entity.ReportNotice" >
update ct_bbtc_report_notice
set title = #{title,jdbcType=VARCHAR},
send_time = #{sendTime,jdbcType=VARCHAR},
send_from_id = #{sendFromId,jdbcType=VARCHAR},
send_to_id = #{sendToId,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_date = #{createDate,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_date = #{updateDate,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectBySendToId" resultMap="BaseResultMap">
SELECT
<include refid="Base_Column_List"/>
FROM ct_bbtc_report_notice
WHERE send_to_id = #{sendToId,jdbcType=VARCHAR}
order by send_time desc
</select>
<select id="getMessageCount" resultType="Integer">
SELECT
count(*)
FROM
CT_BBTC_REPORT_NOTICE n
WHERE
n.SEND_TO_ID = #{sendToId,jdbcType=VARCHAR}
AND n.STATUS = '0'
</select>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd/mybatis-3-config.dtd">
<configuration>
<!-- 全局参数 -->
<settings>
<!-- 使全局的映射器启用或禁用缓存。 -->
<setting name="cacheEnabled" value="true"/>
<!-- 全局启用或禁用延迟加载。当禁用时,所有关联对象都会即时加载。 -->
<setting name="lazyLoadingEnabled" value="true"/>
<!-- 当启用时,有延迟加载属性的对象在被调用时将会完全加载任意属性。否则,每种属性将会按需要加载。 -->
<setting name="aggressiveLazyLoading" value="true"/>
<!-- 是否允许单条sql 返回多个数据集 (取决于驱动的兼容性) default:true -->
<setting name="multipleResultSetsEnabled" value="true"/>
<!-- 是否可以使用列的别名 (取决于驱动的兼容性) default:true -->
<setting name="useColumnLabel" value="true"/>
<!-- 允许JDBC 生成主键。需要驱动器支持。如果设为了true,这个设置将强制使用被生成的主键,有一些驱动器不兼容不过仍然可以执行。 default:false -->
<setting name="useGeneratedKeys" value="false"/>
<!-- 指定 MyBatis 如何自动映射 数据基表的列 NONE:不隐射 PARTIAL:部分 FULL:全部 -->
<setting name="autoMappingBehavior" value="PARTIAL"/>
<!-- 这是默认的执行类型 (SIMPLE: 简单; REUSE: 执行器可能重复使用prepared statements语句;BATCH: 执行器可以重复执行语句和批量更新) -->
<setting name="defaultExecutorType" value="SIMPLE"/>
<!-- 使用驼峰命名法转换字段。 -->
<setting name="mapUnderscoreToCamelCase" value="true"/>
<!-- 设置本地缓存范围 session:就会有数据的共享 statement:语句范围 (这样就不会有数据的共享 ) defalut:session -->
<setting name="localCacheScope" value="SESSION"/>
<!-- 设置但JDBC类型为空时,某些驱动程序 要指定值,default:OTHER,插入空值时不需要指定类型 -->
<setting name="jdbcTypeForNull" value="NULL"/>
</settings>
<!-- 类型别名 -->
<typeAliases>
<typeAlias alias="Page" type="com.ejweb.core.persistence.Page" /><!--分页 -->
</typeAliases>
<!-- 插件配置 -->
<plugins>
<plugin interceptor="com.ejweb.core.persistence.interceptor.PaginationInterceptor" />
</plugins>
</configuration>
# enabled
enabled=false
# project start time[\u9879\u76ee\u542f\u52a8\u65f6\u95f4]
delaySeconds=5
# xml scanning interval time[\u626b\u63cf\u95f4\u9694\u65f6\u957f]
sleepSeconds=2
# xml file's path[xml\u6587\u4ef6\u7684\u8def\u5f84]
mappingPath=mappings
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context" xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd"
default-lazy-init="true">
<description>Shiro Configuration</description>
<!-- 加载配置属性文件 -->
<context:property-placeholder ignore-unresolvable="true" location="classpath:ejweb.properties" />
<!-- Shiro权限过滤过滤器定义 -->
<bean name="shiroFilterChainDefinitions" class="java.lang.String">
<constructor-arg>
<value>
/static/** = anon
/userfiles/** = anon
${adminPath}/cas = cas
${adminPath}/login = authc
${adminPath}/logout = logout
${adminPath}/** = user
/act/rest/service/editor/** = perms[act:model:edit]
/act/rest/service/model/** = perms[act:model:edit]
/act/rest/service/** = user
/ReportServer/** = user
</value>
</constructor-arg>
</bean>
<!-- 安全认证过滤器 -->
<bean id="shiroFilter" class="org.apache.shiro.spring.web.ShiroFilterFactoryBean">
<property name="securityManager" ref="securityManager" /><!--
<property name="loginUrl" value="${cas.server.url}?service=${cas.project.url}${adminPath}/cas" /> -->
<property name="loginUrl" value="${adminPath}/login" />
<property name="successUrl" value="${adminPath}?login" />
<property name="filters">
<map>
<entry key="cas" value-ref="casFilter"/>
<entry key="authc" value-ref="formAuthenticationFilter"/>
</map>
</property>
<property name="filterChainDefinitions">
<ref bean="shiroFilterChainDefinitions"/>
</property>
</bean>
<!-- CAS认证过滤器 -->
<bean id="casFilter" class="org.apache.shiro.cas.CasFilter">
<property name="failureUrl" value="${adminPath}/login"/>
</bean>
<!-- 定义Shiro安全管理配置 -->
<bean id="securityManager" class="org.apache.shiro.web.mgt.DefaultWebSecurityManager">
<property name="realm" ref="systemAuthorizingRealm" />
<property name="sessionManager" ref="sessionManager" />
<property name="cacheManager" ref="shiroCacheManager" />
</bean>
<!-- 自定义会话管理配置 -->
<bean id="sessionManager" class="com.ejweb.core.security.shiro.session.SessionManager">
<property name="sessionDAO" ref="sessionDAO"/>
<!-- 会话超时时间,单位:毫秒 -->
<property name="globalSessionTimeout" value="${session.sessionTimeout}"/>
<!-- 定时清理失效会话, 清理用户直接关闭浏览器造成的孤立会话 -->
<property name="sessionValidationInterval" value="${session.sessionTimeoutClean}"/>
<!-- <property name="sessionValidationSchedulerEnabled" value="false"/> -->
<property name="sessionValidationSchedulerEnabled" value="true"/>
<property name="sessionIdCookie" ref="sessionIdCookie"/>
<property name="sessionIdCookieEnabled" value="true"/>
</bean>
<!-- 指定本系统SESSIONID, 默认为: JSESSIONID 问题: 与SERVLET容器名冲突, 如JETTY, TOMCAT 等默认JSESSIONID,
当跳出SHIRO SERVLET时如ERROR-PAGE容器会为JSESSIONID重新分配值导致登录会话丢失! -->
<bean id="sessionIdCookie" class="org.apache.shiro.web.servlet.SimpleCookie">
<constructor-arg name="name" value="jeesite.session.id"/>
</bean>
<!-- 自定义Session存储容器 -->
<!-- <bean id="sessionDAO" class="com.ejweb.core.security.shiro.session.JedisSessionDAO"> -->
<!-- <property name="sessionIdGenerator" ref="idGen" /> -->
<!-- <property name="sessionKeyPrefix" value="${redis.keyPrefix}_session_" /> -->
<!-- </bean> -->
<bean id="sessionDAO" class="com.ejweb.core.security.shiro.session.CacheSessionDAO">
<property name="sessionIdGenerator" ref="idGen" />
<property name="activeSessionsCacheName" value="activeSessionsCache" />
<property name="cacheManager" ref="shiroCacheManager" />
</bean>
<!-- 定义授权缓存管理器 -->
<!-- <bean id="shiroCacheManager" class="com.ejweb.core.security.shiro.cache.SessionCacheManager" /> -->
<bean id="shiroCacheManager" class="org.apache.shiro.cache.ehcache.EhCacheManager">
<property name="cacheManager" ref="cacheManager"/>
</bean>
<!-- 保证实现了Shiro内部lifecycle函数的bean执行 -->
<bean id="lifecycleBeanPostProcessor" class="org.apache.shiro.spring.LifecycleBeanPostProcessor"/>
<!-- AOP式方法级权限检查 -->
<bean class="org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator" depends-on="lifecycleBeanPostProcessor">
<property name="proxyTargetClass" value="true" />
</bean>
<bean class="org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor">
<property name="securityManager" ref="securityManager"/>
</bean>
</beans>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:jdbc="http://www.springframework.org/schema/jdbc"
xmlns:jee="http://www.springframework.org/schema/jee"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:util="http://www.springframework.org/schema/util"
xmlns:task="http://www.springframework.org/schema/task" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-4.0.xsd
http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-4.0.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-4.0.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-4.2.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-4.0.xsd
http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task-4.0.xsd"
default-lazy-init="true">
<description>Spring Configuration</description>
<!-- 加载配置属性文件 -->
<bean id="propertyConfigurer" class="com.ejweb.core.security.SecurityPropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>classpath:jdbc.properties</value>
<value>classpath:ejweb.properties</value>
</list>
</property>
</bean>
<!-- 使用Annotation自动注册Bean,解决事物失效问题:在主容器中不扫描@Controller注解,在SpringMvc中只扫描@Controller注解。 -->
<context:component-scan base-package="com.ejweb"><!-- base-package 如果多个,用“,”分隔 -->
<context:exclude-filter type="annotation" expression="org.springframework.stereotype.Controller"/>
</context:component-scan>
<!-- MyBatis begin -->
<bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
<property name="dataSource" ref="dataSource"/>
<property name="typeAliasesPackage" value="com.ejweb"/>
<property name="typeAliasesSuperType" value="com.ejweb.core.persistence.BaseEntity"/>
<property name="mapperLocations" value="classpath:/mappings/**/*.xml"/>
<property name="configLocation" value="classpath:/mybatis-config.xml"></property>
</bean>
<!-- 扫描basePackage下所有以@MyBatisDao注解的接口 -->
<bean id="mapperScannerConfigurer" class="org.mybatis.spring.mapper.MapperScannerConfigurer">
<property name="sqlSessionFactoryBeanName" value="sqlSessionFactory" />
<property name="basePackage" value="com.ejweb"/>
<property name="annotationClass" value="com.ejweb.core.persistence.annotation.MyBatisDao"/>
</bean>
<!-- 定义事务 -->
<bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource" ref="dataSource" />
</bean>
<tx:advice id="txAdvice" transaction-manager="transactionManager">
<tx:attributes>
<tx:method name="get*" read-only="true" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="select*" read-only="true" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="find*" read-only="true" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="search*" read-only="true" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="insert*" read-only="false" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="create*" read-only="false" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="add*" read-only="false" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="update*" read-only="false" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="modify*" read-only="false" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="delete*" read-only="false" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="remove*" read-only="false" propagation="REQUIRED" rollback-for="Exception" />
<tx:method name="*" read-only="true" propagation="SUPPORTS" rollback-for="Exception" />
</tx:attributes>
</tx:advice>
<aop:config>
<aop:pointcut id="appService" expression="execution(* com.ejweb.*.*Service*(..))"/>
<aop:advisor advice-ref="txAdvice" pointcut-ref="appService"/>
</aop:config>
<aop:aspectj-autoproxy/>
<!-- 配置 Annotation 驱动,扫描@Transactional注解的类定义事务 -->
<tx:annotation-driven transaction-manager="transactionManager" proxy-target-class="true"/>
<!-- MyBatis end -->
<!-- 配置 JSR303 Bean Validator 定义 -->
<bean id="validator" class="org.springframework.validation.beanvalidation.LocalValidatorFactoryBean" />
<!-- 缓存配置 -->
<bean id="cacheManager" class="org.springframework.cache.ehcache.EhCacheManagerFactoryBean">
<property name="configLocation" value="classpath:${ehcache.configFile}" />
</bean>
<!-- 计划任务配置,用 @Service @Lazy(false)标注类,用@Scheduled(cron = "0 0 2 * * ?")标注方法 -->
<task:executor id="executor" pool-size="10"/> <task:scheduler id="scheduler" pool-size="10"/>
<task:annotation-driven scheduler="scheduler" executor="executor" proxy-target-class="true"/>
<!-- 数据源配置, 使用 BoneCP 数据库连接池 -->
<bean id="dataSource" class="com.alibaba.druid.pool.DruidDataSource"
init-method="init" destroy-method="close">
<!-- 数据源驱动类可不写,Druid默认会自动根据URL识别DriverClass -->
<property name="driverClassName" value="${jdbc.driver.class}" />
<!-- 基本属性 url、user、password -->
<property name="url" value="${jdbc.url}" />
<property name="username" value="${jdbc.username}" />
<property name="password" value="${jdbc.password}" />
<!-- 配置初始化大小、最小、最大 -->
<property name="initialSize" value="${jdbc.initialSize}" />
<property name="minIdle" value="${jdbc.minIdle}" />
<property name="maxActive" value="${jdbc.maxActive}" />
<!-- 配置获取连接等待超时的时间 -->
<property name="maxWait" value="60000" />
<!-- 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒 -->
<property name="timeBetweenEvictionRunsMillis" value="60000" />
<!-- 配置一个连接在池中最小生存的时间,单位是毫秒 -->
<property name="minEvictableIdleTimeMillis" value="300000" />
<property name="validationQuery" value="${jdbc.validationQuery}" />
<property name="testWhileIdle" value="true" />
<property name="testOnBorrow" value="false" />
<property name="testOnReturn" value="false" />
<!-- 打开PSCache,并且指定每个连接上PSCache的大小 -->
<property name="poolPreparedStatements" value="true" />
<property name="maxPoolPreparedStatementPerConnectionSize" value="20" />
<!-- 配置监控统计拦截的filters,去掉后监控界面sql无法统计 -->
<property name="filters" value="stat" />
</bean>
</beans>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context" xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-4.0.xsd">
<description>Spring MVC Configuration</description>
<!-- 加载配置属性文件 -->
<!-- <context:property-placeholder ignore-unresolvable="true" location="classpath:ejweb.properties" />-->
<bean id="propertyConfigurer" class="com.ejweb.core.security.SecurityPropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>classpath:ejweb.properties</value>
</list>
</property>
</bean>
<!-- 使用Annotation自动注册Bean,只扫描@Controller -->
<context:component-scan base-package="com.ejweb" use-default-filters="false"><!-- base-package 如果多个,用“,”分隔 -->
<context:include-filter type="annotation" expression="org.springframework.stereotype.Controller"/>
</context:component-scan>
<!-- REST中根据URL后缀自动判定Content-Type及相应的View -->
<bean id="contentNegotiationManager" class="org.springframework.web.accept.ContentNegotiationManagerFactoryBean">
<property name="mediaTypes">
<map>
<entry key="json" value="application/json"/>
<entry key="xml" value="application/xml;charset=utf-8"/>
</map>
</property>
<!-- 扩展名至mimeType的映射,即 /user.json => application/json -->
<property name= "favorPathExtension" value= "true" />
<!-- 用于开启 /userinfo/123?format=json 的支持 -->
<property name= "favorParameter" value= "true" />
<property name= "parameterName" value= "format"/>
<!-- 是否忽略Accept Header -->
<property name="ignoreAcceptHeader" value="false"/>
<!-- 默认的content type -->
<property name= "defaultContentType" value= "application/json" />
</bean>
<!-- 默认的注解映射的支持 -->
<mvc:annotation-driven content-negotiation-manager="contentNegotiationManager">
<mvc:message-converters register-defaults="true">
<!-- 将StringHttpMessageConverter的默认编码设为UTF-8 -->
<bean class="org.springframework.http.converter.StringHttpMessageConverter">
<constructor-arg value="UTF-8" />
</bean>
<!-- 配置Fastjson支持 -->
<bean class="com.alibaba.fastjson.support.spring.FastJsonHttpMessageConverter">
<property name="supportedMediaTypes">
<list>
<value>text/plain;charset=UTF-8</value>
<value>text/html;charset=UTF-8</value>
<value>application/json;charset=UTF-8</value>
</list>
</property>
<property name="features">
<list>
<value>WriteMapNullValue</value>
<value>QuoteFieldNames</value>
</list>
</property>
</bean>
</mvc:message-converters>
</mvc:annotation-driven>
<!-- Freemarker的配置 -->
<bean id="fmXmlEscape" class="freemarker.template.utility.XmlEscape"/>
<bean id="freemarkerConfig" class="org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer">
<property name="templateLoaderPath" value="${web.view.prefix}"/>
<property name="defaultEncoding" value="utf-8"/>
<property name="freemarkerVariables">
<map>
<entry key="xml_escape" value-ref="fmXmlEscape"/>
</map>
</property>
<property name="freemarkerSettings">
<props>
<prop key="template_update_delay">1</prop>
<prop key="default_encoding">UTF-8</prop>
<prop key="output_encoding">UTF-8</prop>
<prop key="locale">zh_CN</prop>
<prop key="date_format">yyyy-MM-dd</prop>
<prop key="time_format">HH:mm:ss</prop>
<prop key="datetime_format">yyyy-MM-dd HH:mm:ss</prop>
<prop key="number_format">#.##</prop>
</props>
</property>
</bean>
<!-- JSP定义视图文件解析 -->
<bean id="viewResolver" class="org.springframework.web.servlet.view.InternalResourceViewResolver">
<property name="viewClass" value="org.springframework.web.servlet.view.JstlView"/>
<property name="prefix" value="${web.view.prefix}"/>
<property name="suffix" value="${web.view.suffix}"/>
<property name="order" value="0"/>
</bean>
<!-- 对静态资源文件的访问, 将无法mapping到Controller的path交给default servlet handler处理 -->
<mvc:default-servlet-handler />
<!-- 静态资源映射 -->
<mvc:resources mapping="/assets/**" location="/assets/" cache-period="31536000"/>
<!-- 定义无Controller的path<->view直接映射 -->
<mvc:view-controller path="/" view-name="redirect:${web.view.index}"/>
<!-- 拦截器配置,拦截顺序:先执行后定义的,排在第一位的最后执行。-->
<mvc:interceptors>
<mvc:interceptor>
<mvc:mapping path="${adminPath}/**" />
<mvc:exclude-mapping path="${adminPath}/"/>
<mvc:exclude-mapping path="${adminPath}/login"/>
<mvc:exclude-mapping path="${adminPath}/sys/menu/tree"/>
<mvc:exclude-mapping path="${adminPath}/sys/menu/treeData"/>
<mvc:exclude-mapping path="${adminPath}/oa/oaNotify/self/count"/>
<bean class="com.ejweb.core.filter.LogInterceptor" />
</mvc:interceptor>
<!-- 手机视图拦截器 -->
<mvc:interceptor>
<mvc:mapping path="/**" />
<bean class="com.ejweb.core.filter.MobileInterceptor" />
</mvc:interceptor>
</mvc:interceptors>
<!-- 支持Shiro对Controller的方法级AOP安全控制 begin-->
<bean class="org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator" depends-on="lifecycleBeanPostProcessor">
<property name="proxyTargetClass" value="true" />
</bean>
<bean class="org.springframework.web.servlet.handler.SimpleMappingExceptionResolver">
<property name="exceptionMappings">
<props>
<prop key="org.apache.shiro.authz.UnauthorizedException">error/403</prop>
<prop key="java.lang.Throwable">error/500</prop>
</props>
</property>
</bean>
<!-- 支持Shiro对Controller的方法级AOP安全控制 end -->
<!-- 上传文件拦截,设置最大上传文件大小 10M=10*1024*1024(B)=10485760 bytes -->
<!--<bean id="multipartResolver" class="com.ejweb.core.filter.BaiduCommonsMultipartResolver">
<property name="maxUploadSize" value="${web.maxUploadSize}" />
</bean>-->
</beans>
\ No newline at end of file
/* 前后端通信相关的配置,注释只允许使用多行方式 */
{
/* 上传图片配置项 */
"imageActionName": "uploadimage", /* 执行上传图片的action名称 */
"imageFieldName": "upfile", /* 提交的图片表单名称 */
"imageMaxSize": 2048000, /* 上传大小限制,单位B */
"imageAllowFiles": [".png", ".jpg", ".jpeg", ".gif", ".bmp"], /* 上传图片格式显示 */
"imageCompressEnable": true, /* 是否压缩图片,默认是true */
"imageCompressBorder": 1600, /* 图片压缩最长边限制 */
"imageInsertAlign": "none", /* 插入的图片浮动方式 */
"imageUrlPrefix": "http://localhost:8080/static", /* 图片访问路径前缀 */
"imagePathFormat": "/ueditor/image/{yyyy}{mm}{dd}/{time}{rand:6}", /* 上传保存路径,可以自定义保存路径和文件名格式 */
/* {filename} 会替换成原文件名,配置这项需要注意中文乱码问题 */
/* {rand:6} 会替换成随机数,后面的数字是随机数的位数 */
/* {time} 会替换成时间戳 */
/* {yyyy} 会替换成四位年份 */
/* {yy} 会替换成两位年份 */
/* {mm} 会替换成两位月份 */
/* {dd} 会替换成两位日期 */
/* {hh} 会替换成两位小时 */
/* {ii} 会替换成两位分钟 */
/* {ss} 会替换成两位秒 */
/* 非法字符 \ : * ? " < > | */
/* 具请体看线上文档: fex.baidu.com/ueditor/#use-format_upload_filename */
/* 涂鸦图片上传配置项 */
"scrawlActionName": "uploadscrawl", /* 执行上传涂鸦的action名称 */
"scrawlFieldName": "upfile", /* 提交的图片表单名称 */
"scrawlPathFormat": "/ueditor/image/{yyyy}{mm}{dd}/{time}{rand:6}", /* 上传保存路径,可以自定义保存路径和文件名格式 */
"scrawlMaxSize": 2048000, /* 上传大小限制,单位B */
"scrawlUrlPrefix": "http://localhost:8080/static", /* 图片访问路径前缀 */
"scrawlInsertAlign": "none",
/* 截图工具上传 */
"snapscreenActionName": "uploadimage", /* 执行上传截图的action名称 */
"snapscreenPathFormat": "/ueditor/image/{yyyy}{mm}{dd}/{time}{rand:6}", /* 上传保存路径,可以自定义保存路径和文件名格式 */
"snapscreenUrlPrefix": "http://localhost:8080/static", /* 图片访问路径前缀 */
"snapscreenInsertAlign": "none", /* 插入的图片浮动方式 */
/* 抓取远程图片配置 */
"catcherLocalDomain": ["127.0.0.1", "localhost", "img.baidu.com"],
"catcherActionName": "catchimage", /* 执行抓取远程图片的action名称 */
"catcherFieldName": "source", /* 提交的图片列表表单名称 */
"catcherPathFormat": "/ueditor/image/{yyyy}{mm}{dd}/{time}{rand:6}", /* 上传保存路径,可以自定义保存路径和文件名格式 */
"catcherUrlPrefix": "http://localhost:8080/static", /* 图片访问路径前缀 */
"catcherMaxSize": 2048000, /* 上传大小限制,单位B */
"catcherAllowFiles": [".png", ".jpg", ".jpeg", ".gif", ".bmp"], /* 抓取图片格式显示 */
/* 上传视频配置 */
"videoActionName": "uploadvideo", /* 执行上传视频的action名称 */
"videoFieldName": "upfile", /* 提交的视频表单名称 */
"videoPathFormat": "/ueditor/video/{yyyy}{mm}{dd}/{time}{rand:6}", /* 上传保存路径,可以自定义保存路径和文件名格式 */
"videoUrlPrefix": "http://localhost:8080/static", /* 视频访问路径前缀 */
"videoMaxSize": 102400000, /* 上传大小限制,单位B,默认100MB */
"videoAllowFiles": [
".flv", ".swf", ".mkv", ".avi", ".rm", ".rmvb", ".mpeg", ".mpg",
".ogg", ".ogv", ".mov", ".wmv", ".mp4", ".webm", ".mp3", ".wav", ".mid"], /* 上传视频格式显示 */
/* 上传文件配置 */
"fileActionName": "uploadfile", /* controller里,执行上传视频的action名称 */
"fileFieldName": "upfile", /* 提交的文件表单名称 */
"filePathFormat": "/ueditor/file/{yyyy}{mm}{dd}/{time}{rand:6}", /* 上传保存路径,可以自定义保存路径和文件名格式 */
"fileUrlPrefix": "http://localhost:8080/static", /* 文件访问路径前缀 */
"fileMaxSize": 51200000, /* 上传大小限制,单位B,默认50MB */
"fileAllowFiles": [
".png", ".jpg", ".jpeg", ".gif", ".bmp",
".flv", ".swf", ".mkv", ".avi", ".rm", ".rmvb", ".mpeg", ".mpg",
".ogg", ".ogv", ".mov", ".wmv", ".mp4", ".webm", ".mp3", ".wav", ".mid",
".rar", ".zip", ".tar", ".gz", ".7z", ".bz2", ".cab", ".iso",
".doc", ".docx", ".xls", ".xlsx", ".ppt", ".pptx", ".pdf", ".txt", ".md", ".xml"
], /* 上传文件格式显示 */
/* 列出指定目录下的图片 */
"imageManagerActionName": "listimage", /* 执行图片管理的action名称 */
"imageManagerListPath": "/ueditor/image/none.none", /* 指定要列出图片的目录 */
"imageManagerListSize": 20, /* 每次列出文件数量 */
"imageManagerUrlPrefix": "http://localhost:8080/static", /* 图片访问路径前缀 */
"imageManagerInsertAlign": "none", /* 插入的图片浮动方式 */
"imageManagerAllowFiles": [".png", ".jpg", ".jpeg", ".gif", ".bmp"], /* 列出的文件类型 */
/* 列出指定目录下的文件 */
"fileManagerActionName": "listfile", /* 执行文件管理的action名称 */
"fileManagerListPath": "/ueditor/file/none.none", /* 指定要列出文件的目录 */
"fileManagerUrlPrefix": "http://localhost:8080/static", /* 文件访问路径前缀 */
"fileManagerListSize": 20, /* 每次列出文件数量 */
"fileManagerAllowFiles": [
".png", ".jpg", ".jpeg", ".gif", ".bmp",
".flv", ".swf", ".mkv", ".avi", ".rm", ".rmvb", ".mpeg", ".mpg",
".ogg", ".ogv", ".mov", ".wmv", ".mp4", ".webm", ".mp3", ".wav", ".mid",
".rar", ".zip", ".tar", ".gz", ".7z", ".bz2", ".cab", ".iso",
".doc", ".docx", ".xls", ".xlsx", ".ppt", ".pptx", ".pdf", ".txt", ".md", ".xml"
] /* 列出的文件类型 */
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment