Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

optimized searchbar: only words, removed bug in parse rows #424

Merged
merged 6 commits into from
Mar 30, 2020

Conversation

Lorsbyjm
Copy link
Contributor

@Lorsbyjm Lorsbyjm commented Mar 24, 2020

see issue: #366

Visible/Frontend Changes

  • searchbar dissapers when searchfield is empty

  • searching does not take that long

  • please check the regex expression, it should allow only strings with at least one characters or number

  • remeber:
    Search depends on pouchdb indices so this can only be debugged when setting useTemporaryDatabase to false in the config.json

Copy link
Member

@sleidig sleidig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

and thereby also ensure that search results' photo is loaded
@sleidig
Copy link
Member

sleidig commented Mar 26, 2020

I noticed here that the previous merge in the master of the ChildPhotoService had broken the photos in the search result. After some forth and back I ended up with a larger change (moving the loading of the photos to a new EntitySchemaDatatype).
@Lorsbyjm (or @RichardNutt ? or anyone else for that matter): please do a review of my commits here as well - and point out any parts that need to be corrected, cleaned up or better documented.

@Lorsbyjm
Copy link
Contributor Author

@sleidig what do you want to achive. Now no pictures are shown.
Which properties do I need to set?

…rough EntitySchema

this fixes a bug displaying broken child photos
@sleidig
Copy link
Member

sleidig commented Mar 28, 2020

Oh, you are absolutely right. there was another bug that converted an undefined photoFile name wrongly and broke images if you have not set up the Nextcloud integration. This should be fixed now. I also shared a test account for nextcloud in our slack in case you want to test with that as well.

@Lorsbyjm
Copy link
Contributor Author

I do not have enough experience to review the code, but it looks like it is working.
But in the database are still children with an old entity schema, so there are no pictures shown, these children should be deletet. (To test search for Jonas)

Furthermore the loading takes even more time if for every search reslut the image is loaded from the nextcloud. We might think about limiting the search result to an special threshold and not show it if there are more. But to ask the user for more input.

@sleidig
Copy link
Member

sleidig commented Mar 30, 2020

limiting it (maybe also just start after input of at least 3 characters) might be a good idea. The photo load should work asynchronously however - first return the path to the default image (or one that has been uploaded by the server admin) and only later replacing that if a photo is returned from the cloud.
The "Jonas" doc had an invalid photoFile path saved - probably due to the early bug.

@sleidig sleidig merged commit 9d0bf54 into master Mar 30, 2020
@sleidig sleidig deleted the search-panel-fix branch March 30, 2020 07:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants