zoolanders / ytp-source-k2

A K2 Source for YOOtheme Pro
5 stars 0 forks source link

Custom queries - Start loading articles from number xx #6

Closed philmarty closed 2 years ago

philmarty commented 2 years ago

When using a multiple element in the builder with custom query, it would be useful to be able to load article from a specific number.

For example: https://nimb.ws/zY1U9S We use several multiple elements to load article from news categories. The first element, slideshow, loads the first 3 articles. The second element, list, loads 5 more items. We need to load the items from the fourth one onwards, so that the first three items are not duplicated. Backend link: https://zooffs.a51.fr/administrator/index.php?option=com_ajax&templateStyle=12&p=customizer&format=html&site=https%3A%2F%2Fzooffs.a51.fr%2Findex.php

miljan-aleksic commented 2 years ago

The items query relies on the K2 Module content helper, which doesn't support offset parameter. Making our own helper introduces too much complexity, so the best course of action would be to request this feature for the K2 Module to JoomlaWorks and once is supported let us know to add the parameter in the query.

miljan-aleksic commented 2 years ago

Hi Phil,

this should be possible now, I have added a custom helper for loading the items. Can you please test it?

philmarty commented 2 years ago

Hello Miljan,

Thanks a lot for that new feature :) I'm off today but I was eager to test so I updated your extension files. It works like a charm! I can choose the beginner item for a multiple element. Thanks again :)

I see that another person has difficulties using K2 as content source, it's curious as it seems so easy by my side :) I hope you can fix that quickly.

Cheers Phil

Le jeu. 26 mai 2022 à 10:00, Miljan @.***> a écrit :

Hi Phil,

this should be possible now, I have added a custom helper for loading the items. Can you please test it?

— Reply to this email directly, view it on GitHub https://github.com/joolanders/ytp-source-k2/issues/6#issuecomment-1138270850, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACM57PQJZAJLQWEPETDOY3TVL4VP7ANCNFSM5UPSDSGQ . You are receiving this because you authored the thread.Message ID: @.***>