move select() in parser
This commit is contained in:
parent
cf2dca7520
commit
9afb301ebe
30 changed files with 197 additions and 197 deletions
|
|
@ -22,7 +22,7 @@ import re
|
|||
|
||||
from weboob.capabilities.messages import CantSendMessage
|
||||
from weboob.tools.browser import BasePage
|
||||
from weboob.tools.parsers.lxmlparser import select
|
||||
|
||||
|
||||
|
||||
__all__ = ['ClosePage', 'ComposePage', 'ConfirmPage', 'SentPage']
|
||||
|
|
@ -37,7 +37,7 @@ class ComposePage(BasePage):
|
|||
|
||||
def get_nb_remaining_free_sms(self):
|
||||
remaining_regex = re.compile(u'Il vous reste (?P<nb>.+) Texto gratuits vers les numéros SFR à envoyer aujourd\'hui')
|
||||
text = select(self.document.getroot(), '#smsReminder', 1).text.strip()
|
||||
text = self.parser.select(self.document.getroot(), '#smsReminder', 1).text.strip()
|
||||
return remaining_regex.match(text).groupdict().get('nb')
|
||||
|
||||
def post_message(self, message):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue