package com.yiqi.order.domain;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yiqi.app.domain.AppUserAddress;
import com.yiqi.common.annotation.Excel;
import com.yiqi.common.utils.DateUtils;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.yiqi.common.core.domain.BaseEntity;
import lombok.Data;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

/**
 * 【请填写功能名称】对象 order_cloth_delivery_address
 *
 * @author ruoyi
 * @date 2023-12-14
 */
@ApiModel("【请填写功能名称】")
@TableName("order_cloth_delivery_address")
@Data
public class OrderClothDeliveryAddress extends BaseEntity
{
    public OrderClothDeliveryAddress() {
    }

    public OrderClothDeliveryAddress(AppUserAddress appUserAddress) {
        this.appUserId = appUserAddress.getAppUserId();
        this.province = appUserAddress.getProvince();
        this.city = appUserAddress.getCity();
        this.area = appUserAddress.getArea();
        this.address = appUserAddress.getAddress();
        this.addressDetail = appUserAddress.getAddressDetail();
        this.addressId = appUserAddress.getId();
        this.longitude = appUserAddress.getLongitude();
        this.latitude = appUserAddress.getLatitude();
        this.contactName = appUserAddress.getContactName();
        this.contactPhone = appUserAddress.getContactPhone();
        setCreateTime(DateUtils.getNowDate());
    }

    private static final long serialVersionUID=1L;

    /** $column.columnComment */
    @ApiModelProperty("$column.columnComment")
    @TableId(type = IdType.AUTO)
    private Long id;

    /** 洗衣配送费订单 */
    @Excel(name = "洗衣配送费订单")
    @ApiModelProperty("洗衣配送费订单")
    private String deliveryOrderNo;

    /** 订单ID */
    @Excel(name = "订单ID")
    @ApiModelProperty("订单ID")
    private Long orderId;

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

    @ApiModelProperty("客户ID")
    private Long appUserId;

    /** 配送员ID */
    @Excel(name = "配送员ID")
    @ApiModelProperty("配送员ID")
    private Long deliveryManId;

    /** 配送公司ID */
    @Excel(name = "配送公司ID")
    @ApiModelProperty("配送公司ID")
    private String deliveryId;

    /** 配送公司名称 */
    @Excel(name = "配送公司名称")
    @ApiModelProperty("配送公司名称")
    private String deliveryName;

    @ApiModelProperty("服务类型")
    @NotNull(message = "服务类型不能为空")
    private Integer serviceType;

    @ApiModelProperty("服务类型名称")
    @NotEmpty(message = "服务类型名称不能为空")
    private String serviceName;

    /** 地址ID */
    @Excel(name = "地址ID")
    @ApiModelProperty("地址ID")
    private Long addressId;

    /** 衣服订单类型（0=收衣，1=取衣） */
    @Excel(name = "衣服订单类型", readConverterExp = "0==收衣，1=取衣")
    @ApiModelProperty("衣服订单类型（0=收衣，1=取衣）")
    private String clothOrderType;

    /** 省份 */
    @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 String isNeedPay;

    /** 配送费金额 */
    @Excel(name = "配送费金额")
    @ApiModelProperty("配送费金额")
    private BigDecimal deliveryAmount;

    /** 支付状态（0：未支付，1：已支付） */
    @Excel(name = "支付状态", readConverterExp = "0=：未支付，1：已支付")
    @ApiModelProperty("支付状态（0：未支付，1：已支付）")
    private String payStatus;

    /** 支付方式 */
    @Excel(name = "支付方式")
    @ApiModelProperty("支付方式")
    private String payType;

    @ApiModelProperty("配送方式（0=第三方配送，1=门店配送员配送）")
    private String deliveryWay;

    @ApiModelProperty("第三方配送订单号")
    private String thirdDeliveryOrderNo;

    @ApiModelProperty("运单ID")
    private String waybillNo;

}
