|
|
@@ -64,6 +64,20 @@
|
|
|
{
|
|
|
[self.data append_jsondata: result];
|
|
|
self.lastid = self.data._id;
|
|
|
+
|
|
|
+ if([result[@"result"] intValue]!=RESULT_TRUE)
|
|
|
+ {
|
|
|
+ UIAlertController *alertVC = [UIAlertController alertControllerWithTitle: @"Warning"
|
|
|
+ message: result[@"err_msg"]
|
|
|
+ preferredStyle: UIAlertControllerStyleAlert];
|
|
|
+ UIAlertAction *action = [UIAlertAction actionWithTitle:@"Back" style:UIAlertActionStyleCancel handler:^(UIAlertAction * _Nonnull action) {
|
|
|
+ [self.navigationController popViewControllerAnimated:false];
|
|
|
+ }];
|
|
|
+
|
|
|
+ [alertVC addAction:action];
|
|
|
+ [self presentViewController:alertVC animated:YES completion:nil];
|
|
|
+ }
|
|
|
+
|
|
|
self.btnrefresh.hidden = false;
|
|
|
if(self.data.finishload==true)
|
|
|
{
|
|
|
@@ -108,6 +122,18 @@
|
|
|
[self.data append_jsondata: result];
|
|
|
self.lastid = self.data._id;
|
|
|
self.btnrefresh.hidden = false;
|
|
|
+ if([result[@"result"] intValue]!=RESULT_TRUE)
|
|
|
+ {
|
|
|
+ UIAlertController *alertVC = [UIAlertController alertControllerWithTitle: @"Warning"
|
|
|
+ message: result[@"err_msg"]
|
|
|
+ preferredStyle: UIAlertControllerStyleAlert];
|
|
|
+ UIAlertAction *action = [UIAlertAction actionWithTitle:@"Back" style:UIAlertActionStyleCancel handler:^(UIAlertAction * _Nonnull action) {
|
|
|
+ [self.navigationController popViewControllerAnimated:false];
|
|
|
+ }];
|
|
|
+
|
|
|
+ [alertVC addAction:action];
|
|
|
+ [self presentViewController:alertVC animated:YES completion:nil];
|
|
|
+ }
|
|
|
if(self.data.finishload==true)
|
|
|
{
|
|
|
|