@@ -379,8 +379,9 @@ sub api_v1_GET_documents { | |||
my @out; | |||
my $q = sqlquery($dbh, "SELECT id FROM documents WHERE id IN (CALL get_document_filter(?)) LIMIT ?,?", | |||
my $q = sqlquery($dbh, "CALL get_document_filter(?,?,?,?)", | |||
exists $qs->{filter} ? $qs->{filter} : undef, | |||
exists $qs->{tags} ? $qs->{tags} : undef, | |||
$qs->{pageSize} * $qs->{pageIndex}, | |||
$qs->{pageSize}); | |||
while(my ($id) = $q->fetchrow_array()) { |