Procházet zdrojové kódy

【会员系统】更新AI产品为新产品

wanjun před 1 týdnem
rodič
revize
23d5eeb15b

+ 8 - 9
PDF Office/PDF Master/Class/AIInfo/AIPurchaseWindowController/AIPurchaseWindowController.swift

@@ -129,7 +129,6 @@ class AIPurchaseWindowController: NSWindowController, NSWindowDelegate {
         NotificationCenter.default.addObserver(self, selector: #selector(IAPProductRestoreFinishedNotification), name: NSNotification.Name(rawValue: NSNotification.Name.KMIAPProductRestoreFinished.rawValue), object: nil)
         NotificationCenter.default.addObserver(self, selector: #selector(IAPProductRestoreFailedNotification), name: NSNotification.Name(rawValue: NSNotification.Name.KMIAPProductRestoreFailed.rawValue), object: nil)
         NotificationCenter.default.addObserver(self, selector: #selector(AIDeviceStatusChangeNotification), name: NSNotification.Name(rawValue: "kDeviceAIStatusChangeNotification"), object: nil)
-        
     }
     
     func refreshUI() -> Void {
@@ -143,9 +142,9 @@ class AIPurchaseWindowController: NSWindowController, NSWindowDelegate {
     func reloadData() -> Void {
         self.purchaseButton.isEnabled = true
 #if VERSION_FREE
-        let priceLabel = IAPProductsManager.default().liteAIProduct.price()
+        let priceLabel = IAPProductsManager.default().aiAllAccessPack1month_lite.price()
 #else
-        let priceLabel = IAPProductsManager.default().proAIProduct.price()
+        let priceLabel = IAPProductsManager.default().aiAllAccessPack1month_pro.price()
 #endif
         
         let aiInfoValid = KMMemberInfo.shared.isPermitAI
@@ -162,9 +161,9 @@ class AIPurchaseWindowController: NSWindowController, NSWindowDelegate {
     func appStoreRestoreFinish() -> Void {
         var didPurchased: Bool = false
 #if VERSION_FREE
-        didPurchased = IAPProductsManager.default().liteAIProduct.isSubscribed
+        didPurchased = IAPProductsManager.default().aiAllAccessPack1month_lite.isSubscribed
 #else
-        didPurchased = IAPProductsManager.default().proAIProduct.isSubscribed
+        didPurchased = IAPProductsManager.default().aiAllAccessPack1month_pro.isSubscribed
 #endif
         if didPurchased {
             AIInfoManager.default().restoreAI(withInfo: ["receipt_str":IAPProductsManager.default().temptransactioReceipt as Any]) { dict, error in
@@ -201,9 +200,9 @@ class AIPurchaseWindowController: NSWindowController, NSWindowDelegate {
     //MARK: - IBAction
     @IBAction func purchaseAction(_ sender: KMButton) {
 #if VERSION_FREE
-        IAPProductsManager.default().make(IAPProductsManager.default().liteAIProduct)
+        IAPProductsManager.default().make(IAPProductsManager.default().aiAllAccessPack1month_lite)
 #else
-        IAPProductsManager.default().make(IAPProductsManager.default().proAIProduct)
+        IAPProductsManager.default().make(IAPProductsManager.default().aiAllAccessPack1month_pro)
 #endif
         self.addWaingView((self.window?.contentView)!)
         FMTrackEventManager.defaultManager.trackOnceEvent(event: "PUW", withProperties: ["PUW_Btn":"PUW_Btn_BuyAITools"])
@@ -254,7 +253,7 @@ class AIPurchaseWindowController: NSWindowController, NSWindowDelegate {
             
             //Appstore购买结束后绑定票据信息
 #if VERSION_FREE
-            if IAPProductsManager.default().liteAIProduct.isSubscribed {
+            if IAPProductsManager.default().aiAllAccessPack1month_lite.isSubscribed {
                 AIInfoManager.default().activateAI(withInfo: ["receipt_str":IAPProductsManager.default().temptransactioReceipt as Any]) { dict, error in
                     self.reloadData()
                     if KMMemberInfo.shared.isPermitAI {
@@ -263,7 +262,7 @@ class AIPurchaseWindowController: NSWindowController, NSWindowDelegate {
                 }
             }
 #else
-            if IAPProductsManager.default().proAIProduct.isSubscribed {
+            if IAPProductsManager.default().aiAllAccessPack1month_pro.isSubscribed {
                 AIInfoManager.default().activateAI(withInfo: ["receipt_str":IAPProductsManager.default().temptransactioReceipt as Any]) { dict, error in
                     self.reloadData()
                     if KMMemberInfo.shared.isPermitAI {

+ 1 - 1
PDF Office/PDF Master/Class/AIInfo/AIPurchaseWindowController/AIPurchaseWindowController.xib

@@ -28,7 +28,7 @@
         <window title="Window" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" releasedWhenClosed="NO" animationBehavior="default" titlebarAppearsTransparent="YES" titleVisibility="hidden" id="F0z-JX-Cv5">
             <windowStyleMask key="styleMask" titled="YES" closable="YES" miniaturizable="YES" resizable="YES" fullSizeContentView="YES"/>
             <rect key="contentRect" x="196" y="240" width="490" height="530"/>
-            <rect key="screenRect" x="0.0" y="0.0" width="1800" height="1125"/>
+            <rect key="screenRect" x="0.0" y="0.0" width="2560" height="1415"/>
             <view key="contentView" id="se5-gp-TjO">
                 <rect key="frame" x="0.0" y="0.0" width="490" height="530"/>
                 <autoresizingMask key="autoresizingMask"/>

+ 2 - 2
PDF Office/PDF Master/Class/Purchase/DMG/Verification/VerificationManager/AIInfoManager.m

@@ -294,11 +294,11 @@ static AIInfoManager *__Manager = nil;
                 //当前票据未激活设备(针对AppStore版购买过但未激活的情况)
                 BOOL didPurchase = NO;
 #if VERSION_FREE
-                if ([IAPProductsManager defaultManager].liteAIProduct.isSubscribed) {
+                if ([IAPProductsManager defaultManager].aiAllAccessPack1month_lite.isSubscribed) {
                     didPurchase = YES;
                 }
 #else
-                if ([IAPProductsManager defaultManager].proAIProduct.isSubscribed) {
+                if ([IAPProductsManager defaultManager].aiAllAccessPack1month_pro.isSubscribed) {
                     didPurchase = YES;
                 }
 #endif