{if !empty($list)}

<div class="ow_user_list ow_full ow_stdmargin">
	{foreach from=$list item='item' name='user_list'}
		{assign var='dto' value=$item.dto}
		{assign var='id' value=$dto->id}

		{if $smarty.foreach.user_list.first}
			<div class="clearfix {cycle name="rows" values="ow_alt2, ow_alt1"}">
		{/if}

		{capture assign="_fields"}
			{if !empty($fields)}
				{foreach from=$fields[$id] item="field"}
					{$field.label}{$field.value}<br />
				{/foreach}
			{/if}
		{/capture}

		{capture assign="activity"}
            {if !empty($showPresenceList) && !empty($showPresenceList[$id]) && $showPresenceList[$id]}
                {if $onlineInfo}
                    {if (!empty($onlineInfo) && $onlineInfo[$id]) || empty($onlineInfo) }{online_now userId=$dto->id}{else}{text key="base+user_list_activity"}: <span class="ow_remark">{format_date timestamp=$dto->activityStamp}</span>{/if}
                {/if}
            {/if}
		{/capture}

		{assign var="username" value=$usernameList[$id]}

		{assign var="name" value=$displayNameList[$id]}

		{decorator name="user_list_item"
               avatar=$avatars[$id]
               username=$username
               displayName=$name
               contextMenu=$contextMenuList[$id]
               fields=$_fields
               activity=$activity
               set_class='ow_item_set3'}

		{if $smarty.foreach.user_list.iteration % 3 == 0 && !$smarty.foreach.user_list.last}
			</div>
			<div class="clearfix {cycle name="rows" values="ow_alt1,ow_alt2"}">
		{/if}

		{if $smarty.foreach.user_list.last}
		  </div>
		{/if}

	{/foreach}

</div>

<center>{$paging}</center>
{else}
	<center>{text key="base+user_no_users"}</center>
{/if}