Commit c113fe8a authored by tangwei's avatar tangwei

增加场站列表

parent 96702983
......@@ -22,7 +22,7 @@ public class JpPersonStationDto extends BaseDto {
@ApiModelProperty(value = "人员id")
private Long personId;
private String personId;
@ApiModelProperty(value = "场站id")
private Long stationId;
......
package com.yeejoin.amos.boot.module.hygf.api.dto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.yeejoin.amos.boot.module.hygf.api.entity.JpPersonStation;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.yeejoin.amos.boot.biz.common.dto.BaseDto;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.Date;
import java.util.List;
/**
* 第三方场站
......@@ -116,4 +118,6 @@ public class JpStationDto extends BaseDto {
private Double yearIncome;
//地区
private String area;
List<JpPersonStation> statioId;
}
......@@ -26,7 +26,7 @@ public class JpPersonStation extends BaseEntity {
* 人员id
*/
@TableField("person_id")
private Long personId;
private String personId;
/**
* 场站id
......
......@@ -14,7 +14,18 @@
<if test="dto.address!=null">
and hygf_jp_station.address like concat(concat("%",#{dto.address}),"%")
</if>
<if test="dto.area!=null">
and hygf_jp_station.area like concat(concat("%",#{dto.area}),"%")
</if>
<if test="dto.statioId!=null">
and hygf_jp_station.third_station_id in
<foreach collection="dto.statioId" item="item" index="index" open="(" separator="," close=")">
#{item.stationId}
</foreach>
</if>
<if test="dto.thirdStationId!=null">
and hygf_jp_station.third_station_id =#{dto.thirdStationId}
</if>
</select>
......
package com.yeejoin.amos.boot.module.hygf.biz.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.yeejoin.amos.boot.module.hygf.api.dto.ReviewDto;
import com.yeejoin.amos.boot.module.hygf.api.entity.JpPersonStation;
import com.yeejoin.amos.boot.module.hygf.api.entity.PersonnelBusiness;
import com.yeejoin.amos.boot.module.hygf.api.mapper.JpPersonStationMapper;
import com.yeejoin.amos.boot.module.standard.api.entity.PublicAgencyUser;
import org.springframework.web.bind.annotation.RequestMapping;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.Api;
......@@ -31,7 +36,8 @@ public class JpStationController extends BaseController {
@Autowired
JpStationServiceImpl jpStationServiceImpl;
@Autowired
JpPersonStationMapper pPersonStationMapper;
/**
* 新增第三方场站
*
......@@ -98,6 +104,17 @@ public class JpStationController extends BaseController {
@ApiOperation(httpMethod = "GET",value = "场站列表", notes = "场站列表")
public ResponseModel<Page<JpStationDto>> queryForDealerReviewPage(@RequestParam(value = "current") int current, @RequestParam
(value = "size") int size, JpStationDto reviewDto) {
if(reviewDto.getThirdStationId()==null){
//获取当前人管理场站
LambdaQueryWrapper<JpPersonStation> qug=new LambdaQueryWrapper<>();
qug.eq(JpPersonStation::getPersonId,getUserInfo().getUserId());
List<JpPersonStation> pPersonStation=pPersonStationMapper.selectList(qug);
}
Page<JpStationDto> page=jpStationServiceImpl.queryForJpStationPage(current,size,reviewDto);
return ResponseHelper.buildResponse(page);
}
......
......@@ -54,7 +54,6 @@ public class TdHygfJpCollectorHistoryController extends BaseController {
@PutMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新户用光伏监盘采集器历史表", notes = "根据sequenceNbr更新户用光伏监盘采集器历史表")
public ResponseModel<TdHygfJpCollectorHistoryDto> updateBySequenceNbrTdHygfJpCollectorHistory(@RequestBody TdHygfJpCollectorHistoryDto model,@PathVariable(value = "sequenceNbr") Long sequenceNbr) {
model.setSequenceNbr(sequenceNbr);
return ResponseHelper.buildResponse(tdHygfJpCollectorHistoryServiceImpl.updateWithModel(model));
}
......
......@@ -54,7 +54,6 @@ public class TdHygfJpInverterHistoryController extends BaseController {
@PutMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新户用光伏监盘逆变器历史表", notes = "根据sequenceNbr更新户用光伏监盘逆变器历史表")
public ResponseModel<TdHygfJpInverterHistoryDto> updateBySequenceNbrTdHygfJpInverterHistory(@RequestBody TdHygfJpInverterHistoryDto model,@PathVariable(value = "sequenceNbr") Long sequenceNbr) {
model.setSequenceNbr(sequenceNbr);
return ResponseHelper.buildResponse(tdHygfJpInverterHistoryServiceImpl.updateWithModel(model));
}
......
......@@ -54,7 +54,6 @@ public class TdHygfJpInverterWarnController extends BaseController {
@PutMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新户用光伏监盘逆变器报警表", notes = "根据sequenceNbr更新户用光伏监盘逆变器报警表")
public ResponseModel<TdHygfJpInverterWarnDto> updateBySequenceNbrTdHygfJpInverterWarn(@RequestBody TdHygfJpInverterWarnDto model,@PathVariable(value = "sequenceNbr") Long sequenceNbr) {
model.setSequenceNbr(sequenceNbr);
return ResponseHelper.buildResponse(tdHygfJpInverterWarnServiceImpl.updateWithModel(model));
}
......
......@@ -54,7 +54,6 @@ public class TdHygfJpInvertorElecHistoryController extends BaseController {
@PutMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新户用光伏监盘逆变器电能历史表", notes = "根据sequenceNbr更新户用光伏监盘逆变器电能历史表")
public ResponseModel<TdHygfJpInvertorElecHistoryDto> updateBySequenceNbrTdHygfJpInvertorElecHistory(@RequestBody TdHygfJpInvertorElecHistoryDto model,@PathVariable(value = "sequenceNbr") Long sequenceNbr) {
model.setSequenceNbr(sequenceNbr);
return ResponseHelper.buildResponse(tdHygfJpInvertorElecHistoryServiceImpl.updateWithModel(model));
}
......
......@@ -54,7 +54,6 @@ public class TdHygfJpStationPowerHistoryController extends BaseController {
@PutMapping(value = "/{sequenceNbr}")
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新户用光伏监盘电站功率表", notes = "根据sequenceNbr更新户用光伏监盘电站功率表")
public ResponseModel<TdHygfJpStationPowerHistoryDto> updateBySequenceNbrTdHygfJpStationPowerHistory(@RequestBody TdHygfJpStationPowerHistoryDto model,@PathVariable(value = "sequenceNbr") Long sequenceNbr) {
model.setSequenceNbr(sequenceNbr);
return ResponseHelper.buildResponse(tdHygfJpStationPowerHistoryServiceImpl.updateWithModel(model));
}
......
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