Sfoglia il codice sorgente

'首页过滤掉整本付费阅读的书'

zhuchengjie 2 anni fa
parent
commit
01c0e7d011
1 ha cambiato i file con 3 aggiunte e 0 eliminazioni
  1. 3 0
      app/Http/Controllers/QuickApp/Book/BookController.php

+ 3 - 0
app/Http/Controllers/QuickApp/Book/BookController.php

@@ -266,6 +266,7 @@ class BookController extends BaseController
             ->leftjoin('book_categories', 'books.category_id', 'book_categories.id')
             ->whereIn('book_configs.bid',$bid_list)
             ->where('book_configs.is_on_shelf',2)
+            ->where('book_configs.charge_type','!=','BOOK')
             ->whereNotIn('book_configs.cp_source',getHiddenCp())
             ->where('book_categories.pid',$channel)
             ->count();
@@ -282,6 +283,7 @@ class BookController extends BaseController
             ->leftjoin('book_categories', 'books.category_id', 'book_categories.id')
             ->whereIn('book_configs.bid',$bid_list)
             ->where('book_configs.is_on_shelf',2)
+            ->where('book_configs.charge_type','!=','BOOK')
             ->whereNotIn('book_configs.cp_source',getHiddenCp())
             ->where('book_categories.pid',$channel)
             ->pluck('book_configs.bid')->all();
@@ -291,6 +293,7 @@ class BookController extends BaseController
         $rand_bid = BookConfig::join('books', 'book_configs.bid', '=', 'books.id')
             ->leftjoin('book_categories', 'books.category_id', 'book_categories.id')
             ->where('book_configs.is_on_shelf',2)
+            ->where('book_configs.charge_type','!=','BOOK')
             ->whereNotIn('book_configs.cp_source',getHiddenCp())
             ->where('book_categories.pid',$channel)
             ->inRandomOrder()