I have about 100 members (employees) in the members section and I would like to display them in a large list, but they should only appear in the list if they have a specific tag on them (a tags property).
My question is - what is the best way to run through all the members of a specific type and filtering out the ones which has the selected tag (with only Razor).
Best way to list and filter members (razor)
Hi all,
I have about 100 members (employees) in the members section and I would like to display them in a large list, but they should only appear in the list if they have a specific tag on them (a tags property).
My question is - what is the best way to run through all the members of a specific type and filtering out the ones which has the selected tag (with only Razor).
Thanks!!!
Hi Mathias
I would use Examine, and search the InternalMemberIndex for members containing the specific tag.
Theres a great (it's actually the worlds friendliest :)) blog post about searching in Examine here -> http://24days.in/umbraco-cms/2013/getting-started-with-examine/
Hi Mathias and Søren
InternalMemberIndex - definitely is the fastest way to work with members.
But it's suitable only for displaying data.
If you need some table with CRUD operations you have to use MemberService, read more here - https://our.umbraco.org/documentation/reference/management/services/memberservice
It works directly with database and provide the actual data for you, but be aware this is really not so fast as Examine.
Thanks,
Alex
is working on a reply...