Sylvie Ye
Committed by Romain Bignon

[bnporc] use only recipient id on new recipient

remove all 'webid' from budgea
......@@ -372,10 +372,8 @@ class BNPParibasBrowser(JsonBrowserMixin, LoginBrowser):
@need_login
def send_code(self, recipient, **params):
# depending on whether recipient is a weboob or a budgea backend object.
_id = recipient.webid if hasattr(recipient, 'webid') else recipient.id
data = {}
data['idBeneficiaire'] = _id
data['idBeneficiaire'] = recipient.id
data['typeActivation'] = 1
data['codeActivation'] = params['code']
return self.activate_recip.go(data=json.dumps(data), headers={'Content-Type': 'application/json'}).get_recipient(recipient)
......
......@@ -828,7 +828,7 @@ class ActivateRecipPage(AddRecipPage):
def get_recipient(self, recipient):
r = Recipient()
r.iban = recipient.iban
r.id = recipient.webid if hasattr(recipient, 'webid') else recipient.id
r.id = recipient.id
r.label = recipient.label
r.category = u'Externe'
r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(days=5)
......