[Flow] Policy Item-Owner and Administrator should be able to delete

Carsten Bleicker carsten at bleicker.de
Fri Jan 17 13:42:36 CET 2014


hello,
want setup policy to do this:
a user can delete his own record.
and also an administrator can delete it.
i dont get it. any help?

resources:
  methods:
    Delete: 'method(Foo\Bar\Controller\BazController->deleteAction(foo.party == current.securityContext.party))'

roles:
  User: []
  Administrator: [ User ]

acls:
  AuthenticatedUser:
    methods:
      Delete: GRANT
  Administrator:
    methods:
      Delete: 'This one should granted for Administrators. They should be able to delete records with "foo.party != current.securityContext.party"'


More information about the Flow mailing list