mirror of
https://github.com/tuxis-ie/nsedit.git
synced 2025-04-20 20:13:40 +03:00
Use events, not own stuff to fix caching of users
This commit is contained in:
parent
b51ae193eb
commit
4a2ce77bf5
1 changed files with 6 additions and 8 deletions
14
index.php
14
index.php
|
@ -168,7 +168,6 @@ $(document).ready(function () {
|
||||||
owner: {
|
owner: {
|
||||||
title: 'Owner',
|
title: 'Owner',
|
||||||
options: function(data) {
|
options: function(data) {
|
||||||
data.clearCache();
|
|
||||||
return 'users.php?action=listoptions';
|
return 'users.php?action=listoptions';
|
||||||
},
|
},
|
||||||
defaultValue: 'admin'
|
defaultValue: 'admin'
|
||||||
|
@ -513,24 +512,17 @@ $(document).ready(function () {
|
||||||
domsearch: $('#domsearch').val()
|
domsearch: $('#domsearch').val()
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
$('#MasterZones').jtable('load');
|
|
||||||
$('#SlaveZones').jtable('load');
|
|
||||||
<? if (is_adminuser()) { ?>
|
<? if (is_adminuser()) { ?>
|
||||||
$('#Users').hide();
|
$('#Users').hide();
|
||||||
$('#useradmin').click(function () {
|
$('#useradmin').click(function () {
|
||||||
$('#Users').jtable('reload');
|
|
||||||
$('#Users').show();
|
$('#Users').show();
|
||||||
$('#MasterZones').hide();
|
$('#MasterZones').hide();
|
||||||
$('#SlaveZones').hide();
|
$('#SlaveZones').hide();
|
||||||
});
|
});
|
||||||
$('#zoneadmin').click(function () {
|
$('#zoneadmin').click(function () {
|
||||||
$('#Users').hide();
|
$('#Users').hide();
|
||||||
$('#MasterZones').jtable('reload');
|
|
||||||
$('#MasterZones').show();
|
$('#MasterZones').show();
|
||||||
$('#SlaveZones').jtable('reload');
|
|
||||||
$('#SlaveZones').show();
|
$('#SlaveZones').show();
|
||||||
$('#MasterZones').jtable('load');
|
|
||||||
$('#SlaveZones').jtable('load');
|
|
||||||
});
|
});
|
||||||
$('#Users').jtable({
|
$('#Users').jtable({
|
||||||
title: 'Users',
|
title: 'Users',
|
||||||
|
@ -564,8 +556,14 @@ $(document).ready(function () {
|
||||||
type: 'checkbox',
|
type: 'checkbox',
|
||||||
values: {'0': 'No', '1': 'Yes'}
|
values: {'0': 'No', '1': 'Yes'}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
recordAdded: function() {
|
||||||
|
$("#MasterZones").jtable('reload');
|
||||||
|
$("#SlaveZones").jtable('reload');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
$('#MasterZones').jtable('load');
|
||||||
|
$('#SlaveZones').jtable('load');
|
||||||
$('#Users').jtable('load');
|
$('#Users').jtable('load');
|
||||||
$('#ImportZone').jtable('load');
|
$('#ImportZone').jtable('load');
|
||||||
<? } ?>
|
<? } ?>
|
||||||
|
|
Loading…
Add table
Reference in a new issue