package com.carmaintenance.data.model

import com.google.gson.annotations.SerializedName

/**
 * 车辆实体
 */
data class Vehicle(
    @SerializedName("vehicleId")
    val vehicleId: Int,
    @SerializedName("customerId")
    val customerId: Int,
    @SerializedName("licensePlate")
    val licensePlate: String,
    @SerializedName("brand")
    val brand: String,
    @SerializedName("model")
    val model: String,
    @SerializedName("color")
    val color: String? = null,
    @SerializedName("vin")
    val vin: String? = null,
    @SerializedName("engineNo")
    val engineNo: String? = null,
    @SerializedName("purchaseDate")
    val purchaseDate: String? = null,
    @SerializedName("mileage")
    val mileage: Double? = 0.0,
    @SerializedName("lastMaintenanceDate")
    val lastMaintenanceDate: String? = null,
    @SerializedName("nextMaintenanceDate")
    val nextMaintenanceDate: String? = null,
    @SerializedName("status")
    val status: String = "normal"
) {
    val displayName: String
        get() = "$licensePlate - $brand $model"
}
