diff --git a/productionboard/src/main/java/com/productionboard/controller/AluminumTtankController.java b/productionboard/src/main/java/com/productionboard/controller/AluminumTtankController.java index 51bd0d7..bcbca7c 100644 --- a/productionboard/src/main/java/com/productionboard/controller/AluminumTtankController.java +++ b/productionboard/src/main/java/com/productionboard/controller/AluminumTtankController.java @@ -61,7 +61,7 @@ public class AluminumTtankController { @ResponseBody public String getHourProdutionStatisticsJson(){ List mesHourProdutionStatisticsList = - iMesProductionDataService.getMesHourProdutionStatisticsList("铝内胆"); + iMesProductionDataService.getMesHourProdutionStatisticsList("1006"); if(mesHourProdutionStatisticsList.size()>0){ return JSONArray.toJSONString(mesHourProdutionStatisticsList); } diff --git a/productionboard/src/main/java/com/productionboard/controller/TankShellController.java b/productionboard/src/main/java/com/productionboard/controller/TankShellController.java index 2b07b75..f8ab1a8 100644 --- a/productionboard/src/main/java/com/productionboard/controller/TankShellController.java +++ b/productionboard/src/main/java/com/productionboard/controller/TankShellController.java @@ -58,7 +58,7 @@ public class TankShellController { @GetMapping("/getHourProdutionJson") @ResponseBody public String getHourProdutionStatisticsJson(){ - List mesHourProdutionStatisticsList = iMesProductionDataService.getMesHourProdutionStatisticsList("箱壳"); + List mesHourProdutionStatisticsList = iMesProductionDataService.getMesHourProdutionStatisticsList("1009"); if(mesHourProdutionStatisticsList.size()>0){ return JSONArray.toJSONString(mesHourProdutionStatisticsList); } diff --git a/productionboard/src/main/java/com/productionboard/mapper/MesHourProdutionStatisticsMapper.java b/productionboard/src/main/java/com/productionboard/mapper/MesHourProdutionStatisticsMapper.java index 0ff699b..bc6f8c2 100644 --- a/productionboard/src/main/java/com/productionboard/mapper/MesHourProdutionStatisticsMapper.java +++ b/productionboard/src/main/java/com/productionboard/mapper/MesHourProdutionStatisticsMapper.java @@ -3,6 +3,7 @@ package com.productionboard.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.productionboard.entity.MesProduction.MesHourProdutionStatistics; import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Select; import org.springframework.stereotype.Repository; @@ -16,4 +17,19 @@ import java.util.List; @Repository public interface MesHourProdutionStatisticsMapper extends BaseMapper { + /** + * 铝内胆数据监控平台小时产量 + * @param in_id + * @return + */ + @Select("select * from table ( scada_type_hourly_output_new6(#{in_id}) )") + List getMesHourProdutionStatisticsList6(@Param("in_id") Integer in_id); + + /** + * 箱壳成型数据监控平台小时产量 + * @param in_id + * @return + */ + @Select("select * from table ( scada_type_hourly_output_new9(#{in_id}) )") + List getMesHourProdutionStatisticsList9(@Param("in_id") Integer in_id); } diff --git a/productionboard/src/main/java/com/productionboard/service/impl/MesProductionDataServiceImpl.java b/productionboard/src/main/java/com/productionboard/service/impl/MesProductionDataServiceImpl.java index aeda007..4dc9957 100644 --- a/productionboard/src/main/java/com/productionboard/service/impl/MesProductionDataServiceImpl.java +++ b/productionboard/src/main/java/com/productionboard/service/impl/MesProductionDataServiceImpl.java @@ -54,10 +54,13 @@ public class MesProductionDataServiceImpl implements IMesProductionDataService { break; case "1004": adsorptionTankTeamStatistics = teamStatisticsMapper.getAdsorptionTankTeamStatistics(this.in_id); + break; case "1006": adsorptionTankTeamStatistics = teamStatisticsMapper.getAdsorptionTankTeamStatistics6(this.in_id); + break; case "1009": adsorptionTankTeamStatistics = teamStatisticsMapper.getAdsorptionTankTeamStatistics9(this.in_id); + break; default: break; } @@ -74,9 +77,21 @@ public class MesProductionDataServiceImpl implements IMesProductionDataService { @Override @Select("") public List getMesHourProdutionStatisticsList(String locationNumber) { - QueryWrapper wrapper = new QueryWrapper(); - wrapper.eq("POSIONID",locationNumber); - List mesHourProdutionStatistics = hourProdutionStatisticsMapper.selectList(wrapper); + List mesHourProdutionStatistics = new ArrayList<>(); + switch (locationNumber) { + case "1001": + break; + case "1004": + break; + case "1006": + mesHourProdutionStatistics = hourProdutionStatisticsMapper.getMesHourProdutionStatisticsList6(this.in_id); + break; + case "1009": + mesHourProdutionStatistics = hourProdutionStatisticsMapper.getMesHourProdutionStatisticsList9(this.in_id); + break; + default: + break; + } return mesHourProdutionStatistics; }