parent
97e792b467
commit
7c856cd8b6
|
@ -239,6 +239,7 @@ public class CommonServiceImpl implements CommonService {
|
|||
}
|
||||
for (PageData entity : dataList) {
|
||||
entity.put("COMMON_ID",pd.getString("COMMON_ID"));
|
||||
entity.put("COMMON_ITEM_STATUS",1);
|
||||
Warden.initDate(entity);
|
||||
commonItemService.save(entity);
|
||||
}
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
f.CHECK_UNQUALIFIED,
|
||||
f.OPERATION_TYPE,
|
||||
f.COMMON_ITEM_SORT,
|
||||
f.COMMON_ITEM_STATUS,
|
||||
f.ISDELETE,
|
||||
f.CREATOR_ID,
|
||||
f.CREATOR_NAME,
|
||||
|
@ -49,6 +50,7 @@
|
|||
CHECK_UNQUALIFIED,
|
||||
OPERATION_TYPE,
|
||||
COMMON_ITEM_SORT,
|
||||
COMMON_ITEM_STATUS,
|
||||
ISDELETE,
|
||||
CREATOR_ID,
|
||||
CREATOR_NAME,
|
||||
|
@ -74,6 +76,7 @@
|
|||
#{CHECK_UNQUALIFIED},
|
||||
#{OPERATION_TYPE},
|
||||
#{COMMON_ITEM_SORT},
|
||||
#{COMMON_ITEM_STATUS},
|
||||
#{ISDELETE},
|
||||
#{CREATOR_ID},
|
||||
#{CREATOR_NAME},
|
||||
|
@ -146,6 +149,9 @@
|
|||
<if test="COMMON_ITEM_SORT != null">
|
||||
COMMON_ITEM_SORT = #{COMMON_ITEM_SORT},
|
||||
</if>
|
||||
<if test="COMMON_ITEM_STATUS != null">
|
||||
COMMON_ITEM_STATUS = #{COMMON_ITEM_STATUS},
|
||||
</if>
|
||||
<if test="ISDELETE != null and ISDELETE != ''">
|
||||
ISDELETE = #{ISDELETE},
|
||||
</if>
|
||||
|
@ -197,6 +203,7 @@
|
|||
select
|
||||
dca.DICTIONARY_NAME CHECK_CATEGORY_NAME,
|
||||
di.DICTIONARY_NAME CHECK_ITEM_NAME,
|
||||
(select count(*) from BUS_HIDDENDANGERCHECKSTANDARD_CUSTOM_ITEM where COMMON_ITEM_ID = f.COMMON_ITEM_ID) COUNT_CUSTOM,
|
||||
<include refid="Field"></include>
|
||||
from
|
||||
<include refid="tableName"></include> f
|
||||
|
@ -215,6 +222,9 @@
|
|||
<if test="pd.CHECK_CONTENT != null and pd.CHECK_CONTENT != ''">
|
||||
and f.CHECK_CONTENT like CONCAT(CONCAT('%', #{pd.CHECK_CONTENT}),'%')
|
||||
</if>
|
||||
<if test="pd.COMMON_ITEM_STATUS != null and pd.COMMON_ITEM_STATUS != ''">
|
||||
and f.COMMON_ITEM_STATUS = #{pd.COMMON_ITEM_STATUS}
|
||||
</if>
|
||||
order by dca.DICTIONARY_SORT asc, di.DICTIONARY_SORT asc, f.COMMON_ITEM_SORT asc
|
||||
</select>
|
||||
|
||||
|
@ -232,6 +242,9 @@
|
|||
<if test="COMMON_ID != null and COMMON_ID != ''">
|
||||
and f.COMMON_ID = #{COMMON_ID}
|
||||
</if>
|
||||
<if test="COMMON_ITEM_STATUS != null and COMMON_ITEM_STATUS != ''">
|
||||
and f.COMMON_ITEM_STATUS = #{COMMON_ITEM_STATUS}
|
||||
</if>
|
||||
order by dca.DICTIONARY_SORT asc, di.DICTIONARY_SORT asc, f.COMMON_ITEM_SORT asc
|
||||
</select>
|
||||
|
||||
|
|
|
@ -164,6 +164,7 @@
|
|||
<!-- 列表 -->
|
||||
<select id="datalistPage" parameterType="page" resultType="pd">
|
||||
select
|
||||
(select count(*) from BUS_HIDDENDANGERCHECKSTANDARD_CUSTOM_ITEM where COMMON_ID = f.COMMON_ID) COUNT_CUSTOM,
|
||||
<include refid="Field"></include>
|
||||
from
|
||||
<include refid="tableName"></include> f
|
||||
|
|
|
@ -198,10 +198,21 @@
|
|||
<!-- 列表(全部) -->
|
||||
<select id="listAll" parameterType="pd" resultType="pd">
|
||||
select
|
||||
CASE f.DICTIONARY_LEVEL
|
||||
WHEN 1 THEN
|
||||
COUNT(cca.COMMON_ITEM_ID)+COUNT(cua.CUSTOM_ITEM_ID)
|
||||
WHEN 2 THEN
|
||||
COUNT(cci.COMMON_ITEM_ID)+COUNT(cui.CUSTOM_ITEM_ID)
|
||||
END COUNT_USE,
|
||||
<include refid="Field"></include>
|
||||
from
|
||||
<include refid="tableName"></include> f
|
||||
left join bus_hiddendangercheckstandard_common_item cca on cca.CHECK_CATEGORY = f.DICTIONARY_ID
|
||||
left join bus_hiddendangercheckstandard_common_item cci on cci.CHECK_ITEM = f.DICTIONARY_ID
|
||||
left join bus_hiddendangercheckstandard_custom_item cua on cua.CHECK_CATEGORY = f.DICTIONARY_ID
|
||||
left join bus_hiddendangercheckstandard_custom_item cui on cui.CHECK_ITEM = f.DICTIONARY_ID
|
||||
where f.ISDELETE = '0'
|
||||
group by f.DICTIONARY_ID
|
||||
order by f.DICTIONARY_LEVEL asc, f.DICTIONARY_SORT asc
|
||||
</select>
|
||||
|
||||
|
|
Loading…
Reference in New Issue