mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-28 08:02:41 +02:00
make billing usable (shonky interface it now has!)
git-svn-id: http://www.observium.org/svn/observer/trunk@1227 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
+2
-28
@@ -1,33 +1,7 @@
|
||||
<script type="text/javascript" src="<?php echo($config['base_url']); ?>/js/tw-sack.js"></script>
|
||||
<script type="text/javascript">
|
||||
|
||||
|
||||
var ajax = new Array();
|
||||
|
||||
function getInterfaceList(sel)
|
||||
{
|
||||
var deviceId = sel.options[sel.selectedIndex].value;
|
||||
document.getElementById('interface_id').options.length = 0; // Empty city select box
|
||||
if(deviceId.length>0){
|
||||
var index = ajax.length;
|
||||
ajax[index] = new sack();
|
||||
|
||||
ajax[index].requestFile = '<?php echo($config['base_url']); ?>/ajax/list_ports.php?device_id='+deviceId; // Specifying which file to get
|
||||
ajax[index].onCompletion = function(){ createInterfaces(index) }; // Specify function that will be executed after file has been found
|
||||
ajax[index].runAJAX(); // Execute AJAX function
|
||||
}
|
||||
}
|
||||
|
||||
function createInterfaces(index)
|
||||
{
|
||||
var obj = document.getElementById('interface_id');
|
||||
eval(ajax[index].response); // Executing the response from Ajax as Javascript code
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<?php
|
||||
|
||||
include("includes/javascript-interfacepicker.inc.php");
|
||||
|
||||
echo("<div style='margin: 10px;'>");
|
||||
|
||||
if($_SESSION['userlevel'] != '10') { include("includes/error-no-perm.inc.php"); } else {
|
||||
|
||||
Reference in New Issue
Block a user