Skip to content

Commit

Permalink
TA#56200 [ADD] admin_light_mail_outlook, admin_light_mail_gmail (#821)
Browse files Browse the repository at this point in the history
  • Loading branch information
lanto-razafindrabe authored Sep 11, 2023
1 parent ff14601 commit 5329fef
Show file tree
Hide file tree
Showing 14 changed files with 141 additions and 0 deletions.
11 changes: 11 additions & 0 deletions addons/admin_light_mail_gmail/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
Admin Light Mail Gmail
======================
This module extends Administration Light/Mail Servers rights to handle fetchmail_gmail functionalities.
It manages access to the new Gmail fields and add them to the existing `Administration (Light) / Mail Servers` right group.

As a user with `Administration (Light) / Mail Servers` rights.
I go to an incoming or outgoing email servers submenu of `Administration > Email`. I see that I have sufficient rights to access it.

Contributors
------------
* Numigi (tm) and all its contributors (https://bit.ly/numigiens)
4 changes: 4 additions & 0 deletions addons/admin_light_mail_gmail/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import models
17 changes: 17 additions & 0 deletions addons/admin_light_mail_gmail/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

{
"name": "Admin Light Mail Gmail",
"version": "1.0.0",
"author": "Numigi",
"maintainer": "Numigi",
"website": "https://bit.ly/numigi-com",
"license": "AGPL-3",
'category': 'Other',
"depends": ["admin_light_mail", "fetchmail_gmail"],
"summary": """Extends Administration Light/Mail Servers rights to handle
fetchmail_gmail functionalities.""",
"data": [],
"installable": True,
}
18 changes: 18 additions & 0 deletions addons/admin_light_mail_gmail/i18n/fr.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * admin_light_mail_gmail
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 11.0+e\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-08-12 17:50+0000\n"
"PO-Revision-Date: 2019-08-12 13:51-0400\n"
"Last-Translator: <>\n"
"Language-Team: \n"
"Language: fr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: \n"
"X-Generator: Poedit 2.0.6\n"
4 changes: 4 additions & 0 deletions addons/admin_light_mail_gmail/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import google_gmail_mixin
17 changes: 17 additions & 0 deletions addons/admin_light_mail_gmail/models/google_gmail_mixin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from odoo import fields, models

AUTHORIZED_GROUPS = "base.group_system,admin_light_mail.group_email_server"


class GoogleGmailMixin(models.AbstractModel):
_inherit = 'google.gmail.mixin'

google_gmail_authorization_code = fields.Char(groups=AUTHORIZED_GROUPS)
google_gmail_refresh_token = fields.Char(groups=AUTHORIZED_GROUPS)
google_gmail_access_token = fields.Char(groups=AUTHORIZED_GROUPS)
google_gmail_access_token_expiration = fields.Integer(
groups=AUTHORIZED_GROUPS)
google_gmail_uri = fields.Char(groups=AUTHORIZED_GROUPS)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions addons/admin_light_mail_outlook/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
Admin Light Mail Outlook
========================
This module extends Administration Light/Mail Servers rights to handle fetchmail_gmail functionalities.
It manages access to the new Outlook fields and add them to the existing `Administration (Light) / Mail Servers`` right group.

As a user with `Administration (Light) / Mail Servers` rights.
I go to an incoming or outgoing email servers submenu of `Administration > Email`. I see that I have sufficient rights to access it.

Contributors
------------
* Numigi (tm) and all its contributors (https://bit.ly/numigiens)
4 changes: 4 additions & 0 deletions addons/admin_light_mail_outlook/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import models
17 changes: 17 additions & 0 deletions addons/admin_light_mail_outlook/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

{
"name": "Admin Light Mail Outlook",
"version": "1.0.0",
"author": "Numigi",
"maintainer": "Numigi",
"website": "https://bit.ly/numigi-com",
"license": "AGPL-3",
'category': 'Other',
"depends": ["admin_light_mail", "fetchmail_outlook"],
"summary": """Extends Administration Light/Mail Servers rights to handle
fetchmail_outlook functionalities.""",
"data": [],
"installable": True,
}
18 changes: 18 additions & 0 deletions addons/admin_light_mail_outlook/i18n/fr.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * admin_light_mail_outlook
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 11.0+e\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-08-12 17:50+0000\n"
"PO-Revision-Date: 2019-08-12 13:51-0400\n"
"Last-Translator: <>\n"
"Language-Team: \n"
"Language: fr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: \n"
"X-Generator: Poedit 2.0.6\n"
4 changes: 4 additions & 0 deletions addons/admin_light_mail_outlook/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import microsoft_outlook_mixin
16 changes: 16 additions & 0 deletions addons/admin_light_mail_outlook/models/microsoft_outlook_mixin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# © 2023 Numigi (tm) and all its contributors (https://bit.ly/numigiens)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from odoo import fields, models

AUTHORIZED_GROUPS = "base.group_system,admin_light_mail.group_email_server"


class MicrosoftOutlookMixin(models.AbstractModel):
_inherit = 'microsoft.outlook.mixin'

microsoft_outlook_refresh_token = fields.Char(groups=AUTHORIZED_GROUPS)
microsoft_outlook_access_token = fields.Char(groups=AUTHORIZED_GROUPS)
microsoft_outlook_access_token_expiration = fields.Integer(
groups=AUTHORIZED_GROUPS)
microsoft_outlook_uri = fields.Char(groups=AUTHORIZED_GROUPS)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 5329fef

Please sign in to comment.