package com.jeequan.jeepay.db.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.jeequan.jeepay.core.model.BaseModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.util.Date;

/**
 * <p>
 * 商户员工交接班记录表
 * </p>
 *
 * @author [mybatis plus generator]
 * @since 2023-01-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("t_store_user_work_record")
public class StoreUserWorkRecord  extends BaseModel {

    public static final LambdaQueryWrapper<StoreUserWorkRecord> gw(){
        return new LambdaQueryWrapper<>();
    }

    private static final long serialVersionUID=1L;
    /** 员工交接班状态  1-上班 2-下班 **/
    public static final byte WORK_STATE_START =1;
    public static final byte WORK_STATE_END =2;

    /**
     * ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 用户ID
     */
    private Long sysUserId;

    /**
     * 登录用户名
     */
    private String loginUsername;

    /**
     * 真实姓名
     */
    private String realname;

    /**
     * 员工编号
     */
    private String userNo;

    /**
     * 门店ID
     */
    private String storeId;

    /**
     * 商户编号
     */
    private String mchNo;

    /**
     * 成交订单笔数，含退款
     */
    private Long successCount;

    /**
     * 成交订单金额，单位分，含退款金额和手续费
     */
    private Long successAmount;

    /**
     * 退款总笔数，一笔订单多次退款，则计多次
     */
    private Long refundCount;

    /**
     * 退款金额，单位分
     */
    private Long refundAmount;

    /**
     * 登录时间
     */
    private Date workStartTime;

    /**
     * 登录方式， 参考：JWTPayload
     */
    private String loginPageType;

    /**
     * 退出时间
     */
    private Date workEndTime;

    /**
     * 登出方式， 参考：JWTPayload
     */
    private String logoutPageType;

    /**
     * 创建时间
     */
    private Date createdAt;

    /**
     * 更新时间
     */
    private Date updatedAt;


}
