diff --git a/sync_task_with_google_calender/README.rst b/sync_task_with_google_calender/README.rst new file mode 100644 index 000000000..4f8de3ff2 --- /dev/null +++ b/sync_task_with_google_calender/README.rst @@ -0,0 +1,51 @@ +.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg + :target: https://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 + +Google Calendar Integration for Project and Task +========================================= +* Sync Project Task with Google Calendar. +* Auto Update Task with Google Calendar. +* Option to Sync Selected Task with Google Calendar. +* Email Notification. + +Configuration +============= +* No additional configurations needed + +Company +------- +* `Cybrosys Techno Solutions `__ + +License +------- +General Public License, Version 3 (AGPL v3). +(https://www.gnu.org/licenses/agpl-3.0-standalone.html) + +Credits +------- +* Developers: (V17) Ayana KP, + (V16)Jumana Jabin MP, +Contact: odoo@cybrosys.com + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com +* Website : https://cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +.. image:: https://cybrosys.com/images/logo.png + :target: https://cybrosys.com + +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit `Our Website `__ + +Further information +=================== +HTML Description: ``__ diff --git a/sync_task_with_google_calender/__init__.py b/sync_task_with_google_calender/__init__.py new file mode 100644 index 000000000..501b693bc --- /dev/null +++ b/sync_task_with_google_calender/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Ayana KP (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import models diff --git a/sync_task_with_google_calender/__manifest__.py b/sync_task_with_google_calender/__manifest__.py new file mode 100644 index 000000000..eead44450 --- /dev/null +++ b/sync_task_with_google_calender/__manifest__.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Ayana KP (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +{ + 'name': 'Google Calendar Integration For Project And Task', + 'version': '17.0.1.0.0', + 'category': 'Project', + 'summary': 'Module For Integrating Odoo Project With Google Calender.', + "description": """Google Calendar Integration for Project Tasks odoo app + helps users to sync project tasks with google Calendar. Users can get all + task information like name, description, create date time, deadline, and + attende, If a user updates a task then google calendar events also get + updated.""", + 'author': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'website': "https://www.cybrosys.com", + 'depends': ['project', 'google_calendar'], + 'data': [ + 'views/res_users_views.xml', + 'views/project_task_views.xml', + ], + 'images': [ + 'static/description/banner.jpg' + ], + 'license': 'AGPL-3', + 'installable': True, + 'auto_install': False, + 'application': False +} diff --git a/sync_task_with_google_calender/doc/RELEASE_NOTES.md b/sync_task_with_google_calender/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..8096711ba --- /dev/null +++ b/sync_task_with_google_calender/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 17.08.2023 +#### Version 17.0.1.0.0 +#### ADD +- Initial commit for Google Calendar Integration For Project And Task diff --git a/sync_task_with_google_calender/models/__init__.py b/sync_task_with_google_calender/models/__init__.py new file mode 100644 index 000000000..0046803ea --- /dev/null +++ b/sync_task_with_google_calender/models/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies() +# Author: Ayana KP (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import project_task +from . import res_users diff --git a/sync_task_with_google_calender/models/project_task.py b/sync_task_with_google_calender/models/project_task.py new file mode 100644 index 000000000..7d7e61e02 --- /dev/null +++ b/sync_task_with_google_calender/models/project_task.py @@ -0,0 +1,190 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Ayana KP (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +import requests +from odoo import api, fields, models, _ +from odoo.exceptions import UserError + + +class ProjectTask(models.Model): + """ Extend 'project.task' model to add Google Calendar integration.""" + _inherit = 'project.task' + + is_add_in_gcalendar = fields.Boolean(string="Add In G-Calendar Event", + help="Set this field True if you want to" + " add this task to Google Calendar.") + task_event = fields.Char(string="Task Google Calendar Event ID", + help="This field stores the unique ID of Google" + " Calendar event associated with the task.") + task_created = fields.Char(string="Task Creator ID", + help="This field stores the unique ID of the " + "task creator or owner.") + + @api.model + def create(self, vals): + """Override create() method to sync task to Google Calendar if + enabled.""" + task = super().create(vals) + if task.is_add_in_gcalendar: + self.sync_task_to_google_calendar(task) + return task + + def write(self, vals): + """Override write() method to update Google Calendar event if relevant + fields are modified.""" + res = super().write(vals) + if any(field in ['user_id', 'partner_id', 'name', 'description', + 'date_deadline', 'due_date', 'is_add_in_gcalendar'] for + field in vals): + task = self + self.update_google_calendar_event(task) + return res + + def sync_task_to_google_calendar(self, task): + """Sync the task to Google Calendar by creating a new event.""" + if self.is_add_in_gcalendar and ( + not self.partner_id or not self.date_deadline): + required_fields = [] + if not self.partner_id: + required_fields.append(self._fields['partner_id'].string) + if not self.date_deadline: + required_fields.append(self._fields['date_deadline'].string) + raise UserError(_( + f"The following fields are required when 'Add In G-Calendar" + f" Event' is enabled: {', '.join(required_fields)}")) + headers, url = self._prepare_headers_and_url( + self.env.user.google_user_mail) + project_name = task.project_id.name.capitalize() if task.project_id \ + else '' + event = { + "summary": f"Project: {project_name} - Task: {task.name}", + "description": task.description, + "start": {"date": str(task.date_deadline.date())} if task.date_deadline else { + "date": ""}, + "end": { + "date": str(task.date_deadline.date())} if task.date_deadline else { + "date": ""}, + "extendedProperties": { + "private": { + "create_date_time": str(task.create_date), + "user": task.activity_user_id.name if task.activity_user_id else "", + } + }, + "attendees": [{"email": attendee.email} for attendee in + task.user_ids if attendee.email], + "reminders": { + "useDefault": False, + "overrides": [ + {"method": "email", "minutes": 0}, + {"method": "email", "minutes": 24 * 60}, + ] + } + } + if task.partner_id and task.partner_id.email: + event["attendees"].append({"email": task.partner_id.email}) + event["reminders"]["overrides"].append( + {"method": "email", "minutes": 60}) + response = requests.post(url, headers=headers, json=event) + if response.status_code == 200: + event_id = response.json().get('id') + creator_email = response.json().get('creator', {}).get('email') + message = f'Google Calendar Event created\nTask ID: {task.id}\n' \ + f'Event ID: {event_id}\nCreator Email: {creator_email}' + task.message_post(body=message) + task.task_event = event_id + task.task_created = creator_email + else: + message = 'Failed to create event in Google Calendar' + task.message_post(body=message) + + def update_google_calendar_event(self, task): + """Update the Google Calendar event associated with the task.""" + event_id = task.task_event + if not event_id: + self.sync_task_to_google_calendar(task) + return + event = { + "summary": task.name, + "description": task.description, + "start": {"date": str(task.date_deadline.date())} if task.date_deadline else { + "date": ""}, + "end": { + "date": str(task.date_deadline.date())} if task.date_deadline else { + "date": ""}, + "extendedProperties": { + "private": { + "create_date_time": str(task.create_date), + "user": task.activity_user_id.name if task.activity_user_id else "", + } + }, + "attendees": [{"email": attendee.email} for attendee in + task.user_ids if attendee.email], + } + headers, url = self._prepare_headers_and_url( + self.env.user.google_user_mail, event_id) + response = requests.patch(url, headers=headers, json=event) + if response.status_code == 200: + message = f'Event updated in Google Calendar' + task.message_post(body=message) + else: + message = f'Failed to update event in Google Calendar' + task.message_post(body=message) + + def _prepare_headers_and_url(self, google_calendar_id, event_id=None): + """ + Prepare headers and URL for Google Calendar API requests. + """ + headers = { + "Authorization": f"Bearer {self.env.user.user_token}", + "Content-Type": "application/json", + "Accept": "application/json" + } + api_key = self.env.user.api_key + url = f"https://www.googleapis.com/calendar/v3/calendars/" \ + f"{google_calendar_id}/events" + if event_id: + url += f"/{event_id}" + url += f"?key={api_key}" + return headers, url + + def unlink(self): + """Override unlink method to delete associated Google Calendar + events.""" + self.delete_google_calendar_events() + return super(ProjectTask, self).unlink() + + def delete_google_calendar_events(self): + """Delete associated events from Google Calendar.""" + event_ids = self.mapped('task_event') + if event_ids: + headers = { + "Authorization": f"Bearer {self.env.user.user_token}", + "Content-Type": "application/json", + "Accept": "application/json" + } + for event_id in event_ids: + url = f"https://www.googleapis.com/calendar/v3/calendars/" \ + f"{self.env.user.google_user_mail}/events/{event_id}" \ + f"?key=" \ + f"{self.env.user.api_key}" + # Delete event from Google Calendar + response = requests.delete(url, headers=headers) + return response diff --git a/sync_task_with_google_calender/models/res_users.py b/sync_task_with_google_calender/models/res_users.py new file mode 100644 index 000000000..aa55021ae --- /dev/null +++ b/sync_task_with_google_calender/models/res_users.py @@ -0,0 +1,141 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2024-TODAY Cybrosys Technologies(). +# Author: Ayana KP (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +import requests +import re +from datetime import timedelta +from odoo import fields, models, _ +from odoo.exceptions import UserError +from odoo.addons.google_account.models.google_service import \ + GOOGLE_TOKEN_ENDPOINT + + +class ResUsers(models.Model): + """Extend res.users model to include Google Calendar integration.""" + + _inherit = 'res.users' + + refresh_token = fields.Char(string='Refresh Token', + help='Refresh token used for token ' + 'authentication with Google Calendar' + ' service.') + user_token = fields.Char(string='User Token', + help='User token or access token obtained from ' + 'Google Calendar service.') + last_sync_date = fields.Datetime(string='Token Validity', + help='Date and time indicating the ' + 'validity' + ' period of the user token.') + api_key = fields.Char(string="Enter API Key", + help='API key required for authentication and access ' + 'to Google Calendar service.') + google_user_mail = fields.Char(string='User Mail', + help='The Mail address where the task is ' + 'to be created') + + def _set_auth_tokens(self, access_token, refresh_token, ttl): + """Set the authentication tokens for the user.""" + self.write({ + 'refresh_token': refresh_token, + 'user_token': access_token, + 'last_sync_date': fields.Datetime.now() + timedelta( + seconds=ttl) if ttl else False, + }) + + def authenticate_button(self): + """Authenticate the user with Google Calendar service.""" + self.ensure_one() + get_param = self.env['ir.config_parameter'].sudo().get_param + client_id = get_param('google_calendar_client_id') + client_secret = get_param('google_calendar_client_secret') + if not client_id or not client_secret: + raise UserError(_("The account for the Google Calendar " + "service is not configured.")) + # Validate the API key and email credentials + if not (self.api_key and len( + self.api_key) > 10 and self.is_valid_email()): + raise UserError(_("Invalid credentials. Please provide valid " + "API key or email.")) + self.refresh_token = self.google_calendar_account_id.calendar_rtoken + self.user_token = self.google_calendar_account_id.calendar_token + self.last_sync_date = self.google_calendar_account_id. \ + calendar_token_validity + notification = { + 'type': 'ir.actions.client', + 'tag': 'display_notification', + 'params': { + 'title': _('Successful'), + 'type': 'success', + 'message': 'Authentication successful!', + 'sticky': True, + } + } + return notification + + def is_valid_email(self): + """ Return True if the email is valid, False otherwise""" + pattern = r'^[\w\.-]+@[\w\.-]+\.\w+$' + if self.google_user_mail and re.match(pattern, self.google_user_mail): + return True + return False + + def refresh_button(self): + """Refresh the user token using the refresh token.""" + get_param = self.env['ir.config_parameter'].sudo().get_param + client_id = get_param('google_calendar_client_id') + client_secret = get_param('google_calendar_client_secret') + if not client_id or not client_secret: + raise UserError( + _("The account for the Google Calendar service is" + " not configured.")) + headers = {"content-type": "application/x-www-form-urlencoded"} + data = { + 'refresh_token': self.refresh_token, + 'client_id': client_id, + 'client_secret': client_secret, + 'grant_type': 'refresh_token', + } + try: + _dummy, response, _dummy = self.env['google.service']._do_request( + GOOGLE_TOKEN_ENDPOINT, params=data, + headers=headers, method='POST', preuri='') + ttl = response.get('expires_in') + self.write({ + 'user_token': response.get('access_token'), + 'last_sync_date': fields.Datetime.now() + timedelta( + seconds=ttl), + }) + except requests.HTTPError as error: + if error.response.status_code in ( + 400, 401): # invalid grant or invalid client + # Delete refresh token and make sure it's committed + self.env.cr.rollback() + self._set_auth_tokens(False, False, 0) + self.env.cr.commit() + error_key = error.response.json().get("error", "nc") + error_msg = _( + "An error occurred while generating the token. " + "Your authorization code may be invalid or has already" + " expired [%s].You should check your Client ID and secret on " + "the Google APIs platform try to stop and restart your " + "calendar synchronization.", + error_key) + raise UserError(error_msg) diff --git a/sync_task_with_google_calender/static/description/assets/icons/capture (1).png b/sync_task_with_google_calender/static/description/assets/icons/capture (1).png new file mode 100644 index 000000000..8824deafc Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/capture (1).png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/check.png b/sync_task_with_google_calender/static/description/assets/icons/check.png new file mode 100644 index 000000000..c8e85f51d Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/check.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/chevron.png b/sync_task_with_google_calender/static/description/assets/icons/chevron.png new file mode 100644 index 000000000..2089293d6 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/chevron.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/cogs.png b/sync_task_with_google_calender/static/description/assets/icons/cogs.png new file mode 100644 index 000000000..95d0bad62 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/cogs.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/consultation.png b/sync_task_with_google_calender/static/description/assets/icons/consultation.png new file mode 100644 index 000000000..8319d4baa Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/consultation.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/ecom-black.png b/sync_task_with_google_calender/static/description/assets/icons/ecom-black.png new file mode 100644 index 000000000..a9385ff13 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/ecom-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/education-black.png b/sync_task_with_google_calender/static/description/assets/icons/education-black.png new file mode 100644 index 000000000..3eb09b27b Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/education-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/hotel-black.png b/sync_task_with_google_calender/static/description/assets/icons/hotel-black.png new file mode 100644 index 000000000..130f613be Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/hotel-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/img.png b/sync_task_with_google_calender/static/description/assets/icons/img.png new file mode 100644 index 000000000..70197f477 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/img.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/license.png b/sync_task_with_google_calender/static/description/assets/icons/license.png new file mode 100644 index 000000000..a5869797e Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/license.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/lifebuoy.png b/sync_task_with_google_calender/static/description/assets/icons/lifebuoy.png new file mode 100644 index 000000000..658d56ccc Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/lifebuoy.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/manufacturing-black.png b/sync_task_with_google_calender/static/description/assets/icons/manufacturing-black.png new file mode 100644 index 000000000..697eb0e9f Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/manufacturing-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/photo-capture.png b/sync_task_with_google_calender/static/description/assets/icons/photo-capture.png new file mode 100644 index 000000000..06c111758 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/photo-capture.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/pos-black.png b/sync_task_with_google_calender/static/description/assets/icons/pos-black.png new file mode 100644 index 000000000..97c0f90c1 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/pos-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/puzzle.png b/sync_task_with_google_calender/static/description/assets/icons/puzzle.png new file mode 100644 index 000000000..65cf854e7 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/puzzle.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/restaurant-black.png b/sync_task_with_google_calender/static/description/assets/icons/restaurant-black.png new file mode 100644 index 000000000..4a35eb939 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/restaurant-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/service-black.png b/sync_task_with_google_calender/static/description/assets/icons/service-black.png new file mode 100644 index 000000000..301ab51cb Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/service-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/trading-black.png b/sync_task_with_google_calender/static/description/assets/icons/trading-black.png new file mode 100644 index 000000000..9398ba2f1 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/trading-black.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/training.png b/sync_task_with_google_calender/static/description/assets/icons/training.png new file mode 100644 index 000000000..884ca024d Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/training.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/update.png b/sync_task_with_google_calender/static/description/assets/icons/update.png new file mode 100644 index 000000000..ecbc5a01a Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/update.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/user.png b/sync_task_with_google_calender/static/description/assets/icons/user.png new file mode 100644 index 000000000..6ffb23d9f Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/user.png differ diff --git a/sync_task_with_google_calender/static/description/assets/icons/wrench.png b/sync_task_with_google_calender/static/description/assets/icons/wrench.png new file mode 100644 index 000000000..6c04dea0f Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/icons/wrench.png differ diff --git a/sync_task_with_google_calender/static/description/assets/misc/Cybrosys R.png b/sync_task_with_google_calender/static/description/assets/misc/Cybrosys R.png new file mode 100644 index 000000000..da4058087 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/misc/Cybrosys R.png differ diff --git a/sync_task_with_google_calender/static/description/assets/misc/email.svg b/sync_task_with_google_calender/static/description/assets/misc/email.svg new file mode 100644 index 000000000..15291cdc3 --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/email.svg @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/sync_task_with_google_calender/static/description/assets/misc/phone.svg b/sync_task_with_google_calender/static/description/assets/misc/phone.svg new file mode 100644 index 000000000..b7bd7f251 --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/phone.svg @@ -0,0 +1,3 @@ + + + diff --git a/sync_task_with_google_calender/static/description/assets/misc/star (1) 2.svg b/sync_task_with_google_calender/static/description/assets/misc/star (1) 2.svg new file mode 100644 index 000000000..5ae9f507a --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/star (1) 2.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/sync_task_with_google_calender/static/description/assets/misc/support (1) 1.svg b/sync_task_with_google_calender/static/description/assets/misc/support (1) 1.svg new file mode 100644 index 000000000..7d37a8f30 --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/support (1) 1.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/sync_task_with_google_calender/static/description/assets/misc/support-email.svg b/sync_task_with_google_calender/static/description/assets/misc/support-email.svg new file mode 100644 index 000000000..eb70370d6 --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/support-email.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/sync_task_with_google_calender/static/description/assets/misc/tick-mark.svg b/sync_task_with_google_calender/static/description/assets/misc/tick-mark.svg new file mode 100644 index 000000000..2dbb40187 --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/tick-mark.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/sync_task_with_google_calender/static/description/assets/misc/whatsapp 1.svg b/sync_task_with_google_calender/static/description/assets/misc/whatsapp 1.svg new file mode 100644 index 000000000..0bfaf8fc6 --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/whatsapp 1.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/sync_task_with_google_calender/static/description/assets/misc/whatsapp.svg b/sync_task_with_google_calender/static/description/assets/misc/whatsapp.svg new file mode 100644 index 000000000..b618aea1d --- /dev/null +++ b/sync_task_with_google_calender/static/description/assets/misc/whatsapp.svg @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/sync_task_with_google_calender/static/description/assets/modules/module_image (1).jpeg b/sync_task_with_google_calender/static/description/assets/modules/module_image (1).jpeg new file mode 100644 index 000000000..5ae24843e Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/modules/module_image (1).jpeg differ diff --git a/sync_task_with_google_calender/static/description/assets/modules/module_image (1).png b/sync_task_with_google_calender/static/description/assets/modules/module_image (1).png new file mode 100644 index 000000000..0dea4f332 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/modules/module_image (1).png differ diff --git a/sync_task_with_google_calender/static/description/assets/modules/module_image (2).png b/sync_task_with_google_calender/static/description/assets/modules/module_image (2).png new file mode 100644 index 000000000..a5dc79613 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/modules/module_image (2).png differ diff --git a/sync_task_with_google_calender/static/description/assets/modules/module_image-1.jpeg b/sync_task_with_google_calender/static/description/assets/modules/module_image-1.jpeg new file mode 100644 index 000000000..31f066e9c Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/modules/module_image-1.jpeg differ diff --git a/sync_task_with_google_calender/static/description/assets/modules/module_image.jpeg b/sync_task_with_google_calender/static/description/assets/modules/module_image.jpeg new file mode 100644 index 000000000..0cbac311c Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/modules/module_image.jpeg differ diff --git a/sync_task_with_google_calender/static/description/assets/modules/module_image.png b/sync_task_with_google_calender/static/description/assets/modules/module_image.png new file mode 100644 index 000000000..612be4b77 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/modules/module_image.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/1.png b/sync_task_with_google_calender/static/description/assets/screenshots/1.png new file mode 100644 index 000000000..18c788f4b Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/1.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/10.png b/sync_task_with_google_calender/static/description/assets/screenshots/10.png new file mode 100644 index 000000000..366b68625 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/10.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/11-1.png b/sync_task_with_google_calender/static/description/assets/screenshots/11-1.png new file mode 100644 index 000000000..521b7cdf2 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/11-1.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/11-2.png b/sync_task_with_google_calender/static/description/assets/screenshots/11-2.png new file mode 100644 index 000000000..1e39e8182 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/11-2.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/11.png b/sync_task_with_google_calender/static/description/assets/screenshots/11.png new file mode 100644 index 000000000..f3ced1753 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/11.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/12.png b/sync_task_with_google_calender/static/description/assets/screenshots/12.png new file mode 100644 index 000000000..2221aea95 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/12.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/13.png b/sync_task_with_google_calender/static/description/assets/screenshots/13.png new file mode 100644 index 000000000..3f4e23f3a Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/13.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/14.png b/sync_task_with_google_calender/static/description/assets/screenshots/14.png new file mode 100644 index 000000000..d08da60c1 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/14.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/15.png b/sync_task_with_google_calender/static/description/assets/screenshots/15.png new file mode 100644 index 000000000..951240f18 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/15.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/16.png b/sync_task_with_google_calender/static/description/assets/screenshots/16.png new file mode 100644 index 000000000..a490975dd Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/16.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/17.png b/sync_task_with_google_calender/static/description/assets/screenshots/17.png new file mode 100644 index 000000000..4c5cff374 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/17.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/18.png b/sync_task_with_google_calender/static/description/assets/screenshots/18.png new file mode 100644 index 000000000..55690303f Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/18.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/2.png b/sync_task_with_google_calender/static/description/assets/screenshots/2.png new file mode 100644 index 000000000..b2bf1a9e6 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/2.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/20.png b/sync_task_with_google_calender/static/description/assets/screenshots/20.png new file mode 100644 index 000000000..5108547ce Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/20.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/21.png b/sync_task_with_google_calender/static/description/assets/screenshots/21.png new file mode 100644 index 000000000..ade6a9005 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/21.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/22.png b/sync_task_with_google_calender/static/description/assets/screenshots/22.png new file mode 100644 index 000000000..44856dfff Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/22.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/23.png b/sync_task_with_google_calender/static/description/assets/screenshots/23.png new file mode 100644 index 000000000..611ae481e Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/23.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/3.png b/sync_task_with_google_calender/static/description/assets/screenshots/3.png new file mode 100644 index 000000000..4488ebfb6 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/3.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/4.png b/sync_task_with_google_calender/static/description/assets/screenshots/4.png new file mode 100644 index 000000000..687b5b506 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/4.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/6.png b/sync_task_with_google_calender/static/description/assets/screenshots/6.png new file mode 100644 index 000000000..28b709b49 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/6.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/7.png b/sync_task_with_google_calender/static/description/assets/screenshots/7.png new file mode 100644 index 000000000..7cde7fa53 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/7.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/8.png b/sync_task_with_google_calender/static/description/assets/screenshots/8.png new file mode 100644 index 000000000..731d1b4a7 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/8.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/9.png b/sync_task_with_google_calender/static/description/assets/screenshots/9.png new file mode 100644 index 000000000..65b418fc9 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/9.png differ diff --git a/sync_task_with_google_calender/static/description/assets/screenshots/hero-v17.gif b/sync_task_with_google_calender/static/description/assets/screenshots/hero-v17.gif new file mode 100644 index 000000000..d2dc77e06 Binary files /dev/null and b/sync_task_with_google_calender/static/description/assets/screenshots/hero-v17.gif differ diff --git a/sync_task_with_google_calender/static/description/banner.jpg b/sync_task_with_google_calender/static/description/banner.jpg new file mode 100644 index 000000000..6a31fdf69 Binary files /dev/null and b/sync_task_with_google_calender/static/description/banner.jpg differ diff --git a/sync_task_with_google_calender/static/description/icon.png b/sync_task_with_google_calender/static/description/icon.png new file mode 100644 index 000000000..eddff1a9b Binary files /dev/null and b/sync_task_with_google_calender/static/description/icon.png differ diff --git a/sync_task_with_google_calender/static/description/index.html b/sync_task_with_google_calender/static/description/index.html new file mode 100644 index 000000000..d4055c94f --- /dev/null +++ b/sync_task_with_google_calender/static/description/index.html @@ -0,0 +1,1029 @@ + + + + + + + Odoo App 3 Index + + + + + + + + +
+
+
+
+
+ +
+
+
+ Community +
+
+ Enterprise +
+
+ Odoo.sh +
+
+
+
+
+
+

