审核模块相关接口修改
This commit is contained in:
@@ -45,7 +45,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectAuditSignatureVo">
|
||||
select id, bill_no, bill_type, signer_id, signer_role, sign_url, sign_time, pcode, tray_code, approver_id, approver_sign_url, audit_result, image_type, is_current, remark, create_by, create_time, update_by, update_time, is_delete from audit_signature
|
||||
select id, bill_no,rk_id, bill_type, signer_id, signer_role, sign_url, sign_time, pcode, tray_code, approver_id, approver_sign_url, audit_result, image_type, is_current, remark, create_by, create_time, update_by, update_time, is_delete from audit_signature
|
||||
</sql>
|
||||
|
||||
<select id="selectAuditSignatureList" parameterType="AuditSignature" resultMap="AuditSignatureResult">
|
||||
@@ -73,16 +73,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<select id="selectPendingByUser" resultMap="AuditSignatureResult">
|
||||
SELECT
|
||||
id, bill_no, bill_type, signer_id, signer_role, sign_url, sign_time,
|
||||
pcode, tray_code, approver_id, approver_sign_url, audit_result,
|
||||
image_type, is_current, remark, create_by, create_time, update_by,
|
||||
update_time, is_delete
|
||||
<select id="countPendingByUser" resultType="int">
|
||||
SELECT COUNT(1)
|
||||
FROM audit_signature
|
||||
WHERE is_delete = '0'
|
||||
AND approver_id = #{userId}
|
||||
AND audit_result IS NULL
|
||||
AND approver_id = #{approverId}
|
||||
AND audit_result = '2'
|
||||
AND signer_role = '0'
|
||||
</select>
|
||||
|
||||
<select id="existsCurrentSigner" resultType="boolean">
|
||||
@@ -165,52 +162,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<insert id="insertAuditSignature" parameterType="AuditSignature" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into audit_signature
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="billNo != null and billNo != ''">bill_no,</if>
|
||||
<if test="billType != null and billType != ''">bill_type,</if>
|
||||
<if test="signerId != null">signer_id,</if>
|
||||
<if test="signerRole != null">signer_role,</if>
|
||||
<if test="signUrl != null">sign_url,</if>
|
||||
<if test="signTime != null">sign_time,</if>
|
||||
<if test="pcode != null">pcode,</if>
|
||||
<if test="trayCode != null">tray_code,</if>
|
||||
<if test="approverId != null">approver_id,</if>
|
||||
<if test="approverSignUrl != null">approver_sign_url,</if>
|
||||
<if test="auditResult != null">audit_result,</if>
|
||||
<if test="imageType != null">image_type,</if>
|
||||
<if test="isCurrent != null">is_current,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="updateBy != null">update_by,</if>
|
||||
<if test="updateTime != null">update_time,</if>
|
||||
<if test="isDelete != null">is_delete,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="billNo != null and billNo != ''">#{billNo},</if>
|
||||
<if test="billType != null and billType != ''">#{billType},</if>
|
||||
<if test="signerId != null">#{signerId},</if>
|
||||
<if test="signerRole != null">#{signerRole},</if>
|
||||
<if test="signUrl != null">#{signUrl},</if>
|
||||
<if test="signTime != null">#{signTime},</if>
|
||||
<if test="pcode != null">#{pcode},</if>
|
||||
<if test="trayCode != null">#{trayCode},</if>
|
||||
<if test="approverId != null">#{approverId},</if>
|
||||
<if test="approverSignUrl != null">#{approverSignUrl},</if>
|
||||
<if test="auditResult != null">#{auditResult},</if>
|
||||
<if test="imageType != null">#{imageType},</if>
|
||||
<if test="isCurrent != null">#{isCurrent},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="updateBy != null">#{updateBy},</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
<if test="isDelete != null">#{isDelete},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO audit_signature (
|
||||
bill_no,
|
||||
@@ -221,6 +172,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
sign_time,
|
||||
image_type,
|
||||
approver_id,
|
||||
audit_result,
|
||||
is_current,
|
||||
is_delete,
|
||||
create_by,
|
||||
@@ -238,6 +190,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
#{item.signTime},
|
||||
#{item.imageType},
|
||||
#{item.approverId},
|
||||
#{item.auditResult},
|
||||
#{item.isCurrent},
|
||||
#{item.isDelete},
|
||||
#{item.createBy},
|
||||
@@ -248,29 +201,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</insert>
|
||||
|
||||
<update id="updateAuditSignature" parameterType="AuditSignature">
|
||||
update audit_signature
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="billNo != null and billNo != ''">bill_no = #{billNo},</if>
|
||||
<if test="billType != null and billType != ''">bill_type = #{billType},</if>
|
||||
<if test="signerId != null">signer_id = #{signerId},</if>
|
||||
<if test="signerRole != null">signer_role = #{signerRole},</if>
|
||||
<if test="signUrl != null">sign_url = #{signUrl},</if>
|
||||
<if test="signTime != null">sign_time = #{signTime},</if>
|
||||
<if test="pcode != null">pcode = #{pcode},</if>
|
||||
<if test="trayCode != null">tray_code = #{trayCode},</if>
|
||||
<if test="approverId != null">approver_id = #{approverId},</if>
|
||||
<if test="approverSignUrl != null">approver_sign_url = #{approverSignUrl},</if>
|
||||
UPDATE audit_signature
|
||||
<set>
|
||||
<if test="auditResult != null">audit_result = #{auditResult},</if>
|
||||
<if test="imageType != null">image_type = #{imageType},</if>
|
||||
<if test="isCurrent != null">is_current = #{isCurrent},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="createBy != null">create_by = #{createBy},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
<if test="approverId != null">approver_id = #{approverId},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
<if test="isDelete != null">is_delete = #{isDelete},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
</set>
|
||||
WHERE bill_no = #{billNo}
|
||||
AND is_current = '1'
|
||||
AND is_delete = '0'
|
||||
</update>
|
||||
|
||||
<update id="updateIsCurrentToZero">
|
||||
|
||||
Reference in New Issue
Block a user