Gery Debongnie
2fe3861353
[FIX] uses the user's timezone when performing a readgroup (in orm.py)
...
bzr revid: ged@openerp.com-20140128110022-j08khieyt1wvsr8e
2014-01-28 12:00:22 +01:00
Martin Trigaux
f2b2ee8eae
[FIX] expression: do not look at translation in parse when searching with empty string or false
...
This fixes traceback when applying filter 'is not set' on a translatable field
lp bug: https://launchpad.net/bugs/1208565 fixed
bzr revid: mat@openerp.com-20140127144913-qjh9hrnkfdn18sdb
2014-01-27 15:49:13 +01:00
Fabien Pinckaers
1c1b17451d
[FIX] adding menu
...
bzr revid: fp@tinyerp.com-20140125151454-g4xsi25g3re2arwo
2014-01-25 16:14:54 +01:00
Gery Debongnie
b2f27dabf0
[REF] implifies the read_group method by removing an useless dictionary (orm.py)
...
bzr revid: ged@openerp.com-20140124132834-evx3dikqc94m48ed
2014-01-24 14:28:34 +01:00
Gery Debongnie
09706b5dff
[IMP] adds 'W' in front of the week number when formatting date grouped by weeks (method read_group) (orm.py)
...
bzr revid: ged@openerp.com-20140124100921-w5gq1fwidm01xx5l
2014-01-24 11:09:21 +01:00
Raphael Collet
020921a7f3
[IMP] orm: remove commented code
...
bzr revid: rco@openerp.com-20140123094957-knrgx6sy66j4tj39
2014-01-23 10:49:57 +01:00
Raphael Collet
0fb09d9a33
[FIX] fields: small python code fix
...
bzr revid: rco@openerp.com-20140123094646-ri4apn315dm19rl1
2014-01-23 10:46:46 +01:00
Xavier Morel
d50f785b4f
[FIX] view requested by _view_ref with view_ref being undotted
...
Issue introduced in
revid:chm@openerp.com-20130828161130-641xsmbr8xm53xjx: context of a
fields_view_get can provide a *_view_ref name (e.g. tree_view_ref),
whose value is an xid for the view to use (can be used to specify a
view instead of providing a view_id, mostly for embedded views where
there is no way to provide a view_id).
The view_ref being an external id, it must be dotted. Historically,
undotted xids were silently ignored and the system just skipped to
getting the default view for the model (lowest priority view where
inherit_id is null).
In revid:odo@openerp.com-20130821122955-8c9z0mi8cu48rne3 this behavior
was altered to emit a warning when ignoring a malformed view_ref. When
this change was merged into trunk-website-al, the conditional
(view_ref and '.' in view_ref) was split without consideration for the
semantics change: a syntactically invalid view_ref would fall off the
first branch (view_ref) instead of taking the second one (not
view_ref), the code would not fetch the default view for the model and
would instead generate one (through _get_default_%(viewtype)s_view).
However, closer reading reveals the code was already broken in a
specific case of a syntactically valid but unknown xid (view_id
wouldn't get assigned in the first branch, but the code would not take
the second one, resulting yet again in a view generation even if the
database contains a valid view for the model and type).
Fixed by reintroducing explicit second check on view_id, instead of
merely conditional alternative.
bzr revid: xmo@openerp.com-20140123075742-603n2zthqhxee07y
2014-01-23 08:57:42 +01:00
Gery Debongnie
74386a5bb9
[IMP] changes the method read_group so that it now accepts groupbys of the form 'field:groupby_function', like 'create_date:week' for example. Also, removes the previous hack using the context (orm.py)
...
bzr revid: ged@openerp.com-20140122124206-b5p06tpzw2i7tpo2
2014-01-22 13:42:06 +01:00
Gery Debongnie
17e3c31992
[MERGE] merge trunk into local branch
...
bzr revid: ged@openerp.com-20140113142459-pjoiau7pp4knvvda
bzr revid: ged@openerp.com-20140116144304-d00alltpt7j1gzvh
bzr revid: ged@openerp.com-20140121142924-641cu8trhm4pdf1m
2014-01-21 15:29:24 +01:00
Martin Trigaux
a75ebb628c
[IMP] search_read: avoid calling read if search only on id column (security rules already triggered with search)
...
bzr revid: mat@openerp.com-20140117120235-zdj7pjd8xnnrnqol
2014-01-17 13:02:35 +01:00
Christophe Simonis
2f90f80ba0
[FIX] orm: As float fields are stateful (the .digit attribute depend of the database (decimal_precision)), registry model instances need their owm copy.
...
lp bug: https://launchpad.net/bugs/929483 fixed
bzr revid: chs@openerp.com-20140116153708-061aq2k0n1qsb2n3
2014-01-16 16:37:08 +01:00
Thibault Delavallée
ab5c23079a
[MERGE] Sync with trunk, solved conflicts.
...
bzr revid: tde@openerp.com-20140116091716-zk1n5ots94i65io5
2014-01-16 10:17:16 +01:00
Christophe Simonis
0771ca2692
[MERGE] forward port of branch saas-2 up to revid 5002 dle@openerp.com-20140114173613-ruxye1m7fxtcjfim
...
bzr revid: chs@openerp.com-20140115205357-arptzm69logz3osm
2014-01-15 21:53:57 +01:00
jke-openerp
8fbc5b159d
[MERGE] Merge with trunk
...
bzr revid: jke@openerp.com-20140113193949-39t5hssln2u5s899
2014-01-13 20:39:49 +01:00
Stephane Wirtel
dfe775ba1e
[IMP] orm: Use a list of tuples instead of three collections.
...
bzr revid: stw@openerp.com-20140113153124-8921v1010xeuqeb8
2014-01-13 16:31:24 +01:00
Gery Debongnie
fcf97a559a
[IMP] adds support for week/quarter groupby in readgroup method (orm.py)
...
bzr revid: ged@openerp.com-20140113133602-ytxleg91bu3fyx62
2014-01-13 14:36:02 +01:00
Stephane Wirtel
ec35576af3
[IMP] Use INSERT INTO RETURNING for the creation of a record and use some tables
...
instead of a string for the generation of the SQL query.
bzr revid: stw@openerp.com-20140110162731-ma7wk61zof6h9vyr
2014-01-10 17:27:31 +01:00
Martin Trigaux
3fb75a44c8
[FIX] orm: add missing context (without the lang attribute to avoid setting translated values) in write call.
...
bzr revid: mat@openerp.com-20140109153601-13wo9gj5cz6ho3nm
2014-01-09 16:36:01 +01:00
Denis Ledoux
05aab83eb1
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 9743 revid:qdp-launchpad@openerp.com-20140108160719-9i8xhrat49cn9l5e
...
bzr revid: chs@openerp.com-20140107141524-xzz39a2ym66swr0t
bzr revid: chs@openerp.com-20140107172248-zic9mqg0rigy2czb
bzr revid: chs@openerp.com-20140108160418-ph17jgy5hlejj9hr
bzr revid: dle@openerp.com-20140108171400-8r0fwv3wi36w2im0
2014-01-08 18:14:00 +01:00
Christophe Simonis
7f8b6542f0
[FIX] expression: allow exclusion of records with translated fields
...
lp bug: https://launchpad.net/bugs/1071710 fixed
bzr revid: chs@openerp.com-20140108152722-7f0dpsuv1skxbqub
2014-01-08 16:27:22 +01:00
Martin Trigaux
13063d5713
[IMP] osv: display full traceback in terminal (not client side) when a check fails instead of minimal error
...
bzr revid: mat@openerp.com-20140108140554-oey9bje52ndqe0e3
2014-01-08 15:05:54 +01:00
Christophe Simonis
9675445dee
[FIX] expression: allow exclusion of records with translated fields
...
Manual forwardport of revid 4369 chs@openerp.com-20140107112227-sc1ssd1dw404vcz2 of 6.1 branch
lp bug: https://launchpad.net/bugs/1071710 fixed
bzr revid: chs@openerp.com-20140107130840-igmm8sy03nrm5d5f
2014-01-07 14:08:40 +01:00
Gery Debongnie
c2a0f93b9e
[IMP] changes the readgroup method to allow better control in the groupby field when it is a date/datetime (for example, it is now possible to group by week/quarter) (orm.py)
...
bzr revid: ged@openerp.com-20140107085800-hwyt41j3hwj1h1n8
2014-01-07 09:58:00 +01:00
jke-openerp
5a4ecf0134
[Merge] Merge with trunk
...
bzr revid: jke@openerp.com-20131218130304-y3scbl1ms65vhupf
bzr revid: jke@openerp.com-20131220144934-e0hvmc5du87k2k8n
bzr revid: jke@openerp.com-20140106082149-xzralqftgxnauv51
2014-01-06 09:21:49 +01:00
Thibault Delavallée
7a72d858cb
[MERGE] Sync with trunk
...
bzr revid: tde@openerp.com-20140103151324-jk0u8vmrxxomy5vx
2014-01-03 16:13:24 +01:00
Guewen Baconnier
780e1548c0
[CHG] set lang to False instead of en_US (already being the default language), reducing the places where this default value is set
...
bzr revid: guewen.baconnier@camptocamp.com-20131228203801-3z6g1bb0ggfio5x0
2013-12-28 21:38:01 +01:00
Martin Trigaux
79f716c70f
[MERGE] forward port of latest saas-2 until rev 4996 dle@openerp.com-20131218123130-vlejjv7r2klkzoj0
...
bzr revid: mat@openerp.com-20131218160041-58x5kij4v7earagu
2013-12-18 17:00:41 +01:00
jke-openerp
196436f73b
[MERGE] Merge with trunk
...
bzr revid: jke@openerp.com-20131127175727-76iuqrgmg8fumi5f
bzr revid: jke@openerp.com-20131202142549-t1l5pyse00zqw8wm
bzr revid: jke@openerp.com-20131210164214-ctl2z8dzkzohha13
bzr revid: jke@openerp.com-20131211085211-zhnm8ylpz0cws1lg
bzr revid: jke@openerp.com-20131211131225-v60hox0q6drwajqu
2013-12-11 14:12:25 +01:00
Cecile Tonglet
a48c8119ca
[FIX] name_search() where _rec_name is a reference field and links are broken
...
bzr revid: cto@openerp.com-20131211103842-i1n9t8mg9kuw77v3
2013-12-11 11:38:42 +01:00
Xavier ALT
9a4c62861f
[FIX] orm: early return within ``_apply_ir_rules`` for superuser.
...
Save a few time by not not trying to apply ir.rule for superuser, that will
anyway be skipped within ir.rule's ``_compute_domain`` method.
bzr revid: xal@openerp.com-20131210140330-oui4oy8pez12xkxv
2013-12-10 15:03:30 +01:00
Xavier ALT
f5458a954d
[FIX] orm: cleaner batch number of records for auto_init() stored fields.function update
...
bzr revid: xal@openerp.com-20131210122312-f3f4h0z4lpiagsk3
2013-12-10 13:23:12 +01:00
Cecile Tonglet
86776035ba
[FIX] Model.create: trigger stored field recalculation for implicit parent_id fields during create
...
The create() method implicitly creates parent records on objects of the _inherits.
Therefore, in order to make the trigger on the linked field works, we should
include all the _inherits values (fields that make the link to the parent
record) because they are created implicitly.
The write() method does not need this change, as any update of the parent
fields has to be explicit.
bzr revid: odo@openerp.com-20131209184718-wczdefzo9evc0cgc
2013-12-09 19:47:18 +01:00
Denis Ledoux
20be322c45
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 9684 rev-id: dle@openerp.com-20131209145652-3g9rgnfz1w8k0whw
...
bzr revid: chs@openerp.com-20131202105848-33gcz1715w370rve
bzr revid: dle@openerp.com-20131204150643-is3y0b9n8enh3yql
bzr revid: chs@openerp.com-20131206152726-pirikn7v8pev90ic
bzr revid: dle@openerp.com-20131206162437-b9niay99mirk44qm
bzr revid: tde@openerp.com-20131209102019-kjeg0rx2au1d5e5v
bzr revid: dle@openerp.com-20131209155721-589zihxx8jmvlpvp
2013-12-09 16:57:21 +01:00
Cecile Tonglet
3b328aaab4
[FIX] Trigger stored field recalculation for inherited records
...
The create() method implicitly creates record on objects of the _inherits.
Therefore, in order to make the trigger on linked field works, we should
include all the _inherits values (field that makes the link to the rel
record) because they are created implicitly.
bzr revid: cto@openerp.com-20131209154857-788f94w0kh6ef5pp
2013-12-09 16:48:57 +01:00
Cecile Tonglet
2e197cbb98
[IMP] Batch for the computation of function's stored values is now customizable
...
bzr revid: cto@openerp.com-20131209141111-tbg9x1h8l6neu0ml
2013-12-09 15:11:11 +01:00
Martin Trigaux
d2ca43402e
[FIX] orm: inverting the condition seems to work (don't ask why)
...
bzr revid: mat@openerp.com-20131206142220-nfqiyeic9fdkejxy
2013-12-06 15:22:20 +01:00
Martin Trigaux
0be3333f96
[FIX] orm: ignore existing link for operation (4, x) in one2many fields
...
bzr revid: mat@openerp.com-20131206125403-r6uemlh7jagw01gh
2013-12-06 13:54:03 +01:00
Cecile Tonglet
cdff5c1366
[IMP] Performance: by-pass call to _apply_ir_rules for user admin
...
bzr revid: cto@openerp.com-20131205121118-0f9087y2huo7y44l
2013-12-05 13:11:18 +01:00
Martin Trigaux
9652fb0013
[IMP] orm: force checking ir.rules on read when accessing only to _classic_write fields (o2m, m2m, function)
...
More consistent behaviour. Was not able to access unauthorized data (retrieving data on x2m field would trigger security rules) but make sure it raises an exception instead of silently retrieve no data.
Move construct domain inside if clause as no needed before
bzr revid: mat@openerp.com-20131205113254-j3j4bb0p6ed23oht
2013-12-05 12:32:54 +01:00
Christophe Matthieu
8460122209
[MERGE] sync with trunk
...
bzr revid: chm@openerp.com-20131202150856-fzrfcoa8pmsjutau
2013-12-02 16:08:56 +01:00
Christophe Simonis
56bb1b9869
[MERGE] forward port of branch saas-2 up to revid 4992 chs@openerp.com-20131202105848-33gcz1715w370rve
...
bzr revid: chs@openerp.com-20131127110757-5kaay2kcxq0ysb59
bzr revid: chs@openerp.com-20131127161639-yur4rdh3wx43kxle
bzr revid: chs@openerp.com-20131127180647-f8uws77gaym5kfvd
bzr revid: chs@openerp.com-20131202110030-gf20dv2uj5fqv7c2
2013-12-02 12:00:30 +01:00
Fabien Pinckaers
51a32f45a0
[IMP] Speed improvement
...
bzr revid: fp@tinyerp.com-20131130171849-i1cao342bik6wd89
2013-11-30 18:18:49 +01:00
Christophe Simonis
f2da2d6811
[FIX] orm: browse() do not prefetch deprecated fields
...
bzr revid: chs@openerp.com-20131127152537-wkof87ut5cdud6z6
2013-11-27 16:25:37 +01:00
Christophe Simonis
6347f9f4ea
[IMP] orm: copy() does not copy deprecated fields
...
bzr revid: chs@openerp.com-20131126185210-8kd5stdexa4ozn2m
2013-11-26 19:52:10 +01:00
Xavier Morel
1235955197
[IMP] exception handling in _dispatch
...
* ensure users correctly get a 403 forbidden from a failed
_authenticate
* as far as we can tell, NotFound is one of the few things
_authenticate does *not* throw. Catch all exceptions anyway.
* replace default _handle_500, _handle_403 and _handle_404 by single
generic handler since all they did was re-raise the exception anyway
bzr revid: xmo@openerp.com-20131126110519-0yjh01ubrulpzlmn
2013-11-26 12:05:19 +01:00
Christophe Simonis
ab386c0f5f
[MERGE] forward port of branch saas-2 up to revid 4984 chs@openerp.com-20131125151017-lmj53bxg1pfrr4a7
...
bzr revid: chs@openerp.com-20131125154140-cpbk4tcdml2a3b9n
2013-11-25 16:41:40 +01:00
Christophe Simonis
3211a29d9b
[MERGE] forward port of branch 7.0 up to revid 5148 mat@openerp.com-20131125125008-wmpssjk5vygdcc0w
...
bzr revid: chs@openerp.com-20131125151017-lmj53bxg1pfrr4a7
2013-11-25 16:10:17 +01:00
Martin Trigaux
9635119fc1
[FIX] fields: execute name_get for function field of type many2one as SUPERUSER_ID (same behaviour as classical many2one)
...
bzr revid: mat@openerp.com-20131125125008-wmpssjk5vygdcc0w
2013-11-25 13:50:08 +01:00
Martin Trigaux
e2102ca9ce
[IMP] orm: add missing space in error message during validation
...
bzr revid: mat@openerp.com-20131125124717-4jsqv0lfu7hpxusi
2013-11-25 13:47:17 +01:00
Martin Trigaux
3b5cf5d56c
[FIX] translations: fix tests to adapt to new duplication behaviour and remove context hack in copy_data (translations are now fully handled in copy_translation)
...
bzr revid: mat@openerp.com-20131125115727-o9oejao1ziagqti1
2013-11-25 12:57:27 +01:00
Martin Trigaux
fbbc6ea840
[FIX] orm: when duplicating translated object, modify the values to get more coherent values
...
user's language: old (untranslated) -> new (translated)
other language: old (untranslated) -> old (translated)
This allows to have coherent behaviour if copy() method is overwritten to change the text (usually applying _('%s (copy)')). The current user will see the translated terms with modification while the translations are kept for others (and need to be updated).
We prefer keeping slightly irrelevant translations (without translated version of '%s (copy)') for other languages than losing it.
bzr revid: mat@openerp.com-20131125110736-d6iygeq8om5y4fkz
2013-11-25 12:07:36 +01:00
Martin Trigaux
10608a5d18
[FIX] ir_translation: correctly match old and new ids on inherit fields
...
new_id was correctly handled at rev 5118 but the old_id wasn't which could produce inconsistency if there was a gap in ids
bzr revid: mat@openerp.com-20131122175939-lvlf4ih4pyidqxjp
2013-11-22 18:59:39 +01:00
Denis Ledoux
6fd552c3ce
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 5139 rev-id: dle@openerp.com-20131121132305-qjlclgz5v9tze1fr
...
bzr revid: odo@openerp.com-20131120102545-2tlp031yib6viz35
bzr revid: chs@openerp.com-20131120161708-c8sbom592moukwxw
bzr revid: dle@openerp.com-20131121155457-lh7fzouk2upeiu16
2013-11-21 16:54:57 +01:00
Olivier Dony
b7865502e4
[FIX] orm.browse_record: access error due to prefetch of indirectly referenced records (OPW #596679 )
...
The browse_record prefetching algorithm attempts to
load data for all known records from the requested
model (i.e. all IDs present in the browse cache),
regardless of how indirectly/remotely they were
referenced. An indirect parent record may therefore
be prefetched along with its directly browsed children,
possibly crossing company boundaries involuntarily.
This patch implements a fallback mechanism when
the prefetching failed due to what looks like an
ACL restriction. This being a fuzzy concept at the
moment, it does its best to only catch a restricted
set of exceptions, and retry loading the data for
the directly requested ID only.
This may cause a small performance penalty in case
of real errors (with some spurious logging too),
but should only be triggered in very few cases.
The downside when this happens is that the prefetching for that
model gets effectively disabled, requiring multiple
SQL queries for further access to the data of
the other directly browsed records.
This EAFP approach seems safer and faster than
a LBYL technique where we would have to filter
all indirect m2o references according to ACLs
before allowing them to enter the cache.
lp bug: https://launchpad.net/bugs/1238042 fixed
lp bug: https://launchpad.net/bugs/1212429 fixed
bzr revid: odo@openerp.com-20131120100627-031fljyf4ckprc9b
2013-11-20 11:06:27 +01:00
jke-openerp
9e980b4e9d
bzr revid: jke@openerp.com-20131115165942-pki8hgk1j7qxitk8
2013-11-15 17:59:42 +01:00
Xavier Morel
8e78b40e6a
[MERGE] from trunk
...
bzr revid: xmo@openerp.com-20131115132553-9eqxggih8be63i36
2013-11-15 14:25:53 +01:00
Christophe Simonis
ec88c042b2
[MERGE] forward port of branch saas-1 up to revid 4918 chs@openerp.com-20131114134731-n324awyon0spq624
...
bzr revid: chs@openerp.com-20131114135502-xqi6df3jzm7ng0io
2013-11-14 14:55:02 +01:00
Christophe Simonis
993bff902e
[MERGE] forward port of branch 7.0 up to revid 4067 chs@openerp.com-20131114142639-ng7wzfjwvvel2nhv
...
bzr revid: dle@openerp.com-20131112134311-h1vsux0ge17bsqkc
bzr revid: chs@openerp.com-20131114134731-n324awyon0spq624
bzr revid: chs@openerp.com-20130823145204-xwpnlwg0gg2259f6
bzr revid: chs@openerp.com-20130906170157-e7m4pjskyi47q82o
bzr revid: dle@openerp.com-20130909170408-wxgoduzggap6o4ng
bzr revid: dle@openerp.com-20130919141212-ridtrvvfwvu6calr
bzr revid: dle@openerp.com-20131018120136-fvoq337kgx74njsy
bzr revid: dle@openerp.com-20131023103308-18pj2gqq3imrcir7
bzr revid: chs@openerp.com-20131030180528-hqsztaujjjqev8ky
bzr revid: dle@openerp.com-20131106100128-mx8mnguvp321wick
bzr revid: chs@openerp.com-20131115104909-3u3mu40g9xnler88
2013-11-15 11:49:09 +01:00
jke-openerp
7c58ae62fb
[MERGE]0k/web_fullcalendar branch from github
...
bzr revid: jke@openerp.com-20131106164738-0medo6b8938rphzm
2013-11-06 17:47:38 +01:00
Martin Trigaux
4d9e140b8c
[IMP] comments
...
bzr revid: mat@openerp.com-20131104144427-oyca1g1ti583sq3c
2013-11-04 15:44:27 +01:00
Martin Trigaux
91cf53228b
[FIX] orm: when duplicating a record, if duplicates translations on a field from _inherits model, use the id of the parent record instead.
...
Avoid getting old value by removing 'source' value from read result.
lp bug: https://launchpad.net/bugs/1237878 fixed
bzr revid: mat@openerp.com-20131104143408-o71lyws8uba679hd
2013-11-04 15:34:08 +01:00
Quentin (OpenERP)
bdda7b70d3
[FIX] expression.py: when searching on a datetime field with an argument formated as a date, conversion should happen _also_ for the '=' operator. This omission was causing an infinite loop beacuse we were pushing the exact same leaf on the stack without any modification
...
bzr revid: qdp-launchpad@openerp.com-20131104134314-2mv5wkt13ih9c1yg
2013-11-04 14:43:14 +01:00
Guewen Baconnier
226ed9abea
[FIX] propage the context to not lose special keys/values on write() and explicit the source language to write to (en_US)
...
lp bug: https://launchpad.net/bugs/1247158 fixed
bzr revid: guewen.baconnier@camptocamp.com-20131101161820-rwzh8zx2nqpb7r2q
2013-11-01 17:18:20 +01:00
Christophe Simonis
82211b1ac2
[MERGE] forward port of branch 7.0 up to revid 5113 launchpad_translations_on_behalf_of_openerp-20131031054724-b9dbttdcrl9eccwr
...
bzr revid: chs@openerp.com-20131025103657-pbnqhw11mygyi5jn
bzr revid: chs@openerp.com-20131031142125-7bm00z2jpccf3v6f
2013-10-31 15:21:25 +01:00
Christophe Simonis
d67ff9ba02
[FIX] views inheritance: deleting a non-existing attribute must be a no-op
...
bzr revid: chs@openerp.com-20131108175750-yenql6hycpn95i9j
2013-11-08 18:57:50 +01:00
Quentin (OpenERP)
c384955cfa
[FIX] osv.fields: don't raise an error for searching on dummy fields because it's their main reason to be
...
bzr revid: qdp-launchpad@openerp.com-20131030102313-64gb1n98rzdg5mx1
2013-10-30 11:23:13 +01:00
Thibault Delavallée
97f164ba99
[MERGE] Sync with trunk
...
bzr revid: tde@openerp.com-20131028163325-2hpks3hp23zop40n
2013-10-28 17:33:25 +01:00
Christophe Simonis
d91819cb43
[MERGE] forward port of branch saas-2 up to revid 4965 chs@openerp.com-20131025103939-5gta1eifjhx1tsmi
...
bzr revid: chs@openerp.com-20131025104326-4k5hayl0bwdgt0mm
2013-10-25 12:43:26 +02:00
Christophe Simonis
2029aa28eb
[MERGE] forward port of branch saas-1 up to revid 4914 chs@openerp.com-20131025103657-pbnqhw11mygyi5jn
...
bzr revid: chs@openerp.com-20131025103939-5gta1eifjhx1tsmi
2013-10-25 12:39:39 +02:00
Christophe Simonis
2859897815
[FIX] allow falsy extra attributes on fields.
...
bzr revid: chs@openerp.com-20131024135448-e2bpgaqu7mvg1icn
2013-10-24 15:54:48 +02:00
niv-openerp
5696282656
[MERGE] saas2
...
bzr revid: nicolas.vanhoren@openerp.com-20131018103501-sns9zca0nmpm9efn
2013-10-18 12:35:01 +02:00
Olivier Dony
54f740960e
[MERGE] Forward-port of latest saas-1 bugfixes, up to rev. 4912 rev-id: odo@openerp.com-20131016110621-36vvlpn8dgsabyt1
...
bzr revid: odo@openerp.com-20131016111800-jjybreg62bwz61zn
2013-10-16 13:18:00 +02:00
Olivier Dony
7cb7405ffd
[IMP] orm: _store_get_values: rename variables to make this horror slightly more readable
...
We keep having to fight variable decay in that function, for some reason.
bzr revid: odo@openerp.com-20131011134501-7b5rflknjm1r9zfd
2013-10-11 15:45:01 +02:00
Olivier Dony
8ac110c4dd
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 5098 rev-id: odo@openerp.com-20131011123914-7zuvd9mch21yxgj8
...
bzr revid: dle@openerp.com-20131009131902-a93nsbou4w8y0vlx
bzr revid: chs@openerp.com-20131009175454-j06y1ngylfbqyrpj
bzr revid: dle@openerp.com-20130918160049-fo88fl7uyhfoofkv
bzr revid: dle@openerp.com-20130924130544-kmkyr0d73cusvdav
bzr revid: odo@openerp.com-20131011134433-nyfjipvlql4xu127
2013-10-11 15:44:33 +02:00
Olivier Dony
dafa12d92c
[FIX] ir.model: FK constraints for custom m2o fields were never created, creating possible data integrity errors
...
bzr revid: odo@openerp.com-20131010170718-lwoxkqc1tx7i8vhg
2013-10-10 19:07:18 +02:00
Martin Trigaux
a0059326fc
[IMP] remove useless comment
...
bzr revid: mat@openerp.com-20131008111631-y47f0y4wyf8hsf2g
2013-10-08 13:16:31 +02:00
Martin Trigaux
9680b1cd39
[IMP] move comment to the right line
...
bzr revid: mat@openerp.com-20131008105412-pqxpo2q12odjyqp4
2013-10-08 12:54:12 +02:00
Martin Trigaux
241c054b35
[IMP] correctly bound _symbol_f and redifine self._symbol_set_char to keep the API
...
bzr revid: mat@openerp.com-20131008104737-eellli48re2pfmos
2013-10-08 12:47:37 +02:00
Martin Trigaux
3ae73d572d
[FIX] function fields: bound symbol methods of function field (type char) to the correct methods of the char field
...
lp bug: https://launchpad.net/bugs/1208074 fixed
bzr revid: mat@openerp.com-20131008102135-r7lqvky0vd75yo1q
2013-10-08 12:21:35 +02:00
Thibault Delavallée
b74c255168
[MERGE] Sync with trunk until revision 4967 (including al cleaning)
...
bzr revid: tde@openerp.com-20131007081039-adyay7oy1tpx4g2k
2013-10-07 10:10:39 +02:00
Antony Lesuisse
f1faa55cb6
rename links get, allow reference fields without size.
...
bzr revid: al@openerp.com-20131006114704-mkbheq3l355u21jb
2013-10-06 13:47:04 +02:00
Thibault Delavallée
a1d6ac520c
[MERGE] Sync with trunk.
...
Pleave avoid merging with other branches like saas branch, this causes criss-cross issues.
Do things completely instead of tryign to gain 3 minuts.
bzr revid: chm@openerp.com-20131003151612-bmaylm7v3ywqwaux
bzr revid: tde@openerp.com-20131004084936-8xdvfjm2dhtyq07p
2013-10-04 10:49:36 +02:00
Thibault Delavallée
c98ff51f72
[FORWARD] Forward port of saas-2 fixes until revision 4957 chs@openerp.com-20130930125946-exr791f83seaa9br
...
bzr revid: tde@openerp.com-20131003150138-dgi593kd3n0vflgp
2013-10-03 17:01:38 +02:00
Raphael Collet
7358cec8dc
[FIX] expression: in nodes like (left, 'in', right), apply _symbol_set on all values in right
...
bzr revid: rco@openerp.com-20131003075351-5quyz6ge1ayczdo9
2013-10-03 09:53:51 +02:00
Thibault Delavallée
54933118a4
[MERGE] Sync with trunk until revision 4957.
...
bzr revid: tde@openerp.com-20131002133820-8xomdumexexqp3pk
2013-10-02 15:38:20 +02:00
Martin Trigaux
7fc046e6b3
[IMP] orm: don't compute twice the same function for stored fields if two fields have the same trigger function
...
bzr revid: mat@openerp.com-20130930140515-4kbzkotjh2ify5vm
2013-09-30 16:05:15 +02:00
Christophe Simonis
03ef8485d7
[FIX] orm: correct read_group when searching by month
...
bzr revid: chs@openerp.com-20130930125946-exr791f83seaa9br
2013-09-30 14:59:46 +02:00
Martin Trigaux
46020a08da
[IMP] store fields: do not add twice the same function field in the store_function list
...
bzr revid: mat@openerp.com-20130930121511-94a2k0ka91bsgrnf
2013-09-30 14:15:11 +02:00
Xavier Morel
c741c0eeb1
[IMP] reimplement t-field using new converters
...
bzr revid: xmo@openerp.com-20130926145126-21hlubvs39a0z68j
2013-09-26 16:51:26 +02:00
Xavier Morel
789c0d8a6b
[ADD] Conversions from field values to "html" content
...
> many2one --> mettre <br/> si multi-line, html escape le reste (ex:
> adresse sur un event, on a du mettre dans un <pre> mais ce n'est pas
> bien)
> text --> mettre <br/> si multi-line, html escape le reste (ex:
> description d'un produit, à droite)
> char --> normalement pas de multi-line
> fields.binary --> t-field on image field ne semble pas fonctionner
> en écriture (la photo d'une fiche produit)
(validates that the binary field's content is image data by opening it
with PIL, then generates an <img> tag)
TODO:
> fields.float --> utiliser le digits pour formatter les decimals
> correctement (ex: prix d'un produit, à deux décimales)
> On aura aussi besoin d'un widget="currency", un peu comme dans la
> vue form du client web.
bzr revid: xmo@openerp.com-20130926133850-ab14h241q878jbom
2013-09-26 15:38:50 +02:00
Christophe Simonis
28b09221d6
[FIX] orm.BaseModel.exists(): early return if no ids given
...
bzr revid: chs@openerp.com-20130919114711-ofx2aubtr5z7dgh4
2013-09-19 13:47:11 +02:00
Christophe Simonis
fd9a9577df
[MERGE] forward port of branch saas-1 up to revid 4908 dle@openerp.com-20130918160049-fo88fl7uyhfoofkv
...
bzr revid: chs@openerp.com-20130918171816-cxxt3c9ktcq4a8oz
2013-09-18 19:18:16 +02:00
Thibault Delavallée
54c014c4ea
[IMP] read_group: group_by -> groupby (same variable, but was used in previous implementation, so I keep it)
...
bzr revid: tde@openerp.com-20130917100447-u0qhdsw14wdngxwc
2013-09-17 12:04:47 +02:00
Thibault Delavallée
63988959a7
[IMP] read_group: added forgottent year computation
...
bzr revid: tde@openerp.com-20130916114722-4742fhn4ilhf133e
2013-09-16 13:47:22 +02:00
Thibault Delavallée
defa3adbe8
[DOC] read_group: added comments for the new formatting option
...
bzr revid: tde@openerp.com-20130916103047-lpbf7czflyvgtonu
2013-09-16 12:30:47 +02:00
Christophe Simonis
e13ffe7e11
[MERGE] forward port of branch 7.0 up to revid 5075 chs@openerp.com-20130912141018-qmcyase8zqov9d01
...
bzr revid: chs@openerp.com-20130906165207-1oklc8cqs0rex3kg
bzr revid: dle@openerp.com-20130909170248-a4t5y6qd5ikkhhac
bzr revid: dle@openerp.com-20130911083736-6jfkb140jxbbx7j6
bzr revid: chs@openerp.com-20130912150616-v0c383trj7gaa7eu
2013-09-12 17:06:16 +02:00
Christophe Simonis
1d91378ce2
[FIX] ir.ui.view: properly validate newly created inheriting views
...
When a new inheriting view is imported during a module
installation, it is validated thanks to the _constraints
on the ir.ui.view model. However the validation uses
a rather convoluted system for validating the whole
view tree at once (root view + all inherited changes)
while only taking into account the views that belong
to modules that are currently loaded.
This complicated system is necessary to be able to
operate on-the-fly at any point during the registry
loading/initialization.
Now because _constraints are checked during create()
this particular validation happens *before* the
external ID (ir.model.data entry) of that new view
can be created (it obviously needs to wait until
the view record is inserted). As a consequence the
view validation cannot determine the module to
which that new view belongs, and was erroneously
ignoring it.
Changing the view filtering to also include views
that have triggered this check.
Manually created views are not check during registry
update.
bzr revid: chs@openerp.com-20130912141018-qmcyase8zqov9d01
2013-09-12 16:10:18 +02:00
Thibault Delavallée
aca5e76062
[IMP] orm: first draft of improvign group_by on date field, allowing to tune the grain, format and interval when grouping on a date field. Default behavior is the old one, grouping on month.
...
bzr revid: tde@openerp.com-20130910104500-sfjosqkmpfxa2jxk
2013-09-10 12:45:00 +02:00
Xavier Morel
367f8dcf83
[FIX] some models rename fields parameter to read, revert passing it by name to positionally
...
bzr revid: xmo@openerp.com-20130904105318-ib5gwejlplozo12d
2013-09-04 12:53:18 +02:00
Christophe Matthieu
c36bfe173e
[MERGE] from trunk
...
bzr revid: chm@openerp.com-20130828161130-641xsmbr8xm53xjx
2013-08-28 18:11:30 +02:00
Fabien Pinckaers
53824ea842
[MERGE] forward port fix from trunk for access rights on /shop
...
bzr revid: fp@tinyerp.com-20130828095443-pxll7f4cx8g20flm
2013-08-28 11:54:43 +02:00
Xavier Morel
5684c5d286
[IMP] search_read code
...
bzr revid: xmo@openerp.com-20130821135853-i9g6cvi52onrmmte
2013-08-21 15:58:53 +02:00
Olivier Dony
4eb9059480
[IMP] BaseModel.fields_view_get: warn about non-qualified *_view_ref references
...
lp bug: https://launchpad.net/bugs/1214799 fixed
bzr revid: odo@openerp.com-20130821122955-8c9z0mi8cu48rne3
2013-08-21 14:29:55 +02:00
Christophe Simonis
208b697239
[MERGE] forward port of branch saas-1 up to revid 4899 chs@openerp.com-20130821094758-1ae0d1ml5obufzxv
...
bzr revid: odo@openerp.com-20130820160346-qcdy4kavgm5cb9t6
bzr revid: chs@openerp.com-20130821103139-zqqbrt8dq6iixrny
2013-08-21 12:31:39 +02:00
Olivier Dony
fbd0758cb5
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 5054 rev-id: odo@openerp.com-20130820091157-e5brwlxuhujf8rrd
...
bzr revid: chs@openerp.com-20130724085026-525l9apggc9yzx0h
bzr revid: odo@openerp.com-20130730140644-1xih0as5jsks4pub
bzr revid: dle@openerp.com-20130801130723-khgwjkglgsdn34fj
bzr revid: odo@openerp.com-20130820091638-jpbcmh653bpa29em
2013-08-20 11:16:38 +02:00
Christophe Simonis
e78a83ac03
[FIX] browse records do not prefetch fields with groups
...
bzr revid: chs@openerp.com-20130819174930-xjzmrhuuuuwnbdg0
2013-08-19 19:49:30 +02:00
Christophe Simonis
815fc8f84a
[FIX] browse records do not try to prefetch fields user can't read
...
bzr revid: chs@openerp.com-20130819164622-7cre7yqpvlyzsslj
2013-08-19 18:46:22 +02:00
Christophe Matthieu
27b69126d2
[MERGE] from trunk
...
bzr revid: chm@openerp.com-20130726141834-9nroj7wi4fjhd5s4
2013-07-26 16:18:34 +02:00
Thibault Delavallée
f737eb63d0
[IMP] ir_actions_server: added doc + comments + recursion check
...
orm: added _check_m2my_recursion, to check loops in many2many recursive fields
tools: removed sms_send
bzr revid: tde@openerp.com-20130725104914-dutxfon3odp8z167
2013-07-25 12:49:14 +02:00
Christophe Simonis
03381c761d
[FIX] expression: a valid leaf must have a non empty string as first element or be the magic TRUE_LEAF/FALSE_LEAF
...
lp bug: https://launchpad.net/bugs/1197323 fixed
bzr revid: chs@openerp.com-20130719091903-28ez0txxyjh6qiii
2013-07-19 11:19:03 +02:00
Thibault Delavallée
5aad20b9a6
[IMP] fields: date, datetime: added MONTHS variable holding list of (month_number, month_name)
...
bzr revid: tde@openerp.com-20130709123740-18t5yhbtoru6vpne
2013-07-09 14:37:40 +02:00
Christophe Simonis
5a5d9d5941
merge upstream
...
bzr revid: chs@openerp.com-20130702191613-djzicmgpvrhh05zi
2013-07-02 21:16:13 +02:00
Christophe Simonis
5a58a48ef5
[MERGE] forward port of branch saas-1 up to revid 4893 chs@openerp.com-20130701153735-xnbb8zauabf1k63u
...
bzr revid: chs@openerp.com-20130702144745-763n9cdphkppshxl
2013-07-02 16:47:45 +02:00
Antony Lesuisse
b0a348d24e
fields_view_get view_id
...
bzr revid: al@openerp.com-20130701130258-52nvw8aj6s8bcjaf
2013-07-01 15:02:58 +02:00
Antony Lesuisse
3b0935325e
fields_view_get apply post processing even for default views
...
bzr revid: al@openerp.com-20130701122626-9g2uo6ox3p74e55q
2013-07-01 14:26:26 +02:00
Antony Lesuisse
05c9b607f8
fix rng validation, fields_view_get, qweb t-esc t-raw default
...
bzr revid: al@openerp.com-20130630213515-go5qr2dmo0xlazvr
2013-06-30 23:35:15 +02:00
Antony Lesuisse
932efea388
untangle inheritance and postprocessing
...
bzr revid: al@openerp.com-20130629213516-pqcl6oz1g3o5tpgn
2013-06-29 23:35:16 +02:00
Denis Ledoux
9f4397fc85
[MERGE]forward port of latest 7.0 bugfixes, up to rev 5017
...
rev 5017 = launchpad_translations_on_behalf_of_openerp-20130626061833-drxvzosffezp089g
bzr revid: dle@openerp.com-20130627120342-znttbs00q5bkf4ov
2013-06-27 14:03:42 +02:00
Stefan Rijnhart
216f4d5e66
[FIX] Do not search for model = table name in previous commit
...
bzr revid: stefan@therp.nl-20130626140439-3emprb4ewc2xlcsy
2013-06-26 16:04:39 +02:00
Stefan Rijnhart
126b49075d
[FIX] Export creates xml id based on wrong table name
...
lp bug: https://launchpad.net/bugs/1194893 fixed
bzr revid: stefan@therp.nl-20130626135842-sdbvopuen0s7liv9
2013-06-26 15:58:42 +02:00
Christophe Simonis
c0115e7597
[FIX] orm: Do not prefetch custom fields.
...
When installing or updating a module, custom fields referring custom model
(many2one) cannot be read because custom model are not loaded at this stage
(they are only loaded after all modules because they can refer any model).
Not prefetching them avoid crash when computing stored function fields.
bzr revid: chs@openerp.com-20130626091332-231rqg5ouhnc3d2x
2013-06-26 11:13:32 +02:00
Antony Lesuisse
f4332b9b60
[MERGE] trunk
...
bzr revid: al@openerp.com-20130625162755-d6552p98m5jiw941
2013-06-25 18:27:55 +02:00
Quentin (OpenERP)
bcac5bd834
[FIX] ir_property: fixes in property fields related to multi company use cases
...
bzr revid: qdp-launchpad@openerp.com-20130624085731-fthhdpdm4ldi3220
2013-06-24 10:57:31 +02:00
Antony Lesuisse
4f76c69b76
[MERGE] trunk
...
bzr revid: al@openerp.com-20130620151512-p5ysov21an6ogbtv
2013-06-20 17:15:12 +02:00
Olivier Dony
9a5e317618
[FIX] OPW 592482: browse_record should not prefetch binary fields
...
This was apparently a long-standing issue due to a
strange handling of the _prefetch attribute on
columns: accessing a column would only trigger
the prefetching if its _prefetch attribute was
True, but the prefetching itself would also
prefetch columns that had _prefetch False.
We clearly want it the other way around, or
at least we want _prefetch to decide whether
a column is included in any given prefetching
pass. We can skip the prefetching pass when
the only field being accessed has _prefetch
False because it is likely the other fields
have already been prefetched separately.
This last subtlety should not make any
noticeable performance difference.
lp bug: https://launchpad.net/bugs/1177965 fixed
bzr revid: odo@openerp.com-20130620131057-v7s4qfqj976j3ufo
2013-06-20 15:10:57 +02:00
Quentin (OpenERP)
31d05360b2
[REF] fields: removed deprecated view_load attribute and removed useless first argument in property fields definition
...
bzr revid: qdp-launchpad@openerp.com-20130619091332-29pisdnyfemn1u3d
2013-06-19 11:13:32 +02:00
niv-openerp
7822665429
added search_read
...
bzr revid: nicolas.vanhoren@openerp.com-20130621091332-s37ma5gbg88999xv
2013-06-21 11:13:32 +02:00
niv-openerp
a94bbf8e5e
[FIX] Merge fix in saas1 for the problem that made the server crash when install a db
...
bzr revid: nicolas.vanhoren@openerp.com-20130610144915-0nj8vpk7n84ocj3f
bzr revid: nicolas.vanhoren@openerp.com-20130610150657-3xddn91gm0iq0ubp
bzr revid: nicolas.vanhoren@openerp.com-20130610154514-oee6s4f9g17bx63z
2013-06-10 17:45:14 +02:00
Vo Minh Thu
8d0a477644
[IMP] ir_ui_view: do not use _logger.exception() (because there is no exception), add a check on `model`.
...
bzr revid: vmt@openerp.com-20130605121143-u2nkmcmeifphr54h
2013-06-05 14:11:43 +02:00
Vo Minh Thu
0019a86ecf
[MERGE] orm: add _sql_contraints only when _auto.
...
bzr revid: vmt@openerp.com-20130604115402-4cf07eq53o6ocs39
2013-06-04 13:54:02 +02:00
Olivier Dony
b16935efdc
[IMP] orm: include forbidden IDs when logging ir.rules violations, to make troubleshooting easier
...
bzr revid: odo@openerp.com-20130604111354-1x5yc305okhx5ujk
2013-06-04 13:13:54 +02:00
Amit Dodiya
244c82fe4f
[FIX]ir_property: If we add a property on a many2one field with multicompany the value of main company is replaced in all companies value
...
bzr revid: ado@tinyerp.com-20130604110137-jclbsmkohs5mm66w
2013-06-04 16:31:37 +05:30
Vo Minh Thu
6f1531f1d3
[MERGE] orm: add __iter__ method on browse_null.
...
Otherwise Python falls back to __getitem__ when trying to loop over it
or when trying to test `in`.
bzr revid: vmt@openerp.com-20130604081706-z79vqj36ls2adw09
2013-06-04 10:17:06 +02:00
Amit Dodiya
f7d2e495fd
[FIX]ir_property: If we add a property on a many2one field with multicompany the value of main company is replaced in all companies value
...
bzr revid: ado@tinyerp.com-20130531120925-s10hwscv2gexh27a
2013-05-31 17:39:25 +05:30
Amit Dodiya
f1db39aab1
[FIX]ir_property: If we add a property on a many2one field with multicompany the value of main company is replaced in all companies value
...
bzr revid: ado@tinyerp.com-20130531115736-ecrpaer2f2yhnvs5
2013-05-31 17:27:36 +05:30
Amit Dodiya
bfa4ab09f6
[FIX]ir_property: If we add a property on a many2one field with multicompany the value of main company is replaced in all companies value
...
bzr revid: ado@tinyerp.com-20130531101249-1w17yuoklhmiv2cc
2013-05-31 15:42:49 +05:30
Amit Dodiya
99d4732f04
[FIX]ir_property: If we add a property on a many2one field with multicompany the value of main company is replaced in all companies value
...
bzr revid: ado@tinyerp.com-20130527115951-7zssei2fnxyqzrpq
2013-05-27 17:29:51 +05:30
Amit Dodiya
b7e1be5539
[FIX]ir_property: If we add a property on a many2one field with multicompany the value of main company is replaced in all companies value
...
bzr revid: ado@tinyerp.com-20130527114601-tqzlrna1n9jssou2
2013-05-27 17:16:01 +05:30
Thibault Delavallée
1d5068b63e
[FORWARD] Forward port of server 7.0 until revision 4988
...
bzr revid: tde@openerp.com-20130528102733-bsszxp6nvy8yws3t
2013-05-28 12:27:33 +02:00
c01e2fe122
[FIX]ir_property: If we add a property on a many2one field with multicompany the value of main company is replaced in all companies value
...
bzr revid: ado@tinyerp.com-20130520090111-h20jboltev763mj6
2013-05-20 14:31:11 +05:30
Martin Trigaux
8ecd022348
[IMP] clean permissions and shebang in files
...
bzr revid: mat@openerp.com-20130514103333-puuj4kmxq3bwzwec
2013-05-14 12:33:33 +02:00
Ronald Portier
4634dd6f8e
[FIX] Add __iter__ method to browse_null to prevent server hang.
...
lp bug: https://launchpad.net/bugs/1172292 fixed
bzr revid: ronald@therp.nl-20130424142958-u5r2mxtxqj9v431h
2013-04-24 16:29:58 +02:00
Xavier Morel
73ac06ea51
[MERGE] from trunk because ???
...
bzr revid: xmo@openerp.com-20130424142412-hk38mnzkafyigh00
2013-04-24 16:24:12 +02:00
Xavier Morel
c08513763c
[NOTSURE] move __view_look_dom_arch into ir.ui.view
...
Also alter BaseModel._view_look_dom_arch to proxy to method above.
bzr revid: xmo@openerp.com-20130424135825-grjfgbjuc4ozzdqy
2013-04-24 15:58:25 +02:00
Xavier Morel
66121aaec7
[IMP] try to make __view_look_dom_arch independent from model
...
bzr revid: xmo@openerp.com-20130424133716-6qm0n00yiussz1ra
2013-04-24 15:37:16 +02:00
Xavier Morel
fb492d98ba
[ADD] behavior and tests for default & ancestors, fallback handling in read_combined
...
bzr revid: xmo@openerp.com-20130424130907-6d6lkrkrgqv0hsfq
2013-04-24 15:09:07 +02:00
Xavier Morel
8715746672
[IMP] move stuff around, try building flatter top-down API with read_combined as utility 'do all the things' hook
...
bzr revid: xmo@openerp.com-20130424095114-4nw0nfuxzx4n1ltv
2013-04-24 11:51:14 +02:00
Christophe Simonis
261dea6fec
[MERGE] forward port of server v7 up to revision 4954
...
bzr revid: qdp-launchpad@openerp.com-20130422093655-txqmbalod6qmw1s6
bzr revid: chs@openerp.com-20130423183723-9kiexdyzdew8iuzm
2013-04-23 20:37:23 +02:00
Christophe Simonis
60f0bd08ee
[FIX] expression: allow creating child_of expression even if "id" field has been redefined, courtesy of Gustavo Adrian Marino
...
lp bug: https://launchpad.net/bugs/1030942 fixed
lp bug: https://launchpad.net/bugs/1131992 fixed
bzr revid: chs@openerp.com-20130423181926-yk628txd6yiybtko
2013-04-23 20:19:26 +02:00
Xavier Morel
dfc1800305
[MERGE] from trunk to match addons
...
bzr revid: xmo@openerp.com-20130423155233-c7tyowoqsfzzdjv8
2013-04-23 17:52:33 +02:00
Xavier Morel
3ac47a587e
[IMP] remove deprecated explicit setting of type on views
...
bzr revid: xmo@openerp.com-20130423154456-wt4aeb6yr963jbye
2013-04-23 17:44:56 +02:00
Xavier Morel
d40ec67c2d
[IMP] move application of view inheritance outside of fields_view_get and into View.
...
change get_root_ancestor to return just the id of the ancestor view
bzr revid: xmo@openerp.com-20130423150844-eubxue9vbtc6jhof
2013-04-23 17:08:44 +02:00
Xavier Morel
dd43214fe1
[ADD] tests to get_root_ancestor
...
use a default view_type of form in the tests, because whatever
bzr revid: xmo@openerp.com-20130423132523-upbgbt2a3r7cgs08
2013-04-23 15:25:23 +02:00
Xavier Morel
aef4ce51a7
[IMP] move fetching of root view into ir.ui.view
...
bzr revid: xmo@openerp.com-20130423124657-zkogrodgdw0ymf2f
2013-04-23 14:46:57 +02:00
Xavier Morel
c212710f25
[IMP] move resolution of view_ref outside of root-ancestor-searching loop
...
bzr revid: xmo@openerp.com-20130423111929-fs49v0xrahqsi48u
2013-04-23 13:19:29 +02:00
Xavier Morel
e996f92e6c
[REF] move apply_inheritance_specs to ir.ui.view
...
also moved raise_view_error utility function
bzr revid: xmo@openerp.com-20130423105856-558rl6ankd4g3qb0
2013-04-23 12:58:56 +02:00
Xavier Morel
b0f2d3044a
[FIX] don't 'double tap' when applying view inheritance
...
iter(exclude_base=False) would add the base view (being extended) to the sequence, and thus start by extending the base view with itself.
bzr revid: xmo@openerp.com-20130423100845-ryumkx12cwv60pc1
2013-04-23 12:08:45 +02:00
Xavier Morel
980e01d386
[IMP] attempt to remove lexical dependencies from fvg's nested functions
...
should allow moving most of the view inheritance application into
ir.ui.view, where it should belong.
bzr revid: xmo@openerp.com-20130422142444-f09sw841jop3t4a4
2013-04-22 16:24:44 +02:00
Xavier Morel
edf1f23a6e
[ADD] depth-first iterator on views, refactor apply_view_inheritance to use it
...
bzr revid: xmo@openerp.com-20130422125000-pg60ovrxejegenka
2013-04-22 14:50:00 +02:00
Xavier Morel
aa9406e28b
[IMP] move locate inner function to ir.ui.view method
...
bzr revid: xmo@openerp.com-20130419141409-a2jqq5maszc53e6s
2013-04-19 16:14:09 +02:00
Quentin (OpenERP)
d621d26516
[FIX] orm, _generate_order_by(): allow to order by LOG_ACCESS_COLUMNS even if the column is not defined again in self._columns. Raising an error instead of silently skipping the order_by
...
bzr revid: qdp-launchpad@openerp.com-20130419145417-2tix8ynmx51qiqkf
2013-04-19 16:54:17 +02:00
Olivier Dony
8efd16f25a
[FIX] res.partner, orm._check_recursion: prevent recursive partner structures + fix false positives in check_recursion()
...
- res.partner must prevent creating loops in partner
hierarchies, and this can be done easily with an
extra _constraint using the ORM's builtin _check_recursion
- _check_recursion's implementation incorrectly
assumed that the provided 'ids' were unrelated
(not part of a common hierarchy).
- add tests for _check_recursion via extra
tests on res.partner structure
(explains why both patches are in the same
commit)
bzr revid: odo@openerp.com-20130415171732-aj3j2e2mycvzf4kp
2013-04-15 19:17:32 +02:00
Xavier Morel
bbe0fbe2b9
[IMP] use ORM reads when loading views
...
direct SQL query in core ORM means we can't override view loading to
get them from other sources than the database. By using read() this
can be done by overriding ir_ui_view.read.
bzr revid: xmo@openerp.com-20130415100858-ucm97f318mjn5ugq
2013-04-15 12:08:58 +02:00
Raphael Collet
05851d21ba
[MERGE] from trunk
...
bzr revid: rco@openerp.com-20130411073017-x6e4h8xbvmy3ofdw
2013-04-11 09:30:17 +02:00
Thibault Delavallée
2ab15ddeaf
[MERGE] Sync with trunk.
...
bzr revid: tde@openerp.com-20130405110750-1dd4y02xz3wb6ill
bzr revid: tde@openerp.com-20130405133237-n7k66b3w0b3a17o3
2013-04-05 15:32:37 +02:00
Vo Minh Thu
307ca374d6
[MERGE] forward merge 7.0 until revision 4919.
...
bzr revid: vmt@openerp.com-20130404130704-24vsmczw34cssytd
2013-04-04 15:07:04 +02:00
Raphael Collet
09be864f1d
[IMP] replace all tests like 'registry.get(X)' by 'X in registry' where X is non static
...
bzr revid: rco@openerp.com-20130329140723-dnrl02saky570xg0
2013-03-29 15:07:23 +01:00
Thibault Delavallée
655ef77092
[MERGE] Sync with trunk.
...
bzr revid: tde@openerp.com-20130328092414-htawc7j3jrxte866
2013-03-28 10:24:14 +01:00
Thibault Delavallée
5c091dd8e2
[CLEAN] BaseModel: moved get_empty_list_help method to a better place in the code; added some comments.
...
bzr revid: tde@openerp.com-20130328092357-v3grmw9brp9wtfj0
2013-03-28 10:23:57 +01:00
Chris Biersbach
15bd42f5e5
[FIX] Removes the limit of 64 characters from additional text fields added via the interface
...
lp bug: https://launchpad.net/bugs/1053511 fixed
bzr revid: cbi@openerp.com-20130327132335-tro1p1n5at042jfb
2013-03-27 14:23:35 +01:00
Vo Minh Thu
2829882389
[IMP] orm: added a print_report() method.
...
bzr revid: vmt@openerp.com-20130325143256-f8hw66j09310cgjo
2013-03-25 15:32:56 +01:00
Thibault Delavallée
4e74279576
[MERGE] Sync with trunk.
...
bzr revid: tde@openerp.com-20130322090938-xoh67sg08m3ylcrk
2013-03-22 10:09:38 +01:00
Olivier Dony
41598ef041
[FIX] orm.expression: `=?` domain operator broken after 7.0 refactoring ; + added tests
...
lp bug: https://launchpad.net/bugs/1095635 fixed
bzr revid: odo@openerp.com-20130321173737-a0j330ro4i223fkb
2013-03-21 18:37:37 +01:00
Christophe Matthieu
491c3b73f3
[IMP] code cleaning for get_empty_list_help
...
bzr revid: chm@openerp.com-20130321133207-j4tiibjev6lkeuxa
2013-03-21 14:32:07 +01:00
Vo Minh Thu
067cd7d15a
[FIX] ir_model_data: create the _inherits parent external ID prior to the child.
...
This is needed so the uninstall process can simply go through
the installed data by using the ir_model_data entries in reverse
order (when ordered by IDs), so that parents are deleted before
children.
bzr revid: vmt@openerp.com-20130321133202-igea1vxlszfpk6pe
2013-03-21 14:32:02 +01:00
Christophe Matthieu
45cc77dbcb
[MERGE] from trunk
...
bzr revid: chm@openerp.com-20130320133155-qn27q8aek7zp1ls4
2013-03-20 14:31:55 +01:00
Xavier Morel
9494f21ea8
[FIX] __getattr__ implementation on BaseModel
...
object has no __getattr__, in the usual case super(BaseModel,
self).__getattr__ will blow up with an AttributeError (but the wrong
one).
On the other hand, if a BaseModel descendant class is used in MI
alongside a non-BM descendant (e.g. res_partner inheriting from Model
and format_address) and the non-BM descendant also implements
__getattr__, we want to forward the failed attr search to the other
__getattr__ implementation.
So check if super() has a __getattr__, call it if it does otherwise
AttributeError right there.
bzr revid: xmo@openerp.com-20130315115302-z7jla334gb9a5e43
2013-03-15 12:53:02 +01:00
Vo Minh Thu
c79c23d26e
[REF] orm:
...
- isinstance(ids, dict) is done at the end, but not at the beginning,
so if ids was a single dict, it would break in the map(lambda).
- The loop to convert None to False can be done in _read_flat instead
of read (there is already plenty of loops in _read_flat)
- The __getattr__ was breaking the stacktrace.
bzr revid: vmt@openerp.com-20130314154418-0wmxfw1ot92kjmzf
2013-03-14 16:44:18 +01:00
Chris Biersbach
6b80f5bdff
[FIX] orm: moves the access_rule check to the end of the create method to avoid getting errors when trying to create and m2m values are passed, which can cause the rules to fail
...
bzr revid: cbi@openerp.com-20130314092017-agwzvwwbxev531kk
2013-03-14 10:20:17 +01:00
Christophe Matthieu
a37aea3a85
[MERGE] from trunk
...
bzr revid: chm@openerp.com-20130313141600-pyazzzanowtrfjja
2013-03-13 15:16:00 +01:00
Guewen Baconnier
c377140650
[FIX] add SQL constraints only for models stored in database (not on AbstractModel)
...
lp bug: https://launchpad.net/bugs/1151703 fixed
bzr revid: guewen.baconnier@camptocamp.com-20130307085826-omhoc3clix41zydl
2013-03-07 09:58:26 +01:00
Quentin (OpenERP)
d97916a063
[IMP] expression.py: added a clue to debug fuzzy tracebacks related to domain badly written
...
bzr revid: qdp-launchpad@openerp.com-20130306152328-qdlil19diks4mvkt
2013-03-06 16:23:28 +01:00
Olivier Dony
db81edc287
[FIX] *: fix/rationalize db logging to avoid incorrect values during logging
...
The setting/clearing of the tracking were not done
consistently, causing log messages that appeared
to come from one database while coming from another
one or none at all.
The tracker is now set at the earliest points
of request handling where we can:
- in web client, when creating WebRequests (dbname, uid)
- at RPC dispatching in server (uid)
- at cron job acquisition in CronWorker (dbname)
- at Registry acquisition in RegistryManager (dbname)
The tracker is cleared at the very entrance of
the request in the WSGI `application`, ensuring
that no logging is produced with an obsolete
db name. (It cannot be cleared at the end of
the request handling because the werkzeug
wrapper outputs more logging afterwards)
bzr revid: odo@openerp.com-20130301120744-jfitcmze2jldecod
2013-03-01 13:07:44 +01:00
Vo Minh Thu
f1adca94c0
[MERGE] netsvc/service.model: added missing/removed unnecessary `except` clauses.
...
bzr revid: vmt@openerp.com-20130225155828-a364gk3ii2prxe0b
2013-02-25 16:58:28 +01:00
Fabien Pinckaers
b831c5aa15
[iMP] error message simplified for required values
...
bzr revid: fp@openerp.com-20130224135248-wdxg8d3fi79lp88z
2013-02-24 14:52:48 +01:00
Olivier Dony
a961e5e377
[MERGE] search: when count=True, execute main query as a subquery to avoid side effects with offset and limit
...
Granted, calling search() with both count=True and
offset or limit is not extremely useful, but
it is still better to accept it and apply it
to the inner query rather than have silly
errors
bzr revid: odo@openerp.com-20130220174416-yoos2py8dc9jc3md
2013-02-20 18:44:16 +01:00
Vo Minh Thu
9412351315
[IMP] Only unhandled exceptions are logged to the console by the netsvc layer.
...
bzr revid: vmt@openerp.com-20130220115337-6319hshm4vfwlr1o
2013-02-20 12:53:37 +01:00
Olivier Dony
bd02d21f2d
[MERGE] osv: automatically retry transactions that failed due to a transient concurrent transaction conflict
...
lp bug: https://launchpad.net/bugs/992525 fixed
bzr revid: odo@openerp.com-20130219173813-ldrx8l1hlegi2e3y
2013-02-19 18:38:13 +01:00
Raphael Collet
0f43032b82
[FIX] search: when count=True, execute main query as a subquery to avoid side effects with offset and limit
...
bzr revid: rco@openerp.com-20130218145100-4q24j8ko9j9elwpw
2013-02-18 15:51:00 +01:00
Quentin (OpenERP)
0a27066e54
[REF] code review
...
bzr revid: qdp-launchpad@openerp.com-20130215143503-6a6x53gdeb6j33tm
2013-02-15 15:35:03 +01:00
Antonin Bourguignon
74ba45d1fc
[MERGE] trunk
...
bzr revid: abo@openerp.com-20130214173522-2ama9xjn4c2hloap
2013-02-14 18:35:22 +01:00
Raphael Collet
70bda50f7d
[IMP] rename model method 'trigger_workflow' into 'step_workflow' (less confusing)
...
bzr revid: rco@openerp.com-20130213150134-wocd9ey2pubpa3xn
2013-02-13 16:01:34 +01:00
Raphael Collet
f78eb868fd
[IMP] remove model methods _workflow_trigger and _workflow_signal, and replace calls to new workflow methods
...
bzr revid: rco@openerp.com-20130213140046-84aa1xtlndltlhzy
2013-02-13 15:00:46 +01:00
Cecile Tonglet
2346b0d88c
[FIX] osv: Bad error message
...
bzr revid: cto@openerp.com-20130213133345-ovhlrfd2g5sb2tts
2013-02-13 14:33:45 +01:00
Cecile Tonglet
8d491afca5
[FIX] osv: Automatically retry the typical transaction serialization errors
...
lp bug: https://launchpad.net/bugs/992525 fixed
bzr revid: cto@openerp.com-20130213125255-ct0bf90pky2n6w3c
2013-02-13 13:52:55 +01:00
Antonin Bourguignon
f929ebc73b
[MERGE] trunk
...
bzr revid: abo@openerp.com-20130213105620-xyez3q7ddgc0x5x8
2013-02-13 11:56:20 +01:00
Raphael Collet
6f045b48e8
[MERGE] from trunk
...
bzr revid: rco@openerp.com-20130213082352-t3wbhkxfh3z10ukt
2013-02-13 09:23:52 +01:00
Raphael Collet
e76befd6c6
[MERGE] trunk-service-thu (remove the class openerp.netsvc.ExportService)
...
bzr revid: rco@openerp.com-20130212154230-y54s2rbetllwnh4q
2013-02-12 16:42:30 +01:00
Vo Minh Thu
c99c4091ce
[REM] Deleted .apidoc lines.
...
They were probably used by some tools. How sad.
bzr revid: vmt@openerp.com-20130212142410-zqdjd8jw3gtvxab0
2013-02-12 15:24:10 +01:00
Antonin Bourguignon
fbb51ee106
[MERGE] trunk
...
bzr revid: abo@openerp.com-20130212125650-3r8lsai6p5c8ls2h
2013-02-12 13:56:50 +01:00
Antonin Bourguignon
e274ccc7cb
[MERGE] trunk
...
bzr revid: abo@openerp.com-20130211150920-c5yam3yykht1qdpn
2013-02-11 16:09:20 +01:00
Xavier Morel
4a9d82621e
[IMP] don't log from import when converting psycopg exceptions to output messages
...
add conversion for unique constraints, test behavior on unique constraint failure
bzr revid: xmo@openerp.com-20130211143647-l16ssw9z73stbgyc
2013-02-11 15:36:47 +01:00
Xavier ALT
4db48cc102
[MERGE] BUG 1082003: orm: _rec_name should be checked on _all_columns not _columns
...
bzr revid: xal@openerp.com-20130211092411-3eeo2ann5jnttliq
2013-02-11 10:24:11 +01:00
Vo Minh Thu
6b459a1f27
[DOC] orm: documented workflow-related methods.
...
bzr revid: vmt@openerp.com-20130206150244-hs67hhe35okl42ei
2013-02-06 16:02:44 +01:00
Christophe Matthieu
3da294f56a
[IMP] ir_action: averwrite read to add a dynamic_help on model
...
bzr revid: chm@openerp.com-20130204145824-mq423czac9k2inzo
2013-02-04 15:58:24 +01:00
Anand Patel (OpenERP)
a52d21e1cb
[IMP]Improved code for the base_import requirde field
...
bzr revid: pan@tinyerp.com-20130201102750-ozxa3xwqa4rsnt60
2013-02-01 15:57:50 +05:30
Vo Minh Thu
a57b655e43
[REF] object_proxy is no longer used by audittrail (which patches directly openerp.service.model).
...
bzr revid: vmt@openerp.com-20130131161442-17rwinwygte6usfg
2013-01-31 17:14:42 +01:00
Vo Minh Thu
e86f90b0c7
[FIX] osv.object_service must be called osv.object_proxy.
...
bzr revid: vmt@openerp.com-20130130135859-vy96niq19fjsp8g4
2013-01-30 14:58:59 +01:00
Vo Minh Thu
674056c4a5
[REF] services: somewhat clean use of openerp exceptions.
...
bzr revid: vmt@openerp.com-20130130134451-yft2y56hkpnoxgwa
2013-01-30 14:44:51 +01:00
Vo Minh Thu
19b0315f68
[REF] model service: removed the unneeded object_service class.
...
bzr revid: vmt@openerp.com-20130130113646-pviw5d6gnohk7wrb
2013-01-30 12:36:46 +01:00
Vo Minh Thu
271aafd8de
[IMP] added create_workflow, delete_workflow,redirect_workflow as ORM methods.
...
bzr revid: vmt@openerp.com-20130129122710-ypvk9x7ndq84mq8r
2013-01-29 13:27:10 +01:00
Vo Minh Thu
200d008fc4
[FIX] orm: call super in __getattr__.
...
bzr revid: vmt@openerp.com-20130125165314-66j55mtobvt61c7r
2013-01-25 17:53:14 +01:00
Vo Minh Thu
ad7d846106
[IMP] orm: expose a signal_xxx() method to call workflow.trg_validate().
...
bzr revid: vmt@openerp.com-20130125155132-nhyntobe5xm1g7h0
2013-01-25 16:51:32 +01:00
Antonin Bourguignon
11dbed0fb7
[IMP] only call ir.translation when necessary
...
bzr revid: abo@openerp.com-20130123153722-iijbl8hvesstneq3
2013-01-23 16:37:22 +01:00
Antonin Bourguignon
0b65aa2231
[IMP] fix a comment's indentation, remove a few whitespaces
...
bzr revid: abo@openerp.com-20130123152234-g2ou48xajxsq8sqj
2013-01-23 16:22:34 +01:00
Antonin Bourguignon
8214854b79
[IMP] doc
...
bzr revid: abo@openerp.com-20130117144755-r9oboeaw8rr1seqa
2013-01-17 15:47:55 +01:00
Olivier Dony
8e5f0e2ce2
[FIX] fields.date[time]: context_today()/context_timestamp() should fallback to user TZ if context TZ is missing
...
This takes care of cases where the context is missing,
e.g. for workflow-based operations, and is similar
to the way tools.translate._() falls back to the user
language.
lp bug: https://launchpad.net/bugs/949516 fixed
bzr revid: odo@openerp.com-20130111175717-u8r1t7s8872bz2rx
2013-01-12 06:57:17 +13:00
Christophe Simonis
c10d28e4e6
[FIX] orm: SUPERUSER is not restricted by groups on fields
...
bzr revid: chs@openerp.com-20130116164025-qns65cb78p8p57m1
2013-01-16 17:40:25 +01:00
Fabien Pinckaers
aa86fb2bc1
[IMP] custom model allowed
...
bzr revid: fp@tinyerp.com-20121227172825-lny2fobb5g89edca
2012-12-27 18:28:25 +01:00
Raphael Collet
c9bc74c5c9
[MERGE] lp:~therp-nl/openobject-server/ronald@therp.nl_trunk_lp1009014_new (improve transient models vacuum)
...
bzr revid: rco@openerp.com-20121221153122-q6j8vatd2xfmqr3n
2012-12-21 16:31:22 +01:00
Raphael Collet
8ead65d82a
[IMP] orm: fix vacuum of transient model
...
bzr revid: rco@openerp.com-20121221152914-qs1s9h1zwnyzft1m
2012-12-21 16:29:14 +01:00
Raphael Collet
e7ce4a4529
[MERGE] from trunk
...
bzr revid: rco@openerp.com-20121221134259-scc92nby1dn91pe8
2012-12-21 14:42:59 +01:00
Thibault Delavallée
919c0d1152
[REV] Reverted last improvement, because this was messing with the menus.
...
bzr revid: tde@openerp.com-20121221095934-ocbnwz2zvbdbmfug
2012-12-21 10:59:34 +01:00
Thibault Delavallée
e2728306b3
[IMP] OROM: order_spec is overidden by self._order only if None (aka, not specified at all). False or void order_spec allows to avoid having any order_by clause. This is used now in needaction, to speedup the search.
...
bzr revid: tde@openerp.com-20121220205102-lx9ftf3l8qg0xqcu
2012-12-20 21:51:02 +01:00
Thibault Delavallée
36e5b6e88e
[FIX] _search not uniquifies the results, because when using _auto_join we could have duplicates in the 'left part' of the result, i.e. a lead with several unread messages. This is done using a custom method instead of a set, because sets are unordered.
...
bzr revid: tde@openerp.com-20121220141842-or3bigz11qkb13qn
2012-12-20 15:18:42 +01:00
Raphael Collet
95b41b40e9
[IMP] register_hook: improve a bit the code
...
bzr revid: rco@openerp.com-20121219132138-npf12n5l5ug6ujvx
2012-12-19 14:21:38 +01:00
Raphael Collet
fd5dee2267
[MERGE] from trunk
...
bzr revid: rco@openerp.com-20121219130750-3ljqo3dyz05zww08
2012-12-19 14:07:50 +01:00
Olivier Dony
9f77d2e2f4
[FIX] orm,registry: properly check m2o FKs during model update + fix some models `auto_init`ed multiple times
...
The case where no constraint existed at all was not working,
and after fixing it, the ORM started to re-create the same
constraints multiple times for some modules. This was for
models that are split within a module (such as res.users in
base, which is made of several small classes): all the
partial models were going through _auto_init instead
of only the final one - doing useless extra work.
Unfortunately establishing the FK happens before the
XML data files are loaded, so a number of FK and
NOT NULL constraints failed to apply due to missing
tables/records. base.sql had to be extended a bit
to cover these cases in a minimalist fashion
bzr revid: odo@openerp.com-20121217214645-av9n003yzterhujw
2012-12-17 22:46:45 +01:00
Raphael Collet
39fe69babe
[FIX] expression: avoid delitem on a tuple
...
bzr revid: rco@openerp.com-20121217134559-cjc0b4ncs1drupn7
2012-12-17 14:45:59 +01:00
Raphael Collet
3040114651
[MERGE] trunk-style-improvements-xmo (Python stylistic improvement)
...
bzr revid: rco@openerp.com-20121217110150-4ijt04ic17miktq7
2012-12-17 12:01:50 +01:00
Raphael Collet
2679a49af4
[FIX] orm: replace incorrect usage of 'in' by '=='
...
bzr revid: rco@openerp.com-20121217104721-miqmtw2zm7r7lxrs
2012-12-17 11:47:21 +01:00
Raphael Collet
eecc7de437
[MERGE] trunk-acl-thu (check read/write access restrictions on fields with a groups attribute)
...
bzr revid: rco@openerp.com-20121217101528-nt5hsjvvodaap57m
2012-12-17 11:15:28 +01:00
Antony Lesuisse
f6fe592152
[MERGE] trunk
...
bzr revid: al@openerp.com-20121216014404-oonymtva4uww7bwk
2012-12-16 02:44:04 +01:00
Antony Lesuisse
0a35f78974
[MERGE] remove res.partner.address by chs
...
it also removes an ugly hack in the orm.
bzr revid: al@openerp.com-20121215182836-y15v2mwgdg9wyubi
2012-12-15 19:28:36 +01:00
Vo Minh Thu
91ee5eae52
[IMP] orm/acl: proper message instead of `TODO`.
...
bzr revid: vmt@openerp.com-20121214155313-76lncslpx7ugrp6x
2012-12-14 16:53:13 +01:00
Vo Minh Thu
08a082f63f
[FIX] registry: Set the fields_by_model attribute in __init__(), use None to flag non-existing fields-per-model cache.
...
bzr revid: vmt@openerp.com-20121214141114-em9r66e3sfy21t2r
2012-12-14 15:11:14 +01:00
Xavier Morel
d0a377cb1c
[FIX] incorrect docstrings or docstring param names not matching actual param names
...
bzr revid: xmo@openerp.com-20121214130758-a2wp963w4djmb02k
2012-12-14 14:07:58 +01:00
Xavier Morel
b6ece5d65f
[REM] trailing semicolons
...
bzr revid: xmo@openerp.com-20121214124310-wfdkhmcwxnyqu30m
2012-12-14 13:43:10 +01:00
Xavier Morel
c6079dd6bb
[REM] unnecessary parens
...
bzr revid: xmo@openerp.com-20121214123803-6xu2s1ndnoyj4i3e
2012-12-14 13:38:03 +01:00
Xavier Morel
a5cb8460c6
[FIX] __init__ can't return values
...
bzr revid: xmo@openerp.com-20121214122525-bd5207viiz4vqi8x
2012-12-14 13:25:25 +01:00
Xavier Morel
4cb3685f70
[IMP] compare to None by identity
...
bzr revid: xmo@openerp.com-20121214121638-6k5h0ztg94i4f5t6
2012-12-14 13:16:38 +01:00
Vo Minh Thu
3667e3c619
[IMP] module loading: removed unnecessary indentation, added comments.
...
bzr revid: vmt@openerp.com-20121214105820-9nlgzu9pm7cvh1pz
2012-12-14 11:58:20 +01:00
Olivier Dony
e660b70ecb
[IMP] orm: do not warn about missing ondelete cascade rule if ondelete is restrict - that's safe as well
...
bzr revid: odo@openerp.com-20121212210247-emrz5rf9ewcwdggu
2012-12-12 22:02:47 +01:00
Vo Minh Thu
eb0fcc35d2
[FIX] check_field_access_rights: ignore nonexisting fields
...
It seems name_alias is requested but does not exist.
bzr revid: vmt@openerp.com-20121212151509-22494edob4e3fqaf
2012-12-12 16:15:09 +01:00
Vo Minh Thu
1a4fd71880
[FIX] test_fields: _all_columns must be modified similarly to _columns.
...
(Because of the newly added method check_field_access_rights().)
bzr revid: vmt@openerp.com-20121212134755-ykfdykqepwzti5uf
2012-12-12 14:47:55 +01:00
Vo Minh Thu
9d2afcae3f
[IMP] orm: check groups-based access rights on model fields in read() and write().
...
The commented-out tests present in test_acl.py now pass.
Other tests now fail :-(.
bzr revid: vmt@openerp.com-20121212113647-11y3buulifg6tyhj
2012-12-12 12:36:47 +01:00
Christophe Simonis
74b431298e
[FIX] remove res.partner.address model
...
bzr revid: chs@openerp.com-20121211182934-up3sxi0pcw20qrit
2012-12-11 19:29:34 +01:00
Vo Minh Thu
f668a123d9
[IMP] Reduce considerably the loading time of a new registry.
...
Loading time was mesured on the loading of a second database (identical to the
first one), i.e. by passing -d xx,yy on the command line, using cProfile. The
databases were installed with sale, mrp, and the crm.
The cProfile code is commited as part of this patch and should be removed (or
maybe guarded by some command-line flag) (just as the commenting-out of the
cron startup).
The patch was also applied on top of the trunk-simple-table-stats-vmt branch
which provides SQL queries counters.
Results indicate that the number of SQL queries are reduced from about 2100 to
27. Loading time is reduced from 1.3s to 0.26s (i.e. improved by 5).
Changes:
All calls to ir_model_fields to fetch manual (custom) fields are done in a
single call (prior to instanciate all models).
Checks for empty module descriptions are not done unless we are in init or
update mode. (The behavior was the opposite, which was probably a mistake).
Some calls to ir_translation, passing en_US because there was no lang in the
context, are not done anymore.
The improved time is also a result of a change in the decimal_precision module
where precision_get fetches all digits/applications instead of one at a time
(and thus implements its own caching instead of relying on
openerp.tools.ormache).
bzr revid: vmt@openerp.com-20121211105954-lwgs5js7yw3tzghs
2012-12-11 11:59:54 +01:00
Thibault Delavallée
bd0bae6625
[MERGE] Perform auto-join and mailboxes+needaction speed udpate. Server-side branch, holding a refactoring of expression.parse and the addition of _auto_join feature on relational fields.
...
expression.parse: refactored the main parsing loop, now using source and result stacks. Leaf elements are encapsulated into a specific object, allowing to delegate the join condition formation, working table management and table aliases generation to them. The parsing is now a simple loop taking a leaf, doing one action on it, and putting the result back to be analyzed or in the results. This allows to avoid having nested loops and uncontrolled results.
Other modifications :
- updated the generation of order_by to take into account the table now referred using aliases
- updated Query object to use the aliases
- fixed an outstanding bug about _order, now handled as order. This means that putting direct SQL into _order of models will not be supported anymore, because of the computing complexity now that we have multiple joins in queries. The branch holds the patch from Paulius Sladkevičius
- updated and added tests
- added a basic documentation for the freature
lp bug: https://launchpad.net/bugs/1070757 fixed
bzr revid: tde@openerp.com-20121210154652-6sab9usb38i7adlh
2012-12-10 16:46:52 +01:00