package cn.ysk.cashier.dto.shop;

import lombok.Data;

import java.util.List;

import cn.ysk.cashier.annotation.Query;
import org.apache.commons.lang3.StringUtils;

/**
 * @author lyf
 * @website https://eladmin.vip
 * @date 2024-01-23
 **/
@Data
public class TbShopPurveyorTransactQueryCriteria {

    /**
     * 精确
     */
    @Query
    private String shopId;

    /**
     * 精确
     */
    @Query(type = Query.Type.LEFT_LIKE)
    private String purveyorName;

    /**
     * 精确
     */
    @Query
    private String purveyorId;
    /**
     * purveyor进货  reject退货
     */
    @Query
    private String type;

    @Query
    private Integer status;

    @Query(type = Query.Type.BETWEEN)
    private List<Long> createdAt;

    private Integer page;

    private Integer size;

    public void setShopId(String shopId) {
        if (StringUtils.isNotBlank(shopId) && !shopId.equals("1")) {
            this.shopId = shopId;
        }
    }

    public void setStatus(Integer status) {
        if (status != null) {
            this.status = status;
        }
    }

    public void setType(String type) {
        if (StringUtils.isNotBlank(type)) {
            this.type = type;
        }
    }
}