|
@@ -6,8 +6,8 @@
|
|
|
<result column="PERSONNEL_JOB_NUMBER" jdbcType="VARCHAR" property="personnelJobNumber" />
|
|
|
<result column="PERSONNEL_POST" jdbcType="VARCHAR" property="personnelPost" />
|
|
|
<result column="PERSONNEL_NAME" jdbcType="VARCHAR" property="personnelName" />
|
|
|
- <result column="PERSONNEL_DEPARTMENT_ID" jdbcType="DECIMAL" property="departmentId" />
|
|
|
- <result column="PERSONNEL_WORKSHOPID" jdbcType="VARCHAR" property="personnelWorkshopid" />
|
|
|
+ <result column="PERSONNEL_DEPARTMENT_ID" jdbcType="DECIMAL" property="personnelDepartmentId" />
|
|
|
+ <result column="PERSONNEL_WORKSHOPID" jdbcType="DECIMAL" property="personnelWorkshopid" />
|
|
|
<result column="PERSONNEL_SHIFTS" jdbcType="VARCHAR" property="personnelShifts" />
|
|
|
<result column="PERSONNEL_TEAM" jdbcType="VARCHAR" property="personnelTeam" />
|
|
|
<result column="INSERT_USERNAME" jdbcType="VARCHAR" property="insertUsername" />
|
|
@@ -15,27 +15,29 @@
|
|
|
<result column="UPDATE_USERNAME" jdbcType="VARCHAR" property="updateUsername" />
|
|
|
<result column="UPDATE_TIME" jdbcType="TIMESTAMP" property="updateTime" />
|
|
|
<result column="INSERT_UPDATE_REMARK" jdbcType="VARCHAR" property="insertUpdateRemark" />
|
|
|
- <result column="EAS_PERSONNEL_ID" jdbcType="DECIMAL" property="easPersonnelId" />
|
|
|
+ <result column="EAS_PERSONNEL_ID" jdbcType="VARCHAR" property="easPersonnelId" />
|
|
|
<result column="DELETED" jdbcType="DECIMAL" property="deleted" />
|
|
|
<result column="USERNAME" jdbcType="VARCHAR" property="username" />
|
|
|
<result column="PASSWORD" jdbcType="VARCHAR" property="password" />
|
|
|
+ <result column="PERSONNEL_SSO_ID" jdbcType="VARCHAR" property="personnelSsoId" />
|
|
|
</resultMap>
|
|
|
<sql id="columns">
|
|
|
- PERSONNEL_ID, PERSONNEL_JOB_NUMBER, PERSONNEL_POST, PERSONNEL_NAME, PERSONNEL_DEPARTMENT_ID, PERSONNEL_WORKSHOPID,
|
|
|
- PERSONNEL_SHIFTS, PERSONNEL_TEAM, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME,
|
|
|
- UPDATE_TIME, INSERT_UPDATE_REMARK, EAS_PERSONNEL_ID, DELETED, USERNAME, PASSWORD
|
|
|
+ PERSONNEL_ID, PERSONNEL_JOB_NUMBER, PERSONNEL_POST, PERSONNEL_NAME, PERSONNEL_DEPARTMENT_ID,
|
|
|
+ PERSONNEL_WORKSHOPID, PERSONNEL_SHIFTS, PERSONNEL_TEAM, INSERT_USERNAME, INSERT_TIME,
|
|
|
+ UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK, EAS_PERSONNEL_ID, DELETED, USERNAME,
|
|
|
+ PASSWORD, PERSONNEL_SSO_ID
|
|
|
</sql>
|
|
|
<sql id="columns_alias">
|
|
|
- t.PERSONNEL_ID, t.PERSONNEL_JOB_NUMBER, t.PERSONNEL_POST, t.PERSONNEL_NAME, t.PERSONNEL_DEPARTMENT_ID,
|
|
|
+ t.PERSONNEL_ID, t.PERSONNEL_JOB_NUMBER, t.PERSONNEL_POST, t.PERSONNEL_NAME, t.PERSONNEL_DEPARTMENT_ID,
|
|
|
t.PERSONNEL_WORKSHOPID, t.PERSONNEL_SHIFTS, t.PERSONNEL_TEAM, t.INSERT_USERNAME,
|
|
|
t.INSERT_TIME, t.UPDATE_USERNAME, t.UPDATE_TIME, t.INSERT_UPDATE_REMARK, t.EAS_PERSONNEL_ID,
|
|
|
- t.DELETED, t.USERNAME, t.PASSWORD
|
|
|
+ t.DELETED, t.USERNAME, t.PASSWORD, t.PERSONNEL_SSO_ID
|
|
|
</sql>
|
|
|
<sql id="select">
|
|
|
- SELECT <include refid="columns"/> FROM RMS_PERSONNEL
|
|
|
+ SELECT <include refid="columns" /> FROM RMS_PERSONNEL
|
|
|
</sql>
|
|
|
<sql id="select_alias">
|
|
|
- SELECT <include refid="columns_alias"/> FROM RMS_PERSONNEL t
|
|
|
+ SELECT <include refid="columns_alias" /> FROM RMS_PERSONNEL t
|
|
|
</sql>
|
|
|
<sql id="where">
|
|
|
<where>
|
|
@@ -51,10 +53,10 @@
|
|
|
<if test="personnelName != null and personnelName != ''">
|
|
|
and PERSONNEL_NAME = #{personnelName}
|
|
|
</if>
|
|
|
- <if test="departmentId != null">
|
|
|
- and PERSONNEL_DEPARTMENT_ID = #{departmentId}
|
|
|
+ <if test="personnelDepartmentId != null">
|
|
|
+ and PERSONNEL_DEPARTMENT_ID = #{personnelDepartmentId}
|
|
|
</if>
|
|
|
- <if test="personnelWorkshopid != null and personnelWorkshopid != ''">
|
|
|
+ <if test="personnelWorkshopid != null">
|
|
|
and PERSONNEL_WORKSHOPID = #{personnelWorkshopid}
|
|
|
</if>
|
|
|
<if test="personnelShifts != null and personnelShifts != ''">
|
|
@@ -78,7 +80,7 @@
|
|
|
<if test="insertUpdateRemark != null and insertUpdateRemark != ''">
|
|
|
and INSERT_UPDATE_REMARK = #{insertUpdateRemark}
|
|
|
</if>
|
|
|
- <if test="easPersonnelId != null">
|
|
|
+ <if test="easPersonnelId != null and easPersonnelId != ''">
|
|
|
and EAS_PERSONNEL_ID = #{easPersonnelId}
|
|
|
</if>
|
|
|
<if test="deleted != null">
|
|
@@ -90,6 +92,9 @@
|
|
|
<if test="password != null and password != ''">
|
|
|
and PASSWORD = #{password}
|
|
|
</if>
|
|
|
+ <if test="personnelSsoId != null and personnelSsoId != ''">
|
|
|
+ and PERSONNEL_SSO_ID = #{personnelSsoId}
|
|
|
+ </if>
|
|
|
</where>
|
|
|
</sql>
|
|
|
<sql id="whereLike">
|
|
@@ -106,11 +111,11 @@
|
|
|
<if test="personnelName != null and personnelName != ''">
|
|
|
and PERSONNEL_NAME LIKE '%${personnelName}%'
|
|
|
</if>
|
|
|
- <if test="departmentId != null">
|
|
|
- and PERSONNEL_DEPARTMENT_ID = #{departmentId}
|
|
|
+ <if test="personnelDepartmentId != null">
|
|
|
+ and PERSONNEL_DEPARTMENT_ID = #{personnelDepartmentId}
|
|
|
</if>
|
|
|
- <if test="personnelWorkshopid != null and personnelWorkshopid != ''">
|
|
|
- and PERSONNEL_WORKSHOPID LIKE '%${personnelWorkshopid}%'
|
|
|
+ <if test="personnelWorkshopid != null">
|
|
|
+ and PERSONNEL_WORKSHOPID = #{personnelWorkshopid}
|
|
|
</if>
|
|
|
<if test="personnelShifts != null and personnelShifts != ''">
|
|
|
and PERSONNEL_SHIFTS LIKE '%${personnelShifts}%'
|
|
@@ -133,8 +138,8 @@
|
|
|
<if test="insertUpdateRemark != null and insertUpdateRemark != ''">
|
|
|
and INSERT_UPDATE_REMARK LIKE '%${insertUpdateRemark}%'
|
|
|
</if>
|
|
|
- <if test="easPersonnelId != null">
|
|
|
- and EAS_PERSONNEL_ID = #{easPersonnelId}
|
|
|
+ <if test="easPersonnelId != null and easPersonnelId != ''">
|
|
|
+ and EAS_PERSONNEL_ID LIKE '%${easPersonnelId}%'
|
|
|
</if>
|
|
|
<if test="deleted != null">
|
|
|
and DELETED = #{deleted}
|
|
@@ -145,9 +150,12 @@
|
|
|
<if test="password != null and password != ''">
|
|
|
and PASSWORD LIKE '%${password}%'
|
|
|
</if>
|
|
|
+ <if test="personnelSsoId != null and personnelSsoId != ''">
|
|
|
+ and PERSONNEL_SSO_ID LIKE '%${personnelSsoId}%'
|
|
|
+ </if>
|
|
|
</where>
|
|
|
</sql>
|
|
|
- <delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal">
|
|
|
+ <delete id="deleteByPrimaryKey" parameterType="java.lang.Short">
|
|
|
delete from RMS_PERSONNEL
|
|
|
where PERSONNEL_ID = #{personnelId,jdbcType=DECIMAL}
|
|
|
</delete>
|
|
@@ -163,10 +171,10 @@
|
|
|
<if test="personnelName != null and personnelName != ''">
|
|
|
or PERSONNEL_NAME = #{personnelName}
|
|
|
</if>
|
|
|
- <if test="departmentId != null">
|
|
|
- or PERSONNEL_DEPARTMENT_ID = #{departmentId}
|
|
|
+ <if test="personnelDepartmentId != null">
|
|
|
+ or PERSONNEL_DEPARTMENT_ID = #{personnelDepartmentId}
|
|
|
</if>
|
|
|
- <if test="personnelWorkshopid != null and personnelWorkshopid != ''">
|
|
|
+ <if test="personnelWorkshopid != null">
|
|
|
or PERSONNEL_WORKSHOPID = #{personnelWorkshopid}
|
|
|
</if>
|
|
|
<if test="personnelShifts != null and personnelShifts != ''">
|
|
@@ -190,7 +198,7 @@
|
|
|
<if test="insertUpdateRemark != null and insertUpdateRemark != ''">
|
|
|
or INSERT_UPDATE_REMARK = #{insertUpdateRemark}
|
|
|
</if>
|
|
|
- <if test="easPersonnelId != null">
|
|
|
+ <if test="easPersonnelId != null and easPersonnelId != ''">
|
|
|
or EAS_PERSONNEL_ID = #{easPersonnelId}
|
|
|
</if>
|
|
|
<if test="deleted != null">
|
|
@@ -202,22 +210,25 @@
|
|
|
<if test="password != null and password != ''">
|
|
|
or PASSWORD = #{password}
|
|
|
</if>
|
|
|
+ <if test="personnelSsoId != null and personnelSsoId != ''">
|
|
|
+ or PERSONNEL_SSO_ID = #{personnelSsoId}
|
|
|
+ </if>
|
|
|
</delete>
|
|
|
<insert id="insert" parameterType="com.steerinfo.dil.model.RmsPersonnel">
|
|
|
insert into RMS_PERSONNEL (PERSONNEL_ID, PERSONNEL_JOB_NUMBER,
|
|
|
- PERSONNEL_POST, PERSONNEL_NAME, PERSONNEL_DEPARTMENT_ID,
|
|
|
+ PERSONNEL_POST, PERSONNEL_NAME, PERSONNEL_DEPARTMENT_ID,
|
|
|
PERSONNEL_WORKSHOPID, PERSONNEL_SHIFTS, PERSONNEL_TEAM,
|
|
|
INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME,
|
|
|
UPDATE_TIME, INSERT_UPDATE_REMARK, EAS_PERSONNEL_ID,
|
|
|
- DELETED, USERNAME, PASSWORD
|
|
|
- )
|
|
|
+ DELETED, USERNAME, PASSWORD,
|
|
|
+ PERSONNEL_SSO_ID)
|
|
|
values (#{personnelId,jdbcType=DECIMAL}, #{personnelJobNumber,jdbcType=VARCHAR},
|
|
|
- #{personnelPost,jdbcType=VARCHAR}, #{personnelName,jdbcType=VARCHAR}, #{departmentId,jdbcType=DECIMAL},
|
|
|
- #{personnelWorkshopid,jdbcType=VARCHAR}, #{personnelShifts,jdbcType=VARCHAR}, #{personnelTeam,jdbcType=VARCHAR},
|
|
|
+ #{personnelPost,jdbcType=VARCHAR}, #{personnelName,jdbcType=VARCHAR}, #{personnelDepartmentId,jdbcType=DECIMAL},
|
|
|
+ #{personnelWorkshopid,jdbcType=DECIMAL}, #{personnelShifts,jdbcType=VARCHAR}, #{personnelTeam,jdbcType=VARCHAR},
|
|
|
#{insertUsername,jdbcType=VARCHAR}, #{insertTime,jdbcType=TIMESTAMP}, #{updateUsername,jdbcType=VARCHAR},
|
|
|
- #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR}, #{easPersonnelId,jdbcType=DECIMAL},
|
|
|
- #{deleted,jdbcType=DECIMAL}, #{username,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR}
|
|
|
- )
|
|
|
+ #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR}, #{easPersonnelId,jdbcType=VARCHAR},
|
|
|
+ #{deleted,jdbcType=DECIMAL}, #{username,jdbcType=VARCHAR}, #{password,jdbcType=VARCHAR},
|
|
|
+ #{personnelSsoId,jdbcType=VARCHAR})
|
|
|
</insert>
|
|
|
<insert id="insertSelective" parameterType="com.steerinfo.dil.model.RmsPersonnel">
|
|
|
insert into RMS_PERSONNEL
|
|
@@ -234,7 +245,7 @@
|
|
|
<if test="personnelName != null">
|
|
|
PERSONNEL_NAME,
|
|
|
</if>
|
|
|
- <if test="departmentId != null">
|
|
|
+ <if test="personnelDepartmentId != null">
|
|
|
PERSONNEL_DEPARTMENT_ID,
|
|
|
</if>
|
|
|
<if test="personnelWorkshopid != null">
|
|
@@ -273,6 +284,9 @@
|
|
|
<if test="password != null">
|
|
|
PASSWORD,
|
|
|
</if>
|
|
|
+ <if test="personnelSsoId != null">
|
|
|
+ PERSONNEL_SSO_ID,
|
|
|
+ </if>
|
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="personnelId != null">
|
|
@@ -287,11 +301,11 @@
|
|
|
<if test="personnelName != null">
|
|
|
#{personnelName,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="departmentId != null">
|
|
|
- #{departmentId,jdbcType=DECIMAL},
|
|
|
+ <if test="personnelDepartmentId != null">
|
|
|
+ #{personnelDepartmentId,jdbcType=DECIMAL},
|
|
|
</if>
|
|
|
<if test="personnelWorkshopid != null">
|
|
|
- #{personnelWorkshopid,jdbcType=VARCHAR},
|
|
|
+ #{personnelWorkshopid,jdbcType=DECIMAL},
|
|
|
</if>
|
|
|
<if test="personnelShifts != null">
|
|
|
#{personnelShifts,jdbcType=VARCHAR},
|
|
@@ -315,7 +329,7 @@
|
|
|
#{insertUpdateRemark,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
<if test="easPersonnelId != null">
|
|
|
- #{easPersonnelId,jdbcType=DECIMAL},
|
|
|
+ #{easPersonnelId,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
<if test="deleted != null">
|
|
|
#{deleted,jdbcType=DECIMAL},
|
|
@@ -326,6 +340,9 @@
|
|
|
<if test="password != null">
|
|
|
#{password,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
+ <if test="personnelSsoId != null">
|
|
|
+ #{personnelSsoId,jdbcType=VARCHAR},
|
|
|
+ </if>
|
|
|
</trim>
|
|
|
</insert>
|
|
|
<update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.RmsPersonnel">
|
|
@@ -333,8 +350,8 @@
|
|
|
set PERSONNEL_JOB_NUMBER = #{personnelJobNumber,jdbcType=VARCHAR},
|
|
|
PERSONNEL_POST = #{personnelPost,jdbcType=VARCHAR},
|
|
|
PERSONNEL_NAME = #{personnelName,jdbcType=VARCHAR},
|
|
|
- PERSONNEL_DEPARTMENT_ID = #{departmentId,jdbcType=DECIMAL},
|
|
|
- PERSONNEL_WORKSHOPID = #{personnelWorkshopid,jdbcType=VARCHAR},
|
|
|
+ PERSONNEL_DEPARTMENT_ID = #{personnelDepartmentId,jdbcType=DECIMAL},
|
|
|
+ PERSONNEL_WORKSHOPID = #{personnelWorkshopid,jdbcType=DECIMAL},
|
|
|
PERSONNEL_SHIFTS = #{personnelShifts,jdbcType=VARCHAR},
|
|
|
PERSONNEL_TEAM = #{personnelTeam,jdbcType=VARCHAR},
|
|
|
INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR},
|
|
@@ -342,10 +359,11 @@
|
|
|
UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
|
|
|
UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
|
|
|
INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
|
|
|
- EAS_PERSONNEL_ID = #{easPersonnelId,jdbcType=DECIMAL},
|
|
|
+ EAS_PERSONNEL_ID = #{easPersonnelId,jdbcType=VARCHAR},
|
|
|
DELETED = #{deleted,jdbcType=DECIMAL},
|
|
|
USERNAME = #{username,jdbcType=VARCHAR},
|
|
|
- PASSWORD = #{password,jdbcType=VARCHAR}
|
|
|
+ PASSWORD = #{password,jdbcType=VARCHAR},
|
|
|
+ PERSONNEL_SSO_ID = #{personnelSsoId,jdbcType=VARCHAR}
|
|
|
where PERSONNEL_ID = #{personnelId,jdbcType=DECIMAL}
|
|
|
</update>
|
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.RmsPersonnel">
|
|
@@ -360,11 +378,11 @@
|
|
|
<if test="personnelName != null">
|
|
|
PERSONNEL_NAME = #{personnelName,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="departmentId != null">
|
|
|
- PERSONNEL_DEPARTMENT_ID = #{departmentId,jdbcType=DECIMAL},
|
|
|
+ <if test="personnelDepartmentId != null">
|
|
|
+ PERSONNEL_DEPARTMENT_ID = #{personnelDepartmentId,jdbcType=DECIMAL},
|
|
|
</if>
|
|
|
<if test="personnelWorkshopid != null">
|
|
|
- PERSONNEL_WORKSHOPID = #{personnelWorkshopid,jdbcType=VARCHAR},
|
|
|
+ PERSONNEL_WORKSHOPID = #{personnelWorkshopid,jdbcType=DECIMAL},
|
|
|
</if>
|
|
|
<if test="personnelShifts != null">
|
|
|
PERSONNEL_SHIFTS = #{personnelShifts,jdbcType=VARCHAR},
|
|
@@ -388,7 +406,7 @@
|
|
|
INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
<if test="easPersonnelId != null">
|
|
|
- EAS_PERSONNEL_ID = #{easPersonnelId,jdbcType=DECIMAL},
|
|
|
+ EAS_PERSONNEL_ID = #{easPersonnelId,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
<if test="deleted != null">
|
|
|
DELETED = #{deleted,jdbcType=DECIMAL},
|
|
@@ -399,125 +417,132 @@
|
|
|
<if test="password != null">
|
|
|
PASSWORD = #{password,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
+ <if test="personnelSsoId != null">
|
|
|
+ PERSONNEL_SSO_ID = #{personnelSsoId,jdbcType=VARCHAR},
|
|
|
+ </if>
|
|
|
</set>
|
|
|
where PERSONNEL_ID = #{personnelId,jdbcType=DECIMAL}
|
|
|
</update>
|
|
|
- <select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
|
|
|
- <include refid="select"/>
|
|
|
+ <select id="selectByPrimaryKey" parameterType="java.lang.Short" resultMap="BaseResultMap">
|
|
|
+ <include refid="select" />
|
|
|
where PERSONNEL_ID = #{personnelId,jdbcType=DECIMAL}
|
|
|
</select>
|
|
|
<select id="selectByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
|
|
|
- <include refid="select"/>
|
|
|
- <include refid="where"/>
|
|
|
+ <include refid="select" />
|
|
|
+ <include refid="where" />
|
|
|
</select>
|
|
|
<select id="selectLikeByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
|
|
|
- <include refid="select"/>
|
|
|
- <include refid="whereLike"/>
|
|
|
+ <include refid="select" />
|
|
|
+ <include refid="whereLike" />
|
|
|
</select>
|
|
|
<insert id="batchInsert" parameterType="java.util.List">
|
|
|
insert into RMS_PERSONNEL
|
|
|
(PERSONNEL_ID,
|
|
|
PERSONNEL_JOB_NUMBER, PERSONNEL_POST,
|
|
|
- PERSONNEL_NAME, PERSONNEL_DEPARTMENT_ID, PERSONNEL_WORKSHOPID,
|
|
|
- PERSONNEL_SHIFTS, PERSONNEL_TEAM,
|
|
|
- INSERT_USERNAME, INSERT_TIME,
|
|
|
- UPDATE_USERNAME, UPDATE_TIME,
|
|
|
- INSERT_UPDATE_REMARK, EAS_PERSONNEL_ID,
|
|
|
- DELETED, USERNAME, PASSWORD
|
|
|
- )
|
|
|
+ PERSONNEL_NAME, PERSONNEL_DEPARTMENT_ID,
|
|
|
+ PERSONNEL_WORKSHOPID, PERSONNEL_SHIFTS,
|
|
|
+ PERSONNEL_TEAM, INSERT_USERNAME,
|
|
|
+ INSERT_TIME, UPDATE_USERNAME,
|
|
|
+ UPDATE_TIME, INSERT_UPDATE_REMARK,
|
|
|
+ EAS_PERSONNEL_ID, DELETED, USERNAME,
|
|
|
+ PASSWORD, PERSONNEL_SSO_ID)
|
|
|
( <foreach collection="list" item="item" separator="union all">
|
|
|
select
|
|
|
#{item.personnelId,jdbcType=DECIMAL},
|
|
|
#{item.personnelJobNumber,jdbcType=VARCHAR}, #{item.personnelPost,jdbcType=VARCHAR},
|
|
|
- #{item.personnelName,jdbcType=VARCHAR}, #{item.departmentId,jdbcType=DECIMAL}, #{item.personnelWorkshopid,jdbcType=VARCHAR},
|
|
|
- #{item.personnelShifts,jdbcType=VARCHAR}, #{item.personnelTeam,jdbcType=VARCHAR},
|
|
|
- #{item.insertUsername,jdbcType=VARCHAR}, #{item.insertTime,jdbcType=TIMESTAMP},
|
|
|
- #{item.updateUsername,jdbcType=VARCHAR}, #{item.updateTime,jdbcType=TIMESTAMP},
|
|
|
- #{item.insertUpdateRemark,jdbcType=VARCHAR}, #{item.easPersonnelId,jdbcType=DECIMAL},
|
|
|
- #{item.deleted,jdbcType=DECIMAL}, #{item.username,jdbcType=VARCHAR}, #{item.password,jdbcType=VARCHAR}
|
|
|
- from dual
|
|
|
+ #{item.personnelName,jdbcType=VARCHAR}, #{item.personnelDepartmentId,jdbcType=DECIMAL},
|
|
|
+ #{item.personnelWorkshopid,jdbcType=DECIMAL}, #{item.personnelShifts,jdbcType=VARCHAR},
|
|
|
+ #{item.personnelTeam,jdbcType=VARCHAR}, #{item.insertUsername,jdbcType=VARCHAR},
|
|
|
+ #{item.insertTime,jdbcType=TIMESTAMP}, #{item.updateUsername,jdbcType=VARCHAR},
|
|
|
+ #{item.updateTime,jdbcType=TIMESTAMP}, #{item.insertUpdateRemark,jdbcType=VARCHAR},
|
|
|
+ #{item.easPersonnelId,jdbcType=VARCHAR}, #{item.deleted,jdbcType=DECIMAL}, #{item.username,jdbcType=VARCHAR},
|
|
|
+ #{item.password,jdbcType=VARCHAR}, #{item.personnelSsoId,jdbcType=VARCHAR} from dual
|
|
|
</foreach> )
|
|
|
</insert>
|
|
|
<update id="batchUpdate" parameterType="java.util.List">
|
|
|
update RMS_PERSONNEL
|
|
|
set
|
|
|
PERSONNEL_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,PERSONNEL_JOB_NUMBER=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelJobNumber,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,PERSONNEL_POST=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelPost,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,PERSONNEL_NAME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelName,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,PERSONNEL_DEPARTMENT_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
- when #{item.personnelId,jdbcType=DECIMAL} then #{item.departmentId,jdbcType=DECIMAL}
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
+ when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelDepartmentId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,PERSONNEL_WORKSHOPID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
- when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelWorkshopid,jdbcType=VARCHAR}
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
+ when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelWorkshopid,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,PERSONNEL_SHIFTS=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelShifts,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,PERSONNEL_TEAM=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelTeam,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,INSERT_USERNAME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,INSERT_TIME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP}
|
|
|
</foreach>
|
|
|
,UPDATE_USERNAME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,UPDATE_TIME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP}
|
|
|
</foreach>
|
|
|
,INSERT_UPDATE_REMARK=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,EAS_PERSONNEL_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
- when #{item.personnelId,jdbcType=DECIMAL} then #{item.easPersonnelId,jdbcType=DECIMAL}
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
+ when #{item.personnelId,jdbcType=DECIMAL} then #{item.easPersonnelId,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,DELETED=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.deleted,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,USERNAME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.username,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,PASSWORD=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case PERSONNEL_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
when #{item.personnelId,jdbcType=DECIMAL} then #{item.password,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
+ ,PERSONNEL_SSO_ID=
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case PERSONNEL_ID" separator=" ">
|
|
|
+ when #{item.personnelId,jdbcType=DECIMAL} then #{item.personnelSsoId,jdbcType=VARCHAR}
|
|
|
+ </foreach>
|
|
|
where PERSONNEL_ID in
|
|
|
- <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
|
|
|
+ <foreach close=")" collection="list" index="index" item="item" open="(" separator=",">
|
|
|
#{item.personnelId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
</update>
|
|
|
<delete id="batchDelete" parameterType="java.util.List">
|
|
|
delete from RMS_PERSONNEL
|
|
|
where PERSONNEL_ID in
|
|
|
- <foreach collection="list" item="id" open="(" close=")" separator=",">
|
|
|
+ <foreach close=")" collection="list" item="id" open="(" separator=",">
|
|
|
#{id}
|
|
|
</foreach>
|
|
|
</delete>
|
|
@@ -607,24 +632,54 @@
|
|
|
|
|
|
<!-- 根据id值展示人员信息-->
|
|
|
<select id="selectPersonnelById" resultType="java.util.LinkedHashMap">
|
|
|
- SELECT
|
|
|
- RP.PERSONNEL_ID AS "personnelId",
|
|
|
- RP.PERSONNEL_DEPARTMENT_ID AS "departmentId",
|
|
|
- RP.PERSONNEL_JOB_NUMBER AS "personnelJobNumber",
|
|
|
- RP.PERSONNEL_NAME AS "personnelName",
|
|
|
- RP.PERSONNEL_POST AS "personnelPost",
|
|
|
- RP.PERSONNEL_WORKSHOPID AS "personnelWorkshopid",
|
|
|
- RP.PERSONNEL_SHIFTS AS "personnelShifts",
|
|
|
- RP.PERSONNEL_TEAM AS "personnelTeam"
|
|
|
- FROM RMS_PERSONNEL RP
|
|
|
- WHERE RP.PERSONNEL_ID=#{id}
|
|
|
- </select>
|
|
|
+ SELECT
|
|
|
+ RP.PERSONNEL_ID AS "personnelId",
|
|
|
+ RP.PERSONNEL_DEPARTMENT_ID AS "departmentId",
|
|
|
+ RP.PERSONNEL_JOB_NUMBER AS "personnelJobNumber",
|
|
|
+ RP.PERSONNEL_NAME AS "personnelName",
|
|
|
+ RP.PERSONNEL_POST AS "personnelPost",
|
|
|
+ RP.PERSONNEL_WORKSHOPID AS "personnelWorkshopid",
|
|
|
+ RP.PERSONNEL_SHIFTS AS "personnelShifts",
|
|
|
+ RP.PERSONNEL_TEAM AS "personnelTeam"
|
|
|
+ FROM RMS_PERSONNEL RP
|
|
|
+ WHERE RP.PERSONNEL_ID=#{id}
|
|
|
+ </select>
|
|
|
<!-- 获得托运人信息-->
|
|
|
<select id="getShipperId" resultType="java.util.LinkedHashMap">
|
|
|
- SELECT RS.SHIPPER_ID AS "id",
|
|
|
- RS.SHIPPER_ID AS "value",
|
|
|
- RS.SHIPPER_NAME AS "label"
|
|
|
- FROM RMS_SHIPPER RS
|
|
|
- WHERE RS.DELETED!=1
|
|
|
- </select>
|
|
|
+ SELECT RS.SHIPPER_ID AS "id",
|
|
|
+ RS.SHIPPER_ID AS "value",
|
|
|
+ RS.SHIPPER_NAME AS "label"
|
|
|
+ FROM RMS_SHIPPER RS
|
|
|
+ WHERE RS.DELETED!=1
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <!-- 获得托运人信息-->
|
|
|
+ <select id="getSecondShipper" resultType="java.util.LinkedHashMap">
|
|
|
+ SELECT RS.SHIPPER_ID AS "id",
|
|
|
+ RS.SHIPPER_ID AS "value",
|
|
|
+ RS.SHIPPER_NAME AS "label",
|
|
|
+ RS.SHIPPER_SSO_ID AS "shipperSsoId"
|
|
|
+ FROM RMS_SHIPPER RS
|
|
|
+ WHERE RS.SHIPPER_DEPARTMENT_LEVEL = 'LV2'
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <!-- 获得托运人信息-->
|
|
|
+ <select id="getThirdShipper" resultType="java.util.LinkedHashMap">
|
|
|
+ SELECT RS.SHIPPER_ID AS "id",
|
|
|
+ RS.SHIPPER_ID AS "value",
|
|
|
+ RS.SHIPPER_NAME AS "label",
|
|
|
+ RS.SHIPPER_SSO_ID AS "shipperSsoId"
|
|
|
+ FROM RMS_SHIPPER RS
|
|
|
+ WHERE RS.SHIPPER_DEPARTMENT_LEVEL = 'LV3'
|
|
|
+ AND RS.SHIPPER_FATHER_ID = #{shipperId}
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <!-- 查询sso主键以及机构编码 -->
|
|
|
+ <select id="getShipperMap" parameterType="DECIMAL" resultType="java.util.Map" >
|
|
|
+ SELECT
|
|
|
+ RS.SHIPPER_SSO_ID AS "shipperSsoId",
|
|
|
+ RS.SHIPPER_ORG_CODE AS "shipperOrgCode"
|
|
|
+FROM RMS_SHIPPER RS
|
|
|
+WHERE RS.SHIPPER_ID = #{shipperId}
|
|
|
+ </select>
|
|
|
</mapper>
|