1
0

2 Komitmen 799a88c63c ... d43df55f03

Pembuat SHA1 Pesan Tanggal
  culturetown d43df55f03 Merge branch '推广版' of https://git.jdnx.me/tomy/JD_iOS into 推广版 1 hari lalu
  culturetown 900de86f78 登录注册忘记密码相关无用代码清除。 1 hari lalu

+ 0 - 60
Koala/Koala.xcodeproj/project.pbxproj

@@ -77,8 +77,6 @@
 		041D4F052AC42D62008ABDF7 /* JDSelectCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F042AC42D62008ABDF7 /* JDSelectCell.swift */; };
 		041D4F072AC431E5008ABDF7 /* JDSelectReceiveAccountTypeViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F062AC431E5008ABDF7 /* JDSelectReceiveAccountTypeViewController.swift */; };
 		041D4F092AC4367E008ABDF7 /* JDAccountTypeCheckCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F082AC4367E008ABDF7 /* JDAccountTypeCheckCell.swift */; };
-		041D4F0B2AC56484008ABDF7 /* JDLoginView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F0A2AC56484008ABDF7 /* JDLoginView.swift */; };
-		041D4F0D2AC57461008ABDF7 /* JDLoginCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F0C2AC57461008ABDF7 /* JDLoginCell.swift */; };
 		041D4F132AD0FDEB008ABDF7 /* JDAFiatAccountBalanceCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F122AD0FDEB008ABDF7 /* JDAFiatAccountBalanceCell.swift */; };
 		041D4F172AD288F8008ABDF7 /* JDTradeAccountPositionViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F162AD288F8008ABDF7 /* JDTradeAccountPositionViewController.swift */; };
 		041D4F192AD2894E008ABDF7 /* JDTradeAccountHistoryOrderViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 041D4F182AD2894E008ABDF7 /* JDTradeAccountHistoryOrderViewController.swift */; };
@@ -100,11 +98,7 @@
 		042809452B4FF3A8004AE401 /* JDMessageBtn.swift in Sources */ = {isa = PBXBuildFile; fileRef = 042809442B4FF3A8004AE401 /* JDMessageBtn.swift */; };
 		04282A382ADCE17800CB4260 /* JDPhoneInputView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A372ADCE17800CB4260 /* JDPhoneInputView.swift */; };
 		04282A3A2ADCE7A000CB4260 /* JDPasswordInputView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A392ADCE7A000CB4260 /* JDPasswordInputView.swift */; };
-		04282A3C2ADD049700CB4260 /* JDRegisterView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A3B2ADD049700CB4260 /* JDRegisterView.swift */; };
-		04282A3E2ADD067400CB4260 /* JDRegisterCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A3D2ADD067400CB4260 /* JDRegisterCell.swift */; };
 		04282A402ADD08C400CB4260 /* JDCodeInputView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A3F2ADD08C400CB4260 /* JDCodeInputView.swift */; };
-		04282A422ADD10DC00CB4260 /* JDForgotPasswordView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A412ADD10DC00CB4260 /* JDForgotPasswordView.swift */; };
-		04282A442ADD137500CB4260 /* JDForgotPasswordCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A432ADD137500CB4260 /* JDForgotPasswordCell.swift */; };
 		04282A472ADD3D1900CB4260 /* JDTradeMainMenuCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282A462ADD3D1900CB4260 /* JDTradeMainMenuCell.swift */; };
 		0445B3F22B107B4100452BFA /* MDOptionSharePopView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0445B3F12B107B4100452BFA /* MDOptionSharePopView.swift */; };
 		0452C27D2AE226E700B63048 /* JXPagingMainTableView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0452C2762AE226E700B63048 /* JXPagingMainTableView.swift */; };
@@ -666,7 +660,6 @@
 		6C2EAD8429E31F8700E03AF8 /* ApplySharesViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6C2EAD8229E31F8700E03AF8 /* ApplySharesViewController.xib */; };
 		6C2EAD8829E4503500E03AF8 /* ApplySucceedViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6C2EAD8629E4503500E03AF8 /* ApplySucceedViewController.swift */; };
 		6C2EAD8929E4503500E03AF8 /* ApplySucceedViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6C2EAD8729E4503500E03AF8 /* ApplySucceedViewController.xib */; };
-		6C2FFC9A295F5ACC005B8180 /* LoginCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6C2FFC99295F5ACC005B8180 /* LoginCell.xib */; };
 		6C2FFC9C296079E6005B8180 /* TradingPasswordsViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6C2FFC9B296079E6005B8180 /* TradingPasswordsViewController.swift */; };
 		6C2FFC9E29607A07005B8180 /* TradingPasswordsViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6C2FFC9D29607A07005B8180 /* TradingPasswordsViewModel.swift */; };
 		6C2FFCA129607A2A005B8180 /* TradingPasswordsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6C2FFCA029607A2A005B8180 /* TradingPasswordsView.swift */; };
@@ -865,11 +858,9 @@
 		6CA7130F2957034B0047F450 /* PublicModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7130E2957034B0047F450 /* PublicModel.swift */; };
 		6CA71312295717990047F450 /* MineViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA71310295717990047F450 /* MineViewCell.swift */; };
 		6CA71313295717990047F450 /* MineViewCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6CA71311295717990047F450 /* MineViewCell.xib */; };
-		6CA7131529572CBC0047F450 /* LoginViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7131429572CBC0047F450 /* LoginViewController.swift */; };
 		6CA7131729572DBC0047F450 /* LoginViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7131629572DBC0047F450 /* LoginViewModel.swift */; };
 		6CA7131A29572DD70047F450 /* LoginView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7131929572DD70047F450 /* LoginView.swift */; };
 		6CA7131C295737170047F450 /* LoginTopView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7131B295737170047F450 /* LoginTopView.swift */; };
-		6CA7131F29573ADE0047F450 /* LoginCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7131D29573ADE0047F450 /* LoginCell.swift */; };
 		6CA71322295807740047F450 /* BaseInputView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA71321295807740047F450 /* BaseInputView.swift */; };
 		6CA71324295807B10047F450 /* BaseInputView.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6CA71323295807B10047F450 /* BaseInputView.xib */; };
 		6CA7132A2958136E0047F450 /* HMSegmentedControl.m in Sources */ = {isa = PBXBuildFile; fileRef = 6CA713292958136E0047F450 /* HMSegmentedControl.m */; };
@@ -877,16 +868,10 @@
 		6CA7133A2958781C0047F450 /* CountryCode.json in Resources */ = {isa = PBXBuildFile; fileRef = 6CA713392958781C0047F450 /* CountryCode.json */; };
 		6CA7133D29587BE10047F450 /* CountrySelectCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7133B29587BE10047F450 /* CountrySelectCell.swift */; };
 		6CA7133E29587BE10047F450 /* CountrySelectCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6CA7133C29587BE10047F450 /* CountrySelectCell.xib */; };
-		6CA71340295889030047F450 /* RegisterViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7133F295889030047F450 /* RegisterViewController.swift */; };
 		6CA71342295889260047F450 /* RegisterViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA71341295889260047F450 /* RegisterViewModel.swift */; };
 		6CA71345295889770047F450 /* RegisterView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA71344295889770047F450 /* RegisterView.swift */; };
-		6CA7134829588B290047F450 /* RegisterCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7134629588B280047F450 /* RegisterCell.swift */; };
-		6CA7134929588B290047F450 /* RegisterCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6CA7134729588B290047F450 /* RegisterCell.xib */; };
-		6CA7134D2959F6900047F450 /* ForgotPasswordViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7134C2959F68F0047F450 /* ForgotPasswordViewController.swift */; };
 		6CA7134F2959F6AC0047F450 /* ForgotPasswordViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA7134E2959F6AC0047F450 /* ForgotPasswordViewModel.swift */; };
 		6CA713522959F6C40047F450 /* ForgotPasswordView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA713512959F6C40047F450 /* ForgotPasswordView.swift */; };
-		6CA713552959F8F30047F450 /* ForgotPasswordCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA713532959F8F30047F450 /* ForgotPasswordCell.swift */; };
-		6CA713562959F8F30047F450 /* ForgotPasswordCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 6CA713542959F8F30047F450 /* ForgotPasswordCell.xib */; };
 		6CA9FF31295DCEB90097ABA6 /* SecuritySettingsViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA9FF30295DCEB80097ABA6 /* SecuritySettingsViewController.swift */; };
 		6CA9FF33295DCED70097ABA6 /* SecuritySettingsViewModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA9FF32295DCED70097ABA6 /* SecuritySettingsViewModel.swift */; };
 		6CA9FF36295DCEF20097ABA6 /* SecuritySettingsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6CA9FF35295DCEF20097ABA6 /* SecuritySettingsView.swift */; };
@@ -1255,8 +1240,6 @@
 		041D4F042AC42D62008ABDF7 /* JDSelectCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDSelectCell.swift; sourceTree = "<group>"; };
 		041D4F062AC431E5008ABDF7 /* JDSelectReceiveAccountTypeViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDSelectReceiveAccountTypeViewController.swift; sourceTree = "<group>"; };
 		041D4F082AC4367E008ABDF7 /* JDAccountTypeCheckCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDAccountTypeCheckCell.swift; sourceTree = "<group>"; };
-		041D4F0A2AC56484008ABDF7 /* JDLoginView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDLoginView.swift; sourceTree = "<group>"; };
-		041D4F0C2AC57461008ABDF7 /* JDLoginCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDLoginCell.swift; sourceTree = "<group>"; };
 		041D4F122AD0FDEB008ABDF7 /* JDAFiatAccountBalanceCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDAFiatAccountBalanceCell.swift; sourceTree = "<group>"; };
 		041D4F162AD288F8008ABDF7 /* JDTradeAccountPositionViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDTradeAccountPositionViewController.swift; sourceTree = "<group>"; };
 		041D4F182AD2894E008ABDF7 /* JDTradeAccountHistoryOrderViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDTradeAccountHistoryOrderViewController.swift; sourceTree = "<group>"; };
@@ -1278,11 +1261,7 @@
 		042809442B4FF3A8004AE401 /* JDMessageBtn.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDMessageBtn.swift; sourceTree = "<group>"; };
 		04282A372ADCE17800CB4260 /* JDPhoneInputView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDPhoneInputView.swift; sourceTree = "<group>"; };
 		04282A392ADCE7A000CB4260 /* JDPasswordInputView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDPasswordInputView.swift; sourceTree = "<group>"; };
-		04282A3B2ADD049700CB4260 /* JDRegisterView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDRegisterView.swift; sourceTree = "<group>"; };
-		04282A3D2ADD067400CB4260 /* JDRegisterCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDRegisterCell.swift; sourceTree = "<group>"; };
 		04282A3F2ADD08C400CB4260 /* JDCodeInputView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDCodeInputView.swift; sourceTree = "<group>"; };
-		04282A412ADD10DC00CB4260 /* JDForgotPasswordView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDForgotPasswordView.swift; sourceTree = "<group>"; };
-		04282A432ADD137500CB4260 /* JDForgotPasswordCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDForgotPasswordCell.swift; sourceTree = "<group>"; };
 		04282A462ADD3D1900CB4260 /* JDTradeMainMenuCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = JDTradeMainMenuCell.swift; sourceTree = "<group>"; };
 		0445B3F12B107B4100452BFA /* MDOptionSharePopView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MDOptionSharePopView.swift; sourceTree = "<group>"; };
 		0452C2762AE226E700B63048 /* JXPagingMainTableView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = JXPagingMainTableView.swift; sourceTree = "<group>"; };
@@ -1851,7 +1830,6 @@
 		6C2EAD8229E31F8700E03AF8 /* ApplySharesViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = ApplySharesViewController.xib; sourceTree = "<group>"; };
 		6C2EAD8629E4503500E03AF8 /* ApplySucceedViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApplySucceedViewController.swift; sourceTree = "<group>"; };
 		6C2EAD8729E4503500E03AF8 /* ApplySucceedViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = ApplySucceedViewController.xib; sourceTree = "<group>"; };
-		6C2FFC99295F5ACC005B8180 /* LoginCell.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = LoginCell.xib; sourceTree = "<group>"; };
 		6C2FFC9B296079E6005B8180 /* TradingPasswordsViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TradingPasswordsViewController.swift; sourceTree = "<group>"; };
 		6C2FFC9D29607A07005B8180 /* TradingPasswordsViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TradingPasswordsViewModel.swift; sourceTree = "<group>"; };
 		6C2FFCA029607A2A005B8180 /* TradingPasswordsView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TradingPasswordsView.swift; sourceTree = "<group>"; };
@@ -2050,11 +2028,9 @@
 		6CA7130E2957034B0047F450 /* PublicModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PublicModel.swift; sourceTree = "<group>"; };
 		6CA71310295717990047F450 /* MineViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MineViewCell.swift; sourceTree = "<group>"; };
 		6CA71311295717990047F450 /* MineViewCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MineViewCell.xib; sourceTree = "<group>"; };
-		6CA7131429572CBC0047F450 /* LoginViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LoginViewController.swift; sourceTree = "<group>"; };
 		6CA7131629572DBC0047F450 /* LoginViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LoginViewModel.swift; sourceTree = "<group>"; };
 		6CA7131929572DD70047F450 /* LoginView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LoginView.swift; sourceTree = "<group>"; };
 		6CA7131B295737170047F450 /* LoginTopView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LoginTopView.swift; sourceTree = "<group>"; };
-		6CA7131D29573ADE0047F450 /* LoginCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LoginCell.swift; sourceTree = "<group>"; };
 		6CA71321295807740047F450 /* BaseInputView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseInputView.swift; sourceTree = "<group>"; };
 		6CA71323295807B10047F450 /* BaseInputView.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = BaseInputView.xib; sourceTree = "<group>"; };
 		6CA713282958136E0047F450 /* HMSegmentedControl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HMSegmentedControl.h; sourceTree = "<group>"; };
@@ -2064,16 +2040,10 @@
 		6CA713392958781C0047F450 /* CountryCode.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = CountryCode.json; sourceTree = "<group>"; };
 		6CA7133B29587BE10047F450 /* CountrySelectCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CountrySelectCell.swift; sourceTree = "<group>"; };
 		6CA7133C29587BE10047F450 /* CountrySelectCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = CountrySelectCell.xib; sourceTree = "<group>"; };
-		6CA7133F295889030047F450 /* RegisterViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RegisterViewController.swift; sourceTree = "<group>"; };
 		6CA71341295889260047F450 /* RegisterViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RegisterViewModel.swift; sourceTree = "<group>"; };
 		6CA71344295889770047F450 /* RegisterView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RegisterView.swift; sourceTree = "<group>"; };
-		6CA7134629588B280047F450 /* RegisterCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RegisterCell.swift; sourceTree = "<group>"; };
-		6CA7134729588B290047F450 /* RegisterCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = RegisterCell.xib; sourceTree = "<group>"; };
-		6CA7134C2959F68F0047F450 /* ForgotPasswordViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ForgotPasswordViewController.swift; sourceTree = "<group>"; };
 		6CA7134E2959F6AC0047F450 /* ForgotPasswordViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ForgotPasswordViewModel.swift; sourceTree = "<group>"; };
 		6CA713512959F6C40047F450 /* ForgotPasswordView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ForgotPasswordView.swift; sourceTree = "<group>"; };
-		6CA713532959F8F30047F450 /* ForgotPasswordCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ForgotPasswordCell.swift; sourceTree = "<group>"; };
-		6CA713542959F8F30047F450 /* ForgotPasswordCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = ForgotPasswordCell.xib; sourceTree = "<group>"; };
 		6CA9FF30295DCEB80097ABA6 /* SecuritySettingsViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SecuritySettingsViewController.swift; sourceTree = "<group>"; };
 		6CA9FF32295DCED70097ABA6 /* SecuritySettingsViewModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SecuritySettingsViewModel.swift; sourceTree = "<group>"; };
 		6CA9FF35295DCEF20097ABA6 /* SecuritySettingsView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SecuritySettingsView.swift; sourceTree = "<group>"; };
@@ -4562,11 +4532,7 @@
 			children = (
 				6CA7131929572DD70047F450 /* LoginView.swift */,
 				6CA7131B295737170047F450 /* LoginTopView.swift */,
-				6CA7131D29573ADE0047F450 /* LoginCell.swift */,
 				045E7DD92B5A674D008987BA /* JDLoginNewCell.swift */,
-				6C2FFC99295F5ACC005B8180 /* LoginCell.xib */,
-				041D4F0A2AC56484008ABDF7 /* JDLoginView.swift */,
-				041D4F0C2AC57461008ABDF7 /* JDLoginCell.swift */,
 				04282A372ADCE17800CB4260 /* JDPhoneInputView.swift */,
 				04282A392ADCE7A000CB4260 /* JDPasswordInputView.swift */,
 				04282A3F2ADD08C400CB4260 /* JDCodeInputView.swift */,
@@ -4598,11 +4564,8 @@
 		6CA71330295823860047F450 /* VC */ = {
 			isa = PBXGroup;
 			children = (
-				6CA7131429572CBC0047F450 /* LoginViewController.swift */,
 				045E7DD72B592C95008987BA /* JDLoginViewController.swift */,
-				6CA7133F295889030047F450 /* RegisterViewController.swift */,
 				045E7DE12B5A8C12008987BA /* JDRegisterViewController.swift */,
-				6CA7134C2959F68F0047F450 /* ForgotPasswordViewController.swift */,
 				045E7DDB2B5A79B5008987BA /* JDForgotPasswordViewController.swift */,
 			);
 			path = VC;
@@ -4632,11 +4595,7 @@
 			isa = PBXGroup;
 			children = (
 				6CA71344295889770047F450 /* RegisterView.swift */,
-				6CA7134629588B280047F450 /* RegisterCell.swift */,
 				045E7DE32B5A8F4A008987BA /* JDRegisterNewCell.swift */,
-				6CA7134729588B290047F450 /* RegisterCell.xib */,
-				04282A3B2ADD049700CB4260 /* JDRegisterView.swift */,
-				04282A3D2ADD067400CB4260 /* JDRegisterCell.swift */,
 				04BBF5E42C50A6E0003137FE /* JDRegisterProtocolCell.swift */,
 				04BBF5E82C50DD1B003137FE /* JDRegisterInviteCodeCell.swift */,
 			);
@@ -4649,10 +4608,6 @@
 				6CA713512959F6C40047F450 /* ForgotPasswordView.swift */,
 				045E7DDD2B5A7AD8008987BA /* JDForgotPasswordTopView.swift */,
 				045E7DDF2B5A7EDE008987BA /* JDForgotPasswordNewCell.swift */,
-				6CA713532959F8F30047F450 /* ForgotPasswordCell.swift */,
-				6CA713542959F8F30047F450 /* ForgotPasswordCell.xib */,
-				04282A412ADD10DC00CB4260 /* JDForgotPasswordView.swift */,
-				04282A432ADD137500CB4260 /* JDForgotPasswordCell.swift */,
 			);
 			path = ForgotPassword;
 			sourceTree = "<group>";
@@ -5289,7 +5244,6 @@
 				6CD200B829E709A600F0966D /* ASavingsDetailsScreenPopView.xib in Resources */,
 				6CBB62D32AD820130045A4C9 /* MarketDetailNavView.xib in Resources */,
 				6C10F10429DB08D900B79491 /* updateAPP006.png in Resources */,
-				6CA713562959F8F30047F450 /* ForgotPasswordCell.xib in Resources */,
 				6C4AFAD9299D1FD100508EA7 /* AFiatDepositsCell.xib in Resources */,
 				6C4AFAC8299A7A3500508EA7 /* AddAddressViewController.xib in Resources */,
 				6C10F0F229DB08D900B79491 /* updateAPP100.png in Resources */,
@@ -5333,7 +5287,6 @@
 				6C4AFB3F29A7CB2C00508EA7 /* MessageCell.xib in Resources */,
 				6CC37FCB298EC1AD0079FA5C /* DealClosedPopView.xib in Resources */,
 				4066732B2C1856500090561B /* CTKLineUpsDownsCell.xib in Resources */,
