package com.neusoft.smart.pos.dto.order.response;

import com.neusoft.smart.pos.framework.utils.DateUtils;
import com.neusoft.smart.pos.framework.utils.LocalDateTimeUtils;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;

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

/**
 * @author zcf
 * @date 2018-01-08 10：43
 * @description 退款订单查询使用Response
 */
@ApiModel
@Data
@NoArgsConstructor
public class PostRefundOrderResponse {
    public boolean isSuccess;

    public String originalOrderNumber;
    public String refundNumber;
    private Long refundedAmount;
    private Integer id;
    private Long refundableAmount;
    private String refundStatus;
    private Date refundedTime;

//    public void setPayTime(Date refundedTime) {
//        this.refundedTime = DateUtils.format(refundedTime, DateUtils.FORMAT_LONG);
//    }

    private List<PayRefundOrderInfo> payRefundOrderInfos;


    @Data
    @ApiModel
    public static class PayRefundOrderInfo {
        private Integer id;
        private String refundNumber;
        private String mOrderNumber;
        private String tradeId;
        private String payRefundOrderNumber;
        private String thirdRefundNumber;
        private String payType;
        private Long refundedAmount;
        private String refundStatus;
        private Date createdAt;
        private String refundedTime;

        public void setPayTime(Date refundedTime) {
            this.refundedTime = DateUtils.format(refundedTime, DateUtils.FORMAT_LONG);
        }
    }

}
