package com.younike.wxpay.params;

import lombok.Builder;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/** 下单参数 */
@Data
@Builder
public class TransactionParams {

    @NotBlank(message = "appid不能为空")
    private String appid;
    private String sp_appid;

    @NotBlank(message = "商户号不能为空")
    private String mchid;
    private String sp_mchid;

    private String sub_appid;
    private String sub_mchid;

    @NotBlank(message = "商品描述不能为空")
    private String description;

    @NotBlank(message = "商户订单号不能为空")
    private String out_trade_no;

    /* 订单失效时间 yyyy-MM-DDTHH:mm:ss+TIMEZONE */
    private String time_expire;

    /* 附加数据*/
    private String attach;

    @NotBlank(message = "通知地址不能为空")
    private String notify_url;

    /* 订单优惠标记 */
    private String goods_tag;

    @NotNull(message = "订单金额不能为空")
    private Amount amount;

    @NotNull(message = "支付者不能为空")
    private Payer payer;

    /* 订单明细 */
    private Detail detail;

    /* 场景信息 */
    private SceneInfo scene_info;

    /* 结算信息 */
    private SettleInfo settle_info;

}
