forked from Techsystech/web
[11.0][MIG] web_send_message_popup: Migrate to 11.0
parent
503a6f667e
commit
4f16a1c7b0
|
@ -1,62 +0,0 @@
|
||||||
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
|
|
||||||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
|
||||||
:alt: License: AGPL-3
|
|
||||||
|
|
||||||
=========================
|
|
||||||
Web Send Message as Popup
|
|
||||||
=========================
|
|
||||||
|
|
||||||
In the email/notes threads below the form views, the link 'Send a
|
|
||||||
message' unfold a text field. From there, a button allows to open the
|
|
||||||
text field in a full featured email popup with the subject, templates,
|
|
||||||
attachments and followers.
|
|
||||||
|
|
||||||
This module changes the link 'Send a message' so it opens directly the
|
|
||||||
full featured popup instead of the text field, avoiding an extra click
|
|
||||||
if the popup is always wanted.
|
|
||||||
|
|
||||||
|
|
||||||
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
|
|
||||||
:alt: Try me on Runbot
|
|
||||||
:target: https://runbot.odoo-community.org/runbot/162/10.0
|
|
||||||
|
|
||||||
|
|
||||||
Bug Tracker
|
|
||||||
===========
|
|
||||||
|
|
||||||
This module was tested on Odoo 10.0 community and enterprise.
|
|
||||||
|
|
||||||
Bugs are tracked on `GitHub Issues
|
|
||||||
<https://github.com/OCA/web/issues>`_. In case of trouble, please
|
|
||||||
check there if your issue has already been reported. If you spotted it first,
|
|
||||||
help us smashing it by providing a detailed and welcomed feedback.
|
|
||||||
|
|
||||||
Credits
|
|
||||||
=======
|
|
||||||
|
|
||||||
Images
|
|
||||||
------
|
|
||||||
|
|
||||||
* Odoo Community Association: `Icon <https://github.com/OCA/maintainer-tools/blob/master/template/module/static/description/icon.svg>`_.
|
|
||||||
|
|
||||||
Contributors
|
|
||||||
------------
|
|
||||||
|
|
||||||
* Guewen Baconnier <guewen.baconnier@camptocamp.com>
|
|
||||||
* Yannick Vaucher <yannick.vaucher@camptocamp.com>
|
|
||||||
* Nicolas JEUDY <https://github.com/njeudy>
|
|
||||||
|
|
||||||
Maintainer
|
|
||||||
----------
|
|
||||||
|
|
||||||
.. image:: https://odoo-community.org/logo.png
|
|
||||||
:alt: Odoo Community Association
|
|
||||||
:target: https://odoo-community.org
|
|
||||||
|
|
||||||
This module is maintained by the OCA.
|
|
||||||
|
|
||||||
OCA, or the Odoo Community Association, is a nonprofit organization whose
|
|
||||||
mission is to support the collaborative development of Odoo features and
|
|
||||||
promote its widespread use.
|
|
||||||
|
|
||||||
To contribute to this module, please visit https://odoo-community.org.
|
|
|
@ -1 +0,0 @@
|
||||||
# -*- coding: utf-8 -*-
|
|
|
@ -1,17 +1,18 @@
|
||||||
# -*- coding: utf-8 -*-
|
# Copyright 2014-2018 Camptocamp SA
|
||||||
# © 2014-2016 Camptocamp SA
|
# License AGPL-3.0 or later (http://gnu.org/licenses/agpl).
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
{
|
||||||
{'name': 'Web Send Message as Popup',
|
'name': 'Web Send Message as Popup',
|
||||||
'version': '10.0.1.0.0',
|
'version': '11.0.1.0.0',
|
||||||
'author': "Camptocamp, Odoo Community Association (OCA)",
|
'author': "Camptocamp, Odoo Community Association (OCA)",
|
||||||
'maintainer': 'Camptocamp',
|
'maintainer': 'Camptocamp',
|
||||||
'license': 'AGPL-3',
|
'license': 'AGPL-3',
|
||||||
'category': 'Hidden',
|
'category': 'Hidden',
|
||||||
'depends': ['web',
|
'depends': [
|
||||||
|
'web',
|
||||||
|
'mail',
|
||||||
],
|
],
|
||||||
'website': 'http://www.camptocamp.com',
|
'website': 'https://github.com/OCA/web',
|
||||||
'data': ['views/web_send_message_popup.xml'
|
'data': [
|
||||||
|
'templates/assets.xml',
|
||||||
],
|
],
|
||||||
'installable': True,
|
|
||||||
'auto_install': False,
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,14 +0,0 @@
|
||||||
# Translation of Odoo Server.
|
|
||||||
# This file contains the translation of the following modules:
|
|
||||||
#
|
|
||||||
msgid ""
|
|
||||||
msgstr ""
|
|
||||||
"Project-Id-Version: Odoo Server 10.0\n"
|
|
||||||
"Report-Msgid-Bugs-To: \n"
|
|
||||||
"Last-Translator: <>\n"
|
|
||||||
"Language-Team: \n"
|
|
||||||
"MIME-Version: 1.0\n"
|
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
|
||||||
"Content-Transfer-Encoding: \n"
|
|
||||||
"Plural-Forms: \n"
|
|
||||||
|
|
|
@ -0,0 +1,4 @@
|
||||||
|
* Guewen Baconnier <guewen.baconnier@camptocamp.com>
|
||||||
|
* Yannick Vaucher <yannick.vaucher@camptocamp.com>
|
||||||
|
* Nicolas JEUDY <https://github.com/njeudy>
|
||||||
|
* Artem Kostyuk <a.kostyuk@mobilunity.com>
|
|
@ -0,0 +1,8 @@
|
||||||
|
In the email/notes threads below the form views, the link 'Send a
|
||||||
|
message' unfold a text field. From there, a button allows to open the
|
||||||
|
text field in a full featured email popup with the subject, templates,
|
||||||
|
attachments and followers.
|
||||||
|
|
||||||
|
This module changes the link 'Send a message' so it opens directly the
|
||||||
|
full featured popup instead of the text field, avoiding an extra click
|
||||||
|
if the popup is always wanted.
|
|
@ -0,0 +1,3 @@
|
||||||
|
* works even if bit flickering as it renders 1st the std widget and then shows the
|
||||||
|
other one. @simahawk checked the code and unfortunately seems there's no good
|
||||||
|
way to hook if not overriding whole big functions.
|
|
@ -1,18 +1,16 @@
|
||||||
/* © 2016 Camptocamp SA
|
/* Copyright 2018 Camptocamp SA
|
||||||
* License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). */
|
* License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). */
|
||||||
odoo.define('web_send_message_popup.Chatter', function (require) {
|
odoo.define('web_send_message_popup.Chatter', function (require) {
|
||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
var core = require('web.core');
|
var Chatter = require('mail.Chatter');
|
||||||
var composer = require('mail.composer');
|
|
||||||
var Chatter = core.form_widget_registry.get('mail_thread');
|
|
||||||
|
|
||||||
Chatter.include({
|
Chatter.include({
|
||||||
on_open_composer_new_message: function () {
|
_onOpenComposerMessage: function () {
|
||||||
var self = this;
|
|
||||||
this.open_composer();
|
|
||||||
// wait for composer input to be initialized
|
// wait for composer input to be initialized
|
||||||
// taken from http://stackoverflow.com/questions/7307983/while-variable-is-not-defined-wait
|
// taken from http://stackoverflow.com/questions/7307983/while-variable-is-not-defined-wait
|
||||||
|
var self = this;
|
||||||
|
$.when(this._super.apply(this, arguments)).then(function () {
|
||||||
function checkVariable() {
|
function checkVariable() {
|
||||||
if (typeof self.composer !== 'undefined' && typeof self.composer.$input !== 'undefined') {
|
if (typeof self.composer !== 'undefined' && typeof self.composer.$input !== 'undefined') {
|
||||||
self.composer.on_open_full_composer();
|
self.composer.on_open_full_composer();
|
||||||
|
@ -24,6 +22,7 @@ Chatter.include({
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
checkVariable();
|
checkVariable();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<odoo>
|
<odoo>
|
||||||
<template id="assets_backend" name="web_send_message_popup assets" inherit_id="web.assets_backend">
|
<template id="assets_backend" name="web_send_message_popup assets" inherit_id="web.assets_backend">
|
||||||
<xpath expr="." position="inside">
|
<xpath expr="." position="inside">
|
||||||
<script type="text/javascript" src="/web_send_message_popup/static/src/js/chatter.js"></script>
|
<script type="text/javascript" src="/web_send_message_popup/static/src/js/chatter.js"/>
|
||||||
</xpath>
|
</xpath>
|
||||||
</template>
|
</template>
|
||||||
</odoo>
|
</odoo>
|
Loading…
Reference in New Issue