2 次代碼提交 dde2f51dff ... c88e968c33

作者 SHA1 備註 提交日期
  wangmeng c88e968c33 Merge branch 'master' of http://gogs.hnwmzp.cn/nzk1/Asteria-APP 2 年之前
  wangmeng 94cbe7c0ec 找回密码页面完成 2 年之前

+ 22 - 2
Asteria.xcodeproj/project.pbxproj

@@ -46,6 +46,8 @@
 		81E257F92A122AC6004EEF71 /* ASUI.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 81E257F82A122AC6004EEF71 /* ASUI.xcassets */; };
 		81E257FD2A12340E004EEF71 /* ASEnterItemV.m in Sources */ = {isa = PBXBuildFile; fileRef = 81E257FC2A12340E004EEF71 /* ASEnterItemV.m */; };
 		8C24ECE114420CDEE7B9B22B /* Pods_Asteria.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 54DCE8001991D89B696E7D44 /* Pods_Asteria.framework */; };
+		9A1247942A1B082300126226 /* Fuction_Tool.m in Sources */ = {isa = PBXBuildFile; fileRef = 9A1247932A1B082300126226 /* Fuction_Tool.m */; };
+		9A1247972A1B0A2800126226 /* AS_ForgotC.m in Sources */ = {isa = PBXBuildFile; fileRef = 9A1247962A1B0A2800126226 /* AS_ForgotC.m */; };
 		9A2027F52A137B8600FF4DAF /* AuthenticationServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9A2027F42A137B8600FF4DAF /* AuthenticationServices.framework */; };
 		9A337E3A2A04EE1A00D058A5 /* Target_B.m in Sources */ = {isa = PBXBuildFile; fileRef = 9A337E362A04EE1A00D058A5 /* Target_B.m */; };
 		9A337E3B2A04EE1A00D058A5 /* BViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9A337E392A04EE1A00D058A5 /* BViewController.m */; };
