优化下载皮肤❤️
This commit is contained in:
@@ -242,6 +242,7 @@ typedef NS_ENUM(NSInteger, KBSkinDetailSection) {
|
||||
[KBHUD showInfo:KBLocalized(@"正在加载主题详情")];
|
||||
return;
|
||||
}
|
||||
NSLog(@"🧩[SkinDetail] action themeId=%@ purchased=%d", self.themeId, self.detailModel.isPurchased);
|
||||
if (self.detailModel.isPurchased) {
|
||||
[self requestDownload];
|
||||
} else {
|
||||
@@ -287,11 +288,17 @@ typedef NS_ENUM(NSInteger, KBSkinDetailSection) {
|
||||
if (self.detailModel.themePreviewImageUrl.length > 0) {
|
||||
skin[@"preview"] = self.detailModel.themePreviewImageUrl;
|
||||
}
|
||||
skin[@"force_download"] = @(YES);
|
||||
NSLog(@"⬇️[SkinDetail] download request id=%@ zip=%@ force=YES",
|
||||
skin[@"id"], skin[@"zip_url"]);
|
||||
[KBHUD showWithStatus:@"正在下载..."];
|
||||
[[KBSkinService shared] applySkinWithJSON:skin
|
||||
fromViewController:self
|
||||
mode:KBSkinSourceModeRemoteZip
|
||||
completion:^(BOOL success) {
|
||||
completion:^(BOOL success) {
|
||||
NSLog(@"%@[SkinDetail] download result id=%@",
|
||||
(success ? @"✅" : @"❌"),
|
||||
self.detailModel.themeId);
|
||||
if (success) {
|
||||
NSString *themeId = self.detailModel.themeId;
|
||||
if (themeId.length > 0) {
|
||||
|
||||
Reference in New Issue
Block a user