@ -0,0 +1,46 @@ |
|||||
|
.. 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 |
||||
|
|
||||
|
Twilio SMS Gateway |
||||
|
================== |
||||
|
* This module used to send sms through twilio sms from sales, purchase and contact modules. |
||||
|
|
||||
|
Configuration |
||||
|
============= |
||||
|
- Install twilio (pip install twilio) |
||||
|
|
||||
|
Company |
||||
|
======= |
||||
|
* Cybrosys Techno Solutions <https://cybrosys.com/> |
||||
|
|
||||
|
License |
||||
|
======= |
||||
|
GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3). |
||||
|
http://www.gnu.org/licenses/agpl-3.0-standalone.html |
||||
|
|
||||
|
Credits |
||||
|
======= |
||||
|
* Developer: (v15) Busthana Shirin , Contact: odoo@cybrosys.com |
||||
|
|
||||
|
Contacts |
||||
|
======== |
||||
|
* Mail Contact : odoo@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 https://www.cybrosys.com |
||||
|
|
||||
|
Further information |
||||
|
=================== |
||||
|
HTML Description: `<static/description/index.html>`__ |
@ -0,0 +1,22 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
################################################################################ |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>). |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
################################################################################ |
||||
|
from . import models |
||||
|
from . import wizard |
@ -0,0 +1,48 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
################################################################################ |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>). |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
################################################################################ |
||||
|
{ |
||||
|
'name': 'Twilio SMS Gateway', |
||||
|
'version': '15.0.1.0.0', |
||||
|
'category': 'Extra Tools', |
||||
|
'summary': """Send SmS through twilio""", |
||||
|
'description': """The module helps to send SmS through twilio""", |
||||
|
'author': 'Cybrosys Techno Solutions', |
||||
|
'company': 'Cybrosys Techno Solutions', |
||||
|
'maintainer': 'Cybrosys Techno Solutions', |
||||
|
'website': 'https://www.cybrosys.com', |
||||
|
'depends': ['base_setup', 'sale', 'purchase', 'base'], |
||||
|
'data': [ |
||||
|
'security/ir.model.access.csv', |
||||
|
'data/ir_cron_data.xml', |
||||
|
'views/purchase_order_views.xml', |
||||
|
'views/sale_order_views.xml', |
||||
|
'views/twilio_account_views.xml', |
||||
|
'views/twilio_sms_group_views.xml', |
||||
|
'views/twilio_sms_template_views.xml', |
||||
|
'views/twilio_sms_views.xml', |
||||
|
'wizard/twilio_sms_interaction_views.xml', |
||||
|
], |
||||
|
'images': ['static/description/banner.jpg'], |
||||
|
'license': 'AGPL-3', |
||||
|
'installable': True, |
||||
|
'auto_install': False, |
||||
|
'application': True, |
||||
|
} |
@ -0,0 +1,16 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!--Sent SMS on scheduled time --> |
||||
|
<data noupdate="1"> |
||||
|
<record id="ir_cron_sent_sms" model="ir.cron"> |
||||
|
<field name="name">Sent SmS</field> |
||||
|
<field name="model_id" ref="model_twilio_sms"/> |
||||
|
<field name="state">code</field> |
||||
|
<field name="code">model.sent_sms_on_time()</field> |
||||
|
<field name="interval_number">1</field> |
||||
|
<field name="interval_type">minutes</field> |
||||
|
<field name="numbercall">-1</field> |
||||
|
<field name="doall" eval="False"/> |
||||
|
</record> |
||||
|
</data> |
||||
|
</odoo> |
@ -0,0 +1,6 @@ |
|||||
|
## Module <odoo_twilio_sms> |
||||
|
|
||||
|
#### 06.02.2024 |
||||
|
#### Version 15.0.1.0.0 |
||||
|
##### ADD |
||||
|
- Initial Commit for Twilio SMS Gateway |
@ -0,0 +1,27 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from . import purchase_order |
||||
|
from . import res_partner |
||||
|
from . import sale_order |
||||
|
from . import sms_template |
||||
|
from . import twilio_account |
||||
|
from . import twilio_sms |
||||
|
from . import twilio_sms_group |
@ -0,0 +1,39 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from odoo import models, _ |
||||
|
|
||||
|
|
||||
|
class PurchaseOrder(models.Model): |
||||
|
"""Inheriting model purchase order""" |
||||
|
_inherit = 'purchase.order' |
||||
|
|
||||
|
def action_purchase_twilio_sms(self): |
||||
|
"""Action for SmS wizard view""" |
||||
|
action = { |
||||
|
'type': 'ir.actions.act_window', |
||||
|
'name': _('Message Content'), |
||||
|
'res_model': 'twilio.sms.interaction', |
||||
|
'view_mode': 'form', |
||||
|
'target': 'new', |
||||
|
'context': {'default_partner_id': self.partner_id.id}, |
||||
|
'views': [[False, 'form']] |
||||
|
} |
||||
|
return action |
@ -0,0 +1,43 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from odoo import fields, models, _ |
||||
|
|
||||
|
|
||||
|
class ResPartner(models.Model): |
||||
|
"""Inheriting model res partner""" |
||||
|
_inherit = 'res.partner' |
||||
|
|
||||
|
twilio_sms_id = fields.Many2one('twilio.sms.group', |
||||
|
string='Twilio ID', |
||||
|
help='Twilio Connection') |
||||
|
|
||||
|
def action_partner_twilio_sms(self): |
||||
|
"""Action for SmS wizard view""" |
||||
|
action = { |
||||
|
'type': 'ir.actions.act_window', |
||||
|
'name': _('Message Content'), |
||||
|
'res_model': 'twilio.sms.interaction', |
||||
|
'view_mode': 'form', |
||||
|
'target': 'new', |
||||
|
'context': {'default_partner_id': self.id}, |
||||
|
'views': [[False, 'form']] |
||||
|
} |
||||
|
return action |
@ -0,0 +1,39 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from odoo import models, _ |
||||
|
|
||||
|
|
||||
|
class SaleOrder(models.Model): |
||||
|
"""Inheriting model sale order""" |
||||
|
_inherit = 'sale.order' |
||||
|
|
||||
|
def action_twilio_sms(self): |
||||
|
"""Action for SmS wizard view""" |
||||
|
action = { |
||||
|
'type': 'ir.actions.act_window', |
||||
|
'name': _('Message Content'), |
||||
|
'res_model': 'twilio.sms.interaction', |
||||
|
'view_mode': 'form', |
||||
|
'target': 'new', |
||||
|
'context': {'default_partner_id': self.partner_id.id}, |
||||
|
'views': [[False, 'form']] |
||||
|
} |
||||
|
return action |
@ -0,0 +1,30 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from odoo import fields, models, _ |
||||
|
|
||||
|
|
||||
|
class TwilioSmsTemplate(models.Model): |
||||
|
"""Template to create template which can select and send messages""" |
||||
|
_name = 'twilio.sms.template' |
||||
|
_description = 'Twilio SmS Template' |
||||
|
|
||||
|
name = fields.Char(string='Name', help='Name of Template', required=True) |
||||
|
content = fields.Text(string='Content', help='Content of the Template') |
@ -0,0 +1,83 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from twilio.rest import Client |
||||
|
from odoo import fields, models, _ |
||||
|
|
||||
|
|
||||
|
class TwilioAccount(models.Model): |
||||
|
"""Create twilio account to set the details of twilio account, |
||||
|
can set the number and auth token""" |
||||
|
_name = 'twilio.account' |
||||
|
_description = 'Twilio Account' |
||||
|
|
||||
|
name = fields.Char(string='Name', required=True, help='Name') |
||||
|
account_sid = fields.Char(string='Account SID', required=True, |
||||
|
help='Account SID') |
||||
|
auth_token = fields.Char(string='Auth Token', required=True, |
||||
|
help='Auth Token') |
||||
|
from_number = fields.Char(string='From Number', required=True, |
||||
|
help='Twilio account number') |
||||
|
to_number = fields.Char(string='To Number', required=True, |
||||
|
help='Receiving number for testing') |
||||
|
body = fields.Text(string='Body', required=True, |
||||
|
help='Body for test message', |
||||
|
default='This Message is To Test The Connection') |
||||
|
state = fields.Selection(selection=[ |
||||
|
('new', 'New'), |
||||
|
('confirm', 'Connected'), |
||||
|
], string='State', required=True, default='new', |
||||
|
help='The state to show the connection is successful') |
||||
|
|
||||
|
def action_test_connection(self): |
||||
|
"""Send test sms and set the connection""" |
||||
|
try: |
||||
|
client = Client(self.account_sid, self.auth_token) |
||||
|
message = client.messages.create( |
||||
|
body=self.body, |
||||
|
from_=self.from_number, |
||||
|
to=self.to_number) |
||||
|
if message.sid: |
||||
|
self.state = 'confirm' |
||||
|
message_data = _("Connection Successful!") |
||||
|
message_type = 'success' |
||||
|
else: |
||||
|
message_data = _("Connection Not Successful!") |
||||
|
message_type = 'warning' |
||||
|
return { |
||||
|
'type': 'ir.actions.client', |
||||
|
'tag': 'display_notification', |
||||
|
'params': { |
||||
|
'message': message_data, |
||||
|
'type': message_type, |
||||
|
'sticky': True, |
||||
|
} |
||||
|
} |
||||
|
except: |
||||
|
return { |
||||
|
'type': 'ir.actions.client', |
||||
|
'tag': 'display_notification', |
||||
|
'params': { |
||||
|
'message': _("Connection Not Successful!"), |
||||
|
'type': 'warning', |
||||
|
'sticky': True, |
||||
|
} |
||||
|
} |
||||
|
pass |
@ -0,0 +1,104 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from twilio.rest import Client |
||||
|
from odoo import api, fields, models, _ |
||||
|
|
||||
|
|
||||
|
class TwilioSmS(models.Model): |
||||
|
"""Can send sms, select the receiver and template or content, |
||||
|
then can send the sms""" |
||||
|
_name = 'twilio.sms' |
||||
|
_description = 'Twilio SmS' |
||||
|
|
||||
|
name = fields.Char(string='Name', help='Name', required=True) |
||||
|
partner_id = fields.Many2one('twilio.sms.group', |
||||
|
string='Select Receiving Group', |
||||
|
help='Select the receiving groups', |
||||
|
required=True) |
||||
|
template_body_id = fields.Many2one('twilio.sms.template', |
||||
|
string='Message Template', |
||||
|
help='Select the message template') |
||||
|
content = fields.Text(string='Content', help='Content', required=True) |
||||
|
scheduled_date = fields.Date('Scheduled Date', help='Scheduled Date', |
||||
|
default=fields.Date.today) |
||||
|
state = fields.Selection(selection=[ |
||||
|
('draft', 'Draft'), |
||||
|
('confirm', 'Confirm'), |
||||
|
('sent', 'Sent'), |
||||
|
], string="State", default='draft', help='State of the sms') |
||||
|
|
||||
|
@api.onchange('template_body_id') |
||||
|
def onchange_template_body_id(self): |
||||
|
"""Add the content when select the template""" |
||||
|
self.content = self.template_body_id.content |
||||
|
|
||||
|
def action_confirm_sms(self): |
||||
|
"""Send sms when click the action button""" |
||||
|
for val in self: |
||||
|
val.state = 'confirm' |
||||
|
if val.scheduled_date == fields.Date.today(): |
||||
|
self.sent_sms_message(val) |
||||
|
|
||||
|
def sent_sms_on_time(self): |
||||
|
"""Send sms when schedule the time""" |
||||
|
vals = self.env['twilio.sms'].search([]) |
||||
|
for val in vals: |
||||
|
if (val.state == 'confirm' and val.scheduled_date == |
||||
|
fields.date.today()): |
||||
|
self.sent_sms_message(val) |
||||
|
|
||||
|
def sent_sms_message(self, val): |
||||
|
"""Send SmS for all users""" |
||||
|
server = self.env['twilio.account'].search([('state', '=', 'confirm')], |
||||
|
limit=1) |
||||
|
count = len(val.partner_id.contact_ids) |
||||
|
for partner in val.partner_id.contact_ids: |
||||
|
try: |
||||
|
client = Client(server.account_sid, server.auth_token) |
||||
|
message = client.messages.create( |
||||
|
body=val.content, |
||||
|
from_=server.from_number, |
||||
|
to=partner.phone |
||||
|
) |
||||
|
if message.sid: |
||||
|
count = count - 1 |
||||
|
if not count: |
||||
|
val.state = 'sent' |
||||
|
return { |
||||
|
'type': 'ir.actions.client', |
||||
|
'tag': 'display_notification', |
||||
|
'params': { |
||||
|
'message': 'Message Sent Successfully', |
||||
|
'type': 'success', |
||||
|
'sticky': True, |
||||
|
} |
||||
|
} |
||||
|
except: |
||||
|
return { |
||||
|
'type': 'ir.actions.client', |
||||
|
'tag': 'display_notification', |
||||
|
'params': { |
||||
|
'message': _("Message Not Sent!"), |
||||
|
'type': 'warning', |
||||
|
'sticky': True, |
||||
|
} |
||||
|
} |
||||
|
pass |
@ -0,0 +1,33 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
############################################################################### |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
############################################################################### |
||||
|
from odoo import fields, models |
||||
|
|
||||
|
|
||||
|
class TwilioSmsGroup(models.Model): |
||||
|
"""Make group can send sms to group with more than one receiver at time""" |
||||
|
_name = 'twilio.sms.group' |
||||
|
_description = 'Twilio SmS Group' |
||||
|
|
||||
|
name = fields.Char('Name', help='Name of Group', required=True) |
||||
|
contact_ids = fields.One2many('res.partner', |
||||
|
'twilio_sms_id', |
||||
|
string='Partner Group', |
||||
|
help='Group Contacts') |
|
After Width: | Height: | Size: 3.6 KiB |
After Width: | Height: | Size: 310 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.4 KiB |
After Width: | Height: | Size: 576 B |
After Width: | Height: | Size: 733 B |
After Width: | Height: | Size: 911 B |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 673 B |
After Width: | Height: | Size: 878 B |
After Width: | Height: | Size: 653 B |
After Width: | Height: | Size: 905 B |
After Width: | Height: | Size: 839 B |
After Width: | Height: | Size: 427 B |
After Width: | Height: | Size: 627 B |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 988 B |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 4.4 KiB |
After Width: | Height: | Size: 589 B |
After Width: | Height: | Size: 3.4 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 967 B |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 3.8 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 61 KiB |
After Width: | Height: | Size: 61 KiB |
After Width: | Height: | Size: 59 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 161 KiB |
After Width: | Height: | Size: 53 KiB |
After Width: | Height: | Size: 87 KiB |
After Width: | Height: | Size: 47 KiB |
After Width: | Height: | Size: 30 KiB |
After Width: | Height: | Size: 49 KiB |
After Width: | Height: | Size: 46 KiB |
After Width: | Height: | Size: 103 KiB |
After Width: | Height: | Size: 77 KiB |
After Width: | Height: | Size: 6.8 KiB |
@ -0,0 +1,577 @@ |
|||||
|
<div style="background-color: #714B67; height: 810px; width: 100%; padding: 15px; position: relative;"> |
||||
|
<!-- TITLE BAR --> |
||||
|
<div class="d-flex align-items-center justify-content-between" |
||||
|
style="border-bottom: 1px solid #875A7B; padding: 15px; display: flex; justify-content: space-between; align-items: center;"> |
||||
|
<img src="assets/misc/cybrosys-logo.png" width="42" height="42" style="width: 42px; height: 42px;" /> |
||||
|
<div> |
||||
|
<div |
||||
|
style="color: #7C7BAD; font-size: 14px; font-family: 'Montserrat', sans-serif; font-weight: bold; background-color: white; display: inline-block; padding: 3px 10px; border-radius: 50px;" |
||||
|
class="mr-2"> |
||||
|
<i class="fa fa-check mr-1"></i>Community |
||||
|
</div> |
||||
|
<div |
||||
|
style="color: #7C7BAD; font-size: 14px; font-family: 'Montserrat', sans-serif; font-weight: bold; background-color: white; display: inline-block; padding: 3px 10px; border-radius: 50px;" |
||||
|
class="mr-2"> |
||||
|
<i class="fa fa-check mr-1"></i>Enterprise |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- END OF TITLE BAR --> |
||||
|
<div class="container"> |
||||
|
<div class="row"> |
||||
|
<div class="col-sm-12 col-md-12 col-lg-12"> |
||||
|
<!-- APP HERO --> |
||||
|
<h1 style="color: #FFFFFF; font-weight: bolder; font-size: 50px; text-align: center; margin-top: 50px;"> |
||||
|
Twilio SMS Gateway</h1> |
||||
|
<p style="color:#FFFFFF; padding: 8px 15px; text-align: center; font-size: 24px;">Send SMS Through Twilio</p> |
||||
|
<!-- END OF APP HERO --> |
||||
|
<img src="assets/screenshots/hero1.gif" class="img-responsive" |
||||
|
style="width: 100%; margin-left: auto; margin-right: auto;" /> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- NAVIGATION SECTION --> |
||||
|
<div class="d-flex align-items-center" style="border-bottom: 2px solid #714B67; padding: 15px 0px; margin-top: 300px;"> |
||||
|
<div class="d-flex justify-content-center align-items-center mr-2" |
||||
|
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;"> |
||||
|
<img src="assets/misc/compass.png" /> |
||||
|
</div> |
||||
|
<h2 class="mt-2" style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">Explore This |
||||
|
Module</h2> |
||||
|
</div> |
||||
|
<div class="row my-4" style="font-family: 'Montserrat', sans-serif;"> |
||||
|
<div class="col-sm-12 col-md-6 my-3"> |
||||
|
<a href="#overview"> |
||||
|
<div class="d-flex justify-content-between align-items-center" |
||||
|
style="background-color: #f5f5f5; padding: 30px; width: 100%;"> |
||||
|
<div> |
||||
|
<span style="color: #714B67; font-size: 24px; font-weight: 500; display: block;">Overview</span> |
||||
|
<span |
||||
|
style="color: #714B67; font-size: 16px; font-weight: 400; color:#282F33; display: block;">Learn |
||||
|
more about this |
||||
|
module</span> |
||||
|
</div> |
||||
|
<img src="assets/misc/right-arrow.png" width="36" height="36" /> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
<div class="col-sm-12 col-md-6 my-3"> |
||||
|
<a href="#features"> |
||||
|
<div class="d-flex justify-content-between align-items-center" |
||||
|
style="background-color: #f5f5f5; padding: 30px; width: 100%;"> |
||||
|
<div> |
||||
|
<span style="color: #714B67; font-size: 24px; font-weight: 500; display: block;">Features</span> |
||||
|
<span |
||||
|
style="color: #714B67; font-size: 16px; font-weight: 400; color:#282F33; display: block;">View |
||||
|
features of this |
||||
|
module</span> |
||||
|
</div> |
||||
|
<img src="assets/misc/right-arrow.png" width="36" height="36" /> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
<div class="col-sm-12 col-md-6 my-3"> |
||||
|
<a href="#screenshots"> |
||||
|
<div class="d-flex justify-content-between align-items-center" |
||||
|
style="background-color: #f5f5f5; padding: 30px; width: 100%;"> |
||||
|
<div> |
||||
|
<span style="color: #714B67; font-size: 24px; font-weight: 500; display: block;">Screenshots</span> |
||||
|
<span |
||||
|
style="color: #714B67; font-size: 16px; font-weight: 400; color:#282F33; display: block;">View |
||||
|
screenshots of this |
||||
|
module</span> |
||||
|
</div> |
||||
|
<img src="assets/misc/right-arrow.png" width="36" height="36" /> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- END OF NAVIGATION SECTION --> |
||||
|
|
||||
|
<!-- OVERVIEW SECTION --> |
||||
|
<div class="d-flex align-items-center" style="border-bottom: 2px solid #714B67; padding: 15px 0px;" id="overview"> |
||||
|
<div class="d-flex justify-content-center align-items-center mr-2" |
||||
|
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;"> |
||||
|
<img src="assets/misc/pie-chart.png" /> |
||||
|
</div> |
||||
|
<h2 class="mt-2" style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">Overview |
||||
|
</h2> |
||||
|
</div> |
||||
|
<div class="row" style="font-family: 'Montserrat', sans-serif; font-weight: 400; font-size: 14px; line-height: 200%;"> |
||||
|
<div class="col-sm-12 py-4"> |
||||
|
The module will help us to send the sms through twilio, it will help us to send sms from sale order, purchase order |
||||
|
and contacts.In this module we can create the message templates and use whenever we need. This module will |
||||
|
help us to send sms to a group of members also. |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- END OF OVERVIEW SECTION --> |
||||
|
|
||||
|
<!-- FEATURES SECTION --> |
||||
|
<div class="d-flex align-items-center" style="border-bottom: 2px solid #714B67; padding: 15px 0px;" id="features"> |
||||
|
<div class="d-flex justify-content-center align-items-center mr-2" |
||||
|
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;"> |
||||
|
<img src="assets/misc/features.png" /> |
||||
|
</div> |
||||
|
<h2 class="mt-2" style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">Features |
||||
|
</h2> |
||||
|
</div> |
||||
|
<div class="row" style="font-family: 'Montserrat', sans-serif; font-weight: 400; font-size: 14px; line-height: 200%;"> |
||||
|
<div class="col-sm-12 col-md-6"> |
||||
|
<div class="d-flex align-items-center" style="margin-top: 40px; margin-bottom: 40px"> |
||||
|
<img src="assets/misc/check-box.png" class="mr-2" /> |
||||
|
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Can Send SMS in Sale Order, Purchase Order, and Contacts</span> |
||||
|
</div> |
||||
|
<div class="d-flex align-items-center" style="margin-top: 30px; margin-bottom: 30px"> |
||||
|
<img src="assets/misc/check-box.png" class="mr-2" /> |
||||
|
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Create Message Templates for Send the Same Content in Multiple Places.</span> |
||||
|
</div> |
||||
|
<div class="d-flex align-items-center" style="margin-top: 30px; margin-bottom: 30px"> |
||||
|
<img src="assets/misc/check-box.png" class="mr-2" /> |
||||
|
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Create Group of Users and Send Messages to Multiple Persons at a Time.</span> |
||||
|
</div> |
||||
|
<div class="d-flex align-items-center" style="margin-top: 30px; margin-bottom: 30px"> |
||||
|
<img src="assets/misc/check-box.png" class="mr-2" /> |
||||
|
<span style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Send Messages can Previously Scheduled</span> |
||||
|
</div> |
||||
|
|
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- END OF FEATURES SECTION --> |
||||
|
|
||||
|
<!-- SCREENSHOTS SECTION --> |
||||
|
<div class="d-flex align-items-center" style="border-bottom: 2px solid #714B67; padding: 15px 0px;" id="screenshots"> |
||||
|
<div class="d-flex justify-content-center align-items-center mr-2" |
||||
|
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;"> |
||||
|
<img src="assets/misc/pictures.png" /> |
||||
|
</div> |
||||
|
<h2 class="mt-2" style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">Screenshots |
||||
|
</h2> |
||||
|
</div> |
||||
|
<div class="row"> |
||||
|
<div class="col-sm-12"> |
||||
|
|
||||
|
<div style="display: block; margin: 30px auto;"> |
||||
|
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;"> Add the details of twilio account connections.</h3> |
||||
|
<p style="font-weight: 400; font-family: 'Montserrat', sans-serif; font-size: 14px;">In twilio module add the account details, Twilio -> Configuration -> Twilio Account</p> |
||||
|
<img src="assets/screenshots/image1.png" class="img-thumbnail"> |
||||
|
</div> |
||||
|
|
||||
|
<div style="display: block; margin: 30px auto;"> |
||||
|
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Create SMS template to select message body when we send SMS.<br/></h3> |
||||
|
<p style="font-weight: 400; font-family: 'Montserrat', sans-serif; font-size: 14px;">In twilio module we can create multiple message templates. Twilio -> Configuration -> Sms Templates </p> |
||||
|
<img src="assets/screenshots/image2.png" class="img-thumbnail"> |
||||
|
</div> |
||||
|
|
||||
|
<div style="display: block; margin: 30px auto;"> |
||||
|
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Create group of users to send SMS bulk |
||||
|
</h3> |
||||
|
<img src="assets/screenshots/image3.png" class="img-thumbnail"> |
||||
|
</div> |
||||
|
<div style="display: block; margin: 30px auto;"> |
||||
|
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Send bulk SMS by selecting group of users and message body.</h3> |
||||
|
<img src="assets/screenshots/image4.png" class="img-thumbnail"> |
||||
|
</div> |
||||
|
|
||||
|
<div style="display: block; margin: 30px auto;"> |
||||
|
<h3 style="font-family: 'Montserrat', sans-serif; font-size: 18px; font-weight: bold;">Send SMS in sale order</h3> |
||||
|
<img src="assets/screenshots/image5.png" class="img-thumbnail"> |
||||
|
</div> |
||||
|
<!-- END OF SCREENSHOTS SECTION --> |
||||
|
|
||||
|
<!-- SUGGESTED PRODUCTS --> |
||||
|
<div class="row"> |
||||
|
<div class="col-lg-12 d-flex flex-column justify-content-center" |
||||
|
style="text-align: center; padding: 2.5rem 1rem !important;"> |
||||
|
<h2 style="color: #212529 !important;">Suggested Products</h2> |
||||
|
<hr |
||||
|
style="border: 3px solid #714B67 !important; background-color: #714B67 !important; width: 80px !important; margin-bottom: 2rem !important;"/> |
||||
|
|
||||
|
<div id="demo1" class="row carousel slide" |
||||
|
data-ride="carousel"> |
||||
|
<!-- The slideshow --> |
||||
|
<div class="carousel-inner"> |
||||
|
<div class="carousel-item active" |
||||
|
style="min-height:0px"> |
||||
|
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" |
||||
|
style="float:left"> |
||||
|
<a href="https://apps.odoo.com/apps/modules/15.0/odoo_zoom_meet_integration/" |
||||
|
target="_blank"> |
||||
|
<div style="border-radius:10px"> |
||||
|
<img class="img img-responsive center-block" |
||||
|
style="border-top-left-radius:10px; border-top-right-radius:10px" |
||||
|
src="./assets/modules/zoom_meet.jpg"> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" |
||||
|
style="float:left"> |
||||
|
<a href="https://apps.odoo.com/apps/modules/15.0/whatsapp_mail_messaging/" |
||||
|
target="_blank"> |
||||
|
<div style="border-radius:10px"> |
||||
|
<img class="img img-responsive center-block" |
||||
|
style="border-top-left-radius:10px; border-top-right-radius:10px" |
||||
|
src="./assets/modules/whatsapp.gif"> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" |
||||
|
style="float:left"> |
||||
|
<a href="https://apps.odoo.com/apps/modules/15.0/recruitment_twitter/" |
||||
|
target="_blank"> |
||||
|
<div style="border-radius:10px"> |
||||
|
<img class="img img-responsive center-block" |
||||
|
style="border-top-left-radius:10px; border-top-right-radius:10px" |
||||
|
src="./assets/modules/twitter.png"> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="carousel-item" style="min-height:0px"> |
||||
|
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" |
||||
|
style="float:left"> |
||||
|
<a href="https://apps.odoo.com/apps/modules/15.0/integration_whatsapp_chat_live/" |
||||
|
target="_blank"> |
||||
|
<div style="border-radius:10px"> |
||||
|
<img class="img img-responsive center-block" |
||||
|
style="border-top-left-radius:10px; border-top-right-radius:10px" |
||||
|
src="./assets/modules/live_chat.png"> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" |
||||
|
style="float:left"> |
||||
|
<a href="https://apps.odoo.com/apps/modules/15.0/odoo_slack_connector/" |
||||
|
target="_blank"> |
||||
|
<div style="border-radius:10px"> |
||||
|
<img class="img img-responsive center-block" |
||||
|
style="border-top-left-radius:10px; border-top-right-radius:10px" |
||||
|
src="./assets/modules/slack.png"> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" |
||||
|
style="float:left"> |
||||
|
<a href="https://apps.odoo.com/apps/modules/15.0/hr_zk_attendance/" |
||||
|
target="_blank"> |
||||
|
<div style="border-radius:10px"> |
||||
|
<img class="img img-responsive center-block" |
||||
|
style="border-top-left-radius:10px; border-top-right-radius:10px" |
||||
|
src="./assets/modules/1.png"> |
||||
|
</div> |
||||
|
</a> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- Left and right controls --> |
||||
|
<a class="carousel-control-prev" href="#demo1" |
||||
|
data-slide="prev" |
||||
|
style="left:-25px;width: 35px;color: #000;"> |
||||
|
<span class="carousel-control-prev-icon"><i |
||||
|
class="fa fa-chevron-left" |
||||
|
style="font-size:24px"></i></span> </a> |
||||
|
<a class="carousel-control-next" href="#demo1" |
||||
|
data-slide="next" |
||||
|
style="right:-25px;width: 35px;color: #000;"> |
||||
|
<span class="carousel-control-next-icon"><i |
||||
|
class="fa fa-chevron-right" |
||||
|
style="font-size:24px"></i></span> |
||||
|
</a> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- END OF SUGGESTED PRODUCTS --> |
||||
|
|
||||
|
<!-- OUR SERVICES --> |
||||
|
|
||||
|
<div class="d-flex align-items-center" style="border-bottom: 2px solid #714B67; padding: 15px 0px;"> |
||||
|
<div class="d-flex justify-content-center align-items-center mr-2" |
||||
|
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;"> |
||||
|
<img src="assets/misc/star.png" /> |
||||
|
</div> |
||||
|
<h2 class="mt-2" style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">Our Services |
||||
|
</h2> |
||||
|
</div> |
||||
|
|
||||
|
<div class="container my-5"> |
||||
|
<div class="row"> |
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #1dd1a1 !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/cogs.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Customization</h6> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #ff6b6b !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/wrench.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Implementation</h6> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #6462CD !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/lifebuoy.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Support</h6> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #ffa801 !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/user.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Hire |
||||
|
Odoo |
||||
|
Developer</h6> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #54a0ff !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/puzzle.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Integration</h6> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #6d7680 !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/update.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Migration</h6> |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #786fa6 !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/consultation.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Consultancy</h6> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #f8a5c2 !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/training.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Implementation</h6> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-4 d-flex flex-column justify-content-center align-items-center my-4"> |
||||
|
<div class="d-flex justify-content-center align-items-center mx-3 my-3" |
||||
|
style="background-color: #e6be26 !important; border-radius: 15px !important; height: 80px; width: 80px;"> |
||||
|
<img src="assets/icons/license.png" class="img-responsive" height="48px" width="48px"> |
||||
|
</div> |
||||
|
<h6 class="text-center" style="font-family: Montserrat, 'sans-serif' !important; font-weight: bold;"> |
||||
|
Odoo |
||||
|
Licensing Consultancy</h6> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
</div> |
||||
|
|
||||
|
<!-- END OF OUR SERVICES --> |
||||
|
|
||||
|
<!-- OUR INDUSTRIES --> |
||||
|
|
||||
|
<div class="d-flex align-items-center" style="border-bottom: 2px solid #714B67; padding: 15px 0px;"> |
||||
|
<div class="d-flex justify-content-center align-items-center mr-2" |
||||
|
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;"> |
||||
|
<img src="assets/misc/corporate.png" /> |
||||
|
</div> |
||||
|
<h2 class="mt-2" style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">Our |
||||
|
Industries |
||||
|
</h2> |
||||
|
</div> |
||||
|
|
||||
|
<div class="container my-5"> |
||||
|
<div class="row"> |
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/trading-black.png" class="img-responsive mb-3" height="48px" width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
Trading |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
Easily procure |
||||
|
and |
||||
|
sell your products</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/pos-black.png" class="img-responsive mb-3" height="48px" width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
POS |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
Easy |
||||
|
configuration |
||||
|
and convivial experience</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/education-black.png" class="img-responsive mb-3" height="48px" width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
Education |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
A platform for |
||||
|
educational management</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/manufacturing-black.png" class="img-responsive mb-3" height="48px" |
||||
|
width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
Manufacturing |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
Plan, track and |
||||
|
schedule your operations</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/ecom-black.png" class="img-responsive mb-3" height="48px" width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
E-commerce & Website |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
Mobile |
||||
|
friendly, |
||||
|
awe-inspiring product pages</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/service-black.png" class="img-responsive mb-3" height="48px" width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
Service Management |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
Keep track of |
||||
|
services and invoice</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/restaurant-black.png" class="img-responsive mb-3" height="48px" width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
Restaurant |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
Run your bar or |
||||
|
restaurant methodically</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<div class="col-lg-3"> |
||||
|
<div class="my-4 d-flex flex-column justify-content-center" |
||||
|
style="background-color: #f6f8f9 !important; border-radius: 0px; padding: 2rem !important; height: 250px !important;"> |
||||
|
<img src="assets/icons/hotel-black.png" class="img-responsive mb-3" height="48px" width="48px"> |
||||
|
<h5 style="font-family: Montserrat, sans-serif !important; color: #000 !important; font-weight: bold;"> |
||||
|
Hotel Management |
||||
|
</h5> |
||||
|
<p style="font-family: Montserrat, sans-serif !important; font-size: 0.9rem !important;"> |
||||
|
An |
||||
|
all-inclusive |
||||
|
hotel management application</p> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
|
||||
|
<!-- END OF OUR INDUSTRIES --> |
||||
|
|
||||
|
<!-- SUPPORT --> |
||||
|
<div class="d-flex align-items-center" style="border-bottom: 2px solid #714B67; padding: 15px 0px;"> |
||||
|
<div class="d-flex justify-content-center align-items-center mr-2" |
||||
|
style="background-color: #F5F5F5; border-radius: 0px; width: 40px; height: 40px;"> |
||||
|
<img src="assets/misc/customer-support.png" /> |
||||
|
</div> |
||||
|
<h2 class="mt-2" style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">Support |
||||
|
</h2> |
||||
|
</div> |
||||
|
<div class="container mt-5"> |
||||
|
<div class="row"> |
||||
|
<div class="col-sm-12 col-md-6"> |
||||
|
<div style="background-color: #F6F8F9; padding: 30px; display: flex; align-items: center;"> |
||||
|
<div class="mr-4" |
||||
|
style="background-color: #714B67; display: inline-block; height: 70px; width: 70px; display: flex; align-items: center; justify-content: center;"> |
||||
|
<img src="assets/misc/support.png" height="48" width="48" style="width: 42px; height: 42px;" /> |
||||
|
</div> |
||||
|
<div> |
||||
|
<h4>Need Help?</h4> |
||||
|
<p style="line-height: 100%;">Got questions or need help? Get in touch.</p> |
||||
|
<a href="mailto:odoo@cybrosys.com"> |
||||
|
<p style="font-weight: 400; font-size: 28px; line-height: 80%; color: #714B67;"> |
||||
|
odoo@cybrosys.com</p> |
||||
|
</a> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="col-sm-12 col-md-6"> |
||||
|
<div style="background-color: #F6F8F9; padding: 30px; display: flex; align-items: center;"> |
||||
|
<div class="mr-4" |
||||
|
style="background-color: #2AC44D; display: inline-block; height: 70px; width: 70px; display: flex; align-items: center; justify-content: center;"> |
||||
|
<img src="assets/misc/whatsapp.png" height="52" width="52" style="width: 52px; height: 52px;" /> |
||||
|
</div> |
||||
|
<div> |
||||
|
<h4>WhatsApp</h4> |
||||
|
<p style="line-height: 100%;">Say hi to us on WhatsApp!</p> |
||||
|
<a href="https://api.whatsapp.com/send?phone=918606827707"> |
||||
|
<p style="font-weight: 400; font-size: 28px; line-height: 80%; color: #714B67;">+91 86068 |
||||
|
27707</p> |
||||
|
</a> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="row"> |
||||
|
<div class="col-sm-12 my-5 d-flex justify-content-center align-items-center"> |
||||
|
<img src="assets/misc/logo.png" width="144" height="31" |
||||
|
style="width:144px; height: 31px; margin-top: 40px;" /> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- END OF SUPPORT --> |
||||
|
</div> |
||||
|
</div> |
@ -0,0 +1,17 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- This XML defines a customization in Odoo to add a button for sending |
||||
|
SMS via Twilio in the purchase order form. --> |
||||
|
<record id="purchase_order_form" model="ir.ui.view"> |
||||
|
<field name="name">purchase.order.view.form.inherit.odoo.twilio.sms |
||||
|
</field> |
||||
|
<field name="model">purchase.order</field> |
||||
|
<field name="inherit_id" ref="purchase.purchase_order_form"/> |
||||
|
<field name="arch" type="xml"> |
||||
|
<xpath expr="//button[@name='action_rfq_send']" position="after"> |
||||
|
<button name="action_purchase_twilio_sms" type="object" |
||||
|
string="Twilio Send SmS"/> |
||||
|
</xpath> |
||||
|
</field> |
||||
|
</record> |
||||
|
</odoo> |
@ -0,0 +1,17 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- This XML defines a customization in Odoo to add a button for sending |
||||
|
SMS via Twilio in the sale order form. --> |
||||
|
<record id="view_order_form" model="ir.ui.view"> |
||||
|
<field name="name">sale.order.view.form.inherit.odoo.twilio.sms</field> |
||||
|
<field name="model">sale.order</field> |
||||
|
<field name="inherit_id" ref="sale.view_order_form"/> |
||||
|
<field name="arch" type="xml"> |
||||
|
<xpath expr="//button[@name='action_quotation_send']" |
||||
|
position="after"> |
||||
|
<button name="action_twilio_sms" type="object" |
||||
|
string="Twilio Send SmS"/> |
||||
|
</xpath> |
||||
|
</field> |
||||
|
</record> |
||||
|
</odoo> |
@ -0,0 +1,79 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- This XML defines views and actions related to Twilio account configuration in Odoo. --> |
||||
|
<record id="twilio_account_view_form" model="ir.ui.view"> |
||||
|
<field name="name">twilio.account.view.form</field> |
||||
|
<field name="model">twilio.account</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<form> |
||||
|
<!-- State --> |
||||
|
<header> |
||||
|
<button id="test_connection" name="action_test_connection" |
||||
|
string="TEST CONNECTION" class="btn-primary" |
||||
|
type="object" |
||||
|
attrs="{'invisible': [('state','!=','new')]}"/> |
||||
|
<field name="state" widget="statusbar"/> |
||||
|
</header> |
||||
|
<sheet> |
||||
|
<div class="oe_title"> |
||||
|
<label for="name" string="Name"/> |
||||
|
<h1> |
||||
|
<div class="d-flex"> |
||||
|
<field class="text-break" name="name"/> |
||||
|
</div> |
||||
|
</h1> |
||||
|
</div> |
||||
|
<group> |
||||
|
<group> |
||||
|
<field name="account_sid" password="True"/> |
||||
|
<field name="auth_token" password="True"/> |
||||
|
</group> |
||||
|
<group> |
||||
|
<field name="from_number"/> |
||||
|
<field name="to_number"/> |
||||
|
<field name="body"/> |
||||
|
</group> |
||||
|
</group> |
||||
|
</sheet> |
||||
|
</form> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- View for Twilio account tree --> |
||||
|
<record id="twilio_account_view_tree" model="ir.ui.view"> |
||||
|
<field name="name">twilio.account.view.tree</field> |
||||
|
<field name="model">twilio.account</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<tree name="twilio_tree"> |
||||
|
<field name="name"/> |
||||
|
<field name="account_sid"/> |
||||
|
<field name="auth_token"/> |
||||
|
<field name="from_number"/> |
||||
|
<field name="state" widget="badge" |
||||
|
decoration-info="state == 'draft'" |
||||
|
decoration-success="state == 'confirm'"/> |
||||
|
</tree> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Action for Twilio account window --> |
||||
|
<record id="twilio_account_action" model="ir.actions.act_window"> |
||||
|
<field name="name">Twilio Account</field> |
||||
|
<field name="type">ir.actions.act_window</field> |
||||
|
<field name="res_model">twilio.account</field> |
||||
|
<field name="view_mode">tree,form</field> |
||||
|
<field name="help" type="html"> |
||||
|
<p class="o_view_nocontent_smiling_face"> |
||||
|
Generate Account Details |
||||
|
</p> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Main menu --> |
||||
|
<menuitem id="twilio_account_menu_root" name="Twilio" sequence="2"/> |
||||
|
<!-- Sub menu --> |
||||
|
<menuitem id="twilio_account_menu_do_stuff" name="Configuration" |
||||
|
parent="twilio_account_menu_root" sequence="2"/> |
||||
|
<!-- Configuration --> |
||||
|
<menuitem id="twilio_account_menu" name="Twilio Account" |
||||
|
parent="twilio_account_menu_do_stuff" |
||||
|
action="twilio_account_action" |
||||
|
sequence="4"/> |
||||
|
</odoo> |
@ -0,0 +1,57 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- This XML defines views and actions related to Twilio SMS groups in Odoo. --> |
||||
|
<record id="twilio_sms_group_view_form" model="ir.ui.view"> |
||||
|
<field name="name">twilio.sms.group.view.form</field> |
||||
|
<field name="model">twilio.sms.group</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<form name="Contacts"> |
||||
|
<!-- State --> |
||||
|
<sheet> |
||||
|
<div class="oe_title"> |
||||
|
<label for="name" string="Name"/> |
||||
|
<h1> |
||||
|
<div class="d-flex"> |
||||
|
<field class="text-break" name="name"/> |
||||
|
</div> |
||||
|
</h1> |
||||
|
</div> |
||||
|
<field name="contact_ids" widget="many2many" mode="tree"> |
||||
|
<tree editable="bottom"> |
||||
|
<field name="name"/> |
||||
|
<field name="phone"/> |
||||
|
<field name="twilio_sms_id" invisible="1"/> |
||||
|
</tree> |
||||
|
</field> |
||||
|
</sheet> |
||||
|
</form> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- View for Twilio SMS group tree --> |
||||
|
<record id="twilio_sms_group_view_tree" model="ir.ui.view"> |
||||
|
<field name="name">twilio.sms.group.view.tree</field> |
||||
|
<field name="model">twilio.sms.group</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<tree name="twilio_contact_tree"> |
||||
|
<field name="name"/> |
||||
|
</tree> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Action for Twilio SMS group window --> |
||||
|
<record id="twilio_sms_group_action" model="ir.actions.act_window"> |
||||
|
<field name="name">Template</field> |
||||
|
<field name="type">ir.actions.act_window</field> |
||||
|
<field name="res_model">twilio.sms.group</field> |
||||
|
<field name="view_mode">tree,form</field> |
||||
|
<field name="help" type="html"> |
||||
|
<p class="o_view_nocontent_smiling_face"> |
||||
|
Generate Account Details |
||||
|
</p> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Menu item for Twilio SMS groups --> |
||||
|
<menuitem id="twilio_sms_group_menu" name="Contact Group" |
||||
|
parent="twilio_account_menu_do_stuff" |
||||
|
action="twilio_sms_group_action" |
||||
|
sequence="7"/> |
||||
|
</odoo> |
@ -0,0 +1,15 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- Form View to send sms from res.partner --> |
||||
|
<record id="action_twilio_sms_interaction" model="ir.actions.act_window"> |
||||
|
<field name="name">Twilio SMS</field> |
||||
|
<field name="res_model">twilio.sms.interaction</field> |
||||
|
<field name="view_mode">form</field> |
||||
|
<field name="target">new</field> |
||||
|
<field name="context">{ |
||||
|
'default_partner_id': active_id, |
||||
|
}</field> |
||||
|
<field name="binding_model_id" ref="base.model_res_partner"/> |
||||
|
<field name="binding_view_types">form</field> |
||||
|
</record> |
||||
|
</odoo> |
@ -0,0 +1,55 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- This XML defines views and actions related to Twilio SMS templates in Odoo. --> |
||||
|
<record id="twilio_sms_template_view_form" model="ir.ui.view"> |
||||
|
<field name="name">twilio.sms.template.view.form</field> |
||||
|
<field name="model">twilio.sms.template</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<form> |
||||
|
<sheet> |
||||
|
<div class="oe_title"> |
||||
|
<label for="name" string="Name"/> |
||||
|
<h1> |
||||
|
<div class="d-flex"> |
||||
|
<field class="text-break" name="name"/> |
||||
|
</div> |
||||
|
</h1> |
||||
|
</div> |
||||
|
<group> |
||||
|
<group> |
||||
|
<field name="content"/> |
||||
|
</group> |
||||
|
</group> |
||||
|
</sheet> |
||||
|
</form> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- View for Twilio SMS template tree --> |
||||
|
<record id="twilio_sms_template_view_tree" model="ir.ui.view"> |
||||
|
<field name="name">twilio.sms.template.view.tree</field> |
||||
|
<field name="model">twilio.sms.template</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<tree name="twilio_template_tree"> |
||||
|
<field name="name"/> |
||||
|
<field name="content"/> |
||||
|
</tree> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Action for Twilio SMS template window --> |
||||
|
<record id="twilio_sms_template_action" model="ir.actions.act_window"> |
||||
|
<field name="name">SmS Template</field> |
||||
|
<field name="type">ir.actions.act_window</field> |
||||
|
<field name="res_model">twilio.sms.template</field> |
||||
|
<field name="view_mode">tree,form</field> |
||||
|
<field name="help" type="html"> |
||||
|
<p class="o_view_nocontent_smiling_face"> |
||||
|
Generate Account Details |
||||
|
</p> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Menu item for Twilio SMS templates --> |
||||
|
<menuitem id="twilio_sms_template_menu" name="SmS Template" |
||||
|
parent="twilio_account_menu_do_stuff" |
||||
|
action="twilio_sms_template_action" |
||||
|
sequence="5"/> |
||||
|
</odoo> |
@ -0,0 +1,70 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- This XML defines views and actions related to Twilio SMS messages in Odoo. --> |
||||
|
<record id="twilio_sms_view_form" model="ir.ui.view"> |
||||
|
<field name="name">twilio.sms.view.form</field> |
||||
|
<field name="model">twilio.sms</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<form> |
||||
|
<header> |
||||
|
<button id="confirm_sms" name="action_confirm_sms" |
||||
|
string="Send" class="btn-primary" |
||||
|
type="object"/> |
||||
|
<field name="state" widget="statusbar"/> |
||||
|
</header> |
||||
|
<sheet> |
||||
|
<div class="oe_title"> |
||||
|
<label for="name" string="Name"/> |
||||
|
<h1> |
||||
|
<div class="d-flex"> |
||||
|
<field class="text-break" name="name"/> |
||||
|
</div> |
||||
|
</h1> |
||||
|
</div> |
||||
|
<group> |
||||
|
<group> |
||||
|
<field name="partner_id"/> |
||||
|
<field name="template_body_id"/> |
||||
|
</group> |
||||
|
<group> |
||||
|
<field name="content"/> |
||||
|
<field name="scheduled_date"/> |
||||
|
</group> |
||||
|
</group> |
||||
|
</sheet> |
||||
|
</form> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- View for Twilio SMS tree --> |
||||
|
<record id="twilio_sms_view_tree" model="ir.ui.view"> |
||||
|
<field name="name">twilio.sms.view.list</field> |
||||
|
<field name="model">twilio.sms</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<tree> |
||||
|
<field name="name"/> |
||||
|
<field name="partner_id"/> |
||||
|
<field name="content"/> |
||||
|
<field name="scheduled_date"/> |
||||
|
</tree> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Action for Twilio SMS window --> |
||||
|
<record id="twilio_sms_action" model="ir.actions.act_window"> |
||||
|
<field name="name">Twilio SmS</field> |
||||
|
<field name="type">ir.actions.act_window</field> |
||||
|
<field name="res_model">twilio.sms</field> |
||||
|
<field name="view_mode">tree,form</field> |
||||
|
<field name="help" type="html"> |
||||
|
<p class="o_view_nocontent_smiling_face"> |
||||
|
Generate Account Details |
||||
|
</p> |
||||
|
</field> |
||||
|
</record> |
||||
|
<!-- Sub menu --> |
||||
|
<menuitem id="twilio_sms_menu_do_stuff" name="Twilio SmS" |
||||
|
parent="twilio_account_menu_root" sequence="1"/> |
||||
|
<!-- Configuration --> |
||||
|
<menuitem id="twilio_sms_menu" name="SmS" parent="twilio_sms_menu_do_stuff" |
||||
|
action="twilio_sms_action" |
||||
|
sequence="4"/> |
||||
|
</odoo> |
@ -0,0 +1,21 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
################################################################################ |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>). |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
################################################################################ |
||||
|
from . import twilio_sms_interaction |
@ -0,0 +1,84 @@ |
|||||
|
# -*- coding: utf-8 -*- |
||||
|
################################################################################ |
||||
|
# |
||||
|
# Cybrosys Technologies Pvt. Ltd. |
||||
|
# |
||||
|
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>). |
||||
|
# Author: Busthana Shirin (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 <http://www.gnu.org/licenses/>. |
||||
|
################################################################################ |
||||
|
from twilio.rest import Client |
||||
|
from odoo import api, fields, models, _ |
||||
|
|
||||
|
|
||||
|
class TwilioSmsInteraction(models.TransientModel): |
||||
|
""" Class to handle all the functions required in send sms """ |
||||
|
_name = 'twilio.sms.interaction' |
||||
|
_description = 'Twilio SmS Interaction' |
||||
|
|
||||
|
partner_id = fields.Many2one('res.partner', string='Recipient', |
||||
|
help='Receiving User') |
||||
|
receiving_number = fields.Char(string='Receiving Number', |
||||
|
help='Receiving Number', |
||||
|
required=True, readonly=False, |
||||
|
related='partner_id.phone') |
||||
|
template_id = fields.Many2one('twilio.sms.template', |
||||
|
string='Select Template', |
||||
|
help='Message Template') |
||||
|
text_message = fields.Text(string='Message', help='Message Content', |
||||
|
required=True) |
||||
|
|
||||
|
@api.onchange('template_id') |
||||
|
def onchange_template_id(self): |
||||
|
"""Add content when select the template""" |
||||
|
if self.template_id: |
||||
|
self.text_message = self.template_id.content |
||||
|
|
||||
|
def action_confirm_sms(self): |
||||
|
"""Send sms to the corresponding user by using the twilio connection""" |
||||
|
server = self.env['twilio.account'].search([('state', '=', 'confirm')], |
||||
|
limit=1) |
||||
|
try: |
||||
|
client = Client(server.account_sid, server.auth_token) |
||||
|
message = client.messages.create( |
||||
|
body=self.text_message, |
||||
|
from_=server.from_number, |
||||
|
to=self.receiving_number |
||||
|
) |
||||
|
if message.sid: |
||||
|
message_data = _("Message Sent!") |
||||
|
type_data = 'success' |
||||
|
else: |
||||
|
message_data = _("Message Not Sent!") |
||||
|
type_data = 'warning' |
||||
|
return { |
||||
|
'type': 'ir.actions.client', |
||||
|
'tag': 'display_notification', |
||||
|
'params': { |
||||
|
'message': message_data, |
||||
|
'type': type_data, |
||||
|
'sticky': True, |
||||
|
} |
||||
|
} |
||||
|
except: |
||||
|
return { |
||||
|
'type': 'ir.actions.client', |
||||
|
'tag': 'display_notification', |
||||
|
'params': { |
||||
|
'message': _("Message Not Sent!"), |
||||
|
'type': 'warning', |
||||
|
'sticky': True, |
||||
|
} |
||||
|
} |
||||
|
pass |
@ -0,0 +1,29 @@ |
|||||
|
<?xml version="1.0" encoding="utf-8"?> |
||||
|
<odoo> |
||||
|
<!-- This XML defines a form view for interacting with Twilio SMS messages in Odoo. --> |
||||
|
<record id="twilio_sms_interaction_view_form" model="ir.ui.view"> |
||||
|
<field name="name">twilio.sms.interaction.view.form</field> |
||||
|
<field name="model">twilio.sms.interaction</field> |
||||
|
<field name="type">form</field> |
||||
|
<field name="arch" type="xml"> |
||||
|
<form name="Message Content"> |
||||
|
<group> |
||||
|
<group> |
||||
|
<field name="partner_id"/> |
||||
|
<field name="template_id"/> |
||||
|
</group> |
||||
|
<group> |
||||
|
<field name="receiving_number"/> |
||||
|
<field name="text_message" widget="sms_widget"/> |
||||
|
</group> |
||||
|
</group> |
||||
|
<footer> |
||||
|
<button name="action_confirm_sms" type="object" |
||||
|
string="Confirm" class="btn-primary" |
||||
|
data-hotkey="q"/> |
||||
|
<button special="cancel" data-hotkey="z" string="Cancel"/> |
||||
|
</footer> |
||||
|
</form> |
||||
|
</field> |
||||
|
</record> |
||||
|
</odoo> |