I have created a new action in an extended controller (I have extended XenForo_ControllerAdmin_User). My new action is called actionProfileViews.
ProfileViews displays a list of users. I have created my own template for this (profile_views_user_list) but essentially it is the normal user_list template with a few customisations.
Well, here it is:
For each user, the template profile_views_user_list_items is included.
As you can see I have also included the standard functions for filtering a list.
This is my problem.
My action returns this:
ProfileViewCount_ViewAdmin_List looks like this:
This should make it so that when the filter is used, the profile_views_user_list_items template is rendered.
Well, it doesn't do that
Instead it renders the default user_list_item as defined in XenForo_ViewAdmin_User_List:
What have I missed?
ProfileViews displays a list of users. I have created my own template for this (profile_views_user_list) but essentially it is the normal user_list template with a few customisations.
Well, here it is:
For each user, the template profile_views_user_list_items is included.
As you can see I have also included the standard functions for filtering a list.
This is my problem.
My action returns this:
PHP:
return $this->responseView('ProfileViewCount_ViewAdmin_List', 'profile_views_user_list', $viewParams);
ProfileViewCount_ViewAdmin_List looks like this:
PHP:
<?php
class ProfileViewCount_ViewAdmin_List extends XenForo_ViewAdmin_Base
{
public function renderJson()
{
if (!empty($this->_params['filterView']))
{
$this->_templateName = 'profile_views_user_list_items';
}
return null;
}
}
This should make it so that when the filter is used, the profile_views_user_list_items template is rendered.
Well, it doesn't do that
Instead it renders the default user_list_item as defined in XenForo_ViewAdmin_User_List:
What have I missed?