Tags Management
The Admin or Creator user has access to a tags management table page.
The theme has some default categories but an Admin or Creator user can manage these
tags.
The tags management can be accessed by clicking Tag Management
from the
Laravel Examples section of the sidebar. The user is able to add, edit and
delete tags. For adding a new tag you can press the
+ Add Tag button.
If you would like to edit or delete a tag you can click on the Action column. It is also
possible to sort the fields
or to search in the fields.
On the page for adding a new category you will find a form which allows you to fill the name and the description of the new tag and on the edit page you will find a similar form for the changes you wish to make.
The App/Http/Livewire/LaravelExamples/Tag/Create.php
takes care of data validation and creation of a the new tag
public function store(){
$this->validate();
Tag::create([
'name' => $this->name,
'color' =>$this->color,
]);
return redirect(route('tag-management'))->with('status','Tag successfully created.');
}
The policy which authorizes the user to access tags management pages is implemented in App\Policies\TagPolicy.php
.