ranjith-dev #418
@@ -12,6 +12,7 @@ use Filament\Facades\Filament;
|
||||
use Filament\Forms;
|
||||
use Filament\Forms\Components\Actions\Action;
|
||||
use Filament\Forms\Form;
|
||||
use Filament\Forms\Get;
|
||||
use Filament\Notifications\Notification;
|
||||
use Filament\Resources\Resource;
|
||||
use Filament\Tables;
|
||||
@@ -45,6 +46,7 @@ class GrMasterResource extends Resource
|
||||
->reactive()
|
||||
->searchable()
|
||||
->relationship('plant', 'name')
|
||||
->disabled(fn (Get $get) => ! empty($get('id')))
|
||||
->options(function (callable $get) {
|
||||
$userHas = Filament::auth()->user()->plant_id;
|
||||
|
||||
@@ -56,6 +58,7 @@ class GrMasterResource extends Resource
|
||||
// ->relationship('item', 'id')
|
||||
->reactive()
|
||||
->searchable()
|
||||
->disabled(fn (Get $get) => ! empty($get('id')))
|
||||
->options(function (callable $get) {
|
||||
$plantId = $get('plant_id');
|
||||
if (empty($plantId)) {
|
||||
|
||||
Reference in New Issue
Block a user