summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js
diff options
context:
space:
mode:
authorAaron Bohy <aab@odoo.com>2017-08-23 16:10:44 +0200
committerAaron Bohy <aab@odoo.com>2017-08-24 07:20:22 +0200
commit6e4b59cc9cf2ede2ff54579d0cb672210f2b80ab (patch)
treebabb7757b74ddaadb476dfa6a599f0231da34b02 /addons/web/static/src/js
parent42f22a21614ee7967b900736001b8e68b8ad756e (diff)
[FIX] web: Form: display button box in create mode
Before this rev., the button box wasn't displayed on new (not saved yet) records. This wasn't the case before the new views. This is a problem in lunch, as the lunch.order form view is opened in create mode, and the balance is displayed in the button box.
Diffstat (limited to 'addons/web/static/src/js')
-rw-r--r--addons/web/static/src/js/views/form/form_renderer.js4
1 files changed, 0 insertions, 4 deletions
diff --git a/addons/web/static/src/js/views/form/form_renderer.js b/addons/web/static/src/js/views/form/form_renderer.js
index 2ef0f077e09..999006e54c2 100644
--- a/addons/web/static/src/js/views/form/form_renderer.js
+++ b/addons/web/static/src/js/views/form/form_renderer.js
@@ -246,10 +246,6 @@ var FormRenderer = BasicRenderer.extend({
_renderButtonBox: function (node) {
var self = this;
var $result = $('<' + node.tag + '>', { 'class': 'o_not_full' });
- // Avoid to show buttons if we are in create mode (edit mode without res_id)
- if (this.mode === 'edit' && !this.state.res_id) {
- return $result;
- }
var buttons = _.map(node.children, function (child) {
if (child.tag === 'button') {
return self._renderStatButton(child);