Commit graph

2,255 commits

Author SHA1 Message Date
Laurent Bachelier
b4b7182960 Make Collection more safe and sane
* Remove callbacks in Collection object
  Make Collection a "dumb" object (and also a base object,
  though it isn't very useful for now)
* Rename Path to WorkingPath, because it is more about managing state
  than being a single path.
* Rewrite almost all WorkingPath, because the code was overly
  complicated for no reason (I tried some special cases and it turned
  out that fromstring didn't handle them, and that the
  quote-escape-unquote was just unecessary). I also rewrote it to be
  more pythonic (no more lambdas and maps) and added tests.
* Require the full split path when creating a Collection. Because, come to
  think of it, an object needs an unique identifier; in the case of
  Collections, it is the full path, not only its last part.
  I might even replace the id by the full split path in the future.
* There is now only one way to get items of a Collection: calling
  iter_resources().
* Rewrite flatten_resources to iter_resources_flat(), which just calls
  iter_resources() recursively.
* Rewrite the collection part of the canalplus module. There is no more
  callback or a page calling the browser to check another page!
  The logic is only in iter_resources().
  The resulting code is not very pretty, but it should get better.
  As a bonus, avoid to reload the main XML file when we already have it
  open.
* change_path() now expects a split path and not a string.
* up/home special cases for "cd" are handled in the same place, and
  store the previous place properly (but are not yet exploitable by
  an user command).

This is a big commit but it would be hard to split it in *working*
commits.

If you read this entire commit message, I will buy you a beer.

refs #774
fixes #773
2012-03-13 22:08:45 +01:00
Florent
749162188d Add fonction to list bills to download 2012-03-13 22:01:12 +01:00
Florent
7c147cecab Add Bill object 2012-03-13 22:01:11 +01:00
Florent
a8e01e7aee First implementation of boobill application
Only few functions are available
2012-03-13 22:01:10 +01:00
Florent
0238392059 Add datetime field to Details 2012-03-13 22:01:06 +01:00
jems
24ab551694 add library capability and backend and application for archimede software aloes http://www.archimed.fr/aloes/presentation-et-avantages-12.html
Signed-off-by: jems <jems@ldjm.fr>
Signed-off-by: Romain Bignon <romain@symlink.me>
2012-03-13 21:57:38 +01:00
Florent
af7e827856 Change capability to iter and download document 2012-03-13 18:18:18 +01:00
Laurent Bachelier
062f2c4c3e Fix Python 2.5 support
And fix some PEP8 style issues (mostly about spaces) while I was there.

refs #806
2012-03-13 12:36:02 +01:00
Romain Bignon
ef07a9e795 do not use thumbnail_url anymore (closes #810), use set_empty_fields() method, do not give fields in constructor of BaseVideo anymore 2012-03-12 17:16:42 +01:00
Romain Bignon
56691d7ea7 rename iter_search_results to either search_videos and search_gallery (closes #779) 2012-03-12 16:24:33 +01:00
Romain Bignon
5019e07232 check all empty values possible 2012-03-12 13:44:51 +01:00
Romain Bignon
4afac2a0d0 add method CapBaseObject.set_empty_fields()
This method can be used to fill all empty fields with the same value.

A field is empty when is value is None, NotLoaded or NotAvailable.

Example:

     # It will be impossible to get all empty fields, except
     # of 'url' (with a call to fillobj())
     video.set_empty_fields(NotAvailable, ('url',))
2012-03-12 13:42:00 +01:00
Laurent Bachelier
42a1fee141 Fix account types and add account types support to bnporc, for the account types I could get.
Types were taken from KMyMoney, which is for personal tracking, however
some types had no use (cash not something the bank can provide,
maybe credit card but it is usually the "coming" field for us).
Sources: https://en.wikipedia.org/wiki/Bank_account (but not focused on
personal banking) and it's French translation which was more interesting.
Other websites for American and Australian banking almost always mentioned three
accounts: checking/current, savings/deposits, term/fixed deposits.

And some code refactoring.
2012-03-11 01:33:20 +01:00
Romain Bignon
7e414804c8 add required class attributes 2012-03-10 09:23:12 +01:00
Romain Bignon
008bf57264 add field Account.type 2012-03-10 09:04:46 +01:00
Florent
b986cc12fd Add generic cleanup for newspapers storage 2012-03-09 10:05:13 +01:00
Laurent Bachelier
ee04a92f04 Support magnet URLs in weboorents 2012-03-09 02:49:00 +01:00
Laurent Bachelier
f8843084f0 Display magnet URLs when present 2012-03-09 02:14:54 +01:00
Laurent Bachelier
391783a8b6 Support gzipped responses 2012-03-09 01:35:51 +01:00
Laurent Bachelier
a31a751e28 Clean up the Torrent object
As discussed on IRC, those huge constructors aren't ideal.
Includes misc pep8 fixes.
2012-03-09 00:43:02 +01:00
Laurent Bachelier
5a456c22ac Sign modules.list 2012-03-08 01:54:06 +01:00
Florent
1e4851296c Add rsscomment to newsfeed 2012-03-06 19:30:58 +01:00
Laurent Bachelier
64bf35a7e9 Use libyaml for faster loading and saving
if installed
2012-03-06 19:11:02 +01:00
Romain Bignon
a51219a192 add_backend: do not crash if params is None 2012-03-03 23:19:58 +01:00
Romain Bignon
33a9bf71a8 rename havesex and QHaveSex to havedate and QHaveDate 2012-03-03 22:59:17 +01:00
Romain Bignon
00c784e331 display 'category' in priority, 'type' otherwise 2012-02-28 13:54:26 +01:00
Romain Bignon
dcd25b22eb flush output (useful with table formatter) 2012-02-26 18:40:41 +01:00
Florent
72893d88a0 Add ICapBill 2012-02-26 18:34:41 +01:00
Romain Bignon
234bdf6210 do not change sort of housings after display of a new one 2012-02-26 18:31:35 +01:00
Romain Bignon
d8b1588db0 add a TransactionsFormatter for commands 'history' and 'coming' 2012-02-26 18:31:07 +01:00
Romain Bignon
be14595308 apply changes to ICapBank API 2012-02-26 18:30:40 +01:00
Romain Bignon
b8d05430ec add a 'type' field on Transaction object 2012-02-26 15:05:04 +01:00
Romain Bignon
fbe9ccec04 fix crash when trying to add twice a same module 2012-02-25 13:43:58 +01:00
Romain Bignon
cf58a18f00 fix crash when a bookmarked housing has been removed from website 2012-02-22 12:59:57 +01:00
Florent
b30b6398fa Don't get articles if already seen. 2012-02-22 12:57:00 +01:00
Romain Bignon
f5ca33f80e can looking for a rent or a sale 2012-02-19 18:35:33 +01:00
Romain Bignon
3eddf8e6dd fix unicode issue 2012-02-19 18:34:33 +01:00
Romain Bignon
95ad372afc fix: create an 'id' attribute even if missing in the entry 2012-02-19 13:33:09 +01:00
Romain Bignon
d24ea00611 display enhancements 2012-02-19 12:48:11 +01:00
Romain Bignon
1a09a5d43d get(): do not store default value in tree if key is not found 2012-02-19 12:45:57 +01:00
Romain Bignon
d8d9eaef60 new housings on top 2012-02-19 10:57:27 +01:00
Romain Bignon
f0a41716f7 sort housings by cost/area 2012-02-19 10:36:12 +01:00
Romain Bignon
a0e4171af3 fix Newsfeed and GenericBackend 2012-02-18 17:40:22 +01:00
Romain Bignon
09d113b1be can write notes on housings, display them in list 2012-02-18 17:01:38 +01:00
Romain Bignon
1b76994e79 add button to remove a query 2012-02-18 13:15:00 +01:00
Romain Bignon
c8b6c7087b ability to edit queries 2012-02-18 12:56:11 +01:00
Romain Bignon
f340ac485e support bookmarks 2012-02-18 12:27:44 +01:00
Romain Bignon
f6c2edc64f add a 'fullid' property to get 'ID@backend' 2012-02-18 12:27:18 +01:00
Romain Bignon
379083d2d7 save read housings, and display new ones with a blue background 2012-02-18 11:58:28 +01:00
Florent
a195a5e9c8 Small fixe of the "rssid" method usage (updated)
Sorry, I did a little mistake.

Signed-off-by: Florent <weboob@flo.fourcot.fr>
Signed-off-by: Romain Bignon <romain@symlink.me>
2012-02-17 16:08:53 +01:00