Page 1 of 1

FrontEndUsers Additional Properties in Admin Template

Posted: Mon Jan 25, 2021 8:02 pm
by webform
Is it possible to have Additional Properties in in the admin user list template without the user need to Select Additional Properties to View?

I have some specific properties i would like to have permanently fixed in the FEU user list in admin and in a specific order.

I know i can call properties directly with {$entry->extra.fieldalias->val}, but only if the same property is already selected in "Additional Properties".

Maybe it's not possible only customizing the userlist.tpl template?

Re: FrontEndUsers Additional Properties in Admin Template

Posted: Mon Jan 25, 2021 9:24 pm
by MarcG
You should be able to choose additional fields in the Filter -- choose View Filter, and there's a list on the right. Ctrl-click to select more than one.

Re: FrontEndUsers Additional Properties in Admin Template

Posted: Tue Jan 26, 2021 12:03 am
by webform
Thanks! But that is not what i'm asking ;)

I want to have a default preset of properties in a specifik order in the user view template WITHOUT having to select them first in "Additional Properties to View".

Re: FrontEndUsers Additional Properties in Admin Template

Posted: Tue Jan 26, 2021 2:49 am
by DIGI3
You should be able to edit the module's template to make it do what you want. Use the module_custom folder so it doesn't get deleted on upgrade (see https://cmscanbesimple.org/blog/cgblog- ... provements - different module but same concept)

Re: FrontEndUsers Additional Properties in Admin Template

Posted: Tue Jan 26, 2021 9:05 am
by webform
I've been playing around with FEU userlist.tpl template in the module_custom folder, but it's seems like this particular function i want to change is handled in the function file and not in the template.

So it seems like i'm stuck with how to handle Additional Properties in the user list.

Re: FrontEndUsers Additional Properties in Admin Template

Posted: Sun Jan 31, 2021 1:03 pm
by webform
Follow Up:

I've kinda solved it in the userlist.tpl template whitout "hacking" the core files;

Code: Select all

{assign var=preselect value=[myfieldalias1,myfieldalias2,myfieldalias3,myfieldalias4]}
{html_options options=$alldefns selected=$preselect}
And set the select to display:none, so users can't change the selected properties.

In the foreach i place my fields in the order i need/want:

Code: Select all

{$entry->extra.myfieldalias1->val} etc.
First time users have to apply filter on first use (Or the admin creating an account does is), but hereafter the userlist is displaying the needed fields in order.

Not the most elegant solution, i know, but it get the job done!