|
@@ -24,9 +24,11 @@ use App\Models\SitePage;
|
|
|
*/
|
|
|
|
|
|
//巴西官网专用路由
|
|
|
-//$host = $_SERVER['HTTP_HOST']; // 获取当前域名
|
|
|
-//
|
|
|
-//if ($host == 'internal-demo-site.mietubl.com.cn') {
|
|
|
+$host = $_SERVER['HTTP_HOST']; // 获取当前域名
|
|
|
+
|
|
|
+if ($host == 'internal-demo-site.mietubl.com.cn') {
|
|
|
+ Route::get('/{slug}', [CollectionController::class, 'detail'])->name('collection.detail');
|
|
|
+
|
|
|
// Route::get('/{slug}', function ($slug) {
|
|
|
// // 查询数据库,将 category_slug 转换为对应ID
|
|
|
// $categoryId = DistProductCategory::where(function ($query) use ($slug) {
|
|
@@ -51,7 +53,8 @@ use App\Models\SitePage;
|
|
|
// $productController = new ProductController();
|
|
|
// return $productController->detail($slug);
|
|
|
// });
|
|
|
-//}
|
|
|
+
|
|
|
+}
|
|
|
|
|
|
|
|
|
|