Browse Source

Jan 01 [ADD] : Initial Commit 'signup_with_twilio'

pull/254/merge
AjmalCybro 4 months ago
parent
commit
c27f5ddc61
  1. 47
      signup_with_twilio/README.rst
  2. 23
      signup_with_twilio/__init__.py
  3. 53
      signup_with_twilio/__manifest__.py
  4. 22
      signup_with_twilio/controllers/__init__.py
  5. 113
      signup_with_twilio/controllers/signup_with_twilio.py
  6. 6
      signup_with_twilio/doc/RELEASE_NOTES.md
  7. 22
      signup_with_twilio/models/__init__.py
  8. 32
      signup_with_twilio/models/res_config_settings.py
  9. BIN
      signup_with_twilio/static/description/assets/icons/check.png
  10. BIN
      signup_with_twilio/static/description/assets/icons/chevron.png
  11. BIN
      signup_with_twilio/static/description/assets/icons/cogs.png
  12. BIN
      signup_with_twilio/static/description/assets/icons/consultation.png
  13. BIN
      signup_with_twilio/static/description/assets/icons/ecom-black.png
  14. BIN
      signup_with_twilio/static/description/assets/icons/education-black.png
  15. BIN
      signup_with_twilio/static/description/assets/icons/hotel-black.png
  16. BIN
      signup_with_twilio/static/description/assets/icons/license.png
  17. BIN
      signup_with_twilio/static/description/assets/icons/lifebuoy.png
  18. BIN
      signup_with_twilio/static/description/assets/icons/manufacturing-black.png
  19. BIN
      signup_with_twilio/static/description/assets/icons/pos-black.png
  20. BIN
      signup_with_twilio/static/description/assets/icons/puzzle.png
  21. BIN
      signup_with_twilio/static/description/assets/icons/restaurant-black.png
  22. BIN
      signup_with_twilio/static/description/assets/icons/service-black.png
  23. BIN
      signup_with_twilio/static/description/assets/icons/trading-black.png
  24. BIN
      signup_with_twilio/static/description/assets/icons/training.png
  25. BIN
      signup_with_twilio/static/description/assets/icons/update.png
  26. BIN
      signup_with_twilio/static/description/assets/icons/user.png
  27. BIN
      signup_with_twilio/static/description/assets/icons/wrench.png
  28. BIN
      signup_with_twilio/static/description/assets/misc/categories.png
  29. BIN
      signup_with_twilio/static/description/assets/misc/check-box.png
  30. BIN
      signup_with_twilio/static/description/assets/misc/compass.png
  31. BIN
      signup_with_twilio/static/description/assets/misc/corporate.png
  32. BIN
      signup_with_twilio/static/description/assets/misc/customer-support.png
  33. BIN
      signup_with_twilio/static/description/assets/misc/cybrosys-logo.png
  34. BIN
      signup_with_twilio/static/description/assets/misc/features.png
  35. BIN
      signup_with_twilio/static/description/assets/misc/logo.png
  36. BIN
      signup_with_twilio/static/description/assets/misc/pictures.png
  37. BIN
      signup_with_twilio/static/description/assets/misc/pie-chart.png
  38. BIN
      signup_with_twilio/static/description/assets/misc/right-arrow.png
  39. BIN
      signup_with_twilio/static/description/assets/misc/star.png
  40. BIN
      signup_with_twilio/static/description/assets/misc/support.png
  41. BIN
      signup_with_twilio/static/description/assets/misc/whatsapp.png
  42. BIN
      signup_with_twilio/static/description/assets/modules/budget_image.png
  43. BIN
      signup_with_twilio/static/description/assets/modules/credit_image.png
  44. BIN
      signup_with_twilio/static/description/assets/modules/employee_image.png
  45. BIN
      signup_with_twilio/static/description/assets/modules/export_image.png
  46. BIN
      signup_with_twilio/static/description/assets/modules/gantt_image.png
  47. BIN
      signup_with_twilio/static/description/assets/modules/quotation_image.png
  48. BIN
      signup_with_twilio/static/description/assets/screenshots/1.png
  49. BIN
      signup_with_twilio/static/description/assets/screenshots/2.png
  50. BIN
      signup_with_twilio/static/description/assets/screenshots/3.png
  51. BIN
      signup_with_twilio/static/description/assets/screenshots/4.png
  52. BIN
      signup_with_twilio/static/description/assets/screenshots/5.png
  53. BIN
      signup_with_twilio/static/description/assets/screenshots/6.png
  54. BIN
      signup_with_twilio/static/description/assets/screenshots/7.png
  55. BIN
      signup_with_twilio/static/description/assets/screenshots/8.png
  56. BIN
      signup_with_twilio/static/description/assets/screenshots/hero.gif
  57. BIN
      signup_with_twilio/static/description/banner.png
  58. BIN
      signup_with_twilio/static/description/icon.png
  59. 627
      signup_with_twilio/static/description/index.html
  60. 36
      signup_with_twilio/static/src/css/signup.css
  61. 58
      signup_with_twilio/static/src/js/signup.js
  62. 21
      signup_with_twilio/views/res_config_setting_views.xml
  63. 142
      signup_with_twilio/views/signup_templates.xml

