From e8778df3e99127e6f357808f3c8c5c91612e6d79 Mon Sep 17 00:00:00 2001 From: Tom Laermans Date: Fri, 4 Jun 2010 16:18:55 +0000 Subject: [PATCH] forgot another frequencies page, added basic apc mgmt card detection support git-svn-id: http://www.observium.org/svn/observer/trunk@1101 61d68cd4-352d-0410-923a-c4978735b2b8 --- html/images/os/apc.png | Bin 0 -> 1112 bytes .../pages/device/overview/frequencies.inc.php | 45 ++++++++++++++++++ includes/polling/device-apc.inc.php | 9 ++++ 3 files changed, 54 insertions(+) create mode 100644 html/images/os/apc.png create mode 100644 html/pages/device/overview/frequencies.inc.php create mode 100755 includes/polling/device-apc.inc.php diff --git a/html/images/os/apc.png b/html/images/os/apc.png new file mode 100644 index 0000000000000000000000000000000000000000..7bf9f73f12041d2f483e57972e473fbf380e9c43 GIT binary patch literal 1112 zcmV-e1gHCnP)Px#24YJ`L;(K){{a7>y{D4^000SaNLh0L01FcU01FcV0GgZ_00007bV*G`2igV% z4=oeWo2wE400Y=bL_t(o!|j(}h*d=xz<=MIv*(<9@A`+AL61TZg%W0~&}yOhpk=k%qNPQorMB+hd++%(^Yw7| zitZxXOZ#$%1Lts0fZSWK7gv~Omr?HVwmC51ZV;@0WJf`q>x0Wi%D)! zR?}hyxn8W_c+h%HQDvHxwBE8@Pgtsrs*M+o>jnS-DEEr6m5*g@>qTHLf12m@$e7k; zsqe~)TpRiPI5))?xNte_X5a_L;t%ymT89v+_g@G8NS5Y1nb%>-%n0#?HTvzPhJl4C zBl}q%eAS?DLs(HNK7^kv)_qUa8+tUqlIoy`YlpyHId+3q9my{lvc0JNJ9?$ptf#*e z!Ydx(3P+L$3k0c;4t&MX>o3eZdFCpB{nE4GR+2Lw)>jOIkE51Vi5}|IzHb1IOV<-E zR5p1;HJv=k6g427f^Boeq|DlAh}(VK*7^*1fSw08sz|{jYd;3tHq1Zy#Z>@<(*2oF zZM_hUTFh>bbOZQ-CE0Zd9)Cvr<7>_7DJi}0p&P*yhZ_=H&d`!`q-jj{h7#=#@WwN; z9Arxhc*hoM-%+1(SpXf7p6-xJ$uOIYiNW89p1T9@J|Qa_O!rd!l?wZQlt=Cku96*68Lz_1QkmKp^!JUM3zw;(T<|_m#3V9-ViB~%;1z{%5ws4b$l(L*cXEV>7Zk|+ z6wi!vZg{yKAKD{5;UeN&DvV67_#6O^SVLO#9%&V-SlYY;oId-Ko{FcYS~_VO0XZlS zES$~kIS%KPu}k;sp|eU|Sc0ltxwS+@{%ekSb&Lp;t4t7S*zj6$(@fY*N}B*pfF{8I e?t+>AJ^vTo;m6hri?r$h0000"); + echo("

Frequencies

"); + $i = '1'; + $freqs = mysql_query("SELECT * FROM frequency WHERE device_id = '" . $device['device_id'] . "'"); + echo(""); + echo(""); + echo("
"); + echo(""); + while($freq = mysql_fetch_array($freqs)) { + if(is_integer($i/2)) { $row_colour = $list_colour_a; } else { $row_colour = $list_colour_b; } + + $graph_colour = str_replace("#", "", $row_colour); + + $freq_day = "graph.php?id=" . $freq['freq_id'] . "&type=frequency&from=$day&to=$now&width=300&height=100"; + $freq_week = "graph.php?id=" . $freq['freq_id'] . "&type=frequency&from=$week&to=$now&width=300&height=100"; + $freq_month = "graph.php?id=" . $freq['freq_id'] . "&type=frequency&from=$month&to=$now&width=300&height=100"; + $freq_year = "graph.php?id=" . $freq['freq_id'] . "&type=frequency&from=$year&to=$now&width=300&height=100"; + $freq_minigraph = ""; + + $freq_link = ""; + + $freq_link_c = $freq_link . " $freq['freq_limit'] ? "style='color: red'" : '') . '>' . $freq['freq_current'] . "Hz"; + $freq_link_b = $freq_link . $freq_minigraph . ""; + $freq_link_a = $freq_link . $freq['freq_descr'] . ""; + + $freq['freq_descr'] = truncate($freq['freq_descr'], 25, ''); + echo(""); + if($i == $rows) { echo("
$freq_link_a$freq_link_b$freq_link_c
"); } + $i++; + } + echo("
"); + echo("
"); + echo(""); +} + + +?> diff --git a/includes/polling/device-apc.inc.php b/includes/polling/device-apc.inc.php new file mode 100755 index 000000000..e84b32080 --- /dev/null +++ b/includes/polling/device-apc.inc.php @@ -0,0 +1,9 @@ +