aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--locale/nb_NO.UTF-8/LC_MESSAGES/FixMyStreet.po41
-rw-r--r--perllib/FixMyStreet/Cobrand/FiksGataMi.pm46
-rw-r--r--templates/web/fiksgatami/about/_sidebar.html15
-rw-r--r--templates/web/fiksgatami/about/faq-nb.html6
-rw-r--r--templates/web/fiksgatami/about/faq-nn.html6
-rw-r--r--templates/web/fiksgatami/front/footer-marketing.html3
6 files changed, 73 insertions, 44 deletions
diff --git a/locale/nb_NO.UTF-8/LC_MESSAGES/FixMyStreet.po b/locale/nb_NO.UTF-8/LC_MESSAGES/FixMyStreet.po
index 31fd59846..66c404d3b 100644
--- a/locale/nb_NO.UTF-8/LC_MESSAGES/FixMyStreet.po
+++ b/locale/nb_NO.UTF-8/LC_MESSAGES/FixMyStreet.po
@@ -15,8 +15,8 @@ msgstr ""
"Project-Id-Version: fixmystreet\n"
"Report-Msgid-Bugs-To: matthew@mysociety.org\n"
"POT-Creation-Date: 2016-05-03 10:41+0100\n"
-"PO-Revision-Date: 2016-03-23 12:44+0000\n"
-"Last-Translator: mySociety <transifex@mysociety.org>\n"
+"PO-Revision-Date: 2016-05-28 21:04+0000\n"
+"Last-Translator: Jan Høydahl <jh@cominvent.com>\n"
"Language-Team: Norwegian Bokmål (Norway) (http://www.transifex.com/mysociety/fixmystreet/language/nb_NO/)\n"
"Language: nb_NO\n"
"MIME-Version: 1.0\n"
@@ -58,7 +58,7 @@ msgstr "%s administrator:"
#: templates/web/base/status/stats.html:26
msgid "%s bodies"
-msgstr ""
+msgstr "%s administrasjoner"
#: templates/web/base/status/stats.html:24
msgid "%s confirmed alerts, %s unconfirmed"
@@ -110,7 +110,7 @@ msgid ""
"will be sent to the district council, so will appear in both of the district\n"
"council&rsquo;s alerts, but will only appear in the \"Within the boundary\" alert\n"
"for the county council."
-msgstr ""
+msgstr "%s sender forskjellige kategorier problemer til rett administrasjon, så problemer innenfor grensene til en gitt administrasjon vil ikke alltid samsvare med problemrapporter sendt til den administrasjonen. For eksempel, en grafitti-rapport vil bli sendt til kommunen, og vil dukke opp på kommunens varsler, men vil kun vises i \"innenfor grensen\" varselet for fylket."
#: perllib/FixMyStreet/Cobrand/UK.pm:256 perllib/FixMyStreet/Cobrand/UK.pm:268
msgid "%s ward, %s"
@@ -340,7 +340,7 @@ msgstr "Er du en utvikler?"
#: templates/web/base/js/translation_strings.html:52
msgid "Are you sure you want to cancel this upload?"
-msgstr ""
+msgstr "Er du sikker på at du vil avbryte opplastingen?"
#: templates/web/base/admin/body-form.html:69
#: templates/web/base/admin/body.html:16
@@ -590,7 +590,7 @@ msgstr "Bekreft konto"
#: templates/web/base/report/new/form_user_loggedout_password.html:21
#: templates/web/base/report/update/form_user_loggedout_password.html:20
msgid "Confirm by email instead, providing a new password at that point. When you confirm, your password will be updated."
-msgstr ""
+msgstr "Bekreft via e-post isteden, ved å oppgi et nytt passord da. Når du bekrefter vil passordet ditt bli oppdatert."
#: templates/web/base/questionnaire/creator_fixed.html:1
#: templates/web/base/tokens/confirm_problem.html:1
@@ -772,7 +772,7 @@ msgstr "Arbeidshester"
#: templates/web/base/report/update-form.html:29
#: templates/web/base/report/update/form_user_loggedout.html:27
msgid "Do you have a %s password?"
-msgstr "Har du et FiksGataMi-passord?"
+msgstr "Har du et %s-passord?"
#: templates/web/base/questionnaire/index.html:55
msgid "Don&rsquo;t know"
@@ -784,7 +784,7 @@ msgstr "Liker ikke skjemaer?"
#: templates/web/base/js/translation_strings.html:51
msgid "Drag and drop photos here or <u>click to upload</u>"
-msgstr ""
+msgstr "Dra og slipp bilder hit eller <u>klikk for å laste opp</u>"
#: templates/web/base/admin/report_blocks.html:1
#: templates/web/base/admin/report_blocks.html:14
@@ -1559,7 +1559,7 @@ msgstr "Nye lokale problemer på FiksGataMi"
#: templates/web/zurich/admin/report_edit-sdm.html:117
msgid "New note to DM:"
-msgstr ""
+msgstr "Nytt notat til DM:"
#: db/alert_types.pl:38
msgid "New problems for {{COUNCIL}} within {{WARD}} ward on FixMyStreet"
@@ -1727,7 +1727,7 @@ msgstr "Note: <strong>%d</strong>"
#: templates/web/zurich/admin/list_updates.html:21
msgid "Notes from SDM to DM"
-msgstr ""
+msgstr "Notater fra SDM til DM"
#: templates/web/base/report/new/form_user_loggedout.html:2
#: templates/web/base/report/new/form_user_loggedout.html:24
@@ -1972,7 +1972,7 @@ msgstr "Vennligst legg til en melding"
#: perllib/FixMyStreet/App/Controller/Admin.pm:1079
#: perllib/FixMyStreet/App/Controller/Admin.pm:1134
msgid "Please enter a name"
-msgstr ""
+msgstr "Vennligst skriv et navn"
#: templates/web/base/auth/change_password.html:12
#: templates/web/base/auth/change_password.html:15
@@ -2081,7 +2081,7 @@ msgstr "Vær oppmerksom på at oppdateringer ikke blir videresendt til administr
#: templates/web/base/report/new/oauth_email_form.html:4
msgid "Please note your report has <strong>not yet been sent</strong>."
-msgstr ""
+msgstr "Merk at din rapport <strong>enda ikke har blitt sendt</strong>."
#: templates/web/base/report/new/fill_in_details_form.html:20
#: templates/web/zurich/report/new/fill_in_details_form.html:11
@@ -2090,7 +2090,7 @@ msgstr "Merk at din rapport <strong>ennå ikke er sendt</strong. Velg en katego
#: templates/web/base/report/display.html:26
msgid "Please note your update has <strong>not yet been posted</strong>."
-msgstr ""
+msgstr "Merk at din oppdatering <strong>enda ikke har blitt sendt</strong>."
#: templates/web/base/report/new/notes.html:1
#: templates/web/zurich/report/new/notes.html:1
@@ -2130,9 +2130,8 @@ msgstr "Vennligs oppgi om dette problemet er blitt fikset eller ikke"
#: perllib/FixMyStreet/App/Model/PhotoSet.pm:150
#: perllib/FixMyStreet/App/Model/PhotoSet.pm:152
#: templates/web/base/js/translation_strings.html:53
-#, fuzzy
msgid "Please upload an image only"
-msgstr "Vennligst last opp kun JPEG-bilder"
+msgstr "Vennligst last opp kun bilder"
#: perllib/FixMyStreet/App/Controller/Contact.pm:115
msgid "Please write a message"
@@ -2601,7 +2600,7 @@ msgstr "Velg et område"
#: templates/web/base/alert/_list.html:10
msgid "Select which type of alert you’d like and click the button for an RSS feed, or enter your email address to subscribe to an email alert."
-msgstr ""
+msgstr "Velg hvilken type varsel du ønsker og klikk på knappen for en RSS-kilde, eller skriv inn din e-postadresse for å abonnere på et e-postvarsel."
#: perllib/FixMyStreet/Cobrand/Zurich.pm:835
msgid "Sent report back"
@@ -2703,7 +2702,7 @@ msgstr "Beklager, vi kunne ikke finne det stedet."
#: templates/web/base/report/display.html:21
#: templates/web/base/report/new/fill_in_details_form.html:23
msgid "Sorry, we could not log you in. Please fill in the form below."
-msgstr ""
+msgstr "Beklager, vi kunne ikke logge deg inn. Vennligst fyll in skjemaet nedenfor."
#: perllib/FixMyStreet/Geocode/Bing.pm:35
#: perllib/FixMyStreet/Geocode/Google.pm:45
@@ -3438,7 +3437,7 @@ msgstr "Vi fant mer en ett treff for den plassen. Vi viser opp til ti treff, sÃ
#: templates/web/base/report/display.html:27
#: templates/web/base/report/new/oauth_email_form.html:5
msgid "We need your email address, please give it below."
-msgstr ""
+msgstr "Vi behøver din epost-adresse, vennligst oppgi den nedenfor."
#: templates/web/base/report/new/form_user_loggedout_email.html:2
#: templates/web/base/report/update/form_user_loggedout_email.html:2
@@ -3490,7 +3489,7 @@ msgstr "NÃ¥r sendt"
#: templates/web/base/js/translation_strings.html:50
msgid "Whoa there Testino! Three photos are enough."
-msgstr ""
+msgstr "Oj oj, brems ned! Tre bilder er nok."
#: templates/web/base/tokens/confirm_alert.html:7
msgid "Why stop there? <a href=\"/alert\">Set up more alerts</a> for free."
@@ -3612,7 +3611,7 @@ msgstr "Du har allerede lagt ved bilder til denne rapporten. Merk at du kan maks
#: templates/web/base/questionnaire/index.html:83
#: templates/web/base/report/update/form_update.html:14
msgid "You have already attached photos to this update. Note that you can attach a maximum of 3 to this update (if you try to upload more, the oldest will be removed)."
-msgstr ""
+msgstr "Du har allerede lagt ved bilder til denne rapporten. Merk at du kan maksimalt legge ved 3 til rapporten (hvis du laster opp flere blir det eldste slettet)."
#: templates/web/base/auth/sign_out.html:4
#: templates/web/zurich/auth/sign_out.html:3
@@ -3712,7 +3711,7 @@ msgstr "Ditt telefonnummer"
#: templates/web/base/questionnaire/index.html:14
msgid "Your report"
-msgstr ""
+msgstr "Din rapport"
#: templates/web/base/footer.html:29
msgid "Your reports"
diff --git a/perllib/FixMyStreet/Cobrand/FiksGataMi.pm b/perllib/FixMyStreet/Cobrand/FiksGataMi.pm
index 7b175f371..57723ffb6 100644
--- a/perllib/FixMyStreet/Cobrand/FiksGataMi.pm
+++ b/perllib/FixMyStreet/Cobrand/FiksGataMi.pm
@@ -28,6 +28,13 @@ sub disambiguate_location {
};
}
+sub pin_colour {
+ my ( $self, $p, $context ) = @_;
+ return 'green' if $p->is_fixed || $p->is_closed;
+ return 'red' if $p->state eq 'unconfirmed' || $p->state eq 'confirmed';
+ return 'yellow';
+}
+
sub area_types {
[ 'NKO', 'NFY', 'NRA' ];
}
@@ -95,13 +102,16 @@ sub remove_redundant_areas {
sub short_name {
my $self = shift;
- my ($area, $info) = @_;
+ my ($body) = @_;
- my $name = $area->{name} || $area->name;
+ my $name = $body->{name} || $body->name;
if ($name =~ /^(Os|Nes|V\xe5ler|Sande|B\xf8|Her\xf8y)$/) {
- my $parent = $info->{$area->{parent_area}}->{name};
- return URI::Escape::uri_escape_utf8("$name, $parent");
+ my $area_id = $body->body_areas->first->area_id || $body->{id} || $body->id;
+ my $area = mySociety::MaPit::call('area', $area_id);
+ my $parent = mySociety::MaPit::call('area', $area->{parent_area});
+
+ $name .= ", " . $parent->{name};
}
$name =~ s/ & / and /;
@@ -127,7 +137,7 @@ sub council_rss_alert_options {
}
if ( $fylke->{id} == 3 ) { # Oslo
- my $short_name = $self->short_name($fylke, $all_councils);
+ my $short_name = $self->short_name($fylke);
( my $id_name = $short_name ) =~ tr/+/_/;
push @options,
@@ -141,10 +151,10 @@ sub council_rss_alert_options {
};
}
else {
- my $short_kommune_name = $self->short_name($kommune, $all_councils);
+ my $short_kommune_name = $self->short_name($kommune);
( my $id_kommune_name = $short_kommune_name ) =~ tr/+/_/;
- my $short_fylke_name = $self->short_name($fylke, $all_councils);
+ my $short_fylke_name = $self->short_name($fylke);
( my $id_fylke_name = $short_fylke_name ) =~ tr/+/_/;
push @options,
@@ -193,34 +203,38 @@ sub council_rss_alert_options {
}
sub reports_body_check {
- my ( $self, $c, $council ) = @_;
-
- if ($council eq 'Oslo') {
+ my ( $self, $c, $code ) = @_;
+ if ($code eq 'Oslo') {
# There are two Oslos (kommune and fylke), we only want one of them.
- $c->stash->{council} = mySociety::MaPit::call('area', 3);
+ my @bodies = $c->model('DB::Body')->search( { id => 3 } )->all;
+ $c->stash->{body} = $bodies[0];
return 1;
+ }
- } elsif ($council =~ /,/) {
-
+ if ($code =~ /,/) {
# Some kommunes have the same name, use the fylke name to work out which.
- my ($kommune, $fylke) = split /\s*,\s*/, $council;
+ my ($kommune, $fylke) = split /\s*,\s*/, $code;
my $area_types = $c->cobrand->area_types;
my $areas_k = mySociety::MaPit::call('areas', $kommune, type => $area_types);
my $areas_f = mySociety::MaPit::call('areas', $fylke, type => $area_types);
+
if (keys %$areas_f == 1) {
($fylke) = values %$areas_f;
foreach (values %$areas_k) {
if ($_->{name} eq $kommune && $_->{parent_area} == $fylke->{id}) {
- $c->stash->{council} = $_;
+ my @bodies = $c->model('DB::Body')->search( { id => $_->{id} } )->all;
+ $c->stash->{body} = $bodies[0];
return 1;
}
}
}
+
# If we're here, we've been given a bad name.
$c->detach( 'redirect_index' );
-
}
+
+ return;
}
sub jurisdiction_id_example {
diff --git a/templates/web/fiksgatami/about/_sidebar.html b/templates/web/fiksgatami/about/_sidebar.html
new file mode 100644
index 000000000..0a21454f5
--- /dev/null
+++ b/templates/web/fiksgatami/about/_sidebar.html
@@ -0,0 +1,15 @@
+<div class="sticky-sidebar">
+ <aside>
+ <ul class="plain-list">
+ <li>[% INCLUDE link h='/faq' t=loc('Frequently Asked Questions') %]</li>
+ <!-- <li>[% INCLUDE link h='/privacy' t=loc('Privacy and cookies') %]</li> -->
+ <li>[% INCLUDE link h='/contact' t=tprintf(loc("Contact %s", "%s is the site name"), site_name) %]</li>
+ </ul>
+ </aside>
+</div>
+
+[% BLOCK link -%]
+<[% IF c.req.uri.path == h %]strong[% ELSE %]a href="[% h %]"[% END %]>
+[%- t -%]
+</[% IF c.req.uri.path == h %]strong[% ELSE %]a[% END %]>
+[%- END %]
diff --git a/templates/web/fiksgatami/about/faq-nb.html b/templates/web/fiksgatami/about/faq-nb.html
index da35cb03c..3ce0ef12e 100644
--- a/templates/web/fiksgatami/about/faq-nb.html
+++ b/templates/web/fiksgatami/about/faq-nb.html
@@ -1,4 +1,6 @@
-[% INCLUDE 'header.html', title => loc('Frequently Asked Questions') %]
+[% INCLUDE 'header.html', title => loc('Frequently Asked Questions'), bodyclass = 'twothirdswidthpage' %]
+
+[% INCLUDE 'about/_sidebar.html' %]
<h1>Ofte stilte spørsmål</h1>
<dl>
@@ -159,4 +161,4 @@
</dl>
-[% INCLUDE 'footer.html' %]
+[% INCLUDE 'footer.html', pagefooter = 'yes' %]
diff --git a/templates/web/fiksgatami/about/faq-nn.html b/templates/web/fiksgatami/about/faq-nn.html
index 161cfbea5..df7ff5e40 100644
--- a/templates/web/fiksgatami/about/faq-nn.html
+++ b/templates/web/fiksgatami/about/faq-nn.html
@@ -1,4 +1,6 @@
-[% INCLUDE 'header.html', title => loc('Frequently Asked Questions') %]
+[% INCLUDE 'header.html', title => loc('Frequently Asked Questions'), bodyclass = 'twothirdswidthpage' %]
+
+[% INCLUDE 'about/_sidebar.html' %]
<h1>Ofte stilte spurnader</h1>
<dl>
@@ -160,4 +162,4 @@
</dl>
-[% INCLUDE 'footer.html' %]
+[% INCLUDE 'footer.html', pagefooter = 'yes' %]
diff --git a/templates/web/fiksgatami/front/footer-marketing.html b/templates/web/fiksgatami/front/footer-marketing.html
index 6069c8793..da59fe6e6 100644
--- a/templates/web/fiksgatami/front/footer-marketing.html
+++ b/templates/web/fiksgatami/front/footer-marketing.html
@@ -1,8 +1,5 @@
<div class="tablewrapper bordered">
<div id="footer-mobileapps">
- <p>
- <a href="http://wiki.nuug.no/grupper/fiksgatami/android">Last ned FiksGataMi-app for din Android-telefon.</a>
- </p>
</div>
<div id="footer-help">