Changeset 921 for trunk/Modules/NetworkConfigRouterOS/Generators/Signal.php
- Timestamp:
- Feb 25, 2022, 9:30:55 AM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Modules/NetworkConfigRouterOS/Generators/Signal.php
r917 r921 39 39 $Read = $Routerboard->Read(false); 40 40 $Array = $Routerboard->ParseResponse($Read); 41 $NetworkMac = new NetworkMac($this->System); 41 42 foreach ($Array as $Properties) 42 43 { … … 75 76 $RateRx = $this->StripUnits($Properties['rx-rate']); 76 77 $RateTx = $this->StripUnits($Properties['tx-rate']); 78 $MacRef = $NetworkMac->GetIndex($Properties['mac-address']); 77 79 $Queries[] = 'INSERT INTO `NetworkSignal` (`MAC`, `Value`, `Remote`, `RateRx`, `RateTx`, `Time`, `Interface`, `Device`) VALUES '. 78 '( "'.$Properties['mac-address'].'", '.$Strength.', '.$RemoteSignal.', '.$RateRx.', '.$RateTx.', "'.80 '('.$MacRef.', '.$Strength.', '.$RemoteSignal.', '.$RateRx.', '.$RateTx.', "'. 79 81 TimeToMysqlDateTime($this->Time).'", '.$Interface.', '.$Device['Id'].')'; 80 82 } … … 98 100 return array(); 99 101 } 102 $NetworkMac = new NetworkMac($this->System); 100 103 foreach ($Array as $Properties) 101 104 { … … 119 122 120 123 $RateTx = $this->StripUnits($Properties['tx-phy-rate']); 124 125 $MacRef = $NetworkMac->GetIndex($Properties['remote-address']); 121 126 $Queries[] = 'INSERT INTO `NetworkSignal` (`MAC`, `Value`, `Remote`, `RateRx`, `RateTx`, `Time`, `Interface`, `Device`) VALUES '. 122 '( "'.$Properties['remote-address'].'", '.$Strength.', 0, 0, '.round($RateTx / 1000000).', "'.127 '('.$MacRef.', '.$Strength.', 0, 0, '.round($RateTx / 1000000).', "'. 123 128 TimeToMysqlDateTime($this->Time).'", '.$Interface.', '.$Device['Id'].')'; 124 129 }
Note:
See TracChangeset
for help on using the changeset viewer.