| | |
| | | public interface AirDataMapper extends BaseMapper<AirData> { |
| | | List<String> listAirEquipmentMAC(); |
| | | |
| | | List<Long> listAirId(String keyword, Long clientId); |
| | | List<Long> listAirId(String keyword, Long userid); |
| | | |
| | | List<AirDataBo> listAirDataByIds(List<Long> airIdList); |
| | | } |
| | |
| | | */ |
| | | @Mapper |
| | | public interface AirEquipmentMapper extends BaseMapper<AirEquipment> { |
| | | List<AirEquipmentBo> listAirEquipmentByIds(String keyword, Long clientId); |
| | | List<AirEquipmentBo> listAirEquipmentByIds(String keyword, Long userid); |
| | | } |
| | | |
| | | |
| | |
| | | C3mCharging getAllByC3Mac(String c3Mac); |
| | | |
| | | |
| | | List<C3ChargingBo> listC3mChargingDto(String keyword); |
| | | List<C3ChargingBo> listC3mChargingDto(String keyword, Long userid); |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | @Mapper |
| | | public interface LightPoleHeelingMapper extends BaseMapper<LightPoleHeeling> { |
| | | List<LightPoleHeeling> listLightPoleHeeling(String keyword, Integer processingState); |
| | | List<LightPoleHeeling> listLightPoleHeeling(String keyword, Integer processingState, Long userid); |
| | | } |
| | | |
| | | |
| | |
| | | |
| | | @Mapper |
| | | public interface WaterQualityDataMapper extends BaseMapper<WaterQualityData> { |
| | | List<Long> listWaterQualityDataId(String keyword, Long clientId); |
| | | List<Long> listWaterQualityDataId(String keyword, Long userid); |
| | | |
| | | List<WaterQualityDataBo> listWaterQualityDataByIds(List<Long> WaterQualityDataIdList); |
| | | } |
| | |
| | | <if test="keyword != null and keyword != ''"> |
| | | AND t3.pole_name LIKE CONCAT(CONCAT('%', #{keyword}), '%') |
| | | </if> |
| | | <if test="clientId != null"> |
| | | AND t3.client_id = #{clientId} |
| | | <if test="userid != null"> |
| | | AND (t3.user_id = #{userid} OR t3.client_id = #{userid}) |
| | | </if> |
| | | </where> |
| | | GROUP BY |
| | |
| | | <if test="keyword != null and keyword != ''"> |
| | | AND t3.pole_name LIKE CONCAT(CONCAT('%', #{keyword}), '%') |
| | | </if> |
| | | <if test="clientId != null"> |
| | | AND t3.client_id = #{clientId} |
| | | <if test="userid != null"> |
| | | AND (t3.user_id = #{userid} OR t3.client_id = #{userid}) |
| | | </if> |
| | | </where> |
| | | </select> |
| | |
| | | <if test="keyword != null and keyword != ''"> |
| | | AND (t1.c3_name LIKE CONCAT(CONCAT('%', #{keyword}), '%') OR (t3.pole_name LIKE CONCAT(CONCAT('%', #{keyword}), '%'))) |
| | | </if> |
| | | <if test="userid != null"> |
| | | AND (t3.user_id = #{userid} OR t3.client_id = #{userid}) |
| | | </if> |
| | | </where> |
| | | </select> |
| | | </mapper> |
| | |
| | | <if test="processingState != null and processingState != 2"> |
| | | AND t1.processing_state = #{processingState} |
| | | </if> |
| | | <if test="userid != null"> |
| | | AND (t3.user_id = #{userid} OR t3.client_id = #{userid}) |
| | | </if> |
| | | </where> |
| | | |
| | | </select> |
| | |
| | | <if test="keyword != null and keyword != ''"> |
| | | AND t3.pole_name LIKE CONCAT(CONCAT('%', #{keyword}), '%') |
| | | </if> |
| | | <if test="clientId != null"> |
| | | AND t3.client_id = #{clientId} |
| | | <if test="userid != null"> |
| | | AND (t3.user_id = #{userid} OR t3.client_id = #{userid}) |
| | | </if> |
| | | </where> |
| | | GROUP BY |
| | |
| | | * 查询大气数据(模糊查询) |
| | | */ |
| | | public List<AirDataBo> listAirDataByKeyword(BaseConditionVO baseConditionVO, String keyword) { |
| | | Long clientId = SecurityUtils.getClientId(); |
| | | PageHelper.startPage(baseConditionVO.getPageNo(),baseConditionVO.getPageSize()); |
| | | List<Long> listAirId = baseMapper.listAirId(keyword,clientId); |
| | | if(CollUtil.isEmpty(listAirId)){ |
| | | PageHelper.startPage(baseConditionVO.getPageNo(), baseConditionVO.getPageSize()); |
| | | List<Long> listAirId; |
| | | if (SecurityUtils.getClientId() == null) { |
| | | listAirId = baseMapper.listAirId(keyword, null); |
| | | } else { |
| | | listAirId = baseMapper.listAirId(keyword, SecurityUtils.getUserId()); |
| | | } |
| | | if (CollUtil.isEmpty(listAirId)) { |
| | | return CollUtil.newArrayList(); |
| | | } |
| | | List<AirDataBo> airDataBos = baseMapper.listAirDataByIds(listAirId); |
| | |
| | | * 模糊查询 |
| | | */ |
| | | public List<AirEquipmentBo> listAirEquipmentByKeyword(BaseConditionVO baseConditionVO, String keyword) { |
| | | Long clientId = SecurityUtils.getClientId(); |
| | | PageHelper.startPage(baseConditionVO.getPageNo(),baseConditionVO.getPageSize()); |
| | | PageHelper.startPage(baseConditionVO.getPageNo(), baseConditionVO.getPageSize()); |
| | | List<AirEquipmentBo> airEquipmentBos; |
| | | if (SecurityUtils.getClientId() == null) { |
| | | airEquipmentBos = airEquipmentMapper.listAirEquipmentByIds(keyword, null); |
| | | }else{ |
| | | airEquipmentBos = airEquipmentMapper.listAirEquipmentByIds(keyword, SecurityUtils.getUserId()); |
| | | } |
| | | |
| | | List<AirEquipmentBo> airEquipmentBos = airEquipmentMapper.listAirEquipmentByIds(keyword,clientId); |
| | | return airEquipmentBos; |
| | | } |
| | | |
| | |
| | | import com.sandu.ximon.admin.param.C3ChargingAddParam; |
| | | import com.sandu.ximon.admin.param.C3ChargingParam; |
| | | import com.sandu.ximon.admin.param.PoleBindingParam; |
| | | import com.sandu.ximon.admin.security.SecurityUtils; |
| | | import com.sandu.ximon.admin.utils.LogUtils; |
| | | import com.sandu.ximon.admin.utils.RedisUtils; |
| | | import com.sandu.ximon.dao.bo.C3ChargingBo; |
| | |
| | | c3ChargingParam.setKeyword(c3ChargingParam.getKeyword().trim()); |
| | | } |
| | | |
| | | List<C3ChargingBo> c3ChargingBoList = c3mChargingMapper.listC3mChargingDto(c3ChargingParam.getKeyword()); |
| | | List<C3ChargingBo> c3ChargingBoList; |
| | | if(SecurityUtils.getClientId() == null){ |
| | | c3ChargingBoList = c3mChargingMapper.listC3mChargingDto(c3ChargingParam.getKeyword(), null); |
| | | }else{ |
| | | c3ChargingBoList = c3mChargingMapper.listC3mChargingDto(c3ChargingParam.getKeyword(), SecurityUtils.getUserId()); |
| | | } |
| | | for (C3ChargingBo one : c3ChargingBoList) { |
| | | String s = RedisUtils.getBean().get(C3mRedisConstant.C3_STATUS.getCode() + one.getC3Mac()); |
| | | if (s != null) { |
| | |
| | | import com.sandu.ximon.admin.manager.iot.rrpc.enums.A5OrderEnum; |
| | | import com.sandu.ximon.admin.manager.iot.rrpc.mainboard.MainBoardInvokeSyncService; |
| | | import com.sandu.ximon.admin.param.LightPoleHeelingListParam; |
| | | import com.sandu.ximon.admin.security.SecurityUtils; |
| | | import com.sandu.ximon.dao.domain.Light; |
| | | import com.sandu.ximon.dao.domain.LightPoleHeeling; |
| | | import com.sandu.ximon.dao.domain.LightPoleHeelingEquipment; |
| | |
| | | lightPoleHeelingListParam.setKeyword(lightPoleHeelingListParam.getKeyword().trim()); |
| | | } |
| | | |
| | | List<LightPoleHeeling> lightPoleHeelings |
| | | = lightPoleHeelingMapper.listLightPoleHeeling(lightPoleHeelingListParam.getKeyword(), lightPoleHeelingListParam.getProcessingState()); |
| | | List<LightPoleHeeling> lightPoleHeelings; |
| | | if (SecurityUtils.getClientId() == null) { |
| | | lightPoleHeelings = lightPoleHeelingMapper.listLightPoleHeeling(lightPoleHeelingListParam.getKeyword() |
| | | , lightPoleHeelingListParam.getProcessingState(), null); |
| | | } else { |
| | | lightPoleHeelings = lightPoleHeelingMapper.listLightPoleHeeling(lightPoleHeelingListParam.getKeyword() |
| | | , lightPoleHeelingListParam.getProcessingState(), SecurityUtils.getUserId()); |
| | | } |
| | | |
| | | return lightPoleHeelings; |
| | | } |
| | |
| | | * 模糊查询 |
| | | */ |
| | | public List<WaterQualityDataBo> listWaterQualityDataByKeyword(BaseConditionVO baseConditionVO, String keyword) { |
| | | Long clientId = SecurityUtils.getClientId(); |
| | | PageHelper.startPage(baseConditionVO.getPageNo(), baseConditionVO.getPageSize()); |
| | | List<Long> waterQualityDataId = waterQualityDataMapper.listWaterQualityDataId(keyword, clientId); |
| | | List<Long> waterQualityDataId; |
| | | if(SecurityUtils.getClientId() == null){ |
| | | waterQualityDataId = waterQualityDataMapper.listWaterQualityDataId(keyword, null); |
| | | }else{ |
| | | waterQualityDataId = waterQualityDataMapper.listWaterQualityDataId(keyword, SecurityUtils.getUserId()); |
| | | } |
| | | if (CollUtil.isEmpty(waterQualityDataId)) { |
| | | return CollUtil.newArrayList(); |
| | | } |