This commit is contained in:
songliang 2022-12-16 12:48:23 +08:00
parent 7fcdca8fb3
commit e296fc19c3

View File

@ -763,8 +763,21 @@ class MarketController extends BaseController {
':token_type' => $type, ':token_type' => $type,
) )
); );
$counts = $conn->execQuery(
'SELECT count(*) as count FROM t_market_store '.
'WHERE token_type=:token_type '.
$job_filter_fn($job_filter_array).
$lv_filter_fn($lv_filter).
$quality_filter_fn($quality_filter).
$durability_filter_fn($durability_filter).
$search_filter_fn($search_filter_array).
$order_fn($order_method, $order_asc),
array(
':token_type' => $type,
)
);
$total = count($rows); $total = $counts[0]['count'];
$page_end = $start + $page_size; $page_end = $start + $page_size;
if ($page_end > $total) { if ($page_end > $total) {
$page_end = $total; $page_end = $total;
@ -789,7 +802,7 @@ class MarketController extends BaseController {
} }
$this->_rspData(array( $this->_rspData(array(
"total" => count($rows), "total" => $total,
"start" => $start, "start" => $start,
"page_size" => $page_size, "page_size" => $page_size,
'nfts' => $nfts, 'nfts' => $nfts,
@ -837,7 +850,7 @@ class MarketController extends BaseController {
} }
$this->_rspData(array( $this->_rspData(array(
"total" => count($rows), "total" => $total,
"start" => $start, "start" => $start,
"page_size" => $page_size, "page_size" => $page_size,
'nfts' => $nfts, 'nfts' => $nfts,