#3850 (Some optimizations in Lino Noi)
by Luc Saffre · in Developers · assigned to Luc Saffre
Kokkuvõte
Layout of ticket detail. Comment emotions. Comments summary.
Children
Kommentaarid
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Added a writable virtual field Comment.my_emotion and extended the add_picker to support virtual fields. Got it almost working.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Working locally. Added a new model Reaction(comment, user) and moved emotion field there. Started to adapt the ui.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Yes, I had to "remove cookies and site data" for the jane site in my FF preferences. Now the issue is gone.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Same thing when using Chromium on my notebook: emotions are available. So it must be something getting cahced in Firefox.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Oho, yet another observation: on my phone it *does* work, on jane! Which indicates that the issue is caused by something being cached and not updated on the client.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : I started to realize that emotion per comment is not yet what we need. We need indeed a separate model Reaction for emotions. When reading a list of comments, I want a one-click way to show my emotion about this comment. And when I've clicked, I want to see what i've clicked, i don't want a way to c...
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) (1 reply) : The Dropdown is defined with the following options (and these are null on jane but not with runserver): <SiteContext.Consumer>{(siteData) let options = siteData.choicelists[props.elem.field_options.store]; IOW it looks as if that code doesn't find the Emotions choicelist. Where does this siteData c...
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Another observation: JS console says "Uncaught TypeError: this.props.options is null". Maybe try everything with a non-compressed main.js so that we can see where this error happens.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) (2 replies) : I think I just understood why it doesn't work on jane: the static files are not correctly configured. I will check this and then report.
- 5 aastat, 10 kuud ago by hannes about #3850 (Some optimizations in Lino Noi) (1 reply) : After python manage.py prep and runserver noi1r works.
- 5 aastat, 10 kuud ago by hannes about #3850 (Some optimizations in Lino Noi) : Testing with sqlite gave the following error: django.db.utils.OperationalError: no such table: users_user
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Funny: it is just the emotions combobox which is empty. Other comboboxes work. And the emotion itself is also stored. And this problem is only on jane, not locally. To be continued later. Hannes, could you please try on your machine whether you also have the problem?
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : This is the first comment after the release. The list of Emotions is still empty on Jane.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Going to upgrade the jane production site in order to try the new comment emotions on real data.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Customized insert actions in the summary panel now works basically. help_texts not yet good. Still experimenting with which emotions to have in the default config.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Before I fix them, I'd like to do at least one more thing: replace the single (+) button for writing a comment by a series of buttons, one for each emotion. Also I will probably remove the reply_vote field: a vote is different from a comment in that a same user should have only one voice (while a sa...
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : There are now of course many failures (18 to be exact) in the book test suite. They seem all trivial: changed demo data for comments, changed button_text fir TicketStates.new, changed detail layout for comment and tickets...
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Great! It works! Todo: picker must be disabled when there is no reply_to.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : I am almost done with a new core feature: a "picker" fieldsimilar to the Ticket.quick_assign_to field, but for any choicelist field.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Added two new fields to Comment model: emotion and upvote. These make sense only when reply_to is not empty. Note that upvote is a nullable boolean field, True would mean "up" and False mean "down". I am not yet sure whether this will work as i imagine.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : Optimized the detail view of a comment: it now has two tabs. The General tabs shows the full preview and the replies. Everything else is in the "More" tab,
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : The summary of a comment now inlcudes the number of replies. To avoid making one additional db query per row this is implemented as an annotation on CommentsByX.
- 5 aastat, 10 kuud ago by Luc Saffre in reply to tonis about #3850 (Some optimizations in Lino Noi) : AFAICS this is what happens "automatically" already now. Great!
- 5 aastat, 10 kuud ago by Luc Saffre in reply to Luc Saffre about #3850 (Some optimizations in Lino Noi) : Yes, seems so. See this question on SO: [url stackoverflow.com/questions/61818351/react-js-quill-editor-with-tables React JS Quill editor with tables].
- 5 aastat, 10 kuud ago by Luc Saffre in reply to Luc Saffre about #3850 (Some optimizations in Lino Noi) (1 reply) : Seems that the sqill editor removes tables?
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) (1 reply) : One demo comment contains a table (search for "Floop the pig"), and that table displays +- correctly. But when I edit the comment, it has gone. Todo: explain why.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) : I am meditating about how to render the comments. ATM I locally switched back from the cards display to a summary view. Experimenting. I started extending the demo data so that it has more realistic use cases.
- 5 aastat, 10 kuud ago by Luc Saffre in reply to tonis about #3850 (Some optimizations in Lino Noi) : Thanks for the hint! (I added links to your answer because I had to look these words up).
- 5 aastat, 10 kuud ago by tonis in reply to Luc Saffre about #3850 (Some optimizations in Lino Noi) (2 replies) : If the css isn't too complex, likely display flex with one other things. If you create a [url www.w3schools.com/cssref/css3_pr_mediaquery.asp media rule] which sets [url www.w3schools.com/cssref/css3_pr_flex-direction.asp flex-direction] : column, and that might be all that's needed.
- 5 aastat, 10 kuud ago by Luc Saffre about #3850 (Some optimizations in Lino Noi) (1 reply) : In order to be more mobile-friendly, the ticket detail now has three "columns" in each tab. There should be exactly one vflex widget per column, and this item should be at the bottom. TODO: how can we have these columns stacked vertically instead of horizontally when working on a mobile device?