Hi Onur,
Welcome to the forum, and thanks so much for your report!
Unfortunately, I can’t replicate the issue. If I paste the query code to the native Bricks query editor (and change the post type to my Meta Box CPT), the pagination works without issues. So there must be something wrong on your end, which I cannot see at first glance.
You’re using the “global query manager” feature from Advanced Themer, which is a third-party plugin/feature. Please get in touch with Advanced Themer support to get this sorted.
Alternatively, try using the native Bricks query editor and see if it works there.
It would be helpful if we could have a filter to add our own queryTypes allowed in the pagination element. Right now, none of the global queries will be compatible with the pagination element and there is not much I can do about it.
Currently, we restricted the pagination element to only support ‘post’, ‘user’, & ‘term’ objectType because we added logic that can retrieve $current_page and $total_pages for these 3 native loops.
We can provide a total of 3 hooks to make use of the pagination element:
pagination use custom logic - boolean ( default false, if true, will not check the query object type and not execute query, you can get the element settings from this hook to decide returning true or false )
one filter for the pagination current page - integer ( you can get the element settings from this hook for your own logic)
one filter for the pagination total pages - integer (you can get the element settings from this hook for your own logic)
The global queries in AT basically follow the same logic as using the queryEditor. If the loops using the queryEditor support the pagination element, I would guess it should work with global queries as well without messing with $current_page and $total_pages. I will do further tests and let you know