shopApi

商城API项目


订单详情路由

<h5>接口描述</h5> <ul> <li>订单详情模板</li> </ul> <h5>请求URL</h5> <ul> <li><code>/api/admin/orders/{order}</code></li> </ul> <h5>请求方式</h5> <ul> <li>GET</li> </ul> <h5>请求头部</h5> <p>|参数名|必选|类型|说明| |:----    |:---|:----- |-----   | |Authorization |是  |string |JWT token|</p> <h5>Query 请求参数</h5> <p>|参数名|必选|类型|说明| |:----    |:---|:----- |-----   | |include |是  |string |user,orderDetails.goods   |</p> <h5>返回示例</h5> <ul> <li>状态码 200 请求成功</li> </ul> <pre><code>{     &amp;quot;data&amp;quot;: {         &amp;quot;id&amp;quot;: 1,         &amp;quot;user_id&amp;quot;: 1,         &amp;quot;order_no&amp;quot;: &amp;quot;20240331&amp;quot;,         &amp;quot;amount&amp;quot;: 100,         &amp;quot;status&amp;quot;: 2,         &amp;quot;address_id&amp;quot;: 1,         &amp;quot;express_type&amp;quot;: &amp;quot;SF&amp;quot;,         &amp;quot;express_no&amp;quot;: &amp;quot;240331&amp;quot;,         &amp;quot;pay_time&amp;quot;: &amp;quot;2024-03-31 20:39:28&amp;quot;,         &amp;quot;pay_type&amp;quot;: &amp;quot;微信&amp;quot;,         &amp;quot;trade_no&amp;quot;: &amp;quot;2024331&amp;quot;,         &amp;quot;created_at&amp;quot;: &amp;quot;2024-03-31T20:33:53.000000Z&amp;quot;,         &amp;quot;updated_at&amp;quot;: &amp;quot;2024-03-31T20:33:55.000000Z&amp;quot;,         &amp;quot;user&amp;quot;: {             &amp;quot;data&amp;quot;: {                 &amp;quot;id&amp;quot;: 1,                 &amp;quot;name&amp;quot;: &amp;quot;a&amp;quot;,                 &amp;quot;email&amp;quot;: &amp;quot;a@a.com&amp;quot;,                 &amp;quot;created_at&amp;quot;: null,                 &amp;quot;updated_at&amp;quot;: &amp;quot;2024-03-27T20:04:08.000000Z&amp;quot;             }         },         &amp;quot;orderDetails&amp;quot;: {             &amp;quot;data&amp;quot;: [                 {                     &amp;quot;id&amp;quot;: 1,                     &amp;quot;order_id&amp;quot;: 1,                     &amp;quot;goods_id&amp;quot;: 1,                     &amp;quot;price&amp;quot;: 50,                     &amp;quot;num&amp;quot;: 1,                     &amp;quot;created_at&amp;quot;: null,                     &amp;quot;updated_at&amp;quot;: null,                     &amp;quot;goods&amp;quot;: {                         &amp;quot;data&amp;quot;: {                             &amp;quot;id&amp;quot;: 1,                             &amp;quot;category_id&amp;quot;: 7,                             &amp;quot;description&amp;quot;: &amp;quot;这是一台电脑&amp;quot;,                             &amp;quot;price&amp;quot;: 4999,                             &amp;quot;stock&amp;quot;: 999,                             &amp;quot;cover&amp;quot;: &amp;quot;默认头像.jpg&amp;quot;,                             &amp;quot;cover_url&amp;quot;: &amp;quot;https://laravel-shop-api-study.oss-cn-hongkong.aliyuncs.com/默认头像.jpg&amp;quot;,                             &amp;quot;pics&amp;quot;: [                                 &amp;quot;a.png&amp;quot;,                                 &amp;quot;b.png&amp;quot;                             ],                             &amp;quot;pics_url&amp;quot;: [                                 &amp;quot;https://laravel-shop-api-study.oss-cn-hongkong.aliyuncs.com/a.png&amp;quot;,                                 &amp;quot;https://laravel-shop-api-study.oss-cn-hongkong.aliyuncs.com/b.png&amp;quot;                             ],                             &amp;quot;details&amp;quot;: &amp;quot;这是一台好用的电脑&amp;quot;,                             &amp;quot;title&amp;quot;: &amp;quot;电脑111&amp;quot;,                             &amp;quot;is_on&amp;quot;: 1,                             &amp;quot;is_recommend&amp;quot;: 1,                             &amp;quot;created_at&amp;quot;: &amp;quot;2024-03-30T09:18:17.000000Z&amp;quot;,                             &amp;quot;updated_at&amp;quot;: &amp;quot;2024-03-30T17:43:05.000000Z&amp;quot;                         }                     }                 },                 {                     &amp;quot;id&amp;quot;: 2,                     &amp;quot;order_id&amp;quot;: 1,                     &amp;quot;goods_id&amp;quot;: 2,                     &amp;quot;price&amp;quot;: 50,                     &amp;quot;num&amp;quot;: 1,                     &amp;quot;created_at&amp;quot;: null,                     &amp;quot;updated_at&amp;quot;: null,                     &amp;quot;goods&amp;quot;: {                         &amp;quot;data&amp;quot;: {                             &amp;quot;id&amp;quot;: 2,                             &amp;quot;category_id&amp;quot;: 7,                             &amp;quot;description&amp;quot;: &amp;quot;这是一台电脑&amp;quot;,                             &amp;quot;price&amp;quot;: 4999,                             &amp;quot;stock&amp;quot;: 999,                             &amp;quot;cover&amp;quot;: &amp;quot;/imgs/img/1.png&amp;quot;,                             &amp;quot;cover_url&amp;quot;: &amp;quot;https://laravel-shop-api-study.oss-cn-hongkong.aliyuncs.com//imgs/img/1.png&amp;quot;,                             &amp;quot;pics&amp;quot;: [                                 &amp;quot;a.png&amp;quot;,                                 &amp;quot;b.png&amp;quot;                             ],                             &amp;quot;pics_url&amp;quot;: [                                 &amp;quot;https://laravel-shop-api-study.oss-cn-hongkong.aliyuncs.com/a.png&amp;quot;,                                 &amp;quot;https://laravel-shop-api-study.oss-cn-hongkong.aliyuncs.com/b.png&amp;quot;                             ],                             &amp;quot;details&amp;quot;: &amp;quot;这是一台好用的电脑&amp;quot;,                             &amp;quot;title&amp;quot;: &amp;quot;电脑2&amp;quot;,                             &amp;quot;is_on&amp;quot;: 0,                             &amp;quot;is_recommend&amp;quot;: 0,                             &amp;quot;created_at&amp;quot;: &amp;quot;2024-03-30T09:18:21.000000Z&amp;quot;,                             &amp;quot;updated_at&amp;quot;: &amp;quot;2024-03-30T09:18:21.000000Z&amp;quot;                         }                     }                 }             ]         }     } }</code></pre> <ul> <li> <p>状态码 200 成功</p> </li> <li>状态码 422 参数错误</li> </ul>

页面列表

ITEM_HTML