case t1.ITEM_STATE WHEN 0 THEN 'pending' WHEN 5 THEN 'closed' WHEN '10' THEN 'closed_case' ELSE '' END AS projectStatusCode,
t1.CATEGORY_FULL_NAME as allCategoryName,
t2.IMG_URL as projectImgUrl,
t3.CREATED_TIME as closeCaseTime
t3.CREATED_TIME as closeCaseTime,
case
when t1.ITEM_STATE = 10 then 3
when (select ID from js_esua_epdc_events.epdc_item_handle_process where STATE != 10 and DEL_FLAG ='0' and ITEM_ID = t1.ID group by t1.ID) is null then 1
else 2 end as projectLevel
from (select * from(select * from esua_epdc_events.epdc_item where DEL_FLAG = '0'