Created
June 15, 2015 13:10
-
-
Save jeffleeismyhero/7b53826e29fbd2be198a to your computer and use it in GitHub Desktop.
This file contains 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)deleteItemsAtIndexPaths:(NSArray *)indexPaths { | |
NSArray *reloadedIndexPaths = [self safeIndexPaths:indexPaths]; | |
if (reloadedIndexPaths.count > 0) { | |
[self.collectionView deleteItemsAtIndexPaths:reloadedIndexPaths]; | |
} | |
} |
This file contains 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
2015-06-15 08:07:07.559 MyApplication[51976:5933010] Saved: <NSManagedObject: 0x7c8c1590> (entity: Order; id: 0x7c878c80 <x-coredata://18D1A6AB-9CE5-44EF-AAE4-59427BCCA1D0/Order/p16> ; data: { | |
amountTendered = "$100.00"; | |
changeDue = "$22.00"; | |
companyID = 1; | |
completedAt = nil; | |
deviceID = 3; | |
discountTotal = nil; | |
emailAddress = nil; | |
firstName = nil; | |
ipAddress = "::1"; | |
lastName = nil; | |
lineItems = <62706c69 73743030 d4010203 04050858 59542474 6f705824 6f626a65 63747358 24766572 73696f6e 59246172 63686976 6572>; | |
orderNumber = "003-150615080707424"; | |
orderStatus = successful; | |
orderTotal = "78.0"; | |
phoneNumber = nil; | |
remoteID = 26; | |
transactionDate = nil; | |
transactions = <62706c69 73743030 d4010203 04050871 72542474 6f705824 6f626a65 63747358 24766572 73696f6e 59246172 63686976 6572>; | |
}) | |
2015-06-15 08:07:07.559 MyApplication[51976:5933010] savedOrder: <NSManagedObject: 0x7c8c1590> (entity: Order; id: 0x7c878c80 <x-coredata://18D1A6AB-9CE5-44EF-AAE4-59427BCCA1D0/Order/p16> ; data: { | |
amountTendered = "$100.00"; | |
changeDue = "$22.00"; | |
companyID = 1; | |
completedAt = nil; | |
deviceID = 3; | |
discountTotal = nil; | |
emailAddress = nil; | |
firstName = nil; | |
ipAddress = "::1"; | |
lastName = nil; | |
lineItems = <62706c69 73743030 d4010203 04050858 59542474 6f705824 6f626a65 63747358 24766572 73696f6e 59246172 63686976 6572>; | |
orderNumber = "003-150615080707424"; | |
orderStatus = successful; | |
orderTotal = "78.0"; | |
phoneNumber = nil; | |
remoteID = 26; | |
transactionDate = nil; | |
transactions = <62706c69 73743030 d4010203 04050871 72542474 6f705824 6f626a65 63747358 24766572 73696f6e 59246172 63686976 6572>; | |
}) | |
2015-06-15 08:07:07.599 MyApplication[51976:5933010] negative or zero sizes are not supported in the flow layout | |
2015-06-15 08:07:07.600 MyApplication[51976:5933010] *** Assertion failure in -[UICollectionView _endItemAnimationsWithInvalidationContext:tentativelyForReordering:], /SourceCache/UIKit_Sim/UIKit-3347.44/UICollectionView.m:4072 | |
2015-06-15 08:07:07.602 MyApplication[51976:5933010] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Invalid update: invalid number of items in section 2. The number of items contained in an existing section after the update (6) must be equal to the number of items contained in that section before the update (6), plus or minus the number of items inserted or deleted from that section (0 inserted, 1 deleted) and plus or minus the number of items moved into or out of that section (0 moved in, 0 moved out).' | |
*** First throw call stack: | |
( | |
0 CoreFoundation 0x03890746 __exceptionPreprocess + 182 | |
1 libobjc.A.dylib 0x03519a97 objc_exception_throw + 44 | |
2 CoreFoundation 0x038905da +[NSException raise:format:arguments:] + 138 | |
3 Foundation 0x01d42720 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 118 | |
4 UIKit 0x02811e21 -[UICollectionView _endItemAnimationsWithInvalidationContext:tentativelyForReordering:] + 14566 | |
5 UIKit 0x0280e536 -[UICollectionView _endItemAnimationsWithInvalidationContext:] + 48 | |
6 UIKit 0x0280e2ed -[UICollectionView _updateRowsAtIndexPaths:updateAction:] + 374 | |
7 UIKit 0x0280e374 -[UICollectionView deleteItemsAtIndexPaths:] + 48 | |
8 Form 0x008cbae4 -[FORMDataSource deleteItemsAtIndexPaths:] + 196 | |
9 Form 0x008d2676 __33-[FORMDataSource processTargets:]_block_invoke + 806 | |
10 Form 0x008f8b1f +[FORMTarget filteredTargets:filtered:] + 1247 | |
11 Form 0x008d2312 -[FORMDataSource processTargets:] + 178 | |
12 MyApplication 0x00047d8b -[VPPrintCollectionViewController removeProcessOrderButton] + 379 | |
13 MyApplication 0x00043728 -[VPPrintCollectionViewController initWithJSON:andInitialValues:] + 488 | |
14 MyApplication 0x00036fab -[VPPaymentCollectionViewController printOrderReceipt] + 715 | |
15 MyApplication 0x00037c66 __49-[VPPaymentCollectionViewController processOrder]_block_invoke + 998 | |
16 AFNetworking 0x0058b44b __64-[AFHTTPRequestOperation setCompletionBlockWithSuccess:failure:]_block_invoke46 + 43 | |
17 libdispatch.dylib 0x03d485ea _dispatch_call_block_and_release + 15 | |
18 libdispatch.dylib 0x03d6abef _dispatch_client_callout + 14 | |
19 libdispatch.dylib 0x03d506bb _dispatch_main_queue_callback_4CF + 993 | |
20 CoreFoundation 0x037e98ee __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 14 | |
21 CoreFoundation 0x037a75f0 __CFRunLoopRun + 2256 | |
22 CoreFoundation 0x037a6a5b CFRunLoopRunSpecific + 443 | |
23 CoreFoundation 0x037a688b CFRunLoopRunInMode + 123 | |
24 GraphicsServices 0x063e32c9 GSEventRunModal + 192 | |
25 GraphicsServices 0x063e3106 GSEventRun + 104 | |
26 UIKit 0x020f0106 UIApplicationMain + 1526 | |
27 MyApplication 0x0003f3da main + 138 | |
28 libdyld.dylib 0x03d95ac9 start + 1 | |
) | |
libc++abi.dylib: terminating with uncaught exception of type NSException |
This file contains 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)removeProcessOrderButton { | |
NSMutableArray *hideTargets = [NSMutableArray new]; | |
FORMField *field = [self.dataSource fieldWithID:@"process_order" | |
includingHiddenFields:NO]; | |
if (field) { | |
[hideTargets addObject:[FORMTarget hideFieldTargetWithID:field.fieldID]]; | |
[self.dataSource processTargets:hideTargets]; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment