big clean up of Options -> States, total rework, now actually handles pa_user_state -> States as Import/Storage/Bin/Search or View. If Search has orig_search_term saved. If view, has orig_ptype (and orig_search_term if orig_ptype is Search) -- removed OPT.paths -> these are now worked out when we GetEntries based on pa_user_state. This now allows us to GET all URLs for image viewing allowing me to use the back-button without issues in PROD - well we will see once I commit :)

This commit is contained in:
2022-01-20 17:25:01 +11:00
parent 5461cb4036
commit 78acb9bd66
5 changed files with 132 additions and 76 deletions

4
TODO
View File

@@ -1,14 +1,12 @@
## GENERAL
* for below.. make Options( request )
- know that a view is a "path", dont rely on orig_url
- remove all "Options()" that are not set by a user-choice in the F/E and just make sure new "Options" sets all defaults as needed
-- viewlist can work out new view_eids server side, and pass them back as json data
- can consider an optim-- new_view page makes calls to viewlist to ADD json data only, so only trigger a new "viewlist" if we dont have data for that part of the eids
* going forward into search page (and probably all POSTs) does not work
don't render_template instead do a redirect to a GET of the new, or list? for del...
files.py:@app.route("/view/<id>", methods=["POST"])
- first pass -- fails on storage in prod (view_eids was NONE, but prefs had content, odd... ALSO in dev, it did have a list but the img we were viewing was not in the list!
[DONE] files.py:@app.route("/view/<id>", methods=["POST"])
files.py:@app.route("/viewlist", methods=["POST"])
-- this will need a total rewrite for viewer to handle fullscreen across offset/size boundaries so fix that instead
job.py:@app.route("/jobs", methods=["GET", "POST"])