How to customize remove comment action

manojdcoder
Posts: 63
Joined: Thu Oct 29, 2020 12:01 am

How to customize remove comment action

Post by manojdcoder » Thu Dec 31, 2020 11:28 pm

We would like to customize remove comment action, I understand we can override any built-in action by registering custom action with same action id in actions loaded event.

But not sure how to access the current comment, for example retrieving details like comment id, parent id, comment text etc., when user clicks on the remove comment button. Any pointers?

mihaela
Posts: 266
Joined: Wed May 20, 2009 2:40 pm

Re: How to customize remove comment action

Post by mihaela » Mon Jan 04, 2021 4:06 pm

Hello,

For the moment there is no API available to access the current comment to get its properties.
Please give us more details about your use case so we can guide you to a specific implementation or to add more API, if it is necessary. Why do you want to customize the remove comment action? What other functionality do you want to add to it?

Best Regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com

manojdcoder
Posts: 63
Joined: Thu Oct 29, 2020 12:01 am

Re: How to customize remove comment action

Post by manojdcoder » Mon Jan 04, 2021 5:55 pm

When a comment is removed or changes are accepted / rejected by reviewer, we want to show a dialog with a text area where user can enter reason, then same is recorded in our backend with comment id, parent id, what was written in comment or whats the change set etc.,

The comment action has a marker which points the comment text, but it uses an internal id which is different from the id in the XML document. We want to access those ids to record the reason against it.

mihaela
Posts: 266
Joined: Wed May 20, 2009 2:40 pm

Re: How to customize remove comment action

Post by mihaela » Tue Jan 05, 2021 10:09 am

Hello,

Thank you for the information. There are still some details that need to be clarified in order to understand exactly what you want to achieve and how we can help you.

We understand that you want to register a reason for every comment or change that is removed from the document but this can also happen when an user deletes some content that contains review information, right (not only when the user invokes the delete or accept/reject actions)?
Also, we are wondering how do you identify the comment in the content based on the information saved on the server. We are not using unique ids for the comments.
Another question is: what is happening on undo? If the user cancels deleting a comment you remove the reason registered for that comment from the server?

If the information is private you can reply to support@oxygenxml.com and we will continue there.

Best Regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com

Gabriel Titerlea
Posts: 55
Joined: Thu Jun 09, 2016 2:01 pm

Re: How to customize remove comment action

Post by Gabriel Titerlea » Mon Mar 08, 2021 4:58 pm

Hello,

We have released Oxygen XML Web Author 23.1 which contains 2 new API methods which will allow you to set/remove your own custom properties on AuthorPersistentHighlights:

- setPersistentHighlightProperties
- removePersistentHighlightProperties

Best,
Gabriel

Post Reply