-				6CA7134929588B290047F450 /* RegisterCell.xib in Resources */,
 				6CDC5B1329D01A2B00E60730 /* AssetsTotalRecordCell.xib in Resources */,
 				6C10F0EB29DB08D900B79491 /* updateAPP102.png in Resources */,
 				6C10F0F829DB08D900B79491 /* updateAPP070.png in Resources */,
@@ -5366,7 +5319,6 @@
 				6C10F0D029DB08D900B79491 /* updateAPP022.png in Resources */,
 				6C7A1AF629F82BCC004CFBE3 /* CreditsListCell.xib in Resources */,
 				6C86530829AFAC5400A2E7FB /* TDProfitInfoCell.xib in Resources */,
-				6C2FFC9A295F5ACC005B8180 /* LoginCell.xib in Resources */,
 				6CBB62CB2AD6EFD80045A4C9 /* MarketOptionsListCell.xib in Resources */,
 				6C10F10029DB08D900B79491 /* updateAPP014.png in Resources */,
 				6C86531229B47ED000A2E7FB /* TDOrderListCell.xib in Resources */,
@@ -5616,7 +5568,6 @@
 				0428092D2B3D9A4D004AE401 /* JDMineVipTermCell.swift in Sources */,
 				04B788CE2B22D64400FF3027 /* OptionsMenuEditPopView.swift in Sources */,
 				6CD200BB29E8447C00F0966D /* AWalletRecordListCell.swift in Sources */,
-				04282A3E2ADD067400CB4260 /* JDRegisterCell.swift in Sources */,
 				406672F12C1852630090561B /* ChartStyle.swift in Sources */,
 				6CC37FAD2988EEA70079FA5C /* DealSectionView.swift in Sources */,
 				045E7DE02B5A7EDE008987BA /* JDForgotPasswordNewCell.swift in Sources */,
@@ -5873,7 +5824,6 @@
 				6CBB62DB2AD828550045A4C9 /* MDNewsView.swift in Sources */,
 				0452C27D2AE226E700B63048 /* JXPagingMainTableView.swift in Sources */,
 				04CEE2B82ABD3ACA00FAA760 /* JDWorkOrderDetailViewController.swift in Sources */,
-				6CA713552959F8F30047F450 /* ForgotPasswordCell.swift in Sources */,
 				652B91182B9B545000DA1479 /* HomeTopLoginCell.swift in Sources */,
 				6C00A8F5242D918D00CE9ADB /* ESTabBarController.swift in Sources */,
 				658AE9902B67911C00BB26CA /* OptopnsContainerView.swift in Sources */,
@@ -5968,7 +5918,6 @@
 				657428BD2BC27DF10001DAA4 /* TagListView.swift in Sources */,
 				0409C9EB2AF9E0B300103E9B /* JDADepositCoinViewController.swift in Sources */,
 				041D4F052AC42D62008ABDF7 /* JDSelectCell.swift in Sources */,
-				6CA7134D2959F6900047F450 /* ForgotPasswordViewController.swift in Sources */,
 				6CDC5AFE29CE127900E60730 /* TransferHistoryListCell.swift in Sources */,
 				6C86531529B492DA00A2E7FB /* TDUserListCell.swift in Sources */,
 				6CBB634E2ADEDDEC0045A4C9 /* MDPMajorListCell.swift in Sources */,
@@ -6038,7 +5987,6 @@
 				6C00A90A242D918D00CE9ADB /* OperationalAlertView.swift in Sources */,
 				84992CAD2C574DEC00F8E35D /* KKTRLiteInfoView.swift in Sources */,
 				6C86531129B47ED000A2E7FB /* TDOrderListCell.swift in Sources */,
-				6CA7131F29573ADE0047F450 /* LoginCell.swift in Sources */,
 				6CA7131729572DBC0047F450 /* LoginViewModel.swift in Sources */,
 				04FAA55E2C006238003AA6BF /* OpenPositionPopView.swift in Sources */,
 				04BE179A2B0B0F47006B8FB2 /* JDDepositOnChainVerifyViewController.swift in Sources */,
@@ -6075,8 +6023,6 @@
 				6C7A1ACC29F2C495004CFBE3 /* AssetsDealSetAmountPopView.swift in Sources */,
 				6CC37FC9298EC19C0079FA5C /* DealClosedPopView.swift in Sources */,
 				6C2FFCA429607AB7005B8180 /* TradingPasswordsCell.swift in Sources */,
-				041D4F0B2AC56484008ABDF7 /* JDLoginView.swift in Sources */,
-				04282A422ADD10DC00CB4260 /* JDForgotPasswordView.swift in Sources */,
 				6CC37FE2298FB0410079FA5C /* AssetsFinanceViewModel.swift in Sources */,
 				6CBB63322ADD75750045A4C9 /* MSHotCell.swift in Sources */,
 				6C00A98B2433313300CE9ADB /* HXImagePickerController.swift in Sources */,
@@ -6139,7 +6085,6 @@
 				048FE11E2B91BA9C00B8314A /* JDSystemNotificationView.swift in Sources */,
 				65C339662BA144F9007D2E51 /* MarketViewModel.swift in Sources */,
 				0409C9FE2AFE25B900103E9B /* JDTradeWalletSelectDatePopView.swift in Sources */,
-				6CA7131529572CBC0047F450 /* LoginViewController.swift in Sources */,
 				0409C9F82AFC830B00103E9B /* JDDepositOnChainCell.swift in Sources */,
 				6C00A915242D918D00CE9ADB /* PublicMethod.swift in Sources */,
 				0452C2802AE226E700B63048 /* JXPagingListRefreshView.swift in Sources */,
@@ -6209,7 +6154,6 @@
 				041D4EEA2AC14E20008ABDF7 /* JDSearchBarView.swift in Sources */,
 				659B415A2BAC08C600221586 /* OptionalStockViewModel.swift in Sources */,
 				0409C9C62AEFB82700103E9B /* JDDepositVerifyViewController.swift in Sources */,
-				041D4F0D2AC57461008ABDF7 /* JDLoginCell.swift in Sources */,
 				041D4F132AD0FDEB008ABDF7 /* JDAFiatAccountBalanceCell.swift in Sources */,
 				6C8652FF29ABB1A500A2E7FB /* TDStatisticsRecordCell.swift in Sources */,
 				04D38E7D2A9EE8A10047EF9C /* JXSegmentedNumberItemModel.swift in Sources */,
@@ -6277,7 +6221,6 @@
 				6C66AB722AE3A3C4005C471D /* MDOptionsRateCell.swift in Sources */,
 				6C3717E029AA52EF000DDD8B /* TalentDetailsViewModel.swift in Sources */,
 				0409C9B32AEB9A4100103E9B /* JDTradeOptionWaitCell.swift in Sources */,
-				6CA7134829588B290047F450 /* RegisterCell.swift in Sources */,
 				0477865E2B0392E200A81A71 /* HomeNewsCell.swift in Sources */,
 				04CEE2982ABBCC8A00FAA760 /* JDFinancialRecordsMainViewController.swift in Sources */,
 				04CEE2A22ABC247300FAA760 /* JDMessageViewController.swift in Sources */,
@@ -6295,7 +6238,6 @@
 				04E727032BC5370B00BD07EB /* JDContractTradingNotiCell.swift in Sources */,
 				6C031B1F2962C4DA0043BECF /* RealNameFileCell.swift in Sources */,
 				6CCAA19F2AEE1B3D000510FB /* AccountSelectPopView.swift in Sources */,
-				04282A3C2ADD049700CB4260 /* JDRegisterView.swift in Sources */,
 				6CD200B629E7099800F0966D /* ASavingsDetailsScreenPopView.swift in Sources */,
 				6C2FFC9C296079E6005B8180 /* TradingPasswordsViewController.swift in Sources */,
 				041D4EF62AC1880E008ABDF7 /* JDAFiatTransferViewController.swift in Sources */,
@@ -6377,7 +6319,6 @@
 				0409C9E72AF73C7700103E9B /* JDTradeWalletFilterAlertView.swift in Sources */,
 				406673302C1856500090561B /* JDKLineAfterhoursCell.swift in Sources */,
 				406672FC2C1852630090561B /* KLineVerticalIndicatorsView.swift in Sources */,
-				04282A442ADD137500CB4260 /* JDForgotPasswordCell.swift in Sources */,
 				6C4AFB3E29A7CB2C00508EA7 /* MessageCell.swift in Sources */,
 				04D38E782A9EE8A10047EF9C /* JXSegmentedTitleDataSource.swift in Sources */,
 				4BEA62332C2EF6A800CEE286 /* JDLoadView.swift in Sources */,
@@ -6401,7 +6342,6 @@
 				6C7F44662955678800DC6771 /* HomeViewModel.swift in Sources */,
 				6C4AFAF6299FED3200508EA7 /* AFlashViewController.swift in Sources */,
 				6C50AB632A08096A00699557 /* RevokeWithdrawCashPopView.swift in Sources */,
-				6CA71340295889030047F450 /* RegisterViewController.swift in Sources */,
 				6CC8023A29954D3500C36373 /* ADepositViewController.swift in Sources */,
 				6CD200B329E6FB2100F0966D /* ASavingsDetailsListCell.swift in Sources */,
 				04CEE2812AB81D5300FAA760 /* JDTradeAccountDetailViewController.swift in Sources */,

+ 0 - 1
Koala/Koala/Modular/Information/V/InfomationNavView.swift

