This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit ezplatform.com

eZ Community » Forums » Setup & design » Forum Announcement class?
expandshrink

Forum Announcement class?

Forum Announcement class?

Sunday 28 October 2012 2:23:00 pm - 4 replies

Hi,

Has anyone created a forum class that can be set to always be at the top of a board?

I'm guessing it'll be based on the forum topic class with some sort of voodoo to make it stay at the top of the board

Anyone?

Sunday 28 October 2012 5:18:55 pm

Hi,

adding a "Pinned" checkbox to existing forum topic class should be enough. After that, select the checkbox on objects that you want to be pinned and modify your fetch to first sort by checkbox attribute descending, and after that use your existing sort.

Modified on Sunday 28 October 2012 5:19:28 pm by Edi Modrić

Thursday 15 November 2012 10:03:27 am

HI Edi,

I understand adding the checkbox to the class but where would I do this bit you've mentioned

"modify your fetch to first sort by checkbox attribute descending"

Would that be in the forum post tpl file?

Thanks

Thursday 15 November 2012 12:00:11 pm

Quote from Neo Pixel :

HI Edi,

I understand adding the checkbox to the class but where would I do this bit you've mentioned

"modify your fetch to first sort by checkbox attribute descending"

Would that be in the forum post tpl file?

Thanks

Hi Neo,

No, it would be in a template for a "forum" class, not "forum topic" nor "forum post". Presumably, your "forum" class template contains the fetch function that loads forum topics with some predefined sort.

You need to modify that fetch to sort the forum topics by your new checkbox attribute.

Saturday 17 November 2012 2:12:20 pm

Hi Edi,

Ok, thanks. I'll have a look and see if i can figure it out

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from