package com.liquidnet.service.goblin.param.shouqianba.request;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.List;

@ApiModel(value = "商城列表接口")
@Data
public class MallListQueryRequest implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "应用ID", example = "2025912312")
    private String appid;

    @ApiModelProperty(value = "过滤条件")
    private Filter filter;

    @ApiModelProperty(value = "分页游标")
    private Cursor cursor;

    @ApiModelProperty(value = "排序条件")
    private Sort sort;


    @Data
    @ApiModel("查询过滤条件")
    public static class Filter {

        @ApiModelProperty(value = "商户信息")
        private CommonRequest.Seller seller;

        @ApiModelProperty(value = "商城行业筛选")
        private List<String> industryCodes;

        @ApiModelProperty(value = "商城状态筛选")
        private List<Byte> states;

        @ApiModelProperty(value = "商城状态筛选")
        private Byte state;

        @ApiModelProperty(value = "创建时间起始")
        private String beginDateTime;

        @ApiModelProperty(value = "创建时间截止")
        private String endDateTime;
    }

    @Data
    @ApiModel("排序规则")
    public static class Sort {

        @ApiModelProperty(value = "排序方式: DESC/ASC")
        private String sort;

        @ApiModelProperty(value = "排序字段")
        private String sortField;
    }

    @Data
    @ApiModel("分页游标")
    public static class Cursor {

        @ApiModelProperty(value = "游标字段 分页依据的字段（固定为id）")
        private String cursorField;

        @ApiModelProperty(value = "结束游标 上一页的结束游标（首次查询传 null）")
        private String endCursor;

        @ApiModelProperty(value = "查询数量 每页返回的最大订单数")
        private Integer count;
    }
}
