package com.gree.mall.miniapp.bean.material.parts;

import com.gree.mall.miniapp.bean.inf.ValidGroup;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import java.util.List;

@Data
@ApiModel
public class SalesCustomerPartsBean {

    @ApiModelProperty(value = "商户编号", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "商户编号不能空")
    private String companyWechatId;

    @ApiModelProperty(value = "商户名称", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "商户名称不能空")
    private String companyWechatName;

    @ApiModelProperty(value = "维修标识 INNER=保内 OUTSIDE=保外", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "维修标识不能空")
    private String repairFlag;

    @ApiModelProperty(value = "接收网点编号", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "接收网点编号不能空")
    private String receiveWebsitId;

    @ApiModelProperty("接收配件网点编号")
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "接收配件网点编号不能空")
    private String receivePartsWebsitId;

    @ApiModelProperty(value = "师傅身份证", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "师傅身份证不能空")
    private String identity;

    @ApiModelProperty(value = "师傅编号", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "师傅编号不能空")
    private String workerId;

    @ApiModelProperty(value = "师傅名称", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "师傅名称不能空")
    private String workerName;

    @ApiModelProperty(value = "工单编号", required = true)
    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "工单编号不能空")
    private String workOrderNo;

    @ApiModelProperty(value = "用户名称", required = true)
//    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "用户名称不能空")
    private String customerName;

    @ApiModelProperty(value = "用户电话", required = true)
//    @NotBlank(groups = {ValidGroup.Add.class, ValidGroup.Edit.class}, message = "用户电话不能空")
    private String customerTel;

    @ApiModelProperty("备注")
    private String remark;

    @ApiModelProperty("明细")
    @NotEmpty(groups = { ValidGroup.Add.class,ValidGroup.Edit.class }, message = "明细不能空")
    private List<SalesCustomerPartsItemBean> items;

}
