Browse Source

1.客户基础资料增加修改并同步业务数据接口
2.决策分析下所有导出excel表格日期格式化
3.业务利润列表,合计,导出接口增加海运费字段
4.发票删除增加判断,有明细不允许删除
5.客户订舱,海运出口-订舱备注及SI备注同步问题修改
6.结算中心-代收列表增加修改状态接口
7.结算中心保存接口判断是付付费申请单据,金额计算逻辑修改
8.增加营业费用模块相关基础接口

纪新园 4 months ago
parent
commit
8b9b0bbe1b
32 changed files with 1348 additions and 50 deletions
  1. 6 2
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/invoices/entity/FinInvoices.java
  2. 34 0
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/dto/OperatingExpensesDTO.java
  3. 34 0
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/dto/OperatingExpensesItemDTO.java
  4. 169 0
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/entity/OperatingExpenses.java
  5. 130 0
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/entity/OperatingExpensesItem.java
  6. 36 0
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/vo/OperatingExpensesItemVO.java
  7. 36 0
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/vo/OperatingExpensesVO.java
  8. 1 1
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/statisticAnalysis/AgingAnalysisRD.java
  9. 18 0
      blade-service-api/blade-los-api/src/main/java/org/springblade/los/statisticAnalysis/FinanceProfitDtoList.java
  10. 126 0
      blade-service/blade-los/src/main/java/org/springblade/los/basic/corps/controller/BCorpsController.java
  11. 12 12
      blade-service/blade-los/src/main/java/org/springblade/los/business/sea/mapper/BillsMapper.xml
  12. 12 13
      blade-service/blade-los/src/main/java/org/springblade/los/business/sea/service/impl/BillsServiceImpl.java
  13. 1 1
      blade-service/blade-los/src/main/java/org/springblade/los/edi/dto/InttraSoDto.java
  14. 2 4
      blade-service/blade-los/src/main/java/org/springblade/los/excel/BoxNumberProfitExcel.java
  15. 9 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/invoices/controller/FinInvoicesController.java
  16. 2 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/invoices/service/IFinInvoicesService.java
  17. 41 5
      blade-service/blade-los/src/main/java/org/springblade/los/finance/invoices/service/impl/FinInvoicesServiceImpl.java
  18. 126 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/controller/OperatingExpensesController.java
  19. 126 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/controller/OperatingExpensesItemController.java
  20. 42 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesItemMapper.java
  21. 33 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesItemMapper.xml
  22. 42 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesMapper.java
  23. 40 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesMapper.xml
  24. 41 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/IOperatingExpensesItemService.java
  25. 41 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/IOperatingExpensesService.java
  26. 41 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/impl/OperatingExpensesItemServiceImpl.java
  27. 41 0
      blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/impl/OperatingExpensesServiceImpl.java
  28. 10 4
      blade-service/blade-los/src/main/java/org/springblade/los/finance/stl/service/impl/FinStlBillsServiceImpl.java
  29. 39 5
      blade-service/blade-los/src/main/java/org/springblade/los/statisticAnalysis/controller/FinanceStatisticsController.java
  30. 14 1
      blade-service/blade-los/src/main/java/org/springblade/los/statisticAnalysis/controller/StatisticAnalysisController.java
  31. 33 0
      blade-service/blade-los/src/main/java/org/springblade/los/statisticAnalysis/service/impl/StatisticAnalysisServiceImpl.java
  32. 10 2
      blade-service/blade-los/src/main/java/org/springblade/los/view/mapper/FinanceProfitMapper.xml

+ 6 - 2
blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/invoices/entity/FinInvoices.java

@@ -20,7 +20,6 @@ import com.baomidou.mybatisplus.annotation.FieldStrategy;
 import com.baomidou.mybatisplus.annotation.TableField;
 import com.baomidou.mybatisplus.annotation.TableLogic;
 import com.baomidou.mybatisplus.annotation.TableName;
-import com.fasterxml.jackson.annotation.JsonFormat;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
@@ -28,7 +27,6 @@ import org.springblade.los.business.files.entity.FilesCenter;
 import org.springblade.los.finance.fee.vo.FinAccBillsVO;
 import org.springblade.los.finance.stl.dto.FinStlBillsItemsReports;
 import org.springblade.system.entity.Dept;
-import org.springframework.format.annotation.DateTimeFormat;
 
 import java.io.Serializable;
 import java.math.BigDecimal;
