[Pkg-nagios-changes] [SCM] UNNAMED PROJECT branch, debian/master, updated. 810edbdd3feedbfe37f4a65bee50b57b2f60fa2a

Frescha frescha at unitedseed.de
Tue Feb 28 22:12:36 UTC 2012


The following commit has been merged in the debian/master branch:
commit 27064f41b733345e8a1476b5599697f8c9654263
Author: Frescha <frescha at unitedseed.de>
Date:   Sun Jan 8 16:56:53 2012 +0100

    Add: Log mockup

diff --git a/contrib/ui/mockups/log/css/log.css b/shinken/webui/plugins/system/htdocs/css/log.css
similarity index 100%
copy from contrib/ui/mockups/log/css/log.css
copy to shinken/webui/plugins/system/htdocs/css/log.css
diff --git a/shinken/webui/plugins/system/system.py b/shinken/webui/plugins/system/system.py
index 5e80d6f..35409be 100644
--- a/shinken/webui/plugins/system/system.py
+++ b/shinken/webui/plugins/system/system.py
@@ -1,3 +1,26 @@
+#!/usr/bin/env python
+# Copyright (C) 2009-2012 :
+#    Gabes Jean, naparuba at gmail.com
+#    Gerhard Lausser, Gerhard.Lausser at consol.de
+#    Gregory Starck, g.starck at gmail.com
+#    Hartmut Goebel, h.goebel at goebel-consult.de
+#    Andreas Karfusehr, andreas at karfusehr.de
+#
+# This file is part of Shinken.
+#
+# Shinken is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# Shinken is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with Shinken.  If not, see <http://www.gnu.org/licenses/>.
+
 ### Will be populated by the UI with it's own value
 app = None
 
@@ -18,4 +41,23 @@ def system_page():
             'receivers' : receivers, 'pollers' : pollers,
             }
 
-pages = {system_page : { 'routes' : ['/system', '/system/'], 'view' : 'system', 'static' : True}}
\ No newline at end of file
+def show_log():
+    user = app.get_user_auth()
+
+    if not user:
+        redirect("/user/login")
+    
+    schedulers = app.datamgr.get_schedulers()
+    brokers = app.datamgr.get_brokers()
+    reactionners = app.datamgr.get_reactionners()
+    receivers = app.datamgr.get_receivers()
+    pollers = app.datamgr.get_pollers()
+
+    return {'app' : app, 'user' : user, 'schedulers' : schedulers,
+            'brokers' : brokers, 'reactionners' : reactionners,
+            'receivers' : receivers, 'pollers' : pollers,
+            }
+
+pages = {system_page : { 'routes' : ['/system', '/system/'], 'view' : 'system', 'static' : True},
+         show_log : { 'routes' : ['/system/log'], 'view' : 'log', 'static' : True},
+         }
\ No newline at end of file
diff --git a/shinken/webui/plugins/system/views/log.tpl b/shinken/webui/plugins/system/views/log.tpl
new file mode 100644
index 0000000..cdd93cf
--- /dev/null
+++ b/shinken/webui/plugins/system/views/log.tpl
@@ -0,0 +1,54 @@
+%rebase layout globals(), css=['system/css/log.css'], title='Architecture state', menu_part='/system'
+
+%from shinken.bin import VERSION
+%helper = app.helper
+
+%#  "Left Container Start"
+<div id="left_container" class="grid_2">
+	<div id="nav_left">
+		<ul>
+			<li><a href="/system">System</a></li>
+			<li><a href="/system/log">Log</a></li>
+		</ul>
+	</div>
+</div>
+%#  "Left Container End"
+
+<div id="system_overview" class="grid_14 item">
+	
+	<div id="messagebox" class="gradient_alert" style="margin-top: 20px;">
+		<img src="/static/images/icons/alert.png" alt="some_text" style="height: 40px; width: 40px" class="grid_4"/> 
+		<p><strong>Mockup</strong></p>
+	</div>
+	
+	<h2>Log</h2>
+	<!-- stats overview start -->
+
+	<!-- stats overview end -->
+</div>
+
+<!-- Log Contaier START -->
+
+<div id="log_container" class="grid_14">
+	<h2>Datum 1</h2>
+	<ol>
+		<li>Ent 1</li>
+		<li class="row_alt">Ent 2</li>
+		<li>Ent 3</li>
+	</ol>
+					
+	<h2>Datum 2</h2>
+	<ol>
+		<li>Ent 1</li>
+		<li class="row_alt">Ent 2</li>
+		<li>Ent 3</li>
+		<li class="row_alt">Ent 3</li>
+		<li>Ent 4</li>
+		<li class="row_alt">Ent 6</li>
+		<li>Ent 7</li>
+		<li class="row_alt">Ent 8</li>
+		<li>Ent 9</li>
+		<li class="row_alt">Ent 10</li>
+	</ol>
+</div>
+<!-- Log Contaier START -->
\ No newline at end of file
diff --git a/shinken/webui/plugins/system/views/system.tpl b/shinken/webui/plugins/system/views/system.tpl
index a9faf5e..5320d95 100644
--- a/shinken/webui/plugins/system/views/system.tpl
+++ b/shinken/webui/plugins/system/views/system.tpl
@@ -3,7 +3,18 @@
 %from shinken.bin import VERSION
 %helper = app.helper
 
-<div id="system_overview" class="grid_16 item">
+%#  "Left Container Start"
+<div id="left_container" class="grid_2">
+	<div id="nav_left">
+		<ul>
+			<li><a href="/system">System</a></li>
+			<li><a href="/system/log">Log</a></li>
+		</ul>
+	</div>
+</div>
+%#  "Left Container End"
+
+<div id="system_overview" class="grid_14 item">
 	<h2>System Overview</h2>
 	<!-- stats overview start -->
 		<table style="width: 100%">
@@ -19,27 +30,13 @@
 			</tbody>
 		</table> 
 	<!-- stats overview end -->
-	<!--
-	<ul>
-		<li> <a href="#">Arbiter</a></li>
-		<li> <a href="#">State</a> </li>
-		<li> <a href="#">Name</a> </li>
-		<li> <a href="#">Alive</a> </li>
-		<li> <a href="#">Attempts</a> </li>
-		<li> <a href="#">Last Check</a> </li>
-		<li> <a href="#">Realm</a> </li>
-	</ul>
-	-->
 </div>
 
-
-
 <!-- System Detail START -->
 
-<div id="system_detail" class="grid_16">
-
+<div id="system_detail" class="grid_14">
 	<ul>
-		%types = [ ('scheduler', schedulers), ('poller', pollers), ('broker', brokers), ('reactionner', reactionners), ('receiver', receivers)]
+	%types = [ ('scheduler', schedulers), ('poller', pollers), ('broker', brokers), ('reactionner', reactionners), ('receiver', receivers)]
 	%for (sat_type, sats) in types:
 		<li class="grid_3">
 		<a  class="box_round_small">
@@ -70,8 +67,7 @@
  				%end
 		</a>
 		</li>
-			%# end of this satellite type
+		%# end of this satellite type
  	%end
 	</ul>
-
 </div>	
\ No newline at end of file

-- 
UNNAMED PROJECT



More information about the Pkg-nagios-changes mailing list