updated BUGs in general to remove older / fixed BUGs relating to the confusion of current/eids, etc.

update amendments in tables.sql to include job_id in entry_ammendment
added amend.py to move amendment-related code into its own file when we create a job (NewJob)
  and that job matches an amendmentType (via job_name or job_name:amt <- where amt relates to how we do a transform_image), then
  we enter a new EntryAmendment pa_job_mgr knows when a Transform job ends, and removes relevant EntryAmendment
files*.js use EntryAmendment data to render thumbnails with relevant AmendmentType
if a normal page load (like /files_ip), and there is an EntryAmendment, mark up the thumb, run the check jobs to look for completion of the job,
  removeal of the EntryAmendment and update the entry based on 'transformed' image

OVERALL: this is a functioning version that uses EntryAmendments and can handle loading a new page with outstanding amendments
  and 'deals' with it.  This is a good base, but does not cater for remove_files or move_files
This commit is contained in:
2025-10-20 19:31:57 +11:00
parent 905910ecf0
commit 56771308a6
8 changed files with 203 additions and 132 deletions

26
TODO
View File

@@ -1,18 +1,18 @@
### major fix - go to everywhere I call GetEntries(), and redo the logic totally...
* client side:
* instead of removing deleted images from DOM, we should gray them out and put a big Del (red circle with line?) though it as overlay.
[DONE] * Create another table of entry_ammendments - note the deletions, rotations, flips of specific eids - then reproduce that on the client side visually as needed
[DONE] - at least grayed-out, to indicate a pending action is not complete.
- When job that flips, rotates, deletes completes then create an entry_amendment in the DB.
- Also hand fudge the jscript amendments for each job / next get_entry_by_id (if needed will also set amendments as needed)
- When job finishes, remove amendment from DB
- when job finishes, remove amendment from document.amendments
need to rework all the throbber stuff, I think it is probably better not to have a div I never use with the throbber in it, just add when I need it...
like in code for amendments. Also get rid of style and just use class
* new viewing model (get ids of query on first load, then paginate only inside that known list)
- BUT, when we finish a delete, what do I do with pageList / entryList???
- start by showing them as deleted (via amend)
- then on success, remove the ids from the *List arrays in js -- but do
this via repagination, invalidate page cache fully, then getPage(currentPage)
(e.g. assume 1, 2, 3 ... 40 in eList). delete 23, 24,
then reset lists to remove 23 and 24, pageList would then
get reset to page with: 21,22,25,26 ... 30, 31
? get rid of style and just use class -- think this should work, so change in
templates/files.html for throbber, etc. and dont set style as much in view_support.js
### GENERAL
* jobs for AI should show path name
* rm dups job should show progress bar
* jobs for AI should show path name
* rm dups job should show progress bar
* in viewer, there is no move button (maybe add one?)
* think I killed pa_job_manager without passing an eid to a transform job, shouldn't crash
- SHOULD JUST get AI to help clean-up and write defensive code here...