2014-02-27 18:49:01 +00:00
|
|
|
{capture assign='roomList'}{include application='chat' file='boxRoomList' showEmptyRooms=false}{/capture}
|
2013-05-02 20:43:52 +00:00
|
|
|
|
2014-02-27 18:49:01 +00:00
|
|
|
<div id="chatDashboardBoxOnlineListContainer"{if !$roomList|trim} style="display: none;"{/if}>
|
|
|
|
<header class="boxHeadline boxSubHeadline">
|
|
|
|
<h2>{lang}chat.header.menu.chat{/lang}</h2>
|
|
|
|
</header>
|
2014-02-28 16:06:50 +00:00
|
|
|
|
2014-02-27 18:49:01 +00:00
|
|
|
<div class="container marginTop">
|
|
|
|
<ul class="containerList">
|
|
|
|
{@$roomList}
|
|
|
|
</ul>
|
2013-04-26 18:47:40 +00:00
|
|
|
</div>
|
2014-02-27 18:49:01 +00:00
|
|
|
<script data-relocate="true">
|
|
|
|
//<![CDATA[
|
|
|
|
(function($, window, undefined) {
|
2015-01-23 19:53:28 +00:00
|
|
|
var proxy = new WCF.Action.Proxy({
|
2014-02-27 18:49:01 +00:00
|
|
|
data: {
|
|
|
|
actionName: 'getBoxRoomList',
|
|
|
|
className: 'chat\\data\\room\\RoomAction',
|
|
|
|
parameters: {
|
|
|
|
showEmptyRooms: 0
|
|
|
|
}
|
|
|
|
},
|
|
|
|
showLoadingOverlay: false,
|
|
|
|
suppressErrors: true,
|
|
|
|
success: function(data) {
|
|
|
|
if (data.returnValues.template) $('#chatDashboardBoxOnlineListContainer').show();
|
|
|
|
else $('#chatDashboardBoxOnlineListContainer').hide();
|
|
|
|
|
|
|
|
$('#chatDashboardBoxOnlineListContainer ul').html(data.returnValues.template);
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
2015-01-23 19:53:28 +00:00
|
|
|
$(function () {
|
|
|
|
be.bastelstu.wcf.push.onMessage('be.bastelstu.chat.join', proxy.sendRequest.bind(proxy));
|
|
|
|
be.bastelstu.wcf.push.onMessage('be.bastelstu.chat.leave', proxy.sendRequest.bind(proxy));
|
|
|
|
});
|
2014-02-27 18:49:01 +00:00
|
|
|
})(jQuery, this);
|
|
|
|
//]]>
|
|
|
|
</script>
|
|
|
|
</div>
|