@@ -201,6 +203,10 @@
 		81E257F82A122AC6004EEF71 /* ASUI.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = ASUI.xcassets; sourceTree = "<group>"; };
 		81E257FB2A12340E004EEF71 /* ASEnterItemV.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ASEnterItemV.h; sourceTree = "<group>"; };
 		81E257FC2A12340E004EEF71 /* ASEnterItemV.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ASEnterItemV.m; sourceTree = "<group>"; };
+		9A1247922A1B082300126226 /* Fuction_Tool.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Fuction_Tool.h; sourceTree = "<group>"; };
+		9A1247932A1B082300126226 /* Fuction_Tool.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = Fuction_Tool.m; sourceTree = "<group>"; };
+		9A1247952A1B0A2800126226 /* AS_ForgotC.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AS_ForgotC.h; sourceTree = "<group>"; };
+		9A1247962A1B0A2800126226 /* AS_ForgotC.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AS_ForgotC.m; sourceTree = "<group>"; };
 		9A2027F32A137B6A00FF4DAF /* Asteria.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Asteria.entitlements; sourceTree = "<group>"; };
 		9A2027F42A137B8600FF4DAF /* AuthenticationServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AuthenticationServices.framework; path = System/Library/Frameworks/AuthenticationServices.framework; sourceTree = SDKROOT; };
 		9A337E362A04EE1A00D058A5 /* Target_B.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Target_B.m; sourceTree = "<group>"; };
@@ -561,9 +567,19 @@
 			path = CutomBottomBar;
 			sourceTree = "<group>";
 		};
+		9A1247912A1B07F400126226 /* Tool */ = {
+			isa = PBXGroup;
+			children = (
+				9A1247922A1B082300126226 /* Fuction_Tool.h */,
+				9A1247932A1B082300126226 /* Fuction_Tool.m */,
+			);
+			path = Tool;
+			sourceTree = "<group>";
+		};
 		9A2646BA2A187B6100CBFBDC /* Product */ = {
 			isa = PBXGroup;
 			children = (
+				9A1247912A1B07F400126226 /* Tool */,
 				9AD364CD2A05EC2700452C7A /* Config */,
 				9ACBEC1E2A1457E800A8F97A /* CTMediatoaTargets */,
 			);
@@ -635,10 +651,10 @@
 		9A65DE4E2A132BDF00BB1269 /* V */ = {
 			isa = PBXGroup;
 			children = (
-				9A65DE4F2A132FB700BB1269 /* LoginThirdAuthV.h */,
 				9ACBEC262A1472AF00A8F97A /* LoginSignUpV.h */,
-				9A65DE502A132FB700BB1269 /* LoginThirdAuthV.m */,
 				9ACBEC272A1472AF00A8F97A /* LoginSignUpV.m */,
+				9A65DE4F2A132FB700BB1269 /* LoginThirdAuthV.h */,
+				9A65DE502A132FB700BB1269 /* LoginThirdAuthV.m */,
 			);
 			path = V;
 			sourceTree = "<group>";
@@ -677,6 +693,8 @@
 				9A5C64572A12064300CBB185 /* AS_LoginC.m */,
 				9ACBEC232A14707400A8F97A /* AS_SignUpC.h */,
 				9ACBEC242A14707400A8F97A /* AS_SignUpC.m */,
+				9A1247952A1B0A2800126226 /* AS_ForgotC.h */,
+				9A1247962A1B0A2800126226 /* AS_ForgotC.m */,
 			);
 			path = VC;
 			sourceTree = "<group>";
@@ -1186,6 +1204,7 @@
 				9AD3459E2A08D545005CA070 /* GoodsDetailSrcView.m in Sources */,
 				9AD346022A08D60F005CA070 /* ZFPlayerView.m in Sources */,
 				81C3B44429F6612800D79294 /* ASBaseViewController.m in Sources */,
+				9A1247942A1B082300126226 /* Fuction_Tool.m in Sources */,
 				9AD6A5442A1218E8001DE3D9 /* PassWordSecureBtnV.m in Sources */,
 				81C3B44A29F6661500D79294 /* ASBaseNavController.m in Sources */,
 				9AD3460C2A08D60F005CA070 /* ZFVolumeBrightnessView.m in Sources */,
@@ -1197,6 +1216,7 @@
 				9A65DE512A132FB700BB1269 /* LoginThirdAuthV.m in Sources */,
 				9A788C442A08A663003E0025 /* Target_Goods.m in Sources */,
 				9AD3461D2A08D6F0005CA070 /* GoodsInformationM.m in Sources */,
+				9A1247972A1B0A2800126226 /* AS_ForgotC.m in Sources */,
 				9AD345A82A08D571005CA070 /* TYCyclePagerView.m in Sources */,
 				9AD346202A08E30E005CA070 /* SelectVCollectionViewCell.m in Sources */,
 				8134C1BA2A1372A7006EB0EC /* ASUserCenterEnterItemV.m in Sources */,

+ 5 - 0
Asteria/Fuction/Login/V/LoginSignUpV.m

@@ -296,9 +296,14 @@
         @weakify(self)
         [attributed yy_setTextHighlightRange:[string rangeOfString:@"Terms & Conditions"] color:ThemeColor backgroundColor:[UIColor clearColor] tapAction:^(UIView * _Nonnull containerView, NSAttributedString * _Nonnull text, NSRange range, CGRect rect) {
             NSLog(@"----");
+            NSString *temrUrl = [NSString stringWithFormat:@"%@terms-conditions",AS_WebSever];
+            [Fuction_Tool push_BaseWebUrl:temrUrl webTitle:@"Terms & Conditions"];
         }];
         [attributed yy_setTextHighlightRange:[string rangeOfString:@"Privacy Policy"] color:ThemeColor backgroundColor:[UIColor clearColor] tapAction:^(UIView * _Nonnull containerView, NSAttributedString * _Nonnull text, NSRange range, CGRect rect) {
             NSLog(@"----");
+            NSString *PrivacyUrl = [NSString stringWithFormat:@"%@privacy_policy",AS_WebSever];
+
+            [Fuction_Tool push_BaseWebUrl:PrivacyUrl webTitle:@"Privacy Policy"];
         }];
         _xxx_ClickLab.attributedText = attributed;
         _xxx_ClickLab.font = [UIFont systemFontOfSize:12];

+ 16 - 0
Asteria/Fuction/Login/VC/AS_ForgotC.h

@@ -0,0 +1,16 @@
+//
+//  AS_ForgotC.h
+//  Asteria
+//
+//  Created by 王猛 on 2023/5/22.
+//
+
+#import <WMBase/WMBase.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface AS_ForgotC : UCMBaseC
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 152 - 0
Asteria/Fuction/Login/VC/AS_ForgotC.m

@@ -0,0 +1,152 @@
+//
+//  AS_ForgotC.m
+//  Asteria
+//
+//  Created by 王猛 on 2023/5/22.
+//
+
+#import "AS_ForgotC.h"
+#import "EamilTFmatchV.h"
+
+
+@interface AS_ForgotC ()
+@property (nonatomic, strong) UIScrollView *scrollview;
+@property (nonatomic, strong) EamilTFmatchV *xxx_emailTFV;
+@property (nonatomic, strong) UIButton *xxx_sureBtn;
+
+@end
+
+@implementation AS_ForgotC
+
+- (void)viewDidLoad {
+    [super viewDidLoad];
+    // Do any additional setup after loading the view.
+    self.customNavBar.hidden = YES;
+    self.navigationController.navigationBar.hidden = YES;
+}
+- (void)initSubviews{
+    [super initSubviews];
+    [self.view addSubview:self.scrollview];
+    UIView *topNavV = [self logNavView];
+    [self.scrollview addSubview:topNavV];
+    
+    UILabel *titileLab = [UILabel new];
+    titileLab.text = @"RETRIEVE YOUR PASSWORD";
+    titileLab.font = [UIFont boldSystemFontOfSize:16];
+    titileLab.textAlignment = NSTextAlignmentCenter;
+    titileLab.textColor = [UIColor colorWithHexString:@"#000000"];
+    [self.scrollview addSubview:titileLab];
+    titileLab.frame = CGRectMake(20, CGRectGetMaxY(topNavV.frame)+50, KScreenWidth-40, 20);
+    
+    YYLabel *detailLab = [YYLabel new];
+    detailLab.text =  @"If You Forgotten Your Password, Please Enter Your Registered Email Address.\n\n\n You’ll Receive A Link To Reset Your Password.";
+    detailLab.textAlignment = NSTextAlignmentCenter;
+    detailLab.font =  [UIFont systemFontOfSize:14];
+    detailLab.numberOfLines = 0;
+    [self.scrollview addSubview:detailLab];
+    detailLab.frame = CGRectMake(36, CGRectGetMaxY(titileLab.frame)+15, KScreenWidth-72, 100);
+    
+    [self.scrollview addSubview:self.xxx_emailTFV];
+    self.xxx_emailTFV.mj_y = detailLab.maxY+20;
+    
+    [self.scrollview addSubview:self.xxx_sureBtn];
+    self.xxx_sureBtn.mj_y = self.xxx_emailTFV.maxY+30;
+    
+    [self.scrollview bringSubviewToFront:self.xxx_emailTFV];
+    
+}
+
+    #pragma mark - **************** handle ****************
+-(void)handle_closeEvent{
+    [self.navigationController popViewControllerAnimated:YES];
+
+}
+-(void)action_submitClick:(UIButton *)btn{
+    if (![Current_normalTool xxx_isValidateEmail:self.xxx_emailTFV.xxx_emailTF.text]) {
+        [self.view makeToast:@"Please prvide an email address." duration:2 position:CSToastPositionCenter];
+        return;
+    }
+    [self reqNet_forgotPassWord];
+}
+
+
+-(void)reqNet_forgotPassWord{
+    NSString *url = [NSString stringWithFormat:@"%@%@",Formal_Server,@"login/forgotPassword"];
+    NSMutableDictionary *paraDic = [NSMutableDictionary dictionary];
+    [paraDic setObject:self.xxx_emailTFV.xxx_emailTF.text forKey:@"email"];
+    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
+    [PPNetworkHelper POST:url
+               parameters:paraDic
+                  success:^(id responseObject) {
+        [MBProgressHUD hideHUDForView:self.view animated:YES];
+        if (RequestSuccess) {
+            [FTT_Helper CreateTitle:[NSString stringWithFormat:@"If there is an account associated %@ you will receive an email with a link to reset your password.",self.xxx_emailTFV.xxx_emailTF.text] message:nil Sure:@"Sure" preferredStyle:UIAlertControllerStyleAlert action:^{
+                [self handle_closeEvent];
+            } ViewController:self];
+        }else{
+            [self.view makeToast:RequestErrorMsg duration:2 position:CSToastPositionCenter];
+        }
+    } failure:^(NSError *error) {
+        [MBProgressHUD hideHUDForView:self.view animated:YES];
+        [self.view makeToast:ReqNetWorkFaild duration:2 position:CSToastPositionCenter];
+    }];
+}
+
+
+-(UIView *)logNavView{
+    IPhoneXHeigh
+    UIView *topView = [[UIView alloc]initWithFrame:CGRectMake(0, 0, KScreenWidth, securitytop_Y)];
+    UIButton *closeBtn = [UIButton buttonWithType:UIButtonTypeCustom];
+    [closeBtn setImage:[UIImage imageNamed:@"common_close"] forState:UIControlStateNormal];
+    [closeBtn addTarget:self action:@selector(handle_closeEvent) forControlEvents:UIControlEventTouchUpInside];
+    closeBtn.frame = CGRectMake(20, 44, 44, 44);
+    [topView addSubview:closeBtn];
+    UIImageView *headImg = [[UIImageView alloc]init];
+    UIImage *bannerImg = [UIImage imageNamed:@"common_headLogo"];
+    headImg.image = bannerImg ;
+    headImg.frame = CGRectMake((KScreenWidth- bannerImg.size.width)/2, 20 , bannerImg.size.width, bannerImg.size.height);
+    [topView addSubview:headImg];
+    closeBtn.centerY = topView.centerY;
+    headImg.centerY = topView.centerY;
+    return topView;
+}
+
+-(EamilTFmatchV *)xxx_emailTFV{
+    if (!_xxx_emailTFV) {
+        _xxx_emailTFV = [[EamilTFmatchV alloc]initWithFrame:CGRectMake(0, 0, KScreenWidth, 50)];
+        _xxx_emailTFV.xxx_emailTF.placeholder =  @"* Email Address";
+    }
+    return _xxx_emailTFV;
+}
+
+
+
+-(UIButton *)xxx_sureBtn{
+    if (!_xxx_sureBtn) {
+        _xxx_sureBtn = [TT_ControlTool FTT_ControlToolUIButtonFrame:CGRectMake(20,0 ,KScreenWidth-40,50)
+                                                                 taeget:self
+                                                                sel:@selector(action_submitClick:)
+                                                                    tag:0
+                                                               AntTitle:@"SUBMIT"
+                                                              titleFont:17
+                                                             titleColor:[UIColor whiteColor]
+                                                               andImage:nil
+                                                           AndBackColor:nil
+                                                adjustsFontSizesTowidth:NO
+                                                          masksToBounds:YES
+                                                           conrenRadius:5
+                                                            BorderColor:nil
+                                                            BorderWidth:0
+                                              ContentHorizontalAligment:0];
+        _xxx_sureBtn.backgroundColor = ThemeColor;
+    }
+    return _xxx_sureBtn;
+}
+- (UIScrollView *)scrollview {
+    if (!_scrollview) {
+        _scrollview = [[UIScrollView alloc]initWithFrame:CGRectMake(0, 0, KScreenWidth, KScreenHeight)];
+    }
+    return _scrollview;
+}
+
+@end

+ 3 - 1
Asteria/Fuction/Login/VC/AS_LoginC.m

@@ -12,6 +12,7 @@
 
 #import <AFNetworking/AFNetworking.h>
 #import "AS_SignUpC.h"
+#import "AS_ForgotC.h"
 
 
 
@@ -113,7 +114,8 @@
     
 }
 -(void)handle_forgetBtnEvent:(UIButton *)btn{
-    
+    AS_ForgotC *forgoC = [[AS_ForgotC alloc]init];
+    [self.navigationController pushViewController:forgoC animated:YES];
 }
 
 #pragma mark - **************** 懒加载 ****************

