package com.yidian.shenghuoquan.buserorder.dto

import com.google.gson.annotations.SerializedName


/**
 * author: yinjiacheng
 * date: 2021/8/21 14:42
 * description: 订单详情数据结构
 */
data class OrderDetailDto(
  @SerializedName("appid")
  val appid: String,
  @SerializedName("audit_status")
  val auditStatus: Int,
  @SerializedName("audit_time") // 审核时间，商家拒绝退款时间取此字段
  val auditTime: String,
  @SerializedName("business_from")
  val businessFrom: Int,
  @SerializedName("close_time")
  val closeTime: String,
  @SerializedName("comment") // 订单备注
  val comment: String,
  @SerializedName("coupon_list") // 优惠券信息
  val couponList: List<Coupon>,
  @SerializedName("create_time")
  val createTime: String,
  @SerializedName("discount_fee") // 优惠金额
  val discountFee: Double,
  @SerializedName("is_refund")
  val isRefund: Int,
  @SerializedName("life_account_icon")
  val lifeAccountIcon: String,
  @SerializedName("life_account_id")
  val lifeAccountId: String,
  @SerializedName("life_account_name")
  val lifeAccountName: String,
  @SerializedName("marketing_id") // 活动id
  val marketingId: Long,
  @SerializedName("marketing_name") // 活动名称
  val marketingName: String,
  @SerializedName("merge_order_item_list")
  val mergeOrderItemList: List<MergeOrderItem>,
  @SerializedName("order_id") // 订单id
  val orderId: String,
  @SerializedName("order_item_list")
  val orderItemList: List<OrderItem>,
  @SerializedName("order_shipping_info") // 收货人信息
  val orderShippingInfo: OrderShippingInfo,
  @SerializedName("order_status") // 订单状态
  val orderStatus: Int,
  @SerializedName("order_status_text")
  val orderStatusText: String,
  @SerializedName("order_type")
  val orderType: Int,
  @SerializedName("pay_expiration_time")
  val payExpirationTime: String,
  @SerializedName("pay_time") // 支付时间
  val payTime: String,
  @SerializedName("payment") // 支付金额
  val payment: Double,
  @SerializedName("place_list") // 自提点信息
  val placeList: PlaceList,
  @SerializedName("post_fee")
  val postFee: Double,
  @SerializedName("receive_time")
  val receiveTime: String,
  @SerializedName("refund_amount") // 退款金额
  val refundAmount: Double,
  @SerializedName("refund_apply_time") // 退款申请时间
  val refundApplyTime: String,
  @SerializedName("refund_finish_time") // 退款完成时间
  val refundFinishTime: String,
  @SerializedName("shop_id")
  val shopId: String,
  @SerializedName("total_price") // 合计金额 = 优惠金额 + 支付金额
  val totalPrice: Double,
  @SerializedName("update_time")
  val updateTime: String,
  @SerializedName("use_coupon") // 是否使用优惠券，0未使用，1使用
  val useCoupon: Int,
  @SerializedName("user_id")
  val userId: Long,
  @SerializedName("wechat")
  val wechat: Wechat,
  @SerializedName("life_account_phone") // 生活号管理员手机号
  val lifeAccountPhone: String
)

data class Coupon(
  @SerializedName("amount")
  val amount: String,
  @SerializedName("coupon_amount")
  val couponAmount: Int,
  @SerializedName("coupon_id")
  val couponId: String,
  @SerializedName("desc") // 优惠券描述
  val desc: String,
  @SerializedName("end_time")
  val endTime: String,
  @SerializedName("id")
  val id: String,
  @SerializedName("jump_url")
  val jumpUrl: String,
  @SerializedName("name") // 优惠券名称
  val name: String,
  @SerializedName("start_time")
  val startTime: String,
  @SerializedName("status")
  val status: Int,
  @SerializedName("thumbnail")
  val thumbnail: String,
  @SerializedName("type")
  val type: Int,
  @SerializedName("use_activity_type")
  val useActivityType: Int,
  @SerializedName("use_amount_min")
  val useAmountMin: Int,
  @SerializedName("use_amount_type")
  val useAmountType: Int,
  @SerializedName("use_shop_type")
  val useShopType: Int
)

data class MergeOrderItem(
  @SerializedName("desc_pic_url")
  val descPicUrl: List<String>,
  @SerializedName("goods_name")
  val goodsName: String,
  @SerializedName("goods_num")
  val goodsNum: Int,
  @SerializedName("price")
  val price: Double
)

