3 Commits

Author SHA1 Message Date
George Drummond
b71402955c
Failing tests 2019-05-17 13:25:10 -04:00
dandds
2d99b5cfc5 Permission-check for templates accounts for all permission levels.
`user_can` function built for Jinja template contexts should check
application, portfolio, and atat level permissions depending on what
resources are available on `g`.
2019-05-08 13:25:38 -04:00
dandds
42b912d4cb Look up major database resources in a before_request hook.
A `before_request` hook queries the database for portfolios, requests,
and task orders based on the route arguments. The resources are added as
attributes on `g`. The portfolio context processor and the access
decorator now rely on those resources being available on `g`.

WIP: find major resources in before_request hook, apply to g

WIP: use g.portfolio for portfolio context processor

WIP: the access decorator should rely on the resources being available on g
2019-05-06 16:32:55 -04:00