Actualiser js/admin.js
This commit is contained in:
+2
-2
@@ -412,14 +412,14 @@ async function handleCritiqueUpload(input) {
|
||||
loadDashboardData();
|
||||
}
|
||||
|
||||
// Extraction de l'EAN et du titre du CSV
|
||||
function normalizeVideothequeRow(row) {
|
||||
let ean = row['ean_isbn13'] || row['EAN'] || row['ean'] || row['Barcode'] || row['UPC'] || row['upc_isbn10'] || '';
|
||||
if (ean) ean = String(ean).replace(/[^0-9]/g, '');
|
||||
|
||||
// On récupère aussi le titre du CSV pour s'en servir de secours
|
||||
let title = row['title'] ? String(row['title']).trim() : '';
|
||||
|
||||
if (!ean && !title) return null;
|
||||
|
||||
return {
|
||||
ean: ean,
|
||||
title: title
|
||||
|
||||
Reference in New Issue
Block a user