Browse Source

Merge pull request 'master' (#55) from master into V3

Reviewed-on: http://git.lrdaiot.cn:9000/thing/thing_api/pulls/55
qingyuan_dev_new
解作文 1 year ago
parent
commit
649a54a571
  1. 4
      modules/report-analysis/src/main/java/com/thing/carbon/peakvalley/service/impl/PeakValleyServiceImpl.java
  2. 6
      modules/thing/src/main/java/com/thing/device/source/controller/IotThingSourceController.java

4
modules/report-analysis/src/main/java/com/thing/carbon/peakvalley/service/impl/PeakValleyServiceImpl.java

@ -595,11 +595,11 @@ public class PeakValleyServiceImpl implements PeakValleyService {
}else if(temp.getAttrCode().contains("valley")){ }else if(temp.getAttrCode().contains("valley")){
temp.setAttrName(priceInfo.getValleyPriceBean()==null?"谷用"+priceInfo.getBaseName():priceInfo.getValleyPriceBean().getAttrName()); temp.setAttrName(priceInfo.getValleyPriceBean()==null?"谷用"+priceInfo.getBaseName():priceInfo.getValleyPriceBean().getAttrName());
temp.setUintPrice(priceInfo.getValleyPriceBean()==null?BigDecimal.ZERO:priceInfo.getValleyPriceBean().getPrice()); temp.setUintPrice(priceInfo.getValleyPriceBean()==null?BigDecimal.ZERO:priceInfo.getValleyPriceBean().getPrice());
temp.setSort(3);
temp.setSort(4);
}else if(temp.getAttrCode().contains("normal")){ }else if(temp.getAttrCode().contains("normal")){
temp.setAttrName(priceInfo.getNormalPriceBean()==null?"平用"+priceInfo.getBaseName():priceInfo.getNormalPriceBean().getAttrName()); temp.setAttrName(priceInfo.getNormalPriceBean()==null?"平用"+priceInfo.getBaseName():priceInfo.getNormalPriceBean().getAttrName());
temp.setUintPrice(priceInfo.getNormalPriceBean()==null?BigDecimal.ZERO:priceInfo.getNormalPriceBean().getPrice()); temp.setUintPrice(priceInfo.getNormalPriceBean()==null?BigDecimal.ZERO:priceInfo.getNormalPriceBean().getPrice());
temp.setSort(4);
temp.setSort(3);
}else { }else {
temp.setAttrName(priceInfo.getBaseName()); temp.setAttrName(priceInfo.getBaseName());
temp.setUintPrice(priceInfo.getBasePrice()); temp.setUintPrice(priceInfo.getBasePrice());

6
modules/thing/src/main/java/com/thing/device/source/controller/IotThingSourceController.java

@ -148,6 +148,12 @@ public class IotThingSourceController {
return new Result<List<String>>().ok(iotThingSourceService.attrGroup()); return new Result<List<String>>().ok(iotThingSourceService.attrGroup());
} }
@GetMapping("maxSort")
@Operation(summary="最大序号")
public Result<Long> getMaxSort(@RequestParam String configType,@RequestParam Long fromId,@RequestParam Long rootId) {
return new Result<Long>().ok(iotThingSourceService.getMaxSort(configType,fromId,rootId));
}
@PostMapping("attrGroupList") @PostMapping("attrGroupList")
@Operation(summary="标签组") @Operation(summary="标签组")
public Result<List<IotThingSourceDTO>> attrGroupRootId(@RequestBody IotThingSourceReqDTO iotThingSourceDTO) { public Result<List<IotThingSourceDTO>> attrGroupRootId(@RequestBody IotThingSourceReqDTO iotThingSourceDTO) {

Loading…
Cancel
Save