Browse Source

fix:
- 我的预约接口bug修复

zhengzhibin 2 years ago
parent
commit
1a3a688ab3
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/api/controller/User.php

+ 2 - 2
app/api/controller/User.php

@@ -141,9 +141,9 @@ class User extends Permissions
         $where = ['user_id' => $this->getUserId()];
         $where = ['user_id' => $this->getUserId()];
         $status = $this->request->param('status', 0, 'intval');
         $status = $this->request->param('status', 0, 'intval');
         if ($status == 1) {
         if ($status == 1) {
-            $where = ['finish_time' => 0];
+            $where['finish_time'] = 0;
         } elseif ($status == 2) {
         } elseif ($status == 2) {
-            $where = ['finish_time' => ['>', 0]];
+            $where['finish_time'] = ['>', 0];
         }
         }
         $pagenum = $this->request->param('pagenum', 20, 'intval');
         $pagenum = $this->request->param('pagenum', 20, 'intval');
         $datalist = (new AppointmentApplication())->where($where)->order('create_time desc')->paginate($pagenum, true);
         $datalist = (new AppointmentApplication())->where($where)->order('create_time desc')->paginate($pagenum, true);