summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--includes/classes/StockMovement.php9
-rw-r--r--templates/list_movements.tpl2
2 files changed, 10 insertions, 1 deletions
diff --git a/includes/classes/StockMovement.php b/includes/classes/StockMovement.php
index 5ee4aae..6e07cbf 100644
--- a/includes/classes/StockMovement.php
+++ b/includes/classes/StockMovement.php
@@ -246,6 +246,15 @@ class StockMovement extends LibertyContent {
$whereSql = substr_replace( $whereSql, ' WHERE ', 0, 4 );
}
+ $pListHash['cant'] = (int)$this->mDb->getOne(
+ "SELECT COUNT(DISTINCT lc.`content_id`)
+ FROM `".BIT_DB_PREFIX."liberty_content` lc
+ INNER JOIN `".BIT_DB_PREFIX."users_users` uu ON uu.`user_id` = lc.`user_id`
+ $joinSql
+ $whereSql",
+ $bindVars
+ );
+
$X = BIT_DB_PREFIX;
$cmpQtySelect = $this->verifyId( $pListHash['component_content_id'] ?? 0 )
? ", xcmp.`item` AS cmp_qty_type, CAST(xcmp.`xkey` AS DOUBLE PRECISION) AS cmp_qty"
diff --git a/templates/list_movements.tpl b/templates/list_movements.tpl
index a7ef918..3839641 100644
--- a/templates/list_movements.tpl
+++ b/templates/list_movements.tpl
@@ -74,7 +74,7 @@
</table>
<nav>
- {pagination}
+ {pagination ref_type=$filterType find=$smarty.request.find|default:'' component_content_id=$componentContentId|default:'' assembly_content_id=$assemblyContentId|default:''}
</nav>
</section>