正在显示
1 个修改的文件
包含
66 行增加
和
0 行删除
@@ -198,6 +198,7 @@ class UsersController extends HomeBaseController{ | @@ -198,6 +198,7 @@ class UsersController extends HomeBaseController{ | ||
198 | public function getOrder(){ | 198 | public function getOrder(){ |
199 | $users_id=$this->request->param('users_id'); | 199 | $users_id=$this->request->param('users_id'); |
200 | $map['state']=['neq',1]; | 200 | $map['state']=['neq',1]; |
201 | + $map['type']=1; | ||
201 | $order=Db::name('order')->where(['users_id'=>$users_id,])->where($map)->order('id','desc')->paginate(8); | 202 | $order=Db::name('order')->where(['users_id'=>$users_id,])->where($map)->order('id','desc')->paginate(8); |
202 | $data_info=$order->items(); | 203 | $data_info=$order->items(); |
203 | foreach ($data_info as $k=>$v){ | 204 | foreach ($data_info as $k=>$v){ |
@@ -212,6 +213,71 @@ class UsersController extends HomeBaseController{ | @@ -212,6 +213,71 @@ class UsersController extends HomeBaseController{ | ||
212 | ]; | 213 | ]; |
213 | $this->apiResponse(200,'success',$data); | 214 | $this->apiResponse(200,'success',$data); |
214 | } | 215 | } |
216 | + | ||
217 | + | ||
218 | + | ||
219 | + /** | ||
220 | + * @title 用户充值列表 | ||
221 | + * @description 用户充值列表 | ||
222 | + * @author panhaowen | ||
223 | + * @url /portal/users/getOrder2 | ||
224 | + * @method GET | ||
225 | + * | ||
226 | + * @param name:users_id type:String require:1 default:无 other: desc:用户id | ||
227 | + * @param name:page type:String require:1 default:无 other: desc:页码 | ||
228 | + * | ||
229 | + * @return currentPage:当前页 | ||
230 | + * @return allPage:总页数 | ||
231 | + * @return allData:总数据量 | ||
232 | + * @return data:当前页的数据(以下是数组字段) | ||
233 | + * | ||
234 | + * @return id:订单id | ||
235 | + * @return order_no:订单号 | ||
236 | + * @return users_id:用户id | ||
237 | + * @return start_time:开始使用时间 | ||
238 | + * @return price:金额(元) | ||
239 | + * @return state:订单状态(1:没完成 2:已完成 3:已支付) | ||
240 | + */ | ||
241 | + public function getOrder2(){ | ||
242 | + $users_id=$this->request->param('users_id'); | ||
243 | + $map['state']=3; | ||
244 | + $map['type']=2; | ||
245 | + $order=Db::name('order')->where(['users_id'=>$users_id,])->where($map)->order('start_time','desc')->paginate(8); | ||
246 | + $this->apiResponse(200,'success',$order); | ||
247 | + } | ||
248 | + | ||
249 | + | ||
250 | + /** | ||
251 | + * @title 用户提现列表 | ||
252 | + * @description 用户提现列表 | ||
253 | + * @author panhaowen | ||
254 | + * @url /portal/users/getOrder3 | ||
255 | + * @method GET | ||
256 | + * | ||
257 | + * @param name:users_id type:String require:1 default:无 other: desc:用户id | ||
258 | + * @param name:page type:String require:1 default:无 other: desc:页码 | ||
259 | + * | ||
260 | + * @return currentPage:当前页 | ||
261 | + * @return allPage:总页数 | ||
262 | + * @return allData:总数据量 | ||
263 | + * @return data:当前页的数据(以下是数组字段) | ||
264 | + * | ||
265 | + * @return id:订单id | ||
266 | + * @return order_no:订单号 | ||
267 | + * @return users_id:用户id | ||
268 | + * @return start_time:开始使用时间 | ||
269 | + * @return money:金额(元) | ||
270 | + */ | ||
271 | + public function getOrder3(){ | ||
272 | + $users_id=$this->request->param('users_id'); | ||
273 | + $data=Db::name('withdraw')->where([ | ||
274 | + 'user_id'=>$users_id, | ||
275 | + ])->paginate(6); | ||
276 | + $this->apiResponse(200,'success',$data); | ||
277 | + } | ||
278 | + | ||
279 | + | ||
280 | + | ||
215 | /** | 281 | /** |
216 | * @title 用户查询未完成订单信息 | 282 | * @title 用户查询未完成订单信息 |
217 | * @description 用户查询在使用订单信息 | 283 | * @description 用户查询在使用订单信息 |
-
请 注册 或 登录 后发表评论