new style, first version (header, login, dashboard)
authorCiro Scognamiglio <ciro.scognamiglio@cslash.net>
Tue, 11 Feb 2014 17:40:11 +0000 (18:40 +0100)
committerCiro Scognamiglio <ciro.scognamiglio@cslash.net>
Tue, 11 Feb 2014 17:40:11 +0000 (18:40 +0100)
20 files changed:
.gitignore
auth/static/js/logout.js
devel/server-loop.sh
portal/img/icon_slices_color.png [new file with mode: 0644]
portal/img/icon_support.png [new file with mode: 0644]
portal/img/icon_testbed_color.png [new file with mode: 0644]
portal/img/icon_user_color.png [new file with mode: 0644]
portal/img/icon_users_color.png [new file with mode: 0644]
portal/static/css/onelab_marko.css
portal/templates/dashboard.html
portal/templates/home-view.html
ui/static/css/topmenu.css
ui/static/img/icon_slices.png [new file with mode: 0644]
ui/static/img/icon_support.png [new file with mode: 0644]
ui/static/img/icon_testbed_color.png [new file with mode: 0644]
ui/static/img/icon_user_color.png [new file with mode: 0644]
ui/static/img/icon_users_color.png [new file with mode: 0644]
ui/static/img/onelab-portal.png [new file with mode: 0644]
ui/templates/base.html
ui/templates/widget-topmenu.html

