package com.yuchen.saas.payment.api.vo.orderCenter;

import com.yuchen.saas.payment.api.entity.OrderManage;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;
import java.util.List;

/**
 * @author cxj
 * @create 2023年6月25日15:39:50
 */
@Data
public class OrderManageDetailVO extends OrderManage {


    /**
     * 待支付充电对象
     */
    @ApiModelProperty(name = "parkDetail", value = "停车详情")
    private ParkDetail parkDetail;

    @ApiModelProperty(name = "chargeDetailList", value = "收费明细")
    private List<ChargeDetail> chargeDetailList;

    @ApiModelProperty(name = "stationId", value = "充电站id")
    private  Long stationId;

    @ApiModelProperty(name = "stationName", value = "充电站名称")
    private  String stationName;

    @ApiModelProperty(name = "billTime", value = "订单时长")
    private  Long billTime;

    @ApiModelProperty("最终实收金额")
    private Long finallyActualAmount;
    /**
     * 运营商名
     */
    private String operatorName;
    @Data
    public static class ParkDetail {

        @ApiModelProperty(name = "parkEventList", value = "停车事件集合")
        private List<ParkEvent> parkEventList;

        @ApiModelProperty(name = "parkName", value = "园区名称")
        private String parkName;

        @ApiModelProperty(name = "parkingName", value = "停车场名称")
        private String parkingName;

        @ApiModelProperty(name = "plateNo", value = "车牌号码")
        private String plateNo;

        @ApiModelProperty(name = "billType", value = "停车类型:1-临停 2-月卡 3-无牌车，4-特殊车，5-节假日，6-群组")
        private Integer billType;

        @ApiModelProperty(name = "enterTime", value = "进场时间")
        private Date enterTime;

        @ApiModelProperty(name = "outTime", value = "出场时间")
        private Date outTime;

        @ApiModelProperty(name = "parkTime", value = "累计停车时长")
        private Long parkTime;

        @ApiModelProperty(value = "应收金额（最大长度8） 单位：分")
        private Long supposeCost;
        /**
         * 已支付金额（最大长度8） 单位：分
         */
        @ApiModelProperty(value = "已支付金额（最大长度8） 单位：分")
        private Long paidCost;
        /**
         * 优惠减免金额（最大长度8） 单位：分
         */
        @ApiModelProperty(value = "优惠减免金额（最大长度8） 单位：分")
        private Long discountCost;
        /**
         * 账单总金额（最大长度8） 单位：分
         */
        @ApiModelProperty(value = "账单总金额（最大长度8） 单位：分")
        private Long totalCost;

        @ApiModelProperty(name = "hiPaidCost", value = "历史已付金额")
        private Long hiPaidCost;

        @ApiModelProperty(name = "hiDiscountCost", value = "历史已使用优惠券")
        private Long hiDiscountCost;

    }

    @Data
    public static class ParkEvent {
        @ApiModelProperty(name = "event", value = "停车事件")
        private String event;

        @ApiModelProperty(name = "time", value = "时间节点")
        private Date time;

        @ApiModelProperty(name = "name", value = "事项地点名称")
        private String name;

    }

    /**
     * 收费明细
     */
    @Data
    public static class ChargeDetail {
        @ApiModelProperty(name = "ruleName", value = "费用项")
        private String ruleName;

        @ApiModelProperty(name = "rate", value = "0按总时长  1按次数  2停车时段  3单位时长  4日夜组合")
        private Long rate;

        @ApiModelProperty(name = "timeFrame", value = "时段")
        private String timeFrame;

        @ApiModelProperty(name = "parkTimeDetail", value = "使用时长(分钟)")
        private Long parkTimeDetail;

        @ApiModelProperty(value = "收费金额")
        private Long fee;

        @ApiModelProperty(value = "优惠时长(分钟)")
        private Long discount;

    }




}
