diff --git a/packages/pockethost/src/mothership-app/pb_migrations/1760356366_updated_instances.js b/packages/pockethost/src/mothership-app/pb_migrations/1760356366_updated_instances.js new file mode 100644 index 00000000..3f5a6414 --- /dev/null +++ b/packages/pockethost/src/mothership-app/pb_migrations/1760356366_updated_instances.js @@ -0,0 +1,31 @@ +/// +migrate((db) => { + const dao = new Dao(db) + const collection = dao.findCollectionByNameOrId("etae8tuiaxl6xfv") + + // add + collection.schema.addField(new SchemaField({ + "system": false, + "id": "9kcgvnac", + "name": "notes", + "type": "text", + "required": false, + "presentable": false, + "unique": false, + "options": { + "min": null, + "max": null, + "pattern": "" + } + })) + + return dao.saveCollection(collection) +}, (db) => { + const dao = new Dao(db) + const collection = dao.findCollectionByNameOrId("etae8tuiaxl6xfv") + + // remove + collection.schema.removeField("9kcgvnac") + + return dao.saveCollection(collection) +})