@@ -688,6 +686,12 @@ public class FinInvoices implements Serializable {
 	private String bookingAgentEnName;
 
 	/**
+	 * 邮箱
+	 */
+	@ApiModelProperty(value = "邮箱")
+	private String email;
+
+	/**
 	 * 业务员
 	 */
 	@TableField(exist = false)

+ 34 - 0
blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/dto/OperatingExpensesDTO.java

@@ -0,0 +1,34 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.dto;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpenses;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 营业费用数据传输对象实体类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class OperatingExpensesDTO extends OperatingExpenses {
+	private static final long serialVersionUID = 1L;
+
+}

+ 34 - 0
blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/dto/OperatingExpensesItemDTO.java

@@ -0,0 +1,34 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.dto;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpensesItem;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 营业费用明细数据传输对象实体类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class OperatingExpensesItemDTO extends OperatingExpensesItem {
+	private static final long serialVersionUID = 1L;
+
+}

+ 169 - 0
blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/entity/OperatingExpenses.java

@@ -0,0 +1,169 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.entity;
+
+import java.math.BigDecimal;
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.time.LocalDateTime;
+import java.io.Serializable;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * 营业费用实体类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Data
+@TableName("los_operating_expenses")
+@ApiModel(value = "OperatingExpenses对象", description = "营业费用")
+public class OperatingExpenses implements Serializable {
+
+	private static final long serialVersionUID = 1L;
+
+	private Long id;
+	/**
+	* 创建人 Id
+	*/
+		@ApiModelProperty(value = "创建人 Id")
+		private Long createUser;
+	/**
+	* 创建人
+	*/
+		@ApiModelProperty(value = "创建人")
+		private String createUserName;
+	/**
+	* 创建时间
+	*/
+		@ApiModelProperty(value = "创建时间")
+		private LocalDateTime createTime;
+	/**
+	* 修改人 Id
+	*/
+		@ApiModelProperty(value = "修改人 Id")
+		private Long updateUser;
+	/**
+	* 修改人
+	*/
+		@ApiModelProperty(value = "修改人")
+		private String updateUserName;
+	/**
+	* 修改时间
+	*/
+		@ApiModelProperty(value = "修改时间")
+		private LocalDateTime updateTime;
+	/**
+	* 版本
+	*/
+		@ApiModelProperty(value = "版本")
+		private String version;
+	/**
+	* 审核状态
+	*/
+		@ApiModelProperty(value = "审核状态")
+		private String status;
+	/**
+	* 是否已删除(0 否 1是)
+	*/
+		@ApiModelProperty(value = "是否已删除(0 否 1是)")
+		private Integer isDeleted;
+	/**
+	* 备注
+	*/
+		@ApiModelProperty(value = "备注")
+		private String remarks;
+	/**
+	* 分公司
+	*/
+		@ApiModelProperty(value = "分公司")
+		private String branchName;
+	/**
+	* 分公司 Id
+	*/
+		@ApiModelProperty(value = "分公司 Id")
+		private String branchId;
+	/**
+	* 申请人
+	*/
+		@ApiModelProperty(value = "申请人")
+		private Long applicantId;
+	/**
+	* 申请人
+	*/
+		@ApiModelProperty(value = "申请人")
+		private String applicantName;
+	/**
+	* 申请日期
+	*/
+		@ApiModelProperty(value = "申请日期")
+		private LocalDateTime applicantDate;
+	/**
+	* 金额
+	*/
+		@ApiModelProperty(value = "金额")
+		private BigDecimal amount;
+	/**
+	* 银行户头
+	*/
+		@ApiModelProperty(value = "银行户头")
+		private String bankAccount;
+	/**
+	* 账号
+	*/
+		@ApiModelProperty(value = "账号")
+		private String account;
+	/**
+	* 开户行
+	*/
+		@ApiModelProperty(value = "开户行")
+		private String bankOfDeposit;
+	/**
+	* 单据编号
+	*/
+		@ApiModelProperty(value = "单据编号")
+		private String billNo;
+	/**
+	* 支付方式
+	*/
+		@ApiModelProperty(value = "支付方式")
+		private String paymentMethod;
+	/**
+	* 结算状态
+	*/
+		@ApiModelProperty(value = "结算状态")
+		private String settlementStatus;
+	/**
+	* 结算日期
+	*/
+		@ApiModelProperty(value = "结算日期")
+		private LocalDateTime settlementDate;
+	/**
+	* 结算人
+	*/
+		@ApiModelProperty(value = "结算人")
+		private Long settlementPersonId;
+	/**
+	* 结算人
+	*/
+		@ApiModelProperty(value = "结算人")
+		private String settlementPersonName;
+
+
+}

+ 130 - 0
blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/entity/OperatingExpensesItem.java

@@ -0,0 +1,130 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.entity;
+
+import java.math.BigDecimal;
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.time.LocalDateTime;
+import java.io.Serializable;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * 营业费用明细实体类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Data
+@TableName("los_operating_expenses_item")
+@ApiModel(value = "OperatingExpensesItem对象", description = "营业费用明细")
+public class OperatingExpensesItem implements Serializable {
+
+	private static final long serialVersionUID = 1L;
+
+	private Long id;
+	private Long pid;
+	/**
+	* 创建人 Id
+	*/
+		@ApiModelProperty(value = "创建人 Id")
+		private Long createUser;
+	/**
+	* 创建人
+	*/
+		@ApiModelProperty(value = "创建人")
+		private String createUserName;
+	/**
+	* 创建时间
+	*/
+		@ApiModelProperty(value = "创建时间")
+		private LocalDateTime createTime;
+	/**
+	* 修改人 Id
+	*/
+		@ApiModelProperty(value = "修改人 Id")
+		private Long updateUser;
+	/**
+	* 修改人
+	*/
+		@ApiModelProperty(value = "修改人")
+		private String updateUserName;
+	/**
+	* 修改时间
+	*/
+		@ApiModelProperty(value = "修改时间")
+		private LocalDateTime updateTime;
+	/**
+	* 版本
+	*/
+		@ApiModelProperty(value = "版本")
+		private String version;
+	/**
+	* 审核状态
+	*/
+		@ApiModelProperty(value = "审核状态")
+		private String status;
+	/**
+	* 是否已删除(0 否 1是)
+	*/
+		@ApiModelProperty(value = "是否已删除(0 否 1是)")
+		private Integer isDeleted;
+	/**
+	* 备注
+	*/
+		@ApiModelProperty(value = "备注")
+		private String remarks;
+	/**
+	* 分公司
+	*/
+		@ApiModelProperty(value = "分公司")
+		private String branchName;
+	/**
+	* 分公司 Id
+	*/
+		@ApiModelProperty(value = "分公司 Id")
+		private String branchId;
+	/**
+	* 摘要说明
+	*/
+		@ApiModelProperty(value = "摘要说明")
+		private String summaryDescription;
+	/**
+	* 费用归属人
+	*/
+		@ApiModelProperty(value = "费用归属人")
+		private String costOwner;
+	/**
+	* 数量
+	*/
+		@ApiModelProperty(value = "数量")
+		private BigDecimal quantity;
+	/**
+	* 单价
+	*/
+		@ApiModelProperty(value = "单价")
+		private BigDecimal price;
+	/**
+	* 金额
+	*/
+		@ApiModelProperty(value = "金额")
+		private BigDecimal amount;
+
+
+}

+ 36 - 0
blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/vo/OperatingExpensesItemVO.java

@@ -0,0 +1,36 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.vo;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpensesItem;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import io.swagger.annotations.ApiModel;
+
+/**
+ * 营业费用明细视图实体类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@ApiModel(value = "OperatingExpensesItemVO对象", description = "营业费用明细")
+public class OperatingExpensesItemVO extends OperatingExpensesItem {
+	private static final long serialVersionUID = 1L;
+
+}

+ 36 - 0
blade-service-api/blade-los-api/src/main/java/org/springblade/los/finance/operatingExpenses/vo/OperatingExpensesVO.java

@@ -0,0 +1,36 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.vo;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpenses;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import io.swagger.annotations.ApiModel;
+
+/**
+ * 营业费用视图实体类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@ApiModel(value = "OperatingExpensesVO对象", description = "营业费用")
+public class OperatingExpensesVO extends OperatingExpenses {
+	private static final long serialVersionUID = 1L;
+
+}

+ 1 - 1
blade-service-api/blade-los-api/src/main/java/org/springblade/los/statisticAnalysis/AgingAnalysisRD.java

@@ -50,7 +50,7 @@ public class AgingAnalysisRD {
 	@ExcelProperty(value = "180天以上")
 	private BigDecimal oneHundredAndEighty;
 	@ExcelProperty(value = "离港日")
-	private Date etd;
+	private String etd;
 	@ExcelProperty(value = "承运人")
 	private String carrier;
 	@ExcelProperty(value = "销售")

+ 18 - 0
blade-service-api/blade-los-api/src/main/java/org/springblade/los/statisticAnalysis/FinanceProfitDtoList.java

@@ -5,6 +5,7 @@ import com.alibaba.excel.annotation.ExcelProperty;
 import com.alibaba.excel.annotation.write.style.ColumnWidth;
 import com.alibaba.excel.annotation.write.style.ContentRowHeight;
 import com.alibaba.excel.annotation.write.style.HeadRowHeight;
+import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 
 import java.math.BigDecimal;
@@ -265,6 +266,23 @@ public class FinanceProfitDtoList {
 	@ExcelProperty(value = "实际单票利润")
 	private BigDecimal realAmountProfitLoc;
 
+
+	/**
+	 * 应收海运费
+	 */
+	@ExcelProperty(value = "应收海运费")
+	private BigDecimal oceanFreightDr;
+	/**
+	 * 应付海运费
+	 */
+	@ExcelProperty(value = "应付海运费")
+	private BigDecimal oceanFreightCr;
+	/**
+	 * 海运费利润
+	 */
+	@ExcelProperty(value = "海运费利润")
+	private BigDecimal oceanFreightProfit;
+
 	/**
 	 * 委托人
 	 */

+ 126 - 0
blade-service/blade-los/src/main/java/org/springblade/los/basic/corps/controller/BCorpsController.java

@@ -46,9 +46,15 @@ import org.springblade.los.basic.corps.service.IBCorpsTypeDefineService;
 import org.springblade.los.basic.corps.service.IBCorpsTypesService;
 import org.springblade.los.basic.corps.vo.BCorpsVO;
 import org.springblade.los.basic.utils.ExtendedData;
+import org.springblade.los.business.amends.entity.Amends;
+import org.springblade.los.business.amends.service.IAmendsService;
+import org.springblade.los.business.sea.entity.Bills;
+import org.springblade.los.business.sea.service.IBillsService;
 import org.springblade.los.excel.BCorpsExcel;
 import org.springblade.los.finance.fee.entity.FeeCenter;
+import org.springblade.los.finance.fee.entity.FinAccBills;
 import org.springblade.los.finance.fee.service.IFeeCenterService;
+import org.springblade.los.finance.fee.service.IFinAccBillsService;
 import org.springblade.system.feign.ISysClient;
 import org.springblade.system.user.entity.User;
 import org.springblade.system.user.feign.IUserClient;
@@ -85,6 +91,12 @@ public class BCorpsController extends BladeController {
 
 	private final IFeeCenterService feeCenterService;
 
+	private final IFinAccBillsService finAccBillsService;
+
+	private final IBillsService billsService;
+
+	private final IAmendsService amendsService;
+
 	private final IBCorpsAttnService corpsAttnService;
 
 	/**
@@ -528,4 +540,118 @@ public class BCorpsController extends BladeController {
 		return R.data(corps);
 	}
 
+
+	/**
+	 * 客户修改及同步业务数据
+	 */
+	@PostMapping("/updateSynchronize")
+	@RepeatSubmit
+	public R updateSynchronize(@Valid @RequestBody BCorps bCorps) throws Exception {
+		List<FeeCenter> feeCenterList = feeCenterService.list(new LambdaQueryWrapper<FeeCenter>()
+			.eq(FeeCenter::getTenantId, AuthUtil.getTenantId())
+			.eq(FeeCenter::getIsDeleted, 0)
+			.and(i -> i.eq(FeeCenter::getCorpId, bCorps.getId()).or()
+				.eq(FeeCenter::getBillCorpId, bCorps.getId()).or()
+				.eq(FeeCenter::getBookingAgentId, bCorps.getId()).or()
+				.eq(FeeCenter::getGenerationCorpId, bCorps.getId())));
+		if (!feeCenterList.isEmpty()){
+			for (FeeCenter item : feeCenterList){
+				if (bCorps.getId().equals(item.getCorpId())){
+					item.setCorpCnName(bCorps.getCnName());
+					item.setCorpEnName(bCorps.getEnName());
+					item.setShortName(bCorps.getShortName());
+				}
+				if (bCorps.getId().equals(item.getBillCorpId())){
+					item.setBillCorpCnName(bCorps.getCnName());
+					item.setBillCorpEnName(bCorps.getEnName());
+					item.setBillShortName(bCorps.getShortName());
+				}
+				if (bCorps.getId().equals(item.getBookingAgentId())){
+					item.setBookingAgentCnName(bCorps.getCnName());
+					item.setBookingAgentEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getGenerationCorpId())){
+					item.setGenerationCorpCnName(bCorps.getCnName());
+					item.setGenerationCorpEnName(bCorps.getEnName());
+				}
+			}
+			feeCenterService.updateBatchById(feeCenterList);
+		}
+		List<FinAccBills> finAccBillsList = finAccBillsService.list(new LambdaQueryWrapper<FinAccBills>()
+			.eq(FinAccBills::getTenantId, AuthUtil.getTenantId())
+			.eq(FinAccBills::getIsDeleted, 0)
+			.and(i -> i.eq(FinAccBills::getCorpId, bCorps.getId()).or()
+				.eq(FinAccBills::getBillCorpId, bCorps.getId()).or()
+				.eq(FinAccBills::getBookingAgentId, bCorps.getId()).or()
+				.eq(FinAccBills::getGenerationCorpId, bCorps.getId())));
+		if (!finAccBillsList.isEmpty()){
+			for (FinAccBills item : finAccBillsList){
+				if (bCorps.getId().equals(item.getCorpId())){
+					item.setCorpCnName(bCorps.getCnName());
+					item.setCorpEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getBillCorpId())){
+					item.setBillCorpCnName(bCorps.getCnName());
+					item.setBillCorpEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getBookingAgentId())){
+					item.setBookingAgentCnName(bCorps.getCnName());
+					item.setBookingAgentEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getGenerationCorpId())){
+					item.setGenerationCorpCnName(bCorps.getCnName());
+					item.setGenerationCorpEnName(bCorps.getEnName());
+				}
+			}
+			finAccBillsService.updateBatchById(finAccBillsList);
+		}
+		List<Bills> billsList = billsService.list(new LambdaQueryWrapper<Bills>()
+			.eq(Bills::getTenantId, AuthUtil.getTenantId())
+			.eq(Bills::getIsDeleted, 0)
+			.and(i -> i.eq(Bills::getCorpId, bCorps.getId()).or()
+				.eq(Bills::getCarrierId, bCorps.getId()).or()
+				.eq(Bills::getBookingAgentId, bCorps.getId()).or()
+				.eq(Bills::getForeignAgencyId, bCorps.getId())));
+		if (!billsList.isEmpty()){
+			for (Bills item : billsList){
+				if (bCorps.getId().equals(item.getCorpId())){
+					item.setCorpCnName(bCorps.getCnName());
+					item.setCorpEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getCarrierId())){
+					item.setCarrierCnName(bCorps.getCnName());
+					item.setCarrierEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getBookingAgentId())){
+					item.setBookingAgentCnName(bCorps.getCnName());
+					item.setBookingAgentEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getForeignAgencyId())){
+					item.setForeignAgencyCnName(bCorps.getCnName());
+					item.setForeignAgencyEnName(bCorps.getEnName());
+				}
+			}
+			billsService.updateBatchById(billsList);
+		}
+		List<Amends> amendsList = amendsService.list(new LambdaQueryWrapper<Amends>()
+			.eq(Amends::getTenantId, AuthUtil.getTenantId())
+			.eq(Amends::getIsDeleted, 0)
+			.and(i -> i.eq(Amends::getCorpId, bCorps.getId()).or()
+				.eq(Amends::getCarrierId, bCorps.getId())));
+		if (!amendsList.isEmpty()){
+			for (Amends item : amendsList){
+				if (bCorps.getId().equals(item.getCorpId())){
+					item.setCorpCnName(bCorps.getCnName());
+					item.setCorpEnName(bCorps.getEnName());
+				}
+				if (bCorps.getId().equals(item.getCarrierId())){
+					item.setCarrierCnName(bCorps.getCnName());
+					item.setCarrierEnName(bCorps.getEnName());
+				}
+			}
+			amendsService.updateBatchById(amendsList);
+		}
+		return bCorpsService.submit(bCorps);
+	}
+
 }

