Lines 1-20
Link Here
|
1 |
$(document).ready(function(){ |
1 |
$(document).ready(function(){ |
2 |
$(".none").click(function(){ |
2 |
$(".clear_pref").click(function(){ |
3 |
if($(this).prop("checked")){ |
|
|
4 |
var rowid = $(this).attr("id"); |
3 |
var rowid = $(this).attr("id"); |
5 |
var newid = Number(rowid.replace("none","")); |
4 |
var newid = Number(rowid.replace("clear_","")); |
6 |
$("#sms"+newid).prop("checked", false); |
5 |
$("#sms"+newid).prop("checked", false); |
7 |
$("#email"+newid).prop("checked", false); |
6 |
$("#email"+newid).prop("checked", false); |
8 |
$("#phone"+newid).prop("checked", false); |
7 |
$("#phone"+newid).prop("checked", false); |
9 |
$("#digest"+newid).prop("checked", false); |
8 |
$("#digest"+newid).prop("checked", false); |
10 |
$("#rss"+newid).prop("checked", false); |
9 |
$("#rss"+newid).prop("checked", false); |
11 |
} |
|
|
12 |
}); |
13 |
$(".active_notify").on("change",function(){ |
14 |
var attr_id = $(this).data("attr-id"); |
15 |
if( $(this).prop("checked") ){ |
16 |
$("#none" + attr_id ).prop("checked", false); |
17 |
} |
18 |
}); |
10 |
}); |
19 |
$("#info_digests").tooltip(); |
11 |
$("#info_digests").tooltip(); |
20 |
|
12 |
|
Lines 36-42
$(document).ready(function(){
Link Here
|
36 |
return; |
28 |
return; |
37 |
} |
29 |
} |
38 |
} |
30 |
} |
39 |
$(".none").prop("checked", false); // When loading default prefs the "Clear" boxes should be cleared |
|
|
40 |
var jqxhr = $.getJSON('/cgi-bin/koha/members/default_messageprefs.pl?categorycode=' + categorycode, function(data) { |
31 |
var jqxhr = $.getJSON('/cgi-bin/koha/members/default_messageprefs.pl?categorycode=' + categorycode, function(data) { |
41 |
$.each(data.messaging_preferences, function(i, item) { |
32 |
$.each(data.messaging_preferences, function(i, item) { |
42 |
var attrid = item.message_attribute_id; |
33 |
var attrid = item.message_attribute_id; |
43 |
- |
|
|