diff --git a/app/Filament/Resources/ItemResource.php b/app/Filament/Resources/ItemResource.php index 4a0a648..8d8b06b 100644 --- a/app/Filament/Resources/ItemResource.php +++ b/app/Filament/Resources/ItemResource.php @@ -111,6 +111,7 @@ class ItemResource extends Resource ->label('Hourly Quantity') ->placeholder('Scan the valid quantity') ->integer() + ->default(1) ->minValue(1) ->reactive() ->afterStateUpdated(function ($state, callable $set, callable $get) { @@ -135,15 +136,22 @@ class ItemResource extends Resource ]) ->hint(fn ($get) => $get('iHourQuanError') ? $get('iHourQuanError') : null) ->hintColor('danger'), - Forms\Components\Textarea::make('description') + Forms\Components\TextInput::make('uom') ->required() - ->placeholder('Scan the valid description'), + ->label('Unit of Measure') + ->placeholder('Scan the valid uom'), + + Forms\Components\TextInput::make('description') + ->placeholder('Scan the valid description') + ->required() + ->minLength(5) + ->columnSpan(['default' => 1, 'sm' => 2]), // ->columnSpanFull(), Forms\Components\TextInput::make('id') ->hidden() ->readOnly(), ]) - ->columns(2), + ->columns(3), ]); } @@ -162,8 +170,14 @@ class ItemResource extends Resource ->sortable() ->searchable(), Tables\Columns\TextColumn::make('hourly_quantity') + ->label('Hourly Quantity') + ->alignCenter() ->numeric() ->sortable(), + Tables\Columns\TextColumn::make('uom') + ->label('Unit of Measure') + ->alignCenter() + ->sortable(), Tables\Columns\TextColumn::make('plant.name') ->sortable() ->searchable(),