diff options
-rw-r--r-- | templates/web/fixmybarangay/alert/_list.html | 45 | ||||
-rw-r--r-- | templates/web/fixmybarangay/alert/index.html | 32 |
2 files changed, 63 insertions, 14 deletions
diff --git a/templates/web/fixmybarangay/alert/_list.html b/templates/web/fixmybarangay/alert/_list.html new file mode 100644 index 000000000..8491b4562 --- /dev/null +++ b/templates/web/fixmybarangay/alert/_list.html @@ -0,0 +1,45 @@ + <input type="hidden" name="type" value="local"> + <input type="hidden" name="pc" value="[% pc | html %]"> + + + <p> + [% loc("Subscribe to an alert based upon what baranagay you’re in:") %] + </p> + + [% INCLUDE 'errors.html' %] + + <div id="rss_list"> + <p><strong> + [% loc('Problems within the boundary of:') %] + </strong></p> + <ul class="plain-list"> + + [% FOREACH option IN options %] + <li[% IF ! (loop.count % 2) %] class="a"[% END %]> + <input type="radio" name="feed" id="[% option.id %]" value="[% option.id %]"[% IF option.id == selected_feed %] checked[% END %]> + <label class="inline" for="[% option.id %]">[% option.text %]</label> + <a href="[% option.uri %]"><img src="/i/feed.png" width="16" height="16" +title="[% option.rss_text %]" alt="RSS feed" border="0"></a> + </li> + [% END %] +</ul> + + <p> + <input type="submit" name="rss" value="[% loc('Give me an RSS feed') %]"> + <p> + + <p id="alert_or"> + [% loc('or') %] + </p> + + [% UNLESS c.user_exists %] + <p> + [% loc('Your email:') %] <input type="text" id="rznvy" name="rznvy" value="[% rznvy | html %]" size="30"> + </p> + [% END %] + + <p> + <input type="submit" name="alert" value="[% loc('Subscribe me to an email alert') %]"> + </p> + </div> <!-- ???? --> + diff --git a/templates/web/fixmybarangay/alert/index.html b/templates/web/fixmybarangay/alert/index.html index dbf3e7c22..d9bb74ee9 100644 --- a/templates/web/fixmybarangay/alert/index.html +++ b/templates/web/fixmybarangay/alert/index.html @@ -3,9 +3,7 @@ <h1>[% loc('Local RSS feeds and email alerts') %]</h1> <p> -FixMyBarangay has a variety of RSS feeds and email alerts for local problems, including -alerts for all problems within a particular ward, or all problems -within a certain distance of a particular location. +FixMyBarangay has a RSS feeds and email alerts for local problems. </p> [% IF location_error %] @@ -14,17 +12,19 @@ within a certain distance of a particular location. [% INCLUDE 'errors.html' %] [% END %] -<p> -[% loc('To find out what local alerts we have for you, please enter your postcode or street name and area' ) %] -</p> -<form method="get" action="/alert/list" class="full-width"> - <fieldset> - <div class="form-txt-submit-box"> - <input type="text" name="pc" value="[% pc | html %]" placeholder="[% tprintf(loc('e.g. ā%sā or ā%sā'), c.cobrand.example_places) %]"> - <input class="green-btn" type="submit" value="[% loc('Go') %]"> - </div> - </fieldset> -</form> +[% options = [ { + id => 'council:1:Luz', + text => 'Luz', + uri => '/rss/reports/Luz' + }, + { + id => 'council:2:Basak_San_Nicolas', + text => 'Basak San Nicolas' + uri => '/rss/reports/Basak+San_Nicolas' + } ]; +%] + +<form id="alerts" name="alerts" method="post" action="/alert/subscribe"> [% IF photos.size %] <div class="sticky-sidebar" id="alert_recent"> @@ -38,4 +38,8 @@ within a certain distance of a particular location. </div> [% END %] +[% INCLUDE 'alert/_list.html' %] + +</form> + [% INCLUDE 'footer.html' %] |