package cn.superdesk.uniorder.dto.receive.consumer.superdeskmall.unified.mix;

import cn.superdesk.uniorder.common.json.deserializer.DateTimeConvertDeserializer;
import cn.superdesk.uniorder.common.json.serializer.DateTimeConvertSerializer;
import cn.superdesk.uniorder.dto.receive.consumer.BaseReceiveParam;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

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

/**
 * @Description: 用于一般订单 接收 已对过 20200714 1446
 * @Author: linjinyu
 * @CreateDate: 7/14/20 2:46 PM
 * @UpdateUser: linjinyu
 * @UpdateDate: 7/14/20 2:46 PM
 * @UpdateRemark: 修改内容
 * @Version: 1.0
 */
@Data
public class UnifiedMixOrderReceiveParam extends BaseReceiveParam {


	@ApiModelProperty("来源编号 必须 与业务方协定的业务编号 之前的来源是用 orderType 来断定的 orderType 计划弃用")
	private String serviceNo;
	@ApiModelProperty("来源名称 必须")
	private String serviceName;

	@ApiModelProperty("\"orderid\": 53322,")
	@JsonProperty("orderid")
	private Long orderId;
	@ApiModelProperty("\"parent_order_id\": 0,")
	@JsonProperty("parent_order_id")
	private Long parentOrderId;


	@ApiModelProperty("修正 - 20211130 - \"ordersn\": \"ME20200511190608727927\", 订单编号 ordersn 修改为 orderSn")
	@JsonProperty("ordersn")
	private String orderSn;
	@ApiModelProperty("修正 - 20211130 - \"parent_ordersn\": \"\", 父订单编号 parent_ordersn 修改为 parentOrderSn")
	@JsonProperty("parent_ordersn")
	private String parentOrderSn;


	@ApiModelProperty("\"enterpriseId\": \"4138\",")
	@JsonProperty("enterpriseId")
	private Long   enterpriseId;
	@ApiModelProperty("\"organizationId\": \"313\",")
	@JsonProperty("organizationId")
	private Long   organizationId;
	@ApiModelProperty("\"organization_name\": \"超级前台湘江\",")
	@JsonProperty("organization_name")
	private String organizationName;
	@ApiModelProperty("\"enterprise_name\": \"超级前台湘江内购\",")
	@JsonProperty("enterprise_name")
	private String enterpriseName;


	@ApiModelProperty("\"order_type\": \"3\", 目前逻辑是 orderType 去断定 serviceNo serviceName ,orderType 计划弃用")
	@JsonProperty("order_type")
	private Integer orderType;

	@ApiModelProperty("修正 - 20211130 - \"status\": \"1\", 订单状态 key值 字段名 status 修改为 orderState")
	@JsonProperty("status")
	private Integer orderState;
	@ApiModelProperty("添加 - 20211130 - 订单状态 (中文名字-各系统的) 目前此值为通过映射得,更新不及时,故现在改为 业务系统直接传")
	private String  orderStateName;

	@ApiModelProperty("修正 - 20211130 - \"paytype\": \"0\", 支付方式 key值 字段名 paytype 修改为 payType")
	@JsonProperty("payType")
	private Integer payType;
	@ApiModelProperty("添加 - 20211130 - 支付方式 (中文名字-各系统的) 目前此值为通过映射得,更新不及时,故现在改为 业务系统直接传")
	private String  payTypeName;

	@ApiModelProperty(value = "添加 - 20211130 - 付款状态")
	private Integer payState;
	@ApiModelProperty(value = "添加 - 20211130 - 支付状态名称")
	private String  payStateName;

	@ApiModelProperty("\"price\": \"130.85\",")
	@JsonProperty("price")
	private BigDecimal price;


	@ApiModelProperty("\"expresssn\": \"\",")
	@JsonProperty("expresssn")
	private String     expressSn;
	@ApiModelProperty("\"dispatchname\": \"快递\",")
	@JsonProperty("dispatchname")
	private String     dispatchName;
	@ApiModelProperty("\"dispatchtype\": \"0\",")
	@JsonProperty("dispatchtype")
	private Integer    dispatchType;
	@ApiModelProperty("用户产生的运费 \"dispatchprice\": \"0.00\",")
	@JsonProperty("dispatchprice")
	private BigDecimal dispatchPrice;
	@ApiModelProperty("京东产生的运费 詹家豪 202012141555 就说要了加个字段")
	@JsonProperty("dispatchprice_jd")
	private BigDecimal dispatchPriceJd;

