2023-03-10 16:18:11 +08:00

57 lines
2.2 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php
/**
* @date 2023年03月2日
* @author刘孝全
* @emailq8197264@126.com
*
* @ 商户菜单路由
*/
use think\facade\Route;
use app\common\middleware\AdminAuthMiddleware;
use app\common\middleware\AdminTokenMiddleware;
use app\common\middleware\AllowOriginMiddleware;
use app\common\middleware\LogMiddleware;
Route::group(function () {
//商户权限管理
Route::group('merchant/menu', function () {
Route::get('index', '/index')->name('systemMerchantMenuIndex')->option([
'_alias' => '商户菜单/权限表单',
'_auth' => false,
'_form' => 'systemMerchantMenuIndex',
]);
Route::get('lst', '/lst')->name('systemMerchantMenuGetLst')->append(['merchant' => 1])->option([
'_alias' => '商户菜单/权限列表',
]);
Route::post('add', '/add')->name('systemMerchantMenuCreate')->append(['merchant' => 1])->option([
'_alias' => '商户菜单/权限添加',
]);
Route::post('edit/:id', '/edit')->name('systemMerchantMenuUpdate')->append(['merchant' => 1])->option([
'_alias' => '商户菜单/权限编辑',
]);
Route::get('addform', '/AddForm')->name('systemMerchantMenuCreateForm')->append(['merchant' => 1])->option([
'_alias' => '商户菜单/权限添加表单',
'_auth' => false,
'_form' => 'systemMerchantMenuCreate',
]);
Route::get('editform', '/editform')->name('systemMerchantMenuUpdateForm')->append(['merchant' => 1])->option([
'_alias' => '商户菜单/权限编辑表单',
'_auth' => false,
'_form' => 'systemMerchantMenuUpdate',
]);
Route::delete('del/:id', '/del')->name('systemMerchantMenuDelete')->append(['merchant' => 1])->option([
'_alias' => '商户菜单/权限删除',
]);
})->prefix('merchant.system.auth.Menu')->option([
'_path' => '/merchant/menu',
'_auth' => true,
]);
});
// ->middleware(AllowOriginMiddleware::class)
// ->middleware(AdminTokenMiddleware::class, true)
// ->middleware(AdminAuthMiddleware::class)
// ->middleware(LogMiddleware::class);