Commit f442114b by 翁国栋

8小时运营后台--

插入审批人--重复审批
parent d95940e8
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -46,19 +46,21 @@ public class SpmkApproveDetailDto { ...@@ -46,19 +46,21 @@ public class SpmkApproveDetailDto {
@ApiModelProperty(value = "审批执行记录 ", example = "审批执行记录") @ApiModelProperty(value = "审批执行记录 ", example = "审批执行记录")
private List<SpmkApproveExecuteRecord> approveExecuteRecord; private List<SpmkApproveExecuteRecord> approveExecuteRecord;
private Integer empNum; private Integer empNum;
private Integer sts; private Integer sts;
private Integer executeEmpNum;//当前审批中 当前执行人的id private Integer executeEmpNum;//当前审批中 当前执行人的id
private Integer executeSts; private Integer executeSts;
private Integer exeid; private Integer exeid;
private Integer exereid; private Integer exereid;
private Date launchTime; //审批发起时间 private Date launchTime; //审批发起时间
private Integer index;//插入审批人的索引
} }
...@@ -997,8 +997,12 @@ public class RouterUtils { ...@@ -997,8 +997,12 @@ public class RouterUtils {
.operatorHeaderUrl(listUser.get(i_user).getHeadUrl()) .operatorHeaderUrl(listUser.get(i_user).getHeadUrl())
.sts(sts) .sts(sts)
.signatureImg(signatureImg) .signatureImg(signatureImg)
.build() .build().updateById();
.updateById(); // if(spmkExecutor.getId()==0){
// spmkExecutor.insert();
// }else{
// spmkExecutor.updateById();
// }
listUser.get(i_user).setExecute(EXECUTED); listUser.get(i_user).setExecute(EXECUTED);
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<result column="digest" property="digest" /> <result column="digest" property="digest" />
<result column="is_delete" property="isDelete" /> <result column="is_delete" property="isDelete" />
</resultMap> </resultMap>
<resultMap id="BaseResultMap_As" type="cn.timer.api.bean.spmk.SpmkApproveSummary" > <resultMap id="BaseResultMap_As" type="cn.timer.api.bean.spmk.SpmkApproveSummary" >
<id column="id" property="id" /> <id column="id" property="id" />
<result column="org_code" property="orgCode" /> <result column="org_code" property="orgCode" />
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
digest, digest,
is_delete is_delete
</sql> </sql>
<sql id="Base_Column_List_a"> <sql id="Base_Column_List_a">
a.id, a.id,
a.org_code, a.org_code,
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
a.is_delete, a.is_delete,
a.is_urgent a.is_urgent
</sql> </sql>
<sql id="Base_Column_List_Alias"> <sql id="Base_Column_List_Alias">
id SpmkApproveSummary_id, id SpmkApproveSummary_id,
org_code SpmkApproveSummary_org_code, org_code SpmkApproveSummary_org_code,
...@@ -101,9 +101,9 @@ ...@@ -101,9 +101,9 @@
end_time SpmkApproveSummary_end_time, end_time SpmkApproveSummary_end_time,
digest SpmkApproveSummary_digest digest SpmkApproveSummary_digest
</sql> </sql>
<select id="selectPageByQuery" resultMap="BaseResultMap_As" > <select id="selectPageByQuery" resultMap="BaseResultMap_As" >
SELECT SELECT
<include refid="Base_Column_List_a" />, <include refid="Base_Column_List_a" />,
(SELECT name FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num and a.org_code=org_code limit 1) limit 1) as gw_name, (SELECT name FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num and a.org_code=org_code limit 1) limit 1) as gw_name,
(SELECT id FROM zzgl_bmgw_m WHERE id = (SELECT up_id FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num and a.org_code=org_code limit 1) limit 1) limit 1) as bm_id, (SELECT id FROM zzgl_bmgw_m WHERE id = (SELECT up_id FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num and a.org_code=org_code limit 1) limit 1) limit 1) as bm_id,
...@@ -114,7 +114,7 @@ ...@@ -114,7 +114,7 @@
and ( and (
a.title like CONCAT('%',#{param.query},'%') or a.title like CONCAT('%',#{param.query},'%') or
a.initiator like CONCAT('%',#{param.query},'%') or a.initiator like CONCAT('%',#{param.query},'%') or
a.id like CONCAT('%',#{param.query},'%') a.id like CONCAT('%',#{param.query},'%')
) )
</if> </if>
<if test="param.sts != null"> <if test="param.sts != null">
...@@ -127,52 +127,52 @@ ...@@ -127,52 +127,52 @@
and a.create_time <![CDATA[ <= ]]> #{param.endTime} and a.create_time <![CDATA[ <= ]]> #{param.endTime}
</if> </if>
<if test="param.empNums != null and param.empNums.size() > 0"> <if test="param.empNums != null and param.empNums.size() > 0">
and a.emp_num IN and a.emp_num IN
( (
<foreach item="it" index="index" collection="param.empNums" separator="," close="" > <foreach item="it" index="index" collection="param.empNums" separator="," close="" >
#{it} #{it}
</foreach> </foreach>
) )
</if> </if>
ORDER BY a.id DESC ORDER BY a.id DESC
</select> </select>
<select id="selectPageByQueryForEmpNum" resultMap="BaseResultMap_As" > <select id="selectPageByQueryForEmpNum" resultMap="BaseResultMap_As" >
SELECT SELECT
<include refid="Base_Column_List_a" />, <include refid="Base_Column_List_a" />,
(SELECT name FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num limit 1) limit 1) as gw_name, (SELECT name FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num limit 1) limit 1) as gw_name,
(SELECT id FROM zzgl_bmgw_m WHERE id = (SELECT up_id FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num limit 1) limit 1) limit 1) as bm_id, (SELECT id FROM zzgl_bmgw_m WHERE id = (SELECT up_id FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num limit 1) limit 1) limit 1) as bm_id,
(SELECT name FROM zzgl_bmgw_m WHERE id = (SELECT up_id FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num limit 1) limit 1) limit 1) as bm_name (SELECT name FROM zzgl_bmgw_m WHERE id = (SELECT up_id FROM zzgl_bmgw_m WHERE id = (SELECT bmgw_id FROM yggl_main_emp WHERE a.emp_num = emp_num limit 1) limit 1) limit 1) as bm_name
FROM spmk_approve_summary a FROM spmk_approve_summary a
WHERE a.org_code = #{param.orgCode} and a.is_delete=0 WHERE a.org_code = #{param.orgCode} and a.is_delete=0
<if test="param.type != null and param.type >= 1"> <if test="param.type != null and param.type >= 1">
and a.id in and a.id in
(SELECT approve_summary_id FROM spmk_approve_execute_record WHERE id IN (SELECT approve_summary_id FROM spmk_approve_execute_record WHERE id IN
(SELECT (SELECT
approve_execute_record_id approve_execute_record_id
FROM FROM
spmk_executor spmk_executor
WHERE WHERE
emp_num = #{param.empNum} emp_num = #{param.empNum}
<if test="param.sts == 0"> <if test="param.sts == 0">
and sts not in (2,3,4) and sts not in (2,3,4)
</if> </if>
) )
<if test="param.type == 3"> <if test="param.type == 3">
and type in (0,1,2) and type in (0,1,2)
</if> </if>
<if test="param.type != 3"> <if test="param.type != 3">
and type = #{param.type} and type = #{param.type}
</if> </if>
) )
</if> </if>
<if test="param.type != null and param.type == 0"> <if test="param.type != null and param.type == 0">
and a.emp_num = #{param.empNum} and a.emp_num = #{param.empNum}
</if> </if>
<if test="param.sts != null"> <if test="param.sts != null">
<if test="param.sts == 5"> <if test="param.sts == 5">
and a.sts in (0,1,2,3) and a.sts in (0,1,2,3)
...@@ -184,13 +184,13 @@ ...@@ -184,13 +184,13 @@
and a.sts = #{param.sts} and a.sts = #{param.sts}
</if> </if>
</if> </if>
<if test="param.query != null and param.query != ''"> <if test="param.query != null and param.query != ''">
and ( and (
a.title like CONCAT('%',#{param.query},'%') or a.title like CONCAT('%',#{param.query},'%') or
a.initiator like CONCAT('%',#{param.query},'%') or a.initiator like CONCAT('%',#{param.query},'%') or
a.id like CONCAT('%',#{param.query},'%') a.id like CONCAT('%',#{param.query},'%')
) )
</if> </if>
<if test="param.startTime != null and param.startTime != ''"> <if test="param.startTime != null and param.startTime != ''">
...@@ -198,12 +198,12 @@ ...@@ -198,12 +198,12 @@
</if> </if>
<if test="param.endTime != null and param.endTime != ''"> <if test="param.endTime != null and param.endTime != ''">
and a.create_time <![CDATA[ <= ]]> #{param.endTime} and a.create_time <![CDATA[ <= ]]> #{param.endTime}
</if> </if>
ORDER BY a.id DESC ORDER BY a.id DESC
</select> </select>
<!--
<!--
<insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.spmk.SpmkApproveSummary"> <insert id="insert" useGeneratedKeys="true" keyColumn="id" parameterType="cn.timer.api.bean.spmk.SpmkApproveSummary">
INSERT INTO spmk_approve_summary INSERT INTO spmk_approve_summary
...@@ -343,4 +343,4 @@ ...@@ -343,4 +343,4 @@
--> -->
</mapper> </mapper>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment