<defaultvalue>0</defaultvalue>
<minvalue>0</minvalue>
</option>
+ <option name="users_online_record_no_guests">
+ <categoryname>user.list.online</categoryname>
+ <optiontype>boolean</optiontype>
+ <defaultvalue>0</defaultvalue>
+ <options>module_users_online</options>
+ </option>
+ <option name="users_online_enable_legend">
+ <categoryname>user.list.online</categoryname>
+ <optiontype>boolean</optiontype>
+ <defaultvalue>0</defaultvalue>
+ <options>module_users_online</options>
+ </option>
+ <option name="users_online_record">
+ <categoryname>user.list.online</categoryname>
+ <optiontype>integer</optiontype>
+ <hidden>1</hidden>
+ </option>
+ <option name="users_online_record_time">
+ <categoryname>user.list.online</categoryname>
+ <optiontype>integer</optiontype>
+ <hidden>1</hidden>
+ </option>
<!-- /user.list.online -->
<!-- user.cleanup -->
--- /dev/null
+{if !$usersOnlineShowRecord|isset}{assign var='usersOnlineShowRecord' value=true}{/if}
+{if MODULE_USERS_ONLINE && $usersOnlineList->stats[total]}
+ <li class="box32 usersOnlineInfoBox">
+ <span class="icon icon32 icon-user"></span>
+
+ <div>
+ <div class="containerHeadline">
+ <h3><a href="{link controller='UsersOnlineList'}{/link}">{lang}wcf.user.usersOnline{/lang}</a> <span class="badge">{#$usersOnlineList->stats[total]}</span></h3>
+ <p>{lang}wcf.user.usersOnline.detail{/lang}{if $usersOnlineShowRecord} - {lang}wcf.user.usersOnline.record{/lang}{/if}</p>
+ </div>
+
+ <ul class="dataList">
+ {foreach from=$usersOnlineList->getObjects() item=userOnline}
+ <li><a href="{link controller='User' object=$userOnline->getDecoratedObject()}{/link}" class="userLink" data-user-id="{@$userOnline->userID}">{@$userOnline->getFormattedUsername()}</a></li>
+ {/foreach}
+ </ul>
+
+ {if USERS_ONLINE_ENABLE_LEGEND && $usersOnlineList->getUsersOnlineMarkings()|count}
+ <div class="usersOnlineLegend">
+ <p>{lang}wcf.user.usersOnline.marking.legend{/lang}:</p>
+ <ul class="dataList">
+ {foreach from=$usersOnlineList->getUsersOnlineMarkings() item=usersOnlineMarking}
+ <li>{@$usersOnlineMarking}</li>
+ {/foreach}
+ </ul>
+ </div>
+ {/if}
+ </div>
+ </li>
+{/if}
\ No newline at end of file
</form>
</div>
+ <fieldset>
+ <legend>{lang}wcf.user.usersOnline{/lang}</legend>
+
+ <p><small>{lang}wcf.user.usersOnline.detail{/lang}</small></p>
+ <p><small>{lang}wcf.index.usersOnline.record{/lang}</small></p>
+
+ {if USERS_ONLINE_ENABLE_LEGEND && $objects->getUsersOnlineMarkings()|count}
+ <div class="marginTopSmall">
+ <p><small>{lang}wcf.user.usersOnline.marking.legend{/lang}</small></p>
+ <ul class="dataList">
+ {foreach from=$usersOnlineList->getUsersOnlineMarkings() item=usersOnlineMarking}
+ <li><small>{@$usersOnlineMarking}</small></li>
+ {/foreach}
+ </ul>
+ </div>
+ {/if}
+ </fieldset>
+
{@$__boxSidebar}
{/capture}
<?php
namespace wcf\data\user\online;
+use wcf\data\option\OptionAction;
use wcf\data\session\SessionList;
use wcf\data\user\group\UserGroup;
use wcf\data\user\User;
return $this->usersOnlineMarkings;
}
+ /**
+ * Checks the users online record.
+ */
+ public function checkRecord() {
+ $usersOnlineTotal = (USERS_ONLINE_RECORD_NO_GUESTS ? $this->stats['members'] : $this->stats['total']);
+ if ($usersOnlineTotal > USERS_ONLINE_RECORD) {
+ // save new record
+ $optionAction = new OptionAction(array(), 'import', array('data' => array(
+ 'users_online_record' => $usersOnlineTotal,
+ 'users_online_record_time' => TIME_NOW
+ )));
+ $optionAction->executeAction();
+ }
+ }
+
/**
* Checks the 'canViewOnlineStatus' setting.
*
*/
protected function initObjectList() {
parent::initObjectList();
+ $this->objectList->readStats();
+ $this->objectList->checkRecord();
if (!USERS_ONLINE_SHOW_ROBOTS) {
$this->objectList->getConditionBuilder()->add('session.spiderID IS NULL');
Beispiele:<br />
WBB=WoltLab Burning Board<br />
GmbH=Gesellschaft mit beschränkter Haftung]]></item>
+ <item name="wcf.acp.option.users_online_record_no_guests"><![CDATA[Nur registrierte Benutzer im Benutzer-Online-Rekord zählen]]></item>
+ <item name="wcf.acp.option.users_online_enable_legend"><![CDATA[Legende der Benutzergruppen unter der Benutzer-Online-Liste anzeigen]]></item>
</category>
<category name="wcf.acp.package">
<item name="wcf.user.usersOnline.lastActivity"><![CDATA[Letzte Aktivität]]></item>
<item name="wcf.user.usersOnline.location.unknown"><![CDATA[Unbekannter Ort]]></item>
<item name="wcf.user.usersOnline.robots"><![CDATA[Suchmaschinen-Roboter]]></item>
+ <item name="wcf.user.usersOnline.record"><![CDATA[{if USERS_ONLINE_RECORD > 0}Rekord: {#USERS_ONLINE_RECORD} Benutzer ({@USERS_ONLINE_RECORD_TIME|time}){/if}]]></item>
</category>
<category name="wcf.user.recentActivity">
Beispiele:<br />
WBB=WoltLab Burning Board<br />
GmbH=Gesellschaft mit beschränkter Haftung]]></item>
+ <item name="wcf.acp.option.users_online_enable_legendusers_online_record_no_guests"><![CDATA[Exclude guests from user online record]]></item>
+ <item name="wcf.acp.option.users_online_enable_legend"><![CDATA[Display legend for “Users Online” list]]></item>
</category>
<category name="wcf.acp.package">
<item name="wcf.user.usersOnline.lastActivity"><![CDATA[Last Activity]]></item>
<item name="wcf.user.usersOnline.location.unknown"><![CDATA[Unknown location]]></item>
<item name="wcf.user.usersOnline.robots"><![CDATA[Search Engine Robots]]></item>
+ <item name="wcf.user.usersOnline.record"><![CDATA[{if USERS_ONLINE_RECORD > 0}Record: {#USERS_ONLINE_RECORD} User{if USERS_ONLINE_RECORD != 1}s{/if} ({@USERS_ONLINE_RECORD_TIME|time}){/if}]]></item>
</category>
<category name="wcf.user.recentActivity">