api.php 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519
  1. <?php
  2. use Illuminate\Http\Request;
  3. /*
  4. |--------------------------------------------------------------------------
  5. | API Routes
  6. |--------------------------------------------------------------------------
  7. |
  8. | Here is where you can register API routes for your application. These
  9. | routes are loaded by the RouteServiceProvider within a group which
  10. | is assigned the "api" middleware group. Enjoy building your API!
  11. |
  12. */
  13. //Route::middleware('auth:api')->get('/user', function (Request $request) {
  14. // return $request->user();
  15. //});
  16. //
  17. $api = app('Dingo\Api\Routing\Router');
  18. $api->version('v1', ['namespace' => 'App\Http\Controllers\Api\V1'], function ($api) {
  19. $api->post('attachment/upload', [
  20. 'as' => 'attachment.upload',
  21. 'uses' => 'AttachmentController@upload',
  22. ]);
  23. $api->post('attachment/delete', [
  24. 'as' => 'attachment.delete',
  25. 'uses' => 'AttachmentController@delete',
  26. ]);
  27. $api->get('shop2', [
  28. 'as' => 'shop2',
  29. 'uses' => 'AuthController@shop2',
  30. ]);
  31. $api->post('auth/login', [
  32. 'as' => 'auth.login',
  33. 'uses' => 'AuthController@login',
  34. ]);
  35. $api->get('home/index', [
  36. 'as' => 'home.index',
  37. 'uses' => 'HomeController@index',
  38. ]);
  39. $api->get('home/search', [
  40. 'as' => 'home.search',
  41. 'uses' => 'HomeController@search',
  42. ]);
  43. $api->get('cate/index', [
  44. 'as' => 'cate.index',
  45. 'uses' => 'CateController@index',
  46. ]);
  47. $api->get('goods/show', [
  48. 'as' => 'goods.show',
  49. 'uses' => 'GoodsController@show',
  50. ]);
  51. $api->post('goods/comment', [
  52. 'as' => 'goods.comment',
  53. 'uses' => 'GoodsController@comment',
  54. ]);
  55. $api->get('goods/addtocar', [
  56. 'as' => 'goods.addtocar',
  57. 'uses' => 'GoodsController@addToCar',
  58. ]);
  59. $api->get('goods/chose_attr', [
  60. 'as' => 'goods.chose_attr',
  61. 'uses' => 'GoodsController@choseAttr',
  62. ]);
  63. $api->get('goods/collection', [
  64. 'as' => 'goods.collection',
  65. 'uses' => 'GoodsController@collection',
  66. ]);
  67. $api->get('car/index', [
  68. 'as' => 'car.index',
  69. 'uses' => 'CarController@index',
  70. ]);
  71. $api->get('car/delete', [
  72. 'as' => 'car.delete',
  73. 'uses' => 'CarController@delete',
  74. ]);
  75. $api->post('car/update', [
  76. 'as' => 'car.update',
  77. 'uses' => 'CarController@update',
  78. ]);
  79. $api->get('find/index', [
  80. 'as' => 'find.index',
  81. 'uses' => 'FindController@index',
  82. ]);
  83. $api->get('my/index', [
  84. 'as' => 'my.index',
  85. 'uses' => 'MyController@index',
  86. ]);
  87. $api->get('my/favorite', [
  88. 'as' => 'my.favorite',
  89. 'uses' => 'MyController@favorite',
  90. ]);
  91. $api->get('my/address/index', [
  92. 'as' => 'address.index',
  93. 'uses' => 'AddressController@index',
  94. ]);
  95. $api->get('my/address/area', [
  96. 'as' => 'address.area',
  97. 'uses' => 'AddressController@area',
  98. ]);
  99. $api->get('my/address/show', [
  100. 'as' => 'address.show',
  101. 'uses' => 'AddressController@show',
  102. ]);
  103. $api->post('my/address/update', [
  104. 'as' => 'address.update',
  105. 'uses' => 'AddressController@update',
  106. ]);
  107. /* $api->post('my/address/store', [
  108. 'as' => 'address.store',
  109. 'uses' => 'AddressController@store',
  110. ]);*/
  111. $api->get('my/address/delete', [
  112. 'as' => 'address.delete',
  113. 'uses' => 'AddressController@delete',
  114. ]);
  115. $api->get('my/address/edit', [
  116. 'as' => 'address.edit',
  117. 'uses' => 'AddressController@edit',
  118. ]);
  119. $api->get('order/sure', [
  120. 'as' => 'order.sure',
  121. 'uses' => 'OrderController@sure',
  122. ]);
  123. $api->get('order/create', [
  124. 'as' => 'order.create',
  125. 'uses' => 'OrderController@create',
  126. ]);
  127. $api->get('order/show', [
  128. 'as' => 'order.show',
  129. 'uses' => 'OrderController@show',
  130. ]);
  131. $api->post('order/pay', [
  132. 'as' => 'order.pay',
  133. 'uses' => 'OrderController@pay',
  134. ]);
  135. $api->post('order/refund', [
  136. 'as' => 'order.refund',
  137. 'uses' => 'OrderController@refund',
  138. ]);
  139. $api->get('company/info', [
  140. 'as' => 'company.info',
  141. 'uses' => 'CompanyController@companyInfo',
  142. ]);
  143. $api->get('company/version', [
  144. 'as' => 'company.version',
  145. 'uses' => 'CompanyController@version',
  146. ]);
  147. $api->get('card/index', [
  148. 'as' => 'card.index',
  149. 'uses' => 'CardController@cardIndex',
  150. ]);
  151. $api->get('card/info', [
  152. 'as' => 'card.info',
  153. 'uses' => 'CardController@cardUserInfo',
  154. ]);
  155. $api->get('card/progress', [
  156. 'as' => 'card.progress',
  157. 'uses' => 'CardController@cardUserProgress',
  158. ]);
  159. $api->get('card/honor', [
  160. 'as' => 'card.honor',
  161. 'uses' => 'CardController@cardUserHonor',
  162. ]);
  163. $api->get('card/setting', [
  164. 'as' => 'card.setting',
  165. 'uses' => 'CardController@cardSetting',
  166. ]);
  167. $api->get('card/project', [
  168. 'as' => 'card.project',
  169. 'uses' => 'CardController@cardUserProject',
  170. ]);
  171. $api->get('card/projectDetail', [
  172. 'as' => 'card.projectDetail',
  173. 'uses' => 'CardController@projectDetail',
  174. ]);
  175. $api->get('card/trend', [
  176. 'as' => 'card.trend',
  177. 'uses' => 'CardController@CardUserTrend',
  178. ]);
  179. $api->get('card/trendDetail', [
  180. 'as' => 'card.trendDetail',
  181. 'uses' => 'CardController@trendDetail',
  182. ]);
  183. $api->get('album/setting', [
  184. 'as' => 'album.setting',
  185. 'uses' => 'AlbumController@albumSetting',
  186. ]);
  187. $api->get('album/cat', [
  188. 'as' => 'album.cat',
  189. 'uses' => 'AlbumController@albumCat',
  190. ]);
  191. $api->get('album/goods', [
  192. 'as' => 'album.goods',
  193. 'uses' => 'AlbumController@albumGoods',
  194. ]);
  195. $api->get('album/goods-detail', [
  196. 'as' => 'album.goods-detail',
  197. 'uses' => 'AlbumController@albumGoodsDetail',
  198. ]);
  199. $api->get('album/set-price', [
  200. 'as' => 'album.set-price',
  201. 'uses' => 'AlbumController@albumSetPrice',
  202. ]);
  203. $api->post('album/xyx_login', [
  204. 'as' => 'album.xyx_login',
  205. 'uses' => 'AlbumController@albumXyxLogin',
  206. ]);
  207. $api->post('album/login', [
  208. 'as' => 'album.login',
  209. 'uses' => 'AlbumController@albumXcxLogin',
  210. ]);
  211. $api->get('album/checklogin', [
  212. 'as' => 'album.checklogin',
  213. 'uses' => 'AlbumController@albumchecklogin',
  214. ]);
  215. $api->post('album/agent_price_set', [
  216. 'as' => 'album.AgentPriceSet',
  217. 'uses' => 'AlbumController@albumAgentPriceSet',
  218. ]);
  219. $api->get('album/get-banner', [
  220. 'as' => 'album.GetBanner',
  221. 'uses' => 'AlbumController@albumGetBanner',
  222. ]);
  223. $api->get('album/content_list', [
  224. 'as' => 'album.content_list',
  225. 'uses' => 'AlbumController@albumContentList',
  226. ]);
  227. $api->get('album/content_detail', [
  228. 'as' => 'album.content_detail',
  229. 'uses' => 'AlbumController@albumContentDetail',
  230. ]);
  231. $api->get('album/style', [
  232. 'as' => 'album.style',
  233. 'uses' => 'AlbumController@albumStyle',
  234. ]);
  235. $api->post('album/set-phone', [
  236. 'as' => 'album.savePhone',
  237. 'uses' => 'AlbumController@albumSavePhone',
  238. ]);
  239. $api->post('album/set-phone', [
  240. 'as' => 'album.savePhone',
  241. 'uses' => 'AlbumController@albumSavePhone',
  242. ]);
  243. $api->post('album/add_agent', [
  244. 'as' => 'album.AddAgent',
  245. 'uses' => 'AlbumController@albumAddAgent',
  246. ]);
  247. $api->post('album/get-cart-of-watch', [
  248. 'as' => 'album.GetCartOfWatch',
  249. 'uses' => 'AlbumController@albumGetCartOfWatch',
  250. ]);
  251. $api->post('album/get-watch-recored', [
  252. 'as' => 'album.GetWatchRecord',
  253. 'uses' => 'AlbumController@albumGetWatchRecord',
  254. ]);
  255. $api->post('album/set-watch', [
  256. 'as' => 'album.SetWatch',
  257. 'uses' => 'AlbumController@albumSetWatch',
  258. ]);
  259. $api->post('album/save_form_id', [
  260. 'as' => 'album.SaveFormId',
  261. 'uses' => 'AlbumController@albumSaveFormId',
  262. ]);
  263. $api->get('album/search_goods', [
  264. 'as' => 'album.search_goods',
  265. 'uses' => 'AlbumController@albumSearchGoods',
  266. ]);
  267. $api->get('album/add_favorite', [
  268. 'as' => 'album.add_favorite',
  269. 'uses' => 'AlbumController@albumAddFavorite',
  270. ]);
  271. $api->get('album/get-agent-address', [
  272. 'as' => 'album.get-agent-address',
  273. 'uses' => 'AlbumController@albumGetAgentAdress',
  274. ]);
  275. $api->get('album/test', [
  276. 'as' => 'album.test',
  277. 'uses' => 'AlbumController@test',
  278. ]);
  279. $api->post('album/get_data_goods', [
  280. 'as' => 'album.get_data_goods',
  281. 'uses' => 'AlbumController@albumGetDataGoods',
  282. ]);
  283. $api->post('album_post/info', [
  284. 'as' => 'album_post.info',
  285. 'uses' => 'AlbumPosterController@posterInfo',
  286. ]);
  287. $api->post('album_post/create', [
  288. 'as' => 'album_post.create',
  289. 'uses' => 'AlbumPosterController@createPoster',
  290. ]);
  291. $api->post('album_post/del', [
  292. 'as' => 'album_post.del',
  293. 'uses' => 'AlbumPosterController@posterDel',
  294. ]);
  295. $api->get('album/get-customer', [
  296. 'as' => 'album.get-customer',
  297. 'uses' => 'AlbumController@albumGetCustomer',
  298. ]);
  299. $api->post('album/set-customer', [
  300. 'as' => 'album.set-customer',
  301. 'uses' => 'AlbumController@albumSetCustomer',
  302. ]);
  303. $api->post('album/statistical', [
  304. 'as' => 'album.statistical',
  305. 'uses' => 'AlbumController@albumStatistical',
  306. ]);
  307. $api->post('album/get_statistical', [
  308. 'as' => 'album.get_statistical',
  309. 'uses' => 'AlbumController@albumGetStatistical',
  310. ]);
  311. $api->post('album/get_data_cat', [
  312. 'as' => 'album.get_data_cat',
  313. 'uses' => 'AlbumController@albumGetDataCat',
  314. ]);
  315. $api->post('album/get_data_cat_single', [
  316. 'as' => 'album.get_data_cat_single',
  317. 'uses' => 'AlbumController@albumGetDataCatSingle',
  318. ]);
  319. $api->get('album/favorite_list', [
  320. 'as' => 'album.favorite_list',
  321. 'uses' => 'AlbumController@albumFavoriteList',
  322. ]);
  323. $api->get('album/favorite_del', [
  324. 'as' => 'album.favorite_del',
  325. 'uses' => 'AlbumController@albumFavoriteDel',
  326. ]);
  327. $api->get('album/get_user_info', [
  328. 'as' => 'album.get_user_info',
  329. 'uses' => 'AlbumController@albumGetUserInfo',
  330. ]);
  331. $api->get('furniture/setting', [
  332. 'as' => 'furniture.setting',
  333. 'uses' => 'FurnitureController@furnitureSetting',
  334. ]);
  335. $api->any('furniture/add_comments', [
  336. 'as' => 'furniture.add_comments',
  337. 'uses' => 'FurnitureController@furnitureAddComments',
  338. ]);
  339. $api->get('furniture/news_detail', [
  340. 'as' => 'furniture.detail',
  341. 'uses' => 'FurnitureController@furnitureNewsDetail',
  342. ]);
  343. $api->get('furniture/news_list', [
  344. 'as' => 'furniture.list',
  345. 'uses' => 'FurnitureController@furnitureNewsList',
  346. ]);
  347. $api->post('furniture/xcx_login', [
  348. 'as' => 'furniture.xcx_login',
  349. 'uses' => 'FurnitureController@furnitureXcxLogin',
  350. ]);
  351. $api->get('furniture/goods_list', [
  352. 'as' => 'furniture.goodslist',
  353. 'uses' => 'FurnitureController@furnitureGoodsList',
  354. ]);
  355. $api->post('album/customer-goods',[
  356. 'as' => 'album/customer-goods',
  357. 'uses' => 'AlbumController@albumCustomerGoods'
  358. ]);
  359. $api->post('album/customer-goods-detail',[
  360. 'as' => 'album/customer-goods-detail',
  361. 'uses' => 'AlbumController@albumCustomerGoodsDetail'
  362. ]);
  363. $api->post('album/get-count-favorite',[
  364. 'as' => 'album/get-count-favorite',
  365. 'uses' => 'AlbumController@albumGetCountOfFavorite'
  366. ]);
  367. $api->get('furniture/getattr', [
  368. 'as' => 'furniture.getattr',
  369. 'uses' => 'FurnitureController@getAttr',
  370. ]);
  371. $api->post('furniture/createorder', [
  372. 'as' => 'furniture.createOrder',
  373. 'uses' => 'FurnitureController@createOrder',
  374. ]);
  375. $api->get('furniture/getorder', [
  376. 'as' => 'furniture.getorder',
  377. 'uses' => 'FurnitureController@getOrder',
  378. ]);
  379. $api->get('furniture/getorderdetail', [
  380. 'as' => 'furniture.getOrderDetail',
  381. 'uses' => 'FurnitureController@getOrderDetail',
  382. ]);
  383. $api->get('furniture/getprogress', [
  384. 'as' => 'furniture.getprogress',
  385. 'uses' => 'FurnitureController@getProgress',
  386. ]);
  387. $api->get('furniture/getreviewcount', [
  388. 'as' => 'furniture.getreviewcount',
  389. 'uses' => 'FurnitureController@getReviewCount',
  390. ]);
  391. $api->post('furniture/addreview', [
  392. 'as' => 'furniture.addreview',
  393. 'uses' => 'FurnitureController@addReview',
  394. ]);
  395. $api->post('furniture/service_login', [
  396. 'as' => 'furniture.service_login',
  397. 'uses' => 'FurnitureController@serviceLogin',
  398. ]);
  399. $api->get('furniture/getfurnitureads', [
  400. 'as' => 'furniture.getfurnitureads',
  401. 'uses' => 'FurnitureController@getFurnitureAds',
  402. ]);
  403. $api->post('furniture/updatestatus', [
  404. 'as' => 'furniture.updateStatus',
  405. 'uses' => 'FurnitureController@updateStatus',
  406. ]);
  407. $api->post('furniture/getphonenumber', [
  408. 'as' => 'furniture.getPhoneNumber',
  409. 'uses' => 'FurnitureController@getPhoneNumber',
  410. ]);
  411. $api->get('furniture/getqrcode', [
  412. 'as' => 'furniture.getQrcode',
  413. 'uses' => 'FurnitureController@getQrcode',
  414. ]);
  415. $api->get('furniture/ordercount', [
  416. 'as' => 'furniture.orderCount',
  417. 'uses' => 'FurnitureController@orderCount',
  418. ]);
  419. $api->get('furniture/searchlist', [
  420. 'as' => 'furniture.searchList',
  421. 'uses' => 'FurnitureController@searchList',
  422. ]);
  423. $api->any('furniture/printorder', [
  424. 'as' => 'furniture.printOrder',
  425. 'uses' => 'FurnitureController@printOrder',
  426. ]);
  427. $api->post('furniture/saveformid', [
  428. 'as' => 'furniture.saveFormId',
  429. 'uses' => 'FurnitureController@saveFormId',
  430. ]);
  431. $api->get('furniture/getmorecomments', [
  432. 'as' => 'furniture.getMoreComments',
  433. 'uses' => 'FurnitureController@getMoreComments',
  434. ]);
  435. $api->get('furniture/addtolike', [
  436. 'as' => 'furniture.addtolike',
  437. 'uses' => 'FurnitureController@addToLike',
  438. ]);
  439. $api->get('furniture/newgoods_list', [
  440. 'as' => 'furniture.newgoods_list',
  441. 'uses' => 'FurnitureController@newgoods_list',
  442. ]);
  443. $api->get('furniture/newgoods_index', [
  444. 'as' => 'furniture.newgoods_index',
  445. 'uses' => 'FurnitureController@newgoods_index',
  446. ]);
  447. $api->post('furniture/newgoods_addcomment', [
  448. 'as' => 'furniture.newgoods_addcomment',
  449. 'uses' => 'FurnitureController@newgoods_addcomment',
  450. ]);
  451. $api->post('furniture/newgoods_addbooking', [
  452. 'as' => 'furniture.newgoods_addbooking',
  453. 'uses' => 'FurnitureController@newgoods_addbooking',
  454. ]);
  455. /*
  456. * AlbumBoss
  457. */
  458. $api->get('album_boss/get_top', [
  459. 'as' => 'album_boss.get_top',
  460. 'uses' => 'AlbumBossController@getTop',
  461. ]);
  462. $api->post('album_boss/agent_customer', [
  463. 'as' => 'album_boss.agent_customer',
  464. 'uses' => 'AlbumBossController@agentCustomer',
  465. ]);
  466. $api->post('album_boss/agent_statistical', [
  467. 'as' => 'album_boss.agent_statistical',
  468. 'uses' => 'AlbumBossController@agentStatistical',
  469. ]);
  470. $api->post('album_boss/agent_overview', [
  471. 'as' => 'album_boss.agent_overview',
  472. 'uses' => 'AlbumBossController@albumOverview',
  473. ]);
  474. });