change icons, css, add routing to merchandise, add mail templater, fixes

This commit is contained in:
Ludovic CANDELLIER
2023-02-12 23:34:48 +01:00
parent 8313e25f2e
commit f2f4788ce1
71 changed files with 1486 additions and 154 deletions

View File

@@ -0,0 +1,45 @@
<?php
namespace App\Repositories\Core\Export;
class HelperExcel
{
public static function getHeaderStyle($color = 'ffffff', $bgcolor = '00a3cb')
{
return [
'fill' => self::setFill($bgcolor),
'borders' => self::setBorders($bgcolor),
'font' => self::setFont($color, 14, true),
];
}
public static function setFill($color)
{
return [
'fillType' => \PhpOffice\PhpSpreadsheet\Style\Fill::FILL_SOLID,
'startColor' => [
'rgb' => $color,
],
];
}
public static function setBorders($color)
{
return [
'outline' => [
'borderStyle' => \PhpOffice\PhpSpreadsheet\Style\Border::BORDER_THICK,
'color' => ['argb' => $color],
],
];
}
public static function setFont($color, $size = 12, $bold = false, $font = 'Calibri')
{
return [
'name' => $font,
'size' => $size,
'bold' => $bold,
'color' => ['argb' => $color],
];
}
}