소스 검색

pro-1.0.2-12

jeremy 5 년 전
부모
커밋
ed1344bf6e

+ 9 - 2
RainbowPlanet/RainbowPlanet/Base/BaseTabbarViewController/BaseTabbarViewController.swift

@@ -46,8 +46,15 @@ class BaseTabbarViewController: NSObject {
     func tabBarViewController() -> ESTabBarController {
         esTabBarController = ESTabBarController()
         
-        esTabBarController.tabBar.backgroundImage = UIImage.imageWithColor(color: UIColor.white)
-        esTabBarController.tabBar.shadowImage = UIImage(named: "navbar_shadow_pic_down")
+        if #available(iOS 13.0, *) {
+            esTabBarController.tabBar.standardAppearance.configureWithOpaqueBackground()
+            esTabBarController.tabBar.standardAppearance.backgroundImage = UIImage.imageWithColor(color: UIColor.white)
+            esTabBarController.tabBar.standardAppearance.shadowImage = UIImage(named: "navbar_shadow_pic_down")
+            esTabBarController.tabBar.standardAppearance.shadowColor = UIColor.yellow
+        } else {
+            esTabBarController.tabBar.shadowImage = UIImage(named: "navbar_shadow_pic_down")
+        }
+        
         esTabBarController.shouldHijackHandler = {
            [weak self] (tabbarController, viewController, index) in
             AudioServicesPlaySystemSound(1519)

+ 1 - 1
RainbowPlanet/RainbowPlanet/Base/BaseWebViewController/BaseJSWebViewController.swift

@@ -64,7 +64,7 @@ class BaseJSWebViewController: BaseViewController {
     
     lazy var wkWebView: WKWebView = {
         /// 创建webveiew
-        let wkWebView = WKWebView(frame: CGRect(x: 0, y: 0, width: kScreenWidth, height: kScreenHeight-48-kNavBarTotalHeight-kTabBarTotalHeight))
+        let wkWebView = WKWebView(frame: CGRect(x: 0, y: 0, width: kScreenWidth, height: kScreenHeight-44-kNavBarTotalHeight-kTabBarTotalHeight))
         // 监听支持KVO的属性
         wkWebView.addObserver(self, forKeyPath: "estimatedProgress", options: .new, context: nil)
         return wkWebView

+ 3 - 3
RainbowPlanet/RainbowPlanet/Modules/CommunityModule/Community/ViewController/Follow/CommunityFollowViewController.swift

@@ -47,7 +47,7 @@ class CommunityFollowViewController: BaseViewController {
     override func setupLayouts() {
         tableView.snp.makeConstraints { (make) in
             make.top.left.right.equalToSuperview()
-            make.height.equalTo(kScreenHeight-48-kNavBarTotalHeight-kTabBarTotalHeight)
+            make.height.equalTo(kScreenHeight-44-kNavBarTotalHeight-kTabBarTotalHeight)
         }
     }
     
@@ -749,7 +749,7 @@ extension CommunityFollowViewController {
                 NotificationCenter.default.post(name: NSNotification.Name("CommunityViewControllerScrollView"), object: true)
 
                 tableView.snp.updateConstraints { (make) in
-                    make.height.equalTo(kScreenHeight-48-kSafeStatusBarHeight-kTabBarTotalHeight)
+                    make.height.equalTo(kScreenHeight-44-kSafeStatusBarHeight-kTabBarTotalHeight)
                 }
                 self.view.layoutIfNeeded()
                 self.navigationBarIsHidden = true
@@ -760,7 +760,7 @@ extension CommunityFollowViewController {
             if communityNavigationBarIsHidden && communityIndex != 2 {
                 NotificationCenter.default.post(name: NSNotification.Name("CommunityViewControllerScrollView"), object: false)
                 tableView.snp.updateConstraints { (make) in
-                    make.height.equalTo(kScreenHeight-48-kNavBarTotalHeight-kTabBarTotalHeight)
+                    make.height.equalTo(kScreenHeight-44-kNavBarTotalHeight-kTabBarTotalHeight)
                 }
                 self.view.layoutIfNeeded()
                 communityNavigationBarIsHidden = false

+ 3 - 3
RainbowPlanet/RainbowPlanet/Modules/CommunityModule/Community/ViewController/Recommend/CommunityRecommnendViewController.swift

@@ -49,7 +49,7 @@ class CommunityRecommnendViewController: UIViewController {
     func setupLayouts() {
         tableView.snp.makeConstraints { (make) in
             make.top.left.right.equalToSuperview()
-            make.height.equalTo(kScreenHeight-48-kNavBarTotalHeight-kTabBarTotalHeight-48)
+            make.height.equalTo(kScreenHeight-44-kNavBarTotalHeight-kTabBarTotalHeight-40)
         }
         tableView.reloadData()
     }
@@ -644,7 +644,7 @@ extension CommunityRecommnendViewController {
             if communityNavigationBarIsHidden == false && communityIndex != 2 {
                 NotificationCenter.default.post(name: NSNotification.Name("CommunityViewControllerScrollView"), object: true)
                 tableView.snp.updateConstraints { (make) in
-                    make.height.equalTo(kScreenHeight-44-kSafeStatusBarHeight-kTabBarTotalHeight-44)
+                    make.height.equalTo(kScreenHeight-44-kSafeStatusBarHeight-kTabBarTotalHeight-40)
                 }
                 communityNavigationBarIsHidden = true
 
@@ -655,7 +655,7 @@ extension CommunityRecommnendViewController {
             if communityNavigationBarIsHidden && communityIndex != 2 {
                 NotificationCenter.default.post(name: NSNotification.Name("CommunityViewControllerScrollView"), object: false)
                 tableView.snp.updateConstraints { (make) in
-                    make.height.equalTo(kScreenHeight-44-kNavBarTotalHeight-kTabBarTotalHeight-44)
+                    make.height.equalTo(kScreenHeight-44-kNavBarTotalHeight-kTabBarTotalHeight-40)
                 }
                 communityNavigationBarIsHidden = false
             }

+ 2 - 2
RainbowPlanet/RainbowPlanet/Modules/RegisterLoginModule/BindPhoneNumber/ViewController/BindPhoneNumberViewController.swift

@@ -65,12 +65,12 @@ class BindPhoneNumberViewController: BaseViewController {
             switch self?.bindPhoneNumberVCType {
             case .weixinlogin?:
                 SwiftMoyaNetWorkServiceUser.shared().userBindMobileApi(mobile: phoneNumber, smsCode: sms, unionId: self?.userModel?.bindWeixinUserModel?.unionId ?? "", openId: self?.userModel?.bindWeixinUserModel?.openId ?? "", invitationCode: invitationCode, completion: { [weak self] (data) -> (Void) in
-                    RegisterLoginManager.registerLoginSuccessApi(vc: self!)
+                    RegisterLoginManager.registerLoginSuccessApi(vc: self)
                 })
                 break
             case .qqLogin?:
                 SwiftMoyaNetWorkServiceUser.shared().userBindMobileApi(mobile: phoneNumber, smsCode: sms, unionId: self?.userModel?.bindQQUserModel?.unionId ?? "", openId: self?.userModel?.bindQQUserModel?.openId ?? "", invitationCode: invitationCode, completion: { [weak self] (data) -> (Void) in
-                    RegisterLoginManager.registerLoginSuccessApi(vc: self!)
+                    RegisterLoginManager.registerLoginSuccessApi(vc: self)
                 })
                 break
             case .accountSecurityBindMobile?:

+ 2 - 2
RainbowPlanet/RainbowPlanet/Service/SwiftMoyaService/SwiftMoyaServiceApi/SwiftMoyaServiceUser/SwiftMoyaNetWorkServiceUser.swift

@@ -44,7 +44,6 @@ public class SwiftMoyaNetWorkServiceUser: NSObject {
         
         SwiftMoyaNetWorkManager.shared.requestObject(UserModel.self,target: MultiTarget(SwiftMoyaServiceUserApi.userWeiXinRegister(parameters: parameters)), completion: { (userModel) in
             UserModel.shared().setModel(model: userModel as! UserModel)
-            VirusViewModel.registeredVirueRecordAddApi(completion: {})
             let userModel = userModel as! UserModel
             
             completion(userModel as Any)
@@ -158,7 +157,8 @@ public class SwiftMoyaNetWorkServiceUser: NSObject {
             
             SwiftMoyaNetWorkManager.shared.requestObject(UserModel.self,target: MultiTarget(SwiftMoyaServiceUserApi.userBindMobile(parameters: parameters)), completion: { (userModel) in
                 UserModel.shared().setModel(model: userModel as! UserModel)
-                
+                VirusViewModel.registeredVirueRecordAddApi(completion: {})
+
                 completion("")
             }) {
                 (loadingStatus) in