(core) new database structure options to make SOGo use a total of nine tables

This commit is contained in:
Ludovic Marcotte
2016-03-10 16:34:06 -05:00
parent 819851bb92
commit 4ac41dace7
25 changed files with 1055 additions and 118 deletions
+12 -5
View File
@@ -1778,11 +1778,18 @@ static NSArray *childRecordFields = nil;
userRoles = [roles objectEnumerator];
while ((currentRole = [userRoles nextObject]))
{
SQL = [NSString stringWithFormat: @"INSERT INTO %@"
@" (c_object, c_uid, c_role)"
@" VALUES ('/%@', '%@', '%@')",
[folder aclTableName],
objectPath, uid, currentRole];
if ([GCSFolderManager singleStoreMode])
SQL = [NSString stringWithFormat: @"INSERT INTO %@"
@" (c_object, c_uid, c_role, c_folder_id)"
@" VALUES ('/%@', '%@', '%@', %@)",
[folder aclTableName],
objectPath, uid, currentRole, [folder folderId]];
else
SQL = [NSString stringWithFormat: @"INSERT INTO %@"
@" (c_object, c_uid, c_role)"
@" VALUES ('/%@', '%@', '%@')",
[folder aclTableName],
objectPath, uid, currentRole];
[channel evaluateExpressionX: SQL];
}