shopxo/app/route/route.config

59 lines
2.1 KiB
Plaintext
Raw Normal View History

2018-12-31 19:07:03 +08:00
<?php
// +----------------------------------------------------------------------
// | ShopXO 国内领先企业级B2C免费开源电商系统
// +----------------------------------------------------------------------
2019-02-18 13:52:07 +08:00
// | Copyright (c) 2011~2019 http://shopxo.net All rights reserved.
2018-12-31 19:07:03 +08:00
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
// +----------------------------------------------------------------------
// | 路由规则
// +----------------------------------------------------------------------
2020-09-28 22:47:21 +08:00
use think\facade\Route;
2018-12-31 19:07:03 +08:00
// 分隔符
$ds = MyC('common_route_separator', '-', true);
// 商品详情
Route::get('goods'.$ds.':id', 'index/goods/index');
// 搜索
Route::rule('search', 'index/search/index', 'GET|POST');
2021-07-19 18:36:02 +08:00
Route::post('search-goods', 'index/search/goodslist');
2018-12-31 19:07:03 +08:00
// 分类
Route::get('category', 'index/category/index');
2018-12-31 19:15:48 +08:00
// 自定义页面
Route::get('custom'.$ds.':id', 'index/customview/index');
2018-12-31 19:07:03 +08:00
// 购物车
Route::get('cart', 'index/cart/index');
// 订单确认
Route::rule('buy', 'index/buy/index', 'GET|POST');
2021-07-19 18:36:02 +08:00
Route::post('buy-add', 'index/buy/add');
2018-12-31 19:07:03 +08:00
// 文章
Route::get('article-category'.$ds.'[:id]', 'index/article/category');
2018-12-31 19:07:03 +08:00
Route::get('article'.$ds.':id', 'index/article/index');
// 页面设计
Route::get('design'.$ds.':id', 'index/design/index');
2018-12-31 19:07:03 +08:00
// 用户
Route::get('login', 'index/user/logininfo');
Route::get('login'.$ds.'modal', 'index/user/modallogininfo');
2018-12-31 19:29:52 +08:00
Route::get('regster', 'index/user/reginfo');
Route::get('regster'.$ds.'sms', 'index/user/smsreginfo');
Route::get('regster'.$ds.'email', 'index/user/emailreginfo');
2018-12-31 19:07:03 +08:00
Route::get('forget', 'index/user/forgetpwdinfo');
Route::get('logout', 'index/user/logout');
2020-09-28 22:47:21 +08:00
// 插件调用
2020-11-18 11:18:12 +08:00
Route::rule(':pluginsname'.$ds.'[:pluginscontrol]'.$ds.'[:pluginsaction]'.$ds.'[:id]','index/plugins/index')->completeMatch();
2020-09-28 22:47:21 +08:00
Route::rule(':pluginsname'.$ds.':pluginscontrol'.$ds.':pluginsaction'.$ds.'[:id]','index/plugins/index');
2018-12-31 19:07:03 +08:00
?>