mirror of
				https://github.com/librenms/librenms.git
				synced 2024-10-07 16:52:45 +00:00 
			
		
		
		
	* New Device Support for ICT DC Distribution Panels * Fixed indexes, removed tests * Supply name instead of oid to snmp_get call * Fixed index conflict for current sensors
		
			
				
	
	
		
			10 lines
		
	
	
		
			271 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			10 lines
		
	
	
		
			271 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
<?php
 | 
						|
 | 
						|
$oid_sensor = $sensor['sensor_oid'];
 | 
						|
 | 
						|
if ($oid_sensor == '.1.3.6.1.4.1.39145.10.8.1.4.0') {
 | 
						|
    $sensor_value = trim(str_replace('"', '', $snmp_data[$oid_sensor]));
 | 
						|
} else {
 | 
						|
    $sensor_value = trim(str_replace('"', '', $snmp_data[$sensor['sensor_oid'].'.0']));
 | 
						|
}
 |