package cn.pluss.platform.entity;

import  java.util.Date;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * @author DJH 修改
 */
@Data
@Accessors(chain = true)
public class MerchantStore {

    @TableId
    private Integer id;
    private String merchantCode;
    private String merchantName;
    private String storeId;
    private String storeName;
    private String creator;
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date createDt;
    private String openingTime;
    /**
     * 1, 营业中；2, 禁用
     */
    private String status;
    private String email;

    //新增 2019-09-30 lq
    private String storeHeadPic;
    private String storeInsidePic;
    private String cashPic;
    private String productDesc;
    private String payEcdemicSwitch;

    /**
     * 是否是活动商户 0：否 1：是
     */
    private String isMarket;

    @TableField(exist = false)
    private String merchantType;

    /**
     * 查询条件
     */
    @TableField(exist = false)
    private String startTime;
    @TableField(exist = false)
    private String endTime;
    @TableField(exist = false)
    private Integer page;
    @TableField(exist = false)
    private Integer size;
    @TableField(exist = false)
    private String proName;
    @TableField(exist = false)
    private String cityName;
    @TableField(exist = false)
    private String alias;
    @TableField(exist = false)
    private String mcsStatus;

    /**
     * 是否允许异地支付
     * @return
     */
    public boolean allowEcdemicPay() {
        return "1".equals(payEcdemicSwitch);
    }
}

