1
0
mirror of https://github.com/devcode-it/openstamanager.git synced 2025-06-05 22:09:38 +02:00

Ottimizzazzione Database

This commit is contained in:
Thomas Zilio
2018-07-03 15:05:27 +02:00
parent 8f11a2b264
commit bb47682f03
8 changed files with 33 additions and 30 deletions

View File

@ -31,11 +31,7 @@ $results['summable'] = [];
if (!empty($result_query) && $result_query != 'menu' && $result_query != 'custom') {
// Conteggio totale
$count_query = 'SELECT COUNT(*) as `tot` FROM ('.$result_query.') AS `count`';
$count = $dbo->fetchArray($count_query);
if (!empty($count)) {
$results['recordsTotal'] = $count[0]['tot'];
}
$results['recordsTotal'] = $dbo->fetchNum($result_query);
// Filtri di ricerica
$search_filters = [];