[Rt-commit] r13564 - in rt/3.8/trunk: share/html/Install

sunnavy at bestpractical.com sunnavy at bestpractical.com
Tue Jun 24 14:35:08 EDT 2008


Author: sunnavy
Date: Tue Jun 24 14:35:07 2008
New Revision: 13564

Modified:
   rt/3.8/trunk/   (props changed)
   rt/3.8/trunk/share/html/Install/Basics.html
   rt/3.8/trunk/share/html/Install/DatabaseDetails.html
   rt/3.8/trunk/share/html/Install/Global.html
   rt/3.8/trunk/share/html/Install/Initialize.html
   rt/3.8/trunk/share/html/Install/Sendmail.html
   rt/3.8/trunk/share/html/Install/index.html

Log:
 r13771 at sunnavys-mb:  sunnavy | 2008-06-25 02:29:33 +0800
 loc results too


Modified: rt/3.8/trunk/share/html/Install/Basics.html
==============================================================================
--- rt/3.8/trunk/share/html/Install/Basics.html	(original)
+++ rt/3.8/trunk/share/html/Install/Basics.html	Tue Jun 24 14:35:07 2008
@@ -78,14 +78,12 @@
             Store => $RT::Installer->{InstallConfig},
             Meta => $RT::Installer->{Meta} );
     
-    for ( qw/WebPort/ ) {
-        if ( $ARGS{$_} && $ARGS{$_} !~ /^\d+$/ ) {
-            push @results, "Invalid $_: it should be a number";
-        }
+    if ( $ARGS{WebPort} && $ARGS{WebPort} !~ /^\d+$/ ) {
+        push @results, loc("Invalid [_1]: it should be a number", 'WebPort');
     }
 
     unless ( $ARGS{Password} ) {
-        push @results, "You must enter an Administrative password";
+        push @results, loc("You must enter an Administrative password");
     }
 
     if ( $Back ) {

Modified: rt/3.8/trunk/share/html/Install/DatabaseDetails.html
==============================================================================
--- rt/3.8/trunk/share/html/Install/DatabaseDetails.html	(original)
+++ rt/3.8/trunk/share/html/Install/DatabaseDetails.html	Tue Jun 24 14:35:07 2008
@@ -99,9 +99,9 @@
 &>
 % }
 
-
 </form>
 </&>
+
 <%init>
 my @results;
 my $ConnectionSucceeded;
@@ -144,7 +144,7 @@
         );
     
         if ( $dbh ) {
-            push @results, 'Connection succeeded';
+            push @results, loc('Connection succeeded');
             # dba connect dsn, which has table info
             $dbh = DBI->connect(
                 RT::Handle->DSN, $ARGS{DatabaseAdmin}, $ARGS{DatabaseAdminPassword}, { RaiseError => 0, PrintError => 0 },
@@ -169,16 +169,16 @@
                     $sth->execute('RT_System'); 
                     if ( $sth->fetchrow_array ) {
                         $RT::Installer->{DatabaseAction} = 'none';
-                        push @results, "Database $RT::DatabaseName 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";
+                        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);
                     }
                     else {
                         $RT::Installer->{DatabaseAction} = 'acl,coredata,insert';
-                        push @results, "Database $RT::DatabaseName 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.";
+                        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);
                     }
                 }
                 else {
                     $RT::Installer->{DatabaseAction} = 'schema,acl,coredata,insert';
-                    push @results, "Database $RT::DatabaseName 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.";
+                    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 );
                 }
 
             }
@@ -189,14 +189,16 @@
         }
         else {
             $RT::Installer->{DatabaseAction} = 'error';
-            push @results, "Failed to connect to database: $DBI::errstr";
+            push @results, loc("Failed to connect to database: [_1]",
+                    $DBI::errstr );
         }
     }
     else {
-        push @results, $msg;
+        push @results, loc($msg);
     }
 
-$ConnectionSucceeded = ( @results && $results[0] eq 'Connection succeeded' ) ? 1 : 0;
+$ConnectionSucceeded =
+    ( @results && $results[0] eq loc('Connection succeeded') ) ? 1 : 0;
 }
 
 </%init>

Modified: rt/3.8/trunk/share/html/Install/Global.html
==============================================================================
--- rt/3.8/trunk/share/html/Install/Global.html	(original)
+++ rt/3.8/trunk/share/html/Install/Global.html	Tue Jun 24 14:35:07 2008
@@ -105,7 +105,7 @@
             }
         }
         else {
-            push @results, $msg;
+            push @results, loc($msg);
         }
     }
 }

Modified: rt/3.8/trunk/share/html/Install/Initialize.html
==============================================================================
--- rt/3.8/trunk/share/html/Install/Initialize.html	(original)
+++ rt/3.8/trunk/share/html/Install/Initialize.html	Tue Jun 24 14:35:07 2008
@@ -84,7 +84,7 @@
     if ( $actions[0] eq 'create' ) {
         ($status, $msg) = RT::Handle->CreateDatabase( $sysdbh );
         unless ( $status ) {
-            push @results, "ERROR: $msg";
+            push @results, loc('ERROR: [_1]', $msg );
         }
 
         shift @actions; # shift the 'create' action since its job is done.
@@ -121,7 +121,7 @@
                 ($status, $msg) = $RT::Handle->InsertData( $file );
             }
             unless ( $status ) {
-                push @results, "ERROR: $msg";
+                push @results, loc('ERROR: [_1]', $msg);
                 last;
             }
         }

Modified: rt/3.8/trunk/share/html/Install/Sendmail.html
==============================================================================
--- rt/3.8/trunk/share/html/Install/Sendmail.html	(original)
+++ rt/3.8/trunk/share/html/Install/Sendmail.html	Tue Jun 24 14:35:07 2008
@@ -86,11 +86,13 @@
 
 
     unless ( -e $ARGS{SendmailPath} ) {
-        push @results, "$ARGS{SendmailPath} doesn't exist.";
+        push @results, loc( "[_1] doesn't exist.", $ARGS{SendmailPath} );
     }
 
     if ( ! $ARGS{OwnerEmail} || $ARGS{OwnerEmail} !~ /.+ at .+/ ) {
-        push @results, "Invalid Administrator Email: That doesn't look like an email address";
+        push @results,
+            loc("Invalid [_1]: that doesn't look like an email address",
+            'Administrator Email');
     }
 
 

Modified: rt/3.8/trunk/share/html/Install/index.html
==============================================================================
--- rt/3.8/trunk/share/html/Install/index.html	(original)
+++ rt/3.8/trunk/share/html/Install/index.html	Tue Jun 24 14:35:07 2008
@@ -91,7 +91,7 @@
     $locked = 1 unless -w $file;
     
     if ( $locked ) {
-        push @results, "Config file $file is locked";
+        push @results, loc("Config file [_1] is locked", $file);
     }
     elsif ( $Run ) {
         $RT::Installer->{InstallConfig} ||= {};


More information about the Rt-commit mailing list