Optimize code

This commit is contained in:
Daeng Deni Mardaeni
2024-08-13 11:54:42 +07:00
parent 5c4285c77e
commit e950b73b44
42 changed files with 1064 additions and 991 deletions

View File

@@ -7,6 +7,7 @@
use Maatwebsite\Excel\Concerns\WithHeadings;
use Maatwebsite\Excel\Concerns\WithMapping;
use Modules\Lpj\Models\Branch;
use PhpOffice\PhpSpreadsheet\Style\NumberFormat;
class BranchExport implements WithColumnFormatting, WithHeadings, FromCollection, withMapping
{
@@ -41,8 +42,8 @@
: array
{
return [
'A' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_NUMBER,
'D' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_DATE_DATETIME
'A' => NumberFormat::FORMAT_NUMBER,
'D' => NumberFormat::FORMAT_DATE_DATETIME
];
}
}

View File

@@ -7,7 +7,7 @@
use Maatwebsite\Excel\Concerns\WithHeadings;
use Maatwebsite\Excel\Concerns\WithMapping;
use Modules\Lpj\Models\Currency;
use Modules\Lpj\Models\JenisJaminan;
use PhpOffice\PhpSpreadsheet\Style\NumberFormat;
class CurrencyExport implements WithColumnFormatting, WithHeadings, FromCollection, withMapping
{
@@ -46,9 +46,9 @@
: array
{
return [
'A' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_NUMBER,
'B' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_NUMBER,
'E' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_DATE_DATETIME
'A' => NumberFormat::FORMAT_NUMBER,
'B' => NumberFormat::FORMAT_NUMBER,
'E' => NumberFormat::FORMAT_DATE_DATETIME
];
}
}

View File

@@ -7,6 +7,7 @@
use Maatwebsite\Excel\Concerns\WithHeadings;
use Maatwebsite\Excel\Concerns\WithMapping;
use Modules\Lpj\Models\JenisAset;
use PhpOffice\PhpSpreadsheet\Style\NumberFormat;
class JenisAsetExport implements WithColumnFormatting, WithHeadings, FromCollection, withMapping
{
@@ -41,8 +42,8 @@
: array
{
return [
'A' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_NUMBER,
'D' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_DATE_DATETIME
'A' => NumberFormat::FORMAT_NUMBER,
'D' => NumberFormat::FORMAT_DATE_DATETIME
];
}
}

View File

@@ -7,6 +7,7 @@
use Maatwebsite\Excel\Concerns\WithHeadings;
use Maatwebsite\Excel\Concerns\WithMapping;
use Modules\Lpj\Models\JenisFasilitasKredit;
use PhpOffice\PhpSpreadsheet\Style\NumberFormat;
class JenisFasilitasKreditExport implements WithColumnFormatting, WithHeadings, FromCollection, withMapping
{
@@ -41,8 +42,8 @@
: array
{
return [
'A' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_NUMBER,
'D' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_DATE_DATETIME
'A' => NumberFormat::FORMAT_NUMBER,
'D' => NumberFormat::FORMAT_DATE_DATETIME
];
}
}

View File

@@ -7,6 +7,7 @@
use Maatwebsite\Excel\Concerns\WithHeadings;
use Maatwebsite\Excel\Concerns\WithMapping;
use Modules\Lpj\Models\JenisJaminan;
use PhpOffice\PhpSpreadsheet\Style\NumberFormat;
class JenisJaminanExport implements WithColumnFormatting, WithHeadings, FromCollection, withMapping
{
@@ -41,8 +42,8 @@
: array
{
return [
'A' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_NUMBER,
'D' => \PhpOffice\PhpSpreadsheet\Style\NumberFormat::FORMAT_DATE_DATETIME
'A' => NumberFormat::FORMAT_NUMBER,
'D' => NumberFormat::FORMAT_DATE_DATETIME
];
}
}