	@ApiModelProperty("\"createtime\": \"2020-05-11 19:06:08\",")
	@JsonProperty("createtime")
	@JsonSerialize(using = DateTimeConvertSerializer.class)
	@JsonDeserialize(using = DateTimeConvertDeserializer.class)
	private Date createTime;
	@ApiModelProperty("\"paytime\": \"2020-05-11 19:06:16\",")
	@JsonProperty("paytime")
	@JsonSerialize(using = DateTimeConvertSerializer.class)
	@JsonDeserialize(using = DateTimeConvertDeserializer.class)
	private Date payTime;
	@ApiModelProperty("\"sendtime\": \"1970-01-01 08:00:00\",")
	@JsonProperty("sendtime")
	@JsonSerialize(using = DateTimeConvertSerializer.class)
	@JsonDeserialize(using = DateTimeConvertDeserializer.class)
	private Date sendTime;
	@ApiModelProperty("\"finishtime\": \"1970-01-01 08:00:00\",")
	@JsonProperty("finishtime")
	@JsonSerialize(using = DateTimeConvertSerializer.class)
	@JsonDeserialize(using = DateTimeConvertDeserializer.class)
	private Date finishTime;


	@ApiModelProperty("\"companyName\": \"不开发票\",")
	@JsonProperty("companyName")
	private String  companyName;
	@ApiModelProperty("\"taxpayersIDcode\": \"\",")
	@JsonProperty("taxpayersIDcode")
	private String  taxpayersIDcode;
	@ApiModelProperty("\"invoice\": \"\",")
	@JsonProperty("invoice")
	private String  invoice;
	@ApiModelProperty("\"invoiceid\": \"0\",")
	@JsonProperty("invoiceid")
	private Long    invoiceId;
	@ApiModelProperty("\"invoiceType\": \"0\",")
	@JsonProperty("invoiceType")
	private Integer invoiceType;
	@ApiModelProperty("\"invoiceBank\": \"\",")
	@JsonProperty("invoiceBank")
	private String  invoiceBank;
	@ApiModelProperty("\"invoiceAccount\": \"\",")
	@JsonProperty("invoiceAccount")
	private String  invoiceAccount;

	@ApiModelProperty("\"isverify\": \"0\",")
	@JsonProperty("isverify")
	private Integer isVerify;

	@ApiModelProperty("\"isvirtual\": \"0\",")
	@JsonProperty("isvirtual")
	private Integer isVirtual;
	@ApiModelProperty("\"virtual\": \"0\",")
	@JsonProperty("virtual")
	private Long    virtual;

	@ApiModelProperty("\"deleted\": \"0\",")
	@JsonProperty("deleted")
	private Integer deleted;

	@ApiModelProperty("\"carrier\": \"a:0:{}\",")
	@JsonProperty("carrier")
	private String carrier;


	@ApiModelProperty("\"address\": \"a:18:{s:2:\\\"id\\\";s:4:\\\"3391\\\";s:7:\\\"uniacid\\\";s:2:\\\"17\\\";s:6:\\\"openid\\\";s:23:\\\"wap_user_17_17773191107\\\";s:8:\\\"realname\\\";s:6:\\\"岳琳\\\";s:6:\\\"mobile\\\";s:11:\\\"17773191107\\\";s:8:\\\"province\\\";s:6:\\\"湖南\\\";s:4:\\\"city\\\";s:9:\\\"长沙市\\\";s:4:\\\"area\\\";s:9:\\\"雨花区\\\";s:4:\\\"town\\\";s:15:\\\"候家塘街道\\\";s:7:\\\"address\\\";s:34:\\\"韶山北路298号紫金苑6栋907\\\";s:9:\\\"isdefault\\\";s:1:\\\"0\\\";s:7:\\\"zipcode\\\";s:0:\\\"\\\";s:7:\\\"deleted\\\";s:1:\\\"0\\\";s:20:\\\"jd_vop_province_code\\\";s:2:\\\"18\\\";s:16:\\\"jd_vop_city_code\\\";s:4:\\\"1482\\\";s:18:\\\"jd_vop_county_code\\\";s:5:\\\"48937\\\";s:16:\\\"jd_vop_town_code\\\";s:5:\\\"53600\\\";s:11:\\\"jd_vop_area\\\";s:19:\\\"18_1482_48937_53600\\\";}\",")
	@JsonProperty("address")
	private String address;
	@ApiModelProperty("\"addressid\": \"3391\",")
	@JsonProperty("addressid")
	private Long   addressId;


	@ApiModelProperty("\"realnameId\": \"5917\",")
	@JsonProperty("realnameId")
	private Long   realNameId;
	@ApiModelProperty("\"realname\": \"邱丽萍\",")
	@JsonProperty("realname")
	private String realName;

	@ApiModelProperty("\"mobile\": \"17773191107\",")
	@JsonProperty("mobile")
	private String mobile;
	@ApiModelProperty("\"arealname\": \"岳琳\",")
	@JsonProperty("arealname")
	private String aRealName;
	@ApiModelProperty("\"amobile\": \"17773191107\",")
	@JsonProperty("amobile")
	private String aMobile;

	@ApiModelProperty("\"aprovince\": \"湖南\",")
	@JsonProperty("aprovince")
	private String aProvince;
	@ApiModelProperty("\"acity\": \"长沙市\",")
	@JsonProperty("acity")
	private String aCity;
	@ApiModelProperty("\"aarea\": \"雨花区\",")
	@JsonProperty("aarea")
	private String aArea;
	@ApiModelProperty("\"atown\": \"候家塘街道\",")
	@JsonProperty("atown")
	private String aTown;
	@ApiModelProperty("\"aaddress\": \"韶山北路298号紫金苑6栋907\",")
	@JsonProperty("aaddress")
	private String aAddress;


	@ApiModelProperty("\"examineId\": \"\",")
	@JsonProperty("examineId")
	private String examineId;
	@ApiModelProperty("\"examine_name\": \"\",")
	@JsonProperty("examine_name")
	private String examineName;


	/****************************************** 代客专用 Excel 导入后台账号 start mark by linjinyu at 20201221 ******************************************/

	@ApiModelProperty("代客专用")
	@JsonProperty("create_account")
	private String operAccount;
	@ApiModelProperty("代客专用")
	@JsonProperty("create_name")
	private String operName;

	/****************************************** 代客专用 Excel 导入后台账号   end mark by linjinyu at 20201221 ******************************************/


	@ApiModelProperty("\"merchid\": \"8\",")
	@JsonProperty("merchid")
	private Long   merchId;
	@ApiModelProperty("\"merch_name\": \"超级前台自营京东旗舰店\",")
	@JsonProperty("merch_name")
	private String merchName;

	@ApiModelProperty("\"address_realname\": \"岳琳\",")
	@JsonProperty("address_realname")
	private String addressRealName;
	@ApiModelProperty("\"address_mobile\": \"17773191107\",")
	@JsonProperty("address_mobile")
	private String addressMobile;
	@ApiModelProperty("\"address_province\": \"湖南\",")
	@JsonProperty("address_province")
	private String addressProvince;
	@ApiModelProperty("\"address_city\": \"长沙市\",")
	@JsonProperty("address_city")
	private String addressCity;
	@ApiModelProperty("\"address_area\": \"雨花区\",")
	@JsonProperty("address_area")
	private String addressArea;
	@ApiModelProperty("\"address_town\": \"候家塘街道\",")
	@JsonProperty("address_town")
	private String addressTown;
	@ApiModelProperty("\"address_address\": \"湖南 长沙市 雨花区 候家塘街道 韶山北路298号紫金苑6栋907\",")
	@JsonProperty("address_address")
	private String addressAddress;

	@ApiModelProperty("\"detail_url\": \"https://wxn.avic-s.com/web/index.php?c=site&a=entry&m=superdesk_shopv2&do=web&r=order.detail&id=53322\",")
	@JsonProperty("detail_url")
	private String detailUrl;

	@ApiModelProperty("\"remark\": \"\",")
	@JsonProperty("remark")
	private String remark;

	@ApiModelProperty("目前只有超级前台-福利商城 \"message_id\":\"20210907173938-57a306a58362b1bd17d024521c3ce752\"")
	@JsonProperty("message_id")
	private String messageId;


	private List<UnifiedMixOrderGoodsReceiveParam> goods;
}
