Commit 770ee2b4 authored by zhengjiawei's avatar zhengjiawei

添加装备

parent 15a096e9
......@@ -117,14 +117,14 @@ public class EquipmentServiceImpl implements IEquipmentService {
public Equipment queryOne(Long id) {
Optional<Equipment> dict1=iEquipmentDao.findById(id);
Equipment dict=null;
if(dict1.isPresent()){
dict=dict1.get();
}
return dict;
}
@Override
......
......@@ -58,20 +58,26 @@
</select>
<select id="getEquipmentBySpeCount" resultType="int">
select
count(1)
from
wl_stock_detail as sto
left join wl_equipment_detail as det on sto.equipment_detail_id = det.id
left join wl_equipment as equ on det.equipment_id = equ.id
left join wl_equipment_category as cate on equ.category_id = cate.id
where sto.amount <![CDATA[>]]> 0
<if test="name != null and name!='null' ">
and det.name like CONCAT('%',#{name},'%' )
</if>
<if test="code != null and code!='null' ">
and cate.code like CONCAT('%',#{code},'%' )
</if>
select
count(1)
from
wl_stock_detail as sto
left join wl_equipment_specific as spe on sto.qr_code = spe.qr_code
left join wl_warehouse_structure as ware on sto.warehouse_structure_id = ware .id
left join wl_equipment_detail as det on sto.equipment_detail_id = det.id
left join wl_equipment as equ on det.equipment_id = equ.id
left join wl_equipment_category as cate on equ.category_id = cate.id
left join f_equipment_fire_equipment as fire on sto.id = fire.fire_equipment_id
where sto.amount <![CDATA[>]]> 0
<if test="name != null and name!='null' ">
and det.name like CONCAT('%',#{name},'%' )
</if>
<if test="code != null and code!='null' ">
and cate.code like CONCAT('%',#{code},'%' )
</if>
<if test="equipmentId != null and equipmentId!='null' ">
and fire.equipment_id = #{equipmentId}
</if>
</select>
<select id="getFireEquiments" resultType="com.yeejoin.amos.fas.business.vo.EquipmentSpeVo">
select
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment