Kaynağa Gözat

【综合】领取AI流程调整

tangchao 2 gün önce
ebeveyn
işleme
b5921d6913

+ 18 - 42
PDF Office/PDF Master/Class/Purchase/DMG/Verification/KMVerificationMessageViewController.m

@@ -598,48 +598,24 @@ NSPopoverDelegate>
 }
 
 - (IBAction)AIButtonAction:(NSButton *)sender {
-    __block typeof(self) blockSelf = self;
-//    [[FMTrackEventManager defaultManager] trackEventWithEvent:@"Tbr" withProperties:@{@"Tbr_Btn":@"Btn_Tbr_AICredit"}];
-//    [[AIInfoManager defaultManager] fetchAIInfoWithComplention:^(NSDictionary *info, NSError *error) {
-//            
-//    }];
-//    AIUserInfoController *controller = [[AIUserInfoController alloc] init];
-//    controller.purchaseHandle = ^(AIUserInfoController * _Nonnull vc) {
-//#if VERSION_DMG
-//        KMPurchaseEmbeddedWindowController *embeddedWC = [KMPurchaseEmbeddedWindowController currentFirstTrialWC:@"com.brother.pdfreaderpro.ai.product_1"];
-//        [embeddedWC showWindow:nil];
-//        [[embeddedWC window] center];
-//#else
-//        
-//        [[AIPurchaseWindowController currentWC] showWindow:nil];
-//#endif
-//        [[FMTrackEventManager defaultManager] trackEventWithEvent:@"Tbr" withProperties:@{@"Tbr_Btn":@"Btn_Tbr_AICredit_BuyNow"}];
-//    };
-//    controller.enterLicenseHandle = ^(AIUserInfoController * _Nonnull vc) {
-//        KMVerificationWindowController *verifyVC = [KMVerificationWindowController verificationWithType:KMVerificationTypeActivateAIInfo];
-//        verifyVC.callback = ^{
-//
-//        };
-//        [verifyVC showWindow:nil];
-//    };
-//    
-//    controller.guideHandle = ^(AIUserInfoController * _Nonnull vc) {
-//        if (!blockSelf.guideWindowVC) {
-//            KMFunctionGuideWindowController *guideWindowVC = [[KMFunctionGuideWindowController alloc] initWithWindowNibName:@"KMFunctionGuideWindowController"];
-//            blockSelf.guideWindowVC = guideWindowVC;
-//        }
-//        ((KMFunctionGuideWindowController *)(blockSelf.guideWindowVC)).type = KMGuideInfoTypeFunctionMulti;
-//        [blockSelf.guideWindowVC showWindow:nil];
-//        [KMFunctionGuideWindowController setDidShowFor:KMGuideInfoTypeFunctionMultiAIGuide];
-//        [blockSelf.guideWindowVC.window orderFront:nil];
-//    };
-//    
-//    NSPopover *popover = [[NSPopover alloc] init];
-//    popover.contentViewController = controller;
-//    popover.animates = YES;
-//    popover.behavior = NSPopoverBehaviorTransient;
-//    [popover showRelativeToRect:[sender bounds] ofView:sender preferredEdge:NSMinYEdge];
-    [[KMFreeGetAIWC shared] showWindow:nil];
+#if VERSION_FREE
+#if VERSION_DMG
+    KMPurchaseEmbeddedWindowController *winC = [KMPurchaseEmbeddedWindowController currentCode:KMAISubscriptionYearTrailCodeKey_DMG];
+    [winC showWindow:nil];
+    [winC.window center];
+#else
+//            self.window?.showWaitingView()
+    // AppStore 免费版本
+    IAPProductsManager *man = [IAPProductsManager defaultManager];
+    [man makeSubProduct:man.aiAllAccessPack12month_lite discount:man.isCancelAutoRenew];
+    
+#endif
+#else
+    // AppStore 付费版
+//            self.window?.showWaitingView()
+    IAPProductsManager *man = [IAPProductsManager defaultManager];
+    [man makeSubProduct:man.aiAllAccessPack12month_pro discount:man.isCancelAutoRenew];
+#endif
 }
 
 - (IBAction)userButtonAction:(NSButton *)sender {

+ 1 - 1
PDF Office/PDF Master/Class/Purchase/DMG/Window/KMPurchaseSuccessWindowController.swift

@@ -29,7 +29,7 @@ class KMPurchaseSuccessWindowController: KMBaseWindowController {
         super.windowDidLoad()
         
         iconIv.image = NSImage(named: "KMImageNamePurchaseSuccessIcon")
-        titleLabel.stringValue = NSLocalizedString("Purchased Successfully!", tableName: "MemberCenterLocalizable", comment: "")
+        titleLabel.stringValue = NSLocalizedString("Purchase Succeesfully", tableName: "MemberCenterLocalizable", comment: "")
         titleLabel.font = .SFProTextRegularFont(20)
         
         

+ 1 - 1
PDF Office/PDF Master/MemberCenter/Assets/zh-Hant.lproj/MemberCenterLocalizable.strings

@@ -97,7 +97,7 @@
 "Unbind" = "解绑";
 
 "PDF Reader Pro Standard - Annual Plan" = "PDF Reader Pro 標準版 - 年訂閱";
-"PDF Reader Pro Advanced - Annual Plan" = "PDF Reader Pro 進階版 - 年訂閱";
+"PDF Reader Pro Advanced - Annual Plan" = "PDF Reader Pro 高級版 - 年訂閱";
 "PDF Reader Pro Al - Annual Plan" = "PDF Reader Pro Al - 年訂閱";
 "PDF Reader Pro Al - Monthly Plan" = "PDF Reader Pro Al - 月訂閱";
 "PDF Reader Pro Permanent" = "PDF Reader Pro 永久版";

+ 4 - 4
PDF Office/PDF Master/MemberCenter/ViewModel/KMUserInfoVCModel.swift

@@ -159,7 +159,7 @@ class KMUserInfoVCModel: ObservableObject {
     func signOutAction() -> Void {
         NotificationCenter.default.post(name: NSNotification.Name("CloseMenuNotification"), object: nil)
         
-        DispatchQueue.main.async {
+        DispatchQueue.main.asyncAfter(deadline: .now()+0.3) {
             KMMemberPromptWC.shared.showWindow(nil)
             KMMemberPromptWC.shared.window?.makeKeyAndOrderFront(nil)
             KMMemberPromptWC.shared.tipType = .logout
@@ -187,7 +187,7 @@ class KMUserInfoVCModel: ObservableObject {
                 let msg = resultDict.msg
                 if success {
                     self.refreshUserInfo { success, msg,resdic  in
-                        DispatchQueue.main.async {
+                        DispatchQueue.main.asyncAfter(deadline: .now()+0.3) {
                             KMMemberPromptWC.shared.showWindow(nil)
                             KMMemberPromptWC.shared.window?.makeKeyAndOrderFront(nil)
                             KMMemberPromptWC.shared.tipType = .cancelSignout
@@ -203,7 +203,7 @@ class KMUserInfoVCModel: ObservableObject {
                 (KMMemberInfo.shared.ai_payType == 1) {
                 // 在续订中用户提示退订
                 NotificationCenter.default.post(name: NSNotification.Name("CloseMenuNotification"), object: nil)
-                DispatchQueue.main.async {
+                DispatchQueue.main.asyncAfter(deadline: .now()+0.3) {
                     KMMemberPromptWC.shared.showWindow(nil)
                     KMMemberPromptWC.shared.window?.makeKeyAndOrderFront(nil)
                     KMMemberPromptWC.shared.tipType = .unsubscribe
@@ -211,7 +211,7 @@ class KMUserInfoVCModel: ObservableObject {
             } else {
                 // 手动注销
                 NotificationCenter.default.post(name: NSNotification.Name("CloseMenuNotification"), object: nil)
-                DispatchQueue.main.async {
+                DispatchQueue.main.asyncAfter(deadline: .now()+0.3) {
                     KMMemberPromptWC.shared.showWindow(nil)
                     KMMemberPromptWC.shared.window?.makeKeyAndOrderFront(nil)
                     KMMemberPromptWC.shared.tipType = .signout

+ 1 - 1
PDF Office/PDF Master/MemberCenter/WindowsController/KMFreeGetAIWC.swift

@@ -52,7 +52,7 @@ class KMFreeGetAIWC: NSWindowController {
         var productPrice = ""
 #if VERSION_FREE
 #if VERSION_DMG
-        productPrice = KMProductModel.shared.getProductPrice(.pdfReaderProStandard_dmg)
+        productPrice = KMProductModel.shared.getProductPrice(.pdfReaderProAIAnnual_dmg)
 #else
         productPrice = IAPProductsManager.default().aiAllAccessPack12month_lite.price()
 #endif

+ 8 - 8
PDF Office/PDF Master/Strings/zh-Hant.lproj/Localizable.strings

@@ -1551,14 +1551,14 @@
 "Convert JPEG or PNG files to PDFs" = "JPEG或PNG檔轉PDF格式";
 "Import images from connected scanners or iOS devices" = "可直接從已連線的掃描機或iOS裝置中匯入圖片並轉成PDF文件";
 "Convert PDFs to Word, HTML, TXT, JPEG or PNG files" = "PDF檔轉Word、HTML、TXT、JPEG、PNG格式";
-"Advanced Editing Tools" = "進階編輯工具";
+"Advanced Editing Tools" = "高級編輯工具";
 "Add & edit watermark" = "新增與編輯浮水印";
 "PDF page editor" = "PDF頁面編輯";
 "Merge multiple files in one PDF document" = "合併多個檔案為單一PDF";
 "Split and save selected PDF pages as a new separate document" = "分割特定頁面為獨立PDF";
 "Customize PDF stamps" = "客製PDF圖章";
 "Subscription Based Solution" = "訂閱服務體驗";
-"Access all premium features in app" = "體驗訂閱套餐解決方案中的所有進階服務";
+"Access all premium features in app" = "體驗訂閱套餐解決方案中的所有高級服務";
 "File converter - pdf, docx, xlsx, pptx, epub, html, txt, and more" = "支援轉檔格式:pdf, docx, xlsx, pptx, epub, html, txt等";
 "Send faxes directly from your Mac or mobile devices." = "直接從Mac和行動裝置發送文件傳真";
 "Priority customer support" = "優先客服支援";
@@ -1611,8 +1611,8 @@
 "I bought the in-app purchase, but the app doesn't recognize that automatically. How to recover my purchase?" = "我有進行內購升級,但App並未即時自動判斷,我該如何處理?";
 "—》If you already completed the payment, simply click the \"Restore Previous Purchase\" button directly from the upgrade page to enable all the advanced features at no cost to you." = "—》若您已經完成付款,只要在升級頁面中點擊“恢復先前購買內容”即可,毋需再額外花費。";
 "—》Due to Apple needs to confirm your purchase info, you may be required to sign in with your Apple ID. When you restore your purchase, make sure you use the same Apple ID that you previously used." = "—》由於Apple會需要確認您的購買資訊,您必須登入您原先購買內容的Apple ID。";
-"—》Once you see the \"Restore Successfully\" message, you will be able to access the advanced features, including PDF to Office, PDF Watermark, Page Editor, and more." = "—》若看到\"恢復成功\"訊息,你便能使用所有進階功能 (如PDF转换Office, 浮水印,頁面編輯等 )。";
-"—》Once you see the \"Restore Successfully\" message, you will be able to access the advanced features, including PDF to Office, and more." = "—》若看到\"恢復成功\"訊息,你便能使用所有進階功能 (如PDF转换Office)。";
+"—》Once you see the \"Restore Successfully\" message, you will be able to access the advanced features, including PDF to Office, PDF Watermark, Page Editor, and more." = "—》若看到\"恢復成功\"訊息,你便能使用所有高級功能 (如PDF转换Office, 浮水印,頁面編輯等 )。";
+"—》Once you see the \"Restore Successfully\" message, you will be able to access the advanced features, including PDF to Office, and more." = "—》若看到\"恢復成功\"訊息,你便能使用所有高級功能 (如PDF转换Office)。";
 "—》Once you see the \"Restore Successfully\" message, you will be able to access the AI tools include AI translate, AI summarize, AI proofread and AI rewrite." = "—》當出現“恢復購買成功”提示後,代表您可以使用所有AI功能,包括AI翻譯,AI重寫,AI概述,AI校對。";
 
 "next" = "下一頁";
@@ -1689,7 +1689,7 @@
 "Click Here to Import Images" = "點擊此處匯入圖片";
 "New From Clipboard" = "使用剪貼板的內容新增檔案";
 
-"Advanced" = "進階";
+"Advanced" = "高級";
 "Hyperlink" = "超連結";
 "Page Number, URL, Email" = "頁碼, URL, Email";
 "6 months" = "6个月";
@@ -2645,7 +2645,7 @@
 "Customize theme colors: Light Mode, Dark Mode, Sepia Mode and more" = "日間模式,夜間模式,護眼模式等更多主題模式";
 "Split View to compare files" = "分屏視圖同時打開對比多個文檔";
 "Subscription Based Solution" = "訂閱服務體驗";
-"Access all premium features in app" = "體驗訂閱套餐解決方案中的所有進階服務";
+"Access all premium features in app" = "體驗訂閱套餐解決方案中的所有高級服務";
 "Priority customer support" = "優先客服支援";
 "Ad-free" = "移除廣告";
 
@@ -3064,8 +3064,8 @@
 "Unlimited Convert"="無限制轉檔";
 "Purchase failed. Please check your settings and try again." = "購買失敗,  請帮忙檢查一下您的伺服器設定及稍後再試。";
 "Failed to restore previous purchases. Please make sure you've made a valid purchase or try again later." = "恢復購買失敗,請確認您的購買有效或稍後再試。";
-"Purchase completed. You can start using the advanced tools, including PDF to Office, PDF Watermark, Page Editor, and more." = "購買已完成。您可以開始使用包括PDF to Office、PDF浮水印、頁面編輯器等進階工具。";
-"Purchase completed. You can start using the advanced tools, including PDF to Office, and more." = "購買已完成。您可以開始使用包括 PDF to Office 等進階工具。";
+"Purchase completed. You can start using the advanced tools, including PDF to Office, PDF Watermark, Page Editor, and more." = "購買已完成。您可以開始使用包括PDF to Office、PDF浮水印、頁面編輯器等高級工具。";
+"Purchase completed. You can start using the advanced tools, including PDF to Office, and more." = "購買已完成。您可以開始使用包括 PDF to Office 等高級工具。";
 
 "PDF Reader Pro offers a 7-day free trial of the full functions." = "點擊申請,一鍵獲取PDF Reader Pro全功能7天免費試用權益!";
 "Enter your email to get free trial:" = "輸入郵箱申請試用:";