+ 12 - 12
blade-service/blade-los/src/main/java/org/springblade/los/business/sea/mapper/BillsMapper.xml

@@ -334,13 +334,13 @@
         <if test='acc.branchId != null and acc.branchId != ""'>
             and acc.branch_id = #{acc.branchId}
         </if>
-        <if test='acc.isStl != null and acc.isStl != "" and acc.isStl == "1"'>
-            and fee.amount = fee.unsettled_amount
-        </if>
-        <if test='acc.isStl == null or acc.isStl == "" and acc.isStl == "0"'>
-            and fee.amount != fee.unsettled_amount
-        </if>
         <if test='acc.type != null and acc.type != "" and acc.type == "1"'>
+            <if test='acc.isStl != null and acc.isStl != "" and acc.isStl == "1"'>
+                and fee.amount = fee.unsettled_amount
+            </if>
+            <if test='acc.isStl == null or acc.isStl == "" and acc.isStl == "0"'>
+                and fee.amount != fee.unsettled_amount
+            </if>
             <if test='acc.isChecked != null and acc.isChecked == "0"'>
                 and acc.is_checked in (0,1,2)
             </if>
@@ -972,13 +972,13 @@
         <if test='acc.branchId != null and acc.branchId != ""'>
             and acc.branch_id = #{acc.branchId}
         </if>
-        <if test='acc.isStl != null and acc.isStl != "" and acc.isStl == "1"'>
-            and fee.amount = fee.unsettled_amount
-        </if>
-        <if test='acc.isStl == null or acc.isStl == "" and acc.isStl == "0"'>
-            and fee.amount != fee.unsettled_amount
-        </if>
         <if test='acc.type != null and acc.type != "" and acc.type == "1"'>
+            <if test='acc.isStl != null and acc.isStl != "" and acc.isStl == "1"'>
+                and fee.amount = fee.unsettled_amount
+            </if>
+            <if test='acc.isStl == null or acc.isStl == "" and acc.isStl == "0"'>
+                and fee.amount != fee.unsettled_amount
+            </if>
             <if test='acc.isChecked != null and acc.isChecked == "0"'>
                 and acc.is_checked in (0,1,2)
             </if>

+ 12 - 13
blade-service/blade-los/src/main/java/org/springblade/los/business/sea/service/impl/BillsServiceImpl.java

@@ -262,9 +262,9 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 			}
 			// 初始创建为1
 			bills.setVersion("1");
