机具库存收藏修改
This commit is contained in:
parent
6d0deb9dbc
commit
de6e56f059
|
|
@ -192,7 +192,7 @@
|
||||||
|
|
||||||
|
|
||||||
</th> --%>
|
</th> --%>
|
||||||
<th style="vertical-align:middle;color:red" onclick="topage()" class="center">${ma.number}</th>
|
<th style="vertical-align:middle;color:red" onclick="topage(${ma.id} , '${ma.processName}')" class="center">${ma.number}</th>
|
||||||
<th style="vertical-align:middle;" class="center">${ma.creatorName}</th>
|
<th style="vertical-align:middle;" class="center">${ma.creatorName}</th>
|
||||||
<th style="vertical-align:middle;color:red" class="center">
|
<th style="vertical-align:middle;color:red" class="center">
|
||||||
<c:choose>
|
<c:choose>
|
||||||
|
|
@ -217,7 +217,7 @@
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
var uname = localStorage.getItem("uname");
|
var uname = localStorage.getItem("uname");
|
||||||
var pwd = localStorage.getItem("pwd");
|
var pwd = localStorage.getItem("pwd");
|
||||||
function topage() {
|
function topage(id,processName) {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type: "post",
|
type: "post",
|
||||||
url: "http://127.0.0.1:21522/gz-car/login/userLogin",
|
url: "http://127.0.0.1:21522/gz-car/login/userLogin",
|
||||||
|
|
@ -231,8 +231,13 @@
|
||||||
localStorage.setItem("token", data.token);
|
localStorage.setItem("token", data.token);
|
||||||
localStorage.setItem("name", name);
|
localStorage.setItem("name", name);
|
||||||
//window.open("http://192.168.0.14:21625/gz-gqj/index.html")
|
//window.open("http://192.168.0.14:21625/gz-gqj/index.html")
|
||||||
window.open("http://localhost:63343/gz_car_ui/index.html#/page/car_demand_plan/dispatch_car_list.html")
|
if(processName === '派车计划'){
|
||||||
|
window.open("http://localhost:63343/gz_car_ui/page/car_demand_plan/child/dispatch_car_detail.html?id="+id +"&token="+data.token)
|
||||||
|
|
||||||
|
}else if(processName === '用车计划'){
|
||||||
|
window.open("http://localhost:63343/gz_car_ui/page/car_demand_plan/child/apply_plan_detail.html?id="+id +"&token="+data.token)
|
||||||
|
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
alert("没有权限!");
|
alert("没有权限!");
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,214 +1,210 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?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" >
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||||
<mapper namespace="com.bonus.wf.dao.TaskRecordDao" >
|
<mapper namespace="com.bonus.wf.dao.TaskRecordDao" >
|
||||||
<resultMap id="taskRecord" type="com.bonus.wf.beans.TaskRecordBean">
|
<resultMap id="taskRecord" type="com.bonus.wf.beans.TaskRecordBean">
|
||||||
<id property="id" column="id" />
|
<id property="id" column="id" />
|
||||||
<result property="processId" column="processId"/>
|
<result property="processId" column="processId"/>
|
||||||
<result property="companyId" column="companyId"/>
|
<result property="companyId" column="companyId"/>
|
||||||
<result property="processName" column="processName"/>
|
<result property="processName" column="processName"/>
|
||||||
<result property="definitionId" column="definitionId"/>
|
<result property="definitionId" column="definitionId"/>
|
||||||
<result property="definitionName" column="definitionName"/>
|
<result property="definitionName" column="definitionName"/>
|
||||||
<result property="operationTime" column="operationTime"/>
|
<result property="operationTime" column="operationTime"/>
|
||||||
<result property="operationUserId" column="operationId"/>
|
<result property="operationUserId" column="operationId"/>
|
||||||
<result property="operationUserName" column="operationName"/>
|
<result property="operationUserName" column="operationName"/>
|
||||||
<result property="checkerId" column="checkerId"/>
|
<result property="checkerId" column="checkerId"/>
|
||||||
<result property="checkerName" column="checkerName"/>
|
<result property="checkerName" column="checkerName"/>
|
||||||
<result property="definitionId" column="definitionId"/>
|
<result property="definitionId" column="definitionId"/>
|
||||||
<result property="creatorName" column="creatorName"/>
|
<result property="creatorName" column="creatorName"/>
|
||||||
<result property="isExamine2" column="isExamine2"/>
|
<result property="isExamine2" column="isExamine2"/>
|
||||||
<result property="isApproval2" column="isApproval2"/>
|
<result property="isApproval2" column="isApproval2"/>
|
||||||
<result property="responer2" column="responer2"/>
|
<result property="responer2" column="responer2"/>
|
||||||
<result property="responer8" column="responer8"/>
|
<result property="responer8" column="responer8"/>
|
||||||
<result property="responer11" column="responer11"/>
|
<result property="responer11" column="responer11"/>
|
||||||
<result property="checkStatus12" column="checkStatus12"/>
|
<result property="checkStatus12" column="checkStatus12"/>
|
||||||
<result property="isExamine12" column="isExamine12"/>
|
<result property="isExamine12" column="isExamine12"/>
|
||||||
<result property="isApproval12" column="isApproval12"/>
|
<result property="isApproval12" column="isApproval12"/>
|
||||||
<result property="checker12" column="checker12"/>
|
<result property="checker12" column="checker12"/>
|
||||||
<result property="responer12" column="responer12"/>
|
<result property="responer12" column="responer12"/>
|
||||||
<result property="responer18" column="responer18"/>
|
<result property="responer18" column="responer18"/>
|
||||||
<result property="responer19" column="responer19"/>
|
<result property="responer19" column="responer19"/>
|
||||||
<result property="responer20" column="responer20"/>
|
<result property="responer20" column="responer20"/>
|
||||||
<result property="responer21" column="responer21"/>
|
<result property="responer21" column="responer21"/>
|
||||||
<result property="responer22" column="responer22"/>
|
<result property="responer22" column="responer22"/>
|
||||||
<result property="responer23" column="responer23"/>
|
<result property="responer23" column="responer23"/>
|
||||||
<result property="responer24" column="responer24"/>
|
<result property="responer24" column="responer24"/>
|
||||||
<result property="responer25" column="responer25"/>
|
<result property="responer25" column="responer25"/>
|
||||||
<result property="number" column="number"/>
|
<result property="number" column="number"/>
|
||||||
<result property="unitName" column="unitName"/>
|
<result property="unitName" column="unitName"/>
|
||||||
<result property="projectName" column="projectName"/>
|
<result property="projectName" column="projectName"/>
|
||||||
<result property="isFinish" column="isFinish"/>
|
<result property="isFinish" column="isFinish"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<select id="findAll" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
<select id="findAll" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
||||||
SELECT wtr.ID,wtr.DEFINITION_ID as definitionId,wtd.`NAME` as definishtionName,wtr.PROCESS_ID as processId,
|
SELECT wtr.ID,wtr.DEFINITION_ID as definitionId,wtd.`NAME` as definishtionName,wtr.PROCESS_ID as processId,
|
||||||
wpd.`NAME` as processName,wtr.OPERATION_USER as operationUserId,pu.`NAME` as operationUserName,
|
wpd.`NAME` as processName,wtr.OPERATION_USER as operationUserId,pu.`NAME` as operationUserName,
|
||||||
wtr.OPERATION_TIME as operationTime,wtr.IS_FINISH as isFinish,wtr.REMARK
|
wtr.OPERATION_TIME as operationTime,wtr.IS_FINISH as isFinish,wtr.REMARK
|
||||||
FROM wf_task_record wtr,wf_task_definition wtd,wf_process_record wpr,
|
FROM wf_task_record wtr,wf_task_definition wtd,wf_process_record wpr,
|
||||||
wf_process_definition wpd,pm_user pu
|
wf_process_definition wpd,pm_user pu
|
||||||
WHERE wtr.DEFINITION_ID = wtd.ID AND wtr.PROCESS_ID = wpr.ID
|
WHERE wtr.DEFINITION_ID = wtd.ID AND wtr.PROCESS_ID = wpr.ID
|
||||||
AND wpr.PROCESS_ID = wpd.ID AND wtr.OPERATION_USER = pu.ID
|
AND wpr.PROCESS_ID = wpd.ID AND wtr.OPERATION_USER = pu.ID
|
||||||
|
AND wtr.IS_ACTIVE = 1
|
||||||
|
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="findUnFinishContent" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
||||||
|
(
|
||||||
|
SELECT
|
||||||
|
wtr.id AS id,
|
||||||
|
CASE
|
||||||
|
WHEN wtr.DEFINITION_ID IN (1,2,8) THEN wtr.NUMBER
|
||||||
|
WHEN wtr.DEFINITION_ID IN (5,11) THEN wtr1.NUMBER
|
||||||
|
END AS number,
|
||||||
|
wpd.NAME AS processName,
|
||||||
|
wtd.NAME AS definitionName,
|
||||||
|
pu.NAME AS creatorName,
|
||||||
|
DATE_FORMAT(wtr.OPERATION_TIME, '%Y-%m-%d') AS operationTime,
|
||||||
|
wtr.DEFINITION_ID AS definitionId,
|
||||||
|
CASE
|
||||||
|
WHEN wtr.DEFINITION_ID = 11 THEN wtr1.IS_FINISH
|
||||||
|
ELSE wtr.IS_FINISH
|
||||||
|
END AS isFinish,
|
||||||
|
'TASK' AS source
|
||||||
|
FROM
|
||||||
|
wf_task_record wtr
|
||||||
|
LEFT JOIN wf_task_record wtr1 ON wtr1.ID = wtr.SUP_ID
|
||||||
|
LEFT JOIN pm_user pu ON pu.id = wtr.OPERATION_USER
|
||||||
|
LEFT JOIN wf_task_definition wtd ON wtd.ID = wtr.DEFINITION_ID
|
||||||
|
LEFT JOIN wf_process_definition wpd ON wpd.id = wtr.PROCESS_ID
|
||||||
|
WHERE
|
||||||
|
wtr.DEFINITION_ID IN (1, 2, 5, 8, 11)
|
||||||
|
AND (
|
||||||
|
(wtr.DEFINITION_ID = 11 AND wtr1.IS_FINISH = #{param.isFinish})
|
||||||
|
OR (wtr.DEFINITION_ID != 11 AND wtr.IS_FINISH = #{param.isFinish})
|
||||||
|
)
|
||||||
AND wtr.IS_ACTIVE = 1
|
AND wtr.IS_ACTIVE = 1
|
||||||
|
<if test="param.operationUserId != null and param.operationUserId != ''">
|
||||||
|
AND wtr.OPERATION_USER = #{param.operationUserId}
|
||||||
|
</if>
|
||||||
|
<if test="param.keyWord != null and param.keyWord != ''">
|
||||||
|
AND (
|
||||||
|
wpd.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
||||||
|
OR wtd.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
||||||
|
OR pu.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
||||||
|
)
|
||||||
|
</if>
|
||||||
|
)
|
||||||
|
|
||||||
</select>
|
UNION ALL
|
||||||
|
|
||||||
<select id="findUnFinishContent" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
(
|
||||||
(
|
SELECT
|
||||||
SELECT
|
cpa.id AS id,
|
||||||
wtr.id AS id,
|
cpa.code AS number,
|
||||||
CASE
|
'用车计划' AS processName,
|
||||||
WHEN wtr.DEFINITION_ID IN (1,2,8) THEN wtr.NUMBER
|
'用车申请' AS definitionName,
|
||||||
WHEN wtr.DEFINITION_ID IN (5,11) THEN wtr1.NUMBER
|
pu.NAME AS creatorName,
|
||||||
END AS number,
|
DATE_FORMAT(cpa.create_time, '%Y-%m-%d') AS operationTime,
|
||||||
wpd.NAME AS processName,
|
NULL AS definitionId,
|
||||||
wtd.NAME AS definitionName,
|
NULL AS isFinish,
|
||||||
pu.NAME AS creatorName,
|
'PLAN' AS source
|
||||||
DATE_FORMAT(wtr.OPERATION_TIME, '%Y-%m-%d') AS operationTime,
|
FROM
|
||||||
wtr.DEFINITION_ID AS definitionId,
|
car_plan_apply cpa
|
||||||
CASE
|
LEFT JOIN pm_user pu ON pu.id = cpa.creator
|
||||||
WHEN wtr.DEFINITION_ID = 11 THEN wtr1.IS_FINISH
|
WHERE
|
||||||
ELSE wtr.IS_FINISH
|
cpa.status = '1'
|
||||||
END AS isFinish,
|
|
||||||
'TASK' AS source
|
|
||||||
FROM
|
|
||||||
wf_task_record wtr
|
|
||||||
LEFT JOIN wf_task_record wtr1 ON wtr1.ID = wtr.SUP_ID
|
|
||||||
LEFT JOIN pm_user pu ON pu.id = wtr.OPERATION_USER
|
|
||||||
LEFT JOIN wf_task_definition wtd ON wtd.ID = wtr.DEFINITION_ID
|
|
||||||
LEFT JOIN wf_process_definition wpd ON wpd.id = wtr.PROCESS_ID
|
|
||||||
WHERE
|
|
||||||
wtr.DEFINITION_ID IN (1, 2, 5, 8, 11)
|
|
||||||
AND (
|
|
||||||
(wtr.DEFINITION_ID = 11 AND wtr1.IS_FINISH = #{param.isFinish})
|
|
||||||
OR (wtr.DEFINITION_ID != 11 AND wtr.IS_FINISH = #{param.isFinish})
|
|
||||||
)
|
|
||||||
AND wtr.IS_ACTIVE = 1
|
|
||||||
<if test="param.operationUserId != null and param.operationUserId != ''">
|
|
||||||
AND wtr.OPERATION_USER = #{param.operationUserId}
|
|
||||||
</if>
|
|
||||||
<if test="param.keyWord != null and param.keyWord != ''">
|
|
||||||
AND (
|
|
||||||
wpd.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
|
||||||
OR wtd.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
|
||||||
OR pu.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
|
||||||
)
|
|
||||||
</if>
|
|
||||||
)
|
|
||||||
|
|
||||||
UNION ALL
|
<if test="param.operationUserId == '14'">
|
||||||
|
AND cpa.status_type = '3'
|
||||||
(
|
</if>
|
||||||
SELECT
|
<if test="param.operationUserId in ('57','29','55','56','67')">
|
||||||
cpa.id AS id,
|
AND cpa.status_type = '4'
|
||||||
cpa.code AS number,
|
</if>
|
||||||
'用车计划' AS processName,
|
<if test="!(param.operationUserId == null
|
||||||
'用车申请' AS definitionName,
|
|
||||||
pu.NAME AS creatorName,
|
|
||||||
DATE_FORMAT(cpa.create_time, '%Y-%m-%d') AS operationTime,
|
|
||||||
NULL AS definitionId,
|
|
||||||
NULL AS isFinish,
|
|
||||||
'PLAN' AS source
|
|
||||||
FROM
|
|
||||||
car_plan_apply cpa
|
|
||||||
LEFT JOIN pm_user pu ON pu.id = cpa.creator
|
|
||||||
WHERE
|
|
||||||
cpa.status = '1'
|
|
||||||
AND (
|
|
||||||
<if test="param.operationUserId == null or param.operationUserId == ''">
|
|
||||||
1 = 1
|
|
||||||
</if>
|
|
||||||
<if test="param.operationUserId == '14'">
|
|
||||||
cpa.status_type = '3'
|
|
||||||
</if>
|
|
||||||
<if test="param.operationUserId in ('57','29','55','56','67')">
|
|
||||||
cpa.status_type = '4'
|
|
||||||
</if>
|
|
||||||
<if test="!(param.operationUserId == null
|
|
||||||
or param.operationUserId == ''
|
or param.operationUserId == ''
|
||||||
or param.operationUserId == '14'
|
or param.operationUserId == '14'
|
||||||
or param.operationUserId in ('57','29','55','56','67'))">
|
or param.operationUserId in ('57','29','55','56','67'))">
|
||||||
1 = 0
|
AND 1 = 0
|
||||||
</if>
|
</if>
|
||||||
)
|
<if test="param.keyWord != null and param.keyWord != ''">
|
||||||
<if test="param.keyWord != null and param.keyWord != ''">
|
AND pu.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
||||||
AND pu.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
</if>
|
||||||
</if>
|
)
|
||||||
)
|
|
||||||
|
|
||||||
UNION ALL
|
UNION ALL
|
||||||
|
|
||||||
(
|
(
|
||||||
SELECT
|
SELECT
|
||||||
cpo.id AS id,
|
cpa.id AS id,
|
||||||
cpa.code AS number,
|
cpa.code AS number,
|
||||||
'派车计划' AS processName,
|
'派车计划' AS processName,
|
||||||
CASE cpo.type
|
CASE cpo.type
|
||||||
WHEN 1 THEN '车辆派车'
|
WHEN 1 THEN '车辆派车'
|
||||||
WHEN 2 THEN '吊车派车'
|
WHEN 2 THEN '吊车派车'
|
||||||
ELSE '派车'
|
ELSE '派车'
|
||||||
END AS definitionName,
|
END AS definitionName,
|
||||||
pu.NAME AS creatorName,
|
pu.NAME AS creatorName,
|
||||||
DATE_FORMAT(cpo.create_time, '%Y-%m-%d') AS operationTime,
|
DATE_FORMAT(cpo.create_time, '%Y-%m-%d') AS operationTime,
|
||||||
NULL AS definitionId,
|
NULL AS definitionId,
|
||||||
cpo.status AS isFinish,
|
cpo.status AS isFinish,
|
||||||
'OUT' AS source
|
'OUT' AS source
|
||||||
FROM
|
FROM
|
||||||
car_plan_out cpo
|
car_plan_out cpo
|
||||||
LEFT JOIN pm_user pu ON pu.id = cpo.creator
|
LEFT JOIN pm_user pu ON pu.id = cpo.creator
|
||||||
LEFT JOIN car_plan_apply cpa ON cpo.apply_id = cpa.id
|
LEFT JOIN car_plan_apply cpa ON cpo.apply_id = cpa.id
|
||||||
WHERE
|
WHERE
|
||||||
1 = 1
|
1 = 1
|
||||||
<if test="param.operationUserId in ('57','29','55','56','67')">
|
<if test="param.operationUserId in ('57','29','55','56','67')">
|
||||||
AND cpo.status = '0'
|
AND cpo.status = '0'
|
||||||
</if>
|
</if>
|
||||||
<if test="param.operationUserId in ('49','50')">
|
<if test="param.operationUserId in ('49','50')">
|
||||||
AND cpo.status = '1'
|
AND cpo.status = '1'
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="!(param.operationUserId == null
|
<if test="!(param.operationUserId == null
|
||||||
or param.operationUserId == ''
|
or param.operationUserId == ''
|
||||||
or param.operationUserId in ('49','50')
|
or param.operationUserId in ('49','50')
|
||||||
or param.operationUserId in ('57','29','55','56','67'))">
|
or param.operationUserId in ('57','29','55','56','67'))">
|
||||||
1 = 0
|
AND 1 = 0
|
||||||
</if>
|
</if>
|
||||||
<if test="param.keyWord != null and param.keyWord != ''">
|
<if test="param.keyWord != null and param.keyWord != ''">
|
||||||
AND pu.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
AND pu.NAME LIKE CONCAT('%', #{param.keyWord}, '%')
|
||||||
</if>
|
</if>
|
||||||
)
|
)
|
||||||
|
|
||||||
ORDER BY id DESC
|
ORDER BY id DESC
|
||||||
|
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
<select id="find" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
<select id="find" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
||||||
SELECT wtr.ID,wtr.DEFINITION_ID as definitionId,wtd.`NAME` as definishtionName,wtr.PROCESS_ID as processId,
|
SELECT wtr.ID,wtr.DEFINITION_ID as definitionId,wtd.`NAME` as definishtionName,wtr.PROCESS_ID as processId,
|
||||||
wpd.`NAME` as processName,wtr.OPERATION_USER as operationUserId,pu.`NAME` as operationUserName,
|
wpd.`NAME` as processName,wtr.OPERATION_USER as operationUserId,pu.`NAME` as operationUserName,
|
||||||
wtr.OPERATION_TIME as operationTime,wtr.IS_FINISH as isFinish,wtr.REMARK
|
wtr.OPERATION_TIME as operationTime,wtr.IS_FINISH as isFinish,wtr.REMARK
|
||||||
FROM wf_task_record wtr,wf_task_definition wtd,wf_process_record wpr,
|
FROM wf_task_record wtr,wf_task_definition wtd,wf_process_record wpr,
|
||||||
wf_process_definition wpd,pm_user pu
|
wf_process_definition wpd,pm_user pu
|
||||||
WHERE wtr.DEFINITION_ID = wtd.ID AND wtr.PROCESS_ID = wpr.ID
|
WHERE wtr.DEFINITION_ID = wtd.ID AND wtr.PROCESS_ID = wpr.ID
|
||||||
AND wpr.PROCESS_ID = wpd.ID AND wtr.OPERATION_USER = pu.ID
|
AND wpr.PROCESS_ID = wpd.ID AND wtr.OPERATION_USER = pu.ID
|
||||||
AND wtr.IS_ACTIVE = 1
|
AND wtr.IS_ACTIVE = 1
|
||||||
where wtr.ID = #{id}
|
where wtr.ID = #{id}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="findTaskInfo" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
<select id="findTaskInfo" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
||||||
SELECT wtr.ID AS taskId
|
SELECT wtr.ID AS taskId
|
||||||
FROM wf_task_record wtr
|
FROM wf_task_record wtr
|
||||||
LEFT JOIN wf_task_record wtr1 ON wtr1.ID = wtr.SUP_ID
|
LEFT JOIN wf_task_record wtr1 ON wtr1.ID = wtr.SUP_ID
|
||||||
LEFT JOIN wf_new_check wnc ON wnc.TASK_ID = wtr.ID
|
LEFT JOIN wf_new_check wnc ON wnc.TASK_ID = wtr.ID
|
||||||
WHERE wtr.SUP_ID = #{taskId} AND wtr.DEFINITION_ID = #{definitionId}
|
WHERE wtr.SUP_ID = #{taskId} AND wtr.DEFINITION_ID = #{definitionId}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="findRepairTask" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
<select id="findRepairTask" parameterType="com.bonus.wf.beans.TaskRecordBean" resultMap="taskRecord">
|
||||||
SELECT wtr.ID as taskId
|
SELECT wtr.ID as taskId
|
||||||
FROM wf_task_record wtr
|
FROM wf_task_record wtr
|
||||||
WHERE wtr.SUP_ID = #{taskId} AND wtr.DEFINITION_ID = #{definitionId} and wtr.IS_FINISH = 0
|
WHERE wtr.SUP_ID = #{taskId} AND wtr.DEFINITION_ID = #{definitionId} and wtr.IS_FINISH = 0
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<insert id="insert" useGeneratedKeys="true" keyProperty="id">
|
<insert id="insert" useGeneratedKeys="true" keyProperty="id">
|
||||||
insert into wf_task_record
|
insert into wf_task_record
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
<if test="definitionId != null">
|
<if test="definitionId != null">
|
||||||
DEFINITION_ID,
|
DEFINITION_ID,
|
||||||
|
|
@ -295,61 +291,61 @@ ORDER BY id DESC
|
||||||
</if>
|
</if>
|
||||||
1,#{planOutId}
|
1,#{planOutId}
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<select id="findNumber" parameterType="com.bonus.wf.beans.TaskRecordBean" resultType="java.lang.String">
|
<select id="findNumber" parameterType="com.bonus.wf.beans.TaskRecordBean" resultType="java.lang.String">
|
||||||
SELECT COUNT(*) FROM wf_task_record wtr
|
SELECT COUNT(*) FROM wf_task_record wtr
|
||||||
WHERE wtr.OPERATION_TIME LIKE CONCAT("%",#{operationTime},"%")
|
WHERE wtr.OPERATION_TIME LIKE CONCAT("%",#{operationTime},"%")
|
||||||
AND wtr.DEFINITION_ID = #{definitionId}
|
AND wtr.DEFINITION_ID = #{definitionId}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<delete id="delete" parameterType="com.bonus.wf.beans.TaskRecordBean">
|
<delete id="delete" parameterType="com.bonus.wf.beans.TaskRecordBean">
|
||||||
delete from wf_task_record where id = #{id}
|
delete from wf_task_record where id = #{id}
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
<update id="update" parameterType="com.bonus.wf.beans.TaskRecordBean">
|
<update id="update" parameterType="com.bonus.wf.beans.TaskRecordBean">
|
||||||
update wf_task_record
|
update wf_task_record
|
||||||
<set>
|
<set>
|
||||||
<if test="definitionId != null">
|
<if test="definitionId != null">
|
||||||
DEFINITION_ID = #{definitionId},
|
DEFINITION_ID = #{definitionId},
|
||||||
</if>
|
</if>
|
||||||
<if test="processId != null">
|
<if test="processId != null">
|
||||||
PROCESS_ID = #{processId},
|
PROCESS_ID = #{processId},
|
||||||
</if>
|
</if>
|
||||||
<if test="operationUserId !=null">
|
<if test="operationUserId !=null">
|
||||||
OPERATION_USER = #{operationUserId},
|
OPERATION_USER = #{operationUserId},
|
||||||
</if>
|
</if>
|
||||||
<if test="operationTime !=null">
|
<if test="operationTime !=null">
|
||||||
OPERATION_TIME = #{operationTime},
|
OPERATION_TIME = #{operationTime},
|
||||||
</if>
|
</if>
|
||||||
<if test="number !=null">
|
<if test="number !=null">
|
||||||
NUMBER = #{number},
|
NUMBER = #{number},
|
||||||
</if>
|
</if>
|
||||||
<if test="isFinish !=null">
|
<if test="isFinish !=null">
|
||||||
IS_FINISH = #{isFinish},
|
IS_FINISH = #{isFinish},
|
||||||
</if>
|
</if>
|
||||||
<if test="isSplit !=null">
|
<if test="isSplit !=null">
|
||||||
IS_SPLIT = #{isSplit},
|
IS_SPLIT = #{isSplit},
|
||||||
</if>
|
</if>
|
||||||
<if test="companyId !=null">
|
<if test="companyId !=null">
|
||||||
ORG_ID = #{companyId},
|
ORG_ID = #{companyId},
|
||||||
</if>
|
</if>
|
||||||
<if test="remark != null">
|
<if test="remark != null">
|
||||||
REMARK = #{remark},
|
REMARK = #{remark},
|
||||||
</if>
|
</if>
|
||||||
</set>
|
</set>
|
||||||
where id = #{id}
|
where id = #{id}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
<insert id="addTaskAgreement" parameterType="com.bonus.wf.beans.TaskRecordBean">
|
<insert id="addTaskAgreement" parameterType="com.bonus.wf.beans.TaskRecordBean">
|
||||||
insert into wf_agreement_task(TASK_ID,AGREEMENT_ID)
|
insert into wf_agreement_task(TASK_ID,AGREEMENT_ID)
|
||||||
values(#{taskId},#{agreementId})
|
values(#{taskId},#{agreementId})
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<delete id="deleteBatch" parameterType="java.util.List">
|
<delete id="deleteBatch" parameterType="java.util.List">
|
||||||
DELETE FROM wf_process_record WHERE id in(
|
DELETE FROM wf_process_record WHERE id in(
|
||||||
<foreach item="o" collection="list" open="" separator=","
|
<foreach item="o" collection="list" open="" separator=","
|
||||||
close="">
|
close="">
|
||||||
#{o.id}
|
#{o.id}
|
||||||
</foreach>
|
</foreach>
|
||||||
)
|
)
|
||||||
|
|
@ -357,9 +353,9 @@ ORDER BY id DESC
|
||||||
|
|
||||||
|
|
||||||
<select id="checkTask" parameterType="java.lang.String" resultMap="taskRecord">
|
<select id="checkTask" parameterType="java.lang.String" resultMap="taskRecord">
|
||||||
SELECT wtr.ID AS taskId,number
|
SELECT wtr.ID AS taskId,number
|
||||||
FROM wf_task_record wtr
|
FROM wf_task_record wtr
|
||||||
WHERE wtr.SUP_ID = #{taskId} AND wtr.DEFINITION_ID = 20 AND wtr.IS_SPLIT = 0
|
WHERE wtr.SUP_ID = #{taskId} AND wtr.DEFINITION_ID = 20 AND wtr.IS_SPLIT = 0
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
Loading…
Reference in New Issue