Make api show/update/destroy relation actions resourceful
This commit is contained in:
parent
35fc840b41
commit
18f65b78eb
4 changed files with 10 additions and 13 deletions
|
@ -38,8 +38,7 @@ class ApiAbility
|
|||
if user.terms_agreed?
|
||||
can [:create, :update, :upload, :close, :subscribe, :unsubscribe], Changeset if scope?(token, :write_api)
|
||||
can :create, ChangesetComment if scope?(token, :write_api)
|
||||
can [:create, :update, :destroy], [Node, Way] if scope?(token, :write_api)
|
||||
can [:create, :update, :delete], [Relation] if scope?(token, :write_api)
|
||||
can [:create, :update, :destroy], [Node, Way, Relation] if scope?(token, :write_api)
|
||||
end
|
||||
|
||||
if user.moderator?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue