Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add admin back door to get localized field entry for an entry

  • Loading branch information...
commit 473baf7369ce79996f642e0a9844260706cb30f1 1 parent 4762958
@autarch autarch authored
Showing with 6 additions and 2 deletions.
  1. +6 −2 share/mason/lib/form/entry.mas
View
8 share/mason/lib/form/entry.mas
@@ -61,7 +61,7 @@
</fieldset>
-% if ( $c->client()->localize_for_location($location) ) {
+% if ($client_wants_localized_fields) {
<fieldset>
<legend>Basic Info in <% $location->locale()->language_name() | h %></legend>
@@ -146,7 +146,7 @@
</fieldset>
-% if ( $c->client()->localize_for_location($location) && $location->locale()->requires_localized_addresses() ) {
+% if ( $client_wants_localized_fields && $location->locale()->requires_localized_addresses() ) {
<fieldset>
<legend><% $location->locale()->language_name() | h %> Address</legend>
@@ -328,6 +328,10 @@ else
{
$uri = region_uri( location => $location );
}
+
+my $client_wants_localized_fields
+ = $c->client()->localize_for_location($location)
+ || ( $c->vg_user()->is_admin() && $c->request()->params()->{localize} );
</%init>
<%def .categories>
Please sign in to comment.
Something went wrong with that request. Please try again.