Home > Forum > Actions > IsChange or IsNew for Comments

IsChange or IsNew for Comments
0

Hello all,

I know this is not the best practice but I have an approval step where the users might need to have that rejected to make changes in the form.
The step is only handled by the approver and I don't want to use admin options to change the status for a specific request.

I thought about adding a timeout to check if New comments were added in the request.
I know that in the notification configuration, I can select the last comment entered. But I want to create a SQL rule to active/inactive the timeout. For that, I want to check if new comments were actually added.

Do you have any idea how to accomplish this?
Thank you

MVP

Hi Andreia,

I also don't fully understand your request. Based on what I understand I can tell you the following:

- Timeouts are only created / deactivated when an path transition happens. Saving an workflow instance or saving a comment in the view mode won't create a new timeout.
- Even if you have a timeout checking this every few minutes, this will create a lot of versions.
- The "Last comment" is probably not what you assume it is. The last comment will always return the last entered comment regardless of the time /version in which the comment was provided. It will also return the a value if no comment was added in this version.

That's the reason why I created a business rule to return the "current comment". If non was added, it returns nothing.

I've also used the "send mail on new comment" as an example on how to use it:
https://daniels-notes.de/posts/2024/current-comment#example-and-test-cases

Best regards,
Daniel

In reply to: Daniel Krüger (Cosmo Consult)

Hi Andreia,

I also don't fully understand your request. Based on what I understand I can tell you the following:

- Timeouts are only created / deactivated when an path transition happens. Saving an workflow instance or saving a comment in the view mode won't create a new timeout.
- Even if you have a timeout checking this every few minutes, this will create a lot of versions.
- The "Last comment" is probably not what you assume it is. The last comment will always return the last entered comment regardless of the time /version in which the comment was provided. It will also return the a value if no comment was added in this version.

That's the reason why I created a business rule to return the "current comment". If non was added, it returns nothing.

I've also used the "send mail on new comment" as an example on how to use it:
https://daniels-notes.de/posts/2024/current-comment#example-and-test-cases

Best regards,
Daniel

HI Daniel,

I want to send a notification is someone enters a comment in that step.
I checked your post, so you are creating something like
- Technical FIeld that saves last comment
- Technical field that saves a new comment
- Use both fields as execution condition
- If different, an email is sent

I have some questions:
- Where are you configuring this action? Instance saving, etc? In the workflow or global actions?
- I don't want to send any notifications with emails that might happen due to path transition, only if in that step, someone enters a comment

Thank you