From 7c870e6c460675ae2a1444ed9700dadf3bccf192 Mon Sep 17 00:00:00 2001 From: chfei Date: Mon, 9 Nov 2026 14:23:57 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=8F=90=E7=A4=BA=E6=A3=80?= =?UTF-8?q?=E6=B5=8B=E5=9B=BE=E7=89=87=E6=AC=A1=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../WXUserCollectAuthProdListForm.cs | 38 +++++++++++-------- 1 file changed, 23 insertions(+), 15 deletions(-) diff --git a/TEMUKJD/WXForms/ProductForms/WXUserCollectAuthProdListForm.cs b/TEMUKJD/WXForms/ProductForms/WXUserCollectAuthProdListForm.cs index 3e44e60..7e060d8 100644 --- a/TEMUKJD/WXForms/ProductForms/WXUserCollectAuthProdListForm.cs +++ b/TEMUKJD/WXForms/ProductForms/WXUserCollectAuthProdListForm.cs @@ -1302,20 +1302,20 @@ namespace TemuKJD.WXForms.ProductForms .Where(p => ids.Contains(p.id)) .ToDictionary(p => p.id); - var selected = ids - .Where(id => productDict.ContainsKey(id)) - .Select(id => - { - var prod = productDict[id]; - return new ComplianceGoods - { - id = prod.id.ToString(), - name = prod.product_name, - image = prod.main_img, - type = ComplianceGoods.Library - }; - }) - .ToList(); + var selected = ids + .Where(id => productDict.ContainsKey(id)) + .Select(id => + { + var prod = productDict[id]; + return new ComplianceGoods + { + id = prod.id.ToString(), + name = prod.product_name, + image = prod.main_img, + type = ComplianceGoods.Library + }; + }) + .ToList(); if (selected.Count == 0) @@ -1323,7 +1323,15 @@ namespace TemuKJD.WXForms.ProductForms BaseMsgForm.ShowInfo("请选择商品"); return; } - BaseMsgForm.ShowInfo($"当前AI检测剩余:{BaseClass.ImageAnalysisQuota}张"); + if (BaseClass.ImageAnalysisQuota > 0) + { + BaseMsgForm.ShowInfo($"当前AI检测剩余:{BaseClass.ImageAnalysisQuota}张"); + } + else + { + BaseMsgForm.ShowInfo($"当前AI检测剩余:{BaseClass.ImageAnalysisQuota}张,请兑换"); + return; + } var originalText = btnSafeDetection.Text; detection = new CancellationTokenSource();