Commit 92ba35f0 by 章家宝

Merge remote-tracking branch 'refs/remotes/origin/main' into v1.1.0

# Conflicts:
#	aus-admin/build.gradle
#	aus-api/build.gradle
#	aus-core/build.gradle
#	aus-framework/build.gradle
#	aus-front/admin/src/router/FinanceRouter.ts
#	aus-task/build.gradle
#	build.gradle
2 parents 58e053e3 c0ce3a04
Showing 458 changed files with 1759 additions and 483 deletions
......@@ -15,3 +15,8 @@
/aus-task/build/
/LOG_DIR_IS_UNDEFINED/
/aus-framework/build/
/aus-admin/src/main/resources/static/main/assets/
/aus-admin/src/main/resources/static/main/favicon/
/aus-admin/src/main/resources/static/main/main/assets/
/aus-admin/src/main/resources/static/main/tinymce/
/aus-admin/src/main/resources/static/main/index.html
......@@ -134,3 +134,7 @@ gitee帐号:
https://www.kdocs.cn/l/cqSXe4WVE94M
分批退款接口
https://pay.weixin.qq.com/doc/v3/merchant/4012791862
https://www.yuque.com/runhoutang-6m1me/nkb887/bps7fkelyxfeoq7l?singleDoc# 《20260115 生产体验问题》
\ No newline at end of file
......@@ -14,6 +14,7 @@ import org.springframework.security.authorization.AuthorizationManager;
import org.springframework.security.config.ObjectPostProcessor;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
import org.springframework.security.config.annotation.web.configuration.WebSecurityCustomizer;
import org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer;
import org.springframework.security.config.annotation.web.configurers.HeadersConfigurer;
import org.springframework.security.web.AuthenticationEntryPoint;
......@@ -34,6 +35,8 @@ public class SecurityConfig {
"/payment**"
};
private final String[] publicUrls = {"/rest/account/accountTagQrCode**"};
/**
*
*/
......@@ -76,6 +79,8 @@ public class SecurityConfig {
http.headers(httpSecurityHeadersConfigurer -> httpSecurityHeadersConfigurer.frameOptions(HeadersConfigurer.FrameOptionsConfig::sameOrigin).disable());
http
.authorizeHttpRequests((authorize) -> authorize
// 配置不受管理的 URL,允许所有访问
.requestMatchers(publicUrls).permitAll()
.requestMatchers(protectedUrls).access(authorManagerImpl)
.anyRequest().permitAll()
)
......@@ -112,6 +117,11 @@ public class SecurityConfig {
return http.build();
}
// @Bean
// public WebSecurityCustomizer webSecurityCustomizer() {
// return (web) -> web.ignoring().requestMatchers("/ignore/**", "/public/**");
// }
// // 跟踪/查询会话所需
// @Bean
// public SessionRegistry sessionRegistry() {
......
......@@ -8,16 +8,20 @@ import com.glsx.usedcar.export.converter.AccountTypeConverter;
import com.glsx.usedcar.export.converter.BooleanConverter;
import com.glsx.usedcar.export.converter.CertifiedStateConverter;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.account.entity.AccountTag;
import jakarta.persistence.*;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import org.springframework.util.CollectionUtils;
import org.summerframework.orm.validator.CreateValidGroup;
import org.summerframework.orm.validator.UpdateValidGroup;
import org.summerframework.storage.converter.FileInfoConverter;
import org.summerframework.storage.domain.FileInfo;
import java.time.LocalDateTime;
import java.util.Collections;
import java.util.List;
import static jakarta.persistence.GenerationType.IDENTITY;
......@@ -87,8 +91,13 @@ public class AccountBean {
@ExcelProperty(value = "账户类型", converter = AccountTypeConverter.class)
@ColumnWidth(15)
private Account.AccountType accountType;
@ExcelProperty("用户标签")
@ColumnWidth(30)
private String tags;
public AccountBean(Account account) {
this.accountId = account.getAccountId();
this.accountName = account.getAccountName();
......@@ -105,6 +114,12 @@ public class AccountBean {
this.bankMobile = account.getBankMobile();
this.accountType = account.getAccountType();
this.frozenDeposit = account.getFrozenDeposit();
if (!CollectionUtils.isEmpty(account.getAccountTags())) {
List<String> list = new java.util.ArrayList<>(account.getAccountTags().stream().map(AccountTag::getTagName).toList());
// 1. 基础排序(自然顺序,大小写敏感)
Collections.sort(list);
tags = String.join("、", list);
}
}
......
......@@ -22,6 +22,7 @@ import org.summerframework.orm.validator.UpdateValidGroup;
import org.summerframework.storage.converter.FileInfosConverter;
import org.summerframework.storage.domain.FileInfo;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Objects;
......@@ -45,7 +46,8 @@ public class AppealBean {
@ExcelProperty("关联订单编号")
@ColumnWidth(20)
private String orderCode;
@ExcelProperty("车源号(平台唯一识别编号)")
private String sourceNo;
@ExcelProperty("车系名字")
@ColumnWidth(15)
private String carSeriesName;
......@@ -54,11 +56,20 @@ public class AppealBean {
@ColumnWidth(30)
private String carTypeName;
@ExcelProperty("用户名")
@ExcelProperty("车架号")
private String vin;
@ExcelProperty("车牌号")
private String licensePlate;
@ExcelProperty("所属门店")
@ColumnWidth(30)
private String venueName;
@ExcelProperty("付款方姓名")
private String accountName;
@ExcelProperty("手机号")
@ExcelProperty("付款方手机号")
private String mobile;
@ExcelProperty(value = "申诉原因", converter = DictionConverter.class)
......@@ -68,7 +79,9 @@ public class AppealBean {
@ExcelProperty("补充描述")
@ColumnWidth(30)
private String appealContent;
@ExcelProperty("申诉时间")
@ColumnWidth(16)
private LocalDateTime createTime;
/**
* 附件
......@@ -77,7 +90,7 @@ public class AppealBean {
private List<FileInfo> attachments;
@ExcelProperty(value = "申诉状态", converter = AppealStateConverter.class)
@ExcelProperty(value = "工单状态", converter = AppealStateConverter.class)
private Appeal.AppealState appealState;
......@@ -124,6 +137,12 @@ public class AppealBean {
this.solution = appeal.getSolution();
this.solutionDesc = appeal.getSolutionDesc();
this.compensationAmount = appeal.getCompensationAmount();
this.sourceNo = vehicle.getBaseInfo().getSourceNo();
this.vin = vehicle.getBaseInfo().getVin();
this.licensePlate = vehicle.getBaseInfo().getLicensePlate();
this.venueName = vehicle.getVenue().getVenueName();
this.createTime = appeal.getCreateTime();
}
......
......@@ -44,11 +44,11 @@ public class AuctionOrderBean {
private String auctionName;
@ExcelProperty("用户名")
@ExcelProperty("中拍人姓名")
private String accountName;
@ExcelProperty("手机号")
@ExcelProperty("中拍人电话")
private String mobile;
@ExcelProperty("车源号")
......@@ -63,8 +63,14 @@ public class AuctionOrderBean {
@ColumnWidth(30)
private String carTypeName;
@ExcelProperty("新车牌号")
private String newPlateNumber;
@ExcelProperty("原车牌号")
private String licensePlate;
@ExcelProperty("所属门店")
@ColumnWidth(30)
private String venueName;
@ExcelIgnore
@ExcelProperty("机动车登记证书")
private List<FileInfo> registrationCertificate;
......@@ -81,6 +87,10 @@ public class AuctionOrderBean {
@ExcelProperty("佣金")
private double commissionPrice;
@ExcelProperty("买家应付车款")
private double totalPrice;
@ExcelIgnore
@ExcelProperty("支付凭证")
private List<FileInfo> payVouchers;
......@@ -102,17 +112,24 @@ public class AuctionOrderBean {
private Contract deliveryContract;
@ExcelProperty(value = "审核状态", converter = AuditStateConverter.class)
private AuditState auditState;
// @ExcelProperty(value = "审核状态", converter = AuditStateConverter.class)
// private AuditState auditState;
@ExcelProperty(value = "订单状态", converter = AuctionOrderStateConverter.class)
private AuctionOrder.OrderState orderState;
@ExcelProperty("负责人")
private String realName;
@ExcelProperty("新车牌号")
private String newPlateNumber;
@ExcelProperty("过户时间")
private LocalDateTime transferredTime;
@ExcelProperty("中拍时间")
private LocalDateTime createTime;
@ExcelProperty("订单更新时间")
private LocalDateTime updateTime;
@ExcelProperty(value = "是否在申诉中", converter = BooleanConverter.class)
private boolean onAppeal;
......@@ -139,10 +156,16 @@ public class AuctionOrderBean {
this.settlement = auctionOrder.isSettlement();
this.contract = auctionOrder.getContract();
this.deliveryContract = auctionOrder.getDeliveryContract();
this.auditState = auctionOrder.getAuditState();
this.orderState = auctionOrder.getOrderState();
this.transferredTime = auctionOrder.getTransferredTime();
this.onAppeal = auctionOrder.isOnAppeal();
this.realName = auction.getUser().getRealName();
this.createTime = auctionOrder.getCreateTime();
this.updateTime = auctionOrder.getUpdateTime();
this.totalPrice = auctionOrder.getOrderPrice() + auctionOrder.getCommissionPrice();
this.licensePlate = vehicle.getBaseInfo().getLicensePlate();
this.venueName = vehicle.getVenue().getVenueName();
}
}
......@@ -3,8 +3,10 @@ package com.glsx.usedcar.export;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.glsx.usedcar.export.converter.AuctionOrderStateConverter;
import com.glsx.usedcar.export.converter.BooleanConverter;
import com.glsx.usedcar.export.converter.DeliveryOrderStateConverter;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.auction.entity.AuctionOrder;
import com.glsx.usedcar.module.auction.entity.DeliveryOrder;
import com.glsx.usedcar.module.security.entity.User;
......@@ -34,6 +36,8 @@ public class DeliveryOrderBean {
@ExcelProperty("工单编号")
@ColumnWidth(20)
private String orderCode;
@ExcelProperty("车源号(平台唯一识别编号)")
private String sourceNo;
@ExcelProperty("车系名字")
@ColumnWidth(15)
......@@ -43,30 +47,50 @@ public class DeliveryOrderBean {
@ColumnWidth(30)
private String carTypeName;
@ExcelProperty("车架号")
private String vin;
@ExcelProperty("车牌号")
private String licensePlate;
@ExcelProperty("所属门店")
@ColumnWidth(30)
private String venueName;
@ExcelProperty("中拍人姓名")
private String accountName;
@ExcelProperty("中拍人电话")
private String accountMobile;
@ExcelProperty("指派专员")
@ExcelProperty("交付专员")
private String realName;
@ExcelProperty("指派专员手机号")
@ExcelProperty("交付专员联系方式")
private String mobile;
/**
* 工单状态
*/
@ExcelProperty(value = "工单状态", converter = DeliveryOrderStateConverter.class)
private DeliveryOrder.OrderState orderState;
@ExcelProperty("备注")
private String remark;
@ExcelIgnore
@ExcelProperty("预约时间")
private LocalDateTime appointmentTime;
// @ExcelIgnore
// @ExcelProperty("预约时间")
// private LocalDateTime appointmentTime;
// @ExcelProperty("指派时间")
// private LocalDateTime assignedTime;
@ExcelProperty("指派时间")
private LocalDateTime assignedTime;
@ExcelProperty("中拍时间")
private LocalDateTime orderCreateTime;
@ExcelProperty("订单更新时间")
private LocalDateTime orderUpdateTime;
@ExcelProperty(value = "订单状态", converter = AuctionOrderStateConverter.class)
private AuctionOrder.OrderState auctionOrderState;
/**
* 工单状态
*/
@ExcelProperty(value = "工单状态", converter = DeliveryOrderStateConverter.class)
private DeliveryOrder.OrderState orderState;
/**
* 凭证
*/
......@@ -74,26 +98,26 @@ public class DeliveryOrderBean {
private List<FileInfo> vouchers;
@ExcelProperty(value = "核验买家身份证原件", converter = BooleanConverter.class)
private boolean checkIdCard;
@ExcelProperty(value = "签署车辆交接确认单", converter = BooleanConverter.class)
private boolean checkHandover;
@ExcelProperty(value = "交付车辆钥匙", converter = BooleanConverter.class)
private boolean checkKey;
@ExcelProperty(value = "交付车辆所有权证及登记证", converter = BooleanConverter.class)
private boolean checkCertificate;
// @ExcelProperty(value = "核验买家身份证原件", converter = BooleanConverter.class)
// private boolean checkIdCard;
//
//
// @ExcelProperty(value = "签署车辆交接确认单", converter = BooleanConverter.class)
// private boolean checkHandover;
//
//
// @ExcelProperty(value = "交付车辆钥匙", converter = BooleanConverter.class)
// private boolean checkKey;
//
//
// @ExcelProperty(value = "交付车辆所有权证及登记证", converter = BooleanConverter.class)
// private boolean checkCertificate;
/**
* 交付工单的当前状态:准备交付/交付中/过户中/已完成/已取消
*/
@ExcelProperty("当前状态")
private int orderStatus;
// @ExcelProperty("状态")
// private int orderStatus;
@ExcelProperty("状态描述")
......@@ -111,6 +135,7 @@ public class DeliveryOrderBean {
AuctionOrder auctionOrder = deliveryOrder.getAuctionOrder();
Vehicle vehicle = auctionOrder.getVehicle();
User user = deliveryOrder.getUser();
Account account = auctionOrder.getAccount();
this.deliveryOrderId = deliveryOrder.getDeliveryOrderId();
this.orderCode = auctionOrder.getOrderCode();
this.carSeriesName = vehicle.getBaseInfo().getCarSeriesName();
......@@ -122,16 +147,20 @@ public class DeliveryOrderBean {
this.orderState = deliveryOrder.getOrderState();
this.remark = deliveryOrder.getRemark();
this.appointmentTime = deliveryOrder.getAppointmentTime();
this.assignedTime = deliveryOrder.getAssignedTime();
this.vouchers = deliveryOrder.getVouchers();
this.checkIdCard = deliveryOrder.isCheckIdCard();
this.checkHandover = deliveryOrder.isCheckHandover();
this.checkKey = deliveryOrder.isCheckKey();
this.checkCertificate = deliveryOrder.isCheckCertificate();
this.orderStatus = deliveryOrder.getOrderStatus();
// this.orderStatus = deliveryOrder.getOrderStatus();
this.statusText = deliveryOrder.getStatusText();
this.remarks = deliveryOrder.getRemarks();
this.cancelReason = deliveryOrder.getCancelReason();
this.orderCreateTime = auctionOrder.getCreateTime();
this.orderUpdateTime = auctionOrder.getUpdateTime();
this.accountMobile = account.getMobile();
this.accountName = account.getAccountName();
this.venueName = vehicle.getVenue().getVenueName();
this.vin = vehicle.getBaseInfo().getVin();
this.licensePlate = vehicle.getBaseInfo().getLicensePlate();
this.sourceNo = vehicle.getBaseInfo().getSourceNo();
this.orderCode = auctionOrder.getOrderCode();
}
}
package com.glsx.usedcar.export;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.glsx.usedcar.export.converter.RefundStateConverter;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.finance.entity.Deposit;
import com.glsx.usedcar.module.vehicle.entity.BaseInfo;
import jakarta.persistence.Column;
import lombok.Data;
import java.time.LocalDateTime;
import java.util.Objects;
@Data
public class DepositRefundBean {
@ExcelProperty("用户ID")
@ColumnWidth(10)
private int accountId;
@ExcelProperty("用户手机号")
@ColumnWidth(20)
private String mobile;
@ExcelProperty("用户昵称")
@ColumnWidth(20)
private String nickName;
@ExcelProperty("拍场ID")
@ColumnWidth(10)
private int auctionId;
@ExcelProperty("拍场名称")
@ColumnWidth(30)
private String auctionName;
@ExcelProperty("参拍车源号")
@ColumnWidth(20)
private String sourceNo;
@ExcelProperty("参拍车型名称")
@ColumnWidth(30)
private String carTypeName;
@ExcelProperty("商户订单号")
@ColumnWidth(25)
private String outTradeNo;
@ExcelProperty("微信支付订单号")
@ColumnWidth(25)
private String transactionId;
@ExcelProperty("支付金额(元)")
@ColumnWidth(15)
private double transactionAmount;
@ExcelProperty("支付状态")
@ColumnWidth(15)
private String paymentState;
@ExcelProperty("支付时间")
@ColumnWidth(20)
private LocalDateTime paymentTime;
@ExcelProperty("支付渠道")
@ColumnWidth(15)
private String paymentType;
@ExcelProperty("是否中拍")
@ColumnWidth(15)
private String orderState;
@ExcelProperty(value = "退款状态",converter = RefundStateConverter.class)
@ColumnWidth(15)
private Deposit.RefundState refundState;
@ExcelProperty("退款类型")
@ColumnWidth(15)
private String refundType;
@ExcelProperty("退款金额(元)")
@ColumnWidth(15)
private double refundAmount;
@ExcelProperty("微信退款订单号")
@ColumnWidth(25)
private String outRefundNo;
@ExcelProperty("退款申请时间")
@ColumnWidth(20)
private LocalDateTime refundTime;
@ExcelProperty("退款成功时间")
@ColumnWidth(20)
private LocalDateTime refundSuccessTime;
@ExcelProperty("手动退款备注")
@ColumnWidth(35)
private String refundRemark;
@ExcelProperty("退款操作人")
@ColumnWidth(15)
private String refundOperator;
public DepositRefundBean(Deposit deposit) {
Account account = deposit.getAccount();
this.accountId = account.getAccountId();
this.mobile = account.getMobile();
this.nickName = account.getNickName();
this.auctionId = deposit.getAuctionVehicle().getAuction().getAuctionId();
this.auctionName = deposit.getAuctionVehicle().getAuction().getAuctionName();
BaseInfo baseInfo = deposit.getAuctionVehicle().getVehicle().getBaseInfo();
this.sourceNo = baseInfo.getSourceNo();
this.carTypeName = baseInfo.getCarSeriesName() + " "+baseInfo.getCarTypeName();
// this.outTradeNo = deposit.getOutTradeNo();
// this.transactionId = deposit.getTransactionId();
// this.transactionAmount = Math.abs(deposit.getTransaction().getAmount());
// this.paymentState = Objects.nonNull(deposit.getPaymentTime()) ? "已支付" : "已关闭";
// this.paymentTime = deposit.getPaymentTime();
// this.paymentType = "微信支付";
// this.orderState = Objects.nonNull(deposit.getAuctionOrder()) ? "是" : "否";
// this.refundType = deposit.getRefundType();
// this.refundAmount = Objects.nonNull(deposit.getRefundSuccessTime()) ? deposit.getAmount() : 0;
// this.outRefundNo = deposit.getOutRefundNo();
// this.refundTime = deposit.getRefundTime();
// this.refundSuccessTime = deposit.getRefundSuccessTime();
// this.refundState = deposit.getRefundState();
// this.refundRemark = deposit.getRefundRemark();
// this.refundOperator = deposit.getRefundOperator();
}
}
......@@ -33,6 +33,10 @@ public class OrderTransactionBean {
@ColumnWidth(20)
private String transactionCode;
@ExcelProperty("交易时间")
@ColumnWidth(20)
private LocalDateTime transactionTime;
@ExcelProperty("订单编号")
@ColumnWidth(20)
private String orderCode;
......@@ -46,6 +50,9 @@ public class OrderTransactionBean {
@ColumnWidth(15)
private String mobile;
@ExcelProperty("车源号(平台唯一识别编号)")
private String sourceNo;
@ExcelProperty("车系名字")
@ColumnWidth(15)
private String carSeriesName;
......@@ -54,6 +61,14 @@ public class OrderTransactionBean {
@ColumnWidth(30)
private String carTypeName;
@ExcelProperty("车辆保管人姓名")
private String custodianName;
@ExcelProperty("车辆保管人联系方式")
private String custodianPhone;
@ExcelProperty("车辆停放地址信息")
private String handoverAddress;
@ExcelProperty("交易说明")
@ColumnWidth(35)
......@@ -66,16 +81,20 @@ public class OrderTransactionBean {
private List<FileInfo> payVouchers;
@ExcelProperty(value = "审核状态", converter = AuditStateConverter.class)
@ExcelProperty(value = "工单状态", converter = AuditStateConverter.class)
private AuditState auditState;
@ExcelProperty("应付金额")
@ColumnWidth(15)
private double totalAmount;
@ExcelProperty("实际到账金额")
@ColumnWidth(15)
private double amount;
@ExcelProperty(value = "支付类型", converter = PaymentTypeConverter.class)
@ExcelProperty(value = "支付方式", converter = PaymentTypeConverter.class)
@ColumnWidth(10)
private OrderTransaction.PaymentType paymentType;
......@@ -95,6 +114,10 @@ public class OrderTransactionBean {
private LocalDateTime auditTime;
@ExcelProperty("创建时间")
@ColumnWidth(20)
private LocalDateTime createTime;
public OrderTransactionBean(OrderTransaction transaction) {
Account account = transaction.getAuctionOrder().getAccount();
Vehicle vehicle = transaction.getAuctionOrder().getVehicle();
......@@ -110,6 +133,13 @@ public class OrderTransactionBean {
this.auditState = transaction.getAuditState();
this.amount = transaction.getAmount();
this.paymentType = transaction.getPaymentType();
this.totalAmount = transaction.getAuctionOrder().getOrderPrice() + transaction.getAuctionOrder().getCommissionPrice();
this.createTime = transaction.getCreateTime();
this.transactionTime = transaction.getCreateTime();
this.sourceNo = vehicle.getBaseInfo().getSourceNo();
this.custodianName = vehicle.getCustodianInfo().getCustodianName();
this.custodianPhone = vehicle.getCustodianInfo().getCustodianPhone();
this.handoverAddress = vehicle.getCustodianInfo().getHandoverAddress();
}
public void setApproveHistory(ApproveHistory approveHistory) {
......
......@@ -4,10 +4,13 @@ import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.glsx.usedcar.export.converter.ListConverter;
import com.glsx.usedcar.export.converter.VehicleStateConverter;
import com.glsx.usedcar.module.vehicle.entity.*;
import jakarta.persistence.Column;
import lombok.Data;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;
@Data
......@@ -72,12 +75,15 @@ public class VehicleBean {
// 从LicenseInfo补充的属性
@ExcelProperty("年检到期")
@ColumnWidth(15)
private LocalDate annualInspectionExpiry;
@ExcelProperty("交强险到期")
@ColumnWidth(15)
private LocalDate compulsoryInsuranceExpiry;
@ExcelProperty("商业险到期日")
@ColumnWidth(15)
private LocalDate commercialInsuranceExpiry;
@ExcelProperty("钥匙数")
......@@ -137,12 +143,14 @@ public class VehicleBean {
private String carCityName;
@ExcelProperty("首次上牌时间")
@ColumnWidth(15)
private LocalDate registrationDate;
@ExcelProperty("过户次数")
private int transferCount;
@ExcelProperty("最近过户时间")
@ColumnWidth(15)
private LocalDate lastTransferDate;
@ExcelProperty("使用性质:1-非营运/2-营运/3-营转非")
......@@ -196,6 +204,32 @@ public class VehicleBean {
@ExcelProperty("车况描述")
private String conditionDescription;
@ExcelProperty("起拍价")
@ColumnWidth(12)
private double startingBidPrice;
@ExcelProperty("保留价")
@ColumnWidth(12)
private double reservePrice;
@ExcelProperty("创建时间")
@ColumnWidth(15)
private LocalDateTime createTime;
@ExcelProperty("入库时间")
@ColumnWidth(15)
private LocalDateTime warehousingTime;
@ExcelProperty("更新时间")
@ColumnWidth(15)
private LocalDateTime updateTime;
@ExcelProperty(value = "车辆状态", converter = VehicleStateConverter.class)
@ColumnWidth(15)
private Vehicle.VehicleState vehicleState;
// 无参构造方法(EasyExcel需要)
public VehicleBean() {
}
......@@ -205,6 +239,14 @@ public class VehicleBean {
public VehicleBean(Vehicle vehicle) {
// 基础属性
this.vehicleId = vehicle.getVehicleId();
this.createTime = vehicle.getCreateTime();
this.updateTime = vehicle.getUpdateTime();
this.warehousingTime = vehicle.getWarehousingTime();
this.vehicleState = vehicle.getVehicleState();
this.startingBidPrice = vehicle.getStartingBidPrice();
this.reservePrice = vehicle.getReservePrice();
BaseInfo baseInfo = vehicle.getBaseInfo();
OwnerInfo ownerInfo = vehicle.getOwnerInfo();
LicenseInfo licenseInfo = vehicle.getLicenseInfo();
......
......@@ -2,6 +2,7 @@ package com.glsx.usedcar.export;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.github.binarywang.wxpay.constant.WxPayConstants;
import com.glsx.usedcar.export.converter.AuditStateConverter;
import com.glsx.usedcar.export.converter.WithdrawStateConverter;
......@@ -31,59 +32,60 @@ public class WithdrawBean {
private int withdrawId;
@ExcelProperty("用户名")
@ColumnWidth(15)
private String accountName;
@ExcelProperty("手机号")
@ColumnWidth(15)
private String mobile;
@ExcelProperty("流水号")
@ColumnWidth(15)
private String withdrawCode;
@ExcelProperty("审核备注")
@ColumnWidth(30)
private String auditRemark;
@ExcelProperty("申请时间")
@ColumnWidth(15)
private LocalDateTime applyWithdrawTime;
@ExcelProperty("审核时间")
@ColumnWidth(15)
private LocalDateTime auditTime;
@ExcelProperty("提现金额")
@ColumnWidth(15)
private double amount;
@ExcelProperty(value = "审核状态", converter = AuditStateConverter.class)
@ColumnWidth(15)
private AuditState auditState;
@ExcelProperty("付款单号")
private String transferBillNo;
@ExcelProperty("已退款金额")
@ColumnWidth(15)
private Double refundAmount;
@ExcelProperty(value = "付款状态", converter = WithdrawStateConverter.class)
private String state;
@ExcelProperty("失败原因")
private String failReason;
@ExcelProperty("付款金额")
private Double paymentAmount;
@ExcelProperty("发起付款时间")
private LocalDateTime paymentTime;
// @ExcelProperty("发起付款时间")
// private LocalDateTime paymentTime;
@ExcelProperty("转账成功时间")
@ColumnWidth(15)
private LocalDateTime transferTime;
@ExcelProperty("付款备注")
@ColumnWidth(30)
private String transferRemark;
public WithdrawBean(Withdraw withdraw) {
......@@ -96,11 +98,8 @@ public class WithdrawBean {
this.auditTime = withdraw.getAuditTime();
this.amount = withdraw.getAmount();
this.auditState = withdraw.getAuditState();
this.transferBillNo = withdraw.getTransferBillNo();
this.state = withdraw.getState();
this.failReason = withdraw.getFailReason();
this.paymentAmount = withdraw.getPaymentAmount();
this.paymentTime = withdraw.getPaymentTime();
this.refundAmount = withdraw.getRefundAmount();
// this.paymentTime = withdraw.getPaymentTime();
this.transferTime = withdraw.getTransferTime();
this.transferRemark = withdraw.getTransferRemark();
}
......
package com.glsx.usedcar.export.converter;
import com.alibaba.excel.converters.Converter;
import com.alibaba.excel.converters.WriteConverterContext;
import com.alibaba.excel.metadata.GlobalConfiguration;
import com.alibaba.excel.metadata.data.ReadCellData;
import com.alibaba.excel.metadata.data.WriteCellData;
import com.alibaba.excel.metadata.property.ExcelContentProperty;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.finance.entity.Deposit;
import org.summerframework.core.i18n.EnumMessage;
public class RefundStateConverter implements Converter<Deposit.RefundState> {
@Override
public Deposit.RefundState convertToJavaData(ReadCellData<?> cellData, ExcelContentProperty contentProperty, GlobalConfiguration globalConfiguration) throws Exception {
return Converter.super.convertToJavaData(cellData, contentProperty, globalConfiguration);
}
@Override
public WriteCellData<?> convertToExcelData(WriteConverterContext<Deposit.RefundState> context) {
Deposit.RefundState auditState = context.getValue();
String i18nMessage = EnumMessage.getI18nMessage("Deposit.RefundState.", auditState);
return new WriteCellData<>(i18nMessage);
}
}
package com.glsx.usedcar.export.converter;
import com.alibaba.excel.converters.Converter;
import com.alibaba.excel.converters.WriteConverterContext;
import com.alibaba.excel.enums.CellDataTypeEnum;
import com.alibaba.excel.metadata.GlobalConfiguration;
import com.alibaba.excel.metadata.data.ReadCellData;
import com.alibaba.excel.metadata.data.WriteCellData;
import com.alibaba.excel.metadata.property.ExcelContentProperty;
import com.glsx.usedcar.module.meta.AuditState;
import com.glsx.usedcar.module.vehicle.entity.Vehicle;
import org.summerframework.core.i18n.EnumMessage;
public class VehicleStateConverter implements Converter<Vehicle.VehicleState> {
@Override
public CellDataTypeEnum supportExcelTypeKey() {
return CellDataTypeEnum.STRING;
}
@Override
public Vehicle.VehicleState convertToJavaData(ReadCellData<?> cellData, ExcelContentProperty contentProperty, GlobalConfiguration globalConfiguration) throws Exception {
return Converter.super.convertToJavaData(cellData, contentProperty, globalConfiguration);
}
@Override
public WriteCellData<?> convertToExcelData(WriteConverterContext<Vehicle.VehicleState> context) {
Vehicle.VehicleState auditState = context.getValue();
String i18nMessage = EnumMessage.getI18nMessage(auditState);
return new WriteCellData<>(i18nMessage);
}
}
......@@ -5,6 +5,7 @@ import com.glsx.usedcar.export.DeliveryOrderBean;
import com.glsx.usedcar.export.ExcelExporter;
import com.glsx.usedcar.module.auction.entity.*;
import com.glsx.usedcar.module.auction.service.AppealService;
import com.glsx.usedcar.module.vehicle.entity.Vehicle_;
import jakarta.annotation.Resource;
import jakarta.persistence.criteria.Fetch;
import jakarta.persistence.criteria.JoinType;
......@@ -99,7 +100,9 @@ public class AppealController {
@PostMapping("exportAppeal")
public void exportAppeal(@RequestBody Pagination<Appeal> pagination, HttpServletResponse response) throws IOException {
pagination.setLimit(9999);
pagination.addFetch(root -> root.fetch(Appeal_.auctionOrder, JoinType.LEFT).fetch(AuctionOrder_.vehicle, JoinType.LEFT).fetch(Vehicle_.venue, JoinType.LEFT));
List<Appeal> vehicles = pageAppeal(pagination).getContent();
List<AppealBean> vehicleBeans = vehicles.stream().map(AppealBean::new).toList();
ExcelExporter.exportExcel(response, "交付工单列表", "交付工单列表", AppealBean.class, vehicleBeans);
}
......
package com.glsx.usedcar.web.rest.account;
import cn.binarywang.wx.miniapp.api.WxMaQrcodeService;
import cn.binarywang.wx.miniapp.api.WxMaService;
import com.glsx.usedcar.export.AccountBean;
import com.glsx.usedcar.export.ExcelExporter;
import com.glsx.usedcar.module.account.domain.*;
......@@ -22,8 +24,10 @@ import jakarta.persistence.criteria.Predicate;
import jakarta.servlet.http.HttpServletResponse;
import jakarta.validation.Valid;
import lombok.extern.slf4j.Slf4j;
import me.chanjar.weixin.common.error.WxErrorException;
import org.springframework.data.domain.Page;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.http.ResponseEntity;
import org.springframework.security.core.Authentication;
import org.springframework.util.CollectionUtils;
import org.springframework.web.bind.annotation.*;
......@@ -60,6 +64,8 @@ public class AccountController {
private BidService bidService;
@Resource
private DepositService depositService;
@Resource
private WxMaService wxMaService;
/**
* 分页查询个人账户
......@@ -205,6 +211,12 @@ public class AccountController {
return true;
}
@PostMapping("setTagAccounts")
public boolean setTagAccounts(@RequestBody TagAccount tagAccount) {
accountService.setTagAccounts(tagAccount);
return true;
}
/**
* 审核用户申请
*
......@@ -284,8 +296,20 @@ public class AccountController {
@PostMapping("exportAccount")
public void exportAccount(@RequestBody Pagination<Account> pagination, HttpServletResponse response) throws IOException {
pagination.setLimit(9999);
pagination.addFetch(root -> root.fetch(Account_.accountTags, JoinType.LEFT));
List<Account> vehicles = pageAccount(pagination).getContent();
List<AccountBean> vehicleBeans = vehicles.stream().map(AccountBean::new).toList();
ExcelExporter.exportExcel(response, "用户列表", "用户列表", AccountBean.class, vehicleBeans);
}
@GetMapping("accountTagQrCode")
public ResponseEntity<byte[]> accountTagQrCode(@RequestParam String code, HttpServletResponse response) throws WxErrorException {
WxMaQrcodeService qrcodeService = wxMaService.getQrcodeService();
byte[] releases = qrcodeService.createWxaCodeUnlimitBytes(code, "pages/tabbar/HomePage", false, "release", 430, true, null, false);
//设置页面不缓存
response.setHeader("Pragma", "No-cache");
response.setHeader("Cache-Control", "no-cache");
response.setDateHeader("Expires", 0);
return ResponseEntity.ok(releases);
}
}
\ No newline at end of file
......@@ -2,6 +2,7 @@ package com.glsx.usedcar.web.rest.auction;
import com.glsx.usedcar.module.analysis.domain.AuctionVehicleRate;
import com.glsx.usedcar.module.auction.domain.AuctionControl;
import com.glsx.usedcar.module.auction.domain.AuctionVehicleAddon;
import com.glsx.usedcar.module.auction.domain.PendingAuction;
import com.glsx.usedcar.module.auction.entity.*;
import com.glsx.usedcar.module.auction.service.AuctionChangeService;
......@@ -46,8 +47,6 @@ public class AuctionController {
private TrackService trackService;
@Resource
private AuctionOrderService auctionOrderService;
@Resource
private AuctionChangeService auctionChangeService;
/**
......@@ -272,4 +271,9 @@ public class AuctionController {
return auctionService.getAuctionStateCountByType(auctionType);
}
@PostMapping("addAuctionVehicles")
public int addAuctionVehicles(@RequestBody AuctionVehicleAddon auctionVehicleAddon) throws FieldException {
auctionService.addAuctionVehicles(auctionVehicleAddon);
return auctionVehicleAddon.getAuctionId();
}
}
\ No newline at end of file
......@@ -10,6 +10,7 @@ import com.glsx.usedcar.module.auction.service.AuctionOrderService;
import com.glsx.usedcar.module.auction.service.AuctionService;
import com.glsx.usedcar.module.security.entity.User;
import com.glsx.usedcar.module.track.entity.ApproveHistory;
import com.glsx.usedcar.module.vehicle.entity.Vehicle_;
import jakarta.annotation.Resource;
import jakarta.persistence.criteria.JoinType;
import jakarta.servlet.http.HttpServletResponse;
......@@ -147,6 +148,7 @@ public class AuctionOrderController {
public void exportAuctionOrder(@RequestBody Pagination<AuctionOrder> pagination, HttpServletResponse response) throws IOException {
pagination.setLimit(9999);
pagination.addFetch(root -> root.fetch(AuctionOrder_.auction, JoinType.LEFT));
pagination.addFetch(root -> root.fetch(AuctionOrder_.vehicle, JoinType.LEFT).fetch(Vehicle_.venue, JoinType.LEFT));
List<AuctionOrder> vehicles = pageAuctionOrder(pagination).getContent();
List<AuctionOrderBean> vehicleBeans = vehicles.stream().map(AuctionOrderBean::new).toList();
ExcelExporter.exportExcel(response, "订单列表", "订单列表", AuctionOrderBean.class, vehicleBeans);
......
package com.glsx.usedcar.web.rest.finance;
import com.github.binarywang.wxpay.bean.request.WxPayRefundV3Request;
import com.github.binarywang.wxpay.bean.request.WxPayUnifiedOrderV3Request;
import com.github.binarywang.wxpay.bean.result.WxPayRefundV3Result;
import com.github.binarywang.wxpay.exception.WxPayException;
import com.github.binarywang.wxpay.service.WxPayService;
import com.glsx.usedcar.export.DepositBean;
import com.glsx.usedcar.export.DepositRefundBean;
import com.glsx.usedcar.export.ExcelExporter;
import com.glsx.usedcar.export.WithdrawBean;
import com.glsx.usedcar.module.auction.entity.AuctionVehicle;
import com.glsx.usedcar.module.auction.entity.AuctionVehicle_;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.account.entity.Account_;
import com.glsx.usedcar.module.auction.entity.*;
import com.glsx.usedcar.module.auction.service.AuctionOrderService;
import com.glsx.usedcar.module.finance.domain.DepositStat;
import com.glsx.usedcar.module.finance.entity.Deposit;
import com.glsx.usedcar.module.finance.entity.DepositRule;
import com.glsx.usedcar.module.finance.entity.Deposit_;
import com.glsx.usedcar.module.finance.entity.Withdraw;
import com.glsx.usedcar.module.finance.service.DepositService;
import com.glsx.usedcar.module.finance.service.TransactionService;
import com.glsx.usedcar.module.finance.service.WithdrawService;
import com.glsx.usedcar.module.security.entity.User;
import jakarta.annotation.Resource;
import jakarta.persistence.criteria.Fetch;
import jakarta.persistence.criteria.JoinType;
import jakarta.persistence.criteria.*;
import jakarta.servlet.http.HttpServletResponse;
import jakarta.validation.Valid;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.data.domain.Page;
import org.springframework.security.core.Authentication;
import org.springframework.web.bind.annotation.*;
import org.summerframework.orm.paging.Pagination;
......@@ -44,6 +55,11 @@ public class DepositController {
@Resource
private WithdrawService withdrawService;
@Resource
private AuctionOrderService auctionOrderService;
@Resource
private TransactionService transactionService;
/**
* 分页查询保证金规则
*
......@@ -67,6 +83,17 @@ public class DepositController {
return depositService.pageDeposit(pagination);
}
@PostMapping("pageDepositFetchOrder")
public Page<Deposit> pageDepositFetchOrder(@RequestBody Pagination<Deposit> pagination) {
// pagination.addCondition((root, query, builder) -> root.get(Deposit_.paymentTime).isNotNull());
Page<Deposit> depositPage = pageDeposit(pagination);
for (Deposit deposit : depositPage) {
AuctionOrder auctionOrder = auctionOrderService.getAuctionOrderByAccountAndAuctionVehicle(deposit.getAccount(), deposit.getAuctionVehicle());
deposit.setAuctionOrder(auctionOrder);
}
return depositPage;
}
/**
* 根据id查询保证金规则
......@@ -170,9 +197,18 @@ public class DepositController {
ExcelExporter.exportExcel(response, "保证金列表", "保证金列表", DepositBean.class, vehicleBeans);
}
@PostMapping("exportDepositRefund")
public void exportDepositRefund(@RequestBody Pagination<Deposit> pagination, HttpServletResponse response) throws IOException {
pagination.setLimit(9999);
List<Deposit> vehicles = pageDepositFetchOrder(pagination).getContent();
List<DepositRefundBean> vehicleBeans = vehicles.stream().map(DepositRefundBean::new).toList();
ExcelExporter.exportExcel(response, "微信支付流水详情", "微信支付流水详情", DepositRefundBean.class, vehicleBeans);
}
@GetMapping("getFreezeAmountByAccount")
public double getFreezeAmountByAccount(@RequestParam int accountId) {
return depositService.getFreezeAmountByAccount(accountId);
}
}
\ No newline at end of file
package com.glsx.usedcar.web.rest.finance;
import com.github.binarywang.wxpay.exception.WxPayException;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.finance.entity.Recharge;
import com.glsx.usedcar.module.finance.entity.Recharge_;
import com.glsx.usedcar.module.finance.entity.Refund;
import com.glsx.usedcar.module.finance.entity.Withdraw;
import com.glsx.usedcar.module.finance.service.TransactionService;
import com.glsx.usedcar.module.meta.AuditState;
import com.glsx.usedcar.module.security.entity.User;
import com.glsx.usedcar.module.track.entity.ApproveHistory;
import jakarta.annotation.Resource;
import jakarta.persistence.criteria.JoinType;
import jakarta.validation.Valid;
import lombok.extern.slf4j.Slf4j;
import org.springframework.data.domain.Page;
import org.springframework.security.core.Authentication;
import org.springframework.web.bind.annotation.*;
import org.summerframework.core.exception.FieldException;
import org.summerframework.orm.paging.Pagination;
import java.util.List;
import java.util.Map;
@Slf4j
@RestController
@RequestMapping("/rest/recharge")
public class RechargeController {
@Resource
private TransactionService transactionService;
@PostMapping("pageRecharge")
public Page<Recharge> pageRecharge(@RequestBody Pagination<Recharge> pagination) {
// pagination.addFilter(account, Recharge_.account);
pagination.addFetch(root -> root.fetch(Recharge_.account, JoinType.LEFT));
pagination.addCondition((root, query, builder) -> root.get(Recharge_.paymentTime).isNotNull());
return transactionService.pageRecharge(pagination);
}
// @GetMapping("getRechargesByAccountId")
// public List<Recharge> getRechargesByAccountId(@RequestParam int accountId) {
// List<Recharge> recharges = transactionService.getRechargesByAccountId(accountId, AuditState.REJECTED);
// return recharges;
// }
@GetMapping("getRechargeById")
public Recharge getRechargeById(@RequestParam int rechargeId) {
return transactionService.getRechargeById(rechargeId);
}
@GetMapping("getRefundsByRechargeId")
public List<Refund> getRefundsByRechargeId(@RequestParam int rechargeId) {
return transactionService.getRefundsByRechargeId(rechargeId);
}
}
......@@ -7,10 +7,7 @@ import com.glsx.usedcar.module.auction.entity.AuctionOrder_;
import com.glsx.usedcar.module.auction.service.BreachService;
import com.glsx.usedcar.module.finance.domain.OrderTransactionAmountStat;
import com.glsx.usedcar.module.finance.domain.OrderTransactionStat;
import com.glsx.usedcar.module.finance.entity.OrderTransaction;
import com.glsx.usedcar.module.finance.entity.OrderTransaction_;
import com.glsx.usedcar.module.finance.entity.Transaction;
import com.glsx.usedcar.module.finance.entity.Transaction_;
import com.glsx.usedcar.module.finance.entity.*;
import com.glsx.usedcar.module.finance.service.TransactionService;
import com.glsx.usedcar.module.meta.AuditState;
import com.glsx.usedcar.module.security.entity.User;
......@@ -163,6 +160,13 @@ public class TransactionController {
return transactionService.getOrderTransactionCountByAuditState();
}
@GetMapping("getRefundsByWithdrawId")
public List<Refund> getRefundsByWithdrawId(@RequestParam int withdrawId) {
return transactionService.getRefundsByWithdrawId(withdrawId);
}
@PostMapping("updateOrderTransactionDesc")
public OrderTransaction updateOrderTransactionDesc(@RequestBody OrderTransaction orderTransaction) throws FieldException {
return transactionService.updateOrderTransactionDesc(orderTransaction.getTransactionId(), orderTransaction.getTransactionDesc());
......
......@@ -18,6 +18,7 @@ import lombok.extern.slf4j.Slf4j;
import org.springframework.data.domain.Page;
import org.springframework.security.core.Authentication;
import org.springframework.web.bind.annotation.*;
import org.summerframework.core.exception.FieldException;
import org.summerframework.orm.paging.Pagination;
import java.io.IOException;
......@@ -85,7 +86,7 @@ public class WithdrawController {
* @return
*/
@PostMapping("auditWithdraw")
public Withdraw auditWithdraw(@Valid @RequestBody ApproveHistory approveHistory, Authentication authentication) throws WxPayException {
public Withdraw auditWithdraw(@Valid @RequestBody ApproveHistory approveHistory, Authentication authentication) throws WxPayException, FieldException {
approveHistory.setUser((User) authentication.getPrincipal());
return withdrawService.auditWithdraw(approveHistory);
}
......
......@@ -7,6 +7,7 @@ import com.glsx.usedcar.module.auction.entity.AuctionOrder_;
import com.glsx.usedcar.module.auction.entity.DeliveryOrder;
import com.glsx.usedcar.module.auction.entity.DeliveryOrder_;
import com.glsx.usedcar.module.auction.service.DeliveryOrderService;
import com.glsx.usedcar.module.vehicle.entity.Vehicle_;
import jakarta.annotation.Resource;
import jakarta.persistence.criteria.Fetch;
import jakarta.persistence.criteria.JoinType;
......@@ -142,6 +143,7 @@ public class DeliveryOrderController {
public void exportDeliveryOrder(@RequestBody Pagination<DeliveryOrder> pagination, HttpServletResponse response) throws IOException {
pagination.setLimit(9999);
pagination.addFetch(root -> root.fetch(DeliveryOrder_.user, JoinType.LEFT));
pagination.addFetch(root -> root.fetch(DeliveryOrder_.auctionOrder, JoinType.LEFT).fetch(AuctionOrder_.vehicle, JoinType.LEFT).fetch(Vehicle_.venue, JoinType.LEFT));
List<DeliveryOrder> vehicles = pageDeliveryOrder(pagination).getContent();
List<DeliveryOrderBean> vehicleBeans = vehicles.stream().map(DeliveryOrderBean::new).toList();
ExcelExporter.exportExcel(response, "交付工单列表", "交付工单列表", DeliveryOrderBean.class, vehicleBeans);
......
......@@ -1455,6 +1455,27 @@
]
},
{
"code": "deposit_refund",
"name": "微信支付流水管理",
"type": "MENU",
"enabled": false,
"value": "/finance/deposit/refund",
"children": [
{
"code": "deposit_refund_1",
"name": "导出数据",
"type": "BUTTON",
"enabled": true
},
{
"code": "deposit_refund_2",
"name": "手动退款",
"type": "BUTTON",
"enabled": true
}
]
},
{
"code": "finance_withdraw",
"name": "提现审核",
"type": "MENU",
......@@ -1530,6 +1551,39 @@
]
},
{
"code": "finance_recharge",
"name": "微信支付流水",
"type": "MENU",
"enabled": true,
"value": "/finance/recharge",
"children": [
{
"code": "recharge_1",
"name": "查看提现详情页",
"type": "BUTTON",
"enabled": true
},
{
"code": "recharge_2",
"name": "查看完整的申请人账号",
"type": "BUTTON",
"enabled": true
},
{
"code": "recharge_3",
"name": "查看完整的收款账户信息",
"type": "BUTTON",
"enabled": true
},
{
"code": "recharge_4",
"name": "查看退款明细",
"type": "BUTTON",
"enabled": false
}
]
},
{
"code": "reports",
"name": "财务报表",
"type": "MENU",
......@@ -1707,7 +1761,27 @@
"name": "标签管理",
"type": "MENU",
"enabled": true,
"value": "/account/tag"
"value": "/account/tag",
"children": [
{
"code": "tag_1",
"name": "新建标签",
"type": "BUTTON",
"enabled": true
},
{
"code": "tag_2",
"name": "修改标签",
"type": "BUTTON",
"enabled": true
},
{
"code": "tag_3",
"name": "删除标签",
"type": "BUTTON",
"enabled": true
}
]
},
{
"code": "deposit",
......@@ -1813,7 +1887,27 @@
"name": "轮播图管理",
"type": "MENU",
"enabled": true,
"value": "/business/carousel"
"value": "/business/carousel",
"children": [
{
"code": "carousel_1",
"name": "新建轮播图",
"type": "BUTTON",
"enabled": true
},
{
"code": "carousel_2",
"name": "修改轮播图",
"type": "BUTTON",
"enabled": true
},
{
"code": "carousel_3",
"name": "删除轮播图",
"type": "BUTTON",
"enabled": true
}
]
},
{
"code": "price_rule",
......@@ -1999,6 +2093,24 @@
"enabled": true,
"value": "/business/notice",
"children": [
{
"code": "notice_template_1",
"name": "新建消息通知模板",
"type": "BUTTON",
"enabled": true
},
{
"code": "notice_template_2",
"name": "编辑消息通知模板",
"type": "BUTTON",
"enabled": true
},
{
"code": "notice_template_3",
"name": "查看消息通知模板",
"type": "BUTTON",
"enabled": true
}
]
},
{
......
......@@ -3,10 +3,11 @@
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<link rel="icon" href="/admin/main/favicon/favicon.ico" type="image/x-icon">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>广联二手车</title>
<script type="module" crossorigin src="/main/assets/index-DO3wyqf-.js"></script>
<link rel="stylesheet" crossorigin href="/main/assets/index-BQFCVsDg.css">
<title>专电优拍</title>
<script type="module" crossorigin src="/admin/main/assets/index-DPDYQjyF.js"></script>
<link rel="stylesheet" crossorigin href="/admin/main/assets/index-CZnIm2LY.css">
</head>
<body>
<div id="app"></div>
......
......@@ -136,11 +136,12 @@ public class LoginController extends LoginCommonController {
account.setOpenId(openid);
account.setAccountName(phoneNumber);
account.setMobile(phoneNumber);
account.setNickName(NameUtil.getName());
// account.setNickName(NameUtil.getName());
account.setNickName("车商" + phoneNumber.substring(phoneNumber.length() - 4));
account.setEnabled(true);
account.setCertifiedState(Account.CertifiedState.UNCERTIFIED);
account.setAccountType(Account.AccountType.COMMON);
account = accountService.addAccount(account);
account = accountService.addAccount(account, maLoginRequest.getRecommendCode());
} else {
if (!account.isEnabled()) {
accountInfo.setStatus(403);
......
......@@ -10,13 +10,11 @@ import com.glsx.usedcar.module.auction.entity.AuctionVehicle_;
import com.glsx.usedcar.module.auction.entity.Auction_;
import com.glsx.usedcar.module.auction.service.AuctionService;
import jakarta.annotation.Resource;
import jakarta.persistence.criteria.Expression;
import jakarta.persistence.criteria.Join;
import jakarta.persistence.criteria.JoinType;
import jakarta.persistence.criteria.Predicate;
import jakarta.persistence.criteria.*;
import lombok.extern.slf4j.Slf4j;
import org.springframework.data.domain.Page;
import org.springframework.util.CollectionUtils;
import org.springframework.util.StringUtils;
import org.springframework.web.bind.annotation.*;
import org.summerframework.orm.paging.Operator;
import org.summerframework.orm.paging.Pagination;
......@@ -113,9 +111,17 @@ public class AuctionController {
*/
@PostMapping("pageRandomAuctionVehicle")
public Page<AuctionVehicle> pageRandomAuctionVehicle(@RequestBody Pagination<AuctionVehicle> pagination, @RequestAttribute(value = LOGIN_ACCOUNT, required = false) Account account) {
String cityCode = (String) pagination.getDataValue("cities");
pagination.addCondition((root, query, builder) -> {
Expression<Double> randomExp = builder.function("RAND", Double.class); // MySQL 用 RAND()
if (StringUtils.hasText(cityCode)) {
CriteriaBuilder.Case<Number> caseExpr = builder.selectCase();
caseExpr.when(builder.like(root.get(AuctionVehicle_.auction).get(Auction_.cities), "%" + cityCode + "%"), 1).otherwise(0);
query.orderBy(builder.desc(caseExpr), builder.asc(randomExp)); // 按随机值升序(或降序,效果相同)
} else {
query.orderBy(builder.asc(randomExp)); // 按随机值升序(或降序,效果相同)
}
return null; // 无过滤条件,返回所有数据并随机排序
});
return pageAuctionVehicle(pagination, account);
......
......@@ -6,13 +6,17 @@ import com.github.binarywang.wxpay.bean.result.enums.TradeTypeEnum;
import com.github.binarywang.wxpay.exception.WxPayException;
import com.github.binarywang.wxpay.service.WxPayService;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.finance.entity.Deposit_;
import com.glsx.usedcar.module.finance.entity.Recharge;
import com.glsx.usedcar.module.finance.entity.Recharge_;
import com.glsx.usedcar.module.finance.service.TransactionService;
import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.data.domain.Page;
import org.springframework.web.bind.annotation.*;
import org.summerframework.core.exception.FieldException;
import org.summerframework.orm.paging.Pagination;
import static com.glsx.usedcar.web.WebConstants.LOGIN_ACCOUNT;
......@@ -31,18 +35,19 @@ public class RechargeController {
private String notifyUrl;
/**
* 充值接口
* 充值接口 (过时接口,不再使用)
* 详见:https://pay.weixin.qq.com/doc/v3/merchant/4012791856
*
* @param recharge
* @param account
* @return
*/
@Deprecated
@PostMapping("addRecharge")
public WxPayUnifiedOrderV3Result.JsapiResult addRecharge(@RequestBody Recharge recharge, @RequestAttribute(LOGIN_ACCOUNT) Account account) throws WxPayException, FieldException {
recharge = transactionService.addRecharge(account.getAccountId(), recharge);
WxPayUnifiedOrderV3Request request = new WxPayUnifiedOrderV3Request();
request.setDescription("充值");
request.setDescription("拍卖平台充值");
request.setOutTradeNo(recharge.getOutTradeNo());
request.setNotifyUrl(notifyUrl);
request.setSupportFapiao(false);
......@@ -58,14 +63,22 @@ public class RechargeController {
return result;
}
/**
* 调用统一下单接口(JSAPI)
* 详见:https://pay.weixin.qq.com/doc/v3/merchant/4012791856
*/
@PostMapping("createOrder")
public WxPayUnifiedOrderV3Result.JsapiResult createOrder(@RequestBody WxPayUnifiedOrderV3Request request) throws WxPayException {
return this.wxService.createOrderV3(TradeTypeEnum.JSAPI, request);
@PostMapping("pageRecharge")
public Page<Recharge> pageRecharge(@RequestBody Pagination<Recharge> pagination, @RequestAttribute(LOGIN_ACCOUNT) Account account) {
pagination.addFilter(account, Recharge_.account);
pagination.addCondition((root, query, builder) -> root.get(Recharge_.paymentTime).isNotNull());
return transactionService.pageRecharge(pagination);
}
// /**
// * 调用统一下单接口(JSAPI)
// * 详见:https://pay.weixin.qq.com/doc/v3/merchant/4012791856
// */
// @PostMapping("createOrder")
// public WxPayUnifiedOrderV3Result.JsapiResult createOrder(@RequestBody WxPayUnifiedOrderV3Request request) throws WxPayException {
// return this.wxService.createOrderV3(TradeTypeEnum.JSAPI, request);
// }
}
......@@ -67,7 +67,11 @@ public class TransactionController {
public Page<Transaction> pageTransaction(@RequestBody Pagination<Transaction> pagination, @RequestAttribute(LOGIN_ACCOUNT) Account account) {
pagination.addFilter(account, Transaction_.account);
pagination.addSortOrder(new SortOrder(Sort.Direction.DESC, Transaction_.createTime));
return transactionService.pageTransaction(pagination);
Page<Transaction> transactions = transactionService.pageTransaction(pagination);
// for (Transaction transaction : transactions) {
// transaction.setDeposit(depositService.getDepositByTransaction(transaction));
// }
return transactions;
}
/**
......
......@@ -71,10 +71,10 @@ public class WithdrawController {
return withdrawService.addWithdraw(withdraw);
}
@GetMapping("getWithdrawsByWaitUserConfirm")
public List<Withdraw> getWithdrawsByWaitUserConfirm(@RequestAttribute(LOGIN_ACCOUNT) Account account) {
return withdrawService.getWithdrawsByWaitUserConfirm(account);
}
// @GetMapping("getWithdrawsByWaitUserConfirm")
// public List<Withdraw> getWithdrawsByWaitUserConfirm(@RequestAttribute(LOGIN_ACCOUNT) Account account) {
// return withdrawService.getWithdrawsByWaitUserConfirm(account);
// }
@GetMapping("getWxPayMchId")
public String getWxPayMchId() {
......@@ -82,9 +82,9 @@ public class WithdrawController {
}
@PostMapping("updateWithdrawStateById")
public int updateWithdrawStateById(@RequestParam int withdrawId) {
withdrawService.updateWithdrawStateById(withdrawId);
return withdrawId;
}
// @PostMapping("updateWithdrawStateById")
// public int updateWithdrawStateById(@RequestParam int withdrawId) {
// withdrawService.updateWithdrawStateById(withdrawId);
// return withdrawId;
// }
}
\ No newline at end of file
......@@ -4,6 +4,7 @@ import cn.hutool.json.JSONUtil;
import com.github.binarywang.wxpay.bean.notify.SignatureHeader;
import com.github.binarywang.wxpay.bean.notify.WxPayNotifyV3Response;
import com.github.binarywang.wxpay.bean.notify.WxPayNotifyV3Result;
import com.github.binarywang.wxpay.bean.notify.WxPayRefundNotifyV3Result;
import com.github.binarywang.wxpay.bean.transfer.TransferBillsNotifyResult;
import com.github.binarywang.wxpay.constant.WxPayConstants;
import com.github.binarywang.wxpay.exception.WxPayException;
......@@ -14,6 +15,7 @@ import jakarta.annotation.Resource;
import jakarta.servlet.http.HttpServletRequest;
import lombok.extern.slf4j.Slf4j;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
......@@ -69,7 +71,7 @@ public class WxpayController {
transactionService.notifyRecharge(outTradeNo, openid, transactionId);
} else if ("order".equals(attach)) {
// 车款支付成功通知
transactionService.notifyAuctionOrder(outTradeNo, decryptRes.getAmount().getTotal() * 100, transactionId);
transactionService.notifyAuctionOrder(outTradeNo, decryptRes.getAmount().getTotal() / 100D, transactionId);
}
}
//成功返回200/204,body无需有内容
......@@ -88,6 +90,41 @@ public class WxpayController {
}
}
/**
* <pre>
* 退款回调通知处理
* 详见 https://pay.weixin.qq.com/doc/v3/merchant/4012791865
* </pre>
*
* @param notifyData
* @param request
* @return
* @throws WxPayException
*/
@PostMapping("notify/refund")
public ResponseEntity<String> parseRefundNotifyResult(@RequestBody String notifyData, HttpServletRequest request) {
SignatureHeader header = getRequestHeader(request);
try {
WxPayRefundNotifyV3Result res = this.wxService.parseRefundNotifyV3Result(notifyData, header);
WxPayRefundNotifyV3Result.DecryptNotifyResult decryptRes = res.getResult();
log.info("回调退款通知notify/refund开始");
log.info("回调退款OutRefundNo:" + decryptRes.getOutRefundNo());
// 根据自己业务场景需要构造返回对象
if (WxPayConstants.RefundStatus.SUCCESS.equals(decryptRes.getRefundStatus())) {
transactionService.notifyRechargeRefund(decryptRes);
//成功返回200/204,body无需有内容
return ResponseEntity.status(200).body("");
} else {
//失败返回4xx或5xx,且需要构造body信息
return ResponseEntity.status(500).body(WxPayNotifyV3Response.fail("错误原因"));
}
} catch (WxPayException e) {
//失败返回4xx或5xx,且需要构造body信息
return ResponseEntity.status(500).body(WxPayNotifyV3Response.fail("错误原因"));
}
}
@Nullable
@RequestMapping("transfer_notify")
public String transfer_notify(@RequestBody String notifyData, HttpServletRequest request) {
......
......@@ -68,8 +68,8 @@ spring:
data:
redis:
database: 6
host: 120.237.107.125
port: 16379
host: 192.168.0.20
port: 6379
password: Ml1234..
# 连接超时时间 单位 ms(毫秒)
timeout: 3000ms
......
......@@ -17,7 +17,7 @@ import java.util.List;
public interface CommissionRuleDao extends BaseRepository<CommissionRule, Integer>, JpaSpecificationExecutor<CommissionRule> {
@EntityGraph(attributePaths = {"accounts", "accountTags"})
List<CommissionRule> findByEnabledIsTrueAndEffectiveDateLessThanEqualAndExpireDateGreaterThanEqualOrderByApplicableTypeAsc(LocalDate effectiveDate, LocalDate expireDate);
List<CommissionRule> findByEnabledIsTrueAndMinPriceLessThanEqualAndMaxPriceGreaterThanAndEffectiveDateLessThanEqualAndExpireDateGreaterThanEqualOrderByApplicableTypeAsc(double price, double price2, LocalDate effectiveDate, LocalDate expireDate);
@EntityGraph(attributePaths = {"accounts", "accountTags"})
CommissionRule findByRuleId(int ruleId);
......
......@@ -56,6 +56,18 @@ public class CommissionRule extends AuditingEntity implements Serializable {
private String ruleName;
/**
* 最低成交价
*/
@Column(nullable = false)
private double minPrice;
/**
* 最高成交价
*/
@Column(nullable = false)
private double maxPrice;
/**
* 规则详情
*/
@Column(nullable = true, length = 255)
......
......@@ -92,9 +92,17 @@ public class AccountService extends AbstractAuctionService {
* @return 个人账户实例对象
*/
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public Account addAccount(Account account) {
public Account addAccount(Account account, String recommendCode) {
account.setLastLoginTime(LocalDateTime.now());
return accountDao.save(account);
Account save = accountDao.save(account);
if (StringUtils.hasText(recommendCode)) {
accountTagDao.findTopByRecommendCode(recommendCode).ifPresent(accountTag -> {
save.getAccountTags().add(accountTag);
accountTagDao.updateAccountCount();
});
}
return save;
}
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
......@@ -238,6 +246,23 @@ public class AccountService extends AbstractAuctionService {
}
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public void setTagAccounts(TagAccount tagAccount) {
List<Account> accounts = accountDao.findAllById(tagAccount.getAccountIds());
if (!CollectionUtils.isEmpty(tagAccount.getTagIds())) {
List<AccountTag> tags = accountTagDao.findAllById(tagAccount.getTagIds());
for (Account account : accounts) {
account.getAccountTags().clear();
account.getAccountTags().addAll(tags);
}
} else {
for (Account account : accounts) {
account.getAccountTags().clear();
}
}
accountTagDao.updateAccountCount();
}
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public Account updateMobile(Account customer) throws FieldException {
accountDao.checkExists("手机号码已存在用户绑定", customer, Account_.mobile);
return accountDao.updateById(customer.getAccountId(), UpdateField.of(Account_.mobile, customer.getMobile()));
......@@ -262,6 +287,7 @@ public class AccountService extends AbstractAuctionService {
if (StringUtils.hasText(recommendCode)) {
accountTagDao.findTopByRecommendCode(recommendCode).ifPresent(accountTag -> {
account.getAccountTags().add(accountTag);
accountTagDao.updateAccountCount();
});
}
} else if (account.getAccountType() == Account.AccountType.PERSON) {
......@@ -361,7 +387,7 @@ public class AccountService extends AbstractAuctionService {
// 参拍车商
long bidCount = bidDao.countAccountByCreateTimeBetween(startTime, endTime);
//新增中拍车商
long newDealCount = auctionOrderDao.countNewAccountByOrderStateAndTransferredTime(AuctionOrder.OrderState.CANCELED, startTime, endTime);
long newDealCount = auctionOrderDao.countNewAccountByOrderStateAndCreateTime(AuctionOrder.OrderState.CANCELED, startTime, endTime);
AccountDateStat accountTotalStat = new AccountDateStat();
accountTotalStat.setAccountCount((int) accountCount);
accountTotalStat.setActiveCount((int) activeCount);
......
......@@ -81,6 +81,8 @@ public class CommissionRuleService {
public CommissionRule updateCommissionRule(CommissionRule commissionRule) {
CommissionRule commissionRuleDB = commissionRuleDao.updateById(commissionRule,
CommissionRule_.ruleName,
CommissionRule_.maxPrice,
CommissionRule_.minPrice,
CommissionRule_.remark,
CommissionRule_.enabled,
CommissionRule_.ruleType,
......
......@@ -3,7 +3,9 @@ package com.glsx.usedcar.module.auction.dao;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.analysis.domain.IndexValue;
import com.glsx.usedcar.module.analysis.domain.ProfitRadioProjection;
import com.glsx.usedcar.module.auction.entity.Auction;
import com.glsx.usedcar.module.auction.entity.AuctionOrder;
import com.glsx.usedcar.module.vehicle.entity.Vehicle;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.EntityGraph;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
......@@ -29,6 +31,8 @@ public interface AuctionOrderDao extends BaseRepository<AuctionOrder, Integer>,
@EntityGraph(attributePaths = {"vehicle", "account", "auction"})
AuctionOrder findByOrderId(int orderId);
AuctionOrder findTopByAccountAndVehicleAndAuction(Account account, Vehicle vehicle, Auction auction);
AuctionOrder findTopByVehicle_VehicleIdOrderByCreateTimeDesc(int vehicleId);
AuctionOrder findTopByVehicle_VehicleIdAndAccount_AccountIdAndOrderStateOrderByCreateTimeDesc(int vehicleId, int accountId, AuctionOrder.OrderState orderState);
......@@ -49,10 +53,10 @@ public interface AuctionOrderDao extends BaseRepository<AuctionOrder, Integer>,
long countAccountByOrderStateAndTransferredTime(AuctionOrder.OrderState orderState, LocalDateTime startTime, LocalDateTime endTime);
@Query("""
select count(distinct o.account) from AuctionOrder o where o.orderState !=?1 and o.transferredTime between ?2 and ?3 and
not exists (select 1 from AuctionOrder o2 where o2.account = o.account and o2.orderState = ?1 and o2.transferredTime < ?2)
select count(distinct o.account) from AuctionOrder o where o.orderState !=?1 and o.createTime between ?2 and ?3 and
not exists (select 1 from AuctionOrder o2 where o2.account = o.account and o2.orderState = ?1 and o2.createTime < ?2)
""")
long countNewAccountByOrderStateAndTransferredTime(AuctionOrder.OrderState orderState, LocalDateTime startTime, LocalDateTime endTime);
long countNewAccountByOrderStateAndCreateTime(AuctionOrder.OrderState orderState, LocalDateTime startTime, LocalDateTime endTime);
long countByOrderState(AuctionOrder.OrderState orderState);
......
......@@ -30,7 +30,7 @@ public interface AuctionVehicleDao extends BaseRepository<AuctionVehicle, Intege
AuctionVehicle findTopByVehicle_VehicleIdOrderByAuctionStartTimeDesc(int vehicleId);
@EntityGraph(attributePaths = {"auction"})
List<AuctionVehicle> findByVehicle_VehicleIdOrderByAuctionStartTimeDesc(int vehicleId);
List<AuctionVehicle> findByVehicle_VehicleIdOrderByAuctionStartTimeDescAuction_CreateTimeDesc(int vehicleId);
@EntityGraph(attributePaths = {"vehicle", "auction"})
List<AuctionVehicle> findByAuction_AuctionIdOrderByAuctionStartTimeAsc(int auctionId);
......@@ -52,6 +52,8 @@ public interface AuctionVehicleDao extends BaseRepository<AuctionVehicle, Intege
@EntityGraph(attributePaths = {"vehicle", "auction"})
List<AuctionVehicle> findByAuctionStateAndAuctionEndTimeIsBefore(AuctionVehicle.AuctionState auctionState, LocalDateTime endTime);
long countByAuction(Auction auction);
long countByAuctionStateAndAuction(AuctionVehicle.AuctionState auctionState, Auction auction);
@Query("select count(distinct av.vehicle) from AuctionVehicle av where av.auditState = ?1 ")
......
package com.glsx.usedcar.module.auction.domain;
import lombok.Getter;
import lombok.Setter;
import java.util.List;
@Getter
@Setter
public class AuctionVehicleAddon {
private int auctionId;
private List<Integer> vehicleIds;
}
package com.glsx.usedcar.module.auction.service;
import com.github.binarywang.wxpay.bean.request.WxPayRefundV3Request;
import com.github.binarywang.wxpay.bean.result.WxPayRefundV3Result;
import com.github.binarywang.wxpay.exception.WxPayException;
import com.github.binarywang.wxpay.service.WxPayService;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.auction.entity.AuctionOrder;
import com.glsx.usedcar.module.auction.entity.AuctionVehicle;
......@@ -15,8 +19,10 @@ import com.sayalala.wework.wehook.config.MessagesenderProperties;
import com.sayalala.wework.wehook.entity.WeWorkWebhookMessage;
import com.sayalala.wework.wehook.service.MessageService;
import jakarta.annotation.Resource;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.util.CollectionUtils;
import org.springframework.util.StringUtils;
import org.springframework.web.bind.annotation.RequestParam;
import org.summerframework.core.util.DateTimeUtils;
import java.time.LocalDateTime;
......@@ -40,6 +46,7 @@ public abstract class AbstractAuctionService {
@Resource
protected MessagesenderProperties messagesenderProperties;
/**
* 通过订单查询用户的保证金
*
......@@ -73,6 +80,11 @@ public abstract class AbstractAuctionService {
if (Objects.nonNull(deposit)) {
// 解冻保证金
if (deposit.getDepositState() == Deposit.DepositState.FREEZE) {
// try {
// refund(deposit, "自动退款");
// } catch (WxPayException e) {
// e.printStackTrace();
// }
deposit.setDepositState(Deposit.DepositState.UNFREEZE);
// 计算应该从保证金中扣除多少金额,扣除来源于违约金
double depositDeduct = deposit.getAmount() + deposit.getTransaction().getAmount();
......@@ -85,6 +97,8 @@ public abstract class AbstractAuctionService {
}
}
/**
* 发送通知消息
*
......
......@@ -96,6 +96,10 @@ public class AuctionOrderService extends AbstractAuctionService {
return auctionOrderDao.sumOrderPriceByAuctionId(auctionId, AuctionOrder.OrderState.CANCELED).orElse(0.0);
}
public AuctionOrder getAuctionOrderByAccountAndAuctionVehicle(Account account, AuctionVehicle auctionVehicle) {
return auctionOrderDao.findTopByAccountAndVehicleAndAuction(account, auctionVehicle.getVehicle(), auctionVehicle.getAuction());
}
/**
* 分页查询
*
......@@ -340,9 +344,10 @@ public class AuctionOrderService extends AbstractAuctionService {
*/
private double calculateCommissionPrice(LocalDateTime now, Bid bid) {
Account account = bid.getAccount();
double commissionPrice = 0;
LocalDate today = now.toLocalDate();
List<CommissionRule> commissionRules = commissionRuleDao.findByEnabledIsTrueAndEffectiveDateLessThanEqualAndExpireDateGreaterThanEqualOrderByApplicableTypeAsc(today, today);
double bidPrice = bid.getBidPrice();
double commissionPrice = 0;
List<CommissionRule> commissionRules = commissionRuleDao.findByEnabledIsTrueAndMinPriceLessThanEqualAndMaxPriceGreaterThanAndEffectiveDateLessThanEqualAndExpireDateGreaterThanEqualOrderByApplicableTypeAsc(bidPrice, bidPrice, today, today);
CommissionRule commissionRule = null;
if (!commissionRules.isEmpty()) {
for (CommissionRule rule : commissionRules) {
......@@ -369,7 +374,7 @@ public class AuctionOrderService extends AbstractAuctionService {
}
}
if (Objects.nonNull(commissionRule)) {
commissionPrice = commissionRule.calCommissionPrice(bid.getBidPrice());
commissionPrice = commissionRule.calCommissionPrice(bidPrice);
}
return commissionPrice;
}
......
......@@ -10,6 +10,7 @@ import com.glsx.usedcar.module.account.entity.FavoriteId;
import com.glsx.usedcar.module.analysis.domain.AuctionVehicleRate;
import com.glsx.usedcar.module.auction.dao.AuctionDao;
import com.glsx.usedcar.module.auction.dao.AuctionVehicleDao;
import com.glsx.usedcar.module.auction.domain.AuctionVehicleAddon;
import com.glsx.usedcar.module.auction.domain.PendingAuction;
import com.glsx.usedcar.module.auction.entity.Auction;
import com.glsx.usedcar.module.auction.entity.AuctionVehicle;
......@@ -92,7 +93,7 @@ public class AuctionService extends AbstractAuctionService {
}
public List<AuctionVehicle> getAuctionVehiclesByVehicleId(int vehicleId) {
return auctionVehicleDao.findByVehicle_VehicleIdOrderByAuctionStartTimeDesc(vehicleId);
return auctionVehicleDao.findByVehicle_VehicleIdOrderByAuctionStartTimeDescAuction_CreateTimeDesc(vehicleId);
}
/**
......@@ -207,6 +208,49 @@ public class AuctionService extends AbstractAuctionService {
return auctionDb;
}
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public void addAuctionVehicles(AuctionVehicleAddon auctionVehicleAddon) throws FieldException {
Auction auction = auctionDao.findById(auctionVehicleAddon.getAuctionId()).orElseThrow();
if (auction.getAuctionState() == Auction.AuctionState.CLOSED) {
throw new FieldException("auctionState", Auction.AuctionState.CLOSED, "拍场已经结束");
}
if (auction.getAuctionState() == Auction.AuctionState.CANCELLED) {
throw new FieldException("auctionState", Auction.AuctionState.CANCELLED, "拍场已经取消");
}
List<Integer> vehicleIds = auctionVehicleAddon.getVehicleIds();
if (!vehicleIds.isEmpty()) {
List<String> sourceNos = vehicleDao.findBySourceNoVehicleStateNot(vehicleIds, Vehicle.VehicleState.PRICED);
if (!CollectionUtils.isEmpty(sourceNos)) {
String join = String.join(",", sourceNos);
throw new FieldException("sourceNos", sourceNos, "车源号:" + join + "的车辆状态不是待关联拍卖状态,请重新选择车辆");
}
}
List<Vehicle> vehicles = vehicleDao.findByIds(vehicleIds);
for (Vehicle vehicle : vehicles) {
AuctionVehicle av = new AuctionVehicle(auction, vehicle);
av.setPreviewStartTime(auction.getPreviewStartTime());
av.setAuctionStartTime(auction.getAuctionStartTime());
av.setAuctionEndTime(auction.getAuctionEndTime());
switch (auction.getAuctionState()) {
case WAIT_AUCTION -> {
av.setAuctionState(AuctionVehicle.AuctionState.WAIT_AUCTION);
vehicle.setVehicleState(Vehicle.VehicleState.WAIT_AUCTION);
}
case PREVIEW -> {
av.setAuctionState(AuctionVehicle.AuctionState.PREVIEW);
vehicle.setVehicleState(Vehicle.VehicleState.PREVIEW);
}
case AUCTIONING -> {
av.setAuctionState(AuctionVehicle.AuctionState.AUCTIONING);
vehicle.setVehicleState(Vehicle.VehicleState.AUCTIONING);
}
}
auctionVehicleDao.save(av);
}
auction.setVehicleCount((int) auctionVehicleDao.countByAuction(auction));
}
/**
* 通过拍卖场次主键删除数据
*
......
......@@ -127,6 +127,7 @@ public class BidService {
if (Objects.isNull(deposit)) {
//需要交的保证金
int depositAmount = auctionVehicle.getAuction().getDeposit();
// 查询已经交过的冻结的保证金
double freezeAmount = Math.abs(depositDao.sumFreezeByAccountId(accountId, Deposit.DepositState.FREEZE).orElse(0.0));
// 申请提现中的金额
......@@ -183,6 +184,8 @@ public class BidService {
auction.setAccountCount((int) bidDao.countAccountByAuction(auction));
auctionVehicle.setBidCount((int) bidDao.countByAuctionVehicle(auctionVehicle));
// 更新最后活跃时间
account.setLastLoginTime(LocalDateTime.now());
return bid;
}
......
......@@ -4,6 +4,7 @@ import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.auction.entity.Auction;
import com.glsx.usedcar.module.auction.entity.AuctionVehicle;
import com.glsx.usedcar.module.finance.entity.Deposit;
import com.glsx.usedcar.module.finance.entity.Transaction;
import com.glsx.usedcar.module.vehicle.entity.Vehicle;
import org.springframework.data.jpa.repository.EntityGraph;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
......@@ -20,6 +21,9 @@ public interface DepositDao extends BaseRepository<Deposit, Integer>, JpaSpecifi
Deposit findByAccountAndAuctionVehicle(Account account, AuctionVehicle auctionVehicle);
@EntityGraph(attributePaths = {"auctionVehicle.vehicle"})
Deposit findTopByTransaction(Transaction transaction);
Deposit findByAuctionVehicle_AuctionAndAuctionVehicle_VehicleAndDepositStateAndAccount(Auction auction, Vehicle vehicle, Deposit.DepositState depositState, Account account);
List<Deposit> findByAuctionVehicleAndDepositStateAndAccountNot(AuctionVehicle auctionVehicle, Deposit.DepositState depositState, Account account);
......@@ -27,12 +31,15 @@ public interface DepositDao extends BaseRepository<Deposit, Integer>, JpaSpecifi
@EntityGraph(attributePaths = {"account"})
List<Deposit> findByAuctionVehicleAndDepositState(AuctionVehicle auctionVehicle, Deposit.DepositState depositState);
@Query("SELECT SUM(d.amount) FROM Deposit d")
@Query("SELECT SUM(ts.amount) FROM Deposit d left join d.transaction ts ")
Optional<Double> sumAll();
@Query("SELECT SUM(ts.amount) FROM Deposit d left join d.transaction ts where d.depositState =?1")
@Query("SELECT SUM(ts.amount) FROM Deposit d left join d.transaction ts where d.depositState =?1 ")
Optional<Double> sumByDepositState(Deposit.DepositState depositState);
@Query("SELECT SUM(d.amount) FROM Deposit d where d.depositState =?1 ")
Optional<Double> sumAccountByDepositState(Deposit.DepositState depositState);
@Query("select d from Deposit d left join fetch d.transaction left join d.auctionVehicle av where d.account.accountId =?1 and av.vehicle.vehicleId =?2 and av.auction.auctionId =?3")
Deposit findByAccountAndVehicleAndAuction(int accountId, int vehicleId, int auctionId);
......
package com.glsx.usedcar.module.finance.dao;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.finance.entity.Deposit;
import com.glsx.usedcar.module.finance.entity.Recharge;
import com.glsx.usedcar.module.finance.entity.Withdraw;
import com.glsx.usedcar.module.meta.AuditState;
import org.springframework.data.jpa.repository.EntityGraph;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.summerframework.orm.BaseRepository;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Optional;
public interface RechargeDao extends BaseRepository<Recharge, Long>, JpaSpecificationExecutor<Recharge> {
......@@ -13,5 +19,10 @@ public interface RechargeDao extends BaseRepository<Recharge, Long>, JpaSpecific
@EntityGraph(attributePaths = {"account"})
Optional<Recharge> findTopByOutTradeNoAndOpenId(String outTradeNo, String openId);
Optional<Recharge> findTopByOutTradeNoAndTransactionId(String outTradeNo, String transactionId);
@EntityGraph(attributePaths = {"account"})
Optional<Recharge> findByRechargeId(long rechargeId);
List<Recharge> findByAccountAndPaymentTimeNotNullAndOutTradeNoNotNullAndPaymentTimeAfterAndRefundableAmountGreaterThanOrderByPaymentTimeAsc(Account account, LocalDateTime paymentTime, double refundableAmount);
}
package com.glsx.usedcar.module.finance.dao;
import com.glsx.usedcar.module.finance.entity.Recharge;
import com.glsx.usedcar.module.finance.entity.Refund;
import com.glsx.usedcar.module.finance.entity.Withdraw;
import org.springframework.data.jpa.repository.EntityGraph;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.summerframework.orm.BaseRepository;
import java.util.List;
import java.util.Optional;
public interface RefundDao extends BaseRepository<Refund, Long>, JpaSpecificationExecutor<Refund> {
@EntityGraph(attributePaths = {"recharge", "withdraw"})
Optional<Refund> findTopByRecharge_OutTradeNoAndRecharge_TransactionIdAndOutRefundNo(String outTradeNo, String transactionId, String outRefundNo);
@EntityGraph(attributePaths = {"recharge"})
List<Refund> findByWithdraw_WithdrawIdOrderByRefundTimeAsc(int withdrawId);
List<Refund> findByRecharge_RechargeIdOrderByRefundTimeAsc(int rechargeId);
@Query("select sum(r.refundAmount) from Refund r where r.withdraw =?1 and r.refundSuccessTime is not null")
Optional<Double> sumByWithdraw(Withdraw withdraw);
}
......@@ -36,13 +36,12 @@ public interface WithdrawDao extends BaseRepository<Withdraw, Integer>, JpaSpeci
* @param auditState
* @return
*/
@Query("select sum(w.amount) from Withdraw w where w.account.accountId =?1 and w.auditState =?2 or (w.auditState =com.glsx.usedcar.module.meta.AuditState.AUDITED and w.state not in ('SUCCESS','FAIL'))")
@Query("select sum(w.amount) from Withdraw w where w.account.accountId =?1 and w.auditState =?2")
Optional<Double> sumWithdrawByAccountAuditState(int accountId, AuditState auditState);
List<Withdraw> findByAuditStateAndAuditTimeIsAfterAndStateNotIn(AuditState auditState, LocalDateTime auditTime, List<String> status);
@EntityGraph(attributePaths = {"account"})
List<Withdraw> findByAccountAndStateOrderByPaymentTimeDesc(Account account, String state);
// @EntityGraph(attributePaths = {"account"})
// List<Withdraw> findByAccountAndStateOrderByPaymentTimeDesc(Account account, String state);
List<Withdraw> findByAccount_AccountIdAndAuditStateOrderByCreateTimeDesc(int accountId, AuditState auditState);
......
......@@ -11,6 +11,11 @@ public class DepositStat {
* 总金额
*/
private double totalAmount;
/**
* 可用金额
*/
private double depositAmount;
/**
* 冻结金额
*/
......
package com.glsx.usedcar.module.finance.entity;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.auction.entity.AuctionOrder;
import com.glsx.usedcar.module.auction.entity.AuctionVehicle;
import jakarta.persistence.*;
import jakarta.validation.constraints.NotNull;
......@@ -12,6 +13,8 @@ import org.hibernate.annotations.DynamicUpdate;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
import org.summerframework.orm.entity.AuditingTimeEntity;
import java.time.LocalDateTime;
import static jakarta.persistence.GenerationType.IDENTITY;
@Entity
......@@ -66,6 +69,65 @@ public class Deposit extends AuditingTimeEntity {
@Column(nullable = false)
private double amount;
// /**
// * 商户订单号
// */
// @Column(unique = true, nullable = false)
// private String outTradeNo;
//
// @Column
// private LocalDateTime paymentTime;
//
//
// /**
// * 退款备注
// */
// @Column
// private String refundRemark;
//
// /**
// * 微信支付订单号
// */
// @Column(name = "WXTRANSACTION_ID")
// private String transactionId;
//
// /**
// * 微信退款订单号
// */
// @Column
// private String outRefundNo;
//
// /**
// * 退款时间
// */
// @Column
// private LocalDateTime refundTime;
//
// /**
// * 退款成功时间
// */
// @Column
// private LocalDateTime refundSuccessTime;
//
// /**
// * 退款类型
// */
// @Column
// private String refundType;
//
// /**
// * 退款操作人
// */
// @Column
// private String refundOperator;
//
// /**
// * 退款状态
// */
// @Enumerated(EnumType.STRING)
// @Column(nullable = false, length = 32)
// private RefundState refundState;
/**
* 保证金状态
*/
......@@ -74,6 +136,12 @@ public class Deposit extends AuditingTimeEntity {
@Column(nullable = false, length = 32)
private DepositState depositState;
/**
* 关联的订单
*/
@Transient
private AuctionOrder auctionOrder;
public enum DepositState {
/**
* 冻结中
......@@ -85,10 +153,27 @@ public class Deposit extends AuditingTimeEntity {
UNFREEZE;
}
public enum RefundState {
/**
* 未退款
*/
UNREFUND,
/**
* 退款中
*/
REFUNDING,
/**
* 已退款
*/
REFUNDED,
}
public Deposit(Account account, AuctionVehicle auctionVehicle, Transaction transaction) {
this.account = account;
this.auctionVehicle = auctionVehicle;
this.transaction = transaction;
this.depositState = DepositState.FREEZE;
}
}
package com.glsx.usedcar.module.finance.entity;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.meta.AuditState;
import jakarta.persistence.*;
import jakarta.validation.constraints.NotNull;
import lombok.Getter;
......@@ -12,6 +13,8 @@ import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
import java.time.LocalDateTime;
import java.util.HashSet;
import java.util.Set;
import static jakarta.persistence.GenerationType.IDENTITY;
......@@ -42,11 +45,19 @@ public class Recharge implements java.io.Serializable {
@Column(nullable = false, length = 64)
private String openId;
/**
* 充值金额
*/
@Column(nullable = false)
private double amount;
/**
* 可退款金额
*/
@Column(nullable = false)
private double refundableAmount;
/**
* 付款类型
*/
@NotNull
......@@ -58,6 +69,9 @@ public class Recharge implements java.io.Serializable {
@Column
private LocalDateTime createTime;
/**
* 支付成功时间
*/
@Column
private LocalDateTime paymentTime;
......@@ -67,6 +81,24 @@ public class Recharge implements java.io.Serializable {
@Column
private String transactionId;
// /**
// * 退款状态
// */
// @Enumerated(EnumType.STRING)
// @Column(nullable = false, length = 32)
// private Deposit.RefundState refundState;
/**
* 退款记录
*/
@OneToMany(cascade = {CascadeType.REMOVE}, fetch = FetchType.LAZY, mappedBy = "recharge")
private Set<Refund> refunds = new HashSet<>();
public Recharge(Account account, String openId, double amount) {
this.account = account;
this.openId = openId;
......
package com.glsx.usedcar.module.finance.entity;
import com.glsx.usedcar.module.account.entity.Account;
import jakarta.persistence.*;
import jakarta.validation.constraints.NotNull;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;
import java.time.LocalDateTime;
import static jakarta.persistence.GenerationType.IDENTITY;
/**
* 退款
*/
@Entity
@DynamicInsert
@DynamicUpdate
@Table
@EntityListeners(AuditingEntityListener.class)
@Getter
@Setter
@NoArgsConstructor
public class Refund implements java.io.Serializable {
@Id
@GeneratedValue(strategy = IDENTITY)
@Column(unique = true, nullable = false)
private long refundId;
@NotNull
@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
@JoinColumns({@JoinColumn(name = "RECHARGE_ID", nullable = false)})
private Recharge recharge;
@NotNull
@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
@JoinColumns({@JoinColumn(name = "WITHDRAW_ID", nullable = false)})
private Withdraw withdraw;
/**
* 微信退款订单号
*/
@Column
private String outRefundNo;
/**
* 退款金额
*/
@Column
private double refundAmount;
/**
* 退款时间
*/
@Column
private LocalDateTime refundTime;
/**
* 退款成功时间
*/
@Column
private LocalDateTime refundSuccessTime;
public Refund(Withdraw withdraw, Recharge recharge, String outRefundNo, double refundAmount, LocalDateTime refundTime) {
this.withdraw = withdraw;
this.recharge = recharge;
this.outRefundNo = outRefundNo;
this.refundAmount = refundAmount;
this.refundTime = refundTime;
}
}
......@@ -90,6 +90,12 @@ public class Transaction extends AuditingTimeEntity implements Serializable {
@Column(nullable = false, length = 16)
private double surplus;
/**
* 关联的保证金信息
*/
@Transient
private Deposit deposit;
public Transaction(Account account, String transactionName, TransactionType transactionType, double amount, double surplus) {
this.account = account;
this.transactionName = transactionName;
......
......@@ -79,10 +79,16 @@ public class Withdraw extends AuditingEntity implements Serializable {
/**
* 审核时间
*/
@Column(nullable = false)
@Column
private LocalDateTime auditTime;
/**
* 审核人
*/
@Column
private String auditor;
/**
* 收款账户
*/
......@@ -110,55 +116,62 @@ public class Withdraw extends AuditingEntity implements Serializable {
@Column
private String rejectReason;
/**
* 付款单号
*/
@Column
private String transferBillNo;
/**
* 【单据状态】
* 可选取值
* ACCEPTED: 转账已受理
* PROCESSING: 转账处理中,转账结果尚未明确,如一直处于此状态,建议检查账户余额是否足够
* WAIT_USER_CONFIRM: 待收款用户确认,可拉起微信收款确认页面进行收款确认
* TRANSFERING: 转账结果尚未明确,可拉起微信收款确认页面再次重试确认收款
* SUCCESS: 转账成功
* FAIL: 转账失败
* CANCELING: 商户撤销请求受理成功,该笔转账正在撤销中
* CANCELLED: 转账撤销完成
*
* @see WxPayConstants.TransformBillState
*/
@Column
private String state;
/**
* 失败原因
*/
@Column
private String failReason;
/**
* 收款用户姓名
*/
@Column
private String transferName;
/**
* 付款金额
*/
@Column
private Double paymentAmount;
/**
* 用户确认时间
*/
@Column
private LocalDateTime confirmTime;
/**
* 发起付款时间
* 已退款金额
*/
@Column
private LocalDateTime paymentTime;
@Column(nullable = false, length = 16)
private double refundAmount;
// /**
// * 付款单号
// */
// @Column
// private String transferBillNo;
//
// /**
// * 【单据状态】
// * 可选取值
// * ACCEPTED: 转账已受理
// * PROCESSING: 转账处理中,转账结果尚未明确,如一直处于此状态,建议检查账户余额是否足够
// * WAIT_USER_CONFIRM: 待收款用户确认,可拉起微信收款确认页面进行收款确认
// * TRANSFERING: 转账结果尚未明确,可拉起微信收款确认页面再次重试确认收款
// * SUCCESS: 转账成功
// * FAIL: 转账失败
// * CANCELING: 商户撤销请求受理成功,该笔转账正在撤销中
// * CANCELLED: 转账撤销完成
// *
// * @see WxPayConstants.TransformBillState
// */
// @Column
// private String state;
// /**
// * 失败原因
// */
// @Column
// private String failReason;
// /**
// * 收款用户姓名
// */
// @Column
// private String transferName;
// /**
// * 付款金额
// */
// @Column
// private Double paymentAmount;
//
// /**
// * 用户确认时间
// */
// @Column
// private LocalDateTime confirmTime;
//
// /**
// * 发起付款时间
// */
// @Column
// private LocalDateTime paymentTime;
/**
* 转账成功时间
*/
......@@ -171,22 +184,5 @@ public class Withdraw extends AuditingEntity implements Serializable {
@Column
private String transferRemark;
/**
* 【微信支付】转账单号
*/
@Column
private String packageInfo;
public void setPayResult(TransferBillsGetResult result) {
double paymentAmount = Long.parseLong(result.getTransferAmount()) * 0.0 / 100;
LocalDateTime transferTime = DateTimeUtils.attemptParseLocalDateTime(result.getUpdateTime());
this.transferBillNo = result.getTransferBillNo();
this.state = result.getState();
this.failReason = result.getFailReason();
// this.transferName = result.getUserName();
this.paymentAmount = paymentAmount;
this.transferTime = transferTime;
this.transferRemark = result.getTransferRemark();
}
}
\ No newline at end of file
package com.glsx.usedcar.module.finance.service;
import com.github.binarywang.wxpay.exception.WxPayException;
import com.glsx.usedcar.module.account.dao.AccountDao;
import com.glsx.usedcar.module.account.entity.Account;
import com.glsx.usedcar.module.auction.dao.AuctionVehicleDao;
import com.glsx.usedcar.module.auction.entity.AuctionVehicle;
import com.glsx.usedcar.module.auction.service.AbstractAuctionService;
import com.glsx.usedcar.module.finance.dao.DepositDao;
import com.glsx.usedcar.module.finance.dao.DepositRuleDao;
import com.glsx.usedcar.module.finance.dao.TransactionDao;
import com.glsx.usedcar.module.finance.domain.DepositStat;
import com.glsx.usedcar.module.finance.entity.Deposit;
import com.glsx.usedcar.module.finance.entity.DepositRule;
import com.glsx.usedcar.module.finance.entity.DepositRule_;
import com.glsx.usedcar.module.finance.entity.Transaction;
import com.glsx.usedcar.module.meta.AuditState;
import com.glsx.usedcar.module.security.entity.User;
import com.glsx.usedcar.util.CoderGenerator;
import jakarta.annotation.Resource;
import org.hibernate.ObjectNotFoundException;
import org.springframework.data.domain.Page;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.StringUtils;
import org.summerframework.core.exception.FieldException;
import org.summerframework.orm.UpdateField;
import org.summerframework.orm.paging.Pagination;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
/**
......@@ -26,7 +39,7 @@ import java.util.Optional;
*/
@Service
@Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
public class DepositService {
public class DepositService extends AbstractAuctionService {
@Resource
private DepositRuleDao depositRuleDao;
......@@ -36,6 +49,12 @@ public class DepositService {
@Resource
private AccountDao accountDao;
@Resource
private AuctionVehicleDao auctionVehicleDao;
@Resource
private TransactionDao transactionDao;
/**
* 通过ID查询一个保证金规则
*
......@@ -50,6 +69,7 @@ public class DepositService {
return depositDao.findByDepositId(depositId);
}
/**
* 分页查询
*
......@@ -78,6 +98,7 @@ public class DepositService {
return depositDao.sumFreezeByAccountId(accountId, Deposit.DepositState.FREEZE).orElse(0.0);
}
/**
* 修改保证金规则
*
......@@ -139,12 +160,19 @@ public class DepositService {
return depositRuleDao.findAll();
}
public Deposit getDepositByTransaction(Transaction transaction) {
return depositDao.findTopByTransaction(transaction);
}
public DepositStat getDepositStat() {
DepositStat depositStat = new DepositStat();
Optional<Double> totalAmount = accountDao.sumAllSurplus();
// Optional<Double> totalAmount = depositDao.sumAll();
Optional<Double> depositAmount = depositDao.sumAccountByDepositState(Deposit.DepositState.FREEZE);
Optional<Double> freezeAmount = depositDao.sumByDepositState(Deposit.DepositState.FREEZE);
depositStat.setTotalAmount(totalAmount.orElse(0.0));
depositStat.setFreezeAmount(freezeAmount.orElse(0.0));
depositStat.setTotalAmount(Math.abs(totalAmount.orElse(0.0)));
depositStat.setDepositAmount(depositAmount.orElse(0.0));
depositStat.setFreezeAmount(Math.abs(freezeAmount.orElse(0.0)));
return depositStat;
}
......
package com.glsx.usedcar.module.finance.service;
import com.github.binarywang.wxpay.bean.notify.WxPayRefundNotifyV3Result;
import com.github.binarywang.wxpay.bean.request.WxPayRefundV3Request;
import com.github.binarywang.wxpay.bean.result.WxPayRefundV3Result;
import com.github.binarywang.wxpay.bean.transfer.TransferBillsRequest;
import com.github.binarywang.wxpay.bean.transfer.TransferBillsResult;
import com.github.binarywang.wxpay.exception.WxPayException;
import com.glsx.usedcar.gsc.GscApiInvoker;
import com.glsx.usedcar.gsc.GscInvoker;
import com.glsx.usedcar.module.account.dao.AccountDao;
......@@ -9,15 +15,10 @@ import com.glsx.usedcar.module.auction.entity.AuctionOrder;
import com.glsx.usedcar.module.auction.service.AbstractAuctionService;
import com.glsx.usedcar.module.business.entity.NoticeTemplate;
import com.glsx.usedcar.module.business.service.NoticeField;
import com.glsx.usedcar.module.finance.dao.OrderTransactionDao;
import com.glsx.usedcar.module.finance.dao.RechargeDao;
import com.glsx.usedcar.module.finance.dao.TransactionDao;
import com.glsx.usedcar.module.finance.dao.*;
import com.glsx.usedcar.module.finance.domain.OrderTransactionAmountStat;
import com.glsx.usedcar.module.finance.domain.OrderTransactionStat;
import com.glsx.usedcar.module.finance.entity.OrderTransaction;
import com.glsx.usedcar.module.finance.entity.OrderTransaction_;
import com.glsx.usedcar.module.finance.entity.Recharge;
import com.glsx.usedcar.module.finance.entity.Transaction;
import com.glsx.usedcar.module.finance.entity.*;
import com.glsx.usedcar.module.meta.AuditState;
import com.glsx.usedcar.module.track.dao.ApproveHistoryDao;
import com.glsx.usedcar.module.track.entity.ApproveHistory;
......@@ -34,6 +35,7 @@ import org.springframework.data.jpa.domain.Specification;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.StringUtils;
import org.summerframework.core.exception.FieldException;
import org.summerframework.core.util.DateTimeUtils;
import org.summerframework.orm.UpdateField;
......@@ -41,10 +43,7 @@ import org.summerframework.orm.paging.Pagination;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.Optional;
import java.util.*;
/**
* 交易明细(Transaction) 服务实现类
......@@ -71,11 +70,16 @@ public class TransactionService extends AbstractAuctionService {
@Resource
private RechargeDao rechargeDao;
@Resource
private RefundDao refundDao;
@Resource
private GscInvoker gscInvoker;
@Resource
private GscApiInvoker gscApiInvoker;
@Resource
private MessageSource messageSource;
@Resource
private WithdrawDao withdrawDao;
/**
* 通过ID查询一个交易明细
......@@ -96,6 +100,14 @@ public class TransactionService extends AbstractAuctionService {
return transactionDao.findAll(pagination, pagination.getPageRequest());
}
public Page<Recharge> pageRecharge(Pagination<Recharge> pagination) {
return rechargeDao.findAll(pagination, pagination.getPageRequest());
}
public Recharge getRechargeById(long rechargeId) {
return rechargeDao.findByRechargeId(rechargeId).orElseThrow(() -> new ObjectNotFoundException(rechargeId, Recharge.class.getSimpleName()));
}
/**
* 通过ID查询一个订单交易
......@@ -144,13 +156,7 @@ public class TransactionService extends AbstractAuctionService {
OrderTransaction save = orderTransactionDao.save(orderTransaction);
// 发送通知消息
sendNoticeMessage(NoticeTemplate.TemplateType.ORDER_TRANSACTION, Map.of(
NoticeField.ORDER_CODE, auctionOrder.getOrderCode(),
NoticeField.VEHICLE_NAME, auctionOrder.getVehicle().toVehicleName(),
NoticeField.AMOUNT, auctionOrder.getOrderPrice() + auctionOrder.getCommissionPrice(),
NoticeField.ORDER_ACCOUNT_NAME, auctionOrder.getAccount().getAccountName(),
NoticeField.ORDER_TRANSACTION_TIME, auctionOrder.getCreateTime()
));
sendNoticeMessage(NoticeTemplate.TemplateType.ORDER_TRANSACTION, Map.of(NoticeField.ORDER_CODE, auctionOrder.getOrderCode(), NoticeField.VEHICLE_NAME, auctionOrder.getVehicle().toVehicleName(), NoticeField.AMOUNT, auctionOrder.getOrderPrice() + auctionOrder.getCommissionPrice(), NoticeField.ORDER_ACCOUNT_NAME, auctionOrder.getAccount().getAccountName(), NoticeField.ORDER_TRANSACTION_TIME, auctionOrder.getCreateTime()));
return save;
}
}
......@@ -231,6 +237,7 @@ public class TransactionService extends AbstractAuctionService {
return rechargeDao.save(recharge);
}
/**
* 充值结果通知
*
......@@ -246,6 +253,7 @@ public class TransactionService extends AbstractAuctionService {
recharge.setPaymentTime(LocalDateTime.now());
recharge.setTransactionId(transactionId);
double amount = recharge.getAmount();
recharge.setRefundableAmount(amount);
Account account = recharge.getAccount();
account.setSurplus(account.getSurplus() + amount);
Transaction transaction = new Transaction(account, "充值成功,交易号:" + outTradeNo, Transaction.TransactionType.RECHARGE, amount, account.getSurplus());
......@@ -253,6 +261,7 @@ public class TransactionService extends AbstractAuctionService {
}
}
/**
* 订单支付结果通知
*
......@@ -283,6 +292,33 @@ public class TransactionService extends AbstractAuctionService {
}
}
/**
* 退款回调
*
* @param decryptRes
*/
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public void notifyRechargeRefund(WxPayRefundNotifyV3Result.DecryptNotifyResult decryptRes) {
Optional<Refund> refundOptional = refundDao.findTopByRecharge_OutTradeNoAndRecharge_TransactionIdAndOutRefundNo(decryptRes.getOutTradeNo(), decryptRes.getTransactionId(), decryptRes.getOutRefundNo());
if (refundOptional.isPresent()) {
Refund refund = refundOptional.get();
Recharge recharge = refund.getRecharge();
refund.setRefundSuccessTime(DateTimeUtils.attemptParseLocalDateTime(decryptRes.getSuccessTime()));
double refundAmount = refund.getRefundAmount();
Account account = recharge.getAccount();
account.setSurplus(account.getSurplus() - refundAmount);
recharge.setRefundableAmount(recharge.getRefundableAmount() - refundAmount);
Transaction transaction = new Transaction(account, "提现", Transaction.TransactionType.WITHDRAW, -refundAmount, account.getSurplus());
transactionDao.save(transaction);
refundDao.flush();
Withdraw withdraw = refund.getWithdraw();
withdraw.setRefundAmount(refundDao.sumByWithdraw(withdraw).orElse(0.0));
withdraw.setTransferTime(LocalDateTime.now());
}
}
public OrderTransaction getOrderTransactionByOrderId(int orderId) {
return orderTransactionDao.findTopByAuctionOrder_OrderIdOrderByCreateTimeDesc(orderId);
}
......@@ -319,4 +355,12 @@ public class TransactionService extends AbstractAuctionService {
return orderTransaction;
}
public List<Refund> getRefundsByWithdrawId(int withdrawId) {
return refundDao.findByWithdraw_WithdrawIdOrderByRefundTimeAsc(withdrawId);
}
public List<Refund> getRefundsByRechargeId(int rechargeId) {
return refundDao.findByRecharge_RechargeIdOrderByRefundTimeAsc(rechargeId);
}
}
\ No newline at end of file
......@@ -32,6 +32,11 @@ public class MaLoginRequest {
private String openId;
/**
* 推荐码
*/
private String recommendCode;
// /**
// * 历史缓存自动token登录
// */
......
......@@ -57,4 +57,7 @@ Account.CertifiedState.CERTIFY_FAILED=\u8BA4\u8BC1\u5931\u8D25
Account.CertifiedState.CERTIFIED=\u8BA4\u8BC1\u6210\u529F
Account.AccountType.COMMON=\u672A\u8BA4\u8BC1\u7528\u6237
Account.AccountType.PERSON=\u4E2A\u4EBA\u7528\u6237
Account.AccountType.COMPANY=\u8F66\u5546\u7528\u6237"
Account.AccountType.COMPANY=\u8F66\u5546\u7528\u6237
Deposit.RefundState.UNREFUND=\u672A\u9000\u6B3E
Deposit.RefundState.REFUNDING=\u9000\u6B3E\u4E2D
Deposit.RefundState.REFUNDED=\u5DF2\u9000\u6B3E
package org.summerframework.storage.platform;
import com.aspose.cells.*;
import com.aspose.words.*;
import com.aspose.words.ImageSaveOptions;
import com.aspose.words.ImageType;
import com.aspose.words.SaveFormat;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.RandomStringUtils;
import org.apache.commons.lang3.StringUtils;
......@@ -189,26 +185,6 @@ public abstract class AbstractStorageService implements StorageService {
}
protected void thumbWord(String sourceFilePath, String targetFilePath) throws Exception {
// 加载 Word 文档
Document doc = new Document(sourceFilePath);
// 渲染第一页为图片
ImageSaveOptions options = new ImageSaveOptions(SaveFormat.PNG);
// 从第0页开始 仅渲染一页
options.setPageSet(new PageSet(0, 1));
// 分辨率
options.setResolution(150);
String outputImagePath = sourceFilePath.substring(0, sourceFilePath.lastIndexOf(".")) + ".png";
doc.save(outputImagePath, options);
// 生成缩略图(可选)
File outputImageFile = new File(outputImagePath);
BufferedImage image = ImageIO.read(outputImageFile);
BufferedImage thumbnail = resizeImage(image, thumbnailsWidth, thumbnailsHeight); // 你可以指定缩略图大小
ImageIO.write(thumbnail, "png", new File(targetFilePath));
outputImageFile.delete();
}
protected void thumbPdf(String sourceFilePath, String targetFilePath) throws IOException {
// 加载 PDF 文件
FileInputStream file = new FileInputStream(sourceFilePath);
......@@ -227,30 +203,6 @@ public abstract class AbstractStorageService implements StorageService {
document.close();
}
protected void thumbExcel(String sourceFilePath, String targetFilePath) throws Exception {
// 加载 Excel 文件
Workbook workbook = new Workbook(sourceFilePath);
// 获取第一个工作表
Worksheet sheet = workbook.getWorksheets().get(0);
// 渲染选项
ImageOrPrintOptions options = new ImageOrPrintOptions();
options.setImageType(ImageType.PNG);
options.setOnePagePerSheet(true); // 将整张表渲染为一页
options.setOnlyArea(false); // 如果只想渲染有内容的区域,设置为 true
options.setPrintingPage(PrintingPageType.DEFAULT);
// 渲染器
SheetRender render = new SheetRender(sheet, options);
String outputImagePath = sourceFilePath.substring(0, sourceFilePath.lastIndexOf(".")) + ".png";
// 渲染第一页(通常每个 sheet 只有一页)
render.toImage(0, outputImagePath);
// 生成缩略图(可选)
File outputImageFile = new File(outputImagePath);
BufferedImage image = ImageIO.read(outputImageFile);
BufferedImage thumbnail = resizeImage(image, thumbnailsWidth, thumbnailsHeight); // 你可以指定缩略图大小
ImageIO.write(thumbnail, "png", new File(targetFilePath));
outputImageFile.delete();
}
protected void thumbPpt(String sourceFilePath, String targetFilePath) throws IOException {
// 1. 加载 PPTX 文件
......
......@@ -202,7 +202,7 @@ public class LocalFileService extends AbstractStorageService implements StorageS
@Override
public void removeFileInfo(@Nullable FileInfo fileInfo) {
if(Objects.nonNull(fileInfo)){
if (Objects.nonNull(fileInfo)) {
removeFile(fileInfo.getFilePath());
}
}
......@@ -318,9 +318,7 @@ public class LocalFileService extends AbstractStorageService implements StorageS
thumbPath = thumbDir + this.getRandomFileName(filename);
Thumbnails.of(sourceFile).size(thumbnailsWidth, thumbnailsHeight).crop(Positions.CENTER).toFile(absoluteDir + thumbPath);
} else if ("doc".equals(suffix) || "docx".equals(suffix)) {
thumbWord(sourceFile.getAbsolutePath(), absoluteDir + thumbPath);
} else if ("xls".equals(suffix) || "xlsx".equals(suffix)) {
thumbExcel(sourceFile.getAbsolutePath(), absoluteDir + thumbPath);
} else if ("ppt".equals(suffix) || "pptx".equals(suffix)) {
thumbPpt(sourceFile.getAbsolutePath(), absoluteDir + thumbPath);
} else if ("pdf".equals(suffix)) {
......
......@@ -13,9 +13,8 @@
"@tinymce/tinymce-vue": "^6.3.0",
"@types/lodash-es": "^4.17.12",
"ant-design-vue": "~4.2.1",
"autumn-antv": "~0.0.24",
"autumn-vue": "~0.4.47",
"axios": "~1.7.6",
"image-conversion": "^2.1.1",
"china-area-data": "^5.0.1",
"clipboard": "^2.0.11",
"core-js": "^3.6.5",
......@@ -58,8 +57,6 @@
"less-loader": "^6.0.0",
"typescript": "~4.5.2",
"vite": "^5.3.3",
"vite-plugin-electron": "^0.28.7",
"vite-plugin-electron-renderer": "^0.14.5",
"vite-svg-loader": "^5.1.0"
},
"volta":{
......
......@@ -102,13 +102,13 @@ import {
import 'dayjs/locale/zh-cn';
import zhCN from 'ant-design-vue/es/locale/zh_CN';
import lightTheme from '@/assets/style/theme/light';
import {Privilege} from "autumn-vue/lib/core/security/Privilege";
import {Privilege} from "lib/src/core/security/Privilege";
import BreadcrumbBar from "@/components/BreadcrumbBar.vue";
import {Getter} from "vuex-facing-decorator";
import PrivilegeMenu from "@/views/PrivilegeMenu.vue";
import {createVNode} from "vue";
import {message, Modal} from "ant-design-vue";
import Authenticity from "autumn-vue/lib/core/security/Authenticity";
import Authenticity from "lib/src/core/security/Authenticity";
@Component({
components: {
......
......@@ -4,43 +4,55 @@ import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Account} from "lib/src/entity/account/entity/Account";
import {AccountTag} from "lib/src/entity/account/entity/AccountTag";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {ApproveHistory} from "lib/src/entity/track/entity/ApproveHistory";
import {AccountTotalStat} from "lib/src/entity/account/domain/AccountTotalStat";
import {NameCount} from "lib/src/entity/analysis/domain/NameCount";
import {AccountProjection} from "lib/src/entity/account/domain/AccountProjection";
import {ProvinceCount} from "lib/src/entity/account/domain/ProvinceCount";
import {AccountDateStat} from "lib/src/entity/account/domain/AccountDateStat";
import {Pagination} from "lib/src/core/page/Pagination";
import {ResponseEntity} from "lib/src/domain/ResponseEntity";
import {TagAccount} from "lib/src/entity/account/domain/TagAccount";
// endregion
/**
* 个人账户(Account) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class AccountController{
/**
*/
static accountTagQrCode(axios:AxiosStatic, code: string, config?:any): Promise<AxiosResponse<ResponseEntity<byte[]>>> {
return axios.get('account/accountTagQrCode', {params: {code: code}}, config);
}
/**
* 新增用户分组
* @param accountTag
* @return AccountTag
*/
static addAccountTag(axios:AxiosStatic, accountTag: any): Promise<AxiosResponse<AccountTag>> {
static addAccountTag(axios:AxiosStatic, accountTag: AccountTag): Promise<AxiosResponse<AccountTag>> {
return axios.post('account/addAccountTag', accountTag);
}
/**
*/
static addTagAccounts(axios:AxiosStatic, tagAccount: any): Promise<AxiosResponse<boolean>> {
static addTagAccounts(axios:AxiosStatic, tagAccount: TagAccount): Promise<AxiosResponse<boolean>> {
return axios.post('account/addTagAccounts', tagAccount);
}
static setTagAccounts(axios:AxiosStatic, tagAccount: TagAccount): Promise<AxiosResponse<boolean>> {
return axios.post('account/setTagAccounts', tagAccount);
}
/**
* 审核用户申请
* @param approveHistory
* @return ApproveHistory
*/
static auditAccount(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<ApproveHistory>> {
static auditAccount(axios:AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<ApproveHistory>> {
return axios.post('account/auditAccount', approveHistory);
}
......@@ -50,19 +62,19 @@ export class AccountController{
* @param authentication
* @return ApproveHistory
*/
static auditAccounts(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<ApproveHistory>> {
static auditAccounts(axios:AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<ApproveHistory>> {
return axios.post('account/auditAccounts', approveHistory);
}
/**
*/
static enableAccount(axios:AxiosStatic, disableReason: any, accountId: number, enabled: boolean): Promise<AxiosResponse<boolean>> {
static enableAccount(axios:AxiosStatic, disableReason: string, accountId: number, enabled: boolean): Promise<AxiosResponse<boolean>> {
return axios.post('account/enableAccount', disableReason, {params: {accountId: accountId,enabled: enabled}});
}
/**
*/
static exportAccount(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportAccount(axios:AxiosStatic, pagination: Pagination<Account>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('account/exportAccount', pagination, config);
}
......@@ -146,7 +158,7 @@ export class AccountController{
* @param pagination
* @return Page
*/
static pageAccount(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Account>>> {
static pageAccount(axios:AxiosStatic, pagination: Pagination<Account>): Promise<AxiosResponse<Page<Account>>> {
return axios.post('account/pageAccount', pagination);
}
......@@ -157,7 +169,7 @@ export class AccountController{
* @param pagination
* @return Page
*/
static pageAccountTag(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AccountTag>>> {
static pageAccountTag(axios:AxiosStatic, pagination: Pagination<AccountTag>): Promise<AxiosResponse<Page<AccountTag>>> {
return axios.post('account/pageAccountTag', pagination);
}
......@@ -165,7 +177,7 @@ export class AccountController{
/**
*/
static pageAuctionAccount(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Account>>> {
static pageAuctionAccount(axios:AxiosStatic, pagination: Pagination<Account>): Promise<AxiosResponse<Page<Account>>> {
return axios.post('account/pageAuctionAccount', pagination);
}
......@@ -194,7 +206,7 @@ export class AccountController{
* @param account
* @return Account
*/
static updateAccount(axios:AxiosStatic, account: any): Promise<AxiosResponse<Account>> {
static updateAccount(axios:AxiosStatic, account: Account): Promise<AxiosResponse<Account>> {
return axios.post('account/updateAccount', account);
}
......@@ -203,7 +215,7 @@ export class AccountController{
* @param accountTag
* @return AccountTag
*/
static updateAccountTag(axios:AxiosStatic, accountTag: any): Promise<AxiosResponse<AccountTag>> {
static updateAccountTag(axios:AxiosStatic, accountTag: AccountTag): Promise<AxiosResponse<AccountTag>> {
return axios.post('account/updateAccountTag', accountTag);
}
......
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Agreement} from "lib/src/entity/business/entity/Agreement";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 协议管理(Agreement) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class AgreementController{
......@@ -18,7 +18,7 @@ export class AgreementController{
* @param agreement
* @return Agreement
*/
static addAgreement(axios:AxiosStatic, agreement: any): Promise<AxiosResponse<Agreement>> {
static addAgreement(axios:AxiosStatic, agreement: Agreement): Promise<AxiosResponse<Agreement>> {
return axios.post('agreement/addAgreement', agreement);
}
......@@ -42,7 +42,7 @@ export class AgreementController{
* @param pagination
* @return Page
*/
static pageAgreement(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Agreement>>> {
static pageAgreement(axios:AxiosStatic, pagination: Pagination<Agreement>): Promise<AxiosResponse<Page<Agreement>>> {
return axios.post('agreement/pageAgreement', pagination);
}
......@@ -62,7 +62,7 @@ export class AgreementController{
* @param agreement
* @return Agreement
*/
static updateAgreement(axios:AxiosStatic, agreement: any): Promise<AxiosResponse<Agreement>> {
static updateAgreement(axios:AxiosStatic, agreement: Agreement): Promise<AxiosResponse<Agreement>> {
return axios.post('agreement/updateAgreement', agreement);
}
......
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Appeal} from "lib/src/entity/auction/entity/Appeal";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 申诉(Appeal) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class AppealController{
......@@ -18,13 +18,13 @@ export class AppealController{
* @param appeal
* @return Appeal
*/
static acceptanceAppeal(axios:AxiosStatic, appeal: any): Promise<AxiosResponse<Appeal>> {
static acceptanceAppeal(axios:AxiosStatic, appeal: Appeal): Promise<AxiosResponse<Appeal>> {
return axios.post('appeal/acceptanceAppeal', appeal);
}
/**
*/
static exportAppeal(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportAppeal(axios:AxiosStatic, pagination: Pagination<Appeal>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('appeal/exportAppeal', pagination, config);
}
......@@ -48,7 +48,7 @@ export class AppealController{
* @param pagination
* @return Page
*/
static pageAppeal(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Appeal>>> {
static pageAppeal(axios:AxiosStatic, pagination: Pagination<Appeal>): Promise<AxiosResponse<Page<Appeal>>> {
return axios.post('appeal/pageAppeal', pagination);
}
......@@ -56,7 +56,7 @@ export class AppealController{
/**
*/
static processingAppeal(axios:AxiosStatic, appeal: any): Promise<AxiosResponse<Appeal>> {
static processingAppeal(axios:AxiosStatic, appeal: Appeal): Promise<AxiosResponse<Appeal>> {
return axios.post('appeal/processingAppeal', appeal);
}
......
......@@ -3,7 +3,9 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {AppraisePrice} from "lib/src/entity/auction/entity/AppraisePrice";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {ApproveHistory} from "lib/src/entity/track/entity/ApproveHistory";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
......@@ -12,13 +14,13 @@ export class AppraiseController{
/**
*/
static addAppraisePrice(axios:AxiosStatic, appraisePrice: any): Promise<AxiosResponse<AppraisePrice>> {
static addAppraisePrice(axios:AxiosStatic, appraisePrice: AppraisePrice): Promise<AxiosResponse<AppraisePrice>> {
return axios.post('appraise/addAppraisePrice', appraisePrice);
}
/**
*/
static auditAppraisePrice(axios:AxiosStatic, appraisePrice: any): Promise<AxiosResponse<AppraisePrice>> {
static auditAppraisePrice(axios:AxiosStatic, appraisePrice: ApproveHistory): Promise<AxiosResponse<AppraisePrice>> {
return axios.post('appraise/auditAppraisePrice', appraisePrice);
}
......@@ -30,7 +32,7 @@ export class AppraiseController{
/**
*/
static pageAppraisePrice(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AppraisePrice>>> {
static pageAppraisePrice(axios:AxiosStatic, pagination: Pagination<AppraisePrice>): Promise<AxiosResponse<Page<AppraisePrice>>> {
return axios.post('appraise/pageAppraisePrice', pagination);
}
......
......@@ -4,7 +4,9 @@ import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {AuctionChange} from "lib/src/entity/auction/entity/AuctionChange";
import {AuctionVehicleChange} from "lib/src/entity/auction/entity/AuctionVehicleChange";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {ApproveHistory} from "lib/src/entity/track/entity/ApproveHistory";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
......@@ -16,31 +18,31 @@ export class AuctionChangeController{
* @param auctionChange
* @return AuctionChange
*/
static addAuctionChange(axios:AxiosStatic, auctionChange: any): Promise<AxiosResponse<AuctionChange>> {
static addAuctionChange(axios:AxiosStatic, auctionChange: AuctionChange): Promise<AxiosResponse<AuctionChange>> {
return axios.post('auction/change/addAuctionChange', auctionChange);
}
/**
*/
static addAuctionVehicleChange(axios:AxiosStatic, auctionVehicleChange: any): Promise<AxiosResponse<AuctionVehicleChange>> {
static addAuctionVehicleChange(axios:AxiosStatic, auctionVehicleChange: AuctionVehicleChange): Promise<AxiosResponse<AuctionVehicleChange>> {
return axios.post('auction/change/addAuctionVehicleChange', auctionVehicleChange);
}
/**
*/
static auditAuctionChange(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<AuctionChange>> {
static auditAuctionChange(axios:AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<AuctionChange>> {
return axios.post('auction/change/auditAuctionChange', approveHistory);
}
/**
*/
static auditAuctionVehicleChange(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<AuctionVehicleChange>> {
static auditAuctionVehicleChange(axios:AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<AuctionVehicleChange>> {
return axios.post('auction/change/auditAuctionVehicleChange', approveHistory);
}
/**
*/
static pageAuctionChange(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AuctionChange>>> {
static pageAuctionChange(axios:AxiosStatic, pagination: Pagination<AuctionChange>): Promise<AxiosResponse<Page<AuctionChange>>> {
return axios.post('auction/change/pageAuctionChange', pagination);
}
......@@ -48,7 +50,7 @@ export class AuctionChangeController{
/**
*/
static pageAuctionVehicleChange(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AuctionVehicleChange>>> {
static pageAuctionVehicleChange(axios:AxiosStatic, pagination: Pagination<AuctionVehicleChange>): Promise<AxiosResponse<Page<AuctionVehicleChange>>> {
return axios.post('auction/change/pageAuctionVehicleChange', pagination);
}
......
import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
import dayjs, {Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Auction} from "lib/src/entity/auction/entity/Auction";
import {AuctionVehicle} from "lib/src/entity/auction/entity/AuctionVehicle";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {AuctionControl} from "lib/src/entity/auction/domain/AuctionControl";
import {ApproveHistory} from "lib/src/entity/track/entity/ApproveHistory";
import {AuctionVehicleRate} from "lib/src/entity/analysis/domain/AuctionVehicleRate";
import {Pagination} from "lib/src/core/page/Pagination";
import {PendingAuction} from "lib/src/entity/auction/domain/PendingAuction";
import {AuctionVehicleAddon} from "lib/src/entity/auction/domain/AuctionVehicleAddon";
// endregion
/**
/**
* 拍卖场次(Auction) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class AuctionController{
export class AuctionController {
/**
* 新增拍卖场次
* @param auction
* @return Auction
*/
static addAuction(axios:AxiosStatic, auction: any): Promise<AxiosResponse<Auction>> {
static addAuction(axios: AxiosStatic, auction: Auction): Promise<AxiosResponse<Auction>> {
return axios.post('auction/addAuction', auction);
}
/**
*/
static auditAuction(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<ApproveHistory>> {
static addAuctionVehicles(axios: AxiosStatic, auctionVehicleAddon: AuctionVehicleAddon): Promise<AxiosResponse<number>> {
return axios.post('auction/addAuctionVehicles', auctionVehicleAddon);
}
/**
*/
static auditAuction(axios: AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<ApproveHistory>> {
return axios.post('auction/auditAuction', approveHistory);
}
/**
*/
static auditAuctionVehicle(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<ApproveHistory>> {
static auditAuctionVehicle(axios: AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<ApproveHistory>> {
return axios.post('auction/auditAuctionVehicle', approveHistory);
}
......@@ -43,7 +51,7 @@ export class AuctionController{
* @param auctionId
* @return int
*/
static cancelAuctionById(axios:AxiosStatic, auctionId: number): Promise<AxiosResponse<number>> {
static cancelAuctionById(axios: AxiosStatic, auctionId: number): Promise<AxiosResponse<number>> {
return axios.delete('auction/cancelAuctionById', {params: {auctionId: auctionId}});
}
......@@ -52,19 +60,19 @@ export class AuctionController{
* @param auctionId
* @return Auction
*/
static getAuctionById(axios:AxiosStatic, auctionId: number): Promise<AxiosResponse<Auction>> {
static getAuctionById(axios: AxiosStatic, auctionId: number): Promise<AxiosResponse<Auction>> {
return axios.get('auction/getAuctionById', {params: {auctionId: auctionId}});
}
/**
*/
static getAuctionCountRate(axios:AxiosStatic): Promise<AxiosResponse<AuctionVehicleRate[]>> {
static getAuctionCountRate(axios: AxiosStatic): Promise<AxiosResponse<AuctionVehicleRate[]>> {
return axios.get('auction/getAuctionCountRate');
}
/**
*/
static getAuctionDetailById(axios:AxiosStatic, auctionId: number): Promise<AxiosResponse<Auction>> {
static getAuctionDetailById(axios: AxiosStatic, auctionId: number): Promise<AxiosResponse<Auction>> {
return axios.get('auction/getAuctionDetailById', {params: {auctionId: auctionId}});
}
......@@ -73,13 +81,13 @@ export class AuctionController{
* @param auctionId
* @return Auction
*/
static getAuctionInfoById(axios:AxiosStatic, auctionId: number): Promise<AxiosResponse<Auction>> {
static getAuctionInfoById(axios: AxiosStatic, auctionId: number): Promise<AxiosResponse<Auction>> {
return axios.get('auction/getAuctionInfoById', {params: {auctionId: auctionId}});
}
/**
*/
static getAuctionStateCountByType(axios:AxiosStatic, auctionType: any): Promise<AxiosResponse<any>> {
static getAuctionStateCountByType(axios: AxiosStatic, auctionType: any): Promise<AxiosResponse<any>> {
return axios.get('auction/getAuctionStateCountByType', {params: {auctionType: auctionType}});
}
......@@ -88,7 +96,7 @@ export class AuctionController{
* @param aucvehId
* @return AuctionVehicle
*/
static getAuctionVehicleById(axios:AxiosStatic, aucvehId: number): Promise<AxiosResponse<AuctionVehicle>> {
static getAuctionVehicleById(axios: AxiosStatic, aucvehId: number): Promise<AxiosResponse<AuctionVehicle>> {
return axios.get('auction/getAuctionVehicleById', {params: {aucvehId: aucvehId}});
}
......@@ -97,7 +105,7 @@ export class AuctionController{
* @param vehicleId
* @return AuctionVehicle
*/
static getAuctionVehicleByVehicleId(axios:AxiosStatic, vehicleId: number): Promise<AxiosResponse<AuctionVehicle>> {
static getAuctionVehicleByVehicleId(axios: AxiosStatic, vehicleId: number): Promise<AxiosResponse<AuctionVehicle>> {
return axios.get('auction/getAuctionVehicleByVehicleId', {params: {vehicleId: vehicleId}});
}
......@@ -106,31 +114,31 @@ export class AuctionController{
* @param auctionId
* @return List
*/
static getAuctionVehiclesByAuctionId(axios:AxiosStatic, auctionId: number): Promise<AxiosResponse<AuctionVehicle[]>> {
static getAuctionVehiclesByAuctionId(axios: AxiosStatic, auctionId: number): Promise<AxiosResponse<AuctionVehicle[]>> {
return axios.get('auction/getAuctionVehiclesByAuctionId', {params: {auctionId: auctionId}});
}
/**
*/
static getAuctionVehiclesByVehicleId(axios:AxiosStatic, vehicleId: number): Promise<AxiosResponse<AuctionVehicle[]>> {
static getAuctionVehiclesByVehicleId(axios: AxiosStatic, vehicleId: number): Promise<AxiosResponse<AuctionVehicle[]>> {
return axios.get('auction/getAuctionVehiclesByVehicleId', {params: {vehicleId: vehicleId}});
}
/**
*/
static getBiddingAuctions(axios:AxiosStatic): Promise<AxiosResponse<Auction[]>> {
static getBiddingAuctions(axios: AxiosStatic): Promise<AxiosResponse<Auction[]>> {
return axios.get('auction/getBiddingAuctions');
}
/**
*/
static getHotAuctionVehiclesOrderByBidCount(axios:AxiosStatic): Promise<AxiosResponse<AuctionVehicle[]>> {
static getHotAuctionVehiclesOrderByBidCount(axios: AxiosStatic): Promise<AxiosResponse<AuctionVehicle[]>> {
return axios.get('auction/getHotAuctionVehiclesOrderByBidCount');
}
/**
*/
static getTop3AuctionsByAuctionState(axios:AxiosStatic): Promise<AxiosResponse<Auction[]>> {
static getTop3AuctionsByAuctionState(axios: AxiosStatic): Promise<AxiosResponse<Auction[]>> {
return axios.get('auction/getTop3AuctionsByAuctionState');
}
......@@ -139,7 +147,7 @@ export class AuctionController{
* @param pagination
* @return Page
*/
static pageAuction(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Auction>>> {
static pageAuction(axios: AxiosStatic, pagination: Pagination<Auction>): Promise<AxiosResponse<Page<Auction>>> {
return axios.post('auction/pageAuction', pagination);
}
......@@ -147,7 +155,7 @@ export class AuctionController{
/**
*/
static pageAuctionControl(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AuctionControl>>> {
static pageAuctionControl(axios: AxiosStatic, pagination: Pagination<Auction>): Promise<AxiosResponse<Page<AuctionControl>>> {
return axios.post('auction/pageAuctionControl', pagination);
}
......@@ -158,7 +166,7 @@ export class AuctionController{
* @param pagination
* @return Page
*/
static pageAuctionVehicle(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AuctionVehicle>>> {
static pageAuctionVehicle(axios: AxiosStatic, pagination: Pagination<AuctionVehicle>): Promise<AxiosResponse<Page<AuctionVehicle>>> {
return axios.post('auction/pageAuctionVehicle', pagination);
}
......@@ -166,7 +174,7 @@ export class AuctionController{
/**
*/
static pageAuctionVehicleCtrl(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AuctionVehicle>>> {
static pageAuctionVehicleCtrl(axios: AxiosStatic, pagination: Pagination<AuctionVehicle>): Promise<AxiosResponse<Page<AuctionVehicle>>> {
return axios.post('auction/pageAuctionVehicleCtrl', pagination);
}
......@@ -177,7 +185,7 @@ export class AuctionController{
* @param pendingAuction
* @return int
*/
static pendingAuction(axios:AxiosStatic, pendingAuction: any): Promise<AxiosResponse<number>> {
static pendingAuction(axios: AxiosStatic, pendingAuction: PendingAuction): Promise<AxiosResponse<number>> {
return axios.post('auction/pendingAuction', pendingAuction);
}
......@@ -186,7 +194,7 @@ export class AuctionController{
* @param auctionId
* @return int
*/
static removeAuctionById(axios:AxiosStatic, auctionId: number): Promise<AxiosResponse<number>> {
static removeAuctionById(axios: AxiosStatic, auctionId: number): Promise<AxiosResponse<number>> {
return axios.delete('auction/removeAuctionById', {params: {auctionId: auctionId}});
}
......@@ -195,7 +203,7 @@ export class AuctionController{
* @param auction
* @return Auction
*/
static updateAuction(axios:AxiosStatic, auction: any): Promise<AxiosResponse<Auction>> {
static updateAuction(axios: AxiosStatic, auction: Auction): Promise<AxiosResponse<Auction>> {
return axios.post('auction/updateAuction', auction);
}
......
......@@ -3,12 +3,14 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {AuctionOrder} from "lib/src/entity/auction/entity/AuctionOrder";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {BidOrder} from "lib/src/entity/auction/domain/BidOrder";
import {ApproveHistory} from "lib/src/entity/track/entity/ApproveHistory";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 拍卖订单(AuctionOrder) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class AuctionOrderController{
......@@ -18,7 +20,7 @@ export class AuctionOrderController{
* @param bidOrder
* @return AuctionOrder
*/
static addAuctionOrder(axios:AxiosStatic, bidOrder: any): Promise<AxiosResponse<AuctionOrder>> {
static addAuctionOrder(axios:AxiosStatic, bidOrder: BidOrder): Promise<AxiosResponse<AuctionOrder>> {
return axios.post('auctionOrder/addAuctionOrder', bidOrder);
}
......@@ -28,7 +30,7 @@ export class AuctionOrderController{
* @return AuctionOrder
* @throws FieldException
*/
static auditTransferAuctionOrder(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<AuctionOrder>> {
static auditTransferAuctionOrder(axios:AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<AuctionOrder>> {
return axios.post('auctionOrder/auditTransferAuctionOrder', approveHistory);
}
......@@ -37,13 +39,13 @@ export class AuctionOrderController{
* @param auctionOrder
* @return AuctionOrder
*/
static cancelAuctionOrder(axios:AxiosStatic, auctionOrder: any): Promise<AxiosResponse<AuctionOrder>> {
static cancelAuctionOrder(axios:AxiosStatic, auctionOrder: AuctionOrder): Promise<AxiosResponse<AuctionOrder>> {
return axios.post('auctionOrder/cancelAuctionOrder', auctionOrder);
}
/**
*/
static exportAuctionOrder(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportAuctionOrder(axios:AxiosStatic, pagination: Pagination<AuctionOrder>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('auctionOrder/exportAuctionOrder', pagination, config);
}
......@@ -91,7 +93,7 @@ export class AuctionOrderController{
* @param pagination
* @return Page
*/
static pageAuctionOrder(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<AuctionOrder>>> {
static pageAuctionOrder(axios:AxiosStatic, pagination: Pagination<AuctionOrder>): Promise<AxiosResponse<Page<AuctionOrder>>> {
return axios.post('auctionOrder/pageAuctionOrder', pagination);
}
......
......@@ -2,11 +2,13 @@
import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {BankAccount} from "lib/src/entity/finance/entity/BankAccount";
import {Pagination} from "lib/src/core/page/Pagination";
import {Page} from "lib/src/core/page/Page";
// endregion
/**
* 银行账户(BankAccount) PI接口
* @author gonglei
* @since 2025-10-19 11:05:09
*/
export class BankAccountController{
......@@ -16,7 +18,7 @@ export class BankAccountController{
* @param bankAccount
* @return BankAccount
*/
static addBankAccount(axios:AxiosStatic, bankAccount: any): Promise<AxiosResponse<BankAccount>> {
static addBankAccount(axios:AxiosStatic, bankAccount: BankAccount): Promise<AxiosResponse<BankAccount>> {
return axios.post('bankAccount/addBankAccount', bankAccount);
}
......@@ -59,7 +61,7 @@ export class BankAccountController{
* @param pagination
* @return Page
*/
static pageBankAccount(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<BankAccount>>> {
static pageBankAccount(axios:AxiosStatic, pagination: Pagination<BankAccount>): Promise<AxiosResponse<Page<BankAccount>>> {
return axios.post('bankAccount/pageBankAccount', pagination);
}
......@@ -79,7 +81,7 @@ export class BankAccountController{
* @param bankAccount
* @return BankAccount
*/
static updateBankAccount(axios:AxiosStatic, bankAccount: any): Promise<AxiosResponse<BankAccount>> {
static updateBankAccount(axios:AxiosStatic, bankAccount: BankAccount): Promise<AxiosResponse<BankAccount>> {
return axios.post('bankAccount/updateBankAccount', bankAccount);
}
......
......@@ -3,14 +3,14 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Bid} from "lib/src/entity/auction/entity/Bid";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {IndexValue} from "lib/src/entity/analysis/domain/IndexValue";
import {ProvinceRate} from "lib/src/entity/analysis/domain/ProvinceRate";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 投标竞价(Bid) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class BidController{
......@@ -43,7 +43,7 @@ export class BidController{
* @param pagination
* @return Page
*/
static pageBid(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Bid>>> {
static pageBid(axios:AxiosStatic, pagination: Pagination<Bid>): Promise<AxiosResponse<Page<Bid>>> {
return axios.post('bid/pageBid', pagination);
}
......
......@@ -11,7 +11,7 @@ export class BreachController{
/**
*/
static addBreachRecord(axios:AxiosStatic, breachRecord: any): Promise<AxiosResponse<BreachRecord>> {
static addBreachRecord(axios:AxiosStatic, breachRecord: BreachRecord): Promise<AxiosResponse<BreachRecord>> {
return axios.post('breach/addBreachRecord', breachRecord);
}
......
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Carousel} from "lib/src/entity/business/entity/Carousel";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 轮播图(Carousel) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class CarouselController{
......@@ -18,7 +18,7 @@ export class CarouselController{
* @param carousel
* @return Carousel
*/
static addCarousel(axios:AxiosStatic, carousel: any): Promise<AxiosResponse<Carousel>> {
static addCarousel(axios:AxiosStatic, carousel: Carousel): Promise<AxiosResponse<Carousel>> {
return axios.post('carousel/addCarousel', carousel);
}
......@@ -36,7 +36,7 @@ export class CarouselController{
* @param pagination
* @return Page
*/
static pageCarousel(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Carousel>>> {
static pageCarousel(axios:AxiosStatic, pagination: Pagination<Carousel>): Promise<AxiosResponse<Page<Carousel>>> {
return axios.post('carousel/pageCarousel', pagination);
}
......@@ -56,7 +56,7 @@ export class CarouselController{
* @param carousel
* @return Carousel
*/
static updateCarousel(axios:AxiosStatic, carousel: any): Promise<AxiosResponse<Carousel>> {
static updateCarousel(axios:AxiosStatic, carousel: Carousel): Promise<AxiosResponse<Carousel>> {
return axios.post('carousel/updateCarousel', carousel);
}
......
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {CommissionRule} from "lib/src/entity/account/entity/CommissionRule";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 佣金规则(CommissionRule) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class CommissionRuleController{
......@@ -18,7 +18,7 @@ export class CommissionRuleController{
* @param commissionRule
* @return CommissionRule
*/
static addCommissionRule(axios:AxiosStatic, commissionRule: any): Promise<AxiosResponse<CommissionRule>> {
static addCommissionRule(axios:AxiosStatic, commissionRule: CommissionRule): Promise<AxiosResponse<CommissionRule>> {
return axios.post('commissionRule/addCommissionRule', commissionRule);
}
......@@ -61,7 +61,7 @@ export class CommissionRuleController{
* @param pagination
* @return Page
*/
static pageCommissionRule(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<CommissionRule>>> {
static pageCommissionRule(axios:AxiosStatic, pagination: Pagination<CommissionRule>): Promise<AxiosResponse<Page<CommissionRule>>> {
return axios.post('commissionRule/pageCommissionRule', pagination);
}
......@@ -81,7 +81,7 @@ export class CommissionRuleController{
* @param commissionRule
* @return CommissionRule
*/
static updateCommissionRule(axios:AxiosStatic, commissionRule: any): Promise<AxiosResponse<CommissionRule>> {
static updateCommissionRule(axios:AxiosStatic, commissionRule: CommissionRule): Promise<AxiosResponse<CommissionRule>> {
return axios.post('commissionRule/updateCommissionRule', commissionRule);
}
......
import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs, {Dayjs} from 'dayjs';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {BusinessConfig} from "lib/src/entity/business/domain/BusinessConfig";
import {ESignPartAConfig} from "lib/src/domain/ESignPartAConfig";
import {DarkBidPriceRange} from "lib/src/entity/business/domain/DarkBidPriceRange";
import {LightBidPriceRange} from "lib/src/entity/business/domain/LightBidPriceRange";
// endregion
/**
/**
*/
export class ConfigController {
export class ConfigController{
/**
* 查询SystemConfig
* @return BusinessConfig
*/
static getBusinessConfig(axios: AxiosStatic): Promise<AxiosResponse<BusinessConfig>> {
static getBusinessConfig(axios:AxiosStatic): Promise<AxiosResponse<BusinessConfig>> {
return axios.get('config/getBusinessConfig');
}
/**
*/
static getDarkBidPriceRange(axios: AxiosStatic): Promise<AxiosResponse<DarkBidPriceRange>> {
static getDarkBidPriceRange(axios:AxiosStatic): Promise<AxiosResponse<DarkBidPriceRange>> {
return axios.get('config/getDarkBidPriceRange');
}
/**
*/
static getESignPartAConfig(axios: AxiosStatic): Promise<AxiosResponse<ESignPartAConfig>> {
static getESignPartAConfig(axios:AxiosStatic): Promise<AxiosResponse<ESignPartAConfig>> {
return axios.get('config/getESignPartAConfig');
}
/**
*/
static getLightBidPriceRange(axios: AxiosStatic): Promise<AxiosResponse<LightBidPriceRange>> {
static getLightBidPriceRange(axios:AxiosStatic): Promise<AxiosResponse<LightBidPriceRange>> {
return axios.get('config/getLightBidPriceRange');
}
......@@ -43,25 +43,25 @@ export class ConfigController {
* @param businessConfig
* @return boolean
*/
static updateBusinessConfig(axios: AxiosStatic, businessConfig: any): Promise<AxiosResponse<boolean>> {
static updateBusinessConfig(axios:AxiosStatic, businessConfig: BusinessConfig): Promise<AxiosResponse<boolean>> {
return axios.post('config/updateBusinessConfig', businessConfig);
}
/**
*/
static updateDarkBidPriceRange(axios: AxiosStatic, darkBidPriceRange: any): Promise<AxiosResponse<boolean>> {
static updateDarkBidPriceRange(axios:AxiosStatic, darkBidPriceRange: DarkBidPriceRange): Promise<AxiosResponse<boolean>> {
return axios.post('config/updateDarkBidPriceRange', darkBidPriceRange);
}
/**
*/
static updateESignPartAConfig(axios: AxiosStatic, businessConfig: any): Promise<AxiosResponse<boolean>> {
static updateESignPartAConfig(axios:AxiosStatic, businessConfig: ESignPartAConfig): Promise<AxiosResponse<boolean>> {
return axios.post('config/updateESignPartAConfig', businessConfig);
}
/**
*/
static updateLightBidPriceRange(axios: AxiosStatic, lightBidPriceRange: any): Promise<AxiosResponse<boolean>> {
static updateLightBidPriceRange(axios:AxiosStatic, lightBidPriceRange: LightBidPriceRange): Promise<AxiosResponse<boolean>> {
return axios.post('config/updateLightBidPriceRange', lightBidPriceRange);
}
......
......@@ -4,12 +4,12 @@ import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Contract} from "lib/src/entity/auction/entity/Contract";
import {ContractTemplate} from "lib/src/entity/auction/entity/ContractTemplate";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 合同(Contract) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class ContractController{
......@@ -19,7 +19,7 @@ export class ContractController{
* @param contract
* @return Contract
*/
static addContract(axios:AxiosStatic, contract: any): Promise<AxiosResponse<Contract>> {
static addContract(axios:AxiosStatic, contract: Contract): Promise<AxiosResponse<Contract>> {
return axios.post('contract/addContract', contract);
}
......@@ -28,7 +28,7 @@ export class ContractController{
* @param contractTemplate
* @return ContractTemplate
*/
static addContractTemplate(axios:AxiosStatic, contractTemplate: any): Promise<AxiosResponse<ContractTemplate>> {
static addContractTemplate(axios:AxiosStatic, contractTemplate: ContractTemplate): Promise<AxiosResponse<ContractTemplate>> {
return axios.post('contract/addContractTemplate', contractTemplate);
}
......@@ -86,7 +86,7 @@ export class ContractController{
* @param pagination
* @return Page
*/
static pageContract(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Contract>>> {
static pageContract(axios:AxiosStatic, pagination: Pagination<Contract>): Promise<AxiosResponse<Page<Contract>>> {
return axios.post('contract/pageContract', pagination);
}
......@@ -97,7 +97,7 @@ export class ContractController{
* @param pagination
* @return Page
*/
static pageContractTemplate(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<ContractTemplate>>> {
static pageContractTemplate(axios:AxiosStatic, pagination: Pagination<ContractTemplate>): Promise<AxiosResponse<Page<ContractTemplate>>> {
return axios.post('contract/pageContractTemplate', pagination);
}
......@@ -135,7 +135,7 @@ export class ContractController{
* @param contractTemplate
* @return ContractTemplate
*/
static updateContractTemplate(axios:AxiosStatic, contractTemplate: any): Promise<AxiosResponse<ContractTemplate>> {
static updateContractTemplate(axios:AxiosStatic, contractTemplate: ContractTemplate): Promise<AxiosResponse<ContractTemplate>> {
return axios.post('contract/updateContractTemplate', contractTemplate);
}
......
......@@ -2,6 +2,8 @@
import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Vehicle} from "lib/src/entity/vehicle/entity/Vehicle";
import {DeliveryStatus} from "lib/src/entity/auction/domain/DeliveryStatus";
// endregion
/**
......@@ -10,13 +12,13 @@ export class DataSyncController{
/**
*/
static pushCarData(axios:AxiosStatic, vehicle: any): Promise<AxiosResponse<ResponseResult>> {
static pushCarData(axios:AxiosStatic, vehicle: Vehicle): Promise<AxiosResponse<ResponseResult>> {
return axios.post('//pushCarData', vehicle);
}
/**
*/
static syncDeliveryStatus(axios:AxiosStatic, deliveryStatus: any): Promise<AxiosResponse<ResponseResult>> {
static syncDeliveryStatus(axios:AxiosStatic, deliveryStatus: DeliveryStatus): Promise<AxiosResponse<ResponseResult>> {
return axios.post('//syncDeliveryStatus', deliveryStatus);
}
......
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {DeliveryOrder} from "lib/src/entity/auction/entity/DeliveryOrder";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 交付订单(DeliveryOrder) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class DeliveryOrderController{
......@@ -18,13 +18,13 @@ export class DeliveryOrderController{
* @param deliveryOrder
* @return DeliveryOrder
*/
static assignDeliveryOrder(axios:AxiosStatic, deliveryOrder: any): Promise<AxiosResponse<DeliveryOrder>> {
static assignDeliveryOrder(axios:AxiosStatic, deliveryOrder: DeliveryOrder): Promise<AxiosResponse<DeliveryOrder>> {
return axios.post('deliveryOrder/assignDeliveryOrder', deliveryOrder);
}
/**
*/
static cancelDeliveryOrder(axios:AxiosStatic, deliveryOrder: any): Promise<AxiosResponse<DeliveryOrder>> {
static cancelDeliveryOrder(axios:AxiosStatic, deliveryOrder: DeliveryOrder): Promise<AxiosResponse<DeliveryOrder>> {
return axios.post('deliveryOrder/cancelDeliveryOrder', deliveryOrder);
}
......@@ -36,7 +36,7 @@ export class DeliveryOrderController{
/**
*/
static exportDeliveryOrder(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportDeliveryOrder(axios:AxiosStatic, pagination: Pagination<DeliveryOrder>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('deliveryOrder/exportDeliveryOrder', pagination, config);
}
......@@ -84,7 +84,7 @@ export class DeliveryOrderController{
* @param deliveryOrder
* @return DeliveryOrder
*/
static handleDeliveryOrder(axios:AxiosStatic, deliveryOrder: any): Promise<AxiosResponse<DeliveryOrder>> {
static handleDeliveryOrder(axios:AxiosStatic, deliveryOrder: DeliveryOrder): Promise<AxiosResponse<DeliveryOrder>> {
return axios.post('deliveryOrder/handleDeliveryOrder', deliveryOrder);
}
......@@ -93,7 +93,7 @@ export class DeliveryOrderController{
* @param pagination
* @return Page
*/
static pageDeliveryOrder(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<DeliveryOrder>>> {
static pageDeliveryOrder(axios:AxiosStatic, pagination: Pagination<DeliveryOrder>): Promise<AxiosResponse<Page<DeliveryOrder>>> {
return axios.post('deliveryOrder/pageDeliveryOrder', pagination);
}
......
......@@ -3,14 +3,14 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {DepositRule} from "lib/src/entity/finance/entity/DepositRule";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Deposit} from "lib/src/entity/finance/entity/Deposit";
import {DepositStat} from "lib/src/entity/finance/domain/DepositStat";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 保证金规则(DepositRule) PI接口
* @author gonglei
* @since 2025-10-13 12:18:10
*/
export class DepositController{
......@@ -20,7 +20,7 @@ export class DepositController{
* @param depositRule
* @return DepositRule
*/
static addDepositRule(axios:AxiosStatic, depositRule: any): Promise<AxiosResponse<DepositRule>> {
static addDepositRule(axios:AxiosStatic, depositRule: DepositRule): Promise<AxiosResponse<DepositRule>> {
return axios.post('depositRule/addDepositRule', depositRule);
}
......@@ -35,11 +35,17 @@ export class DepositController{
/**
*/
static exportDeposit(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportDeposit(axios:AxiosStatic, pagination: Pagination<Deposit>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('depositRule/exportDeposit', pagination, config);
}
/**
*/
static exportDepositRefund(axios:AxiosStatic, pagination: Pagination<Deposit>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('depositRule/exportDepositRefund', pagination, config);
}
/**
* 查询全部$保证金规则
* @return List
*/
......@@ -90,18 +96,26 @@ export class DepositController{
/**
*/
static pageDeposit(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Deposit>>> {
static pageDeposit(axios:AxiosStatic, pagination: Pagination<Deposit>): Promise<AxiosResponse<Page<Deposit>>> {
return axios.post('depositRule/pageDeposit', pagination);
}
static PAGE_DEPOSIT = 'depositRule/pageDeposit';
/**
*/
static pageDepositFetchOrder(axios:AxiosStatic, pagination: Pagination<Deposit>): Promise<AxiosResponse<Page<Deposit>>> {
return axios.post('depositRule/pageDepositFetchOrder', pagination);
}
static PAGE_DEPOSIT_FETCH_ORDER = 'depositRule/pageDepositFetchOrder';
/**
* 分页查询保证金规则
* @param pagination
* @return Page
*/
static pageDepositRule(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<DepositRule>>> {
static pageDepositRule(axios:AxiosStatic, pagination: Pagination<DepositRule>): Promise<AxiosResponse<Page<DepositRule>>> {
return axios.post('depositRule/pageDepositRule', pagination);
}
......@@ -121,7 +135,7 @@ export class DepositController{
* @param depositRule
* @return DepositRule
*/
static updateDepositRule(axios:AxiosStatic, depositRule: any): Promise<AxiosResponse<DepositRule>> {
static updateDepositRule(axios:AxiosStatic, depositRule: DepositRule): Promise<AxiosResponse<DepositRule>> {
return axios.post('depositRule/updateDepositRule', depositRule);
}
......
......@@ -2,11 +2,12 @@
import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Dictionary} from "lib/src/core/dictionary/Dictionary";
import {Diction} from "lib/src/core/dictionary/Diction";
// endregion
/**
* 字典表(Dictionary) 控制层
* @author gonglei
* @since 2022-04-18 16:06:57
*/
export class DictionaryController{
......@@ -16,7 +17,7 @@ export class DictionaryController{
* @param dictionary
* @return Dictionary
*/
static addDictionary(axios:AxiosStatic, dictionary: any): Promise<AxiosResponse<Dictionary>> {
static addDictionary(axios:AxiosStatic, dictionary: Dictionary): Promise<AxiosResponse<Dictionary>> {
return axios.post('dictionary/addDictionary', dictionary);
}
......@@ -68,7 +69,7 @@ export class DictionaryController{
* @param dictionary
* @return Dictionary
*/
static updateDictionary(axios:AxiosStatic, dictionary: any): Promise<AxiosResponse<Dictionary>> {
static updateDictionary(axios:AxiosStatic, dictionary: Dictionary): Promise<AxiosResponse<Dictionary>> {
return axios.post('dictionary/updateDictionary', dictionary);
}
......
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Favorite} from "lib/src/entity/account/entity/Favorite";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 收藏(Favorite) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class FavoriteController{
......@@ -18,7 +18,7 @@ export class FavoriteController{
* @param favorite
* @return Favorite
*/
static addFavorite(axios:AxiosStatic, favorite: any): Promise<AxiosResponse<Favorite>> {
static addFavorite(axios:AxiosStatic, favorite: Favorite): Promise<AxiosResponse<Favorite>> {
return axios.post('favorite/addFavorite', favorite);
}
......@@ -27,7 +27,7 @@ export class FavoriteController{
* @param pagination
* @return Page
*/
static pageFavorite(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Favorite>>> {
static pageFavorite(axios:AxiosStatic, pagination: Pagination<Favorite>): Promise<AxiosResponse<Page<Favorite>>> {
return axios.post('favorite/pageFavorite', pagination);
}
......
......@@ -4,12 +4,12 @@ import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {NoticeMessage} from "lib/src/entity/business/entity/NoticeMessage";
import {NoticeTemplate} from "lib/src/entity/business/entity/NoticeTemplate";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 通知模板(NoticeTemplate) PI接口
* @author gonglei
* @since 2025-10-13 12:18:10
*/
export class NoticeController{
......@@ -19,7 +19,7 @@ export class NoticeController{
* @param noticeTemplate
* @return NoticeTemplate
*/
static addNoticeTemplate(axios:AxiosStatic, noticeTemplate: any): Promise<AxiosResponse<NoticeTemplate>> {
static addNoticeTemplate(axios:AxiosStatic, noticeTemplate: NoticeTemplate): Promise<AxiosResponse<NoticeTemplate>> {
return axios.post('notice/addNoticeTemplate', noticeTemplate);
}
......@@ -49,7 +49,7 @@ export class NoticeController{
/**
*/
static pageNoticeMessage(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<NoticeMessage>>> {
static pageNoticeMessage(axios:AxiosStatic, pagination: Pagination<NoticeMessage>): Promise<AxiosResponse<Page<NoticeMessage>>> {
return axios.post('notice/pageNoticeMessage', pagination);
}
......@@ -60,7 +60,7 @@ export class NoticeController{
* @param pagination
* @return Page
*/
static pageNoticeTemplate(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<NoticeTemplate>>> {
static pageNoticeTemplate(axios:AxiosStatic, pagination: Pagination<NoticeTemplate>): Promise<AxiosResponse<Page<NoticeTemplate>>> {
return axios.post('notice/pageNoticeTemplate', pagination);
}
......@@ -80,7 +80,7 @@ export class NoticeController{
* @param noticeTemplate
* @return NoticeTemplate
*/
static updateNoticeTemplate(axios:AxiosStatic, noticeTemplate: any): Promise<AxiosResponse<NoticeTemplate>> {
static updateNoticeTemplate(axios:AxiosStatic, noticeTemplate: NoticeTemplate): Promise<AxiosResponse<NoticeTemplate>> {
return axios.post('notice/updateNoticeTemplate', noticeTemplate);
}
......
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {PriceRule} from "lib/src/entity/vehicle/entity/PriceRule";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 价格规则(PriceRule) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class PriceRuleController{
......@@ -18,7 +18,7 @@ export class PriceRuleController{
* @param priceRule
* @return PriceRule
*/
static addPriceRule(axios:AxiosStatic, priceRule: any): Promise<AxiosResponse<PriceRule>> {
static addPriceRule(axios:AxiosStatic, priceRule: PriceRule): Promise<AxiosResponse<PriceRule>> {
return axios.post('priceRule/addPriceRule', priceRule);
}
......@@ -42,7 +42,7 @@ export class PriceRuleController{
* @param pagination
* @return Page
*/
static pagePriceRule(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<PriceRule>>> {
static pagePriceRule(axios:AxiosStatic, pagination: Pagination<PriceRule>): Promise<AxiosResponse<Page<PriceRule>>> {
return axios.post('priceRule/pagePriceRule', pagination);
}
......@@ -62,7 +62,7 @@ export class PriceRuleController{
* @param priceRule
* @return PriceRule
*/
static updatePriceRule(axios:AxiosStatic, priceRule: any): Promise<AxiosResponse<PriceRule>> {
static updatePriceRule(axios:AxiosStatic, priceRule: PriceRule): Promise<AxiosResponse<PriceRule>> {
return axios.post('priceRule/updatePriceRule', priceRule);
}
......
import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Page} from "lib/src/core/page/Page";
import {Recharge} from "lib/src/entity/finance/entity/Recharge";
import {Pagination} from "lib/src/core/page/Pagination";
import {Refund} from "lib/src/entity/finance/entity/Refund";
// endregion
/**
*/
export class RechargeController{
/**
*/
static getRechargeById(axios:AxiosStatic, rechargeId: number): Promise<AxiosResponse<Recharge>> {
return axios.get('recharge/getRechargeById', {params: {rechargeId: rechargeId}});
}
/**
*/
static getRefundsByRechargeId(axios:AxiosStatic, rechargeId: number): Promise<AxiosResponse<Refund[]>> {
return axios.get('recharge/getRefundsByRechargeId', {params: {rechargeId: rechargeId}});
}
/**
*/
static pageRecharge(axios:AxiosStatic, pagination: Pagination<Recharge>): Promise<AxiosResponse<Page<Recharge>>> {
return axios.post('recharge/pageRecharge', pagination);
}
static PAGE_RECHARGE = 'recharge/pageRecharge';
// region 前端扩展代码区
// endregion
}
......@@ -3,12 +3,12 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {ReleaseOrder} from "lib/src/entity/auction/entity/ReleaseOrder";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 解押订单(ReleaseOrder) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class ReleaseOrderController{
......@@ -18,7 +18,7 @@ export class ReleaseOrderController{
* @param releaseOrder
* @return ReleaseOrder
*/
static addReleaseOrder(axios:AxiosStatic, releaseOrder: any): Promise<AxiosResponse<ReleaseOrder>> {
static addReleaseOrder(axios:AxiosStatic, releaseOrder: ReleaseOrder): Promise<AxiosResponse<ReleaseOrder>> {
return axios.post('order/addReleaseOrder', releaseOrder);
}
......@@ -36,7 +36,7 @@ export class ReleaseOrderController{
* @param pagination
* @return Page
*/
static pageReleaseOrder(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<ReleaseOrder>>> {
static pageReleaseOrder(axios:AxiosStatic, pagination: Pagination<ReleaseOrder>): Promise<AxiosResponse<Page<ReleaseOrder>>> {
return axios.post('order/pageReleaseOrder', pagination);
}
......@@ -56,7 +56,7 @@ export class ReleaseOrderController{
* @param releaseOrder
* @return ReleaseOrder
*/
static updateReleaseOrder(axios:AxiosStatic, releaseOrder: any): Promise<AxiosResponse<ReleaseOrder>> {
static updateReleaseOrder(axios:AxiosStatic, releaseOrder: ReleaseOrder): Promise<AxiosResponse<ReleaseOrder>> {
return axios.post('order/updateReleaseOrder', releaseOrder);
}
......
......@@ -4,12 +4,12 @@ import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Outbound} from "lib/src/entity/venue/entity/Outbound";
import {Warehousing} from "lib/src/entity/venue/entity/Warehousing";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 出库(Outbound) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class RelocationController{
......@@ -19,7 +19,7 @@ export class RelocationController{
* @param outbound
* @return Outbound
*/
static addOutbound(axios:AxiosStatic, outbound: any): Promise<AxiosResponse<Outbound>> {
static addOutbound(axios:AxiosStatic, outbound: Outbound): Promise<AxiosResponse<Outbound>> {
return axios.post('outbound/addOutbound', outbound);
}
......@@ -28,7 +28,7 @@ export class RelocationController{
* @param warehousing
* @return Warehousing
*/
static addWarehousing(axios:AxiosStatic, warehousing: any): Promise<AxiosResponse<Warehousing>> {
static addWarehousing(axios:AxiosStatic, warehousing: Warehousing): Promise<AxiosResponse<Warehousing>> {
return axios.post('outbound/addWarehousing', warehousing);
}
......@@ -55,7 +55,7 @@ export class RelocationController{
* @param pagination
* @return Page
*/
static pageOutbound(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Outbound>>> {
static pageOutbound(axios:AxiosStatic, pagination: Pagination<Outbound>): Promise<AxiosResponse<Page<Outbound>>> {
return axios.post('outbound/pageOutbound', pagination);
}
......@@ -66,7 +66,7 @@ export class RelocationController{
* @param pagination
* @return Page
*/
static pageWarehousing(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Warehousing>>> {
static pageWarehousing(axios:AxiosStatic, pagination: Pagination<Warehousing>): Promise<AxiosResponse<Page<Warehousing>>> {
return axios.post('outbound/pageWarehousing', pagination);
}
......@@ -95,7 +95,7 @@ export class RelocationController{
* @param outbound
* @return Outbound
*/
static updateOutbound(axios:AxiosStatic, outbound: any): Promise<AxiosResponse<Outbound>> {
static updateOutbound(axios:AxiosStatic, outbound: Outbound): Promise<AxiosResponse<Outbound>> {
return axios.post('outbound/updateOutbound', outbound);
}
......@@ -104,7 +104,7 @@ export class RelocationController{
* @param warehousing
* @return Warehousing
*/
static updateWarehousing(axios:AxiosStatic, warehousing: any): Promise<AxiosResponse<Warehousing>> {
static updateWarehousing(axios:AxiosStatic, warehousing: Warehousing): Promise<AxiosResponse<Warehousing>> {
return axios.post('outbound/updateWarehousing', warehousing);
}
......
import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs, {Dayjs} from 'dayjs';
// region 前端扩展导入包
import {TreeItem} from "autumn-vue/lib/core/bean/TreeItem";
import {Page} from "autumn-vue/lib/core/page/Page";
import {TreeItem} from "lib/src/core/bean/TreeItem";
import {Page} from "lib/src/core/page/Page";
import {Role} from 'lib/src/entity/security/entity/Role';
import {User} from "lib/src/entity/security/entity/User";
......
......@@ -20,7 +20,7 @@ export class StorageController{
* @param vehicle
* @return int
*/
static updateVehicleAlbums(axios:AxiosStatic, vehicle: any): Promise<AxiosResponse<number>> {
static updateVehicleAlbums(axios:AxiosStatic, vehicle: Vehicle): Promise<AxiosResponse<number>> {
return axios.post('upload/updateVehicleAlbums', vehicle);
}
......
......@@ -3,7 +3,8 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {VehicleBrowserHistory} from "lib/src/entity/track/entity/VehicleBrowserHistory";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
......@@ -12,7 +13,7 @@ export class TrackController{
/**
*/
static pageVehicleBrowserHistory(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<VehicleBrowserHistory>>> {
static pageVehicleBrowserHistory(axios:AxiosStatic, pagination: Pagination<VehicleBrowserHistory>): Promise<AxiosResponse<Page<VehicleBrowserHistory>>> {
return axios.post('track/pageVehicleBrowserHistory', pagination);
}
......
......@@ -3,15 +3,17 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Transaction} from "lib/src/entity/finance/entity/Transaction";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {OrderTransaction} from "lib/src/entity/finance/entity/OrderTransaction";
import {OrderTransactionStat} from "lib/src/entity/finance/domain/OrderTransactionStat";
import {OrderTransactionAmountStat} from "lib/src/entity/finance/domain/OrderTransactionAmountStat";
import {ApproveHistory} from "lib/src/entity/track/entity/ApproveHistory";
import {Pagination} from "lib/src/core/page/Pagination";
import {Refund} from "lib/src/entity/finance/entity/Refund";
// endregion
/**
* 交易明细(Transaction) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class TransactionController{
......@@ -22,19 +24,19 @@ export class TransactionController{
* @return OrderTransaction
* @throws FieldException
*/
static auditOrderTransaction(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<OrderTransaction>> {
static auditOrderTransaction(axios:AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<OrderTransaction>> {
return axios.post('transaction/auditOrderTransaction', approveHistory);
}
/**
*/
static exportOrderTransaction(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportOrderTransaction(axios:AxiosStatic, pagination: Pagination<OrderTransaction>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('transaction/exportOrderTransaction', pagination, config);
}
/**
*/
static exportOrderTransactionAudit(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportOrderTransactionAudit(axios:AxiosStatic, pagination: Pagination<OrderTransaction>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('transaction/exportOrderTransactionAudit', pagination, config);
}
......@@ -78,6 +80,12 @@ export class TransactionController{
}
/**
*/
static getRefundsByWithdrawId(axios:AxiosStatic, withdrawId: number): Promise<AxiosResponse<Refund[]>> {
return axios.get('transaction/getRefundsByWithdrawId', {params: {withdrawId: withdrawId}});
}
/**
* 根据id查询交易明细
* @param transactionId
* @return Transaction
......@@ -91,7 +99,7 @@ export class TransactionController{
* @param pagination
* @return Page
*/
static pageOrderTransaction(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<OrderTransaction>>> {
static pageOrderTransaction(axios:AxiosStatic, pagination: Pagination<OrderTransaction>): Promise<AxiosResponse<Page<OrderTransaction>>> {
return axios.post('transaction/pageOrderTransaction', pagination);
}
......@@ -102,7 +110,7 @@ export class TransactionController{
* @param pagination
* @return Page
*/
static pageTransaction(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Transaction>>> {
static pageTransaction(axios:AxiosStatic, pagination: Pagination<Transaction>): Promise<AxiosResponse<Page<Transaction>>> {
return axios.post('transaction/pageTransaction', pagination);
}
......@@ -119,7 +127,7 @@ export class TransactionController{
/**
*/
static updateOrderTransactionDesc(axios:AxiosStatic, orderTransaction: any): Promise<AxiosResponse<OrderTransaction>> {
static updateOrderTransactionDesc(axios:AxiosStatic, orderTransaction: OrderTransaction): Promise<AxiosResponse<OrderTransaction>> {
return axios.post('transaction/updateOrderTransactionDesc', orderTransaction);
}
......
......@@ -3,15 +3,16 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Vehicle} from "lib/src/entity/vehicle/entity/Vehicle";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {VehicleHistoryProjection} from "lib/src/entity/vehicle/domain/VehicleHistoryProjection";
import {NameCount} from "lib/src/entity/analysis/domain/NameCount";
import {FileInfo} from "autumn-vue/lib/core/bean/FileInfo";
import {FileInfo} from "lib/src/core/bean/FileInfo";
import {Pagination} from "lib/src/core/page/Pagination";
import {VehicleVenue} from "lib/src/entity/vehicle/domain/VehicleVenue";
// endregion
/**
* 库存车辆(Vehicle) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class VehicleController{
......@@ -21,19 +22,19 @@ export class VehicleController{
* @param vehicle
* @return Vehicle
*/
static addVehicle(axios:AxiosStatic, vehicle: any): Promise<AxiosResponse<Vehicle>> {
static addVehicle(axios:AxiosStatic, vehicle: Vehicle): Promise<AxiosResponse<Vehicle>> {
return axios.post('vehicle/addVehicle', vehicle);
}
/**
*/
static exportCheckedVehicles(axios:AxiosStatic, vehicleIds: any, config?:any): Promise<AxiosResponse<void>> {
static exportCheckedVehicles(axios:AxiosStatic, vehicleIds: number[], config?:any): Promise<AxiosResponse<void>> {
return axios.post('vehicle/exportCheckedVehicles', vehicleIds, config);
}
/**
*/
static exportPriceVehicles(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportPriceVehicles(axios:AxiosStatic, pagination: Pagination<Vehicle>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('vehicle/exportPriceVehicles', pagination, config);
}
......@@ -43,7 +44,7 @@ export class VehicleController{
* @param response
* @throws IOException
*/
static exportVehicles(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportVehicles(axios:AxiosStatic, pagination: Pagination<Vehicle>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('vehicle/exportVehicles', pagination, config);
}
......@@ -117,7 +118,7 @@ export class VehicleController{
/**
*/
static pagePriceVehicle(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Vehicle>>> {
static pagePriceVehicle(axios:AxiosStatic, pagination: Pagination<Vehicle>): Promise<AxiosResponse<Page<Vehicle>>> {
return axios.post('vehicle/pagePriceVehicle', pagination);
}
......@@ -128,7 +129,7 @@ export class VehicleController{
* @param pagination
* @return Page
*/
static pageVehicle(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Vehicle>>> {
static pageVehicle(axios:AxiosStatic, pagination: Pagination<Vehicle>): Promise<AxiosResponse<Page<Vehicle>>> {
return axios.post('vehicle/pageVehicle', pagination);
}
......@@ -148,7 +149,7 @@ export class VehicleController{
* @param vehicle
* @return Vehicle
*/
static updateVehicle(axios:AxiosStatic, vehicle: any): Promise<AxiosResponse<Vehicle>> {
static updateVehicle(axios:AxiosStatic, vehicle: Vehicle): Promise<AxiosResponse<Vehicle>> {
return axios.post('vehicle/updateVehicle', vehicle);
}
......@@ -157,14 +158,14 @@ export class VehicleController{
* @param vehicleVenue
* @return Vehicle
*/
static updateVehicleVenue(axios:AxiosStatic, vehicleVenue: any): Promise<AxiosResponse<Vehicle>> {
static updateVehicleVenue(axios:AxiosStatic, vehicleVenue: VehicleVenue): Promise<AxiosResponse<Vehicle>> {
return axios.post('vehicle/updateVehicleVenue', vehicleVenue);
}
/**
* 更新车辆封面
*/
static uploadVehicleCover(axios:AxiosStatic, fileInfo: any, vehicleId: number): Promise<AxiosResponse<FileInfo>> {
static uploadVehicleCover(axios:AxiosStatic, fileInfo: FileInfo, vehicleId: number): Promise<AxiosResponse<FileInfo>> {
return axios.post('vehicle/uploadVehicleCover', fileInfo, {params: {vehicleId: vehicleId}});
}
......@@ -173,7 +174,7 @@ export class VehicleController{
* @param vehicle
* @return Vehicle
*/
static warehousingVehicle(axios:AxiosStatic, vehicle: any): Promise<AxiosResponse<Vehicle>> {
static warehousingVehicle(axios:AxiosStatic, vehicle: Vehicle): Promise<AxiosResponse<Vehicle>> {
return axios.post('vehicle/warehousingVehicle', vehicle);
}
......
......@@ -5,15 +5,15 @@ import dayjs,{Dayjs} from 'dayjs';
import {Area} from "lib/src/entity/venue/entity/Area";
import {ParkingSpace} from "lib/src/entity/venue/entity/ParkingSpace";
import {Venue} from "lib/src/entity/venue/entity/Venue";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {CascaderOption} from "lib/src/domain/CascaderOption";
import {User} from "lib/src/entity/security/entity/User";
import {VenueOption} from "lib/src/entity/venue/domain/VenueOption";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 车辆场地(Venue) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class VenueController{
......@@ -23,7 +23,7 @@ export class VenueController{
* @param area
* @return Area
*/
static addArea(axios:AxiosStatic, area: any): Promise<AxiosResponse<Area>> {
static addArea(axios:AxiosStatic, area: Area): Promise<AxiosResponse<Area>> {
return axios.post('venue/addArea', area);
}
......@@ -32,7 +32,7 @@ export class VenueController{
* @param parkingSpace
* @return ParkingSpace
*/
static addParkingSpace(axios:AxiosStatic, parkingSpace: any): Promise<AxiosResponse<ParkingSpace>> {
static addParkingSpace(axios:AxiosStatic, parkingSpace: ParkingSpace): Promise<AxiosResponse<ParkingSpace>> {
return axios.post('venue/addParkingSpace', parkingSpace);
}
......@@ -41,13 +41,13 @@ export class VenueController{
* @param venue
* @return Venue
*/
static addVenue(axios:AxiosStatic, venue: any): Promise<AxiosResponse<Venue>> {
static addVenue(axios:AxiosStatic, venue: Venue): Promise<AxiosResponse<Venue>> {
return axios.post('venue/addVenue', venue);
}
/**
*/
static addVenueUsers(axios:AxiosStatic, users: any, venueId: number): Promise<AxiosResponse<number>> {
static addVenueUsers(axios:AxiosStatic, users: User[], venueId: number): Promise<AxiosResponse<number>> {
return axios.post('venue/addVenueUsers', users, {params: {venueId: venueId}});
}
......@@ -137,7 +137,7 @@ export class VenueController{
* 分页查询区域
* @param pagination
*/
static pageArea(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Area>>> {
static pageArea(axios:AxiosStatic, pagination: Pagination<Area>): Promise<AxiosResponse<Page<Area>>> {
return axios.post('venue/pageArea', pagination);
}
......@@ -148,7 +148,7 @@ export class VenueController{
* @param pagination
* @return Page
*/
static pageParkingSpace(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<ParkingSpace>>> {
static pageParkingSpace(axios:AxiosStatic, pagination: Pagination<ParkingSpace>): Promise<AxiosResponse<Page<ParkingSpace>>> {
return axios.post('venue/pageParkingSpace', pagination);
}
......@@ -159,7 +159,7 @@ export class VenueController{
* @param pagination
* @return Page
*/
static pageVenue(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Venue>>> {
static pageVenue(axios:AxiosStatic, pagination: Pagination<Venue>): Promise<AxiosResponse<Page<Venue>>> {
return axios.post('venue/pageVenue', pagination);
}
......@@ -167,7 +167,7 @@ export class VenueController{
/**
*/
static pageVenueUser(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<User>>> {
static pageVenueUser(axios:AxiosStatic, pagination: Pagination<User>): Promise<AxiosResponse<Page<User>>> {
return axios.post('venue/pageVenueUser', pagination);
}
......@@ -205,7 +205,7 @@ export class VenueController{
* @param area
* @return Area
*/
static updateArea(axios:AxiosStatic, area: any): Promise<AxiosResponse<Area>> {
static updateArea(axios:AxiosStatic, area: Area): Promise<AxiosResponse<Area>> {
return axios.post('venue/updateArea', area);
}
......@@ -214,7 +214,7 @@ export class VenueController{
* @param parkingSpace
* @return ParkingSpace
*/
static updateParkingSpace(axios:AxiosStatic, parkingSpace: any): Promise<AxiosResponse<ParkingSpace>> {
static updateParkingSpace(axios:AxiosStatic, parkingSpace: ParkingSpace): Promise<AxiosResponse<ParkingSpace>> {
return axios.post('venue/updateParkingSpace', parkingSpace);
}
......@@ -223,7 +223,7 @@ export class VenueController{
* @param venue
* @return Venue
*/
static updateVenue(axios:AxiosStatic, venue: any): Promise<AxiosResponse<Venue>> {
static updateVenue(axios:AxiosStatic, venue: Venue): Promise<AxiosResponse<Venue>> {
return axios.post('venue/updateVenue', venue);
}
......
......@@ -3,12 +3,13 @@ import {AxiosResponse, AxiosStatic} from 'axios';
import dayjs,{Dayjs} from 'dayjs';
// region 前端扩展导入包
import {Withdraw} from "lib/src/entity/finance/entity/Withdraw";
import {Page} from "autumn-vue/lib/core/page/Page";
import {Page} from "lib/src/core/page/Page";
import {ApproveHistory} from "lib/src/entity/track/entity/ApproveHistory";
import {Pagination} from "lib/src/core/page/Pagination";
// endregion
/**
* 提现申请(Withdraw) PI接口
* @author gonglei
* @since 2025-10-13 12:18:11
*/
export class WithdrawController{
......@@ -18,13 +19,13 @@ export class WithdrawController{
* @param approveHistory
* @return Withdraw
*/
static auditWithdraw(axios:AxiosStatic, approveHistory: any): Promise<AxiosResponse<Withdraw>> {
static auditWithdraw(axios:AxiosStatic, approveHistory: ApproveHistory): Promise<AxiosResponse<Withdraw>> {
return axios.post('withdraw/auditWithdraw', approveHistory);
}
/**
*/
static exportWithdraw(axios:AxiosStatic, pagination: any, config?:any): Promise<AxiosResponse<void>> {
static exportWithdraw(axios:AxiosStatic, pagination: Pagination<Withdraw>, config?:any): Promise<AxiosResponse<void>> {
return axios.post('withdraw/exportWithdraw', pagination, config);
}
......@@ -54,7 +55,7 @@ export class WithdrawController{
* @param pagination
* @return Page
*/
static pageWithdraw(axios:AxiosStatic, pagination: any): Promise<AxiosResponse<Page<Withdraw>>> {
static pageWithdraw(axios:AxiosStatic, pagination: Pagination<Withdraw>): Promise<AxiosResponse<Page<Withdraw>>> {
return axios.post('withdraw/pageWithdraw', pagination);
}
......
......@@ -192,6 +192,11 @@ export default {
"depositState": {
"FREEZE": "冻结中",
"UNFREEZE": "已解冻"
},
"refundState": {
"UNREFUND": "未退款",
"REFUNDING": "退款中",
"REFUNDED": "已退款"
}
},
"depositRule": {
......
import {AuthenticationManager} from "autumn-vue/lib/core/security/AuthenticationManager";
// import {AuthenticationManager} from "lib/src/core/security/AuthenticationManager";
import {AuthenticationManager} from "lib/src/core/security/AuthenticationManager";
export class AuthService extends AuthenticationManager {
......
import {AxiosInstance} from 'axios';
import {message} from 'ant-design-vue';
import {AuthenticationManager} from "autumn-vue/lib/core/security/AuthenticationManager";
import {DefaultTokenInterceptor} from "autumn-vue/lib/core/http/DefaultTokenInterceptor";
import {AutumnConfig} from "autumn-vue/lib/core/config/AutumnConfig";
import {AuthenticationManager} from "lib/src/core/security/AuthenticationManager";
import {DefaultTokenInterceptor} from "lib/src/core/http/DefaultTokenInterceptor";
import {AutumnConfig} from "lib/src/core/config/AutumnConfig";
import dayjs, {Dayjs} from "dayjs";
export class CustomTokenInterceptor {
......@@ -136,7 +136,7 @@ export class CustomTokenInterceptor {
* @param error 响应回调,根据不同响应进行不同操作
*/
private handleError(error: any) {
if(!error.response){
if (!error.response) {
return;
}
console.log(error);
......
import {Modal} from "ant-design-vue/es";
import _extends from "@babel/runtime/helpers/esm/extends";
import _defaults from "@babel/runtime/helpers/esm/defaults";
import {ModalFuncProps} from 'ant-design-vue/lib/modal/Modal';
import {createVNode} from "vue";
import {VNodeProps, VNodeTypes} from '@vue/runtime-core';
import {Data} from 'ant-design-vue/lib/_util/type';
import type {ButtonProps as ButtonPropsType} from "ant-design-vue/lib/button/buttonTypes";
export default interface ModalProps extends ModalFuncProps {
component: VNodeTypes;
props?: (Data & VNodeProps) | null;
emits?: { [event: string]: (...args: any[]) => void }
}
const DEFAULT_MODAL_PROPS: ModalFuncProps = {
open: false,
width: 1024,
okText: '确定',
cancelText: '取消',
closable: true,
maskClosable: false,
mask: true,
keyboard: true,
icon: null,
class: 'dynamic-modal'
}
export class ModalService {
/**
* 适用于表单,有确认和关闭按钮
* @param modalProps
*/
public static confirm(modalProps: ModalProps) {
modalProps = _defaults(modalProps, DEFAULT_MODAL_PROPS);
const vNode = modalProps.content = createVNode(modalProps.component, modalProps.props);
if (!modalProps.onOk) {
// @ts-ignore
modalProps.okButtonProps = {style: {display: 'none'}};
}
const configs = _extends(_extends({}, modalProps), {
onOk: (...args: any[]) => {
if (modalProps.onOk) {
modalProps.onOk(vNode.component.proxy, args);
}
// 禁止确定时关闭弹窗
return new Promise((resolve, reject) => reject());
},
onCancel: (...args: any[]) => {
if (modalProps.onCancel) {
return modalProps.onCancel(vNode.component.proxy);
}
}
});
const modal = Modal.confirm(configs);
if (modalProps.emits) {
vNode.component.emit = ((event, args) => {
if (modalProps.emits[event]) {
modalProps.emits[event](args);
}
});
}
return modal;
}
/**
* 适用于信息弹框,单个按钮
* @param modalProps
*/
public static info(modalProps: ModalProps) {
modalProps = _defaults(modalProps, DEFAULT_MODAL_PROPS);
const vNode = modalProps.content = createVNode(modalProps.component, modalProps.props);
const configs = _extends(_extends({}, modalProps), {
onOk: (...args: any[]) => {
if (modalProps.onOk) {
modalProps.onOk(vNode.component.proxy, args);
}
},
onCancel: (...args: any[]) => {
if (modalProps.onCancel) {
return modalProps.onCancel(vNode.component.proxy);
}
}
});
const modal = Modal.info(configs);
if (modalProps.emits) {
vNode.component.emit = ((event, args) => {
if (modalProps.emits[event]) {
modalProps.emits[event](args);
}
});
}
return modal;
}
}
No preview for this file type
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!