aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/SPCustomQuery.m18
1 files changed, 13 insertions, 5 deletions
diff --git a/Source/SPCustomQuery.m b/Source/SPCustomQuery.m
index b7d41bfa..1108e6d6 100644
--- a/Source/SPCustomQuery.m
+++ b/Source/SPCustomQuery.m
@@ -1467,21 +1467,29 @@
NSMutableArray *tempRow = [NSMutableArray array];
NSInteger i;
- //set field names as first line
- while ( (tableColumn = [enumerator nextObject]) ) {
+ // Set field names as first line
+ while ((tableColumn = [enumerator nextObject]))
+ {
[tempRow addObject:[[tableColumn headerCell] stringValue]];
}
+
[currentResult addObject:[NSArray arrayWithArray:tempRow]];
- //add rows
- for ( i = 0 ; i < [self numberOfRowsInTableView:customQueryView] ; i++) {
+ // Add rows
+ for (i = 0; i < [self numberOfRowsInTableView:customQueryView]; i++)
+ {
[tempRow removeAllObjects];
+
enumerator = [tableColumns objectEnumerator];
- while ( (tableColumn = [enumerator nextObject]) ) {
+
+ while ((tableColumn = [enumerator nextObject]))
+ {
[tempRow addObject:[self tableView:customQueryView objectValueForTableColumn:tableColumn row:i]];
}
+
[currentResult addObject:[NSArray arrayWithArray:tempRow]];
}
+
return currentResult;
}