Skip to content
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

[ADD] update_partner_info to be modified by IWP DONOTMERGE #413

Draft
wants to merge 1 commit into
base: 12.0
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions cooperator/models/subscription_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ def is_member(self, vals, cooperator):
vals["already_cooperator"] = True
return vals

def update_partner_info(self):
# To be overiden to update specific partner information based
# on subscription request
return True

@api.constrains("share_product_id", "is_company")
def _check_share_available_to_user(self):
for request in self:
Expand Down Expand Up @@ -696,6 +701,7 @@ def validate_subscription_request(self):
raise UserError(_("Number of share must be greater than 0."))
if self.partner_id:
partner = self.partner_id
self.update_partner_info()
else:
partner = None
domain = []
Expand Down