Exemplo n.º 1
0
 def get_recipient_object(self, iban, label):
     r = Recipient()
     r.iban = iban
     r.id = iban
     r.label = label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(days=5)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 2
0
 def get_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.id
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(days=5)
     r.currency = u'EUR'
     r.bank_name = self.get('data.activationBeneficiaire.nomBanque')
     return r
Exemplo n.º 3
0
 def get_recipient_obj(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.datetime.now().replace(microsecond=0)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 4
0
 def get_recipient_object(self, iban, label):
     r = Recipient()
     r.iban = iban
     r.id = iban
     r.label = label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(days=5)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 5
0
 def build_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     r.enabled_at = datetime.now().replace(microsecond=0)
     r.currency = u'EUR'
     r.bank_name = recipient.bank_name
     return r
Exemplo n.º 6
0
 def get_recipient_obj(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.datetime.now().replace(microsecond=0)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 7
0
 def build_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     r.enabled_at = date.today()
     r.currency = u'EUR'
     r.bank_name = recipient.bank_name
     return r
Exemplo n.º 8
0
 def build_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     r.enabled_at = date.today()
     r.currency = u'EUR'
     r.bank_name = recipient.bank_name
     return r
Exemplo n.º 9
0
 def build_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(days=5)
     r.currency = u'EUR'
     r.bank_name = recipient.bank_name
     return r
Exemplo n.º 10
0
 def get_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = self.get('data.gestionBeneficiaire.identifiantBeneficiaire')
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(days=5)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 11
0
 def get_recipient_object(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     # On credit mutuel recipients are immediatly available.
     r.enabled_at = datetime.now().replace(microsecond=0)
     r.currency = 'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 12
0
 def get_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.webid if hasattr(recipient, 'webid') else recipient.id
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(
         days=5)
     r.currency = u'EUR'
     r.bank_name = self.get('data.activationBeneficiaire.nomBanque')
     return r
Exemplo n.º 13
0
 def get_recipient(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = self.get('data.gestionBeneficiaire.identifiantBeneficiaire')
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(
         days=5)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 14
0
 def get_recipient_object(self, recipient):
     r = Recipient()
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     # On credit mutuel recipients are immediatly available.
     r.enabled_at = datetime.now().replace(microsecond=0)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     return r
Exemplo n.º 15
0
    def get_recipient(self):
        div = self.doc.xpath('//div[@class="confirmation__text"]')[0]

        ret = Recipient()
        ret.label = CleanText('//p[b[contains(text(),"Libellé du compte :")]]/text()')(div)
        ret.iban = ret.id = CleanText('//p[b[contains(text(),"Iban :")]]/text()')(div)
        ret.bank_name = CleanText(u'//p[b[contains(text(),"Établissement bancaire :")]]/text()')(div)
        ret.currency = u'EUR'
        ret.category = u'Externe'
        ret.enabled_at = datetime.date.today()
        assert ret.label
        return ret
Exemplo n.º 16
0
    def get_recipient(self):
        div = self.doc.xpath('//div[@class="confirmation__text"]')[0]

        ret = Recipient()
        ret.label = CleanText('//p[b[contains(text(),"Libellé du compte :")]]/text()')(div)
        ret.iban = ret.id = CleanText('//p[b[contains(text(),"Iban :")]]/text()')(div)
        ret.bank_name = CleanText(u'//p[b[contains(text(),"Établissement bancaire :")]]/text()')(div)
        ret.currency = u'EUR'
        ret.category = u'Externe'
        ret.enabled_at = datetime.date.today()
        assert ret.label
        return ret
Exemplo n.º 17
0
 def get_recipient(self, recipient):
     # handle polling response
     r = Recipient()
     r.iban = recipient.iban
     r.id = self.get('data.gestionBeneficiaire.identifiantBeneficiaire')
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(days=5)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     r._id_transaction = self.get('data.gestionBeneficiaire.idTransactionAF') or NotAvailable
     r._transfer_id = self.get('data.gestionBeneficiaire.identifiantBeneficiaire') or NotAvailable
     return r
Exemplo n.º 18
0
 def get_recipient_object(self, recipient, get_info=False):
     r = Recipient()
     if get_info:
         recap_iban = CleanText('//div[div[contains(text(), "IBAN")]]/div[has-class("recapTextField")]', replace=[(' ', '')])(self.doc)
         assert recap_iban == recipient.iban
         recipient.bank_name = CleanText('//div[div[contains(text(), "Banque du")]]/div[has-class("recapTextField")]', default=NotAvailable)(self.doc)
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     # On societe generale recipients are immediatly available.
     r.enabled_at = datetime.now().replace(microsecond=0)
     r.currency = u'EUR'
     r.bank_name = recipient.bank_name
     return r
Exemplo n.º 19
0
 def get_recipient(self, recipient):
     # handle polling response
     r = Recipient()
     r.iban = recipient.iban
     r.id = self.get('data.gestionBeneficiaire.identifiantBeneficiaire')
     r.label = recipient.label
     r.category = u'Externe'
     r.enabled_at = datetime.now().replace(microsecond=0) + timedelta(
         days=5)
     r.currency = u'EUR'
     r.bank_name = NotAvailable
     r._id_transaction = self.get(
         'data.gestionBeneficiaire.idTransactionAF') or NotAvailable
     r._transfer_id = self.get(
         'data.gestionBeneficiaire.identifiantBeneficiaire') or NotAvailable
     return r
Exemplo n.º 20
0
 def get_recipient_object(self, recipient, get_info=False):
     r = Recipient()
     if get_info:
         recap_iban = CleanText(
             '//div[div[contains(text(), "IBAN")]]/div[has-class("recapTextField")]',
             replace=[(' ', '')])(self.doc)
         assert recap_iban == recipient.iban
         recipient.bank_name = CleanText(
             '//div[div[contains(text(), "Banque du")]]/div[has-class("recapTextField")]',
             default=NotAvailable)(self.doc)
     r.iban = recipient.iban
     r.id = recipient.iban
     r.label = recipient.label
     r.category = recipient.category
     # On societe generale recipients are immediatly available.
     r.enabled_at = datetime.now().replace(microsecond=0)
     r.currency = u'EUR'
     r.bank_name = recipient.bank_name
     return r