@@ -40,7 +40,6 @@ class InfomationNavView: BaseView {
     @objc func clickRightBtnAction() {
         guard OperationalUserInfoData.getLogin() else {
             currentVc()?.navigationController?.pushViewController(JDLoginViewController(), animated: true)
-//            currentVc()?.navigationController?.pushViewController(LoginViewController(), animated: true)
             return
         }
         

+ 0 - 358
Koala/Koala/Modular/Login/V/ForgotPassword/ForgotPasswordCell.swift

@@ -1,358 +0,0 @@
-//
-//  ForgotPasswordCell.swift
-//  Koala
-//
-//  Created by 刘千军 on 2022/12/26.
-//  Copyright © 2022 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class ForgotPasswordCell: BaseTableViewCell {
-    @IBOutlet var segmentdView: UIView!
-    
-    @IBOutlet var accountBgView: UIView!
-    
-    @IBOutlet var codeBgView: UIView!
-    
-    @IBOutlet var pwBgView: UIView!
-    
-    @IBOutlet var pwRepeatBgView: UIView!
-
-    @IBOutlet var submitBtn: UIButton!
-    
-    @IBOutlet var textView: UITextView!
-    
-    var index: Int = 0 // 选择下标 0 ,邮箱 ,1 手机
-    var forgotPasswordVM: ForgotPasswordViewModel?
-    
-    lazy var segmentedControl: HMSegmentedControl = {
-        let segmentedControl = HMSegmentedControl(frame: CGRect(x: 0, y: 0, width: SCREEN_WIDTH - 30, height: 40))
-        segmentedControl.selectedSegmentIndex = 0
-        segmentedControl.backgroundColor = .clear
-        segmentedControl.titleTextAttributes = [NSAttributedString.Key.foregroundColor: _color("#999999&#999999"), NSAttributedString.Key.font: _PFSM(14)]
-        segmentedControl.selectedTitleTextAttributes = [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: _PFSM(14)]
-        segmentedControl.selectionIndicatorHeight = 2
-        segmentedControl.segmentWidthStyle = .dynamic
-        segmentedControl.selectionStyle = .textWidthStripe
-        segmentedControl.selectionIndicatorLocation = .bottom
-        segmentedControl.selectionIndicatorColor = MainBackGroundColor
-        segmentedControl.indexChangeBlock = { [weak self] index in
-            self?.updateLayer(index: Int(index))
-        }
-        return segmentedControl
-    }()
-    
-    lazy var accountInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.codeBgView.isHidden = false
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickCountryCodeBlock = { [weak self] in
-            self?.clickCountryCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var codeInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.sendBgView.isHidden = false
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.setTitleText(text: switchLanguage("验证码"))
-        inView.clickSendCodeBlock = { [weak self] in
-            self?.clickSendCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var pwInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.setOpenBtnShow()
-        
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.setTitleText(text: switchLanguage("重置密码"))
-        return inView
-    }()
-    
-    lazy var pwRepeatInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.setOpenBtnShow()
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.setTitleText(text: switchLanguage("再一次输入新密码"))
-        return inView
-    }()
-    
-    override func awakeFromNib() {
-        super.awakeFromNib()
-        self.backgroundColor = ALLBackGroundColor
-        self.contentView.backgroundColor = .clear
-        self.segmentdView.backgroundColor = .clear
-        self.accountBgView.backgroundColor = .clear
-        self.codeBgView.backgroundColor = .clear
-        self.pwBgView.backgroundColor = .clear
-        self.pwRepeatBgView.backgroundColor = .clear
-        
-        self.segmentdView.addSubview(self.segmentedControl)
-        self.accountBgView.addSubview(self.accountInputView)
-        self.codeBgView.addSubview(self.codeInputView)
-        self.pwBgView.addSubview(self.pwInputView)
-        self.pwRepeatBgView.addSubview(self.pwRepeatInputView)
-        
-        self.accountInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.codeInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.pwInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.pwRepeatInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.segmentedControl.sectionTitles = [switchLanguage("手机"), switchLanguage("邮箱")]
-        
-        self.submitBtn.setTitle(switchLanguage("重置密码"), for: .normal)
-        self.submitBtn.setTitleColor(WhiteTextColor, for: .normal)
-        self.submitBtn.backgroundColor = MainBackGroundColor
-        self.submitBtn.setViewLayerBorderColor(myColor: .clear, borderWidth: 0, maskBounds: 4)
-        self.submitBtn.setTextFont(.PFSM, 16)
-        self.submitBtn.addTarget(self, action: #selector(clickSubmitBtnAction), for: .touchUpInside)
-        
-        let str1: String = switchLanguage("已有账户?")
-        let str2 = " " + switchLanguage("快速登录")
-        
-        let attri = NSMutableAttributedString(attributedString: NSAttributedString(string: str1 + str2, attributes: [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: UIFont.systemFont(ofSize: 14)]))
-        attri.addAttributes([NSAttributedString.Key.link: "Login" + "://"],
-                            range: ((attri.string) as NSString).range(of: str2))
-        self.textView.linkTextAttributes = [NSAttributedString.Key.foregroundColor: MainBackGroundColor]
-        self.textView.attributedText = attri
-        self.textView.delegate = self
-        self.textView.textAlignment = .center
-        self.textView.backgroundColor = .clear
-        self.textView.isEditable = false
-        
-        updateLayer(index: 0)
-        
-    }
-
-    override func setSelected(_ selected: Bool, animated: Bool) {
-        super.setSelected(selected, animated: animated)
-
-        
-    }
-}
-
-extension ForgotPasswordCell: UITextFieldDelegate, UITextViewDelegate {
-    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-        // 判断超链接协议
-        if let sch = URL.scheme, sch == "Login" {
-            currentVc()?.navigationController?.popViewController(animated: true)
-            return true
-        }
-        return false
-    }
-    
-    // MARK: - 输入框的变化
-
-    @objc func inputChange(_ textField: UITextField) {
-        let text = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.forgotPasswordVM?.account = text
-        }
-        else if textField == self.codeInputView.textField {
-            self.forgotPasswordVM?.code = text
-        }
-        else if textField == self.pwInputView.textField {
-            self.forgotPasswordVM?.pw = text
-        }
-        else {
-            self.forgotPasswordVM?.pwRepeat = text
-        }
-    }
-    
-    // 限制输入
-    func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
-        let existingString: NSString = textField.text as NSString? ?? "" as NSString
-        let candidateString = existingString.replacingCharacters(in: range, with: string)
-        if candidateString.length < existingString.length {
-            return true
-        }
-      
-        return true
-    }
-    
-    // 已经开始编辑
-    func textFieldDidBeginEditing(_ textField: UITextField) {
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.removeErrorView()
-            self.accountInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-        else if textField == self.codeInputView.textField {
-            self.codeInputView.bgView.removeErrorView()
-            self.codeInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-        else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.removeErrorView()
-            self.pwInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-        else {
-            self.pwRepeatInputView.bgView.removeErrorView()
-            self.pwRepeatInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-    }
-    
-    // 已经结束编辑
-    func textFieldDidEndEditing(_ textField: UITextField) {
-        let text: String = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.updateLayerBorderColor(color: .clear)
-            if self.index == 0 { // 手机错误提示
-                guard text.length > 0 else {
-                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入手机号"))
-                    return
-                }
-            }
-            else if self.index == 1 { // 邮箱错误提示
-                guard text.length > 0 else {
-                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入邮箱"))
-                    return
-                }
-                let pp = "^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$"
-                let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-            
-                if !predicate.evaluate(with: text) {
-                    self.accountInputView.bgView.addErrorView(switchLanguage("邮箱格式错误"))
-                }
-            }
-        }
-        else if textField == self.codeInputView.textField {
-            self.codeInputView.bgView.updateLayerBorderColor(color: .clear)
-        }
-        else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-                self.pwInputView.bgView.addErrorView(switchLanguage("请输入密码"))
-                return
-            }
-            let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-            let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-        
-            if !predicate.evaluate(with: text) {
-                self.pwInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-            }
-        }
-        else if textField == self.pwRepeatInputView.textField {
-            self.pwRepeatInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text == self.pwInputView.textField.text ?? "" else {
-                self.pwRepeatInputView.bgView.addErrorView(switchLanguage("两次密码不一致"))
-                return
-            }
-        }
-    }
-}
-
-extension ForgotPasswordCell {
-    func updateLayer(index: Int) {
-        self.index = index
-        self.forgotPasswordVM?.type = index
-        if index == 0 {
-            self.accountInputView.codeBgView.isHidden = false
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("电话号码"))
-            self.accountInputView.setTitleText(text: switchLanguage("电话号码"))
-        }
-        else {
-            self.accountInputView.codeBgView.isHidden = true
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("邮箱/子账号"))
-            self.accountInputView.setTitleText(text: switchLanguage("邮箱/子账号"))
-        }
-        
-        self.codeInputView.setTextPlaceholder(text: switchLanguage("验证码"))
-        self.pwInputView.setTextPlaceholder(text: switchLanguage("密码"))
-        self.pwRepeatInputView.setTextPlaceholder(text: switchLanguage("密码"))
-        
-        self.accountInputView.textField.text = ""
-        self.codeInputView.textField.text = ""
-        self.pwInputView.textField.text = ""
-        self.pwRepeatInputView.textField.text = ""
-        
-        self.accountInputView.bgView.removeErrorView()
-        self.codeInputView.bgView.removeErrorView()
-        self.pwInputView.bgView.removeErrorView()
-        self.pwRepeatInputView.bgView.removeErrorView()
-        
-        self.forgotPasswordVM?.account = ""
-        self.forgotPasswordVM?.pw = ""
-        self.forgotPasswordVM?.code = ""
-        self.forgotPasswordVM?.pwRepeat = ""
-    }
-    
-    //
-    func forgotPasswordUpdate(vm: ForgotPasswordViewModel) {
-        self.forgotPasswordVM = vm
-        self.updateLayer(index: 0)
-        self.accountInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: vm.abbreviate), for: .normal)
-        self.accountInputView.rightCodeBtn.setTitle("+" + vm.areaCode, for: .normal)
-        self.accountInputView.textField.text = vm.account
-        self.codeInputView.textField.text = vm.code
-        self.pwInputView.textField.text = vm.pw
-        self.pwRepeatInputView.textField.text = vm.pwRepeat
-    }
-    
-    @objc func clickCountryCodeAction() {
-        self.endEditing(true)
-        let pop = CountrySelectPopView()
-        pop.showRelyPopupView(view: self.accountInputView.bgView) { [weak self] model in
-            if model.areaCode.length > 0 {
-                self?.accountInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: model.abbreviate), for: .normal)
-                self?.accountInputView.rightCodeBtn.setTitle("+" + model.areaCode, for: .normal)
-                self?.forgotPasswordVM?.abbreviate = model.abbreviate
-                self?.forgotPasswordVM?.areaCode = model.areaCode
-            }
-        }
-    }
-    
-    func clickSendCodeAction() {
-        self.endEditing(true)
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-            
-        self.forgotPasswordVM?.netCode()
-    }
-    
-    @objc func clickSubmitBtnAction() {
-        self.endEditing(true)
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-        
-        guard (self.codeInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-    
-        guard (self.pwInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-        
-        let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-        let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-    
-        if !predicate.evaluate(with: self.pwInputView.textField.text ?? "") {
-            return
-        }
-        
-        guard (self.pwInputView.textField.text ?? "") == (self.pwRepeatInputView.textField.text ?? "") else {
-            return
-        }
-        
-        self.forgotPasswordVM?.netNewPassword()
-    }
-}

+ 0 - 108
Koala/Koala/Modular/Login/V/ForgotPassword/ForgotPasswordCell.xib

@@ -1,108 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21225" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
-    <device id="retina6_0" orientation="portrait" appearance="light"/>
-    <dependencies>
-        <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21207"/>
-        <capability name="System colors in document resources" minToolsVersion="11.0"/>
-        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
-    </dependencies>
-    <objects>
-        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
-        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
-        <tableViewCell contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" rowHeight="640" id="KGk-i7-Jjw" customClass="ForgotPasswordCell" customModule="Koala" customModuleProvider="target">
-            <rect key="frame" x="0.0" y="0.0" width="387" height="640"/>
-            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
-            <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
-                <rect key="frame" x="0.0" y="0.0" width="387" height="640"/>
-                <autoresizingMask key="autoresizingMask"/>
-                <subviews>
-                    <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="qlp-SG-XwQ">
-                        <rect key="frame" x="15" y="5" width="357" height="40"/>
-                        <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="40" id="hsf-ZL-l63"/>
-                        </constraints>
-                    </view>
-                    <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="8kq-Nw-4kM">
-                        <rect key="frame" x="15" y="55" width="357" height="300"/>
-                        <subviews>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="6Q8-DA-yj2">
-                                <rect key="frame" x="0.0" y="0.0" width="357" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                                <constraints>
-                                    <constraint firstAttribute="height" constant="75" id="zUe-0g-dca"/>
-                                </constraints>
-                            </view>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="6kC-H2-pwj">
-                                <rect key="frame" x="0.0" y="75" width="357" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                            </view>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="tPD-Cs-AXz">
-                                <rect key="frame" x="0.0" y="150" width="357" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                            </view>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="9FX-Cb-r1t">
-                                <rect key="frame" x="0.0" y="225" width="357" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                            </view>
-                        </subviews>
-                        <constraints>
-                            <constraint firstItem="9FX-Cb-r1t" firstAttribute="height" secondItem="6Q8-DA-yj2" secondAttribute="height" id="5NI-eS-O6X"/>
-                            <constraint firstItem="6kC-H2-pwj" firstAttribute="height" secondItem="6Q8-DA-yj2" secondAttribute="height" id="ffV-10-O2w"/>
-                            <constraint firstItem="tPD-Cs-AXz" firstAttribute="height" secondItem="6Q8-DA-yj2" secondAttribute="height" id="vQi-vp-2vJ"/>
-                        </constraints>
-                    </stackView>
-                    <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="0KQ-Uy-yz9">
-                        <rect key="frame" x="15" y="445" width="357" height="42"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="42" id="YIo-zK-ioN"/>
-                        </constraints>
-                        <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
-                        <state key="normal" title="Button"/>
-                    </button>
-                    <textView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" textAlignment="natural" translatesAutoresizingMaskIntoConstraints="NO" id="V6q-BF-TbT">
-                        <rect key="frame" x="15" y="507" width="357" height="113"/>
-                        <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                        <color key="textColor" systemColor="labelColor"/>
-                        <fontDescription key="fontDescription" type="system" pointSize="14"/>
-                        <textInputTraits key="textInputTraits" autocapitalizationType="sentences"/>
-                    </textView>
-                </subviews>
-                <constraints>
-                    <constraint firstItem="V6q-BF-TbT" firstAttribute="top" secondItem="0KQ-Uy-yz9" secondAttribute="bottom" constant="20" id="1pX-su-Dco"/>
-                    <constraint firstItem="qlp-SG-XwQ" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="5" id="2xR-5p-vRE"/>
-                    <constraint firstItem="8kq-Nw-4kM" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="IX1-O9-Ze6"/>
-                    <constraint firstItem="qlp-SG-XwQ" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="PAA-62-zLY"/>
-                    <constraint firstItem="V6q-BF-TbT" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="RKH-4f-nPG"/>
-                    <constraint firstAttribute="trailing" secondItem="V6q-BF-TbT" secondAttribute="trailing" constant="15" id="TpF-y9-fcl"/>
-                    <constraint firstAttribute="trailing" secondItem="0KQ-Uy-yz9" secondAttribute="trailing" constant="15" id="WYx-u3-lGQ"/>
-                    <constraint firstAttribute="trailing" secondItem="qlp-SG-XwQ" secondAttribute="trailing" constant="15" id="asx-V8-Hse"/>
-                    <constraint firstItem="0KQ-Uy-yz9" firstAttribute="top" secondItem="8kq-Nw-4kM" secondAttribute="bottom" constant="90" id="bZY-8o-SKU"/>
-                    <constraint firstAttribute="bottom" secondItem="V6q-BF-TbT" secondAttribute="bottom" constant="20" id="eyI-ce-rgR"/>
-                    <constraint firstAttribute="trailing" secondItem="8kq-Nw-4kM" secondAttribute="trailing" constant="15" id="lWm-9P-qC6"/>
-                    <constraint firstItem="0KQ-Uy-yz9" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="ozp-qg-Adm"/>
-                    <constraint firstItem="8kq-Nw-4kM" firstAttribute="top" secondItem="qlp-SG-XwQ" secondAttribute="bottom" constant="10" id="rk6-fK-SUh"/>
-                </constraints>
-            </tableViewCellContentView>
-            <connections>
-                <outlet property="accountBgView" destination="6Q8-DA-yj2" id="kdE-m5-xvf"/>
-                <outlet property="codeBgView" destination="6kC-H2-pwj" id="o8l-kK-JcK"/>
-                <outlet property="pwBgView" destination="tPD-Cs-AXz" id="ua2-Vm-6XB"/>
-                <outlet property="pwRepeatBgView" destination="9FX-Cb-r1t" id="43p-bh-Fe8"/>
-                <outlet property="segmentdView" destination="qlp-SG-XwQ" id="PUi-ZE-8pp"/>
-                <outlet property="submitBtn" destination="0KQ-Uy-yz9" id="wXn-He-bej"/>
-                <outlet property="textView" destination="V6q-BF-TbT" id="prX-J5-OKT"/>
-            </connections>
-            <point key="canvasLocation" x="274.61538461538458" y="110.18957345971563"/>
-        </tableViewCell>
-    </objects>
-    <resources>
-        <systemColor name="labelColor">
-            <color red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
-        </systemColor>
-        <systemColor name="systemBackgroundColor">
-            <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
-        </systemColor>
-    </resources>
-</document>

+ 1 - 1
Koala/Koala/Modular/Login/V/ForgotPassword/ForgotPasswordView.swift

@@ -83,7 +83,7 @@ extension ForgotPasswordView: UITableViewDelegate, UITableViewDataSource {
     }
     
     func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
-//        let cell:ForgotPasswordCell = tableView.dequeueReusableCell(withIdentifier: "ForgotPasswordCell") as! ForgotPasswordCell
+
         let cell: JDForgotPasswordNewCell = tableView.dequeueReusableCell(withIdentifier: JDForgotPasswordNewCell.description()) as! JDForgotPasswordNewCell
         cell.forgotPasswordUpdate(vm: self.VM!)
         return cell

+ 0 - 571
Koala/Koala/Modular/Login/V/ForgotPassword/JDForgotPasswordCell.swift

@@ -1,571 +0,0 @@
-//
-//  JDForgotPasswordCell.swift
-//  Koala
-//
-//  Created by mac on 2023/10/16.
-//  Copyright © 2023 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class JDForgotPasswordCell: BaseTableViewCell {
-    var index: Int = 0 // 选择下标 0 ,邮箱 ,1 手机
-    var forgotPasswordVM: ForgotPasswordViewModel?
-    
-    lazy var countryView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        v.isUserInteractionEnabled = true
-        
-        v.addGestureRecognizer(UITapGestureRecognizer(target: self, action: #selector(clickCountryCodeAction)))
-        return v
-    }()
-    
-    lazy var countryLb: UILabel = {
-        let v = UILabel()
-        v.textColor = .black
-        v.setTextFont(.PFSM, 14)
-        v.text = switchLanguage("国际/地区")
-        return v
-    }()
-    
-    lazy var countryLineView: UIView = {
-        let v = UIView()
-        v.backgroundColor = _color("#E8E8E8&#E8E8E8")
-        return v
-    }()
-    
-    lazy var countryArrowIv: UIImageView = {
-        let v = UIImageView()
-        v.image = _image("Base_W_RightArrows&Base_W_RightArrows")
-        return v
-    }()
-    
-    lazy var accountBgView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        return v
-    }()
-    
-    lazy var accountInputView: JDPhoneInputView = {
-        let inView = JDPhoneInputView()
-        inView.codeBgView.isHidden = false
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickCountryCodeBlock = { [weak self] in
-            self?.clickCountryCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var codeBgView: UIView = {
-        let v = UIView()
-        
-        return v
-    }()
-    
-    lazy var codeInputView: JDCodeInputView = {
-        let inView = JDCodeInputView()
-        inView.sendBgView.isHidden = false
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        
-        inView.clickSendCodeBlock = { [weak self] in
-            self?.clickSendCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var pwBgView: UIView = {
-        let v = UIView()
-        
-        return v
-    }()
-    
-    lazy var pwInputView: JDPasswordInputView = {
-        let inView = JDPasswordInputView()
-//        inView.setOpenBtnShow()
-        
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-//        inView.setTitleText(text: switchLanguage("重置密码"))
-        inView.setTextPlaceholder(text: "请设置密码")
-        return inView
-    }()
-    
-    lazy var rePwBgView: UIView = {
-        let v = UIView()
-        
-        return v
-    }()
-    
-    lazy var pwRepeatInputView: JDPasswordInputView = {
-        let inView = JDPasswordInputView()
-//        inView.setOpenBtnShow()
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-//        inView.setTitleText(text: switchLanguage("再一次输入新密码"))
-        inView.setTextPlaceholder(text: "再次确认密码")
-        return inView
-    }()
-    
-    lazy var submitBtn: UIButton = {
-        let submitBtn = UIButton(type: .custom)
-        submitBtn.setTitle(switchLanguage("重置密码"), for: .normal)
-        submitBtn.setTitleColor(WhiteTextColor, for: .normal)
-        submitBtn.backgroundColor = MainBackGroundColor
-        submitBtn.setViewLayerBorderColor(myColor: .clear, borderWidth: 0, maskBounds: 22)
-        submitBtn.setTextFont(.PFSM, 16)
-        submitBtn.addTarget(self, action: #selector(clickSubmitBtnAction), for: .touchUpInside)
-        return submitBtn
-        
-    }()
-    
-    lazy var useEmailLoginBtn: UIButton = {
-        let v = UIButton(type: .custom)
-        
-        v.setTitle(switchLanguage("使用邮箱"), for: .normal)
-        v.setTitleColor(.black, for: .normal)
-        v.setTextFont(.PFSR, 14)
-        v.reactive.controlEvents(.touchUpInside).observeValues { [weak self] _ in
-            
-            if self?.index == 0 {
-                self?.updateLayer(index: 1)
-            } else {
-                self?.updateLayer(index: 0)
-            }
-        }
-        
-        return v
-    }()
-    
-    lazy var textView: UITextView = {
-        let v = UITextView()
-        
-        let str1: String = switchLanguage("返回登录")
-    
-        let attri = NSMutableAttributedString(attributedString: NSAttributedString(string: str1, attributes: [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: UIFont.systemFont(ofSize: 14)]))
-//        attri.addAttributes([NSAttributedString.Key.link:("Login"+"://")],
-//                            range: ((attri.string) as NSString).range(of: str1))
-        
-        attri.addAttributes([NSAttributedString.Key.link: "Login"+"://"], range: NSMakeRange(0, str1.length))
-        v.linkTextAttributes = [NSAttributedString.Key.foregroundColor: TitleTextColor]
-        v.attributedText = attri
-        v.delegate = self
-        v.textAlignment = .center
-        v.backgroundColor = .clear
-        v.isEditable = false
-        
-        return v
-    }()
-    
-    override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
-        super.init(style: style, reuseIdentifier: reuseIdentifier)
-        
-        contentView.backgroundColor = .clear
-        
-        contentView.addSubview(self.countryView)
-        self.countryView.snp.makeConstraints { make in
-            make.left.equalTo(contentView.snp.left).offset(18)
-            make.right.equalTo(contentView.snp.right).offset(-18)
-            make.top.equalTo(contentView.snp.top).offset(10)
-            make.height.equalTo(50)
-        }
-        self.countryView.addSubview(self.countryLb)
-        self.countryLb.snp.makeConstraints { make in
-            make.left.equalTo(self.countryView.snp.left)
-            make.centerY.equalTo(self.countryView)
-        }
-        self.countryView.addSubview(self.countryArrowIv)
-        self.countryArrowIv.snp.makeConstraints { make in
-            make.right.equalTo(self.countryView.snp.right)
-            make.centerY.equalTo(self.countryView)
-            make.size.equalTo(CGSize(width: 5, height: 10))
-        }
-        self.countryView.addSubview(self.countryLineView)
-        self.countryLineView.snp.makeConstraints { make in
-            make.left.right.bottom.equalTo(self.countryView)
-            make.height.equalTo(1)
-        }
-        
-        contentView.addSubview(self.accountBgView)
-        self.accountBgView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.countryView.snp.bottom)
-            make.height.equalTo(50)
-        }
-        self.accountBgView.addSubview(self.accountInputView)
-        self.accountInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.accountBgView)
-        }
-        
-        contentView.addSubview(self.codeBgView)
-        self.codeBgView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.accountBgView.snp.bottom)
-            make.height.equalTo(50)
-        }
-        
-        self.codeBgView.addSubview(self.codeInputView)
-        self.codeInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.codeBgView)
-        }
-        
-        contentView.addSubview(self.pwBgView)
-        self.pwBgView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.codeBgView.snp.bottom)
-            make.height.equalTo(50)
-        }
-        
-        self.pwBgView.addSubview(self.pwInputView)
-        self.pwInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.pwBgView)
-        }
-        
-        contentView.addSubview(self.rePwBgView)
-        self.rePwBgView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.pwBgView.snp.bottom)
-            make.height.equalTo(50)
-        }
-        
-        self.rePwBgView.addSubview(self.pwRepeatInputView)
-        self.pwRepeatInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.rePwBgView)
-        }
-        
-        contentView.addSubview(self.submitBtn)
-        self.submitBtn.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.rePwBgView.snp.bottom).offset(75)
-            make.height.equalTo(44)
-        }
-        
-        contentView.addSubview(self.useEmailLoginBtn)
-        self.useEmailLoginBtn.snp.makeConstraints { make in
-            make.top.equalTo(self.submitBtn.snp.bottom).offset(26)
-            make.centerX.equalTo(contentView)
-        }
-        
-        contentView.addSubview(self.textView)
-        self.textView.snp.makeConstraints { make in
-            make.top.equalTo(self.useEmailLoginBtn.snp.bottom).offset(100)
-            make.centerX.equalTo(contentView)
-            make.size.equalTo(CGSize(width: 200, height: 30))
-            make.bottom.equalTo(contentView.snp.bottom).offset(-100)
-        }
-        
-        self.updateLayer(index: 0)
-    }
-    
-    @available(*, unavailable)
-    required init?(coder aDecoder: NSCoder) {
-        fatalError("init(coder:) has not been implemented")
-    }
-    
-    /*
-     override func awakeFromNib() {
-         super.awakeFromNib()
-         self.backgroundColor = ALLBackGroundColor
-         self.contentView.backgroundColor = .clear
-     
-         self.accountBgView.backgroundColor = .clear
-         self.codeBgView.backgroundColor = .clear
-         self.pwBgView.backgroundColor = .clear
-         self.pwRepeatBgView.backgroundColor = .clear
-        
-         self.accountBgView.addSubview(self.accountInputView)
-         self.codeBgView.addSubview(self.codeInputView)
-         self.pwBgView.addSubview(self.pwInputView)
-         self.pwRepeatBgView.addSubview(self.pwRepeatInputView)
-        
-         self.accountInputView.snp.makeConstraints { make in
-             make.edges.equalToSuperview()
-         }
-        
-         self.codeInputView.snp.makeConstraints { make in
-             make.edges.equalToSuperview()
-         }
-        
-         self.pwInputView.snp.makeConstraints { make in
-             make.edges.equalToSuperview()
-         }
-        
-         self.pwRepeatInputView.snp.makeConstraints { make in
-             make.edges.equalToSuperview()
-         }
-        
-         submitBtn.setTitle(switchLanguage("重置密码"), for: .normal)
-         submitBtn.setTitleColor(WhiteTextColor, for: .normal)
-         submitBtn.backgroundColor = MainBackGroundColor
-         submitBtn.setViewLayerBorderColor(myColor: .clear, borderWidth: 0, maskBounds: 4)
-         submitBtn.setTextFont(.PFSM, 16)
-         submitBtn.addTarget(self, action: #selector(clickSubmitBtnAction), for: .touchUpInside)
-        
-         let str1:String = switchLanguage("已有账户?")
-         let str2:String = " " + switchLanguage("快速登录")
-        
-         let attri = NSMutableAttributedString(attributedString: NSAttributedString(string: str1 + str2,attributes:[NSAttributedString.Key.foregroundColor : TitleTextColor,NSAttributedString.Key.font : UIFont.systemFont(ofSize: 14)]))
-         attri.addAttributes([NSAttributedString.Key.link:("Login"+"://")],
-                             range: ((attri.string) as NSString).range(of: str2))
-         textView.linkTextAttributes = [NSAttributedString.Key.foregroundColor : MainBackGroundColor]
-         textView.attributedText = attri
-         textView.delegate = self
-         textView.textAlignment = .center
-         textView.backgroundColor = .clear
-         textView.isEditable = false
-        
-         updateLayer(index: 0)
-         
-     }
-
-      */
-    override func setSelected(_ selected: Bool, animated: Bool) {
-        super.setSelected(selected, animated: animated)
-
-        
-    }
-}
-
-extension JDForgotPasswordCell: UITextFieldDelegate, UITextViewDelegate {
-    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-        // 判断超链接协议
-        if let sch = URL.scheme, sch == "Login" {
-            currentVc()?.navigationController?.popViewController(animated: true)
-            return true
-        }
-        return false
-    }
-    
-    // MARK: - 输入框的变化
-
-    @objc func inputChange(_ textField: UITextField) {
-        let text = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.forgotPasswordVM?.account = text
-        } else if textField == self.codeInputView.textField {
-            self.forgotPasswordVM?.code = text
-        } else if textField == self.pwInputView.textField {
-            self.forgotPasswordVM?.pw = text
-        } else {
-            self.forgotPasswordVM?.pwRepeat = text
-        }
-    }
-    
-    // 限制输入
-    func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
-        let existingString: NSString = textField.text as NSString? ?? "" as NSString
-        let candidateString = existingString.replacingCharacters(in: range, with: string)
-        if candidateString.length < existingString.length {
-            return true
-        }
-      
-        return true
-    }
-    
-    // 已经开始编辑
-    func textFieldDidBeginEditing(_ textField: UITextField) {
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.removeErrorView()
-//            self.accountInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else if textField == self.codeInputView.textField {
-            self.codeInputView.bgView.removeErrorView()
-//            self.codeInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.removeErrorView()
-//            self.pwInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else {
-            self.pwRepeatInputView.bgView.removeErrorView()
-//            self.pwRepeatInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-    }
-    
-    // 已经结束编辑
-    func textFieldDidEndEditing(_ textField: UITextField) {
-        let text: String = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.updateLayerBorderColor(color: .clear)
-            if self.index == 0 { // 手机错误提示
-                guard text.length > 0 else {
-//                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入手机号"))
-                    return
-                }
-            } else if self.index == 1 { // 邮箱错误提示
-                guard text.length > 0 else {
-//                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入邮箱"))
-                    return
-                }
-                let pp = "^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$"
-                let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-            
-                if !predicate.evaluate(with: text) {
-//                    self.accountInputView.bgView.addErrorView(switchLanguage("邮箱格式错误"))
-                }
-            }
-        } else if textField == self.codeInputView.textField {
-//            self.codeInputView.bgView.updateLayerBorderColor(color: .clear)
-        } else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-//                self.pwInputView.bgView.addErrorView(switchLanguage("请输入密码"))
-                return
-            }
-            let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-            let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-        
-            if !predicate.evaluate(with: text) {
-//                self.pwInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-            }
-        } else if textField == self.pwRepeatInputView.textField {
-            self.pwRepeatInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text == self.pwInputView.textField.text ?? "" else {
-//                self.pwRepeatInputView.bgView.addErrorView(switchLanguage("两次密码不一致"))
-                return
-            }
-        }
-    }
-}
-
-extension JDForgotPasswordCell {
-    func updateLayer(index: Int) {
-        self.index = index
-        self.forgotPasswordVM?.type = index
-        if index == 0 {
-            self.accountInputView.codeBgView.isHidden = false
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("请输入手机号码"))
-            
-            self.accountInputView.updateLayerView(index: 0)
-            self.useEmailLoginBtn.setTitle(switchLanguage("使用邮箱"), for: .normal)
-            
-        } else {
-            self.accountInputView.codeBgView.isHidden = true
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("请输入邮箱地址"))
-            self.accountInputView.updateLayerView(index: 1)
-            self.useEmailLoginBtn.setTitle(switchLanguage("使用手机"), for: .normal)
-        }
-        
-        self.codeInputView.setTextPlaceholder(text: switchLanguage("请输入验证码"))
-        self.pwInputView.setTextPlaceholder(text: switchLanguage("请设置密码"))
-        self.pwRepeatInputView.setTextPlaceholder(text: switchLanguage("再次确认密码"))
-        
-        self.accountInputView.textField.text = ""
-        self.codeInputView.textField.text = ""
-        self.pwInputView.textField.text = ""
-        self.pwRepeatInputView.textField.text = ""
-        
-        self.accountInputView.bgView.removeErrorView()
-        self.codeInputView.bgView.removeErrorView()
-        self.pwInputView.bgView.removeErrorView()
-        self.pwRepeatInputView.bgView.removeErrorView()
-        
-        self.forgotPasswordVM?.account = ""
-        self.forgotPasswordVM?.pw = ""
-        self.forgotPasswordVM?.code = ""
-        self.forgotPasswordVM?.pwRepeat = ""
-    }
-    
-    //
-    func forgotPasswordUpdate(vm: ForgotPasswordViewModel) {
-        self.forgotPasswordVM = vm
-        self.updateLayer(index: 0)
-//        self.accountInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: vm.abbreviate), for: .normal)
-        
-        self.countryLb.text = "国际/地区("+vm.countryName+")"
-//        self.accountInputView.rightCodeBtn.setTitle("+"+vm.areaCode, for: .normal)
-        self.accountInputView.rightCodeLb.text = "+"+vm.areaCode
-        self.accountInputView.textField.text = vm.account
-        self.codeInputView.textField.text = vm.code
-        self.pwInputView.textField.text = vm.pw
-        self.pwRepeatInputView.textField.text = vm.pwRepeat
-    }
-    
-    @objc func clickCountryCodeAction() {
-        self.endEditing(true)
-        let pop = CountrySelectPopView()
-        pop.showRelyPopupView(view: self.countryView) { [weak self] model in
-            if model.areaCode.length > 0 {
-//                self?.accountInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: model.abbreviate), for: .normal)
-                self?.countryLb.text = "国际/地区("+model.name+")"
-//                self?.accountInputView.rightCodeBtn.setTitle("+"+model.areaCode, for: .normal)
-                self?.accountInputView.rightCodeLb.text = "+"+model.areaCode
-                self?.forgotPasswordVM?.abbreviate = model.abbreviate
-                self?.forgotPasswordVM?.areaCode = model.areaCode
-                self?.forgotPasswordVM?.countryName = model.name
-            }
-        }
-    }
-    
-    func clickSendCodeAction() {
-        self.endEditing(true)
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-            
-        self.forgotPasswordVM?.netCode()
-    }
-    
-    @objc func clickSubmitBtnAction() {
-        self.endEditing(true)
-        
-//        guard (accountInputView.textField.text ?? "").length > 0 else {
-//
-//            ProgressHUD.showError(status: switchLanguage("请输入账号"))
-//            return
-//        }
-//
-//        guard (codeInputView.textField.text ?? "").length > 0 else {
-//
-//            ProgressHUD.showError(status: switchLanguage("请输入验证码"))
-//            return
-//        }
-//
-//        guard (pwInputView.textField.text ?? "").length > 0 else {
-//
-//            ProgressHUD.showError(status: switchLanguage("请输入密码"))
-//            return
-//        }
-//
-//        let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-//        let predicate = NSPredicate.init(format: "SELF MATCHES %@",pp)
-//
-//        if !predicate .evaluate(with: pwInputView.textField.text ?? ""){
-//
-//            //                self.pwInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-//            ProgressHUD.showError(status: switchLanguage("8-20位字符"))
-//           return
-//        }
-        
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入账号"))
-            
-            return
-        }
-        
-        guard (self.codeInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入验证码"))
-            return
-        }
-    
-        guard (self.pwInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入新密码"))
-            return
-        }
-        
-        let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-        let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-    
-        if !predicate.evaluate(with: self.pwInputView.textField.text ?? "") {
-            ProgressHUD.showError(status: switchLanguage("8-20位字符,包含数字和字母"))
-            
-            return
-        }
-        
-        guard (self.pwInputView.textField.text ?? "") == (self.pwRepeatInputView.textField.text ?? "") else {
-            ProgressHUD.showError(status: switchLanguage("确认密码输入不一致"))
-            return
-        }
-        
-        self.forgotPasswordVM?.netNewPassword()
-    }
-}

