Sfoglia il codice sorgente

获取影片场次日期列表:只返回当前日期后的排片日期

family 1 anno fa
parent
commit
6dff7395a5

+ 1 - 1
app/common/repositories/movie/CinemaSchedRepository.php

@@ -40,7 +40,7 @@ class CinemaSchedRepository extends BaseRepository
40
     public function getFilmSchedDate($film_sign)
40
     public function getFilmSchedDate($film_sign)
41
     {
41
     {
42
         $field = 'show_date';
42
         $field = 'show_date';
43
-        $where = ['film_sign' => $film_sign];
43
+        $where = [['film_sign', '=', $film_sign], ['show_date', '>=', strtotime(date('Y-m-d'))]];
44
 
44
 
45
         $show_date = $this->dao->search(null, $where)->field([$field])->order('show_date asc')->group('show_date')->select()->toArray();
45
         $show_date = $this->dao->search(null, $where)->field([$field])->order('show_date asc')->group('show_date')->select()->toArray();
46
         foreach ($show_date as $key => $value) {
46
         foreach ($show_date as $key => $value) {