Skip to content
This repository has been archived by the owner on Sep 21, 2022. It is now read-only.

Commit

Permalink
Closing #88 (Tooltip with nodes list in reservation view grows bigger…
Browse files Browse the repository at this point in the history
… than browser can display)
  • Loading branch information
danbim committed Oct 29, 2013
1 parent 98162af commit 71bd2b1
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions js/wisegui.js
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,12 @@ function buildPersonalReservationsTable(parent, reservations) {

from = $('<a href="#" rel="tooltip" title="'+reservation.from.toISOString()+'">' + reservation.from.format("YYYY-MM-DD HH:mm:ss") + '</a>').tooltip('show').click(nop);
to = $('<a href="#" rel="tooltip" title="'+reservation.to.toISOString()+'">' + reservation.to.format("YYYY-MM-DD HH:mm:ss") + '</a>').tooltip('show').click(nop);
nodes = $('<a href="#" rel="tooltip" title="'+reservation.nodeUrns.join("<br/>")+'">'+ reservation.nodeUrns.length + ' nodes</a>').tooltip('show').click(nop);
nodes = $(
'<div>'
+ ' <a href="javascript:;" data-target="#wisegui-personal-reservation-nodes-'+reservation.experimentId+'" data-toggle="collapse">'+ reservation.nodeUrns.length + ' nodes</a>'
+ ' <div class="collapse" id="wisegui-personal-reservation-nodes-' + reservation.experimentId + '">' + reservation.nodeUrns.join("<br/>") + '</div>'
+ '</div>'
);
btn = $('<a class="btn btn-primary">Open</a>').bind('click', reservation, function(e) {
e.preventDefault();
navigateTo(e.data.experimentId);
Expand Down Expand Up @@ -417,7 +422,12 @@ function buildReservationTable(reservationsTab) {
reservation = reservations[i];
from = $('<a href="#" rel="tooltip" title="'+reservation.from.toISOString()+'">' + reservation.from.format("YYYY-MM-DD HH:mm:ss") + '</a>').tooltip('show').click(nop);
to = $('<a href="#" rel="tooltip" title="'+reservation.to.toISOString()+'">' + reservation.to.format("YYYY-MM-DD HH:mm:ss") + '</a>').tooltip('show').click(nop);
nodes = $('<a href="#" rel="tooltip" title="'+reservation.nodeUrns.join("<br/>")+'">'+ reservation.nodeUrns.length + ' nodes</a>').tooltip('show').click(nop);
nodes = $(
'<div>'
+ ' <a href="javascript:;" data-target="#wisegui-reservation-nodes-'+i+'" data-toggle="collapse">'+ reservation.nodeUrns.length + ' nodes</a>'
+ ' <div class="collapse" id="wisegui-reservation-nodes-'+i+'">' + reservation.nodeUrns.join("<br/>") + '</div>'
+ '</div>'
);

tableRows[i] = [];
tableRows[i][0] = from;
Expand Down

0 comments on commit 71bd2b1

Please sign in to comment.