Updated auto focus option while disabled
This commit is contained in:
@@ -299,9 +299,10 @@ class ProductionQuantityResource extends Resource
|
||||
->required()
|
||||
->columnSpan(2)
|
||||
// ->rules(['regex:/^[1-9][0-9]{6,}$/'])
|
||||
->disabled(function ($get) {
|
||||
return $get('item_code');
|
||||
})
|
||||
// ->disabled(function ($get) {
|
||||
// return $get('item_code');
|
||||
// })
|
||||
// ->readOnly(fn (callable $get) => $get('item_code'))
|
||||
->default(function () {
|
||||
// $latestProductionOrder = ProductionQuantity::latest()->first()->production_order;
|
||||
// return $latestProductionOrder ?? null;
|
||||
@@ -325,9 +326,10 @@ class ProductionQuantityResource extends Resource
|
||||
->columnSpan(2)
|
||||
->autofocus(true)
|
||||
->debounce(100)
|
||||
->disabled(function ($get) {
|
||||
return !$get('production_order');
|
||||
})
|
||||
// ->disabled(function ($get) {
|
||||
// return !$get('production_order');
|
||||
// })
|
||||
|
||||
// ->submitOnEnter()
|
||||
->afterStateUpdated(function ($state, callable $get, callable $set) {
|
||||
$set('success_msg', null);
|
||||
|
||||
Reference in New Issue
Block a user