package com.cool.store.request;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

@Data
public class UserAndPositionRequest {

    @ApiModelProperty("类型 职位:position  人员:person")
    private String type;

    @ApiModelProperty("type对应的值")
    private String value;

    @ApiModelProperty("名称")
    private String name;


    public static UserAndPositionRequest convert(String type, String value, String name) {
        UserAndPositionRequest userAndPositionRequest = new UserAndPositionRequest();
        userAndPositionRequest.setType(type);
        userAndPositionRequest.setValue(value);
        userAndPositionRequest.setName(name);
        return userAndPositionRequest;
    }

}
