mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-09-20 15:08:34 +03:00
graph-view: hard-code app-name to %graph on server-side
This commit is contained in:
parent
183e7210cc
commit
9d4e10ff48
@ -25,33 +25,28 @@
|
||||
title+(un so)
|
||||
description+(un so)
|
||||
mark+(uf ~ (mu so))
|
||||
app+(un so)
|
||||
associated+(un associated)
|
||||
==
|
||||
::
|
||||
++ leave
|
||||
%- ot
|
||||
:~ resource+dejs:resource
|
||||
app+so
|
||||
==
|
||||
::
|
||||
++ delete
|
||||
%- ot
|
||||
:~ resource+dejs:resource
|
||||
app+so
|
||||
==
|
||||
::
|
||||
++ join
|
||||
%- ot
|
||||
:~ resource+dejs:resource
|
||||
app+so
|
||||
ship+(su ;~(pfix sig fed:ag))
|
||||
==
|
||||
::
|
||||
++ groupify
|
||||
%- ou
|
||||
:~ resource+(un dejs:resource)
|
||||
app+(un so)
|
||||
to+(uf ~ (mu dejs:resource))
|
||||
==
|
||||
++ invite !!
|
||||
|
@ -32,14 +32,13 @@
|
||||
title=@t
|
||||
description=@t
|
||||
mark=(unit mark)
|
||||
app=@tas
|
||||
=associated
|
||||
==
|
||||
[%delete rid=resource app=@tas]
|
||||
[%leave rid=resource app=@tas]
|
||||
[%join rid=resource app=@tas =ship]
|
||||
[%delete rid=resource]
|
||||
[%leave rid=resource]
|
||||
[%join rid=resource =ship]
|
||||
::[%invite rid=resource ships=(set ship)]
|
||||
[%groupify rid=resource app=@tas to=(unit resource)]
|
||||
[%groupify rid=resource to=(unit resource)]
|
||||
==
|
||||
--
|
||||
|
||||
|
@ -53,7 +53,7 @@
|
||||
creator our.bowl
|
||||
==
|
||||
=/ act=metadata-action
|
||||
[%add group-path [app.action (en-path:resource rid.action)] metadata]
|
||||
[%add group-path graph+(en-path:resource rid.action) metadata]
|
||||
;< ~ bind:m (poke-our %metadata-hook %metadata-action !>(act))
|
||||
;< ~ bind:m
|
||||
(poke-our %metadata-hook %metadata-hook-action !>([%add-owned group-path]))
|
||||
|
@ -27,7 +27,7 @@
|
||||
(pure:m u.ugroup)
|
||||
::
|
||||
++ scry-metadatum
|
||||
|= [app=app-name:graph-view rid=resource]
|
||||
|= rid=resource
|
||||
=/ m (strand ,metadata)
|
||||
^- form:m
|
||||
=/ enc-path=@t
|
||||
@ -35,7 +35,7 @@
|
||||
;< umeta=(unit metadata) bind:m
|
||||
%+ scry:strandio (unit metadata)
|
||||
%+ weld /gx/metadata-store/metadata
|
||||
/[enc-path]/[app]/[enc-path]/noun
|
||||
/[enc-path]/graph/[enc-path]/noun
|
||||
?> ?=(^ umeta)
|
||||
(pure:m u.umeta)
|
||||
--
|
||||
@ -50,7 +50,7 @@
|
||||
?. hidden.group
|
||||
(strand-fail:strandio %bad-request ~)
|
||||
;< =metadata bind:m
|
||||
(scry-metadatum app.action rid.action)
|
||||
(scry-metadatum rid.action)
|
||||
?~ to.action
|
||||
;< ~ bind:m
|
||||
%+ poke-our %contact-view
|
||||
@ -63,11 +63,12 @@
|
||||
=/ app-path
|
||||
(en-path:resource rid.action)
|
||||
=/ add-md=metadata-action
|
||||
[%add new-path [app.action app-path] metadata]
|
||||
[%add new-path graph+app-path metadata]
|
||||
;< ~ bind:m
|
||||
(poke-our %metadata-store metadata-action+!>(add-md))
|
||||
;< ~ bind:m
|
||||
(poke-our %metadata-store metadata-action+!>([%remove app-path [app.action app-path]]))
|
||||
%+ poke-our %metadata-store
|
||||
metadata-action+!>([%remove app-path graph+app-path])
|
||||
;< ~ bind:m
|
||||
(poke-our %group-store %group-update !>([%remove-group rid.action]))
|
||||
(pure:m !>(~))
|
||||
|
@ -8,13 +8,13 @@
|
||||
++ poke-our poke-our:strandio
|
||||
::
|
||||
++ scry-metadata
|
||||
|= [app=@tas rid=resource]
|
||||
|= rid=resource
|
||||
=/ m (strand ,(unit resource))
|
||||
^- form:m
|
||||
;< pax=(unit (set path)) bind:m
|
||||
%+ scry:strandio ,(unit (set path))
|
||||
;: weld
|
||||
/gx/metadata-store/resource/[app]
|
||||
/gx/metadata-store/resource/graph
|
||||
(en-path:resource rid)
|
||||
/noun
|
||||
==
|
||||
@ -33,8 +33,7 @@
|
||||
;< =bowl:spider bind:m get-bowl:strandio
|
||||
?: =(our.bowl entity.rid.action)
|
||||
(fail %bad-request ~)
|
||||
;< group=(unit resource) bind:m
|
||||
(scry-metadata app.action rid.action)
|
||||
;< group=(unit resource) bind:m (scry-metadata rid.action)
|
||||
?^ group
|
||||
:: We have group, graph is managed
|
||||
;< ~ bind:m
|
||||
|
@ -7,13 +7,13 @@
|
||||
++ poke-our poke-our:strandio
|
||||
::
|
||||
++ scry-metadata
|
||||
|= [app=app-name:graph-view rid=resource]
|
||||
|= rid=resource
|
||||
=/ m (strand ,resource)
|
||||
^- form:m
|
||||
;< pax=(unit (set path)) bind:m
|
||||
%+ scry:strandio ,(unit (set path))
|
||||
;: weld
|
||||
/gx/metadata-store/resource/[app]
|
||||
/gx/metadata-store/resource/graph
|
||||
(en-path:resource rid)
|
||||
/noun
|
||||
==
|
||||
@ -22,13 +22,13 @@
|
||||
(pure:m (de-path:resource n.u.pax))
|
||||
::
|
||||
++ scry-group
|
||||
|= [app=app-name:graph-view rid=resource]
|
||||
|= rid=resource
|
||||
=/ m (strand ,group)
|
||||
^- form:m
|
||||
;< ugroup=(unit group) bind:m
|
||||
%+ scry:strandio ,(unit group)
|
||||
;: weld
|
||||
/gx/group-store/resource/[app]
|
||||
/gx/group-store/resource/graph
|
||||
(en-path:resource rid)
|
||||
/noun
|
||||
==
|
||||
@ -54,10 +54,8 @@
|
||||
;< =bowl:spider bind:m get-bowl:strandio
|
||||
?: =(our.bowl entity.rid.action)
|
||||
(strand-fail:strandio %bad-request ~)
|
||||
;< group-rid=resource bind:m
|
||||
(scry-metadata app.action rid.action)
|
||||
;< g=group bind:m
|
||||
(scry-group app.action group-rid)
|
||||
;< group-rid=resource bind:m (scry-metadata rid.action)
|
||||
;< g=group bind:m (scry-group group-rid)
|
||||
?. hidden.g
|
||||
;< ~ bind:m (delete-graph rid.action)
|
||||
(pure:m !>(~))
|
||||
|
Loading…
Reference in New Issue
Block a user