Commit 8a332077 authored by tangwei's avatar tangwei

修改电站监控权限注解

parent 1f5cc0ff
......@@ -20,9 +20,9 @@ public interface JpCollectorMapper extends BaseMapper<JpCollector> {
List<Map<String,Object>> queryCollectorCountStatus(@Param("dto") JpStationDto reviewDto);
// @UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"sta.regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
List<JpCollectorDto> selectPageData(@Param("dto") JpCollectorDto reviewDto, Integer current, Integer size);
// @UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"sta.regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
int selectPageDataTota(@Param("dto") JpCollectorDto reviewDto);
}
......@@ -22,10 +22,10 @@ public interface JpInverterMapper extends BaseMapper<JpInverter> {
List<Map<String,Object>> queryInverterCountStatus(@Param("dto") JpStationDto reviewDto);
//@UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@DealerRestrict(field ={"amos_company_code","regional_companies_code","developer_user_id"},fieldConditions ={"in","in","in"} ,relationship="and")
@UserEmpower(field ={"sta.regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
// @DealerRestrict(field ={"amos_company_code","regional_companies_code","developer_user_id"},fieldConditions ={"in","in","in"} ,relationship="and")
List<JpInverterDtoNew> selectPageData(@Param("dto") JpInverterDto reviewDto, int current, int size);
//@UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"sta.regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
int selectPageDataTotal(@Param("dto") JpInverterDto reviewDto);
}
......@@ -25,33 +25,34 @@ public interface JpStationMapper extends BaseMapper<JpStation> {
List<Map<String,Object>> countState(@Param("dto") JpStationDto reviewDto);
List<Map<String,Double>> getPowerqx(String dateType);
@DealerRestrict(field ={"amos_company_code","regional_companies_code","developer_user_id"} ,fieldConditions ={"in","in","in"} ,relationship="and")
//@DealerRestrict(field ={"amos_company_code","regional_companies_code","developer_user_id"} ,fieldConditions ={"in","in","in"} ,relationship="and")
@UserEmpower(field ={"hygf_jp_station.regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
List<JpStation> getJpStation(@Param("dto") JpStationDto reviewDto);
List<JpStation> getJpStationList(@Param("dto") JpStationDto reviewDto);
// @UserEmpower(field ={"ORG_CODE"} ,fieldConditions ={"in"} ,relationship="")
@UserEmpower(field ={"ORG_CODE"} ,fieldConditions ={"in"} ,relationship="and",specific=false)
List<DropDown> getRegion();
//@UserEmpower(field ={"hygf_regional_companies.regional_companies_code","hygf_unit_info.amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"hygf_regional_companies.regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
List<DropDown> getDealer(@Param("regionalCompaniesCode") String regionalCompaniesCode);
@UserEmpower(field ={"regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
JpStationDto getCountJpStationdata(@Param("dto") JpStationDto reviewDto);
// @UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
List<Map<String,Object>> getcountState(@Param("dto") JpStationDto reviewDto);
//投产电站数
/// @UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
Map<String,Object>getcountStatetc(@Param("dto") JpStationDto reviewDto);
//建设建站数
// @UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
Map<String,Object>getcountStatejs(@Param("dto") JpStationDto reviewDto);
//接入中电站数
//@UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
Map<String,Object>getcountStatejr(@Param("dto") JpStationDto reviewDto);
// @UserEmpower(field ={"regional_companies_code","amos_company_code"} ,fieldConditions ={"in","in"} ,relationship="and")
@UserEmpower(field ={"regional_companies_code"} ,fieldConditions ={"in"} ,relationship="and")
Map<String,Object> getcount( @Param("dto") JpStationDto reviewDto);
@UserEmpower(field ={"hygf_jp_station.regional_companies_code"} ,dealerField={"amos_company_code","regional_companies_code","developer_user_id"} ,fieldConditions ={"in","in","in"} ,relationship="and")
......
......@@ -512,43 +512,38 @@ public class JpStationController extends BaseController {
@UserLimits
public ResponseModel<Page<Map<String, Object>>> getjpStationConservation(JpStationDto reviewDto) {
JpStationDto jpStation = jpStationMapper.getCountJpStationdata(reviewDto);
List<Map<String, Object>> date = new ArrayList<>();
Map<String, Object> map = new HashMap<>();
DecimalFormat format2 = new DecimalFormat("0.000");
//炭
map.put("name1", "实时功率(kW)");
map.put("name2", "组件总容量(MWp)");
map.put("value1", format2.format(jpStation.getRealTimePower()));
map.put("value1", jpStation.getRealTimePower()!=null?format2.format(jpStation.getRealTimePower()):0);
//硫
map.put("value2", format2.format(jpStation.getCapacity()));
map.put("value2", jpStation.getCapacity()!=null?format2.format(jpStation.getCapacity()):0);
Map<String, Object> map2 = new HashMap<>();
map2.put("name1", "当日电量(MWh)");
map2.put("name2", "当日收益(元)");
//炭
map2.put("value1", format2.format(jpStation.getDayGenerate()));
map2.put("value1", jpStation.getDayGenerate()!=null?format2.format(jpStation.getDayGenerate()):0);
//硫
map2.put("value2", format2.format(jpStation.getDayIncome()));
map2.put("value2", jpStation.getDayIncome()!=null?format2.format(jpStation.getDayIncome()):0);
Map<String, Object> map3 = new HashMap<>();
map3.put("name1", "当月电量(MWh)");
map3.put("name2", "当月收益(万元)");
//炭
map3.put("value1", format2.format(jpStation.getMonthGenerate()));
map3.put("value1", jpStation.getMonthGenerate()!=null?format2.format(jpStation.getMonthGenerate()):0);
//硫
map3.put("value2", format2.format(jpStation.getMonthIncome()));
map3.put("value2", jpStation.getMonthIncome()!=null?format2.format(jpStation.getMonthIncome()):0);
Map<String, Object> map4 = new HashMap<>();
map4.put("name1", "累计电量(MWh)");
map4.put("name2", "累计收益(万元)");
//炭
map4.put("value1", format2.format(jpStation.getAccumulatedPower()));
map4.put("value1", jpStation.getAccumulatedPower()!=null?format2.format(jpStation.getAccumulatedPower()):0);
//硫
map4.put("value2", format2.format(jpStation.getCumulativeIncome()));
map4.put("value2", jpStation.getCumulativeIncome()!=null?format2.format(jpStation.getCumulativeIncome()):0);
date.add(map);
date.add(map2);
......
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