LCL: implement account history

Signed-off-by: Pierre Mazière <pierre.maziere@gmail.com>
Signed-off-by: Romain Bignon <romain@peerfuse.org>
This commit is contained in:
Pierre Mazière 2011-03-06 23:47:54 +01:00 committed by Romain Bignon
commit e14af3b890
3 changed files with 47 additions and 3 deletions

View file

@ -18,7 +18,7 @@
from weboob.tools.browser import BaseBrowser, BrowserIncorrectPassword
from .pages import LoginPage, LoginErrorPage, FramePage, AccountsPage
from .pages import LoginPage, LoginErrorPage, FramePage, AccountsPage, AccountHistoryPage
__all__ = ['LCLBrowser']
@ -35,6 +35,7 @@ class LCLBrowser(BaseBrowser):
'https://particuliers.secure.lcl.fr/everest/UWBI/UWBIAccueil\?DEST=IDENTIFICATION': LoginErrorPage,
'https://particuliers.secure.lcl.fr/outil/UWSP/Synthese/accesSynthese': AccountsPage,
'https://particuliers.secure.lcl.fr/outil/UWB2/Accueil\?DEST=INIT': FramePage,
'https://particuliers.secure.lcl.fr/outil/UWLM/ListeMouvementsPro/accesListeMouvementsPro.*': AccountHistoryPage,
}
def __init__(self, agency, *args, **kwargs):
@ -73,6 +74,11 @@ class LCLBrowser(BaseBrowser):
return None
def get_history(self,account):
if not self.is_on_page(AccountHistoryPage) :
self.location('%s://%s%s' % (self.PROTOCOL, self.DOMAIN, account.link_id))
return self.page.get_operations()
#def get_coming_operations(self, account):
# if not self.is_on_page(AccountComing) or self.page.account.id != account.id:
# self.location('/NS_AVEEC?ch4=%s' % account.link_id)