+ 3 - 0
Asteria/PreFixHeader.h

@@ -18,10 +18,13 @@
 //所有功能模块需要依赖的 项目(需变化)特定内容,相关内容和不变化的Base无关
 #import "ProjectConfigDefine.h"
 #import "CTMediator+ASTargerts.h"
+#import "Fuction_Tool.h"
 //当功能模块变成Pod后,需要的依赖
 //#import <Product/ProjectConfigDefine.h>
 //#import <WMBase/CTMediator+ASTargerts.h>
 
+
+
 ///基础库的导入内容
 #import <WMBase/WMBase.h>
 ///Base库的依赖,放项目中加快build

+ 2 - 2
Asteria/Product/CTMediatoaTargets/CTMediator+ASTargerts.h

@@ -6,7 +6,7 @@
 //
 
 
-///wm_tips: 本质上只是一个方便方法,它对任何的 模块不存在任何依赖,项目在确定用的模块的时候,再次拿出来需要使用的方法
+///wm_tips: 本质上只是一个方便方法,它对任何的 模块不存在任何依赖,项目在确定模块的时候,再次拿出来需要使用的方法
 ///如果某个模块功能变化,只需要在它外面包一个Target-Action,就可以直接拿来用了。而且包Target-Action的过程中,不会对现有项目产生任何侵入性的影响。
 #import <CTMediator/CTMediator.h>
 #import <UIKit/UIKit.h>
