Merge branch 'onelab' of ssh://git.onelab.eu/git/myslice into fibre
authorLoic Baron <loic.baron@lip6.fr>
Thu, 24 Jul 2014 09:34:22 +0000 (06:34 -0300)
committerLoic Baron <loic.baron@lip6.fr>
Thu, 24 Jul 2014 09:34:22 +0000 (06:34 -0300)
manifoldapi/static/js/manifold.js
plugins/filter_status/static/js/filter_status.js
plugins/filter_status/templates/filter_status.html
plugins/testbeds/templates/testbeds.html
portal/slicerequestview.py
portal/static/css/onelab.css
portal/templates/slice-resource-view.html

index fe76629..178108d 100644 (file)
@@ -463,7 +463,7 @@ function QueryStore() {
     {
         var query_ext = this.find_analyzed_query_ext(query_uuid);
         query_ext.filters = $.grep(query_ext.filters, function(x) {
-            return x == filter;
+            return x != filter;
         });
 
         this.apply_filters(query_uuid);
@@ -1833,6 +1833,7 @@ case TYPE_LIST_OF_VALUES:
             // FILTERS
 
             case FILTER_ADDED: 
+                console.log("FILTER ADDED", data);
                 /* Update internal record state */
                 manifold.query_store.add_filter(query_uuid, data);
 
@@ -1842,6 +1843,7 @@ case TYPE_LIST_OF_VALUES:
                 break;
 
             case FILTER_REMOVED:
+                console.log("FILTER REMOVED", data);
                 /* Update internal record state */
                 manifold.query_store.remove_filter(query_uuid, data);
 
index 3bcd15c..9c1c244 100644 (file)
 
             // ... and communicate the appropriate filters to the manager
             // NOTE: we use the manifold namespace for internal filters 
-            if (self.prev_filter_status)
-                manifold.raise_event(self.options.query_uuid, FILTER_REMOVED, self.prev_filter_status);
-
+            if (self.prev_filter_status) {
+                var filter = ['manifold:status', '==', self.prev_filter_status];
+                manifold.raise_event(self.options.query_uuid, FILTER_REMOVED, filter);
+            }
             // XXX The datatables will be refreshed twice !
             if (filter_status != 'all') {
                 // No filter for 'all'
index 654d280..8350eb1 100644 (file)
@@ -1,5 +1,5 @@
 <div id={{ domid }}>
-  <span class="list-group-item-heading sl-resources">View:</span>
+  <span class="list-group-item-heading sl-resources" style='font-size:inherit;'>View:</span>
   
   <a href="#" 
      class="list-group-item sl-resources active" 
@@ -22,7 +22,7 @@
   </a>
   
   <a href="#" class="list-group-item sl-resources"
-     style='display: inline-block !important; font-size: inherit;' 
+     style='display: inline-block !important; font-size: inherit; width:130px;
      id="{{ domid }}__unconfigured" 
      data-status="unconfigured"
      title="View resources that you have selected to add to your slice, that require configuration before they can be reserved. Hover you mouse over the symbol next to the checkbox for more details."
index 1b84a5f..d670c9d 100644 (file)
@@ -10,7 +10,8 @@
           id="testbeds-filter_{[{ testbed.network_hrn }]}"
           data-platform="{[{ testbed.network_hrn }]}">
        <span class="list-group-item-heading">{[{ testbed.platform }]}</span>
-       <!--<p class="list-group-item-heading">{[{ testbed.network_hrn }]}</p></a> -->
+       <!--<p class="list-group-item-heading">{[{ testbed.network_hrn }]}</p>-->
+       </a>
 </div>
 
 </div>
index bd711d5..e81602a 100644 (file)
@@ -34,6 +34,7 @@ class SliceRequestView (LoginRequiredAutoLogoutView, ThemeView):
         slice_name =''
         purpose=''
         exp_url=''
+        authority_hrn = None
         # Retrieve the list of authorities
         authorities_query = Query.get('authority').select('name', 'authority_hrn')
         authorities = execute_admin_query(wsgi_request, authorities_query)
@@ -98,7 +99,7 @@ class SliceRequestView (LoginRequiredAutoLogoutView, ThemeView):
                     authority_hrn = authority['authority_hrn']
 
             # Handle the case when the template uses only hrn and not name
-            if not authority_hrn:
+            if authority_hrn is None:
                 authority_hrn = wsgi_request.POST.get('org_name', '')
 
             slice_request = {
index 1104c98..4c53cce 100644 (file)
@@ -369,6 +369,8 @@ a.sl-resources, a.sl-resources:hover {
     padding:2px 4px;
     -moz-border-radius: 4px;
     border-radius: 4px;
+    width:125px;
+    text-align: center;
 }
 a.sl-resources.active, a.sl-resources.active:hover, a.sl-resources.active:focus {
     border:0;
@@ -692,4 +694,4 @@ div.slogan {
     color:white;
     padding-top:60px;
     text-shadow: 1px 1px #013540;
-}
\ No newline at end of file
+}
index 6b7fa4c..626b7f5 100644 (file)
@@ -47,7 +47,7 @@ $(document).ready(function() {
                </div>
        
                <div class="row">
-                       <div class="col-md-4">
+                       <div class="col-md-6">
                                {{ filter_status }}
                        </div>
                        <div class="col-md-2">