Further attempts are made

master
assar 8 years ago
parent ff1d42defd
commit c687eb60e6

@ -212,16 +212,18 @@ function perform_query() {
var notes = $('<div class="results-notes"></div>'); var notes = $('<div class="results-notes"></div>');
if (data[i].notes != null && data[i].notes.length > 0) { if (data[i].notes != null && data[i].notes.length > 0) {
var icon = $('<i class="fa fa-sticky-note"></i>'); var icon = $('<i class="fa fa-sticky-note"></i>');
var tooltipText = $('<div class="tooltiptext"'); var tooltipText = $('<div class="tooltiptext"></div>');
var tooltip = $('<div class="tooltip"></div>'); var tooltip = $('<div class="tooltip"></div>');
tooltip.append(icon, tooltipText); tooltip.append(icon, tooltipText);
notes.append(tooltip); notes.append(tooltip);
} }
newClicker.append(notes); newClicker.append(notes);
newClicker.append($('<div class="results-datasheet"></div>') var datasheet = $('<div class="results-datashet"></div>');
.html('<a href="https://www.elab.kth.se/parts/getfile/' if (data[i].datasheet != null)
+ data[i].datasheet.substring(0, data[i].datasheet.length - 4) datasheet.html('<a href="https://www.elab.kth.se/parts/getfile/'
+ '"><i class="fa fa-file-text" aria-hidden="true"></i></a>')); + data[i].datasheet.substring(0, data[i].datasheet.length - 4)
+ '"><i class="fa fa-file-text" aria-hidden="true"></i></a>');
newClicker.append(datasheet);
newRow.append(newClicker); newRow.append(newClicker);
newResults.append(newRow); newResults.append(newRow);

Loading…
Cancel
Save