package es.verdnatura.presentation.view.feature.delivery.model

import androidx.room.Entity
import androidx.room.PrimaryKey
import androidx.room.TypeConverters
import es.verdnatura.db.MapTypeConverter
import java.io.Serializable

class ClientTicketList(
    var list: MutableList<ClientTicketSalix> = mutableListOf()
)

//Tarea 6275
@Entity(tableName = "clientTickets")
data class ClientTicketSalix(
    @PrimaryKey var id: Long,
    var clientFk: Int,
    var nickname: String,
    var addressFk: Int,
    var packages: Int,
    var street: String,
    var postalCode: String,
    var city: String,
    var warehouseName: String?,
    var salePersonPhone: String?,
    var ticketObservation: String?,
    var clientPhone: String?,
    var clientMobile: String?,
    var addressPhone: String?,
    var addressMobile: String?,
    var signed: Int,
    var latitude: Double?,
    var longitude: Double?,
    var ipt: String?,
    @TypeConverters(MapTypeConverter::class) var tickets: MutableList<Ticket>,
    var cmrFk: Int? = null,
    var route: Long? = null,
    var email: String? = null
) : Serializable

data class MyLocation(
    var Longitude: Double,
    var Latitude: Double
) : Serializable

data class Ticket(
    var Id: Long,
    var Packages: Int,
    var PackingType: String?,
    var Note: String?,
    var cmrFk: Int? = null
) : Serializable

@Entity(tableName = "signedPending")
data class SignedTickets(
    @TypeConverters(MapTypeConverter::class) val queryMapList: MutableMap<String?, String?>,
    @PrimaryKey
    val fileName: String
)
