|
Lines 1-3
Link Here
|
|
|
1 |
/* global __ */ |
| 2 |
|
| 1 |
$( document ).ready(function() { |
3 |
$( document ).ready(function() { |
| 2 |
var checkboxes = $("#delete-alert-form input[type='checkbox']"); |
4 |
var checkboxes = $("#delete-alert-form input[type='checkbox']"); |
| 3 |
var checkedcheckboxes = 0; |
5 |
var checkedcheckboxes = 0; |
|
Lines 37-43
$( document ).ready(function() {
Link Here
|
| 37 |
if( soundfield.val() !== '' ){ |
39 |
if( soundfield.val() !== '' ){ |
| 38 |
playSound( soundfield.val() ); |
40 |
playSound( soundfield.val() ); |
| 39 |
} else { |
41 |
} else { |
| 40 |
alert( MSG_AUDIO_EMPTY_SOUND ); |
42 |
alert( __("Please select or enter a sound.") ); |
| 41 |
} |
43 |
} |
| 42 |
}); |
44 |
}); |
| 43 |
|
45 |
|
|
Lines 59-67
$( document ).ready(function() {
Link Here
|
| 59 |
|
61 |
|
| 60 |
$('#delete-alert-form').on('submit', function() { |
62 |
$('#delete-alert-form').on('submit', function() { |
| 61 |
if( checkedcheckboxes == 1 ){ |
63 |
if( checkedcheckboxes == 1 ){ |
| 62 |
return confirm( MSG_AUDIO_CONFIRM_DELETE ); |
64 |
return confirm( __("Are you sure you want to delete the selected audio alerts?") ); |
| 63 |
} else { |
65 |
} else { |
| 64 |
alert( MSG_AUDIO_CHECK_CHECKBOXES ); |
66 |
alert( __("Check the box next to the alert you want to delete.") ); |
| 65 |
return false; |
67 |
return false; |
| 66 |
} |
68 |
} |
| 67 |
}); |
69 |
}); |
| 68 |
- |
|
|