[Rt-commit] r14504 - in rt/branches/3.999-DANGEROUS: share/html/Install share/html/Install/Elements

sunnavy at bestpractical.com sunnavy at bestpractical.com
Fri Jul 25 04:24:19 EDT 2008


Author: sunnavy
Date: Fri Jul 25 04:24:19 2008
New Revision: 14504

Modified:
   rt/branches/3.999-DANGEROUS/   (props changed)
   rt/branches/3.999-DANGEROUS/share/html/Install/Basics.html
   rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseDetails.html
   rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseType.html
   rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Errors
   rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Wrapper
   rt/branches/3.999-DANGEROUS/share/html/Install/Finish.html
   rt/branches/3.999-DANGEROUS/share/html/Install/Global.html
   rt/branches/3.999-DANGEROUS/share/html/Install/Initialize.html
   rt/branches/3.999-DANGEROUS/share/html/Install/Sendmail.html
   rt/branches/3.999-DANGEROUS/share/html/Install/autohandler
   rt/branches/3.999-DANGEROUS/share/html/Install/index.html

Log:
 r14964 at sunnavys-mb:  sunnavy | 2008-07-25 15:53:52 +0800
 fix for share/html/Install


Modified: rt/branches/3.999-DANGEROUS/share/html/Install/Basics.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/Basics.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/Basics.html	Fri Jul 25 04:24:19 2008
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&| Elements/Wrapper, Title => loc('Step %1 of %2: ', 3, 7) . loc('Customize Basics') &> 
+<&| Elements/Wrapper, Title => _('Step %1 of %2: ', 3, 7) . _('Customize Basics') &> 
 
 <& Elements/Errors, Errors => \@errors &>
 
@@ -58,7 +58,7 @@
     CurrentValue => RT::Installer->current_values(@Types) &>
 
 <input type="hidden" name="Run" value="1">
-<& /Elements/Submit, Label => loc('Next: ') . loc('Customize Email Configuration'),Back => 1, BackLabel => loc('Back: ' ) . loc( 'Customize Database Details') &>
+<& /Elements/Submit, Label => _('Next: ') . _('Customize Email Configuration'),Back => 1, BackLabel => _('Back: ' ) . _( 'Customize Database Details') &>
 </form>
 </&>
 