+ 0 - 115
Koala/Koala/Modular/Login/V/ForgotPassword/JDForgotPasswordView.swift

@@ -1,115 +0,0 @@
-//
-//  JDForgotPasswordView.swift
-//  Koala
-//
-//  Created by mac on 2023/10/16.
-//  Copyright © 2023 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class JDForgotPasswordView: BaseView {
-    var VM: ForgotPasswordViewModel?
-    lazy var topView: LoginTopView = {
-        let topView = LoginTopView(frame: CGRect(x: 0, y: 0, width: SCREEN_WIDTH, height: 120))
-        topView.titleLab.text = switchLanguage("忘记密码")
-        topView.backgroundColor = .clear
-        return topView
-    }()
-    
-    lazy var tableView: BaseTableView = { [weak self] in
-        let tableView = BaseTableView(frame: .zero, style: .plain)
-        tableView.separatorStyle = .none
-        tableView.delegate = self
-        tableView.dataSource = self
-        tableView.backgroundColor = .clear
-        tableView.tableHeaderView = UIView()
-        tableView.tableFooterView = UIView()
-        tableView.showsHorizontalScrollIndicator = false
-        tableView.showsVerticalScrollIndicator = false
-        tableView.register(JDForgotPasswordCell.self, forCellReuseIdentifier: JDForgotPasswordCell.description())
-        
-        tableView.contentInsetAdjustmentBehavior = .never
-        return tableView
-    }()
-
-    override func subView() {
-        super.subView()
-        self.addSubview(self.topView)
-        self.addSubview(self.tableView)
-        self.mySwitchLanguage()
-        self.mySwitchSkin()
-    }
-    
-    override func layoutSubviews() {
-        super.layoutSubviews()
-        
-        self.tableView.snp.makeConstraints { make in
-            make.top.equalTo(self.topView.snp.bottom)
-            make.left.right.bottom.equalToSuperview()
-        }
-    }
-    
-    override func setViewModel(viewmodel: AnyObject) {
-        guard viewmodel is ForgotPasswordViewModel else {
-            return
-        }
-        self.VM = viewmodel as? ForgotPasswordViewModel
-        super.setViewModel(viewmodel: viewmodel)
-    }
-    
-    override func mySwitchLanguage() {}
-    
-    override func mySwitchSkin() {
-        self.tableView.backgroundColor = .clear
-        self.backgroundColor = .clear
-    }
-    
-    override func blindModel() {
-        self.VM?.codeAction.values.observeValues { [weak self] resilt in
-            if resilt {
-                let indexPath = NSIndexPath(row: 0, section: 0)
-                if let cell: JDForgotPasswordCell = self?.tableView.cellForRow(at: indexPath as IndexPath) as? JDForgotPasswordCell {
-                    cell.codeInputView.updateTimer()
-                }
-            }
-        }
-    }
-}
-
-// 代理
-extension JDForgotPasswordView: UITableViewDelegate, UITableViewDataSource {
-    func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
-        return 1
-    }
-    
-    func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
-//        let cell:ForgotPasswordCell = tableView.dequeueReusableCell(withIdentifier: "ForgotPasswordCell") as! ForgotPasswordCell
-        let cell = tableView.dequeueReusableCell(withIdentifier: JDForgotPasswordCell.description()) as! JDForgotPasswordCell
-        cell.forgotPasswordUpdate(vm: self.VM!)
-        cell.backgroundColor = .clear
-        return cell
-    }
-    
-    func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
-        return -1
-    }
-    
-    func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? {
-        return UIView()
-    }
-    
-    func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
-        return UIView()
-    }
-
-    func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
-        return 0
-    }
-    
-    func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
-        return 2
-    }
-    
-    func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {}
-}

+ 0 - 386
Koala/Koala/Modular/Login/V/Login/JDLoginCell.swift

@@ -1,386 +0,0 @@
-//
-//  JDLoginCell.swift
-//  Koala
-//
-//  Created by mac on 2023/9/28.
-//  Copyright © 2023 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class JDLoginCell: BaseTableViewCell {
-    var index: Int = 0 // 选择下标 0 ,邮箱 ,1 手机
-    
-    var loginVM: LoginViewModel?
-    
-    lazy var countryView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        v.isUserInteractionEnabled = true
-        
-        v.addGestureRecognizer(UITapGestureRecognizer(target: self, action: #selector(clickCountryCodeAction)))
-        return v
-    }()
-    
-    lazy var countryLb: UILabel = {
-        let v = UILabel()
-        v.textColor = .black
-        v.setTextFont(.PFSM, 14)
-        v.text = switchLanguage("国际/地区")
-        return v
-    }()
-    
-    lazy var countryLineView: UIView = {
-        let v = UIView()
-        v.backgroundColor = _color("#E8E8E8&#E8E8E8")
-        return v
-    }()
-    
-    lazy var countryArrowIv: UIImageView = {
-        let v = UIImageView()
-        v.image = _image("Base_W_RightArrows&Base_W_RightArrows")
-        return v
-    }()
-    
-    lazy var phoneView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        return v
-    }()
-    
-    lazy var topInputView: JDPhoneInputView = {
-        let inView = JDPhoneInputView()
-        
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickCountryCodeBlock = { [weak self] in
-            self?.clickCountryCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var passwordView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        return v
-    }()
-    
-    lazy var bottomInputView: JDPasswordInputView = {
-        let inView = JDPasswordInputView()
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        
-        inView.setTextPlaceholder(text: switchLanguage("请输入密码"))
-        
-        return inView
-    }()
-    
-    lazy var forgetPwBtn: UIButton = {
-        let v = UIButton(type: .custom)
-        
-        v.setTitle(switchLanguage("忘记密码?"), for: .normal)
-        v.setTitleColor(.black, for: .normal)
-        v.setTextFont(.PFSR, 14)
-        v.reactive.controlEvents(.touchUpInside).observeValues { [weak self] _ in
-            currentVc()?.navigationController?.pushViewController(ForgotPasswordViewController(), animated: true)
-        }
-        
-        return v
-    }()
-    
-    lazy var submitBtn: UIButton = {
-        let submitBtn = UIButton(type: .custom)
-        submitBtn.setTitle(switchLanguage("登录"), for: .normal)
-        submitBtn.setTitleColor(WhiteTextColor, for: .normal)
-        submitBtn.backgroundColor = MainBackGroundColor
-        submitBtn.setViewLayerBorderColor(myColor: .clear, borderWidth: 0, maskBounds: 22)
-        submitBtn.setTextFont(.PFSM, 16)
-        submitBtn.addTarget(self, action: #selector(clickSubmitBtnAction), for: .touchUpInside)
-        return submitBtn
-        
-    }()
-    
-    lazy var useEmailLoginBtn: UIButton = {
-        let v = UIButton(type: .custom)
-        
-        v.setTitle(switchLanguage("使用邮箱登录"), for: .normal)
-        v.setTitleColor(.black, for: .normal)
-        v.setTextFont(.PFSR, 14)
-        v.reactive.controlEvents(.touchUpInside).observeValues { [weak self] _ in
-            
-            if self?.index == 0 {
-                self?.updateLayer(index: 1)
-            } else {
-                self?.updateLayer(index: 0)
-            }
-            //            currentVc()?.navigationController?.pushViewController(ForgotPasswordViewController(), animated: true)
-        }
-        
-        return v
-    }()
-    
-    override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
-        super.init(style: style, reuseIdentifier: reuseIdentifier)
-        
-        contentView.addSubview(self.countryView)
-        self.countryView.snp.makeConstraints { make in
-            make.left.equalTo(contentView.snp.left).offset(18)
-            make.right.equalTo(contentView.snp.right).offset(-18)
-            make.top.equalTo(contentView.snp.top).offset(10)
-            make.height.equalTo(50)
-        }
-        self.countryView.addSubview(self.countryLb)
-        self.countryLb.snp.makeConstraints { make in
-            make.left.equalTo(self.countryView.snp.left)
-            make.centerY.equalTo(self.countryView)
-        }
-        self.countryView.addSubview(self.countryArrowIv)
-        self.countryArrowIv.snp.makeConstraints { make in
-            make.right.equalTo(self.countryView.snp.right)
-            make.centerY.equalTo(self.countryView)
-            make.size.equalTo(CGSize(width: 5, height: 10))
-        }
-        self.countryView.addSubview(self.countryLineView)
-        self.countryLineView.snp.makeConstraints { make in
-            make.left.right.bottom.equalTo(self.countryView)
-            make.height.equalTo(1)
-        }
-        
-        contentView.addSubview(self.phoneView)
-        self.phoneView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.countryView.snp.bottom)
-            make.height.equalTo(50)
-        }
-        self.phoneView.addSubview(self.topInputView)
-        self.topInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.phoneView)
-        }
-        
-        contentView.addSubview(self.passwordView)
-        self.passwordView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.height.equalTo(50)
-            make.top.equalTo(self.phoneView.snp.bottom)
-        }
-        
-        self.passwordView.addSubview(self.bottomInputView)
-        self.bottomInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.passwordView)
-        }
-        
-        contentView.addSubview(self.forgetPwBtn)
-        self.forgetPwBtn.snp.makeConstraints { make in
-            make.top.equalTo(self.passwordView.snp.bottom).offset(12)
-            make.right.equalTo(self.passwordView.snp.right)
-            make.height.equalTo(30)
-        }
-        
-        contentView.addSubview(self.submitBtn)
-        self.submitBtn.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.forgetPwBtn.snp.bottom).offset(75)
-            make.height.equalTo(44)
-        }
-        
-        contentView.addSubview(self.useEmailLoginBtn)
-        self.useEmailLoginBtn.snp.makeConstraints { make in
-            make.top.equalTo(self.submitBtn.snp.bottom).offset(26)
-            make.centerX.equalTo(contentView)
-            make.bottom.equalTo(contentView.snp.bottom).offset(-20)
-        }
-        
-        self.updateLayer(index: 0)
-    }
-    
-    @available(*, unavailable)
-    required init?(coder aDecoder: NSCoder) {
-        fatalError("init(coder:) has not been implemented")
-    }
-}
-
-extension JDLoginCell: UITextFieldDelegate, UITextViewDelegate {
-//    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-//        //判断超链接协议
-//        if let sch = URL.scheme,sch == "Register" {
-//            currentVc()?.navigationController?.pushViewController(RegisterViewController(), animated: true)
-//            return true
-//        } else if let sch = URL.scheme,sch == "User" {
-//            //            currentVc()?.navigationController?.popViewController(animated: true)
-//
-//            let vc = BaseWebViewController()
-//
-//            vc.url =  UserPolicy
-//            vc.myNavigationBar.title_Label.text = switchLanguage("用户协议")
-//            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-//
-//            return true
-//        } else if let sch = URL.scheme, sch == "Policy" {
-//
-//            let vc = BaseWebViewController()
-//
-//            vc.url = LicensePolicy
-//            vc.myNavigationBar.title_Label.text = switchLanguage("隐私政策")
-//            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-//
-//            return true
-//
-//        }
-//        return false
-//    }
-    
-    // MARK: - 输入框的变化
-
-    @objc func inputChange(_ textField: UITextField) {
-        let text = textField.text ?? ""
-        if textField == self.topInputView.textField {
-            self.loginVM?.account = text
-        } else {
-            self.loginVM?.pw = text
-        }
-    }
-    
-    // 限制输入
-    func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
-        let existingString: NSString = textField.text as NSString? ?? "" as NSString
-        let candidateString = existingString.replacingCharacters(in: range, with: string)
-        if candidateString.length < existingString.length {
-            return true
-        }
-        
-        return true
-    }
-    
-    // 已经开始编辑
-    func textFieldDidBeginEditing(_ textField: UITextField) {
-        if textField == self.topInputView.textField {
-            self.topInputView.bgView.removeErrorView()
-            //            self.topInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else {
-            self.bottomInputView.bgView.removeErrorView()
-            //            self.bottomInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-    }
-    
-    // 已经结束编辑
-    func textFieldDidEndEditing(_ textField: UITextField) {
-        let text: String = textField.text ?? ""
-        if textField == self.topInputView.textField {
-            self.topInputView.bgView.updateLayerBorderColor(color: .clear)
-            if self.index == 0 { // 手机错误提示
-                guard text.length > 0 else {
-                    //                    self.topInputView.bgView.addErrorView(switchLanguage("请输入手机号"))
-                    return
-                }
-            } else if self.index == 1 { // 邮箱错误提示
-                guard text.length > 0 else {
-                    //                    self.topInputView.bgView.addErrorView(switchLanguage("请输入邮箱"))
-                    return
-                }
-                let pp = "^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$"
-                let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-                
-                if !predicate.evaluate(with: text) {
-                    //                    self.topInputView.bgView.addErrorView(switchLanguage("邮箱格式错误"))
-                }
-            }
-        } else if textField == self.bottomInputView.textField {
-            self.bottomInputView.bgView.updateLayerBorderColor(color: .clear)
-            self.bottomInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-                //                self.bottomInputView.bgView.addErrorView(switchLanguage("请输入密码"))
-                return
-            }
-            let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-            let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-            
-            if !predicate.evaluate(with: text) {
-                //                self.bottomInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-            }
-        }
-    }
-}
-
-extension JDLoginCell {
-    func updateLayer(index: Int) {
-        self.index = index
-        self.loginVM?.type = index
-        if index == 0 {
-            self.topInputView.updateLayerView(index: 0)
-            self.topInputView.setTextPlaceholder(text: switchLanguage("请输入手机号码"))
-            self.useEmailLoginBtn.setTitle(switchLanguage("使用邮箱登录"), for: .normal)
-            
-        } else {
-            self.topInputView.updateLayerView(index: 1)
-            self.topInputView.setTextPlaceholder(text: switchLanguage("请输入电子邮箱"))
-            
-            self.useEmailLoginBtn.setTitle(switchLanguage("使用手机登录"), for: .normal)
-        }
-        
-        self.bottomInputView.setTextPlaceholder(text: switchLanguage("请输入密码"))
-        
-        self.topInputView.textField.text = ""
-        self.bottomInputView.textField.text = ""
-        
-        self.topInputView.bgView.removeErrorView()
-        self.bottomInputView.bgView.removeErrorView()
-        
-        self.loginVM?.account = ""
-        self.loginVM?.pw = ""
-    }
-    
-    // 登录
-    func loginUpdate(vm: LoginViewModel) {
-        self.loginVM = vm
-        //        self.updateLayer(index: 0)
-        //        self.topInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: vm.abbreviate), for: .normal)
-        self.countryLb.text = "国际/地区("+vm.countryName+")"
-        
-//        self.topInputView.rightCodeBtn.setTitle("+"+vm.areaCode, for: .normal)
-        self.topInputView.rightCodeLb.text = "+"+vm.areaCode
-        self.topInputView.textField.text = self.loginVM?.account
-        
-        self.bottomInputView.textField.text = self.loginVM?.pw
-    }
-    
-    @objc func clickCountryCodeAction() {
-        self.endEditing(true)
-        let pop = CountrySelectPopView()
-        pop.showRelyPopupView(view: self.countryView) { [weak self] model in
-            if model.areaCode.length > 0 {
-                //                self?.topInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: model.abbreviate), for: .normal)
-                self?.countryLb.text = "国际/地区("+model.name+")"
-                
-//                self?.topInputView.rightCodeBtn.setTitle("+"+model.areaCode, for: .normal)
-                self?.topInputView.rightCodeLb.text = "+"+model.areaCode
-                self?.loginVM?.abbreviate = model.abbreviate
-                self?.loginVM?.areaCode = model.areaCode
-                self?.loginVM?.countryName = model.name
-            }
-        }
-    }
-    
-    @objc func clickSubmitBtnAction() {
-        self.endEditing(true)
-        guard (self.topInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入账号"))
-            
-            return
-        }
-        
-        guard (self.bottomInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入密码"))
-            
-            return
-        }
-        
-        let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-        let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-        
-        if !predicate.evaluate(with: self.bottomInputView.textField.text ?? "") {
-            ProgressHUD.showError(status: switchLanguage("请输入正确账号密码"))
-            return
-        }
-        
-        self.loginVM?.netLogin()
-    }
-}

+ 1 - 1
Koala/Koala/Modular/Login/V/Login/JDLoginNewCell.swift

@@ -194,7 +194,7 @@ extension JDLoginNewCell: UITextFieldDelegate, UITextViewDelegate {
     func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
         // 判断超链接协议
         if let sch = URL.scheme, sch == "Register" {
-            currentVc()?.navigationController?.pushViewController(RegisterViewController(), animated: true)
+            currentVc()?.navigationController?.pushViewController(JDRegisterViewController(), animated: true)
             return true
         }
         return false

+ 0 - 179
Koala/Koala/Modular/Login/V/Login/JDLoginView.swift

@@ -1,179 +0,0 @@
-//
-//  JDLoginView.swift
-//  Koala
-//
-//  Created by mac on 2023/9/28.
-//  Copyright © 2023 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class JDLoginView: BaseView {
-    var VM: LoginViewModel?
-    lazy var topView: LoginTopView = {
-        let topView = LoginTopView(frame: CGRect(x: 0, y: 0, width: SCREEN_WIDTH, height: 120))
-        topView.titleLab.text = switchLanguage("登录")
-        return topView
-    }()
-    
-    lazy var tableView: BaseTableView = { [weak self] in
-        let tableView = BaseTableView(frame: .zero, style: .plain)
-        tableView.separatorStyle = .none
-        tableView.delegate = self
-        tableView.dataSource = self
-        tableView.backgroundColor = .clear
-        tableView.tableHeaderView = UIView()
-        tableView.tableFooterView = UIView()
-        tableView.showsHorizontalScrollIndicator = false
-        tableView.showsVerticalScrollIndicator = false
-        tableView.register(JDLoginCell.self, forCellReuseIdentifier: JDLoginCell.description())
-        
-        tableView.contentInsetAdjustmentBehavior = .never
-        return tableView
-    }()
-
-    lazy var textView: UITextView = {
-        let v = UITextView()
-        
-        let str1: String = switchLanguage("注册即表示您同意")
-        let str2 = " "+switchLanguage("《用户协议》")
-        let str3 = " "+switchLanguage("和")
-        let str4 = " "+switchLanguage("《隐私条款》")
-        let str5 = "\n\n"
-        
-        let str6: String = switchLanguage("没有账户?立即")
-        let str7 = " "+switchLanguage("注册")
-        
-        let attri = NSMutableAttributedString(attributedString: NSAttributedString(string: str1+str2+str3+str4+str5+str6+str7, attributes: [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: UIFont.systemFont(ofSize: 14)]))
-        attri.addAttributes([NSAttributedString.Key.link: "Register"+"://"],
-                            range: ((attri.string) as NSString).range(of: str7))
-        
-        attri.addAttributes([NSAttributedString.Key.link: "User"+"://"],
-                            range: ((attri.string) as NSString).range(of: str2))
-        
-        attri.addAttributes([NSAttributedString.Key.link: "Policy"+"://"],
-                            range: ((attri.string) as NSString).range(of: str4))
-        
-        v.linkTextAttributes = [NSAttributedString.Key.foregroundColor: MainBackGroundColor]
-        
-        v.attributedText = attri
-        v.delegate = self
-        v.textAlignment = .center
-        v.backgroundColor = .clear
-        v.isEditable = false
-        v.isScrollEnabled = false
-        
-        return v
-    }()
-    
-    override func subView() {
-        super.subView()
-        self.addSubview(self.topView)
-        self.addSubview(self.tableView)
-        self.addSubview(self.textView)
-        self.mySwitchLanguage()
-        self.mySwitchSkin()
-    }
-    
-    override func layoutSubviews() {
-        super.layoutSubviews()
-        
-        self.textView.snp.makeConstraints { make in
-            
-            make.left.equalTo(self.snp.left).offset(20)
-            make.right.equalTo(self.snp.right).offset(-20)
-            make.height.equalTo(80)
-            make.bottom.equalTo(self.snp.bottom).offset(-58)
-        }
-        
-        self.tableView.snp.makeConstraints { make in
-            make.top.equalTo(self.topView.snp.bottom)
-            make.left.right.equalToSuperview()
-            make.bottom.equalTo(self.textView.snp.top)
-        }
-    }
-    
-    override func setViewModel(viewmodel: AnyObject) {
-        guard viewmodel is LoginViewModel else {
-            return
-        }
-        self.VM = viewmodel as? LoginViewModel
-        super.setViewModel(viewmodel: viewmodel)
-    }
-    
-    override func mySwitchLanguage() {}
-    
-    override func mySwitchSkin() {
-        self.tableView.backgroundColor = .clear
-        self.backgroundColor = ALLBackGroundColor
-    }
-    
-    override func blindModel() {}
-}
-
-extension JDLoginView: UITextViewDelegate {
-    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-        // 判断超链接协议
-        if let sch = URL.scheme, sch == "Register" {
-            currentVc()?.navigationController?.pushViewController(RegisterViewController(), animated: true)
-            return true
-        } else if let sch = URL.scheme, sch == "User" {
-            //            currentVc()?.navigationController?.popViewController(animated: true)
-            
-            let vc = BaseWebViewController()
-            
-            vc.url = getUserPolicyUrl()
-            vc.myNavigationBar.title_Label.text = switchLanguage("用户协议")
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-            
-            return true
-        } else if let sch = URL.scheme, sch == "Policy" {
-            let vc = BaseWebViewController()
-            
-            vc.url = getLicensePolicyUrl()
-            vc.myNavigationBar.title_Label.text = switchLanguage("隐私政策")
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-            
-            return true
-        }
-        return false
-    }
-}
-
-// 代理
-extension JDLoginView: UITableViewDelegate, UITableViewDataSource {
-    func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
-        return 1
-    }
-    
-    func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
-//        let cell:LoginCell = tableView.dequeueReusableCell(withIdentifier: "LoginCell") as! LoginCell
-        
-        let cell = tableView.dequeueReusableCell(withIdentifier: JDLoginCell.description()) as! JDLoginCell
-        cell.loginUpdate(vm: self.VM!)
-        cell.backgroundColor = .clear
-        return cell
-    }
-    
-    func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
-        return -1
-    }
-    
-    func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? {
-        return UIView()
-    }
-    
-    func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
-        return UIView()
-    }
-
-    func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
-        return 0
-    }
-    
-    func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
-        return 2
-    }
-    
-    func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {}
-}

