提交 53176e39 作者: chaining

增加忽略文件

父级 bcbb26a2
/target/
/.settings/
/.idea/
/.classpath
/.project
.DS_Store
~/
/logs/
/wios.iml
# 默认忽略的文件
/shelf/
/workspace.xml
# 基于编辑器的 HTTP 客户端请求
/httpRequests/
# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="CompilerConfiguration">
<annotationProcessing>
<profile name="Maven default annotation processors profile" enabled="true">
<sourceOutputDir name="target/generated-sources/annotations" />
<sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
<outputRelativeToContentRoot value="true" />
<module name="nbd-wios-manage" />
</profile>
</annotationProcessing>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Encoding">
<file url="file://$PROJECT_DIR$/src/main/java" charset="UTF-8" />
<file url="file://$PROJECT_DIR$/src/main/resources" charset="UTF-8" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="RemoteRepositoriesConfiguration">
<remote-repository>
<option name="id" value="central" />
<option name="name" value="central" />
<option name="url" value="https://maven.aliyun.com/nexus/content/groups/public" />
</remote-repository>
<remote-repository>
<option name="id" value="cams-releases" />
<option name="name" value="cams-releases" />
<option name="url" value="https://packages.aliyun.com/maven/repository/2105436-release-W8f7J2/" />
</remote-repository>
<remote-repository>
<option name="id" value="central" />
<option name="name" value="Maven Central repository" />
<option name="url" value="https://repo1.maven.org/maven2" />
</remote-repository>
<remote-repository>
<option name="id" value="jboss.community" />
<option name="name" value="JBoss Community repository" />
<option name="url" value="https://repository.jboss.org/nexus/content/repositories/public/" />
</remote-repository>
<remote-repository>
<option name="id" value="rdc-snapshots" />
<option name="name" value="rdc-snapshots" />
<option name="url" value="https://repo.rdc.aliyun.com/repository/42378-snapshot-SzMM2B/" />
</remote-repository>
<remote-repository>
<option name="id" value="snapshots" />
<option name="name" value="snapshots" />
<option name="url" value="https://maven.aliyun.com/nexus/content/groups/public" />
</remote-repository>
<remote-repository>
<option name="id" value="cams-snapshots" />
<option name="name" value="cams-snapshots" />
<option name="url" value="https://packages.aliyun.com/maven/repository/2105436-snapshot-QhOZhi/" />
</remote-repository>
<remote-repository>
<option name="id" value="rdc-releases" />
<option name="name" value="rdc-releases" />
<option name="url" value="https://repo.rdc.aliyun.com/repository/42378-release-YWUwgn/" />
</remote-repository>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ExternalStorageConfigurationManager" enabled="true" />
<component name="MavenProjectsManager">
<option name="originalFiles">
<list>
<option value="$PROJECT_DIR$/pom.xml" />
</list>
</option>
</component>
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" project-jdk-name="18" project-jdk-type="JavaSDK" />
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/warehouse.iml" filepath="$PROJECT_DIR$/.idea/warehouse.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
\ No newline at end of file
<License>
<Data>
<Products>
<Product>Aspose.Total for Java</Product>
<Product>Aspose.Words for Java</Product>
</Products>
<EditionType>Enterprise</EditionType>
<SubscriptionExpiry>20991231</SubscriptionExpiry>
<LicenseExpiry>20991231</LicenseExpiry>
<SerialNumber>8bfe198c-7f0c-4ef8-8ff0-acc3237bf0d7</SerialNumber>
</Data>
<Signature>
sNLLKGMUdF0r8O1kKilWAGdgfs2BvJb/2Xp8p5iuDVfZXmhppo+d0Ran1P9TKdjV4ABwAgKXxJ3jcQTqE/2IRfqwnPf8itN8aFZlV3TJPYeD3yWE7IT55Gz6EijUpC7aKeoohTb4w2fpox58wWoF3SNp6sK6jDfiAUGEHYJ9pjU=
</Signature>
</License>
{
"groups": [
{
"name": "cams",
"type": "com.boco.nbd.wios.core.config.ConfigDicProperties",
"sourceType": "com.boco.nbd.wios.core.config.ConfigDicProperties"
},
{
"name": "sms.aliyun",
"type": "com.boco.nbd.wios.flow.sms.aliyun.properties.AliyunProperties",
"sourceType": "com.boco.nbd.wios.flow.sms.aliyun.properties.AliyunProperties"
}
],
"properties": [
{
"name": "cams.due-date",
"type": "java.util.List<com.boco.nbd.cams.core.entity.config.ConfigIntDic>",
"description": "处理时限",
"sourceType": "com.boco.nbd.wios.core.config.ConfigDicProperties"
},
{
"name": "cams.enum-number-config",
"type": "java.util.List<com.boco.nbd.cams.core.entity.config.ConfigDic>",
"description": "数值类枚举",
"sourceType": "com.boco.nbd.wios.core.config.ConfigDicProperties"
},
{
"name": "cams.enum-string-config",
"type": "java.util.List<com.boco.nbd.cams.core.entity.config.ConfigDic>",
"description": "字符值类枚举",
"sourceType": "com.boco.nbd.wios.core.config.ConfigDicProperties"
},
{
"name": "cams.name",
"type": "java.lang.String",
"sourceType": "com.boco.nbd.wios.core.config.ConfigDicProperties"
},
{
"name": "cams.report-entry",
"type": "java.util.List<com.boco.nbd.wios.core.entity.ReportEntry>",
"description": "报告配置实体",
"sourceType": "com.boco.nbd.wios.core.config.ConfigDicProperties"
},
{
"name": "cams.score-algorithm",
"type": "java.util.List<com.boco.nbd.wios.core.entity.AlgorithmDic>",
"description": "评分自动计算算法",
"sourceType": "com.boco.nbd.wios.core.config.ConfigDicProperties"
},
{
"name": "sms.aliyun.access-key-id",
"type": "java.lang.String",
"description": "accessKeyId.",
"sourceType": "com.boco.nbd.wios.flow.sms.aliyun.properties.AliyunProperties"
},
{
"name": "sms.aliyun.access-key-secret",
"type": "java.lang.String",
"description": "accessKeySecret.",
"sourceType": "com.boco.nbd.wios.flow.sms.aliyun.properties.AliyunProperties"
},
{
"name": "sms.aliyun.endpoint",
"type": "java.lang.String",
"description": "Endpoint.",
"sourceType": "com.boco.nbd.wios.flow.sms.aliyun.properties.AliyunProperties",
"defaultValue": "cn-hangzhou"
},
{
"name": "sms.aliyun.sign-name",
"type": "java.lang.String",
"description": "短信签名.",
"sourceType": "com.boco.nbd.wios.flow.sms.aliyun.properties.AliyunProperties"
},
{
"name": "sms.aliyun.templates",
"type": "java.util.Map<java.lang.String,java.lang.String>",
"description": "短信模板.",
"sourceType": "com.boco.nbd.wios.flow.sms.aliyun.properties.AliyunProperties"
}
],
"hints": []
}
\ No newline at end of file
#farme core部分会读取这部分配置信息<= 导入部分 异常 看源码发现的
# cdn:
cdn.image.url=
# db:
database=mysql
# 配置到bootstrap.yml不生效
spring.main.allow-bean-definition-overriding=false
server:
port: 30350
spring:
application:
name: nbd-wios-manage
zhname: 开迈斯WIOS服务
cloud:
nacos:
# discovery:
# server-addr: ${nacos-server-addr}
# namespace: ${nacos-server-namespace}
# config:
# server-addr: ${nacos-server-addr}
# namespace: ${nacos-server-namespace}
# shared-configs[0].data-id: constant.yml
# shared-configs[0].group: DEFAULT_GROUP
# shared-configs[0].refresh: true
# file-extension: yml #指定配置中心中对应的配置文件的格式
# enabled: true
config:
enabled: false
jta:
enabled: false
\ No newline at end of file
server:
port: 30350
spring:
application:
name: nbd-wios-manage
zhname: 开迈斯WIOS服务
cloud:
nacos:
# discovery:
# server-addr: ${nacos-server-addr}
# namespace: ${nacos-server-namespace}
# config:
# server-addr: ${nacos-server-addr}
# namespace: ${nacos-server-namespace}
# shared-configs[0].data-id: constant.yml
# shared-configs[0].group: DEFAULT_GROUP
# shared-configs[0].refresh: true
# file-extension: yml #指定配置中心中对应的配置文件的格式
# enabled: true
config:
enabled: false
jta:
enabled: false
\ No newline at end of file
server:
port: 30350
#nacos相关参数通过环境变量带入
spring:
application:
name: nbd-wios-manage
zhname: 开迈斯WIOS服务
cloud:
# nacos:
# discovery:
# server-addr: 10.12.1.17:8848
# namespace: ce18ccbc-e054-45ad-893f-ed7ebee1704b
# config:
# server-addr: 10.12.1.17:8848
# namespace: ce18ccbc-e054-45ad-893f-ed7ebee1704b
# shared-configs[0].data-id: constant.yml
# shared-configs[0].group: DEFAULT_GROUP
# shared-configs[0].refresh: true
# file-extension: yml #指定配置中心中对应的配置文件的格式
# enabled: true
# config:
# enabled: false
nacos:
config:
enabled: false
refresh-enabled: false
discovery:
enabled: false
instance-enabled: false
jta:
enabled: false
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!--
根节点:configuration,包含以下三个属性
scan:当属性设置为true时,如果配置文件发生改变,将会被重新加载,默认true
scanPeriod:设置监测配置文件是否修改的时间间隔,没有给出时间单位,默认单位毫秒,scan为true,属性生效,默认时间间隔为1分钟
debug:true,打印logback内部日志信息,实时查看logback运行状态,默认false
子节点:
contextName:设置上下文名称,默认default
property:定义变量值,存在name、value属性
timestamp:时间戳字符串,存在key、dataPattern(遵循java.txt.SimpleDataFormat格式)属性
appender:写日志组件,必要属性name、class,以下子节点详解
encoder:日志格式化
filter:过滤器
-->
<configuration>
<property name="LOG_HOME" value="./logs"></property>
<property name="HISTORY_LOG_HOME" value="${LOG_HOME}/history"></property>
<property name="LOG_PATTERN"
value="%d{yyyy-MM-dd HH:mm:ss.SSS} [%t] [%-5level] %logger{36} [%file:%line] - %msg%n"></property>
<!--console log-->
<appender name="consoleAppender" class="ch.qos.logback.core.ConsoleAppender">
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<!--格式化输出:%d表示日期,%-5level:级别从左显示5个字符宽度,%t表示线程名,%msg:日志消息,%n是换行符-->
<pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} %-5level ${PID:-} --- [%t] %logger{50} - %msg%n</pattern>
</encoder>
</appender>
<!--info log-->
<appender name="infoAppender" class="ch.qos.logback.core.rolling.RollingFileAppender">
<File>${LOG_HOME}/log.log</File>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${HISTORY_LOG_HOME}/%d{yyyy-MM}/log-%d{yyyy-MM-dd}.%i.zip</fileNamePattern>
<maxHistory>30</maxHistory>
<maxFileSize>200MB</maxFileSize>
<totalSizeCap>1GB</totalSizeCap>
</rollingPolicy>
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>${LOG_PATTERN}</pattern>
</encoder>
<Append>false</Append>
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>INFO</level>
</filter>
</appender>
<!--error log-->
<appender name="errorAppender" class="ch.qos.logback.core.rolling.RollingFileAppender">
<File>${LOG_HOME}/error.log</File>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<fileNamePattern>${HISTORY_LOG_HOME}/%d{yyyy-MM}/error-%d{yyyy-MM-dd}.%i.zip</fileNamePattern>
<maxHistory>5</maxHistory>
<maxFileSize>100MB</maxFileSize>
<totalSizeCap>1GB</totalSizeCap>
</rollingPolicy>
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>${LOG_PATTERN}</pattern>
</encoder>
<Append>false</Append>
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>ERROR</level>
</filter>
</appender>
<!--personalize appender start-->
<appender name="startAppender" class="ch.qos.logback.core.FileAppender">
<File>${LOG_HOME}/start.log</File>
<Append>false</Append>
<layout class="ch.qos.logback.classic.PatternLayout">
<Pattern>${LOG_PATTERN}</Pattern>
</layout>
<!-- <Append>false</Append>-->
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>INFO</level>
</filter>
</appender>
<appender name="schedulerJobAppender" class="ch.qos.logback.core.FileAppender">
<File>${LOG_HOME}/job.log</File>
<Append>false</Append>
<layout class="ch.qos.logback.classic.PatternLayout">
<Pattern>${LOG_PATTERN}</Pattern>
</layout>
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>INFO</level>
</filter>
</appender>
<appender name="processAppender" class="ch.qos.logback.core.FileAppender">
<File>${LOG_HOME}/process.log</File>
<Append>false</Append>
<layout class="ch.qos.logback.classic.PatternLayout">
<Pattern>${LOG_PATTERN}</Pattern>
</layout>
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>INFO</level>
</filter>
</appender>
<!--personalize logger start-->
<logger name="com.boco.nbd.wios.microservice.Application" level="INFO" additivity="false">
<appender-ref ref="startAppender"/>
</logger>
<logger name="com.boco.nbd.wios.task" level="INFO" additivity="false">
<appender-ref ref="schedulerJobAppender"/>
</logger>
<logger name="com.boco.nbd.wios.flow.process" level="INFO" additivity="false">
<appender-ref ref="processAppender"/>
</logger>
<root level="INFO">
<appender-ref ref="consoleAppender"/>
<appender-ref ref="infoAppender"/>
<appender-ref ref="errorAppender"/>
</root>
</configuration>
\ 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.boco.nbd.wios.manage.mapper.def.AccountMapperEx" >
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.Account" >
<!--
WARNING - @mbggenerated
This element is automatically generated by MyBatis Generator, do not modify.
This element was generated on Mon May 18 18:39:09 CST 2020.
-->
<id column="id" property="id" jdbcType="INTEGER" />
<result column="account" property="account" jdbcType="VARCHAR" />
<result column="password" property="password" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="phone" property="phone" jdbcType="VARCHAR" />
<result column="job_number" property="jobNumber" jdbcType="VARCHAR" />
<result column="email" property="email" jdbcType="VARCHAR" />
<result column="user_id" property="userId" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="INTEGER" />
<result column="virtual_balance" property="virtualBalance" jdbcType="DECIMAL" />
<result column="power" property="power" jdbcType="DECIMAL" />
<result column="charge_electric" property="chargeElectric" jdbcType="DECIMAL" />
<result column="last_login_time" property="lastLoginTime" jdbcType="TIMESTAMP" />
<result column="create_account_id" property="createAccountId" jdbcType="INTEGER" />
<result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
<result column="update_time" property="updateTime" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Example_Where_Clause" >
<!--
WARNING - @mbggenerated
This element is automatically generated by MyBatis Generator, do not modify.
This element was generated on Mon May 18 18:39:09 CST 2020.
-->
<where >
<foreach collection="oredCriteria" item="criteria" separator="or" >
<if test="criteria.valid" >
<trim prefix="(" suffix=")" prefixOverrides="and" >
<foreach collection="criteria.criteria" item="criterion" >
<choose >
<when test="criterion.noValue" >
and ${criterion.condition}
</when>
<when test="criterion.singleValue" >
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue" >
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue" >
and ${criterion.condition}
<foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List" >
id, account, password, name, phone, job_number, email, user_id , status, virtual_balance, power,
charge_electric, last_login_time, create_account_id, create_time, update_time
</sql>
<select id="selectByPrimaryKeyForUpdate" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
select
<include refid="Base_Column_List" />
from wb_account
where id = #{id,jdbcType=INTEGER}
for update
</select>
<select id="getListForOem" parameterType="com.boco.nbd.wios.manage.entity.bo.AccountBo"
resultType="com.boco.nbd.wios.manage.entity.bo.AccountVo">
select t.*,o.name as oemName,o.id as oemId from wb_account t
inner join t_oem o on t.id=o.wb_account_id
<where>
<if test="phone != null and account !=''">
and t.phone = #{phone}
</if>
<if test="oemId != null">
and o.id = #{oemId}
</if>
<if test="type != null">
and o.type = #{type}
</if>
</where>
</select>
<select id="selectByIds"
resultType="com.boco.nbd.wios.manage.entity.bo.Account">
select t.* from wb_account t
where t.id in
<foreach collection="ids" item="item" index="index" open="(" close=")" separator=",">
#{item}
</foreach>
</select>
<select id="selectByParentIds"
resultType="com.boco.nbd.wios.manage.entity.bo.AccountVo">
select t.*,war.role_id as roleId,wr.name as roleName from wb_account t
left join wb_account_role war on war.account_id = t.id
left join wb_role wr on wr.id = war.role_id
where (
t.parent_id in
<foreach collection="parentIds" item="item" index="index" open="(" close=")" separator=",">
#{item}
</foreach>
or
t.id in
<foreach collection="parentIds" item="item" index="index" open="(" close=")" separator=",">
#{item}
</foreach>
)
<if test="account != null and account !=''">
and t.account = #{account}
</if>
<if test="name != null and name != ''">
<bind name="nameLike" value="'%' + name + '%'"/>
and t.name like #{nameLike}
</if>
</select>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.CamsAccountMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.CamsAccount">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="account_id" jdbcType="INTEGER" property="accountId" />
<result column="department_id" jdbcType="INTEGER" property="departmentId" />
<result column="region_id" jdbcType="VARCHAR" property="regionId" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="create_account" jdbcType="INTEGER" property="createAccount" />
<result column="update_account" jdbcType="INTEGER" property="updateAccount" />
<result column="alarm_id" jdbcType="VARCHAR" property="alarmId" />
</resultMap>
<sql id="Base_Column_List">
id, account_id, department_id, region_id, status, create_time, update_time, create_account,
update_account,alarm_id
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_cams_account
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.CamsAccount">
insert into t_cams_account (id, account_id, department_id,
region_id, status, create_time,
update_time, create_account, update_account,alarm_id
)
values (#{id,jdbcType=INTEGER}, #{accountId,jdbcType=INTEGER}, #{departmentId,jdbcType=INTEGER},
#{regionId,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP},
#{updateTime,jdbcType=TIMESTAMP}, #{createAccount,jdbcType=INTEGER}, #{updateAccount,jdbcType=INTEGER},
#{alarmId,jdbcType=INTEGER}
)
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.CamsAccount">
insert into t_cams_account
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="accountId != null">
account_id,
</if>
<if test="departmentId != null">
department_id,
</if>
<if test="regionId != null">
region_id,
</if>
<if test="status != null">
status,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="createAccount != null">
create_account,
</if>
<if test="updateAccount != null">
update_account,
</if>
<if test="alarmId != null">
alarm_id,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="accountId != null">
#{accountId,jdbcType=INTEGER},
</if>
<if test="departmentId != null">
#{departmentId,jdbcType=INTEGER},
</if>
<if test="regionId != null">
#{regionId,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
#{createAccount,jdbcType=INTEGER},
</if>
<if test="updateAccount != null">
#{updateAccount,jdbcType=INTEGER},
</if>
<if test="alarmId != null">
#{alarmId,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.CamsAccount">
update t_cams_account
<set>
<if test="accountId != null">
account_id = #{accountId,jdbcType=INTEGER},
</if>
<if test="departmentId != null">
department_id = #{departmentId,jdbcType=INTEGER},
</if>
<if test="regionId != null">
region_id = #{regionId,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
create_account = #{createAccount,jdbcType=INTEGER},
</if>
<if test="updateAccount != null">
update_account = #{updateAccount,jdbcType=INTEGER},
</if>
<if test="alarmId != null">
alarm_id = #{alarmId,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.CamsAccount">
update t_cams_account
set account_id = #{accountId,jdbcType=INTEGER},
department_id = #{departmentId,jdbcType=INTEGER},
region_id = #{regionId,jdbcType=VARCHAR},
status = #{status,jdbcType=INTEGER},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP},
create_account = #{createAccount,jdbcType=INTEGER},
update_account = #{updateAccount,jdbcType=INTEGER},
alarm_id = #{alarmId,jdbcType=VARCHAR}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_cams_account
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByAccountIdAndDeptId" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_cams_account
where account_id = #{accountId,jdbcType=INTEGER}
<if test="departmentId != null">
and department_id = #{departmentId,jdbcType=INTEGER}
</if>
</select>
<select id="selectByExample" parameterType="com.boco.nbd.wios.manage.entity.bo.CamsAccount"
resultType="com.boco.nbd.wios.manage.entity.bo.CamsAccountVo">
select t.*,role.name as roleName,
<!-- r.name as regionName, -->
d.name as deptName,a.name as userName,a.email as userEmail,
a.account as userAccount
from t_cams_account t
left join wb_account a on t.account_id=a.id
left join t_department d on t.department_id=d.id
<!-- left join t_region r on t.region_id = r.id -->
left join wb_account_role ar on ar.account_id=a.id
left join wb_role role on role.id=ar.role_id
<where>
t.status != 3
<if test="userName != null and userName != ''">
and a.name = #{userName}
</if>
<if test="account != null and account != ''">
and a.account = #{account}
</if>
<if test="roleId != null">
and ar.role_id = #{roleId}
</if>
<if test="regionId != null">
and find_in_set(#{regionId},t.region_id)
</if>
<if test="alarmId != null">
and find_in_set(#{alarmId},t.alarm_id)
</if>
</where>
order by t.create_time desc
</select>
</mapper>
<?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.boco.nbd.wios.downloadfile.mapper.def.CptDataStoreMapper" >
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.downloadfile.model.CptDataStore" >
<id column="Id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="type" property="type" jdbcType="VARCHAR" />
<result column="path" property="path" jdbcType="VARCHAR" />
<result column="bak_path" property="bakPath" jdbcType="VARCHAR" />
</resultMap>
<sql id="Example_Where_Clause" >
<where >
<foreach collection="oredCriteria" item="criteria" separator="or" >
<if test="criteria.valid" >
<trim prefix="(" suffix=")" prefixOverrides="and" >
<foreach collection="criteria.criteria" item="criterion" >
<choose >
<when test="criterion.noValue" >
and ${criterion.condition}
</when>
<when test="criterion.singleValue" >
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue" >
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue" >
and ${criterion.condition}
<foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause" >
<where >
<foreach collection="example.oredCriteria" item="criteria" separator="or" >
<if test="criteria.valid" >
<trim prefix="(" suffix=")" prefixOverrides="and" >
<foreach collection="criteria.criteria" item="criterion" >
<choose >
<when test="criterion.noValue" >
and ${criterion.condition}
</when>
<when test="criterion.singleValue" >
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue" >
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue" >
and ${criterion.condition}
<foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List" >
Id, name, type, path, bak_path
</sql>
<select id="selectByExample" resultMap="BaseResultMap" parameterType="com.boco.nbd.wios.downloadfile.model.CptDataStoreCriteria" >
select
<if test="distinct" >
distinct
</if>
<include refid="Base_Column_List" />
from cpt_datastore
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null" >
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from cpt_datastore
where Id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from cpt_datastore
where Id = #{id,jdbcType=VARCHAR}
</delete>
<delete id="deleteByExample" parameterType="com.boco.nbd.wios.downloadfile.model.CptDataStoreCriteria" >
delete from cpt_datastore
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.downloadfile.model.CptDataStore" >
insert into cpt_datastore (Id, name, type,
path, bak_path)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR},
#{path,jdbcType=VARCHAR}, #{bakPath,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.boco.nbd.wios.downloadfile.model.CptDataStore" >
insert into cpt_datastore
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
Id,
</if>
<if test="name != null" >
name,
</if>
<if test="type != null" >
type,
</if>
<if test="path != null" >
path,
</if>
<if test="bakPath != null" >
bak_path,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="type != null" >
#{type,jdbcType=VARCHAR},
</if>
<if test="path != null" >
#{path,jdbcType=VARCHAR},
</if>
<if test="bakPath != null" >
#{bakPath,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.boco.nbd.wios.downloadfile.model.CptDataStoreCriteria" resultType="java.lang.Integer" >
select count(*) from cpt_datastore
<if test="_parameter != null" >
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map" >
update cpt_datastore
<set >
<if test="record.id != null" >
Id = #{record.id,jdbcType=VARCHAR},
</if>
<if test="record.name != null" >
name = #{record.name,jdbcType=VARCHAR},
</if>
<if test="record.type != null" >
type = #{record.type,jdbcType=VARCHAR},
</if>
<if test="record.path != null" >
path = #{record.path,jdbcType=VARCHAR},
</if>
<if test="record.bakPath != null" >
bak_path = #{record.bakPath,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null" >
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map" >
update cpt_datastore
set Id = #{record.id,jdbcType=VARCHAR},
name = #{record.name,jdbcType=VARCHAR},
type = #{record.type,jdbcType=VARCHAR},
path = #{record.path,jdbcType=VARCHAR},
bak_path = #{record.bakPath,jdbcType=VARCHAR}
<if test="_parameter != null" >
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.boco.nbd.wios.downloadfile.model.CptDataStore" >
update cpt_datastore
<set >
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="type != null" >
type = #{type,jdbcType=VARCHAR},
</if>
<if test="path != null" >
path = #{path,jdbcType=VARCHAR},
</if>
<if test="bakPath != null" >
bak_path = #{bakPath,jdbcType=VARCHAR},
</if>
</set>
where Id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.boco.nbd.wios.downloadfile.model.CptDataStore" >
update cpt_datastore
set name = #{name,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
path = #{path,jdbcType=VARCHAR},
bak_path = #{bakPath,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.boco.nbd.wios.manage.mapper.def.DepartmentMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.Department">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="region_id" jdbcType="INTEGER" property="regionId" />
<result column="address" jdbcType="VARCHAR" property="address" />
<result column="parent_id" jdbcType="INTEGER" property="parentId" />
<result column="id_tree" jdbcType="VARCHAR" property="idTree" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="create_account" jdbcType="INTEGER" property="createAccount" />
<result column="update_account" jdbcType="INTEGER" property="updateAccount" />
</resultMap>
<sql id="Base_Column_List">
id, name, region_id, address, parent_id, id_tree, remark, status, create_time, update_time,
create_account, update_account
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_department
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.Department"
useGeneratedKeys="true" keyProperty="id">
insert into t_department (id, name, region_id,
address, parent_id, id_tree,
remark, status, create_time,
update_time, create_account, update_account
)
values (#{id,jdbcType=INTEGER}, #{name,jdbcType=VARCHAR}, #{regionId,jdbcType=INTEGER},
#{address,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER}, #{idTree,jdbcType=VARCHAR},
#{remark,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP},
#{updateTime,jdbcType=TIMESTAMP}, #{createAccount,jdbcType=INTEGER}, #{updateAccount,jdbcType=INTEGER}
)
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.Department">
insert into t_department
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="name != null">
name,
</if>
<if test="regionId != null">
region_id,
</if>
<if test="address != null">
address,
</if>
<if test="parentId != null">
parent_id,
</if>
<if test="idTree != null">
id_tree,
</if>
<if test="remark != null">
remark,
</if>
<if test="status != null">
status,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="createAccount != null">
create_account,
</if>
<if test="updateAccount != null">
update_account,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="regionId != null">
#{regionId,jdbcType=INTEGER},
</if>
<if test="address != null">
#{address,jdbcType=VARCHAR},
</if>
<if test="parentId != null">
#{parentId,jdbcType=INTEGER},
</if>
<if test="idTree != null">
#{idTree,jdbcType=VARCHAR},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
#{createAccount,jdbcType=INTEGER},
</if>
<if test="updateAccount != null">
#{updateAccount,jdbcType=INTEGER},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.Department">
update t_department
<set>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="regionId != null">
region_id = #{regionId,jdbcType=INTEGER},
</if>
<if test="address != null">
address = #{address,jdbcType=VARCHAR},
</if>
<if test="parentId != null">
parent_id = #{parentId,jdbcType=INTEGER},
</if>
<if test="idTree != null">
id_tree = #{idTree,jdbcType=VARCHAR},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
create_account = #{createAccount,jdbcType=INTEGER},
</if>
<if test="updateAccount != null">
update_account = #{updateAccount,jdbcType=INTEGER},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.Department">
update t_department
set name = #{name,jdbcType=VARCHAR},
region_id = #{regionId,jdbcType=INTEGER},
address = #{address,jdbcType=VARCHAR},
parent_id = #{parentId,jdbcType=INTEGER},
id_tree = #{idTree,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
status = #{status,jdbcType=INTEGER},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP},
create_account = #{createAccount,jdbcType=INTEGER},
update_account = #{updateAccount,jdbcType=INTEGER}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_department
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectAll" parameterType="java.lang.Integer"
resultType="com.boco.nbd.wios.manage.entity.bo.DepartmentVo">
select t.*,r.name as regionName from t_department t
left join t_region r on r.id=t.region_id
<where>
<if test="status != null">
and t.status = #{status}
</if>
</where>
</select>
<update id="updateIdTree">
update t_department
set id_tree = concat(#{idTreeNewPrefix},substring(id_tree,length(#{idTreePrefix})+1,length(id_tree)))
where id_tree like concat(#{idTreePrefix},'%')
</update>
<select id="selectByParentId" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_department
where parent_id = #{parentId,jdbcType=INTEGER} and status=1
</select>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.DictionaryMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.Dictionary">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="value" jdbcType="VARCHAR" property="value" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="sort_time" jdbcType="TIMESTAMP" property="sortTime" />
<result column="create_account" jdbcType="VARCHAR" property="createAccount" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="modify_account" jdbcType="VARCHAR" property="modifyAccount" />
<result column="modify_time" jdbcType="TIMESTAMP" property="modifyTime" />
<result column="is_settle" jdbcType="INTEGER" property="isSettle" />
<result column="multiple" jdbcType="INTEGER" property="multiple" />
<result column="device_len" jdbcType="INTEGER" property="deviceLen" />
</resultMap>
<sql id="Base_Column_List">
id, type, name, value, status, sort_time, create_account, create_time, modify_account,
modify_time,is_settle,multiple,device_len
</sql>
<delete id="delete" parameterType="java.lang.String">
delete from t_dictionary
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.Dictionary">
insert into t_dictionary (id, type, name,
value, status, sort_time,
create_account, create_time, modify_account,
modify_time,is_settle,multiple,device_len)
values (#{id,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{value,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, #{sortTime,jdbcType=TIMESTAMP},
#{createAccount,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{modifyAccount,jdbcType=VARCHAR},
#{modifyTime,jdbcType=TIMESTAMP}, #{isSettle,jdbcType=INTEGER}, #{multiple,jdbcType=INTEGER}, #{deviceLen,jdbcType=INTEGER})
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.Dictionary">
insert into t_dictionary
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="type != null">
type,
</if>
<if test="name != null">
name,
</if>
<if test="value != null">
value,
</if>
<if test="status != null">
status,
</if>
<if test="sortTime != null">
sort_time,
</if>
<if test="createAccount != null">
create_account,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="modifyAccount != null">
modify_account,
</if>
<if test="modifyTime != null">
modify_time,
</if>
<if test="isSettle != null">
is_settle,
</if>
<if test="multiple != null">
multiple,
</if>
<if test="deviceLen != null">
device_len,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="value != null">
#{value,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=INTEGER},
</if>
<if test="sortTime != null">
#{sortTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
#{createAccount,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="modifyAccount != null">
#{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
#{modifyTime,jdbcType=TIMESTAMP},
</if>
<if test="isSettle != null">
#{isSettle,jdbcType=INTEGER},
</if>
<if test="multiple != null">
#{multiple,jdbcType=INTEGER},
</if>
<if test="deviceLen != null">
#{deviceLen,jdbcType=INTEGER},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.Dictionary">
update t_dictionary
<set>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="value != null">
value = #{value,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="sortTime != null">
sort_time = #{sortTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
create_account = #{createAccount,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="modifyAccount != null">
modify_account = #{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
<if test="isSettle != null">
is_settle = #{isSettle,jdbcType=INTEGER},
</if>
<if test="multiple != null">
multiple = #{multiple,jdbcType=INTEGER},
</if>
<if test="deviceLen != null">
device_len = #{deviceLen,jdbcType=INTEGER},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.Dictionary">
update t_dictionary
set type = #{type,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
value = #{value,jdbcType=VARCHAR},
status = #{status,jdbcType=INTEGER},
sort_time = #{sortTime,jdbcType=TIMESTAMP},
create_account = #{createAccount,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
modify_account = #{modifyAccount,jdbcType=VARCHAR},
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
is_settle = #{isSettle,jdbcType=INTEGER},
multiple = #{multiple,jdbcType=INTEGER},
device_len = #{deviceLen,jdbcType=INTEGER}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectById" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_dictionary
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="selectValidByType" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_dictionary t
<where>
status=1
<if test="type != null">
and t.type = #{type}
</if>
<if test="name != null and name != ''">
and t.name = #{name}
</if>
<if test="value != null and value != ''">
and t.value = #{value}
</if>
</where>
order by t.value
</select>
<select id="selectValidById" resultType="com.boco.nbd.wios.manage.entity.bo.Dictionary">
select
<include refid="Base_Column_List" />
from t_dictionary t
<where>
status=1
<if test="type != null">
and t.type = #{type}
</if>
<if test="name != null and name != ''">
and t.name = #{name}
</if>
<if test="id != null and id != ''">
and t.id != #{id}
</if>
</where>
</select>
<delete id="deleteByType" parameterType="java.lang.String">
delete from t_dictionary
where type = #{type}
</delete>
<insert id="batchInsert" parameterType="java.util.List">
insert into t_dictionary (id, type, name,
value, status, sort_time,
create_account, create_time, modify_account,
modify_time,is_settle,multiple,device_len)
values
<foreach collection="list" item="item" separator=",">
(#{item.id,jdbcType=VARCHAR}, #{item.type,jdbcType=VARCHAR}, #{item.name,jdbcType=VARCHAR},
#{item.value,jdbcType=VARCHAR}, #{item.status,jdbcType=INTEGER}, #{item.sortTime,jdbcType=TIMESTAMP},
#{item.createAccount,jdbcType=VARCHAR}, #{item.createTime,jdbcType=TIMESTAMP}, #{item.modifyAccount,jdbcType=VARCHAR},
#{item.modifyTime,jdbcType=TIMESTAMP},#{item.isSettle,jdbcType=INTEGER},#{item.multiple,jdbcType=INTEGER},#{item.deviceLen,jdbcType=INTEGER})
</foreach>
</insert>
</mapper>
<?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.boco.nbd.wios.flow.mapper.def.EvaluationStatisticsMapper">
<select id="getNormalOrderFiled" parameterType="com.boco.nbd.wios.flow.entity.qo.EvaluationStatisticsQo" resultType="com.boco.nbd.wios.flow.entity.po.OrderPO">
select *
from t_order
where type=1 and process_ins_id is not null and (node_flag!=199 and status=64)=false
<if test="startTime != null and startTime != ''">
and DATE_FORMAT(create_time,'%Y-%m-%d')&gt;= #{startTime}
</if>
<if test="endTime != null and endTime != ''">
and DATE_FORMAT(create_time,'%Y-%m-%d')&lt;= #{endTime}
</if>
<if test="installSupplierId != null and installSupplierId != ''" >
and install_supplier_id = #{installSupplierId}
</if>
<if test="areaId != null and areaId != ''" >
and area_id = #{areaId}
</if>
<if test="electricExpand != null and electricExpand != ''">
and electric_expand = #{electricExpand}
</if>
<if test="nodeFlag != null ">
and node_flag in
<foreach collection="nodeFlag" item="nodeFlag" open="(" separator="," close=")">
#{nodeFlag}
</foreach>
</if>
</select>
<select id="getOrderFiled" parameterType="com.boco.nbd.wios.flow.entity.qo.EvaluationStatisticsQo" resultType="com.boco.nbd.wios.flow.entity.po.OrderPO">
select *
from t_order
where type=1 and process_ins_id is not null and node_flag = '199'
<if test='timeType == "1"'>
and DATE_FORMAT(create_time,'%Y-%m-%d')&gt;= #{startTime}
and DATE_FORMAT(create_time,'%Y-%m-%d')&lt;= #{endTime}
</if>
<if test='timeType == "2"'>
and DATE_FORMAT(close_time,'%Y-%m-%d')&gt;= #{startTime}
and DATE_FORMAT(close_time,'%Y-%m-%d')&lt;= #{endTime}
</if>
<if test="installSupplierId != null and installSupplierId != ''" >
and install_supplier_id = #{installSupplierId}
</if>
<if test="areaId != null and areaId != ''" >
and area_id = #{areaId}
</if>
<if test="electricExpand != null and electricExpand != ''">
and electric_expand = #{electricExpand}
</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.boco.nbd.wios.manage.mapper.def.ExpandPriceMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.ExpandPrice">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="region_id" jdbcType="INTEGER" property="regionId" />
<result column="region_name" jdbcType="VARCHAR" property="regionName" />
<result column="price" jdbcType="DECIMAL" property="price" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="create_account" jdbcType="VARCHAR" property="createAccount" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="update_account" jdbcType="VARCHAR" property="updateAccount" />
</resultMap>
<sql id="Base_Column_List">
id, region_id, region_name, price, status, create_time, create_account, update_time,
update_account
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_expand_price
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.ExpandPrice">
insert into t_expand_price (id, region_id, region_name,
price, status, create_time,
create_account, update_time, update_account
)
values (#{id,jdbcType=INTEGER}, #{regionId,jdbcType=INTEGER}, #{regionName,jdbcType=VARCHAR},
#{price,jdbcType=DECIMAL}, #{status,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP},
#{createAccount,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{updateAccount,jdbcType=VARCHAR}
)
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.ExpandPrice">
insert into t_expand_price
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="regionId != null">
region_id,
</if>
<if test="regionName != null">
region_name,
</if>
<if test="price != null">
price,
</if>
<if test="status != null">
status,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="createAccount != null">
create_account,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="updateAccount != null">
update_account,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="regionId != null">
#{regionId,jdbcType=INTEGER},
</if>
<if test="regionName != null">
#{regionName,jdbcType=VARCHAR},
</if>
<if test="price != null">
#{price,jdbcType=DECIMAL},
</if>
<if test="status != null">
#{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
#{createAccount,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="updateAccount != null">
#{updateAccount,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.ExpandPrice">
update t_expand_price
<set>
<if test="regionId != null">
region_id = #{regionId,jdbcType=INTEGER},
</if>
<if test="regionName != null">
region_name = #{regionName,jdbcType=VARCHAR},
</if>
<if test="price != null">
price = #{price,jdbcType=DECIMAL},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
create_account = #{createAccount,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="updateAccount != null">
update_account = #{updateAccount,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.ExpandPrice">
update t_expand_price
set region_id = #{regionId,jdbcType=INTEGER},
region_name = #{regionName,jdbcType=VARCHAR},
price = #{price,jdbcType=DECIMAL},
status = #{status,jdbcType=INTEGER},
create_time = #{createTime,jdbcType=TIMESTAMP},
create_account = #{createAccount,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
update_account = #{updateAccount,jdbcType=VARCHAR}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_expand_price
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByRegionId" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_expand_price
where status = 1
<if test="regionId != null and regionId != ''">
and region_id = #{regionId,jdbcType=INTEGER}
</if>
order by create_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.boco.nbd.wios.flow.mapper.def.FlowMapper">
</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.boco.nbd.wios.flow.mapper.def.FlowOrderInstallMapper">
</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.boco.nbd.wios.flow.mapper.def.FlowOrderSurveyMapper">
</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.boco.nbd.wios.flow.mapper.def.GroupMapper">
<delete id="deleteNodeGroup">
delete
from tv3_lug_node_group
where group_id = #{groupId}
</delete>
<delete id="deleteUserGroup">
delete
from tv3_lug_group_user
where group_id = #{groupId}
</delete>
</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.boco.nbd.wios.flow.mapper.def.HolidayMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.flow.entity.po.HolidayPO">
<result property="id" column="id" jdbcType="VARCHAR"/>
<result property="holidayDate" column="holiday_date" jdbcType="TIMESTAMP"/>
<result property="holidayDesc" column="holiday_desc" jdbcType="VARCHAR"/>
<result property="holidayType" column="holiday_type" jdbcType="VARCHAR"/>
</resultMap>
<sql id="Base_Column_List">
id,holiday_date,holiday_desc,holiday_type
</sql>
<select id="getList" resultType="com.boco.nbd.wios.flow.entity.po.HolidayPO">
select <include refid="Base_Column_List" /> from t_holiday where holiday_date like #{date}"%" order by holiday_date asc
</select>
<select id="getListByType" resultType="java.lang.String">
select holiday_date from t_holiday where holiday_type=#{holidayType} and holiday_date like #{date}"%" order by holiday_date asc
</select>
</mapper>
<?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.boco.nbd.wios.flow.mapper.def.ImportOrderMapper">
<select id="getImportOrderAll" resultType="com.boco.nbd.wios.flow.entity.bo.OrderTempBO">
select a.id,
a.oem_name,
b.code oem_code,
c.name region_name,
a.address,
case a.user_sex when 0 then '女' when 1 then '男' else '未知' end user_sex,
a.user_phone,
case a.survey_before_sale_enable when 0 then '否' when 1 then '是' end survey_before_sale_enable,
a.vehicle_model,
a.vehicle_chassis_no,
a.wallbox_model,
a.vehicle_parking_status,
a.vehicle_parking_no,
a.out_order_id,
date_format(a.invoice_time, '%Y-%m-%d') invoice_time,
a.oem_agent_name,
a.oem_agent_contact_name,
a.oem_agent_info,
case a.estate_type when 1 then '普通高层' when 2 then '商用两住' when 3 then '别墅' when 4 then '公司' when 5 then '厂房' when 6 then '自建房' when 7 then '其他' end estate_type,
case a.has_independent_parking when 0 then '否' when 1 then '是' end has_independent_parking,
case a.install_position when 1 then '室内' when 2 then '室外' end install_position,
case a.property_agree when 0 then '不同意' when 1 then '同意' end property_agree,
case a.electric_expand when 0 then '否' when 1 then '是' end electric_expand,
case a.need_erect_pile when 0 then '否' when 1 then '是' end need_erect_pile,
case a.manu_dispatch_enable when 0 then '否' when 1 then '是' end manu_dispatch_enable,
case a.is_need_survey when 0 then '否' when 1 then '是' end is_need_survey,
case a.install_emergency_level when 1 then '一般' when 2 then '紧急' end install_emergency_level
from t_order_temp a
left join t_oem b on a.oem_id = b.id
left join t_region c on a.region_id = c.id
where a.type=#{type}
</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.boco.nbd.wios.manage.mapper.def.InfoConfigMapper" >
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.InfoConfig" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="type" property="type" jdbcType="INTEGER" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
<result column="modify_time" property="modifyTime" jdbcType="TIMESTAMP" />
<result column="is_del" property="isDel" jdbcType="INTEGER" />
</resultMap>
<sql id="Base_Column_List" >
id, type, name, create_time, modify_time, is_del
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from t_info_config
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="selectValidNameType" resultType="com.boco.nbd.wios.manage.entity.bo.InfoConfig">
SELECT
<include refid="Base_Column_List" />
FROM
t_info_config
<where>
is_del=0
<if test="type != null">
and type =#{type,jdbcType=INTEGER}
</if>
<if test="name != null and name != ''">
<bind name="nameLike" value="'%' + name + '%'"/>
and name like #{nameLike}
</if>
</where>
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from t_info_config
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.InfoConfig" >
insert into t_info_config (id, type, name,
create_time, modify_time, is_del
)
values (#{id,jdbcType=VARCHAR}, #{type,jdbcType=INTEGER}, #{name,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{modifyTime,jdbcType=TIMESTAMP}, #{isDel,jdbcType=INTEGER}
)
</insert>
<insert id="insertSelective" parameterType="com.boco.nbd.wios.manage.entity.bo.InfoConfig" >
insert into t_info_config
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="type != null" >
type,
</if>
<if test="name != null" >
name,
</if>
<if test="createTime != null" >
create_time,
</if>
<if test="modifyTime != null" >
modify_time,
</if>
<if test="isDel != null" >
is_del,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="type != null" >
#{type,jdbcType=INTEGER},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="createTime != null" >
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="modifyTime != null" >
#{modifyTime,jdbcType=TIMESTAMP},
</if>
<if test="isDel != null" >
#{isDel,jdbcType=INTEGER},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.boco.nbd.wios.manage.entity.bo.InfoConfig" >
update t_info_config
<set >
<if test="type != null" >
type = #{type,jdbcType=INTEGER},
</if>
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="createTime != null" >
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="modifyTime != null" >
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
<if test="isDel != null" >
is_del = #{isDel,jdbcType=INTEGER},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.boco.nbd.wios.manage.entity.bo.InfoConfig">
update t_info_config
set type = #{type,jdbcType=INTEGER},
name = #{name,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
is_del = #{isDel,jdbcType=INTEGER}
where id = #{id,jdbcType=VARCHAR}
</update>
</mapper>
<?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.boco.nbd.wios.log.mapper.def.InterfaceMonitorMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.log.entity.po.InterfaceMonitorPO">
<result property="interfaceName" column="interface_name" jdbcType="VARCHAR"/>
<result property="interfaceAddress" column="interface_address" jdbcType="VARCHAR"/>
<result property="orderNo" column="order_no" jdbcType="VARCHAR"/>
<result property="responseData" column="response_data" jdbcType="VARCHAR"/>
<result property="responseTime" column="response_time" jdbcType="INTEGER"/>
<result property="interfaceState" column="interface_state" jdbcType="INTEGER"/>
<result property="callTime" column="call_time" jdbcType="TIMESTAMP"/>
</resultMap>
<sql id="QuerySql">
<where>
<if test="interfaceName != null and interfaceName != ''">
and interface_name = #{interfaceName}
</if>
<if test="interfaceState != null and interfaceState != ''">
and interface_state = #{interfaceState}
</if>
<if test="startTime != null and startTime != '' ">
<if test='timeType == "hour"'>
and DATE_FORMAT(call_time,'%Y-%m-%d %H:%i:%s') &gt;= #{startTime}
</if>
<if test='timeType == "day"'>
and DATE_FORMAT(call_time,'%Y-%m-%d') &gt;= #{startTime}
</if>
</if>
<if test="endTime != null and endTime != '' ">
<if test='timeType == "hour"'>
and DATE_FORMAT(call_time,'%Y-%m-%d %H:%i:%s') &lt;= #{endTime}
</if>
<if test='timeType == "day"'>
and DATE_FORMAT(call_time,'%Y-%m-%d') &lt;= #{endTime}
</if>
</if>
</where>
</sql>
<select id="getInterfaceMonitorList" parameterType="com.boco.nbd.wios.log.entity.qo.InterfaceMonitorQO" resultType="com.boco.nbd.wios.log.entity.po.InterfaceMonitorPO">
select interface_name,interface_address,order_no,
response_data,response_time,
CASE interface_state WHEN '1' THEN '正常' ELSE '异常' END interface_state,
call_time
from t_interface_monitor <include refid="QuerySql"/>
</select>
<select id="getInterfaceMonitorCount" parameterType="com.boco.nbd.wios.log.entity.qo.InterfaceMonitorQO" resultType="java.lang.Integer">
select count(*) from t_interface_monitor <include refid="QuerySql"/>
</select>
<resultMap id="InterfaceMonitorCountMap" type="java.util.HashMap">
<result column="name" property="key" javaType="java.lang.String"/>
<result column="num" property="value" javaType="java.lang.Integer"/>
</resultMap>
<select id="getInterfaceMonitorCountMap" parameterType="com.boco.nbd.wios.log.entity.qo.InterfaceMonitorQO" resultMap="InterfaceMonitorCountMap">
select response_data name,count(*) num from t_interface_monitor <include refid="QuerySql"/> GROUP BY response_data
</select>
<select id="getInterfaceMonitorMothCountMap" parameterType="com.boco.nbd.wios.log.entity.qo.InterfaceMonitorQO" resultMap="InterfaceMonitorCountMap">
select DATE_FORMAT( call_time, '%Y-%m-%d' ) name,count(*) num from t_interface_monitor <include refid="QuerySql"/> GROUP BY DATE_FORMAT( call_time, '%Y-%m-%d' )
</select>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.MaterialConfigMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.MaterialConfig">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="type" jdbcType="INTEGER" property="type" />
<result column="region_id" jdbcType="INTEGER" property="regionId" />
<result column="oem_id" jdbcType="INTEGER" property="oemId" />
<result column="content" jdbcType="VARCHAR" property="content" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="create_account" jdbcType="VARCHAR" property="createAccount" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="update_account" jdbcType="VARCHAR" property="updateAccount" />
</resultMap>
<sql id="Base_Column_List">
id, type, region_id, oem_id, content, status, create_time, create_account, update_time,
update_account
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_material_config
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.MaterialConfig">
insert into t_material_config (id, type, region_id,
oem_id, content, status,
create_time, create_account, update_time,
update_account)
values (#{id,jdbcType=INTEGER}, #{type,jdbcType=INTEGER}, #{regionId,jdbcType=INTEGER},
#{oemId,jdbcType=INTEGER}, #{content,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER},
#{createTime,jdbcType=TIMESTAMP}, #{createAccount,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP},
#{updateAccount,jdbcType=VARCHAR})
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.MaterialConfig">
insert into t_material_config
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="type != null">
type,
</if>
<if test="regionId != null">
region_id,
</if>
<if test="oemId != null">
oem_id,
</if>
<if test="content != null">
content,
</if>
<if test="status != null">
status,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="createAccount != null">
create_account,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="updateAccount != null">
update_account,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="type != null">
#{type,jdbcType=INTEGER},
</if>
<if test="regionId != null">
#{regionId,jdbcType=INTEGER},
</if>
<if test="oemId != null">
#{oemId,jdbcType=INTEGER},
</if>
<if test="content != null">
#{content,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
#{createAccount,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="updateAccount != null">
#{updateAccount,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.MaterialConfig">
update t_material_config
<set>
<if test="type != null">
type = #{type,jdbcType=INTEGER},
</if>
<!-- <if test="regionId != null"> -->
region_id = #{regionId,jdbcType=INTEGER},
<!-- </if>
<if test="oemId != null"> -->
oem_id = #{oemId,jdbcType=INTEGER},
<!-- </if>
<if test="content != null"> -->
content = #{content,jdbcType=VARCHAR},
<!-- </if> -->
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="createAccount != null">
create_account = #{createAccount,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="updateAccount != null">
update_account = #{updateAccount,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.MaterialConfig">
update t_material_config
set type = #{type,jdbcType=INTEGER},
region_id = #{regionId,jdbcType=INTEGER},
oem_id = #{oemId,jdbcType=INTEGER},
content = #{content,jdbcType=VARCHAR},
status = #{status,jdbcType=INTEGER},
create_time = #{createTime,jdbcType=TIMESTAMP},
create_account = #{createAccount,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
update_account = #{updateAccount,jdbcType=VARCHAR}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultType="com.boco.nbd.wios.manage.entity.bo.MaterialConfigVo">
select
t.id,
t.type,
t.region_id,
t.oem_id,
t.status,
t.content,
t.create_time,
t.create_account,
t.update_time,
t.update_account,
r.name as regionName,
o.name as oemName,
r.id_tree as regionTree
from t_material_config t
left join t_region r on r.id=t.region_id
left join t_oem o on o.id=t.oem_id
where t.id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByExample" parameterType="com.boco.nbd.wios.manage.entity.bo.MaterialConfigBo"
resultType="com.boco.nbd.wios.manage.entity.bo.MaterialConfigVo">
select
t.id, t.type, t.region_id, t.oem_id,t.content, t.status, t.create_time, t.create_account, t.update_time,
t.update_account
,r.name as regionName,o.name as oemName from t_material_config t
left join t_region r on r.id=t.region_id
left join t_oem o on o.id=t.oem_id
<where>
t.status = 1
<if test="regionId != null">
and t.region_id = #{regionId}
</if>
<if test="oemId != null">
and t.oem_id = #{oemId}
</if>
<if test="type != null">
and t.type = #{type}
</if>
<if test="oemName != null and oemName != ''">
<bind name="oemNameLike" value="'%' + oemName + '%'"/>
and o.name like #{oemNameLike}
</if>
</where>
order by t.create_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.boco.nbd.wios.flow.mapper.def.MenuFieldMapper">
</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.boco.nbd.wios.flow.mapper.def.NodeMapper">
<!--获取节点配置的用户组 -->
<select id="getNodeGroupsInfo" parameterType="Long"
resultType="com.boco.nbd.wios.flow.entity.bo.NodeGroupBO">
SELECT
a.flow_id,
a.flow_code,
b.node_id,
b.node_code,
b.node_name,
d.group_id,
d.group_name
FROM
tv3_lug_groups d
left join tv3_lug_node_group c on c.group_id = d.group_id
left join tv3_lug_nodes b on b.node_id = c.node_id
<if test="nodeId !=null">
AND b.node_id = #{nodeId}
</if>
left join tv3_lug_flows a on a.flow_id = b.flow_id
WHERE 1 = 1
<if test="nodeId !=null">
AND b.node_id = #{nodeId}
</if>
ORDER BY b.node_id
</select>
<!-- 解除节点和组的关系 -->
<delete id="deleteGroupNode">
delete
from tv3_lug_node_group
where node_id = #{nodeId}
</delete>
<!-- 绑定节点和组 -->
<select id="bindGroupNode" resultType="Integer">
insert into tv3_lug_node_group
(node_id, group_id)
values (#{nodeId}, #{groupId})
</select>
<select id="selectByFlowIdAndNodeCode" resultType="com.boco.nbd.wios.flow.entity.po.FlowNodePO">
select a.flow_id,
a.category_name,
a.flow_code,
a.flow_name,
b.node_id,
b.node_code,
b.node_name
from tv3_lug_flows a,
tv3_lug_nodes b
where a.flow_id = b.flow_id
<if test="flowCode !=null">
AND b.flow_code = #{flowCode}
</if>
<if test="nodeCode !=null">
and node_code = #{nodeCode}
</if>
</select>
<!-- 据组ID删除成员 -->
<delete id="deleteGroupUser">
delete
from tv3_lug_group_user
where group_id = #{groupId}
</delete>
<insert id="bindGroupUser">
insert into tv3_lug_group_user (group_id, user_id)
values (#{groupId}, #{userId})
</insert>
<select id="getRoles">
select a.id role_id, a.name role_name
from wb_role a
where a.status = 1
order by a.id
</select>
<!--主机厂加载CAMS用户
select b.type vendor_type, a.id user_id,b.id vendor_id,b.name vendor_name from wb_account a
inner join t_oem b on (a.parent_id=b.wb_account_id or a.id=b.wb_account_id)
inner join t_oem_contract c on b.id = c.oem_id and c.status = 2
union all
-->
<select id="loadUsers" resultType="com.boco.nbd.wios.flow.entity.po.UserPO">
select a.*,b.name user_name,b.phone, d.id role_id, d.name role_name from
(
select 0 vendor_type,a.id user_id,-1 vendor_id,'CAMS' vendor_name from wb_account a where a.parent_id is null
union all
select 0 vendor_type,a.id user_id,-1 vendor_id,'CAMS' vendor_name from wb_account a
inner join t_cams_account b on a.id=b.account_id
union all
select 3 vendor_type,a.id user_id,c.id vendor_id,c.name vendor_id
from wb_account a
inner join t_supplier c on (c.account_id=a.id or c.account_id=a.parent_id)) a
inner join wb_account b on a.user_id=b.id
inner join wb_account_role c on c.account_id=b.id
inner join wb_role d on c.role_id=d.id
where b.status = 1
<if test="vendorId != null and vendorId!=0">
and (a.vendor_id=#{vendorId} or (a.vendor_id=-1 and exists(select 1 from t_oem where id=#{vendorId})))
</if>
order by a.vendor_type
</select>
<!--主机厂加载CAMS用户
union all
select b.type vendor_type,a.id user_id,b.id vendor_id,b.name vendor_name from wb_account a
inner join t_oem b on (a.parent_id=b.wb_account_id or a.id=b.wb_account_id)
inner join t_oem_contract c on b.id = c.oem_id and c.status = 2
-->
<select id="getUserByGroup" parameterType="java.lang.Long" resultType="com.boco.nbd.wios.flow.entity.po.UserPO">
select a.*,b.name user_name,b.phone, d.id role_id, d.name role_name,e.group_id from
(
select 0 vendor_type,a.id user_id,-1 vendor_id,'CAMS' vendor_name from wb_account a where a.parent_id is null
union all
select 0 vendor_type,a.id user_id,-1 vendor_id,'CAMS' vendor_name from wb_account a
inner join t_cams_account b on a.id=b.account_id
union all
select 3 vendor_type,a.id user_id,c.id vendor_id,c.name vendor_id
from wb_account a
inner join t_supplier c on (c.account_id=a.id or c.account_id=a.parent_id)) a
inner join wb_account b on a.user_id=b.id
inner join wb_account_role c on c.account_id=b.id
inner join wb_role d on c.role_id=d.id
inner join tv3_lug_groups f on (f.vendor_id=a.vendor_id or (a.vendor_id =-1 and exists(select 1 from t_oem where
id=f.vendor_id)))
left join tv3_lug_group_user e on b.id = e.user_id and f.group_id=e.group_id
where b.status = 1
<if test="groupId != null">
and f.group_id = #{groupId}
</if>
order by a.vendor_type
</select>
<select id="getSuperUserByGroup" parameterType="java.lang.Long"
resultType="com.boco.nbd.wios.flow.entity.po.BaseUserPO">
select c.id, c.phone
from wb_account c
inner join tv3_lug_group_user d on c.id = d.user_id and d.group_id = #{groupId}
where c.status = 1
</select>
<select id="getSelectVendorInfo" resultType="com.boco.nbd.wios.flow.entity.po.VendorPO">
select distinct a.id vendor_id, a.name vendor_name
from t_oem a
inner join t_oem_contract b on a.id = b.oem_id and b.status = 2
where type = 1
and a.status = 1
union all
select id vendor_id, name vendor_name
from t_supplier
</select>
<select id="getFlowNodeUserInfo" parameterType="com.boco.nbd.wios.flow.entity.qo.FlowNodeUserQo"
resultType="com.boco.nbd.wios.flow.entity.po.FlowNodeUserPO">
select a.flow_code, b.node_code, d.group_name, d.vendor_name, e.user_id, f.name user_name,f.phone
from tv3_lug_flows a
inner join tv3_lug_nodes b on a.flow_id = b.flow_id
inner join tv3_lug_node_group c on b.node_id = c.node_id
inner join tv3_lug_groups d on c.group_id = d.group_id
inner join tv3_lug_group_user e on d.group_id = e.group_id
inner join wb_account f on e.user_id = f.id
where 1=1
and a.flow_code=#{flowCode}
<if test="nodeCode != null">
and b.node_code=#{nodeCode}
</if>
<if test="vendorId != null">
and d.vendor_id=#{vendorId}
</if>
<if test="userName != null and userName != ''">
<bind name="userNameLike" value="'%' + userName + '%'"/>
and f.name like #{userNameLike}
</if>
</select>
<!-- 据组ID删除成员 -->
<delete id="deleteConnectConfig">
delete
from t_connect_order_config
where group_id = #{groupId}
and user_id = #{userId}
</delete>
<insert id="bindConnectConfig">
insert into t_connect_order_config (group_id, user_id, end_number)
values (#{groupId}, #{userId}, #{endNumber})
</insert>
<select id="getConnectConfig" resultType="com.boco.nbd.wios.flow.entity.bo.ConnectConfigBO">
select d.vendor_id,
d.vendor_name,
d.group_id,
d.group_name,
e.user_id,
f.name user_name,
g.end_number
from tv3_lug_flows a
inner join tv3_lug_nodes b on a.flow_id = b.flow_id
inner join tv3_lug_node_group c on b.node_id = c.node_id
inner join tv3_lug_groups d on c.group_id = d.group_id
inner join tv3_lug_group_user e on d.group_id = e.group_id
inner join wb_account f on e.user_id = f.id
left join t_connect_order_config g on g.group_id = e.group_id and g.user_id = e.user_id
where a.flow_code = #{flowCode}
and b.node_code = #{nodeCode}
<if test="vendorId != null">
and d.vendor_id = #{vendorId}
</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.boco.nbd.wios.flow.mapper.def.OemCascadeMapper">
<resultMap id="oemCascadeMap" type="com.boco.nbd.wios.flow.entity.po.OemCascadePO">
<result column="id" property="id"/>
<result column="name" property="name"/>
<result column="parent_id" property="parentId"/>
<result column="materials_code" property="materialsCode"/>
</resultMap>
<select id="getCascadePO" parameterType="string" resultMap="oemCascadeMap">
select id,name,materials_code,parent_id from t_oem_cascade
where 1=1
<if test="oemId != null">
and find_in_set(parent_id,#{oemId})
</if>
</select>
<select id="getCascadeById" parameterType="string" resultMap="oemCascadeMap">
select id, name, materials_code, parent_id
from t_oem_cascade
where id = #{id}
</select>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.OemContractItemMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.OemContractItem">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="contract_id" jdbcType="VARCHAR" property="contractId" />
<result column="item_id" jdbcType="VARCHAR" property="itemId" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="price" jdbcType="DECIMAL" property="price" />
<result column="tax_rate" jdbcType="DECIMAL" property="taxRate" />
<result column="rate_price" jdbcType="DECIMAL" property="ratePrice" />
<result column="description" jdbcType="VARCHAR" property="description" />
<result column="create_account" jdbcType="VARCHAR" property="createAccount" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="modify_account" jdbcType="VARCHAR" property="modifyAccount" />
<result column="modify_time" jdbcType="TIMESTAMP" property="modifyTime" />
</resultMap>
<sql id="Base_Column_List">
id, contract_id, item_id, type, price, tax_rate, rate_price, description, create_account,
create_time, modify_account, modify_time
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_oem_contract_item
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.OemContractItem">
insert into t_oem_contract_item (id, contract_id, item_id,
type, price, tax_rate,
rate_price, description, create_account,
create_time, modify_account, modify_time
)
values (#{id,jdbcType=INTEGER}, #{contractId,jdbcType=VARCHAR}, #{itemId,jdbcType=VARCHAR},
#{type,jdbcType=VARCHAR}, #{price,jdbcType=DECIMAL}, #{taxRate,jdbcType=DECIMAL},
#{ratePrice,jdbcType=DECIMAL}, #{description,jdbcType=VARCHAR}, #{createAccount,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{modifyAccount,jdbcType=VARCHAR}, #{modifyTime,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.OemContractItem">
insert into t_oem_contract_item
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="contractId != null">
contract_id,
</if>
<if test="itemId != null">
item_id,
</if>
<if test="type != null">
type,
</if>
<if test="price != null">
price,
</if>
<if test="taxRate != null">
tax_rate,
</if>
<if test="ratePrice != null">
rate_price,
</if>
<if test="description != null">
description,
</if>
<if test="createAccount != null">
create_account,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="modifyAccount != null">
modify_account,
</if>
<if test="modifyTime != null">
modify_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="contractId != null">
#{contractId,jdbcType=VARCHAR},
</if>
<if test="itemId != null">
#{itemId,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="price != null">
#{price,jdbcType=DECIMAL},
</if>
<if test="taxRate != null">
#{taxRate,jdbcType=DECIMAL},
</if>
<if test="ratePrice != null">
#{ratePrice,jdbcType=DECIMAL},
</if>
<if test="description != null">
#{description,jdbcType=VARCHAR},
</if>
<if test="createAccount != null">
#{createAccount,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="modifyAccount != null">
#{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
#{modifyTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.OemContractItem">
update t_oem_contract_item
<set>
<if test="contractId != null">
contract_id = #{contractId,jdbcType=VARCHAR},
</if>
<if test="itemId != null">
item_id = #{itemId,jdbcType=VARCHAR},
</if>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="price != null">
price = #{price,jdbcType=DECIMAL},
</if>
<if test="taxRate != null">
tax_rate = #{taxRate,jdbcType=DECIMAL},
</if>
<if test="ratePrice != null">
rate_price = #{ratePrice,jdbcType=DECIMAL},
</if>
<if test="description != null">
description = #{description,jdbcType=VARCHAR},
</if>
<if test="createAccount != null">
create_account = #{createAccount,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="modifyAccount != null">
modify_account = #{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.OemContractItem">
update t_oem_contract_item
set contract_id = #{contractId,jdbcType=VARCHAR},
item_id = #{itemId,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
price = #{price,jdbcType=DECIMAL},
tax_rate = #{taxRate,jdbcType=DECIMAL},
rate_price = #{ratePrice,jdbcType=DECIMAL},
description = #{description,jdbcType=VARCHAR},
create_account = #{createAccount,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
modify_account = #{modifyAccount,jdbcType=VARCHAR},
modify_time = #{modifyTime,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_oem_contract_item
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByContractId" parameterType="java.lang.Integer" resultType="com.boco.nbd.wios.manage.entity.bo.OemContractItemVo">
select t.*
from t_oem_contract_item t
where t.contract_id = #{contractId,jdbcType=INTEGER}
</select>
<select id="selectByContractIdAndItemId" resultType="com.boco.nbd.wios.manage.entity.bo.OemContractItemVo">
select t.*
from t_oem_contract_item t
where t.contract_id = #{contractId} and t.item_id=#{itemId}
</select>
<select id="selectPureByContractId" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select t.*
from t_oem_contract_item t
where t.contract_id = #{contractId,jdbcType=INTEGER}
</select>
<select id="selectByItemId" parameterType="java.lang.String" resultMap="BaseResultMap">
select t.*
from t_oem_contract_item t
where t.item_id = #{itemId}
</select>
<insert id="batchInsert" parameterType="java.util.List">
insert into t_oem_contract_item (id, contract_id, item_id,
type, price, tax_rate,
rate_price, description, create_account,
create_time, modify_account, modify_time
)
values
<foreach collection="list" item="item" separator=",">
(#{item.id,jdbcType=INTEGER}, #{item.contractId,jdbcType=VARCHAR}, #{item.itemId,jdbcType=VARCHAR},
#{item.type,jdbcType=VARCHAR}, #{item.price,jdbcType=DECIMAL}, #{item.taxRate,jdbcType=DECIMAL},
#{item.ratePrice,jdbcType=DECIMAL}, #{item.description,jdbcType=VARCHAR}, #{item.createAccount,jdbcType=VARCHAR},
#{item.createTime,jdbcType=TIMESTAMP}, #{item.modifyAccount,jdbcType=VARCHAR}, #{item.modifyTime,jdbcType=TIMESTAMP}
)
</foreach>
</insert>
<delete id="deleteByContractId" parameterType="java.lang.Integer">
delete from t_oem_contract_item
where contract_id = #{contractId}
</delete>
</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.boco.nbd.wios.manage.mapper.def.OperateLogDeleteMapper" >
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.OperateLogDelete" >
<id column="id" property="id" jdbcType="INTEGER" />
<result column="type" property="type" jdbcType="TINYINT" />
<result column="third_party_id" property="thirdPartyId" jdbcType="VARCHAR" />
<result column="pre_name" property="preName" jdbcType="VARCHAR" />
<result column="pre_value" property="preValue" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="value" property="value" jdbcType="VARCHAR" />
<result column="desc" property="desc" jdbcType="VARCHAR" />
<result column="create_account" property="createAccount" jdbcType="INTEGER" />
<result column="create_account_name" property="createAccountName" jdbcType="VARCHAR" />
<result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, type, third_party_id, pre_name, pre_value, name, value, desc, create_account,
create_account_name, create_time
</sql>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.OperateLogDelete" >
insert into t_operate_log_delete (id, type, third_party_id,
pre_name, pre_value, name,
value, desc, create_account,
create_account_name, create_time)
values (#{id,jdbcType=INTEGER}, #{type,jdbcType=TINYINT}, #{thirdPartyId,jdbcType=VARCHAR},
#{preName,jdbcType=VARCHAR}, #{preValue,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{value,jdbcType=VARCHAR}, #{desc,jdbcType=VARCHAR}, #{createAccount,jdbcType=INTEGER},
#{createAccountName,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.boco.nbd.wios.manage.entity.bo.OperateLogDelete" >
insert into t_operate_log_delete
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="type != null" >
type,
</if>
<if test="thirdPartyId != null" >
third_party_id,
</if>
<if test="preName != null" >
pre_name,
</if>
<if test="preValue != null" >
pre_value,
</if>
<if test="name != null" >
name,
</if>
<if test="value != null" >
value,
</if>
<if test="desc != null" >
desc,
</if>
<if test="createAccount != null" >
create_account,
</if>
<if test="createAccountName != null" >
create_account_name,
</if>
<if test="createTime != null" >
create_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=INTEGER},
</if>
<if test="type != null" >
#{type,jdbcType=TINYINT},
</if>
<if test="thirdPartyId != null" >
#{thirdPartyId,jdbcType=VARCHAR},
</if>
<if test="preName != null" >
#{preName,jdbcType=VARCHAR},
</if>
<if test="preValue != null" >
#{preValue,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="value != null" >
#{value,jdbcType=VARCHAR},
</if>
<if test="desc != null" >
#{desc,jdbcType=VARCHAR},
</if>
<if test="createAccount != null" >
#{createAccount,jdbcType=INTEGER},
</if>
<if test="createAccountName != null" >
#{createAccountName,jdbcType=VARCHAR},
</if>
<if test="createTime != null" >
#{createTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<insert id="batchInsert">
insert into t_operate_log_delete ( type, third_party_id,
pre_name, pre_value, name,
value, `desc`, create_account,
create_account_name, create_time)
values
<foreach collection="list" item="item" separator=",">
( #{item.type,jdbcType=TINYINT}, #{item.thirdPartyId,jdbcType=VARCHAR},
#{item.preName,jdbcType=VARCHAR}, #{item.preValue,jdbcType=VARCHAR}, #{item.name,jdbcType=VARCHAR},
#{item.value,jdbcType=VARCHAR}, #{item.desc,jdbcType=VARCHAR}, #{item.createAccount,jdbcType=INTEGER},
#{item.createAccountName,jdbcType=VARCHAR}, #{item.createTime,jdbcType=TIMESTAMP})
</foreach>
</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.boco.nbd.wios.manage.mapper.def.OperateLogMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.OperateLog">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="type" jdbcType="INTEGER" property="type" />
<result column="third_party_id" jdbcType="VARCHAR" property="thirdPartyId" />
<result column="pre_name" jdbcType="VARCHAR" property="preName" />
<result column="pre_value" jdbcType="VARCHAR" property="preValue" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="value" jdbcType="VARCHAR" property="value" />
<result column="desc" jdbcType="VARCHAR" property="desc" />
<result column="create_account" jdbcType="INTEGER" property="createAccount" />
<result column="create_account_name" jdbcType="VARCHAR" property="createAccountName" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
</resultMap>
<sql id="Base_Column_List">
id, type, third_party_id, pre_name, pre_value, name, value, `desc`, create_account,
create_account_name, create_time
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_operate_log
where id = #{id,jdbcType=INTEGER}
</delete>
<delete id="deleteByOrderId">
delete from t_operate_log
where third_party_id = #{orderId}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.OperateLog">
insert into t_operate_log (id, type, third_party_id,
pre_name, pre_value, name,
value, `desc`, create_account,
create_account_name, create_time)
values (#{id,jdbcType=INTEGER}, #{type,jdbcType=INTEGER}, #{thirdPartyId,jdbcType=VARCHAR},
#{preName,jdbcType=VARCHAR}, #{preValue,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{value,jdbcType=VARCHAR}, #{desc,jdbcType=VARCHAR}, #{createAccount,jdbcType=INTEGER},
#{createAccountName,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.OperateLog">
insert into t_operate_log
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="type != null">
type,
</if>
<if test="thirdPartyId != null">
third_party_id,
</if>
<if test="preName != null">
pre_name,
</if>
<if test="preValue != null">
pre_value,
</if>
<if test="name != null">
name,
</if>
<if test="value != null">
value,
</if>
<if test="desc != null">
desc,
</if>
<if test="createAccount != null">
create_account,
</if>
<if test="createAccountName != null">
create_account_name,
</if>
<if test="createTime != null">
create_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="type != null">
#{type,jdbcType=INTEGER},
</if>
<if test="thirdPartyId != null">
#{thirdPartyId,jdbcType=VARCHAR},
</if>
<if test="preName != null">
#{preName,jdbcType=VARCHAR},
</if>
<if test="preValue != null">
#{preValue,jdbcType=VARCHAR},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="value != null">
#{value,jdbcType=VARCHAR},
</if>
<if test="desc != null">
#{desc,jdbcType=VARCHAR},
</if>
<if test="createAccount != null">
#{createAccount,jdbcType=INTEGER},
</if>
<if test="createAccountName != null">
#{createAccountName,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.OperateLog">
update t_operate_log
<set>
<if test="type != null">
type = #{type,jdbcType=INTEGER},
</if>
<if test="thirdPartyId != null">
third_party_id = #{thirdPartyId,jdbcType=VARCHAR},
</if>
<if test="preName != null">
pre_name = #{preName,jdbcType=VARCHAR},
</if>
<if test="preValue != null">
pre_value = #{preValue,jdbcType=VARCHAR},
</if>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="value != null">
value = #{value,jdbcType=VARCHAR},
</if>
<if test="desc != null">
desc = #{desc,jdbcType=VARCHAR},
</if>
<if test="createAccount != null">
create_account = #{createAccount,jdbcType=INTEGER},
</if>
<if test="createAccountName != null">
create_account_name = #{createAccountName,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.OperateLog">
update t_operate_log
set type = #{type,jdbcType=INTEGER},
third_party_id = #{thirdPartyId,jdbcType=VARCHAR},
pre_name = #{preName,jdbcType=VARCHAR},
pre_value = #{preValue,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
value = #{value,jdbcType=VARCHAR},
desc = #{desc,jdbcType=VARCHAR},
create_account = #{createAccount,jdbcType=INTEGER},
create_account_name = #{createAccountName,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_operate_log
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByExample" parameterType="com.boco.nbd.wios.manage.entity.bo.OperateLogBo"
resultType="com.boco.nbd.wios.manage.entity.bo.OperateLog">
select t.* from t_operate_log t
<where>
<if test="type != null">
and t.type = #{type}
</if>
<if test="typeList != null">
and t.type in
<foreach collection="typeList" item="item" index="index" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
<if test="thirdPartyId != null and thirdPartyId != ''">
and t.third_party_id = #{thirdPartyId}
</if>
<if test="name != null and name !='' ">
and t.name = #{name}
</if>
</where>
order by t.create_time desc
</select>
<select id="getNewestCheckFailByOrderId" resultType="com.boco.nbd.wios.manage.entity.bo.OperateLog">
select
<include refid="Base_Column_List" />
from t_operate_log
where type=1
<if test="orderId != null and orderId != ''">
and third_party_id =#{orderId}
</if>
<if test="name != null and name != ''">
and name=#{name}
</if>
ORDER BY
create_time DESC
LIMIT 0,1
</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.boco.nbd.wios.flow.mapper.def.OrderAbnormalMapper">
<select id="getOrderAbnormalAll" resultType="com.boco.nbd.wios.flow.entity.bo.OrderAbnormalBO">
select a.id,
a.oem_name,
b.code oem_code,
case when a.region_level=1 then a.country_name when a.region_level=2 then a.area_name when a.region_level=3 then a.province_name when a.region_level=4 then a.region_name when a.region_level=5 then a.city_name end region_name,
a.address,
case a.user_sex when 0 then '女' when 1 then '男' else '未知' end user_sex,
a.user_phone,
case a.survey_before_sale_enable when 0 then '否' when 1 then '是' end survey_before_sale_enable,
a.vehicle_model,
a.vehicle_chassis_no,
a.wallbox_model,
a.vehicle_parking_status,
a.vehicle_parking_no,
a.out_order_id,
date_format(a.invoice_time, '%Y-%m-%d') invoice_time,
a.oem_agent_name,
a.oem_agent_contact_name,
a.oem_agent_info,
a.create_time,
a.status,
a.pack_type,
a.overtime_type,
case a.estate_type when 1 then '普通高层' when 2 then '商用两住' when 3 then '别墅' when 4 then '公司' when 5 then '厂房' when 6 then '自建房' when 7 then '其他' end estate_type,
case a.has_independent_parking when 0 then '否' when 1 then '是' end has_independent_parking,
case a.install_position when 1 then '室内' when 2 then '室外' end install_position,
case a.property_agree when 0 then '不同意' when 1 then '同意' end property_agree,
case a.electric_expand when 0 then '否' when 1 then '是' end electric_expand,
case a.need_erect_pile when 0 then '否' when 1 then '是' end need_erect_pile,
case a.manu_dispatch_enable when 0 then '否' when 1 then '是' end manu_dispatch_enable,
case a.is_need_survey when 0 then '否' when 1 then '是' end is_need_survey,
case a.install_emergency_level when 1 then '一般' when 2 then '紧急' end install_emergency_level
from t_order_abnormal a
left join t_oem b on a.oem_id = b.id
left join t_region c on a.region_id = c.id
</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.boco.nbd.wios.flow.mapper.def.OrderBlockedMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.flow.entity.po.OrderBlockedPO">
<id property="id" column="id" jdbcType="VARCHAR"/>
<result property="orderId" column="order_id" jdbcType="VARCHAR"/>
<result property="nodeFlag" column="node_flag" jdbcType="VARCHAR"/>
<result property="currentNode" column="current_node" jdbcType="VARCHAR"/>
<result property="remarks" column="remarks" jdbcType="VARCHAR"/>
<result property="whether" column="whether" jdbcType="VARCHAR"/>
<result property="status" column="status" jdbcType="VARCHAR"/>
<result property="updateTime" column="update_time" jdbcType="TIMESTAMP"/>
<result property="nextTime" column="next_time" jdbcType="TIMESTAMP"/>
</resultMap>
<sql id="Base_Column_List">
id,order_id,node_flag,current_node,
remarks,whether,status,
update_time,next_time
</sql>
<select id="getAllByIdList" resultType="com.boco.nbd.wios.flow.entity.po.OrderBlockedPO">
select
<include refid="Base_Column_List" />
from t_order_blocked
where order_id = #{orderId}
<if test="nodeFlag != null and nodeFlag != ''">
and node_flag = #{nodeFlag}
</if>
order by node_flag asc,update_time asc
</select>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.OrderInstallItemDeleteMapper" >
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.OrderInstallItemDelete" >
<id column="id" property="id" jdbcType="INTEGER" />
<result column="order_id" property="orderId" jdbcType="VARCHAR" />
<result column="type" property="type" jdbcType="BIT" />
<result column="item_type" property="itemType" jdbcType="INTEGER" />
<result column="item_id" property="itemId" jdbcType="VARCHAR" />
<result column="item_name" property="itemName" jdbcType="VARCHAR" />
<result column="item_model" property="itemModel" jdbcType="VARCHAR" />
<result column="item_warehouse_id" property="itemWarehouseId" jdbcType="VARCHAR" />
<result column="contract_item_id" property="contractItemId" jdbcType="INTEGER" />
<result column="qunatity" property="qunatity" jdbcType="DECIMAL" />
<result column="fee" property="fee" jdbcType="DECIMAL" />
<result column="description" property="description" jdbcType="VARCHAR" />
<result column="create_account" property="createAccount" jdbcType="VARCHAR" />
<result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
<result column="modify_account" property="modifyAccount" jdbcType="VARCHAR" />
<result column="modify_time" property="modifyTime" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, order_id, type, item_type, item_id, item_name, item_model, item_warehouse_id,
contract_item_id, qunatity, fee, description, create_account, create_time, modify_account,
modify_time
</sql>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.OrderInstallItemDelete" >
insert into t_order_install_item_delete (id, order_id, type,
item_type, item_id, item_name,
item_model, item_warehouse_id, contract_item_id,
qunatity, fee, description,
create_account, create_time, modify_account,
modify_time)
values (#{id,jdbcType=INTEGER}, #{orderId,jdbcType=VARCHAR}, #{type,jdbcType=BIT},
#{itemType,jdbcType=INTEGER}, #{itemId,jdbcType=VARCHAR}, #{itemName,jdbcType=VARCHAR},
#{itemModel,jdbcType=VARCHAR}, #{itemWarehouseId,jdbcType=VARCHAR}, #{contractItemId,jdbcType=INTEGER},
#{qunatity,jdbcType=DECIMAL}, #{fee,jdbcType=DECIMAL}, #{description,jdbcType=VARCHAR},
#{createAccount,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{modifyAccount,jdbcType=VARCHAR},
#{modifyTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.boco.nbd.wios.manage.entity.bo.OrderInstallItemDelete" >
insert into t_order_install_item_delete
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="orderId != null" >
order_id,
</if>
<if test="type != null" >
type,
</if>
<if test="itemType != null" >
item_type,
</if>
<if test="itemId != null" >
item_id,
</if>
<if test="itemName != null" >
item_name,
</if>
<if test="itemModel != null" >
item_model,
</if>
<if test="itemWarehouseId != null" >
item_warehouse_id,
</if>
<if test="contractItemId != null" >
contract_item_id,
</if>
<if test="qunatity != null" >
qunatity,
</if>
<if test="fee != null" >
fee,
</if>
<if test="description != null" >
description,
</if>
<if test="createAccount != null" >
create_account,
</if>
<if test="createTime != null" >
create_time,
</if>
<if test="modifyAccount != null" >
modify_account,
</if>
<if test="modifyTime != null" >
modify_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="orderId != null" >
#{orderId,jdbcType=VARCHAR},
</if>
<if test="type != null" >
#{type,jdbcType=BIT},
</if>
<if test="itemType != null" >
#{itemType,jdbcType=INTEGER},
</if>
<if test="itemId != null" >
#{itemId,jdbcType=VARCHAR},
</if>
<if test="itemName != null" >
#{itemName,jdbcType=VARCHAR},
</if>
<if test="itemModel != null" >
#{itemModel,jdbcType=VARCHAR},
</if>
<if test="itemWarehouseId != null" >
#{itemWarehouseId,jdbcType=VARCHAR},
</if>
<if test="contractItemId != null" >
#{contractItemId,jdbcType=INTEGER},
</if>
<if test="qunatity != null" >
#{qunatity,jdbcType=DECIMAL},
</if>
<if test="fee != null" >
#{fee,jdbcType=DECIMAL},
</if>
<if test="description != null" >
#{description,jdbcType=VARCHAR},
</if>
<if test="createAccount != null" >
#{createAccount,jdbcType=VARCHAR},
</if>
<if test="createTime != null" >
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="modifyAccount != null" >
#{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null" >
#{modifyTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<insert id="batchInsert" parameterType="java.util.List">
insert into t_order_install_item_delete ( order_id,type, item_type,
item_id, item_name, item_model,
contract_item_id, qunatity, fee,
description, create_account, create_time,
modify_account, modify_time)
values
<foreach collection="list" item="item" separator=",">
(#{item.orderId,jdbcType=VARCHAR},#{item.type,jdbcType=INTEGER}, #{item.itemType,jdbcType=INTEGER},
#{item.itemId,jdbcType=VARCHAR}, #{item.itemName,jdbcType=VARCHAR}, #{item.itemModel,jdbcType=VARCHAR},
#{item.contractItemId,jdbcType=INTEGER}, #{item.qunatity,jdbcType=DECIMAL}, #{item.fee,jdbcType=DECIMAL},
#{item.description,jdbcType=VARCHAR}, #{item.createAccount,jdbcType=VARCHAR}, #{item.createTime,jdbcType=TIMESTAMP},
#{item.modifyAccount,jdbcType=VARCHAR}, #{item.modifyTime,jdbcType=TIMESTAMP})
</foreach>
</insert>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.OrderScoreMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.OrderScore">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="order_id" jdbcType="INTEGER" property="orderId" />
<result column="score_config_id" jdbcType="INTEGER" property="scoreConfigId" />
<result column="code" jdbcType="VARCHAR" property="code" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="weight" jdbcType="INTEGER" property="weight" />
<result column="score" jdbcType="INTEGER" property="score" />
<result column="type" jdbcType="INTEGER" property="type" />
<result column="description" jdbcType="VARCHAR" property="description" />
<result column="create_account" jdbcType="VARCHAR" property="createAccount" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="modify_account" jdbcType="VARCHAR" property="modifyAccount" />
<result column="modify_time" jdbcType="TIMESTAMP" property="modifyTime" />
</resultMap>
<sql id="Base_Column_List">
id, order_id, score_config_id, code, name, status, weight, score, description, create_account,
create_time, modify_account, modify_time
</sql>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.OrderScore">
insert into t_order_score (id, order_id, score_config_id,
code, name, weight,
score, type, status,
description, create_account, create_time,
modify_account, modify_time)
values (#{id,jdbcType=VARCHAR}, #{orderId,jdbcType=VARCHAR}, #{scoreConfigId,jdbcType=VARCHAR},
#{code,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{weight,jdbcType=INTEGER},
#{score,jdbcType=INTEGER}, #{type,jdbcType=INTEGER}, #{status,jdbcType=INTEGER},
#{description,jdbcType=VARCHAR}, #{createAccount,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{modifyAccount,jdbcType=VARCHAR}, #{modifyTime,jdbcType=TIMESTAMP})
</insert>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.OrderScore">
update t_order_score
<set>
<if test="score != null">
score = #{score,jdbcType=INTEGER},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="description != null">
description = #{description,jdbcType=VARCHAR},
</if>
<if test="modifyAccount != null">
modify_account = #{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="updateByCode" parameterType="com.boco.nbd.wios.manage.entity.bo.OrderScore">
update t_order_score
<set>
<if test="score != null">
score = #{score,jdbcType=INTEGER},
</if>
<if test="resultCalc != null">
score_calc = #{resultCalc,jdbcType=INTEGER},
</if>
<if test="description != null">
description = #{description,jdbcType=VARCHAR},
</if>
<if test="modifyAccount != null">
modify_account = #{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
</set>
where order_id = #{orderScoreId,jdbcType=INTEGER}
and code = #{code,jdbcType=VARCHAR},
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_order_score
where id = #{id,jdbcType=INTEGER}
</select>
<select id="getScoreByOrderId" parameterType="java.lang.String" resultType="java.lang.Double">
select
avg(score) as sumScore
from t_order_score
where order_id = #{orderId,jdbcType=INTEGER} and status =1
</select>
<select id="selectByExample" parameterType="com.boco.nbd.wios.manage.entity.bo.OrderScore" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_order_score
where order_id = #{orderId,jdbcType=INTEGER}
and code = #{code,jdbcType=VARCHAR},
</select>
<select id="getListByOrderId" resultType="com.boco.nbd.wios.manage.entity.bo.OrderScore">
select
<include refid="Base_Column_List" />
from t_order_score
where order_id = #{orderId,jdbcType=VARCHAR} and status =1
</select>
<select id="getOrderListLessThan60" resultType="com.boco.nbd.wios.manage.entity.bo.Order">
select od.*
from t_order od
join t_operate_log ol on od.id = ol.third_party_id
where
od.install_supplier_id = #{supplierId,jdbcType=INTEGER}
and od.region_id = #{regionId,jdbcType=INTEGER}
and ol.name = '61'
and DATE_FORMAT(ol.create_time,'%Y-%m') = #{month,jdbcType=VARCHAR}
GROUP BY od.id
</select>
<insert id="insertOrderScore" parameterType="java.lang.String">
insert into t_order_score(order_id, score_config_id, code, name, weight, score, type, status, description,
create_account, create_time, modify_account, modify_time)
SELECT #{orderId,jdbcType=VARCHAR},sc.id, sc.code, sc.name,
sc.weight,0, 1,1, '',
1,NOW(), 1, NOW()
from t_score_config sc
where sc.status=1 and sc.parent_code='customer'
</insert>
<select id="selectByTypeAndOrderIds"
resultType="com.boco.nbd.wios.manage.entity.bo.OrderScore">
select t.*
from t_order_score t
where
t.type=#{type} and
t.order_id in
<foreach collection="orderIds" item="item" index="index" open="(" close=")" separator=",">
#{item}
</foreach>
</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.boco.nbd.wios.flow.mapper.def.PlanTaskMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.flow.entity.po.PlanTaskPO">
<result property="year" column="year" jdbcType="VARCHAR"/>
<result property="oemName" column="oem_name" jdbcType="VARCHAR"/>
<result property="janCount" column="jan_count" jdbcType="INTEGER"/>
<result property="febCount" column="feb_count" jdbcType="INTEGER"/>
<result property="marCount" column="mar_count" jdbcType="INTEGER"/>
<result property="aprCount" column="apr_count" jdbcType="INTEGER"/>
<result property="mayCount" column="may_count" jdbcType="INTEGER"/>
<result property="junCount" column="jun_count" jdbcType="INTEGER"/>
<result property="julCount" column="jul_count" jdbcType="INTEGER"/>
<result property="augCount" column="aug_count" jdbcType="INTEGER"/>
<result property="sepCount" column="sep_count" jdbcType="INTEGER"/>
<result property="octCount" column="oct_count" jdbcType="INTEGER"/>
<result property="novCount" column="nov_count" jdbcType="INTEGER"/>
<result property="decCount" column="dec_count" jdbcType="INTEGER"/>
<result property="createUser" column="create_user" jdbcType="VARCHAR"/>
</resultMap>
<sql id="Base_Column_List">
year,oem_name,jan_count,
feb_count,mar_count,apr_count,
may_count,jun_count,jul_count,
aug_count,sep_count,oct_count,
nov_count,dec_count,create_user
</sql>
<select id="selectByYearAndOemName" resultType="com.boco.nbd.wios.flow.entity.po.PlanTaskPO">
select year,
sum(jan_count) as jan_count,
sum(feb_count) as feb_count,
sum(mar_count) as mar_count,
sum(apr_count) as apr_count,
sum(may_count) as may_count,
sum(jun_count) as jun_count,
sum(jul_count) as jul_count,
sum(aug_count) as aug_count,
sum(sep_count) as sep_count,
sum(oct_count) as oct_count,
sum(nov_count) as nov_count,
sum(dec_count) as dec_count
from t_plan_task
where year=#{year}
<if test="oemName != null and oemName != ''">
and oem_name=#{oemName}
</if>
GROUP BY year
</select>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.RegionMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.Region">
<id column="id" jdbcType="INTEGER" property="id"/>
<result column="code" jdbcType="VARCHAR" property="code"/>
<result column="name" jdbcType="VARCHAR" property="name"/>
<result column="parent_id" jdbcType="INTEGER" property="parentId"/>
<result column="status" jdbcType="INTEGER" property="status"/>
<result column="remark" jdbcType="VARCHAR" property="remark"/>
<result column="id_tree" jdbcType="VARCHAR" property="idTree"/>
<result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime"/>
</resultMap>
<sql id="Base_Column_List">
id
, code, name, parent_id, status, remark,id_tree, create_time, update_time
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete
from t_region
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.Region"
useGeneratedKeys="true" keyProperty="id">
insert into t_region (id, code, name,
parent_id, status, remark, id_tree,
create_time, update_time)
values (#{id,jdbcType=INTEGER}, #{code,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{parentId,jdbcType=INTEGER}, #{status,jdbcType=INTEGER}, #{remark,jdbcType=VARCHAR},
#{idTree,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.Region">
insert into t_region
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="code != null">
code,
</if>
<if test="name != null">
name,
</if>
<if test="parentId != null">
parent_id,
</if>
<if test="status != null">
status,
</if>
<if test="remark != null">
remark,
</if>
<if test="idTree != null">
id_tree,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateTime != null">
update_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="code != null">
#{code,jdbcType=VARCHAR},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="parentId != null">
#{parentId,jdbcType=INTEGER},
</if>
<if test="status != null">
#{status,jdbcType=INTEGER},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="idTree != null">
#{idTree,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.bo.Region">
update t_region
<set>
<if test="code != null">
code = #{code,jdbcType=VARCHAR},
</if>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="parentId != null">
parent_id = #{parentId,jdbcType=INTEGER},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="idTree != null">
id_tree = #{idTree,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.Region">
update t_region
set code = #{code,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
parent_id = #{parentId,jdbcType=INTEGER},
status = #{status,jdbcType=INTEGER},
remark = #{remark,jdbcType=VARCHAR},
id_tree = #{idTree,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from t_region
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectRegionByOrderId" parameterType="String" resultType="Integer">
SELECT CASE
WHEN
t.region_level = 1 THEN
t.country_id
WHEN t.region_level = 2 THEN
t.area_id
WHEN t.region_level = 3 THEN
t.province_id
WHEN t.region_level = 5 THEN
t.city_id
ELSE t.region_id
END AS region_id
FROM t_order AS t
WHERE t.id = #{orderId}
</select>
<select id="selectByParentId" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from t_region
where parent_id = #{parentId,jdbcType=INTEGER} and status=1
</select>
<select id="selectAll" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from t_region t
<where>
1=1
<if test="status != null">
and t.status = #{status}
</if>
<if test="ids != null">
and t.id in
<foreach collection="ids" item="item" index="index" open="(" close=")" separator=",">
#{item}
</foreach>
</if>
order by t.id_tree
</where>
</select>
<select id="selectByName" parameterType="java.lang.String" resultMap="BaseResultMap">
select *
from t_region
where name = #{name}
and status = 1
</select>
<select id="selectByCode" parameterType="java.lang.String" resultMap="BaseResultMap">
select *
from t_region
where code = #{code}
</select>
<select id="selectSelfAndChildren" parameterType="java.lang.String" resultMap="BaseResultMap">
select *
from t_region
where id_tree like concat(#{idTree}, '%')
</select>
<update id="updateIdTree">
update t_region
set id_tree = concat(#{idTreeNewPrefix}, substring(id_tree, length(#{idTreePrefix}) + 1, length(id_tree)))
where id_tree like concat(#{idTreePrefix}, '%')
</update>
</mapper>
<?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.boco.nbd.wios.manage.mapper.def.ScoreConfigMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.ScoreConfig">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="code" jdbcType="VARCHAR" property="code" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="parent_code" jdbcType="VARCHAR" property="parentCode" />
<result column="parent_name" jdbcType="VARCHAR" property="parentName" />
<result column="weight" jdbcType="INTEGER" property="weight" />
<result column="parent_weight" jdbcType="INTEGER" property="parentWeight" />
<result column="source" jdbcType="VARCHAR" property="source" />
<result column="description" jdbcType="VARCHAR" property="description" />
<result column="create_account" jdbcType="VARCHAR" property="createAccount" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="modify_account" jdbcType="VARCHAR" property="modifyAccount" />
<result column="modify_time" jdbcType="TIMESTAMP" property="modifyTime" />
</resultMap>
<sql id="Base_Column_List">
id, code, name, status, type, parent_code, weight, source, description, create_account,
create_time, modify_account, modify_time
</sql>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.ScoreConfig">
insert into t_score_config (id, code, name,
status, type, parent_code,
weight, source, description,
create_account, create_time, modify_account,
modify_time)
values (#{id,jdbcType=INTEGER}, #{code,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{status,jdbcType=INTEGER}, #{type,jdbcType=VARCHAR}, #{parentCode,jdbcType=VARCHAR},
#{weight,jdbcType=INTEGER}, #{source,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR},
#{createAccount,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{modifyAccount,jdbcType=VARCHAR},
#{modifyTime,jdbcType=TIMESTAMP})
</insert>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.ScoreConfig">
update t_score_config
<set>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="weight != null">
weight = #{weight,jdbcType=INTEGER},
</if>
<if test="source != null">
source = #{source,jdbcType=VARCHAR},
</if>
<if test="description != null">
description = #{description,jdbcType=VARCHAR},
</if>
<if test="modifyAccount != null">
modify_account = #{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_score_config
where id = #{id,jdbcType=INTEGER}
</select>
<select id="getListByType" parameterType="java.lang.String" resultMap="BaseResultMap">
select
ts.id, ts.code, ts.name, ts.status, ts.type, ts.parent_code, ts.weight, ts.source, ts.description, ts.create_account,
ts.create_time, ts.modify_account, ts.modify_time,
ts2.name as parent_name,
ts2.weight as parent_weight
from t_score_config ts
left join t_score_config ts2 on ts.parent_code = ts2.code and ts2.status=1
where ts.type = #{type,jdbcType=VARCHAR} and ts.status =1
</select>
<select id="selectByCode" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_score_config
where code = #{code,jdbcType=VARCHAR}
</select>
<select id="selectByParentCodeCode" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_score_config
where parent_code = #{parentCode,jdbcType=VARCHAR}
</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.boco.nbd.wios.score.mapper.def.ScoreConfigV2Mapper">
<delete id="truncateData">
update t_score_config_v2 set status=0
</delete>
</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.boco.nbd.wios.manage.mapper.def.ScoreSupplierDetailMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.ScoreSupplierDetail">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="score_supplier_id" jdbcType="INTEGER" property="scoreSupplierId" />
<result column="code" jdbcType="VARCHAR" property="code" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="parent_code" jdbcType="VARCHAR" property="parentCode" />
<result column="parent_name" jdbcType="VARCHAR" property="parentName" />
<result column="parent_weight" jdbcType="VARCHAR" property="parentWeight" />
<result column="weight" jdbcType="INTEGER" property="weight" />
<result column="score" jdbcType="DECIMAL" property="score" />
<result column="result_calc" jdbcType="DECIMAL" property="resultCalc" />
<result column="source" jdbcType="VARCHAR" property="source" />
<result column="description" jdbcType="VARCHAR" property="description" />
<result column="create_account" jdbcType="VARCHAR" property="createAccount" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="modify_account" jdbcType="VARCHAR" property="modifyAccount" />
<result column="modify_time" jdbcType="TIMESTAMP" property="modifyTime" />
</resultMap>
<sql id="Base_Column_List">
tss.id, tss.score_supplier_id, tss.code, tss.name, tss.status, tss.type, tss.parent_code,tss.score, tss.result_calc, tss.weight, tss.source, tss.description, tss.create_account,
tss.create_time, tss.modify_account, tss.modify_time
</sql>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.ScoreSupplierDetail">
insert into t_score_supplier_detail (id, score_supplier_id, code, name,
status, type, parent_code,
weight,score, source, description,
create_account, create_time, modify_account,
modify_time)
values (#{id,jdbcType=INTEGER}, #{iscore_supplier_id,jdbcType=INTEGER}, #{code,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{status,jdbcType=INTEGER}, #{type,jdbcType=VARCHAR}, #{parentCode,jdbcType=VARCHAR},
#{weight,jdbcType=INTEGER}, #{score,jdbcType=INTEGER}, #{source,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR},
#{createAccount,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{modifyAccount,jdbcType=VARCHAR},
#{modifyTime,jdbcType=TIMESTAMP})
</insert>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.bo.ScoreSupplierDetail">
update t_score_supplier_detail
<set>
<if test="score != null">
score = #{score,jdbcType=DECIMAL},
</if>
<if test="resultCalc != null">
result_calc = #{resultCalc,jdbcType=DECIMAL},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="description != null">
description = #{description,jdbcType=VARCHAR},
</if>
<if test="modifyAccount != null">
modify_account = #{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="updateByCode" parameterType="com.boco.nbd.wios.manage.entity.bo.ScoreSupplierDetail">
update t_score_supplier_detail
<set>
<if test="score != null">
score = #{score,jdbcType=DECIMAL},
</if>
<if test="resultCalc != null">
result_calc = #{resultCalc,jdbcType=INTEGER},
</if>
<if test="description != null">
description = #{description,jdbcType=VARCHAR},
</if>
<if test="modifyAccount != null">
modify_account = #{modifyAccount,jdbcType=VARCHAR},
</if>
<if test="modifyTime != null">
modify_time = #{modifyTime,jdbcType=TIMESTAMP},
</if>
</set>
where score_supplier_id = #{scoreSupplierId,jdbcType=INTEGER}
and code = #{code,jdbcType=VARCHAR}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_score_supplier_detail tss
where tss.id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByExample" parameterType="com.boco.nbd.wios.manage.entity.bo.ScoreSupplierDetail" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />,
ts.name as parent_name,
ts.weight as parent_weight
from t_score_supplier_detail tss
join t_score_config ts on tss.parent_code=ts.code and ts.status=1
where tss.score_supplier_id = #{scoreSupplierId,jdbcType=INTEGER}
<if test="code != null">
and tss.code = #{code,jdbcType=VARCHAR}
</if>
<if test="parentCode != null">
and tss.parent_code = #{parentCode,jdbcType=VARCHAR}
</if>
</select>
<select id="getListByScoreSupplierId" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />,
ts.name as parent_name
from t_score_supplier_detail tss
left join t_score_config ts on tss.parent_code=ts.code and ts.status=1
where tss.score_supplier_id = #{scoreSupplierId,jdbcType=VARCHAR} and tss.status =1
</select>
<select id="getListByScoreSupplierIdAndParentCode" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_score_supplier_detail tss
where tss.score_supplier_id = #{scoreSupplierId} and tss.status =1 and parent_code=#{parentCode}
</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.boco.nbd.wios.score.mapper.def.ScoreSupplierItemMapper">
</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.boco.nbd.wios.score.mapper.def.ScoreSupplierV2Mapper">
<select id="queryScoreItem" resultType="com.boco.nbd.wios.score.entity.bo.ScoreItemBO">
select a.final_score,b.appraisal_id from t_score_supplier_item a
inner join t_score_config_v2 b on a.score_config_id=b.id
where a.score_supplier_id= #{scoreSupplierId}
</select>
<select id="queryScoreSupplier" resultType="com.boco.nbd.wios.score.entity.po.ScoreSupplierPO">
select a.*,(select group_concat(distinct appraisal_user)
from t_supplier_user_config b where b.supplier_config_id=a.supplier_config_id) appraisal_user
from t_score_supplier_v2 a
where 1=1
<if test="supplierId !=null">
and a.supplier_id= #{supplierId}
</if>
<if test="month!='' and month!=null">
and a.month = #{month}
</if>
order by create_time desc
</select>
<select id="getScoreSupplierItem" resultType="com.boco.nbd.wios.score.entity.bo.ScoreSupplierItemBO">
select a.id,
a.score_supplier_id,
a.score_config_id,
b.score_item,
b.total_score,
b.appraisal_department_id,
b.appraisal_id,
b.appraisal_describe,
b.appraisal_target,
b.appraisal_algorithm,
b.appraisal_department,
b.weight,
b.score_weight,
a.description,
a.final_score,
c.appraisal_user
from t_score_supplier_item a
inner join t_score_config_v2 b on a.score_config_id = b.id
left join t_supplier_user_config c on c.supplier_config_id = #{supplierConfigId}
and c.appraisal_department_id = b.appraisal_department_id
where a.score_supplier_id = #{scoreSupplierId}
</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.boco.nbd.wios.flow.mapper.def.SecretPhoneMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.flow.entity.SecretPhone">
<id column="phone" jdbcType="VARCHAR" property="phone" />
<result column="secret_no" jdbcType="VARCHAR" property="secretNo" />
<result column="pool_key" jdbcType="VARCHAR" property="poolKey" />
<result column="expired_time" jdbcType="TIMESTAMP" property="expiredTime" />
<result column="subs_id" jdbcType="VARCHAR" property="subsId" />
<result column="status" jdbcType="INTEGER" property="status" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
</resultMap>
<sql id="Base_Column_List">
phone, secret_no, pool_key, expired_time, subs_id, status, update_time, create_time
</sql>
<delete id="delete" parameterType="java.lang.String">
delete from t_secret_phone
where phone = #{phone,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.flow.entity.SecretPhone">
insert into t_secret_phone (phone, secret_no, pool_key,
expired_time, subs_id, status,
update_time, create_time)
values (#{phone,jdbcType=VARCHAR}, #{secretNo,jdbcType=VARCHAR}, #{poolKey,jdbcType=VARCHAR},
#{expiredTime,jdbcType=TIMESTAMP}, #{subsId,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER},
#{updateTime,jdbcType=TIMESTAMP}, #{createTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.flow.entity.SecretPhone">
insert into t_secret_phone
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="phone != null">
phone,
</if>
<if test="secretNo != null">
secret_no,
</if>
<if test="poolKey != null">
pool_key,
</if>
<if test="expiredTime != null">
expired_time,
</if>
<if test="subsId != null">
subs_id,
</if>
<if test="status != null">
status,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="createTime != null">
create_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="phone != null">
#{phone,jdbcType=VARCHAR},
</if>
<if test="secretNo != null">
#{secretNo,jdbcType=VARCHAR},
</if>
<if test="poolKey != null">
#{poolKey,jdbcType=VARCHAR},
</if>
<if test="expiredTime != null">
#{expiredTime,jdbcType=TIMESTAMP},
</if>
<if test="subsId != null">
#{subsId,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=INTEGER},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.flow.entity.SecretPhone">
update t_secret_phone
<set>
<if test="secretNo != null">
secret_no = #{secretNo,jdbcType=VARCHAR},
</if>
<if test="poolKey != null">
pool_key = #{poolKey,jdbcType=VARCHAR},
</if>
<if test="expiredTime != null">
expired_time = #{expiredTime,jdbcType=TIMESTAMP},
</if>
<if test="subsId != null">
subs_id = #{subsId,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=INTEGER},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
</set>
where phone = #{phone,jdbcType=VARCHAR}
</update>
<update id="update" parameterType="com.boco.nbd.wios.flow.entity.SecretPhone">
update t_secret_phone
set secret_no = #{secretNo,jdbcType=VARCHAR},
pool_key = #{poolKey,jdbcType=VARCHAR},
expired_time = #{expiredTime,jdbcType=TIMESTAMP},
subs_id = #{subsId,jdbcType=VARCHAR},
status = #{status,jdbcType=INTEGER},
update_time = #{updateTime,jdbcType=TIMESTAMP},
create_time = #{createTime,jdbcType=TIMESTAMP}
where phone = #{phone,jdbcType=VARCHAR}
</update>
<select id="selectByPhone" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_secret_phone
where phone = #{phone,jdbcType=VARCHAR} and status=1
</select>
<select id="selectByExample" parameterType="com.boco.nbd.wios.flow.entity.SecretPhone"
resultType="com.boco.nbd.wios.flow.entity.SecretPhone">
select t.* from t_secret_phone t
<where>
<if test="secretNo != null and secretNo !=''">
and t.secret_no = #{secretNo}
</if>
<if test="status != null">
and t.status = #{status}
</if>
</where>
order by t.create_time desc
</select>
<select id="selectExpired"
resultType="com.boco.nbd.wios.flow.entity.SecretPhone">
select t.* from t_secret_phone t
where t.expired_time &lt;= now() and t.status=1
</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.boco.nbd.wios.manage.mapper.def.SettlementDetailMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetail">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="settlement_id" jdbcType="VARCHAR" property="settlementId" />
<result column="order_id" jdbcType="VARCHAR" property="orderId" />
<result column="user_name" jdbcType="VARCHAR" property="userName" />
<result column="user_phone" jdbcType="VARCHAR" property="userPhone" />
<result column="device_fee" jdbcType="DECIMAL" property="deviceFee" />
<result column="device_fee_with_tax" jdbcType="DECIMAL" property="deviceFeeWithTax" />
<result column="install_service_fee" jdbcType="DECIMAL" property="installServiceFee" />
<result column="install_service_fee_with_tax" jdbcType="DECIMAL" property="installServiceFeeWithTax" />
<result column="total_fee" jdbcType="DECIMAL" property="totalFee" />
<result column="total_fee_with_tax" jdbcType="DECIMAL" property="totalFeeWithTax" />
<result column="install_finish_time" jdbcType="TIMESTAMP" property="installFinishTime" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="is_del" jdbcType="INTEGER" property="isDel" />
</resultMap>
<sql id="Base_Column_List">
id, settlement_id, order_id, user_name, user_phone, device_fee, device_fee_with_tax,
install_service_fee, install_service_fee_with_tax, total_fee, total_fee_with_tax,
install_finish_time, create_time,is_del
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_settlement_detail
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetail">
insert into t_settlement_detail (id, settlement_id, order_id,
user_name, user_phone, device_fee,
device_fee_with_tax, install_service_fee, install_service_fee_with_tax,
total_fee, total_fee_with_tax, install_finish_time,
create_time)
values (#{id,jdbcType=INTEGER}, #{settlementId,jdbcType=VARCHAR}, #{orderId,jdbcType=VARCHAR},
#{userName,jdbcType=VARCHAR}, #{userPhone,jdbcType=VARCHAR}, #{deviceFee,jdbcType=DECIMAL},
#{deviceFeeWithTax,jdbcType=DECIMAL}, #{installServiceFee,jdbcType=DECIMAL}, #{installServiceFeeWithTax,jdbcType=DECIMAL},
#{totalFee,jdbcType=DECIMAL}, #{totalFeeWithTax,jdbcType=DECIMAL}, #{installFinishTime,jdbcType=TIMESTAMP},
#{createTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetail">
insert into t_settlement_detail
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="settlementId != null">
settlement_id,
</if>
<if test="orderId != null">
order_id,
</if>
<if test="userName != null">
user_name,
</if>
<if test="userPhone != null">
user_phone,
</if>
<if test="deviceFee != null">
device_fee,
</if>
<if test="deviceFeeWithTax != null">
device_fee_with_tax,
</if>
<if test="installServiceFee != null">
install_service_fee,
</if>
<if test="installServiceFeeWithTax != null">
install_service_fee_with_tax,
</if>
<if test="totalFee != null">
total_fee,
</if>
<if test="totalFeeWithTax != null">
total_fee_with_tax,
</if>
<if test="installFinishTime != null">
install_finish_time,
</if>
<if test="createTime != null">
create_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="settlementId != null">
#{settlementId,jdbcType=VARCHAR},
</if>
<if test="orderId != null">
#{orderId,jdbcType=VARCHAR},
</if>
<if test="userName != null">
#{userName,jdbcType=VARCHAR},
</if>
<if test="userPhone != null">
#{userPhone,jdbcType=VARCHAR},
</if>
<if test="deviceFee != null">
#{deviceFee,jdbcType=DECIMAL},
</if>
<if test="deviceFeeWithTax != null">
#{deviceFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="installServiceFee != null">
#{installServiceFee,jdbcType=DECIMAL},
</if>
<if test="installServiceFeeWithTax != null">
#{installServiceFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="totalFee != null">
#{totalFee,jdbcType=DECIMAL},
</if>
<if test="totalFeeWithTax != null">
#{totalFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="installFinishTime != null">
#{installFinishTime,jdbcType=TIMESTAMP},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetail">
update t_settlement_detail
<set>
<if test="settlementId != null">
settlement_id = #{settlementId,jdbcType=VARCHAR},
</if>
<if test="orderId != null">
order_id = #{orderId,jdbcType=VARCHAR},
</if>
<if test="userName != null">
user_name = #{userName,jdbcType=VARCHAR},
</if>
<if test="userPhone != null">
user_phone = #{userPhone,jdbcType=VARCHAR},
</if>
<if test="deviceFee != null">
device_fee = #{deviceFee,jdbcType=DECIMAL},
</if>
<if test="deviceFeeWithTax != null">
device_fee_with_tax = #{deviceFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="installServiceFee != null">
install_service_fee = #{installServiceFee,jdbcType=DECIMAL},
</if>
<if test="installServiceFeeWithTax != null">
install_service_fee_with_tax = #{installServiceFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="totalFee != null">
total_fee = #{totalFee,jdbcType=DECIMAL},
</if>
<if test="totalFeeWithTax != null">
total_fee_with_tax = #{totalFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="installFinishTime != null">
install_finish_time = #{installFinishTime,jdbcType=TIMESTAMP},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="deleteByOrderId">
UPDATE t_settlement_detail
SET is_del = 1
WHERE
order_id = #{orderId,jdbcType=VARCHAR}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetail">
update t_settlement_detail
set settlement_id = #{settlementId,jdbcType=VARCHAR},
order_id = #{orderId,jdbcType=VARCHAR},
user_name = #{userName,jdbcType=VARCHAR},
user_phone = #{userPhone,jdbcType=VARCHAR},
device_fee = #{deviceFee,jdbcType=DECIMAL},
device_fee_with_tax = #{deviceFeeWithTax,jdbcType=DECIMAL},
install_service_fee = #{installServiceFee,jdbcType=DECIMAL},
install_service_fee_with_tax = #{installServiceFeeWithTax,jdbcType=DECIMAL},
total_fee = #{totalFee,jdbcType=DECIMAL},
total_fee_with_tax = #{totalFeeWithTax,jdbcType=DECIMAL},
install_finish_time = #{installFinishTime,jdbcType=TIMESTAMP},
create_time = #{createTime,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_settlement_detail
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByOemId" resultMap="BaseResultMap">
select t.*
from t_settlement_detail t
left join t_order o on o.id=t.order_id
where
o.oem_id = #{oemId,jdbcType=INTEGER}
and
t.install_finish_time &gt; #{installFinishStartTime,jdbcType=VARCHAR}
and
t.install_finish_time &lt; #{installFinishEndTime,jdbcType=VARCHAR}
</select>
<select id="selectBySettlementId" resultMap="BaseResultMap">
select t.*
from t_settlement_detail t
where
t.settlement_id=#{settlementId}
</select>
<update id="batchUpdateSettlementId">
update t_settlement_detail
set settlement_id = #{settlementId,jdbcType=VARCHAR}
where id in
<foreach collection="idList" index="index" item="item" separator="," open="(" close=")">
#{item}
</foreach>
</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.boco.nbd.wios.manage.mapper.def.SettlementDetailSupplierMapper">
<resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetailSupplier">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="settlement_id" jdbcType="VARCHAR" property="settlementId" />
<result column="order_id" jdbcType="VARCHAR" property="orderId" />
<result column="user_name" jdbcType="VARCHAR" property="userName" />
<result column="user_phone" jdbcType="VARCHAR" property="userPhone" />
<result column="survey_fee" jdbcType="DECIMAL" property="surveyFee" />
<result column="survey_fee_with_tax" jdbcType="DECIMAL" property="surveyFeeWithTax" />
<result column="item_fee" jdbcType="DECIMAL" property="itemFee" />
<result column="item_fee_with_tax" jdbcType="DECIMAL" property="itemFeeWithTax" />
<result column="install_fee" jdbcType="DECIMAL" property="installFee" />
<result column="install_fee_with_tax" jdbcType="DECIMAL" property="installFeeWithTax" />
<result column="expand_fee" jdbcType="DECIMAL" property="expandFee" />
<result column="total_fee" jdbcType="DECIMAL" property="totalFee" />
<result column="total_fee_with_tax" jdbcType="DECIMAL" property="totalFeeWithTax" />
<result column="finish_time" jdbcType="TIMESTAMP" property="finishTime" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="is_del" jdbcType="INTEGER" property="isDel" />
</resultMap>
<sql id="Base_Column_List">
id, settlement_id, order_id, user_name, user_phone, survey_fee, survey_fee_with_tax,
item_fee, item_fee_with_tax, install_fee, install_fee_with_tax, expand_fee, total_fee,
total_fee_with_tax, finish_time, create_time,is_del
</sql>
<delete id="delete" parameterType="java.lang.Integer">
delete from t_settlement_detail_supplier
where id = #{id,jdbcType=INTEGER}
</delete>
<insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetailSupplier">
insert into t_settlement_detail_supplier (id, settlement_id, order_id,
user_name, user_phone, survey_fee,
survey_fee_with_tax, item_fee, item_fee_with_tax,
install_fee, install_fee_with_tax, expand_fee,
total_fee, total_fee_with_tax, finish_time,
create_time)
values (#{id,jdbcType=INTEGER}, #{settlementId,jdbcType=VARCHAR}, #{orderId,jdbcType=VARCHAR},
#{userName,jdbcType=VARCHAR}, #{userPhone,jdbcType=VARCHAR}, #{surveyFee,jdbcType=DECIMAL},
#{surveyFeeWithTax,jdbcType=DECIMAL}, #{itemFee,jdbcType=DECIMAL}, #{itemFeeWithTax,jdbcType=DECIMAL},
#{installFee,jdbcType=DECIMAL}, #{installFeeWithTax,jdbcType=DECIMAL}, #{expandFee,jdbcType=DECIMAL},
#{totalFee,jdbcType=DECIMAL}, #{totalFeeWithTax,jdbcType=DECIMAL}, #{finishTime,jdbcType=TIMESTAMP},
#{createTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertDynamic" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetailSupplier">
insert into t_settlement_detail_supplier
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="settlementId != null">
settlement_id,
</if>
<if test="orderId != null">
order_id,
</if>
<if test="userName != null">
user_name,
</if>
<if test="userPhone != null">
user_phone,
</if>
<if test="surveyFee != null">
survey_fee,
</if>
<if test="surveyFeeWithTax != null">
survey_fee_with_tax,
</if>
<if test="itemFee != null">
item_fee,
</if>
<if test="itemFeeWithTax != null">
item_fee_with_tax,
</if>
<if test="installFee != null">
install_fee,
</if>
<if test="installFeeWithTax != null">
install_fee_with_tax,
</if>
<if test="expandFee != null">
expand_fee,
</if>
<if test="totalFee != null">
total_fee,
</if>
<if test="totalFeeWithTax != null">
total_fee_with_tax,
</if>
<if test="finishTime != null">
finish_time,
</if>
<if test="createTime != null">
create_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="settlementId != null">
#{settlementId,jdbcType=VARCHAR},
</if>
<if test="orderId != null">
#{orderId,jdbcType=VARCHAR},
</if>
<if test="userName != null">
#{userName,jdbcType=VARCHAR},
</if>
<if test="userPhone != null">
#{userPhone,jdbcType=VARCHAR},
</if>
<if test="surveyFee != null">
#{surveyFee,jdbcType=DECIMAL},
</if>
<if test="surveyFeeWithTax != null">
#{surveyFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="itemFee != null">
#{itemFee,jdbcType=DECIMAL},
</if>
<if test="itemFeeWithTax != null">
#{itemFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="installFee != null">
#{installFee,jdbcType=DECIMAL},
</if>
<if test="installFeeWithTax != null">
#{installFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="expandFee != null">
#{expandFee,jdbcType=DECIMAL},
</if>
<if test="totalFee != null">
#{totalFee,jdbcType=DECIMAL},
</if>
<if test="totalFeeWithTax != null">
#{totalFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="finishTime != null">
#{finishTime,jdbcType=TIMESTAMP},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateDynamic" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetailSupplier">
update t_settlement_detail_supplier
<set>
<if test="settlementId != null">
settlement_id = #{settlementId,jdbcType=VARCHAR},
</if>
<if test="orderId != null">
order_id = #{orderId,jdbcType=VARCHAR},
</if>
<if test="userName != null">
user_name = #{userName,jdbcType=VARCHAR},
</if>
<if test="userPhone != null">
user_phone = #{userPhone,jdbcType=VARCHAR},
</if>
<if test="surveyFee != null">
survey_fee = #{surveyFee,jdbcType=DECIMAL},
</if>
<if test="surveyFeeWithTax != null">
survey_fee_with_tax = #{surveyFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="itemFee != null">
item_fee = #{itemFee,jdbcType=DECIMAL},
</if>
<if test="itemFeeWithTax != null">
item_fee_with_tax = #{itemFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="installFee != null">
install_fee = #{installFee,jdbcType=DECIMAL},
</if>
<if test="installFeeWithTax != null">
install_fee_with_tax = #{installFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="expandFee != null">
expand_fee = #{expandFee,jdbcType=DECIMAL},
</if>
<if test="totalFee != null">
total_fee = #{totalFee,jdbcType=DECIMAL},
</if>
<if test="totalFeeWithTax != null">
total_fee_with_tax = #{totalFeeWithTax,jdbcType=DECIMAL},
</if>
<if test="finishTime != null">
finish_time = #{finishTime,jdbcType=TIMESTAMP},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="update" parameterType="com.boco.nbd.wios.manage.entity.settlement.po.SettlementDetailSupplier">
update t_settlement_detail_supplier
set settlement_id = #{settlementId,jdbcType=VARCHAR},
order_id = #{orderId,jdbcType=VARCHAR},
user_name = #{userName,jdbcType=VARCHAR},
user_phone = #{userPhone,jdbcType=VARCHAR},
survey_fee = #{surveyFee,jdbcType=DECIMAL},
survey_fee_with_tax = #{surveyFeeWithTax,jdbcType=DECIMAL},
item_fee = #{itemFee,jdbcType=DECIMAL},
item_fee_with_tax = #{itemFeeWithTax,jdbcType=DECIMAL},
install_fee = #{installFee,jdbcType=DECIMAL},
install_fee_with_tax = #{installFeeWithTax,jdbcType=DECIMAL},
expand_fee = #{expandFee,jdbcType=DECIMAL},
total_fee = #{totalFee,jdbcType=DECIMAL},
total_fee_with_tax = #{totalFeeWithTax,jdbcType=DECIMAL},
finish_time = #{finishTime,jdbcType=TIMESTAMP},
create_time = #{createTime,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=INTEGER}
</update>
<select id="selectById" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from t_settlement_detail_supplier
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectBySupplierId" resultMap="BaseResultMap">
select t.*
from t_settlement_detail_supplier t
left join t_order o on o.id=t.order_id
where
o.install_supplier_id = #{supplierId,jdbcType=INTEGER}
and
t.finish_time &gt; #{finishStartTime,jdbcType=VARCHAR}
and
t.finish_time &lt; #{finishEndTime,jdbcType=VARCHAR}
</select>
<select id="selectBySettlementId" resultMap="BaseResultMap">
select t.*
from t_settlement_detail_supplier t
where
t.settlement_id=#{settlementId}
</select>
<update id="batchUpdateSettlementId">
update t_settlement_detail_supplier
set settlement_id = #{settlementId,jdbcType=VARCHAR}
where id in
<foreach collection="idList" index="index" item="item" separator="," open="(" close=")">
#{item}
</foreach>
</update>
<update id="deleteByOrderId">
UPDATE t_settlement_detail_supplier
SET is_del = 1
WHERE
order_id = #{orderId,jdbcType=VARCHAR}
</update>
</mapper>
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论