8012 AbsorbDeviceKB v1

master
yinq 2 years ago
parent 22ec7d68f9
commit e1b7c96f30

@ -20,7 +20,7 @@ public interface ScadaAbsorbMapper {
public List<AbsorbDeviceTimeLoss> selectScadaAdsorbFault(int in_id); public List<AbsorbDeviceTimeLoss> selectScadaAdsorbFault(int in_id);
public String selectScadaAdsorbDeviceOEE(); public String selectScadaAdsorbDeviceOEE(int in_id);
public String selectScadaAdsorbDeviceAlarmCount(); public String selectScadaAdsorbDeviceAlarmCount();
} }

@ -74,7 +74,7 @@ public interface ScadaAdsorbDeviceinfoMapper
ScadaAdsorbDeviceinfo getEnergyProductionThisMonth(); ScadaAdsorbDeviceinfo getEnergyProductionThisMonth();
List<ScadaAdsorbDeviceinfo> getEnergyProduction(); List<ScadaAdsorbDeviceinfo> getEnergyProduction(int in_id);
@DataSource(value = DataSourceType.MASTER) @DataSource(value = DataSourceType.MASTER)
List<AbsorbDeviceUtilOee> getUtilOee(int in_id); List<AbsorbDeviceUtilOee> getUtilOee(int in_id);

@ -45,7 +45,7 @@ public class KBAdsorbDeviceinfoServiceImpl implements IKBAdsorbDeviceinfoService
@Override @Override
public String getAdsorbDeviceOEE(){ public String getAdsorbDeviceOEE(){
return ScadaAbsorbMapper.selectScadaAdsorbDeviceOEE(); return ScadaAbsorbMapper.selectScadaAdsorbDeviceOEE(this.in_id);
} }
@Override @Override

@ -126,7 +126,7 @@ public class ScadaAdsorbDeviceinfoServiceImpl implements IScadaAdsorbDeviceinfoS
@Override @Override
@DataSource(value = DataSourceType.MASTER) @DataSource(value = DataSourceType.MASTER)
public List<ScadaAdsorbDeviceinfo> getEnergyProduction() { public List<ScadaAdsorbDeviceinfo> getEnergyProduction() {
return scadaAdsorbDeviceinfoMapper.getEnergyProduction(); return scadaAdsorbDeviceinfoMapper.getEnergyProduction(this.in_id);
} }
@Override @Override

@ -23,16 +23,19 @@
select * from table ( scada_adsorb_fault(#{in_id}) ) select * from table ( scada_adsorb_fault(#{in_id}) )
</select> </select>
<select id="selectScadaAdsorbDeviceOEE" resultType="String"> <select id="selectScadaAdsorbDeviceOEE" resultType="String" parameterType="integer">
/*select to_char(round(OEE,2),'fm99999999999990.00') as oee from /*select to_char(round(OEE,2),'fm99999999999990.00') as oee from
SCADA_HOUR_OEE where DEVICEID = '1#' SCADA_HOUR_OEE where DEVICEID = '1#'
and CREATETIME = (select max (CREATETIME) from SCADA_HOUR_OEE where DEVICEID = DEVICEID) order by CREATETIME desc and CREATETIME = (select max (CREATETIME) from SCADA_HOUR_OEE where DEVICEID = DEVICEID) order by CREATETIME desc
*/ */
select OEE
/* select OEE
from (select * from (select *
from SCADA_XF_DEVICEINFO_1 from SCADA_XF_DEVICEINFO_1
order by CREATETIME desc) order by CREATETIME desc)
where rownum = 1 where rownum = 1*/
select *
from table ( scada_adsorb_device_oee_new(#{in_id}) )
</select> </select>
<select id="selectScadaAdsorbDeviceAlarmCount" resultType="String"> <select id="selectScadaAdsorbDeviceAlarmCount" resultType="String">

@ -125,8 +125,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
SELECT * FROM TABLE( scada_absorb_device_eptm_q() ) SELECT * FROM TABLE( scada_absorb_device_eptm_q() )
</select> </select>
<select id="getEnergyProduction" resultMap="ScadaAdsorbDeviceinfoResult"> <select id="getEnergyProduction" parameterType="integer" resultMap="ScadaAdsorbDeviceinfoResult">
SELECT * FROM TABLE( scada_absorb_device_ep_q() ) SELECT * FROM TABLE( scada_absorb_device_ep_q2(#{in_id}) )
</select> </select>
<select id="getUtilOee" parameterType="integer" resultMap="ScadaAbsorbUtilOee"> <select id="getUtilOee" parameterType="integer" resultMap="ScadaAbsorbUtilOee">

Loading…
Cancel
Save