|
|
@@ -24,6 +24,14 @@ class UserOrderLists extends BaseApiDataLists implements ListsSearchInterface
|
|
|
'=' => ['a.status'],
|
|
|
];
|
|
|
}
|
|
|
+
|
|
|
+ public function queryWhere(){
|
|
|
+ $where = [];
|
|
|
+ if (empty($this->params['status'])) {
|
|
|
+ $where[] = ['a.status', '<>', 0];
|
|
|
+ }
|
|
|
+ return $where;
|
|
|
+ }
|
|
|
|
|
|
/**
|
|
|
* @notes 获取列表
|
|
|
@@ -38,6 +46,7 @@ class UserOrderLists extends BaseApiDataLists implements ListsSearchInterface
|
|
|
'a.user_id' => $this->userId,
|
|
|
])
|
|
|
->where($this->searchWhere)
|
|
|
+ ->where($this->queryWhere())
|
|
|
->limit($this->limitOffset, $this->limitLength)
|
|
|
->order('a.create_time', 'desc')
|
|
|
->select()
|
|
|
@@ -56,6 +65,7 @@ class UserOrderLists extends BaseApiDataLists implements ListsSearchInterface
|
|
|
'user_id' => $this->userId,
|
|
|
])
|
|
|
->where($this->searchWhere)
|
|
|
+ ->where($this->queryWhere())
|
|
|
->count();
|
|
|
}
|
|
|
|