package de.tsschulz.tt_tagebuch.shared.api.models

import kotlinx.serialization.Serializable

@Serializable
data class TrainingTimeDto(
    val id: Int = 0,
    val trainingGroupId: Int? = null,
    val weekday: Int = 0,
    val startTime: String = "",
    val endTime: String = "",
    val sortOrder: Int = 0,
)

@Serializable
data class TrainingGroupMemberBrief(
    val id: Int,
    val firstName: String? = null,
    val lastName: String? = null,
)

@Serializable
data class TrainingGroupDto(
    val id: Int = 0,
    val clubId: Int? = null,
    val name: String = "",
    val sortOrder: Int = 0,
    val excludeFromQuickDiaryCreate: Boolean = false,
    val isPreset: Boolean = false,
    val presetType: String? = null,
    val trainingTimes: List<TrainingTimeDto> = emptyList(),
    val members: List<TrainingGroupMemberBrief> = emptyList(),
)

@Serializable
data class CreateClubTrainingGroupBody(
    val name: String,
    val sortOrder: Int? = null,
)

@Serializable
data class UpdateClubTrainingGroupBody(
    val name: String,
    val sortOrder: Int? = null,
)

@Serializable
data class CreateTrainingTimeBody(
    val trainingGroupId: Int,
    val weekday: Int,
    val startTime: String,
    val endTime: String,
)

@Serializable
data class UpdateTrainingTimeBody(
    val weekday: Int,
    val startTime: String,
    val endTime: String,
)