+ Google Calendar Integration for Project and Task

+

+ Google Calendar Synchronization With Odoo Project and Tasks +

+
+ +
+
+
+
+
+

+ Key Highlights +

+
+
+
+
+
+ +
+
+

+ Community, Enterprise and Odoo.sh Support

+

Available in + Odoo 17.0 Community, Enterprise and Odoo.sh +

+
+
+
+
+
+
+ +
+
+

+ Sync Project Task with Google Calendar.

+
+
+
+
+
+
+ +
+
+

+ Auto Delete Task with Google Calendar.

+
+
+
+
+
+
+ +
+
+

+ Auto Update Task with Google Calendar.

+
+
+
+
+
+
+ +
+
+
+
+
+ +
+
+

+ Create a new project from Google cloud platform.

+
+
+
+
+
+
+ +
+
+

+ Add a project name and click on "CREATE" button.

+
+
+
+
+
+
+ +
+
+

+ Navigate to "Google API Console" and click on "ENABLE APIS AND + SERVICES".

+
+
+
+
+
+
+ +
+
+

+ Enable Google Calendar API.

+
+
+
+
+
+
+ +
+
+

+ Search for 'Google Calendar API,' open it, and click 'Enable' to activate it.

+
+
+
+
+
+
+ +
+
+

+ Navigate to "Credentials" menu and click "Create Credentials" button. Then select + "Google Calendar API" as api and "User Data" as data accessing and click + "Next".

