Commit bc429ec0 by 罗胜

2022-03-24 罗胜

1.油量分析修改
2.航班执行期监控修改
3.航线论证修改
parent e031a93d
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.airport.dao.LeftOverOilDao">
<select id="getLeftOverOilData" resultType="com.ejweb.modules.airport.entity.LeftOverOilEntity">
select * from foc_avg_left_over_oil
where
1=1
<if test="year !=null and year!=''">
and year =#{year}
</if>
<if test="month !=null and month!=''">
and month = #{month}
</if>
<if test="acType !=null and acType!=''">
and ac_type= #{acType}
</if>
<if test="airport !=null and airport!=''">
and airport = #{airport}
</if>
</select>
<select id="selectOilByAcTyoeAndIataId" resultType="double">
select avg_left_over_oil from foc_avg_left_over_oil where ac_type=#{acType} and airport=#{airport} and `year`=#{year} and `month`=#{month} limit 1
</select>
<select id="selectOilByAirport" resultType="double">
select avg_left_over_oil from foc_avg_left_over_oil where airport=#{acType} and `year`=#{year} and `month`=#{month} limit 1
</select>
</mapper>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ejweb.modules.airport.dao.OilAnalysisDao">
<update id="update" parameterType="com.ejweb.modules.airport.bean.OilAnalysisUpdateBean">
update foc_flight_dynamics_sta set create_date=now()
<if test="extraOilConclusion !=null and extraOilConclusion !='' ">
, extra_oil_conclusion = #{extraOilConclusion}
</if>
<if test="remark !=null and remark !='' ">
,remark = #{remark}
</if>
where id=#{id}
</update>
<select id="getExcelOilAnalysisData1" resultType="com.ejweb.modules.airport.entity.OilAnalysisEntity">
select DATE_FORMAT(sta.std, '%Y/%m/%d %H:%i')as std,
DATE_FORMAT(sta.std, '%Y/%m/%d %H:%i:%s')as stdExcel,
......@@ -8,6 +20,7 @@
sta.ac_no,
sta.dispatcher_name,
IFNULL(u.name,'') as dispatcherAccount,
sta.extra_oil_fuel_reason_new,
sta.total_oil,
sta.dep_iata_id,
sta.arr_iata_id,
......@@ -88,7 +101,6 @@
sta.total_oil,
sta.dep_iata_id,
sta.arr_iata_id,
sta.extra_oil_fuel_reason,
DATE_FORMAT(sta.update_date, '%Y/%m/%d')as updateDate,
DATE_FORMAT(sta.update_time, '%Y/%m/%d %H:%i:%s')as updateTime,
sta.arr_air_port_name,
......@@ -105,10 +117,50 @@
sta.alt2_time,
sta.alt2_distance,
sta.cruising_altitude,
sta.e_e_t as eet
sta.e_e_t as eet,
sta.arr_alt_iata_id,
IFNULL(sta.flight_time,'') as flight_time,
plan.plan_left_over,
plan.hold,
plan.reserve,
sta.extra_oil_conclusion,
sta.extra_oil_fuel_reason_new,
sta.remark,
plan.takeoff_weight,
plan.landing_weight,
plan.payload_weight,
plan.zero_fuel,
plan.kal_cargo_load,
plan.maximum_fuel_capacity,
plan.total,
plan.total_time,
plan.trip,
plan.trip_time,
plan.trip_dist,
plan.arrival_time,
plan.alternate_fuel,
plan.alternate_time,
plan.alternate_dist,
plan.taxi_out,
plan.taxi_out_time,
plan.hold,
plan.etop,
plan.etop_time,
plan.reserve,
plan.reserve_time,
plan.extra_time,
plan.extra,
(CASE plan.cfp_flag
WHEN 0 Then '无二放和ETOPS'
WHEN 1 Then '只有ETOPS无二放'
WHEN 2 Then '只有二放无ETOPS'
ELSE '有二放和ETOPS' END) AS cfp_flag,
plan.custom_extra_time,
plan.limiting_takeoff_weight,
plan.limiting_landing_weight
from foc_flight_dynamics_sta sta
LEFT JOIN foc_flight_plan plan ON sta.id = plan.dynamics_sta_id
where 1=1
<if test="arrIata!=null and arrIata!='' ">
and sta.arr_iata_id = #{arrIata}
</if>
......@@ -118,7 +170,7 @@
</if>
<if test="flightNo!=null and flightNo!='' ">
and sta.flight_no = #{flightNo}
and sta.flight_no LIKE CONCAT('%',#{flightNo}, '%')
</if>
<if test="dispatcherZH!=null and dispatcherZH!=''">
......@@ -137,19 +189,35 @@
and sta.std <![CDATA[<]]> date_format(#{maxDepTime},'%Y-%c-%d %H:%i')
</if>
<if test="mintotalOil !=null and mintotalOil!=''">
and substring_index(sta.total_oil,'KGS',1) >= #{mintotalOil}
<if test="minLeftOverOil !=null and minLeftOverOil !=0">
and plan.plan_left_over >= #{minLeftOverOil}
</if>
<if test="maxtotalOil !=null and maxtotalOil!=''">
and substring_index(sta.total_oil,'KGS',1) <![CDATA[<]]> #{maxtotalOil}
<if test="maxLeftOverOil !=null and maxLeftOverOil !=0">
and plan.plan_left_over <![CDATA[<]]> #{maxLeftOverOil}
</if>
<if test="acType !=null and acType!=''">
and sta.ac_type_name like CONCAT('%',#{acType},'%')
</if>
group by sta.std,sta.flight_no
order by sta.std desc
<if test="minExtraOil !=null and minExtraOil!=0">
and substring_index(sta.extra_oil_fuel_reason_new,':',1) >= #{minExtraOil}
</if>
</select>
<if test="maxExtraOil !=null and maxExtraOil!=0">
and substring_index(sta.extra_oil_fuel_reason_new,':',1) <![CDATA[<]]> #{maxExtraOil}
</if>
<if test="extraOilReason !=null and extraOilReason!=''">
and substring_index( sta.extra_oil_fuel_reason_new, ':',- 1 ) like CONCAT('%',#{extraOilReason},'%')
</if>
GROUP BY
sta.std,
sta.flight_no
ORDER BY
sta.std DESC
</select>
<select id="getOilAnalysisData1" resultType="com.ejweb.modules.airport.entity.OilAnalysisEntity">
......@@ -215,6 +283,131 @@
</select>
<select id="getOilAnalysisData" resultType="com.ejweb.modules.airport.entity.OilAnalysisEntity">
SELECT
DATE_FORMAT( sta.std, '%Y/%m/%d %H:%i' ) AS std,
sta.id,
sta.flight_no,
sta.ac_no,
IFNULL(sta.dispatcher_account,'') as dispatcher_account,
IFNULL(sta.dispatcher_name,'') as dispatcher_name,
plan.plan_left_over,
sta.arr_air_port_name,
sta.dep_air_port_name,
sta.arr_icao_id,
sta.extra_oil_fuel_reason_new,
sta.extra_oil_conclusion,
IFNULL(plan.hold,'') as hold,
IFNULL(plan.reserve,'') as reserve,
sta.total_oil,
sta.remark_msg,
DATE_FORMAT( sta.update_date, '%Y/%m/%d' ) AS updateDate,
DATE_FORMAT( sta.update_time, '%Y/%m/%d %H:%i:%s' ) AS updateTime,
sta.ac_type_name,
sta.remark
FROM
foc_flight_dynamics_sta sta
LEFT JOIN foc_flight_plan plan ON sta.id = plan.dynamics_sta_id
where 1=1
<if test="arrIata!=null and arrIata!='' ">
and sta.arr_iata_id = #{arrIata}
</if>
<if test="depIata!=null and depIata!='' ">
and sta.dep_iata_id = #{depIata}
</if>
<if test="flightNo!=null and flightNo!='' ">
and sta.flight_no LIKE CONCAT('%',#{flightNo}, '%')
</if>
<if test="dispatcherZH!=null and dispatcherZH!=''">
and sta.dispatcher_account LIKE CONCAT('%',#{dispatcherZH}, '%')
</if>
<if test="dispatcherENG!=null and dispatcherENG!=''">
and sta.dispatcher_name LIKE CONCAT('%',#{dispatcherENG}, '%')
</if>
<if test="minDepTime !=null and minDepTime!=''">
and sta.std <![CDATA[>=]]> date_format(#{minDepTime},'%Y-%c-%d %H:%i')
</if>
<if test="maxDepTime !=null and maxDepTime!=''">
and sta.std <![CDATA[<]]> date_format(#{maxDepTime},'%Y-%c-%d %H:%i')
</if>
<if test="minLeftOverOil !=null and minLeftOverOil !=0">
and plan.plan_left_over >= #{minLeftOverOil}
</if>
<if test="maxLeftOverOil !=null and maxLeftOverOil !=0">
and plan.plan_left_over <![CDATA[<]]> #{maxLeftOverOil}
</if>
<if test="acType !=null and acType!=''">
and sta.ac_type_name like CONCAT('%',#{acType},'%')
</if>
<if test="minExtraOil !=null and minExtraOil!=0">
and substring_index(sta.extra_oil_fuel_reason_new,':',1) >= #{minExtraOil}
</if>
<if test="maxExtraOil !=null and maxExtraOil!=0">
and substring_index(sta.extra_oil_fuel_reason_new,':',1) <![CDATA[<]]> #{maxExtraOil}
</if>
<if test="extraOilReason !=null and extraOilReason!=''">
and substring_index( sta.extra_oil_fuel_reason_new, ':',- 1 ) like CONCAT('%',#{extraOilReason},'%')
</if>
GROUP BY
sta.std,
sta.flight_no
ORDER BY
sta.std DESC
</select>
<select id="getById" resultType="com.ejweb.modules.airport.entity.OilAnalysisEntity">
SELECT
DATE_FORMAT( sta.std, '%Y/%m/%d %H:%i' ) AS std,
sta.id,
sta.flight_no,
sta.ac_no,
sta.dispatcher_account,
sta.dep_iata_id,
sta.arr_iata_id,
sta.extra_oil_fuel_reason_new,
sta.arr_air_port_name,
sta.dep_air_port_name,
sta.extra_oil_conclusion,
plan.plan_left_over,
plan.hold,
plan.reserve,
DATE_FORMAT( sta.update_date, '%Y/%m/%d' ) AS updateDate,
DATE_FORMAT( sta.update_time, '%Y/%m/%d %H:%i:%s' ) AS updateTime,
sta.ac_type_name
FROM
foc_flight_dynamics_sta sta
LEFT JOIN foc_flight_plan plan ON sta.flight_no = plan.flight_no and sta.std=plan.std
where sta.id=#{id}
</select>
<select id="getOilReasons" resultType="string">
SELECT DISTINCT
substring_index( extra_oil_fuel_reason_new, ':',- 1 )
FROM
foc_flight_dynamics_sta
WHERE
1=1
<if test="startTime !=null and startTime!=null">
and DATE_FORMAT(std, '%Y/%m/%d') >= #{startTime}
</if>
<if test="endTime !=null and endTime!=null">
and DATE_FORMAT(std, '%Y/%m/%d') &lt;= #{endTime}
</if>
and substring_index( extra_oil_fuel_reason_new, ':',- 1 ) != ''
</select>
<!--已不用-->
<!--
<select id="getOilAnalysisData" resultType="com.ejweb.modules.airport.entity.OilAnalysisEntity">
select DATE_FORMAT(sta.std, '%Y/%m/%d %H:%i')as std,
sta.flight_no,
sta.ac_no,
......@@ -272,7 +465,6 @@
order by sta.std desc
</select>
-->
</mapper>
\ No newline at end of file
......@@ -69,4 +69,8 @@
FROM foc_user_depart a
WHERE a.del_flag = '0'
</select>
<select id="getDepartIdByUserId" resultType="java.lang.String">
select depart_id from sys_user_profiles where user_id = #{userId}
</select>
</mapper>
\ No newline at end of file
......@@ -460,7 +460,7 @@
SELECT
id,
verif_id,
verify_status,
verify_status,feedbackStatus
report, form_id,
form_text,
depart_id,
......@@ -548,6 +548,18 @@
</if>
ORDER BY apply_no DESC
</select>
<select id="getConditionFeedbackStatus" resultType="java.lang.Integer">
select count(1) FROM foc_condition_feedback WHERE del_flag =0 and remarks is not null and LENGTH(remarks)>0 AND depart_id=#{departId} and condition_id in
<foreach collection="conditionIds" item="conditionId" open="(" close=")" separator=",">
#{conditionId}
</foreach>
</select>
<select id="getConditionsByVerifyId" resultType="java.lang.String">
select c.id from foc_verify_condition c left join foc_airline_verify v on v.id=c.verif_id where v.id =#{verifId}
</select>
<update id="updateStatus">
update foc_verify_condition
SET status = #{status}
......
......@@ -677,18 +677,29 @@
) menu8,
(
SELECT
COUNT( 1 )
count( 1 )
FROM
(
SELECT
count( 1 )
FROM
foc_airline_verify a
LEFT JOIN foc_route_verify rf ON a.id = rf.verif_id
LEFT JOIN foc_verify_condition s ON a.id = s.verif_id
LEFT JOIN foc_airports p ON p.airport_iata = a.depIata
LEFT JOIN foc_aircraft_type q ON q.id = a.aircraft_type
LEFT JOIN foc_user_depart r ON s.depart_id = r.id
WHERE
a.del_flag = '0'
AND s.condition_status='03'
a.del_flag = 0
AND rf.STATUS = 1
AND rf.verify_status = '03'
AND s.complete = '0'
AND is_feed = '0'
AND a.verif_status = '00'
GROUP BY
s.verif_id,
s.depart_id
) temp
) menu9,
(
SELECT
......@@ -740,6 +751,23 @@
DUAL
</select>
<sql id="menu9">
--原菜单9
SELECT
COUNT( 1 )
FROM
foc_airline_verify a
LEFT JOIN foc_verify_condition s ON a.id = s.verif_id
LEFT JOIN foc_airports p ON p.airport_iata = a.depIata
LEFT JOIN foc_aircraft_type q ON q.id = a.aircraft_type
WHERE
a.del_flag = '0'
AND s.condition_status='03'
AND s.complete = '0'
AND is_feed = '0'
AND a.verif_status = '00'
</sql>
<update id="updateByPrimaryKey">
update foc_airline_verify
set
......
......@@ -3,19 +3,21 @@ package com.ejweb.modules.airport.api;
import com.ejweb.core.api.RequestBean;
import com.ejweb.core.api.ResponseBean;
import com.ejweb.core.base.GenericBean;
import com.ejweb.core.base.PageEntity;
import com.ejweb.core.conf.ErrorCode;
import com.ejweb.core.conf.GConstants;
import com.ejweb.core.utils.excel.ExportExcel;
import com.ejweb.modules.airport.bean.ExtraOilReasonBean;
import com.ejweb.modules.airport.bean.OilAnalysisBean;
import com.ejweb.modules.airport.bean.OilAnalysisIdBean;
import com.ejweb.modules.airport.bean.OilAnalysisUpdateBean;
import com.ejweb.modules.airport.entity.OilAnalysisEntity;
import com.ejweb.modules.airport.service.OilAnalysisService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
......@@ -74,5 +76,49 @@ public class OilAnalysisController {
return responseBean;
}
@RequestMapping(value = "/selectAnalysisIolById")
public ResponseBean selectAnalysisIolById(RequestBean requestBean) {
ResponseBean responseBean = new ResponseBean();
OilAnalysisIdBean bean = requestBean.getObjectBean(OilAnalysisIdBean.class);
OilAnalysisEntity oilAnalysis = oilAnalysisService.selectById(bean.getId());
if (oilAnalysis == null) {
responseBean.setMessage(GConstants.EMPTY);
responseBean.setStatus(ErrorCode.STATUS_CODE_2001);
return responseBean;
} else {
responseBean.setData(oilAnalysis);
responseBean.setMessage(GConstants.OK);
responseBean.setStatus(ErrorCode.STATUS_CODE_2000);
}
return responseBean;
}
@RequestMapping(value = "/update")
@ResponseBody
public ResponseBean update(RequestBean requestBean) {
ResponseBean responseBean = new ResponseBean();
OilAnalysisUpdateBean bean = requestBean.getObjectBean(OilAnalysisUpdateBean.class);
oilAnalysisService.update(bean);
responseBean.setMessage(GConstants.OK);
responseBean.setStatus(ErrorCode.STATUS_CODE_2000);
return responseBean;
}
@RequestMapping(value = "/getOilReason")
@ResponseBody
public ResponseBean getOilReason(RequestBean requestBean) {
ResponseBean responseBean = new ResponseBean();
ExtraOilReasonBean bean = requestBean.getObjectBean(ExtraOilReasonBean.class);
List<String> reasons=oilAnalysisService.getOilReason(bean);
responseBean.setMessage(GConstants.OK);
responseBean.setStatus(ErrorCode.STATUS_CODE_2000);
responseBean.setData(reasons);
return responseBean;
}
}
......@@ -157,9 +157,10 @@ public class StatisticalController {
//机型状态自定义
List<TypeBean> typeBeans = JSON.parseArray(s.getAirlineJson(),TypeBean.class);
s.setTypeOne(typeInfo(typeBeans.get(0),s.getAirlineStatus()));
s.setTypeTwo(typeInfo(typeBeans.get(typeBeans.size()-3),s.getAirlineStatus()));
s.setTypeThree(typeInfo(typeBeans.get(typeBeans.size()-2),s.getAirlineStatus()));
s.setTypeFour(typeInfo(typeBeans.get(typeBeans.size()-1),s.getAirlineStatus()));
s.setTypeTwo(typeInfo(typeBeans.get(typeBeans.size()-4),s.getAirlineStatus()));
s.setTypeThree(typeInfo(typeBeans.get(typeBeans.size()-3),s.getAirlineStatus()));
s.setTypeFour(typeInfo(typeBeans.get(typeBeans.size()-2),s.getAirlineStatus()));
s.setTypeFive(typeInfo(typeBeans.get(typeBeans.size()-1),s.getAirlineStatus()));
}
String fileName = "航线执行期监控统计.xlsx";
try {
......
package com.ejweb.modules.airport.bean;
/**
* 额外油原因串时间参数
*/
public class ExtraOilReasonBean {
private String startTime;
private String endTime;
public String getStartTime() {
return startTime;
}
public void setStartTime(String startTime) {
this.startTime = startTime;
}
public String getEndTime() {
return endTime;
}
public void setEndTime(String endTime) {
this.endTime = endTime;
}
}
package com.ejweb.modules.airport.bean;
import com.ejweb.core.base.GenericBean;
import com.ejweb.core.conf.GConstants;
import javax.validation.constraints.Min;
public class LeftOverOilListBean extends GenericBean {
@Min(value = 1, message = "pageNo必须大于等于1")
private int pageNo = 1;//第几页
@Min(value = 1, message = "pageSize必须大于等于1")
private int pageSize = GConstants.PAGE_SIZE;//每页条数
private int year;
private int month;
private String acType;
private String airport;
public String getAirport() {
return airport;
}
public void setAirport(String airport) {
this.airport = airport;
}
public int getPageNo() {
return pageNo;
}
public void setPageNo(int pageNo) {
this.pageNo = pageNo;
}
public int getPageSize() {
return pageSize;
}
public void setPageSize(int pageSize) {
this.pageSize = pageSize;
}
public int getYear() {
return year;
}
public void setYear(int year) {
this.year = year;
}
public int getMonth() {
return month;
}
public void setMonth(int month) {
this.month = month;
}
public String getAcType() {
return acType;
}
public void setAcType(String acType) {
this.acType = acType;
}
}
......@@ -3,6 +3,7 @@ package com.ejweb.modules.airport.bean;
import com.alibaba.fastjson.annotation.JSONField;
import com.ejweb.core.base.GenericBean;
import com.ejweb.core.conf.GConstants;
import com.lowagie.text.PageSize;
import javax.validation.constraints.Min;
......@@ -15,7 +16,11 @@ import javax.validation.constraints.Min;
* @time 2020年12月10日
*/
public class OilAnalysisBean extends GenericBean {
@Min(value=1, message="pageNo必须大于等于1")
private int pageNo=1;//第几页
@Min(value=1, message="pageSize必须大于等于1")
private int pageSize= GConstants.PAGE_SIZE;//每页条数
//最低起飞时间
private String minDepTime;
......@@ -33,16 +38,68 @@ public class OilAnalysisBean extends GenericBean {
private String dispatcherENG;
//签派员中文名
private String dispatcherZH;
//最低总油量
private Integer mintotalOil;
//最高总油量
private Integer maxtotalOil;
//最低剩油量
private Integer minLeftOverOil;
//最高剩油量
private Integer maxLeftOverOil;
//额外油原因
private String extraOilReason;
//机型
private String acType;
//最低额外油
private Integer minExtraOil;
//最高额外油
private Integer maxExtraOil;
public Integer getMinLeftOverOil() {
return minLeftOverOil;
}
public void setMinLeftOverOil(Integer minLeftOverOil) {
this.minLeftOverOil = minLeftOverOil;
}
public Integer getMaxLeftOverOil() {
return maxLeftOverOil;
}
public void setMaxLeftOverOil(Integer maxLeftOverOil) {
this.maxLeftOverOil = maxLeftOverOil;
}
public String getExtraOilReason() {
return extraOilReason;
}
public void setExtraOilReason(String extraOilReason) {
this.extraOilReason = extraOilReason;
}
public String getAcType() {
return acType;
}
public void setAcType(String acType) {
this.acType = acType;
}
public Integer getMinExtraOil() {
return minExtraOil;
}
public void setMinExtraOil(Integer minExtraOil) {
this.minExtraOil = minExtraOil;
}
public Integer getMaxExtraOil() {
return maxExtraOil;
}
public void setMaxExtraOil(Integer maxExtraOil) {
this.maxExtraOil = maxExtraOil;
}
@Min(value=1, message="pageNo必须大于等于1")
private int pageNo=1;//第几页
@Min(value=1, message="pageSize必须大于等于1")
private int pageSize= GConstants.PAGE_SIZE;//每页条数
public String getMinDepTime() {
return minDepTime;
......@@ -92,22 +149,6 @@ public class OilAnalysisBean extends GenericBean {
this.dispatcher = dispatcher;
}
public Integer getMintotalOil() {
return mintotalOil;
}
public void setMintotalOil(Integer mintotalOil) {
this.mintotalOil = mintotalOil;
}
public Integer getMaxtotalOil() {
return maxtotalOil;
}
public void setMaxtotalOil(Integer maxtotalOil) {
this.maxtotalOil = maxtotalOil;
}
public int getPageNo() {
return pageNo;
}
......
package com.ejweb.modules.airport.bean;
import com.ejweb.core.base.GenericBean;
import org.hibernate.validator.constraints.NotEmpty;
/**
* 油量分析根据id查询数据
*
* @author luos
* @version 1.0
* @team suzhou
* @time 2022年3月1日
*/
public class OilAnalysisIdBean extends GenericBean {
@NotEmpty(message = "油量分析id不能为空")
private Integer id;
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
}
package com.ejweb.modules.airport.bean;
import com.ejweb.core.base.GenericBean;
import org.hibernate.validator.constraints.NotEmpty;
/**
* 油量分析根据id查询数据
*
* @author luos
* @version 1.0
* @team suzhou
* @time 2022年3月1日
*/
public class OilAnalysisUpdateBean extends GenericBean {
@NotEmpty(message = "油量分析id不能为空")
private Integer id;
private String extraOilConclusion;
private String remark;
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark;
}
public String getExtraOilConclusion() {
return extraOilConclusion;
}
public void setExtraOilConclusion(String extraOilConclusion) {
this.extraOilConclusion = extraOilConclusion;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
}
package com.ejweb.modules.airport.dao;
import com.ejweb.core.base.BaseDao;
import com.ejweb.modules.airport.bean.LeftOverOilListBean;
import com.ejweb.modules.airport.bean.OilAnalysisBean;
import com.ejweb.modules.airport.entity.LeftOverOilEntity;
import org.apache.ibatis.annotations.Param;
import java.util.List;
public interface LeftOverOilDao extends BaseDao {
List<LeftOverOilEntity> getLeftOverOilData(LeftOverOilListBean bean);
Double selectOilByAcTyoeAndIataId(@Param("acType") String acType,@Param("airport") String airport, @Param("year") Integer year,@Param("month") Integer month);
Double selectOilByAirport(@Param("acType")String acType,@Param("year") int year, @Param("month") int month);
}
......@@ -2,9 +2,12 @@ package com.ejweb.modules.airport.dao;
import com.ejweb.core.base.BaseDao;
import com.ejweb.modules.airport.bean.AirportListBean;
import com.ejweb.modules.airport.bean.ExtraOilReasonBean;
import com.ejweb.modules.airport.bean.OilAnalysisBean;
import com.ejweb.modules.airport.bean.OilAnalysisUpdateBean;
import com.ejweb.modules.airport.entity.AirportListEntity;
import com.ejweb.modules.airport.entity.OilAnalysisEntity;
import org.apache.ibatis.annotations.Param;
import java.util.List;
......@@ -15,4 +18,13 @@ public interface OilAnalysisDao extends BaseDao {
// 导出查询油量分析数据
List<OilAnalysisEntity> getExcelOilAnalysisData(OilAnalysisBean bean);
//根据id查询油量信息数据
OilAnalysisEntity getById(@Param("id") Integer id);
//更新额外油论证
void update(OilAnalysisUpdateBean bean);
//获取近一个月的理由
List<String> getOilReasons(@Param("startTime") String startTime,@Param("endTime") String endTime);
}
package com.ejweb.modules.airport.entity;
import com.ejweb.core.base.BaseEntity;
/**
* 历史平均落地剩油数据字典表
*
* @author luos
* @version 1.0
* @team suzhou
* @time 2022年3月1日
*/
public class LeftOverOilEntity extends BaseEntity {
private static final long serialVersionUID = -1L;
private Integer year;
private String acType;
private Integer month;
private String arrAirport;
private String arrIataId;
private String arrIcaoId;
private Integer avgLeftOverOil;
}
......@@ -2,6 +2,9 @@ package com.ejweb.modules.airport.entity;
import com.ejweb.core.base.BaseEntity;
import com.ejweb.core.utils.excel.annotation.ExcelField;
import org.jfree.chart.title.Title;
import java.math.BigDecimal;
/**
......@@ -14,97 +17,492 @@ import com.ejweb.core.utils.excel.annotation.ExcelField;
*/
public class OilAnalysisEntity {
@ExcelField(title="序号", type=0, align=1, sort=27 )
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
private int id;
@ExcelField(title = "序号", type = 0, align = 1, sort = 27)
private int no;
@ExcelField(title="计划起飞时间", type=0, align=1, sort=28 )
@ExcelField(title = "计划起飞时间", type = 0, align = 1, sort = 28)
private String stdExcel; // 计划起飞时间(导出用)
@ExcelField(title="航班号", type=0, align=1, sort=29 )
@ExcelField(title = "航班号", type = 0, align = 1, sort = 29)
private String flightNo; // 航班号
@ExcelField(title="飞机号", type=0, align=1, sort=30 )
@ExcelField(title = "飞机号", type = 0, align = 1, sort = 30)
private String acNo; // 飞机号
@ExcelField(title="机型", type=0, align=1, sort=31 )
@ExcelField(title = "机型", type = 0, align = 1, sort = 31)
private String acTypeName; // 机型
@ExcelField(title="起飞机场", type=0, align=1, sort=32 )
@ExcelField(title = "起飞机场", type = 0, align = 1, sort = 32)
private String depAirPortName; // 起飞机场中文名称
@ExcelField(title="起飞机场三字码", type=0, align=1, sort=33 )
@ExcelField(title = "起飞机场三字码", type = 0, align = 1, sort = 33)
private String depIataId; // 起飞机场三字码
@ExcelField(title="起飞机场四字码", type=0, align=1, sort=34 )
@ExcelField(title = "起飞机场四字码", type = 0, align = 1, sort = 34)
private String depIcaoId; // 起飞机场四字码
@ExcelField(title="目的机场", type=0, align=1, sort=35 )
@ExcelField(title = "目的机场", type = 0, align = 1, sort = 35)
private String arrAirPortName; // 落地机场中文名称
@ExcelField(title="目的机场三字码", type=0, align=1, sort=36 )
@ExcelField(title = "目的机场三字码", type = 0, align = 1, sort = 36)
private String arrIataId; // 落地机场三字码
@ExcelField(title="目的机场四字码", type=0, align=1, sort=37 )
@ExcelField(title = "目的机场四字码", type = 0, align = 1, sort = 37)
private String arrIcaoId; // 落地机场四字码
@ExcelField(title="签派人姓名", type=0, align=1, sort=38 )
@ExcelField(title = "签派人姓名", type = 0, align = 1, sort = 38)
private String dispatcherAccount; // 签派人账号
@ExcelField(title="签派人账号", type=0, align=1, sort=39 )
@ExcelField(title = "签派人账号", type = 0, align = 1, sort = 39)
private String dispatcherName; // 签派人
@ExcelField(title="总油量(KGS)", type=0, align=1, sort=40 )
@ExcelField(title = "总油量(KGS)", type = 0, align = 1, sort = 40)
private Integer totalOilKGS; // 总油量
@ExcelField(title="总油量(LBS)", type=0, align=1, sort=41 )
@ExcelField(title = "总油量(LBS)", type = 0, align = 1, sort = 41)
private Integer totalOilLBS; // 总油量
@ExcelField(title="起飞额外油量", type=0, align=1, sort=42 )
private Integer extraOilFuelTakeoff; // 起飞额外油量
@ExcelField(title="起飞额外油量原因", type=0, align=1, sort=43 )
private String extraOilFuelTakeoffReason; // 起飞额外油量原因
@ExcelField(title="到达额外油量", type=0, align=1, sort=44 )
private Integer extraOilFuelArr; // 到达额外油量
@ExcelField(title="到达额外油量原因", type=0, align=1, sort=45 )
private String extraOilFuelArrReason; // 到达额外油量原因
@ExcelField(title="航路额外油量", type=0, align=1, sort=46 )
private Integer extraOilFuelFlight; // 航路额外油量
@ExcelField(title="航路额外油量原因", type=0, align=1, sort=47)
private String extraOilFuelFlightReason; // 航路额外油量原因
@ExcelField(title="其他额外油量", type=0, align=1, sort=48 )
private Integer extraOilFuelOther; // 其他额外油量
@ExcelField(title="其他额外油量原因", type=0, align=1, sort=49 )
private String extraOilFuelOtherReason; // 起飞额外油量原因
@ExcelField(title="数据更新时间", type=0, align=1, sort=50 )
// @ExcelField(title="起飞额外油量", type=0, align=1, sort=42 )
// private Integer extraOilFuelTakeoff; // 起飞额外油量
// @ExcelField(title="起飞额外油量原因", type=0, align=1, sort=43 )
// private String extraOilFuelTakeoffReason; // 起飞额外油量原因
// @ExcelField(title="到达额外油量", type=0, align=1, sort=44 )
// private Integer extraOilFuelArr; // 到达额外油量
// @ExcelField(title="到达额外油量原因", type=0, align=1, sort=45 )
// private String extraOilFuelArrReason; // 到达额外油量原因
// @ExcelField(title="航路额外油量", type=0, align=1, sort=46 )
// private Integer extraOilFuelFlight; // 航路额外油量
// @ExcelField(title="航路额外油量原因", type=0, align=1, sort=47)
// private String extraOilFuelFlightReason; // 航路额外油量原因
// @ExcelField(title="其他额外油量", type=0, align=1, sort=48 )
// private Integer extraOilFuelOther; // 其他额外油量
// @ExcelField(title="其他额外油量原因", type=0, align=1, sort=49 )
// private String extraOilFuelOtherReason; // 起飞额外油量原因
@ExcelField(title = "数据更新时间", type = 0, align = 1, sort = 48)
private String updateTime; // 数据更新时间
@ExcelField(title="航线耗油", type=0, align=1, sort=51 )
@ExcelField(title = "航线耗油", type = 0, align = 1, sort = 49)
private String airlineOil; // 航线耗油
@ExcelField(title="签派放行备注", type=0, align=1, sort=52 )
@ExcelField(title = "签派放行备注", type = 0, align = 1, sort = 50)
private String remarkMsg; // 签派放行备注
@ExcelField(title="目的机场到第一备降所需油量", type=0, align=1, sort=53 )
@ExcelField(title = "目的机场到第一备降所需油量", type = 0, align = 1, sort = 51)
private String alt1Fuel; // 目的机场到第一备降所需油量
@ExcelField(title="目的机场到第一备降所需时间", type=0, align=1, sort=54 )
@ExcelField(title = "目的机场到第一备降所需时间", type = 0, align = 1, sort = 52)
private String alt1Time; // 目的机场到第一备降所需时间
@ExcelField(title="目的机场到第一备降距离", type=0, align=1, sort=55 )
@ExcelField(title = "目的机场到第一备降距离", type = 0, align = 1, sort = 53)
private String alt1Distance; // 目的机场到第一备降距离
@ExcelField(title="目的机场到第二备降所需油量", type=0, align=1, sort=56 )
@ExcelField(title = "目的机场到第二备降所需油量", type = 0, align = 1, sort = 54)
private String alt2Fuel; // 目的机场到第二备降所需油量
@ExcelField(title="目的机场到第二备降所需时间", type=0, align=1, sort=57 )
@ExcelField(title = "目的机场到第二备降所需时间", type = 0, align = 1, sort = 55)
private String alt2Time; // 目的机场到第二备降所需时间
@ExcelField(title="目的机场到第二备降距离", type=0, align=1, sort=58 )
@ExcelField(title = "目的机场到第二备降距离", type = 0, align = 1, sort = 56)
private String alt2Distance; // 目的机场到第二备降距离
@ExcelField(title="巡航高度", type=0, align=1, sort=59 )
@ExcelField(title = "巡航高度", type = 0, align = 1, sort = 57)
private String cruisingAltitude; // 巡航高度
@ExcelField(title="EET", type=0, align=1, sort=60 )
@ExcelField(title = "落地备降场三字码", type = 0, align = 1, sort = 58)
private String arrAltIataId; //
@ExcelField(title = "飞行时间", type = 0, align = 1, sort = 59)
private String flightTime; //
@ExcelField(title = "EET", type = 0, align = 1, sort = 60)
private String eeT; // EET
@ExcelField(title = "额外油量", type = 0, align = 1, sort = 61)
private String extraOil; //额外油量
@ExcelField(title = "额外油原因", type = 0, align = 1, sort = 62)
private String extraOilReason;//额外油原因
@ExcelField(title = "额外油结论", type = 0, align = 1, sort = 63)
private String extraOilConclusion;//额外油结论
@ExcelField(title = "计划落地剩油", type = 0, align = 1, sort = 64)
private String planLeftOver;//计划落地剩油
@ExcelField(title = "计划落地剩油增减量", type = 0, align = 1, sort = 65)
private Integer increaseOrDecrease;//计划落地剩油增减量
@ExcelField(title = "CFP标志", type = 0, align = 1, sort = 66)
private String cfpFlag;//
@ExcelField(title = "计算起飞重量", type = 0, align = 1, sort = 67)
private String takeoffWeight;//
@ExcelField(title = "计算落地重量", type = 0, align = 1, sort = 68)
private String landingWeight;//
@ExcelField(title = "计算业载", type = 0, align = 1, sort = 69)
private String payloadWeight;//
@ExcelField(title = "计算零油量重量", type = 0, align = 1, sort = 70)
private String zeroFuel;//
@ExcelField(title = "计算货物重量", type = 0, align = 1, sort = 71)
private String kalCargoLoad;//
@ExcelField(title = "油箱最大容积", type = 0, align = 1, sort = 72)
private String maximumFuelCapacity;//
@ExcelField(title = "总油", type = 0, align = 1, sort = 73)
private String total;//
@ExcelField(title = "总时间", type = 0, align = 1, sort = 74)
private String totalTime;//
@ExcelField(title = "航线耗油", type = 0, align = 1, sort = 75)
private String trip;//
@ExcelField(title = "航线时间", type = 0, align = 1, sort = 76)
private String tripTime;//
@ExcelField(title = "航线距离", type = 0, align = 1, sort = 77)
private String tripDist;//
@ExcelField(title = "预计到达时刻", type = 0, align = 1, sort = 78)
private String arrivalTime;//
@ExcelField(title = "备降耗油", type = 0, align = 1, sort = 79)
private String alternateFuel;//
@ExcelField(title = "备降时间", type = 0, align = 1, sort = 80)
private String alternateTime;//
@ExcelField(title = "备降距离", type = 0, align = 1, sort = 81)
private String alternateDist;//
@ExcelField(title = "滑出油", type = 0, align = 1, sort = 82)
private String taxiOut;//
@ExcelField(title = "滑出时间", type = 0, align = 1, sort = 83)
private String taxiOutTime;//
@ExcelField(title = "最后储备油", type = 0, align = 1, sort = 84)
private String hold;//最后储存油
@ExcelField(title = "不可预期燃油", type = 0, align = 1, sort = 85)
private String reserve;//不可预期燃油
@ExcelField(title = "不可预期时间", type = 0, align = 1, sort = 86)
private String reserveTime;//不可预期燃油
@ExcelField(title = "计算额外油", type = 0, align = 1, sort = 87)
private String extra;//
@ExcelField(title = "计算额外时间", type = 0, align = 1, sort = 88)
private String extraTime;//
@ExcelField(title = "录入额外时间", type = 0, align = 1, sort = 89)
private String customExtraTime;//
@ExcelField(title = "性能限制起飞重量", type = 0, align = 1, sort = 90)
private String limitingTakeoffWeight;//
@ExcelField(title = "性能限制落地重量", type = 0, align = 1, sort = 91)
private String limitingLandingWeight;//
@ExcelField(title = "Etop油量", type = 0, align = 1, sort = 92)
private String etop;//
@ExcelField(title = "Etop时间", type = 0, align = 1, sort = 93)
private String etopTime;//
@ExcelField(title = "备注", type = 0, align = 1, sort = 94)
private String remark;//备注
private String extraOilFuelReasonNew;//额外油及原因新
private Integer avgPlanLeftOver; //改机型到达机场的历史平均落地剩油
private String updateDate; // 数据更新时间
private String extraOilFuelReason; // 额外油加注原因
private String totalOil; // 总油量
private String std; // 计划起飞时间
public String getLandingWeight() {
return landingWeight;
}
public void setLandingWeight(String landingWeight) {
this.landingWeight = landingWeight;
}
public String getTakeoffWeight() {
return takeoffWeight;
}
public void setTakeoffWeight(String takeoffWeight) {
this.takeoffWeight = takeoffWeight;
}
public String getPayloadWeight() {
return payloadWeight;
}
public void setPayloadWeight(String payloadWeight) {
this.payloadWeight = payloadWeight;
}
public String getZeroFuel() {
return zeroFuel;
}
public void setZeroFuel(String zeroFuel) {
this.zeroFuel = zeroFuel;
}
public String getKalCargoLoad() {
return kalCargoLoad;
}
public void setKalCargoLoad(String kalCargoLoad) {
this.kalCargoLoad = kalCargoLoad;
}
public String getMaximumFuelCapacity() {
return maximumFuelCapacity;
}
public void setMaximumFuelCapacity(String maximumFuelCapacity) {
this.maximumFuelCapacity = maximumFuelCapacity;
}
public String getTotalTime() {
return totalTime;
}
public void setTotalTime(String totalTime) {
this.totalTime = totalTime;
}
public String getTripTime() {
return tripTime;
}
public void setTripTime(String tripTime) {
this.tripTime = tripTime;
}
public String getTripDist() {
return tripDist;
}
public void setTripDist(String tripDist) {
this.tripDist = tripDist;
}
public String getArrivalTime() {
return arrivalTime;
}
public void setArrivalTime(String arrivalTime) {
this.arrivalTime = arrivalTime;
}
public String getAlternateFuel() {
return alternateFuel;
}
public void setAlternateFuel(String alternateFuel) {
this.alternateFuel = alternateFuel;
}
public String getAlternateTime() {
return alternateTime;
}
public void setAlternateTime(String alternateTime) {
this.alternateTime = alternateTime;
}
public String getAlternateDist() {
return alternateDist;
}
public void setAlternateDist(String alternateDist) {
this.alternateDist = alternateDist;
}
public String getTaxiOutTime() {
return taxiOutTime;
}
public void setTaxiOutTime(String taxiOutTime) {
this.taxiOutTime = taxiOutTime;
}
public String getReserveTime() {
return reserveTime;
}
public void setReserveTime(String reserveTime) {
this.reserveTime = reserveTime;
}
public String getExtra() {
return extra;
}
public void setExtra(String extra) {
this.extra = extra;
}
public String getExtraTime() {
return extraTime;
}
public void setExtraTime(String extraTime) {
this.extraTime = extraTime;
}
public String getCustomExtraTime() {
return customExtraTime;
}
public void setCustomExtraTime(String customExtraTime) {
this.customExtraTime = customExtraTime;
}
public String getLimitingTakeoffWeight() {
return limitingTakeoffWeight;
}
public void setLimitingTakeoffWeight(String limitingTakeoffWeight) {
this.limitingTakeoffWeight = limitingTakeoffWeight;
}
public String getLimitingLandingWeight() {
return limitingLandingWeight;
}
public void setLimitingLandingWeight(String limitingLandingWeight) {
this.limitingLandingWeight = limitingLandingWeight;
}
public String getEtopTime() {
return etopTime;
}
public void setEtopTime(String etopTime) {
this.etopTime = etopTime;
}
public String getTotal() {
return total;
}
public void setTotal(String total) {
this.total = total;
}
public String getTrip() {
return trip;
}
public void setTrip(String trip) {
this.trip = trip;
}
public String getTaxiOut() {
return taxiOut;
}
public void setTaxiOut(String taxiOut) {
this.taxiOut = taxiOut;
}
public String getCfpFlag() {
return cfpFlag;
}
public void setCfpFlag(String cfpFlag) {
this.cfpFlag = cfpFlag;
}
public String getEtop() {
return etop;
}
public void setEtop(String etop) {
this.etop = etop;
}
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark;
}
public Integer getIncreaseOrDecrease() {
return increaseOrDecrease;
}
public void setIncreaseOrDecrease(Integer increaseOrDecrease) {
this.increaseOrDecrease = increaseOrDecrease;
}
public Integer getAvgPlanLeftOver() {
return avgPlanLeftOver;
}
public void setAvgPlanLeftOver(Integer avgPlanLeftOver) {
this.avgPlanLeftOver = avgPlanLeftOver;
}
public String getExtraOil() {
return extraOil;
}
public void setExtraOil(String extraOil) {
this.extraOil = extraOil;
}
public String getExtraOilReason() {
return extraOilReason;
}
public void setExtraOilReason(String extraOilReason) {
this.extraOilReason = extraOilReason;
}
public String getExtraOilConclusion() {
return extraOilConclusion;
}
public void setExtraOilConclusion(String extraOilConclusion) {
this.extraOilConclusion = extraOilConclusion;
}
public String getPlanLeftOver() {
return planLeftOver;
}
public void setPlanLeftOver(String planLeftOver) {
this.planLeftOver = planLeftOver;
}
public String getHold() {
return hold;
}
public void setHold(String hold) {
this.hold = hold;
}
public String getReserve() {
return reserve;
}
public void setReserve(String reserve) {
this.reserve = reserve;
}
public String getExtraOilFuelReasonNew() {
return extraOilFuelReasonNew;
}
public void setExtraOilFuelReasonNew(String extraOilFuelReasonNew) {
this.extraOilFuelReasonNew = extraOilFuelReasonNew;
}
public String getArrAltIataId() {
return arrAltIataId;
}
public void setArrAltIataId(String arrAltIataId) {
this.arrAltIataId = arrAltIataId;
}
public String getFlightTime() {
return flightTime;
}
public void setFlightTime(String flightTime) {
this.flightTime = flightTime;
}
public String getAirlineOil() {
return airlineOil;
}
......@@ -218,37 +616,37 @@ public class OilAnalysisEntity {
this.dispatcherAccount = dispatcherAccount;
}
public String getExtraOilFuelTakeoffReason() {
return extraOilFuelTakeoffReason;
}
public void setExtraOilFuelTakeoffReason(String extraOilFuelTakeoffReason) {
this.extraOilFuelTakeoffReason = extraOilFuelTakeoffReason;
}
public String getExtraOilFuelArrReason() {
return extraOilFuelArrReason;
}
public void setExtraOilFuelArrReason(String extraOilFuelArrReason) {
this.extraOilFuelArrReason = extraOilFuelArrReason;
}
public String getExtraOilFuelFlightReason() {
return extraOilFuelFlightReason;
}
public void setExtraOilFuelFlightReason(String extraOilFuelFlightReason) {
this.extraOilFuelFlightReason = extraOilFuelFlightReason;
}
public String getExtraOilFuelOtherReason() {
return extraOilFuelOtherReason;
}
public void setExtraOilFuelOtherReason(String extraOilFuelOtherReason) {
this.extraOilFuelOtherReason = extraOilFuelOtherReason;
}
// public String getExtraOilFuelTakeoffReason() {
// return extraOilFuelTakeoffReason;
// }
//
// public void setExtraOilFuelTakeoffReason(String extraOilFuelTakeoffReason) {
// this.extraOilFuelTakeoffReason = extraOilFuelTakeoffReason;
// }
//
// public String getExtraOilFuelArrReason() {
// return extraOilFuelArrReason;
// }
//
// public void setExtraOilFuelArrReason(String extraOilFuelArrReason) {
// this.extraOilFuelArrReason = extraOilFuelArrReason;
// }
//
// public String getExtraOilFuelFlightReason() {
// return extraOilFuelFlightReason;
// }
//
// public void setExtraOilFuelFlightReason(String extraOilFuelFlightReason) {
// this.extraOilFuelFlightReason = extraOilFuelFlightReason;
// }
//
// public String getExtraOilFuelOtherReason() {
// return extraOilFuelOtherReason;
// }
//
// public void setExtraOilFuelOtherReason(String extraOilFuelOtherReason) {
// this.extraOilFuelOtherReason = extraOilFuelOtherReason;
// }
public String getStdExcel() {
......@@ -339,37 +737,37 @@ public class OilAnalysisEntity {
this.extraOilFuelReason = extraOilFuelReason;
}
public Integer getExtraOilFuelTakeoff() {
return extraOilFuelTakeoff;
}
public void setExtraOilFuelTakeoff(Integer extraOilFuelTakeoff) {
this.extraOilFuelTakeoff = extraOilFuelTakeoff;
}
public Integer getExtraOilFuelArr() {
return extraOilFuelArr;
}
public void setExtraOilFuelArr(Integer extraOilFuelArr) {
this.extraOilFuelArr = extraOilFuelArr;
}
public Integer getExtraOilFuelFlight() {
return extraOilFuelFlight;
}
public void setExtraOilFuelFlight(Integer extraOilFuelFlight) {
this.extraOilFuelFlight = extraOilFuelFlight;
}
public Integer getExtraOilFuelOther() {
return extraOilFuelOther;
}
public void setExtraOilFuelOther(Integer extraOilFuelOther) {
this.extraOilFuelOther = extraOilFuelOther;
}
// public Integer getExtraOilFuelTakeoff() {
// return extraOilFuelTakeoff;
// }
//
// public void setExtraOilFuelTakeoff(Integer extraOilFuelTakeoff) {
// this.extraOilFuelTakeoff = extraOilFuelTakeoff;
// }
//
// public Integer getExtraOilFuelArr() {
// return extraOilFuelArr;
// }
//
// public void setExtraOilFuelArr(Integer extraOilFuelArr) {
// this.extraOilFuelArr = extraOilFuelArr;
// }
//
// public Integer getExtraOilFuelFlight() {
// return extraOilFuelFlight;
// }
//
// public void setExtraOilFuelFlight(Integer extraOilFuelFlight) {
// this.extraOilFuelFlight = extraOilFuelFlight;
// }
//
// public Integer getExtraOilFuelOther() {
// return extraOilFuelOther;
// }
//
// public void setExtraOilFuelOther(Integer extraOilFuelOther) {
// this.extraOilFuelOther = extraOilFuelOther;
// }
public String getDepAirPortName() {
return depAirPortName;
......
......@@ -17,19 +17,29 @@ public class StatisticalListEntity extends BaseEntity {
private String airlineJson;
@ExcelField(title="航线状态", type=0, align=1, sort=26 )
private String status;
@ExcelField(title="A319/A320", type=0, align=1, sort=21 )
@ExcelField(title="A319/A320", type=0, align=1, sort=20 )
private String typeOne;
@ExcelField(title="A321", type=0, align=1, sort=22 )
@ExcelField(title="A320neo", type=0, align=1, sort=21 )
private String typeTwo;
@ExcelField(title="A320neo", type=0, align=1, sort=23 )
@ExcelField(title="A321", type=0, align=1, sort=22 )
private String typeThree;
@ExcelField(title="A330", type=0, align=1, sort=24 )
@ExcelField(title="A321neo", type=0, align=1, sort=23 )
private String typeFour;
@ExcelField(title="航线", type=0, align=1, sort=20 )
@ExcelField(title="A330", type=0, align=1, sort=24 )
private String typeFive;
@ExcelField(title="航线", type=0, align=1, sort=19 )
private String depIataLabel;
@ExcelField(title="序号", type=0, align=1, sort=19 )
@ExcelField(title="序号", type=0, align=1, sort=18 )
private int no;
public String getTypeFive() {
return typeFive;
}
public void setTypeFive(String typeFive) {
this.typeFive = typeFive;
}
public String getArrIata() {
return arrIata;
}
......
package com.ejweb.modules.airport.service;
import com.ejweb.core.base.BaseService;
import com.ejweb.core.base.PageEntity;
import com.ejweb.modules.airport.bean.LeftOverOilListBean;
import com.ejweb.modules.airport.bean.OilAnalysisBean;
import com.ejweb.modules.airport.dao.LeftOverOilDao;
import com.ejweb.modules.airport.entity.LeftOverOilEntity;
import com.ejweb.modules.airport.entity.OilAnalysisEntity;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.StringUtils;
import java.util.List;
@Service
public class LeftOverOilService extends BaseService<LeftOverOilDao> {
@Autowired
private LeftOverOilDao leftOverOilDao;
public PageEntity<LeftOverOilEntity> getAnalysisData(LeftOverOilListBean bean) {
PageHelper.startPage(bean.getPageNo(), bean.getPageSize());
PageInfo<LeftOverOilEntity> pageInfo = null;
List<LeftOverOilEntity> list = null;
list = leftOverOilDao.getLeftOverOilData(bean);
if (list == null || list.size() == 0) {
return null;
}
pageInfo = new PageInfo<LeftOverOilEntity>(list);
if (pageInfo.getPages() < bean.getPageNo()) {// 页码大于总页数,则返回NULL
return null;
}
PageEntity<LeftOverOilEntity> page = new PageEntity<LeftOverOilEntity>();
page.setPageNo(pageInfo.getPageNum());
page.setPageSize(pageInfo.getPageSize());
page.setCount(pageInfo.getTotal());
page.setTotalPage(pageInfo.getPages());
page.setList(pageInfo.getList());
return page;
}
}
......@@ -2,16 +2,25 @@ package com.ejweb.modules.airport.service;
import com.ejweb.core.base.BaseService;
import com.ejweb.core.base.PageEntity;
import com.ejweb.modules.airport.bean.ExtraOilReasonBean;
import com.ejweb.modules.airport.bean.OilAnalysisBean;
import com.ejweb.modules.airport.bean.OilAnalysisUpdateBean;
import com.ejweb.modules.airport.dao.LeftOverOilDao;
import com.ejweb.modules.airport.dao.OilAnalysisDao;
import com.ejweb.modules.airport.entity.LeftOverOilEntity;
import com.ejweb.modules.airport.entity.OilAnalysisEntity;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import org.apache.commons.lang3.ObjectUtils;
import org.apache.http.client.utils.DateUtils;
import org.apache.lucene.util.MathUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.StringUtils;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
@Service
......@@ -20,7 +29,8 @@ public class OilAnalysisService extends BaseService<OilAnalysisDao> {
@Autowired
protected OilAnalysisDao oilAnalysisDao;
@Autowired
private LeftOverOilDao leftOverOilDao;
public PageEntity<OilAnalysisEntity> getAnalysisData(OilAnalysisBean bean, Boolean isPage) {
......@@ -68,62 +78,99 @@ public class OilAnalysisService extends BaseService<OilAnalysisDao> {
oilAnalysisEntity.setTotalOilLBS(Integer.valueOf(strLBS.replaceAll("LBS", "")));
}
String oilFuelReason = oilAnalysisEntity.getExtraOilFuelReason();
if (!StringUtils.isEmpty(oilFuelReason)) {
String[] arr = oilFuelReason.split("\\|");
for (int i = 0; i < arr.length; i++) {
String arrTemp = arr[i];
String oilNum = "";
String oilReason = "";
String[] reasonArr = arrTemp.split(":");
if (arrTemp.indexOf(":") > 1) {
if (reasonArr.length == 1) {
//只有前面
oilNum = reasonArr[0];
oilReason = "";
} else if (reasonArr.length == 2) {
//前后都有
oilNum = reasonArr[0];
oilReason = reasonArr[1];
}
} else {
if (reasonArr.length == 1) {
//只有后面
oilNum = "";
oilReason = reasonArr[0];
}
}
if (oilNum.length() == 0) {
oilNum = "0";
}
switch (i) {
case 0:
//到达额外油量及原因
oilAnalysisEntity.setExtraOilFuelArr(Integer.valueOf(oilNum));
oilAnalysisEntity.setExtraOilFuelArrReason(oilReason);
break;
case 1:
//起飞油量及原因
oilAnalysisEntity.setExtraOilFuelTakeoff(Integer.valueOf(oilNum));
oilAnalysisEntity.setExtraOilFuelTakeoffReason(oilReason);
break;
case 2:
//航路额外油量及原因
oilAnalysisEntity.setExtraOilFuelFlight(Integer.valueOf(oilNum));
oilAnalysisEntity.setExtraOilFuelFlightReason(oilReason);
break;
case 3:
//其他额外油量及原因
oilAnalysisEntity.setExtraOilFuelOther(Integer.valueOf(oilNum));
oilAnalysisEntity.setExtraOilFuelOtherReason(oilReason);
break;
default:
}
}
}
//新增加的字段处理
String oilFuelReason = oilAnalysisEntity.getExtraOilFuelReasonNew();
String[] arr = oilFuelReason.split(":");
if(oilFuelReason.startsWith(":")&& !oilFuelReason.endsWith(":")){
oilAnalysisEntity.setExtraOil("");
oilAnalysisEntity.setExtraOilReason(arr[0]);
}else if(oilFuelReason.endsWith(":")&& !oilFuelReason.startsWith(":")){
oilAnalysisEntity.setExtraOil(arr[0].equals("0")?"":arr[0]);
oilAnalysisEntity.setExtraOilReason("");
}else if(!oilFuelReason.startsWith(":")&& !oilFuelReason.endsWith(":")){
oilAnalysisEntity.setExtraOil(arr[0].equals("0")?"":arr[0]);
oilAnalysisEntity.setExtraOilReason(arr[1]);
}else{
oilAnalysisEntity.setExtraOil("");
oilAnalysisEntity.setExtraOilReason("");
}
if(ObjectUtils.notEqual(oilAnalysisEntity.getPlanLeftOver(),null)){
String planLeftOver=String.valueOf(oilAnalysisEntity.getPlanLeftOver());
//0下标为年,1位月,2位日
String[] timeArr = oilAnalysisEntity.getStd().split("/");
int year=Integer.valueOf(timeArr[0]);
int month=Integer.valueOf(timeArr[1]);
Double leftOverOil =leftOverOilDao.selectOilByAcTyoeAndIataId(oilAnalysisEntity.getAcTypeName(),oilAnalysisEntity.getArrIcaoId(),year,month);
if(!ObjectUtils.notEqual(leftOverOil,null)){
leftOverOil=leftOverOilDao.selectOilByAirport(oilAnalysisEntity.getAcTypeName(),year,month);
}
oilAnalysisEntity.setPlanLeftOver(oilAnalysisEntity.getPlanLeftOver());
System.out.println(planLeftOver);
System.out.println(leftOverOil);
oilAnalysisEntity.setIncreaseOrDecrease(Integer.valueOf(planLeftOver)-leftOverOil.intValue());
}else{
oilAnalysisEntity.setPlanLeftOver("");
}
if("0".equals(oilAnalysisEntity.getExtraOil())){
oilAnalysisEntity.setExtraOil("");
}
// String oilFuelReason = oilAnalysisEntity.getExtraOilFuelReason();
// if (!StringUtils.isEmpty(oilFuelReason)) {
// String[] arr = oilFuelReason.split("\\|");
// for (int i = 0; i < arr.length; i++) {
// String arrTemp = arr[i];
// String oilNum = "";
// String oilReason = "";
// String[] reasonArr = arrTemp.split(":");
// if (arrTemp.indexOf(":") > 1) {
// if (reasonArr.length == 1) {
// //只有前面
// oilNum = reasonArr[0];
// oilReason = "";
//
// } else if (reasonArr.length == 2) {
// //前后都有
// oilNum = reasonArr[0];
// oilReason = reasonArr[1];
// }
// } else {
// if (reasonArr.length == 1) {
// //只有后面
// oilNum = "";
// oilReason = reasonArr[0];
// }
// }
//
// if (oilNum.length() == 0) {
// oilNum = "0";
// }
//
// switch (i) {
// case 0:
// //到达额外油量及原因
// oilAnalysisEntity.setExtraOilFuelArr(Integer.valueOf(oilNum));
// oilAnalysisEntity.setExtraOilFuelArrReason(oilReason);
// break;
// case 1:
// //起飞油量及原因
// oilAnalysisEntity.setExtraOilFuelTakeoff(Integer.valueOf(oilNum));
// oilAnalysisEntity.setExtraOilFuelTakeoffReason(oilReason);
// break;
// case 2:
// //航路额外油量及原因
// oilAnalysisEntity.setExtraOilFuelFlight(Integer.valueOf(oilNum));
// oilAnalysisEntity.setExtraOilFuelFlightReason(oilReason);
// break;
// case 3:
// //其他额外油量及原因
// oilAnalysisEntity.setExtraOilFuelOther(Integer.valueOf(oilNum));
// oilAnalysisEntity.setExtraOilFuelOtherReason(oilReason);
// break;
// default:
// }
// }
// }
}
if (oilAnalysisEntityList == null || oilAnalysisEntityList.size() == 0) {
......@@ -146,4 +193,23 @@ public class OilAnalysisService extends BaseService<OilAnalysisDao> {
}
public OilAnalysisEntity selectById(Integer id) {
return oilAnalysisDao.getById(id);
}
public void update(OilAnalysisUpdateBean bean) {
oilAnalysisDao.update(bean);
}
public List<String> getOilReason(ExtraOilReasonBean bean) {
String startTime=DateUtils.formatDate(org.apache.commons.lang3.time.DateUtils.addDays(new Date(),-30), "yyyy/MM/dd");
String endTime=DateUtils.formatDate(new Date(), "yyyy/MM/dd");
if(org.apache.commons.lang3.StringUtils.isNotBlank(bean.getStartTime())){
startTime=bean.getStartTime();
}
if(org.apache.commons.lang3.StringUtils.isNotBlank(bean.getEndTime())){
endTime=bean.getEndTime();
}
return oilAnalysisDao.getOilReasons(startTime,endTime);
}
}
......@@ -3,6 +3,8 @@
*/
package com.ejweb.modules.airport.service;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.ejweb.core.base.BaseService;
import com.ejweb.core.base.PageEntity;
import com.ejweb.modules.airport.bean.StatiscalCheckBean;
......@@ -170,6 +172,7 @@ public class StatisticalService extends BaseService<StatisticalDao> {
//筛选foc_check_iata中 不需要的航班 add by luoh
Iterator<StatisticalListEntity> iterCheck = lists.iterator();
String a321neoStr="{\"status\":\"3\",\"type\":\"321neo\"}";
while (iterCheck.hasNext()) {
StatisticalListEntity entity = iterCheck.next();
String iataStr = entity.getDepIata() + "-" + entity.getArrIata();
......@@ -179,6 +182,18 @@ public class StatisticalService extends BaseService<StatisticalDao> {
break;
}
}
List<String> list = JSON.parseArray(entity.getAirlineJson(), String.class);
List<String> newList=new ArrayList<>();
if(list.size()==4&&list.get(1).contains("A321")){
newList.add(list.get(0));
newList.add(list.get(2));
newList.add(a321neoStr);
newList.add(list.get(1));
newList.add(list.get(3));
}else{
newList=list;
}
entity.setAirlineJson(newList.toString());
}
//创建Page类
Page page = new Page(statisticalListBean.getPageNo(), statisticalListBean.getPageSize());
......
......@@ -21,4 +21,6 @@ public interface DepartDao extends BaseDao{
public List<DepartEntity> findRiskList(DepartBean bean);
public List<DepartEntity> findDepartByList(@Param(value="type") String type, @Param(value = "isVerif") String isVerif);
public List<DepartTypeEntity> findDepartAllList();
public String getDepartIdByUserId(@Param("userId") String userId);
}
\ No newline at end of file
......@@ -120,9 +120,10 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
entity.setConnect(verifyDao.getConnectList(entity.getVerifId()));
entity.setDepName(verifyDao.getConnetList(entity.getVerifId()));
String typelist = verifyDao.getTypeList1(entity.getVerifId());
if (StringUtils.isNoneBlank(typelist))
if (StringUtils.isNoneBlank(typelist)) {
entity.setAircraftName(entity.getAircraftName() + ":" + typelist);
}
}
PageEntity<SailingCommandEntity> page = new PageEntity<SailingCommandEntity>();
page.setPageNo(pageInfo.getPageNum());
page.setPageSize(pageInfo.getPageSize());
......@@ -347,7 +348,7 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
sb.append("<p style=\"text-align:right\">运行控制部组织协调中心</p><p style=\"text-align:right\">电话:010-69615154</p></td></tr>");
sb.append("<tr style=\"text-align:center;background-color:#e5e5e5;\"><td colspan=\"3\">编写</td><td colspan=\"2\">审核</td><td colspan=\"3\">批准</td></tr>");
sb.append("<tr style=\"text-align:center;\"><td colspan=\"3\">组织协调单元</td><td colspan=\"2\"><textarea style=\"width:100%\" rows=\"1\">万宇</textarea><td colspan=\"3\"><textarea style=\"width:100%\" rows=\"1\">梁广义</textarea></td></tr>");
sb.append("<tr style=\"text-align:center;\"><td colspan=\"2\">公司主管领导</td><td colspan=\"6\"><textarea style=\"width:100%\" rows=\"1\">胡波</textarea></td></tr>");
sb.append("<tr style=\"text-align:center;\"><td colspan=\"2\">公司主管领导</td><td colspan=\"6\"><textarea style=\"width:100%\" rows=\"1\">刘桃林</textarea></td></tr>");
sb.append("<tr><td>类别</td><td>要求执行</td><td colspan=\"2\">要求修改程序</td><td colspan=\"3\">要求提供反馈</td><td>其他</td></tr>");
sb.append("<tr><td>本指令发至</td><td colspan=\"7\">公司各部门。</td></tr>");
sb.append("<tr><td>抄送至</td><td colspan=\"7\">公司分管领导。</td></tr>");
......@@ -908,7 +909,7 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
}
/**
* @param entity
*
* @param verifType
* @return
* @author huhy
......@@ -990,23 +991,25 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
String title = "首都航空关于" + flight;
VerifyEmailHandler.getInstance().sendEmail(title + "的开航指令提示(智能首航论证系统提示)", en + com.ejweb.core.util.TemplateFactory.generateHtmlFromFtl(templateName, map) + plan, mails, ccmails);
} catch (IOException e) {
}catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (TemplateException e) {
}
catch (TemplateException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
public List<ConnectionPlan> planlist(String fileName, String filePath) {
InputStream in = null;
//读取文件
try {
//获取目标文件的绝对路径
// String fullFileName = filePath;
String fullFileName = GConstants.FILE_UPLOAD_DIR + filePath;
InputStream in = null;
in = new FileInputStream(fullFileName);
ImportExcel ei = new ImportExcel(fileName, in, 1, 0);
try {
......@@ -1040,6 +1043,14 @@ public class SailingCommandService extends CurdService<SailingCommandDao, Sailin
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} finally {
try {
if (in != null) {
in.close();
}
} catch (IOException e) {
e.printStackTrace();
}
}
return null;
}
......
......@@ -36,10 +36,18 @@ public class VerifyFeedbackBean extends GenericBean {
private String sort;
@Min(value = 1, message = "pageSize必须大于等于1")
private int pageSize = GConstants.PAGE_SIZE;//每页条数
private String departId;
List arrIataList;
List depIataList;
public String getDepartId() {
return departId;
}
public void setDepartId(String departId) {
this.departId = departId;
}
public List getArrIataList() {
return arrIataList;
}
......
......@@ -77,4 +77,8 @@ public interface VerifyFeedbackDao extends BaseDao {
List<VerifyFeedbackEntity> findlist3(VerifyFeedbackBean bean);
List<VerifyFeedbackEntity> findList4(VerifyFeedbackBean bean);
int getConditionFeedbackStatus(@Param("departId") String departId, @Param("conditionIds") List<String> conditionIds);
List<String> getConditionsByVerifyId(@Param("verifId") String verifId);
}
......@@ -55,6 +55,17 @@ public class VerifyFeedbackEntity extends BaseEntity {
private String feedbackStatus;
private String roundtripType;
private String conditionFeedbackStatus;
public String getConditionFeedbackStatus() {
return conditionFeedbackStatus;
}
public void setConditionFeedbackStatus(String conditionFeedbackStatus) {
this.conditionFeedbackStatus = conditionFeedbackStatus;
}
public String getRoundtripType() {
return roundtripType;
}
......
......@@ -54,6 +54,7 @@ public class VerifyFeedbackService extends BaseService<VerifyFeedbackDao> {
RouteVerifyService routeVerifyService;
public PageEntity<VerifyFeedbackEntity> findList(VerifyFeedbackBean bean) {
String departId= departDao.getDepartIdByUserId(bean.getUserCode());
if (StringUtils.isNotEmpty(bean.getArrIata())) {
bean.setArrIataList(verifyDao.getIataStr(bean.getArrIata()));
}
......@@ -82,6 +83,13 @@ public class VerifyFeedbackService extends BaseService<VerifyFeedbackDao> {
return null;
}
for (VerifyFeedbackEntity entity : list) {
List<String> conditions=dao.getConditionsByVerifyId(entity.getVerifId());
int count = dao.getConditionFeedbackStatus(departId, conditions);
if(count>0){
entity.setConditionFeedbackStatus("01");
}else{
entity.setConditionFeedbackStatus("00");
}
List<Map<String, String>> list1 = verifyDao.getConnectList(entity.getVerifId());
List<Map<String, String>> list2 = new ArrayList<Map<String, String>>();
for (Map<String, String> map : list1) {
......
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