mirror of
https://github.com/utopia-os/utopia-ui.git
synced 2025-12-13 07:46:10 +00:00
seed relations
This commit is contained in:
parent
213b97dfd5
commit
119afe2ea0
27
backend/directus-config/development/seed/relations.json
Normal file
27
backend/directus-config/development/seed/relations.json
Normal file
@ -0,0 +1,27 @@
|
||||
{
|
||||
"collection": "relations",
|
||||
"meta": {
|
||||
"insert_order": 1,
|
||||
"create": true,
|
||||
"update": true,
|
||||
"delete": true,
|
||||
"preserve_ids": true,
|
||||
"ignore_on_update": []
|
||||
},
|
||||
"data": [
|
||||
{
|
||||
"_sync_id": "1",
|
||||
"relation": "is_following",
|
||||
"heading": "Following",
|
||||
"direction": "outgoing",
|
||||
"hideWhenEmpty": true
|
||||
},
|
||||
{
|
||||
"_sync_id": "2",
|
||||
"relation": "is_following",
|
||||
"heading": "Follower",
|
||||
"direction": "ingoing",
|
||||
"hideWhenEmpty": true
|
||||
}
|
||||
]
|
||||
}
|
||||
@ -86,6 +86,32 @@ FROM
|
||||
public.types as types
|
||||
WHERE
|
||||
name = 'user:text+gallery'
|
||||
ON CONFLICT (id) DO UPDATE
|
||||
SET collection = excluded.collection,
|
||||
item = excluded.item,
|
||||
sort = excluded.sort,
|
||||
types_id = excluded.types_id;
|
||||
|
||||
INSERT INTO public."types_profileTemplate" (collection, id, item, sort, types_id)
|
||||
SELECT
|
||||
'relations', '3', '1' , '3', types.id
|
||||
FROM
|
||||
public.types as types
|
||||
WHERE
|
||||
name = 'user:text+gallery'
|
||||
ON CONFLICT (id) DO UPDATE
|
||||
SET collection = excluded.collection,
|
||||
item = excluded.item,
|
||||
sort = excluded.sort,
|
||||
types_id = excluded.types_id;
|
||||
|
||||
INSERT INTO public."types_profileTemplate" (collection, id, item, sort, types_id)
|
||||
SELECT
|
||||
'relations', '4', '2' , '4', types.id
|
||||
FROM
|
||||
public.types as types
|
||||
WHERE
|
||||
name = 'user:text+gallery'
|
||||
ON CONFLICT (id) DO UPDATE
|
||||
SET collection = excluded.collection,
|
||||
item = excluded.item,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user