XF 1.4 Duplicating member_list_item for XenStaff-like AddOn

CaptainMorgan

Active member

Following @Jake Bunce 's advice, I was able to get this working on the member_list_item template. I have two concerns.

1) I created a duplicate of the member_list_item template so that my code would not interfere with other stock XF templates. Naturally, {$user.customFields.field_id} works only on the stock member_list_item template and not mine. How do I go about getting this to work on my duplicate template? My code gets from the cache XenForo_Model_User, but this appears to not be what I need, so I tried XenForo_Model_UserField. This almost worked (see #2), but I had unserialize it. Is there another model I should be using?

2) The value displayed on the member_list_item template is the choice's number, not the value of the text. So, instead of ouputting: "Field: Value", it's outputting "Field: Value's id". It is a dropdown custom field with a number of choices to pick from. How do I get that value's id to show its text instead?

EDIT::So it seems this was what I needed for #2 above. Any chance on getting assistance with #1? Thanks
 
Back
Top Bottom