Commit Graph
22 Commits
Author SHA1 Message Date
Martin Trigaux ef8ad324b0 [I18N] *: export 15.0 source terms
closes odoo/odoo#76542

X-original-commit: 63e6807437295519a0f4705fb88644d6d557ca3a
Related: odoo/enterprise#20882
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-09-16 07:17:40 +00:00
std-odoo 8739c81867 [FIX] mail_plugin: fix missing translations
Purpose
=======
Fix missing translations on the Outlook / Gmail plugin and add them in
the mail plugin module.

Task-2612788

closes odoo/odoo#75599

X-original-commit: 47c9be8970011863e8e7b474665c823e751df085
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-08-30 10:58:57 +00:00
std-odoo 61d9cb8098 [IMP] mail_plugin: add translations for 404 error management
Purpose
=======

Currently the application will display a 404 error message, if the mail
plugin module is not installed or if the user made an error in the URL
of his Odoo database, which is confusing for end users.

So, we show an error message during the authentication process if the
database is not reachable and we should add the translations related to
those changes.

Task-2577531
See odoo/mail-client-extensions/pull/17

closes odoo/odoo#75637

X-original-commit: 3c00fddb99091b96259eed1e45ef9de53c53f795
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-08-26 12:46:55 +00:00
std-odoo 9d13bb4534 [FIX] mail_plugin: fix missing translations
Purpose
=======
Fix missing translations on the Outlook plugin and add them in the
mail plugin module.

Task-2612788

closes odoo/odoo#74399

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-07-29 12:27:45 +00:00
Stephane Debauche 347111c7b8 [FIX] mail_plugin: improve error management when enriching companies
Purpose
=======

If the partner was removed after the user open the email on the Gmail
side, return a clean error message instead of raising a traceback.

Add translations for the new strings in the plugin.

Links
=====

Task-2567566
Followup of odoo/odoo#73653
See odoo/mail-client-extensions#15

closes odoo/odoo#75076

X-original-commit: e782c85b95aed30dd38bd30c29e57a9acc540a49
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-08-13 13:38:42 +00:00
std-odoo 540f7b8cab [IMP] mail_plugin: shorten the error messages
Purpose
=======
Shorten the error message to make them appear on a single line.

Task-2518668
See odoo/mail-client-extensions/pull/12

closes odoo/odoo#71542

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-07-27 06:57:28 +00:00
Xavier-Do 288595f558 [FIX] *: add explicit license to all manifest
The license is missing in most enterprise manifest so
the decision was taken to make it explicit in all cases.
When not defined, a warning will be triggered starting from
14.0 when falling back on the default LGPL-3.

closes odoo/odoo#74245

Related: odoo/design-themes#48
Related: odoo/enterprise#19862
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2021-07-26 13:09:57 +00:00
std-odoo 43052586cb [FIX] mail_plugin: fix a translation when the enrichment fail
Bug
===
One error message is not translated.

Task-2518668

closes odoo/odoo#73856

X-original-commit: cfeff76797f2f6bd390e41974f2f8255df81a738
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-07-16 11:30:03 +00:00
std-odoo 7d476512b8 [FIX] mail_plugin: fix an error during the authentication
Bug
===
Since 478068c829 we wanted to use the
Odoo redirection function everywhere.

But this function work only if we redirect the user to the same site.

The mail plugin need to redirect outside of Odoo and so we can not use
this function.

closes odoo/odoo#73698

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-07-14 11:54:40 +00:00
nounoubensebia ba048b0317 [IMP] mail_plugin: add enrich strings to translate
Enrich capability has been improved in 14.3 . This commit adds strings to
translate for plugins in 14.4 + .

Task-2563180
Odoo PR: odoo/odoo#71947
Outlook code: odoo/mail-client-extensions@d122177927

closes odoo/odoo#73687

X-original-commit: a9cc87a57b80b4f962b11de8e3e0b41248384273
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-07-14 10:35:30 +00:00
nounoubensebia 017ecb37f2 [IMP] mail_plugin: enable enrichment and update of an existing company
Add an enrich and update endpoint allowing the user to update an existing
company if the company has no insights, as this can bring valuable information
for the user especially if the company has no infos.

Task-2563180

closes odoo/odoo#73658

X-original-commit: 72c35667d3e6f99cb4cfdbd1c93b877cc9fef750
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-07-13 16:42:10 +00:00
Martin Trigaux 6758868731 [I18N] *: export saas-14.4 source terms
Without demo data

closes odoo/odoo#73560

X-original-commit: 802e46541117573e028b711ea33dad9df9075a39
Related: odoo/enterprise#19602
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-07-12 10:57:37 +00:00
Jeremy Kersten 478068c829 [IMP] *: always use Odoo Response
This branch adds request.redirect on all requests.
In case of a front end request, we do an url_for to the location.

We removed redirect_with_hash that was only for retro compatibility

local_redirect has been renamed to redirect_query, and param keep_hash has been
removed and moved.

Default code for redirect is 303 now instead of 302.

Now redirect and redirect_query make local redirect by default, you need to
pass local=False to make external redirect.

All werkeug.utils.redirect has been replaced by request.redirect.

Http.redirect now use an http.Response type, and it become easy to add an
override like 'set_cookies' e.g.

Dispatch of a website.page return an http.response too, so we first need to
check if it is a cached version before to check if it is an Odoo Response.

Migrate your code:

http.redirect -> request.redirect(location, code, local)
http.local_redirect -> request.redirect_query(location, query, code, local)
http.redirect_with_hash -> request.redirect