+ 0 - 282
Koala/Koala/Modular/Login/V/Login/LoginCell.swift

@@ -1,282 +0,0 @@
-//
-//  LoginCell.swift
-//  Koala
-//
-//  Created by 刘千军 on 2022/12/24.
-//  Copyright © 2022 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class LoginCell: BaseTableViewCell {
-    @IBOutlet var segmentdView: UIView!
-    
-    @IBOutlet var topView: UIView!
-    @IBOutlet var bottomView: UIView!
-    
-    @IBOutlet var forgetPWBtn: UIButton!
-    
-    @IBOutlet var submitBtn: UIButton!
-    
-    @IBOutlet var textView: UITextView!
-    
-    var index: Int = 0 // 选择下标 0 ,邮箱 ,1 手机
-    
-    var loginVM: LoginViewModel?
-    
-    var clickForgotPasswordBlock: (() -> Void)?
-    
-    lazy var segmentedControl: HMSegmentedControl = {
-        let segmentedControl = HMSegmentedControl(frame: CGRect(x: 0, y: 0, width: SCREEN_WIDTH - 30, height: 40))
-        segmentedControl.selectedSegmentIndex = 0
-        segmentedControl.backgroundColor = .clear
-        segmentedControl.titleTextAttributes = [NSAttributedString.Key.foregroundColor: _color("#999999&#999999"), NSAttributedString.Key.font: _PFSM(14)]
-        segmentedControl.selectedTitleTextAttributes = [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: _PFSM(14)]
-        segmentedControl.selectionIndicatorHeight = 2
-        segmentedControl.segmentWidthStyle = .dynamic
-        segmentedControl.selectionStyle = .textWidthStripe
-        segmentedControl.selectionIndicatorLocation = .bottom
-        segmentedControl.selectionIndicatorColor = _color("#000000&#000000")
-        segmentedControl.indexChangeBlock = { [weak self] index in
-            self?.updateLayer(index: Int(index))
-        }
-        return segmentedControl
-    }()
-    
-    lazy var topInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.codeBgView.isHidden = false
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickCountryCodeBlock = { [weak self] in
-            self?.clickCountryCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var bottomInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.setOpenBtnShow()
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-       
-        inView.setTitleText(text: switchLanguage("密码"))
-        return inView
-    }()
-    
-    override func awakeFromNib() {
-        super.awakeFromNib()
-        self.backgroundColor = ALLBackGroundColor
-        self.contentView.backgroundColor = .clear
-        self.segmentdView.backgroundColor = .clear
-        self.topView.backgroundColor = .clear
-        self.bottomView.backgroundColor = .clear
-        
-        self.segmentdView.addSubview(self.segmentedControl)
-        
-        self.topView.addSubview(self.topInputView)
-        self.bottomView.addSubview(self.bottomInputView)
-        
-        self.topInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.bottomInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.segmentedControl.sectionTitles = [switchLanguage("手机号码"), switchLanguage("邮箱")]
-        
-        self.submitBtn.setTitle(switchLanguage("登录"), for: .normal)
-        self.submitBtn.setTitleColor(WhiteTextColor, for: .normal)
-        self.submitBtn.backgroundColor = MainBackGroundColor
-        self.submitBtn.setViewLayerBorderColor(myColor: .clear, borderWidth: 0, maskBounds: 4)
-        self.submitBtn.setTextFont(.PFSM, 16)
-        self.submitBtn.addTarget(self, action: #selector(clickSubmitBtnAction), for: .touchUpInside)
-        
-        self.forgetPWBtn.setTitle(switchLanguage("忘记密码?"), for: .normal)
-        self.forgetPWBtn.setTitleColor(MainBackGroundColor, for: .normal)
-        self.forgetPWBtn.setTextFont(.PFSM, 14)
-        self.forgetPWBtn.reactive.controlEvents(.touchUpInside).observeValues { [weak self] _ in
-            currentVc()?.navigationController?.pushViewController(ForgotPasswordViewController(), animated: true)
-        }
-        
-        let str1: String = switchLanguage("没有账户?")
-        let str2 = " " + switchLanguage("快速注册")
-        
-        let attri = NSMutableAttributedString(attributedString: NSAttributedString(string: str1 + str2, attributes: [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: UIFont.systemFont(ofSize: 14)]))
-        attri.addAttributes([NSAttributedString.Key.link: "Register" + "://"],
-                            range: ((attri.string) as NSString).range(of: str2))
-        self.textView.linkTextAttributes = [NSAttributedString.Key.foregroundColor: MainBackGroundColor]
-        self.textView.attributedText = attri
-        self.textView.delegate = self
-        self.textView.textAlignment = .center
-        self.textView.backgroundColor = .clear
-        self.textView.isEditable = false
-        
-        updateLayer(index: 0)
-        
-    }
-
-    override func setSelected(_ selected: Bool, animated: Bool) {
-        super.setSelected(selected, animated: animated)
-
-        
-    }
-}
-
-extension LoginCell: UITextFieldDelegate, UITextViewDelegate {
-    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-        // 判断超链接协议
-        if let sch = URL.scheme, sch == "Register" {
-            currentVc()?.navigationController?.pushViewController(RegisterViewController(), animated: true)
-            return true
-        }
-        return false
-    }
-    
-    // MARK: - 输入框的变化
-
-    @objc func inputChange(_ textField: UITextField) {
-        let text = textField.text ?? ""
-        if textField == self.topInputView.textField {
-            self.loginVM?.account = text
-        } else {
-            self.loginVM?.pw = text
-        }
-    }
-    
-    // 限制输入
-    func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
-        let existingString: NSString = textField.text as NSString? ?? "" as NSString
-        let candidateString = existingString.replacingCharacters(in: range, with: string)
-        if candidateString.length < existingString.length {
-            return true
-        }
-      
-        return true
-    }
-    
-    // 已经开始编辑
-    func textFieldDidBeginEditing(_ textField: UITextField) {
-        if textField == self.topInputView.textField {
-            self.topInputView.bgView.removeErrorView()
-            self.topInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else {
-            self.bottomInputView.bgView.removeErrorView()
-            self.bottomInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-    }
-    
-    // 已经结束编辑
-    func textFieldDidEndEditing(_ textField: UITextField) {
-        let text: String = textField.text ?? ""
-        if textField == self.topInputView.textField {
-            self.topInputView.bgView.updateLayerBorderColor(color: .clear)
-            if self.index == 0 { // 手机错误提示
-                guard text.length > 0 else {
-                    self.topInputView.bgView.addErrorView(switchLanguage("请输入手机号"))
-                    return
-                }
-            } else if self.index == 1 { // 邮箱错误提示
-                guard text.length > 0 else {
-                    self.topInputView.bgView.addErrorView(switchLanguage("请输入邮箱"))
-                    return
-                }
-                let pp = "^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$"
-                let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-            
-                if !predicate.evaluate(with: text) {
-                    self.topInputView.bgView.addErrorView(switchLanguage("邮箱格式错误"))
-                }
-            }
-        } else if textField == self.bottomInputView.textField {
-            self.bottomInputView.bgView.updateLayerBorderColor(color: .clear)
-            self.bottomInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-                self.bottomInputView.bgView.addErrorView(switchLanguage("请输入密码"))
-                return
-            }
-            let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-            let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-        
-            if !predicate.evaluate(with: text) {
-                self.bottomInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-            }
-        }
-    }
-}
-
-extension LoginCell {
-    func updateLayer(index: Int) {
-        self.index = index
-        self.loginVM?.type = index
-        if index == 0 {
-            self.topInputView.codeBgView.isHidden = false
-            self.topInputView.setTextPlaceholder(text: switchLanguage("电话号码"))
-            self.topInputView.setTitleText(text: switchLanguage("电话号码"))
-            
-        } else {
-            self.topInputView.codeBgView.isHidden = true
-            self.topInputView.setTextPlaceholder(text: switchLanguage("邮箱/子账号"))
-            self.topInputView.setTitleText(text: switchLanguage("邮箱/子账号"))
-        }
-        
-        self.bottomInputView.setTextPlaceholder(text: switchLanguage("密码"))
-       
-        self.topInputView.textField.text = ""
-        self.bottomInputView.textField.text = ""
-        
-        self.topInputView.bgView.removeErrorView()
-        self.bottomInputView.bgView.removeErrorView()
-        
-        self.loginVM?.account = ""
-        self.loginVM?.pw = ""
-    }
-    
-    // 登录
-    func loginUpdate(vm: LoginViewModel) {
-        self.loginVM = vm
-        self.updateLayer(index: 0)
-        self.topInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: vm.abbreviate), for: .normal)
-        self.topInputView.rightCodeBtn.setTitle("+" + vm.areaCode, for: .normal)
-       
-        self.topInputView.textField.text = self.loginVM?.account
-        
-        self.bottomInputView.textField.text = self.loginVM?.pw
-    }
-    
-    @objc func clickCountryCodeAction() {
-        self.endEditing(true)
-        let pop = CountrySelectPopView()
-        pop.showRelyPopupView(view: self.topInputView.bgView) { [weak self] model in
-            if model.areaCode.length > 0 {
-                self?.topInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: model.abbreviate), for: .normal)
-                
-                self?.topInputView.rightCodeBtn.setTitle("+" + model.areaCode, for: .normal)
-                self?.loginVM?.abbreviate = model.abbreviate
-                self?.loginVM?.areaCode = model.areaCode
-            }
-        }
-    }
-    
-    @objc func clickSubmitBtnAction() {
-        self.endEditing(true)
-        guard (self.topInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-        
-        guard (self.bottomInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-        
-        let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-        let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-    
-        if !predicate.evaluate(with: self.bottomInputView.textField.text ?? "") {
-            return
-        }
-        
-        self.loginVM?.netLogin()
-    }
-}

+ 0 - 107
Koala/Koala/Modular/Login/V/Login/LoginCell.xib

@@ -1,107 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21225" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
-    <device id="retina6_0" orientation="portrait" appearance="light"/>
-    <dependencies>
-        <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21207"/>
-        <capability name="System colors in document resources" minToolsVersion="11.0"/>
-        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
-    </dependencies>
-    <objects>
-        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
-        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
-        <tableViewCell contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" rowHeight="866" id="KGk-i7-Jjw" customClass="LoginCell" customModule="Koala" customModuleProvider="target">
-            <rect key="frame" x="0.0" y="0.0" width="700" height="866"/>
-            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
-            <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
-                <rect key="frame" x="0.0" y="0.0" width="700" height="866"/>
-                <autoresizingMask key="autoresizingMask"/>
-                <subviews>
-                    <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="xNN-G5-v1z">
-                        <rect key="frame" x="15" y="5" width="670" height="40"/>
-                        <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="40" id="4AC-bx-uiU"/>
-                        </constraints>
-                    </view>
-                    <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="iSa-8N-Hv8">
-                        <rect key="frame" x="15" y="55" width="670" height="150"/>
-                        <subviews>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="jld-kN-TDB">
-                                <rect key="frame" x="0.0" y="0.0" width="670" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                                <constraints>
-                                    <constraint firstAttribute="height" constant="75" id="0lq-bU-g0D"/>
-                                </constraints>
-                            </view>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="TPi-ay-xXH">
-                                <rect key="frame" x="0.0" y="75" width="670" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                            </view>
-                        </subviews>
-                        <constraints>
-                            <constraint firstItem="TPi-ay-xXH" firstAttribute="height" secondItem="jld-kN-TDB" secondAttribute="height" id="5TO-rv-shq"/>
-                        </constraints>
-                    </stackView>
-                    <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="jGj-qw-Jxf">
-                        <rect key="frame" x="15" y="205" width="54" height="489"/>
-                        <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
-                        <state key="normal" title="Button"/>
-                    </button>
-                    <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="A7E-tB-bt8">
-                        <rect key="frame" x="15" y="734" width="670" height="42"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="42" id="jcr-Zz-9DW"/>
-                        </constraints>
-                        <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
-                        <state key="normal" title="Button"/>
-                    </button>
-                    <textView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" textAlignment="natural" translatesAutoresizingMaskIntoConstraints="NO" id="tvw-dW-6ZZ">
-                        <rect key="frame" x="10" y="796" width="680" height="40"/>
-                        <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="40" id="frS-Rg-MT6"/>
-                        </constraints>
-                        <color key="textColor" systemColor="labelColor"/>
-                        <fontDescription key="fontDescription" type="system" pointSize="14"/>
-                        <textInputTraits key="textInputTraits" autocapitalizationType="sentences"/>
-                    </textView>
-                </subviews>
-                <constraints>
-                    <constraint firstItem="tvw-dW-6ZZ" firstAttribute="top" secondItem="A7E-tB-bt8" secondAttribute="bottom" constant="20" id="0dH-JO-88J"/>
-                    <constraint firstItem="iSa-8N-Hv8" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="4ZV-3N-slX"/>
-                    <constraint firstItem="A7E-tB-bt8" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="5Sn-NM-8cH"/>
-                    <constraint firstItem="tvw-dW-6ZZ" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="10" id="BLu-Nt-joW"/>
-                    <constraint firstItem="xNN-G5-v1z" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="5" id="DEb-L0-ddb"/>
-                    <constraint firstItem="jGj-qw-Jxf" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="HEt-LE-uFh"/>
-                    <constraint firstItem="xNN-G5-v1z" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="HQ3-ci-USQ"/>
-                    <constraint firstItem="A7E-tB-bt8" firstAttribute="top" secondItem="jGj-qw-Jxf" secondAttribute="bottom" constant="40" id="RuY-X2-O6F"/>
-                    <constraint firstAttribute="trailing" secondItem="xNN-G5-v1z" secondAttribute="trailing" constant="15" id="Wsy-tD-w1a"/>
-                    <constraint firstAttribute="trailing" secondItem="A7E-tB-bt8" secondAttribute="trailing" constant="15" id="d4w-Rg-20z"/>
-                    <constraint firstItem="jGj-qw-Jxf" firstAttribute="top" secondItem="iSa-8N-Hv8" secondAttribute="bottom" id="egk-ZY-YEY"/>
-                    <constraint firstAttribute="trailing" secondItem="iSa-8N-Hv8" secondAttribute="trailing" constant="15" id="fQd-aq-Kus"/>
-                    <constraint firstItem="iSa-8N-Hv8" firstAttribute="top" secondItem="xNN-G5-v1z" secondAttribute="bottom" constant="10" id="kVv-l3-5GA"/>
-                    <constraint firstItem="tvw-dW-6ZZ" firstAttribute="centerX" secondItem="H2p-sc-9uM" secondAttribute="centerX" id="mPc-RW-Pa9"/>
-                    <constraint firstAttribute="bottom" secondItem="tvw-dW-6ZZ" secondAttribute="bottom" constant="30" id="yqj-v4-NH4"/>
-                </constraints>
-            </tableViewCellContentView>
-            <connections>
-                <outlet property="bottomView" destination="TPi-ay-xXH" id="8GL-yw-0cf"/>
-                <outlet property="forgetPWBtn" destination="jGj-qw-Jxf" id="dZT-hD-9F1"/>
-                <outlet property="segmentdView" destination="xNN-G5-v1z" id="Jhe-RP-h0l"/>
-                <outlet property="submitBtn" destination="A7E-tB-bt8" id="G2e-Bu-wXJ"/>
-                <outlet property="textView" destination="tvw-dW-6ZZ" id="mte-i0-of0"/>
-                <outlet property="topView" destination="jld-kN-TDB" id="EZp-2A-NZD"/>
-            </connections>
-            <point key="canvasLocation" x="435.38461538461536" y="271.56398104265401"/>
-        </tableViewCell>
-    </objects>
-    <resources>
-        <systemColor name="labelColor">
-            <color red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
-        </systemColor>
-        <systemColor name="systemBackgroundColor">
-            <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
-        </systemColor>
-    </resources>
-</document>

+ 0 - 560
Koala/Koala/Modular/Login/V/Register/JDRegisterCell.swift

@@ -1,560 +0,0 @@
-//
-//  JDRegisterCell.swift
-//  Koala
-//
-//  Created by mac on 2023/10/16.
-//  Copyright © 2023 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class JDRegisterCell: BaseTableViewCell {
-    var index: Int = 0 // 选择下标 ,0 手机 1 ,邮箱
-    var registerVM: RegisterViewModel?
-    
-    var isAgree = false {
-        didSet {
-            //            self.updateAgree()
-        }
-    }
-    
-    lazy var countryView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        v.isUserInteractionEnabled = true
-        
-        v.addGestureRecognizer(UITapGestureRecognizer(target: self, action: #selector(clickCountryCodeAction)))
-        return v
-    }()
-    
-    lazy var countryLb: UILabel = {
-        let v = UILabel()
-        v.textColor = .black
-        v.setTextFont(.PFSM, 14)
-        v.text = switchLanguage("国际/地区")
-        return v
-    }()
-    
-    lazy var countryLineView: UIView = {
-        let v = UIView()
-        v.backgroundColor = _color("#E8E8E8&#E8E8E8")
-        return v
-    }()
-    
-    lazy var countryArrowIv: UIImageView = {
-        let v = UIImageView()
-        v.image = _image("Base_W_RightArrows&Base_W_RightArrows")
-        return v
-    }()
-    
-    lazy var phoneView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        return v
-    }()
-    
-    lazy var accountInputView: JDPhoneInputView = {
-        let inView = JDPhoneInputView()
-        
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickCountryCodeBlock = { [weak self] in
-            self?.clickCountryCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var codeBgView: UIView = {
-        let v = UIView()
-        
-        return v
-    }()
-    
-    lazy var codeInputView: JDCodeInputView = {
-        let inView = JDCodeInputView()
-        inView.sendBgView.isHidden = false
-        inView.textField.delegate = self
-        //        inView.setTitleText(text: switchLanguage("验证码"))
-        inView.setTextPlaceholder(text: switchLanguage("请输入验证码"))
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickSendCodeBlock = { [weak self] in
-            self?.clickSendCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var passwordView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        return v
-    }()
-    
-    lazy var pwInputView: JDPasswordInputView = {
-        let inView = JDPasswordInputView()
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        
-        inView.setTextPlaceholder(text: switchLanguage("请设置密码"))
-        
-        return inView
-    }()
-    
-    lazy var inviteCodeView: UIView = {
-        let v = UIView()
-        v.backgroundColor = .clear
-        return v
-    }()
-    
-    lazy var scanBtn: UIButton = {
-        let v = UIButton(type: .custom)
-        v.setImage(_image("jdmine_qrcode_scan&jdmine_qrcode_scan"), for: .normal)
-        v.addTarget(self, action: #selector(scanAction), for: .touchUpInside)
-        
-        return v
-    }()
-    
-    lazy var inviteInputView: JDPasswordInputView = {
-        let inView = JDPasswordInputView()
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.openBtn.isHidden = true
-        inView.textField.isSecureTextEntry = false
-        inView.setTextPlaceholder(text: switchLanguage("请输入邀请码(选填)"))
-        
-        return inView
-    }()
-    
-    lazy var submitBtn: UIButton = {
-        let submitBtn = UIButton(type: .custom)
-        submitBtn.setTitle(switchLanguage("注册"), for: .normal)
-        submitBtn.setTitleColor(WhiteTextColor, for: .normal)
-        submitBtn.backgroundColor = MainBackGroundColor
-        submitBtn.setViewLayerBorderColor(myColor: .clear, borderWidth: 0, maskBounds: 22)
-        submitBtn.setTextFont(.PFSM, 16)
-        submitBtn.addTarget(self, action: #selector(clickSubmitBtnAction), for: .touchUpInside)
-        return submitBtn
-        
-    }()
-    
-    lazy var useEmailLoginBtn: UIButton = {
-        let v = UIButton(type: .custom)
-        
-        v.setTitle(switchLanguage("使用邮箱注册"), for: .normal)
-        v.setTitleColor(.black, for: .normal)
-        v.setTextFont(.PFSR, 14)
-        v.reactive.controlEvents(.touchUpInside).observeValues { [weak self] _ in
-            
-            if self?.index == 0 {
-                self?.updateLayer(index: 1)
-            } else {
-                self?.updateLayer(index: 0)
-            }
-        }
-        
-        return v
-    }()
-    
-    override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
-        super.init(style: style, reuseIdentifier: reuseIdentifier)
-        
-        contentView.addSubview(self.countryView)
-        self.countryView.snp.makeConstraints { make in
-            make.left.equalTo(contentView.snp.left).offset(18)
-            make.right.equalTo(contentView.snp.right).offset(-18)
-            make.top.equalTo(contentView.snp.top).offset(10)
-            make.height.equalTo(50)
-        }
-        self.countryView.addSubview(self.countryLb)
-        self.countryLb.snp.makeConstraints { make in
-            make.left.equalTo(self.countryView.snp.left)
-            make.centerY.equalTo(self.countryView)
-        }
-        self.countryView.addSubview(self.countryArrowIv)
-        self.countryArrowIv.snp.makeConstraints { make in
-            make.right.equalTo(self.countryView.snp.right)
-            make.centerY.equalTo(self.countryView)
-            make.size.equalTo(CGSize(width: 5, height: 10))
-        }
-        self.countryView.addSubview(self.countryLineView)
-        self.countryLineView.snp.makeConstraints { make in
-            make.left.right.bottom.equalTo(self.countryView)
-            make.height.equalTo(1)
-        }
-        
-        contentView.addSubview(self.phoneView)
-        self.phoneView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.countryView.snp.bottom)
-            make.height.equalTo(50)
-        }
-        self.phoneView.addSubview(self.accountInputView)
-        self.accountInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.phoneView)
-        }
-        
-        contentView.addSubview(self.codeBgView)
-        self.codeBgView.snp.makeConstraints { make in
-            make.left.right.height.equalTo(self.countryView)
-            make.top.equalTo(self.phoneView.snp.bottom)
-        }
-        self.codeBgView.addSubview(self.codeInputView)
-        self.codeInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.codeBgView)
-        }
-        
-        contentView.addSubview(self.passwordView)
-        self.passwordView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.height.equalTo(50)
-            make.top.equalTo(self.codeBgView.snp.bottom)
-        }
-        
-        self.passwordView.addSubview(self.pwInputView)
-        self.pwInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.passwordView)
-        }
-        
-        contentView.addSubview(self.inviteCodeView)
-        self.inviteCodeView.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.height.equalTo(50)
-            make.top.equalTo(self.passwordView.snp.bottom)
-        }
-        
-        self.inviteCodeView.addSubview(self.inviteInputView)
-        self.inviteInputView.snp.makeConstraints { make in
-            make.edges.equalTo(self.inviteCodeView)
-        }
-        
-        self.inviteCodeView.addSubview(self.scanBtn)
-        self.scanBtn.snp.makeConstraints { make in
-            make.right.equalTo(self.inviteCodeView.snp.right).offset(2)
-            make.centerY.equalTo(self.inviteCodeView)
-            make.size.equalTo(CGSizeMake(30, 30))
-        }
-        
-        contentView.addSubview(self.submitBtn)
-        self.submitBtn.snp.makeConstraints { make in
-            make.left.right.equalTo(self.countryView)
-            make.top.equalTo(self.inviteInputView.snp.bottom).offset(75)
-            make.height.equalTo(44)
-        }
-        
-        contentView.addSubview(self.useEmailLoginBtn)
-        self.useEmailLoginBtn.snp.makeConstraints { make in
-            make.top.equalTo(self.submitBtn.snp.bottom).offset(26)
-            make.centerX.equalTo(contentView)
-            make.bottom.equalTo(contentView.snp.bottom).offset(-20)
-        }
-        
-        //        contentView.addSubview(textView)
-        //        textView.snp.makeConstraints { make in
-        //            make.top.equalTo(useEmailLoginBtn.snp.bottom).offset(150)
-        ////            make.centerX.equalTo(contentView)
-        ////            make.size.equalTo(CGSize(width: 200, height: 30))
-        //            make.left.equalTo(contentView.snp.left).offset(20)
-        //            make.right.equalTo(contentView.snp.right).offset(-20)
-        //            make.height.equalTo(40)
-        //            make.bottom.equalTo(contentView.snp.bottom).offset(-58)
-        //        }
-        
-        self.updateLayer(index: 0)
-    }
-    
-    @available(*, unavailable)
-    required init?(coder aDecoder: NSCoder) {
-        fatalError("init(coder:) has not been implemented")
-    }
-}
-
-extension JDRegisterCell: UITextFieldDelegate, UITextViewDelegate {
-    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-        // 判断超链接协议
-        if let sch = URL.scheme, sch == "User" {
-            let vc = BaseWebViewController()
-            
-            vc.url = getUserPolicyUrl()
-            vc.myNavigationBar.title_Label.text = switchLanguage("用户协议")
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-            
-            return true
-        } else if let sch = URL.scheme, sch == "Policy" {
-            let vc = BaseWebViewController()
-            
-            vc.url = getLicensePolicyUrl()
-            vc.myNavigationBar.title_Label.text = switchLanguage("隐私政策")
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-            
-            return true
-        }
-        return false
-    }
-    
-    // MARK: - 输入框的变化
-
-    @objc func inputChange(_ textField: UITextField) {
-        let text = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.registerVM?.account = text
-        } else if textField == self.codeInputView.textField {
-            self.registerVM?.code = text
-        } else if textField == self.pwInputView.textField {
-            self.registerVM?.pw = text
-        } else {
-            self.registerVM?.inviteCode = text
-        }
-    }
-    
-    // 限制输入
-    func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
-        let existingString: NSString = textField.text as NSString? ?? "" as NSString
-        let candidateString = existingString.replacingCharacters(in: range, with: string)
-        if candidateString.length < existingString.length {
-            return true
-        }
-        
-        return true
-    }
-    
-    // 已经开始编辑
-    func textFieldDidBeginEditing(_ textField: UITextField) {
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.removeErrorView()
-            //            self.accountInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else if textField == self.codeInputView.textField {
-            self.codeInputView.bgView.removeErrorView()
-            //            self.codeInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.removeErrorView()
-            //            self.pwInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-        //        else{
-        self.inviteInputView.bgView.removeErrorView()
-        //            self.inviteInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        //        }
-    }
-    
-    // 已经结束编辑
-    func textFieldDidEndEditing(_ textField: UITextField) {
-        let text: String = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.updateLayerBorderColor(color: .clear)
-            if self.index == 0 { // 手机错误提示
-                guard text.length > 0 else {
-                    //                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入手机号"))
-                    
-                    return
-                }
-            } else if self.index == 1 { // 邮箱错误提示
-                guard text.length > 0 else {
-                    //                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入邮箱"))
-                    return
-                }
-                let pp = "^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$"
-                let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-                
-                if !predicate.evaluate(with: text) {
-                    //                    self.accountInputView.bgView.addErrorView(switchLanguage("邮箱格式错误"))
-                }
-            }
-        } else if textField == self.codeInputView.textField {
-            self.codeInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-                //                self.codeInputView.bgView.addErrorView(switchLanguage("请输入验证码"))
-                return
-            }
-        } else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-                //                self.pwInputView.bgView.addErrorView(switchLanguage("请输入密码"))
-                return
-            }
-            let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-            let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-            
-            if !predicate.evaluate(with: text) {
-                //                self.pwInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-            }
-        } else if textField == self.inviteInputView.textField {
-            self.inviteInputView.bgView.updateLayerBorderColor(color: .clear)
-        }
-    }
-}
-
-extension JDRegisterCell {
-    @objc func scanAction() {
-        let scanVC = ScanCodeViewController()
-        scanVC.modalPresentationStyle = .fullScreen
-        scanVC.scanBlock = { resultString in
-            
-            if resultString.hasPrefix("http") {
-                let urlDomain = OperationalUserInfoData.getShardDomain()+"/rf/"
-                
-                if resultString.hasPrefix(urlDomain) {
-                    let resultLength = resultString.length
-                    let domainLength = urlDomain.length
-                    
-                    let str = resultString.substring(fromIndex: domainLength) // resultString.suffix(resultLength-domainLength)
-                    
-                    self.inviteInputView.textField.text = str
-                }
-                
-            } else {
-                self.inviteInputView.textField.text = resultString
-            }
-        }
-        
-        currentVc()?.navigationController?.present(scanVC, animated: true)
-    }
-
-    //    func updateAgree() -> Void {
-    //        if self.isAgree{
-    //            self.protocolBtn .setImage(_image("Base_W_Agree&Base_W_Agree").imageWithTintColor(color: MainBackGroundColor), for: .normal)
-    //        }else{
-    //            self.protocolBtn .setImage(_image("Base_W_unAgree&Base_W_unAgree"), for: .normal)
-    //        }
-    //
-    //        self.updateProtocolAtt()
-    //    }
-    //
-    //    func updateProtocolAtt() -> Void {
-    //        let text = switchLanguage("我已阅读并同意服务协议")
-    //
-    //        let range = (text as NSString).range(of: switchLanguage("服务协议"))
-    //
-    //        if self.isAgree{
-    //            let att = NSMutableAttributedString.init(string: text,attributes: [NSAttributedString.Key.foregroundColor: MainBackGroundColor])
-    //            att.addAttributes([NSAttributedString.Key.underlineColor: MainBackGroundColor,NSAttributedString.Key.underlineStyle : NSNumber(value: NSUnderlineStyle.single.union(.single).rawValue)], range: range)
-    //            self.protocol1Btn.setAttributedTitle(att, for: .normal)
-    //        }else{
-    //            let att = NSMutableAttributedString.init(string: text,attributes: [NSAttributedString.Key.foregroundColor: MidTextColor])
-    //            att.addAttributes([NSAttributedString.Key.underlineColor: MidTextColor,NSAttributedString.Key.underlineStyle : NSNumber(value: NSUnderlineStyle.single.union(.single).rawValue)], range: range)
-    //            self.protocol1Btn.setAttributedTitle(att, for: .normal)
-    //        }
-    //
-    //
-    //    }
-    
-    func updateLayer(index: Int) {
-        self.index = index
-        self.registerVM?.type = index
-        if index == 0 {
-            self.accountInputView.codeBgView.isHidden = false
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("请输入手机号码"))
-            //            self.accountInputView.setTitleText(text: switchLanguage("电话号码"))
-            self.useEmailLoginBtn.setTitle(switchLanguage("使用邮箱注册"), for: .normal)
-            self.accountInputView.updateLayerView(index: 0)
-            
-        } else {
-            self.accountInputView.codeBgView.isHidden = true
-            self.accountInputView.updateLayerView(index: 1)
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("请输入邮箱地址"))
-            
-            self.useEmailLoginBtn.setTitle(switchLanguage("使用手机注册"), for: .normal)
-            //            self.accountInputView.setTitleText(text: switchLanguage("邮箱"))
-        }
-        
-        self.codeInputView.setTextPlaceholder(text: switchLanguage("请输入验证码"))
-        self.pwInputView.setTextPlaceholder(text: switchLanguage("设置登录密码"))
-        self.inviteInputView.setTextPlaceholder(text: switchLanguage("请输入邀请码(选填)"))
-        
-        self.accountInputView.textField.text = ""
-        self.codeInputView.textField.text = ""
-        self.pwInputView.textField.text = ""
-        self.inviteInputView.textField.text = ""
-        
-        self.accountInputView.bgView.removeErrorView()
-        self.codeInputView.bgView.removeErrorView()
-        self.pwInputView.bgView.removeErrorView()
-        self.inviteInputView.bgView.removeErrorView()
-        
-        self.registerVM?.account = ""
-        self.registerVM?.pw = ""
-        self.registerVM?.code = ""
-        self.registerVM?.inviteCode = ""
-    }
-    
-    //
-    func registerUpdate(vm: RegisterViewModel) {
-        self.registerVM = vm
-        self.updateLayer(index: 0)
-        
-        self.countryLb.text = "国际/地区("+vm.countryName+")"
-        
-        //        self.accountInputView.rightCodeBtn.setTitle("+"+vm.areaCode, for: .normal)
-        self.accountInputView.rightCodeLb.text = "+"+vm.areaCode
-        self.accountInputView.textField.text = vm.account
-        self.codeInputView.textField.text = vm.code
-        self.pwInputView.textField.text = vm.pw
-        self.inviteInputView.textField.text = vm.inviteCode
-    }
-    
-    @objc func clickCountryCodeAction() {
-        self.endEditing(true)
-        let pop = CountrySelectPopView()
-        pop.showRelyPopupView(view: self.countryView) { [weak self] model in
-            if model.areaCode.length > 0 {
-                //                self?.accountInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: model.abbreviate), for: .normal)
-                
-                self?.countryLb.text = "国际/地区("+model.name+")"
-                //                self?.accountInputView.rightCodeBtn.setTitle("+"+model.areaCode, for: .normal)
-                self?.accountInputView.rightCodeLb.text = "+"+model.areaCode
-                self?.registerVM?.abbreviate = model.abbreviate
-                self?.registerVM?.areaCode = model.areaCode
-                self?.registerVM?.countryName = model.name
-            }
-        }
-    }
-    
-    func clickSendCodeAction() {
-        self.endEditing(true)
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-        
-        self.registerVM?.netCode()
-    }
-    
-    @objc func clickProtocolBtnAction() {
-        self.isAgree = !self.isAgree
-    }
-    
-    @objc func clickProtocol1BtnAction() {
-        let vc = BaseWebViewController()
-        vc.url = "https://m.ddse.com/agreement"
-        vc.titleStr = switchLanguage("服务协议")
-        currentVc()?.navigationController?.pushViewController(vc, animated: true)
-    }
-    
-    @objc func clickSubmitBtnAction() {
-        self.endEditing(true)
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入账号"))
-            return
-        }
-        
-        guard (self.codeInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入验证码"))
-            return
-        }
-        
-        guard (self.pwInputView.textField.text ?? "").length > 0 else {
-            ProgressHUD.showError(status: switchLanguage("请输入密码"))
-            return
-        }
-        
-        let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-        let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-        
-        if !predicate.evaluate(with: self.pwInputView.textField.text ?? "") {
-            //                self.pwInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-            ProgressHUD.showError(status: switchLanguage("8-20位字符,包含数字和字母"))
-            return
-        }
-        
-        //        guard self.isAgree else {
-        //            ProgressHUD.showError(status: switchLanguage("请勾选协议"))
-        //            return
-        //        }
-        
-        self.registerVM?.netRegister()
-    }
-}

