mirror of
https://github.com/OCA/knowledge.git
synced 2025-07-22 20:12:04 -06:00
Merge pull request #113 from initOS/8.0-FIX_attachment_preview_prevent_multiple_click_binds
unbind for click to prevent multiple click binds
This commit is contained in:
commit
73d85c855c
@ -126,6 +126,7 @@ openerp.attachment_preview = function(instance)
|
||||
{
|
||||
return;
|
||||
}
|
||||
$elements.unbind("click")
|
||||
$elements.click(function(e)
|
||||
{
|
||||
e.stopPropagation();
|
||||
@ -212,6 +213,7 @@ openerp.attachment_preview = function(instance)
|
||||
var $element = self.$el.find('.oe-binary-preview');
|
||||
if(openerp.attachment_preview.can_preview(extension))
|
||||
{
|
||||
$element.unbind("click")
|
||||
$element.click(function()
|
||||
{
|
||||
openerp.attachment_preview.show_preview(
|
||||
|
Loading…
Reference in New Issue
Block a user