Compare commits
No commits in common. "e429032a1478b5d7fd62b0253825af294c00d54a" and "ff08e941ee43cd75b4c9854d5b8bb3b955756f5a" have entirely different histories.
e429032a14
...
ff08e941ee
@ -1,8 +1,6 @@
|
|||||||
package com.jdc.jdcproject.controller;
|
package com.jdc.jdcproject.controller;
|
||||||
|
|
||||||
import com.jdc.jdcproject.entity.DicekeMiningloss;
|
|
||||||
import com.jdc.jdcproject.entity.VO.DicekeTotalMiningVo;
|
import com.jdc.jdcproject.entity.VO.DicekeTotalMiningVo;
|
||||||
import com.jdc.jdcproject.service.IDicekeMininglossService;
|
|
||||||
import com.jdc.jdcproject.service.IDicekeTotalMiningService;
|
import com.jdc.jdcproject.service.IDicekeTotalMiningService;
|
||||||
import com.jdc.jdcproject.utils.Result;
|
import com.jdc.jdcproject.utils.Result;
|
||||||
import io.swagger.v3.oas.annotations.Operation;
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
@ -25,46 +23,15 @@ import java.util.List;
|
|||||||
public class DicekeTotalMiningController {
|
public class DicekeTotalMiningController {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private IDicekeTotalMiningService dicekeTotalMiningService;
|
private IDicekeTotalMiningService iDicekeTotalMiningService;
|
||||||
@Autowired
|
|
||||||
private IDicekeMininglossService dicekeMininglossService;
|
|
||||||
|
|
||||||
@Operation(summary = "通过Month查询采剥量报表")
|
@Operation(summary = "通过Month查询采剥量报表")
|
||||||
@GetMapping("findTotalMiningByMonth")
|
@GetMapping("findTotalMiningByMonth")
|
||||||
public Result findTotalMiningByMonth(@RequestParam(required = false) LocalDate Month){
|
public Result findTotalMiningByMonth(@RequestParam(required = false) LocalDate Month){
|
||||||
List<DicekeTotalMiningVo> totalMiningVoList = dicekeTotalMiningService.getTotalMiningByMonth(Month);
|
List<DicekeTotalMiningVo> totalMiningVoList = iDicekeTotalMiningService.getTotalMiningByMonth(Month);
|
||||||
System.out.println(totalMiningVoList.toString());
|
System.out.println(totalMiningVoList.toString());
|
||||||
return Result.successResult().data("totalMiningVoList",totalMiningVoList);
|
return Result.successResult().data("totalMiningVoList",totalMiningVoList);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Operation(summary = "修改采剥量报表")
|
|
||||||
@PostMapping("updateTotalMining")
|
|
||||||
public Result updateTotalMining(@RequestBody DicekeTotalMiningVo dtm){
|
|
||||||
|
|
||||||
DicekeMiningloss dml = new DicekeMiningloss();
|
|
||||||
|
|
||||||
dml.setLossID(dtm.getTotalID());
|
|
||||||
dml.setPlateID(dtm.getPlateID());
|
|
||||||
dml.setShovelID(dtm.getShovelID());
|
|
||||||
dml.setBeizhu(dtm.getBeizhu());
|
|
||||||
dml.setStrippingTon(dtm.getStrippingTon());
|
|
||||||
dml.setStrippingAndTotalMiningTon(dtm.getStrippingAndTotalMiningTon());
|
|
||||||
dml.setMonth(dtm.getMonth());
|
|
||||||
|
|
||||||
boolean updateFlag = dicekeMininglossService.updateById(dml);
|
|
||||||
if (updateFlag){
|
|
||||||
return Result.successResult();
|
|
||||||
} else {
|
|
||||||
return Result.errorResult();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
*
|
|
||||||
* 删除直接删掉对应表的字段?
|
|
||||||
*
|
|
||||||
* */
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -53,15 +53,12 @@ public class DicekeMiningloss implements Serializable {
|
|||||||
@Schema(description = "配矿配矿量(吨)")
|
@Schema(description = "配矿配矿量(吨)")
|
||||||
private Double allocationTon;
|
private Double allocationTon;
|
||||||
|
|
||||||
@Schema(description = "备注")
|
|
||||||
private String beizhu;
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "DicekeMiningloss{" +
|
return "DicekeMiningloss{" +
|
||||||
"lossID='" + lossID + '\'' +
|
"lossID = " + lossID +
|
||||||
", plateID='" + plateID + '\'' +
|
", plateID = " + plateID +
|
||||||
", shovelID='" + shovelID + '\'' +
|
", shovelID = " + shovelID +
|
||||||
", month = " + month +
|
", month = " + month +
|
||||||
", strippingTon = " + strippingTon +
|
", strippingTon = " + strippingTon +
|
||||||
", strippingAndTotalMiningTon = " + strippingAndTotalMiningTon +
|
", strippingAndTotalMiningTon = " + strippingAndTotalMiningTon +
|
||||||
@ -69,7 +66,6 @@ public class DicekeMiningloss implements Serializable {
|
|||||||
", dilutionRate = " + dilutionRate +
|
", dilutionRate = " + dilutionRate +
|
||||||
", lossRate = " + lossRate +
|
", lossRate = " + lossRate +
|
||||||
", allocationTon = " + allocationTon +
|
", allocationTon = " + allocationTon +
|
||||||
", beizhu='" + beizhu + '\'' +
|
"}";
|
||||||
'}';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -10,15 +10,11 @@ public class DicekeTotalMiningVo {
|
|||||||
|
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
@Schema(description = "TotalID") /*传LossID,涉及修改或删除Loss表*/
|
@Schema(description = "平盘名称")
|
||||||
@TableId("TotalID")
|
private String plateRange;
|
||||||
private String TotalID;
|
|
||||||
|
|
||||||
@Schema(description = "外键关联平盘表")
|
@Schema(description = "铲号")
|
||||||
private String plateID;
|
private String shovelCode;
|
||||||
|
|
||||||
@Schema(description = "外键关联铲号表")
|
|
||||||
private String shovelID;
|
|
||||||
|
|
||||||
@Schema(description = "备注")
|
@Schema(description = "备注")
|
||||||
private String beizhu;
|
private String beizhu;
|
||||||
@ -38,18 +34,16 @@ public class DicekeTotalMiningVo {
|
|||||||
@Schema(description = "月份")
|
@Schema(description = "月份")
|
||||||
private LocalDate month;
|
private LocalDate month;
|
||||||
|
|
||||||
public DicekeTotalMiningVo(String totalID,
|
public DicekeTotalMiningVo(String plateRange,
|
||||||
String plateID,
|
String shovelCode,
|
||||||
String shovelID,
|
|
||||||
String beizhu,
|
String beizhu,
|
||||||
String UOM,
|
String UOM,
|
||||||
Double oreYield,
|
Double oreYield,
|
||||||
Double strippingTon,
|
Double strippingTon,
|
||||||
Double strippingAndTotalMiningTon,
|
Double strippingAndTotalMiningTon,
|
||||||
LocalDate month) {
|
LocalDate month) {
|
||||||
TotalID = totalID;
|
this.plateRange = plateRange;
|
||||||
this.plateID = plateID;
|
this.shovelCode = shovelCode;
|
||||||
this.shovelID = shovelID;
|
|
||||||
this.beizhu = beizhu;
|
this.beizhu = beizhu;
|
||||||
this.UOM = UOM;
|
this.UOM = UOM;
|
||||||
OreYield = oreYield;
|
OreYield = oreYield;
|
||||||
@ -61,9 +55,8 @@ public class DicekeTotalMiningVo {
|
|||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "DicekeTotalMiningVo{" +
|
return "DicekeTotalMiningVo{" +
|
||||||
"TotalID='" + TotalID + '\'' +
|
"plateRange='" + plateRange + '\'' +
|
||||||
", plateID='" + plateID + '\'' +
|
", shovelCode='" + shovelCode + '\'' +
|
||||||
", shovelID='" + shovelID + '\'' +
|
|
||||||
", beizhu='" + beizhu + '\'' +
|
", beizhu='" + beizhu + '\'' +
|
||||||
", UOM='" + UOM + '\'' +
|
", UOM='" + UOM + '\'' +
|
||||||
", OreYield=" + OreYield +
|
", OreYield=" + OreYield +
|
||||||
|
@ -3,7 +3,6 @@ package com.jdc.jdcproject.mapper;
|
|||||||
import com.jdc.jdcproject.entity.DicekeMiningloss;
|
import com.jdc.jdcproject.entity.DicekeMiningloss;
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.jdc.jdcproject.entity.VO.DicekeMininglossVo;
|
import com.jdc.jdcproject.entity.VO.DicekeMininglossVo;
|
||||||
import com.jdc.jdcproject.entity.VO.DicekeTotalMiningVo;
|
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
@ -27,7 +26,4 @@ public interface DicekeMininglossMapper extends BaseMapper<DicekeMiningloss> {
|
|||||||
|
|
||||||
|
|
||||||
List<DicekeMininglossVo> findLossByMonth(int monthV,int year);
|
List<DicekeMininglossVo> findLossByMonth(int monthV,int year);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,6 @@ public class DicekeTotalMiningServiceImpl extends ServiceImpl<DicekeMininglossMa
|
|||||||
List<DicekeTotalMiningVo> totalMiningList = new ArrayList<>();
|
List<DicekeTotalMiningVo> totalMiningList = new ArrayList<>();
|
||||||
//将mininglossListt赋值给totalMiningList
|
//将mininglossListt赋值给totalMiningList
|
||||||
for (DicekeMininglossVo dmlVoLItem : mininglossVoList){
|
for (DicekeMininglossVo dmlVoLItem : mininglossVoList){
|
||||||
String TotalID = dmlVoLItem.getLossID();
|
|
||||||
String plateR = dmlVoLItem.getPlateRange();
|
String plateR = dmlVoLItem.getPlateRange();
|
||||||
String shovelC = dmlVoLItem.getShovelCode();
|
String shovelC = dmlVoLItem.getShovelCode();
|
||||||
String beiZ = dmlVoLItem.getBeizhu();
|
String beiZ = dmlVoLItem.getBeizhu();
|
||||||
@ -41,7 +40,7 @@ public class DicekeTotalMiningServiceImpl extends ServiceImpl<DicekeMininglossMa
|
|||||||
Double strippingAndTMT = dmlVoLItem.getStrippingAndTotalMiningTon();
|
Double strippingAndTMT = dmlVoLItem.getStrippingAndTotalMiningTon();
|
||||||
LocalDate mon = dmlVoLItem.getMonth();
|
LocalDate mon = dmlVoLItem.getMonth();
|
||||||
|
|
||||||
DicekeTotalMiningVo dtmVoItem = new DicekeTotalMiningVo(TotalID,plateR,
|
DicekeTotalMiningVo dtmVoItem = new DicekeTotalMiningVo(plateR,
|
||||||
shovelC,beiZ,uom,oreY,strippingT,strippingAndTMT,mon);
|
shovelC,beiZ,uom,oreY,strippingT,strippingAndTMT,mon);
|
||||||
|
|
||||||
totalMiningList.add(dtmVoItem);
|
totalMiningList.add(dtmVoItem);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user