@@ -75,11 +75,11 @@
             Meta => $RT::Installer->{Meta} );
     
     if ( $ARGS{WebPort} && $ARGS{WebPort} !~ /^\d+$/ ) {
-        push @errors, loc("Invalid %1: it should be a number", 'WebPort');
+        push @errors, _("Invalid %1: it should be a number", 'WebPort');
     }
 
     unless ( $ARGS{Password} ) {
-        push @errors, loc("You must enter an Administrative password");
+        push @errors, _("You must enter an Administrative password");
     }
 
     if ( $Back ) {

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseDetails.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseDetails.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseDetails.html	Fri Jul 25 04:24:19 2008
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&| Elements/Wrapper, Title => loc('Step %1 of %2: ', 2, 7 ) . loc('Check your database credentials') &> 
+<&| Elements/Wrapper, Title => _('Step %1 of %2: ', 2, 7 ) . _('Check your database credentials') &> 
 
 % if ( @errors ) {
 <& Elements/Errors, Errors => \@errors &>
@@ -79,12 +79,12 @@
 <input type="hidden" name="Run" value="1">
 
 % if ( @results && !@errors ) {
-<& /Elements/Submit, Label => loc('Next: ') . loc('Customize Basics'),
-Back => 1, BackLabel => loc('Back: ') . loc('Select Database Type'),
+<& /Elements/Submit, Label => _('Next: ') . _('Customize Basics'),
+Back => 1, BackLabel => _('Back: ') . _('Select Database Type'),
 Name => 'Next' &>
 % } else {
-<& /Elements/Submit, Label => loc('Check Database Connectivity'),
-Back => 1, BackLabel => loc('Back: ') . loc('Select Database Type')
+<& /Elements/Submit, Label => _('Check Database Connectivity'),
+Back => 1, BackLabel => _('Back: ') . _('Select Database Type')
 &>
 % }
 
@@ -133,7 +133,7 @@
         );
     
         if ( $dbh ) {
-            push @results, loc('Connection succeeded');
+            push @results, _('Connection succeeded');
             # dba connect dsn, which has table info
             $dbh = DBI->connect(
                 RT::Handle->DSN, $ARGS{DatabaseAdmin}, $ARGS{DatabaseAdminPassword}, { RaiseError => 0, PrintError => 0 },
@@ -158,16 +158,16 @@
                     $sth->execute('RT_System'); 
                     if ( $sth->fetchrow_array ) {
                         $RT::Installer->{DatabaseAction} = 'none';
-                        push @results, loc("%1 appears to be fully initialized.  We won't need to create any tables or insert metadata, but you can continue to customez RT by clicking 'Customize Basics' below", $RT::DatabaseName);
+                        push @results, _("%1 appears to be fully initialized.  We won't need to create any tables or insert metadata, but you can continue to customez RT by clicking 'Customize Basics' below", $RT::DatabaseName);
                     }
                     else {
                         $RT::Installer->{DatabaseAction} = 'acl,coredata,insert';
-                        push @results, loc("%1 already exists and has RT's tables in place, but does not contain RT's metadata. The 'Initialize Database' step later on can insert metadata into this existing database. If this is acceptable, click 'Customize Basics' below to continue customizing RT.", $RT::DatabaseName);
+                        push @results, _("%1 already exists and has RT's tables in place, but does not contain RT's metadata. The 'Initialize Database' step later on can insert metadata into this existing database. If this is acceptable, click 'Customize Basics' below to continue customizing RT.", $RT::DatabaseName);
                     }
                 }
                 else {
                     $RT::Installer->{DatabaseAction} = 'schema,acl,coredata,insert';
-                    push @results, loc("%1 already exists, but does not contain RT's tables or metadata. The 'Initialize Database' step later on can insert tables and metadata into this existing database. if this is acceptable, click 'Customize Basic' below to continue customizing RT.", $RT::DatabaseName );
+                    push @results, _("%1 already exists, but does not contain RT's tables or metadata. The 'Initialize Database' step later on can insert tables and metadata into this existing database. if this is acceptable, click 'Customize Basic' below to continue customizing RT.", $RT::DatabaseName );
                 }
 
             }
@@ -178,12 +178,12 @@
         }
         else {
             $RT::Installer->{DatabaseAction} = 'error';
-            push @errors, loc("Failed to connect to database: %1",
+            push @errors, _("Failed to connect to database: %1",
                     $DBI::errstr );
         }
     }
     else {
-        push @results, loc($msg);
+        push @results, _($msg);
     }
 
 }

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseType.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseType.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/DatabaseType.html	Fri Jul 25 04:24:19 2008
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&|Elements/Wrapper, Title => loc('Step %1 of %2: ', 1, 7 ) . loc('Choose a database engine') &>
+<&|Elements/Wrapper, Title => _('Step %1 of %2: ', 1, 7 ) . _('Choose a database engine') &>
 
 <div class="intro">
 <p>
@@ -67,7 +67,7 @@
     CurrentValue => RT::Installer->current_values(@Types) &>
 
 <input type="hidden" name="Run" value="1">
