Commit Graph

1223 Commits

Author SHA1 Message Date
Thibault Delavallée 382efffb58 [MERGE] [CLEAN] Part I of cleaning and improvements of the server branch of website-al, after review with our Masters. All Glory to Our Masters.
[CLEAN] res_config, res_users: cleaned call to imd.get_object() + code cleaning
- res_config: raise by default, no need to set the argument at True
- res_users: directly embedded get_user_groups_view code inside update_user_groups_view.
The try / except is still necessary, because when installing a new db, groups and users
are created before the user_groups_view view effectively exist. Due to some circular
references, the try / except is therefore necessary to install a new db.

[CLEAN] ir_qweb: simplified and cleaned QWebcontext implementation
- now using openerp.tools.safe_eval, instead of a custom eval with custom builtins
- removed undefined_handler, hardcoded to a lambda function that returns None for
a missing attribute
- cleaned code, removed now dead BUILTINS, removed commented code
- tools.safe_eval: added a parameter locals_builtins. This allows to copy the globals builtins in the locals. This modification is due to the fact that the locals always returns None, allowing to simplify templates. Otherwise we would have to test the existence of each variable before actually using it. However as the locals always return None for every key, the globals are never checked. Copying the builtins inside the local allows to have a complete locals, but slightly break the globals/locals separation.

[CLEAN] Misc
- setup.py: reverted website-al unnecessary change
- oe: reverted website-al unnecessary change

[DOC] renamed misc_qweb.rst file into ir_qweb.rst

bzr revid: tde@openerp.com-20140116184144-fd5h4a94we13mm72
2014-01-16 19:41:44 +01:00
Thibault Delavallée f4bb798cb8 [CLEAN] ir_qweb: removed commented and now dead BUILTINS
bzr revid: tde@openerp.com-20140116183315-g5ootf670kwx1z1z
2014-01-16 19:33:15 +01:00
Thibault Delavallée c76a3aba8f [CLEAN] ir_qweb: simplified and cleaned QWebcontext implementation
- now using openerp.tools.safe_eval, instead of a custom eval with custom builtins
- removed undefined_handler, hardcoded to a lambda function that returns None for
a missing attribute

tools.safe_eval: added a parameter locals_builtins. This allows to copy the builtins
in the locals. This hack is due to the fact that the locals always returns None, allowing
to simplify templates. Otherwise we would have to test the existence of each variable
before actually using it.
However as the locals always return None for every key, the globals are never checked.
Copying the builtins inside the local allows to have a complete locals, but sligtly
break the globals/locals separation.

To be reviewed and approved.

