Commit fd5d7656 authored by Damien Mat's avatar Damien Mat Committed by ntome

[creditmutuel] 'Eurocompte serenite' account and transactions typing

Closes: 12163@zendesk
parent ca5539ef
......@@ -130,44 +130,45 @@ class item_account_generic(ItemElement):
klass = Account
TYPES = OrderedDict([
('Credits Promoteurs', Account.TYPE_CHECKING), # it doesn't fit loan's model
('Compte Cheque', Account.TYPE_CHECKING),
('Compte Courant', Account.TYPE_CHECKING),
('Cpte Courant', Account.TYPE_CHECKING),
('Contrat Personnel', Account.TYPE_CHECKING),
('Cc Contrat Personnel', Account.TYPE_CHECKING),
('C/C', Account.TYPE_CHECKING),
('Start', Account.TYPE_CHECKING),
('Comptes courants', Account.TYPE_CHECKING),
('Service Accueil', Account.TYPE_CHECKING),
('Catip', Account.TYPE_DEPOSIT),
('Cic Immo', Account.TYPE_LOAN),
('Credit', Account.TYPE_LOAN),
('Crédits', Account.TYPE_LOAN),
('Eco-Prêt', Account.TYPE_LOAN),
('Mcne', Account.TYPE_LOAN),
('Nouveau Prêt', Account.TYPE_LOAN),
('Pret', Account.TYPE_LOAN),
('Credits Promoteurs', Account.TYPE_CHECKING), # it doesn't fit loan's model
('Compte Cheque', Account.TYPE_CHECKING),
('Compte Courant', Account.TYPE_CHECKING),
('Cpte Courant', Account.TYPE_CHECKING),
('Contrat Personnel', Account.TYPE_CHECKING),
('Cc Contrat Personnel', Account.TYPE_CHECKING),
('C/C', Account.TYPE_CHECKING),
('Start', Account.TYPE_CHECKING),
('Comptes courants', Account.TYPE_CHECKING),
('Service Accueil', Account.TYPE_CHECKING),
('Eurocompte Serenite', Account.TYPE_CHECKING),
('Catip', Account.TYPE_DEPOSIT),
('Cic Immo', Account.TYPE_LOAN),
('Credit', Account.TYPE_LOAN),
('Crédits', Account.TYPE_LOAN),
('Eco-Prêt', Account.TYPE_LOAN),
('Mcne', Account.TYPE_LOAN),
('Nouveau Prêt', Account.TYPE_LOAN),
('Pret', Account.TYPE_LOAN),
('Regroupement De Credits', Account.TYPE_LOAN),
('Nouveau Pret 0%', Account.TYPE_LOAN),
('Passeport Credit', Account.TYPE_REVOLVING_CREDIT),
('Allure Libre', Account.TYPE_REVOLVING_CREDIT),
('Preference', Account.TYPE_REVOLVING_CREDIT),
('Plan 4', Account.TYPE_REVOLVING_CREDIT),
('P.E.A', Account.TYPE_PEA),
('Pea', Account.TYPE_PEA),
('Nouveau Pret 0%', Account.TYPE_LOAN),
('Passeport Credit', Account.TYPE_REVOLVING_CREDIT),
('Allure Libre', Account.TYPE_REVOLVING_CREDIT),
('Preference', Account.TYPE_REVOLVING_CREDIT),
('Plan 4', Account.TYPE_REVOLVING_CREDIT),
('P.E.A', Account.TYPE_PEA),
('Pea', Account.TYPE_PEA),
('Compte De Liquidite Pea', Account.TYPE_PEA),
('Compte Epargne', Account.TYPE_SAVINGS),
('Etalis', Account.TYPE_SAVINGS),
('Ldd', Account.TYPE_SAVINGS),
('Livret', Account.TYPE_SAVINGS),
("Plan D'Epargne", Account.TYPE_SAVINGS),
('Tonic Croissance', Account.TYPE_SAVINGS),
('Capital Expansion', Account.TYPE_SAVINGS),
('Épargne', Account.TYPE_SAVINGS),
('Capital Plus', Account.TYPE_SAVINGS),
('Compte Garantie Titres', Account.TYPE_MARKET),
])
('Compte Epargne', Account.TYPE_SAVINGS),
('Etalis', Account.TYPE_SAVINGS),
('Ldd', Account.TYPE_SAVINGS),
('Livret', Account.TYPE_SAVINGS),
("Plan D'Epargne", Account.TYPE_SAVINGS),
('Tonic Croissance', Account.TYPE_SAVINGS),
('Capital Expansion', Account.TYPE_SAVINGS),
('Épargne', Account.TYPE_SAVINGS),
('Capital Plus', Account.TYPE_SAVINGS),
('Compte Garantie Titres', Account.TYPE_MARKET),
])
REVOLVING_LOAN_LABELS = [
'Passeport Credit',
......@@ -620,19 +621,18 @@ class CardsListPage(LoggedPage, HTMLPage):
class Transaction(FrenchTransaction):
PATTERNS = [(re.compile(r'^VIR(EMENT)? (?P<text>.*)'), FrenchTransaction.TYPE_TRANSFER),
(re.compile(r'^(PRLV|Plt|PRELEVEMENT) (?P<text>.*)'), FrenchTransaction.TYPE_ORDER),
(re.compile(r'^(?P<text>.*) CARTE \d+ PAIEMENT CB\s+(?P<dd>\d{2})(?P<mm>\d{2}) ?(.*)$'),
FrenchTransaction.TYPE_CARD),
(re.compile(r'^PAIEMENT PSC\s+(?P<dd>\d{2})(?P<mm>\d{2}) (?P<text>.*) CARTE \d+ ?(.*)$'),
FrenchTransaction.TYPE_CARD),
(re.compile(r'^(?P<text>RELEVE CARTE.*)'), FrenchTransaction.TYPE_CARD_SUMMARY),
(re.compile(r'^RETRAIT DAB (?P<dd>\d{2})(?P<mm>\d{2}) (?P<text>.*) CARTE [\*\d]+'),
FrenchTransaction.TYPE_WITHDRAWAL),
(re.compile(r'^CHEQUE( (?P<text>.*))?$'), FrenchTransaction.TYPE_CHECK),
(re.compile(r'^(F )?COTIS\.? (?P<text>.*)'), FrenchTransaction.TYPE_BANK),
(re.compile(r'^(REMISE|REM CHQ) (?P<text>.*)'), FrenchTransaction.TYPE_DEPOSIT),
]
PATTERNS = [
(re.compile(r'^(VIR(EMENT)?|VIRT.) (?P<text>.*)'), FrenchTransaction.TYPE_TRANSFER),
(re.compile(r'^(PRLV|Plt|PRELEVEMENT) (?P<text>.*)'), FrenchTransaction.TYPE_ORDER),
(re.compile(r'^(?P<text>.*) CARTE \d+ PAIEMENT CB\s+(?P<dd>\d{2})(?P<mm>\d{2}) ?(.*)$'), FrenchTransaction.TYPE_CARD),
(re.compile(r'^PAIEMENT PSC\s+(?P<dd>\d{2})(?P<mm>\d{2}) (?P<text>.*) CARTE \d+ ?(.*)$'), FrenchTransaction.TYPE_CARD),
(re.compile(r'^Regroupement \d+ PAIEMENTS (?P<dd>\d{2})(?P<mm>\d{2}) (?P<text>.*) CARTE \d+ ?(.*)$'), FrenchTransaction.TYPE_CARD),
(re.compile(r'^(?P<text>RELEVE CARTE.*)'), FrenchTransaction.TYPE_CARD_SUMMARY),
(re.compile(r'^RETRAIT DAB (?P<dd>\d{2})(?P<mm>\d{2}) (?P<text>.*) CARTE [\*\d]+'), FrenchTransaction.TYPE_WITHDRAWAL),
(re.compile(r'^CHEQUE( (?P<text>.*))?$'), FrenchTransaction.TYPE_CHECK),
(re.compile(r'^(F )?COTIS\.? (?P<text>.*)'), FrenchTransaction.TYPE_BANK),
(re.compile(r'^(REMISE|REM CHQ) (?P<text>.*)'), FrenchTransaction.TYPE_DEPOSIT),
]
_is_coming = False
......
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