-			if (ObjectUtils.isNotNull(bills.getPolId())){
+			if (ObjectUtils.isNotNull(bills.getPolId())) {
 				BPorts ports = ibPortsService.getById(bills.getPolId());
-				if (ports != null){
+				if (ports != null) {
 					bills.setPolCnName(ports.getCnName());
 					bills.setPolEnName(ports.getEnName());
 					bills.setPolCode(ports.getCode());
@@ -272,7 +272,7 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 			}
 			this.save(bills);
 		} else {
-			Bills dataSourceBill = baseMapper.selectOne(new LambdaQueryWrapper<Bills>().select(Bills::getId,Bills::getCorpId,Bills::getActualEta, Bills::getVersion).eq(Bills::getId, bills.getId()));
+			Bills dataSourceBill = baseMapper.selectOne(new LambdaQueryWrapper<Bills>().select(Bills::getId, Bills::getCorpId, Bills::getActualEta, Bills::getVersion).eq(Bills::getId, bills.getId()));
 			if (!Objects.equals(dataSourceBill.getVersion(), bills.getVersion())) {
 				return R.fail(601, "数据已被其他用户更新,请等待刷新后重试");
 			}
@@ -280,16 +280,16 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 			// 旧数据处理
 			int version = StringUtil.isBlank(dataSourceBill.getVersion()) ? 1 : Integer.parseInt(dataSourceBill.getVersion());
 			bills.setVersion(String.valueOf(version + 1));
-			if ("SI".equals(bills.getBusinessType())){
+			if ("SI".equals(bills.getBusinessType())) {
 				boolean corpId = ObjectUtils.isNotNull(bills.getCorpId()) && !bills.getCorpId().equals(dataSourceBill.getCorpId());
 				boolean ata = ObjectUtils.isNotNull(bills.getActualEta()) && !bills.getActualEta().equals(dataSourceBill.getActualEta());
-				if (corpId || ata){
+				if (corpId || ata) {
 					List<FinAccBills> finAccBillsList = finAccBillsService.list(new LambdaQueryWrapper<FinAccBills>()
-						.eq(FinAccBills::getBusinessBillId,bills.getId())
-						.eq(FinAccBills::getTenantId,AuthUtil.getTenantId())
-						.eq(FinAccBills::getIsDeleted,0));
-					if (!finAccBillsList.isEmpty()){
-						for (FinAccBills item : finAccBillsList){
+						.eq(FinAccBills::getBusinessBillId, bills.getId())
+						.eq(FinAccBills::getTenantId, AuthUtil.getTenantId())
+						.eq(FinAccBills::getIsDeleted, 0));
+					if (!finAccBillsList.isEmpty()) {
+						for (FinAccBills item : finAccBillsList) {
 							item.setBusinessDate(bills.getActualEta());
 							item.setBillDate(bills.getActualEta());
 							item.setBillCorpId(bills.getCorpId());
@@ -344,7 +344,6 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 							bills1.setCyReturnTime(bills.getCyReturnTime());
 							bills1.setCyTrailerTime(bills.getCyTrailerTime());
 							bills1.setSiRemarks(bills.getSiRemarks());
-							bills1.setCyRemarks(bills.getCyRemarks());
 							this.updateById(bills1);
 						}
 					}
@@ -4552,7 +4551,7 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 			TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
 			throw new RuntimeException("生成订单编号失败");
 		}
-		copyBills.setCyRemarks("");
+		copyBills.setSiRemarks("");
 		copyBills.setBusinessType("SE");
 		copyBills.setBusinessTypes("海运");
 		copyBills.setSeaType("E");
@@ -5047,7 +5046,7 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 	@Override
 	public R sendMessageBooking(Bills bills) {
 		Bills detail = baseMapper.selectById(bills.getId());
-		if (detail != null){
+		if (detail != null) {
 			if (ObjectUtils.isNotNull(detail.getCustomerServiceId())) {
 				R<User> res = userClient.userInfoById(detail.getCustomerServiceId());
 				if (res.isSuccess() && ObjectUtils.isNotNull(res.getData())) {

+ 1 - 1
blade-service/blade-los/src/main/java/org/springblade/los/edi/dto/InttraSoDto.java

@@ -864,7 +864,7 @@ public class InttraSoDto {
 		if(ObjectUtils.isNull(this.ediTypes)){
 			return false;
 		}else {
-			return ("HYCK".equals(this.ediTypes.getType()) && "中外运".equals(ediTypes.getCode()));
+			return ("HYJK".equals(this.ediTypes.getType()) && "中外运".equals(ediTypes.getCode()));
 		}
 	}
 	public Boolean ediTypeIsHYCK_ZIM_SI(){

+ 2 - 4
blade-service/blade-los/src/main/java/org/springblade/los/excel/BoxNumberProfitExcel.java

@@ -86,14 +86,12 @@ public class BoxNumberProfitExcel {
 	 * etd
 	 */
 	@ExcelProperty(value = "etd")
-	@DateTimeFormat("yyyy-MM-dd")
-	private Date etd;
+	private String etd;
 	/**
 	 * eta
 	 */
 	@ExcelProperty(value = "eta")
-	@DateTimeFormat("yyyy-MM-dd")
-	private Date eta;
+	private String eta;
 	/**
 	 * teu
 	 */

+ 9 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/invoices/controller/FinInvoicesController.java

@@ -394,5 +394,14 @@ public class FinInvoicesController extends BladeController {
 		return finInvoicesService.revokeGenerateFinStlBillsV1(billId);
 	}
 
+	/**
+	 * 已开已收状态修改
+	 */
+	@GetMapping("/openedReceived")
+	@RepeatSubmit
+	public R openedReceived(@RequestParam("billId") String billId) {
+		return finInvoicesService.openedReceived(billId);
+	}
+
 
 }

+ 2 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/invoices/service/IFinInvoicesService.java

@@ -135,4 +135,6 @@ public interface IFinInvoicesService extends IService<FinInvoices> {
 	R revokeGenerateFinStlBillsV1(String billId);
 
 	R add(FinInvoices finInvoices);
+
+	R openedReceived(String billId);
 }

+ 41 - 5
blade-service/blade-los/src/main/java/org/springblade/los/finance/invoices/service/impl/FinInvoicesServiceImpl.java

@@ -1230,7 +1230,7 @@ public class FinInvoicesServiceImpl extends ServiceImpl<FinInvoicesMapper, FinIn
 			.eq(FinInvoicesItems::getIsDeleted, 0)
 			.in(FinInvoicesItems::getPid, longList));
 		if (!finInvoicesItems.isEmpty()) {
-			finInvoicesItemsService.removeByIds(finInvoicesItems.stream().map(FinInvoicesItems::getId).collect(Collectors.toList()));
+			throw new RuntimeException("存在明细,删除失败");
 		}
 		this.removeByIds(longList);
 		return R.data("操作成功");
@@ -1724,9 +1724,9 @@ public class FinInvoicesServiceImpl extends ServiceImpl<FinInvoicesMapper, FinIn
 	/*	if (new BigDecimal("0.00").compareTo(finInvoices.getAmountLoc()) >= 0) {
 			throw new RuntimeException("开票失败:开票金额不能小于等于0");
 		}*/
-		if (invoiceAmount.compareTo(finInvoices.getAmountLoc()) > 0) {
+		/*if (invoiceAmount.compareTo(finInvoices.getAmountLoc()) > 0) {
 			throw new RuntimeException("开票失败:开票金额大于合计金额,保存失败");
-		}
+		}*/
 		detail.setStatus(3);
 		baseMapper.updateById(detail);
 		return R.data(detail);
@@ -1800,9 +1800,9 @@ public class FinInvoicesServiceImpl extends ServiceImpl<FinInvoicesMapper, FinIn
 		/*if (new BigDecimal("0.00").compareTo(finInvoices.getAmountLoc()) >= 0) {
 			throw new RuntimeException("开票失败:开票金额不能小于等于0");
 		}*/
-		if (invoiceAmount.compareTo(finInvoices.getAmountLoc()) > 0) {
+		/*if (invoiceAmount.compareTo(finInvoices.getAmountLoc()) > 0) {
 			throw new RuntimeException("开票失败:开票金额大于合计金额,保存失败");
-		}
+		}*/
 		detail.setStatus(3);
 		baseMapper.updateById(detail);
 		return R.data(detail);
@@ -2770,6 +2770,42 @@ public class FinInvoicesServiceImpl extends ServiceImpl<FinInvoicesMapper, FinIn
 		return R.data(finInvoices);
 	}
 
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public R openedReceived(String billId) {
+		if (ObjectUtils.isNull(billId)) {
+			throw new RuntimeException("缺少必要参数");
+		}
+		List<FinInvoices> finInvoicesList = baseMapper.selectList(new LambdaQueryWrapper<FinInvoices>()
+			.eq(FinInvoices::getIsDeleted, 0)
+			.eq(FinInvoices::getTenantId, AuthUtil.getTenantId())
+			.in(FinInvoices::getId, Func.toLongList(billId)));
+		if (finInvoicesList.isEmpty()) {
+			throw new RuntimeException("未查到销项发票单据");
+		}
+		List<FinInvoicesItems> finInvoicesItemsList = finInvoicesItemsService.list(new LambdaQueryWrapper<FinInvoicesItems>()
+			.eq(FinInvoicesItems::getIsDeleted, 0)
+			.eq(FinInvoicesItems::getTenantId, AuthUtil.getTenantId())
+			.in(FinInvoicesItems::getPid, finInvoicesList.stream().map(FinInvoices::getId).collect(Collectors.toList())));
+		if (!finInvoicesItemsList.isEmpty()) {
+			for (FinInvoicesItems item : finInvoicesItemsList) {
+				item.setUpdateUser(AuthUtil.getUserId());
+				item.setUpdateTime(new Date());
+				item.setUpdateUserName(AuthUtil.getUserName());
+				item.setGenerateInvoices("1");
+			}
+			finInvoicesItemsService.updateBatchById(finInvoicesItemsList);
+		}
+		for (FinInvoices item : finInvoicesList) {
+			item.setBillStatus("1");
+			item.setUpdateUser(AuthUtil.getUserId());
+			item.setUpdateTime(new Date());
+			item.setUpdateUserName(AuthUtil.getUserName());
+		}
+		this.updateBatchById(finInvoicesList);
+		return R.success("操作成功");
+	}
+
 	private FinInvoices countFeeItems(FinInvoices reconciliation, List<FinInvoicesItems> finStlBillsItemsList, String exrateType) {
 		BigDecimal amountCnyD = new BigDecimal("0.00");
 		BigDecimal amountUsdD = new BigDecimal("0.00");

+ 126 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/controller/OperatingExpensesController.java

@@ -0,0 +1,126 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.controller;
+
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
+import lombok.AllArgsConstructor;
+import javax.validation.Valid;
+
+import org.springblade.core.mp.support.Condition;
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.tool.api.R;
+import org.springblade.core.tool.utils.Func;
+import org.springframework.web.bind.annotation.*;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpenses;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesVO;
+import org.springblade.los.finance.operatingExpenses.service.IOperatingExpensesService;
+import org.springblade.core.boot.ctrl.BladeController;
+
+/**
+ * 营业费用 控制器
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@RestController
+@AllArgsConstructor
+@RequestMapping("/operatingexpenses")
+@Api(value = "营业费用", tags = "营业费用接口")
+public class OperatingExpensesController extends BladeController {
+
+	private final IOperatingExpensesService operatingExpensesService;
+
+	/**
+	 * 详情
+	 */
+	@GetMapping("/detail")
+	@ApiOperationSupport(order = 1)
+	@ApiOperation(value = "详情", notes = "传入operatingExpenses")
+	public R<OperatingExpenses> detail(OperatingExpenses operatingExpenses) {
+		OperatingExpenses detail = operatingExpensesService.getOne(Condition.getQueryWrapper(operatingExpenses));
+		return R.data(detail);
+	}
+
+	/**
+	 * 分页 营业费用
+	 */
+	@GetMapping("/list")
+	@ApiOperationSupport(order = 2)
+	@ApiOperation(value = "分页", notes = "传入operatingExpenses")
+	public R<IPage<OperatingExpenses>> list(OperatingExpenses operatingExpenses, Query query) {
+		IPage<OperatingExpenses> pages = operatingExpensesService.page(Condition.getPage(query), Condition.getQueryWrapper(operatingExpenses));
+		return R.data(pages);
+	}
+
+	/**
+	 * 自定义分页 营业费用
+	 */
+	@GetMapping("/page")
+	@ApiOperationSupport(order = 3)
+	@ApiOperation(value = "分页", notes = "传入operatingExpenses")
+	public R<IPage<OperatingExpensesVO>> page(OperatingExpensesVO operatingExpenses, Query query) {
+		IPage<OperatingExpensesVO> pages = operatingExpensesService.selectOperatingExpensesPage(Condition.getPage(query), operatingExpenses);
+		return R.data(pages);
+	}
+
+	/**
+	 * 新增 营业费用
+	 */
+	@PostMapping("/save")
+	@ApiOperationSupport(order = 4)
+	@ApiOperation(value = "新增", notes = "传入operatingExpenses")
+	public R save(@Valid @RequestBody OperatingExpenses operatingExpenses) {
+		return R.status(operatingExpensesService.save(operatingExpenses));
+	}
+
+	/**
+	 * 修改 营业费用
+	 */
+	@PostMapping("/update")
+	@ApiOperationSupport(order = 5)
+	@ApiOperation(value = "修改", notes = "传入operatingExpenses")
+	public R update(@Valid @RequestBody OperatingExpenses operatingExpenses) {
+		return R.status(operatingExpensesService.updateById(operatingExpenses));
+	}
+
+	/**
+	 * 新增或修改 营业费用
+	 */
+	@PostMapping("/submit")
+	@ApiOperationSupport(order = 6)
+	@ApiOperation(value = "新增或修改", notes = "传入operatingExpenses")
+	public R submit(@Valid @RequestBody OperatingExpenses operatingExpenses) {
+		return R.status(operatingExpensesService.saveOrUpdate(operatingExpenses));
+	}
+
+	
+	/**
+	 * 删除 营业费用
+	 */
+	@PostMapping("/remove")
+	@ApiOperationSupport(order = 8)
+	@ApiOperation(value = "删除", notes = "传入ids")
+	public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) {
+		return R.status(operatingExpensesService.removeByIds(Func.toLongList(ids)));
+	}
+
+	
+}

+ 126 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/controller/OperatingExpensesItemController.java

@@ -0,0 +1,126 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.controller;
+
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
+import lombok.AllArgsConstructor;
+import javax.validation.Valid;
+
+import org.springblade.core.mp.support.Condition;
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.tool.api.R;
+import org.springblade.core.tool.utils.Func;
+import org.springframework.web.bind.annotation.*;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpensesItem;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesItemVO;
+import org.springblade.los.finance.operatingExpenses.service.IOperatingExpensesItemService;
+import org.springblade.core.boot.ctrl.BladeController;
+
+/**
+ * 营业费用明细 控制器
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@RestController
+@AllArgsConstructor
+@RequestMapping("/operatingexpensesitem")
+@Api(value = "营业费用明细", tags = "营业费用明细接口")
+public class OperatingExpensesItemController extends BladeController {
+
+	private final IOperatingExpensesItemService operatingExpensesItemService;
+
+	/**
+	 * 详情
+	 */
+	@GetMapping("/detail")
+	@ApiOperationSupport(order = 1)
+	@ApiOperation(value = "详情", notes = "传入operatingExpensesItem")
+	public R<OperatingExpensesItem> detail(OperatingExpensesItem operatingExpensesItem) {
+		OperatingExpensesItem detail = operatingExpensesItemService.getOne(Condition.getQueryWrapper(operatingExpensesItem));
+		return R.data(detail);
+	}
+
+	/**
+	 * 分页 营业费用明细
+	 */
+	@GetMapping("/list")
+	@ApiOperationSupport(order = 2)
+	@ApiOperation(value = "分页", notes = "传入operatingExpensesItem")
+	public R<IPage<OperatingExpensesItem>> list(OperatingExpensesItem operatingExpensesItem, Query query) {
+		IPage<OperatingExpensesItem> pages = operatingExpensesItemService.page(Condition.getPage(query), Condition.getQueryWrapper(operatingExpensesItem));
+		return R.data(pages);
+	}
+
+	/**
+	 * 自定义分页 营业费用明细
+	 */
+	@GetMapping("/page")
+	@ApiOperationSupport(order = 3)
+	@ApiOperation(value = "分页", notes = "传入operatingExpensesItem")
+	public R<IPage<OperatingExpensesItemVO>> page(OperatingExpensesItemVO operatingExpensesItem, Query query) {
+		IPage<OperatingExpensesItemVO> pages = operatingExpensesItemService.selectOperatingExpensesItemPage(Condition.getPage(query), operatingExpensesItem);
+		return R.data(pages);
+	}
+
+	/**
+	 * 新增 营业费用明细
+	 */
+	@PostMapping("/save")
+	@ApiOperationSupport(order = 4)
+	@ApiOperation(value = "新增", notes = "传入operatingExpensesItem")
+	public R save(@Valid @RequestBody OperatingExpensesItem operatingExpensesItem) {
+		return R.status(operatingExpensesItemService.save(operatingExpensesItem));
+	}
+
+	/**
+	 * 修改 营业费用明细
+	 */
+	@PostMapping("/update")
+	@ApiOperationSupport(order = 5)
+	@ApiOperation(value = "修改", notes = "传入operatingExpensesItem")
+	public R update(@Valid @RequestBody OperatingExpensesItem operatingExpensesItem) {
+		return R.status(operatingExpensesItemService.updateById(operatingExpensesItem));
+	}
+
+	/**
+	 * 新增或修改 营业费用明细
+	 */
+	@PostMapping("/submit")
+	@ApiOperationSupport(order = 6)
+	@ApiOperation(value = "新增或修改", notes = "传入operatingExpensesItem")
+	public R submit(@Valid @RequestBody OperatingExpensesItem operatingExpensesItem) {
+		return R.status(operatingExpensesItemService.saveOrUpdate(operatingExpensesItem));
+	}
+
+	
+	/**
+	 * 删除 营业费用明细
+	 */
+	@PostMapping("/remove")
+	@ApiOperationSupport(order = 8)
+	@ApiOperation(value = "删除", notes = "传入ids")
+	public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) {
+		return R.status(operatingExpensesItemService.removeByIds(Func.toLongList(ids)));
+	}
+
+	
+}

+ 42 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesItemMapper.java

@@ -0,0 +1,42 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.mapper;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpensesItem;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesItemVO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import java.util.List;
+
+/**
+ * 营业费用明细 Mapper 接口
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+public interface OperatingExpensesItemMapper extends BaseMapper<OperatingExpensesItem> {
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param operatingExpensesItem
+	 * @return
+	 */
+	List<OperatingExpensesItemVO> selectOperatingExpensesItemPage(IPage page, OperatingExpensesItemVO operatingExpensesItem);
+
+}

+ 33 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesItemMapper.xml

@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.springblade.los.finance.operatingExpenses.mapper.OperatingExpensesItemMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="operatingExpensesItemResultMap" type="org.springblade.los.finance.operatingExpenses.entity.OperatingExpensesItem">
+        <id column="id" property="id"/>
+        <result column="pid" property="pid"/>
+        <result column="create_user" property="createUser"/>
+        <result column="create_user_name" property="createUserName"/>
+        <result column="create_time" property="createTime"/>
+        <result column="update_user" property="updateUser"/>
+        <result column="update_user_name" property="updateUserName"/>
+        <result column="update_time" property="updateTime"/>
+        <result column="version" property="version"/>
+        <result column="status" property="status"/>
+        <result column="is_deleted" property="isDeleted"/>
+        <result column="remarks" property="remarks"/>
+        <result column="branch_name" property="branchName"/>
+        <result column="branch_id" property="branchId"/>
+        <result column="summary_description" property="summaryDescription"/>
+        <result column="cost_owner" property="costOwner"/>
+        <result column="quantity" property="quantity"/>
+        <result column="price" property="price"/>
+        <result column="amount" property="amount"/>
+    </resultMap>
+
+
+    <select id="selectOperatingExpensesItemPage" resultMap="operatingExpensesItemResultMap">
+        select * from los_operating_expenses_item where is_deleted = 0
+    </select>
+
+</mapper>

+ 42 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesMapper.java

@@ -0,0 +1,42 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.mapper;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpenses;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesVO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import java.util.List;
+
+/**
+ * 营业费用 Mapper 接口
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+public interface OperatingExpensesMapper extends BaseMapper<OperatingExpenses> {
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param operatingExpenses
+	 * @return
+	 */
+	List<OperatingExpensesVO> selectOperatingExpensesPage(IPage page, OperatingExpensesVO operatingExpenses);
+
+}

+ 40 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/mapper/OperatingExpensesMapper.xml

@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.springblade.los.finance.operatingExpenses.mapper.OperatingExpensesMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="operatingExpensesResultMap" type="org.springblade.los.finance.operatingExpenses.entity.OperatingExpenses">
+        <id column="id" property="id"/>
+        <result column="create_user" property="createUser"/>
+        <result column="create_user_name" property="createUserName"/>
+        <result column="create_time" property="createTime"/>
+        <result column="update_user" property="updateUser"/>
+        <result column="update_user_name" property="updateUserName"/>
+        <result column="update_time" property="updateTime"/>
+        <result column="version" property="version"/>
+        <result column="status" property="status"/>
+        <result column="is_deleted" property="isDeleted"/>
+        <result column="remarks" property="remarks"/>
+        <result column="branch_name" property="branchName"/>
+        <result column="branch_id" property="branchId"/>
+        <result column="applicant_id" property="applicantId"/>
+        <result column="applicant_name" property="applicantName"/>
+        <result column="applicant_date" property="applicantDate"/>
+        <result column="amount" property="amount"/>
+        <result column="bank_account" property="bankAccount"/>
+        <result column="account" property="account"/>
+        <result column="bank_of_deposit" property="bankOfDeposit"/>
+        <result column="bill_no" property="billNo"/>
+        <result column="payment_method" property="paymentMethod"/>
+        <result column="settlement_status" property="settlementStatus"/>
+        <result column="settlement_date" property="settlementDate"/>
+        <result column="settlement_person_id" property="settlementPersonId"/>
+        <result column="settlement_person_name" property="settlementPersonName"/>
+    </resultMap>
+
+
+    <select id="selectOperatingExpensesPage" resultMap="operatingExpensesResultMap">
+        select * from los_operating_expenses where is_deleted = 0
+    </select>
+
+</mapper>

+ 41 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/IOperatingExpensesItemService.java

@@ -0,0 +1,41 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.service;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpensesItem;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesItemVO;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+/**
+ * 营业费用明细 服务类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+public interface IOperatingExpensesItemService extends IService<OperatingExpensesItem> {
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param operatingExpensesItem
+	 * @return
+	 */
+	IPage<OperatingExpensesItemVO> selectOperatingExpensesItemPage(IPage<OperatingExpensesItemVO> page, OperatingExpensesItemVO operatingExpensesItem);
+
+}

+ 41 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/IOperatingExpensesService.java

@@ -0,0 +1,41 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.service;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpenses;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesVO;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+/**
+ * 营业费用 服务类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+public interface IOperatingExpensesService extends IService<OperatingExpenses> {
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param operatingExpenses
+	 * @return
+	 */
+	IPage<OperatingExpensesVO> selectOperatingExpensesPage(IPage<OperatingExpensesVO> page, OperatingExpensesVO operatingExpenses);
+
+}

+ 41 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/impl/OperatingExpensesItemServiceImpl.java

@@ -0,0 +1,41 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.service.impl;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpensesItem;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesItemVO;
+import org.springblade.los.finance.operatingExpenses.mapper.OperatingExpensesItemMapper;
+import org.springblade.los.finance.operatingExpenses.service.IOperatingExpensesItemService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+/**
+ * 营业费用明细 服务实现类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Service
+public class OperatingExpensesItemServiceImpl extends ServiceImpl<OperatingExpensesItemMapper, OperatingExpensesItem> implements IOperatingExpensesItemService {
+
+	@Override
+	public IPage<OperatingExpensesItemVO> selectOperatingExpensesItemPage(IPage<OperatingExpensesItemVO> page, OperatingExpensesItemVO operatingExpensesItem) {
+		return page.setRecords(baseMapper.selectOperatingExpensesItemPage(page, operatingExpensesItem));
+	}
+
+}

+ 41 - 0
blade-service/blade-los/src/main/java/org/springblade/los/finance/operatingExpenses/service/impl/OperatingExpensesServiceImpl.java

@@ -0,0 +1,41 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.los.finance.operatingExpenses.service.impl;
+
+import org.springblade.los.finance.operatingExpenses.entity.OperatingExpenses;
+import org.springblade.los.finance.operatingExpenses.vo.OperatingExpensesVO;
+import org.springblade.los.finance.operatingExpenses.mapper.OperatingExpensesMapper;
+import org.springblade.los.finance.operatingExpenses.service.IOperatingExpensesService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+/**
+ * 营业费用 服务实现类
+ *
+ * @author BladeX
+ * @since 2025-08-28
+ */
+@Service
+public class OperatingExpensesServiceImpl extends ServiceImpl<OperatingExpensesMapper, OperatingExpenses> implements IOperatingExpensesService {
+
+	@Override
+	public IPage<OperatingExpensesVO> selectOperatingExpensesPage(IPage<OperatingExpensesVO> page, OperatingExpensesVO operatingExpenses) {
+		return page.setRecords(baseMapper.selectOperatingExpensesPage(page, operatingExpenses));
+	}
+
+}

+ 10 - 4
blade-service/blade-los/src/main/java/org/springblade/los/finance/stl/service/impl/FinStlBillsServiceImpl.java

@@ -310,14 +310,20 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 			finStlBills.setAmountCrUsd(amountCrUSD);
 			finStlBills.setAmountDrLoc(amountDrLoc);
 			finStlBills.setAmountCrLoc(amountCrLoc);
-			if ("C".equals(finStlBills.getDc())) {
+			if ("FFSQ".equals(finStlBills.getBusinessType())) {
 				finStlBills.setAmountSub(finStlBills.getAmountCr().subtract(finStlBills.getAmountDr()));
 				finStlBills.setAmountSubUsd(finStlBills.getAmountCrUsd().subtract(finStlBills.getAmountDrUsd()));
 				finStlBills.setAmountSubLoc(finStlBills.getAmountCrLoc().subtract(finStlBills.getAmountDrLoc()));
 			} else {
-				finStlBills.setAmountSub(finStlBills.getAmountDr().subtract(finStlBills.getAmountCr()));
-				finStlBills.setAmountSubUsd(finStlBills.getAmountDrUsd().subtract(finStlBills.getAmountCrUsd()));
-				finStlBills.setAmountSubLoc(finStlBills.getAmountDrLoc().subtract(finStlBills.getAmountCrLoc()));
+				if ("C".equals(finStlBills.getDc())){
+					finStlBills.setAmountSub(finStlBills.getAmountCr().subtract(finStlBills.getAmountDr()));
+					finStlBills.setAmountSubUsd(finStlBills.getAmountCrUsd().subtract(finStlBills.getAmountDrUsd()));
+					finStlBills.setAmountSubLoc(finStlBills.getAmountCrLoc().subtract(finStlBills.getAmountDrLoc()));
+				}else{
+					finStlBills.setAmountSub(finStlBills.getAmountDr().subtract(finStlBills.getAmountCr()));
+					finStlBills.setAmountSubUsd(finStlBills.getAmountDrUsd().subtract(finStlBills.getAmountCrUsd()));
+					finStlBills.setAmountSubLoc(finStlBills.getAmountDrLoc().subtract(finStlBills.getAmountCrLoc()));
+				}
 			}
 			//附件
 			List<Long> ids = finStlBills.getFinStlBillsItemsList().stream().map(FinStlBillsItems::getSrcIdInvoices).filter(Objects::nonNull).collect(Collectors.toList());

+ 39 - 5
blade-service/blade-los/src/main/java/org/springblade/los/statisticAnalysis/controller/FinanceStatisticsController.java

@@ -6,6 +6,7 @@ package org.springblade.los.statisticAnalysis.controller;
  */
 
 import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
 import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
@@ -23,6 +24,9 @@ import org.springframework.web.bind.annotation.RestController;
 
 import javax.servlet.http.HttpServletResponse;
 import java.math.BigDecimal;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.Date;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
@@ -62,8 +66,14 @@ public class FinanceStatisticsController {
 	 * 分页 决策分析列表合计
 	 */
 	@GetMapping("/financeProfitExport")
-	public void financeProfitExport(FinanceProfitDtoList financeProfit, HttpServletResponse response) {
+	public void financeProfitExport(FinanceProfitDtoList financeProfit, HttpServletResponse response) throws ParseException {
 		List<FinanceProfitDtoList> financeProfitList = statisticAnalysisService.financeProfitExport(financeProfit);
+		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+		for (FinanceProfitDtoList item : financeProfitList){
+			if (ObjectUtils.isNotNull(item.getStatisticsDate())){
+				item.setStatisticsDate(formatter.format(formatter.parse(item.getStatisticsDate())));
+			}
+		}
 		ExcelUtil.export(response, "业务利润", "业务利润", financeProfitList, FinanceProfitDtoList.class);
 	}
 
@@ -158,8 +168,14 @@ public class FinanceStatisticsController {
 	 * 应收(付)实收(付)明细表导出
 	 */
 	@GetMapping("/feeSummaryDetailExport")
-	public void feeSummaryDetailExportList(FeeSummaryQ feeSummaryQ, HttpServletResponse response) {
+	public void feeSummaryDetailExportList(FeeSummaryQ feeSummaryQ, HttpServletResponse response) throws ParseException {
 		List<FeeSummaryDetailRD> list = statisticAnalysisService.feeSummaryDetailExportList(feeSummaryQ);
+		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+		for (FeeSummaryDetailRD item : list){
+			if (ObjectUtils.isNotNull(item.getEtdDate())){
+				item.setEtdDate(formatter.format(formatter.parse(item.getEtdDate())));
+			}
+		}
 		if ("D".equals(feeSummaryQ.getDc())) {
 			ExcelUtil.export(response, "应收实收明细表", "应收实收明细表", list, FeeSummaryDetailRD.class);
 		} else {
@@ -204,8 +220,14 @@ public class FinanceStatisticsController {
 	 * 未收(付)明细表导出
 	 */
 	@GetMapping("/feeSummaryDetailExportNot")
-	public void feeSummaryDetailExportNot(FeeSummaryQ feeSummaryQ, HttpServletResponse response) {
+	public void feeSummaryDetailExportNot(FeeSummaryQ feeSummaryQ, HttpServletResponse response) throws ParseException {
 		List<FeeSummaryDetailNotRD> list = statisticAnalysisService.feeSummaryDetailExportNotList(feeSummaryQ);
+		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+		for (FeeSummaryDetailNotRD item : list){
+			if (ObjectUtils.isNotNull(item.getEtd())){
+				item.setEtd(formatter.format(formatter.parse(item.getEtd())));
+			}
+		}
 		if ("D".equals(feeSummaryQ.getDc())) {
 			ExcelUtil.export(response, "未收明细表", "未收明细表", list, FeeSummaryDetailNotRD.class);
 		} else {
@@ -225,8 +247,14 @@ public class FinanceStatisticsController {
 	 * 账龄分析导出
 	 */
 	@GetMapping("/agingAnalysisExport")
-	public void agingAnalysisExport(FeeSummaryQ feeSummaryQ, HttpServletResponse response) {
+	public void agingAnalysisExport(FeeSummaryQ feeSummaryQ, HttpServletResponse response) throws ParseException {
 		List<AgingAnalysisRD> list = statisticAnalysisService.agingAnalysisExport(feeSummaryQ);
+		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+		for (AgingAnalysisRD item : list){
+			if (ObjectUtils.isNotNull(item.getEtd())){
+				item.setEtd(formatter.format(formatter.parse(item.getEtd())));
+			}
+		}
 		if ("D".equals(feeSummaryQ.getDc())) {
 			ExcelUtil.export(response, "未收明细表", "未收明细表", list, AgingAnalysisRD.class);
 		} else {
@@ -271,8 +299,14 @@ public class FinanceStatisticsController {
 	 * 费用是否结算导出
 	 */
 	@GetMapping("/feeSettlementExport")
-	public void feeSettlementExport(FeeSettlementExcel feeSettlementExcel, HttpServletResponse response) {
+	public void feeSettlementExport(FeeSettlementExcel feeSettlementExcel, HttpServletResponse response) throws ParseException {
 		List<FeeSettlementExcel> list = statisticAnalysisService.feeSettlementList(feeSettlementExcel);
+		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+		for (FeeSettlementExcel item : list){
+			if (ObjectUtils.isNotNull(item.getBillDate())){
+				item.setBillDate(formatter.format(formatter.parse(item.getBillDate())));
+			}
+		}
 		ExcelUtil.export(response, "业务费用结算统计", "业务费用结算统计", list, FeeSettlementExcel.class);
 	}
 

+ 14 - 1
blade-service/blade-los/src/main/java/org/springblade/los/statisticAnalysis/controller/StatisticAnalysisController.java

@@ -1,6 +1,7 @@
 package org.springblade.los.statisticAnalysis.controller;
 
 import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
 import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
@@ -12,6 +13,7 @@ import org.springblade.core.tool.api.R;
 import org.springblade.los.excel.BoxNumberProfitExcel;
 import org.springblade.los.statisticAnalysis.BoxNumberProfitQ;
 import org.springblade.los.statisticAnalysis.DecisionAnalysis;
+import org.springblade.los.statisticAnalysis.FeeSettlementExcel;
 import org.springblade.los.statisticAnalysis.service.IStatisticAnalysisService;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
@@ -19,6 +21,8 @@ import org.springframework.web.bind.annotation.RequestParam;
 import org.springframework.web.bind.annotation.RestController;
 
 import javax.servlet.http.HttpServletResponse;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
 import java.util.List;
 import java.util.Map;
 
@@ -79,8 +83,17 @@ public class StatisticAnalysisController {
 	 * 分页 海运箱量利润统计导出
 	 */
 	@GetMapping("/boxNumberProfitStatisticsExport")
-	public void boxNumberProfitStatisticsExport(BoxNumberProfitQ boxNumberProfit, HttpServletResponse response) {
+	public void boxNumberProfitStatisticsExport(BoxNumberProfitQ boxNumberProfit, HttpServletResponse response) throws ParseException {
 		List<BoxNumberProfitExcel> list = statisticAnalysisService.boxNumberProfitStatisticsList(boxNumberProfit);
+		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+		for (BoxNumberProfitExcel item : list){
+			if (ObjectUtils.isNotNull(item.getEtd())){
+				item.setEtd(formatter.format(formatter.parse(item.getEtd())));
+			}
+			if (ObjectUtils.isNotNull(item.getEta())){
+				item.setEta(formatter.format(formatter.parse(item.getEta())));
+			}
+		}
 		ExcelUtil.export(response, "海运箱量利润统计", "海运箱量利润统计", list, BoxNumberProfitExcel.class);
 	}
 

+ 33 - 0
blade-service/blade-los/src/main/java/org/springblade/los/statisticAnalysis/service/impl/StatisticAnalysisServiceImpl.java

@@ -177,6 +177,16 @@ public class StatisticAnalysisServiceImpl implements IStatisticAnalysisService {
 						BigDecimal feeCentersUCRealLoc = feeCenterList.stream().filter(e -> i.getId().equals(e.getPid()) && "C".equals(e.getDc()))
 							.reduce(BigDecimal.ZERO, (x, y) -> x.add(y.getStlTtlAmount().multiply(y.getExrate())), BigDecimal::add)
 							.setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightDr = feeCenterList.stream()
+							.filter(e -> i.getId().equals(e.getPid()) && "HYF".equals(e.getFeeCode()) && "D".equals(e.getDc()))
+							.map(FeeCenter::getAmountLoc).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightCr = feeCenterList.stream()
+							.filter(e -> i.getId().equals(e.getPid()) && "HYF".equals(e.getFeeCode()) && "C".equals(e.getDc()))
+							.map(FeeCenter::getAmountLoc).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightProfit = oceanFreightDr.subtract(oceanFreightCr);
+						item.setOceanFreightCr(item.getOceanFreightCr().add(oceanFreightCr));
+						item.setOceanFreightDr(item.getOceanFreightDr().add(oceanFreightDr));
+						item.setOceanFreightProfit(item.getOceanFreightProfit().add(oceanFreightProfit));
 						item.setAmountCr(item.getAmountCr().add(feeCentersCC));
 						item.setRealAmountCr(item.getRealAmountCr().add(feeCentersCCReal));
 						item.setAmountCrUsd(item.getAmountCrUsd().add(feeCentersUC));
@@ -705,6 +715,16 @@ public class StatisticAnalysisServiceImpl implements IStatisticAnalysisService {
 						BigDecimal feeCentersUCRealLoc = feeCenterList.stream().filter(e -> i.getId().equals(e.getPid()) && "C".equals(e.getDc()))
 							.reduce(BigDecimal.ZERO, (x, y) -> x.add(y.getStlTtlAmount().multiply(y.getExrate())), BigDecimal::add)
 							.setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightDr = feeCenterList.stream()
+							.filter(e -> i.getId().equals(e.getPid()) && "HYF".equals(e.getFeeCode()) && "D".equals(e.getDc()))
+							.map(FeeCenter::getAmountLoc).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightCr = feeCenterList.stream()
+							.filter(e -> i.getId().equals(e.getPid()) && "HYF".equals(e.getFeeCode()) && "C".equals(e.getDc()))
+							.map(FeeCenter::getAmountLoc).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightProfit = oceanFreightDr.subtract(oceanFreightCr);
+						item.setOceanFreightCr(item.getOceanFreightCr().add(oceanFreightCr));
+						item.setOceanFreightDr(item.getOceanFreightDr().add(oceanFreightDr));
+						item.setOceanFreightProfit(item.getOceanFreightProfit().add(oceanFreightProfit));
 						item.setAmountCr(item.getAmountCr().add(feeCentersCC));
 						item.setRealAmountCr(item.getRealAmountCr().add(feeCentersCCReal));
 						item.setAmountCrUsd(item.getAmountCrUsd().add(feeCentersUC));
@@ -758,6 +778,9 @@ public class StatisticAnalysisServiceImpl implements IStatisticAnalysisService {
 		map.put("realAmountProfitLoc", financeProfitList.stream().map(FinanceProfitDtoList::getRealAmountProfitLoc).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add));
 		map.put("amountProfit", financeProfitList.stream().map(FinanceProfitDtoList::getAmountProfit).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add));
 		map.put("amountProfitUsd", financeProfitList.stream().map(FinanceProfitDtoList::getAmountProfitUsd).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add));
+		map.put("oceanFreightDr", financeProfitList.stream().map(FinanceProfitDtoList::getOceanFreightDr).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add));
+		map.put("oceanFreightCr", financeProfitList.stream().map(FinanceProfitDtoList::getOceanFreightCr).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add));
+		map.put("oceanFreightProfit", financeProfitList.stream().map(FinanceProfitDtoList::getOceanFreightProfit).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add));
 		return R.data(map);
 	}
 
@@ -863,6 +886,16 @@ public class StatisticAnalysisServiceImpl implements IStatisticAnalysisService {
 						BigDecimal feeCentersUCRealLoc = feeCenterList.stream().filter(e -> i.getId().equals(e.getPid()) && "C".equals(e.getDc()))
 							.reduce(BigDecimal.ZERO, (x, y) -> x.add(y.getStlTtlAmount().multiply(y.getExrate())), BigDecimal::add)
 							.setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightDr = feeCenterList.stream()
+							.filter(e -> i.getId().equals(e.getPid()) && "HYF".equals(e.getFeeCode()) && "D".equals(e.getDc()))
+							.map(FeeCenter::getAmountLoc).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightCr = feeCenterList.stream()
+							.filter(e -> i.getId().equals(e.getPid()) && "HYF".equals(e.getFeeCode()) && "C".equals(e.getDc()))
+							.map(FeeCenter::getAmountLoc).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add).setScale(2, RoundingMode.HALF_UP);
+						BigDecimal oceanFreightProfit = oceanFreightDr.subtract(oceanFreightCr);
+						item.setOceanFreightCr(item.getOceanFreightCr().add(oceanFreightCr));
+						item.setOceanFreightDr(item.getOceanFreightDr().add(oceanFreightDr));
+						item.setOceanFreightProfit(item.getOceanFreightProfit().add(oceanFreightProfit));
 						item.setAmountCr(item.getAmountCr().add(feeCentersCC));
 						item.setRealAmountCr(item.getRealAmountCr().add(feeCentersCCReal));
 						item.setAmountCrUsd(item.getAmountCrUsd().add(feeCentersUC));

+ 10 - 2
blade-service/blade-los/src/main/java/org/springblade/los/view/mapper/FinanceProfitMapper.xml

@@ -80,7 +80,11 @@
         seb.real_amount_dr_loc AS realAmountDrLoc,
         seb.amount_cr_loc AS amountCrLoc,
         seb.real_amount_cr_loc AS realAmountCrLoc,
-        seb.branch_name as branchId
+        seb.branch_name as branchId,
+        seb.corp_source AS corpSource,
+        seb.ocean_freight_dr AS oceanFreightDr,
+        seb.ocean_freight_cr AS oceanFreightCr,
+        seb.ocean_freight_profit AS oceanFreightProfit
         FROM
         los_finance_profit seb
         WHERE
@@ -191,7 +195,11 @@
         seb.real_amount_dr_loc AS realAmountDrLoc,
         seb.amount_cr_loc AS amountCrLoc,
         seb.real_amount_cr_loc AS realAmountCrLoc,
-        seb.branch_name as branchId
+        seb.branch_name as branchId,
+        seb.corp_source AS corpSource,
+        seb.ocean_freight_dr AS oceanFreightDr,
+        seb.ocean_freight_cr AS oceanFreightCr,
+        seb.ocean_freight_profit AS oceanFreightProfit
         FROM
         los_finance_profit seb
         WHERE