mirror of
https://github.com/pockethost/pockethost.git
synced 2025-11-24 06:25:48 +00:00
mothership: add notes field to user
This commit is contained in:
parent
ff74fcc690
commit
2b51452491
@ -0,0 +1,29 @@
|
||||
/// <reference path="../pb_data/types.d.ts" />
|
||||
migrate((db) => {
|
||||
const dao = new Dao(db)
|
||||
const collection = dao.findCollectionByNameOrId("systemprofiles0")
|
||||
|
||||
// add
|
||||
collection.schema.addField(new SchemaField({
|
||||
"system": false,
|
||||
"id": "5jejgdlc",
|
||||
"name": "notes",
|
||||
"type": "editor",
|
||||
"required": false,
|
||||
"presentable": false,
|
||||
"unique": false,
|
||||
"options": {
|
||||
"convertUrls": false
|
||||
}
|
||||
}))
|
||||
|
||||
return dao.saveCollection(collection)
|
||||
}, (db) => {
|
||||
const dao = new Dao(db)
|
||||
const collection = dao.findCollectionByNameOrId("systemprofiles0")
|
||||
|
||||
// remove
|
||||
collection.schema.removeField("5jejgdlc")
|
||||
|
||||
return dao.saveCollection(collection)
|
||||
})
|
||||
Loading…
x
Reference in New Issue
Block a user