+ 0 - 193
Koala/Koala/Modular/Login/V/Register/JDRegisterView.swift

@@ -1,193 +0,0 @@
-//
-//  JDRegisterView.swift
-//  Koala
-//
-//  Created by mac on 2023/10/16.
-//  Copyright © 2023 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class JDRegisterView: BaseView {
-    var VM: RegisterViewModel?
-    lazy var topView: LoginTopView = {
-        let topView = LoginTopView(frame: CGRect(x: 0, y: 0, width: SCREEN_WIDTH, height: 120))
-        topView.titleLab.text = switchLanguage("注册")
-        topView.backgroundColor = .clear
-        return topView
-    }()
-    
-    lazy var textView: UITextView = {
-        let v = UITextView()
-        
-        let str1: String = switchLanguage("注册即表示您同意")
-        let str2 = " "+switchLanguage("《用户协议》")
-        let str3 = " "+switchLanguage("和")
-        let str4 = " "+switchLanguage("《隐私条款》")
-        let str5 = "\n\n"
-        
-        let str6: String = switchLanguage("已有账户?立即")
-        let str7 = " "+switchLanguage("登录")
-        
-        let attri = NSMutableAttributedString(attributedString: NSAttributedString(string: str1+str2+str3+str4+str5+str6+str7, attributes: [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: UIFont.systemFont(ofSize: 14)]))
-        attri.addAttributes([NSAttributedString.Key.link: "Login"+"://"],
-                            range: ((attri.string) as NSString).range(of: str7))
-        attri.addAttributes([NSAttributedString.Key.link: "User"+"://"],
-                            range: ((attri.string) as NSString).range(of: str2))
-        
-        attri.addAttributes([NSAttributedString.Key.link: "Policy"+"://"],
-                            range: ((attri.string) as NSString).range(of: str4))
-        
-        v.linkTextAttributes = [NSAttributedString.Key.foregroundColor: MainBackGroundColor]
-        v.attributedText = attri
-        v.delegate = self
-        v.textAlignment = .center
-        v.backgroundColor = .clear
-        v.isEditable = false
-        v.isScrollEnabled = false
-        return v
-    }()
-    
-    lazy var tableView: BaseTableView = { [weak self] in
-        let tableView = BaseTableView(frame: .zero, style: .plain)
-        tableView.separatorStyle = .none
-        tableView.delegate = self
-        tableView.dataSource = self
-        tableView.backgroundColor = .clear
-        tableView.tableHeaderView = UIView()
-        tableView.tableFooterView = UIView()
-        tableView.showsHorizontalScrollIndicator = false
-        tableView.showsVerticalScrollIndicator = false
-        
-        tableView.register(JDRegisterCell.self, forCellReuseIdentifier: JDRegisterCell.description())
- 
-        tableView.contentInsetAdjustmentBehavior = .never
-        return tableView
-    }()
-
-    lazy var bgIv: UIImageView = {
-        let v = UIImageView()
-        v.image = _image("jdmine_join_delegateBg&jdmine_join_delegateBg")
-        return v
-    }()
-    
-    override func subView() {
-        super.subView()
-        
-        self.addSubview(self.topView)
-        self.addSubview(self.tableView)
-        
-        self.addSubview(self.textView)
-        
-        self.mySwitchLanguage()
-        self.mySwitchSkin()
-    }
-    
-    override func layoutSubviews() {
-        super.layoutSubviews()
-        
-        self.textView.snp.makeConstraints { make in
-            make.left.equalTo(self.snp.left).offset(20)
-            make.right.equalTo(self.snp.right).offset(-20)
-            make.height.equalTo(80)
-            make.bottom.equalTo(self.snp.bottom).offset(-58)
-        }
-        
-        self.tableView.snp.makeConstraints { make in
-            make.top.equalTo(self.topView.snp.bottom)
-            make.left.right.equalToSuperview()
-            make.bottom.equalTo(self.textView.snp.top)
-        }
-    }
-    
-    override func setViewModel(viewmodel: AnyObject) {
-        guard viewmodel is RegisterViewModel else {
-            return
-        }
-        self.VM = viewmodel as? RegisterViewModel
-        super.setViewModel(viewmodel: viewmodel)
-    }
-    
-    override func mySwitchLanguage() {}
-    
-    override func mySwitchSkin() {
-        self.tableView.backgroundColor = .clear
-    }
-    
-    override func blindModel() {
-        self.VM?.codeAction.values.observeValues { [weak self] resilt in
-            if resilt {
-                let indexPath = NSIndexPath(row: 0, section: 0)
-                if let cell: JDRegisterCell = self?.tableView.cellForRow(at: indexPath as IndexPath) as? JDRegisterCell {
-                    cell.codeInputView.updateTimer()
-                }
-            }
-        }
-    }
-}
-
-extension JDRegisterView: UITextViewDelegate {
-    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-        // 判断超链接协议
-        if let sch = URL.scheme, sch == "User" {
-            let vc = BaseWebViewController()
-            
-            vc.url = getUserPolicyUrl()
-            vc.myNavigationBar.title_Label.text = switchLanguage("用户协议")
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-            
-            return true
-        } else if let sch = URL.scheme, sch == "Policy" {
-            let vc = BaseWebViewController()
-            
-            vc.url = getLicensePolicyUrl()
-            vc.myNavigationBar.title_Label.text = switchLanguage("隐私政策")
-            currentVc()?.navigationController?.pushViewController(vc, animated: true)
-            
-            return true
-            
-        } else if let sch = URL.scheme, sch == "Login" {
-            currentVc()?.navigationController?.popViewController(animated: true)
-            return true
-        }
-        return false
-    }
-}
-    
-// 代理
-extension JDRegisterView: UITableViewDelegate, UITableViewDataSource {
-    func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
-        return 1
-    }
-    
-    func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
-//        let cell:RegisterCell = tableView.dequeueReusableCell(withIdentifier: "RegisterCell") as! RegisterCell
-        
-        let cell = tableView.dequeueReusableCell(withIdentifier: JDRegisterCell.description()) as! JDRegisterCell
-        cell.registerUpdate(vm: self.VM!)
-        cell.backgroundColor = .clear
-        return cell
-    }
-    
-    func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
-        return -1
-    }
-    
-    func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView? {
-        return UIView()
-    }
-    
-    func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
-        return UIView()
-    }
-
-    func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
-        return 0
-    }
-    
-    func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
-        return 2
-    }
-    
-    func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {}
-}

