Commit eab25a36 authored by Maxime Gasselin's avatar Maxime Gasselin Committed by Romain Bignon

[creditmutuel] Fix card history navigation

For the second half of the history (the last 6 month), it seems now to
be mandatory to add 'secondHalf' value to reach the xml pages.

Closes: 1021612@redmine 28727@sibi
parent ae7d78f4
......@@ -361,9 +361,14 @@ class CreditMutuelBrowser(LoginBrowser, StatesMixin):
urlstogo =
monthly_tr = []
half_history = 'firstHalf'
for url in urlstogo:
if 'GoMonthPrecedent' not in url:
if 'GoMonthPrecedent' in url:
# To reach the 6 last month of history you need to change this url parameter
# Moreover we are on a transition page where we see the 6 next month (no scrapping here)
half_history = 'secondHalf'
history =
self.tr_date =
......@@ -382,13 +387,13 @@ class CreditMutuelBrowser(LoginBrowser, StatesMixin):
m ='fid=GoMonth&mois=(\d+)', self.url)
if m:
m =
self.location('CRP8_SCIM_DEPCAR.aspx?_tabi=C&a__itaret=as=SCIM_ListeActivityStep\%3a\%3a\%2fSCIM_ListeRouter%3a%3a&a__mncret=SCIM_LST&a__ecpid=EID2011&_stack=_remote::moiSelectionner={},moiAfficher=firstHalf,typeDepense=T&_pid=SCIM_DEPCAR_Details'.format(m), data=data)
self.location('CRP8_SCIM_DEPCAR.aspx?_tabi=C&a__itaret=as=SCIM_ListeActivityStep\%3a\%3a\%2fSCIM_ListeRouter%3a%3a&a__mncret=SCIM_LST&a__ecpid=EID2011&_stack=_remote::moiSelectionner={},moiAfficher={},typeDepense=T&_pid=SCIM_DEPCAR_Details'.format(m, half_history), data=data)
self.location(self.url, data=data)
if not
history =
# We are now with an XML page with all the transactions of the months
# We are now with an XML page with all the transactions of the month
history =
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