From 2055d020d333efcd7ace558289aa59690c41a4fe Mon Sep 17 00:00:00 2001 From: sugar1569 Date: Wed, 22 Nov 2023 14:53:36 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E7=A8=8B=E5=BA=8F=E7=9B=AE=E5=BD=95?= =?UTF-8?q?=E3=80=91=E6=B7=BB=E5=8A=A0demo=E7=A4=BA=E4=BE=8B=E8=B7=AF?= =?UTF-8?q?=E7=94=B1=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * commit 'f3234cbb6ad8161c8c15c6224ac96fe7f1761393': (36 commits) 【程序目录】优化安装提示文字 【程序目录】更新v5.2.1版本 【程序目录】更新v5.2.1版本 【程序目录】更新v5.2.1版本 【模版目录】更新v5.2.1版本 【程序目录】更新v5.2.1版本 【模版目录】更新v5.2.1版本 【程序目录】更新v5.2.1版本 【程序目录】优化用户读取 【程序文档】更新 【程序目录】更新优化 【程序目录】优化图片下载 【程序目录】更新5.2 readme 修改docker容器内无法连接外网的问题 【程序目录】更新5.2 【程序目录】更新5.2 【程序目录】更新5.2 【程序目录】更新5.2 update README.md. 【程序文档】更新5.2 ... # Conflicts: # .gitignore # README.md # crmeb/app/adminapi/controller/UpgradeController.php # crmeb/app/adminapi/controller/v1/order/StoreOrder.php # crmeb/app/adminapi/controller/v1/setting/SystemConfig.php # crmeb/app/services/activity/combination/StoreCombinationServices.php # crmeb/app/services/agent/AgentLevelServices.php # crmeb/app/services/product/product/CopyTaobaoServices.php # crmeb/app/services/user/UserRechargeServices.php # crmeb/app/services/user/UserSignServices.php # crmeb/crmeb/services/FileService.php # crmeb/crmeb/services/SystemConfigService.php # crmeb/crmeb/utils/DownloadImage.php # crmeb/public/admin/system_static/css/chunk-vendors.d4d844e5.css # crmeb/public/install/crmeb.sql # template/admin/package-lock.json # template/admin/package.json # template/admin/src/App.vue # template/admin/src/api/order.js # template/admin/src/components/cards/cards.vue # template/admin/src/components/customerInfo/index.vue # template/admin/src/components/freightTemplate/city.vue # template/admin/src/components/from/from.vue # template/admin/src/components/linkaddress/index.vue # template/admin/src/components/mobileConfigRightDiy/c_set_up.vue # template/admin/src/components/mobileConfigRightDiy/c_tab.vue # template/admin/src/components/uploadImg/index.vue # template/admin/src/components/uploadPictures/index.vue # template/admin/src/components/wangEditor/index.vue # template/admin/src/layout/navBars/breadcrumb/search.vue # template/admin/src/layout/navBars/breadcrumb/setings.vue # template/admin/src/layout/navMenu/vertical.vue # template/admin/src/main.js # template/admin/src/pages/account/login/index.vue # template/admin/src/pages/app/wechat/menus/index.vue # template/admin/src/pages/cms/addArticle/index.vue # template/admin/src/pages/cms/articleCategory/index.vue # template/admin/src/pages/finance/billingRecords/index.vue # template/admin/src/pages/finance/commission/handle/commissionDetails.vue # template/admin/src/pages/finance/commission/index.vue # template/admin/src/pages/index/components/baseInfo.vue # template/admin/src/pages/index/components/gridMenu.vue # template/admin/src/pages/index/components/visitChart.vue # template/admin/src/pages/kefu/appChat/feedback.vue # template/admin/src/pages/kefu/pc/components/baseHeader.vue # template/admin/src/pages/kefu/pc/index.vue # template/admin/src/pages/marketing/live/index.vue # template/admin/src/pages/marketing/lottery/create.vue # template/admin/src/pages/marketing/recharge/index.vue # template/admin/src/pages/marketing/sign/index.vue # template/admin/src/pages/marketing/sign/rewards.vue # template/admin/src/pages/marketing/storeBargain/create.vue # template/admin/src/pages/marketing/storeCombination/create.vue # template/admin/src/pages/marketing/storeCouponIssue/create.vue # template/admin/src/pages/marketing/storeCouponIssue/index.vue # template/admin/src/pages/marketing/storeSeckill/create.vue # template/admin/src/pages/notify/smsConfig/tableList.vue # template/admin/src/pages/order/invoice/index.vue # template/admin/src/pages/order/offline/index.vue # template/admin/src/pages/order/orderList/components/tableList.vue # template/admin/src/pages/order/orderList/handle/orderDetails.vue # template/admin/src/pages/order/orderList/handle/orderSend.vue # template/admin/src/pages/order/orderList/index.vue # template/admin/src/pages/order/orderList/orderListDetails.vue # template/admin/src/pages/product/productAdd/index.vue # template/admin/src/pages/product/productAttr/addAttr.vue # template/admin/src/pages/product/productList/index.vue # template/admin/src/pages/setting/agreement/index.vue # template/admin/src/pages/setting/devise/diyIndex.vue # template/admin/src/pages/setting/devise/list.vue # template/admin/src/pages/setting/devise/users.vue # template/admin/src/pages/setting/multiLanguage/langList.vue # template/admin/src/pages/setting/notification/index.vue # template/admin/src/pages/setting/setSystem/index.vue # template/admin/src/pages/setting/storage/index.vue # template/admin/src/pages/setting/storeList/index.vue # template/admin/src/pages/setting/systemRole/index.vue # template/admin/src/pages/setting/themeStyle/index.vue # template/admin/src/pages/statistic/product/components/goodsDetail.vue # template/admin/src/pages/statistic/product/components/productRanking.vue # template/admin/src/pages/statistic/transaction/components/toDay.vue # template/admin/src/pages/statistic/transaction/components/transaction.vue # template/admin/src/pages/system/backendRouting/index.vue # template/admin/src/pages/system/clear/index.vue # template/admin/src/pages/system/codeGeneration/components/TableForm.vue # template/admin/src/pages/system/crontab/index.vue # template/admin/src/pages/system/file/index.vue # template/admin/src/pages/system/group/pc.vue # template/admin/src/pages/system/group/visualization.vue # template/admin/src/pages/system/maintain/systemDatabackup/index.vue # template/admin/src/pages/user/grade/card/index.vue # template/admin/src/pages/user/grade/right/index.vue # template/admin/src/pages/user/list/handle/userDetails.vue # template/admin/src/pages/user/list/index.vue # template/admin/src/styles/index.less # template/admin/src/styles/style.css # template/admin/src/styles/style.less # template/admin/src/styles/style.scss # template/admin/src/theme/app.scss # template/admin/src/theme/element.scss # template/admin/src/theme/variables.scss # template/uni-app/components/cartList/index.vue # template/uni-app/components/catGoodList/index.vue # template/uni-app/components/privacyAgreementPopup/index.vue # template/uni-app/components/productWindow/index.vue # template/uni-app/libs/login.js # template/uni-app/libs/wechat.js # template/uni-app/pages.json # template/uni-app/pages/annex/settled/index.vue # template/uni-app/pages/goods_cate/goods_cate2.vue # template/uni-app/pages/goods_cate/goods_cate3.vue # template/uni-app/pages/users/binding_phone/index.vue # template/uni-app/pages/users/components/verify/verifyPoint/verifyPoint.vue # template/uni-app/pages/users/user_phone/index.vue --- crmeb/app/adminapi/route/demo.php | 85 +++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 crmeb/app/adminapi/route/demo.php diff --git a/crmeb/app/adminapi/route/demo.php b/crmeb/app/adminapi/route/demo.php new file mode 100644 index 000000000..b49687ef0 --- /dev/null +++ b/crmeb/app/adminapi/route/demo.php @@ -0,0 +1,85 @@ + +// +---------------------------------------------------------------------- +use think\facade\Route; + +/** + * 应用模块 路由示例 + * 注意: + * 1. 路由示例只做参考,请根据实际情况修改 + * 2. 如果需要使用路由中间件,请在路由前面加上中间件名称,如:middleware(\app\middleware\ApiAuthMiddleware::class) + * 3. 如果需要使用路由参数,请在路由后面加上参数,如:'id' => '\d+', 多个参数用英文逗号分隔 + * 4. 如果需要使用路由别名,请在路由后面加上别名,如:'id' => 'user_id', 多个参数用英文逗号分隔 + * 5. 如果需要使用路由变量,请在路由后面加上变量,如:':id' => '\ + * 6. 如果需要使用路由正则,请在路由后面加上正则,如:':id' => '/ + * 严格按照这种方法写,可以快速生成接口文档和添加接口权限设置 + */ +Route::group('demo', function () { + + /** 路由示例 */ + Route::group('路由示例',function () { + //get请求路由,第一参数为路由地址,第二参数为处理函数 目录:app/controller/v1/application/wechat/menus + Route::get('wechat/demo1', 'v1.application.wechat.menus/index')->option([ + 'real_name' => '微信公众号菜单列表' //接口名称 + ]); + //post请求路由,第一参数为路由地址,第二参数为处理函数 目录:app/controller/v1/application/wechat/menus + Route::post('wechat/demo2', 'v1.application.wechat.menus/save')->option([ + 'real_name' => '保存微信公众号菜单' //接口名称 + ]); + //delete请求路由,第一参数为路由地址,第二参数为处理函数 目录:app/controller/v1/application/wechat/menus + Route::delete('wechat/demo3/:id', 'v1.application.wechat.menus/delete')->option([ + 'real_name' => '删除图文' //接口名称 + ]); + //put请求路由,第一参数为路由地址,第二参数为处理函数 目录:app/controller/v1/application/wechat/menus + Route::put('wechat/demo3/:id', 'v1.application.wechat.menus/save')->option([ + 'real_name' => '编辑图文' //接口名称 + ]); + + //资源路由可以快速创建增删改查路由 客服反馈接口 第一参数为路由地址,第二参数为处理函数 目录:app/controller/v1/kefu/StoreServiceFeedback + Route::resource('feedback', 'v1.kefu.StoreServiceFeedback')->only([ //只允许index read edit update 四个操作 + //GET请求 对应方法index + 'index', + //DELETE请求 对应方法delete + // 'delete', + //POST请求 对应方法save + 'save', + //GET请求 对应方法read + 'read', + //POST请求 对应方法create + // 'create', + //PUT请求 对应方法update + 'update', + //GET请求 对应方法edit + 'edit' + ])->option([ + 'real_name' => [//接口名称 + 'index' => '获取用户反馈列表', + // 'delete' => '删除用户反馈列表', + 'save' => '保存用户反馈列表', + 'read' => '获取用户反馈', + // 'create' => '添加用户反馈列表', + 'update' => '修改用户反馈', + 'edit' => '获取修改用户反馈表单', + ] + ]); + })->option([ + 'parent' => 'app', //父级路由 + 'cate_name' => '公众号' //分组名称 + ]); + +})->middleware([//中间件 + \app\http\middleware\AllowOriginMiddleware::class, //允许跨域 + \app\adminapi\middleware\AdminAuthTokenMiddleware::class, //后台管理员认证 + \app\adminapi\middleware\AdminCheckRoleMiddleware::class, //后台管理员角色检测 + \app\adminapi\middleware\AdminLogMiddleware::class //后台管理员日志 +])->option([ + 'mark' => 'demo', //标记 + 'mark_name' => 'demo演示' //标记名称 +]);