@@ -23,7 +23,7 @@ NS_ASSUME_NONNULL_BEGIN
 ///登录页面
 -(UIViewController *)Login_LoginC:(NSDictionary *)params;
 
-
+///个页面
 -(UIViewController *)getUserCenterVc:(NSDictionary *)params;
 
 

+ 3 - 2
Asteria/Product/CTMediatoaTargets/CTMediator+ASTargerts.m

@@ -22,9 +22,10 @@
     return [self performTarget:@"Login" action:@"AS_LoginC" params:params shouldCacheTarget:NO];
 }
 
-
-
 -(UIViewController *)getUserCenterVc:(NSDictionary *)params{
     return [self performTarget:@"userCenter" action:@"getUserCenterVc" params:params shouldCacheTarget:NO];
 }
+
+
+
 @end

+ 1 - 0
Asteria/Product/Config/ProjectConfigDefine.h

@@ -9,6 +9,7 @@
 #define ProjectConfigDefine_h
 
 ///wm_tips 所有的pod模块的特定化依赖,每个Project修改,额、
+///
 ///////正式服务器
 #define WebBase_Server @"https://app.westkiss.com/"
 #define Formal_Server @"https://app.westkiss.com/app-api/"

+ 18 - 0
Asteria/Product/Tool/Fuction_Tool.h

