Compare commits
No commits in common. "5271ebe0bd6ad5c27ea452168b2bfc6403da1e69" and "f0256a5ce163303dec381fba276a96b1ec5a95f3" have entirely different histories.
5271ebe0bd
...
f0256a5ce1
|
|
@ -1,6 +1,5 @@
|
|||
package com.bonus.sgzb.base.api.domain;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.bonus.sgzb.common.core.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
|
|
@ -14,7 +13,7 @@ import java.util.List;
|
|||
@Data
|
||||
public class SltAgreementInfo {
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
private Long id;
|
||||
/**
|
||||
|
|
@ -22,15 +21,15 @@ public class SltAgreementInfo {
|
|||
*/
|
||||
private String ids;
|
||||
/**
|
||||
* 协议id
|
||||
*协议id
|
||||
*/
|
||||
private String agreementId;
|
||||
/**
|
||||
* 编码
|
||||
*编码
|
||||
*/
|
||||
private String maCode;
|
||||
/**
|
||||
* 当前在用量
|
||||
*当前在用量
|
||||
*/
|
||||
private Integer useNum;
|
||||
/**
|
||||
|
|
@ -38,59 +37,55 @@ public class SltAgreementInfo {
|
|||
*/
|
||||
private String typeModelName;
|
||||
/**
|
||||
* 机具规格id
|
||||
*机具规格id
|
||||
*/
|
||||
private String typeId;
|
||||
/**
|
||||
* 机具id
|
||||
*机具id
|
||||
*/
|
||||
private String maId;
|
||||
/**
|
||||
* 配件单价
|
||||
*配件单价
|
||||
*/
|
||||
private String partPrice;
|
||||
/**
|
||||
* 领料数量
|
||||
*领料数量
|
||||
*/
|
||||
// @Excel(name = "数量",sort = 4)
|
||||
@ExcelProperty(index = 4, value = "数量")
|
||||
@Excel(name = "数量")
|
||||
private String num;
|
||||
/**
|
||||
* 领料时间
|
||||
*领料时间
|
||||
*/
|
||||
// @Excel(name = "开始日期",sort = 6)
|
||||
@ExcelProperty(index = 6, value = "开始日期")
|
||||
@Excel(name = "开始日期")
|
||||
private String startTime;
|
||||
/**
|
||||
* 退料时间
|
||||
*退料时间
|
||||
*/
|
||||
// @Excel(name = "结算日期",sort = 7)
|
||||
@ExcelProperty(index = 7, value = "结算日期")
|
||||
@Excel(name = "结算日期")
|
||||
private String endTime;
|
||||
/**
|
||||
* 0在用1退回
|
||||
*0在用1退回
|
||||
*/
|
||||
private String status;
|
||||
/**
|
||||
* 领料id
|
||||
*领料id
|
||||
*/
|
||||
private String leaseId;
|
||||
/**
|
||||
* 配件数量
|
||||
*配件数量
|
||||
*/
|
||||
private String partNum;
|
||||
/**
|
||||
* 退料id
|
||||
*退料id
|
||||
*/
|
||||
private String backId;
|
||||
/**
|
||||
* 租赁单价
|
||||
*租赁单价
|
||||
*/
|
||||
// @Excel(name = "台班费单价(元/天)",sort = 5)
|
||||
@ExcelProperty(index = 5, value = "台班费单价(元/天)")
|
||||
@Excel(name = "台班费单价(元/天)")
|
||||
private String leasePrice;
|
||||
/**
|
||||
* 原值
|
||||
*原值
|
||||
*/
|
||||
private String buyPrice;
|
||||
/**
|
||||
|
|
@ -100,44 +95,37 @@ public class SltAgreementInfo {
|
|||
/**
|
||||
* 项目名称
|
||||
*/
|
||||
// @Excel(name = "领用单位")
|
||||
@ExcelProperty(value = "领用单位")
|
||||
@Excel(name = "领用单位")
|
||||
private String unitName;
|
||||
/**
|
||||
* 工程名称
|
||||
*/
|
||||
// @Excel(name = "工程名称")
|
||||
@ExcelProperty(value = "工程名称")
|
||||
@Excel(name = "工程名称")
|
||||
private String projectName;
|
||||
/**
|
||||
* 设备名称
|
||||
*/
|
||||
// @Excel(name = "设备名称",sort = 1)
|
||||
@ExcelProperty(index = 1, value = "设备名称")
|
||||
@Excel(name = "设备名称")
|
||||
private String typeName;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
// @Excel(name = "规格型号", sort = 2)
|
||||
@ExcelProperty(index = 2, value = "规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String modelName;
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
// @Excel(name = "单位", sort = 3)
|
||||
@ExcelProperty(index = 3, value = "单位")
|
||||
@Excel(name = "单位")
|
||||
private String nuitName;
|
||||
/**
|
||||
* 租赁天数
|
||||
*/
|
||||
// @Excel(name = "结算天数",sort = 8)
|
||||
@ExcelProperty(index = 8, value = "结算天数")
|
||||
@Excel(name = "结算天数")
|
||||
private String leaseDays;
|
||||
/**
|
||||
* 租赁费用
|
||||
*/
|
||||
// @Excel(name = "结算金额",sort = 9)
|
||||
@ExcelProperty(index = 9, value = "结算金额")
|
||||
@Excel(name = "结算金额")
|
||||
private String costs;
|
||||
/**
|
||||
* 配件总价
|
||||
|
|
@ -150,8 +138,7 @@ public class SltAgreementInfo {
|
|||
/**
|
||||
* 真实租赁费用
|
||||
*/
|
||||
// @Excel(name = "本月暂计金额",sort = 10)
|
||||
@ExcelProperty(index = 10, value = "本月暂计金额")
|
||||
@Excel(name = "本月暂计金额")
|
||||
private String realCosts;
|
||||
/**
|
||||
* 类型(0不收费,1收费)
|
||||
|
|
@ -174,8 +161,7 @@ public class SltAgreementInfo {
|
|||
/**
|
||||
* 费用承担方
|
||||
*/
|
||||
// @Excel(name = "费用承担方(01项目,03分包)")
|
||||
@ExcelProperty(value = "费用承担方(01项目,03分包)")
|
||||
@Excel(name = "费用承担方(01项目,03分包)")
|
||||
private String costBearingParty;
|
||||
/**
|
||||
* 调整天数
|
||||
|
|
@ -186,21 +172,19 @@ public class SltAgreementInfo {
|
|||
*/
|
||||
private BigDecimal realDays;
|
||||
/**
|
||||
* 是否结算(0 未结算 1已结算)
|
||||
* 是否结算(0 未结算 1已结算)
|
||||
*/
|
||||
private String isSlt;
|
||||
/**
|
||||
* 月份
|
||||
* 月份
|
||||
*/
|
||||
// @Excel(name = "月份")
|
||||
@ExcelProperty(value = "月份")
|
||||
private String month;
|
||||
/**
|
||||
* 月份
|
||||
* 月份
|
||||
*/
|
||||
private String nextMonth;
|
||||
/**
|
||||
* 委外维修费用
|
||||
* 委外维修费用
|
||||
*/
|
||||
private String outSourceCosts;
|
||||
private String beginTime;
|
||||
|
|
|
|||
|
|
@ -2,9 +2,6 @@ package com.bonus.sgzb.material.controller;
|
|||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.convert.Convert;
|
||||
import com.alibaba.excel.EasyExcel;
|
||||
import com.alibaba.excel.ExcelWriter;
|
||||
import com.alibaba.excel.write.metadata.WriteSheet;
|
||||
import com.bonus.sgzb.base.api.domain.SltAgreementApply;
|
||||
import com.bonus.sgzb.base.api.domain.SltAgreementDetails;
|
||||
import com.bonus.sgzb.base.api.domain.SltAgreementInfo;
|
||||
|
|
@ -18,14 +15,11 @@ import com.bonus.sgzb.common.log.enums.BusinessType;
|
|||
import com.bonus.sgzb.material.domain.*;
|
||||
import com.bonus.sgzb.material.service.SltAgreementInfoService;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
import java.net.URLEncoder;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
|
|
@ -69,58 +63,33 @@ public class SltAgreementInfoController extends BaseController {
|
|||
return AjaxResult.success(sltAgreementInfoService.getSltInfoMonth(list));
|
||||
}
|
||||
|
||||
/* @ApiOperation(value = "月结明细导出")
|
||||
@ApiOperation(value = "月结明细导出")
|
||||
@PostMapping("/exportSltInfoMonth")
|
||||
public void exportSltInfoMonth(HttpServletResponse response, @RequestBody List<AgreementInfo> list) {
|
||||
List<SltAgreementInfo> sltInfoMonth = sltAgreementInfoService.getSltInfoMonth(list);
|
||||
for (AgreementInfo agreementInfo : list) {
|
||||
for (SltAgreementInfo sltAgreementInfo : sltInfoMonth) {
|
||||
// 单个协议导出
|
||||
if (StringUtils.isNotBlank(agreementInfo.getCodeNum())) {
|
||||
String[] split = agreementInfo.getCodeNum().split(",");
|
||||
for (String s : split) {
|
||||
if (s.equals(sltAgreementInfo.getCodeNum().toString())) {
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
ExcelUtil<SltAgreementInfo> util = new ExcelUtil<SltAgreementInfo>(SltAgreementInfo.class);
|
||||
util.exportExcel(response, node, "月结明细导出数据");
|
||||
}
|
||||
String[] split = agreementInfo.getCodeNum().split(",");
|
||||
for (String s : split) {
|
||||
if (s.equals(sltAgreementInfo.getCodeNum().toString())) {
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
ExcelUtil<SltAgreementInfo> util = new ExcelUtil<SltAgreementInfo>(SltAgreementInfo.class);
|
||||
util.exportExcel(response, node, "月结明细导出数据");
|
||||
}
|
||||
} else {
|
||||
// 多个协议导出
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
ExcelUtil<SltAgreementInfo> util = new ExcelUtil<SltAgreementInfo>(SltAgreementInfo.class);
|
||||
util.exportExcel(response, node, "月结明细导出数据");
|
||||
}
|
||||
}
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
@ApiOperation(value = "月结明细导出")
|
||||
@PostMapping("/exportSltInfoMonth")
|
||||
public void exportSltInfoMonth(HttpServletResponse response, @RequestBody List<AgreementInfo> list) throws IOException {
|
||||
@ApiOperation(value = "批量月结明细导出")
|
||||
@PostMapping("/exportBatchSltInfoMonth")
|
||||
public void exportBatchSltInfoMonth(HttpServletResponse response, @RequestBody List<AgreementInfo> list) {
|
||||
List<SltAgreementInfo> sltInfoMonth = sltAgreementInfoService.getSltInfoMonth(list);
|
||||
List<List<MonthRepairInfo>> allLists = new ArrayList<>();
|
||||
for (AgreementInfo agreementInfo : list) {
|
||||
for (SltAgreementInfo sltAgreementInfo : sltInfoMonth) {
|
||||
// 单个协议导出
|
||||
if (StringUtils.isNotBlank(agreementInfo.getCodeNum())) {
|
||||
String[] split = agreementInfo.getCodeNum().split(",");
|
||||
for (String s : split) {
|
||||
if (s.equals(sltAgreementInfo.getCodeNum().toString())) {
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
List<MonthRepairInfo> leaseInfoList = Convert.toList(MonthRepairInfo.class, node);
|
||||
allLists.add(leaseInfoList);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// 多个协议导出
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
List<MonthRepairInfo> leaseInfoList = Convert.toList(MonthRepairInfo.class, node);
|
||||
allLists.add(leaseInfoList);
|
||||
}
|
||||
}
|
||||
for (SltAgreementInfo sltAgreementInfo : sltInfoMonth) {
|
||||
List<SltAgreementInfo> node = sltAgreementInfo.getNode();
|
||||
ExcelUtil<SltAgreementInfo> util = new ExcelUtil<SltAgreementInfo>(SltAgreementInfo.class);
|
||||
util.exportExcel(response, node, "月结明细导出数据");
|
||||
}
|
||||
exportMultipleLists(allLists, response);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -177,7 +146,7 @@ public class SltAgreementInfoController extends BaseController {
|
|||
*/
|
||||
@Log(title = "维修明细导出", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/exportRepair")
|
||||
public void exportRepair(HttpServletResponse response, @RequestBody List<AgreementInfo> list) {
|
||||
public void exportRepair(HttpServletResponse response, List<AgreementInfo> list) {
|
||||
List<SltAgreementInfo> explist = sltAgreementInfoService.getRepairList(list);
|
||||
List<RepairInfo> leaseInfoList = Convert.toList(RepairInfo.class, explist);
|
||||
ExcelUtil<RepairInfo> util = new ExcelUtil<RepairInfo>(RepairInfo.class);
|
||||
|
|
@ -189,7 +158,7 @@ public class SltAgreementInfoController extends BaseController {
|
|||
*/
|
||||
@Log(title = "报废明细导出", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/exportScrap")
|
||||
public void exportScrap(HttpServletResponse response, @RequestBody List<AgreementInfo> list) {
|
||||
public void exportScrap(HttpServletResponse response, List<AgreementInfo> list) {
|
||||
List<SltAgreementInfo> explist = sltAgreementInfoService.getScrapList(list);
|
||||
List<ScrapInfo> leaseInfoList = Convert.toList(ScrapInfo.class, explist);
|
||||
ExcelUtil<ScrapInfo> util = new ExcelUtil<ScrapInfo>(ScrapInfo.class);
|
||||
|
|
@ -201,7 +170,7 @@ public class SltAgreementInfoController extends BaseController {
|
|||
*/
|
||||
@Log(title = "预报废明细导出", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/exportPreScrap")
|
||||
public void exportPreScrap(HttpServletResponse response, @RequestBody List<AgreementInfo> list) {
|
||||
public void exportPreScrap(HttpServletResponse response, List<AgreementInfo> list) {
|
||||
List<SltAgreementInfo> explist = sltAgreementInfoService.getPreScrapList(list);
|
||||
List<preScrapInfo> leaseInfoList = Convert.toList(preScrapInfo.class, explist);
|
||||
ExcelUtil<preScrapInfo> util = new ExcelUtil<preScrapInfo>(preScrapInfo.class);
|
||||
|
|
@ -274,20 +243,5 @@ public class SltAgreementInfoController extends BaseController {
|
|||
return toAjax(sltAgreementInfoService.settlementReview(apply));
|
||||
}
|
||||
|
||||
public void exportMultipleLists(List<List<MonthRepairInfo>> lists, HttpServletResponse response) throws IOException {
|
||||
String fileName = "月结明细导出数据.xlsx";
|
||||
response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet");
|
||||
response.setHeader("Content-Disposition", "attachment; filename=" + URLEncoder.encode(fileName, "UTF-8"));
|
||||
|
||||
// 使用 EasyExcel 创建一个写入器
|
||||
ExcelWriter excelWriter = EasyExcel.write(response.getOutputStream(), MonthRepairInfo.class).build();
|
||||
|
||||
for (int i = 0; i < lists.size(); i++) {
|
||||
WriteSheet writeSheet = EasyExcel.writerSheet("Sheet" + (i + 1)).build();
|
||||
excelWriter.write(lists.get(i), writeSheet);
|
||||
}
|
||||
|
||||
// 关闭写入器
|
||||
excelWriter.finish();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,215 +0,0 @@
|
|||
package com.bonus.sgzb.material.domain;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.bonus.sgzb.base.api.domain.SltAgreementInfo;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author:liang.chao
|
||||
* @Date:2024/8/15 - 19:44
|
||||
*/
|
||||
public class MonthRepairInfo {
|
||||
/**
|
||||
* 领料数量
|
||||
*/
|
||||
// @Excel(name = "数量",sort = 4)
|
||||
@ExcelProperty(index = 4, value = "数量")
|
||||
private String num;
|
||||
|
||||
public String getNum() {
|
||||
return num;
|
||||
}
|
||||
|
||||
public void setNum(String num) {
|
||||
this.num = num;
|
||||
}
|
||||
|
||||
public String getStartTime() {
|
||||
return startTime;
|
||||
}
|
||||
|
||||
public void setStartTime(String startTime) {
|
||||
this.startTime = startTime;
|
||||
}
|
||||
|
||||
public String getEndTime() {
|
||||
return endTime;
|
||||
}
|
||||
|
||||
public void setEndTime(String endTime) {
|
||||
this.endTime = endTime;
|
||||
}
|
||||
|
||||
public String getLeasePrice() {
|
||||
return leasePrice;
|
||||
}
|
||||
|
||||
public void setLeasePrice(String leasePrice) {
|
||||
this.leasePrice = leasePrice;
|
||||
}
|
||||
|
||||
public String getUnitName() {
|
||||
return unitName;
|
||||
}
|
||||
|
||||
public void setUnitName(String unitName) {
|
||||
this.unitName = unitName;
|
||||
}
|
||||
|
||||
public String getProjectName() {
|
||||
return projectName;
|
||||
}
|
||||
|
||||
public void setProjectName(String projectName) {
|
||||
this.projectName = projectName;
|
||||
}
|
||||
|
||||
public String getTypeName() {
|
||||
return typeName;
|
||||
}
|
||||
|
||||
public void setTypeName(String typeName) {
|
||||
this.typeName = typeName;
|
||||
}
|
||||
|
||||
public String getModelName() {
|
||||
return modelName;
|
||||
}
|
||||
|
||||
public void setModelName(String modelName) {
|
||||
this.modelName = modelName;
|
||||
}
|
||||
|
||||
public String getNuitName() {
|
||||
return nuitName;
|
||||
}
|
||||
|
||||
public void setNuitName(String nuitName) {
|
||||
this.nuitName = nuitName;
|
||||
}
|
||||
|
||||
public String getLeaseDays() {
|
||||
return leaseDays;
|
||||
}
|
||||
|
||||
public void setLeaseDays(String leaseDays) {
|
||||
this.leaseDays = leaseDays;
|
||||
}
|
||||
|
||||
public String getCosts() {
|
||||
return costs;
|
||||
}
|
||||
|
||||
public void setCosts(String costs) {
|
||||
this.costs = costs;
|
||||
}
|
||||
|
||||
public String getRealCosts() {
|
||||
return realCosts;
|
||||
}
|
||||
|
||||
public void setRealCosts(String realCosts) {
|
||||
this.realCosts = realCosts;
|
||||
}
|
||||
|
||||
public String getCostBearingParty() {
|
||||
return costBearingParty;
|
||||
}
|
||||
|
||||
public void setCostBearingParty(String costBearingParty) {
|
||||
this.costBearingParty = costBearingParty;
|
||||
}
|
||||
|
||||
public String getMonth() {
|
||||
return month;
|
||||
}
|
||||
|
||||
public void setMonth(String month) {
|
||||
this.month = month;
|
||||
}
|
||||
|
||||
/**
|
||||
* 领料时间
|
||||
*/
|
||||
// @Excel(name = "开始日期",sort = 6)
|
||||
@ExcelProperty(index = 6, value = "开始日期")
|
||||
private String startTime;
|
||||
/**
|
||||
* 退料时间
|
||||
*/
|
||||
// @Excel(name = "结算日期",sort = 7)
|
||||
@ExcelProperty(index = 7, value = "结算日期")
|
||||
private String endTime;
|
||||
/**
|
||||
* 租赁单价
|
||||
*/
|
||||
// @Excel(name = "台班费单价(元/天)",sort = 5)
|
||||
@ExcelProperty(index = 5, value = "台班费单价(元/天)")
|
||||
private String leasePrice;
|
||||
|
||||
/**
|
||||
* 项目名称
|
||||
*/
|
||||
// @Excel(name = "领用单位")
|
||||
@ExcelProperty(index = 11,value = "领用单位")
|
||||
private String unitName;
|
||||
/**
|
||||
* 工程名称
|
||||
*/
|
||||
// @Excel(name = "工程名称")
|
||||
@ExcelProperty(index = 12,value = "工程名称")
|
||||
private String projectName;
|
||||
/**
|
||||
* 设备名称
|
||||
*/
|
||||
// @Excel(name = "设备名称",sort = 1)
|
||||
@ExcelProperty(index = 1, value = "设备名称")
|
||||
private String typeName;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
// @Excel(name = "规格型号", sort = 2)
|
||||
@ExcelProperty(index = 2, value = "规格型号")
|
||||
private String modelName;
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
// @Excel(name = "单位", sort = 3)
|
||||
@ExcelProperty(index = 3, value = "单位")
|
||||
private String nuitName;
|
||||
/**
|
||||
* 租赁天数
|
||||
*/
|
||||
// @Excel(name = "结算天数",sort = 8)
|
||||
@ExcelProperty(index = 8, value = "结算天数")
|
||||
private String leaseDays;
|
||||
/**
|
||||
* 租赁费用
|
||||
*/
|
||||
// @Excel(name = "结算金额",sort = 9)
|
||||
@ExcelProperty(index = 9, value = "结算金额")
|
||||
private String costs;
|
||||
|
||||
/**
|
||||
* 真实租赁费用
|
||||
*/
|
||||
// @Excel(name = "本月暂计金额",sort = 10)
|
||||
@ExcelProperty(index = 10, value = "本月暂计金额")
|
||||
private String realCosts;
|
||||
|
||||
/**
|
||||
* 费用承担方
|
||||
*/
|
||||
// @Excel(name = "费用承担方(01项目,03分包)")
|
||||
@ExcelProperty(value = "费用承担方(01项目,03分包)")
|
||||
private String costBearingParty;
|
||||
/**
|
||||
* 月份
|
||||
*/
|
||||
// @Excel(name = "月份")
|
||||
@ExcelProperty(value = "月份")
|
||||
private String month;
|
||||
}
|
||||
|
|
@ -49,35 +49,37 @@ public class RepairInfo {
|
|||
/**
|
||||
* 配件名称
|
||||
*/
|
||||
@Excel(name = "配件名称",sort = 4)
|
||||
@Excel(name = "配件名称")
|
||||
private String partName;
|
||||
/**
|
||||
*配件型号
|
||||
*/
|
||||
@Excel(name = "配件型号",sort = 5)
|
||||
@Excel(name = "配件型号")
|
||||
private String partModelName;
|
||||
/**
|
||||
* 项目名称
|
||||
*/
|
||||
@Excel(name = "结算单位名称")
|
||||
private String unitName;
|
||||
/**
|
||||
* 工程名称
|
||||
*/
|
||||
@Excel(name = "结算工程名称")
|
||||
private String projectName;
|
||||
/**
|
||||
* 设备名称
|
||||
*/
|
||||
@Excel(name = "设备名称",sort = 1)
|
||||
@Excel(name = "设备名称")
|
||||
private String typeName;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@Excel(name = "规格型号",sort = 2)
|
||||
@Excel(name = "规格型号")
|
||||
private String modelName;
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
@Excel(name = "计量单位",sort = 3)
|
||||
@Excel(name = "计量单位")
|
||||
private String nuitName;
|
||||
/**
|
||||
*租赁单价
|
||||
|
|
@ -86,12 +88,8 @@ public class RepairInfo {
|
|||
/**
|
||||
*领料数量
|
||||
*/
|
||||
@Excel(name = "数量")
|
||||
private String num;
|
||||
/**
|
||||
*领料数量
|
||||
*/
|
||||
@Excel(name = "配件数量",sort = 6)
|
||||
private String partNum;
|
||||
/**
|
||||
*领料时间
|
||||
*/
|
||||
|
|
@ -111,29 +109,27 @@ public class RepairInfo {
|
|||
/**
|
||||
* 应结算金额
|
||||
*/
|
||||
@Excel(name = "配件单价")
|
||||
private String costs;
|
||||
|
||||
@Excel(name = "配件单价",sort = 7)
|
||||
private String partPrice;
|
||||
/**
|
||||
* 实际结算金额
|
||||
*/
|
||||
// @Excel(name = "实际结算金额(元)")
|
||||
@Excel(name = "实际结算金额(元)")
|
||||
private String realCosts;
|
||||
/**
|
||||
* 配件总价
|
||||
*/
|
||||
@Excel(name = "配件总价(元)",sort = 8)
|
||||
@Excel(name = "配件总价(元)")
|
||||
private String partAllCosts;
|
||||
/**
|
||||
* 费用总价
|
||||
*/
|
||||
// @Excel(name = "费用总价")
|
||||
@Excel(name = "费用总价")
|
||||
private String allCosts;
|
||||
/**
|
||||
* 委外维修费用
|
||||
*/
|
||||
// @Excel(name = "委外维修费用")
|
||||
@Excel(name = "委外维修费用")
|
||||
private String outSourceCosts;
|
||||
/**
|
||||
* 实际结算金额
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ public class ScrapInfo {
|
|||
/**
|
||||
*设备编码
|
||||
*/
|
||||
@Excel(name = "设备编码",sort = 4)
|
||||
@Excel(name = "设备编码")
|
||||
private String maCode;
|
||||
|
||||
/**
|
||||
|
|
@ -46,7 +46,7 @@ public class ScrapInfo {
|
|||
/**
|
||||
*原值
|
||||
*/
|
||||
@Excel(name = "赔偿单价",sort = 6)
|
||||
@Excel(name = "赔偿单价")
|
||||
private String buyPrice;
|
||||
/**
|
||||
*
|
||||
|
|
@ -55,25 +55,27 @@ public class ScrapInfo {
|
|||
/**
|
||||
* 项目名称
|
||||
*/
|
||||
@Excel(name = "结算单位名称")
|
||||
private String unitName;
|
||||
/**
|
||||
* 工程名称
|
||||
*/
|
||||
@Excel(name = "结算工程名称")
|
||||
private String projectName;
|
||||
/**
|
||||
* 设备名称
|
||||
*/
|
||||
@Excel(name = "设备名称",sort = 1)
|
||||
@Excel(name = "设备名称")
|
||||
private String typeName;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@Excel(name = "规格型号",sort = 2)
|
||||
@Excel(name = "规格型号")
|
||||
private String modelName;
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
@Excel(name = "计量单位",sort = 3)
|
||||
@Excel(name = "计量单位")
|
||||
private String nuitName;
|
||||
/**
|
||||
*租赁单价
|
||||
|
|
@ -82,7 +84,7 @@ public class ScrapInfo {
|
|||
/**
|
||||
*领料数量
|
||||
*/
|
||||
@Excel(name = "报废数量",sort = 5)
|
||||
@Excel(name = "报废数量")
|
||||
private String num;
|
||||
/**
|
||||
*领料时间
|
||||
|
|
@ -103,7 +105,7 @@ public class ScrapInfo {
|
|||
/**
|
||||
* 租赁费用
|
||||
*/
|
||||
@Excel(name = "赔偿金额",sort = 7)
|
||||
@Excel(name = "报废费用")
|
||||
private String costs;
|
||||
/**
|
||||
* 类型(0不收费,1收费)
|
||||
|
|
|
|||
|
|
@ -28,13 +28,12 @@ public class preScrapInfo {
|
|||
/**
|
||||
*设备编码
|
||||
*/
|
||||
@Excel(name = "设备编码",sort = 4)
|
||||
@Excel(name = "设备编码")
|
||||
private String maCode;
|
||||
|
||||
/**
|
||||
*0在用1退回
|
||||
*/
|
||||
@Excel(name = "状态",defaultValue = "待报废",sort = 100)
|
||||
private String status;
|
||||
/**
|
||||
*领料id
|
||||
|
|
@ -63,28 +62,26 @@ public class preScrapInfo {
|
|||
/**
|
||||
* 设备名称
|
||||
*/
|
||||
@Excel(name = "设备名称",sort = 1)
|
||||
@Excel(name = "设备名称")
|
||||
private String typeName;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@Excel(name = "规格型号",sort = 2)
|
||||
@Excel(name = "规格型号")
|
||||
private String modelName;
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
@Excel(name = "计量单位",sort = 3)
|
||||
@Excel(name = "计量单位")
|
||||
private String nuitName;
|
||||
/**
|
||||
*租赁单价
|
||||
*/
|
||||
private String leasePrice;
|
||||
|
||||
|
||||
/**
|
||||
*领料数量
|
||||
*/
|
||||
@Excel(name = "报废数量",sort = 5)
|
||||
@Excel(name = "报废数量")
|
||||
private String num;
|
||||
/**
|
||||
*领料时间
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
package com.bonus.sgzb.material.service.impl;
|
||||
|
||||
import com.alibaba.excel.EasyExcel;
|
||||
import com.alibaba.excel.write.metadata.WriteSheet;
|
||||
import com.bonus.sgzb.base.api.domain.SltAgreementApply;
|
||||
import com.bonus.sgzb.base.api.domain.SltAgreementInfo;
|
||||
import com.bonus.sgzb.base.api.domain.SltAgreementRelation;
|
||||
|
|
@ -13,6 +11,8 @@ import com.bonus.sgzb.common.core.utils.DateUtils;
|
|||
import com.bonus.sgzb.common.core.web.domain.AjaxResult;
|
||||
import com.bonus.sgzb.common.security.utils.SecurityUtils;
|
||||
import com.bonus.sgzb.material.domain.AgreementInfo;
|
||||
import com.bonus.sgzb.material.domain.ProjectMonthCosts;
|
||||
import com.bonus.sgzb.material.domain.ProjectMonthDetail;
|
||||
import com.bonus.sgzb.material.domain.TmTask;
|
||||
|
||||
import com.bonus.sgzb.material.mapper.CalMonthlyMapper;
|
||||
|
|
@ -20,12 +20,11 @@ import com.bonus.sgzb.material.mapper.SltAgreementInfoMapper;
|
|||
import com.bonus.sgzb.material.service.SltAgreementInfoService;
|
||||
import com.bonus.sgzb.material.vo.GlobalContants;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.apache.poi.ss.formula.functions.T;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
import java.math.BigDecimal;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
|
|
@ -482,7 +481,7 @@ public class SltAgreementInfoServiceImpl implements SltAgreementInfoService {
|
|||
agreementInfo.setCostBearingParty(sltAgreementInfo.getCostBearingParty());
|
||||
agreementInfo.setStartTime(sltAgreementInfo.getBeginTime());
|
||||
agreementInfo.setIds(sltAgreementInfo.getIds());
|
||||
sltAgreementInfo.setMonth(DateTimeHelper.getNowMonth(DateTimeHelper.parse(bean.getEndTime(), "yyyy-MM")));
|
||||
sltAgreementInfo.setMonth(bean.getMonth());
|
||||
sltAgreementInfo.setCodeNum(num++);
|
||||
agreementInfo.setEndTime(sltAgreementInfo.getOffTime());
|
||||
List<SltAgreementInfo> leaseListOneMonth = getLeaseListOneMonth(agreementInfo, sltAgreementInfo);
|
||||
|
|
|
|||
Loading…
Reference in New Issue