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