[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Fwd: Patch for admin.sql : admin__save_user()
- Subject: Fwd: Patch for admin.sql : admin__save_user()
- From: Erik Huelsmann <..hidden..>
- Date: Tue, 17 May 2011 23:34:14 +0200
Accidentally cc-ed ledger-smb-devel-*request*... forwarding.
---------- Forwarded message ----------
From: Erik Huelsmann <..hidden..>
Date: Tue, May 17, 2011 at 11:31 PM
Subject: Patch for admin.sql : admin__save_user()
To: ..hidden..
Cc: ..hidden..
Hi Chris,
How about this patch to admin__save_user() to fix the issue that the
admin must be in the employee table too.
Index: sql/modules/admin.sql
===================================================================
--- sql/modules/admin.sql (revision 3137)
+++ sql/modules/admin.sql (working copy)
@@ -358,6 +358,11 @@
insert into user_preference (id) values (v_user_id);
+ select * from entity_employee where entity_id = in_entity_id;
+ IF NOT FOUND THEN
+ select into entity_employee (entity_id) values (in_entity_id);
+ END IF;
+
-- Finally, issue the create user statement
return v_user_id ;
Bye,
Erik.