diff options
| author | Julien Castiaux <juc@odoo.com> | 2019-04-30 09:42:22 +0000 |
|---|---|---|
| committer | Julien Castiaux <juc@odoo.com> | 2019-05-02 07:25:13 +0000 |
| commit | 81877310bc3247a0d9998194e6561e04b8706098 (patch) | |
| tree | 4b3836da291d95ba63ae1bdfe6b68903e1922a54 /addons/web/static/src/js/tools/debug_manager.js | |
| parent | 49fdd155f752fb36db46e972fa87aff39860758f (diff) | |
[FIX] web: ignore field `message_attachment_count` in debug menu
Open a record with a chatter (ie an opw task), add an attachment, enable
debug mode and click on "Set Defaults" in the debug tools, traceback.
The `message_attachment_count` field is a special view added by the
chatter on the form view. This field exists on the view but is absent on
the list of field listed by the XML file. Setting a default value on
that special field is not supported.
opw-1972372
closes odoo/odoo#33044
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Diffstat (limited to 'addons/web/static/src/js/tools/debug_manager.js')
| -rw-r--r-- | addons/web/static/src/js/tools/debug_manager.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/addons/web/static/src/js/tools/debug_manager.js b/addons/web/static/src/js/tools/debug_manager.js index e4134d18afc..af2067bebaf 100644 --- a/addons/web/static/src/js/tools/debug_manager.js +++ b/addons/web/static/src/js/tools/debug_manager.js @@ -433,6 +433,7 @@ DebugManager.include({ var fields = state.fields; var fieldsInfo = state.fieldsInfo.form; var fieldNamesInView = state.getFieldNames(); + var fieldNamesOnlyOnView = ['message_attachment_count']; var fieldsValues = state.data; var modifierDatas = {}; _.each(fieldNamesInView, function (fieldName) { @@ -441,6 +442,7 @@ DebugManager.include({ }); }); this.fields = _.chain(fieldNamesInView) + .difference(fieldNamesOnlyOnView) .map(function (fieldName) { var modifierData = modifierDatas[fieldName]; var invisibleOrReadOnly; |
