[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SF.net SVN: ledger-smb:[3904] trunk



Revision: 3904
          http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=3904&view=rev
Author:   einhverfr
Date:     2011-10-21 08:48:36 +0000 (Fri, 21 Oct 2011)
Log Message:
-----------
Merging from branches/1.3

Modified Paths:
--------------
    trunk/Changelog
    trunk/LedgerSMB/Scripts/admin.pm
    trunk/UI/Admin/edit_user.html
    trunk/t/01-load.t

Property Changed:
----------------
    trunk/
    trunk/LedgerSMB/Scripts/admin.pm
    trunk/LedgerSMB/Scripts/employee.pm
    trunk/sql/upgrade/1.2-1.3-manual.sql


Property changes on: trunk
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/1.3:3711-3900
   + /branches/1.3:3711-3903

Modified: trunk/Changelog
===================================================================
--- trunk/Changelog	2011-10-21 07:55:56 UTC (rev 3903)
+++ trunk/Changelog	2011-10-21 08:48:36 UTC (rev 3904)
@@ -20,6 +20,8 @@
 * Correcting LedgerSMB.pot (bug reported by Herman V) (Chris T)
 * Documented parameterized translation syntax for .po files (Herman V)
 * Added en_GB and en_US to language table for new installations (Chris T)
+* Added check for system configuration before tests begin (Chris T)
+* Clarified password reset interface for user management (Chris T)
 
 Changelog for LedgerSMB 1.3.1
 * Language selection for invoice templates fixed (Chris T)

Modified: trunk/LedgerSMB/Scripts/admin.pm
===================================================================
--- trunk/LedgerSMB/Scripts/admin.pm	2011-10-21 07:55:56 UTC (rev 3903)
+++ trunk/LedgerSMB/Scripts/admin.pm	2011-10-21 08:48:36 UTC (rev 3904)
@@ -166,7 +166,7 @@
     my $request = shift @_;
     my $admin = LedgerSMB::DBObject::Admin->new(base=>$request, copy=>'all');
     
-    my $sal = $admin->get_salutations();
+    my @sal = $admin->get_salutations();
     
     my $groups = $admin->get_roles();
     my $user = $request->{_user};
@@ -183,7 +183,7 @@
     
         $template->render(
             {
-                salutations=>$sal,
+                salutations=>..hidden..,
                 roles=>$groups,
                 countries=>$admin->get_countries(),
                 stylesheet => $request->{stylesheet},


Property changes on: trunk/LedgerSMB/Scripts/admin.pm
___________________________________________________________________
Added: svn:mergeinfo
   + /branches/1.3/LedgerSMB/Scripts/admin.pm:3901-3903
/branches/1.3/scripts/admin.pl:3711-3903


Property changes on: trunk/LedgerSMB/Scripts/employee.pm
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/1.3/LedgerSMB/Scripts/employee.pm:3712-3900
/branches/1.3/scripts/employee.pl:3842-3843
   + /branches/1.3/LedgerSMB/Scripts/employee.pm:3712-3903
/branches/1.3/scripts/employee.pl:3842-3843

Modified: trunk/UI/Admin/edit_user.html
===================================================================
--- trunk/UI/Admin/edit_user.html	2011-10-21 07:55:56 UTC (rev 3903)
+++ trunk/UI/Admin/edit_user.html	2011-10-21 08:48:36 UTC (rev 3904)
@@ -49,6 +49,7 @@
                 </td>
             </tr>
             <?lsmb END ?>
+            <?lsmb UNLESS user.employee.entity_id ?>
             <tr>
                 <td><?lsmb text('Import') ?></td>
                 <?lsmb 
@@ -73,35 +74,53 @@
                            name    = 'import'
                            type    = 'radio'
                    } ?>
-            <tr>
+            </tr>
+            <?lsmb END # unless user.employee.entity_id ?>
+            <?lsmb UNLESS user.employee.entity_id ?>
+            <tr><td>&nbsp;</td>
                 <td>
                     <select name="salutation">
                         <?lsmb FOREACH sal = salutations ?>
                             <option value="<?lsmb sal.id?>"><?lsmb sal.salutation?></option>
                         <?lsmb END?>
                     </select>
+                       
                 </td>
             </tr>
+            <?lsmb END ?>
             
             <tr>
                 <td><?lsmb ('First Name') ?></td>
                 <td>
+                    <?lsmb IF user.employee.entity_id;
+                               user.employee.first_name;
+                           ELSE; ?>
                     <input type="text" name="first_name" value="<?lsmb user.employee.first_name?>"/>
+                   <?lsmb END ?>
                 </td>
             </tr>
             
             <tr>
                 <td><?lsmb text('Last Name') ?></td>
                 <td>
+                    <?lsmb IF user.employee.entity_id;
+                               user.employee.last_name;
+                           ELSE; ?>
                     <input type="text" name="last_name" value="<?lsmb user.employee.last_name?>"/>
+                   <?lsmb END ?>
                 </td>
             </tr>
             <tr>
                 <td><?lsmb text('Employee No.') ?></td>
                 <td>
+                    <?lsmb IF user.employee.entity_id;
+                               user.employee.employeenumber;
+                           ELSE; ?>
                     <input type="textarea" name="employeenumber" value="<?lsmb user.employee.employeenumber?>"/>
+                   <?lsmb END ?>
                 </td>
             </tr>
+           <?lsmb UNLESS user.employee.entity_id ?>
             <tr>
                 <td><?lsmb text('Country') ?></td>
                 <td>
@@ -119,8 +138,13 @@
                     } ?>
                 </td>
             </tr>
+            <?lsmb END ?>
         </table>
+           <?lsmb IF user.employee.entity_id ?>
+        <button type="submit" value="save_user"><?lsmb text('Set Password') ?>
+           <?lsmb ELSE ?>
         <button type="submit" value="save_user"><?lsmb text('Save User') ?>
+           <?lsmb END ?>
         </button>
     </form>
     <?lsmb IF user.user.username AND user.user.import != 1 ?>


Property changes on: trunk/sql/upgrade/1.2-1.3-manual.sql
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/1.3/sql/upgrade/1.2-1.3-manual.sql:3712-3900
/branches/1.3/sql/upgrade/1.2-1.3.sql:3711-3851
/trunk/sql/upgrade/1.2-1.3.sql:858-3710
   + /branches/1.3/sql/upgrade/1.2-1.3-manual.sql:3712-3903
/branches/1.3/sql/upgrade/1.2-1.3.sql:3711-3851
/trunk/sql/upgrade/1.2-1.3.sql:858-3710

Modified: trunk/t/01-load.t
===================================================================
--- trunk/t/01-load.t	2011-10-21 07:55:56 UTC (rev 3903)
+++ trunk/t/01-load.t	2011-10-21 08:48:36 UTC (rev 3904)
@@ -4,6 +4,8 @@
 use warnings;
 use Test::More tests => 55;
 
+use_ok('LedgerSMB::Sysconfig') 
+    || BAIL_OUT('System Configuration could be loaded!');
 use_ok('LedgerSMB');
 use_ok('LedgerSMB::AA');
 use_ok('LedgerSMB::AM');
@@ -43,7 +45,6 @@
 use_ok('LedgerSMB::RP');
 use_ok('LedgerSMB::Auth');
 use_ok('LedgerSMB::DBObject::Reconciliation');
-use_ok('LedgerSMB::Sysconfig');
 use_ok('LedgerSMB::Tax');
 use_ok('LedgerSMB::Template');
 use_ok('LedgerSMB::Template::Elements');

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.