Browse Source

项目详情提交逻辑更改

feature/dangjian
wanggongfeng 3 years ago
parent
commit
ce539c0d76
  1. 23
      esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml

23
esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml

@ -507,8 +507,27 @@
FROM epdc_item item
LEFT JOIN epdc_events eve ON item.EVENT_ID = eve.ID AND eve.DEL_FLAG = '0'
left join epdc_item_fusing_delay_record d on d.ITEM_ID = item.ID and d.DEL_FLAG = '0'
WHERE
item.DEL_FLAG = '0'
left join (
select
ID,ITEM_ID,CREATED_TIME,state
from epdc_item_handle_process
where DEL_FLAG = '0'
and ID in (
select t.ID from (
select a.ID ,a.ITEM_ID
from (
select ITEM_ID,max(CREATED_TIME) as CREATED_TIME
from epdc_item_handle_process
where DEL_FLAG = '0'
group by ITEM_ID
) b left join epdc_item_handle_process a
on a.ITEM_ID = b.ITEM_ID and a.CREATED_TIME = b.CREATED_TIME
) t
)
) process on process.ITEM_ID = item.ID
WHERE item.DEL_FLAG = '0'
and (item.PEOPLE_FLAG is null or (item.PEOPLE_FLAG = '0' and process.state not in (11,15)))
<if test="itemState != null and itemState != ''">
AND item.ITEM_STATE = #{itemState}

Loading…
Cancel
Save