return response()->download($tmp, $filename . '.pdf')->deleteFileAfterSend(true);
}
- $bottomStrings = ['shorts', 'pants'];
+ $bottomStrings = ['shorts', 'pants', 'tights'];
$references = explode(',', $references);
/** @var FluidbookPublication $book */
$r[$reference] = $data;
$title = trim(trim($data['Catégorie'] ?? '') . ' ' . trim($data['RBU'] ?? ''));
- $subtitle = trim(trim($data['Age Group'] ?? '') . ' - ' . $data['Gender'] . ' - ' . trim($data['Product Line'] ?? ''), '- ');
+ $subtitle = trim(trim($data['Age Group'] ?? '') . ' - ' . $data['Genre'] . ' - ' . trim($data['Product Line'] ?? ''), '- ');
$key = md5($title . $subtitle);
if (!isset($planches[$key])) {
$planches[$key] = ['class' => $data['Catégorie'], 'title' => $title, 'subtitle' => $subtitle, 'groups' => ['top' => [], 'bottom' => []]];
}
$group = 'top';
foreach ($bottomStrings as $str) {
- if (stristr($data['Article Type'], $str)) {
+ if (stristr($data['Article Type'], $str) !== false) {
$group = 'bottom';
break;
}
if (!count($products)) {
continue;
}
- $lines= array_merge($lines, array_chunk($products, $cols, true));;;
+ $lines = array_merge($lines, array_chunk($products, $cols, true));;;
}
$subs = array_chunk($lines, $rows, true);