+ 0 - 402
Koala/Koala/Modular/Login/V/Register/RegisterCell.swift

@@ -1,402 +0,0 @@
-//
-//  RegisterCell.swift
-//  Koala
-//
-//  Created by 刘千军 on 2022/12/25.
-//  Copyright © 2022 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class RegisterCell: BaseTableViewCell {
-    @IBOutlet var segmentdView: UIView!
-    
-    @IBOutlet var accountBgView: UIView!
-    
-    @IBOutlet var codeBgView: UIView!
-    @IBOutlet var pwBgView: UIView!
-    @IBOutlet var inviteBgView: UIView!
-    
-    @IBOutlet var protocolBtn: UIButton!
-    
-    @IBOutlet var protocol1Btn: UIButton!
-    
-    @IBOutlet var submitBtn: UIButton!
-    
-    @IBOutlet var textView: UITextView!
-    
-    var index: Int = 0 // 选择下标 ,0 手机 1 ,邮箱
-    var registerVM: RegisterViewModel?
-    
-    var isAgree = false {
-        didSet {
-            self.updateAgree()
-        }
-    }
-    
-    lazy var segmentedControl: HMSegmentedControl = {
-        let segmentedControl = HMSegmentedControl(frame: CGRect(x: 0, y: 0, width: SCREEN_WIDTH - 30, height: 40))
-        segmentedControl.selectedSegmentIndex = 0
-        segmentedControl.backgroundColor = .clear
-        segmentedControl.titleTextAttributes = [NSAttributedString.Key.foregroundColor: _color("#999999&#999999"), NSAttributedString.Key.font: _PFSM(14)]
-        segmentedControl.selectedTitleTextAttributes = [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: _PFSM(14)]
-        segmentedControl.selectionIndicatorHeight = 2
-        segmentedControl.segmentWidthStyle = .dynamic
-        segmentedControl.selectionStyle = .textWidthStripe
-        segmentedControl.selectionIndicatorLocation = .bottom
-        segmentedControl.selectionIndicatorColor = MainBackGroundColor
-        segmentedControl.indexChangeBlock = { [weak self] index in
-            self?.updateLayer(index: Int(index))
-        }
-        return segmentedControl
-    }()
-    
-    lazy var accountInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.codeBgView.isHidden = false
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickCountryCodeBlock = { [weak self] in
-            self?.clickCountryCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var codeInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.sendBgView.isHidden = false
-        inView.textField.delegate = self
-        inView.setTitleText(text: switchLanguage("验证码"))
-        
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.clickSendCodeBlock = { [weak self] in
-            self?.clickSendCodeAction()
-        }
-        return inView
-    }()
-    
-    lazy var pwInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.setOpenBtnShow()
-        inView.textField.delegate = self
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        inView.setTitleText(text: switchLanguage("设置登录密码"))
-        return inView
-    }()
-    
-    lazy var inviteInputView: BaseInputView = {
-        let inView = BaseInputView()
-        inView.textField.delegate = self
-        inView.setTitleText(text: switchLanguage("邀请码(选填)"))
-        inView.textField.addTarget(self, action: #selector(inputChange(_:)), for: .editingChanged)
-        return inView
-    }()
-    
-    override func awakeFromNib() {
-        super.awakeFromNib()
-        
-        self.backgroundColor = ALLBackGroundColor
-        self.contentView.backgroundColor = .clear
-        self.segmentdView.backgroundColor = .clear
-        self.accountBgView.backgroundColor = .clear
-        self.codeBgView.backgroundColor = .clear
-        self.pwBgView.backgroundColor = .clear
-        self.inviteBgView.backgroundColor = .clear
-        
-        self.segmentdView.addSubview(self.segmentedControl)
-        self.accountBgView.addSubview(self.accountInputView)
-        self.codeBgView.addSubview(self.codeInputView)
-        self.pwBgView.addSubview(self.pwInputView)
-        self.inviteBgView.addSubview(self.inviteInputView)
-        
-        self.accountInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.codeInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.pwInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.inviteInputView.snp.makeConstraints { make in
-            make.edges.equalToSuperview()
-        }
-        
-        self.segmentedControl.sectionTitles = [switchLanguage("手机"), switchLanguage("邮箱")]
-        
-        self.submitBtn.setTitle(switchLanguage("注册"), for: .normal)
-        self.submitBtn.setTitleColor(WhiteTextColor, for: .normal)
-        self.submitBtn.backgroundColor = MainBackGroundColor
-        self.submitBtn.setViewLayerBorderColor(myColor: .clear, borderWidth: 0, maskBounds: 4)
-        self.submitBtn.setTextFont(.PFSM, 16)
-        self.submitBtn.addTarget(self, action: #selector(clickSubmitBtnAction), for: .touchUpInside)
-        
-        let str1: String = switchLanguage("已有账户?")
-        let str2 = " " + switchLanguage("快速登录")
-        
-        let attri = NSMutableAttributedString(attributedString: NSAttributedString(string: str1 + str2, attributes: [NSAttributedString.Key.foregroundColor: TitleTextColor, NSAttributedString.Key.font: UIFont.systemFont(ofSize: 14)]))
-        attri.addAttributes([NSAttributedString.Key.link: "Login" + "://"],
-                            range: ((attri.string) as NSString).range(of: str2))
-        self.textView.linkTextAttributes = [NSAttributedString.Key.foregroundColor: MainBackGroundColor]
-        self.textView.attributedText = attri
-        self.textView.delegate = self
-        self.textView.textAlignment = .center
-        self.textView.backgroundColor = .clear
-        self.textView.isEditable = false
-        
-        updateLayer(index: 0)
-        
-        self.protocol1Btn.setTextFont(.PFSR, 10)
-       
-        self.isAgree = false
-        
-        self.protocolBtn.addTarget(self, action: #selector(clickProtocolBtnAction), for: .touchUpInside)
-        
-        self.protocol1Btn.addTarget(self, action: #selector(clickProtocol1BtnAction), for: .touchUpInside)
-    }
-
-    override func setSelected(_ selected: Bool, animated: Bool) {
-        super.setSelected(selected, animated: animated)
-
-        
-    }
-}
-
-extension RegisterCell: UITextFieldDelegate, UITextViewDelegate {
-    func textView(_ textView: UITextView, shouldInteractWith URL: URL, in characterRange: NSRange) -> Bool {
-        // 判断超链接协议
-        if let sch = URL.scheme, sch == "Login" {
-            currentVc()?.navigationController?.popViewController(animated: true)
-            return true
-        }
-        return false
-    }
-    
-    // MARK: - 输入框的变化
-
-    @objc func inputChange(_ textField: UITextField) {
-        let text = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.registerVM?.account = text
-        } else if textField == self.codeInputView.textField {
-            self.registerVM?.code = text
-        } else if textField == self.pwInputView.textField {
-            self.registerVM?.pw = text
-        } else {
-            self.registerVM?.inviteCode = text
-        }
-    }
-    
-    // 限制输入
-    func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
-        let existingString: NSString = textField.text as NSString? ?? "" as NSString
-        let candidateString = existingString.replacingCharacters(in: range, with: string)
-        if candidateString.length < existingString.length {
-            return true
-        }
-      
-        return true
-    }
-    
-    // 已经开始编辑
-    func textFieldDidBeginEditing(_ textField: UITextField) {
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.removeErrorView()
-            self.accountInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else if textField == self.codeInputView.textField {
-            self.codeInputView.bgView.removeErrorView()
-            self.codeInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.removeErrorView()
-            self.pwInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        } else {
-            self.inviteInputView.bgView.removeErrorView()
-            self.inviteInputView.bgView.updateLayerBorderColor(color: MainBackGroundColor)
-        }
-    }
-    
-    // 已经结束编辑
-    func textFieldDidEndEditing(_ textField: UITextField) {
-        let text: String = textField.text ?? ""
-        if textField == self.accountInputView.textField {
-            self.accountInputView.bgView.updateLayerBorderColor(color: .clear)
-            if self.index == 0 { // 手机错误提示
-                guard text.length > 0 else {
-                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入手机号"))
-                    return
-                }
-            } else if self.index == 1 { // 邮箱错误提示
-                guard text.length > 0 else {
-                    self.accountInputView.bgView.addErrorView(switchLanguage("请输入邮箱"))
-                    return
-                }
-                let pp = "^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$"
-                let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-            
-                if !predicate.evaluate(with: text) {
-                    self.accountInputView.bgView.addErrorView(switchLanguage("邮箱格式错误"))
-                }
-            }
-        } else if textField == self.codeInputView.textField {
-            self.codeInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-                self.codeInputView.bgView.addErrorView(switchLanguage("请输入验证码"))
-                return
-            }
-        } else if textField == self.pwInputView.textField {
-            self.pwInputView.bgView.updateLayerBorderColor(color: .clear)
-            guard text.length > 0 else {
-                self.pwInputView.bgView.addErrorView(switchLanguage("请输入密码"))
-                return
-            }
-            let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-            let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-        
-            if !predicate.evaluate(with: text) {
-                self.pwInputView.bgView.addErrorView(switchLanguage("8-20位字符,必须包含数字和字母"))
-            }
-        } else if textField == self.inviteInputView.textField {
-            self.inviteInputView.bgView.updateLayerBorderColor(color: .clear)
-        }
-    }
-}
-
-extension RegisterCell {
-    func updateAgree() {
-        if self.isAgree {
-            self.protocolBtn.setImage(_image("Base_W_Agree&Base_W_Agree").imageWithTintColor(color: MainBackGroundColor), for: .normal)
-        } else {
-            self.protocolBtn.setImage(_image("Base_W_unAgree&Base_W_unAgree"), for: .normal)
-        }
-        
-        self.updateProtocolAtt()
-    }
-    
-    func updateProtocolAtt() {
-        let text = switchLanguage("我已阅读并同意服务协议")
-       
-        let range = (text as NSString).range(of: switchLanguage("服务协议"))
-        
-        if self.isAgree {
-            let att = NSMutableAttributedString(string: text, attributes: [NSAttributedString.Key.foregroundColor: MainBackGroundColor])
-            att.addAttributes([NSAttributedString.Key.underlineColor: MainBackGroundColor, NSAttributedString.Key.underlineStyle: NSNumber(value: NSUnderlineStyle.single.union(.single).rawValue)], range: range)
-            self.protocol1Btn.setAttributedTitle(att, for: .normal)
-        } else {
-            let att = NSMutableAttributedString(string: text, attributes: [NSAttributedString.Key.foregroundColor: MidTextColor])
-            att.addAttributes([NSAttributedString.Key.underlineColor: MidTextColor, NSAttributedString.Key.underlineStyle: NSNumber(value: NSUnderlineStyle.single.union(.single).rawValue)], range: range)
-            self.protocol1Btn.setAttributedTitle(att, for: .normal)
-        }
-    }
-    
-    func updateLayer(index: Int) {
-        self.index = index
-        self.registerVM?.type = index
-        if index == 0 {
-            self.accountInputView.codeBgView.isHidden = false
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("电话号码"))
-            self.accountInputView.setTitleText(text: switchLanguage("电话号码"))
-           
-        } else {
-            self.accountInputView.codeBgView.isHidden = true
-            self.accountInputView.setTextPlaceholder(text: switchLanguage("邮箱"))
-            self.accountInputView.setTitleText(text: switchLanguage("邮箱"))
-        }
-        
-        self.codeInputView.setTextPlaceholder(text: switchLanguage("验证码"))
-        self.pwInputView.setTextPlaceholder(text: switchLanguage("设置登录密码"))
-        self.inviteInputView.setTextPlaceholder(text: switchLanguage("邀请码(选填)"))
-       
-        self.accountInputView.textField.text = ""
-        self.codeInputView.textField.text = ""
-        self.pwInputView.textField.text = ""
-        self.inviteInputView.textField.text = ""
-        
-        self.accountInputView.bgView.removeErrorView()
-        self.codeInputView.bgView.removeErrorView()
-        self.pwInputView.bgView.removeErrorView()
-        self.inviteInputView.bgView.removeErrorView()
-        
-        self.registerVM?.account = ""
-        self.registerVM?.pw = ""
-        self.registerVM?.code = ""
-        self.registerVM?.inviteCode = ""
-    }
-    
-    //
-    func registerUpdate(vm: RegisterViewModel) {
-        self.registerVM = vm
-        self.updateLayer(index: 0)
-        self.accountInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: vm.abbreviate), for: .normal)
-        self.accountInputView.rightCodeBtn.setTitle("+" + vm.areaCode, for: .normal)
-        self.accountInputView.textField.text = vm.account
-        self.codeInputView.textField.text = vm.code
-        self.pwInputView.textField.text = vm.pw
-        self.inviteInputView.textField.text = vm.inviteCode
-    }
-    
-    @objc func clickCountryCodeAction() {
-        self.endEditing(true)
-        let pop = CountrySelectPopView()
-        pop.showRelyPopupView(view: self.accountInputView.bgView) { [weak self] model in
-            if model.areaCode.length > 0 {
-                self?.accountInputView.leftCodeBtn.setTitle(emojiFlagForISOCountryCode(countryCode: model.abbreviate), for: .normal)
-                
-                self?.accountInputView.rightCodeBtn.setTitle("+" + model.areaCode, for: .normal)
-                self?.registerVM?.abbreviate = model.abbreviate
-                self?.registerVM?.areaCode = model.areaCode
-            }
-        }
-    }
-    
-    func clickSendCodeAction() {
-        self.endEditing(true)
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-            
-        self.registerVM?.netCode()
-    }
-    
-    @objc func clickProtocolBtnAction() {
-        self.isAgree = !self.isAgree
-    }
-    
-    @objc func clickProtocol1BtnAction() {
-        let vc = BaseWebViewController()
-        vc.url = "https://m.ddse.com/agreement"
-        vc.titleStr = switchLanguage("服务协议")
-        currentVc()?.navigationController?.pushViewController(vc, animated: true)
-    }
-    
-    @objc func clickSubmitBtnAction() {
-        self.endEditing(true)
-        guard (self.accountInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-        
-        guard (self.codeInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-    
-        guard (self.pwInputView.textField.text ?? "").length > 0 else {
-            return
-        }
-        
-        let pp = "^(?=.*[0-9])(?=.*[a-zA-Z])[0-9a-zA-Z~!@#$%^&*.?_-]{8,20}$"
-        let predicate = NSPredicate(format: "SELF MATCHES %@", pp)
-    
-        if !predicate.evaluate(with: self.pwInputView.textField.text ?? "") {
-            return
-        }
-        
-        guard self.isAgree else {
-            ProgressHUD.showError(status: switchLanguage("请勾选协议"))
-            return
-        }
-        
-        self.registerVM?.netRegister()
-    }
-}

+ 0 - 129
Koala/Koala/Modular/Login/V/Register/RegisterCell.xib

@@ -1,129 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="21507" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
-    <device id="retina6_0" orientation="portrait" appearance="light"/>
-    <dependencies>
-        <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21505"/>
-        <capability name="System colors in document resources" minToolsVersion="11.0"/>
-        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
-    </dependencies>
-    <objects>
-        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
-        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
-        <tableViewCell contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" rowHeight="574" id="KGk-i7-Jjw" customClass="RegisterCell" customModule="Koala" customModuleProvider="target">
-            <rect key="frame" x="0.0" y="0.0" width="424" height="574"/>
-            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
-            <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
-                <rect key="frame" x="0.0" y="0.0" width="424" height="574"/>
-                <autoresizingMask key="autoresizingMask"/>
-                <subviews>
-                    <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="MF5-7V-kNC">
-                        <rect key="frame" x="15" y="5" width="394" height="40"/>
-                        <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="40" id="ai3-eb-IKH"/>
-                        </constraints>
-                    </view>
-                    <stackView opaque="NO" contentMode="scaleToFill" axis="vertical" translatesAutoresizingMaskIntoConstraints="NO" id="DQE-2N-Iaj">
-                        <rect key="frame" x="15" y="55" width="394" height="300"/>
-                        <subviews>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="j2Z-JK-RKR">
-                                <rect key="frame" x="0.0" y="0.0" width="394" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                                <constraints>
-                                    <constraint firstAttribute="height" constant="75" id="Dhk-p7-gn9"/>
-                                </constraints>
-                            </view>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="pGQ-lL-F5f">
-                                <rect key="frame" x="0.0" y="75" width="394" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                            </view>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Hza-zs-9AE">
-                                <rect key="frame" x="0.0" y="150" width="394" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                            </view>
-                            <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="cS3-jo-wvZ">
-                                <rect key="frame" x="0.0" y="225" width="394" height="75"/>
-                                <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                            </view>
-                        </subviews>
-                        <constraints>
-                            <constraint firstItem="pGQ-lL-F5f" firstAttribute="height" secondItem="j2Z-JK-RKR" secondAttribute="height" id="8qO-JV-EFW"/>
-                            <constraint firstItem="cS3-jo-wvZ" firstAttribute="height" secondItem="j2Z-JK-RKR" secondAttribute="height" id="A7z-LR-BdW"/>
-                            <constraint firstItem="Hza-zs-9AE" firstAttribute="height" secondItem="j2Z-JK-RKR" secondAttribute="height" id="pIU-Se-OLn"/>
-                        </constraints>
-                    </stackView>
-                    <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="zwq-Oq-xPy">
-                        <rect key="frame" x="0.0" y="355" width="40" height="37"/>
-                        <constraints>
-                            <constraint firstAttribute="width" constant="40" id="wmR-BA-iyj"/>
-                        </constraints>
-                        <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
-                    </button>
-                    <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="690-Z6-ahJ">
-                        <rect key="frame" x="15" y="452" width="394" height="42"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="42" id="4DQ-GN-rEl"/>
-                        </constraints>
-                        <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
-                        <state key="normal" title="Button"/>
-                    </button>
-                    <textView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" textAlignment="natural" translatesAutoresizingMaskIntoConstraints="NO" id="9kg-Bm-i9C">
-                        <rect key="frame" x="15" y="514" width="394" height="40"/>
-                        <color key="backgroundColor" systemColor="systemBackgroundColor"/>
-                        <constraints>
-                            <constraint firstAttribute="height" constant="40" id="39W-vC-3H9"/>
-                        </constraints>
-                        <color key="textColor" systemColor="labelColor"/>
-                        <fontDescription key="fontDescription" type="system" pointSize="14"/>
-                        <textInputTraits key="textInputTraits" autocapitalizationType="sentences"/>
-                    </textView>
-                    <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="leading" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="060-Ox-hEq">
-                        <rect key="frame" x="40" y="356.66666666666669" width="369" height="34"/>
-                        <inset key="imageEdgeInsets" minX="0.0" minY="0.0" maxX="2.2250738585072014e-308" maxY="0.0"/>
-                    </button>
-                </subviews>
-                <constraints>
-                    <constraint firstAttribute="trailing" secondItem="DQE-2N-Iaj" secondAttribute="trailing" constant="15" id="9zc-vB-2jn"/>
-                    <constraint firstItem="060-Ox-hEq" firstAttribute="centerY" secondItem="zwq-Oq-xPy" secondAttribute="centerY" id="EH3-iu-7qB"/>
-                    <constraint firstItem="9kg-Bm-i9C" firstAttribute="top" secondItem="690-Z6-ahJ" secondAttribute="bottom" constant="20" id="GNn-nM-ZkY"/>
-                    <constraint firstItem="690-Z6-ahJ" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="Mo3-iE-T8z"/>
-                    <constraint firstAttribute="trailing" secondItem="MF5-7V-kNC" secondAttribute="trailing" constant="15" id="Mxn-dP-VAS"/>
-                    <constraint firstItem="zwq-Oq-xPy" firstAttribute="top" secondItem="DQE-2N-Iaj" secondAttribute="bottom" id="Ng4-Oc-CxJ"/>
-                    <constraint firstAttribute="trailing" secondItem="060-Ox-hEq" secondAttribute="trailing" constant="15" id="PtM-gz-T19"/>
-                    <constraint firstItem="DQE-2N-Iaj" firstAttribute="top" secondItem="MF5-7V-kNC" secondAttribute="bottom" constant="10" id="Rbu-Cl-vno"/>
-                    <constraint firstAttribute="trailing" secondItem="9kg-Bm-i9C" secondAttribute="trailing" constant="15" id="Rk2-rd-geV"/>
-                    <constraint firstItem="zwq-Oq-xPy" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="bw9-h8-IZF"/>
-                    <constraint firstItem="060-Ox-hEq" firstAttribute="leading" secondItem="zwq-Oq-xPy" secondAttribute="trailing" id="cH5-PO-YMI"/>
-                    <constraint firstItem="690-Z6-ahJ" firstAttribute="top" secondItem="zwq-Oq-xPy" secondAttribute="bottom" constant="60" id="d4s-rg-FrE"/>
-                    <constraint firstAttribute="bottom" secondItem="9kg-Bm-i9C" secondAttribute="bottom" constant="20" id="fUq-HX-cbD"/>
-                    <constraint firstItem="DQE-2N-Iaj" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="iHD-aZ-Tnq"/>
-                    <constraint firstAttribute="trailing" secondItem="690-Z6-ahJ" secondAttribute="trailing" constant="15" id="qUz-OK-PGA"/>
-                    <constraint firstItem="MF5-7V-kNC" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="qWg-to-LGr"/>
-                    <constraint firstItem="9kg-Bm-i9C" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" constant="15" id="vgm-JE-z5q"/>
-                    <constraint firstItem="MF5-7V-kNC" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" constant="5" id="zGi-nL-gnF"/>
-                </constraints>
-            </tableViewCellContentView>
-            <connections>
-                <outlet property="accountBgView" destination="j2Z-JK-RKR" id="9Qr-SX-n4C"/>
-                <outlet property="codeBgView" destination="pGQ-lL-F5f" id="bw2-f6-pwX"/>
-                <outlet property="inviteBgView" destination="cS3-jo-wvZ" id="4we-HS-ixW"/>
-                <outlet property="protocol1Btn" destination="060-Ox-hEq" id="DOF-IY-7YC"/>
-                <outlet property="protocolBtn" destination="zwq-Oq-xPy" id="rFX-or-t3K"/>
-                <outlet property="pwBgView" destination="Hza-zs-9AE" id="9VU-B8-1Ej"/>
-                <outlet property="segmentdView" destination="MF5-7V-kNC" id="uch-ac-QJ5"/>
-                <outlet property="submitBtn" destination="690-Z6-ahJ" id="9Y4-VW-5HA"/>
-                <outlet property="textView" destination="9kg-Bm-i9C" id="HSX-2C-kfJ"/>
-            </connections>
-            <point key="canvasLocation" x="255.38461538461539" y="178.43601895734596"/>
-        </tableViewCell>
-    </objects>
-    <resources>
-        <systemColor name="labelColor">
-            <color red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
-        </systemColor>
-        <systemColor name="systemBackgroundColor">
-            <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
-        </systemColor>
-    </resources>
-</document>

+ 0 - 80
Koala/Koala/Modular/Login/VC/ForgotPasswordViewController.swift

@@ -1,80 +0,0 @@
-//
-//  ForgotPasswordViewController.swift
-//  Koala
-//
-//  Created by 刘千军 on 2022/12/26.
-//  Copyright © 2022 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class ForgotPasswordViewController: BaseViewController {
-    var viewModel = ForgotPasswordViewModel()
-    lazy var forgotPasswordView: JDForgotPasswordView = {
-        let view = JDForgotPasswordView(type: .ViewModel(ViewModel: self.viewModel))
-        return view
-    }()
-    
-    lazy var bgIv: UIImageView = {
-        let v = UIImageView()
-        v.image = _image("Login_bg&Login_bg")
-        return v
-    }()
-    
-    override func viewWillDisappear(_ animated: Bool) {
-        super.viewWillDisappear(animated)
-    }
-    
-    override func viewWillAppear(_ animated: Bool) {
-        super.viewWillAppear(animated)
-    }
-    
-    override func viewDidLoad() {
-        super.viewDidLoad()
-        self.myNavigationBar.left_SuperView.isHidden = false
-        self.myNavigationBar.left_Button.setImage(NavViewBlackImage, for: .normal)
-    }
-    
-    override func subView() {
-        self.view.addSubview(self.bgIv)
-        self.view.addSubview(self.forgotPasswordView)
-    }
-    
-    override func updateViewConstraints() {
-        super.updateViewConstraints()
-        
-        self.bgIv.snp.makeConstraints { make in
-            make.top.right.left.equalTo(self.view)
-            make.height.equalTo(406)
-        }
-        
-        self.forgotPasswordView.snp.makeConstraints { make in
-            make.left.right.bottom.equalToSuperview()
-            make.top.equalTo(TopHeight)
-        }
-    }
-    
-    override func mySwitchLanguage() {
-        self.forgotPasswordView.mySwitchLanguage()
-    }
-    
-    override func mySwitchSkin() {
-        self.myNavigationBar.setMyStyle()
-        self.view.backgroundColor = ALLBackGroundColor
-        self.forgotPasswordView.mySwitchSkin()
-    }
-    
-    override func blindModel() {
-        self.viewModel.newPasswordAction.values.observeValues { [weak self] resilt in
-            if resilt {
-                self?.navigationController?.popViewController(animated: true)
-            }
-        }
-    }
-}
-
-extension ForgotPasswordViewController {
-    @objc func clickRightBtnAction() {
-        self.navigationController?.popViewController(animated: true)
-    }
-}

