mirror of
https://github.com/hkalexling/Mango.git
synced 2026-04-25 00:00:52 -04:00
- option to resume/start from beginning at the title view
- option to toggle read/unread status at the title view - move all embeded JS to public/
This commit is contained in:
+1
-27
@@ -14,31 +14,5 @@
|
||||
<a class="uk-button uk-button-danger" href="/logout">Log Out</a>
|
||||
|
||||
<% content_for "script" do %>
|
||||
<script>
|
||||
var scanning = false
|
||||
function scan() {
|
||||
scanning = true
|
||||
$('#scan-status > div').removeAttr('hidden');
|
||||
$('#scan-status > span').attr('hidden', '');
|
||||
var color = $('#scan').css('color');
|
||||
$('#scan').css('color', 'gray');
|
||||
$.post('/api/admin/scan', function (data) {
|
||||
var ms = data.milliseconds;
|
||||
var titles = data.titles;
|
||||
$('#scan-status > span').text('Scanned ' + titles + ' titles in ' + ms + 'ms');
|
||||
$('#scan-status > span').removeAttr('hidden');
|
||||
$('#scan').css('color', color);
|
||||
$('#scan-status > div').attr('hidden', '');
|
||||
scanning = false;
|
||||
});
|
||||
}
|
||||
$(function() {
|
||||
$('li').click(function() {
|
||||
url = $(this).attr('data-url');
|
||||
if (url) {
|
||||
$(location).attr('href', url)
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<script src="/js/admin.js"></script>
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user