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
Allow to track queue change in follow-ups #1167
Allow to track queue change in follow-ups #1167
Conversation
In the "Change Further Details" section, it seems that you cannot edit the ticket title. |
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 change seems reasonable to me.
Could you add a small unit test for this additional feature (maybe in helpdesk/tests/test_ticket_actions.py)?
Thanks, yes I will and I will also update the time calculation code relative to each follow-up. The idea is that if a helpdesk admin wants to introduce time_spent auto calculation or wish to modify the calculation settings, he can make a queryset with all FollowUps, remove time_spent and .save() to (re)calculate the time. |
I have refactored the time_spent_calculation so it doesn't make unnecessary queries when no exclusion is set. It is now dealing with queue changes over time with the newly introduced TicketChange for field _('Queue'). A unit test was made to validate creation of the TicketChange together with the modification of the ticket queue. Another one to test multiple queue exclusions over time with correct time_spent calculation. |
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.
Looks good - thanks for adding the unit tests
@Benbb96 - if you do not see any issues here then please merge the 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.
Just a few feedbacks, but it's really good work. The feature seems to be complete now!
…late Co-authored-by: Benbb96 <Benbb96@users.noreply.github.com>
Co-authored-by: Benbb96 <Benbb96@users.noreply.github.com>
Thank you @Benbb96, suggestions committed! I need a signal sent when the ticket is updated. |
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.
Alright, no problem!
Because of Time calculation feature that allows for time in specific queues not to be counted in, we need to track queue changes in TicketChanges.
As ticket changes are related to follow-ups, I have added the ability to change ticket queue in the "Change Further Details" of the ticket view.
If this is approved, it will enable me to code correct calculation for the FOLLOWUP_TIME_SPENT_EXCLUDE_QUEUES setting.
In my use case, queues are used to pass tickets to different teams.