diff --git a/TODO b/TODO index 8fd904b..ccd751e 100644 --- a/TODO +++ b/TODO @@ -1,6 +1,5 @@ ### GENERAL - * after move, instead of back to home page, go to an ammended view of the thumbs to keep moving - - works in DEV, should explore bootstrap5 toast? (or a better 'status' update on POSTs, and get it to also increase/descrease the job counter as appropriate) + * get all status messages to use toasts AND get func to also increase/descrease the job counter as appropriate) * ignore face should ignore ALL matching faces (re: Declan) diff --git a/files.py b/files.py index 003d737..41b7429 100644 --- a/files.py +++ b/files.py @@ -622,8 +622,6 @@ def move_files(): for el in request.form: jex.append( JobExtra( name=f"{el}", value=request.form[el] ) ) job=NewJob( "move_files", 0, None, jex ) - st.SetMessage( f"Created Job #{job.id} to move selected file(s)") -# return redirect("/jobs") return make_response( jsonify( job_id=job.id, status="success" ) ) @login_required diff --git a/internal/js/files_support.js b/internal/js/files_support.js index 29f2dbc..007535e 100644 --- a/internal/js/files_support.js +++ b/internal/js/files_support.js @@ -62,7 +62,7 @@ function MoveSubmit() // remove the images being moved $("[name^=eid-]").each( function() { $('#'+$(this).attr('value')).remove() } ) $('#dbox').modal('hide') - $.ajax({ type: 'POST', data: $('#mv_fm').serialize(), url: '/move_files', success: function(data){ console.log(data); return false; } }) + $.ajax({ type: 'POST', data: $('#mv_fm').serialize(), url: '/move_files', success: function(data){ $('.toast-body').html( "Created Job #" + data.job_id + " to move selected file(s)" ); $('.toast').toast("show"); return false; } }) } // show the DBox for a move file, includes all thumbnails of selected files to move diff --git a/templates/base.html b/templates/base.html index 7041cfd..1852a54 100644 --- a/templates/base.html +++ b/templates/base.html @@ -168,6 +168,16 @@ {% if not InDBox %} {%block script_content %}{% endblock script_content %} +