Commit 599806ed authored by Sylvie Ye's avatar Sylvie Ye Committed by Romain Bignon

[societegenerale] add TYPE_CONSUMER_CREDIT account type

parent 4f4e3218
......@@ -185,7 +185,7 @@ class SocieteGenerale(LoginBrowser, StatesMixin):
if account._prestation_id in account_comings:
account.coming = account_comings[account._prestation_id]
if account.type == account.TYPE_LOAN:
if account.type in (account.TYPE_LOAN, account.TYPE_CONSUMER_CREDIT, ):
self.loans.go(conso=(account._loan_type == 'PR_CONSO'))
account = self.page.get_loan_account(account)
......@@ -193,7 +193,7 @@ class SocieteGenerale(LoginBrowser, StatesMixin):
@need_login
def iter_history(self, account):
if account.type in (account.TYPE_LOAN, account.TYPE_MARKET, ):
if account.type in (account.TYPE_LOAN, account.TYPE_MARKET, account.TYPE_CONSUMER_CREDIT, ):
return
if account.type == Account.TYPE_PEA and not ('Espèces' in account.label or 'ESPECE' in account.label):
......@@ -234,7 +234,8 @@ class SocieteGenerale(LoginBrowser, StatesMixin):
@need_login
def iter_coming(self, account):
if account.type in (account.TYPE_LOAN, account.TYPE_MARKET, account.TYPE_PEA,
account.TYPE_LIFE_INSURANCE, account.TYPE_REVOLVING_CREDIT):
account.TYPE_LIFE_INSURANCE, account.TYPE_REVOLVING_CREDIT,
account.TYPE_CONSUMER_CREDIT, ):
return
internal_id = account._internal_id
......
......@@ -98,6 +98,7 @@ class AccountsPage(JsonBasePage):
'VIE_FEDER': Account.TYPE_LIFE_INSURANCE,
'ASSURANCE_VIE_GENERALE': Account.TYPE_LIFE_INSURANCE,
'AVANCE_PATRIMOINE': Account.TYPE_REVOLVING_CREDIT,
'PRET_EXPRESSO': Account.TYPE_CONSUMER_CREDIT,
}
obj_id = obj_number = CleanText(Dict('numeroCompteFormate'), replace=[(' ', '')])
......@@ -115,7 +116,7 @@ class AccountsPage(JsonBasePage):
obj__prestation_id = Dict('id')
def obj__loan_type(self):
if Field('type')(self) == Account.TYPE_LOAN:
if Field('type')(self) in (Account.TYPE_LOAN, Account.TYPE_CONSUMER_CREDIT, ):
return Dict('codeFamille')(self)
return None
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment