feat: tambah budget kegiatan dengan alur threshold approval/voting
This commit is contained in:
@@ -17,6 +17,8 @@ class ActivityForm
|
||||
Textarea::make('description')->label('Deskripsi')->rows(3)->columnSpanFull(),
|
||||
DatePicker::make('start_date')->label('Mulai')->required(),
|
||||
DatePicker::make('end_date')->label('Selesai')->required(),
|
||||
TextInput::make('budget')->label('Estimasi Budget (Rp)')->numeric()
|
||||
->helperText('Kosongkan jika tidak ada budget. < Rp500.000: langsung | Rp500.000–2.000.000: approval ketua | > Rp2.000.000: voting'),
|
||||
DateTimePicker::make('executed_at')->label('Waktu Pelaksanaan')
|
||||
->visible(fn ($record) => $record?->status === 'approved'),
|
||||
Textarea::make('execution_notes')->label('Catatan Pelaksanaan')->rows(3)->columnSpanFull()
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Filament\Resources\CashRecords\Schemas;
|
||||
|
||||
use App\Models\Activity;
|
||||
use App\Models\CashCategory;
|
||||
use Filament\Forms\Components\DatePicker;
|
||||
use Filament\Forms\Components\Placeholder;
|
||||
@@ -27,6 +28,9 @@ class CashRecordForm
|
||||
->live(),
|
||||
Textarea::make('description')->label('Keterangan')->required()->columnSpanFull(),
|
||||
DatePicker::make('date')->label('Tanggal')->required(),
|
||||
Select::make('activity_id')->label('Kegiatan Terkait')
|
||||
->options(Activity::whereIn('status', ['approved'])->pluck('title', 'id'))
|
||||
->searchable()->nullable(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user