From 8a388ccb5a8b15c7b130996cb024f4f899526f0b Mon Sep 17 00:00:00 2001 From: "ZLW-PC\\Administrator" <374861669@qq.com> Date: Tue, 27 Feb 2018 17:33:47 +0800 Subject: [PATCH] weixin page --- README.md | 6 +-- .../Controllers/Weixin/IndexController.php | 2 + resources/views/weixin/index/page.blade.php | 43 +++++++------------ .../views/weixin/user/register.blade.php | 2 +- routes/web.php | 4 +- 5 files changed, 24 insertions(+), 33 deletions(-) diff --git a/README.md b/README.md index 7316158..c378890 100644 --- a/README.md +++ b/README.md @@ -29,11 +29,11 @@ WAP端 注意:PC端跟微商城的域名是同一个域名,WAP端的域名通常是PC端的子域名,这里的案例PC端的域名是www.lqycms.com,WAP端的域名是m.lqycms.com -PC入口:http://+PC域名+/ +PC入口:http://+PC域名+/ -WAP入口:http://+WAP域名+/,WAP域名解析与PC域名一致,都是指向同一目录下 +WAP入口:http://+WAP域名+/,WAP域名解析与PC域名一致,都是指向同一目录下 -微商城入口:http://+PC域名+/weixin,支付仅支持微信支付。 +微商城入口:http://+PC域名+/weixin,支付仅支持微信支付。 6、后台功能 diff --git a/app/Http/Controllers/Weixin/IndexController.php b/app/Http/Controllers/Weixin/IndexController.php index e561789..41d8e93 100644 --- a/app/Http/Controllers/Weixin/IndexController.php +++ b/app/Http/Controllers/Weixin/IndexController.php @@ -159,6 +159,8 @@ class IndexController extends CommonController if($post) { + $post['body'] = preg_replace('/src=\"\/uploads\/allimg/',"src=\"".env('APP_URL')."/uploads/allimg",$post['body']); + $post['pubdate'] = date('Y-m-d',$post['pubdate']); $data['post'] = $post; } else diff --git a/resources/views/weixin/index/page.blade.php b/resources/views/weixin/index/page.blade.php index 409a394..fe26f48 100644 --- a/resources/views/weixin/index/page.blade.php +++ b/resources/views/weixin/index/page.blade.php @@ -1,30 +1,19 @@ - - -<?php if(empty($post["seotitle"])){echo $post["title"];}else{echo $post["seotitle"];} ?>_<?php echo sysconfig('CMS_WEBNAME'); ?> - - -@include('home.common.header') -
-
-
- - -

-
-
- - +@include('weixin.common.headerNav') + +

-
-@include('home.common.footer') \ No newline at end of file +
+
+@include('weixin.common.footer') + \ No newline at end of file diff --git a/resources/views/weixin/user/register.blade.php b/resources/views/weixin/user/register.blade.php index 97ab6b4..4538f2f 100644 --- a/resources/views/weixin/user/register.blade.php +++ b/resources/views/weixin/user/register.blade.php @@ -48,7 +48,7 @@ 提交
-已有账号 注册协议 +已有账号 注册协议


diff --git a/routes/web.php b/routes/web.php index f5b161d..16fbd7c 100644 --- a/routes/web.php +++ b/routes/web.php @@ -58,7 +58,7 @@ Route::group(['prefix' => 'weixin', 'namespace' => 'Weixin'], function () { Route::get('/category', 'IndexController@category')->name('weixin_category'); Route::get('/category_goods_list', 'GoodsController@categoryGoodsList')->name('weixin_category_goods_list'); //产品分类页 Route::get('/page404', 'IndexController@page404')->name('weixin_page404'); //404页面 - Route::get('/search', 'IndexController@search')->name('weixin_search'); //搜索页面 + Route::get('/search', 'IndexController@search')->name('weixin_search'); //搜索页面 Route::get('/p/{id}', 'ArticleController@detail')->name('weixin_article_detail'); //文章详情页 Route::get('/cat{cat}', 'ArticleController@category')->name('weixin_article_category'); //分类页 Route::get('/tag{tag}', 'IndexController@tag')->name('weixin_tag'); //标签页 @@ -68,7 +68,7 @@ Route::group(['prefix' => 'weixin', 'namespace' => 'Weixin'], function () { Route::get('/bonus_list', 'BonusController@bonusList')->name('weixin_bonus_list'); Route::any('/wxpay_notify', 'WxPayController@wxpayNotify')->name('weixin_wxpay_notify'); //微信回调 - Route::any('/wxoauth', 'UserController@oauth')->name('weixin_wxoauth'); //微信网页授权 + Route::any('/wxoauth', 'UserController@oauth')->name('weixin_wxoauth'); //微信网页授权 Route::any('/login', 'UserController@login')->name('weixin_login'); Route::any('/register', 'UserController@register')->name('weixin_register'); Route::get('/logout', 'UserController@logout')->name('weixin_user_logout'); //退出