X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=portal%2Ftemplates%2Fbase.html;h=841dca99c828bc976726e29c78ebee573611aa1d;hb=a52e4ba486797f7569a9d9ac451089e698100fd5;hp=82fa444f6efcb2b2517e920e8fe32a873c804e74;hpb=335a5be14ae49e9f9ed35710be9e516f9ea8b789;p=unfold.git diff --git a/portal/templates/base.html b/portal/templates/base.html index 82fa444f..841dca99 100644 --- a/portal/templates/base.html +++ b/portal/templates/base.html @@ -1,6 +1,7 @@ {% load portal_filters %} {# This is required by insert_above #}{% insert_handler %} - + + {{theme}} portal - {{ section }} @@ -20,7 +21,7 @@ - + @@ -54,6 +55,7 @@ {% insert_str prelude "css/topmenu.css" %} {% insert_str prelude "js/logout.js" %} + @@ -65,7 +67,7 @@ This list of slices should go into SESSION ! $(document).ready(function() { {% if username %} myslice.login(function(){ - user = myslice.user(); + user = myslice.get_user(); var slices = []; if($.isEmptyObject(user)){ @@ -75,36 +77,77 @@ $(document).ready(function() { slices.push("no slice"); }else{ slices = user.slices; + {% if theme != "fed4fire" or "onelab" in theme %} drawSlices(slices); + {% endif %} } - {% if theme == "fed4fire" %} - p = myslice.projects(); + {% if theme == "fed4fire" or "onelab" in theme%} + p = myslice.get_projects(); if(p != null){ - drawProjects(p); + //drawProjects(p); + drawProjectsTree(p,slices); } {% endif %} }); function drawSlices(slices){ var items = []; - + console.log(slices); $.each( slices, function(i, val) { - items.push( "
  • " + val + "
  • " ); + items.push( "
  • " + val + "
  • " ); }); $("div#home-slice-list").html($( "