Recipie/api/pb_migrations/1755056714_updated_recipes.js
june b8de3e82e9 [PIE-8] Add recipe detail view And Other Major Changes (!6)
- Adds /recipe/:id page
- (Almost!) fully designed and functional recipe view
- Has steps, images, ingredients, peripheral info (work/wait time, rating, description, servings)
- New colour scheme! Much more monotone but in a nice way (imo)
- New font, not condensed
- Several more smaller design changes
Co-authored-by: june <self@breadone.net>
Co-committed-by: june <self@breadone.net>
2025-08-13 16:54:05 +12:00

45 lines
988 B
JavaScript

/// <reference path="../pb_data/types.d.ts" />
migrate((app) => {
const collection = app.findCollectionByNameOrId("pbc_842702175")
// add field
collection.fields.addAt(9, new Field({
"hidden": false,
"id": "number1485952547",
"max": null,
"min": null,
"name": "worktime",
"onlyInt": true,
"presentable": false,
"required": false,
"system": false,
"type": "number"
}))
// add field
collection.fields.addAt(10, new Field({
"hidden": false,
"id": "number2198822773",
"max": null,
"min": null,
"name": "waittime",
"onlyInt": true,
"presentable": false,
"required": false,
"system": false,
"type": "number"
}))
return app.save(collection)
}, (app) => {
const collection = app.findCollectionByNameOrId("pbc_842702175")
// remove field
collection.fields.removeById("number1485952547")
// remove field
collection.fields.removeById("number2198822773")
return app.save(collection)
})