dyjh 6 년 전
부모
커밋
95f334befd
3개의 변경된 파일18개의 추가작업 그리고 1개의 파일을 삭제
  1. 13 0
      app/Http/Controllers/Api/V1/AlbumController.php
  2. 1 1
      app/Http/Controllers/Api/V1/Controller.php
  3. 4 0
      routes/api.php

+ 13 - 0
app/Http/Controllers/Api/V1/AlbumController.php

xqd
@@ -1681,6 +1681,19 @@ class AlbumController extends Controller
         }
     }
 
+    public function test()
+    {
+        $weChatApp = AlbumManufacturerModel::where('store_id', 1)->first();\Log::info('2221');
+        $config = [
+            'app_id' => $weChatApp->G_app_id,
+            'secret' => $weChatApp->G_app_secret,
+            'response_type' => 'array',
+        ];\Log::info('2224');
+        $app = Factory::officialAccount($config);
+        $text = new Text('111');dd($text);
+        $res_msg = $app->customer_service->message($text)->to('o_O0HuA4ugJG0npjLSL_Cd33FN8c')->send();\Log::info($res_msg);
+    }
+
     /**
      * @param $storeid
      * @param $open_id

+ 1 - 1
app/Http/Controllers/Api/V1/Controller.php

xqd
@@ -21,7 +21,7 @@ class Controller extends BaseController
 
         $this->middleware('auth:api', [
             'except' => [
-                'upload', 'getCode', 'reset', 'login', 'get', 'register', 'alipayNotify', 'wechatpayNotify', 'get', 'area', 'get_province', 'get_city', 'get_county', 'albumStyle', 'test', 'index', 'companyInfo', 'shop2', 'cardIndex', 'cardUserInfo', 'cardUserProgress', 'cardUserHonor', 'cardUserProject', 'CardUserTrend', 'projectDetail', 'trendDetail', 'albumSetting', 'albumXyxLogin', 'albumCat', 'albumchecklogin', 'albumGoods', 'albumGoodsDetail', 'albumSetPrice', 'albumXcxLogin', 'albumContentList', 'albumSearchGoods','albumContentDetail','albumFavoriteList','albumAddFavorite','albumFavoriteDel','getAttr','getOrder','getProgress','getReviewCount', 'furnitureNewsDetail','furnitureSetting','furnitureXcxLogin','furnitureGoodsList','serviceLogin','getFurnitureAds','getPhoneNumber','getQrcode','orderCount','searchList','printOrder','saveFormId','furnitureNewsList','getMoreComments','addToLike','albumSavePhone','albumGetStatistical',
+                'upload', 'getCode', 'reset', 'login', 'get', 'register', 'alipayNotify', 'wechatpayNotify', 'get', 'area', 'get_province', 'get_city', 'get_county', 'albumStyle', 'test', 'index', 'companyInfo', 'shop2', 'cardIndex', 'cardUserInfo', 'cardUserProgress', 'cardUserHonor', 'cardUserProject', 'CardUserTrend', 'projectDetail', 'trendDetail', 'albumSetting', 'albumXyxLogin', 'albumCat', 'albumchecklogin', 'albumGoods', 'albumGoodsDetail', 'albumSetPrice', 'albumXcxLogin', 'albumContentList', 'albumSearchGoods','albumContentDetail','albumFavoriteList','albumAddFavorite','albumFavoriteDel','getAttr','getOrder','getProgress','getReviewCount', 'furnitureNewsDetail','furnitureSetting','furnitureXcxLogin','furnitureGoodsList','serviceLogin','getFurnitureAds','getPhoneNumber','getQrcode','orderCount','searchList','printOrder','saveFormId','furnitureNewsList','getMoreComments','addToLike','albumSavePhone','albumGetStatistical','test',
                 'albumGetWatchRecord','albumSetWatch','albumGetCartOfWatch','albumSaveFormId','albumAddAgent','albumGetBanner','albumGetDataGoods','newgoods_list','newgoods_index','albumGetAgentAdress','albumSetCustomer','albumGetCustomer','albumGetDataCat','albumCustomerGoods','albumCustomerGoodsDetail','albumGetDataCatSingle','albumGetCountOfFavorite','albumGetUserInfo','albumStatistical','posterInfo','createPoster','posterDel'
             ]
         ]);

+ 4 - 0
routes/api.php

xqd
@@ -292,6 +292,10 @@ $api->version('v1', ['namespace' => 'App\Http\Controllers\Api\V1'], function ($a
         'as' => 'album.get-agent-address',
         'uses' => 'AlbumController@albumGetAgentAdress',
     ]);
+    $api->get('album/test', [
+        'as' => 'album.test',
+        'uses' => 'AlbumController@test',
+    ]);
 
     $api->post('album/get_data_goods', [
         'as' => 'album.get_data_goods',