package com.freemud.sdk.api.assortment.order.response.order;

import lombok.Data;

import java.util.List;

/**
 * All rights Reserved, Designed By www.freemud.cn
 *
 * @version V1.0
 * @Title: CreateFatherSonOrderResponse
 * @Package com.freemud.sdk.api.assortment.order.response.order
 * @Description:
 * @author: jiaxin.liu
 * @date: 2019/6/18 14:24
 * @Copyright: 2019 www.freemud.cn Inc. All rights reserved.
 * 注意：本内容仅限于上海非码科技内部传阅，禁止外泄以及用于其他的商业目
 */
@Data
public class CreateFatherSonOrderResponse {
    private Integer errcode;
    private List<QueryOrdersResponse.DataBean.OrderBean> orderBeanList;
    private String errmsg;

    public static CreateFatherSonOrderResponse error(Integer errcode, String errmsg) {
        CreateFatherSonOrderResponse createFatherSonOrderResponse = new CreateFatherSonOrderResponse();
        createFatherSonOrderResponse.setErrcode(errcode);
        createFatherSonOrderResponse.setErrmsg(errmsg);
        return createFatherSonOrderResponse;
    }

    public static CreateFatherSonOrderResponse error(String errcode, String errmsg) {
        CreateFatherSonOrderResponse createFatherSonOrderResponse = new CreateFatherSonOrderResponse();
        createFatherSonOrderResponse.setErrcode(Integer.parseInt(errcode));
        createFatherSonOrderResponse.setErrmsg(errmsg);
        return createFatherSonOrderResponse;
    }
}
