Commit 7ad3e1f6 authored by 翟国钧's avatar 翟国钧

对外抛出一个统一处理返回数据对象的block

parent 12cb8a35
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
@property (nonatomic, strong) NSString *webHost; @property (nonatomic, strong) NSString *webHost;
@property (nonatomic, strong) NSString *loginExpiredName; @property (nonatomic, strong) NSString *loginExpiredName;
@property (nonatomic, strong) NSString *urlCommonParameters; @property (nonatomic, strong) NSString *urlCommonParameters;
@property (nonatomic, copy) void (^handleResponse) (NSDictionary *response);
+ (instancetype)sharedInstance; + (instancetype)sharedInstance;
/** /**
......
...@@ -182,6 +182,9 @@ ...@@ -182,6 +182,9 @@
if (success) { if (success) {
[UIApplication sharedApplication].networkActivityIndicatorVisible = NO; [UIApplication sharedApplication].networkActivityIndicatorVisible = NO;
success(responseObject); success(responseObject);
if (self.handleResponse) {
_handleResponse(responseObject);
}
} }
}); });
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment