[FIX] menu dissapears on click in certain elements. production endpiont.

This commit is contained in:
Jared Kipe
2020-09-29 12:08:40 -07:00
parent 4a05d8397f
commit 8deb11c22b
2 changed files with 9 additions and 22 deletions

View File

@@ -9,12 +9,10 @@ from odoo.exceptions import UserError
class PublisherWarrantyContract(models.AbstractModel): class PublisherWarrantyContract(models.AbstractModel):
_inherit = 'publisher_warranty.contract' _inherit = 'publisher_warranty.contract'
# CONFIG_HIBOU_URL = 'https://hibou.io/hibouapi/v1/professional'
CONFIG_HIBOU_URL = 'https://odoo-hibou-test12.hibou-test-odoo.us-w-p1.hibou.me/hibouapi/v1/professional' CONFIG_HIBOU_URL = 'https://api.hibou.io/hibouapi/v1/professional'
# CONFIG_HIBOU_MESSAGE_URL = 'https://hibou.io/hibouapi/v1/professional/message' CONFIG_HIBOU_MESSAGE_URL = 'https://api.hibou.io/hibouapi/v1/professional/message'
CONFIG_HIBOU_MESSAGE_URL = 'https://odoo-hibou-test12.hibou-test-odoo.us-w-p1.hibou.me/hibouapi/v1/professional/message' CONFIG_HIBOU_QUOTE_URL = 'https://api.hibou.io/hibouapi/v1/professional/quote'
# CONFIG_HIBOU_QUOTE_URL = 'https://hibou.io/hibouapi/v1/professional/quote'
CONFIG_HIBOU_QUOTE_URL = 'https://odoo-hibou-test12.hibou-test-odoo.us-w-p1.hibou.me/hibouapi/v1/professional/quote'
DAYS_ENDING_SOON = 7 DAYS_ENDING_SOON = 7
@api.model @api.model

View File

@@ -203,16 +203,17 @@ var HibouProfessionalSystrayWidget = Widget.extend({
self.update_subject_selection(el); self.update_subject_selection(el);
}); });
// propagation will dismiss the modal/dropdown
this.$el.find('.o_mail_navbar_dropdown').on('click', function(e){
e.stopPropagation();
});
// Update Subscription Button // Update Subscription Button
this.$('.update_subscription').on('click', function(e){ this.$('.update_subscription').on('click', function(e){
e.preventDefault();
e.stopPropagation();
self.button_update_subscription(); self.button_update_subscription();
}); });
this.$('.hibou_get_messages').on('click', function(e){ this.$('.hibou_get_messages').on('click', function(e){
e.preventDefault();
e.stopPropagation();
self.button_get_messages(); self.button_get_messages();
}); });
@@ -221,30 +222,18 @@ var HibouProfessionalSystrayWidget = Widget.extend({
if (self.quote_url) { if (self.quote_url) {
return; // allow default url click event return; // allow default url click event
} }
e.preventDefault();
e.stopPropagation();
self.button_quote(); self.button_quote();
}); });
// Update Message Preferences Button // Update Message Preferences Button
this.$('.update_message_preferences').on('click', function(e){ this.$('.update_message_preferences').on('click', function(e){
e.preventDefault();
e.stopPropagation();
self.button_update_message_preferences(); self.button_update_message_preferences();
}); });
// Send Message Button // Send Message Button
this.$('.hibou_send_message').on('click', function(e){ this.$('.hibou_send_message').on('click', function(e){
e.preventDefault();
e.stopPropagation();
self.button_send_message(); self.button_send_message();
}); });
// Kill the default click event
this.$('.hibou_message_form_container').on('click', function (e) {
//e.preventDefault();
e.stopPropagation();
})
}, },
handleStatusUpdate: function(status) { handleStatusUpdate: function(status) {