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

SF.net SVN: ledger-smb:[5514] branches/1.3



Revision: 5514
          http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=5514&view=rev
Author:   einhverfr
Date:     2013-01-08 02:10:15 +0000 (Tue, 08 Jan 2013)
Log Message:
-----------
Fixing administrative password reset logic so that the password is correctly changed and the redirect is to the edit user screen

Modified Paths:
--------------
    branches/1.3/Changelog
    branches/1.3/LedgerSMB/DBObject/Admin.pm
    branches/1.3/UI/Admin/edit_user.html
    branches/1.3/scripts/admin.pl

Property Changed:
----------------
    branches/1.3/Changelog

Modified: branches/1.3/Changelog
===================================================================
--- branches/1.3/Changelog	2013-01-08 02:07:09 UTC (rev 5513)
+++ branches/1.3/Changelog	2013-01-08 02:10:15 UTC (rev 5514)
@@ -14,6 +14,8 @@
 * Changing xetex demos to use Liberation font (Chris T, h/t Erik H)
 * Better appearance of customer history report filter screen (Chris T)
 * Fixed new Dynatable.tex not handling col ids with underscores (Chris T)
+* Fixed admin passwd reset directing to showing new user screen (Chris T)
+* Fixed admin passwd reset ineffective (Chris T, bug 3599803)
 
 Changelog for 1.3.27
 * Detect whether ledgersmb.conf exists during Makefile.PL run and create if


Property changes on: branches/1.3/Changelog
___________________________________________________________________
Added: svn:mergeinfo
   + /trunk/Changelog:3711-3712,5424,5446-5448,5451,5457,5459,5461,5466,5473,5475,5482-5483,5485,5487,5489,5495-5496,5513

Modified: branches/1.3/LedgerSMB/DBObject/Admin.pm
===================================================================
--- branches/1.3/LedgerSMB/DBObject/Admin.pm	2013-01-08 02:07:09 UTC (rev 5513)
+++ branches/1.3/LedgerSMB/DBObject/Admin.pm	2013-01-08 02:10:15 UTC (rev 5514)
@@ -89,6 +89,7 @@
             'import',
         ]
     );
+    $user->{id} = $user->{user_id} if $user->{user_id};
     $user->{entity_id} = $employee->{entity_id};
     if ($user->save() == 8){ # Duplicate User exception --CT
         $user->{dbh}->rollback;

Modified: branches/1.3/UI/Admin/edit_user.html
===================================================================
--- branches/1.3/UI/Admin/edit_user.html	2013-01-08 02:07:09 UTC (rev 5513)
+++ branches/1.3/UI/Admin/edit_user.html	2013-01-08 02:10:15 UTC (rev 5514)
@@ -8,7 +8,7 @@
                        action = 'save_user';
                 ELSIF user.user.username;
                       text('Editing User');
-                      action = 'edit_user';
+                      action = 'save_user';
                 ELSE;
                       text('New User');
                       action = 'save_user';
@@ -18,6 +18,7 @@
     <form method="POST" action="admin.pl">
         <input type="hidden" name="action" value="<?lsmb action ?>"/>
         <input type="hidden" name="entity_id" value="<?lsmb user.employee.entity_id ?>"/>
+        <input type="hidden" name="user_id" value="<?lsmb user.user.id ?>" />
         <table>
 
             <?lsmb IF user.user.username?>

Modified: branches/1.3/scripts/admin.pl
===================================================================
--- branches/1.3/scripts/admin.pl	2013-01-08 02:07:09 UTC (rev 5513)
+++ branches/1.3/scripts/admin.pl	2013-01-08 02:10:15 UTC (rev 5514)
@@ -134,7 +134,7 @@
     }
     my $groups = $admin->get_roles();
     $admin->{stylesheet} = $request->{stylesheet};
-    $admin->{user_id} = $admin->{user}->{id};
+    $admin->{user_id} = $admin->{user}->{id} unless $admin->{user_id};
     __edit_page($admin);
 }
 

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