';
html += items.map(function (u) {
- var id = idPrefix + u.Id;
-
var isChecked = isEnabledList ? currentList.indexOf(u.Id) != -1 : currentList.indexOf(u.Id) == -1;
var checkedHtml = isChecked ? ' checked="checked"' : '';
- return '
';
+ return '
' + u.Name + '';
}).join('');
@@ -86,7 +84,7 @@
fillItems($('.sendToUsersList', page), users, 'chkSendTo', 'chkSendTo', notificationConfig.SendToUsers, true);
fillItems($('.servicesList', page), services, 'chkService', 'chkService', notificationConfig.DisabledServices);
- $('#chkEnabled', page).checked(notificationConfig.Enabled || false).checkboxradio('refresh');
+ $('#chkEnabled', page).checked(notificationConfig.Enabled || false);
$('#txtTitle', page).val(notificationConfig.Title || typeInfo.DefaultTitle);
@@ -135,15 +133,21 @@
notificationConfig.Title = null;
}
- notificationConfig.DisabledMonitorUsers = $('.chkMonitor:not(:checked)', page).get().map(function (c) {
+ notificationConfig.DisabledMonitorUsers = $('.chkMonitor', page).get().filter(function (c) {
+ return !c.checked;
+ }).map(function (c) {
return c.getAttribute('data-itemid');
});
- notificationConfig.SendToUsers = $('.chkSendTo:checked', page).get().map(function (c) {
+ notificationConfig.SendToUsers = $('.chkSendTo', page).get().filter(function (c) {
+ return c.checked;
+ }).map(function (c) {
return c.getAttribute('data-itemid');
});
- notificationConfig.DisabledServices = $('.chkService:not(:checked)', page).get().map(function (c) {
+ notificationConfig.DisabledServices = $('.chkService', page).get().filter(function (c) {
+ return !c.checked;
+ }).map(function (c) {
return c.getAttribute('data-itemid');
});