@@ -0,0 +1,18 @@
+//
+//  Fuction_Tool.h
+//  Asteria
+//
+//  Created by 王猛 on 2023/5/22.
+//
+
+#import <Foundation/Foundation.h>
+#import <WMBase/XXX_BaseWebC.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+@interface Fuction_Tool : NSObject
++(void)push_BaseWebUrl:(NSString *)url webTitle:(NSString *)title;
++(void)push_JSBaseWebUrl:(NSString *)url webTitle:(NSString *)title;
+@end
+
+NS_ASSUME_NONNULL_END

+ 27 - 0
Asteria/Product/Tool/Fuction_Tool.m

@@ -0,0 +1,27 @@
+//
+//  Fuction_Tool.m
+//  Asteria
+//
+//  Created by 王猛 on 2023/5/22.
+//
+
+#import "Fuction_Tool.h"
+
+@implementation Fuction_Tool
++(void)push_BaseWebUrl:(NSString *)url webTitle:(NSString *)title{
+    XXX_BaseWebC *vc = [[XXX_BaseWebC alloc] init];
+    [vc xxx_dsWebLoadUrl:url];
+    vc.webTitle = title;
+    [[Current_normalTool topViewController].navigationController pushViewController:vc animated:true];
+}
++(void)push_JSBaseWebUrl:(NSString *)url webTitle:(NSString *)title{
+    XXX_BaseWebC *vc = [[XXX_BaseWebC alloc] init];
+    [vc xxx_dsWebLoadUrl:url];
+    vc.webTitle = title;
+    [vc tool_dsWebViewAddJS];
+    [[Current_normalTool topViewController].navigationController pushViewController:vc animated:true];
+}
+
+
+
+@end

+ 0 - 1
Asteria/Tabber/AS_TabBarViewController.m

@@ -30,7 +30,6 @@
     
     NSArray *selimgArr = @[@"tab_search", @"tab_home", @"tab_mine"];
     NSMutableArray *tabvcAry = [[NSMutableArray alloc]init];
-
     for (int i= 0; i<titleArr.count; i++) {
         QMUINavigationController *uikitNavController = [[QMUINavigationController alloc] initWithRootViewController:vcAry[i]];
         UITabBarItem *tabBarItem = [[UITabBarItem alloc] initWithTitle:titleArr[i] image:UIImageMake(imgArr[i]) tag:i];