package com.yiqi.order.domain.vo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.yiqi.app.domain.vo.AppUserVO;
import com.yiqi.common.annotation.Excel;
import com.yiqi.common.core.domain.BaseEntity;
import com.yiqi.order.domain.OrderDelivery;
import com.yiqi.system.domain.SysOrg;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 洗衣订单对象 order_cloth
 *
 * @author xiaohei
 * @date 2023-10-17
 */
@Data
public class OrderClothVO extends BaseEntity
{
    private static final long serialVersionUID=1L;

    @ApiModelProperty("主键ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    /** 订单编号 */
    @Excel(name = "订单编号")
    @ApiModelProperty("订单编号")
    private String orderNo;

    /** 门店/工厂ID */
    @Excel(name = "门店/工厂ID")
    @ApiModelProperty("门店/工厂ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long orgId;

    /** 来源类型 */
    @Excel(name = "来源类型")
    @ApiModelProperty("来源类型")
    private String sourceType;

    /** 工厂ID */
    @Excel(name = "工厂ID")
    @ApiModelProperty("工厂ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long factoryId;

    /** 客户ID */
    @Excel(name = "客户ID")
    @ApiModelProperty("客户ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long appUserId;

    /** 省份 */
    @Excel(name = "省份")
    @ApiModelProperty("省份")
    private String province;

    /** 城市 */
    @Excel(name = "城市")
    @ApiModelProperty("城市")
    private String city;

    /** 区域 */
    @Excel(name = "区域")
    @ApiModelProperty("区域")
    private String area;

    /** 地址 */
    @Excel(name = "地址")
    @ApiModelProperty("地址")
    private String address;

    /** 地址明细（门牌号） */
    @Excel(name = "地址明细", readConverterExp = "门=牌号")
    @ApiModelProperty("地址明细（门牌号）")
    private String addressDetail;

    /** 经度 */
    @Excel(name = "经度")
    @ApiModelProperty("经度")
    private BigDecimal longitude;

    /** 纬度 */
    @Excel(name = "纬度")
    @ApiModelProperty("纬度")
    private BigDecimal latitude;

    /** 联系人 */
    @Excel(name = "联系人")
    @ApiModelProperty("联系人")
    private String contactName;

    /** 联系人手机号 */
    @Excel(name = "联系人手机号")
    @ApiModelProperty("联系人手机号")
    private String contactPhone;

    /** 订单总金额 */
    @Excel(name = "订单总金额")
    @ApiModelProperty("订单总金额")
    private BigDecimal orderAmount;

    @ApiModelProperty("衣服总金额")
    private BigDecimal orderClothPrice;

    @ApiModelProperty("衣服件数")
    private Integer orderClothCount;

    /** 支付金额 */
    @Excel(name = "支付金额")
    @ApiModelProperty("支付金额")
    private BigDecimal payAmount;

    @ApiModelProperty("付款时间类型（0=收衣付款,1=取衣付款）")
    private String payTimeType;

    /** 支付方式（0=微信，1=支付宝，2=现金，3=余额） */
    @Excel(name = "支付方式", readConverterExp = "0==微信，1=支付宝，2=现金，3=余额")
    @ApiModelProperty("支付方式（0=微信，1=支付宝，2=现金，3=余额）")
    private String payType;

    @ApiModelProperty("是否付款")
    private String hasPay;

    @Excel(name = "支付状态", readConverterExp = "0==待支付，1=支付成功，2=支付失败")
    @ApiModelProperty("支付状态 0：待支付 1: 支付成功 -1：支付失败")
    private String payStatus;

    /** 支付时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "支付时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("支付时间")
    private Date payTime;

    /** 支付宝/微信支付订单号 */
    @Excel(name = "支付宝/微信支付订单号")
    @ApiModelProperty("支付宝/微信支付订单号")
    private String outTradeOrderNo;

    /** 下单渠道（APP=APP，WXAPP=小程序，OFFLINE=线下门店） */
    @Excel(name = "下单渠道", readConverterExp = "A=PP=APP，WXAPP=小程序，OFFLINE=线下门店")
    @ApiModelProperty("下单渠道（APP=APP，WXAPP=小程序，OFFLINE=线下门店）")
    private String orderSource;

    /** 退款金额 */
    @Excel(name = "退款金额")
    @ApiModelProperty("退款金额")
    private BigDecimal refundAmount;

    /** 退款描述 */
    @Excel(name = "退款描述")
    @ApiModelProperty("退款描述")
    private String refundContent;

    /** 预约时间（yyyy-MM-dd HH:mm） */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty("预约时间")
    private Date appointmentTime;

    /** 预约件数 */
    @Excel(name = "预约件数")
    @ApiModelProperty("预约件数")
    private Integer appointmentCount;

    @ApiModelProperty("订单状态（0=预约待取，1=待上门，2=已上门，3=已取货、待门店定价，4=已定价、待支付，5=支付确认中" +
            "，6=清洗中，7=洗衣完成、已到店，8=待送衣，9=送衣中，10=已送达、待评价，11=已完成，100=已取消）")
    private String orderStatus;

    /** 取衣时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "取衣时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("取衣时间")
    private Date takeClothTime;

    /** 取衣人 */
    @Excel(name = "取衣人")
    @ApiModelProperty("取衣人")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long takeClothAppUserId;

    /** 定价时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "定价时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("定价时间")
    private Date setPriceTime;

    /** 取货时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "取货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("取货时间")
    private Date pickUpTime;

    /** 开始洗衣时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "开始洗衣时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("开始洗衣时间")
    private Date washClothStartTime;

    /** 结束洗衣时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "结束洗衣时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("结束洗衣时间")
    private Date washClothEndTime;

    /** 送店时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "送店时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("送店时间")
    private Date sendToStoreTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "预计取衣时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("预计取衣时间")
    private Date planSendToUserTime;

    /** 取衣时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "取衣时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("取衣时间")
    private Date sendToUserTime;


    /** 退款申请时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "退款申请时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("退款申请时间")
    private Date refundApplyTime;

    /** 退款时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "退款时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("退款时间")
    private Date refundTime;

    /** 退款状态（0=正常，1=退款申请中，2=退款同意，3=退款拒绝，4=退款取消） */
    @Excel(name = "退款状态", readConverterExp = "0==正常，1=退款申请中，2=退款同意，3=退款拒绝，4=退款取消")
    @ApiModelProperty("退款状态（0=正常，1=退款申请中，2=退款同意，3=退款拒绝，4=退款取消）")
    private String refundStatus;

    /** 退款原因 */
    @Excel(name = "退款原因")
    @ApiModelProperty("退款原因")
    private String refundReason;

    /** 送衣人 */
    @Excel(name = "送衣人")
    @ApiModelProperty("送衣人")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long sendClothAppUserId;

    /** 收衣方式（0=到店，1=上门） */
    @Excel(name = "收衣方式", readConverterExp = "0==到店，1=上门")
    @ApiModelProperty("收衣方式（0=到店，1=上门）")
    private String takeClothWay;

    /** 取衣方式（0=到店，1=上门） */
    @Excel(name = "取衣方式", readConverterExp = "0==到店，1=上门")
    @ApiModelProperty("取衣方式（0=到店，1=上门）")
    private String sendClothWay;

    /** 优惠券优惠总金额 */
    @Excel(name = "优惠券优惠总金额")
    @ApiModelProperty("优惠券优惠总金额")
    private BigDecimal couponAmount;

    /** 订单完成 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @Excel(name = "订单完成", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("订单完成")
    private Date finishTime;

    /** 门店员工ID */
    @Excel(name = "门店员工ID")
    @ApiModelProperty("门店员工ID")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long employeeId;

    /** 删除状态（0=正常,2=删除） */
    @ApiModelProperty("删除状态（0=正常,2=删除）")
    private String delFlag;

    /** 是否拆装 */
    @Excel(name = "是否拆装")
    @ApiModelProperty("是否拆装")
    private String isDisassemblyAndAssembly;

    /** 是否大件 */
    @Excel(name = "是否大件")
    @ApiModelProperty("是否大件")
    private String isLargeItem;

    /** 订单加急 */
    @Excel(name = "订单加急")
    @ApiModelProperty("订单加急")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long clothSpeedId;

    /** 订单加急 */
    @Excel(name = "订单加急")
    @ApiModelProperty("订单加急")
    private String clothSpeedName;

    /** 是否特殊 */
    @Excel(name = "是否特殊")
    @ApiModelProperty("是否特殊")
    private String isSpecial;

    /** 优惠券抵扣金额 */
    @Excel(name = "优惠券抵扣金额")
    @ApiModelProperty("优惠券抵扣金额")
    private BigDecimal couponDeductAmount;

    @ApiModelProperty("现金抵扣金额")
    private BigDecimal cashDeductAmount;

    @ApiModelProperty("APP用户扣款余额")
    private BigDecimal appUserBalanceAmount;

    @ApiModelProperty("门店/工厂信息")
    private SysOrg sysOrg;

    @ApiModelProperty("衣服信息")
    private List<OrderClothItemVO> orderClothItemVOS;

    @ApiModelProperty("收衣配送信息")
    private OrderDelivery collectClothDeliverInfo;

    @ApiModelProperty("送回配送信息")
    private OrderDelivery takeClothDeliverInfo;

    @ApiModelProperty("收衣人明细")
    private AppUserVO takeClothUserVO;

    @ApiModelProperty("送衣人明细")
    private AppUserVO sendClothUserVO;
}
