mirror of
https://github.com/christianvidalwolf-prog/CrazeAnalytix.git
synced 2026-08-03 11:05:23 +02:00
Fix Buy Box parsing: only include ASINs with Issue Type/Reason specified
This commit is contained in:
Binary file not shown.
@@ -1973,9 +1973,13 @@ export const processBuyBoxExcel = async (fileOrBuffer: File | ArrayBuffer): Prom
|
||||
if (!asin || asin.length < 5) continue;
|
||||
|
||||
const rawReason = String(row[config.reasonCol] || '').trim();
|
||||
const reason = rawReason || 'Unknown';
|
||||
|
||||
// Only add if there's actually a BB lost (non-empty reason or explicit entry)
|
||||
// Only consider as BB lost if there is an Issue Type / Reason specified
|
||||
// Empty reason means no issue = they have the Buy Box
|
||||
if (!rawReason) continue;
|
||||
|
||||
const reason = rawReason;
|
||||
|
||||
if (!buyBoxMap.has(asin)) {
|
||||
buyBoxMap.set(asin, { countries: [], reasons: {} });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user