package com.ruoyi.model.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.cyl.h5.pojo.vo.H5OrderVO;
import com.cyl.manager.oms.pojo.vo.ManagerOrderDetailVO;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * 订单信息对象 applet_order
 * 
 * @author ruoyi
 * @date 2025-03-28
 */
@Data
public class AppletOrderItem {
    private static final long serialVersionUID = 1L;

    /** 唯一标识 */
    private Long id;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    /** 创建者 */
    private Integer createBy;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    /** 修改者 */
    private Integer updateBy;

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

    /** 订单状态类型 在接单大厅使用 */
    @Excel(name = "订单状态")
    private Integer status;

    /** 派单次数 */
    @Excel(name = "派单次数")
    private Integer num;

    /** 本单酬劳 */
    @Excel(name = "本单酬劳")
    private BigDecimal price;

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

    /** 订单类型 */
    @Excel(name = "订单类型")
    private String type;

    /** 无法接单原因 */
    @Excel(name = "无法接单原因")
    private String reason;

    /** 关联服务者ID */
    @Excel(name = "关联服务者ID")
    private Long userId;


    /** 派单给的用户集合 */
    @Excel(name = "派单给的用户集合")
    private String userIdJson;

    /** 关联宠物ID */
    @Excel(name = "关联宠物ID")
    private Integer petId;


    private Long orderId;
    private String orderSn;


    @TableField(exist = false)
    private H5OrderVO h5OrderVO;


    @TableField(exist = false)
    private ManagerOrderDetailVO managerOrderDetailVO;



    /** 接单时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "接单时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime startTime;

    /** 伴宠师姓名 */
    @Excel(name = "伴宠师姓名")
    private String name;

    /** 伴宠师电话 */
    @Excel(name = "伴宠师电话")
    private String phone;

    /** 订单状态 0待服务 1进行中 2已完成 */
    @Excel(name = "订单状态")
    private Integer orderStatus;

    /** 本单比例 */
    @Excel(name = "本单比例")
    private BigDecimal orderGiveProportion;

    /** 本单佣金 */
    @Excel(name = "本单佣金")
    private BigDecimal orderGivePrice;

    /** 确认服务日期 */
    @Excel(name = "确认服务日期")
    private Integer isDate;

    /** 确认服务地址 */
    @Excel(name = "确认服务地址")
    private Integer isAddress;

    /** 确认宠物信息 */
    @Excel(name = "确认宠物信息")
    private Integer isPet;

    //给用户的返点
    @TableField(exist = false)
    private BigDecimal orderGive;
}