|
@@ -10,7 +10,8 @@
|
|
|
insert into work_task_item(
|
|
insert into work_task_item(
|
|
|
deduction_person_id,finish_time,deduction_person_name,deduction_money,content_id,store_id,work_id,deduction_reason,item_id,state,community_id,task_id
|
|
deduction_person_id,finish_time,deduction_person_name,deduction_money,content_id,store_id,work_id,deduction_reason,item_id,state,community_id,task_id
|
|
|
) values (
|
|
) values (
|
|
|
- #{deductionPersonId},#{finishTime},#{deductionPersonName},#{deductionMoney},#{contentId},#{storeId},#{workId},#{deductionReason},#{itemId},#{state},#{communityId},#{taskId}
|
|
|
|
|
|
|
+ #{deductionPersonId},#{finishTime},#{deductionPersonName},#{deductionMoney},#{contentId},#{storeId},#{workId},#{deductionReason},#{itemId},#{state},
|
|
|
|
|
+ #{communityId},#{taskId}
|
|
|
)
|
|
)
|
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
|
@@ -20,9 +21,10 @@
|
|
|
select t.deduction_person_id deductionPersonId,t.finish_time finishTime,t.deduction_person_name
|
|
select t.deduction_person_id deductionPersonId,t.finish_time finishTime,t.deduction_person_name
|
|
|
deductionPersonName,t.deduction_money deductionMoney,t.content_id contentId,t.status_cd statusCd,t.store_id
|
|
deductionPersonName,t.deduction_money deductionMoney,t.content_id contentId,t.status_cd statusCd,t.store_id
|
|
|
storeId,t.work_id workId,t.deduction_reason deductionReason,t.item_id itemId,t.state,t.community_id
|
|
storeId,t.work_id workId,t.deduction_reason deductionReason,t.item_id itemId,t.state,t.community_id
|
|
|
- communityId,t.task_id taskId,wpc.content
|
|
|
|
|
|
|
+ communityId,t.task_id taskId,wpc.content,GROUP_CONCAT(we.staff_name) staffName,GROUP_CONCAT(we.remark) remark
|
|
|
from work_task_item t
|
|
from work_task_item t
|
|
|
left join work_pool_content wpc on t.content_id = wpc.content_id and wpc.status_cd = '0'
|
|
left join work_pool_content wpc on t.content_id = wpc.content_id and wpc.status_cd = '0'
|
|
|
|
|
+ left join work_event we on t.item_id = we.item_id and we.status_cd = '0'
|
|
|
where 1 =1
|
|
where 1 =1
|
|
|
<if test="deductionPersonId !=null and deductionPersonId != ''">
|
|
<if test="deductionPersonId !=null and deductionPersonId != ''">
|
|
|
and t.deduction_person_id= #{deductionPersonId}
|
|
and t.deduction_person_id= #{deductionPersonId}
|
|
@@ -63,7 +65,10 @@
|
|
|
<if test="taskId !=null and taskId != ''">
|
|
<if test="taskId !=null and taskId != ''">
|
|
|
and t.task_id= #{taskId}
|
|
and t.task_id= #{taskId}
|
|
|
</if>
|
|
</if>
|
|
|
- order by t.create_time desc
|
|
|
|
|
|
|
+ group by t.deduction_person_id ,t.finish_time ,t.deduction_person_name,
|
|
|
|
|
+ t.deduction_money ,t.content_id ,t.store_id ,t.work_id ,t.deduction_reason ,t.item_id ,
|
|
|
|
|
+ t.state,t.community_id,t.task_id ,wpc.content,wpc.seq_num
|
|
|
|
|
+ order by wpc.seq_num
|
|
|
<if test="page != -1 and page != null ">
|
|
<if test="page != -1 and page != null ">
|
|
|
limit #{page}, #{row}
|
|
limit #{page}, #{row}
|
|
|
</if>
|
|
</if>
|