This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"data": [ | |
{ | |
"id": "1484098195203840_1500346223579037", | |
"from": { | |
"id": "1484098195203840", | |
"name": "Hermano Libre" | |
}, | |
"to": { | |
"data": [ | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"data": [ | |
{ | |
"id": "1484098195203840_1500346223579037", | |
"from": { | |
"id": "1484098195203840", | |
"name": "Hermano Libre" | |
}, | |
"to": { | |
"data": [ | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$toData = $datum['to']['data']; | |
$toArray = []; | |
$tagArray = []; | |
foreach ($toData as $toUser) { | |
array_push($toArray, $toUser['id']); | |
} | |
if (isset($datum['message_tags'])) { | |
foreach($datum['message_tags'] as $tag) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$toData = $datum['to']['data']; | |
// rekey to use user id's as index | |
$rekeyedToData = []; | |
foreach($toData as $toUser) { | |
$key = $toUser['id']; | |
$rekeyedToData[$key] = $toUser; | |
} | |
// iterate through message_tags, remove the tagged user from $rekeyedToData |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$toData = $datum['to']['data']; | |
// rekey to use user id's as index | |
$rekeyedToData = []; | |
foreach($toData as $toUser) { | |
$key = $toUser['id']; | |
// add an extra 'count' key for user ids that show up more than once | |
if(array_key_exists($key, $rekeyedToData)) { | |
$rekeyedToData[$key]['count']++; | |
} else { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$toData = $datum['to']['data']; | |
$toArray = []; | |
$tagArray = []; | |
foreach($toData as $toUser) { | |
array_push($toArray, $toUser['id']); | |
} | |
if(isset($datum['message_tags'])){ | |
foreach($datum['message_tags'] as $tag) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)save | |
{ | |
Matter *matter = [NSEntityDescription insertNewObjectForEntityForName:@"Matter" inManagedObjectContext:[RKObjectManager sharedManager].managedObjectStore.mainQueueManagedObjectContext]; | |
matter.matterDescription = self.description.text; | |
matter.displayNumber = @"1234-Testest"; | |
matter.status = @"Open"; | |
NSError *error; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe MattersTableViewController do | |
tests MattersTableViewController | |
describe '#viewDidLoad' do | |
describe 'navBarLabel' do | |
it 'should be visible' do | |
end | |
it 'should be initialized with title "ALL MATTERS"' do | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.repl_history | |
build | |
tags | |
.DS_Store | |
*.swp | |
*.swo | |
resources/*.nib | |
resources/*.momd | |
resources/*.storyboardc | |
.DS_Store |