add backend.name param for new ConsoleApplication.format() method

This commit is contained in:
Christophe Benz 2010-06-22 10:44:52 +02:00
commit 7b8798efd9
2 changed files with 4 additions and 4 deletions

View file

@ -38,9 +38,9 @@ class Travel(ConsoleApplication):
@ConsoleApplication.command('Search stations')
def command_stations(self, pattern):
for backend, station in self.weboob.do('iter_station_search', pattern):
self.format(station)
self.format(station, backend.name)
@ConsoleApplication.command('List all departures on a special station')
def command_departures(self, station, arrival=None):
for backend, departure in self.weboob.do('iter_station_departures', station, arrival):
self.format(departure)
self.format(departure, backend.name)