moved JoblogSearch to internal/js/ as it does not need any jinja processing, added button and hotkey to show logs, and brief logs into dbox - it works, but needs prettying up
This commit is contained in:
@@ -207,4 +207,8 @@
|
||||
<svg id="user" viewBox="0 0 16 16">
|
||||
<path d="M3 14s-1 0-1-1 1-4 6-4 6 3 6 4-1 1-1 1H3zm5-6a3 3 0 1 0 0-6 3 3 0 0 0 0 6z"/>
|
||||
</svg>
|
||||
<svg id="log" viewBox="0 0 16 16">
|
||||
<path d="M6 8a3 3 0 1 0 0-6 3 3 0 0 0 0 6zm-5 6s-1 0-1-1 1-4 6-4 6 3 6 4-1 1-1 1H1zM11 3.5a.5.5 0 0 1 .5-.5h4a.5.5 0 0 1 0 1h-4a.5.5 0 0 1-.5-.5zm.5 2.5a.5.5 0 0 0 0 1h4a.5.5 0 0 0 0-1h-4zm2 3a.5.5 0 0 0 0 1h2a.5.5 0 0 0 0-1h-2zm0 3a.5.5 0 0 0 0 1h2a.5.5 0 0 0 0-1h-2z"/>
|
||||
</svg>
|
||||
|
||||
</svg>
|
||||
|
||||
|
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 25 KiB |
@@ -275,3 +275,22 @@ function FaceDBox(key, item)
|
||||
$('#dbox-content').html(div)
|
||||
$('#dbox').modal('show')
|
||||
}
|
||||
|
||||
|
||||
// func called to show logs relating to this filename from viewer
|
||||
// pops results up in a dbox
|
||||
function JoblogSearch()
|
||||
{
|
||||
data="eid="+current
|
||||
$.ajax({ type: 'POST', data: data, url: '/joblog_search', success: function(res) {
|
||||
data = JSON.parse(res)
|
||||
div='<div>'
|
||||
for( i=0; i<data.length; i++ )
|
||||
div+='Log: ' + data[i].log + '<br>'
|
||||
div+='</div>'
|
||||
$('#dbox-title').html("Logs relating to this filename")
|
||||
$('#dbox-content').html(div)
|
||||
$('#dbox').modal('show')
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -75,16 +75,6 @@
|
||||
return s
|
||||
}
|
||||
|
||||
function JoblogSearch()
|
||||
{
|
||||
data="eid="+current
|
||||
$.ajax({ type: 'POST', data: data, url: '/joblog_search', success: function(res) {
|
||||
data = JSON.parse(res)
|
||||
console.log(data)
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function CallViewListRoute(dir)
|
||||
{
|
||||
data="eids="+$("#eids").val()
|
||||
@@ -250,6 +240,9 @@
|
||||
<button class="btn btn-outline-info p-1" title="View in Fullscreen mode (hotkey: F)" onClick="fullscreen=true; ViewImageOrVideo()">
|
||||
<svg width="28" height="28" fill="currentColor"><use xlink:href="{{url_for('internal', filename='icons.svg')}}#fullscreen"/></svg>
|
||||
</button>
|
||||
<button class="btn btn-outline-info p-1" title="Show logs relating to this filename (hotkey: l)" onClick="JoblogSearch()">
|
||||
<svg width="28" height="28" fill="currentColor"><use xlink:href="{{url_for('internal', filename='icons.svg')}}#log"/></svg>
|
||||
</button>
|
||||
<button id="del" class="btn btn-outline-danger p-1" title="Delete (hotkey: Del)"
|
||||
onClick="$.ajax({ type: 'POST', data: '&eid-0={{current}}', url: '/delete_files', success: function(data){ window.location='/'; return false; } })">
|
||||
<svg width="28" height="28" fill="currentColor"><use xlink:href="{{url_for('internal', filename='icons.svg')}}#trash"/></svg>
|
||||
@@ -285,6 +278,9 @@ $( document ).keydown(function(event) {
|
||||
fullscreen=!document.fullscreen
|
||||
ViewImageOrVideo()
|
||||
break;
|
||||
case "l":
|
||||
JoblogSearch()
|
||||
break;
|
||||
case "Delete":
|
||||
$('#del').click()
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user