Steven 1 سال پیش
والد
کامیت
49e74026b8

+ 2 - 2
KulexiuForStudent/KulexiuForStudent/Common/Tools/UIView+ExtensionForDotLine.m

@@ -33,8 +33,8 @@
 }
 
 - (void)removeAllSublayers {
-    for (CALayer *layer in self.layer.sublayers) {
-        [layer removeFromSuperlayer];
+    while (self.layer.sublayers.count) {
+        [self.layer.sublayers.lastObject removeFromSuperlayer];
     }
 }
 

+ 7 - 0
KulexiuForStudent/KulexiuForStudent/Module/Login/Controller/VefiCodeLoginController.m

@@ -93,9 +93,16 @@
     [view showViewCallback:^(NSDictionary * _Nonnull parm) {
         [self veriImageCodeWithParm:parm checkView:weakView];
     }];
+    [view cancelCheck:^{
+        [self displayKeyboard];
+    }];
     [view disPlayImageWithPhone:phoneNo];
 }
 
+- (void)displayKeyboard {
+    [self.bodyView showKeyboard];
+}
+
 // 发送短信 校验图形验证码
 - (void)veriImageCodeWithParm:(NSDictionary *)parm checkView:(VeriCheckView *)checkView {
     [LOADING_MANAGER showHUD];

+ 1 - 1
KulexiuForStudent/KulexiuForStudent/Module/Mine/Feedback/Controller/FeedbackListViewController.m

@@ -145,7 +145,7 @@
                 FeedbackListModel *model = [[FeedbackListModel alloc] initWithDictionary:parm];
                 [self.dataArray addObject:model];
             }
-            if ([[dic ks_dictionaryValueForKey:@"data"] ks_boolValueForKey:@"next"] == NO) {
+            if (sourceArray.count < self.rows) {
                 self.isLoadMore = NO;
             }
         }

+ 4 - 0
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/VeriCheckView.h

@@ -10,6 +10,8 @@
 
 typedef void(^SureCallback)(NSDictionary * _Nonnull parm);
 
+typedef void(^CheckCancelCallback)(void);
+
 NS_ASSUME_NONNULL_BEGIN
 
 @interface VeriCheckView : UIView
@@ -19,6 +21,8 @@ NS_ASSUME_NONNULL_BEGIN
 
 - (void)showViewCallback:(SureCallback)callback;
 
+- (void)cancelCheck:(CheckCancelCallback)callback;
+
 - (void)hiddView;
 
 - (void)disPlayImageWithPhone:(NSString *)phoneNo;

+ 11 - 1
KulexiuForStudent/KulexiuForStudent/Module/Mine/Setting/View/VeriCheckView.m

@@ -26,6 +26,8 @@
 
 @property (nonatomic, strong) UIView *mountView;
 
+@property (nonatomic, copy) CheckCancelCallback cancelCallback;
+
 @end
 
 @implementation VeriCheckView
@@ -106,7 +108,7 @@
 
 - (void)disPlayImageWithPhone:(NSString *)phoneNo {
     self.phoneNo = phoneNo;
-    NSString *url = [NSString stringWithFormat:@"%@%@?phone=%@",hostURL, @"/api-student/code/getImageCode",phoneNo];
+    NSString *url = [NSString stringWithFormat:@"%@%@?phone=%@",hostURL, @"/api-teacher/code/getImageCode",phoneNo];
     [[SDImageCache sharedImageCache] removeImageForKey:url withCompletion:^{
         [self.checkImage sd_setImageWithURL:[NSURL URLWithString:[url getUrlEndcodeString]] placeholderImage:[UIImage imageNamed:@"image_placeholder"] options:SDWebImageRefreshCached];
     }];
@@ -123,6 +125,11 @@
     [self.mountView addSubview:self];
 }
 
+- (void)cancelCheck:(CheckCancelCallback)callback {
+    if (callback) {
+        self.cancelCallback = callback;
+    }
+}
 
 - (void)tapAction:(UITapGestureRecognizer *)g {
     [self endEditing:YES];
@@ -132,6 +139,9 @@
 - (void)hiddView {
     [self endEditing:YES];
     [self removeFromSuperview];
+    if (self.cancelCallback) {
+        self.cancelCallback();
+    }
 }
 
 - (BOOL)textFieldShouldReturn:(UITextField *)textField {

+ 1 - 3
KulexiuForStudent/KulexiuForStudent/Module/Mine/Works/View/MineWorksOpenDisplayCell.m

@@ -53,9 +53,7 @@
 }
 
 - (void)removeColorLayer {
-    for (CALayer *layer in self.likeView.layer.sublayers) {
-        [layer removeFromSuperlayer];
-    }
+    [self.likeView.layer.sublayers makeObjectsPerformSelector:@selector(removeFromSuperlayer)];
 }
 
 - (void)setSelected:(BOOL)selected animated:(BOOL)animated {