bzr revid: tde@openerp.com-20140116182750-1rnw8iljt5a9gb4u
2014-01-16 19:27:50 +01:00
Xavier Morel ff51574fae [FIX] somebody renamed classes without fixing the corresponding autodoc invocation
bzr revid: xmo@openerp.com-20140116144957-j2no6ls83vfxtgbk
2014-01-16 15:49:57 +01:00
Fabien Meghazi cee6749395 [IMP] ir_http._handle_exception() raises last exception in order to keep original traceback
bzr revid: fme@openerp.com-20140116135426-x7q8l6ph2m1ln8ry
2014-01-16 14:54:26 +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
Christophe Simonis a69f789b41 [MERGE] forward port of branch 7.0 up to revid 5224 chs@openerp.com-20140206105141-7e8bv8ordqqsswh7
bzr revid: dle@openerp.com-20140205105045-j95kduyjiq83e57z
bzr revid: dle@openerp.com-20140114173613-ruxye1m7fxtcjfim
bzr revid: dle@openerp.com-20140116161158-u95vcs3os4tk2zob
bzr revid: dle@openerp.com-20140121172737-gzawfi3ssg7xifef
bzr revid: chs@openerp.com-20140129094554-c3abc8x3qz9mpszr
bzr revid: chs@openerp.com-20140129140159-9vwkpr078shoonum
bzr revid: chs@openerp.com-20140206110220-myn57cryam1y4k9v
2014-02-06 12:02:20 +01:00
Martin Trigaux 7950914c69 [IMP] ir_fields: no need to sanitize the _str_to_html as it is already done in the _symbol_set of html fields. This avoids doing twice the sanitization.
bzr revid: mat@openerp.com-20140206094628-umx2rfb9rcim7v82
2014-02-06 10:46:28 +01:00
Mohammed Shekha (OpenERP) 15813479f5 [FIX]Fixed the issue of html field import fails, because of no converter found for str to html.
bzr revid: msh@openerp.com-20140203120525-ui117od6lpksm1bq
2014-02-03 17:35:25 +05:30
Fabien Meghazi 130fff6241 [REM] Removed QWeb's useless t-escf and t-rawf
bzr revid: fme@openerp.com-20140115183346-qhifdt2ta9am7tj7
2014-01-15 19:33:46 +01:00
Olivier Dony 1c129e4ca0 [FIX] ir.translation: search view should use the stored `src` colum, the `source` function is meant for edition only
bzr revid: odo@openerp.com-20140115121021-978u00gkshuabvtf
2014-01-15 13:10:21 +01:00
Denis Ledoux 3fdd1e649f [FIX] base: print workflow now displays the transition where the workflow instance is stuck
bzr revid: dle@openerp.com-20140114170529-wg1c3q8492whr19d
2014-01-14 18:05:29 +01:00
Xavier Morel 58ff276887 [FIX] pillow-compatible import
bzr revid: xmo@openerp.com-20140114124843-zpg2qzua90uq1pxu
2014-01-14 13:48:43 +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
Xavier Morel 4a3a7130fb [IMP] replace setattr with direct attribute setting
bzr revid: xmo@openerp.com-20140108102118-virpiwarr0t0ojek
2014-01-08 11:21:18 +01:00
Christophe Simonis ee53f9da60 [FIX] ir.actions.server: remove stupid restriction on model names
bzr revid: chs@openerp.com-20140107172010-3sqo5yqrxz9523hy
2014-01-07 18:20:10 +01:00
Christophe Matthieu 3d618cd6b4 [IMP] ir_qweb: add groups evaluation when a qweb view is rendered
bzr revid: chm@openerp.com-20140107151227-837ecc075be2prp8
2014-01-07 16:12:27 +01:00
Fabien Meghazi 51c53cb396 [IMP] QWeb: set template information on 'iterator not found' exception
bzr revid: fme@openerp.com-20140107105452-qrthkboh5wearljb
2014-01-07 11:54:52 +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
Martin Trigaux 0bd968a801 [MERGE] [FIX] ir_translation: backport of rev 5018 from trunk
rename method load to load_module_terms to avoid name clash with load call from base_import (opw 602531)

bzr revid: mat@openerp.com-20131231140358-ldh0snu9zmcs3tpw
2013-12-31 15:03:58 +01:00
Martin Trigaux 216303c2fa [FIX] ir_translation: rename method load to load_module_terms to avoid name clash with load call from base_import
bzr revid: mat@openerp.com-20131230125307-kald7ir36bvq3o7c
2013-12-30 13:53:07 +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
Xavier Morel b741852c3d [IMP] correctly handle writing to a view without a model_data (e.g. test views)
bzr revid: xmo@openerp.com-20131218134932-382cvndk8asr82ip
2013-12-18 14:49:32 +01:00
Thibault Delavallée 56f18f56c5 [FIX] ir_ui_view: still usign context without being sure it exists
bzr revid: tde@openerp.com-20131218105511-fuf8ca99nimzbcpc
2013-12-18 11:55:11 +01:00
Fabien Meghazi b72b74864a [IMP] QWeb: set template information on template not found exception
bzr revid: fme@openerp.com-20131217135618-0l1emdsz6brviosm
2013-12-17 14:56:18 +01:00
Fabien Meghazi f229af7b57 [IMP] Set ir.model.data noupdate flag to touched views
bzr revid: fme@openerp.com-20131217131439-b0rv83oeqat5rue8
2013-12-17 14:14:39 +01:00
Fabien Meghazi a859a53e72 [FIX] ir.model.data#_update() should honor the noupdate flag
In `init` mode, a record can still be filled with multiple record
nodes with the first node being in a data@noupdate="1" and the other
nodes without @noupdate attribute but this won't be the case anymore in
`update` mode

bzr revid: fme@openerp.com-20131216144304-2e8b9xvoks2fvlj9
2013-12-16 15:43:04 +01:00
Xavier Morel f6a5800d59 [ADD] ability to disable fields escaping
bzr revid: xmo@openerp.com-20131216092330-2v50c8uzzsb3qp8q
2013-12-16 10:23:30 +01:00
Xavier Morel 0546993327 [FIX] merge from trunk and fix handling of view inheritance
main problem, view inheritance model field would use model from the
root view (after following inherit_id links) rather than the base view
(the requested one) -> with divergent models, it was possible for the
requested view itself to never be returned.

