Changeset 868
- Timestamp:
- Jan 13, 2020, 1:10:38 AM (5 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Application/Version.php
r867 r868 1 1 <?php 2 2 3 $Revision = 86 7; // Subversion revision3 $Revision = 868; // Subversion revision 4 4 $DatabaseRevision = 867; // SQL structure revision 5 5 $ReleaseTime = strtotime('2020-01-13'); -
trunk/Modules/Network/Network.php
r867 r868 816 816 $Output = ''; 817 817 $Condition = 'WHERE (`NetworkInterface`.`LastOnline` <= "'.TimeToMysqlDateTime($Time - $MinDuration).'")'; 818 if ($OnlineNow != null) $Condition .= ' AND (`NetworkInterface`.`Online` = '.$OnlineNow.')'; 819 if ($OnlinePrevious != null) $Condition .= ' AND (`NetworkInterface`.`OnlineNotify` = '.$OnlinePrevious.')'; 818 echo($OnlineNow); 819 if ($OnlineNow >= 0) $Condition .= ' AND (`NetworkInterface`.`Online` = '.$OnlineNow.')'; 820 echo($OnlinePrevious); 821 if ($OnlinePrevious >= 0) $Condition .= ' AND (`NetworkInterface`.`OnlineNotify` = '.$OnlinePrevious.')'; 822 echo($Condition."\n"); 820 823 $DbResult3 = $this->Database->query('SELECT CONCAT_WS("-", `NetworkDevice`.`Name`, NULLIF(`NetworkInterface`.`Name`, "")) AS `Name`, '. 821 824 '`NetworkInterface`.`Online`, `NetworkInterface`.`LastOnline` FROM `NetworkInterface` '. … … 854 857 $NewOffline = $this->OnlineList('Nově offline', 0, 1, $this->MinNotifyTime); 855 858 $Output .= $NewOffline['Report']; 856 if ($Output != '') 857 { 858 $StillOffline = $this->OnlineList('Stále offline', 0, 0, 0); 859 $Output .= $StillOffline['Report']; 860 } 861 $Offline = $this->OnlineList('Offline', 0, null, 0); 859 $StillOffline = $this->OnlineList('Stále offline', 0, 0, 0); 860 $Output .= $StillOffline['Report']; 861 $Offline = $this->OnlineList('Offline', 0, -1, 0); 862 862 return(array('Report' => $Output, 'Count' => $Offline['Count'], 'ShortTitle' => 'Odezva')); 863 863 } … … 869 869 $Output = ''; 870 870 $Condition = 'WHERE (`NetworkPort`.`LastOnline` <= "'.TimeToMysqlDateTime($Time - $MinDuration).'")'; 871 if ($OnlineNow != null) $Condition .= ' AND (`NetworkPort`.`Online` = '.$OnlineNow.')';872 if ($OnlinePrevious != null) $Condition .= ' AND (`NetworkPort`.`OnlineNotify` = '.$OnlinePrevious.')';871 if ($OnlineNow >= null) $Condition .= ' AND (`NetworkPort`.`Online` = '.$OnlineNow.')'; 872 if ($OnlinePrevious >= null) $Condition .= ' AND (`NetworkPort`.`OnlineNotify` = '.$OnlinePrevious.')'; 873 873 $DbResult3 = $this->Database->query('SELECT CONCAT(CONCAT_WS("-", `NetworkDevice`.`Name`, NULLIF(`NetworkInterface`.`Name`, "")), ":", `NetworkPort`.`Number`, "(", `NetworkPort`.`Name`, ")") AS `Name`, '. 874 874 '`NetworkPort`.`Online`, `NetworkPort`.`LastOnline` FROM `NetworkPort` '. … … 909 909 $NewOffline = $this->PortCheckList('Nově offline', 0, 1, $this->MinNotifyTime); 910 910 $Output .= $NewOffline['Report']; 911 if ($Output != '') 912 { 913 $StillOffline = $this->PortCheckList('Stále offline', 0, 0, 0); 914 $Output .= $StillOffline['Report']; 915 } 916 $Offline = $this->PortCheckList('Offline', 0, null, 0); 911 $StillOffline = $this->PortCheckList('Stále offline', 0, 0, 0); 912 $Output .= $StillOffline['Report']; 913 $Offline = $this->PortCheckList('Offline', 0, -1, 0); 917 914 return(array('Report' => $Output, 'Count' => $Offline['Count'], 'ShortTitle' => 'Port')); 918 915 } -
trunk/Modules/Notify/Notify.php
r867 r868 97 97 { 98 98 $Mail = new Mail(); 99 $Mail->Subject = 'Notification';99 $Mail->Subject = $Title; 100 100 $Mail->AddTo($User['Value'], $User['Name']); 101 101 $Mail->AddBody(strip_tags($Content), 'text/plain'); … … 109 109 $Output .= strip_tags(str_replace("</", " </", str_replace('<br/>', "\n", $Content))); 110 110 } 111 112 return($Output);113 111 } 114 112 … … 121 119 ); 122 120 } 121 122 return($Output); 123 123 } 124 124
Note:
See TracChangeset
for help on using the changeset viewer.