正在显示
2 个修改的文件
包含
22 行增加
和
0 行删除
@@ -41,6 +41,28 @@ class Order extends Api | @@ -41,6 +41,28 @@ class Order extends Api | ||
41 | } | 41 | } |
42 | 42 | ||
43 | /** | 43 | /** |
44 | + * 我的订单-订单数量 | ||
45 | + * @ApiMethod (GET) | ||
46 | + * @ApiHeaders (name=token, type=string, required=true, description="请求的Token") | ||
47 | + * @ApiReturnParams (name="code", type="integer", required=true, sample="0") | ||
48 | + * @ApiReturnParams (name="msg", type="string", required=true, sample="返回成功") | ||
49 | + * @ApiReturnParams (name="data", type="object", description="扩展数据返回") | ||
50 | + * @ApiReturn ({ | ||
51 | + 'code':'1', | ||
52 | + 'msg':'返回成功' | ||
53 | + }) | ||
54 | + */ | ||
55 | + public function getOrderNum() | ||
56 | + { | ||
57 | + $this->success(__('成功'),[ | ||
58 | + 'payment_num' => count($this->model->getList($this->user['id'], 'payment')), | ||
59 | + 'delivery_num' => count($this->model->getList($this->user['id'], 'delivery')), | ||
60 | + 'receive_num' => count($this->model->getList($this->user['id'], 'receive')), | ||
61 | + 'appraise_num' => count($this->model->getList($this->user['id'], 'appraise')), | ||
62 | + ]); | ||
63 | + } | ||
64 | + | ||
65 | + /** | ||
44 | * 我的订单-修改地址 | 66 | * 我的订单-修改地址 |
45 | * @ApiMethod (GET) | 67 | * @ApiMethod (GET) |
46 | * @ApiHeaders (name=token, type=string, required=true, description="请求的Token") | 68 | * @ApiHeaders (name=token, type=string, required=true, description="请求的Token") |
此 diff 太大无法显示。
-
请 注册 或 登录 后发表评论