[REF] web_editor, web: remove unused getRecordInfo event and methods
In the 12.3 editor revert, the handler for the getRecordInfo event was removed, but the code that triggered this event was forgotten and now doesn't do anything. This commit removes this dead code. closes odoo/odoo#49126 Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
This commit is contained in:
committed by
qsm-odoo
parent
f66640e3d3
commit
6efe469941
@@ -30,12 +30,6 @@ var ColorpickerWidget = Widget.extend({
|
||||
init: function (parent, options) {
|
||||
this._super(...arguments);
|
||||
options = options || {};
|
||||
this.trigger_up('getRecordInfo', {
|
||||
recordInfo: options,
|
||||
callback: function (recordInfo) {
|
||||
_.defaults(options, recordInfo);
|
||||
},
|
||||
});
|
||||
|
||||
this.pickerFlag = false;
|
||||
this.sliderFlag = false;
|
||||
|
||||
@@ -1019,12 +1019,6 @@ var SnippetsMenu = Widget.extend({
|
||||
init: function (parent, options) {
|
||||
this._super.apply(this, arguments);
|
||||
options = options || {};
|
||||
this.trigger_up('getRecordInfo', {
|
||||
recordInfo: options,
|
||||
callback: function (recordInfo) {
|
||||
_.defaults(options, recordInfo);
|
||||
},
|
||||
});
|
||||
|
||||
this.options = options;
|
||||
if (!this.options.snippets) {
|
||||
|
||||
@@ -4547,11 +4547,6 @@ registry.many2one = SnippetOptionWidget.extend({
|
||||
*/
|
||||
start: function () {
|
||||
var self = this;
|
||||
this.trigger_up('getRecordInfo', _.extend(this.options, {
|
||||
callback: function (recordInfo) {
|
||||
_.defaults(self.options, recordInfo);
|
||||
},
|
||||
}));
|
||||
|
||||
this.Model = this.$target.data('oe-many2one-model');
|
||||
this.ID = +this.$target.data('oe-many2one-id');
|
||||
|
||||
@@ -24,13 +24,6 @@ var AltDialog = Dialog.extend({
|
||||
title: _t("Change media description and tooltip")
|
||||
}, options));
|
||||
|
||||
this.trigger_up('getRecordInfo', {
|
||||
recordInfo: options,
|
||||
callback: function (recordInfo) {
|
||||
_.defaults(options, recordInfo);
|
||||
},
|
||||
});
|
||||
|
||||
this.media = media;
|
||||
var allEscQuots = /"/g;
|
||||
this.alt = ($(this.media).attr('alt') || "").replace(allEscQuots, '"');
|
||||
|
||||
@@ -43,13 +43,6 @@ var LinkDialog = Dialog.extend({
|
||||
// all btn-* classes anyway.
|
||||
];
|
||||
|
||||
this.trigger_up('getRecordInfo', {
|
||||
recordInfo: this.options,
|
||||
callback: function (recordInfo) {
|
||||
_.defaults(self.options, recordInfo);
|
||||
},
|
||||
});
|
||||
|
||||
// data is used in the dialog template.
|
||||
this.props = options.props || {};
|
||||
|
||||
|
||||
@@ -52,14 +52,6 @@ var MediaDialog = Dialog.extend({
|
||||
save_text: _t("Add"),
|
||||
}, options));
|
||||
|
||||
this.trigger_up('getRecordInfo', {
|
||||
recordInfo: options,
|
||||
type: 'media',
|
||||
callback: function (recordInfo) {
|
||||
_.defaults(options, recordInfo);
|
||||
},
|
||||
});
|
||||
|
||||
if (!options.noImages) {
|
||||
this.imageWidget = new MediaModules.ImageWidget(this, media, options);
|
||||
}
|
||||
|
||||
@@ -30,10 +30,8 @@ var Wysiwyg = Widget.extend({
|
||||
* @options {integer} [options.recordInfo.res_id]
|
||||
* @options {String} [options.recordInfo.data_res_model]
|
||||
* @options {integer} [options.recordInfo.data_res_id]
|
||||
* @see _onGetRecordInfo
|
||||
* @see _getAttachmentsDomain in /wysiwyg/widgets/media.js
|
||||
* @options {Object} options.attachments
|
||||
* @see _onGetRecordInfo
|
||||
* @see _getAttachmentsDomain in /wysiwyg/widgets/media.js (for attachmentIDs)
|
||||
* @options {function} options.generateOptions
|
||||
* called with the summernote configuration object used before sending to summernote
|
||||
|
||||
Reference in New Issue
Block a user