N°3649 - Activity panel: Add menu to compose button to select the target log when on a readonly tab (activity, read only case log)

This commit is contained in:
Molkobain
2021-03-23 12:09:26 +01:00
parent 367197357c
commit 1d6ad94694
4 changed files with 115 additions and 14 deletions

View File

@@ -172,8 +172,19 @@ $(function()
this._closePopup();
}
},
/**
* @return {void}
* @param oEvent
* @private
*/
_onBodyClick: function (oEvent) {
if ($(oEvent.target.closest(this.js_selectors.menu)).length === 0 && $(oEvent.target.closest(this.options.toggler)).length === 0) {
if (false === this._isOpened()) {
return;
}
if ($(oEvent.target.closest(this.js_selectors.menu)).length === 0 &&
// Menu without a toggler cannot be closed by an "outside" click, on programatically (same way it was opened in the first place)
((true === this._hasToggler()) && ($(oEvent.target.closest(this.options.toggler)).length === 0))) {
this._closePopup();
}
},