fix BUG-95 (next button at top doesnt work in flat view)

This commit is contained in:
2022-07-15 22:52:02 +10:00
parent b2dd6a3de0
commit cfb222e3d1
3 changed files with 5 additions and 5 deletions

1
BUGs
View File

@@ -1,4 +1,3 @@
### Next: 96
BUG-85: once we rebuild data from scratch, need to reset just clean out pa_user_state's
BUG-94: video player no longer works on any platform/browser - just 'spins' then nothing, URL seems right, I can play the video after I download the file direct, so the file is ok too. Used to work -- maybe using Ubuntu 22.04??? (or other newer pieces - feels wrong though, this feels client side somehow - did I bork the html somehow - check git'
BUG-95: next button at the top doesnt work

4
README
View File

@@ -65,7 +65,7 @@ To rebuild DB from scratch/empty data:
#scratch, when we get real data, we will instead cp a backup file not the
#tables.sql
( cd /srv/docker/config/ ; sudo docker-compose stop padb_dev ; yes | sudo docker-compose rm padb_dev ; sudo rm -rf /srv/docker/container/padb_dev/data/ ; sudo cp /home/ddp/src/photoassistant/tables.sql /srv/docker/container/padb_dev/docker-entrypoint-initdb.d/tables.sql ; sudo docker-compose up padb_dev ) &
( cd /srv/docker/config/ ; sudo docker-compose stop padb_dev ; yes | sudo docker-compose rm padb_dev ; sudo rm -rf /srv/docker/container/padb_dev/data/ ; sudo cp /home/ddp/src/photoassistant/tables.sql /srv/docker/container/padb_dev/docker-entrypoint-initdb.d/tables.sql ; sudo docker-compose up -d padb_dev ) &
To get back a 'working' but scanned set of data:
@@ -89,7 +89,7 @@ To get back a 'working' but scanned set of data:
sudo bash
# gunzip -c /home/ddp/src/photoassistant/DB_BACKUP/20200126-all-imported-no-duplicates.sql.gz > /srv/docker/container/padb/docker-entrypoint-initdb.d/tables.sql
( cd /srv/docker/config/ ; sudo docker-compose stop padb ; yes | sudo docker-compose rm padb ; sudo rm -rf /srv/docker/container/padb/data/ ; sudo docker-compose up padb )
( cd /srv/docker/config/ ; sudo docker-compose stop padb ; yes | sudo docker-compose rm padb ; sudo rm -rf /srv/docker/container/padb/data/ ; sudo docker-compose up -d padb )
HANDY SQLs/commands:

View File

@@ -138,6 +138,7 @@ class States(PA):
pref=PA_UserState.query.filter(PA_UserState.pa_user_dn==current_user.dn,PA_UserState.path_type==self.path_type).first()
if pref:
print( f"pref={pref}" )
self.grouping=pref.grouping
self.how_many=pref.how_many
self.offset=pref.st_offset
@@ -219,8 +220,8 @@ class States(PA):
self.size = request.form['size']
# seems html cant do boolean, but uses strings so convert
if self.path_type != "View" and 'folders' in request.form:
# we are changing values based on a POST to the form, if we changed the folders option, we need to reset things
if 'ChangeFileOpts' in request.path and self.folders != request.form['folders']:
# we are changing values based on a POST to the form, if we are in folder view and we changed the folders option, we need to reset things
if 'ChangeFileOpts' in request.path and self.folders and self.folders != request.form['folders']:
self.num_entries=0
self.first_eid=0
self.last_eid=0