From 8c3f789af2960d2de64bdec80e02ef5877b3f378 Mon Sep 17 00:00:00 2001 From: shanj <18996038927@163.com> Date: Wed, 7 Sep 2022 02:10:18 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D1688=E7=88=AC=E8=99=AB?= =?UTF-8?q?=E5=8F=96=E5=9B=BE=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../APIServices/PurchaseProductAPIService.cs | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/BBWY.Client/APIServices/PurchaseProductAPIService.cs b/BBWY.Client/APIServices/PurchaseProductAPIService.cs index b6ecab86..46fb01d9 100644 --- a/BBWY.Client/APIServices/PurchaseProductAPIService.cs +++ b/BBWY.Client/APIServices/PurchaseProductAPIService.cs @@ -199,11 +199,14 @@ namespace BBWY.Client.APIServices Location = jobject["data"]["1081181309101"]["data"]["location"].ToString() }; - var colors3216 = jobject["globalData"]["skuModel"]["skuProps"].FirstOrDefault(j => j.Value("fid") == 3216)["value"].Children().Select(j => new - { - name = j.Value("name"), - imageUrl = j.Value("imageUrl") - }).ToList(); + var colorsProperty = jobject["globalData"]["skuModel"]["skuProps"].FirstOrDefault(j => j.Value("fid") == 3216 && + j.Value("fid") == 1627207)["value"] + .Children() + .Select(j => new + { + name = j.Value("name"), + imageUrl = j.Value("imageUrl") + }).ToList(); var firstPrice = jobject["data"]["1081181309582"]["data"]["priceModel"]["currentPrices"][0].Value("price"); @@ -227,7 +230,7 @@ namespace BBWY.Client.APIServices Title = name, PurchaseSkuId = value.Value("skuId"), PurchaseSkuSpecId = value.Value("specId"), - Logo = colors3216.FirstOrDefault(c => c.name == matchName)?.imageUrl ?? "pack://application:,,,/Resources/Images/defaultItem.png" + Logo = colorsProperty.FirstOrDefault(c => c.name == matchName)?.imageUrl ?? "pack://application:,,,/Resources/Images/defaultItem.png" }); }