Commit 5b7560f9 authored by Quentin Defenouillere's avatar Quentin Defenouillere Committed by Romain Bignon

[pradoepargne] Make module completely inherit from Humanis

The Prado website has been engulfed by Humanis.
It is currently 100% broken but works when using the Humanis URLs.
Since pradoepargne now behaves exactly like humanis, there is no point
in keeping a and a since it works with total
inheritance from humanis.

Closes: 35971@sibi, 35867@sibi, 36065@sibi
parent d7b32af6
# -*- coding: utf-8 -*-
# Copyright(C) 2017 Edouard Lambert
# This file is part of a weboob module.
# This weboob module is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# This weboob module is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# GNU Affero General Public License for more details.
# You should have received a copy of the GNU Affero General Public License
# along with this weboob module. If not, see <>.
from weboob.browser import AbstractBrowser, URL
from .pages import LoginPage
class PradoBrowser(AbstractBrowser):
PARENT = 'cmes'
login = URL('pradoepargne/fr/identification/default.cgi', LoginPage)
def __init__(self, baseurl, subsite, login, password, *args, **kwargs):
self.weboob = kwargs['weboob']
super(PradoBrowser, self).__init__(baseurl, login, password, subsite, *args, **kwargs)
......@@ -18,18 +18,15 @@
# along with this weboob module. If not, see <>.
from import CapBankPockets, AccountNotFound
from import Module, BackendConfig
from import AbstractModule, BackendConfig
from import ValueBackendPassword
from weboob.capabilities.base import find_object
from .browser import PradoBrowser
from import CapBankPockets
__all__ = ['PradoepargneModule']
class PradoepargneModule(Module, CapBankPockets):
class PradoepargneModule(AbstractModule, CapBankPockets):
NAME = 'pradoepargne'
DESCRIPTION = u'Prado Épargne Salariale'
MAINTAINER = u'Edouard Lambert'
......@@ -40,26 +37,4 @@ class PradoepargneModule(Module, CapBankPockets):
ValueBackendPassword('login', label='Identifiant', masked=False),
ValueBackendPassword('password', label='Mot de passe'))
BROWSER = PradoBrowser
def create_default_browser(self):
return self.create_browser("",
def get_account(self, _id):
return find_object(self.browser.iter_accounts(), id=_id, error=AccountNotFound)
def iter_accounts(self):
return self.browser.iter_accounts()
def iter_history(self, account):
return self.browser.iter_history(account)
def iter_investment(self, account):
return self.browser.iter_investment(account)
def iter_pocket(self, account):
return self.browser.iter_pocket(account)
PARENT = 'humanis'
# -*- coding: utf-8 -*-
# Copyright(C) 2012-2019 Budget Insight
from weboob.browser.pages import AbstractPage
class LoginPage(AbstractPage):
PARENT = 'cmes'
PARENT_URL = 'login'
BROWSER_ATTR = 'package.browser.CmesBrowser'
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