-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
fix(timeline): correct updating of reminders and reasons for waiting … #18915
base: 10.0/bugfixes
Are you sure you want to change the base?
Conversation
@@ -413,11 +414,29 @@ public static function handlePendingReasonUpdateFromNewTimelineItem( | |||
} | |||
} | |||
|
|||
if (!isset($new_timeline_item->input['pendingreasons_id']) && $new_timeline_item->getType() === 'TicketTask') { |
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.
it doesn't matter what type of object is added (Followups / Task), if the pending reason is different it needs to be updated no?
// No actual updates -> nothing to be done | ||
if (count($pending_updates) == 0) { | ||
return; | ||
} | ||
|
||
if ($new_timeline_item->getType() === 'ITILFollowup') { |
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.
same here
// Case 8: ticket with 2 timeline items | ||
// The first set the pending data and the second send the same data | ||
// This simulate what will be sent if a pending task is added after the pending followup |
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.
Based on the existing test cases, when a follow-up (or a task, whatever) is added to a ticket with a waiting reason, the ticket is set to "waiting" with automatic reminders based on the date of that follow-up. If additional follow-ups are added later, as long as the ticket remains in the waiting state, the reference date does not change (it remains the date of the first follow-up that set the ticket to waiting). If a new follow-up changes the waiting reason, only the parameters are updated, but the reference date remains unchanged. The current test does not check this point; we should see if it can be added. In any case, the current behavior seems to be the expected one, so there is no bug, right?
ping @AdrienClairembault
Checklist before requesting a review
Please delete options that are not relevant.
Description
If a pending message with restart to a pending task without restart, it did not stop the reminders
If a message waiting with retry to a message waiting without retry, it changes the reason of waiting for the previous message, but does not make a retry
If a message in the queue without retry, to a message in the queue with retry, it changes the reason for waiting of the previous message and starts the reminders on the date of the previous message.
Screenshots (if appropriate):