for now made del/restore force a reload of main page, it still does not show you created the del/restore job, but it is better than nothing. Also fixed dumb bug I introduced when handling trash/restore icons and moved an if rather than copied it between the alert for dir in and buttons for del/restore

This commit is contained in:
2021-06-11 19:03:37 +10:00
parent 2451d25a0c
commit c3398ef77a

View File

@@ -16,7 +16,8 @@
{% elif "files_sp" in request.url %}
<i class="fas fa-database"></i>
{% set tmp_path=cwd | replace( "static/Storage", "" ) + "/" %}
{% else %}
{% elif "files_rbp" in request.url %}
<i class="fas fa-trash-restore-alt"></i>
{% set tmp_path=cwd | replace( "static/Bin", "" ) + "/" %}
{% endif %}
{{tmp_path}}</span>
@@ -249,7 +250,7 @@ function DelDBox(del_or_undel)
div+="'/restore_files', "
div+=`
data: to_del,
success: function(data){ console.log('Delete/Restore File(s) succeeded - TODO: need a FE msg' ); return false; } })" class="btn btn-outline-danger col-lg-2">Ok</button>
success: function(data){ window.location='/'; return false; } })" class="btn btn-outline-danger col-lg-2">Ok</button>
</div>
`
$('#dbox-content').html(div)