I have the following code in a snippet:
{% component source: “Team Members”, layout: “List”, sortBy: “weighting”, limit: “100”, type: “module” %}
In the custom module that I’m pulling this list from, I’m adding a weighting number, but it just seems to sort alphabetically no matter what I do.
Any thoughts?
Uhm, never mind. I think the weighting is reverse of how I was thinking.
Higher number shows first?! Is that how weighting works?!
Correct - Higher number shows first
A3CS
March 28, 2019, 8:01pm
4
Hey, just make sure to add the Sort Value for the weighting - Descending
1 Like
Thanks for confirming, @Peter-Schmidt !
@A3CS - I didn’t know you could reverse the sort order - thanks!
Documentation on the component options here:
https://docs.treepl.co/documentation_group/component-types/module-custom-modules
And something I do when weighting is use numbering like this:
1000
990
980
970
…
Instead of:
1000
999
998
997
…
That way you have ‘empty’ spots available to shift things around or add new items in without having to re-weight every.single.item.
You may already be doing this but just thought I’d mention it
A3CS
March 29, 2019, 3:44am
7
Ha @Adam.Wilson thought I was the only one that ‘weighted’ this way… it has come in handy on numerous occasions leaving the extra spots for those last minute additions.
1 Like
Do the exact same thing - You learn it the hard way!