Update MVMCoreLoadRequestOperation.m
added function to display alert from "Action" object in response level
This commit is contained in:
parent
75e33cd05b
commit
5466c75c5c
@ -796,7 +796,7 @@
|
||||
}
|
||||
|
||||
//make post load calls function
|
||||
[MVMCoreLoadRequestOperation loadPostCallActions:loadObject];
|
||||
[MVMCoreLoadRequestOperation loadCallActions:loadObject];
|
||||
|
||||
[loadObject.operation markAsFinished];
|
||||
}
|
||||
@ -819,6 +819,20 @@
|
||||
}
|
||||
}
|
||||
|
||||
+ (void)loadCallActions:(nonnull MVMCoreLoadObject *)loadObject {
|
||||
NSDictionary *actionDict = [loadObject.responseJSON dict:@"Action"];
|
||||
if (actionDict) {
|
||||
//TODO needs to create operation queue based on concurrent flag
|
||||
//BOOL isConcurrent = [postCallsDict boolForKey:@"concurrent"];
|
||||
//Needs further enhancements based on the flags.
|
||||
BOOL shouldTriggerFromCache = [actionDict boolForKey:@"shouldTriggerFromCache"];
|
||||
//Check if page is not from cache
|
||||
if (!loadObject.pageDataFromCache || shouldTriggerFromCache) {
|
||||
[[MVMCoreActionHandler sharedActionHandler] handleActionWithDictionary:actionDict additionalData:nil delegateObject:nil];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+ (void)removeCaches:(nullable NSDictionary *)cacheDictionary {
|
||||
|
||||
if (cacheDictionary) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user