Skip to content

Conversation

@kobros-tech
Copy link
Contributor

In a competition with: #89

Only one is planned to be merged or we can take the best of both in one single thing.

@OCA-git-bot
Copy link
Contributor

Hi @etobella,
some modules you are maintaining are being modified, check this out!

@kobros-tech
Copy link
Contributor Author

back_to_draft.mp4

@kobros-tech
Copy link
Contributor Author

the good in this approach the simple code

the bad is that all signers will be emails even if some of them have already signed, this is bad because they may unsubscribe.

but your opinion is welcome:

@pedrobaeza
@etobella
@victoralmau

@kobros-tech
Copy link
Contributor Author

@wlin-kencove

needing to review this one and all merging and their similarities in 18.0

@pedrobaeza pedrobaeza changed the title [IMP] sign_oca: add back to draft action button [16.0][IMP] sign_oca: add back to draft action button Sep 2, 2025
@pedrobaeza pedrobaeza added this to the 16.0 milestone Sep 2, 2025

def action_reset_to_draft(self):
self.write({"state": "1_draft"})
self._set_action_log("to_draft")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What will happen if we have 2 signers and one of them has already signed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@etobella

In fact that module can not help unless I cancel and then set it back to draft and then I set to sent,

For example if a customer and employee, and employee has signed then this workfow will make the email to be sent to the customer or all customers who are in the sign request even if one of them has already signed.

In fact this is the point I made the other PR for, that is making email to be sent only to who did not sign.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But then, all signers should be reseted back, isn't it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not at all, the point was just sending the email to who signed will not make sense because if the open the link they find themselves already signed.

but their signature is there not changed, other signers if they sign that will be append to former ones.

To avoid unnecessary emails I select the people who didn't sign to receive the notification email.

But I confirm no partner have to sign a document they already signed as this will make them upset and the purpose of this approach to facilitate to them not to annoy them.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But that is mainly the issue...

Let me explain myself. If we cancel the sign.request, all signatures should be invalidated and we might need to start over again and sign everything again.

At least this is the way I see it. For me, the main goal here is to resend the request to the missing signers, wouldn't be better to do that?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@etobella
@victoralmau
and not change or update the state between canel, draft, and sent?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO, no, the status should not be changed. As with other sections of Odoo, why shouldn't it be possible to resend an email to someone without having to change anything?

A button (only visible if sent and not signed) that does just that (sending an email) is the simplest and clearest interface.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in fact that first PR is doing the same functionality #89

Can we transition to and continue conversation as that button you suggest is there and I don't change the state there too.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Answered at #89, the approach I propose is neither this PR nor the other one.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will make it closer there, don't worry.

@kobros-tech
Copy link
Contributor Author

@etobella

now this issue is solved after importing a function from my former PR, its in the 2nd commit now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants