package com.slodon.b2b2c.vo.helpdesk;

import com.slodon.b2b2c.seller.pojo.Vendor;
import com.slodon.b2b2c.system.pojo.Admin;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * 平台查看聊天记录，供应商客服vo
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class HelpdeskVendorVO implements Serializable {

    private static final long serialVersionUID = -8293180755869525230L;
    @ApiModelProperty("供应商ID，平台统一生成")
    private Long storeId;
    @ApiModelProperty("商户id")
    private Long vendorId;
    @ApiModelProperty("商户账号")
    private String vendorName;

    public HelpdeskVendorVO(Vendor vendor) {
        storeId = vendor.getStoreId();
        vendorId = vendor.getVendorId();
        vendorName = vendor.getVendorName();
    }

    public HelpdeskVendorVO(Admin admin) {
        storeId = 0L;
        vendorId = Long.valueOf(admin.getAdminId());
        vendorName = admin.getAdminName();
    }
}
