Extremely close to alpha release

This commit is contained in:
Simon Brooke 2018-07-05 11:16:48 +01:00
parent ff5c78d030
commit fc2bd86cff
43 changed files with 2375 additions and 719 deletions

View file

@ -1,55 +1,74 @@
{% extends "base.html" %}
<!-- File application-index.html generated 2018-07-03T23:08:20.049Z by adl.to-selmer-templates.
<!-- File application-index.html generated 2018-07-05T10:14:18.460Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<dl class='index'>
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-addresses-Addresses'>
Address
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
Addresses of all buildings which contain dwellings.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-authorities-Authorities'>
Authority
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
Authorities which may authenticate canvassers to the system.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-canvassers-Canvassers'>
Canvasser
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
Primary users of the system: those actually interviewing electors.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors %}
<dt>
<a href='list-districts-Districts'>
District
</a>
</dt>
{% endifmemberof %}
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors %}
<dd>
<p>
Electoral districts: TODO: Shape (polygon) information will need to be added, for use in maps.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-dwellings-Dwellings'>
Dwelling
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
All dwellings within addresses in the system; a dwelling is a
@ -60,110 +79,155 @@ All dwellings within addresses in the system; a dwelling is a
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-electors-Electors'>
Elector
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
All electors known to the system; electors are people believed to be entitled to vote in the current campaign.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
<dt>
<a href='list-followupactions-Followupactions'>
Followupaction
</a>
</dt>
{% endifmemberof %}
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
<dd>
<p>
Actions taken on followup requests.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-followupmethods-Followupmethods'>
Followupmethod
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-followuprequests-Followuprequests'>
Followuprequest
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
Requests for a followup with an issue expert
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-genders-Genders'>
Gender
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
All genders which may be assigned to electors.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers analysts admin %}
<dt>
<a href='list-intentions-Intentions'>
Intention
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers analysts admin %}
<dd>
<p>
Intentions of electors to vote for options elicited in visits.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-issues-Issues'>
Issue
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
Issues believed to be of interest to electors, about which they may have questions.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-options-Options'>
Option
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
Options in the election or referendum being canvassed on
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dt>
<a href='list-roles-Roles'>
Role
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<dd>
<p>
A role (essentially, the same as a group, but application layer rather than database layer) of which a user may be a member.
</p>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<dt>
<a href='list-teams-Teams'>
Team
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<dd>
</dd>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
<dt>
<a href='list-visits-Visits'>
Visit
</a>
</dt>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
<dd>
<p>
All visits made by canvassers to dwellings in which opinions were recorded.
</p>
</dd>
{% endifmemberof %}
</dl>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-addresses-Address.html generated 2018-07-03T23:08:20.032Z by adl.to-selmer-templates.
<!-- File form-addresses-Address.html generated 2018-07-05T10:14:18.448Z 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-addresses-Address' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,7 +33,7 @@ You are not permitted to view id of addresses
address
</label>
{% ifmemberof admin %}
<input id='address' name='address' type='text' value='{{record.address}}' maxlength='256' size='60'/>
<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'>
@ -48,7 +51,7 @@ You are not permitted to view address of addresses
postcode
</label>
{% ifmemberof admin %}
<input id='postcode' name='postcode' type='text' value='{{record.postcode}}' maxlength='16' size='16'/>
<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'>
@ -66,7 +69,7 @@ You are not permitted to view postcode of addresses
phone
</label>
{% ifmemberof admin %}
<input id='phone' name='phone' type='text' value='{{record.phone}}' maxlength='16' size='16'/>
<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'>
@ -84,12 +87,13 @@ You are not permitted to view phone of addresses
district_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='districts' found='true'>
<input name='district_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='district_id' name='district_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='district_id' name='district_id' class='pseudo-widget disabled'>
@ -138,19 +142,43 @@ You are not permitted to view longitude of addresses
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this addresses 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 addresses 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-authorities-Authority.html generated 2018-07-03T23:08:20.060Z by adl.to-selmer-templates.
<!-- File form-authorities-Authority.html generated 2018-07-05T10:14:18.468Z 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-authorities-Authority' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -26,108 +29,117 @@ You are not permitted to view id of authorities
{% endifmemberof %}
</p>
<p class='widget'>
<label for='request-token-uri'>
<label for='request_token_uri'>
request-token-uri
</label>
{% ifmemberof admin %}
<input id='request-token-uri' name='request-token-uri' type='text' value='{{record.request-token-uri}}' maxlength='256' size='60'/>
<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 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 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 %}
</p>
<p class='widget'>
<label for='access-token-uri'>
<label for='access_token_uri'>
access-token-uri
</label>
{% ifmemberof admin %}
<input id='access-token-uri' name='access-token-uri' type='text' value='{{record.access-token-uri}}' maxlength='256' size='60'/>
<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 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 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 %}
</p>
<p class='widget'>
<label for='authorize-uri'>
<label for='authorize_uri'>
authorize-uri
</label>
{% ifmemberof admin %}
<input id='authorize-uri' name='authorize-uri' type='text' value='{{record.authorize-uri}}' maxlength='256' size='60'/>
<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 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 id='authorize_uri' name='authorize_uri' class='pseudo-widget not-authorised'>
You are not permitted to view authorize_uri of authorities
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='consumer-key'>
<label for='consumer_key'>
consumer-key
</label>
{% ifmemberof admin %}
<input id='consumer-key' name='consumer-key' type='text' value='{{record.consumer-key}}' maxlength='32' size='32'/>
<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 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 id='consumer_key' name='consumer_key' class='pseudo-widget not-authorised'>
You are not permitted to view consumer_key of authorities
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='consumer-secret'>
<label for='consumer_secret'>
consumer-secret
</label>
{% ifmemberof admin %}
<input id='consumer-secret' name='consumer-secret' type='text' value='{{record.consumer-secret}}' maxlength='256' size='60'/>
<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 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 id='consumer_secret' name='consumer_secret' class='pseudo-widget not-authorised'>
You are not permitted to view consumer_secret of authorities
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this authorities 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 authorities 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 %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-canvassers-Canvasser.html generated 2018-07-03T23:08:20.065Z by adl.to-selmer-templates.
<!-- File form-canvassers-Canvasser.html generated 2018-07-05T10:14:18.471Z 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-canvassers-Canvasser' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,7 +33,7 @@ You are not permitted to view id of canvassers
username
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<input id='username' name='username' type='text' value='{{record.username}}' maxlength='32' size='32'/>
<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'>
@ -48,7 +51,7 @@ You are not permitted to view username of canvassers
fullname
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<input id='fullname' name='fullname' type='text' value='{{record.fullname}}' maxlength='64' size='60'/>
<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'>
@ -66,12 +69,13 @@ You are not permitted to view fullname of canvassers
elector_id
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<div class='select-box' farside='electors' found='true'>
<input name='elector_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='elector_id' name='elector_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;email=" + elector_id_search_box.text + "&amp;name=" + elector_id_search_box.text + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='elector_id' name='elector_id' class='pseudo-widget disabled'>
@ -89,12 +93,13 @@ You are not permitted to view elector_id of canvassers
address_id
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<div class='select-box' farside='addresses' found='true'>
<input name='address_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='address_id' name='address_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='address_id' name='address_id' class='pseudo-widget disabled'>
@ -112,7 +117,7 @@ You are not permitted to view address_id of canvassers
phone
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<input id='phone' name='phone' type='text' value='{{record.phone}}' maxlength='16' size='16'/>
<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'>
@ -130,7 +135,7 @@ You are not permitted to view phone of canvassers
email
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<input id='email' name='email' type='text' value='{{record.email}}' maxlength='128' size='60'/>
<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'>
@ -148,12 +153,13 @@ You are not permitted to view email of canvassers
authority_id
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<div class='select-box' farside='authorities' found='true'>
<input name='authority_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='authority_id' name='authority_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='authority_id' name='authority_id' class='pseudo-widget disabled'>
@ -189,11 +195,11 @@ You are not permitted to view authorised of canvassers
roles
</label>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<div class='select-box' farside='roles' found='true'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='roles' name='roles' class='pseudo-widget disabled'>
@ -206,19 +212,43 @@ You are not permitted to view roles of canvassers
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this canvassers record
</label>
<input id='save-button' name='save-button' class='action-safe' type='submit' value='Save!'/>
</p>
{% endifmemberof %}
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<p class='widget action-dangerous'>
<label for='delete-button' class='action-dangerous'>
To delete this canvassers 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-districts-District.html generated 2018-07-03T23:08:20.021Z by adl.to-selmer-templates.
<!-- File form-districts-District.html generated 2018-07-05T10:14:18.436Z 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-districts-District' method='POST'>
@ -11,10 +14,10 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
<label for='id'>
id
</label>
{% ifmemberof admin admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
{% ifmemberof admin %}
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
{% else %}
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors %}
<span id='id' name='id' class='pseudo-widget disabled'>
{{record.id}}
</span>
@ -29,10 +32,10 @@ You are not permitted to view id of districts
<label for='name'>
name
</label>
{% ifmemberof admin admin %}
<input id='name' name='name' type='text' value='{{record.name}}' maxlength='64' size='60'/>
{% 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 admin %}
{% ifmemberof public admin canvassers teamorganisers issueexperts analysts issueeditors %}
<span id='name' name='name' class='pseudo-widget disabled'>
{{record.name}}
</span>
@ -43,19 +46,28 @@ You are not permitted to view name of districts
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this districts 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 districts 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 %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-dwellings-Dwelling.html generated 2018-07-03T23:08:20.081Z by adl.to-selmer-templates.
<!-- File form-dwellings-Dwelling.html generated 2018-07-05T10:14:18.485Z 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-dwellings-Dwelling' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,12 +33,13 @@ You are not permitted to view id of dwellings
address_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='addresses' found='true'>
<input name='address_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='address_id' name='address_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='address_id' name='address_id' class='pseudo-widget disabled'>
@ -49,36 +53,60 @@ You are not permitted to view address_id of dwellings
{% endifmemberof %}
</p>
<p class='widget'>
<label for='sub-address'>
<label for='sub_address'>
sub-address
</label>
{% ifmemberof admin %}
<input id='sub-address' name='sub-address' type='text' value='{{record.sub-address}}' maxlength='32' size='32'/>
<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 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 id='sub_address' name='sub_address' class='pseudo-widget not-authorised'>
You are not permitted to view sub_address of dwellings
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this dwellings 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 dwellings 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-electors-Elector.html generated 2018-07-03T23:08:20.055Z by adl.to-selmer-templates.
<!-- File form-electors-Elector.html generated 2018-07-05T10:14:18.465Z 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-electors-Elector' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,7 +33,7 @@ You are not permitted to view id of electors
name
</label>
{% ifmemberof admin %}
<input id='name' name='name' type='text' value='{{record.name}}' maxlength='64' size='60'/>
<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'>
@ -48,12 +51,13 @@ You are not permitted to view name of electors
dwelling_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='dwellings' found='true'>
<input name='dwelling_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='dwelling_id' name='dwelling_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='dwelling_id' name='dwelling_id' class='pseudo-widget disabled'>
@ -71,7 +75,7 @@ You are not permitted to view dwelling_id of electors
phone
</label>
{% ifmemberof admin %}
<input id='phone' name='phone' type='text' value='{{record.phone}}' maxlength='16' size='16'/>
<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'>
@ -89,7 +93,7 @@ You are not permitted to view phone of electors
email
</label>
{% ifmemberof admin %}
<input id='email' name='email' type='text' value='{{record.email}}' maxlength='128' size='60'/>
<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'>
@ -107,11 +111,11 @@ You are not permitted to view email of electors
gender
</label>
{% ifmemberof admin %}
<div class='select-box' farside='genders' found='true'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='gender' name='gender' class='pseudo-widget disabled'>
@ -124,19 +128,43 @@ You are not permitted to view gender of electors
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this electors 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 electors 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,12 @@
{% extends "base.html" %}
<!-- File form-followupactions-Followupaction.html generated 2018-07-03T23:08:20.084Z by adl.to-selmer-templates.
<!-- File form-followupactions-Followupaction.html generated 2018-07-05T10:14:18.488Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block extra-head %}
{% script "js/lib/node_modules/simplemde/dist/simplemde.min.js" %}
{% style "js/lib/node_modules/simplemde/dist/simplemde.min.css" %}
{% endblock %}
{% block content %}
<div id='content' class='edit'>
<form action='{{servlet-context}}/form-followupactions-Followupaction' method='POST'>
@ -12,7 +16,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,12 +34,13 @@ You are not permitted to view id of followupactions
request_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='followuprequests' found='true'>
<input name='request_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='request_id' name='request_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;issue_id=" + request_id_search_box.text + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
<span id='request_id' name='request_id' class='pseudo-widget disabled'>
@ -53,12 +58,13 @@ You are not permitted to view request_id of followupactions
actor
</label>
{% ifmemberof admin %}
<div class='select-box' farside='canvassers' found='true'>
<input name='actor-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='actor' name='actor' comment='JavaScript stuff to fix up aynchronous loading'>
<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>
</div>
</span>
{% else %}
{% ifmemberof issueexperts canvassers analysts issueeditors admin %}
<span id='actor' name='actor' class='pseudo-widget disabled'>
@ -76,7 +82,7 @@ You are not permitted to view actor of followupactions
date
</label>
{% ifmemberof admin %}
<input id='date' name='date' type='text' value='{{record.date}}' maxlength='' size='16'/>
<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'>
@ -94,7 +100,9 @@ You are not permitted to view date of followupactions
notes
</label>
{% ifmemberof admin %}
<input id='notes' name='notes' type='text' value='{{record.notes}}' maxlength='' size='16'/>
<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'>
@ -125,19 +133,61 @@ You are not permitted to view closed of followupactions
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this followupactions 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 followupactions 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'>
/**
* 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,
uniqueId: "Smeagol-{{page}}",
delay: 1000,
},
indentWithTabs: true,
insertTexts: {
horizontalRule: ["", "\n\n-----\n\n"],
image: ["![](http://", ")"],
link: ["[", "](http://)"],
table: ["", "\n\n| Column 1 | Column 2 | Column 3 |\n| -------- | -------- | -------- |\n| Text | Text | Text |\n\n"],
},
showIcons: ["code"], //, "table"], - sadly, markdown-clj does not support tables
spellChecker: true,
status: ["autosave", "lines", "words", "cursor"]
});
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-followupmethods-Followupmethod.html generated 2018-07-03T23:08:20.087Z by adl.to-selmer-templates.
<!-- File form-followupmethods-Followupmethod.html generated 2018-07-05T10:14:18.491Z 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'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -25,19 +28,28 @@ You are not permitted to view id of followupmethods
{% 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 %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-followuprequests-Followuprequest.html generated 2018-07-03T23:08:20.025Z by adl.to-selmer-templates.
<!-- File form-followuprequests-Followuprequest.html generated 2018-07-05T10:14:18.440Z 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-followuprequests-Followuprequest' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,12 +33,13 @@ You are not permitted to view id of followuprequests
elector_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='electors' found='true'>
<input name='elector_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='elector_id' name='elector_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;email=" + elector_id_search_box.text + "&amp;name=" + elector_id_search_box.text + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='elector_id' name='elector_id' class='pseudo-widget disabled'>
@ -53,12 +57,13 @@ You are not permitted to view elector_id of followuprequests
visit_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='visits' found='true'>
<input name='visit_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='visit_id' name='visit_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='visit_id' name='visit_id' class='pseudo-widget disabled'>
@ -76,11 +81,11 @@ You are not permitted to view visit_id of followuprequests
issue_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='issues' found='true'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='issue_id' name='issue_id' class='pseudo-widget disabled'>
@ -98,11 +103,11 @@ You are not permitted to view issue_id of followuprequests
method_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='followupmethods' found='true'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='method_id' name='method_id' class='pseudo-widget disabled'>
@ -115,19 +120,43 @@ You are not permitted to view method_id of followuprequests
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this followuprequests 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 followuprequests 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-genders-Gender.html generated 2018-07-03T23:08:20.014Z by adl.to-selmer-templates.
<!-- File form-genders-Gender.html generated 2018-07-05T10:14:18.432Z 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-genders-Gender' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -25,19 +28,28 @@ You are not permitted to view id of genders
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this genders 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 genders 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 %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-intentions-Intention.html generated 2018-07-03T23:08:20.075Z by adl.to-selmer-templates.
<!-- File form-intentions-Intention.html generated 2018-07-05T10:14:18.481Z 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-intentions-Intention' method='POST'>
@ -12,12 +15,13 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
visit_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='visits' found='true'>
<input name='visit_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='visit_id' name='visit_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers analysts admin %}
<span id='visit_id' name='visit_id' class='pseudo-widget disabled'>
@ -35,12 +39,13 @@ You are not permitted to view visit_id of intentions
elector_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='electors' found='true'>
<input name='elector_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='elector_id' name='elector_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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 + "&amp;email=" + elector_id_search_box.text + "&amp;name=" + elector_id_search_box.text + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers analysts admin %}
<span id='elector_id' name='elector_id' class='pseudo-widget disabled'>
@ -58,11 +63,11 @@ You are not permitted to view elector_id of intentions
option_id
</label>
{% ifmemberof admin %}
<div class='select-box' farside='options' found='true'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers analysts admin %}
<span id='option_id' name='option_id' class='pseudo-widget disabled'>
@ -93,19 +98,43 @@ You are not permitted to view locality of intentions
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this intentions 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 intentions 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,12 @@
{% extends "base.html" %}
<!-- File form-issues-Issue.html generated 2018-07-03T23:08:20.039Z by adl.to-selmer-templates.
<!-- File form-issues-Issue.html generated 2018-07-05T10:14:18.452Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block extra-head %}
{% script "js/lib/node_modules/simplemde/dist/simplemde.min.js" %}
{% style "js/lib/node_modules/simplemde/dist/simplemde.min.css" %}
{% endblock %}
{% block content %}
<div id='content' class='edit'>
<form action='{{servlet-context}}/form-issues-Issue' method='POST'>
@ -12,7 +16,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof issueeditors admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,7 +34,7 @@ You are not permitted to view id of issues
url
</label>
{% ifmemberof issueeditors admin %}
<input id='url' name='url' type='text' value='{{record.url}}' maxlength='256' size='60'/>
<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'>
@ -66,7 +70,9 @@ You are not permitted to view current of issues
brief
</label>
{% ifmemberof issueeditors admin %}
<input id='brief' name='brief' type='text' value='{{record.brief}}' maxlength='' size='16'/>
<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'>
@ -79,19 +85,46 @@ You are not permitted to view brief of issues
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof issueeditors admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this issues record
</label>
<input id='save-button' name='save-button' class='action-safe' type='submit' value='Save!'/>
</p>
{% endifmemberof %}
{% ifmemberof issueeditors admin %}
<p class='widget action-dangerous'>
<label for='delete-button' class='action-dangerous'>
To delete this issues 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'>
var simplemde = new SimpleMDE({
autosave: {
enabled: true,
uniqueId: "Smeagol-{{page}}",
delay: 1000,
},
indentWithTabs: true,
insertTexts: {
horizontalRule: ["", "\n\n-----\n\n"],
image: ["![](http://", ")"],
link: ["[", "](http://)"],
table: ["", "\n\n| Column 1 | Column 2 | Column 3 |\n| -------- | -------- | -------- |\n| Text | Text | Text |\n\n"],
},
showIcons: ["code"], //, "table"], - sadly, markdown-clj does not support tables
spellChecker: true,
status: ["autosave", "lines", "words", "cursor"]
});
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-options-Option.html generated 2018-07-03T23:08:20.074Z by adl.to-selmer-templates.
<!-- File form-options-Option.html generated 2018-07-05T10:14:18.481Z 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-options-Option' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -25,19 +28,28 @@ You are not permitted to view id of options
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this options 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 options 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 %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-roles-Role.html generated 2018-07-03T23:08:20.042Z by adl.to-selmer-templates.
<!-- File form-roles-Role.html generated 2018-07-05T10:14:18.454Z 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-roles-Role' method='POST'>
@ -12,7 +15,7 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<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'>
@ -30,7 +33,7 @@ You are not permitted to view id of roles
name
</label>
{% ifmemberof admin %}
<input id='name' name='name' type='text' value='{{record.name}}' maxlength='64' size='60'/>
<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'>
@ -48,12 +51,13 @@ You are not permitted to view name of roles
members
</label>
{% ifmemberof admin %}
<div class='select-box' farside='canvassers' found='true'>
<input name='members-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='members' name='members' multiple='multiple' comment='JavaScript stuff to fix up aynchronous loading'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='members' name='members' class='pseudo-widget disabled'>
@ -66,19 +70,43 @@ You are not permitted to view members of roles
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this roles 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 roles 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-teams-Team.html generated 2018-07-03T23:08:20.050Z by adl.to-selmer-templates.
<!-- File form-teams-Team.html generated 2018-07-05T10:14:18.461Z 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-teams-Team' method='POST'>
@ -12,9 +15,9 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
id
</label>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<span id='id' name='id' class='pseudo-widget disabled'>
{{record.id}}
</span>
@ -30,9 +33,9 @@ You are not permitted to view id of teams
name
</label>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<input id='name' name='name' type='text' value='{{record.name}}' maxlength='64' size='60'/>
<input id='name' name='name' type='string' value='{{record.name}}' maxlength='64' size='60'/>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<span id='name' name='name' class='pseudo-widget disabled'>
{{record.name}}
</span>
@ -48,14 +51,15 @@ You are not permitted to view name of teams
district_id
</label>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<div class='select-box' farside='districts' found='true'>
<input name='district_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='district_id' name='district_id' comment='JavaScript stuff to fix up aynchronous loading'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<span id='district_id' name='district_id' class='pseudo-widget disabled'>
{{record.district_id}}
</span>
@ -73,7 +77,7 @@ latitude
{% 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 canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<span id='latitude' name='latitude' class='pseudo-widget disabled'>
{{record.latitude}}
</span>
@ -89,14 +93,15 @@ You are not permitted to view latitude of teams
members
</label>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<div class='select-box' farside='canvassers' found='true'>
<input name='members-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='members' name='members' multiple='multiple' comment='JavaScript stuff to fix up aynchronous loading'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<span id='members' name='members' class='pseudo-widget disabled'>
{{record.members}}
</span>
@ -112,14 +117,15 @@ You are not permitted to view members of teams
organisers
</label>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<div class='select-box' farside='canvassers' found='true'>
<input name='organisers-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='organisers' name='organisers' multiple='multiple' comment='JavaScript stuff to fix up aynchronous loading'>
<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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<span id='organisers' name='organisers' class='pseudo-widget disabled'>
{{record.organisers}}
</span>
@ -137,7 +143,7 @@ longitude
{% 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 canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin teamorganisers admin %}
<span id='longitude' name='longitude' class='pseudo-widget disabled'>
{{record.longitude}}
</span>
@ -148,19 +154,43 @@ You are not permitted to view longitude of teams
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this teams record
</label>
<input id='save-button' name='save-button' class='action-safe' type='submit' value='Save!'/>
</p>
{% endifmemberof %}
{% ifmemberof teamorganisers admin teamorganisers admin %}
<p class='widget action-dangerous'>
<label for='delete-button' class='action-dangerous'>
To delete this teams 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,8 +1,11 @@
{% extends "base.html" %}
<!-- File form-visits-Visit.html generated 2018-07-03T23:08:20.046Z by adl.to-selmer-templates.
<!-- File form-visits-Visit.html generated 2018-07-05T10:14:18.457Z 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-visits-Visit' method='POST'>
@ -11,10 +14,10 @@ See [Application Description Language](https://github.com/simon-brooke/adl).-->
<label for='id'>
id
</label>
{% ifmemberof admin admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
{% ifmemberof admin %}
<input id='id' name='id' type='string' value='{{record.id}}' maxlength='' size='16'/>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
<span id='id' name='id' class='pseudo-widget disabled'>
{{record.id}}
</span>
@ -29,15 +32,16 @@ You are not permitted to view id of visits
<label for='address_id'>
address_id
</label>
{% ifmemberof admin admin %}
<div class='select-box' farside='addresses' found='true'>
<input name='address_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='address_id' name='address_id' comment='JavaScript stuff to fix up aynchronous loading'>
{% 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 + "&amp;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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
<span id='address_id' name='address_id' class='pseudo-widget disabled'>
{{record.address_id}}
</span>
@ -52,15 +56,16 @@ You are not permitted to view address_id of visits
<label for='canvasser_id'>
canvasser_id
</label>
{% ifmemberof admin admin %}
<div class='select-box' farside='canvassers' found='true'>
<input name='canvasser_id-search-box' onchange='/* javascript to repopulate the select widget */'/>
<select id='canvasser_id' name='canvasser_id' comment='JavaScript stuff to fix up aynchronous loading'>
{% 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>
</div>
</span>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
<span id='canvasser_id' name='canvasser_id' class='pseudo-widget disabled'>
{{record.canvasser_id}}
</span>
@ -75,10 +80,10 @@ You are not permitted to view canvasser_id of visits
<label for='date'>
date
</label>
{% ifmemberof admin admin %}
<input id='date' name='date' type='text' value='{{record.date}}' maxlength='' size='16'/>
{% 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 issueexperts analysts issueeditors admin %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers %}
<span id='date' name='date' class='pseudo-widget disabled'>
{{record.date}}
</span>
@ -89,19 +94,43 @@ You are not permitted to view date of visits
{% endifmemberof %}
{% endifmemberof %}
</p>
{% ifmemberof admin %}
<p class='widget action-safe'>
<label for='save-button' class='action-safe'>
To save this visits 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 visits 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'>
/**
* 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));
});
}
</script>
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-addresses-Addresses.html generated 2018-07-03T23:08:20.064Z by adl.to-selmer-templates.
<!-- File list-addresses-Addresses.html generated 2018-07-05T10:14:18.471Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-addresses-Address'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-addresses-Address' class='big-link'>
Add a new Address
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-addresses-Addresses' class='list' action='{{servlet-context}}/list-addresses-Addresses' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='addresses'>
<thead>
<tr>
@ -34,6 +65,9 @@ latitude
<th>
longitude
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -58,7 +92,7 @@ longitude
<input id='longitude' type='number' name='longitude' value='{{ params.longitude }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -96,15 +130,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-addresses-Addresses');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-authorities-Authorities.html generated 2018-07-03T23:08:20.023Z by adl.to-selmer-templates.
<!-- File list-authorities-Authorities.html generated 2018-07-05T10:14:18.439Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-authorities-Authority'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-authorities-Authority' class='big-link'>
Add a new Authority
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-authorities-Authorities' class='list' action='{{servlet-context}}/list-authorities-Authorities' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='authorities'>
<thead>
<tr>
@ -25,6 +56,9 @@ access-token-uri
<th>
authorize-uri
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -40,7 +74,7 @@ authorize-uri
<input id='authorize_uri' type='text' name='authorize_uri' value='{{ params.authorize_uri }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -67,15 +101,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-authorities-Authorities');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-canvassers-Canvassers.html generated 2018-07-03T23:08:20.079Z by adl.to-selmer-templates.
<!-- File list-canvassers-Canvassers.html generated 2018-07-05T10:14:18.485Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-canvassers-Canvasser'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof canvassers teamorganisers admin canvassers teamorganisers admin %}
<div class='big-link-container'>
<a href='form-canvassers-Canvasser' class='big-link'>
Add a new Canvasser
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-canvassers-Canvassers' class='list' action='{{servlet-context}}/list-canvassers-Canvassers' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='canvassers'>
<thead>
<tr>
@ -40,6 +71,9 @@ authority_id
<th>
authorised
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -70,7 +104,7 @@ authorised
<input id='authorised' type='text' name='authorised' value='{{ params.authorised }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -118,15 +152,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-canvassers-Canvassers');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-districts-Districts.html generated 2018-07-03T23:08:20.072Z by adl.to-selmer-templates.
<!-- File list-districts-Districts.html generated 2018-07-05T10:14:18.479Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-districts-District'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-districts-District' class='big-link'>
Add a new District
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-districts-Districts' class='list' action='{{servlet-context}}/list-districts-Districts' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='districts'>
<thead>
<tr>
@ -19,6 +50,9 @@ id
<th>
name
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -28,7 +62,7 @@ name
<input id='name' type='text' name='name' value='{{ params.name }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -49,15 +83,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-districts-Districts');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-dwellings-Dwellings.html generated 2018-07-03T23:08:20.059Z by adl.to-selmer-templates.
<!-- File list-dwellings-Dwellings.html generated 2018-07-05T10:14:18.468Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-dwellings-Dwelling'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-dwellings-Dwelling' class='big-link'>
Add a new Dwelling
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-dwellings-Dwellings' class='list' action='{{servlet-context}}/list-dwellings-Dwellings' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='dwellings'>
<thead>
<tr>
@ -22,6 +53,9 @@ address_id
<th>
sub-address
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -34,7 +68,7 @@ sub-address
<input id='sub_address' type='text' name='sub_address' value='{{ params.sub_address }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -60,15 +94,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-dwellings-Dwellings');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-electors-Electors.html generated 2018-07-03T23:08:20.038Z by adl.to-selmer-templates.
<!-- File list-electors-Electors.html generated 2018-07-05T10:14:18.451Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-electors-Elector'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-electors-Elector' class='big-link'>
Add a new Elector
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-electors-Electors' class='list' action='{{servlet-context}}/list-electors-Electors' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='electors'>
<thead>
<tr>
@ -31,6 +62,9 @@ email
<th>
gender
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -52,7 +86,7 @@ gender
<input id='gender_expanded' type='text' name='gender_expanded' value='{{ params.gender_expanded }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -89,15 +123,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-electors-Electors');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-followupactions-Followupactions.html generated 2018-07-03T23:08:20.078Z by adl.to-selmer-templates.
<!-- File list-followupactions-Followupactions.html generated 2018-07-05T10:14:18.484Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-followupactions-Followupaction'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-followupactions-Followupaction' class='big-link'>
Add a new Followupaction
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-followupactions-Followupactions' class='list' action='{{servlet-context}}/list-followupactions-Followupactions' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='followupactions'>
<thead>
<tr>
@ -31,6 +62,9 @@ notes
<th>
closed
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -52,7 +86,7 @@ closed
<input id='closed' type='text' name='closed' value='{{ params.closed }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -89,15 +123,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-followupactions-Followupactions');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,28 +1,62 @@
{% extends "base.html" %}
<!-- File list-followupmethods-Followupmethods.html generated 2018-07-03T23:08:20.045Z by adl.to-selmer-templates.
<!-- File list-followupmethods-Followupmethods.html generated 2018-07-05T10:14:18.456Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-followupmethods-Followupmethod'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-followupmethods-Followupmethod' class='big-link'>
Add a new Followupmethod
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-followupmethods-Followupmethods' class='list' action='{{servlet-context}}/list-followupmethods-Followupmethods' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='followupmethods'>
<thead>
<tr>
<th>
id
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
<input id='id' type='text' name='id' value='{{ params.id }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -40,15 +74,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-followupmethods-Followupmethods');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-followuprequests-Followuprequests.html generated 2018-07-03T23:08:20.018Z by adl.to-selmer-templates.
<!-- File list-followuprequests-Followuprequests.html generated 2018-07-05T10:14:18.434Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-followuprequests-Followuprequest'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-followuprequests-Followuprequest' class='big-link'>
Add a new Followuprequest
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-followuprequests-Followuprequests' class='list' action='{{servlet-context}}/list-followuprequests-Followuprequests' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='followuprequests'>
<thead>
<tr>
@ -28,6 +59,9 @@ issue_id
<th>
method_id
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -46,7 +80,7 @@ method_id
<input id='method_id_expanded' type='text' name='method_id_expanded' value='{{ params.method_id_expanded }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -84,15 +118,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-followuprequests-Followuprequests');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,28 +1,62 @@
{% extends "base.html" %}
<!-- File list-genders-Genders.html generated 2018-07-03T23:08:20.008Z by adl.to-selmer-templates.
<!-- File list-genders-Genders.html generated 2018-07-05T10:14:18.428Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-genders-Gender'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-genders-Gender' class='big-link'>
Add a new Gender
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-genders-Genders' class='list' action='{{servlet-context}}/list-genders-Genders' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='genders'>
<thead>
<tr>
<th>
id
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
<input id='id' type='text' name='id' value='{{ params.id }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -40,15 +74,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-genders-Genders');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-intentions-Intentions.html generated 2018-07-03T23:08:20.083Z by adl.to-selmer-templates.
<!-- File list-intentions-Intentions.html generated 2018-07-05T10:14:18.487Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-intentions-Intention'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-intentions-Intention' class='big-link'>
Add a new Intention
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-intentions-Intentions' class='list' action='{{servlet-context}}/list-intentions-Intentions' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='intentions'>
<thead>
<tr>
@ -25,6 +56,9 @@ option_id
<th>
locality
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -40,7 +74,7 @@ locality
<input id='locality' type='number' name='locality' value='{{ params.locality }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -73,15 +107,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-intentions-Intentions');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-issues-Issues.html generated 2018-07-03T23:08:20.073Z by adl.to-selmer-templates.
<!-- File list-issues-Issues.html generated 2018-07-05T10:14:18.480Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-issues-Issue'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof issueeditors admin %}
<div class='big-link-container'>
<a href='form-issues-Issue' class='big-link'>
Add a new Issue
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-issues-Issues' class='list' action='{{servlet-context}}/list-issues-Issues' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='issues'>
<thead>
<tr>
@ -25,6 +56,9 @@ current
<th>
brief
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -40,7 +74,7 @@ brief
<input id='brief' type='text' name='brief' value='{{ params.brief }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -67,15 +101,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-issues-Issues');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,28 +1,62 @@
{% extends "base.html" %}
<!-- File list-options-Options.html generated 2018-07-03T23:08:20.020Z by adl.to-selmer-templates.
<!-- File list-options-Options.html generated 2018-07-05T10:14:18.435Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-options-Option'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-options-Option' class='big-link'>
Add a new Option
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-options-Options' class='list' action='{{servlet-context}}/list-options-Options' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='options'>
<thead>
<tr>
<th>
id
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
<input id='id' type='text' name='id' value='{{ params.id }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -40,15 +74,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-options-Options');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-roles-Roles.html generated 2018-07-03T23:08:20.044Z by adl.to-selmer-templates.
<!-- File list-roles-Roles.html generated 2018-07-05T10:14:18.456Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-roles-Role'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-roles-Role' class='big-link'>
Add a new Role
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-roles-Roles' class='list' action='{{servlet-context}}/list-roles-Roles' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='roles'>
<thead>
<tr>
@ -19,6 +50,9 @@ id
<th>
name
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -28,7 +62,7 @@ name
<input id='name' type='text' name='name' value='{{ params.name }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -49,15 +83,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-roles-Roles');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-teams-Teams.html generated 2018-07-03T23:08:20.012Z by adl.to-selmer-templates.
<!-- File list-teams-Teams.html generated 2018-07-05T10:14:18.431Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-teams-Team'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<div class='big-link-container'>
<a href='form-teams-Team' class='big-link'>
Add a new Team
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-teams-Teams' class='list' action='{{servlet-context}}/list-teams-Teams' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='teams'>
<thead>
<tr>
@ -28,6 +59,9 @@ latitude
<th>
longitude
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -46,7 +80,7 @@ longitude
<input id='longitude' type='number' name='longitude' value='{{ params.longitude }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -78,15 +112,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-teams-Teams');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}

View file

@ -1,15 +1,46 @@
{% extends "base.html" %}
<!-- File list-visits-Visits.html generated 2018-07-03T23:08:20.010Z by adl.to-selmer-templates.
<!-- File list-visits-Visits.html generated 2018-07-05T10:14:18.430Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<form id='content' class='list'>
{% block back-links %}
<div>
<div class='back-link-container'>
{% ifequal params.offset "0" %}
<a id='back-link' class='back-link' href='{{servlet-context}}/admin'>
Back
</a>
{% else %}
<a id='prev-selector' class='back-link'>
Previous
</a>
{% endifunequal %}
</div>
</div>
{% endblock %}
{% block big-links %}
<div>
<div class='big-link-container'>
<a href='form-visits-Visit'>
<a id='next-selector' role='button' class='big-link'>
Next
</a>
</div>
{% ifmemberof admin %}
<div class='big-link-container'>
<a href='form-visits-Visit' class='big-link'>
Add a new Visit
</a>
</div>
{% endifmemberof %}
</div>
{% endblock %}
{% block content %}
<form id='list-visits-Visits' class='list' action='{{servlet-context}}/list-visits-Visits' method='POST'>
{% csrf-field %}
<input id='offset' type='hidden' value='{{params.offset|default:0}}'/>
<input id='limit' type='hidden' value='{{params.limit|default:50}}'/>
<table caption='visits'>
<thead>
<tr>
@ -25,6 +56,9 @@ canvasser_id
<th>
date
</th>
<th>
&nbsp;
</th>
</tr>
<tr>
<th>
@ -40,7 +74,7 @@ date
<input id='date' type='date' name='date' value='{{ params.date }}'/>
</th>
<th>
<input type='submit' id='search' value='Search'/>
<input type='submit' id='search-widget' value='Search'/>
</th>
</tr>
</thead>
@ -71,15 +105,30 @@ View
</tr>
{% endfor %}
</tbody>
<tfoot>
<div class='back-link-container'>
<input id='page' name='page' disabled='{% ifequal offset 0 %} false {% else %} true {% endifequal %}' value='Previous'/>
</div>
<div class='big-link-container'>
<input id='page' name='page' disabled='false' value='Next'/>
</div>
</tfoot>
</table>
</form>
{% endblock %}
{% block extra-script %}
var form = document.getElementById('list-visits-Visits');
var ow = document.getElementById('offset');
var lw = document.getElementById('limit');
form.addEventListener('submit', function() {
ow.value='0';
});
{% ifunequal params.offset "0" %}
document.getElementById('prev-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)-parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endifunequal %}
document.getElementById('next-selector').addEventListener('click', function () {
ow.value=(parseInt(ow.value)+parseInt(lw.value));
console.log('Updated offset to ' + ow.value);
form.submit();
});
{% endblock %}