47
signup_with_twilio/README.rst

@ -0,0 +1,47 @@
.. image:: https://img.shields.io/badge/license-LGPL--3-green.svg
:target: https://www.gnu.org/licenses/lgpl-3.0-standalone.html
:alt: License: LGPL-3
SignUp With Mobile
==================
* This module allow to Signup with Mobile Number
Configuration
=============
- Before installing this module please ensure that 'twilio' package is installed.
- Installation code: pip install twilio
License
-------
General Public License, Version 3 (LGPL v3).
(https://www.gnu.org/licenses/lgpl-3.0-standalone.html)
Company
-------
* 'Cybrosys Techno Solutions <https://cybrosys.com/>`
Credits
-------
* Developer: (V15) Afra MP, 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>`__

23
signup_with_twilio/__init__.py

@ -0,0 +1,23 @@
# -*- coding: utf-8 -*-
#############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
#############################################################################
from . import controllers
from . import models

53
signup_with_twilio/__manifest__.py

@ -0,0 +1,53 @@
# -*- coding: utf-8 -*-
#############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
#############################################################################
{
'name': 'SignUp With Mobile',
'version': '15.0.1.0.0',
'category': 'Extra Tools',
'summary': 'A Module For SignUp With Mobile Number.',
'description': """Module helps users sign up using their mobile number and
verify it with a one-time password (OTP) by Twilio.Additionally, the
option to sign up with an email ID is also available""",
'author': 'Cybrosys Techno Solutions',
'company': 'Cybrosys Techno Solutions',
'maintainer': 'Cybrosys Techno Solutions',
'website': 'https://www.cybrosys.com',
'depends': ['auth_signup'],
'data': [
'views/res_config_setting_views.xml',
'views/signup_templates.xml',
],
'assets': {
'web.assets_frontend': [
'signup_with_twilio/static/src/css/signup.css',
'signup_with_twilio/static/src/js/signup.js'
],
},
'external_dependencies': {
'python': ['twilio']
},
'images': ['static/description/banner.png'],
'license': 'LGPL-3',
'installable': True,
'auto_install': False,
'application': False,
}

22
signup_with_twilio/controllers/__init__.py

@ -0,0 +1,22 @@
# -*- coding: utf-8 -*-
#############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
#############################################################################
from . import signup_with_twilio

113
signup_with_twilio/controllers/signup_with_twilio.py

@ -0,0 +1,113 @@
# -*- coding: utf-8 -*-
#############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
#############################################################################
import logging
import werkzeug
import werkzeug.exceptions
import werkzeug.utils
import werkzeug.wrappers
import werkzeug.wsgi
from twilio.rest import Client
from odoo import http, _
from odoo.addons.web.controllers.main import Home
from odoo.http import request
from odoo.exceptions import UserError
from odoo.addons.mail.tools.credentials import get_twilio_credentials
from odoo.addons.auth_signup.models.res_users import SignupError
_logger = logging.getLogger(__name__)
class AuthSignupHome(Home):
"""Uses to signup with mobile number and
login with the same mobile number"""
@http.route('/web/signup-mobile', type='http', auth='public',
website=True, sitemap=False)
def web_auth_signup_mobile(self, *args, **kw):
"""Create new user with mobile number"""
qcontext = self.get_auth_signup_qcontext()
if kw.get('country_code') and kw.get('login_mobile'):
qcontext.update({'login': kw.get('country_code') + kw.get(
'login_mobile')})
kw.update({'login': kw.get('country_code') + kw.get(
'login_mobile')})
if not qcontext.get('token') and not qcontext.get('signup_enabled'):
raise werkzeug.exceptions.NotFound()
if 'error' not in qcontext and request.httprequest.method == 'POST':
try:
self.do_signup(qcontext)
user = request.env['res.users'].sudo().search(
[('login', '=', qcontext['login'])])
if user.partner_id and kw.get('signup_mobile'):
user.partner_id.update({'email': ''})
user.partner_id.update({'phone': qcontext['login']})
return self.web_login(*args, **kw)
except UserError as e:
qcontext['error'] = e.args[0]
except (SignupError, AssertionError) as e:
if request.env["res.users"].sudo().search(
[("login", "=", qcontext.get("login"))]):
qcontext["error"] = _(
"Another user is already registered "
"using this Mobile Number.")
else:
_logger.error("%s", e)
qcontext['error'] = _("Could not create a new account.")
response = request.render('signup_with_twilio.signup_mobile', qcontext)
response.headers['X-Frame-Options'] = 'SAME ORIGIN'
response.headers['Content-Security-Policy'] = "frame-ancestors 'self'"
return response
@http.route('/web/login', type='http', auth="none")
def web_login(self, redirect=None, **kw):
"""Update the parameters to login with mobile Number"""
request.params.update({'login': kw.get('login')})
return super(AuthSignupHome, self).web_login(redirect=None, **kw)
@http.route('/web/send_otp', auth='public', type='json')
def web_send_otp(self, **kw):
"""Sent OTP through SMS to the given number using twilio"""
(account_sid, auth_token) = get_twilio_credentials(request.env)
from_number = request.env['ir.config_parameter'].sudo().get_param(
'signup_with_twilio.twilio_from_number')
if not account_sid or not auth_token or not from_number:
raise UserError(_('Twilio Credential are Required'))
client = Client(account_sid, auth_token)
message = client.messages.create(
to='+' + kw.get('country_code') + kw.get('mobile'),
from_=from_number,
body='Your Odoo verification code is:' + str(kw.get('otp')) +
'.OTP valid till 2 minutes.'
)
_logger.info('Message successfully sent to your mobie number: %s',
message.sid)
@http.route('/web/reset_password', type='http', auth='public',
website=True, sitemap=False)
def web_auth_reset_password(self, *args, **kw):
"""Update the email in user email field"""
if kw.get('login-mail'):
user = request.env['res.users'].sudo().search(
[('login', '=', kw.get('login'))])
if user:
user.email = kw.get('login-mail')
return super(AuthSignupHome, self).web_auth_reset_password(args, **kw)

6
signup_with_twilio/doc/RELEASE_NOTES.md

@ -0,0 +1,6 @@
## Module <signup_with_twilio>
#### 11.06.2024
#### Version 15.0.1.0.0
##### ADD
- Initial Commit for SignUp With Mobile

22
signup_with_twilio/models/__init__.py

@ -0,0 +1,22 @@
# -*- coding: utf-8 -*-
#############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
#############################################################################
from . import res_config_settings

32
signup_with_twilio/models/res_config_settings.py

@ -0,0 +1,32 @@
# -*- coding: utf-8 -*-
#############################################################################
#
# Cybrosys Technologies Pvt. Ltd.
#
# Copyright (C) 2023-TODAY Cybrosys Technologies(<https://www.cybrosys.com>)
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>)
#
# You can modify it under the terms of the GNU LESSER
# GENERAL PUBLIC LICENSE (LGPL 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 LESSER GENERAL PUBLIC LICENSE (LGPL v3) for more details.
#
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE
# (LGPL v3) along with this program.
# If not, see <http://www.gnu.org/licenses/>.
#
#############################################################################
from odoo import fields, models
class ResConfigSettings(models.TransientModel):
""" Inherit the base settings to add a twilio from number """
_inherit = 'res.config.settings'
twilio_from_number = fields.Char('Twilio From Number',
help="From number which used to send sms "
"from the number",
config_parameter='signup_with_twilio.twilio_from_number')

BIN
signup_with_twilio/static/description/assets/icons/check.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

BIN
signup_with_twilio/static/description/assets/icons/chevron.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 310 B

BIN
signup_with_twilio/static/description/assets/icons/cogs.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
signup_with_twilio/static/description/assets/icons/consultation.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

BIN
signup_with_twilio/static/description/assets/icons/ecom-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 576 B

BIN
signup_with_twilio/static/description/assets/icons/education-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 733 B

BIN
signup_with_twilio/static/description/assets/icons/hotel-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 911 B

BIN
signup_with_twilio/static/description/assets/icons/license.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
signup_with_twilio/static/description/assets/icons/lifebuoy.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
signup_with_twilio/static/description/assets/icons/manufacturing-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 673 B

BIN
signup_with_twilio/static/description/assets/icons/pos-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 878 B

BIN
signup_with_twilio/static/description/assets/icons/puzzle.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 653 B

BIN
signup_with_twilio/static/description/assets/icons/restaurant-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 905 B

BIN
signup_with_twilio/static/description/assets/icons/service-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 839 B

BIN
signup_with_twilio/static/description/assets/icons/trading-black.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 427 B

BIN
signup_with_twilio/static/description/assets/icons/training.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 627 B

BIN
signup_with_twilio/static/description/assets/icons/update.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
signup_with_twilio/static/description/assets/icons/user.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 988 B

BIN
signup_with_twilio/static/description/assets/icons/wrench.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
signup_with_twilio/static/description/assets/misc/categories.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
signup_with_twilio/static/description/assets/misc/check-box.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
signup_with_twilio/static/description/assets/misc/compass.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

BIN
signup_with_twilio/static/description/assets/misc/corporate.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
signup_with_twilio/static/description/assets/misc/customer-support.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

BIN
signup_with_twilio/static/description/assets/misc/cybrosys-logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

BIN
signup_with_twilio/static/description/assets/misc/features.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 589 B

BIN
signup_with_twilio/static/description/assets/misc/logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

BIN
signup_with_twilio/static/description/assets/misc/pictures.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
signup_with_twilio/static/description/assets/misc/pie-chart.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

BIN
signup_with_twilio/static/description/assets/misc/right-arrow.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 967 B

BIN
signup_with_twilio/static/description/assets/misc/star.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
signup_with_twilio/static/description/assets/misc/support.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

BIN
signup_with_twilio/static/description/assets/misc/whatsapp.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.0 KiB

BIN
signup_with_twilio/static/description/assets/modules/budget_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

BIN
signup_with_twilio/static/description/assets/modules/credit_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

BIN
signup_with_twilio/static/description/assets/modules/employee_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

BIN
signup_with_twilio/static/description/assets/modules/export_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

BIN
signup_with_twilio/static/description/assets/modules/gantt_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

BIN
signup_with_twilio/static/description/assets/modules/quotation_image.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/1.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 228 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/2.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 137 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/3.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 132 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/4.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 126 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/5.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 127 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/6.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 131 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/7.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 140 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/8.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 133 KiB

BIN
signup_with_twilio/static/description/assets/screenshots/hero.gif

Binary file not shown.

After

Width:  |  Height:  |  Size: 252 KiB

BIN
signup_with_twilio/static/description/banner.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

BIN
signup_with_twilio/static/description/icon.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

627
signup_with_twilio/static/description/index.html

@ -0,0 +1,627 @@
<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
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>Odoo.sh
</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;">
SignUp With Mobile
</h1>
<p style="color:#FFFFFF; padding: 8px 15px; text-align: center; font-size: 24px;">User Can SignUp With Mobile Number.</p>
<!-- END OF APP HERO -->
<img src="assets/screenshots/hero.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 for 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">
User can signup with mobile or email ID, if user signing up with mobile should verify their mobile number also.
</div>
</div>
<!-- END OF OVERVIEW SECTION -->
<!-- CONFIGURATION -->
<div class="d-flex align-items-center"
style="border-bottom: 2px solid #714B67; padding: 15px 0px;"
id="configuration">
<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;">
Configuration
</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"/>
<div class="row"
style="font-family: 'Montserrat', sans-serif; font-weight: 400; font-size: 14px; line-height: 200%;">
<div class="col py-4">
For the proper working of this module, please ensure that
the Packages are installed before the installation of this
module
<li><b><i>twilio</i></b> - pip install twilio</li>
</div>
</div>
</div>
</div>
</div>
<!-- END OF CONFIGURATION 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: 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;">User Can signup with mobile number.</span>
</div>
</div>
<div class="col-sm-12 col-md-6">
<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;">Signup with Email ID also possible.</span>
</div>
</div>
<div class="col-sm-12 col-md-6">
<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;">Mobile number should verify by otp for safety.</span>
</div>
</div>
<div class="col-sm-12 col-md-6">
<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;">Available in both community and enterprise.</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;">Twilio Configuration</h3>
<p style="font-weight: 400; font-family: 'Montserrat', sans-serif; font-size: 14px;">Create an Account in Twilio and Create from number which provided by Twilio.</p>
<img src="assets/screenshots/1.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<p style="font-weight: 400; font-family: 'Montserrat', sans-serif; font-size: 14px;">Update the Credentials in Odoo Settings > Twilio.
</p>
<img src="assets/screenshots/2.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;">Signup with Mobile Number
</h3>
<p style="font-weight: 400; font-family: 'Montserrat', sans-serif; font-size: 14px;">There is a link for signup with mobile number.
</p>
<img src="assets/screenshots/3.png" class="img-thumbnail">
</div>
<div style="display: block; margin: 30px auto;">
<p style="font-weight: 400; font-family: 'Montserrat', sans-serif; font-size: 14px;">Firstly add the mobile number and click the sent otp button,
then we will receive a otp in given mobile number, then add the mobile number
in the OTP field and update the name and password, then click on the Signup.
</p>
<img src="assets/screenshots/4.png" class="img-thumbnail">
<img src="assets/screenshots/5.png" class="img-thumbnail">
<img src="assets/screenshots/6.png" class="img-thumbnail">
<img src="assets/screenshots/7.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;">Reset Password
</h3>
<p style="font-weight: 400; font-family: 'Montserrat', sans-serif; font-size: 14px;">If in case we forget the password, reset the password will send mail to the given mail.
</p>
<img src="assets/screenshots/8.png" class="img-thumbnail">
</div>
</div>
</div>
<!-- END OF SCREENSHOTS SECTION -->
<!-- RELATED PRODUCTS -->
<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/categories.png"/>
</div>
<h2 class="mt-2"
style="font-family: 'Montserrat', sans-serif; font-size: 24px; font-weight: bold;">
Related
Products
</h2>
</div>
<div class="row">
<div class="col-sm-12">
<div id="demo1" class="row carousel slide" data-ride="carousel">
<!-- The slideshow -->
<div class="carousel-inner" style="padding: 30px;">
<div class="carousel-item" style="min-height: 198.656px;">
<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/export_stockinfo_xls/" 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/export_image.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/custom_gantt_view/" 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/gantt_image.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/sales_credit_limit/" 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/credit_image.png">
</div>
</a>
</div>
</div>
<div class="carousel-item active"
style="min-height: 198.656px;">
<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/base_account_budget/" 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/budget_image.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/product_to_quotation/" 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/quotation_image.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/employee_documents_expiry/"
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/employee_image.png">
</div>
</a>
</div>
</div>
</div>
<!-- Left and right controls -->
<a class="carousel-control-prev" href="#demo1" data-slide="prev"
style="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="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 RELATED 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 &amp; 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 d-flex justify-content-center align-items-center"
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 d-flex justify-content-center align-items-center"
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 -->

36
signup_with_twilio/static/src/css/signup.css

@ -0,0 +1,36 @@
.signup-link{
position: relative;
margin-left: 29%;
}
.country-and-mobile-number{
display: flex;
flex-direction: row;
position: center;
}
.div_code{
height: 30px;
}
.login_mobile{
height: 31px;
}
.field-phone col-lg-3 {
width: 200px; /* Adjust the width as needed */
overflow: hidden;
color: red;
}
.field-phone col-lg-3 {
height: 150px; /* Adjust the height as needed */
overflow-y: scroll;
}
/* Style the options within the custom dropdown */
.div_code option {
padding: 10px;
}
.oe_signup_form_mobile{
max-width: 300px;
position: relative;
margin: 50px auto;
}

58
signup_with_twilio/static/src/js/signup.js

@ -0,0 +1,58 @@
odoo.define('signup_with_twilio.signup', function (require) {
'use strict';
var rpc = require('web.rpc');
var ajax = require('web.ajax');
var publicWidget = require('web.public.widget');
publicWidget.registry.SignUpForm = publicWidget.Widget.extend({
selector: '.oe_signup_form_mobile, .oe_reset_password_form',
events: {
'click .sent-otp': '_onClick',
'change .check_login': '_onClickCheck',
'click button[type="submit"]': '_onSubmitClick',
},
async willStart() {
this.$('.sign-up').attr('disabled','disabled');
},
_onClick: function (ev) {
/** OTP will be create and collect the to number and redirected
to the twilio function o send the otp, and enable the signup
button to signup the user **/
ev.stopPropagation();
ev.preventDefault();
this.$('.sign-up').removeAttr('disabled');
this.$('.sent-otp').attr('disabled','disabled');
const CountryCode = $(".div_code")[0].value
const Mobile = $(".login_mobile")[0].value
let OTP = '';
var digits = '0123456789';
for (let i = 0; i < 4; i++ ) {
OTP += digits[Math.floor(Math.random() * 10)];
}
window.localStorage.setItem("OTP", OTP)
ajax.rpc('/web/send_otp', {
'country_code' : CountryCode,
'mobile': Mobile,
'otp': OTP,
})
},
_onSubmitClick: function (ev) {
/**Signup button will check the sent and receive otp to block the
user creation if it is not same, and also enable the otp button to
send the sms again **/
this.$('.sent-otp').removeAttr('disabled');
let otp_val = $("#sms_otp_verify")[0].value
let OTP = window.localStorage.getItem("OTP")
if (OTP && otp_val && OTP != otp_val){
ev.preventDefault();
alert('OTP is not matching');
}
},
_onClickCheck: function (ev) {
/**This will update the email page if it has the same login**/
let checked = $('.check_login')[0].checked
if (checked) {
$('#login_mail')[0].value = $(".field-login")[0].children[1].value
}
},
});
});

21
signup_with_twilio/views/res_config_setting_views.xml

@ -0,0 +1,21 @@
<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<!-- Inherit the res.config.settings view to add the twilio account details-->
<record id="res_config_settings_view_form" model="ir.ui.view">
<field name="name">
res.config.settings.view.form.inherit.signup.with.twilio
</field>
<field name="model">res.config.settings</field>
<field name="inherit_id"
ref="base_setup.res_config_settings_view_form"/>
<field name="arch" type="xml">
<xpath expr="//div[@id='mail_twilio_auth_token']" position="after">
<div class="row mt16" id="mail_twilio_from_number">
<label for="twilio_from_number" class="col-lg-3"/>
<field name="twilio_from_number"
placeholder="e.g. +919999999999"/>
</div>
</xpath>
</field>
</record>
</odoo>

142
signup_with_twilio/views/signup_templates.xml

@ -0,0 +1,142 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<!--Inherit the signup template to add the mobile number signup link-->
<template id="signup_with_mobile_link" inherit_id="auth_signup.signup"
name="Signup with mobile link">
<xpath expr="//button[@type='submit']" position="after">
<div class="justify-content-between mt-2 d-flex small signup-link">
<a class="sign-up-mobile" style="font-size: 12px;"
t-attf-href="/web/signup-mobile">SignUp
With Mobile
</a>
</div>
</xpath>
</template>
<!-- Template for signup with mobile -->
<template id="signup_with_mobile_fields"
name="Auth Signup with mobile form fields">
<div class="mb-3 field-login-mobile">
<label for="login_mobile">Mobile Numer</label>
<div class="country-and-mobile-number">
<div class="mb-1 field-phone col-lg-3" id="country_code">
<select class="div_code" name="country_code"
style="background-color: white">
<option value=""/>
<option t-foreach="request.env['res.country'].sudo().search([])"
t-as="country"
t-att-value="country.phone_code">
<span>+</span>
<t t-esc="country.phone_code"/>
</option>
</select>
</div>
<div class="mb-1 field-phone col-lg-9" id="div_number">
<input type="text" name="login_mobile"
t-att-value="login_mobile"
class="login_mobile form-control form-control-sm"
autofocus="autofocus" autocapitalize="off"
required="required"
t-att-readonly="'readonly' if only_passwords else None"/>
</div>
</div>
</div>
<div class="otp-verification">
<label for="otp_verify">OTP Verification</label>
<div class="mb-3 otp_verify"
style="display: flex; flex-direction: row;">
<div class="mb-1 sms-validate col-lg-6">
<input type="text" name="sms_otp" t-att-value="sms_otp"
id="sms_otp_verify"
class="form-control" autofocus="autofocus"
style="height: 32px; margin-right:5px;"/>
</div>
<button name="sent_otp_sms"
style="height: 32px; margin-left:5px; border-radius: 20px; padding-bottom: 27px"
class="btn btn-primary sent-otp col-lg-6"
role="button">Sent OTP
</button>
</div>
</div>
<div class="mb-3 field-name">
<label for="name">Your Name</label>
<input type="text" name="name" t-att-value="name" id="name"
class="form-control form-control-sm"
placeholder="e.g. John Doe"
t-att-readonly="'readonly' if only_passwords else None"
t-att-autofocus="'autofocus' if login and not only_passwords else None"/>
</div>
<div class="mb-3 field-password pt-2">
<label for="password">Password</label>
<input type="password" name="password" id="password"
class="form-control form-control-sm"
t-att-autofocus="'autofocus' if only_passwords else None"/>
</div>
<div class="mb-3 field-confirm_password">
<label for="confirm_password">Confirm Password</label>
<input type="password" name="confirm_password"
id="confirm_password"
class="form-control form-control-sm"/>
</div>
</template>
<!-- Template for signup with mobile -->
<template id="signup_mobile" name="Sign up login">
<t t-call="web.login_layout">
<form class="oe_signup_form_mobile" role="form" method="post"
t-if="not message">
<input type="hidden" name="csrf_token"
t-att-value="request.csrf_token()"/>
<t t-call="signup_with_twilio.signup_with_mobile_fields">
<t t-set="only_passwords"
t-value="bool(token and not invalid_token)"/>
</t>
<p class="alert alert-danger" t-if="error" role="alert">
<t t-esc="error"/>
</p>
<input type="hidden" name="redirect" t-att-value="redirect"/>
<input type="hidden" name="token" t-att-value="token"/>
<input type="hidden" name="signup_mobile" t-att-value="True"/>
<div class="text-center oe_login_buttons d-grid pt-3">
<button type="submit" class="btn btn-primary sign-up">Sign
up
</button>
<a t-attf-href="/web/login?{{ keep_query() }}"
class="btn btn-link btn-sm" role="button">Already have an
account?
</a>
<div class="o_login_auth"/>
</div>
</form>
</t>
</template>
<!-- Inherit the reset password template to add the mobile number-->
<template id="sign_up_mobile_reset_password"
inherit_id="auth_signup.reset_password"
name="Reset password">
<xpath expr="//div[@class='form-group field-login']/label"
position="replace">
<label for="login" class="col-form-label">Login Email/Mobile
Number
</label>
</xpath>
<xpath expr="//form[@class='oe_reset_password_form']/t[2]"
position="after">
<div class="check-login">
<input type="checkbox" name="check-login" class="check_login">
<span>Mail as same as login</span>
</input>
</div>
<t t-if="not token">
<div class="mb-3 field-email">
<label for="login_mail" class="col-form-label">Mail to send
Password
</label>
<input type="text" name="login-mail"
t-att-value="login_mail"
id="login_mail" class="form-control"
autofocus="autofocus" required="required"
autocapitalize="off"/>
</div>
</t>
</xpath>
</template>
</odoo>
Loading…
Cancel
Save