[IMP] highlight toggling between validation and import buttons

bzr revid: xmo@openerp.com-20121003121619-e6nbd78mfa5owycp
This commit is contained in:
Xavier Morel
2012-10-03 14:16:19 +02:00
parent f6544c801f
commit e8a7d276bf
2 changed files with 5 additions and 3 deletions
+4 -2
View File
@@ -325,8 +325,10 @@ openerp.base_import = function (instance) {
});
},
render_import_result: function (message) {
if (_.isEmpty(message)) {
this.$('.oe_import_import').addClass('oe_highlight');
var no_messages = _.isEmpty(message);
this.$('.oe_import_import').toggleClass('oe_highlight', no_messages);
this.$('.oe_import_validate').toggleClass('oe_highlight', !no_messages);
if (no_messages) {
message.push({
type: 'info',
message: _t("Everything seems valid.")
+1 -1
View File
@@ -4,7 +4,7 @@
<form action="" method="post" enctype="multipart/form-data" class="oe_import">
<header>
<button type="button" disabled="disabled"
class="oe_button oe_import_button oe_import_validate"
class="oe_button oe_import_button oe_import_validate oe_highlight"
>Validate</button>
<button type="button" disabled="disabled"
class="oe_button oe_import_button oe_import_import"