From 2ab33522a6a0799cb9aaf9a663e3b91a5e4fa2ac Mon Sep 17 00:00:00 2001 From: Loic Baron Date: Wed, 29 Oct 2014 14:16:52 +0100 Subject: [PATCH] Caching: Resources, Leases and Slices pre-loaded on the dashboard using REST --- portal/templates/base.html | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/portal/templates/base.html b/portal/templates/base.html index 0f2ecb52..df8fd9c1 100644 --- a/portal/templates/base.html +++ b/portal/templates/base.html @@ -69,11 +69,27 @@ $(document).ready(function() { slices = user.slices; drawSlices(slices); } + + /* + Launch queries to get the resources and leases in Manifold Cache + */ + + $.post("/rest/resource/", function( data ) { + }); + $.post("/rest/lease/", function( data ) { + }); + + function drawSlices(slices){ var items = []; $.each( slices, function(i, val) { items.push( "
  • " + val + "
  • " ); + /* + Launch a Query for each slice to get resources and leases in Manifold Cache + */ + $.post("/rest/slice/", { 'filters': { 'slice_hrn' : val } }, function(data) { + }); }); $("div#home-slice-list").html($( "