diff options
| author | Martin Geubelle <mge@odoo.com> | 2017-04-25 16:05:58 +0200 |
|---|---|---|
| committer | Martin Geubelle <mge@odoo.com> | 2017-04-27 16:56:47 +0200 |
| commit | 67d7cbd06bbffaba6687dda9d4c883529d645e56 (patch) | |
| tree | e46f6410f8f71ea414b3ea0319f586908dba24b2 /addons/web/static/src/js/views/basic | |
| parent | e4ac74450f346f47d397a510d8efe65bd5fa0f1f (diff) | |
[FIX] web: pass `bin_size` in context
When fetching record, `bin_size` needs to be passed in the context
to notify the server to send the `bin_size` and not the whole base64
of binary fields.
Diffstat (limited to 'addons/web/static/src/js/views/basic')
| -rw-r--r-- | addons/web/static/src/js/views/basic/basic_model.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/addons/web/static/src/js/views/basic/basic_model.js b/addons/web/static/src/js/views/basic/basic_model.js index ad9e3fbeed1..3247a2806ef 100644 --- a/addons/web/static/src/js/views/basic/basic_model.js +++ b/addons/web/static/src/js/views/basic/basic_model.js @@ -1253,8 +1253,7 @@ var BasicModel = AbstractModel.extend({ model: record.model, method: 'read', args: [[record.res_id], fieldNames], - context: record.context, - // context: {bin_size: true} // FIXME: when editing a subrecord in the partner form view, it tries to write the bin_size on the image field + context: _.extend({}, record.context, {bin_size: true}), }) .then(function (result) { result = result[0]; |
