Skip to content

Commit

Permalink
feat: add routes to category
Browse files Browse the repository at this point in the history
  • Loading branch information
phojie committed Dec 4, 2022
1 parent fbf0087 commit 624e3d4
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 0 deletions.
6 changes: 6 additions & 0 deletions resources/js/composables/app/navigation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import HeroiconsCog from '~icons/heroicons/cog'
import HeroiconsDocumentText from '~icons/heroicons/document-text'
import HeroiconsQuestionMarkCircle from '~icons/heroicons/question-mark-circle'
import HeroiconsFingerPrint from '~icons/heroicons/finger-print'
import HeroiconsQueueList from '~icons/heroicons/queue-list'
// import HeroiconsShieldCheck from '~icons/heroicons/shield-check'

interface NavigationItem {
Expand All @@ -28,6 +29,11 @@ export const useNavigation = () => {
icon: HeroiconsHome,

},
{
name: 'Categories',
href: '/admin/categories',
icon: HeroiconsQueueList,
},
{
name: 'Menus',
icon: HeroiconsDocumentDuplicate,
Expand Down
4 changes: 4 additions & 0 deletions routes/components/index.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?php

use App\Http\Controllers\Components\CategoryController;
use App\Http\Controllers\Components\PermissionController;
use App\Http\Controllers\Components\RoleController;
use App\Http\Controllers\Components\TemporaryFileController;
Expand All @@ -19,4 +20,7 @@

// users
Route::get('users/{id}', [UserController::class, 'show'])->name('components.users.show');

// categories
Route::get('categories/{id}', [CategoryController::class, 'show'])->name('components.categories.show');
});
2 changes: 2 additions & 0 deletions routes/web.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,5 @@

require __DIR__.'/auth/index.php';
require __DIR__.'/components/index.php';

require __DIR__.'/admin/category.php';

0 comments on commit 624e3d4

Please sign in to comment.