+
+
+
+
+
+
+ +
+
+

+ Choose 'Web Application' as the application type and provide a name. Click 'Add URL' + under 'Authorized Redirect URIs' and enter your URL.

+
+
+
+
+
+
+ +
+
+

+ On clicking "Create" button user will get "Client ID" and "Client secret" key for + Google calendar api.

+
+
+
+
+
+
+ +
+
+

+ Under Settings -> Calendar -> Google Calendar, add Client ID and Client Secret then + save.

+
+
+
+
+
+
+ +
+
+

+ Under Settings -> Users and Companies -> Users menu, navigate to the "Sync of + Project Task" tab + where users need to enter the API Key and User Mail, then click the + "AUTHENTICATE" button.

+
+
+
+
+
+
+ +
+
+

+ Under "Create Credentials," you can find the API key. Click on it to generate the + API key, then copy and paste it into the "Enter API Key" field in the above + screenshot.

+
+
+
+
+
+
+ +
+
+

+ After filling in these fields, click on the "AUTHENTICATE" button. If the + authentication is successful, a success notification will appear in the right + corner.

+
+
+
+
+
+
+ +
+
+

+ If the connection is successful, tokens will be generated automatically.

+
+
+
+
+
+
+ +
+
+

+ Then goto Calendar module and confirm the synchronization.