index bb1d472..bd9a874 100644 (file)
@@ -19,3 +19,5 @@ plugins/*/*.html
 myslice.ini*
 # other junk
 foo.*
+.project
+.pydevproject
index 1e140a9..c417bb5 100644 (file)
@@ -1,7 +1,7 @@
 /* retrieve username from the button that is clicked, the one named 'logout' 
    and that is expected to have the 'username' attribute */
 function logout () {
-    var username=$(this).attr('username');
+    var username=$(this).data('username');
     var msg="Are you sure you want to logout as " + username + " ?";
     /* redirect to /logout, see urls.py */
     if (confirm(msg)) window.location="/logout/";
index 1ac43e4..1d94e8e 100755 (executable)
@@ -3,7 +3,7 @@ DIRNAME=$(dirname $0)
 cd $DIRNAME/..
 
 # default port : if hostname starts with z -> use 8080 ; otherwise take 80
-hostname | grep -q '^z' && port=8080 || port=80
+hostname | grep -q '^z' && port=8080 || port=8080
 [[ -n "$@" ]] && port=$1
 
 while true; do 
diff --git a/portal/img/icon_slices_color.png b/portal/img/icon_slices_color.png
new file mode 100644 (file)
index 0000000..bd3bc34
Binary files /dev/null and b/portal/img/icon_slices_color.png differ
diff --git a/portal/img/icon_support.png b/portal/img/icon_support.png
new file mode 100644 (file)
index 0000000..6c77efc
Binary files /dev/null and b/portal/img/icon_support.png differ
diff --git a/portal/img/icon_testbed_color.png b/portal/img/icon_testbed_color.png
new file mode 100644 (file)
index 0000000..d1169d5
Binary files /dev/null and b/portal/img/icon_testbed_color.png differ
diff --git a/portal/img/icon_user_color.png b/portal/img/icon_user_color.png
new file mode 100644 (file)
index 0000000..a8ef8c6
Binary files /dev/null and b/portal/img/icon_user_color.png differ
diff --git a/portal/img/icon_users_color.png b/portal/img/icon_users_color.png
new file mode 100644 (file)
index 0000000..6cf3888
Binary files /dev/null and b/portal/img/icon_users_color.png differ
index d310399..1436169 100644 (file)
@@ -5,28 +5,16 @@
 /* GENERAL */
 
 .container {
-    padding: 0 !important;
-    color: #fff;
-    background: url(http://new.fit-equipex.fr/images/background.jpg) no-repeat;
+    padding: 0 ;
+    background-color:white;
+    color: black;
     margin: 0;
     width: 100%;
     max-width: 100%;
-    min-height: 100%;
+    min-height: 600px;
     height: 100%;
 }
 
-table {
-   color:white;
-}
-table.dataTable {
-   color:black;
-}
-
-
-.container h1, .container h2 {
-    color: #fff !important;
-}
-
 div.plugin-outline-complete, 
 div.plugin-outline-body {
     border: 0px solid;
@@ -64,13 +52,13 @@ a.plugin-tooltip:hover {
 
 /* LIST VIEW */
 div.well-lg {
-    background-color: rgba(168, 32, 202, 0.5) !important;
+    background-color: rgba(168, 32, 202, 0.5) ;
 }
 div.onelab-title {
-    background-color: rgba(168, 32, 202, 0.5) !important;
+    background-color: rgba(168, 32, 202, 0.5) ;
 }
 div.well {
-    background-color: rgba(0, 0, 0, 0.5) !important;
+    background-color: rgba(0, 0, 0, 0.5) ;
 }
 h2.well.well-lg {
     border-radius:0;
@@ -90,8 +78,8 @@ h2.well.well-lg {
 }
 
 #complete-resources {
-/*    background-color: #92f79e !important; */
-    background-color: #B8B2FF !important;
+/*    background-color: #92f79e ; */
+    background-color: #B8B2FF ;
 }
 
 #complete-filters {
@@ -100,17 +88,17 @@ h2.well.well-lg {
 }
 
 #complete-users {
-/*    background-color: #ff7394 !important; */
-    background-color: #add7ff !important;
+/*    background-color: #ff7394 ; */
+    background-color: #add7ff ;
 }
 /*
 #complete-measurements {
-    background-color: !important;
+    background-color: ;
 }
 */
 #complete-pending {
-/*    background-color: #add7ff !important; */
-    background-color: #B8B2FF !important;
+/*    background-color: #add7ff ; */
+    background-color: #B8B2FF ;
 
 }
 
@@ -144,77 +132,15 @@ h2.well.well-lg {
     opacity: 1;
 }
 
-.nav.nav-tabs {
-    font-family: Ubuntu, Arial, sans-serif;
-    border: 0 !important;
-    border-bottom: 3px solid #fff !important;
-    margin-bottom: 40px;
-}
-
-.nav.nav-tabs li.active a {
-    color: #572bc9;
-    border-left: 0px solid #572bc9;
-    border-top: 0px solid #572bc9;
-    border-right: 0px solid #572bc9;
-}
-
-.nav.nav-tabs li a {
-    color: #333;
-    border: 0 !important;
-    margin-right: 5px;
-}
-
-.nav.nav-tabs li a:hover {
-    color: #333;
-    background: #572bc9;
-    color: #fff;
-    border: 0 !important;
-}
-
-
-
-/* if window enlarged wider than background picture */
-body {
-    background: black !important;
-}
-
-/* TOPMENU.CSS */
 
-/* Thierry : turning this off
-body {
-    *//* background: #30196d !important; *//*
-    background: black !important;
-    padding-top: 60px;
-    padding-bottom: 0px;
-}
-Thierry */
-
-/* Thierry : turning this off
-div.topmenu { 
-    padding-top: 0px;
-    font-family: Ubuntu, Arial, sans-serif;
-    font-weight: bold;
-    background: #fff;
-    -webkit-box-shadow: 0px 10px 10px rgba(50, 50, 50, 0.44);
-    -moz-box-shadow:    0px 10px 10px rgba(50, 50, 50, 0.44);
-    box-shadow:         0px 10px 10px rgba(50, 50, 50, 0.44);
-}
-Thierry */
 
-/* Thierry : turning this off
-.navbar-nav li a,
-.navbar-nav li.other a {
-    padding-top: 25px;
-    padding-bottom: 20px;
-}
-Thierry */
 
 .navbar-nav li a:hover {
-    color: #572bc9 !important;
+    color: #572bc9 ;
 }
 
 .navbar-nav li.active a {
-    background: #eee !important;
+    background: #eee ;
 }
 
 /* Thierry : turning this off
@@ -290,7 +216,7 @@ input {
 div.dataTables_length label, 
 div.dataTables_filter label,
 div.dataTables_info {
-    font-family: Ubuntu, Arial, sans-serif !important;
+    font-family: Ubuntu, Arial, sans-serif ;
 }
 
 
@@ -300,42 +226,42 @@ div.dataTables_info {
 
 div.QueryTable table.dataTable th {
     font: bold 12px/22px Ubuntu, Arial, sans-serif;
-    color: #333 !important;
-    border-right: 0px solid #333 !important;
-    border-bottom: 0px solid #C1DAD7 !important;
-    border-top: 0px solid #C1DAD7 !important;
+    color: #333 ;
+    border-right: 0px solid #333 ;
+    border-bottom: 0px solid #C1DAD7 ;
+    border-top: 0px solid #C1DAD7 ;
     letter-spacing: 1px;
     text-transform: uppercase;
     text-align: left;
     padding: 8px 12px 4px 20px;
     vertical-align:middle;
-    background: url('../img/tablesort-header.png') no-repeat !important
+    background: url('../img/tablesort-header.png') no-repeat ; 
 }
 
 div.QueryTable table.dataTable td, div.QueryTable table.dataTable textarea, div.QueryTable table.dataTable input [type="text"] {
     font: normal 12px Ubuntu, Arial, Helvetica, sans-serif;
-    border-right: 0px solid #fff !important;
-    border-bottom: 1px solid #fff !important;
+    border-right: 0px solid #fff ;
+    border-bottom: 1px solid #fff ;
 }
 
 div.QueryTable table.dataTable thead { 
-    background: url('../img/tablesort-header.png') repeat-x !important;
+    background: url('../img/tablesort-header.png') repeat-x ;
     background-color: #caebea;
 }
 
 div.QueryTable table.dataTable tfoot { 
-    background: url('../img/tablesort-header.png') repeat-x !important;
-    /* background-color: # !important; */
+    background: url('../img/tablesort-header.png') repeat-x ;
+    /* background-color: # ; */
 }
 
 
 /* QUERY EDITOR */
 
 table.query-editor {
-    margin: 40px auto !important;
+    margin: 40px auto ;
     clear: both;
     /* width: 80%;*/
-    width: 100% !important;
+    width: 100% ;
     font-family: Ubuntu;
 }
 
@@ -345,12 +271,12 @@ table.query-editor {
 .plugin.Tabs 
 Thierry */
 {
-    margin-top: 60px !important;
+    margin-top: 60px ;
 }
 
 table.query-editor td {
-    padding: 5px 5px !important;
-    font: normal 12px Ubuntu, Arial, sans-serif !important;
+    padding: 5px 5px ;
+    font: normal 12px Ubuntu, Arial, sans-serif ;
 }
 
 
@@ -392,41 +318,143 @@ table.query-editor td {
 }
 
 .ms-dashboard-content ul {
-    list-style-type: none !important;
+    list-style-type: none ;
     padding-left: 0;
-    text-align: center !important;
+    text-align: center ;
 }
 
 .ms-dashboard-content {
-    padding: 0 !important;
-}
-
-.ms-dashboard-content a {
-    color: #ff7394 !important;
-/* color: #ff0099 !important; */
+    padding: 0 ;
 }
 
-.ms-dashboard-content a:hover {
-    color: white !important;
-}
-.ms-dashboard-caption h2 {
-    font-family: Ubuntu, Arial, sans-serif;
-    border-bottom: 0 !important;
-    text-transform: uppercase;
-}
 
 #ms-dashboard-profile>div.ms-dashboard-caption {
-    background: no-repeat url(#) !important;
-    padding-left: 0 !important;
+    background: no-repeat url(#) ;
+    padding-left: 0 ;
 }   
 
 #ms-dashboard-testbeds>div.ms-dashboard-caption {
-    background: no-repeat url(#) !important;
-    padding-left: 0 !important;
+    background: no-repeat url(#) ;
+    padding-left: 0 ;
 }   
 
 #ms-dashboard-slices>div.ms-dashboard-caption {
-    background: no-repeat url(#) !important;
-    padding-left: 0 !important;
+    background: no-repeat url(#) ;
+    padding-left: 0 ;
 }   
 
+
+
+
+
+
+
+
+
+/*** NEW CSS STYLES FOR ONLEAB ***/
+
+body {
+    background-color:white;
+    color:black;
+}
+div.wrapper {
+    width:980px;
+    margin:0 auto;
+    position:relative;
+}
+/* HEADER */
+div#header {
+    height:100px;
+    background-color:white;
+}
+
+div#secondary {
+    
+}
+
+div#secondary ul {
+    position:absolute;
+    top:20px;
+    right:0;
+}
+
+div#secondary li {
+    font-size:10pt;
+    float:left;
+    list-style:none;
+    margin-right:30px;
+}
+div#secondary li:last-child {
+    margin-right:0;
+}
+
+div#navigation {
+    background-color:black;
+    width:100%;
+    height:40px;
+}
+div#navigation div.wrapper {
+    text-align:center;
+}
+div#navigation ul {
+    margin:0;
+    padding:0;
+    display: inline-block;
+    list-style-type: none;
+    white-space: nowrap;
+}
+
+div#navigation li {
+    color:white;
+    font-family:helvetica, sans-serif;
+    font-size:10pt ;
+    font-weight:normal;
+    line-height:0.8em;
+    letter-spacing:0.6pt;
+    list-style:none;
+    float:left;
+    padding:0;
+    margin:15px 50px 0 0;
+}
+div#navigation li a {
+    color:white;
+}
+div#navigation li a:hover {
+    text-decoration:none;
+    color:#B8B2FF;
+}
+div#navigation li:last-child {
+    margin-right:0;
+}
+
+/* HOME DASHBOARD */
+div#home-dashboard {
+    color:black;
+    margin:25px 0;
+}
+div#home-dashboard table {
+    margin:25px;
+    width:100%;
+}
+div#home-dashboard table td {
+    text-align:center;
+    padding:15px 0;
+}
+/**/
+
+/* NAV TABS */
+
+.nav.nav-tabs {
+}
+
+.nav.nav-tabs li.active a {
+   
+}
+
+.nav.nav-tabs li a {
+}
+
+.nav.nav-tabs li a:hover {
+}
+
+/**/
\ No newline at end of file
index e4c61b4..3ef7914 100644 (file)
@@ -7,7 +7,6 @@
 
 <div id='tophat_status'></div>
 <div id='ms-dashboard'>
