refactor: simplify PartnerInfolist sections by removing dynamic notification labels and icons

This commit is contained in:
Yoga Pangestu 2026-04-09 13:06:08 +07:00
parent 2bd0b200e3
commit 24d87cbbae

View File

@ -3,7 +3,6 @@
namespace App\Filament\Resources\Manage\Partners\Infolists;
use App\Enums\DecisionAdmin;
use App\Enums\NotifStyle;
use App\Filament\Support\CheerfulNotification;
use App\Models\User;
use Filament\Infolists\Components\RepeatableEntry;
@ -88,8 +87,7 @@ public static function configure(Schema $schema): Schema
Grid::make(3)
->schema([
Section::make(fn () => CheerfulNotification::getByKey('company.director_nik'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-user' : null)
Section::make('NIK Direktur')
->schema([
TextEntry::make('company.director_nik')
->hiddenLabel(),
@ -136,8 +134,7 @@ public static function configure(Schema $schema): Schema
}),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.establishment_deed'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('Akta Pendirian')
->schema([
TextEntry::make('company.deed_incorporation')
->hiddenLabel(),
@ -145,8 +142,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('company.deed_incorporation'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.siup_nib'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('SIUP / NIB')
->schema([
TextEntry::make('company.trade_license')
->hiddenLabel(),
@ -154,8 +150,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('company.trade_license'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.npwp'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('NPWP')
->schema([
TextEntry::make('company.tax_id_number')
->hiddenLabel(),
@ -163,8 +158,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('company.tax_id_number'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.pkp'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('PKP')
->schema([
TextEntry::make('company.taxable_enterprise')
->hiddenLabel(),
@ -172,8 +166,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('company.taxable_enterprise'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.annual_tax'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('SPT Tahunan')
->schema([
TextEntry::make('company.annual_tax_return')
->hiddenLabel(),
@ -181,8 +174,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('company.annual_tax_return'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.domicile'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('Suket Domisili')
->schema([
TextEntry::make('company.domicile_certificate')
->hiddenLabel(),
@ -190,8 +182,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('company.domicile_certificate'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.company_profile'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('Profil Perusahaan')
->schema([
TextEntry::make('company.profile')
->hiddenLabel(),
@ -228,8 +219,7 @@ public static function configure(Schema $schema): Schema
Grid::make(2)
->schema([
Section::make(fn () => CheerfulNotification::getByKey('company.journalism_org_cert'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('Organisasi Kewartawanan')
->schema([
TextEntry::make('company.partnerMedia.journalism_organization')
->hiddenLabel(),
@ -237,8 +227,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('company.partnerMedia.journalism_organization', 'company.partnerMedia', 'partnerMedia'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.press_council_cert'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('Sertifikat Dewan Pers')
->schema([
TextEntry::make('company.partnerMedia.press_council_certificate')
->hiddenLabel(),
@ -257,18 +246,17 @@ public static function configure(Schema $schema): Schema
Grid::make(3)
->schema([
TextEntry::make('name')
->label('Nama'),
->label('Nama Lengkap'),
TextEntry::make('email')
->label('Email'),
->label('Alamat Surel'),
TextEntry::make('phone_number')
->label('No. Telepon'),
->label('Nomor Telepon'),
]),
Grid::make(2)
->schema([
Section::make(fn () => CheerfulNotification::getByKey('company.press_card'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-identification' : null)
Section::make('Dokumen Pers')
->schema([
TextEntry::make('press_card')
->hiddenLabel(),
@ -276,8 +264,7 @@ public static function configure(Schema $schema): Schema
self::fileEntry('press_card', null, 'journalists'),
]),
Section::make(fn () => CheerfulNotification::getByKey('company.ukw_cert'))
->icon(fn () => CheerfulNotification::getNotifStyle() === NotifStyle::CHEERFUL ? 'heroicon-o-document-text' : null)
Section::make('Sertifikat UKW')
->schema([
TextEntry::make('ukw_certificate')
->hiddenLabel(),