+ 0 - 82
Koala/Koala/Modular/Login/VC/LoginViewController.swift

@@ -1,82 +0,0 @@
-//
-//  LoginViewController.swift
-//  Koala
-//
-//  Created by 刘千军 on 2022/12/24.
-//  Copyright © 2022 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class LoginViewController: BaseViewController {
-    var viewModel = LoginViewModel()
-    lazy var loginView: JDLoginView = {
-        let view = JDLoginView(type: .ViewModel(ViewModel: self.viewModel))
-        view.backgroundColor = .clear
-        return view
-    }()
- 
-    lazy var bgIv: UIImageView = {
-        let v = UIImageView()
-        v.image = _image("Login_bg&Login_bg")
-        return v
-    }()
-    
-    override func viewWillDisappear(_ animated: Bool) {
-        super.viewWillDisappear(animated)
-    }
-    
-    override func viewWillAppear(_ animated: Bool) {
-        super.viewWillAppear(animated)
-    }
-    
-    override func viewDidLoad() {
-        super.viewDidLoad()
-        self.myNavigationBar.left_SuperView.isHidden = false
-        self.myNavigationBar.left_Button.setImage(NavViewSpecialBlackImage, for: .normal)
-     
-        self.myNavigationBar.right_SuperView.isHidden = false
-    }
-    
-    override func subView() {
-        self.view.addSubview(self.bgIv)
-        self.view.addSubview(self.loginView)
-    }
-    
-    override func updateViewConstraints() {
-        super.updateViewConstraints()
-        
-        self.bgIv.snp.makeConstraints { make in
-            make.top.right.left.equalTo(self.view)
-            make.height.equalTo(406)
-        }
-        self.loginView.snp.makeConstraints { make in
-            make.left.right.bottom.equalToSuperview()
-            make.top.equalTo(TopHeight)
-        }
-    }
-    
-    override func mySwitchLanguage() {
-        self.loginView.mySwitchLanguage()
-    }
-    
-    override func mySwitchSkin() {
-        self.myNavigationBar.setMyStyle()
-        self.view.backgroundColor = ALLBackGroundColor
-        self.loginView.mySwitchSkin()
-    }
-    
-    override func blindModel() {
-        self.viewModel.loginAction.values.observeValues { [weak self] resilt in
-            if resilt {
-                self?.navigationController?.popToRootViewController(animated: true)
-            }
-        }
-    }
-}
-
-extension LoginViewController {
-    @objc func clickRightBtnAction() {
-        self.navigationController?.pushViewController(RegisterViewController(), animated: true)
-    }
-}

+ 0 - 83
Koala/Koala/Modular/Login/VC/RegisterViewController.swift

@@ -1,83 +0,0 @@
-//
-//  RegisterViewController.swift
-//  Koala
-//
-//  Created by 刘千军 on 2022/12/25.
-//  Copyright © 2022 刘千军. All rights reserved.
-//
-
-import UIKit
-
-class RegisterViewController: BaseViewController {
-    var viewModel = RegisterViewModel()
-    lazy var registerView: JDRegisterView = {
-        let view = JDRegisterView(type: .ViewModel(ViewModel: self.viewModel))
-        return view
-    }()
-    
-    lazy var bgIv: UIImageView = {
-        let v = UIImageView()
-        v.image = _image("Login_bg&Login_bg")
-        return v
-    }()
-    
-    override func viewWillDisappear(_ animated: Bool) {
-        super.viewWillDisappear(animated)
-    }
-    
-    override func viewWillAppear(_ animated: Bool) {
-        super.viewWillAppear(animated)
-    }
-    
-    override func viewDidLoad() {
-        super.viewDidLoad()
-        self.myNavigationBar.left_SuperView.isHidden = false
-        self.myNavigationBar.left_Button.setImage(NavViewBlackImage, for: .normal)
-        
-        OperationalUserInfoData.removeUserInfoData()
-    }
-    
-    override func subView() {
-        self.view.addSubview(self.bgIv)
-        
-        self.view.addSubview(self.registerView)
-    }
-    
-    override func updateViewConstraints() {
-        super.updateViewConstraints()
-        
-        self.bgIv.snp.makeConstraints { make in
-            make.top.right.left.equalTo(self.view)
-            make.height.equalTo(406)
-        }
-        
-        self.registerView.snp.makeConstraints { make in
-            make.left.right.bottom.equalToSuperview()
-            make.top.equalTo(TopHeight)
-        }
-    }
-    
-    override func mySwitchLanguage() {
-        self.registerView.mySwitchLanguage()
-    }
-    
-    override func mySwitchSkin() {
-        self.myNavigationBar.setMyStyle()
-        self.view.backgroundColor = ALLBackGroundColor
-        self.registerView.mySwitchSkin()
-    }
-    
-    override func blindModel() {
-        self.viewModel.registerAction.values.observeValues { [weak self] resilt in
-            if resilt {
-                self?.navigationController?.popToRootViewController(animated: true)
-            }
-        }
-    }
-}
-
-extension RegisterViewController {
-    @objc func clickRightBtnAction() {
-        self.navigationController?.popViewController(animated: true)
-    }
-}