Generate random ids for instructions and ingredients
This commit is contained in:
@@ -5,26 +5,26 @@ import kotlinx.serialization.Serializable
|
||||
|
||||
@Serializable
|
||||
data class AddRecipeRequestV0(
|
||||
@SerialName("name") val name: String = "",
|
||||
@SerialName("description") val description: String = "",
|
||||
@SerialName("recipeYield") val recipeYield: String = "",
|
||||
@SerialName("recipeIngredient") val recipeIngredient: List<AddRecipeIngredientV0> = emptyList(),
|
||||
@SerialName("recipeInstructions") val recipeInstructions: List<AddRecipeInstructionV0> = emptyList(),
|
||||
@SerialName("settings") val settings: AddRecipeSettingsV0 = AddRecipeSettingsV0(),
|
||||
@SerialName("name") val name: String,
|
||||
@SerialName("description") val description: String,
|
||||
@SerialName("recipeYield") val recipeYield: String,
|
||||
@SerialName("recipeIngredient") val recipeIngredient: List<AddRecipeIngredientV0>,
|
||||
@SerialName("recipeInstructions") val recipeInstructions: List<AddRecipeInstructionV0>,
|
||||
@SerialName("settings") val settings: AddRecipeSettingsV0,
|
||||
)
|
||||
|
||||
@Serializable
|
||||
data class AddRecipeIngredientV0(
|
||||
@SerialName("note") val note: String = "",
|
||||
@SerialName("note") val note: String,
|
||||
)
|
||||
|
||||
@Serializable
|
||||
data class AddRecipeInstructionV0(
|
||||
@SerialName("text") val text: String = "",
|
||||
@SerialName("text") val text: String,
|
||||
)
|
||||
|
||||
@Serializable
|
||||
data class AddRecipeSettingsV0(
|
||||
@SerialName("disableComments") val disableComments: Boolean = false,
|
||||
@SerialName("public") val public: Boolean = true,
|
||||
@SerialName("disableComments") val disableComments: Boolean,
|
||||
@SerialName("public") val public: Boolean,
|
||||
)
|
||||
@@ -5,26 +5,28 @@ import kotlinx.serialization.Serializable
|
||||
|
||||
@Serializable
|
||||
data class UpdateRecipeRequestV1(
|
||||
@SerialName("description") val description: String = "",
|
||||
@SerialName("recipeYield") val recipeYield: String = "",
|
||||
@SerialName("recipeIngredient") val recipeIngredient: List<AddRecipeIngredientV1> = emptyList(),
|
||||
@SerialName("recipeInstructions") val recipeInstructions: List<AddRecipeInstructionV1> = emptyList(),
|
||||
@SerialName("settings") val settings: AddRecipeSettingsV1 = AddRecipeSettingsV1(),
|
||||
@SerialName("description") val description: String,
|
||||
@SerialName("recipeYield") val recipeYield: String,
|
||||
@SerialName("recipeIngredient") val recipeIngredient: List<AddRecipeIngredientV1>,
|
||||
@SerialName("recipeInstructions") val recipeInstructions: List<AddRecipeInstructionV1>,
|
||||
@SerialName("settings") val settings: AddRecipeSettingsV1,
|
||||
)
|
||||
|
||||
@Serializable
|
||||
data class AddRecipeIngredientV1(
|
||||
@SerialName("note") val note: String = "",
|
||||
@SerialName("referenceId") val id: String,
|
||||
@SerialName("note") val note: String,
|
||||
)
|
||||
|
||||
@Serializable
|
||||
data class AddRecipeInstructionV1(
|
||||
@SerialName("id") val id: String,
|
||||
@SerialName("text") val text: String = "",
|
||||
@SerialName("ingredientReferences") val ingredientReferences: List<String> = emptyList(),
|
||||
@SerialName("ingredientReferences") val ingredientReferences: List<String>,
|
||||
)
|
||||
|
||||
@Serializable
|
||||
data class AddRecipeSettingsV1(
|
||||
@SerialName("disableComments") val disableComments: Boolean = false,
|
||||
@SerialName("public") val public: Boolean = true,
|
||||
@SerialName("disableComments") val disableComments: Boolean,
|
||||
@SerialName("public") val public: Boolean,
|
||||
)
|
||||
Reference in New Issue
Block a user