+
+
+
+ +
+
+
+ +
+
+

+ When creating a project task, the user must enable "Add In G-Calendar Event" and + provide additional task information such as the name, customer, due date, deadline, + end date, and description.

+
+
+
+
+
+
+ +
+
+

+ The user will see that tasks with "Add In G-Calendar Event" are automatically linked + to Google Calendar.

+
+
+
+
+
+
+ +
+
+

+ Clicking on the Google Calendar event will display all task details, including the + project and task name, creation date and time, attendees, description, and + user.

+
+
+
+
+
+
+ +
+
+

+ The "Google Calendar Task Event" tab in Odoo tasks will display the Event ID and + Creator ID.

+
+
+
+
+
+
+ +
+
+

+ When updating project task details such as user, customer, name, description, + deadline, or due date, the Google Calendar event will also be updated. The status of + these changes can be viewed in the chatter.

+
+
+
+
+
+
+ +
+
+

+ The user can view the updated Google Calendar event according to the task + changes.

+
+
+
+
+
+
+ +
+
+

+ If the user deletes a project task, the corresponding Google Calendar event will + also be deleted.

+
+
+
+
+
+
+ +
+
+

+ After deleting the project tasks from Odoo, you'll notice that the corresponding + event is also deleted from the Google Calendar.

+
+
+
+
+
+
+
    +
  • + Available in + Odoo 17.0 Community, Enterprise and Odoo.sh +
  • +
  • + Helps to + Sync Project Task with Google Calendar. +
  • +
