card orders WIP
This commit is contained in:
@@ -8,6 +8,7 @@ use Illuminate\Http\Request;
|
||||
use Laravel\Nova\Fields\ID;
|
||||
use Laravel\Nova\Fields\Text;
|
||||
use Laravel\Nova\Http\Requests\NovaRequest;
|
||||
use Trin4ik\NovaSwitcher\NovaSwitcher;
|
||||
|
||||
class CardType extends Resource
|
||||
{
|
||||
@@ -34,6 +35,22 @@ class CardType extends Resource
|
||||
'name',
|
||||
];
|
||||
|
||||
/**
|
||||
* Get the displayable label of the resource.
|
||||
*/
|
||||
public static function label(): string
|
||||
{
|
||||
return __('Card types');
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the displayable singular label of the resource.
|
||||
*/
|
||||
public static function singularLabel(): string
|
||||
{
|
||||
return __('Card type');
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the fields displayed by the resource.
|
||||
*/
|
||||
@@ -50,7 +67,7 @@ class CardType extends Resource
|
||||
->rules('nullable', 'numeric'),
|
||||
|
||||
Text::make(__('Notes'), 'notes')
|
||||
->rules('required', 'string', 'max:255'),
|
||||
->rules('nullable', 'string', 'max:255'),
|
||||
|
||||
NovaSwitcher::make(__('Active'), 'active')
|
||||
->default(true),
|
||||
|
||||
Reference in New Issue
Block a user