Compare commits
No commits in common. "194c738d073bd196b1db7b1fb3fc7995f2341bce" and "9d06e979b816d20006d4c5c23325ea56b6bea49a" have entirely different histories.
194c738d07
...
9d06e979b8
@ -1,14 +0,0 @@
|
|||||||
-- Author: Hayden Hargreaves (hhargreaves2006@gmail.com)
|
|
||||||
-- Desc: Update recipes table to allow larger serving sizes.
|
|
||||||
-- Date: 01/13/2026
|
|
||||||
|
|
||||||
BEGIN;
|
|
||||||
|
|
||||||
ALTER TABLE recipes
|
|
||||||
DROP CONSTRAINT recipes_serves_check;
|
|
||||||
|
|
||||||
ALTER TABLE recipes
|
|
||||||
ADD CONSTRAINT recipes_serves_check
|
|
||||||
CHECK (serves >= 0 AND serves <= 127);
|
|
||||||
|
|
||||||
COMMIT;
|
|
||||||
@ -12,5 +12,3 @@ psql -h "$PSQL_HOST" -U "$PSQL_USERNAME" -d "$PSQL_DATABASE" -f ./internal/infra
|
|||||||
psql -h "$PSQL_HOST" -U "$PSQL_USERNAME" -d "$PSQL_DATABASE" -f ./internal/infrastructure/database/migrations/010_create_recipe_of_the_week_procedure.sql
|
psql -h "$PSQL_HOST" -U "$PSQL_USERNAME" -d "$PSQL_DATABASE" -f ./internal/infrastructure/database/migrations/010_create_recipe_of_the_week_procedure.sql
|
||||||
psql -h "$PSQL_HOST" -U "$PSQL_USERNAME" -d "$PSQL_DATABASE" -f ./internal/infrastructure/database/migrations/011_update_engagement_enum.sql
|
psql -h "$PSQL_HOST" -U "$PSQL_USERNAME" -d "$PSQL_DATABASE" -f ./internal/infrastructure/database/migrations/011_update_engagement_enum.sql
|
||||||
|
|
||||||
psql -h "$PSQL_HOST" -U "$PSQL_USERNAME" -d "$PSQL_DATABASE" -f ./internal/infrastructure/database/migrations/013_update_recipes_allow_large_servings.sql
|
|
||||||
|
|
||||||
|
|||||||
@ -34,7 +34,7 @@ export function validateCreateRecipeForm(values: CreateRecipeFormValues, dirty:
|
|||||||
servingSize: dirty.servingSize
|
servingSize: dirty.servingSize
|
||||||
? values.servingSize !== "" &&
|
? values.servingSize !== "" &&
|
||||||
Number(values.servingSize) >= 1 &&
|
Number(values.servingSize) >= 1 &&
|
||||||
Number(values.servingSize) <= 127
|
Number(values.servingSize) <= 16
|
||||||
: true,
|
: true,
|
||||||
category: dirty.category
|
category: dirty.category
|
||||||
? values.category !== "" && isRecipeMeal(values.category)
|
? values.category !== "" && isRecipeMeal(values.category)
|
||||||
|
|||||||
@ -385,7 +385,7 @@ export default function Create() {
|
|||||||
error="Please enter a serving size."
|
error="Please enter a serving size."
|
||||||
parentClasses="flex-grow w-1/3"
|
parentClasses="flex-grow w-1/3"
|
||||||
min="1"
|
min="1"
|
||||||
max="127"
|
max="16"
|
||||||
classes={INPUT_CLASSES}
|
classes={INPUT_CLASSES}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user