Courtesy of odony for help and review ;)

closes odoo/odoo#72599

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-07-08 07:00:06 +00:00
std-odoo 00f2840f0c [IMP] mail_plugin: add the translation for the attachment related message
Purpose
=======
In 14.3 we added the possibility to upload attachments when logging
an email. In the commit, we add the translation for the corresponding
error message.

Task 2545048
See odoo/odoo/pull/71543
See odoo/mail-client-extensions/pull/11

closes odoo/odoo#72530

X-original-commit: ba747ed81631cca549a380446cd8f05e711bdf76
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-06-22 12:00:24 +00:00
nounoubensebia aa02285b0a [FIX] [crm_]mail_plugin: fix multi_company access error
This commit fixes the multi_company access error when the user is attempting to
see a record belonging to another company then the one he is logged in to from
the plugins, upon login, it returns all the company ids related to the user so
that the plugin redirects the user to the record with all companies ticked.

Task-2541205

closes odoo/odoo#72529

Plugin-pr: https://github.com/odoo/mail-client-extensions/pull/10
X-original-commit: 92972fa16920e070e533040439243a0257357aad
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-06-22 11:52:30 +00:00
std-odoo a755ed2475 [IMP] mail_plugin: allow to upload attachments when logging an email
Purpose
=======
Allow to upload the attachments of the email when logging it on the
partner / lead / ticket.

Technical
=========
The attachments posted on this new endpoint are base 64 encoded and
added in the JSON data in a list (name, encoded content).

Links
=====
Task 2545048
See odoo/mail-client-extensions/pull/11

closes odoo/odoo#72515

X-original-commit: 71626ad727fd573fd98e595e0ae964ce0559e547
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-06-22 09:30:28 +00:00
std-odoo d27fb9c952 [IMP] (crm_)mail_plugin: support translations for the Gmail addon
Purpose
=======
This commit allow the users to translate their Gmail Addon.

The language of the addon will be the language the user set on his
preference, on his Odoo database.

The translations will be downloaded from Odoo and stored in the cache,
so translator can use the existing system to translate the addon.

Task 2502261
See odoo/mail-client-extensions/pull/8
See odoo/odoo/pull/69288
See odoo/enterprise/pull/17711

closes odoo/odoo#69288

Related: odoo/enterprise#17711
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-05-31 07:26:31 +00:00
nounoubensebia 24d5c789f1 [IMP] mail_plugin, crm_mail_plugin: add translation support for email plugins
In mail_plugin module, add a method which returns translatable modules,
this method will be overridden in the other modules to add their module names.

Translations are prepared via the _prepare_translations method which uses
the get_translations_for_webclient method, this way we can easily fetch
translations without having to write python code.

We also add xml files in "static/", these files contain terms to be translated,
for each plugin we create a separate xml file so that we can easily update each
plugin separately.

This implementation will allow having translations handled by Odoo, which has
several advantages:
- existing system, nothing to develop
- it will use transifex and the terms will be translated by the community
- forces that mail_client implementations to have the same logic (consistency)
- compared to other solutions which rely on python code to return translations,
  this solution is more robust as it avoids having to type the string to
  translate twice

Task-2480075

closes odoo/odoo#69118

Ent-pr: https://github.com/odoo/enterprise/pull/17626
Plugin-pr: https://github.com/odoo/mail-client-extensions/pull/6
Related: odoo/enterprise#17626
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-05-26 12:51:57 +00:00
Martin Trigaux 41d8b8cf68 [I18N] *: export saas-14.3 source terms
closes odoo/odoo#70673

X-original-commit: bcb9ff784e44462384b0a43a0a23eed7a1111bc5
Related: odoo/enterprise#18269
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2021-05-11 12:28:28 +00:00
std-odoo d3db46f06f [IMP] mail_plugin: return the "is_company" field
Purpose
=======
Return the "is_company" field for the <res.partner>, so when the partner
has no image, we can display the appropriate placeholder image
(person for non-company and buildings image for company).

Task 2496443

closes odoo/odoo#69562

X-original-commit: 37766d3ef32816f332cd285cce8dbb1fa5e4b66a
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-04-20 15:51:29 +00:00
std-odoo ab179fb600 [FIX] mail_plugin: avoid repeating company creation
Purpose
=======
Avoid creating / enriching multiple time the same company.

It can occur in many situation; when IAP do not return an email address
the the company, when the domain is blacklisted...

We also want to remove the field "iap_enrich_info" from the res.partner
model because this field can be heavy (JSON field) and the res.partner
model is used a lot.

Technical
=========
For this purpose, we create a new model <res.partner.iap> which will
store the IAP response and the requested domain.

So we can retrieve the previously enriched company regardless of the
partner's values

Task 2466653
See odoo/odoo/pull/68286
See odoo/upgrade/pull/2301

closes odoo/odoo#68286

Related: odoo/upgrade#2301
Related: odoo/enterprise#17426
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-04-01 14:23:07 +00:00
nounoubensebia 3d514037bb [REF] [crm_]mail_client_extension: rename to mail_plugin
Rename the mail_client_extension and crm_mail_client_extension modules to
mail_plugin and crm_mail_plugin respectively, purpose is to shorten the name of
the modules as it is now quite big and verbose.

Task-2427737

UPG-PR: https://github.com/odoo/upgrade/pull/2156
COM-PR: https://github.com/odoo/odoo/pull/66139
2021-03-29 14:21:05 +00:00