youyesyet/resources/templates/auto/form-teams-Team.html
Simon Brooke 3a49e50a51 Now actually pulling data from server, but some regressions.
The map isn't rendering, and there's something wrong with options. But a lot is working.
2018-07-03 20:16:38 +01:00

167 lines
6.3 KiB
HTML

{% extends "base.html" %}
<!-- File form-teams-Team.html generated 2018-07-03T12:23:51.915Z by adl.to-selmer-templates.
See [Application Description Language](https://github.com/simon-brooke/adl).-->
{% block content %}
<div id='content' class='edit'>
<form action='{{servlet-context}}/form-teams-Team' method='POST'>
{% csrf-field %}
<p class='widget'>
<label for='id'>
id
</label>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<input id='id' name='id' type='text' value='{{record.id}}' maxlength='' size='16'/>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='id' name='id' class='pseudo-widget disabled'>
{{record.id}}
</span>
{% else %}
<span id='id' name='id' class='pseudo-widget not-authorised'>
You are not permitted to view id of teams
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='name'>
name
</label>
{% ifmemberof teamorganisers admin teamorganisers admin %}
<input id='name' name='name' type='text' value='{{record.name}}' maxlength='64' size='60'/>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='name' name='name' class='pseudo-widget disabled'>
{{record.name}}
</span>
{% else %}
<span id='name' name='name' class='pseudo-widget not-authorised'>
You are not permitted to view name of teams
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='district_id'>
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'>
{% for record in districts %}<option value='{{record.id}}'>{{record.name}}</option>{% endfor %}
</select>
</div>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='district_id' name='district_id' class='pseudo-widget disabled'>
{{record.district_id}}
</span>
{% else %}
<span id='district_id' name='district_id' class='pseudo-widget not-authorised'>
You are not permitted to view district_id of teams
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='latitude'>
latitude
</label>
{% 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 %}
<span id='latitude' name='latitude' class='pseudo-widget disabled'>
{{record.latitude}}
</span>
{% else %}
<span id='latitude' name='latitude' class='pseudo-widget not-authorised'>
You are not permitted to view latitude of teams
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='members'>
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'>
{% for record in canvassers %}<option value='{{record.id}}'>{{record.username}} {{record.fullname}} {{record.address_id}} {{record.phone}} {{record.email}}</option>{% endfor %}
</select>
</div>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='members' name='members' class='pseudo-widget disabled'>
{{record.members}}
</span>
{% else %}
<span id='members' name='members' class='pseudo-widget not-authorised'>
You are not permitted to view members of teams
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='organisers'>
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'>
{% for record in canvassers %}<option value='{{record.id}}'>{{record.username}} {{record.fullname}} {{record.address_id}} {{record.phone}} {{record.email}}</option>{% endfor %}
</select>
</div>
{% else %}
{% ifmemberof canvassers teamorganisers issueexperts analysts issueeditors admin canvassers teamorganisers issueexperts analysts issueeditors admin %}
<span id='organisers' name='organisers' class='pseudo-widget disabled'>
{{record.organisers}}
</span>
{% else %}
<span id='organisers' name='organisers' class='pseudo-widget not-authorised'>
You are not permitted to view organisers of teams
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<p class='widget'>
<label for='longitude'>
longitude
</label>
{% 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 %}
<span id='longitude' name='longitude' class='pseudo-widget disabled'>
{{record.longitude}}
</span>
{% else %}
<span id='longitude' name='longitude' class='pseudo-widget not-authorised'>
You are not permitted to view longitude of teams
</span>
{% endifmemberof %}
{% endifmemberof %}
</p>
<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>
<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>
</form>
</div>
{% endblock %}