Commit debab54a authored by tangwei's avatar tangwei

增加过滤条件

parent f2fd2f8e
......@@ -380,7 +380,10 @@ public class EquipmentSpecificController extends AbstractBaseController {
@GetMapping(value = "/getListByEquipmentCode/{code}")
@ApiOperation(httpMethod = "GET", value = "根据装备分类code获取装备list", notes = "根据装备分类code获取装备list")
public List<Map<String, Object>> getListByEquipmentCode( @PathVariable String code){
return equipmentSpecificSerivce.getListByEquipmentCode(code);
ReginParams ReginParams=getSelectedOrgInfo();
String bizCode= ReginParams.getPersonIdentity().getCompanyBizOrgCode();
return equipmentSpecificSerivce.getListByEquipmentCode(code,bizCode);
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
......
......@@ -229,7 +229,7 @@ public interface EquipmentSpecificMapper extends BaseMapper<EquipmentSpecific> {
List<Map<String, Object>> getFireMonitorInfo(@Param("equipmentId") Long fireEquipmentId, @Param("list") String[] strings);
List<Map<String, Object>> getFirePumpInfo(@Param("list") String[] strings);
List<Map<String, Object>> getFirePumpInfo(@Param("list") String[] strings,@Param("bizOrgCode") String bizOrgCode);
List<Map<String, Object>> getFirePumpInfoEQ(@Param("list") String[] strings,@Param("bizOrgCode") String bizOrgCode);
......
......@@ -227,7 +227,7 @@ public interface IEquipmentSpecificSerivce extends IService<EquipmentSpecific> {
* @param code 装备分类逗号隔开
* @return 装备list
*/
List<Map<String, Object>> getListByEquipmentCode(String code);
List<Map<String, Object>> getListByEquipmentCode(String code,String bizOrgCode);
List<Map<String, Object>> getFirePumpInfoEQ(String code,String bizOrgCode);
/**
* 根据装备id获取物联日志
......
......@@ -1831,11 +1831,11 @@ public class EquipmentSpecificSerivceImpl extends ServiceImpl<EquipmentSpecificM
}
@Override
public List<Map<String, Object>> getListByEquipmentCode(String code) {
public List<Map<String, Object>> getListByEquipmentCode(String code,String bizOrgCode) {
List<Map<String, Object>> list = new ArrayList<>();
if (StringUtil.isNotEmpty(code)) {
String[] strings = code.split(",");
list = equipmentSpecificMapper.getFirePumpInfo(strings);
list = equipmentSpecificMapper.getFirePumpInfo(strings,bizOrgCode);
}
return list;
}
......
......@@ -1706,6 +1706,9 @@
wes.equipment_code LIKE <![CDATA[CONCAT(#{item},'%')]]>
</foreach>
</if>
<if test="bizOrgCode != null and bizOrgCode != ''">
and wes.biz_org_code LIKE concat(#{bizOrgCode}, '%')
</if>
</where>
ORDER BY realtiemIotIndexUpdateDate DESC
</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