package com.mmc.pms.entity;

import com.mmc.pms.model.dto.DeviceListDTO;
import io.swagger.annotations.ApiModel;
import lombok.Data;

/**
 * @Author small @Date 2023/5/15 17:04 @Version 1.0
 */
@Data
@ApiModel("设备列表")
public class DeviceListDO {
  private Integer id;
  private String deviceName;
  private String imageUrl;
  private String price;
  private String brandName;
  private String sysDistrictName;
  private String modelName;
  private String deviceCategoryName;
  private Integer residueCount;
  private Integer inventoryId;
  private String appraise;

  public DeviceListDTO deviceListDTO() {
    return DeviceListDTO.builder()
        .id(this.id)
        .deviceName(this.deviceName)
        .imageUrl(this.imageUrl)
        .price(this.price)
        .brandName(this.brandName)
        .sysDistrictName(this.sysDistrictName)
        .modelName(this.modelName)
        .deviceCategoryName(this.deviceCategoryName)
        .residueCount(this.residueCount)
        .inventoryId(this.inventoryId)
        .appraise(this.appraise)
        .build();
  }
}