+
+
+
+
+
+
Version + 17.0.1.0.0|Released on:18th Jun 2024 +
+

+ Initial Commit for Google Calendar Integration For Project And Task.

+
+
+
+
+
+
+
+

+ Related Products

+
+
+ +
+
+

+ Our Services

+ +
+
+
+
+
+
+
+
+ service-icon +
+
+

Odoo + Customization

+
+
+
+
+
+
+ service-icon +
+
+

Odoo + Implementation

+
+
+
+
+
+
+ service-icon +
+
+

Odoo + Support

+
+
+
+
+
+
+ service-icon +
+
+

Hire + Odoo Developer

+
+
+
+
+ +
+
+ service-icon +
+
+

Odoo + Integration

+
+
+
+
+
+
+ service-icon +
+
+

Odoo + Migration

+
+
+
+
+
+
+ service-icon +
+
+

Odoo + Consultancy

+
+
+
+
+
+
+ service-icon +
+
+

Odoo + Implementation

+
+
+
+
+
+
+ service-icon +
+
+

Odoo + Licensing Consultancy

+
+
+
+
+
+
+

+ Our Industries

+ +
+
+
+
+
+
+ +

Trading

+

Easily procure and sell your products

+
+
+
+
+ +

POS

+

Easy configuration and convivial experience