-
   <div class="container">
     <div class="row">
       <div class='col-xs-4' id="ms-dashboard-profile">
index c5f3bfc..ec1f54b 100644 (file)
@@ -6,25 +6,35 @@
 {% endblock unfold_margin %}
 
 {% block unfold_main %}
-<link rel="stylesheet" type="text/css" href="{{STATIC_URL}}/css/onelab.css" />
 <!-- xxx ideally only onelab.css but ... xxx -->
 <link rel="stylesheet" type="text/css" href="{{STATIC_URL}}/css/registration.css" />
-<div class='well-lg onelab-title'>
-  <h2 style="font-weight: bold;">Welcome to the OneLab portal !</h2>
-  <h4>New to OneLab? Please <a href="/portal/register">register</a> or learn more about <a href="http://www.onelab.eu/" target="_blank">the project</a>.</h3>
-</div>
-<div class='well'>
-<p>
-Experimentally-driven research is key to success in exploring the possible
-futures of the Internet. The OneLab initiative provides an open,
-general-purpose, shared experimental facility, both large-scale and
-sustainable, which allows European industry and academia to innovate and assess
-the performance of their solutions. Based on the results of several different
-European and national projects, OneLab offers access to a range of  tools and
-testbeds including PlanetLab Europe, the NITOS wireless testbed, and other
-federated testbeds.
-</p>
-<p>This UI server is connected to the manifold backend running at <code>{{ MANIFOLD_URL }}</code>.</p>
+       <div id="home-dashboard">
+       <ul class="nav nav-tabs">
+         <li class="active"><a href="#">USER</a></li>
+         <li><a href="#">MANAGER</a></li>
+       </ul>
+       <div id="user">
+               <table>
+                       <tr>
+                               <td>PROFILE</td>
+                               <td>SLICES</td>
+                               <td>SUPPORT</td>
+                       </tr>
+                       <tr>
+                               <td><img src="{{ STATIC_URL }}img/icon_user_color.png" alt="" /></td>
+                               <td><img src="{{ STATIC_URL }}img/icon_slices.png" alt="" /></td>
+                               <td><img src="{{ STATIC_URL }}img/icon_support.png" alt="" /></td>
+                       </tr>
+                       <tr>
+                               <td>
+                                       <a href="/portal/register">Register</a>
+                               </td>
+                       </tr>
+               </table>
+       </div>
+       <div id="manager">
+               
+       </div>
 </div>
 
 {% endblock unfold_main %}
