|
@ -5,11 +5,11 @@ |
|
|
<meta charset="utf-8"> |
|
|
<meta charset="utf-8"> |
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"> |
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"> |
|
|
<title>Library</title> |
|
|
<title>Library</title> |
|
|
<link rel="stylesheet" href="{{ url_for('static', filename='css/main-new.css') }}"> |
|
|
<link rel="stylesheet" href="{{ url_for('static', filename='css/main.css') }}"> |
|
|
|
|
|
|
|
|
<!--TEST--> |
|
|
<!--TEST--> |
|
|
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.3/jquery.min.js"></script> |
|
|
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.3/jquery.min.js"></script> |
|
|
|
|
|
|
|
|
<script type="text/javascript"> |
|
|
<script type="text/javascript"> |
|
|
$(document).ready(function() { |
|
|
$(document).ready(function() { |
|
|
|
|
|
|
|
@ -139,7 +139,7 @@ |
|
|
}); |
|
|
}); |
|
|
/////DISPLAY FILES///////////// |
|
|
/////DISPLAY FILES///////////// |
|
|
$(".file-names").click(function(event){ |
|
|
$(".file-names").click(function(event){ |
|
|
|
|
|
|
|
|
// alert(listofselecteddocs); |
|
|
// alert(listofselecteddocs); |
|
|
// if classname in listselecteddocs, checkbox is checked; |
|
|
// if classname in listselecteddocs, checkbox is checked; |
|
|
|
|
|
|
|
@ -170,9 +170,9 @@ |
|
|
checkboite = "<br /><input type='checkbox' class='addtoprint' id='"+classname+"' name='"+classname+"' value='print' checked><label for='"+classname+"'> Add to print</label>"; |
|
|
checkboite = "<br /><input type='checkbox' class='addtoprint' id='"+classname+"' name='"+classname+"' value='print' checked><label for='"+classname+"'> Add to print</label>"; |
|
|
} else { |
|
|
} else { |
|
|
checkboite = "<br /><input type='checkbox' class='addtoprint' id='"+classname+"' name='"+classname+"' value='print'><label for='"+classname+"'> Add to print</label>"; |
|
|
checkboite = "<br /><input type='checkbox' class='addtoprint' id='"+classname+"' name='"+classname+"' value='print'><label for='"+classname+"'> Add to print</label>"; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if ((extension=="jpg") || (extension=="jpeg") || (extension=="png") || (extension=="gif") || (extension=="tiff")) { |
|
|
if ((extension=="jpg") || (extension=="jpeg") || (extension=="png") || (extension=="gif") || (extension=="tiff")) { |
|
|
$(".name-elements").append("<li><img class='listed-images' src='/files/"+ledocument+"'>"+checkboite+"</li>"); |
|
|
$(".name-elements").append("<li><img class='listed-images' src='/files/"+ledocument+"'>"+checkboite+"</li>"); |
|
|
} |
|
|
} |
|
@ -203,7 +203,7 @@ |
|
|
|
|
|
|
|
|
var listofselecteddocs = []; |
|
|
var listofselecteddocs = []; |
|
|
|
|
|
|
|
|
$(document.body).on("click", "input[type='checkbox']", function() { |
|
|
$(document.body).on("click", "input[type='checkbox']", function() { |
|
|
var self=$(this); |
|
|
var self=$(this); |
|
|
if(self.is(":checked")){ |
|
|
if(self.is(":checked")){ |
|
|
theid = self.attr("id"); |
|
|
theid = self.attr("id"); |
|
@ -247,9 +247,9 @@ $.ajax({ |
|
|
<body> |
|
|
<body> |
|
|
<div class="nav-top"> |
|
|
<div class="nav-top"> |
|
|
<ul> |
|
|
<ul> |
|
|
<li><a class="nav-button" style="text-align: left;" href="bought">BOUGHT</a></li> |
|
|
<li><span class="nav-button" style="text-align: left;" id="bought">BOUGHT</span></li> |
|
|
<li><a class="nav-button" style="text-align: center;" href="stolen">STOLEN</a> |
|
|
<li><span class="nav-button" style="text-align: center;" id="stolen">STOLEN</span> |
|
|
<li><a class="nav-button" style="text-align: right;" href="repurposed">REPURPOSED</a> |
|
|
<li><span class="nav-button" style="text-align: right;" id="repurposed">REPURPOSED</span> |
|
|
</ul> |
|
|
</ul> |
|
|
</div> |
|
|
</div> |
|
|
<div class="main"> |
|
|
<div class="main"> |
|
@ -258,8 +258,7 @@ $.ajax({ |
|
|
|
|
|
|
|
|
<div id="listofpeople"> |
|
|
<div id="listofpeople"> |
|
|
{% for librarian in librarians %} |
|
|
{% for librarian in librarians %} |
|
|
<!-- <a href="#" class="librarian-names">{{ librarian }}</a> --> |
|
|
<span class="librarian-names" id={{librarian}}>{{librarian}}</span> |
|
|
<span class="librarian-names">{{ librarian }}</span> |
|
|
|
|
|
{% endfor %} |
|
|
{% endfor %} |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
@ -313,30 +312,11 @@ $.ajax({ |
|
|
</div> |
|
|
</div> |
|
|
<div class="nav-bottom"> |
|
|
<div class="nav-bottom"> |
|
|
<ul> |
|
|
<ul> |
|
|
<li><a class="nav-button" style="text-align: left;" href="copied">COPIED</a></li> |
|
|
<li><span class="nav-button" style="text-align: left;" id="copied">COPIED</span></li> |
|
|
<li><a class="nav-button" style="text-align: center;" href="found">FOUND</a></li> |
|
|
<li><span class="nav-button" style="text-align: center;" id="found">FOUND</span></li> |
|
|
<li><a class="nav-button" style="text-align: right;" href="gift">GIFT</a></li> |
|
|
<li><span class="nav-button" style="text-align: right;" id="gift">GIFT</span></li> |
|
|
</ul> |
|
|
</ul> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
</body> |
|
|
</body> |
|
|
</html> |
|
|
</html> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- |
|
|
|
|
|
https://stackoverflow.com/questions/42661249/making-a-checkbox-persistent-on-page-reload |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
https://stackoverflow.com/questions/1154258/persistence-of-checkbox-values |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
https://stackoverflow.com/questions/31671918/how-to-persist-checkbox-checked-state-after-page-reload |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
https://stackoverflow.com/questions/42525002/localstorage-for-checkboxes |
|
|
|
|
|
https://developer.tizen.org/community/code-snippet/web-code-snippet/how-save-checkbox-status-localstorage |
|
|
|
|
|
https://www.sitepoint.com/quick-tip-persist-checkbox-checked-state-after-page-reload/ |
|
|
|
|
|
https://stackoverflow.com/questions/40935362/how-to-persist-checkbox-selection-with-page-refresh |
|
|
|
|
|
--> |
|
|
|