From 50d1cd9069a04088ba351bc95e31663f1bc1c986 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BE=9C=E5=A3=B0=E4=B8=96=E7=BA=AA?= <> Date: Mon, 8 Dec 2025 16:04:26 +0800 Subject: [PATCH] =?UTF-8?q?1.ui=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SynthReel.xcodeproj/project.pbxproj | 8 +++-- .../VC/SRDetailPlayerViewController.swift | 2 +- .../Player/VM/SRShortPlayerViewModel.swift | 5 +++- .../Store/Views/SRSmallCoinViewCell.swift | 8 +++-- SynthReel/Libs/SRAppstore/SRIapManager.swift | 6 ++-- .../Libs/SRAppstore/SRPayDataRequest.swift | 1 + SynthReel/Source/GoogleService-Info.plist | 30 +++++++++++++++++++ SynthReel/Source/Info.plist | 6 ++-- SynthReel/Source/en.lproj/Localizable.strings | 8 +++++ 9 files changed, 62 insertions(+), 12 deletions(-) create mode 100644 SynthReel/Source/GoogleService-Info.plist diff --git a/SynthReel.xcodeproj/project.pbxproj b/SynthReel.xcodeproj/project.pbxproj index d3be653..99b0fc8 100644 --- a/SynthReel.xcodeproj/project.pbxproj +++ b/SynthReel.xcodeproj/project.pbxproj @@ -194,6 +194,7 @@ 3754B0312EE2C9D4009EBCAD /* SRVideoRechargeView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3754B0302EE2C9D4009EBCAD /* SRVideoRechargeView.swift */; }; 3779D0612ECF1CB8006B1698 /* SRShortHeaderView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3779D0602ECF1CB8006B1698 /* SRShortHeaderView.swift */; }; 47BB39E2DD30787FA591F8EB /* Pods_SynthReel.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F9255BF4D4B1CFDDB5CFFB43 /* Pods_SynthReel.framework */; }; + 85ACDA2F2EE6B3760009B306 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 85ACDA2E2EE6B3760009B306 /* GoogleService-Info.plist */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ @@ -497,6 +498,7 @@ 85ACDA282EE69CD90009B306 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 85ACDA292EE69CD90009B306 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 85ACDA2B2EE69CD90009B306 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/Localizable.strings; sourceTree = ""; }; + 85ACDA2E2EE6B3760009B306 /* GoogleService-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = ""; }; AA88214030574193B51DE563 /* Pods-SynthReel.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SynthReel.release.xcconfig"; path = "Target Support Files/Pods-SynthReel/Pods-SynthReel.release.xcconfig"; sourceTree = ""; }; F9255BF4D4B1CFDDB5CFFB43 /* Pods_SynthReel.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_SynthReel.framework; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ @@ -782,6 +784,7 @@ children = ( 03E9A7C02EC47177000D1067 /* Assets.xcassets */, 03E9A7C12EC47177000D1067 /* Info.plist */, + 85ACDA2E2EE6B3760009B306 /* GoogleService-Info.plist */, 03E9A7C32EC47177000D1067 /* LaunchScreen.storyboard */, 03B1A8562EC5E4F1006C353F /* Localizable.strings */, 03B1A8692EC6BD49006C353F /* Bridging-Header.h */, @@ -1614,6 +1617,7 @@ files = ( 03E9A7CC2EC47177000D1067 /* Assets.xcassets in Resources */, 03B1A8582EC5E4F1006C353F /* Localizable.strings in Resources */, + 85ACDA2F2EE6B3760009B306 /* GoogleService-Info.plist in Resources */, 03B1A8DD2EC6D0EB006C353F /* SRHomeChildCell.xib in Resources */, 03E9A7CE2EC47177000D1067 /* LaunchScreen.storyboard in Resources */, ); @@ -1891,7 +1895,7 @@ CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_TEAM = 6RZK7QBQQ7; + DEVELOPMENT_TEAM = 9JR2Y32ZU3; EXCLUDED_ARCHS = ""; "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = arm64; GENERATE_INFOPLIST_FILE = YES; @@ -1935,7 +1939,7 @@ CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_TEAM = 6RZK7QBQQ7; + DEVELOPMENT_TEAM = 9JR2Y32ZU3; GENERATE_INFOPLIST_FILE = YES; INFOPLIST_FILE = SynthReel/Source/Info.plist; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; diff --git a/SynthReel/Class/Player/VC/SRDetailPlayerViewController.swift b/SynthReel/Class/Player/VC/SRDetailPlayerViewController.swift index 450a816..4382948 100644 --- a/SynthReel/Class/Player/VC/SRDetailPlayerViewController.swift +++ b/SynthReel/Class/Player/VC/SRDetailPlayerViewController.swift @@ -83,7 +83,7 @@ class SRDetailPlayerViewController: JXPlayerListViewController { let lockCoins = videoInfo?.coins ?? 0 if myCoins < lockCoins, (self.sr_viewModel.currentCell as? SRShortDetailPlayerCell)?.hasLastEpisodeUnlocked != true { -// self.sr_viewModel.openRechargeView() + self.sr_viewModel.openRechargeView() } else { DispatchQueue.main.asyncAfter(deadline: .now() + 0.5) { [weak self] in guard let self = self else { return } diff --git a/SynthReel/Class/Player/VM/SRShortPlayerViewModel.swift b/SynthReel/Class/Player/VM/SRShortPlayerViewModel.swift index f514e28..1c9ae9c 100644 --- a/SynthReel/Class/Player/VM/SRShortPlayerViewModel.swift +++ b/SynthReel/Class/Player/VM/SRShortPlayerViewModel.swift @@ -11,6 +11,7 @@ import JXPlayer import YYText import HWPanModal +@MainActor class SRShortPlayerViewModel: JXPlayerListViewModel { var shortId: String = "0" @@ -196,7 +197,9 @@ extension SRShortPlayerViewModel { view.videoInfo = videoInfo view.buyFinishHandle = { [weak self] in guard let self = self else { return } -// self.requestDetailData(indexPath: self.currentIndexPath, completer: nil) + Task{ + await self.requestShortDetail(indexPath: self.currentIndexPath) + } } view.didDismissHandle = { [weak self] in guard let self = self else { return } diff --git a/SynthReel/Class/Store/Views/SRSmallCoinViewCell.swift b/SynthReel/Class/Store/Views/SRSmallCoinViewCell.swift index ada9f6e..d9ff645 100644 --- a/SynthReel/Class/Store/Views/SRSmallCoinViewCell.swift +++ b/SynthReel/Class/Store/Views/SRSmallCoinViewCell.swift @@ -96,13 +96,14 @@ class SRSmallCoinViewCell: SRStoreCoinsCell { private func setupUI() { contentView.addSubview(bgImageView) contentView.addSubview(badgeImageView) + contentView.addSubview(bonusLabel) badgeImageView.addSubview(badgeLabel) // 中间容器(金币 + 数字 + 额外奖励) contentView.addSubview(centerContainer) centerContainer.addSubview(coinImageView) centerContainer.addSubview(coinLabel) - centerContainer.addSubview(bonusLabel) +// centerContainer.addSubview() contentView.addSubview(priceLabel) } @@ -138,12 +139,13 @@ class SRSmallCoinViewCell: SRStoreCoinsCell { coinLabel.snp.makeConstraints { make in make.centerY.equalTo(coinImageView) make.left.equalTo(coinImageView.snp.right).offset(0) + make.right.equalToSuperview() } // 额外奖励 bonusLabel.snp.makeConstraints { make in - make.centerY.equalTo(coinImageView) - make.left.equalTo(coinLabel.snp.right).offset(0) + make.centerX.equalToSuperview() + make.top.equalTo(coinLabel.snp.bottom).offset(0) make.right.equalToSuperview() } diff --git a/SynthReel/Libs/SRAppstore/SRIapManager.swift b/SynthReel/Libs/SRAppstore/SRIapManager.swift index 7871edc..9d1b1c4 100644 --- a/SynthReel/Libs/SRAppstore/SRIapManager.swift +++ b/SynthReel/Libs/SRAppstore/SRIapManager.swift @@ -9,10 +9,12 @@ import UIKit import StoreKit + +@MainActor class SRIapManager { typealias CompletionHandler = ((_ finish: Bool) -> Void) ///内购模版前缀 - static let IAPPrefix = "univico" + static let IAPPrefix = "synthreel" static let manager = SRIapManager() @@ -220,7 +222,7 @@ extension SRIapManager: SRPayMangerDelegate { SRLogin.manager.userInfo?.is_vip = true } - SRToast.show(text: "SRbleo_success".localized) + SRToast.show(text: "synthreel_success".localized) self.completionHandler?(true) if buyType == .subVip { NotificationCenter.default.post(name: SRIapManager.buyVipFinishNotification, object: nil) diff --git a/SynthReel/Libs/SRAppstore/SRPayDataRequest.swift b/SynthReel/Libs/SRAppstore/SRPayDataRequest.swift index 0247485..961c538 100644 --- a/SynthReel/Libs/SRAppstore/SRPayDataRequest.swift +++ b/SynthReel/Libs/SRAppstore/SRPayDataRequest.swift @@ -9,6 +9,7 @@ import UIKit import StoreKit +@MainActor class SRPayDataRequest: NSObject { private var oldTemplateModel: SRPayDateModel? private(set) var newTemplateModel: SRPayDateModel? diff --git a/SynthReel/Source/GoogleService-Info.plist b/SynthReel/Source/GoogleService-Info.plist new file mode 100644 index 0000000..8ecae5c --- /dev/null +++ b/SynthReel/Source/GoogleService-Info.plist @@ -0,0 +1,30 @@ + + + + + API_KEY + AIzaSyDvdKZ1OBbnWz7WeIq47747U4WW8WKWemE + GCM_SENDER_ID + 803478191528 + PLIST_VERSION + 1 + BUNDLE_ID + com.hbqinjiu.SynthReel + PROJECT_ID + synthreel + STORAGE_BUCKET + synthreel.firebasestorage.app + IS_ADS_ENABLED + + IS_ANALYTICS_ENABLED + + IS_APPINVITE_ENABLED + + IS_GCM_ENABLED + + IS_SIGNIN_ENABLED + + GOOGLE_APP_ID + 1:803478191528:ios:c0cbb2e33d8a01ee1a719d + + \ No newline at end of file diff --git a/SynthReel/Source/Info.plist b/SynthReel/Source/Info.plist index bf59de1..4fa068d 100644 --- a/SynthReel/Source/Info.plist +++ b/SynthReel/Source/Info.plist @@ -17,14 +17,14 @@ Editor CFBundleURLSchemes - fb1765365954312054 + fb1203129771732470 FacebookAppID - 1765365954312054 + 1203129771732470 FacebookClientToken - 7a0b78de0a5f0e04738e8596b1b50aaa + 3e671125d76ef8555893cd453337ccfc UIApplicationSceneManifest UIApplicationSupportsMultipleScenes diff --git a/SynthReel/Source/en.lproj/Localizable.strings b/SynthReel/Source/en.lproj/Localizable.strings index 3b7efbe..af0926b 100644 --- a/SynthReel/Source/en.lproj/Localizable.strings +++ b/SynthReel/Source/en.lproj/Localizable.strings @@ -90,3 +90,11 @@ "synthreel_price" = "price"; "synthreel_balance" = "balance"; "synthreel_continue" = "Claim Now"; +"synthreel_success" = "success"; + +"pay_error_1" = "You are already a member!"; +"pay_error_2" = "Invalid in-app purchase"; +"pay_error_3" = "Payment has been cancelled"; +"pay_error_4" = "Purchase Failed"; +"pay_error_5" = "There are no recoverable in-app purchases."; +"pay_error_6" = "You have unfinished in-app purchases, please restore them first.";