+
+
+
+
+ +

+ Education

+

A platform for educational management

+
+
+
+
+ +

+ Manufacturing

+

Plan, track and schedule your operations

+
+
+
+
+ +

E-commerce & + Website

+

Mobile friendly, awe-inspiring product pages

+
+
+
+
+ +

Service + Management

+

Keep track of services and invoice

+
+
+
+
+ +

+ Restaurant

+

Run your bar or restaurant methodically

+
+
+
+
+ +

Hotel + Management

+

An all-inclusive hotel management application

+
+
+
+
+
+
+

+ Support

+
+
+
+
+
+
+
+ +
+ Need + Help? +

Got + questions or need help? Get in touch.

+
odoo@cybrosys.com +
+
+
+
+
+
+
+
+ +
+ WhatsApp +

Say hi to + us on WhatsApp!

+
+91 + 99456767686 +
+
+
+
+
+
+
+
+
+ + + + + + diff --git a/sync_task_with_google_calender/views/project_task_views.xml b/sync_task_with_google_calender/views/project_task_views.xml new file mode 100644 index 000000000..344f4cfbe --- /dev/null +++ b/sync_task_with_google_calender/views/project_task_views.xml @@ -0,0 +1,31 @@ + + + + + + project.task.view.form.inherit.sync.task.with.google.calender + + project.task + + + + is_add_in_gcalendar + + + + + + + + + + + + + + + + + diff --git a/sync_task_with_google_calender/views/res_users_views.xml b/sync_task_with_google_calender/views/res_users_views.xml new file mode 100644 index 000000000..2b6aff0eb --- /dev/null +++ b/sync_task_with_google_calender/views/res_users_views.xml @@ -0,0 +1,37 @@ + + + + + + res.users.view.form.inherit.sync.task.with.google.calender + + res.users + + + + + + + + + + + + + + + +