OK, I'm now happy with the issue experts' workflow.

This commit is contained in:
Simon Brooke 2018-09-06 16:08:51 +01:00
parent 54ad57349c
commit 863a7e3c0e
2 changed files with 30 additions and 2 deletions

View file

@ -1,3 +1,22 @@
------------------------------------------------------------------------
-- User `youyesyet` (the app, and less secure parts of the site)
-- must have the permissions of `canvassers`.
------------------------------------------------------------------------
DO
$do$
BEGIN
IF NOT EXISTS (
SELECT -- SELECT list can stay empty for this
FROM pg_catalog.pg_roles
WHERE rolname = 'youyesyet') THEN
CREATE ROLE youyesyet LOGIN PASSWORD 'thisisnotsecure';
END IF;
END
$do$;
grant canvassers to youyesyet;
------------------------------------------------------------------------ ------------------------------------------------------------------------
-- convenience view lv_followupactions of entity followupactions for -- convenience view lv_followupactions of entity followupactions for
-- lists, et cetera -- lists, et cetera

View file

@ -36,7 +36,7 @@
</label> </label>
{% ifmemberof issueexperts analysts issueeditors admin %} {% ifmemberof issueexperts analysts issueeditors admin %}
<span id='visit' name='visit' class='pseudo-widget disabled'> <span id='visit' name='visit' class='pseudo-widget disabled'>
by {{visit.canvasser_id_expanded}} at {{visit.date}} by {{visit.canvasser_id_expanded}} on {{visit.date}}
</span> </span>
{% else %} {% else %}
<span id='visit_id' name='visit_id' class='pseudo-widget not-authorised'> <span id='visit_id' name='visit_id' class='pseudo-widget not-authorised'>
@ -46,8 +46,17 @@
</p> </p>
<p class='widget'> <p class='widget'>
<label for='issue_id'> <label for='issue_id'>
{{issue.id}} Issue
</label> </label>
{% ifmemberof issueexperts analysts issueeditors admin %}
<span id='visit' name='visit' class='pseudo-widget disabled'>
{{issue.id}}
</span>
{% else %}
<span id='visit_id' name='visit_id' class='pseudo-widget not-authorised'>
You are not permitted to view visit of followuprequests
</span>
{% endifmemberof %}
{% ifmemberof issueexperts admin %} {% ifmemberof issueexperts admin %}
<div id="issue-brief"> <div id="issue-brief">
{{issue.brief|safe}} {{issue.brief|safe}}