aboutsummaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
Diffstat (limited to 'templates')
-rw-r--r--templates/email/zurich/problem-wish.txt26
-rw-r--r--templates/email/zurich/submit-external-personal.txt2
-rw-r--r--templates/email/zurich/submit-external-wish.txt22
-rw-r--r--templates/email/zurich/submit-external.txt2
-rw-r--r--templates/web/zurich/admin/report_edit-sdm.html1
-rw-r--r--templates/web/zurich/admin/report_edit.html192
6 files changed, 150 insertions, 95 deletions
diff --git a/templates/email/zurich/problem-wish.txt b/templates/email/zurich/problem-wish.txt
new file mode 100644
index 000000000..09cc9c7ca
--- /dev/null
+++ b/templates/email/zurich/problem-wish.txt
@@ -0,0 +1,26 @@
+Subject: Züri wie neu: Meldung #[% problem.id %]
+
+Grüezi [% problem.name %]
+
+Besten Dank für Ihre Meldung auf <<Züri wie neu>>. Wir haben Ihr Anliegen an [% problem.body(c).name %]
+weitergeleitet, da es nicht in den Zuständigkeitsbereich der beteiligten Fachbereiche fällt.
+
+Unter:
+ [% url %]
+finden Sie Ihre Meldung auf der Website.
+
+
+Ihre Meldung lautet:
+
+[% problem.detail %]
+
+
+
+Freundliche Grüsse
+
+Ihre Stadt Zürich
+
+
+
+Dieses E-Mail wurde automatisch generiert. Bitte antworten Sie nicht darauf.
+
diff --git a/templates/email/zurich/submit-external-personal.txt b/templates/email/zurich/submit-external-personal.txt
index 5e0823871..2d4fce606 100644
--- a/templates/email/zurich/submit-external-personal.txt
+++ b/templates/email/zurich/submit-external-personal.txt
@@ -6,6 +6,8 @@ Die folgende Meldung wurde auf http://www.stadt-zuerich.ch/zueriwieneu erfasst:
Öffentliche URL: <?=$values['url']?>
+<?=$values['external_message']?>
+
Name des Meldenden: <?=$values['name']?>
Email des Meldenden: <?=$values['email']?>
diff --git a/templates/email/zurich/submit-external-wish.txt b/templates/email/zurich/submit-external-wish.txt
new file mode 100644
index 000000000..8a6dc34dd
--- /dev/null
+++ b/templates/email/zurich/submit-external-wish.txt
@@ -0,0 +1,22 @@
+Subject: Züri wie neu: Weitergeleitete Meldung #<?=$values['id']?>
+
+Grüezi <?=$values['bodies_name']?>,
+
+Die folgende Meldung wurde auf http://www.stadt-zuerich.ch/zueriwieneu erfasst:
+
+Öffentliche URL: <?=$values['url']?>
+
+<?=$values['external_message']?>
+
+"Züri wie neu" ist eine Dienstleistung der Stadt Zürich zum Thema
+Bürgerbeteiligung. Auf dieser Plattform kann die Bevölkerung auf Schäden und
+Mängel an der städtischen Infrastruktur hinweisen.
+Diese Meldung wurde Ihnen von der Stadt Zürich gesendet, da es Ihr
+Zuständigkeitsgebiet betreffen könnte.
+
+Bei Fragen zu "Züri wie neu" wenden Sie sich bitte an gis-zentrum@zuerich.ch.
+
+
+Freundliche Grüsse
+
+Ihre Stadt Zürich
diff --git a/templates/email/zurich/submit-external.txt b/templates/email/zurich/submit-external.txt
index bf409dccc..8a6dc34dd 100644
--- a/templates/email/zurich/submit-external.txt
+++ b/templates/email/zurich/submit-external.txt
@@ -6,6 +6,8 @@ Die folgende Meldung wurde auf http://www.stadt-zuerich.ch/zueriwieneu erfasst:
Öffentliche URL: <?=$values['url']?>
+<?=$values['external_message']?>
+
"Züri wie neu" ist eine Dienstleistung der Stadt Zürich zum Thema
Bürgerbeteiligung. Auf dieser Plattform kann die Bevölkerung auf Schäden und
Mängel an der städtischen Infrastruktur hinweisen.
diff --git a/templates/web/zurich/admin/report_edit-sdm.html b/templates/web/zurich/admin/report_edit-sdm.html
index 6e952022a..7f8a0d74f 100644
--- a/templates/web/zurich/admin/report_edit-sdm.html
+++ b/templates/web/zurich/admin/report_edit-sdm.html
@@ -16,6 +16,7 @@
<input type="hidden" name="submit" value="1" >
<p align="right"><input type="submit" name="send_back" value="[% loc('Not for my subdivision') %]"></p>
+<p align="right"><input type="submit" name="not_contactable" value="[% loc('Customer not contactable') %]"></p>
<ul class="no-bullets">
<li><a href="[% c.uri_for_email( '/report', problem.id ) %]">[% loc('View report on site' )%]</a></li>
diff --git a/templates/web/zurich/admin/report_edit.html b/templates/web/zurich/admin/report_edit.html
index 1bf7c2a5c..19a076435 100644
--- a/templates/web/zurich/admin/report_edit.html
+++ b/templates/web/zurich/admin/report_edit.html
@@ -91,28 +91,10 @@
[% END %]
</ul>
-<p><label for="new_internal_note">[% loc('New internal note:') %]</label>
-<textarea name='new_internal_note' id='new_internal_note' cols=60 rows=5>[% new_internal_note | html %]</textarea></p>
-
<p><span class="mock-label">[% loc('State:') %]</span> <select name="state" id="state">
<option value="">--</option>
- [% FOREACH s IN [
- ['unconfirmed', loc('Submitted')]
- ['confirmed', loc('Open')],
- ['planned', loc('Planned')],
- ['hidden', loc('Hidden')],
- ['investigating', loc('Wish')],
- ['partial', loc('Not contactable')],
- ['unable to fix', loc('Jurisdiction unknown')],
- ] %]
- <option [% 'selected ' IF s.0 == problem.state %] value="[% s.0 %]">[% s.1 %]</option>
- [% END %]
- [% IF problem.state == 'closed' %]
- <option selected value="closed">[% loc('Extern') %]</option>
- [% ELSIF problem.state == 'fixed - council' %]
- <option selected value="fixed - council">[% loc('Closed') %]</option>
- [% ELSIF problem.state == 'in progress' %]
- <option selected value="in progress">[% loc('In progress') %]</option>
+ [% FOREACH s IN states %]
+ <option [% 'selected ' IF s.state == problem.state %] value="[% s.state %]">[% s.trans %]</option>
[% END %]
</select></p>
@@ -123,113 +105,133 @@
<script type="text/javascript">
$(function(){
- // Show or hide the automatic reply field
+
+ $('.assignation select').change(function(){
+ if (this.value == "") {
+ $('.assignation').css('color', '#000');
+ } else {
+ var a = $(this).closest('li').css('color', '#000');
+ $('.assignation select').not(this).val("");
+ $('.assignation').not(a).css('color', '#999');
+ }
+ });
+
$('#state').change(function(){
- if ($(this).val() === 'hidden') {
+ // Show or hide the automatic reply field
+ var state = $(this).val();
+ if (state === 'hidden') {
$('#automatic-reply').show();
} else {
$('#automatic-reply').hide();
}
+
+ // Show or hide the categories
+ if (state === 'confirmed') {
+ $('#assignation__category').show();
+ $('#assignation__subdivision').show();
+ } else {
+ $('#assignation__category').hide();
+ $('#assignation__subdivision').hide();
+ $('#assignation__category select').val('');
+ $('#assignation__subdivision select').val('');
+ }
+
+ if ((state === 'closed') || (state === 'investigating')) {
+ $('#assignation__external').show();
+ } else {
+ $('#assignation__external select').val('');
+ $('#assignation__external').hide();
+ }
+
}).change();
});
</script>
-[% IF problem.state == 'unconfirmed' OR problem.state == 'confirmed' %]
-
<ul class="no-bullets">
-[% list = FOR body IN bodies %]
- [%- NEXT UNLESS body.parent.id == c.user.from_body.id %]
- <option value="[% body.id %]"[% IF body.id == problem.bodies_str %] selected[% END %]>[% body.name %]</option>
-[% END %]
- [% IF admin_type != 'super' AND list %]
- <li class="assignation">
- <label for="body_subdivision">[% loc('Assign to subdivision:') %]</label>
- <select name="body_subdivision" id="body_subdivision">
- <option value="">--</option>
- [% list %]
- </select>
- </li>
- [% END %]
+[% IF problem.state == 'confirmed' %]
<li class="assignation">
<label for="category">
[% loc('Category:') %] [% problem.category %]<br>
-[% loc('Assign to different category:') %]</label>
- <select name="category" id="category">
- <option value="">--</option>
- [% FOREACH cat IN categories %]
- <option value="[% cat %]">[% cat %]</option>
- [% END %]
- </select></li>
-<li class="assignation">
-<label for="body_external">[% loc('Assign to external body:') %]</label>
- <select name="body_external" id="body_external">
- <option value="">--</option>
- [% FOR body IN bodies %]
- [% NEXT IF body.parent OR body.bodies OR body.deleted %]
- <option value="[% body.id %]"[% IF body.id == problem.bodies_str %] selected[% END %]>[% body.name %]</option>
- [% END %]
+ <div id="assignation__category">
+ [% loc('Assign to different category:') %]</label>
+ <select name="category" id="category">
+ <option value="">--</option>
+ [% FOREACH cat IN categories %]
+ <option value="[% cat %]">[% cat %]</option>
+ [% END %]
</select>
- <br>
- <input type="checkbox" name="third_personal" id="third_personal" value="1"[% ' checked' IF problem.extra.third_personal %]>
- <label for="third_personal" class="inline">[% loc('Include reporter personal details') %]</label>
-
-</ul>
-
-<script type="text/javascript">
-$(function(){
- $('.assignation select').change(function(){
- if (this.value == "") {
- $('.assignation').css('color', '#000');
- } else {
- var a = $(this).closest('li').css('color', '#000');
- $('.assignation select').not(this).val("");
- $('.assignation').not(a).css('color', '#999');
- }
- });
-});
-</script>
-
-[% ELSIF problem.state == 'planned' %]
+ </div>
+</li>
-<ul class="no-bullets">
[% list = FOR body IN bodies %]
[%- NEXT UNLESS body.parent.id == c.user.from_body.id %]
- <option value="[% body.id %]">[% body.name %]</option>
+ <option value="[% body.id %]"[% IF body.id == problem.bodies_str %] selected[% END %]>[% body.name %]</option>
[% END %]
[% IF admin_type != 'super' AND list %]
- <li class="assignation">
- <label for="body_subdivision">[% loc('Assign to subdivision:') %]</label>
+ <li class="assignation" id="assignation__subdivision">
+ <label for="body_subdivision">[% loc('Assign to subdivision:') %]</label>
<select name="body_subdivision" id="body_subdivision">
- <option value="" selected>--</option>
+ <option value="">--</option>
[% list %]
</select>
</li>
[% END %]
- <li><label for="status_update">[% loc('Public response:') %]</label>
- [% INCLUDE 'admin/response_templates_select.html' for='status_update' %]
- <textarea name='status_update' id='status_update' cols=60 rows=5>
- [%- IF problem.extra.public_response -%]
- [%- problem.extra.public_response | html -%]
- [%- ELSE -%]
-
-Freundliche Grüsse
+[% END %]
-Ihre Stadt Zürich
- [%- END %]</textarea>
+[%# 3rd party messages sent for Extern/Wunsch states %]
+[% SWITCH problem.state %]
+ [% CASE ['closed','investigating'] %]
+ <ul class="no-bullets">
+ <li class="assignation" id="assignation__external">
+ <label for="body_external">
+ [% IF problem.state == 'closed' %]
+ [% loc('Assign to external body:') %]
+ [% ELSE %]
+ [% loc('Assign to competent body:') %]
+ [% END %]
+ </label>
+ <select name="body_external" id="body_external">
+ <option value="">--</option>
+ [% FOR body IN bodies %]
+ [% NEXT IF body.parent OR body.bodies OR body.deleted %]
+ <option value="[% body.id %]"[% IF body.id == problem.external_body %] selected[% END %]>[% body.name %]</option>
+ [% END %]
+ </select>
+ <br>
+ [% IF problem.state == 'closed' %]
+ <input type="checkbox" name="third_personal" id="third_personal" value="1"[% ' checked' IF problem.extra.third_personal %]>
+ <label for="third_personal" class="inline">[% loc('Include reporter personal details') %]</label>
+ [% END %]
+ [% INCLUDE 'admin/response_templates_select.html' for='external_body' %]
+ <textarea name='external_message' id='external_body' cols=60 rows=5></textarea>
</li>
-</ul>
-
-[% ELSIF problem.state == 'fixed - council' %]
-
-<p><span class="mock-label">[% loc('Public response:') %]</span>
-[% problem.extra.public_response | html %]
-</p>
+ </ul>
+[% END %]
+[%# Public response field shown for Ruckmeldung ausstehend/Extern/
+ # Zustandigkeit unbekannt/Wunsch/Nicht kontaktierbar/Unsichtbar %]
+[% SWITCH problem.state %]
+ [% CASE ['planned','closed','unable to fix','investigating','partial','hidden'] %]
+ <ul class="no-bullets">
+ <li><label for="status_update">[% loc('Public response:') %]</label>
+ [% INCLUDE 'admin/response_templates_select.html' for='status_update' %]
+ <textarea name='status_update' id='status_update' cols=60 rows=5>
+ [%- problem.extra.public_response || default_public_response | html -%]
+ </textarea>
+ </li>
+ </ul>
+ [% CASE 'fixed - council' %]
+ <p><span class="mock-label">[% loc('Public response:') %]</span>
+ [% problem.extra.public_response | html %]
+ </p>
[% END %]
+<p><label for="new_internal_note">[% loc('New internal note:') %]</label>
+<textarea name='new_internal_note' id='new_internal_note' cols=60 rows=5>[% new_internal_note | html %]</textarea></p>
+
<p>
<label for="time_spent">[% loc('Time spent (in minutes):') %]</label>
<input type="text" name="time_spent" id="form_time_spent" style="width: 4em" value="0">