-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Better Canvas search to prevent metadata beeing searched in fulltext | Code formatted #726
Conversation
let mindMapcontent = JSON.parse (content); | ||
let topic = mindMapcontent.nodedata.topic; | ||
content = utils.normalize(topic.toString()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't seem to go through all the nodes in order to search for content.
I added a text node randomly inside the tree and I couldn't find it.
Having the text in a canvas note instead appears to work fine.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you have further information?
I tried the same and it does work in my case. It does find the whole searched text in the textnote. Random Text note inside my tree:
working with mindmap, too. I cant reproduce your behaviour:
but could be sth with the backendcache thats created when searched. if you have a really big database. I can´t check if zadam loads every note in the cache regardless the size of the database.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@CobriMediaJulien , for the mind map you would need to add more nodes. From what I see in the screenshot it's only a single node ("now a mindmaptest"). Try pressing enter a few times to create a few subnodes and search for that subnode instead.
I believe you need to iterate recursively through all the nodes, similarly to how you do for canvas note.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could reproduce. I just search for topic value and not children. I will fix it this weekend.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed and commited to this PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@CobriMediaJulien , don't forget to remove the draft status from the PR once the required changes were done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this PR provides also a fix for:
Mindmap search works now
Improvement of canva library feature. Now u can delete items and manage your library in the UI.
For reference:
#720
@eliandoran
Could you pls check the code if the quality regarding variable names is okay? I just hacked it together. It kinda works well enough. i don´t have anymore time this week.
Now it searches only the text or topic of the notes.