data class OrderItem(
  @SerializedName("clear_price")
  val clearPrice: Double,
  @SerializedName("create_time")
  val createTime: String,
  @SerializedName("desc_pic_url")
  val descPicUrl: List<String>,
  @SerializedName("expiration_time")
  val expirationTime: String,
  @SerializedName("goods_name") // 商品名称
  val goodsName: String,
  @SerializedName("goods_num") // 商品数量
  val goodsNum: Int,
  @SerializedName("goods_sale_type")
  val goodsSaleType: Int,
  @SerializedName("goods_share_code")
  val goodsShareCode: String,
  @SerializedName("goods_sku_id")
  val goodsSkuId: String,
  @SerializedName("goods_spu_id")
  val goodsSpuId: String,
  @SerializedName("goods_type")
  val goodsType: Int,
  @SerializedName("goods_version")
  val goodsVersion: Int,
  @SerializedName("introduce_pic_url")
  val introducePicUrl: List<String>,
  @SerializedName("is_used")
  val isUsed: Int,
  @SerializedName("marketing_id")
  val marketingId: Long,
  @SerializedName("marketing_type")
  val marketingType: Int,
  @SerializedName("order_id")
  val orderId: String,
  @SerializedName("order_item_id")
  val orderItemId: String,
  @SerializedName("payment")
  val payment: Double,
  @SerializedName("price") // 商品单价
  val price: Double,
  @SerializedName("refund_amount")
  val refundAmount: Double,
  @SerializedName("refund_count")
  val refundCount: Int,
  @SerializedName("refund_finish_time")
  val refundFinishTime: String,
  @SerializedName("refund_status")
  val refundStatus: Int,
  @SerializedName("rule_refund")
  val ruleRefund: Int,
  @SerializedName("settle_code")
  val settleCode: Long,
  @SerializedName("share_coupon")
  val shareCoupon: Int,
  @SerializedName("shop_id")
  val shopId: String,
  @SerializedName("sub_shop_id")
  val subShopId: String,
  @SerializedName("update_time")
  val updateTime: String,
  @SerializedName("use_time")
  val useTime: String,
  @SerializedName("user_id")
  val userId: Long
)

data class OrderShippingInfo(
  @SerializedName("create_time")
  val createTime: String,
  @SerializedName("order_id")
  val orderId: String,
  @SerializedName("receiver_address") // 收货人地址
  val receiverAddress: String,
  @SerializedName("receiver_mobile") // 收货人手机号码
  val receiverMobile: String,
  @SerializedName("receiver_name") // 收货人名称
  val receiverName: String,
  @SerializedName("take_place_id")
  val takePlaceId: Long,
  @SerializedName("update_time")
  val updateTime: String,
  @SerializedName("user_id")
  val userId: Long
)

data class PlaceList(
  @SerializedName("address") // 自提点地址
  val address: String,
  @SerializedName("area")
  val area: String,
  @SerializedName("city")
  val city: String,
  @SerializedName("contact_name") // 自提点联系人姓名
  val contactName: String,
  @SerializedName("create_time")
  val createTime: String,
  @SerializedName("is_delete")
  val isDelete: Int,
  @SerializedName("latitude")
  val latitude: String,
  @SerializedName("life_account_id")
  val lifeAccountId: String,
  @SerializedName("location")
  val location: String,
  @SerializedName("longitude")
  val longitude: String,
  @SerializedName("phone") // 自提点联系人手机号码
  val phone: String,
  @SerializedName("province")
  val province: String,
  @SerializedName("take_place_id")
  val takePlaceId: Long,
  @SerializedName("take_place_name") // 自提点名称
  val takePlaceName: String,
  @SerializedName("update_time")
  val updateTime: String
)

data class Wechat(
  @SerializedName("activity_type")
  val activityType: Int,
  @SerializedName("city")
  val city: String,
  @SerializedName("country")
  val country: String,
  @SerializedName("create_time")
  val createTime: String,
  @SerializedName("gender")
  val gender: String,
  @SerializedName("invite_user_id")
  val inviteUserId: Long,
  @SerializedName("is_history")
  val isHistory: Int,
  @SerializedName("language")
  val language: String,
  @SerializedName("openid")
  val openid: String,
  @SerializedName("phone")
  val phone: String,
  @SerializedName("province")
  val province: String,
  @SerializedName("session_key")
  val sessionKey: String,
  @SerializedName("union_id")
  val unionId: String,
  @SerializedName("update_time")
  val updateTime: String,
  @SerializedName("user_avatar")
  val userAvatar: String,
  @SerializedName("user_id")
  val userId: Long,
  @SerializedName("user_nick")
  val userNick: String,
  @SerializedName("wechat_app_id")
  val wechatAppId: String,
  @SerializedName("wechat_id")
  val wechatId: Long
)
