QiFeng.ZWY.MagWeb/Content/admin/dist/js/main-frame.js
(完整代码) 1KB$(function () {
$("#frame").hide();
$(".div-loading").show();
//Initial the outer frame, which is going to handle the SignalR connection
initNotificationHub();
$(window).bind('load resize', function () {
$("#frame").width($(window).width());
$("#frame").height($(window).height() - $(".page-footer").height() - 30);
$(".div-loading").hide();
$("#frame").fadeIn(1000);
});
});
function initNotificationHub() {
var shopId = $("#curShop").val();
var accountId = $("#curAccount").val();
var notificationHub = $.connection.notificationHub;
registerClientMethods(notificationHub);
$.connection.hub.start().done(function () {
var curConnectionId = $.connection.hub.id;
notificationHub.server.join(shopId, accountId, curConnectionId);
});
}
function registerClientMethods(hub) {
hub.client.newMessage = function (messageModel) {
var strHtml = '<li>' +
'<a href="/Orders/List">' +
'<div>' +
'<strong>' + messageModel.MsgTitle + '</strong>' +
'</div>' +
'<div>' + messageModel.MsgContent + '</div>' +
'</a>' +
'</li>' +
'<li class="divider"></li>';
var currentMsgCount = $("#frame").contents().find("#noteBadge").html();
$("#frame").contents().find("#noteBadge").html(parseInt(currentMsgCount) + 1);
$("#frame").contents().find("#noteBadge").show();
$("#frame").contents().find("#messageBox").prepend(strHtml);
$("#notifier")[0].play();
alertify.logPosition("bottom right");
alertify.log(messageModel.MsgContent);
};
}
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。