-<& /Elements/Submit, Label => loc('Next: ') . loc( 'Check your database credentials') &>
+<& /Elements/Submit, Label => _('Next: ') . _( 'Check your database credentials') &>
 </form>
 </&>
 <%init>

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Errors
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Errors	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Errors	Fri Jul 25 04:24:19 2008
@@ -46,7 +46,7 @@
 %# 
 %# END BPS TAGGED BLOCK }}}
 % if (@Errors) {
-<&| "/Widgets/TitleBox", title => loc('Error'), hideable => 0, class => 'error'  &>
+<&| "/Widgets/TitleBox", title => _('Error'), hideable => 0, class => 'error'  &>
 <ul>
 % for my $Error ( @Errors ) {
 <li>

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Wrapper
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Wrapper	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/Elements/Wrapper	Fri Jul 25 04:24:19 2008
@@ -48,10 +48,10 @@
 <&/Elements/Header, title => $Title &>
 <& /Elements/PageLayout,
     title => $Title,
-    toptabs => { a => { title => loc('Install RT'),
+    toptabs => { a => { title => _('Install RT'),
                         path => 'Install/'
                         },
-                b => { title => loc('Buy Support'),
+                b => { title => _('Buy Support'),
                         path => 'mailto:sales at bestpractical.com'}
                 },
                         

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/Finish.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/Finish.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/Finish.html	Fri Jul 25 04:24:19 2008
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&| Elements/Wrapper, Title => loc('Step %1 of %2: ', 7, 7) . loc('Finish') &> 
+<&| Elements/Wrapper, Title => _('Step %1 of %2: ', 7, 7) . _('Finish') &> 
 
 <div class="intro">
 <p>

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/Global.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/Global.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/Global.html	Fri Jul 25 04:24:19 2008
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&| Elements/Wrapper, Title => loc('Step %1 of %2: ', 5, 7 ) . loc('Customize Email Addresses') &> 
+<&| Elements/Wrapper, Title => _('Step %1 of %2: ', 5, 7 ) . _('Customize Email Addresses') &> 
 
 <& Elements/Errors, Errors => \@errors &>
 
@@ -61,8 +61,8 @@
 
 <input type="hidden" name="Run" value="1">
 <& /Elements/Submit, Label => $RT::Installer->{DatabaseAction} eq 'none' ?
-loc('Next: ') . loc('Finish') : loc('Next: ') . loc( 'Initialize Database'),
-    Back => 1, BackLabel => loc('Back: ' ) . loc('Customize Email Configuration') &>
+_('Next: ') . _('Finish') : _('Next: ') . _( 'Initialize Database'),
+    Back => 1, BackLabel => _('Back: ' ) . _('Customize Email Configuration') &>
 </form>
 </&>
 <%init>
@@ -84,7 +84,7 @@
     for ( qw/comment_address correspond_address/ ) {
         if ( $ARGS{$_} && $ARGS{$_} !~ /.+ at .+/ ) {
             push @errors,
-                loc("Invalid %1: '%2' doesn't look like an email address",
+                _("Invalid %1: '%2' doesn't look like an email address",
                 $_, $ARGS{$_});
         }
     }
@@ -106,7 +106,7 @@
             }
         }
         else {
-            push @errors, loc($msg);
+            push @errors, _($msg);
         }
     }
 }

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/Initialize.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/Initialize.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/Initialize.html	Fri Jul 25 04:24:19 2008
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&|Elements/Wrapper, Title => loc('Step %1 of %2: ', 6, 7) . loc('Initialize Database') &> 
+<&|Elements/Wrapper, Title => _('Step %1 of %2: ', 6, 7) . _('Initialize Database') &> 
 
 <& Elements/Errors, Errors => \@errors &>
 
@@ -57,8 +57,8 @@
 
 <form method="post">
 <input type="hidden" name="Run" value="1">
-<& /Elements/Submit, Label => loc('Initialize Database'), Back => 1,
-    BackLabel => loc('Back: ') . loc('Customize Global') &>
+<& /Elements/Submit, Label => _('Initialize Database'), Back => 1,
+    BackLabel => _('Back: ') . _('Customize Global') &>
 </form>
 </&>
 <%init>
@@ -84,7 +84,7 @@
     if ( $actions[0] eq 'create' ) {
         ($status, $msg) = RT::Handle->create_database( $sysdbh );
         unless ( $status ) {
-            push @errors, loc('ERROR: %1', $msg );
+            push @errors, _('ERROR: %1', $msg );
         }
 
         shift @actions; # shift the 'create' action since its job is done.
@@ -121,7 +121,7 @@
                 ($status, $msg) = $RT::Handle->insert_data( $file );
             }
             unless ( $status ) {
-                push @errors, loc('ERROR: %1', $msg);
+                push @errors, _('ERROR: %1', $msg);
                 last;
             }
         }

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/Sendmail.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/Sendmail.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/Sendmail.html	Fri Jul 25 04:24:19 2008
@@ -45,7 +45,7 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&|Elements/Wrapper, Title => loc('Step %1 of %2: ', 4, 7 ) . loc('Email Configuration') &> 
+<&|Elements/Wrapper, Title => _('Step %1 of %2: ', 4, 7 ) . _('Email Configuration') &> 
 
 <& Elements/Errors, Errors => \@errors &>
 
@@ -59,8 +59,8 @@
 &>
 
 <input type="hidden" name="Run" value="1">
-<& /Elements/Submit, Label => loc('Next: ') . loc( 'Customize Global Defaults'),
-    Back => 1, BackLabel => loc('Back: ' ) . loc('Customize Basics') &>
+<& /Elements/Submit, Label => _('Next: ') . _( 'Customize Global Defaults'),
+    Back => 1, BackLabel => _('Back: ' ) . _('Customize Basics') &>
 </form>
 </&>
 <%init>
@@ -81,12 +81,12 @@
 
 
     unless ( -e $ARGS{SendmailPath} ) {
-        push @errors, loc( "%1 doesn't exist.", $ARGS{SendmailPath} );
+        push @errors, _( "%1 doesn't exist.", $ARGS{SendmailPath} );
     }
 
     if ( ! $ARGS{OwnerEmail} || $ARGS{OwnerEmail} !~ /.+ at .+/ ) {
         push @errors,
-            loc("Invalid %1: that doesn't look like an email address",
+            _("Invalid %1: that doesn't look like an email address",
             'Administrator Email');
     }
 

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/autohandler
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/autohandler	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/autohandler	Fri Jul 25 04:24:19 2008
@@ -51,6 +51,7 @@
 
 <%init>
 
+$RT::_install_mode = 1;
 if (RT->install_mode) {
     $r->content_type("text/html; charset=utf-8");
     require RT::Installer;

Modified: rt/branches/3.999-DANGEROUS/share/html/Install/index.html
==============================================================================
--- rt/branches/3.999-DANGEROUS/share/html/Install/index.html	(original)
+++ rt/branches/3.999-DANGEROUS/share/html/Install/index.html	Fri Jul 25 04:24:19 2008
@@ -45,13 +45,13 @@
 %# those contributions and any derivatives thereof.
 %# 
 %# END BPS TAGGED BLOCK }}}
-<&| Elements/Wrapper, Title => loc('Welcome to RT!') &>
+<&| Elements/Wrapper, Title => _('Welcome to RT!') &>
 
 <& Elements/Errors, Errors => \@errors &>
 
 % if ( !$locked) {
 
-<h1><% loc('What is RT?') %></h1>
+<h1><% _('What is RT?') %></h1>
 
 <div class="intro">
 <p>
@@ -60,7 +60,7 @@
 <p>
 <&|/l&>RT is used by Fortune 100 companies, one-person businesses, government agencies, educational institutions, hospitals, nonprofits, NGOs, libraries, open source projects and all sorts of other organizations on all seven continents. (Yes, even Antarctica.)</&>
 </p>
-<h2><% loc('Getting started') %></h2>
+<h2><% _('Getting started') %></h2>
 <p>
 <b>
 <&|/l&>You're seeing this screen because you started up an RT server without a working database. Most likely, this is the first time you're running RT.  If you click <i>Let's go!</i> below, RT will guide you through setting up your RT server and database.</&>
@@ -72,7 +72,7 @@
 
 <form method="post">
 <input type="hidden" name="Run" value="1" />
-<& /Elements/Submit, Label => loc( "Let's go!") &>
+<& /Elements/Submit, Label => _( "Let's go!") &>
 </form>
 % }
 </&>
@@ -83,7 +83,7 @@
     $locked = 1 unless -w $file;
     
     if ( $locked ) {
-        push @errors, loc("Config file %1 is locked", $file);
+        push @errors, _("Config file %1 is locked", $file);
     }
     elsif ( $Run ) {
         $RT::Installer->{InstallConfig} ||= {};


More information about the Rt-commit mailing list