Updated navigation list order and import, export button color and navigation label
This commit is contained in:
@@ -43,6 +43,8 @@ class LocatorInvoiceValidationResource extends Resource
|
||||
|
||||
protected static ?string $navigationGroup = 'Export Dispatch';
|
||||
|
||||
protected static ?int $navigationSort = 5;
|
||||
|
||||
public static function form(Form $form): Form
|
||||
{
|
||||
return $form
|
||||
@@ -640,11 +642,15 @@ class LocatorInvoiceValidationResource extends Resource
|
||||
|
||||
ImportAction::make()
|
||||
->importer(LocatorInvoiceValidationImporter::class)
|
||||
->label('Import Locator Invoice')
|
||||
->color('warning')
|
||||
->visible(function() {
|
||||
return Filament::auth()->user()->can('view import locator invoice validation');
|
||||
}),
|
||||
ExportAction::make()
|
||||
->exporter(LocatorInvoiceValidationExporter::class)
|
||||
->label('Export Locator Invoice')
|
||||
->color('warning')
|
||||
->visible(function() {
|
||||
return Filament::auth()->user()->can('view export locator invoice validation');
|
||||
}),
|
||||
@@ -894,6 +900,11 @@ class LocatorInvoiceValidationResource extends Resource
|
||||
];
|
||||
}
|
||||
|
||||
public static function getNavigationLabel(): string
|
||||
{
|
||||
return 'Scan Invoice';
|
||||
}
|
||||
|
||||
public static function getPages(): array
|
||||
{
|
||||
return [
|
||||
|
||||
@@ -36,8 +36,11 @@ class PalletValidationResource extends Resource
|
||||
protected static ?string $model = PalletValidation::class;
|
||||
|
||||
protected static ?string $navigationIcon = 'heroicon-o-rectangle-stack';
|
||||
|
||||
protected static ?string $navigationGroup = 'Export Dispatch';
|
||||
|
||||
protected static ?int $navigationSort = 1;
|
||||
|
||||
public static function form(Form $form): Form
|
||||
{
|
||||
|
||||
@@ -526,11 +529,15 @@ class PalletValidationResource extends Resource
|
||||
}),
|
||||
ImportAction::make()
|
||||
->importer(PalletValidationImporter::class)
|
||||
->label('Import Pallet')
|
||||
->color('warning')
|
||||
->visible(function() {
|
||||
return Filament::auth()->user()->can('view import pallet validation');
|
||||
}),
|
||||
ExportAction::make()
|
||||
->exporter(PalletValidationExporter::class)
|
||||
->label('Export Pallet')
|
||||
->color('warning')
|
||||
->visible(function() {
|
||||
return Filament::auth()->user()->can('view export pallet validation');
|
||||
}),
|
||||
@@ -544,6 +551,11 @@ class PalletValidationResource extends Resource
|
||||
];
|
||||
}
|
||||
|
||||
public static function getNavigationLabel(): string
|
||||
{
|
||||
return 'Scan Pallet';
|
||||
}
|
||||
|
||||
public static function getPages(): array
|
||||
{
|
||||
return [
|
||||
|
||||
@@ -38,6 +38,8 @@ class ReworkLocatorInvoiceValidationResource extends Resource
|
||||
|
||||
protected static ?string $navigationGroup = 'Export Dispatch';
|
||||
|
||||
protected static ?int $navigationSort = 7;
|
||||
|
||||
public static function form(Form $form): Form
|
||||
{
|
||||
return $form
|
||||
@@ -241,6 +243,7 @@ class ReworkLocatorInvoiceValidationResource extends Resource
|
||||
}),
|
||||
Tables\Columns\TextColumn::make('plant.name')
|
||||
->label('Plant')
|
||||
->alignCenter()
|
||||
->sortable(),
|
||||
Tables\Columns\TextColumn::make('invoice_number')
|
||||
->label('Invoice Number')
|
||||
@@ -314,11 +317,15 @@ class ReworkLocatorInvoiceValidationResource extends Resource
|
||||
->headerActions([
|
||||
ImportAction::make()
|
||||
->importer(ReworkLocatorInvoiceValidationImporter::class)
|
||||
->label('Import Rework Invoice')
|
||||
->color('warning')
|
||||
->visible(function() {
|
||||
return Filament::auth()->user()->can('view import rework invoice validation');
|
||||
}),
|
||||
ExportAction::make()
|
||||
->exporter(ReworkLocatorInvoiceValidationExporter::class)
|
||||
->label('Export Rework Invoice')
|
||||
->color('warning')
|
||||
->visible(function() {
|
||||
return Filament::auth()->user()->can('view export rework invoice validation');
|
||||
}),
|
||||
@@ -531,6 +538,11 @@ class ReworkLocatorInvoiceValidationResource extends Resource
|
||||
];
|
||||
}
|
||||
|
||||
public static function getNavigationLabel(): string
|
||||
{
|
||||
return 'Scan Rework';
|
||||
}
|
||||
|
||||
public static function getPages(): array
|
||||
{
|
||||
return [
|
||||
@@ -540,10 +552,6 @@ class ReworkLocatorInvoiceValidationResource extends Resource
|
||||
'edit' => Pages\EditReworkLocatorInvoiceValidation::route('/{record}/edit'),
|
||||
];
|
||||
}
|
||||
public static function getNavigationLabel(): string
|
||||
{
|
||||
return 'Rework Invoice / Pallet';
|
||||
}
|
||||
|
||||
public static function getEloquentQuery(): Builder
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user