#17: progress, not complete.
This commit is contained in:
parent
0026218993
commit
9c3af4c936
|
@ -33,7 +33,7 @@
|
|||
[org.webjars/bootstrap "4.0.0-alpha.6-1"]
|
||||
[org.webjars/font-awesome "4.7.0"]
|
||||
[org.webjars.bower/tether "1.4.0"]
|
||||
[re-frame "0.9.2"]
|
||||
[re-frame "0.10.5"]
|
||||
[reagent "0.6.1"]
|
||||
[reagent-utils "0.2.1"]
|
||||
[ring-middleware-format "0.7.2"]
|
||||
|
@ -136,10 +136,10 @@
|
|||
[com.cemerick/piggieback "0.2.2-SNAPSHOT"]
|
||||
[directory-naming/naming-java "0.8"]
|
||||
[doo "0.1.7"]
|
||||
[figwheel-sidecar "0.5.9"]]
|
||||
[figwheel-sidecar "0.5.15"]]
|
||||
:plugins [[com.jakemccrary/lein-test-refresh "0.18.1"]
|
||||
[lein-doo "0.1.7"]
|
||||
[lein-figwheel "0.5.9"]
|
||||
[lein-figwheel "0.5.15"]
|
||||
[org.clojure/clojurescript "1.9.495"]]
|
||||
:cljsbuild
|
||||
{:builds
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
------------------------------------------------------------------------
|
||||
-- File queries.sql
|
||||
--
|
||||
-- autogenerated by adl.to-hugsql-queries at 2018-07-07T08:09:48.253Z
|
||||
-- autogenerated by adl.to-hugsql-queries at 2018-07-09T20:55:32.719Z
|
||||
--
|
||||
-- See [Application Description
|
||||
-- Language](https://github.com/simon-brooke/adl).
|
||||
|
@ -504,6 +504,19 @@ ORDER BY lv_canvassers.username,
|
|||
lv_canvassers.email,
|
||||
lv_canvassers.id
|
||||
|
||||
-- :name list-canvassers-by-issue :? :*
|
||||
-- :doc links all existing canvasser records related to a given issue
|
||||
SELECT *
|
||||
FROM canvassers, ln_expertise_canvassers_issues
|
||||
WHERE canvassers.id = ln_expertise_canvassers_issues.canvasser_id
|
||||
AND ln_expertise_canvassers_issues.issue_id = :id
|
||||
ORDER BY canvassers.username,
|
||||
canvassers.fullname,
|
||||
canvassers.address_id,
|
||||
canvassers.phone,
|
||||
canvassers.email,
|
||||
canvassers.id
|
||||
|
||||
-- :name list-canvassers-by-role :? :*
|
||||
-- :doc links all existing canvasser records related to a given role
|
||||
SELECT *
|
||||
|
@ -728,6 +741,13 @@ SELECT DISTINCT * FROM lv_issues
|
|||
--~ (if (:offset params) "OFFSET :offset ")
|
||||
--~ (if (:limit params) "LIMIT :limit" "LIMIT 100")
|
||||
|
||||
-- :name list-issues-by-canvasser :? :*
|
||||
-- :doc links all existing issue records related to a given canvasser
|
||||
SELECT *
|
||||
FROM issues, ln_experts_issues_canvassers
|
||||
WHERE issues.id = ln_experts_issues_canvassers.issue_id
|
||||
AND ln_experts_issues_canvassers.canvasser_id = :id
|
||||
|
||||
-- :name list-options :? :*
|
||||
-- :doc lists all existing option records
|
||||
SELECT DISTINCT * FROM lv_options
|
||||
|
|
|
@ -36,4 +36,27 @@ FROM addresses
|
|||
WHERE locality = :locality
|
||||
|
||||
|
||||
-- :name list-open-requests :? :*
|
||||
-- :doc lists all existing followuprequest records which have not been closed and which the :expert has expertise to answer.
|
||||
SELECT DISTINCT request.*,
|
||||
electors.name ||', '|| electors.gender AS elector_id_expanded,
|
||||
addresses.address ||', '|| addresses.postcode ||', '|| visits.date AS visit_id_expanded,
|
||||
request.issue_id as issue_id_expanded,
|
||||
request.method_id AS method_id_expanded,
|
||||
visits.date
|
||||
FROM followuprequests as request,
|
||||
ln_experts_issues_canvassers as expertise,
|
||||
canvassers as experts,
|
||||
electors,
|
||||
addresses,
|
||||
visits
|
||||
where not exists (select * from followupactions as action
|
||||
where action.request_id = request.id
|
||||
and action.closed = true)
|
||||
and request.elector_id = electors.id
|
||||
and request.visit_id = visits.id
|
||||
and visits.address_id = addresses.id
|
||||
and request.issue_id = expertise.issue_id
|
||||
and expertise.canvasser_id = :expert
|
||||
ORDER BY visits.date desc
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
--
|
||||
-- auto-generated by [Application Description Language framework]
|
||||
--
|
||||
-- (https://github.com/simon-brooke/adl) at 20180707T080949.294Z
|
||||
-- (https://github.com/simon-brooke/adl) at 20180709T205533.789Z
|
||||
--
|
||||
-- A web-app intended to be used by canvassers
|
||||
-- campaigning for a 'Yes' vote in the second independence
|
||||
|
@ -915,6 +915,38 @@ ALTER TABLE visits ADD CONSTRAINT ri_visits_canvassers_canvasser_id
|
|||
REFERENCES canvassers(id)
|
||||
ON DELETE NO ACTION ;
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- link table joining canvassers with issues
|
||||
------------------------------------------------------------------------
|
||||
CREATE TABLE ln_expertise_canvassers_issues
|
||||
(
|
||||
canvasser_id INTEGER,
|
||||
issue_id VARCHAR(32)
|
||||
);
|
||||
GRANT SELECT ON ln_expertise_canvassers_issues TO admin,
|
||||
analysts,
|
||||
canvassers,
|
||||
issueeditors,
|
||||
issueexperts,
|
||||
teamorganisers ;
|
||||
GRANT INSERT ON ln_expertise_canvassers_issues TO admin,
|
||||
canvassers,
|
||||
teamorganisers ;
|
||||
GRANT UPDATE ON ln_expertise_canvassers_issues TO admin,
|
||||
canvassers,
|
||||
teamorganisers ;
|
||||
GRANT DELETE ON ln_expertise_canvassers_issues TO admin ;
|
||||
|
||||
ALTER TABLE ln_expertise_canvassers_issues ADD CONSTRAINT ri_ln_expertise_canvassers_issues_canvassers_canvasser_id
|
||||
FOREIGN KEY( canvasser_id )
|
||||
REFERENCES canvassers(id)
|
||||
ON DELETE NO ACTION ;
|
||||
|
||||
ALTER TABLE ln_expertise_canvassers_issues ADD CONSTRAINT ri_ln_expertise_canvassers_issues_issues_issue_id
|
||||
FOREIGN KEY( issue_id )
|
||||
REFERENCES issues(id)
|
||||
ON DELETE NO ACTION ;
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- link table joining canvassers with roles
|
||||
------------------------------------------------------------------------
|
||||
|
@ -977,6 +1009,36 @@ ALTER TABLE ln_teams_events_teams ADD CONSTRAINT ri_ln_teams_events_teams_teams_
|
|||
REFERENCES teams(id)
|
||||
ON DELETE NO ACTION ;
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- link table joining issues with canvassers
|
||||
------------------------------------------------------------------------
|
||||
CREATE TABLE ln_experts_issues_canvassers
|
||||
(
|
||||
issue_id VARCHAR(32),
|
||||
canvasser_id INTEGER
|
||||
);
|
||||
GRANT SELECT ON ln_experts_issues_canvassers TO admin,
|
||||
analysts,
|
||||
canvassers,
|
||||
issueeditors,
|
||||
issueexperts,
|
||||
teamorganisers ;
|
||||
GRANT INSERT ON ln_experts_issues_canvassers TO admin,
|
||||
issueeditors ;
|
||||
GRANT UPDATE ON ln_experts_issues_canvassers TO admin,
|
||||
issueeditors ;
|
||||
GRANT DELETE ON ln_experts_issues_canvassers TO admin ;
|
||||
|
||||
ALTER TABLE ln_experts_issues_canvassers ADD CONSTRAINT ri_ln_experts_issues_canvassers_canvassers_canvasser_id
|
||||
FOREIGN KEY( canvasser_id )
|
||||
REFERENCES canvassers(id)
|
||||
ON DELETE NO ACTION ;
|
||||
|
||||
ALTER TABLE ln_experts_issues_canvassers ADD CONSTRAINT ri_ln_experts_issues_canvassers_issues_issue_id
|
||||
FOREIGN KEY( issue_id )
|
||||
REFERENCES issues(id)
|
||||
ON DELETE NO ACTION ;
|
||||
|
||||
------------------------------------------------------------------------
|
||||
-- link table joining roles with canvassers
|
||||
------------------------------------------------------------------------
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File application-index.html generated 2018-07-07T08:09:49.942Z by adl.to-selmer-templates.
|
||||
<!-- File application-index.html generated 2018-07-09T20:55:34.526Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -7,7 +7,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<dl class='index'>
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-addresses-Addresses'>
|
||||
<a href='{{servlet-context}}/list-addresses-Addresses'>
|
||||
Address
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -22,7 +22,7 @@ Addresses of all buildings which contain
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-authorities-Authorities'>
|
||||
<a href='{{servlet-context}}/list-authorities-Authorities'>
|
||||
Authority
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -37,7 +37,7 @@ Authorities which may authenticate canvassers to
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-canvassers-Canvassers'>
|
||||
<a href='{{servlet-context}}/list-canvassers-Canvassers'>
|
||||
Canvasser
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -52,7 +52,7 @@ Primary users of the system: those actually
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors %}
|
||||
<dt>
|
||||
<a href='list-districts-Districts'>
|
||||
<a href='{{servlet-context}}/list-districts-Districts'>
|
||||
District
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -68,7 +68,7 @@ Electoral districts: TODO: Shape (polygon)
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-dwellings-Dwellings'>
|
||||
<a href='{{servlet-context}}/list-dwellings-Dwellings'>
|
||||
Dwelling
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -87,7 +87,7 @@ All dwellings within addresses in the system; a
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-electors-Electors'>
|
||||
<a href='{{servlet-context}}/list-electors-Electors'>
|
||||
Elector
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -103,7 +103,7 @@ All electors known to the system; electors are
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-events-Events'>
|
||||
<a href='{{servlet-context}}/list-events-Events'>
|
||||
Event
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -120,7 +120,7 @@ Event
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-followupactions-Followupactions'>
|
||||
<a href='{{servlet-context}}/list-followupactions-Followupactions'>
|
||||
Followupaction
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -135,7 +135,7 @@ Actions taken on followup
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-followupmethods-Followupmethods'>
|
||||
<a href='{{servlet-context}}/list-followupmethods-Followupmethods'>
|
||||
Followupmethod
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -146,7 +146,7 @@ Followupmethod
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-followuprequests-Followuprequests'>
|
||||
<a href='{{servlet-context}}/list-followuprequests-Followuprequests'>
|
||||
Followuprequest
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -161,7 +161,7 @@ Requests for a followup with an issue
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-genders-Genders'>
|
||||
<a href='{{servlet-context}}/list-genders-Genders'>
|
||||
Gender
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -176,7 +176,7 @@ All genders which may be assigned to
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers analysts admin %}
|
||||
<dt>
|
||||
<a href='list-intentions-Intentions'>
|
||||
<a href='{{servlet-context}}/list-intentions-Intentions'>
|
||||
Intention
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -191,7 +191,7 @@ Intentions of electors to vote for options
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-issues-Issues'>
|
||||
<a href='{{servlet-context}}/list-issues-Issues'>
|
||||
Issue
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -206,7 +206,7 @@ Issues believed to be of interest to electors,
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-options-Options'>
|
||||
<a href='{{servlet-context}}/list-options-Options'>
|
||||
Option
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -221,7 +221,7 @@ Options in the election or referendum being
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<dt>
|
||||
<a href='list-roles-Roles'>
|
||||
<a href='{{servlet-context}}/list-roles-Roles'>
|
||||
Role
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -237,7 +237,7 @@ A role (essentially, the same as a group, but
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<dt>
|
||||
<a href='list-teams-Teams'>
|
||||
<a href='{{servlet-context}}/list-teams-Teams'>
|
||||
Team
|
||||
</a>
|
||||
</dt>
|
||||
|
@ -248,7 +248,7 @@ Team
|
|||
{% endifmemberof %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
|
||||
<dt>
|
||||
<a href='list-visits-Visits'>
|
||||
<a href='{{servlet-context}}/list-visits-Visits'>
|
||||
Visit
|
||||
</a>
|
||||
</dt>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-addresses-Address.html generated 2018-07-07T08:09:49.931Z by adl.to-selmer-templates.
|
||||
<!-- File form-addresses-Address.html generated 2018-07-09T20:55:34.515Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -10,28 +10,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-addresses-Address' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of addresses
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='address'>
|
||||
Address
|
||||
</label>
|
||||
{% if {{record.address}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='address' name='address' type='string' value='{{record.address}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
|
@ -45,11 +29,27 @@ You are not permitted to view address of addresses
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='address' name='address' type='string' value='{{record.address}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='address' name='address' class='pseudo-widget disabled'>
|
||||
{{record.address}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='address' name='address' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view address of addresses
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='postcode'>
|
||||
Postcode
|
||||
</label>
|
||||
{% if {{record.postcode}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='postcode' name='postcode' type='string' value='{{record.postcode}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
|
@ -63,11 +63,27 @@ You are not permitted to view postcode of addresses
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='postcode' name='postcode' type='string' value='{{record.postcode}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='postcode' name='postcode' class='pseudo-widget disabled'>
|
||||
{{record.postcode}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='postcode' name='postcode' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view postcode of addresses
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='phone'>
|
||||
Phone
|
||||
</label>
|
||||
{% if {{record.phone}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='phone' name='phone' type='string' value='{{record.phone}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
|
@ -81,11 +97,27 @@ You are not permitted to view phone of addresses
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='phone' name='phone' type='string' value='{{record.phone}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='phone' name='phone' class='pseudo-widget disabled'>
|
||||
{{record.phone}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='phone' name='phone' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view phone of addresses
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='district_id'>
|
||||
District_id
|
||||
</label>
|
||||
{% if {{record.district_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='districts' found='true'>
|
||||
<input name='district_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-districts?name=" + district_id_search_box.text, null, function (data) {updateMenuOptions("district_id", "id", ["name"], data);})'/>
|
||||
|
@ -105,11 +137,33 @@ You are not permitted to view district_id of addresses
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='districts' found='true'>
|
||||
<input name='district_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-districts?name=" + district_id_search_box.text, null, function (data) {updateMenuOptions("district_id", "id", ["name"], data);})'/>
|
||||
<br/>
|
||||
<select id='district_id' name='district_id'>
|
||||
{% for r in districts %}<option value='{{r.id}}' {% ifequal record.district_id r.id%}selected{% endifequal %}>{{r.name}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='district_id' name='district_id' class='pseudo-widget disabled'>
|
||||
{{record.district_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='district_id' name='district_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view district_id of addresses
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='latitude'>
|
||||
Latitude
|
||||
</label>
|
||||
{% if {{record.latitude}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='latitude' name='latitude' type='number' value='{{record.latitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -123,11 +177,27 @@ You are not permitted to view latitude of addresses
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='latitude' name='latitude' type='number' value='{{record.latitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='latitude' name='latitude' class='pseudo-widget disabled'>
|
||||
{{record.latitude}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='latitude' name='latitude' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view latitude of addresses
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='longitude'>
|
||||
Longitude
|
||||
</label>
|
||||
{% if {{record.longitude}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='longitude' name='longitude' type='number' value='{{record.longitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -141,6 +211,21 @@ You are not permitted to view longitude of addresses
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='longitude' name='longitude' type='number' value='{{record.longitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='longitude' name='longitude' class='pseudo-widget disabled'>
|
||||
{{record.longitude}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='longitude' name='longitude' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view longitude of addresses
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-authorities-Authority.html generated 2018-07-07T08:09:49.951Z by adl.to-selmer-templates.
|
||||
<!-- File form-authorities-Authority.html generated 2018-07-09T20:55:34.531Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -14,8 +14,9 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% if {{record.id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
|
@ -27,11 +28,27 @@ You are not permitted to view id of authorities
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of authorities
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='request_token_uri'>
|
||||
Request-token-uri
|
||||
</label>
|
||||
{% if {{record.request-token-uri}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='request_token_uri' name='request_token_uri' type='string' value='{{record.request_token_uri}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
|
@ -45,11 +62,27 @@ You are not permitted to view request_token_uri of authorities
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='request_token_uri' name='request_token_uri' type='string' value='{{record.request_token_uri}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='request_token_uri' name='request_token_uri' class='pseudo-widget disabled'>
|
||||
{{record.request_token_uri}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='request_token_uri' name='request_token_uri' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view request_token_uri of authorities
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='access_token_uri'>
|
||||
Access-token-uri
|
||||
</label>
|
||||
{% if {{record.access-token-uri}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='access_token_uri' name='access_token_uri' type='string' value='{{record.access_token_uri}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
|
@ -63,11 +96,27 @@ You are not permitted to view access_token_uri of authorities
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='access_token_uri' name='access_token_uri' type='string' value='{{record.access_token_uri}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='access_token_uri' name='access_token_uri' class='pseudo-widget disabled'>
|
||||
{{record.access_token_uri}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='access_token_uri' name='access_token_uri' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view access_token_uri of authorities
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='authorize_uri'>
|
||||
Authorize-uri
|
||||
</label>
|
||||
{% if {{record.authorize-uri}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='authorize_uri' name='authorize_uri' type='string' value='{{record.authorize_uri}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
|
@ -81,11 +130,27 @@ You are not permitted to view authorize_uri of authorities
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='authorize_uri' name='authorize_uri' type='string' value='{{record.authorize_uri}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='authorize_uri' name='authorize_uri' class='pseudo-widget disabled'>
|
||||
{{record.authorize_uri}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='authorize_uri' name='authorize_uri' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view authorize_uri of authorities
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='consumer_key'>
|
||||
Consumer-key
|
||||
</label>
|
||||
{% if {{record.consumer-key}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='consumer_key' name='consumer_key' type='string' value='{{record.consumer_key}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
|
@ -99,11 +164,27 @@ You are not permitted to view consumer_key of authorities
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='consumer_key' name='consumer_key' type='string' value='{{record.consumer_key}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='consumer_key' name='consumer_key' class='pseudo-widget disabled'>
|
||||
{{record.consumer_key}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='consumer_key' name='consumer_key' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view consumer_key of authorities
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='consumer_secret'>
|
||||
Consumer-secret
|
||||
</label>
|
||||
{% if {{record.consumer-secret}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='consumer_secret' name='consumer_secret' type='string' value='{{record.consumer_secret}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
|
@ -117,6 +198,21 @@ You are not permitted to view consumer_secret of authorities
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='consumer_secret' name='consumer_secret' type='string' value='{{record.consumer_secret}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='consumer_secret' name='consumer_secret' class='pseudo-widget disabled'>
|
||||
{{record.consumer_secret}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='consumer_secret' name='consumer_secret' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view consumer_secret of authorities
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-canvassers-Canvasser.html generated 2018-07-07T08:09:49.958Z by adl.to-selmer-templates.
|
||||
<!-- File form-canvassers-Canvasser.html generated 2018-07-09T20:55:34.536Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -11,28 +11,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-canvassers-Canvasser' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='username'>
|
||||
Username
|
||||
</label>
|
||||
{% if {{record.username}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='username' name='username' type='string' value='{{record.username}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
|
@ -46,11 +30,27 @@ You are not permitted to view username of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='username' name='username' type='string' value='{{record.username}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='username' name='username' class='pseudo-widget disabled'>
|
||||
{{record.username}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='username' name='username' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view username of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='fullname'>
|
||||
Fullname
|
||||
</label>
|
||||
{% if {{record.fullname}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='fullname' name='fullname' type='string' value='{{record.fullname}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
|
@ -64,11 +64,27 @@ You are not permitted to view fullname of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='fullname' name='fullname' type='string' value='{{record.fullname}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='fullname' name='fullname' class='pseudo-widget disabled'>
|
||||
{{record.fullname}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='fullname' name='fullname' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view fullname of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='elector_id'>
|
||||
Elector_id
|
||||
</label>
|
||||
{% if {{record.elector_id}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='electors' found='true'>
|
||||
<input name='elector_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-electors?gender=" + elector_id_search_box.text + "&email=" + elector_id_search_box.text + "&name=" + elector_id_search_box.text + "&phone=" + elector_id_search_box.text, null, function (data) {updateMenuOptions("elector_id", "id", ["gender", "email", "name", "phone"], data);})'/>
|
||||
|
@ -88,11 +104,33 @@ You are not permitted to view elector_id of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='electors' found='true'>
|
||||
<input name='elector_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-electors?gender=" + elector_id_search_box.text + "&email=" + elector_id_search_box.text + "&name=" + elector_id_search_box.text + "&phone=" + elector_id_search_box.text, null, function (data) {updateMenuOptions("elector_id", "id", ["gender", "email", "name", "phone"], data);})'/>
|
||||
<br/>
|
||||
<select id='elector_id' name='elector_id'>
|
||||
{% for r in electors %}<option value='{{r.id}}' {% ifequal record.elector_id r.id%}selected{% endifequal %}>{{r.name}} {{r.phone}} {{r.email}} {{r.gender}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='elector_id' name='elector_id' class='pseudo-widget disabled'>
|
||||
{{record.elector_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='elector_id' name='elector_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view elector_id of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='address_id'>
|
||||
Address_id
|
||||
</label>
|
||||
{% if {{record.address_id}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='addresses' found='true'>
|
||||
<input name='address_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-addresses?postcode=" + address_id_search_box.text + "&address=" + address_id_search_box.text, null, function (data) {updateMenuOptions("address_id", "id", ["postcode", "address"], data);})'/>
|
||||
|
@ -112,11 +150,33 @@ You are not permitted to view address_id of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='addresses' found='true'>
|
||||
<input name='address_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-addresses?postcode=" + address_id_search_box.text + "&address=" + address_id_search_box.text, null, function (data) {updateMenuOptions("address_id", "id", ["postcode", "address"], data);})'/>
|
||||
<br/>
|
||||
<select id='address_id' name='address_id'>
|
||||
{% for r in addresses %}<option value='{{r.id}}' {% ifequal record.address_id r.id%}selected{% endifequal %}>{{r.address}} {{r.postcode}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='address_id' name='address_id' class='pseudo-widget disabled'>
|
||||
{{record.address_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='address_id' name='address_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view address_id of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='phone'>
|
||||
Phone
|
||||
</label>
|
||||
{% if {{record.phone}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='phone' name='phone' type='string' value='{{record.phone}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
|
@ -130,11 +190,27 @@ You are not permitted to view phone of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='phone' name='phone' type='string' value='{{record.phone}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='phone' name='phone' class='pseudo-widget disabled'>
|
||||
{{record.phone}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='phone' name='phone' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view phone of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='email'>
|
||||
Email
|
||||
</label>
|
||||
{% if {{record.email}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='email' name='email' type='string' value='{{record.email}}' maxlength='128' size='60'/>
|
||||
{% else %}
|
||||
|
@ -148,11 +224,27 @@ You are not permitted to view email of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='email' name='email' type='string' value='{{record.email}}' maxlength='128' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='email' name='email' class='pseudo-widget disabled'>
|
||||
{{record.email}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='email' name='email' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view email of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='authority_id'>
|
||||
Authority_id
|
||||
</label>
|
||||
{% if {{record.authority_id}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='authorities' found='true'>
|
||||
<input name='authority_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-authorities?id=" + authority_id_search_box.text, null, function (data) {updateMenuOptions("authority_id", "id", ["id"], data);})'/>
|
||||
|
@ -172,11 +264,33 @@ You are not permitted to view authority_id of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='authorities' found='true'>
|
||||
<input name='authority_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-authorities?id=" + authority_id_search_box.text, null, function (data) {updateMenuOptions("authority_id", "id", ["id"], data);})'/>
|
||||
<br/>
|
||||
<select id='authority_id' name='authority_id'>
|
||||
{% for r in authorities %}<option value='{{r.id}}' {% ifequal record.authority_id r.id%}selected{% endifequal %}>{{r.id}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='authority_id' name='authority_id' class='pseudo-widget disabled'>
|
||||
{{record.authority_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='authority_id' name='authority_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view authority_id of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='authorised'>
|
||||
Authorised
|
||||
</label>
|
||||
{% if {{record.authorised}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='authorised' name='authorised' type='checkbox' value='{{record.authorised}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -190,11 +304,27 @@ You are not permitted to view authorised of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<input id='authorised' name='authorised' type='checkbox' value='{{record.authorised}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='authorised' name='authorised' class='pseudo-widget disabled'>
|
||||
{{record.authorised}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='authorised' name='authorised' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view authorised of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='roles'>
|
||||
Roles
|
||||
</label>
|
||||
{% if {{record.roles}} %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='roles' found='true'>
|
||||
<select id='roles' name='roles' multiple='multiple'>
|
||||
|
@ -212,6 +342,25 @@ You are not permitted to view roles of canvassers
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<span class='select-box' farside='roles' found='true'>
|
||||
<select id='roles' name='roles' multiple='multiple'>
|
||||
{% for r in roles %}<option value='{{r.role_id}}' {% ifequal record.roles r.role_id%}selected{% endifequal %}>{{r.name}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='roles' name='roles' class='pseudo-widget disabled'>
|
||||
{{record.roles}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='roles' name='roles' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view roles of canvassers
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-districts-District.html generated 2018-07-07T08:09:49.922Z by adl.to-selmer-templates.
|
||||
<!-- File form-districts-District.html generated 2018-07-09T20:55:34.509Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -10,28 +10,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-districts-District' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of districts
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='name'>
|
||||
Name
|
||||
</label>
|
||||
{% if {{record.name}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
|
@ -45,6 +29,21 @@ You are not permitted to view name of districts
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors %}
|
||||
<span id='name' name='name' class='pseudo-widget disabled'>
|
||||
{{record.name}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='name' name='name' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view name of districts
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-dwellings-Dwelling.html generated 2018-07-07T08:09:49.973Z by adl.to-selmer-templates.
|
||||
<!-- File form-dwellings-Dwelling.html generated 2018-07-09T20:55:34.547Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -10,28 +10,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-dwellings-Dwelling' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of dwellings
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='address_id'>
|
||||
Address_id
|
||||
</label>
|
||||
{% if {{record.address_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='addresses' found='true'>
|
||||
<input name='address_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-addresses?postcode=" + address_id_search_box.text + "&address=" + address_id_search_box.text, null, function (data) {updateMenuOptions("address_id", "id", ["postcode", "address"], data);})'/>
|
||||
|
@ -51,11 +35,33 @@ You are not permitted to view address_id of dwellings
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='addresses' found='true'>
|
||||
<input name='address_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-addresses?postcode=" + address_id_search_box.text + "&address=" + address_id_search_box.text, null, function (data) {updateMenuOptions("address_id", "id", ["postcode", "address"], data);})'/>
|
||||
<br/>
|
||||
<select id='address_id' name='address_id'>
|
||||
{% for r in addresses %}<option value='{{r.id}}' {% ifequal record.address_id r.id%}selected{% endifequal %}>{{r.address}} {{r.postcode}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='address_id' name='address_id' class='pseudo-widget disabled'>
|
||||
{{record.address_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='address_id' name='address_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view address_id of dwellings
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='sub_address'>
|
||||
Sub-address
|
||||
</label>
|
||||
{% if {{record.sub-address}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='sub_address' name='sub_address' type='string' value='{{record.sub_address}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
|
@ -69,6 +75,21 @@ You are not permitted to view sub_address of dwellings
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='sub_address' name='sub_address' type='string' value='{{record.sub_address}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='sub_address' name='sub_address' class='pseudo-widget disabled'>
|
||||
{{record.sub_address}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='sub_address' name='sub_address' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view sub_address of dwellings
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-electors-Elector.html generated 2018-07-07T08:09:49.947Z by adl.to-selmer-templates.
|
||||
<!-- File form-electors-Elector.html generated 2018-07-09T20:55:34.529Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -10,28 +10,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-electors-Elector' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of electors
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='name'>
|
||||
Name
|
||||
</label>
|
||||
{% if {{record.name}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
|
@ -45,11 +29,27 @@ You are not permitted to view name of electors
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='name' name='name' class='pseudo-widget disabled'>
|
||||
{{record.name}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='name' name='name' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view name of electors
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='dwelling_id'>
|
||||
Dwelling_id
|
||||
</label>
|
||||
{% if {{record.dwelling_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='dwellings' found='true'>
|
||||
<input name='dwelling_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-dwellings?sub-address=" + dwelling_id_search_box.text + "&address_id=" + dwelling_id_search_box.text, null, function (data) {updateMenuOptions("dwelling_id", "id", ["sub-address", "address_id"], data);})'/>
|
||||
|
@ -69,11 +69,33 @@ You are not permitted to view dwelling_id of electors
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='dwellings' found='true'>
|
||||
<input name='dwelling_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-dwellings?sub-address=" + dwelling_id_search_box.text + "&address_id=" + dwelling_id_search_box.text, null, function (data) {updateMenuOptions("dwelling_id", "id", ["sub-address", "address_id"], data);})'/>
|
||||
<br/>
|
||||
<select id='dwelling_id' name='dwelling_id'>
|
||||
{% for r in dwellings %}<option value='{{r.id}}' {% ifequal record.dwelling_id r.id%}selected{% endifequal %}>{{r.address_id}} {{r.sub-address}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='dwelling_id' name='dwelling_id' class='pseudo-widget disabled'>
|
||||
{{record.dwelling_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='dwelling_id' name='dwelling_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view dwelling_id of electors
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='phone'>
|
||||
Phone
|
||||
</label>
|
||||
{% if {{record.phone}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='phone' name='phone' type='string' value='{{record.phone}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
|
@ -87,11 +109,27 @@ You are not permitted to view phone of electors
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='phone' name='phone' type='string' value='{{record.phone}}' maxlength='16' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='phone' name='phone' class='pseudo-widget disabled'>
|
||||
{{record.phone}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='phone' name='phone' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view phone of electors
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='email'>
|
||||
Email
|
||||
</label>
|
||||
{% if {{record.email}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='email' name='email' type='string' value='{{record.email}}' maxlength='128' size='60'/>
|
||||
{% else %}
|
||||
|
@ -105,11 +143,27 @@ You are not permitted to view email of electors
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='email' name='email' type='string' value='{{record.email}}' maxlength='128' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='email' name='email' class='pseudo-widget disabled'>
|
||||
{{record.email}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='email' name='email' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view email of electors
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='gender'>
|
||||
Gender
|
||||
</label>
|
||||
{% if {{record.gender}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='genders' found='true'>
|
||||
<select id='gender' name='gender'>
|
||||
|
@ -127,6 +181,25 @@ You are not permitted to view gender of electors
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='genders' found='true'>
|
||||
<select id='gender' name='gender'>
|
||||
{% for r in genders %}<option value='{{r.id}}' {% ifequal record.gender r.id%}selected{% endifequal %}>{{r.id}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='gender' name='gender' class='pseudo-widget disabled'>
|
||||
{{record.gender}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='gender' name='gender' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view gender of electors
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-events-Events.html generated 2018-07-07T08:09:49.954Z by adl.to-selmer-templates.
|
||||
<!-- File form-events-Events.html generated 2018-07-09T20:55:34.534Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -11,28 +11,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-events-Events' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of events
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='name'>
|
||||
Name
|
||||
</label>
|
||||
{% if {{record.name}} %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
|
@ -46,11 +30,27 @@ You are not permitted to view name of events
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='name' name='name' class='pseudo-widget disabled'>
|
||||
{{record.name}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='name' name='name' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view name of events
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='teams'>
|
||||
Teams
|
||||
</label>
|
||||
{% if {{record.teams}} %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<span class='select-box' farside='teams' found='true'>
|
||||
<input name='teams_search_box' onchange='$.getJSON("/auto/json/seach-strings-teams?name=" + teams_search_box.text, null, function (data) {updateMenuOptions("teams", "id", ["name"], data);})'/>
|
||||
|
@ -70,11 +70,33 @@ You are not permitted to view teams of events
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<span class='select-box' farside='teams' found='true'>
|
||||
<input name='teams_search_box' onchange='$.getJSON("/auto/json/seach-strings-teams?name=" + teams_search_box.text, null, function (data) {updateMenuOptions("teams", "id", ["name"], data);})'/>
|
||||
<br/>
|
||||
<select id='teams' name='teams' multiple='multiple'>
|
||||
{% for r in teams %}<option value='{{r.id}}' {% ifequal record.teams r.id%}selected{% endifequal %}>{{r.name}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='teams' name='teams' class='pseudo-widget disabled'>
|
||||
{{record.teams}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='teams' name='teams' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view teams of events
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='date'>
|
||||
Date
|
||||
</label>
|
||||
{% if {{record.date}} %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='date' name='date' type='date' value='{{record.date}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -88,11 +110,27 @@ You are not permitted to view date of events
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='date' name='date' type='date' value='{{record.date}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='date' name='date' class='pseudo-widget disabled'>
|
||||
{{record.date}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='date' name='date' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view date of events
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='time'>
|
||||
Time
|
||||
</label>
|
||||
{% if {{record.time}} %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='time' name='time' type='time' value='{{record.time}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -106,11 +144,27 @@ You are not permitted to view time of events
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='time' name='time' type='time' value='{{record.time}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='time' name='time' class='pseudo-widget disabled'>
|
||||
{{record.time}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='time' name='time' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view time of events
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='decription'>
|
||||
Decription
|
||||
</label>
|
||||
{% if {{record.decription}} %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<textarea rows='8' cols='60' id='decription' name='decription'>
|
||||
{{record.decription}}
|
||||
|
@ -126,11 +180,29 @@ You are not permitted to view decription of events
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<textarea rows='8' cols='60' id='decription' name='decription'>
|
||||
{{record.decription}}
|
||||
</textarea>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='decription' name='decription' class='pseudo-widget disabled'>
|
||||
{{record.decription}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='decription' name='decription' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view decription of events
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='cancelled'>
|
||||
Cancelled
|
||||
</label>
|
||||
{% if {{record.cancelled}} %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='cancelled' name='cancelled' type='checkbox' value='{{record.cancelled}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -144,6 +216,21 @@ You are not permitted to view cancelled of events
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<input id='cancelled' name='cancelled' type='checkbox' value='{{record.cancelled}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='cancelled' name='cancelled' class='pseudo-widget disabled'>
|
||||
{{record.cancelled}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='cancelled' name='cancelled' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view cancelled of events
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-followupactions-Followupaction.html generated 2018-07-07T08:09:49.976Z by adl.to-selmer-templates.
|
||||
<!-- File form-followupactions-Followupaction.html generated 2018-07-09T20:55:34.549Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -11,28 +11,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-followupactions-Followupaction' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of followupactions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='request_id'>
|
||||
Request_id
|
||||
</label>
|
||||
{% if {{record.request_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='followuprequests' found='true'>
|
||||
<input name='request_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-followuprequests?elector_id=" + request_id_search_box.text + "&issue_id=" + request_id_search_box.text + "&visit_id=" + request_id_search_box.text, null, function (data) {updateMenuOptions("request_id", "id", ["elector_id", "issue_id", "visit_id"], data);})'/>
|
||||
|
@ -52,11 +36,33 @@ You are not permitted to view request_id of followupactions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='followuprequests' found='true'>
|
||||
<input name='request_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-followuprequests?elector_id=" + request_id_search_box.text + "&issue_id=" + request_id_search_box.text + "&visit_id=" + request_id_search_box.text, null, function (data) {updateMenuOptions("request_id", "id", ["elector_id", "issue_id", "visit_id"], data);})'/>
|
||||
<br/>
|
||||
<select id='request_id' name='request_id'>
|
||||
{% for r in followuprequests %}<option value='{{r.id}}' {% ifequal record.request_id r.id%}selected{% endifequal %}>{{r.elector_id}} {{r.visit_id}} {{r.issue_id}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
|
||||
<span id='request_id' name='request_id' class='pseudo-widget disabled'>
|
||||
{{record.request_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='request_id' name='request_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view request_id of followupactions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='actor'>
|
||||
Actor
|
||||
</label>
|
||||
{% if {{record.actor}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='actor_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + actor_search_box.text, null, function (data) {updateMenuOptions("actor", "", [""], data);})'/>
|
||||
|
@ -76,11 +82,33 @@ You are not permitted to view actor of followupactions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='actor_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + actor_search_box.text, null, function (data) {updateMenuOptions("actor", "", [""], data);})'/>
|
||||
<br/>
|
||||
<select id='actor' name='actor'>
|
||||
{% for r in canvassers %}<option value='{{r.id}}' {% ifequal record.actor r.id%}selected{% endifequal %}>{{r.username}} {{r.fullname}} {{r.address_id}} {{r.phone}} {{r.email}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
|
||||
<span id='actor' name='actor' class='pseudo-widget disabled'>
|
||||
{{record.actor}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='actor' name='actor' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view actor of followupactions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='date'>
|
||||
Date
|
||||
</label>
|
||||
{% if {{record.date}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='date' name='date' type='string' value='{{record.date}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -94,11 +122,27 @@ You are not permitted to view date of followupactions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='date' name='date' type='string' value='{{record.date}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
|
||||
<span id='date' name='date' class='pseudo-widget disabled'>
|
||||
{{record.date}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='date' name='date' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view date of followupactions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='notes'>
|
||||
Notes
|
||||
</label>
|
||||
{% if {{record.notes}} %}
|
||||
{% ifmemberof admin %}
|
||||
<textarea rows='8' cols='60' id='notes' name='notes'>
|
||||
{{record.notes}}
|
||||
|
@ -114,11 +158,29 @@ You are not permitted to view notes of followupactions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<textarea rows='8' cols='60' id='notes' name='notes'>
|
||||
{{record.notes}}
|
||||
</textarea>
|
||||
{% else %}
|
||||
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
|
||||
<span id='notes' name='notes' class='pseudo-widget disabled'>
|
||||
{{record.notes}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='notes' name='notes' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view notes of followupactions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='closed'>
|
||||
Closed
|
||||
</label>
|
||||
{% if {{record.closed}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='closed' name='closed' type='checkbox' value='{{record.closed}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -132,6 +194,21 @@ You are not permitted to view closed of followupactions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='closed' name='closed' type='checkbox' value='{{record.closed}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
|
||||
<span id='closed' name='closed' class='pseudo-widget disabled'>
|
||||
{{record.closed}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='closed' name='closed' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view closed of followupactions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-followupmethods-Followupmethod.html generated 2018-07-07T08:09:49.979Z by adl.to-selmer-templates.
|
||||
<!-- File form-followupmethods-Followupmethod.html generated 2018-07-09T20:55:34.550Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -14,8 +14,9 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% if {{record.id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
|
@ -27,6 +28,21 @@ You are not permitted to view id of followupmethods
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of followupmethods
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-followuprequests-Followuprequest.html generated 2018-07-07T08:09:49.925Z by adl.to-selmer-templates.
|
||||
<!-- File form-followuprequests-Followuprequest.html generated 2018-07-09T20:55:34.512Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -10,28 +10,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-followuprequests-Followuprequest' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of followuprequests
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='elector_id'>
|
||||
Elector_id
|
||||
</label>
|
||||
{% if {{record.elector_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='electors' found='true'>
|
||||
<input name='elector_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-electors?gender=" + elector_id_search_box.text + "&email=" + elector_id_search_box.text + "&name=" + elector_id_search_box.text + "&phone=" + elector_id_search_box.text, null, function (data) {updateMenuOptions("elector_id", "id", ["gender", "email", "name", "phone"], data);})'/>
|
||||
|
@ -51,11 +35,33 @@ You are not permitted to view elector_id of followuprequests
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='electors' found='true'>
|
||||
<input name='elector_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-electors?gender=" + elector_id_search_box.text + "&email=" + elector_id_search_box.text + "&name=" + elector_id_search_box.text + "&phone=" + elector_id_search_box.text, null, function (data) {updateMenuOptions("elector_id", "id", ["gender", "email", "name", "phone"], data);})'/>
|
||||
<br/>
|
||||
<select id='elector_id' name='elector_id'>
|
||||
{% for r in electors %}<option value='{{r.id}}' {% ifequal record.elector_id r.id%}selected{% endifequal %}>{{r.name}} {{r.phone}} {{r.email}} {{r.gender}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='elector_id' name='elector_id' class='pseudo-widget disabled'>
|
||||
{{record.elector_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='elector_id' name='elector_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view elector_id of followuprequests
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='visit_id'>
|
||||
Visit_id
|
||||
</label>
|
||||
{% if {{record.visit_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='visits' found='true'>
|
||||
<input name='visit_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-visits?address_id=" + visit_id_search_box.text + "&date=" + visit_id_search_box.text, null, function (data) {updateMenuOptions("visit_id", "id", ["address_id", "date"], data);})'/>
|
||||
|
@ -75,11 +81,33 @@ You are not permitted to view visit_id of followuprequests
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='visits' found='true'>
|
||||
<input name='visit_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-visits?address_id=" + visit_id_search_box.text + "&date=" + visit_id_search_box.text, null, function (data) {updateMenuOptions("visit_id", "id", ["address_id", "date"], data);})'/>
|
||||
<br/>
|
||||
<select id='visit_id' name='visit_id'>
|
||||
{% for r in visits %}<option value='{{r.id}}' {% ifequal record.visit_id r.id%}selected{% endifequal %}>{{r.address_id}} {{r.date}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='visit_id' name='visit_id' class='pseudo-widget disabled'>
|
||||
{{record.visit_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='visit_id' name='visit_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view visit_id of followuprequests
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='issue_id'>
|
||||
Issue_id
|
||||
</label>
|
||||
{% if {{record.issue_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='issues' found='true'>
|
||||
<select id='issue_id' name='issue_id'>
|
||||
|
@ -97,11 +125,31 @@ You are not permitted to view issue_id of followuprequests
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='issues' found='true'>
|
||||
<select id='issue_id' name='issue_id'>
|
||||
{% for r in issues %}<option value='{{r.id}}' {% ifequal record.issue_id r.id%}selected{% endifequal %}>{{r.id}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='issue_id' name='issue_id' class='pseudo-widget disabled'>
|
||||
{{record.issue_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='issue_id' name='issue_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view issue_id of followuprequests
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='method_id'>
|
||||
Method_id
|
||||
</label>
|
||||
{% if {{record.method_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='followupmethods' found='true'>
|
||||
<select id='method_id' name='method_id'>
|
||||
|
@ -119,6 +167,25 @@ You are not permitted to view method_id of followuprequests
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='followupmethods' found='true'>
|
||||
<select id='method_id' name='method_id'>
|
||||
{% for r in followupmethods %}<option value='{{r.id}}' {% ifequal record.method_id r.id%}selected{% endifequal %}>{{r.id}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='method_id' name='method_id' class='pseudo-widget disabled'>
|
||||
{{record.method_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='method_id' name='method_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view method_id of followuprequests
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-genders-Gender.html generated 2018-07-07T08:09:49.918Z by adl.to-selmer-templates.
|
||||
<!-- File form-genders-Gender.html generated 2018-07-09T20:55:34.505Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -14,8 +14,9 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% if {{record.id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
|
@ -27,6 +28,21 @@ You are not permitted to view id of genders
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of genders
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-intentions-Intention.html generated 2018-07-07T08:09:49.968Z by adl.to-selmer-templates.
|
||||
<!-- File form-intentions-Intention.html generated 2018-07-09T20:55:34.543Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -14,6 +14,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<label for='visit_id'>
|
||||
Visit_id
|
||||
</label>
|
||||
{% if {{record.visit_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='visits' found='true'>
|
||||
<input name='visit_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-visits?address_id=" + visit_id_search_box.text + "&date=" + visit_id_search_box.text, null, function (data) {updateMenuOptions("visit_id", "id", ["address_id", "date"], data);})'/>
|
||||
|
@ -33,11 +34,33 @@ You are not permitted to view visit_id of intentions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='visits' found='true'>
|
||||
<input name='visit_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-visits?address_id=" + visit_id_search_box.text + "&date=" + visit_id_search_box.text, null, function (data) {updateMenuOptions("visit_id", "id", ["address_id", "date"], data);})'/>
|
||||
<br/>
|
||||
<select id='visit_id' name='visit_id'>
|
||||
{% for r in visits %}<option value='{{r.id}}' {% ifequal record.visit_id r.id%}selected{% endifequal %}>{{r.address_id}} {{r.date}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers analysts admin %}
|
||||
<span id='visit_id' name='visit_id' class='pseudo-widget disabled'>
|
||||
{{record.visit_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='visit_id' name='visit_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view visit_id of intentions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='elector_id'>
|
||||
Elector_id
|
||||
</label>
|
||||
{% if {{record.elector_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='electors' found='true'>
|
||||
<input name='elector_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-electors?gender=" + elector_id_search_box.text + "&email=" + elector_id_search_box.text + "&name=" + elector_id_search_box.text + "&phone=" + elector_id_search_box.text, null, function (data) {updateMenuOptions("elector_id", "id", ["gender", "email", "name", "phone"], data);})'/>
|
||||
|
@ -57,11 +80,33 @@ You are not permitted to view elector_id of intentions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='electors' found='true'>
|
||||
<input name='elector_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-electors?gender=" + elector_id_search_box.text + "&email=" + elector_id_search_box.text + "&name=" + elector_id_search_box.text + "&phone=" + elector_id_search_box.text, null, function (data) {updateMenuOptions("elector_id", "id", ["gender", "email", "name", "phone"], data);})'/>
|
||||
<br/>
|
||||
<select id='elector_id' name='elector_id'>
|
||||
{% for r in electors %}<option value='{{r.id}}' {% ifequal record.elector_id r.id%}selected{% endifequal %}>{{r.name}} {{r.phone}} {{r.email}} {{r.gender}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers analysts admin %}
|
||||
<span id='elector_id' name='elector_id' class='pseudo-widget disabled'>
|
||||
{{record.elector_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='elector_id' name='elector_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view elector_id of intentions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='option_id'>
|
||||
Option_id
|
||||
</label>
|
||||
{% if {{record.option_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='options' found='true'>
|
||||
<select id='option_id' name='option_id'>
|
||||
|
@ -79,11 +124,31 @@ You are not permitted to view option_id of intentions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='options' found='true'>
|
||||
<select id='option_id' name='option_id'>
|
||||
{% for r in options %}<option value='{{r.id}}' {% ifequal record.option_id r.id%}selected{% endifequal %}>{{r.id}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers analysts admin %}
|
||||
<span id='option_id' name='option_id' class='pseudo-widget disabled'>
|
||||
{{record.option_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='option_id' name='option_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view option_id of intentions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='locality'>
|
||||
Locality
|
||||
</label>
|
||||
{% if {{record.locality}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='locality' name='locality' type='number' value='{{record.locality}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -97,6 +162,21 @@ You are not permitted to view locality of intentions
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='locality' name='locality' type='number' value='{{record.locality}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers analysts admin %}
|
||||
<span id='locality' name='locality' class='pseudo-widget disabled'>
|
||||
{{record.locality}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='locality' name='locality' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view locality of intentions
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-issues-Issue.html generated 2018-07-07T08:09:49.935Z by adl.to-selmer-templates.
|
||||
<!-- File form-issues-Issue.html generated 2018-07-09T20:55:34.521Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -15,8 +15,9 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% if {{record.id}} %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
|
@ -28,11 +29,27 @@ You are not permitted to view id of issues
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of issues
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='url'>
|
||||
Url
|
||||
</label>
|
||||
{% if {{record.url}} %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<input id='url' name='url' type='string' value='{{record.url}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
|
@ -46,11 +63,27 @@ You are not permitted to view url of issues
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<input id='url' name='url' type='string' value='{{record.url}}' maxlength='256' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='url' name='url' class='pseudo-widget disabled'>
|
||||
{{record.url}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='url' name='url' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view url of issues
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='current'>
|
||||
Current
|
||||
</label>
|
||||
{% if {{record.current}} %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<input id='current' name='current' type='checkbox' value='{{record.current}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -64,11 +97,27 @@ You are not permitted to view current of issues
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<input id='current' name='current' type='checkbox' value='{{record.current}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='current' name='current' class='pseudo-widget disabled'>
|
||||
{{record.current}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='current' name='current' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view current of issues
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='brief'>
|
||||
Brief
|
||||
</label>
|
||||
{% if {{record.brief}} %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<textarea rows='8' cols='60' id='brief' name='brief'>
|
||||
{{record.brief}}
|
||||
|
@ -84,6 +133,23 @@ You are not permitted to view brief of issues
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<textarea rows='8' cols='60' id='brief' name='brief'>
|
||||
{{record.brief}}
|
||||
</textarea>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='brief' name='brief' class='pseudo-widget disabled'>
|
||||
{{record.brief}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='brief' name='brief' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view brief of issues
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
@ -107,6 +173,21 @@ To delete this issues record
|
|||
{% endblock %}
|
||||
{% block extra-tail %}
|
||||
<script type='text/javascript'>
|
||||
/**
|
||||
* update the select menu with id `wid` from this `data` whose fields include
|
||||
* this `entity_key` and these `fields`
|
||||
*/
|
||||
function updateMenuOptions(wid, entity_key, fields, data){
|
||||
$('#' + wid).children().filter(function(){
|
||||
return $(this).attr('selected') === undefined;
|
||||
}).remove().end();
|
||||
|
||||
$.each(data, function(key, entry){
|
||||
$('#' + wid).append(
|
||||
$('<option></option>').attr('value', key).text(entry));
|
||||
});
|
||||
}
|
||||
|
||||
var simplemde = new SimpleMDE({
|
||||
autosave: {
|
||||
enabled: true,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-options-Option.html generated 2018-07-07T08:09:49.967Z by adl.to-selmer-templates.
|
||||
<!-- File form-options-Option.html generated 2018-07-09T20:55:34.542Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -14,8 +14,9 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% if {{record.id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
|
@ -27,6 +28,21 @@ You are not permitted to view id of options
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='32' size='32'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of options
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-roles-Role.html generated 2018-07-07T08:09:49.937Z by adl.to-selmer-templates.
|
||||
<!-- File form-roles-Role.html generated 2018-07-09T20:55:34.522Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -10,28 +10,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-roles-Role' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of roles
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='name'>
|
||||
Name
|
||||
</label>
|
||||
{% if {{record.name}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
|
@ -45,11 +29,27 @@ You are not permitted to view name of roles
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='name' name='name' class='pseudo-widget disabled'>
|
||||
{{record.name}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='name' name='name' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view name of roles
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='members'>
|
||||
Members
|
||||
</label>
|
||||
{% if {{record.members}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='members_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + members_search_box.text, null, function (data) {updateMenuOptions("members", "", [""], data);})'/>
|
||||
|
@ -69,6 +69,27 @@ You are not permitted to view members of roles
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='members_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + members_search_box.text, null, function (data) {updateMenuOptions("members", "", [""], data);})'/>
|
||||
<br/>
|
||||
<select id='members' name='members' multiple='multiple'>
|
||||
{% for r in canvassers %}<option value='{{r.id}}' {% ifequal record.members r.id%}selected{% endifequal %}>{{r.username}} {{r.fullname}} {{r.address_id}} {{r.phone}} {{r.email}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='members' name='members' class='pseudo-widget disabled'>
|
||||
{{record.members}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='members' name='members' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view members of roles
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-teams-Team.html generated 2018-07-07T08:09:49.943Z by adl.to-selmer-templates.
|
||||
<!-- File form-teams-Team.html generated 2018-07-09T20:55:34.527Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -10,28 +10,12 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-teams-Team' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of teams
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
<input id='id' name='id' type='hidden' value='{{record.id}}'/>
|
||||
<p class='widget'>
|
||||
<label for='name'>
|
||||
Name
|
||||
</label>
|
||||
{% if {{record.name}} %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
|
@ -45,11 +29,27 @@ You are not permitted to view name of teams
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<span id='name' name='name' class='pseudo-widget disabled'>
|
||||
{{record.name}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='name' name='name' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view name of teams
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='district_id'>
|
||||
District_id
|
||||
</label>
|
||||
{% if {{record.district_id}} %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<span class='select-box' farside='districts' found='true'>
|
||||
<input name='district_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-districts?name=" + district_id_search_box.text, null, function (data) {updateMenuOptions("district_id", "id", ["name"], data);})'/>
|
||||
|
@ -69,11 +69,33 @@ You are not permitted to view district_id of teams
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<span class='select-box' farside='districts' found='true'>
|
||||
<input name='district_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-districts?name=" + district_id_search_box.text, null, function (data) {updateMenuOptions("district_id", "id", ["name"], data);})'/>
|
||||
<br/>
|
||||
<select id='district_id' name='district_id'>
|
||||
{% for r in districts %}<option value='{{r.id}}' {% ifequal record.district_id r.id%}selected{% endifequal %}>{{r.name}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<span id='district_id' name='district_id' class='pseudo-widget disabled'>
|
||||
{{record.district_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='district_id' name='district_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view district_id of teams
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='latitude'>
|
||||
Latitude
|
||||
</label>
|
||||
{% if {{record.latitude}} %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<input id='latitude' name='latitude' type='number' value='{{record.latitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -87,11 +109,27 @@ You are not permitted to view latitude of teams
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<input id='latitude' name='latitude' type='number' value='{{record.latitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<span id='latitude' name='latitude' class='pseudo-widget disabled'>
|
||||
{{record.latitude}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='latitude' name='latitude' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view latitude of teams
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='members'>
|
||||
Members
|
||||
</label>
|
||||
{% if {{record.members}} %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='members_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + members_search_box.text, null, function (data) {updateMenuOptions("members", "", [""], data);})'/>
|
||||
|
@ -111,11 +149,33 @@ You are not permitted to view members of teams
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='members_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + members_search_box.text, null, function (data) {updateMenuOptions("members", "", [""], data);})'/>
|
||||
<br/>
|
||||
<select id='members' name='members' multiple='multiple'>
|
||||
{% for r in canvassers %}<option value='{{r.id}}' {% ifequal record.members r.id%}selected{% endifequal %}>{{r.username}} {{r.fullname}} {{r.address_id}} {{r.phone}} {{r.email}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<span id='members' name='members' class='pseudo-widget disabled'>
|
||||
{{record.members}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='members' name='members' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view members of teams
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='organisers'>
|
||||
Organisers
|
||||
</label>
|
||||
{% if {{record.organisers}} %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='organisers_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + organisers_search_box.text, null, function (data) {updateMenuOptions("organisers", "", [""], data);})'/>
|
||||
|
@ -135,11 +195,33 @@ You are not permitted to view organisers of teams
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='organisers_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + organisers_search_box.text, null, function (data) {updateMenuOptions("organisers", "", [""], data);})'/>
|
||||
<br/>
|
||||
<select id='organisers' name='organisers' multiple='multiple'>
|
||||
{% for r in canvassers %}<option value='{{r.id}}' {% ifequal record.organisers r.id%}selected{% endifequal %}>{{r.username}} {{r.fullname}} {{r.address_id}} {{r.phone}} {{r.email}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<span id='organisers' name='organisers' class='pseudo-widget disabled'>
|
||||
{{record.organisers}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='organisers' name='organisers' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view organisers of teams
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='longitude'>
|
||||
Longitude
|
||||
</label>
|
||||
{% if {{record.longitude}} %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<input id='longitude' name='longitude' type='number' value='{{record.longitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -153,6 +235,21 @@ You are not permitted to view longitude of teams
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<input id='longitude' name='longitude' type='number' value='{{record.longitude}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
|
||||
<span id='longitude' name='longitude' class='pseudo-widget disabled'>
|
||||
{{record.longitude}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='longitude' name='longitude' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view longitude of teams
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-visits-Visit.html generated 2018-07-07T08:09:49.940Z by adl.to-selmer-templates.
|
||||
<!-- File form-visits-Visit.html generated 2018-07-09T20:55:34.524Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -14,8 +14,9 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
|||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% if {{record.id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
<input id='id' name='id' type='number' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
|
@ -27,11 +28,27 @@ You are not permitted to view id of visits
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='number' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of visits
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='address_id'>
|
||||
Address_id
|
||||
</label>
|
||||
{% if {{record.address_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='addresses' found='true'>
|
||||
<input name='address_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-addresses?postcode=" + address_id_search_box.text + "&address=" + address_id_search_box.text, null, function (data) {updateMenuOptions("address_id", "id", ["postcode", "address"], data);})'/>
|
||||
|
@ -51,11 +68,33 @@ You are not permitted to view address_id of visits
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='addresses' found='true'>
|
||||
<input name='address_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-addresses?postcode=" + address_id_search_box.text + "&address=" + address_id_search_box.text, null, function (data) {updateMenuOptions("address_id", "id", ["postcode", "address"], data);})'/>
|
||||
<br/>
|
||||
<select id='address_id' name='address_id'>
|
||||
{% for r in addresses %}<option value='{{r.id}}' {% ifequal record.address_id r.id%}selected{% endifequal %}>{{r.address}} {{r.postcode}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
|
||||
<span id='address_id' name='address_id' class='pseudo-widget disabled'>
|
||||
{{record.address_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='address_id' name='address_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view address_id of visits
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='canvasser_id'>
|
||||
Canvasser_id
|
||||
</label>
|
||||
{% if {{record.canvasser_id}} %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='canvasser_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + canvasser_id_search_box.text, null, function (data) {updateMenuOptions("canvasser_id", "", [""], data);})'/>
|
||||
|
@ -75,11 +114,33 @@ You are not permitted to view canvasser_id of visits
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<span class='select-box' farside='canvassers' found='true'>
|
||||
<input name='canvasser_id_search_box' onchange='$.getJSON("/auto/json/seach-strings-canvassers?=" + canvasser_id_search_box.text, null, function (data) {updateMenuOptions("canvasser_id", "", [""], data);})'/>
|
||||
<br/>
|
||||
<select id='canvasser_id' name='canvasser_id'>
|
||||
{% for r in canvassers %}<option value='{{r.id}}' {% ifequal record.canvasser_id r.id%}selected{% endifequal %}>{{r.username}} {{r.fullname}} {{r.address_id}} {{r.phone}} {{r.email}}</option>{% endfor %}
|
||||
</select>
|
||||
</span>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
|
||||
<span id='canvasser_id' name='canvasser_id' class='pseudo-widget disabled'>
|
||||
{{record.canvasser_id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='canvasser_id' name='canvasser_id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view canvasser_id of visits
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
<p class='widget'>
|
||||
<label for='date'>
|
||||
Date
|
||||
</label>
|
||||
{% if {{record.date}} %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='date' name='date' type='string' value='{{record.date}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
|
@ -93,6 +154,21 @@ You are not permitted to view date of visits
|
|||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% else %}
|
||||
{% ifmemberof admin %}
|
||||
<input id='date' name='date' type='string' value='{{record.date}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
|
||||
<span id='date' name='date' class='pseudo-widget disabled'>
|
||||
{{record.date}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='date' name='date' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view date of visits
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
{% endif %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-addresses-Addresses.html generated 2018-07-07T08:09:49.953Z by adl.to-selmer-templates.
|
||||
<!-- File list-addresses-Addresses.html generated 2018-07-09T20:55:34.533Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-addresses-Address' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-addresses-Address' class='big-link'>
|
||||
Add a new Address
|
||||
</a>
|
||||
</div>
|
||||
|
@ -112,7 +112,7 @@ Longitude
|
|||
{{ record.phone }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-districts-District?id={{ record.district_id }}'>
|
||||
<a href='{{servlet-context}}/form-districts-District?id={{ record.district_id }}'>
|
||||
{{ record.district_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -123,7 +123,7 @@ Longitude
|
|||
{{ record.longitude }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-addresses-Address?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-addresses-Address?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-authorities-Authorities.html generated 2018-07-07T08:09:49.924Z by adl.to-selmer-templates.
|
||||
<!-- File list-authorities-Authorities.html generated 2018-07-09T20:55:34.510Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-authorities-Authority' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-authorities-Authority' class='big-link'>
|
||||
Add a new Authority
|
||||
</a>
|
||||
</div>
|
||||
|
@ -94,7 +94,7 @@ Authorize-uri
|
|||
{{ record.authorize_uri }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-authorities-Authority?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-authorities-Authority?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-canvassers-Canvassers.html generated 2018-07-07T08:09:49.972Z by adl.to-selmer-templates.
|
||||
<!-- File list-canvassers-Canvassers.html generated 2018-07-09T20:55:34.545Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-canvassers-Canvasser' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-canvassers-Canvasser' class='big-link'>
|
||||
Add a new Canvasser
|
||||
</a>
|
||||
</div>
|
||||
|
@ -121,12 +121,12 @@ Authorised
|
|||
{{ record.fullname }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-electors-Elector?id={{ record.elector_id }}'>
|
||||
<a href='{{servlet-context}}/form-electors-Elector?id={{ record.elector_id }}'>
|
||||
{{ record.elector_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-addresses-Address?id={{ record.address_id }}'>
|
||||
<a href='{{servlet-context}}/form-addresses-Address?id={{ record.address_id }}'>
|
||||
{{ record.address_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -137,7 +137,7 @@ Authorised
|
|||
{{ record.email }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-authorities-Authority?id={{ record.authority_id }}'>
|
||||
<a href='{{servlet-context}}/form-authorities-Authority?id={{ record.authority_id }}'>
|
||||
{{ record.authority_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -145,7 +145,7 @@ Authorised
|
|||
{{ record.authorised }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-canvassers-Canvasser?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-canvassers-Canvasser?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-districts-Districts.html generated 2018-07-07T08:09:49.965Z by adl.to-selmer-templates.
|
||||
<!-- File list-districts-Districts.html generated 2018-07-09T20:55:34.538Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-districts-District' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-districts-District' class='big-link'>
|
||||
Add a new District
|
||||
</a>
|
||||
</div>
|
||||
|
@ -76,7 +76,7 @@ Name
|
|||
{{ record.name }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-districts-District?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-districts-District?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-dwellings-Dwellings.html generated 2018-07-07T08:09:49.950Z by adl.to-selmer-templates.
|
||||
<!-- File list-dwellings-Dwellings.html generated 2018-07-09T20:55:34.531Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-dwellings-Dwelling' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-dwellings-Dwelling' class='big-link'>
|
||||
Add a new Dwelling
|
||||
</a>
|
||||
</div>
|
||||
|
@ -79,7 +79,7 @@ Sub-address
|
|||
{{ record.id }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-addresses-Address?id={{ record.address_id }}'>
|
||||
<a href='{{servlet-context}}/form-addresses-Address?id={{ record.address_id }}'>
|
||||
{{ record.address_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -87,7 +87,7 @@ Sub-address
|
|||
{{ record.sub_address }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-dwellings-Dwelling?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-dwellings-Dwelling?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-electors-Electors.html generated 2018-07-07T08:09:49.934Z by adl.to-selmer-templates.
|
||||
<!-- File list-electors-Electors.html generated 2018-07-09T20:55:34.519Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-electors-Elector' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-electors-Elector' class='big-link'>
|
||||
Add a new Elector
|
||||
</a>
|
||||
</div>
|
||||
|
@ -100,7 +100,7 @@ Gender
|
|||
{{ record.name }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-dwellings-Dwelling?id={{ record.dwelling_id }}'>
|
||||
<a href='{{servlet-context}}/form-dwellings-Dwelling?id={{ record.dwelling_id }}'>
|
||||
{{ record.dwelling_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -111,12 +111,12 @@ Gender
|
|||
{{ record.email }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-genders-Gender?id={{ record.gender }}'>
|
||||
<a href='{{servlet-context}}/form-genders-Gender?id={{ record.gender }}'>
|
||||
{{ record.gender_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-electors-Elector?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-electors-Elector?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-events-Events.html generated 2018-07-07T08:09:49.965Z by adl.to-selmer-templates.
|
||||
<!-- File list-events-Events.html generated 2018-07-09T20:55:34.539Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof teamorganisers admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-events-Events' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-events-Events' class='big-link'>
|
||||
Add a new Event
|
||||
</a>
|
||||
</div>
|
||||
|
@ -112,7 +112,7 @@ Cancelled
|
|||
{{ record.cancelled }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-events-Events?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-events-Events?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-followupactions-Followupactions.html generated 2018-07-07T08:09:49.971Z by adl.to-selmer-templates.
|
||||
<!-- File list-followupactions-Followupactions.html generated 2018-07-09T20:55:34.544Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-followupactions-Followupaction' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-followupactions-Followupaction' class='big-link'>
|
||||
Add a new Followupaction
|
||||
</a>
|
||||
</div>
|
||||
|
@ -97,12 +97,12 @@ Closed
|
|||
{{ record.id }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-followuprequests-Followuprequest?id={{ record.request_id }}'>
|
||||
<a href='{{servlet-context}}/form-followuprequests-Followuprequest?id={{ record.request_id }}'>
|
||||
{{ record.request_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-canvassers-Canvasser?id={{ record.actor }}'>
|
||||
<a href='{{servlet-context}}/form-canvassers-Canvasser?id={{ record.actor }}'>
|
||||
{{ record.actor_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -116,7 +116,7 @@ Closed
|
|||
{{ record.closed }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-followupactions-Followupaction?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-followupactions-Followupaction?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-followupmethods-Followupmethods.html generated 2018-07-07T08:09:49.939Z by adl.to-selmer-templates.
|
||||
<!-- File list-followupmethods-Followupmethods.html generated 2018-07-09T20:55:34.524Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-followupmethods-Followupmethod' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-followupmethods-Followupmethod' class='big-link'>
|
||||
Add a new Followupmethod
|
||||
</a>
|
||||
</div>
|
||||
|
@ -67,7 +67,7 @@ Id
|
|||
{{ record.id }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-followupmethods-Followupmethod?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-followupmethods-Followupmethod?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-followuprequests-Followuprequests.html generated 2018-07-07T08:09:49.920Z by adl.to-selmer-templates.
|
||||
<!-- File list-followuprequests-Followuprequests.html generated 2018-07-09T20:55:34.506Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-followuprequests-Followuprequest' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-followuprequests-Followuprequest' class='big-link'>
|
||||
Add a new Followuprequest
|
||||
</a>
|
||||
</div>
|
||||
|
@ -91,27 +91,27 @@ Method_id
|
|||
{{ record.id }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-electors-Elector?id={{ record.elector_id }}'>
|
||||
<a href='{{servlet-context}}/form-electors-Elector?id={{ record.elector_id }}'>
|
||||
{{ record.elector_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-visits-Visit?id={{ record.visit_id }}'>
|
||||
<a href='{{servlet-context}}/form-visits-Visit?id={{ record.visit_id }}'>
|
||||
{{ record.visit_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-issues-Issue?id={{ record.issue_id }}'>
|
||||
<a href='{{servlet-context}}/form-issues-Issue?id={{ record.issue_id }}'>
|
||||
{{ record.issue_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-followupmethods-Followupmethod?id={{ record.method_id }}'>
|
||||
<a href='{{servlet-context}}/form-followupmethods-Followupmethod?id={{ record.method_id }}'>
|
||||
{{ record.method_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-followuprequests-Followuprequest?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-followuprequests-Followuprequest?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-genders-Genders.html generated 2018-07-07T08:09:49.914Z by adl.to-selmer-templates.
|
||||
<!-- File list-genders-Genders.html generated 2018-07-09T20:55:34.500Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-genders-Gender' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-genders-Gender' class='big-link'>
|
||||
Add a new Gender
|
||||
</a>
|
||||
</div>
|
||||
|
@ -67,7 +67,7 @@ Id
|
|||
{{ record.id }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-genders-Gender?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-genders-Gender?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-intentions-Intentions.html generated 2018-07-07T08:09:49.975Z by adl.to-selmer-templates.
|
||||
<!-- File list-intentions-Intentions.html generated 2018-07-09T20:55:34.548Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-intentions-Intention' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-intentions-Intention' class='big-link'>
|
||||
Add a new Intention
|
||||
</a>
|
||||
</div>
|
||||
|
@ -82,17 +82,17 @@ Locality
|
|||
{% for record in records %}
|
||||
<tr>
|
||||
<td>
|
||||
<a href='form-visits-Visit?id={{ record.visit_id }}'>
|
||||
<a href='{{servlet-context}}/form-visits-Visit?id={{ record.visit_id }}'>
|
||||
{{ record.visit_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-electors-Elector?id={{ record.elector_id }}'>
|
||||
<a href='{{servlet-context}}/form-electors-Elector?id={{ record.elector_id }}'>
|
||||
{{ record.elector_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-options-Option?id={{ record.option_id }}'>
|
||||
<a href='{{servlet-context}}/form-options-Option?id={{ record.option_id }}'>
|
||||
{{ record.option_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -100,7 +100,7 @@ Locality
|
|||
{{ record.locality }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-intentions-Intention?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-intentions-Intention?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-issues-Issues.html generated 2018-07-07T08:09:49.966Z by adl.to-selmer-templates.
|
||||
<!-- File list-issues-Issues.html generated 2018-07-09T20:55:34.541Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof issueeditors admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-issues-Issue' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-issues-Issue' class='big-link'>
|
||||
Add a new Issue
|
||||
</a>
|
||||
</div>
|
||||
|
@ -94,7 +94,7 @@ Brief
|
|||
{{ record.brief }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-issues-Issue?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-issues-Issue?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-options-Options.html generated 2018-07-07T08:09:49.921Z by adl.to-selmer-templates.
|
||||
<!-- File list-options-Options.html generated 2018-07-09T20:55:34.507Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-options-Option' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-options-Option' class='big-link'>
|
||||
Add a new Option
|
||||
</a>
|
||||
</div>
|
||||
|
@ -67,7 +67,7 @@ Id
|
|||
{{ record.id }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-options-Option?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-options-Option?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-roles-Roles.html generated 2018-07-07T08:09:49.939Z by adl.to-selmer-templates.
|
||||
<!-- File list-roles-Roles.html generated 2018-07-09T20:55:34.523Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-roles-Role' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-roles-Role' class='big-link'>
|
||||
Add a new Role
|
||||
</a>
|
||||
</div>
|
||||
|
@ -76,7 +76,7 @@ Name
|
|||
{{ record.name }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-roles-Role?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-roles-Role?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-teams-Teams.html generated 2018-07-07T08:09:49.917Z by adl.to-selmer-templates.
|
||||
<!-- File list-teams-Teams.html generated 2018-07-09T20:55:34.504Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof teamorganisers admin teamorganisers admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-teams-Team' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-teams-Team' class='big-link'>
|
||||
Add a new Team
|
||||
</a>
|
||||
</div>
|
||||
|
@ -94,7 +94,7 @@ Longitude
|
|||
{{ record.name }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-districts-District?id={{ record.district_id }}'>
|
||||
<a href='{{servlet-context}}/form-districts-District?id={{ record.district_id }}'>
|
||||
{{ record.district_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -105,7 +105,7 @@ Longitude
|
|||
{{ record.longitude }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-teams-Team?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-teams-Team?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File list-visits-Visits.html generated 2018-07-07T08:09:49.916Z by adl.to-selmer-templates.
|
||||
<!-- File list-visits-Visits.html generated 2018-07-09T20:55:34.502Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ Next
|
|||
</div>
|
||||
{% ifmemberof admin %}
|
||||
<div class='big-link-container'>
|
||||
<a href='form-visits-Visit' class='big-link'>
|
||||
<a href='{{servlet-context}}/form-visits-Visit' class='big-link'>
|
||||
Add a new Visit
|
||||
</a>
|
||||
</div>
|
||||
|
@ -85,12 +85,12 @@ Date
|
|||
{{ record.id }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-addresses-Address?id={{ record.address_id }}'>
|
||||
<a href='{{servlet-context}}/form-addresses-Address?id={{ record.address_id }}'>
|
||||
{{ record.address_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-canvassers-Canvasser?id={{ record.canvasser_id }}'>
|
||||
<a href='{{servlet-context}}/form-canvassers-Canvasser?id={{ record.canvasser_id }}'>
|
||||
{{ record.canvasser_id_expanded }}
|
||||
</a>
|
||||
</td>
|
||||
|
@ -98,7 +98,7 @@ Date
|
|||
{{ record.date }}
|
||||
</td>
|
||||
<td>
|
||||
<a href='form-visits-Visit?id={{ record.id }}'>
|
||||
<a href='{{servlet-context}}/form-visits-Visit?id={{ record.id }}'>
|
||||
View
|
||||
</a>
|
||||
</td>
|
||||
|
|
|
@ -23,20 +23,19 @@
|
|||
{% block top %}
|
||||
<header>
|
||||
<div id="nav">
|
||||
<img id="nav-icon" src="img/threelines.png" alt="Menu"/>
|
||||
<img id="nav-icon" src="{{servlet-context}}/img/threelines.png" alt="Menu"/>
|
||||
<menu id="nav-menu" class="nav">
|
||||
<li class=""><a href="home">Home</a></li>
|
||||
<li class=""><a href="library">Library</a></li>
|
||||
<li class=""><a href="register">Register</a></li>
|
||||
<li class="">{% if user %}<a href="logout">Logout</a>
|
||||
{% else %}<a href="login">Login</a>{% endif %}</li>
|
||||
<li class=""><a href="about">About</a></li>
|
||||
<li class=""><a href="{{servlet-context}}/home">Home</a></li>
|
||||
<li class=""><a href="{{servlet-context}}/library">Library</a></li>
|
||||
<li class=""><a href="{{servlet-context}}/register">Register</a></li>
|
||||
<li class="">{% if user %}<a href="{{servlet-context}}/logout">Logout</a>
|
||||
{% else %}<a href="{{servlet-context}}/login">Login</a>{% endif %}</li>
|
||||
<li class=""><a href="{{servlet-context}}/about">About</a></li>
|
||||
{% if user %}
|
||||
<li id="user"><a href="profile">Logged in as {{user.username}}</a></li>
|
||||
<li id="user"><a href="{{servlet-context}}/profile">Logged in as {{user.username}}</a></li>
|
||||
{% endif %}
|
||||
</menu>
|
||||
</div>
|
||||
<!-- img id="site-logo" src="{{site-logo}}" alt="{{site-title}}" width="64" height="64"/ -->
|
||||
<h1>{{title}}</h1>
|
||||
{% if message|not-empty %}
|
||||
<div class="message">
|
||||
|
@ -71,16 +70,16 @@
|
|||
<footer>
|
||||
<div id="credits">
|
||||
<div>
|
||||
<img src="img/credits/ric-logo.png" width="24" height="24"/>
|
||||
<img src="{{servlet-context}}/img/credits/ric-logo.png" width="24" height="24"/>
|
||||
A project of the
|
||||
<a href="https://radical.scot/">Radical Independence Campaign</a> ||
|
||||
Version {{version}}
|
||||
</div>
|
||||
<div>
|
||||
<img height="16" width="16" alt="Clojure" src="img/credits/luminus-logo.png"/>Built with <a href="http://www.luminusweb.net/">LuminusWeb</a> ||
|
||||
<img height="16" width="16" alt="Clojure" src="img/credits/clojure-icon.gif"/> Powered by <a href="http://clojure.org">Clojure</a> ||
|
||||
<img height="16" width="16" alt="GitHub" src="img/credits/github-logo-transparent.png"/>Find me/fork me on <a href="https://github.com/simon-brooke/smeagol">Github</a> ||
|
||||
<img height="16" width="16" alt="Free Software Foundation" src="img/credits/gnu.small.png"/>Licensed under the <a href="http://www.gnu.org/licenses/gpl-2.0.html">GNU General Public License version 2.0</a>
|
||||
<img height="16" width="16" alt="Clojure" src="{{servlet-context}}/img/credits/luminus-logo.png"/>Built with <a href="http://www.luminusweb.net/">LuminusWeb</a> ||
|
||||
<img height="16" width="16" alt="Clojure" src="{{servlet-context}}/img/credits/clojure-icon.gif"/> Powered by <a href="http://clojure.org">Clojure</a> ||
|
||||
<img height="16" width="16" alt="GitHub" src="{{servlet-context}}/img/credits/github-logo-transparent.png"/>Find me/fork me on <a href="https://github.com/simon-brooke/smeagol">Github</a> ||
|
||||
<img height="16" width="16" alt="Free Software Foundation" src="{{servlet-context}}/img/credits/gnu.small.png"/>Licensed under the <a href="http://www.gnu.org/licenses/gpl-2.0.html">GNU General Public License version 2.0</a>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
|
|
0
resources/templates/issue-expert/list.html
Normal file
0
resources/templates/issue-expert/list.html
Normal file
55
resources/templates/issue-expert/request.html
Normal file
55
resources/templates/issue-expert/request.html
Normal file
|
@ -0,0 +1,55 @@
|
|||
{% extends "base.html" %}
|
||||
<!-- File form-followupmethods-Followupmethod.html generated 2018-07-09T16:38:56.477Z by adl.to-selmer-templates.
|
||||
See [Application Description Language](https://github.com/simon-brooke/adl).-->
|
||||
|
||||
|
||||
{% block extra-head %}
|
||||
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
<div id='content' class='edit'>
|
||||
<form action='{{servlet-context}}/form-followupmethods-Followupmethod' method='POST'>
|
||||
{% csrf-field %}
|
||||
<p class='widget'>
|
||||
<label for='id'>
|
||||
Id
|
||||
</label>
|
||||
{% ifmemberof admin %}
|
||||
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
|
||||
{% else %}
|
||||
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
|
||||
<span id='id' name='id' class='pseudo-widget disabled'>
|
||||
{{record.id}}
|
||||
</span>
|
||||
{% else %}
|
||||
<span id='id' name='id' class='pseudo-widget not-authorised'>
|
||||
You are not permitted to view id of followupmethods
|
||||
</span>
|
||||
{% endifmemberof %}
|
||||
{% endifmemberof %}
|
||||
</p>
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-safe'>
|
||||
<label for='save-button' class='action-safe'>
|
||||
To save this followupmethods record
|
||||
</label>
|
||||
<input id='save-button' name='save-button' class='action-safe' type='submit' value='Save!'/>
|
||||
</p>
|
||||
{% endifmemberof %}
|
||||
{% ifmemberof admin %}
|
||||
<p class='widget action-dangerous'>
|
||||
<label for='delete-button' class='action-dangerous'>
|
||||
To delete this followupmethods record
|
||||
</label>
|
||||
<input id='delete-button' name='delete-button' class='action-dangerous' type='submit' value='Delete!'/>
|
||||
</p>
|
||||
{% endifmemberof %}
|
||||
</form>
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
||||
{% block extra-tail %}
|
||||
<script type='text/javascript'>
|
||||
</script>
|
||||
|
||||
{% endblock %}
|
9
resources/templates/roles/canvasser.html
Normal file
9
resources/templates/roles/canvasser.html
Normal file
|
@ -0,0 +1,9 @@
|
|||
{% extends "base.html" %}
|
||||
{% block big-links %}
|
||||
<div class="big-link-container">
|
||||
<a href="{{servlet-context}}/profile" class="big-link" id="profile-link">Your profile</a>
|
||||
</div>
|
||||
<div class="big-link-container">
|
||||
<a href="{{servlet-context}}/app" class="big-link" id="app-link">App</a>
|
||||
</div>
|
||||
{% endblock %}
|
0
resources/templates/untitled.html
Normal file
0
resources/templates/untitled.html
Normal file
|
@ -10,10 +10,11 @@
|
|||
[youyesyet.layout :refer [error-page]]
|
||||
[youyesyet.middleware :as middleware]
|
||||
[youyesyet.routes.home :refer [home-routes]]
|
||||
[youyesyet.routes.oauth :refer [oauth-routes]]
|
||||
[youyesyet.routes.auto-json :refer [auto-rest-routes]]
|
||||
[youyesyet.routes.auto :refer [auto-selmer-routes]]
|
||||
[youyesyet.routes.auto-json :refer [auto-rest-routes]]
|
||||
[youyesyet.routes.issue-experts :refer [issue-expert-routes]]
|
||||
[youyesyet.routes.rest :refer [rest-routes]]
|
||||
[youyesyet.routes.oauth :refer [oauth-routes]]
|
||||
[youyesyet.routes.roles :refer [roles-routes]]
|
||||
[youyesyet.routes.services :refer [service-routes]]
|
||||
[youyesyet.env :refer [defaults]]))
|
||||
|
@ -72,6 +73,9 @@
|
|||
(-> #'roles-routes
|
||||
(wrap-routes middleware/wrap-csrf)
|
||||
(wrap-routes middleware/wrap-formats))
|
||||
(-> #'issue-expert-routes
|
||||
(wrap-routes middleware/wrap-csrf)
|
||||
(wrap-routes middleware/wrap-formats))
|
||||
(-> #'auto-rest-routes
|
||||
(wrap-routes middleware/wrap-csrf)
|
||||
(wrap-routes middleware/wrap-formats))
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
(ns
|
||||
youyesyet.routes.auto
|
||||
"User interface routes for Youyesyet auto-generated by [Application Description Language framework](https://github.com/simon-brooke/adl) at 20180707T080949.557Z"
|
||||
"User interface routes for Youyesyet auto-generated by [Application Description Language framework](https://github.com/simon-brooke/adl) at 20180709T205534.030Z"
|
||||
(:require
|
||||
[adl-support.core :as support]
|
||||
[clojure.java.io :as io]
|
||||
|
@ -176,7 +176,8 @@
|
|||
{:electors (db/list-electors db/*db*)}
|
||||
{:addresses (db/list-addresses db/*db*)}
|
||||
{:authorities (db/list-authorities db/*db*)}
|
||||
{:roles (db/list-roles db/*db*)}))))))
|
||||
{:roles (db/list-roles db/*db*)}
|
||||
{:issues (db/list-issues db/*db*)}))))))
|
||||
|
||||
(defn
|
||||
list-districts-Districts
|
||||
|
@ -689,7 +690,7 @@
|
|||
(empty? (remove nil? (vals p)))
|
||||
[]
|
||||
(db/get-issue db/*db* p))})
|
||||
(list))))))
|
||||
(list {:canvassers (db/list-canvassers db/*db*)}))))))
|
||||
|
||||
(defn
|
||||
list-options-Options
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
(ns
|
||||
youyesyet.routes.auto-json
|
||||
"JSON routes for youyesyet auto-generated by [Application Description Language framework](https://github.com/simon-brooke/adl) at 20180707T080948.404Z"
|
||||
"JSON routes for youyesyet auto-generated by [Application Description Language framework](https://github.com/simon-brooke/adl) at 20180709T205532.861Z"
|
||||
(:require
|
||||
[adl-support.core :as support]
|
||||
[clojure.core.memoize :as memo]
|
||||
|
@ -675,6 +675,11 @@
|
|||
[{:keys [params]}]
|
||||
(do (db/list-canvassers-by-elector params)))
|
||||
|
||||
(defn
|
||||
list-canvassers-by-issue
|
||||
[{:keys [params]}]
|
||||
(do (db/list-canvassers-by-issue params)))
|
||||
|
||||
(defn
|
||||
list-canvassers-by-role
|
||||
[{:keys [params]}]
|
||||
|
@ -879,6 +884,11 @@
|
|||
:ttl/threshold
|
||||
1000000))
|
||||
|
||||
(defn
|
||||
list-issues-by-canvasser
|
||||
[{:keys [params]}]
|
||||
(do (db/list-issues-by-canvasser params)))
|
||||
|
||||
(def
|
||||
list-options
|
||||
(memo/ttl
|
||||
|
@ -1587,6 +1597,10 @@
|
|||
"/json/auto/list-canvassers-by-elector"
|
||||
request
|
||||
(route/restricted (list-canvassers-by-elector request)))
|
||||
(GET
|
||||
"/json/auto/list-canvassers-by-issue"
|
||||
request
|
||||
(route/restricted (list-canvassers-by-issue request)))
|
||||
(GET
|
||||
"/json/auto/list-canvassers-by-role"
|
||||
request
|
||||
|
@ -1683,6 +1697,10 @@
|
|||
"/json/auto/list-issues"
|
||||
request
|
||||
(route/restricted (list-issues request)))
|
||||
(GET
|
||||
"/json/auto/list-issues-by-canvasser"
|
||||
request
|
||||
(route/restricted (list-issues-by-canvasser request)))
|
||||
(GET
|
||||
"/json/auto/list-options"
|
||||
request
|
||||
|
|
68
src/clj/youyesyet/routes/issue_experts.clj
Normal file
68
src/clj/youyesyet/routes/issue_experts.clj
Normal file
|
@ -0,0 +1,68 @@
|
|||
(ns ^{:doc "Routes/pages available to issue experts."
|
||||
:author "Simon Brooke"} youyesyet.routes.issue-experts
|
||||
(:require [adl-support.utils :refer [safe-name]]
|
||||
[clojure.java.io :as io]
|
||||
[clojure.string :as s]
|
||||
[clojure.tools.logging :as log]
|
||||
[clojure.walk :refer [keywordize-keys]]
|
||||
[markdown.core :refer [md-to-html-string]]
|
||||
[noir.util.route :as route]
|
||||
[ring.util.http-response :as response]
|
||||
[youyesyet.config :refer [env]]
|
||||
[youyesyet.db.core :as db]
|
||||
[youyesyet.layout :as layout]
|
||||
[youyesyet.oauth :as oauth]
|
||||
[compojure.core :refer [defroutes GET POST]]
|
||||
))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;;;;
|
||||
;;;; youyesyet.routes.home: routes and pages for issue experts.
|
||||
;;;;
|
||||
;;;; This program is free software; you can redistribute it and/or
|
||||
;;;; modify it under the terms of the GNU General Public License
|
||||
;;;; as published by the Free Software Foundation; either version 2
|
||||
;;;; of the License, or (at your option) any later version.
|
||||
;;;;
|
||||
;;;; This program is distributed in the hope that it will be useful,
|
||||
;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;;;; GNU General Public License for more details.
|
||||
;;;;
|
||||
;;;; You should have received a copy of the GNU General Public License
|
||||
;;;; along with this program; if not, write to the Free Software
|
||||
;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
|
||||
;;;; USA.
|
||||
;;;;
|
||||
;;;; Copyright (C) 2016 Simon Brooke for Radical Independence Campaign
|
||||
;;;;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
(defn list-page [request]
|
||||
(layout/render
|
||||
"auto/list-followuprequests-Followuprequests.html"
|
||||
(:session request)
|
||||
(let [user (:user (:session request))]
|
||||
{:title "Open requests"
|
||||
:user user
|
||||
:records (db/list-open-requests db/*db* {:expert (:id user)})})))
|
||||
|
||||
|
||||
(defn followup-request-page [request]
|
||||
(layout/render
|
||||
"issue-expert/request.html"
|
||||
(:session request)
|
||||
{:title "Open requests"
|
||||
:user (:user (:session request))
|
||||
:request (db/get-followuprequest
|
||||
db/*db*
|
||||
{:id (:id (keywordize-keys (:params request)))})}))
|
||||
|
||||
|
||||
(defroutes issue-expert-routes
|
||||
(GET "/issue-expert/list" request
|
||||
(route/restricted (list-page request)))
|
||||
(GET "/issue-expert/followup-request" request
|
||||
(route/restricted (followup-request-page request)))
|
||||
(POST "/issue-expert/followup-request" request
|
||||
(route/restricted (followup-request-page request))))
|
|
@ -1,6 +1,7 @@
|
|||
(ns ^{:doc "Routes/pages available to authenticated users in specific roles."
|
||||
:author "Simon Brooke"} youyesyet.routes.roles
|
||||
(:require [adl-support.utils :refer [safe-name]]
|
||||
(:require [adl-support.core :as support]
|
||||
[adl-support.utils :refer [safe-name]]
|
||||
[clojure.tools.logging :as log]
|
||||
[clojure.walk :refer [keywordize-keys]]
|
||||
[compojure.core :refer [defroutes GET POST]]
|
||||
|
@ -8,6 +9,7 @@
|
|||
[ring.util.http-response :as response]
|
||||
[youyesyet.config :refer [env]]
|
||||
[youyesyet.db.core :as db-core]
|
||||
[youyesyet.routes.issue-experts :as expert]
|
||||
[youyesyet.layout :as layout]
|
||||
[youyesyet.oauth :as oauth]
|
||||
[youyesyet.routes.auto :as auto]))
|
||||
|
@ -34,7 +36,10 @@
|
|||
|
||||
(defn admins-page
|
||||
[request]
|
||||
(response/found "/admin"))
|
||||
(layout/render
|
||||
(support/resolve-template "application-index.html")
|
||||
(:session request)
|
||||
{:title "Administrative menu"}))
|
||||
|
||||
|
||||
(defn analysts-page
|
||||
|
@ -42,7 +47,10 @@
|
|||
some other geographical information system; so there isn't a need to put
|
||||
anything sophisticated here."
|
||||
[request]
|
||||
(response/found "/admin"))
|
||||
(layout/render
|
||||
(support/resolve-template "application-index.html")
|
||||
(:session request)
|
||||
{:title "Administrative menu"}))
|
||||
|
||||
|
||||
(defn canvassers-page
|
||||
|
@ -50,22 +58,17 @@
|
|||
(layout/render "roles/canvasser.html" request {}))
|
||||
|
||||
|
||||
(defn issue-experts-page
|
||||
[request]
|
||||
(layout/render "roles/issue-experts.html" request {}))
|
||||
|
||||
|
||||
(defn team-organisers-page
|
||||
[request]
|
||||
(layout/render "roles/team-orgenisers.html" request {}))
|
||||
|
||||
|
||||
(defroutes roles-routes
|
||||
(GET "/roles/admins" [request] (route/restricted (admins-page request)))
|
||||
(GET "/roles/analysts" [request] (route/restricted (analysts-page request)))
|
||||
(GET "/roles/canvassers" [request] (route/restricted (canvassers-page request)))
|
||||
(GET "/roles/issue_editors" [request] (route/restricted (auto/list-issues-Issues request)))
|
||||
(GET "/roles/issue_experts" [request] (route/restricted (issue-experts-page request)))
|
||||
(GET "/roles/team_organisers" [request] (route/restricted (auto/list-teams-Teams request)))
|
||||
(GET "/roles/admin" request (route/restricted (admins-page request)))
|
||||
(GET "/roles/analysts" request (route/restricted (analysts-page request)))
|
||||
(GET "/roles/canvassers" request (route/restricted (canvassers-page request)))
|
||||
(GET "/roles/issue_editors" request (route/restricted (auto/list-issues-Issues request)))
|
||||
(GET "/roles/issue_experts" request (route/restricted (expert/list-page request)))
|
||||
(GET "/roles/team_organisers" request (route/restricted (auto/list-teams-Teams request)))
|
||||
(GET "/roles" request (route/restricted (roles-page request))))
|
||||
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
[re-frame.core :as rf]
|
||||
[secretary.core :as secretary]
|
||||
[youyesyet.canvasser-app.ajax :refer [load-interceptors!]]
|
||||
[youyesyet.canvasser-app.gis :refer [get-current-location]]
|
||||
[youyesyet.canvasser-app.handlers :as h]
|
||||
[youyesyet.canvasser-app.subscriptions]
|
||||
[youyesyet.canvasser-app.ui-utils :as ui]
|
||||
|
@ -74,14 +75,18 @@
|
|||
(defn issue-page []
|
||||
(issue/panel))
|
||||
|
||||
(defn issue-experts-page []
|
||||
(expert/panel))
|
||||
|
||||
(defn map-page []
|
||||
(maps/panel))
|
||||
|
||||
(def pages
|
||||
{:about #'about-page
|
||||
:building #'building-page
|
||||
:elector #'elector-page
|
||||
:dwelling #'dwelling-page
|
||||
:elector #'elector-page
|
||||
:expert #'expert
|
||||
:followup #'followup-page
|
||||
:gdpr #'gdpr-page
|
||||
:issues #'issues-page
|
||||
|
@ -191,7 +196,7 @@
|
|||
|
||||
(defn init! []
|
||||
(rf/dispatch-sync [:initialize-db])
|
||||
(h/get-current-location)
|
||||
(get-current-location)
|
||||
(rf/dispatch [:fetch-locality])
|
||||
(rf/dispatch [:fetch-options])
|
||||
(rf/dispatch [:fetch-issues])
|
||||
|
|
139
src/cljs/youyesyet/canvasser_app/gis.cljs
Normal file
139
src/cljs/youyesyet/canvasser_app/gis.cljs
Normal file
|
@ -0,0 +1,139 @@
|
|||
(ns ^{:doc "Canvasser app map stuff."
|
||||
:author "Simon Brooke"}
|
||||
youyesyet.canvasser-app.gis
|
||||
(:require [cljs.reader :refer [read-string]]
|
||||
[cemerick.url :refer (url url-encode)]
|
||||
[day8.re-frame.http-fx]
|
||||
[re-frame.core :refer [dispatch reg-event-db reg-event-fx subscribe]]
|
||||
[ajax.core :refer [GET]]
|
||||
[ajax.json :refer [json-request-format json-response-format]]
|
||||
[youyesyet.canvasser-app.state :as db]
|
||||
))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;;;;
|
||||
;;;; youyesyet.canvasser-app.gis: stuff to do with maps.
|
||||
;;;;
|
||||
;;;; This program is free software; you can redistribute it and/or
|
||||
;;;; modify it under the terms of the GNU General Public License
|
||||
;;;; as published by the Free Software Foundation; either version 2
|
||||
;;;; of the License, or (at your option) any later version.
|
||||
;;;;
|
||||
;;;; This program is distributed in the hope that it will be useful,
|
||||
;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;;;; GNU General Public License for more details.
|
||||
;;;;
|
||||
;;;; You should have received a copy of the GNU General Public License
|
||||
;;;; along with this program; if not, write to the Free Software
|
||||
;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
|
||||
;;;; USA.
|
||||
;;;;
|
||||
;;;; Copyright (C) 2016 Simon Brooke for Radical Independence Campaign
|
||||
;;;;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
;; map stuff. If we do this in canvasser-app.views.map we get circular
|
||||
;; references, so do it here.
|
||||
|
||||
(defn get-current-location []
|
||||
"Get the current location from the device."
|
||||
(try
|
||||
(if (.-geolocation js/navigator)
|
||||
(.getCurrentPosition
|
||||
(.-geolocation js/navigator)
|
||||
(fn [position]
|
||||
(js/console.log (str "Current location is: "
|
||||
(.-latitude (.-coords position)) ", "
|
||||
(.-longitude (.-coords position))))
|
||||
(dispatch [:set-latitude (.-latitude (.-coords position))])
|
||||
(dispatch [:set-longitude (.-longitude (.-coords position))])))
|
||||
(js/console.log "Geolocation not available"))
|
||||
(catch js/Object any
|
||||
(js/console.log "Exception while trying to access location: " + any))))
|
||||
|
||||
|
||||
(defn pin-image
|
||||
"select the name of a suitable pin image for this address"
|
||||
[address]
|
||||
(let [intentions
|
||||
(set
|
||||
(remove
|
||||
nil?
|
||||
(map
|
||||
:intention
|
||||
(mapcat :electors
|
||||
(:dwellings address)))))]
|
||||
(case (count intentions)
|
||||
0 "unknown-pin"
|
||||
1 (str (name (first intentions)) "-pin")
|
||||
"mixed-pin")))
|
||||
|
||||
|
||||
(defn map-pin-click-handler
|
||||
"On clicking on the pin, navigate to the electors at the address.
|
||||
This way of doing it adds an antry in the browser location history,
|
||||
so back links work."
|
||||
[id]
|
||||
(js/console.log (str "Click handler for address #" id))
|
||||
(let [view @(subscribe [:view])
|
||||
centre (.getCenter view)]
|
||||
(dispatch [:set-zoom (.getZoom view)])
|
||||
(dispatch [:set-latitude (.-lat centre)])
|
||||
(dispatch [:set-longitude (.-lng centre)]))
|
||||
(set! window.location.href (str "#building/" id)))
|
||||
|
||||
|
||||
(defn add-map-pin
|
||||
"Add a map-pin at this address in this map view"
|
||||
[address view]
|
||||
(let [lat (:latitude address)
|
||||
lng (:longitude address)
|
||||
pin (.icon js/L
|
||||
(clj->js
|
||||
{:iconAnchor [16 41]
|
||||
:iconSize [32 42]
|
||||
:iconUrl (str "img/map-pins/" (pin-image address) ".png")
|
||||
:riseOnHover true
|
||||
:shadowAnchor [16 23]
|
||||
:shadowSize [57 24]
|
||||
:shadowUrl "img/map-pins/shadow_pin.png"}))
|
||||
marker (.marker js/L
|
||||
(.latLng js/L lat lng)
|
||||
(clj->js {:icon pin
|
||||
:title (:address address)}))]
|
||||
(.on (.addTo marker view) "click" (fn [_] (map-pin-click-handler (str (:id address)))))
|
||||
marker))
|
||||
|
||||
|
||||
(defn map-remove-pins
|
||||
"Remove all pins from this map `view`. Side-effecty; liable to be problematic."
|
||||
[view]
|
||||
|
||||
(if
|
||||
view
|
||||
(.eachLayer
|
||||
view
|
||||
(fn [layer]
|
||||
(try
|
||||
(if
|
||||
(instance? js/L.Marker layer)
|
||||
(.removeLayer view layer))
|
||||
(catch js/Object any (js/console.log (str "Failed to remove pin '" layer "' from map: " any)))))))
|
||||
view)
|
||||
|
||||
|
||||
(defn refresh-map-pins
|
||||
"Refresh the map pins on this map. Side-effecty; liable to be problematic."
|
||||
[]
|
||||
(let [view (map-remove-pins @(subscribe [:view]))
|
||||
addresses @(subscribe [:addresses])]
|
||||
(if
|
||||
view
|
||||
(do
|
||||
(js/console.log (str "Adding " (count addresses) " pins"))
|
||||
(doall (map #(add-map-pin % view) addresses)))
|
||||
(js/console.log "View is not yet ready"))
|
||||
view))
|
||||
|
||||
|
|
@ -7,12 +7,13 @@
|
|||
[re-frame.core :refer [dispatch reg-event-db reg-event-fx subscribe]]
|
||||
[ajax.core :refer [GET]]
|
||||
[ajax.json :refer [json-request-format json-response-format]]
|
||||
[youyesyet.canvasser-app.gis :refer [refresh-map-pins get-current-location]]
|
||||
[youyesyet.canvasser-app.state :as db]
|
||||
))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;;;;
|
||||
;;;; youyesyet.handlers: handlers for events.
|
||||
;;;; youyesyet.canvasser-app.handlers: event handlers.
|
||||
;;;;
|
||||
;;;; This program is free software; you can redistribute it and/or
|
||||
;;;; modify it under the terms of the GNU General Public License
|
||||
|
@ -101,113 +102,12 @@
|
|||
(:electors state) "'")))))
|
||||
|
||||
|
||||
;; map stuff. If we do this in canvasser-app.views.map we get circular
|
||||
;; references, so do it here.
|
||||
(defn pin-image
|
||||
"select the name of a suitable pin image for this address"
|
||||
[address]
|
||||
(let [intentions
|
||||
(set
|
||||
(remove
|
||||
nil?
|
||||
(map
|
||||
:intention
|
||||
(mapcat :electors
|
||||
(:dwellings address)))))]
|
||||
(case (count intentions)
|
||||
0 "unknown-pin"
|
||||
1 (str (name (first intentions)) "-pin")
|
||||
"mixed-pin")))
|
||||
|
||||
|
||||
(defn map-pin-click-handler
|
||||
"On clicking on the pin, navigate to the electors at the address.
|
||||
This way of doing it adds an antry in the browser location history,
|
||||
so back links work."
|
||||
[id]
|
||||
(js/console.log (str "Click handler for address #" id))
|
||||
(let [view @(subscribe [:view])
|
||||
centre (.getCenter view)]
|
||||
(dispatch [:set-zoom (.getZoom view)])
|
||||
(dispatch [:set-latitude (.-lat centre)])
|
||||
(dispatch [:set-longitude (.-lng centre)]))
|
||||
(set! window.location.href (str "#building/" id)))
|
||||
|
||||
|
||||
(defn add-map-pin
|
||||
"Add a map-pin at this address in this map view"
|
||||
[address view]
|
||||
(let [lat (:latitude address)
|
||||
lng (:longitude address)
|
||||
pin (.icon js/L
|
||||
(clj->js
|
||||
{:iconAnchor [16 41]
|
||||
:iconSize [32 42]
|
||||
:iconUrl (str "img/map-pins/" (pin-image address) ".png")
|
||||
:riseOnHover true
|
||||
:shadowAnchor [16 23]
|
||||
:shadowSize [57 24]
|
||||
:shadowUrl "img/map-pins/shadow_pin.png"}))
|
||||
marker (.marker js/L
|
||||
(.latLng js/L lat lng)
|
||||
(clj->js {:icon pin
|
||||
:title (:address address)}))]
|
||||
(.on (.addTo marker view) "click" (fn [_] (map-pin-click-handler (str (:id address)))))
|
||||
marker))
|
||||
|
||||
|
||||
(defn map-remove-pins
|
||||
"Remove all pins from this map `view`. Side-effecty; liable to be problematic."
|
||||
[view]
|
||||
|
||||
(if
|
||||
view
|
||||
(.eachLayer
|
||||
view
|
||||
(fn [layer]
|
||||
(try
|
||||
(if
|
||||
(instance? js/L.Marker layer)
|
||||
(.removeLayer view layer))
|
||||
(catch js/Object any (js/console.log (str "Failed to remove pin '" layer "' from map: " any)))))))
|
||||
view)
|
||||
|
||||
|
||||
(defn refresh-map-pins
|
||||
"Refresh the map pins on this map. Side-effecty; liable to be problematic."
|
||||
[]
|
||||
(let [view (map-remove-pins @(subscribe [:view]))
|
||||
addresses @(subscribe [:addresses])]
|
||||
(if
|
||||
view
|
||||
(do
|
||||
(js/console.log (str "Adding " (count addresses) " pins"))
|
||||
(doall (map #(add-map-pin % view) addresses)))
|
||||
(js/console.log "View is not yet ready"))
|
||||
view))
|
||||
|
||||
|
||||
(reg-event-db
|
||||
:initialize-db
|
||||
(fn [_ _]
|
||||
db/default-db))
|
||||
|
||||
|
||||
(defn get-current-location []
|
||||
"Get the current location from the device."
|
||||
(try
|
||||
(if (.-geolocation js/navigator)
|
||||
(.getCurrentPosition
|
||||
(.-geolocation js/navigator)
|
||||
(fn [position]
|
||||
(js/console.log "Current location is: " + position)
|
||||
(dispatch [:set-latitude (.-latitude (.-coords position))])
|
||||
(dispatch [:set-longitude (.-longitude (.-coords position))])))
|
||||
(js/console.log "Geolocation not available"))
|
||||
(catch js/Object any
|
||||
(js/console.log "Exception while trying to access location: " + any))))
|
||||
|
||||
|
||||
;; (reg-event-fx
|
||||
;; :feedback
|
||||
;; (fn [x y]
|
||||
|
@ -254,11 +154,21 @@
|
|||
:db (add-to-feedback db :fetch-locality)}))
|
||||
|
||||
|
||||
(reg-event-db
|
||||
:get-current-location
|
||||
(fn [db _]
|
||||
(js/console.log "Updating current location")
|
||||
(assoc db :froboz (get-current-location))))
|
||||
|
||||
|
||||
(reg-event-db
|
||||
:process-locality
|
||||
(fn
|
||||
[db [_ response]]
|
||||
(js/console.log "Updating locality data")
|
||||
;; loop to do it again
|
||||
(dispatch [:dispatch-later [{:ms 5000 :dispatch [:fetch-locality]}
|
||||
{:ms 1000 :dispatch [:get-current-location]}]])
|
||||
(assoc
|
||||
(remove-from-feedback db :fetch-locality)
|
||||
(refresh-map-pins)
|
||||
|
@ -270,6 +180,9 @@
|
|||
(fn [db _]
|
||||
;; TODO: signal something has failed? It doesn't matter very much, unless it keeps failing.
|
||||
(js/console.log "Failed to fetch locality data")
|
||||
;; loop to do it again
|
||||
(dispatch [:dispatch-later [{:ms 60000 :dispatch [:fetch-locality]}
|
||||
{:ms 1000 :dispatch [:get-current-location]}]])
|
||||
(assoc
|
||||
(remove-from-feedback db :fetch-locality)
|
||||
:error (cons :fetch-locality (:error db)))))
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
youyesyet.canvasser-app.views.map
|
||||
(:require [re-frame.core :refer [reg-sub subscribe dispatch dispatch-sync]]
|
||||
[reagent.core :as reagent]
|
||||
[youyesyet.canvasser-app.handlers :refer [get-current-location refresh-map-pins]]))
|
||||
[youyesyet.canvasser-app.gis :refer [refresh-map-pins get-current-location]]))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;;;;
|
||||
|
@ -28,7 +28,6 @@
|
|||
;;;;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
|
||||
;;; The pattern from the re-com demo (https://github.com/Day8/re-com) is to have
|
||||
;;; one source file/namespace per view. Each namespace contains a function 'panel'
|
||||
;;; whose output is an enlive-style specification of the view to be redered.
|
||||
|
|
5
src/cljs/youyesyet/issue_expert_app/README.md
Normal file
5
src/cljs/youyesyet/issue_expert_app/README.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
# Issue Expert app
|
||||
|
||||
The Issue Expert app is essentially a whole different app. I think it needs to be an app because it needs a much more slick UI than an old CRUD web system, but it's designed for use on desktop systems with large screens.
|
||||
|
||||
It comprises two views: a list of open followup requests, and a view to handle an individual request. The work flow is, pick a request from the list, obtain an exclusive lock on it,
|
0
src/cljs/youyesyet/issue_expert_app/core.cljs
Normal file
0
src/cljs/youyesyet/issue_expert_app/core.cljs
Normal file
52
src/cljs/youyesyet/issue_expert_app/views/list.cljs
Normal file
52
src/cljs/youyesyet/issue_expert_app/views/list.cljs
Normal file
|
@ -0,0 +1,52 @@
|
|||
(ns ^{:doc "Issue Expert app list panel."
|
||||
:author "Simon Brooke"}
|
||||
youyesyet.canvasser-app.views.issues
|
||||
(:require [re-frame.core :refer [reg-sub subscribe]]
|
||||
[youyesyet.canvasser-app.ui-utils :as ui]))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;;;;
|
||||
;;;; youyesyet.canvasser-app.views.issues: working view for issue experts for youyesyet.
|
||||
;;;;
|
||||
;;;; This program is free software; you can redistribute it and/or
|
||||
;;;; modify it under the terms of the GNU General Public License
|
||||
;;;; as published by the Free Software Foundation; either version 2
|
||||
;;;; of the License, or (at your option) any later version.
|
||||
;;;;
|
||||
;;;; This program is distributed in the hope that it will be useful,
|
||||
;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;;;; GNU General Public License for more details.
|
||||
;;;;
|
||||
;;;; You should have received a copy of the GNU General Public License
|
||||
;;;; along with this program; if not, write to the Free Software
|
||||
;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
|
||||
;;;; USA.
|
||||
;;;;
|
||||
;;;; Copyright (C) 2016 Simon Brooke for Radical Independence Campaign
|
||||
;;;;
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
|
||||
|
||||
;;; The pattern from the re-com demo (https://github.com/Day8/re-com) is to have
|
||||
;;; one source file/namespace per view. Each namespace contains a function 'panel'
|
||||
;;; whose output is an enlive-style specification of the view to be redered.
|
||||
;;; I propose to follow this pattern. This file will provide the issues view.
|
||||
|
||||
|
||||
;;; TODO: This is, in essence, an enturely different app. It really ought to be
|
||||
;;; in a separate project. But to get it working quickly, it's here for now.
|
||||
|
||||
;;; Simple list of the issues of the day.
|
||||
(defn panel
|
||||
"Generate the list panel."
|
||||
[]
|
||||
(let [issues @(subscribe [:issues])]
|
||||
(if issues
|
||||
[:div
|
||||
[:h1 "Issues"]
|
||||
[:div.container {:id "main-container"}
|
||||
(ui/back-link)
|
||||
[:div {:id "issue-list"}
|
||||
(map (fn [i] (ui/big-link (:id i) :target (str "#issue/" (:id i)))) issues)]]]
|
||||
(ui/error-panel "No issues loaded"))))
|
|
@ -408,7 +408,7 @@ version="0.1.1">
|
|||
the system.</documentation>
|
||||
<key>
|
||||
<property required="true" type="string" name="id" column="id"
|
||||
size="32" distinct="all">
|
||||
size="32" distinct="all" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -471,6 +471,7 @@ version="0.1.1">
|
|||
<property type="text" name="brief">
|
||||
<prompt prompt="Brief response to issue" locale="en-GB"/>
|
||||
</property>
|
||||
<property type="link" name="experts" entity="canvassers"/>
|
||||
<list properties="listed" name="Issues">
|
||||
<field property="id">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
|
@ -512,7 +513,7 @@ version="0.1.1">
|
|||
<documentation>Intentions of electors to vote for options
|
||||
elicited in visits.</documentation>
|
||||
<key>
|
||||
<property type="integer" distinct="system" required="true"
|
||||
<property type="integer" distinct="system" required="true" immutable="true"
|
||||
name="id">
|
||||
<generator action="native"/>
|
||||
</property>
|
||||
|
@ -577,9 +578,7 @@ version="0.1.1">
|
|||
</field>
|
||||
</form>
|
||||
</entity>
|
||||
<!--
|
||||
entity canvassers already has a key - not generating one
|
||||
-->
|
||||
|
||||
<entity table="canvassers" name="canvassers" magnitude="5"
|
||||
volatility="4">
|
||||
<documentation>Primary users of the system: those actually
|
||||
|
@ -635,6 +634,10 @@ version="0.1.1">
|
|||
farkey="role_id">
|
||||
<prompt prompt="Roles" locale="en-GB"/>
|
||||
</property>
|
||||
<property type="link" name="expertise" entity="issues">
|
||||
<documentation>Only relevant to issue experts.</documentation>
|
||||
<prompt prompt="Expertise" locale="en-GB"/>
|
||||
</property>
|
||||
<permission group="canvassers" permission="edit">
|
||||
<documentation>But only their own record</documentation>
|
||||
</permission>
|
||||
|
@ -716,16 +719,14 @@ version="0.1.1">
|
|||
<permission group="issueeditors" permission="read"/>
|
||||
<permission group="admin" permission="all"/>
|
||||
</entity>
|
||||
<!--
|
||||
entity followuprequests already has a key - not generating one
|
||||
-->
|
||||
|
||||
<entity table="followuprequests" name="followuprequests"
|
||||
magnitude="7" volatility="2">
|
||||
<documentation>Requests for a followup with an issue
|
||||
expert</documentation>
|
||||
<key>
|
||||
<property required="true" type="integer" name="id"
|
||||
column="id" distinct="system">
|
||||
column="id" distinct="system" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -787,9 +788,7 @@ version="0.1.1">
|
|||
<permission group="issueeditors" permission="read"/>
|
||||
<permission group="admin" permission="all"/>
|
||||
</entity>
|
||||
<!--
|
||||
entity roles already has a key - not generating one
|
||||
-->
|
||||
|
||||
<entity table="roles" name="roles" magnitude="1" volatility="7">
|
||||
<documentation>A role (essentially, the same as a group, but
|
||||
application layer rather than database layer) of which a user
|
||||
|
@ -833,9 +832,7 @@ version="0.1.1">
|
|||
<permission group="issueeditors" permission="read"/>
|
||||
<permission group="admin" permission="all"/>
|
||||
</entity>
|
||||
<!--
|
||||
entity teams already has a key - not generating one
|
||||
-->
|
||||
|
||||
<entity table="teams" name="teams" magnitude="4" volatility="4">
|
||||
<key>
|
||||
<property type="integer" name="id" column="id"
|
||||
|
@ -951,13 +948,14 @@ version="0.1.1">
|
|||
<permission permission="read" group="issueeditors"/>
|
||||
<permission permission="all" group="admin"/>
|
||||
</entity>
|
||||
|
||||
<entity name="events" table="events" magnitude="5">
|
||||
<documentation>
|
||||
An event to which a team or teams are invited. Typically created by the team organiser(s).
|
||||
May be a training event, a social event or a canvassing session.
|
||||
</documentation>
|
||||
<key>
|
||||
<property type="integer" distinct="system" required="true" name="id">
|
||||
<property type="integer" distinct="system" required="true" name="id" immutable="true">
|
||||
<generator action="native"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -1020,16 +1018,14 @@ version="0.1.1">
|
|||
<permission group="issueeditors" permission="read"/>
|
||||
<permission group="admin" permission="all"/>
|
||||
</entity>
|
||||
<!--
|
||||
entity followupactions already has a key - not generating one
|
||||
-->
|
||||
|
||||
<entity table="followupactions" name="followupactions"
|
||||
magnitude="7" volatility="0">
|
||||
<documentation>Actions taken on followup
|
||||
requests.</documentation>
|
||||
<key>
|
||||
<property required="true" type="integer" name="id"
|
||||
column="id" distinct="system">
|
||||
column="id" distinct="system" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -1112,7 +1108,7 @@ version="0.1.1">
|
|||
canvassed on</documentation>
|
||||
<key>
|
||||
<property required="true" type="string" name="id" column="id"
|
||||
size="32" immutable="true" distinct="all">
|
||||
size="32" distinct="all" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
|
|
@ -391,7 +391,7 @@
|
|||
<documentation>Authorities which may authenticate canvassers to
|
||||
the system.</documentation>
|
||||
<key>
|
||||
<property required="true" type="string" name="id" column="id" size="32" distinct="all">
|
||||
<property required="true" type="string" name="id" column="id" size="32" distinct="all" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -450,6 +450,7 @@
|
|||
<property type="text" name="brief">
|
||||
<prompt prompt="Brief response to issue" locale="en-GB"/>
|
||||
</property>
|
||||
<property type="link" name="experts" entity="canvassers"/>
|
||||
<list properties="listed" name="Issues">
|
||||
<field property="id">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
|
@ -492,7 +493,7 @@
|
|||
<documentation>Intentions of electors to vote for options
|
||||
elicited in visits.</documentation>
|
||||
<key>
|
||||
<property type="integer" distinct="system" required="true" name="id">
|
||||
<property type="integer" distinct="system" required="true" immutable="true" name="id">
|
||||
<generator action="native"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -600,6 +601,10 @@
|
|||
<property type="link" name="roles" entity="roles" farkey="role_id">
|
||||
<prompt prompt="Roles" locale="en-GB"/>
|
||||
</property>
|
||||
<property type="link" name="expertise" entity="issues">
|
||||
<documentation>Only relevant to issue experts.</documentation>
|
||||
<prompt prompt="Expertise" locale="en-GB"/>
|
||||
</property>
|
||||
<permission group="canvassers" permission="edit">
|
||||
<documentation>But only their own record</documentation>
|
||||
</permission>
|
||||
|
@ -688,7 +693,7 @@
|
|||
<documentation>Requests for a followup with an issue
|
||||
expert</documentation>
|
||||
<key>
|
||||
<property required="true" type="integer" name="id" column="id" distinct="system">
|
||||
<property required="true" type="integer" name="id" column="id" distinct="system" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -913,7 +918,7 @@
|
|||
May be a training event, a social event or a canvassing session.
|
||||
</documentation>
|
||||
<key>
|
||||
<property type="integer" distinct="system" required="true" name="id">
|
||||
<property type="integer" distinct="system" required="true" name="id" immutable="true">
|
||||
<generator action="native"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -982,7 +987,7 @@
|
|||
<documentation>Actions taken on followup
|
||||
requests.</documentation>
|
||||
<key>
|
||||
<property required="true" type="integer" name="id" column="id" distinct="system">
|
||||
<property required="true" type="integer" name="id" column="id" distinct="system" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
@ -1058,7 +1063,7 @@
|
|||
<documentation>Options in the election or referendum being
|
||||
canvassed on</documentation>
|
||||
<key>
|
||||
<property required="true" type="string" name="id" column="id" size="32" immutable="true" distinct="all">
|
||||
<property required="true" type="string" name="id" column="id" size="32" distinct="all" immutable="true">
|
||||
<prompt prompt="id" locale="en-GB"/>
|
||||
</property>
|
||||
</key>
|
||||
|
|
Loading…
Reference in a new issue