order服务拆分
This commit is contained in:
@@ -21,7 +21,6 @@ import java.time.LocalDateTime;
|
||||
* @since 2025-02-14
|
||||
*/
|
||||
@Data
|
||||
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("tb_order_detail")
|
||||
@@ -131,6 +130,9 @@ public class OrderDetail implements Serializable {
|
||||
* 状态: in-production 制作中;wait_out 待取餐;refunding 退款中; part_refund 部分退单; refund-退单; done 完成;
|
||||
*/
|
||||
private String status;
|
||||
/**
|
||||
* 菜品状态:待起菜 PENDING_PREP 待出菜 READY_TO_SERVE 已出菜 SENT_OUT 已上菜 DELIVERED
|
||||
*/
|
||||
private String subStatus;
|
||||
|
||||
/**
|
||||
@@ -176,6 +178,22 @@ public class OrderDetail implements Serializable {
|
||||
|
||||
@Column(onInsertValue = "now()", onUpdateValue = "now()")
|
||||
private LocalDateTime updateTime;
|
||||
/**
|
||||
* 下单时间 为订单支付成功时间
|
||||
*/
|
||||
private LocalDateTime orderTime;
|
||||
/**
|
||||
* 起菜时间
|
||||
*/
|
||||
private LocalDateTime startOrderTime;
|
||||
/**
|
||||
* 出菜时间
|
||||
*/
|
||||
private LocalDateTime dishOutTime;
|
||||
/**
|
||||
* 上菜时间
|
||||
*/
|
||||
private LocalDateTime foodServeTime;
|
||||
|
||||
/**
|
||||
* 是否赠送 0否 1是
|
||||
|
||||
@@ -16,6 +16,7 @@ import java.io.Serial;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
/**
|
||||
* 订单表 实体类。
|
||||
@@ -27,6 +28,7 @@ import lombok.NoArgsConstructor;
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Table("tb_order_info")
|
||||
@Accessors(chain = true)
|
||||
public class OrderInfo implements Serializable {
|
||||
|
||||
@Serial
|
||||
|
||||
@@ -18,6 +18,6 @@ public interface OrderDetailService extends IService<OrderDetail> {
|
||||
List<OrderDetailPrintVo> getOrderDetailPrint(Long orderId);
|
||||
|
||||
|
||||
// 更新订单详情状态 将订单详情的状态为wait-pay 更新为 payed
|
||||
// 更新订单详情状态 将订单详情的状态为wait-pay 更新为 done
|
||||
void updateOrderDetailStatus(Long orderId,String status);
|
||||
}
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
package com.czg.order.vo;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 数据汇总-商品销量排名
|
||||
* @author tankaikai
|
||||
* @since 2025-03-07 15:50
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class DataSummaryProductSaleRankingVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
private Long productId;
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
private String productName;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
private BigDecimal number;
|
||||
|
||||
/**
|
||||
* 金额
|
||||
*/
|
||||
private BigDecimal amount;
|
||||
|
||||
/**
|
||||
* 退单量
|
||||
*/
|
||||
private BigDecimal refundCount;
|
||||
|
||||
/**
|
||||
* 退单金额
|
||||
*/
|
||||
private BigDecimal refundAmount;
|
||||
|
||||
}
|
||||
@@ -1,173 +0,0 @@
|
||||
package com.czg.order.vo;
|
||||
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 数据汇总-商品销售
|
||||
* @author tankaikai
|
||||
* @since 2025-03-07 15:50
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class DataSummaryProductSaleVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
/**
|
||||
* productSum
|
||||
*/
|
||||
private ProductSumVo productSum = new ProductSumVo();
|
||||
/**
|
||||
* countList
|
||||
*/
|
||||
private List<CountListVo> countList = new ArrayList<>();
|
||||
/**
|
||||
* productCount
|
||||
*/
|
||||
private ProductCountVo productCount = new ProductCountVo();
|
||||
/**
|
||||
* productList
|
||||
*/
|
||||
private Page<ContentVo> productList = new Page<ContentVo>(new ArrayList<ContentVo>(), 1, 10, 0);
|
||||
|
||||
/**
|
||||
* ProductSumVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class ProductSumVo {
|
||||
/**
|
||||
* icon
|
||||
*/
|
||||
private String icon;
|
||||
/**
|
||||
* isAmount
|
||||
*/
|
||||
private String isAmount;
|
||||
/**
|
||||
* payAmount
|
||||
*/
|
||||
private BigDecimal payAmount;
|
||||
/**
|
||||
* payType
|
||||
*/
|
||||
private String payType;
|
||||
/**
|
||||
* saveAmount
|
||||
*/
|
||||
private BigDecimal saveAmount;
|
||||
}
|
||||
|
||||
/**
|
||||
* ProductCountVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class ProductCountVo {
|
||||
/**
|
||||
* icon
|
||||
*/
|
||||
private String icon;
|
||||
/**
|
||||
* isAmount
|
||||
*/
|
||||
private String isAmount;
|
||||
/**
|
||||
* payAmount
|
||||
*/
|
||||
private BigDecimal payAmount;
|
||||
/**
|
||||
* payType
|
||||
*/
|
||||
private String payType;
|
||||
/**
|
||||
* saveAmount
|
||||
*/
|
||||
private BigDecimal saveAmount;
|
||||
}
|
||||
/**
|
||||
* ContentVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class ContentVo {
|
||||
/**
|
||||
* cateName
|
||||
*/
|
||||
private String cateName;
|
||||
/**
|
||||
* num
|
||||
*/
|
||||
private BigDecimal num;
|
||||
/**
|
||||
* price
|
||||
*/
|
||||
private BigDecimal price;
|
||||
/**
|
||||
* productId
|
||||
*/
|
||||
private Object productId;
|
||||
/**
|
||||
* productName
|
||||
*/
|
||||
private String productName;
|
||||
/**
|
||||
* productSkuId
|
||||
*/
|
||||
private Long productSkuId;
|
||||
/**
|
||||
* productSkuName
|
||||
*/
|
||||
private String productSkuName;
|
||||
/**
|
||||
* refAmount
|
||||
*/
|
||||
private BigDecimal refAmount;
|
||||
/**
|
||||
* refNum
|
||||
*/
|
||||
private BigDecimal refNum;
|
||||
/**
|
||||
* salesAmount
|
||||
*/
|
||||
private BigDecimal salesAmount;
|
||||
/**
|
||||
* 销售数量
|
||||
*/
|
||||
private BigDecimal salesNum;
|
||||
/**
|
||||
* 单位名称
|
||||
*/
|
||||
private String unitName;
|
||||
}
|
||||
|
||||
/**
|
||||
* CountListVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class CountListVo {
|
||||
/**
|
||||
* 销售额
|
||||
*/
|
||||
private BigDecimal saleAmount;
|
||||
/**
|
||||
* 销售量
|
||||
*/
|
||||
private BigDecimal saleNum;
|
||||
/**
|
||||
* 日期
|
||||
*/
|
||||
private String tradeDay;
|
||||
}
|
||||
}
|
||||
@@ -1,148 +0,0 @@
|
||||
package com.czg.order.vo;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 数据统计-营业-上半部分
|
||||
* @author tankaikai
|
||||
* @since 2025-03-07 15:35
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class DataSummaryTradeVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* sale
|
||||
*/
|
||||
private SaleVo sale = new SaleVo();
|
||||
/**
|
||||
* count
|
||||
*/
|
||||
private CountVo count = new CountVo();
|
||||
/**
|
||||
* vip
|
||||
*/
|
||||
private VipVo vip = new VipVo();
|
||||
|
||||
/**
|
||||
* SaleVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class SaleVo {
|
||||
/**
|
||||
* 会员退款金额
|
||||
*/
|
||||
private BigDecimal outAmount;
|
||||
/**
|
||||
* 总金额
|
||||
*/
|
||||
private BigDecimal totalSaleAmount;
|
||||
/**
|
||||
* 会员总金额
|
||||
*/
|
||||
private BigDecimal totalVipAmount;
|
||||
/**
|
||||
* 会员充值金额
|
||||
*/
|
||||
private BigDecimal inAmount;
|
||||
/**
|
||||
* 总实收
|
||||
*/
|
||||
private BigDecimal incomeAmountAll;
|
||||
/**
|
||||
* 销售收款金额
|
||||
*/
|
||||
private BigDecimal incomeAmount;
|
||||
/**
|
||||
* payCount
|
||||
*/
|
||||
private List<PayCountVo> payCount = new ArrayList<>();
|
||||
/**
|
||||
* 销售退款金额
|
||||
*/
|
||||
private BigDecimal refundAmount;
|
||||
|
||||
/**
|
||||
* PayCountVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class PayCountVo {
|
||||
/**
|
||||
* 图标
|
||||
*/
|
||||
private String icon;
|
||||
/**
|
||||
* isAmount
|
||||
*/
|
||||
private String isAmount;
|
||||
/**
|
||||
* 金额
|
||||
*/
|
||||
private Integer payAmount;
|
||||
/**
|
||||
* 描述
|
||||
*/
|
||||
private String payType;
|
||||
/**
|
||||
* saveAmount
|
||||
*/
|
||||
private BigDecimal saveAmount;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* CountVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class CountVo {
|
||||
/**
|
||||
* 客单价
|
||||
*/
|
||||
private Integer unitPrice;
|
||||
/**
|
||||
* 翻台率
|
||||
*/
|
||||
private String turnoverRate;
|
||||
/**
|
||||
* 优惠单数
|
||||
*/
|
||||
private Integer saveNum;
|
||||
/**
|
||||
* 优惠金额
|
||||
*/
|
||||
private BigDecimal saveAmount;
|
||||
}
|
||||
|
||||
/**
|
||||
* VipVo
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public static class VipVo {
|
||||
/**
|
||||
* 会员消费笔数
|
||||
*/
|
||||
private Integer useNum;
|
||||
/**
|
||||
* 新增会员数
|
||||
*/
|
||||
private Integer newFlow;
|
||||
/**
|
||||
* 会员消费金额
|
||||
*/
|
||||
private BigDecimal useAmount;
|
||||
}
|
||||
}
|
||||
@@ -1,69 +0,0 @@
|
||||
package com.czg.order.vo;
|
||||
|
||||
import cn.idev.excel.annotation.ExcelIgnore;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import cn.idev.excel.annotation.write.style.ColumnWidth;
|
||||
import com.alibaba.fastjson2.annotation.JSONField;
|
||||
import com.pig4cloud.plugin.excel.annotation.ExcelLine;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 销量统计导出
|
||||
*
|
||||
* @author tankaikai
|
||||
* @since 2025-03-07 16:22
|
||||
*/
|
||||
@Data
|
||||
@ColumnWidth(30)
|
||||
public class SaleSummaryExportVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
/**
|
||||
* 导入时候回显行号
|
||||
*/
|
||||
@ExcelLine
|
||||
@ExcelIgnore
|
||||
@JSONField(serialize = false)
|
||||
private Long lineNum;
|
||||
/**
|
||||
* 商品分类
|
||||
*/
|
||||
@ExcelProperty("商品分类")
|
||||
private String categoryName;
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ExcelProperty("商品名称")
|
||||
private String productName;
|
||||
/**
|
||||
* 商品规格
|
||||
*/
|
||||
@ExcelProperty("商品规格")
|
||||
private String specName;
|
||||
/**
|
||||
* 销售额
|
||||
*/
|
||||
@ExcelProperty("销售额")
|
||||
private BigDecimal salesAmount;
|
||||
/**
|
||||
* 退单额
|
||||
*/
|
||||
@ExcelProperty("退单额")
|
||||
private BigDecimal refundAmount;
|
||||
/**
|
||||
* 实际销量
|
||||
*/
|
||||
@ExcelProperty("实际销量")
|
||||
private BigDecimal salesNum;
|
||||
/**
|
||||
* 退单量
|
||||
*/
|
||||
@ExcelProperty("退单量")
|
||||
private BigDecimal refundNum;
|
||||
|
||||
}
|
||||
@@ -1,75 +0,0 @@
|
||||
package com.czg.order.vo;
|
||||
|
||||
import cn.idev.excel.annotation.ExcelIgnore;
|
||||
import cn.idev.excel.annotation.ExcelProperty;
|
||||
import cn.idev.excel.annotation.write.style.ColumnWidth;
|
||||
import com.alibaba.fastjson2.annotation.JSONField;
|
||||
import com.pig4cloud.plugin.excel.annotation.ExcelLine;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 台桌统计明细
|
||||
* @author tankaikai
|
||||
* @since 2025-03-07 16:22
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
@ColumnWidth(20)
|
||||
public class TableSummaryInfoVo implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 导入时候回显行号
|
||||
*/
|
||||
@ExcelLine
|
||||
@ExcelIgnore
|
||||
@JSONField(serialize = false)
|
||||
private Long lineNum;
|
||||
/**
|
||||
* 台桌id
|
||||
*/
|
||||
@ExcelIgnore
|
||||
private Long tableId;
|
||||
/**
|
||||
* 台桌码
|
||||
*/
|
||||
@ExcelIgnore
|
||||
private String tableCode;
|
||||
/**
|
||||
* 区域名称
|
||||
*/
|
||||
@ExcelProperty("区域名称")
|
||||
private String areaName;
|
||||
/**
|
||||
* 台桌号
|
||||
*/
|
||||
@ExcelProperty("台桌号")
|
||||
private String tableName;
|
||||
/**
|
||||
* 订单数量
|
||||
*/
|
||||
@ExcelProperty("订单数量")
|
||||
private Long orderCount;
|
||||
/**
|
||||
* 订单金额
|
||||
*/
|
||||
@ExcelProperty("订单金额")
|
||||
private BigDecimal orderAmount;
|
||||
/**
|
||||
* 退款数量
|
||||
*/
|
||||
@ExcelProperty("退款数量")
|
||||
private Long refundCount;
|
||||
/**
|
||||
* 退款金额
|
||||
*/
|
||||
@ExcelProperty("退款金额")
|
||||
private BigDecimal refundAmount;
|
||||
}
|
||||
Reference in New Issue
Block a user