[Vtigercrm-commits] [vtiger-commits] r9509 - /vtigercrm/trunk/install/5createTables.inc.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Wed Sep 13 11:02:13 EDT 2006
Author: richie
Date: Wed Sep 13 09:02:06 2006
New Revision: 9509
Log:
Fixed the default group population issue --by Don
Modified:
vtigercrm/trunk/install/5createTables.inc.php
Modified: vtigercrm/trunk/install/5createTables.inc.php
==============================================================================
--- vtigercrm/trunk/install/5createTables.inc.php (original)
+++ vtigercrm/trunk/install/5createTables.inc.php Wed Sep 13 09:02:06 2006
@@ -100,6 +100,16 @@
$user->save("Users");
+ //Inserting Entries into vtiger_groups table
+ $result = $db->query("select groupid from vtiger_groups where groupname='Team Selling';");
+ $group1_id = $db->query_result($result,0,"groupid");
+ $result = $db->query("select groupid from vtiger_groups where groupname='Marketing Group';");
+ $group2_id = $db->query_result($result,0,"groupid");
+ $result = $db->query("select groupid from vtiger_groups where groupname='Support Group';");
+ $group3_id = $db->query_result($result,0,"groupid");
+
+ $db->query("insert into vtiger_users2group values ('".$group2_id."',".$user->id.")");
+
// we need to change the admin user to a fixed id of 1.
//$query = "update vtiger_users set id='1' where user_name='$user->user_name'";
//$result = $db->query($query, true, "Error updating admin user ID: ");
@@ -145,6 +155,10 @@
//Creating the flat vtiger_files
createUserPrivilegesfile($user->id);
createUserSharingPrivilegesfile($user->id);
+
+ $db->query("insert into vtiger_users2group values ('".$group1_id."',".$user->id.")");
+ $db->query("insert into vtiger_users2group values ('".$group2_id."',".$user->id.")");
+ $db->query("insert into vtiger_users2group values ('".$group3_id."',".$user->id.")");
}
More information about the vtigercrm-commits
mailing list