package com.izouma.wenlvju.dto;

import cn.hutool.core.bean.BeanUtil;
import com.alibaba.excel.annotation.ExcelProperty;
import com.izouma.wenlvju.domain.TrainingInstitution;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
@ApiModel("培训机构")
public class TrainingInstitutionDTO {
    @ExcelProperty(value = "编号")
    private Long id;

    @ExcelProperty(value = "企业名称")
    @ApiModelProperty("企业名称")
    private String name;

    @ExcelProperty(value = "注册号")
    @ApiModelProperty("注册号")
    private String uscc;

    @ExcelProperty(value = "法人姓名")
    @ApiModelProperty(value = "法人姓名")
    private String privacyPolicy;

    @ExcelProperty(value = "固定电话")
    @ApiModelProperty(value = "固定电话")
    private String contactPhone;

    @ExcelProperty(value = "移动电话")
    @ApiModelProperty(value = "移动电话")
    private String phone;

    public TrainingInstitutionDTO(TrainingInstitution trainingInstitution) {
        BeanUtil.copyProperties(trainingInstitution, this);
    }
}