index 70acc0e..e66404e 100644 (file)
@@ -1,6 +1,5 @@
 /* this is to get the content below the navbar */
 body {
-    padding-top: 60px;
 }
 
 /* center the buttons vertically in the header */
diff --git a/ui/static/img/icon_slices.png b/ui/static/img/icon_slices.png
new file mode 100644 (file)
index 0000000..bd3bc34
Binary files /dev/null and b/ui/static/img/icon_slices.png differ
diff --git a/ui/static/img/icon_support.png b/ui/static/img/icon_support.png
new file mode 100644 (file)
index 0000000..6c77efc
Binary files /dev/null and b/ui/static/img/icon_support.png differ
diff --git a/ui/static/img/icon_testbed_color.png b/ui/static/img/icon_testbed_color.png
new file mode 100644 (file)
index 0000000..d1169d5
Binary files /dev/null and b/ui/static/img/icon_testbed_color.png differ
diff --git a/ui/static/img/icon_user_color.png b/ui/static/img/icon_user_color.png
new file mode 100644 (file)
index 0000000..a8ef8c6
Binary files /dev/null and b/ui/static/img/icon_user_color.png differ
diff --git a/ui/static/img/icon_users_color.png b/ui/static/img/icon_users_color.png
new file mode 100644 (file)
index 0000000..6cf3888
Binary files /dev/null and b/ui/static/img/icon_users_color.png differ
diff --git a/ui/static/img/onelab-portal.png b/ui/static/img/onelab-portal.png
new file mode 100644 (file)
index 0000000..c7e4404
Binary files /dev/null and b/ui/static/img/onelab-portal.png differ
index 49a57ad..f29b71b 100644 (file)
@@ -1,6 +1,6 @@
-{# This is required by insert_above #}{% insert_handler %}<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
-<html lang="en"> <head>
-<title> MySlice - {{ title }} </title>
+{# This is required by insert_above #}{% insert_handler %}<!DOCTYPE html>
+<html lang="en"><head>
+<title>MySlice - {{ title }}</title>
 <meta name="viewport" content="width=device-width, initial-scale=1.0">
 <link rel="shortcut icon" href="/static/img/myslice-icon.png">
 {# This is where insert_str will end up #}{% media_container prelude %}
index 089bd3c..ee88601 100644 (file)
@@ -2,45 +2,44 @@
 {% insert_str prelude "css/bootstrap.css" %}
 {% insert_str prelude "css/topmenu.css" %}
 {% insert_str prelude "js/logout.js" %}
-<nav class="navbar navbar-default navbar-fixed-top" role="navigation">
-  <div class="navbar-header">
-    <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-myslice-collapse">
-      <span class="sr-only">Toggle navigation</span>
-      <span class="icon-bar"></span>
-      <span class="icon-bar"></span>
-      <span class="icon-bar"></span>
-    </button>
-    <a class="navbar-brand" href="/">
-      <img src="{{ STATIC_URL }}img/onelab-logo.png" height="30" alt="OneLab logo" />
-    </a>
-  </div>
-  <div class="collapse navbar-collapse navbar-myslice-collapse topmenu">
-    <ul class="nav navbar-nav">
-       {% for d in topmenu_items %} 
-       {% if d.dropdown %}
-       {% if d.is_active %} <li class='active'> {% else %} <li class='other'> {% endif %}
-         <a class="dropdown-toggle" data-toggle="dropdown" href="{{ d.href }}">{{ d.label }}<b class="caret"></b></a>
-         <ul class="dropdown-menu">
-           {% for dd in d.contents %}
-           <li class='{% if dd.is_active %}active{% else %}other{% endif %}{% if dd.disabled %} disabled{%endif%}'
-           {% if dd.domid %} id='{{dd.domid}}'{% endif %}>
-           <a href="{{ dd.href }}"> {{ dd.label }} </a> </li>
-           {% endfor %}
-         </ul>
-        </li>
-        {% else %} 
-       <li class='{% if d.is_active %}active{% else %}other{% endif %}{% if d.disabled %} disabled{%endif%}'
-       {% if d.domid %} id='{{d.domid}}'{% endif %}>
-       <a href="{{ d.href }}"> {{ d.label }} </a> </li>
+
+
+
+<div id="header">
+       <div class="wrapper">
+               <div class="logo">
+                       <a href="/"><img src="{{ STATIC_URL }}img/onelab-portal.png" alt="OneLab - Future Internet Testbeds" /></a>
+               </div>
+               
+               <div id="secondary">
+                       <ul>
+                               <li>News</li>
+                               <li>About</li>
+                               <li><a target="_blank" href="http://www.onelab.eu">Public Website</a></li>
+                               <li>Intranet</li>
+                       </ul>
+               </div>
+       </div>
+       
+       {% if username %}
+       <div id="navigation">
+               <div class="wrapper">
+               <ul>
+                       <li>SLICES</li>
+                       <li>REQUESTS</li>
+                       <li>INSTITUTION</li>
+                       <li><a href="/portal/contact/">SUPPORT</a></li>
+                       <li>|</li>
+                       <li>{{ username }}</li>
+                       <li><a id="logout" data-username="{{ username }}">LOGOUT</a></li>
+               </ul>
+               </div>
+       </div>
+       {% else %}
+       <div id="navigation">
+               <div class="wrapper"></div>
+       </div>
        {% endif %}
-       {% endfor %}
-    </ul> {# logout.js will attach a click function on that button, which then retrieves the 'username' attribute #}
-    <ul class="nav navbar-nav pull-right logged-in">
-      <li class='username'> {% if username %}
-      Logged in as {{ username }}
-      <button id='logout' class='btn btn-xs btn-danger logged-in' username='{{ username }}'>Logout</button> {% else %}
-      Not logged in{% endif %}
-      </li>
-    </ul>
-  </div>
-</nav>
+</div>
+
+