<?php

use Illuminate\Support\Facades\Route;
use App\Http\Controllers\{{modelName}}Controller;

Route::get('/{{modelNameSnakeCase}}', [{{modelName}}Controller::class, 'index'])
    ->middleware('permission:{{modelNameSnakeCase}},view');

Route::post('/{{modelNameSnakeCase}}', [{{modelName}}Controller::class, 'store'])
    ->middleware('permission:{{modelNameSnakeCase}},add');

Route::get('/{{modelNameSnakeCase}}/{id}', [{{modelName}}Controller::class, 'show'])
    ->middleware('permission:{{modelNameSnakeCase}},view');

Route::put('/{{modelNameSnakeCase}}/{id}', [{{modelName}}Controller::class, 'update'])
    ->middleware('permission:{{modelNameSnakeCase}},edit');

Route::delete('/{{modelNameSnakeCase}}/{id}', [{{modelName}}Controller::class, 'destroy'])
    ->middleware('permission:{{modelNameSnakeCase}},delete');
