NIHVIVO-2944 Updated JS for accounts-per-page to ensure both select lists (top of the page and bottom of the page) allow the selection of number of accounts per page.
This commit is contained in:
parent
1969089cdd
commit
b221215871
1 changed files with 7 additions and 2 deletions
|
@ -9,15 +9,20 @@ function changeAction(form, url) {
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
|
|
||||||
//Accounts per page
|
//Accounts per page
|
||||||
//Hide is javascrip is enable
|
//Hide if javascript is enabled
|
||||||
$('input[name="accounts-per-page"]').addClass('hidden');
|
$('input[name="accounts-per-page"]').addClass('hidden');
|
||||||
|
|
||||||
$('.accounts-per-page').change(function() {
|
$('.accounts-per-page').change(function() {
|
||||||
|
// ensure both accounts-per-page select elements are
|
||||||
|
// set to the same value before submitting
|
||||||
|
var selectedValue = $(this).val();
|
||||||
|
$('.accounts-per-page').val(selectedValue);
|
||||||
|
alert(selectedValue);
|
||||||
$('#account-display').submit();
|
$('#account-display').submit();
|
||||||
});
|
});
|
||||||
|
|
||||||
//Delete accounts
|
//Delete accounts
|
||||||
//Show is javascript is enable
|
//Show is javascript is enabled
|
||||||
$('input:checkbox[name=delete-all]').removeClass('hidden');
|
$('input:checkbox[name=delete-all]').removeClass('hidden');
|
||||||
|
|
||||||
$('input:checkbox[name=delete-all]').click(function(){
|
$('input:checkbox[name=delete-all]').click(function(){
|
||||||
|
|
Loading…
Add table
Reference in a new issue