Commit 89c37490 authored by wujiang's avatar wujiang

提交代码

parent d5614cf1
...@@ -44,7 +44,9 @@ ...@@ -44,7 +44,9 @@
WHEN hbga.grid_status = '7' THEN '片区运营待审核' WHEN hbga.grid_status = '7' THEN '片区运营待审核'
WHEN hbga.grid_status = '8' THEN '工程待审核' WHEN hbga.grid_status = '8' THEN '工程待审核'
WHEN hbga.grid_status = '9' THEN '整改待审核' WHEN hbga.grid_status = '9' THEN '整改待审核'
ELSE '待整改' END AS gridStatus ELSE '待整改' END AS gridStatus,
hygf_commercial.scale,
hygf_power_station_engineering_info.real_scale as realScale
FROM FROM
hygf_basic_grid_record hbga hygf_basic_grid_record hbga
LEFT JOIN hygf_peasant_household hph ON hph.sequence_nbr = hbga.peasant_household_id LEFT JOIN hygf_peasant_household hph ON hph.sequence_nbr = hbga.peasant_household_id
...@@ -53,6 +55,9 @@ ...@@ -53,6 +55,9 @@
left join left join
(select work_order_power_station_id, MIN( operation_time ) as firstSubmitDate from hygf_construction_gird_records hcgr where operation_content = '提交并网资料' GROUP BY work_order_power_station_id) (select work_order_power_station_id, MIN( operation_time ) as firstSubmitDate from hygf_construction_gird_records hcgr where operation_content = '提交并网资料' GROUP BY work_order_power_station_id)
newHcgr on newHcgr.work_order_power_station_id = hbga.work_order_power_station_id newHcgr on newHcgr.work_order_power_station_id = hbga.work_order_power_station_id
LEFT JOIN hygf_commercial on hygf_commercial.survey_information_id =hph.survey_information_id
LEFT JOIN hygf_work_order_power_station on hygf_work_order_power_station.peasant_household_id =hph.sequence_nbr
LEFT JOIN hygf_power_station_engineering_info on hygf_power_station_engineering_info.work_order_power_station_id=hygf_work_order_power_station.sequence_nbr
<where> <where>
hbga.is_delete = 0 hbga.is_delete = 0
<if test="map.routhPathId != null and map.routhPathId != ''"> <if test="map.routhPathId != null and map.routhPathId != ''">
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
hph.sequence_nbr AS sequenceNbr, hph.sequence_nbr AS sequenceNbr,
hph.peasant_household_no peasantHouseholdNo, hph.peasant_household_no peasantHouseholdNo,
hph.owners_name AS ownersName, hph.owners_name AS ownersName,
concat(hph.project_address_name,project_address_detail) AS projectAddress, concat(hph.project_address_name,hph.project_address_detail) AS projectAddress,
hph.regional_companies_name AS regionalCompaniesName, hph.regional_companies_name AS regionalCompaniesName,
IFNULL( info.`status`, '待推送' ) AS status, IFNULL( info.`status`, '待推送' ) AS status,
(select count( hfro.sequence_nbr ) from hygf_financing_rectification_order hfro where hfro.peasant_household_id = hph.sequence_nbr )orderNum, (select count( hfro.sequence_nbr ) from hygf_financing_rectification_order hfro where hfro.peasant_household_id = hph.sequence_nbr )orderNum,
...@@ -21,12 +21,18 @@ ...@@ -21,12 +21,18 @@
hph.developer_name developerName, hph.developer_name developerName,
hph.is_history isHistory, hph.is_history isHistory,
info.financing_companies_name financingCompaniesName, info.financing_companies_name financingCompaniesName,
hfi.tr_create_time trCreateTime hfi.tr_create_time trCreateTime,
hygf_commercial.scale,
hygf_power_station_engineering_info.real_scale as realScale
FROM FROM
`hygf_peasant_household` hph `hygf_peasant_household` hph
LEFT JOIN hygf_financing_info info ON info.peasant_household_id = hph.sequence_nbr LEFT JOIN hygf_financing_info info ON info.peasant_household_id = hph.sequence_nbr
LEFT JOIN hygf_unit_info on hph.developer_code = hygf_unit_info.amos_company_code LEFT JOIN hygf_unit_info on hph.developer_code = hygf_unit_info.amos_company_code
left join hygf_financing_info hfi on hfi.peasant_household_id = hph.sequence_nbr left join hygf_financing_info hfi on hfi.peasant_household_id = hph.sequence_nbr
LEFT JOIN hygf_commercial on hygf_commercial.survey_information_id =hph.survey_information_id
LEFT JOIN hygf_work_order_power_station on hygf_work_order_power_station.peasant_household_id =hph.sequence_nbr
LEFT JOIN hygf_power_station_engineering_info on hygf_power_station_engineering_info.work_order_power_station_id=hygf_work_order_power_station.sequence_nbr
<where> <where>
hph.construction_state = '验收完成' hph.construction_state = '验收完成'
<if test="params.routhPathId != null and params.routhPathId != ''"> <if test="params.routhPathId != null and params.routhPathId != ''">
......
...@@ -98,14 +98,19 @@ ...@@ -98,14 +98,19 @@
and hygf_rectification_order.rectification_status = '已作废' and hygf_rectification_order.rectification_source = hygf_work_order_power_station.work_order_power_station_node and hygf_rectification_order.rectification_source in ('area','engineering','design')order by rec_date desc limit 1) as rollbackOrderId, and hygf_rectification_order.rectification_status = '已作废' and hygf_rectification_order.rectification_source = hygf_work_order_power_station.work_order_power_station_node and hygf_rectification_order.rectification_source in ('area','engineering','design')order by rec_date desc limit 1) as rollbackOrderId,
(select hygf_rectification_order.sequence_nbr from hygf_rectification_order (select hygf_rectification_order.sequence_nbr from hygf_rectification_order
where hygf_rectification_order.peasant_househole_id = hygf_work_order_power_station.peasant_household_id where hygf_rectification_order.peasant_househole_id = hygf_work_order_power_station.peasant_household_id
and hygf_rectification_order.rectification_status in ('待整改','待提交','整改中','整改待审核','待审核') and hygf_rectification_order.rectification_source in ('area','engineering','design') LIMIT 1) as rectificationNum and hygf_rectification_order.rectification_status in ('待整改','待提交','整改中','整改待审核','待审核') and hygf_rectification_order.rectification_source in ('area','engineering','design') LIMIT 1) as rectificationNum,
from hygf_work_order_power_station LEFT join hygf_work_order hygf_commercial.scale,
on hygf_work_order.sequence_nbr=hygf_work_order_power_station.work_order_id hygf_power_station_engineering_info.real_scale as realScale
from hygf_work_order_power_station
LEFT join hygf_work_order on hygf_work_order.sequence_nbr=hygf_work_order_power_station.work_order_id
LEFT JOIN hygf_peasant_household on hygf_peasant_household.sequence_nbr=hygf_work_order_power_station.peasant_household_id LEFT JOIN hygf_peasant_household on hygf_peasant_household.sequence_nbr=hygf_work_order_power_station.peasant_household_id
LEFT JOIN hygf_power_station_engineering_info on hygf_power_station_engineering_info.work_order_power_station_id=hygf_work_order_power_station.sequence_nbr LEFT JOIN hygf_power_station_engineering_info on hygf_power_station_engineering_info.work_order_power_station_id=hygf_work_order_power_station.sequence_nbr
LEFT JOIN ( LEFT JOIN (
SELECT work_order_power_station_id, MIN( operation_time ) as firstConstructionDate FROM hygf_construction_records WHERE operation_content = '编辑施工资料' GROUP BY work_order_power_station_id SELECT work_order_power_station_id, MIN( operation_time ) as firstConstructionDate FROM hygf_construction_records WHERE operation_content = '编辑施工资料' GROUP BY work_order_power_station_id
) newHcr ON newHcr.work_order_power_station_id = hygf_work_order_power_station.sequence_nbr ) newHcr ON newHcr.work_order_power_station_id = hygf_work_order_power_station.sequence_nbr
LEFT JOIN hygf_commercial on hygf_commercial.survey_information_id =hygf_peasant_household.survey_information_id
<where> <where>
<if test="dto.routhPathId != null and dto.routhPathId != ''"> <if test="dto.routhPathId != null and dto.routhPathId != ''">
and hygf_work_order_power_station.sequence_nbr = #{dto.routhPathId} and hygf_work_order_power_station.sequence_nbr = #{dto.routhPathId}
......
...@@ -256,10 +256,10 @@ public class WorkOrderController extends BaseController { ...@@ -256,10 +256,10 @@ public class WorkOrderController extends BaseController {
else { else {
e.setIsAudit("1"); e.setIsAudit("1");
} }
if(e.getPeasantHouseholdNo() != null) { // if(e.getPeasantHouseholdNo() != null) {
e.setScale(householdContractMapper.getHygfCommercialScale(e.getPeasantHouseholdNo())); // e.setScale(householdContractMapper.getHygfCommercialScale(e.getPeasantHouseholdNo()));
e.setRealScale(powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNo(e.getPeasantHouseholdNo())); // e.setRealScale(powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNo(e.getPeasantHouseholdNo()));
} // }
}); });
} }
......
...@@ -125,15 +125,15 @@ public class BasicGridAcceptanceServiceImpl extends BaseService<BasicGridAccepta ...@@ -125,15 +125,15 @@ public class BasicGridAcceptanceServiceImpl extends BaseService<BasicGridAccepta
pageNew.setTotal(page.getTotal()); pageNew.setTotal(page.getTotal());
pageNew.setSize(size); pageNew.setSize(size);
if (page.getList() != null && page.getList().size() > 0) { // if (page.getList() != null && page.getList().size() > 0) {
page.getList().forEach(e -> { // page.getList().forEach(e -> {
if (e.getPeasantHouseholdNo() != null) { // if (e.getPeasantHouseholdNo() != null) {
e.setScale(householdContractMapper.getHygfCommercialScale(e.getPeasantHouseholdNo())); // e.setScale(householdContractMapper.getHygfCommercialScale(e.getPeasantHouseholdNo()));
e.setRealScale(powerStationEngineeringInfoMapper // e.setRealScale(powerStationEngineeringInfoMapper
.getRealScaleByPeasantHouseholdNo(e.getPeasantHouseholdNo())); // .getRealScaleByPeasantHouseholdNo(e.getPeasantHouseholdNo()));
} // }
}); // });
} // }
pageNew.setRecords(page.getList()); pageNew.setRecords(page.getList());
return pageNew; return pageNew;
......
...@@ -123,12 +123,12 @@ public class FinancingInfoServiceImpl extends BaseService<FinancingInfoDto, Fina ...@@ -123,12 +123,12 @@ public class FinancingInfoServiceImpl extends BaseService<FinancingInfoDto, Fina
PageHelper.startPage((int) page.getCurrent(), (int) page.getSize()); PageHelper.startPage((int) page.getCurrent(), (int) page.getSize());
List<Map<String, Object>> list = financingInfoMapper.getStationFinancingInfoList(params, amosOrgCodes); List<Map<String, Object>> list = financingInfoMapper.getStationFinancingInfoList(params, amosOrgCodes);
list.forEach(e -> { list.forEach(e -> {
e.put("scale", householdContractMapper.getHygfCommercialScale((String) e.get("peasantHouseholdNo"))); // e.put("scale", householdContractMapper.getHygfCommercialScale((String) e.get("peasantHouseholdNo")));
if (e.containsKey("isHistory") && e.get("isHistory").toString().equals("1")){ // if (e.containsKey("isHistory") && e.get("isHistory").toString().equals("1")){
e.put("realScale", powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNoIsHisotry((String) e.get("peasantHouseholdNo"))); // e.put("realScale", powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNoIsHisotry((String) e.get("peasantHouseholdNo")));
}else { // }else {
e.put("realScale", powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNo((String) e.get("peasantHouseholdNo"))); // e.put("realScale", powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNo((String) e.get("peasantHouseholdNo")));
} // }
e.put("regionName",e.get("projectAddress").toString().split("/")[0]); e.put("regionName",e.get("projectAddress").toString().split("/")[0]);
e.put("trCreateTime", DateUtils.dateStringFormat(e.get("trCreateTime"))); e.put("trCreateTime", DateUtils.dateStringFormat(e.get("trCreateTime")));
if (null != e.get("instanceId") && e.get("instanceId").toString().contains(",")) { if (null != e.get("instanceId") && e.get("instanceId").toString().contains(",")) {
......
...@@ -689,15 +689,15 @@ public class WorkOrderServiceImpl extends BaseService<WorkOrderDto, WorkOrder, W ...@@ -689,15 +689,15 @@ public class WorkOrderServiceImpl extends BaseService<WorkOrderDto, WorkOrder, W
PageHelper.startPage(pageNum, pageSize); PageHelper.startPage(pageNum, pageSize);
List<WorkOrderPage> list = workOrderMapper.queryForwgpage(workOrder); List<WorkOrderPage> list = workOrderMapper.queryForwgpage(workOrder);
if(list != null && list.size() > 0) { // if(list != null && list.size() > 0) {
list.forEach(e -> { // list.forEach(e -> {
if(e.getPeasantHouseholdNo() != null) { // if(e.getPeasantHouseholdNo() != null) {
e.setScale(householdContractMapper.getHygfCommercialScale(e.getPeasantHouseholdNo())); // e.setScale(householdContractMapper.getHygfCommercialScale(e.getPeasantHouseholdNo()));
e.setRealScale(powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNo(e.getPeasantHouseholdNo())); // e.setRealScale(powerStationEngineeringInfoMapper.getRealScaleByPeasantHouseholdNo(e.getPeasantHouseholdNo()));
} // }
}); // });
//
} // }
PageInfo<WorkOrderPage> page = new PageInfo(list); PageInfo<WorkOrderPage> page = new PageInfo(list);
......
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