package com.gxwebsoft.shop.param;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.gxwebsoft.common.core.annotation.QueryField;
import com.gxwebsoft.common.core.annotation.QueryType;
import com.gxwebsoft.common.core.web.BaseParam;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;

/**
 * 订单商品记录表查询参数
 *
 * @author 科技小王子
 * @since 2022-12-09 17:15:31
 */
@Data
@EqualsAndHashCode(callSuper = false)
@JsonInclude(JsonInclude.Include.NON_NULL)
@ApiModel(value = "OrderGoodsParam对象", description = "订单商品记录表查询参数")
public class OrderGoodsParam extends BaseParam {
    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "订单商品ID")
    @QueryField(type = QueryType.EQ)
    private Integer orderGoodsId;

    @ApiModelProperty(value = "商品分类")
    private Integer categoryId;

    @ApiModelProperty(value = "商品ID")
    @QueryField(type = QueryType.EQ)
    private Integer goodsId;

    @ApiModelProperty(value = "商品名称")
    private String goodsName;

    @ApiModelProperty(value = "商品封面图ID")
    @QueryField(type = QueryType.EQ)
    private Integer imageId;

    @ApiModelProperty(value = "库存计算方式(10下单减库存 20付款减库存)")
    @QueryField(type = QueryType.EQ)
    private Integer deductStockType;

    @ApiModelProperty(value = "规格类型(10单规格 20多规格)")
    @QueryField(type = QueryType.EQ)
    private Integer specType;

    @ApiModelProperty(value = "商品sku唯一标识")
    private String goodsSkuId;

    @ApiModelProperty(value = "SKU的规格属性(json格式)")
    private String goodsProps;

    @ApiModelProperty(value = "商品详情")
    private String content;

    @ApiModelProperty(value = "商品编码")
    private String goodsNo;

    @ApiModelProperty(value = "商品价格(单价)")
    @QueryField(type = QueryType.EQ)
    private BigDecimal goodsPrice;

    @ApiModelProperty(value = "商品划线价")
    @QueryField(type = QueryType.EQ)
    private BigDecimal linePrice;

    @ApiModelProperty(value = "商品重量(Kg)")
    private Double goodsWeight;

    @ApiModelProperty(value = "所属档口")
    private Integer gear;

    @ApiModelProperty(value = "是否存在会员等级折扣")
    @QueryField(type = QueryType.EQ)
    private Integer isUserGrade;

    @ApiModelProperty(value = "会员折扣比例(0-10)")
    @QueryField(type = QueryType.EQ)
    private Integer gradeRatio;

    @ApiModelProperty(value = "会员折扣的商品单价")
    @QueryField(type = QueryType.EQ)
    private BigDecimal gradeGoodsPrice;

    @ApiModelProperty(value = "会员折扣的总额差")
    @QueryField(type = QueryType.EQ)
    private BigDecimal gradeTotalMoney;

    @ApiModelProperty(value = "优惠券折扣金额")
    @QueryField(type = QueryType.EQ)
    private BigDecimal couponMoney;

    @ApiModelProperty(value = "积分金额")
    @QueryField(type = QueryType.EQ)
    private BigDecimal pointsMoney;

    @ApiModelProperty(value = "积分抵扣数量")
    @QueryField(type = QueryType.EQ)
    private Integer pointsNum;

    @ApiModelProperty(value = "赠送的积分数量")
    @QueryField(type = QueryType.EQ)
    private Integer pointsBonus;

    @ApiModelProperty(value = "付款状态(10未付款 20已付款)")
    @QueryField(type = QueryType.EQ)
    private Integer payStatus;

    @ApiModelProperty(value = "购买数量")
    @QueryField(type = QueryType.EQ)
    private Integer totalNum;

    @ApiModelProperty(value = "商品总价(数量×单价)")
    @QueryField(type = QueryType.EQ)
    private BigDecimal totalPrice;

    @ApiModelProperty(value = "实际付款价(折扣和优惠后)")
    @QueryField(type = QueryType.EQ)
    private BigDecimal totalPayPrice;

    @ApiModelProperty(value = "发货状态(10未发货 20已发货 30部分发货)")
    @QueryField(type = QueryType.EQ)
    private Integer deliveryStatus;

    @ApiModelProperty(value = "已发货数量")
    @QueryField(type = QueryType.EQ)
    private Integer deliveryNum;

    @ApiModelProperty(value = "发货时间")
    @TableField(exist = false)
    private String deliveryTime;

    @ApiModelProperty(value = "星期几")
    @QueryField(type = QueryType.EQ)
    private Integer week;

    @ApiModelProperty(value = "是否开启单独分销(0关闭 1开启)")
    @QueryField(type = QueryType.EQ)
    private Integer isIndDealer;

    @ApiModelProperty(value = "是否临时报餐")
    @QueryField(type = QueryType.EQ)
    private Integer temporary;

    @ApiModelProperty(value = "分销佣金类型(10百分比 20固定金额)")
    @QueryField(type = QueryType.EQ)
    private Integer dealerMoneyType;

    @ApiModelProperty(value = "分销佣金(一级)")
    @QueryField(type = QueryType.EQ)
    private BigDecimal firstMoney;

    @ApiModelProperty(value = "分销佣金(二级)")
    @QueryField(type = QueryType.EQ)
    private BigDecimal secondMoney;

    @ApiModelProperty(value = "分销佣金(三级)")
    @QueryField(type = QueryType.EQ)
    private BigDecimal thirdMoney;

    @ApiModelProperty(value = "是否已评价(0否 1是)")
    @QueryField(type = QueryType.EQ)
    private Integer isComment;

    @ApiModelProperty(value = "订单ID")
    @QueryField(type = QueryType.EQ)
    private Integer orderId;

    @ApiModelProperty(value = "用户ID")
    @QueryField(type = QueryType.EQ)
    private Integer userId;

    @ApiModelProperty(value = "来源记录ID")
    @QueryField(type = QueryType.EQ)
    private Integer goodsSourceId;

    @ApiModelProperty(value = "排序(数字越小越靠前)")
    @QueryField(type = QueryType.EQ)
    private Integer sortNumber;

    @ApiModelProperty(value = "备注")
    private String comments;

    @ApiModelProperty(value = "状态, 0正常, 1冻结")
    @QueryField(type = QueryType.EQ)
    private Integer status;

    @ApiModelProperty(value = "是否删除, 0否, 1是")
    @QueryField(type = QueryType.EQ)
    private Integer deleted;

    @ApiModelProperty(value = "商户编码")
    private String merchantCode;

    @ApiModelProperty(value = "用户昵称")
    @TableField(exist = false)
    private String nickname;

    @ApiModelProperty(value = "订购份数是否大于0")
    @TableField(exist = false)
    private Boolean hasNum;

    @ApiModelProperty(value = "订单状态")
    @TableField(exist = false)
    private Integer orderStatus;

    @QueryField(value = "delivery_time", type = QueryType.GE)
    @TableField(exist = false)
    @ApiModelProperty("报餐时间起始值")
    private String deliveryTimeStart;

    @QueryField(value = "delivery_time", type = QueryType.LE)
    @TableField(exist = false)
    @ApiModelProperty("报餐时间结束值")
    private String deliveryTimeEnd;

    @ApiModelProperty(value = "按部门查询")
    @TableField(exist = false)
    private Integer organizationId;

}
