Boolean field added

This commit is contained in:
HolgerHatGarKeineNode
2023-02-13 19:29:53 +01:00
parent a0cf95d2a0
commit c659c99bee
13 changed files with 51 additions and 13 deletions

View File

@@ -91,7 +91,8 @@ class BitcoinEvent extends Resource
->hideFromIndex(),
Text::make('Link')
->rules('required', 'string'),
->rules('required', 'string')
->hideFromIndex(),
BelongsTo::make(__('Venue'), 'venue', Venue::class)
->searchable()

View File

@@ -13,6 +13,7 @@ use Illuminate\Database\Eloquent\Model;
use Illuminate\Http\Request;
use Laravel\Nova\Fields\BelongsTo;
use Laravel\Nova\Fields\BelongsToMany;
use Laravel\Nova\Fields\Boolean;
use Laravel\Nova\Fields\Code;
use Laravel\Nova\Fields\ID;
use Laravel\Nova\Fields\Number;
@@ -161,6 +162,10 @@ class LibraryItem extends Resource
)
->rules('required', 'string'),
Boolean::make(__('News Article'), 'news')->help(__('Is this a news article?')),
Boolean::make(__('Approve'), 'approved')->help(__('Article approved')),
Code::make(__('Value'), 'value')
->rules('nullable', 'string')
->help('Please paste the URL to the video here, or the link to the blog article, or the link to the book, or the Markdown itself.'),