2 Комити 25569887d3 ... 38de73d7f8

Аутор SHA1 Порука Датум
  tangchao 38de73d7f8 Merge branch 'develop_PDFReaderProNew' of git.kdan.cc:Mac_PDF/PDF_Office into develop_PDFReaderProNew пре 1 недеља
  tangchao 63ea1d3e96 【综合】7天领取流程调整 пре 1 недеља
1 измењених фајлова са 15 додато и 9 уклоњено
  1. 15 9
      PDF Office/PDF Master/MemberCenter/View/KMSignUpView.swift

+ 15 - 9
PDF Office/PDF Master/MemberCenter/View/KMSignUpView.swift

@@ -504,16 +504,22 @@ class KMSignUpView: KMBaseXibView {
             self?.window?.hideWaitingView()
             
 #if VERSION_DMG
-            if result == true {
-                if KMDataManager.ud_bool(forKey: KMAdvancedAnnualTrailKey) {
-                    DispatchQueue.main.async {
-                        let winC = KMPurchaseEmbeddedWindowController.currentCode(KMAdvancedAnnualSubscriptionTrailCodeKey_DMG)
-                        winC.showWindow(nil)
-                        winC.window?.center()
-                    }
-                    
-                    KMDataManager.ud_set(false, forKey: KMAdvancedAnnualTrailKey)
+            if result == nil || result == false {
+                return
+            }
+            if KMDataManager.ud_bool(forKey: KMAdvancedAnnualTrailKey) == false {
+                return
+            }
+            
+            let info = KMMemberInfo.shared
+            if info.vip_levels == "1" || info.canTrail { // 用户注册成功 或 登录免费账户
+                DispatchQueue.main.async {
+                    let winC = KMPurchaseEmbeddedWindowController.currentCode(KMAdvancedAnnualSubscriptionTrailCodeKey_DMG)
+                    winC.showWindow(nil)
+                    winC.window?.center()
                 }
+                    
+                KMDataManager.ud_set(false, forKey: KMAdvancedAnnualTrailKey)
             }
 #endif
         }