bzr revid: xmo@openerp.com-20131212134422-uxg6h21w1jhth9ow
2013-12-12 14:44:22 +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
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
Denis Ledoux fb90e7d572 [FIX]ir_attachement: not self.pool.get(model) instead of model not in self.pool
bzr revid: dle@openerp.com-20131206173602-no831oxc6m1kf6lu
2013-12-06 18:36:02 +01:00
Denis Ledoux 4669f05406 [FIX] ir_attachement: search, if the model of the ir_attachement has been removed, the search ignore the attachement.
bzr revid: dle@openerp.com-20131206162314-vjpgtag8qhkl1jhk
2013-12-06 17:23:14 +01:00
Thibault Delavallée 806c6866bd [FIX] ir_qweb: do not perform dict operation on context without being sur it is not None (next one)
bzr revid: tde@openerp.com-20131206102714-7lrhyk156sywvvea
2013-12-06 11:27:14 +01:00
Thibault Delavallée 0926b1717f [FIX] ir_qweb: do not perform dict operation on context without being sur it is not None
bzr revid: tde@openerp.com-20131206102555-rys582neghxi2x21
2013-12-06 11:25:55 +01:00
Thibault Delavallée fea975aaa4 [IMP] ir_model: get_object: re-introduce old behavior controlled by a new argument. This allows to have a method allowing the new behavior without breaking compatibility with all addons that are based on receiving a ValueError.
bzr revid: tde@openerp.com-20131206095853-6waq2v2ajbgv02vp
2013-12-06 10:58:53 +01:00
Fabien Meghazi 72e67607f1 [REM] Removed exception handling in the wrong place. Will move 403 check on website addon
bzr revid: fme@openerp.com-20131205150504-x33i83gxt10w9hkm
2013-12-05 16:05:04 +01:00
Xavier Morel 745ecc9d25 [FIX] qweb: incorrect propagation of t-field options through rendering methods
bzr revid: xmo@openerp.com-20131205111530-nj26muxxep1yey79
2013-12-05 12:15:30 +01:00
Christophe Simonis 51e05e068b [FIX] ir.http: catch all authentification errors
bzr revid: chs@openerp.com-20131204102430-qxqk8qtze5n5rqe8
2013-12-04 11:24:30 +01:00
Fabien Pinckaers dc35f14d32 [IMP] Removed 1 SQL query for each t-field monetary or float
bzr revid: fp@tinyerp.com-20131203211903-p5uo3shhon8i4umw
2013-12-03 22:19:03 +01:00
Antony Lesuisse 73c943d9b3 [MERGE] trunk
bzr revid: al@openerp.com-20131203192609-dbz5z5dg8x3cuta1
2013-12-03 20:26:09 +01:00
Antony Lesuisse 43979cfd8f [IMP] http improvement
- context manager request object (removes some ugly hacks)
- improve http error handling
- add lazyresponses

bzr revid: al@openerp.com-20131203190639-e8r1qm9wc82t8g4k
2013-12-03 20:06:39 +01:00
Christophe Matthieu 1bf1f0de8f [FIX] forgotten fix for fields_view_get in orm.py (moved to ir_ui_view.py): [MERGE] forward port of branch saas-2 up to revid 4987 chs@openerp.com-20131127105828-ng8z4by1tszmj9d2
bzr revid: chm@openerp.com-20131202191411-edf01rvvpngyezok
2013-12-02 20:14:11 +01:00
Christophe Matthieu 8460122209 [MERGE] sync with trunk
bzr revid: chm@openerp.com-20131202150856-fzrfcoa8pmsjutau
2013-12-02 16:08:56 +01:00
Xavier Morel 103cea2da0 [FIX] change ManyToOne converter to use read on parent record and pass the browse_record's context through
avoids access rights issue, can be used for automagical formatting of address on res.partner

bzr revid: xmo@openerp.com-20131202095638-hoj7sxvax5808irc
2013-12-02 10:56:38 +01:00
Xavier Morel 228938ccba [ADD] formats support to date and datetime converters
bzr revid: xmo@openerp.com-20131202073313-tu79esduu5bvyaai
2013-12-02 08:33:13 +01:00
Xavier Morel c457c2197a [REF] inline server formats in date & datetime converter methods
bzr revid: xmo@openerp.com-20131129103943-1ba1jbm3xxk1p42t
2013-11-29 11:39:43 +01:00
Fabien Pinckaers e477c1f617 [FIX] temporary fix, should be cleaned by removing editable context
bzr revid: fp@tinyerp.com-20131201115142-mok8vlkua5f4tb5l
2013-12-01 12:51:42 +01:00