diff --git a/access_restriction_by_ip/README.rst b/access_restriction_by_ip/README.rst new file mode 100644 index 000000000..d5048b9c1 --- /dev/null +++ b/access_restriction_by_ip/README.rst @@ -0,0 +1,17 @@ +Access Restriction By IP V13 +============================ + +This module will restrict users access to his account from the specified IP only. If user access his +account from non-specified IP, login will be restricted and a warning message will be displayed in +login page. + +If no IP is specified for a user, then there will not be restriction by IP. He can access from any IP. + + +Credits +======= +Cybrosys Techno Solutions + +Author +------ +* Niyas Raphy diff --git a/access_restriction_by_ip/__init__.py b/access_restriction_by_ip/__init__.py new file mode 100644 index 000000000..60253c54a --- /dev/null +++ b/access_restriction_by_ip/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +from . import controllers +from . import models + + diff --git a/access_restriction_by_ip/__manifest__.py b/access_restriction_by_ip/__manifest__.py new file mode 100644 index 000000000..6fdd2b6af --- /dev/null +++ b/access_restriction_by_ip/__manifest__.py @@ -0,0 +1,39 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +{ + 'name': 'Access Restriction By IP', + 'summary': """User Can Access His Account Only From Specified IP Address""", + 'version': '13.0.1.0.0', + 'description': """User Can Access His Account Only From Specified IP Address""", + 'author': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'website': 'https://www.cybrosys.com', + 'category': 'Tools', + 'depends': ['base', 'mail'], + 'license': 'LGPL-3', + 'data': [ + 'security/ir.model.access.csv', + 'views/allowed_ips_view.xml', + ], + 'images': ['static/description/banner.jpg'], + 'demo': [], + 'installable': True, + 'auto_install': False, +} + diff --git a/access_restriction_by_ip/controllers/__init__.py b/access_restriction_by_ip/controllers/__init__.py new file mode 100644 index 000000000..12a21ea7e --- /dev/null +++ b/access_restriction_by_ip/controllers/__init__.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +from . import main + diff --git a/access_restriction_by_ip/controllers/main.py b/access_restriction_by_ip/controllers/main.py new file mode 100644 index 000000000..47276e922 --- /dev/null +++ b/access_restriction_by_ip/controllers/main.py @@ -0,0 +1,78 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +from odoo.addons.web.controllers import main +from odoo.http import request +from odoo.exceptions import Warning +import odoo +import odoo.modules.registry +from odoo.tools.translate import _ +from odoo import http + + +class Home(main.Home): + + @http.route('/web/login', type='http', auth="public") + def web_login(self, redirect=None, **kw): + main.ensure_db() + request.params['login_success'] = False + if request.httprequest.method == 'GET' and redirect and request.session.uid: + return http.redirect_with_hash(redirect) + + if not request.uid: + request.uid = odoo.SUPERUSER_ID + + values = request.params.copy() + try: + values['databases'] = http.db_list() + except odoo.exceptions.AccessDenied: + values['databases'] = None + if request.httprequest.method == 'POST': + old_uid = request.uid + ip_address = request.httprequest.environ['REMOTE_ADDR'] + if request.params['login']: + user_rec = request.env['res.users'].sudo().search([('login', '=', request.params['login'])]) + if user_rec.allowed_ips: + ip_list = [] + for rec in user_rec.allowed_ips: + ip_list.append(rec.ip_address) + if ip_address in ip_list: + uid = request.session.authenticate(request.session.db, request.params['login'], request.params['password']) + if uid is not False: + request.params['login_success'] = True + if not redirect: + redirect = '/web' + return http.redirect_with_hash(redirect) + request.uid = old_uid + values['error'] = _("Wrong login/password") + request.uid = old_uid + values['error'] = _("Not allowed to login from this IP") + else: + uid = request.session.authenticate(request.session.db, request.params['login'], + request.params['password']) + if uid is not False: + request.params['login_success'] = True + if not redirect: + redirect = '/web' + return http.redirect_with_hash(redirect) + request.uid = old_uid + values['error'] = _("Wrong login/password") + + + return request.render('web.login', values) diff --git a/access_restriction_by_ip/doc/RELEASE_NOTES.md b/access_restriction_by_ip/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..c78d175f5 --- /dev/null +++ b/access_restriction_by_ip/doc/RELEASE_NOTES.md @@ -0,0 +1,5 @@ +## Module + +#### 02.08.2019 +#### Version 13.0.1.0.0 +#### ADD Initial Commit for access_restriction_by_ip diff --git a/access_restriction_by_ip/models/__init__.py b/access_restriction_by_ip/models/__init__.py new file mode 100644 index 000000000..2ced003bf --- /dev/null +++ b/access_restriction_by_ip/models/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +from . import allowed_ips + + diff --git a/access_restriction_by_ip/models/allowed_ips.py b/access_restriction_by_ip/models/allowed_ips.py new file mode 100644 index 000000000..2be23a85e --- /dev/null +++ b/access_restriction_by_ip/models/allowed_ips.py @@ -0,0 +1,33 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +from odoo import models, fields + + +class ResUsersInherit(models.Model): + _inherit = 'res.users' + + allowed_ips = fields.One2many('allowed.ips', 'users_ip', string='IP') + + +class AllowedIPs(models.Model): + _name = 'allowed.ips' + + users_ip = fields.Many2one('res.users', string='IP') + ip_address = fields.Char(string='Allowed IP') diff --git a/access_restriction_by_ip/security/ir.model.access.csv b/access_restriction_by_ip/security/ir.model.access.csv new file mode 100644 index 000000000..c6ee084c4 --- /dev/null +++ b/access_restriction_by_ip/security/ir.model.access.csv @@ -0,0 +1,2 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_allowed_ips,access.allowed.ips,access_restriction_by_ip.model_allowed_ips,base.group_user,1,1,1,0 diff --git a/access_restriction_by_ip/static/description/access_non_set_ip.png b/access_restriction_by_ip/static/description/access_non_set_ip.png new file mode 100644 index 000000000..0af97d8ae Binary files /dev/null and b/access_restriction_by_ip/static/description/access_non_set_ip.png differ diff --git a/access_restriction_by_ip/static/description/banner.jpg b/access_restriction_by_ip/static/description/banner.jpg new file mode 100644 index 000000000..f5bbd4859 Binary files /dev/null and b/access_restriction_by_ip/static/description/banner.jpg differ diff --git a/access_restriction_by_ip/static/description/cybro_logo.png b/access_restriction_by_ip/static/description/cybro_logo.png new file mode 100644 index 000000000..bb309114c Binary files /dev/null and b/access_restriction_by_ip/static/description/cybro_logo.png differ diff --git a/access_restriction_by_ip/static/description/icon.png b/access_restriction_by_ip/static/description/icon.png new file mode 100644 index 000000000..401fd1ed3 Binary files /dev/null and b/access_restriction_by_ip/static/description/icon.png differ diff --git a/access_restriction_by_ip/static/description/index.html b/access_restriction_by_ip/static/description/index.html new file mode 100644 index 000000000..91d38c01f --- /dev/null +++ b/access_restriction_by_ip/static/description/index.html @@ -0,0 +1,309 @@ +
+
+

+ Access Restriction By IP +

+

+ User can access his account only from specified IP's +

+
+ Cybrosys Technologies +
+
+
+
+
+

+ Overview +

+

+ This module will restrict the users access to his account from specified IP address only +

+
+
+ +
+
+

+ Features +

+

+ + Administrator can set a IP or a group of IP address for each users +

+

+ + Users can access their account only from the specified IP's +

+ + Accessing system from a non-specified IP will restrict the user login +

+

+ + A warning message will be displayed

+

+ + If no IP is set to user means there is no any restriction by IP

+

+ + IP Address for each users can be set from users form view

+
+
+
+
+

+ Setting IP address for User +

+

+ + Setting IP address for user from users form view
+ + User will be able to access his account only from this IP's +

+
+ +
+

+ User accessing his account +

+

+ + On accessing account from a non specified IP +

+
+ +
+ +
+
+ + +
+ +
+
+ +
+ +
+ +
+ diff --git a/access_restriction_by_ip/static/description/user_set_ip.png b/access_restriction_by_ip/static/description/user_set_ip.png new file mode 100644 index 000000000..1f6d1b8b1 Binary files /dev/null and b/access_restriction_by_ip/static/description/user_set_ip.png differ diff --git a/access_restriction_by_ip/views/allowed_ips_view.xml b/access_restriction_by_ip/views/allowed_ips_view.xml new file mode 100644 index 000000000..3b7f244d4 --- /dev/null +++ b/access_restriction_by_ip/views/allowed_ips_view.xml @@ -0,0 +1,21 @@ + + + + + res.users + res.users + + + + + + + + + + + + + + + diff --git a/inventory_barcode_scanning/README.rst b/inventory_barcode_scanning/README.rst new file mode 100644 index 000000000..acd3120ee --- /dev/null +++ b/inventory_barcode_scanning/README.rst @@ -0,0 +1,49 @@ +.. 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 + +Barcode scanning in inventory +============================= +This module will used for barcode scanning in inventory. + +Depends +======= +[stock] addon Odoo + +Configuration +============= +* No additional configurations needed + +Company +------- +* `Cybrosys Techno Solutions `__ + +Credits +------- +* Developer: Niyas Raphy@cybrosys + Sreejith P @cybrosys + Version 13: Nimisha Murali@cybrosys + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com +* Website : https://cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +.. image:: https://cybrosys.com/images/logo.png + :target: https://cybrosys.com + +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit `Our Website `__ + +Further information +=================== +HTML Description: ``__ + + diff --git a/inventory_barcode_scanning/__init__.py b/inventory_barcode_scanning/__init__.py new file mode 100644 index 000000000..4cec6ef76 --- /dev/null +++ b/inventory_barcode_scanning/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith P (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import models diff --git a/inventory_barcode_scanning/__manifest__.py b/inventory_barcode_scanning/__manifest__.py new file mode 100644 index 000000000..af90f3562 --- /dev/null +++ b/inventory_barcode_scanning/__manifest__.py @@ -0,0 +1,41 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith P (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +{ + 'name': 'Barcode scanning in Inventory', + 'version': '13.0.1.0.0', + 'summary': 'Barcode Support in Stock Picking.', + 'author': 'Cybrosys Techno solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'website': 'https://www.cybrosys.com', + 'depends': ['stock'], + 'category': 'Inventory', + 'demo': [], + 'data': ['views/stock_picking.xml'], + 'installable': True, + 'application': False, + 'auto_install': False, + 'images': ['static/description/banner.jpg'], + 'qweb': [], + 'license': 'AGPL-3', +} diff --git a/inventory_barcode_scanning/doc/RELEASE_NOTES.md b/inventory_barcode_scanning/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..bb5b783ca --- /dev/null +++ b/inventory_barcode_scanning/doc/RELEASE_NOTES.md @@ -0,0 +1,9 @@ +## Module + +#### 07.10.2019 +#### Version 13.0.1.0.0 +#### ADD +Initial commit for Barcode scanning in Inventory + + + diff --git a/inventory_barcode_scanning/models/__init__.py b/inventory_barcode_scanning/models/__init__.py new file mode 100644 index 000000000..b2cefca09 --- /dev/null +++ b/inventory_barcode_scanning/models/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith p (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import stock_picking diff --git a/inventory_barcode_scanning/models/stock_picking.py b/inventory_barcode_scanning/models/stock_picking.py new file mode 100644 index 000000000..c8f6d547d --- /dev/null +++ b/inventory_barcode_scanning/models/stock_picking.py @@ -0,0 +1,65 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith p (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from odoo import fields, models, api +from odoo.exceptions import Warning + + +class StockPicking(models.Model): + _inherit = 'stock.picking' + + barcode = fields.Char(string='Barcode') + + @api.onchange('barcode') + def barcode_scanning(self): + match = False + product_obj = self.env['product.product'] + product_id = product_obj.search([('barcode', '=', self.barcode)]) + if self.barcode and not product_id: + self.barcode = None + raise Warning('No product is available for this barcode') + if self.barcode and self.move_ids_without_package: + for line in self.move_ids_without_package: + if line.product_id.barcode == self.barcode: + line.quantity_done += 1 + self.barcode = None + match = True + if self.barcode and not match: + self.barcode = None + if product_id: + raise Warning('This product is not available in the order.' + 'You can add this product by clicking the "Add an item" and scan') + + +class StockPickingOperation(models.Model): + _inherit = 'stock.move' + + barcode = fields.Char(string='Barcode') + + @api.onchange('barcode') + def _onchange_barcode_scan(self): + product_rec = self.env['product.product'] + if self.barcode: + product = product_rec.search([('barcode', '=', self.barcode)]) + self.product_id = product.id + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/inventory_barcode_scanning/static/description/banner.jpg b/inventory_barcode_scanning/static/description/banner.jpg new file mode 100644 index 000000000..86c66b6c2 Binary files /dev/null and b/inventory_barcode_scanning/static/description/banner.jpg differ diff --git a/inventory_barcode_scanning/static/description/cybro_logo.png b/inventory_barcode_scanning/static/description/cybro_logo.png new file mode 100644 index 000000000..bb309114c Binary files /dev/null and b/inventory_barcode_scanning/static/description/cybro_logo.png differ diff --git a/inventory_barcode_scanning/static/description/cybrosys-inventory-barcode.png b/inventory_barcode_scanning/static/description/cybrosys-inventory-barcode.png new file mode 100644 index 000000000..85c709a1b Binary files /dev/null and b/inventory_barcode_scanning/static/description/cybrosys-inventory-barcode.png differ diff --git a/inventory_barcode_scanning/static/description/icon.png b/inventory_barcode_scanning/static/description/icon.png new file mode 100644 index 000000000..110f86b9f Binary files /dev/null and b/inventory_barcode_scanning/static/description/icon.png differ diff --git a/inventory_barcode_scanning/static/description/index.html b/inventory_barcode_scanning/static/description/index.html new file mode 100644 index 000000000..8e4d8ac7a --- /dev/null +++ b/inventory_barcode_scanning/static/description/index.html @@ -0,0 +1,359 @@ + +
+
+

+ Barcode scanning support for Inventory +

+

+ Use Barcode scanner to add entry in Stock Picking +

+
+ Cybrosys Technologies +
+ +
+ cybrosys technologies +
+
+
+
+ +
+
+

+ Overview +

+

+ With this module you can avoid manual entry of product quantity in Stock Picking form. Presently you have to enter the quantity of each product individually. By installing this module you will get an extra field in stock picking form to Scan Barcode and update the quantity of product automatically. +

+
+ +
+
+
+

+ Features +

+

+ + Avoid manual entry of item count in Stock Picking. +

+

+ + Use barcode to add product. +

+ +
+
+
+
+

+ Screenshots +

+

+ + Enable editing mode. +

+

+ + Click the field 'Barcode' and scan the Product. +

+

+ + You can see the quantity is updating automatically. +

+

+ + If no associated product is found in list then a warning will popup. +

+
  • + In this case you can add the product to list by clicking Add an Item + +
  • +
  • + Here also you will have the option to scan barcode for easy addition. +
  • +
+
+ +
+ +
+
+ +
+
+ cybrosys technologies +
+
+
+
+

+ Our Services +

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

+ + Odoo Support +

+ +
+ +
+
+
+
+
+

+ Our Industries +

+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Trading + +

+

+ Easily procure and sell your products. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Manufacturing +

+

+ Plan, track and schedule your operations. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Restaurant +

+

+ Run your bar or restaurant methodical. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + POS +

+

+ Easy configuring and convivial selling. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + E-commerce & Website +

+

+ Mobile friendly, awe-inspiring product pages. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Hotel Management +

+

+ An all-inclusive hotel management application. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Education +

+

+ A Collaborative platform for educational management. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Service Management +

+

+ Keep track of services and invoice accordingly. +

+
+
+
+
+
+
+ +
+ + + + + + + + + + + diff --git a/inventory_barcode_scanning/static/description/inventory_barcode.png b/inventory_barcode_scanning/static/description/inventory_barcode.png new file mode 100644 index 000000000..85c709a1b Binary files /dev/null and b/inventory_barcode_scanning/static/description/inventory_barcode.png differ diff --git a/inventory_barcode_scanning/views/stock_picking.xml b/inventory_barcode_scanning/views/stock_picking.xml new file mode 100644 index 000000000..daaddde1d --- /dev/null +++ b/inventory_barcode_scanning/views/stock_picking.xml @@ -0,0 +1,20 @@ + + + + + + Barcode Scanning Inventory + stock.picking + + + + + + + + + + + + + diff --git a/login_user_detail/README.rst b/login_user_detail/README.rst new file mode 100755 index 000000000..3a1646314 --- /dev/null +++ b/login_user_detail/README.rst @@ -0,0 +1,52 @@ +.. image:: https://img.shields.io/badge/licence-AGPL--1-blue.svg + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 + +User Log Details +================ + +This module developed to record login details of user. + +Installation +============ + +Just select it from available modules to install it, there is no need to extra installations. + +Configuration +============= + +Nothing to configure. + +Company +------- +* `Cybrosys Techno Solutions `__ + +Credits +------- +* Developer: + Saritha @ cybrosys + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com +* Website : https://cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +.. image:: https://cybrosys.com/images/logo.png + :target: https://cybrosys.com + +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit `Our Website `__ + +Further information +=================== +HTML Description: ``__ + + + diff --git a/login_user_detail/__init__.py b/login_user_detail/__init__.py new file mode 100755 index 000000000..4d63b6757 --- /dev/null +++ b/login_user_detail/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Your Name (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import models diff --git a/login_user_detail/__manifest__.py b/login_user_detail/__manifest__.py new file mode 100755 index 000000000..9aecb50ea --- /dev/null +++ b/login_user_detail/__manifest__.py @@ -0,0 +1,42 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Your Name (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +{ + 'name': "User Log Details", + 'version': '13.0.1.0.1', + 'summary': """Login User Details & IP Address""", + 'description': """This module records login information of user""", + 'author': "Cybrosys Techno Solutions ", + 'company': "Cybrosys Techno Solutions ", + 'maintainer': 'Cybrosys Techno Solutions', + 'website': "https://www.cybrosys.com", + 'category': 'Tools', + 'depends': ['base'], + 'license': 'LGPL-3', + 'data': [ + 'security/ir.model.access.csv', + 'views/login_user_views.xml'], + 'demo': [], + 'images': ['static/description/banner.png'], + 'installable': True, + 'auto_install': False, +} diff --git a/login_user_detail/doc/RELEASE_NOTES.md b/login_user_detail/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..f01e7c0a9 --- /dev/null +++ b/login_user_detail/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 10.03.2019 +#### Version 13.0.1.0.0 +#### ADD +- Initial Commit for login_user_detail diff --git a/login_user_detail/models/__init__.py b/login_user_detail/models/__init__.py new file mode 100755 index 000000000..52c913351 --- /dev/null +++ b/login_user_detail/models/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Your Name (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import login_user_details diff --git a/login_user_detail/models/login_user_details.py b/login_user_detail/models/login_user_details.py new file mode 100755 index 000000000..9b7b2325a --- /dev/null +++ b/login_user_detail/models/login_user_details.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Your Name (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +import logging +from itertools import chain +from odoo.http import request +from odoo import models, fields, api + +_logger = logging.getLogger(__name__) +USER_PRIVATE_FIELDS = ['password'] +concat = chain.from_iterable + + +class LoginUserDetail(models.Model): + _inherit = 'res.users' + + @api.model + def _check_credentials(self, password): + result = super(LoginUserDetail, self)._check_credentials(password) + ip_address = request.httprequest.environ['REMOTE_ADDR'] + vals = {'name': self.name, + 'ip_address': ip_address + } + self.env['login.detail'].sudo().create(vals) + return result + + +class LoginUpdate(models.Model): + _name = 'login.detail' + + name = fields.Char(string="User Name") + date_time = fields.Datetime(string="Login Date And Time", default=lambda self: fields.datetime.now()) + ip_address = fields.Char(string="IP Address") diff --git a/login_user_detail/security/ir.model.access.csv b/login_user_detail/security/ir.model.access.csv new file mode 100755 index 000000000..7935bc9e7 --- /dev/null +++ b/login_user_detail/security/ir.model.access.csv @@ -0,0 +1,2 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_login_user_detail,login_user_detail_login_detail,model_login_detail,,1,1,1,1 diff --git a/login_user_detail/static/description/banner.png b/login_user_detail/static/description/banner.png new file mode 100755 index 000000000..65f71eaa3 Binary files /dev/null and b/login_user_detail/static/description/banner.png differ diff --git a/login_user_detail/static/description/cybro_logo.png b/login_user_detail/static/description/cybro_logo.png new file mode 100755 index 000000000..bb309114c Binary files /dev/null and b/login_user_detail/static/description/cybro_logo.png differ diff --git a/login_user_detail/static/description/cybrosys-login-user-details.png b/login_user_detail/static/description/cybrosys-login-user-details.png new file mode 100755 index 000000000..38477eeed Binary files /dev/null and b/login_user_detail/static/description/cybrosys-login-user-details.png differ diff --git a/login_user_detail/static/description/icon.png b/login_user_detail/static/description/icon.png new file mode 100755 index 000000000..724a2717f Binary files /dev/null and b/login_user_detail/static/description/icon.png differ diff --git a/login_user_detail/static/description/index.html b/login_user_detail/static/description/index.html new file mode 100755 index 000000000..e02fe7d4f --- /dev/null +++ b/login_user_detail/static/description/index.html @@ -0,0 +1,310 @@ +
+
+

+ User Log Details +

+

+ Records User Log Details +

+
+ Cybrosys Technologies +
+ +
+ cybrosys technologies +
+
+
+
+ +
+
+

+ Overview +

+

+ User Log Details, Record login date,IP Address of login user. +

+
+
+
+
+

+ Screenshots +

+

+ + Login Details +

+
+ +
+
+
+ +
+
+ cybrosys technologies +
+
+
+
+

+ Our Services +

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

+ + Odoo Support +

+ +
+ +
+
+
+
+
+

+ Our Industries +

+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Trading + +

+

+ Easily procure and sell your products. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Manufacturing +

+

+ Plan, track and schedule your operations. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Restaurant +

+

+ Run your bar or restaurant methodical. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + POS +

+

+ Easy configuring and convivial selling. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + E-commerce & Website +

+

+ Mobile friendly, awe-inspiring product pages. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Hotel Management +

+

+ An all-inclusive hotel management application. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Education +

+

+ A Collaborative platform for educational management. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Service Management +

+

+ Keep track of services and invoice accordingly. +

+
+
+
+
+
+
+ +
+ diff --git a/login_user_detail/static/description/login.png b/login_user_detail/static/description/login.png new file mode 100755 index 000000000..38477eeed Binary files /dev/null and b/login_user_detail/static/description/login.png differ diff --git a/login_user_detail/views/login_user_views.xml b/login_user_detail/views/login_user_views.xml new file mode 100755 index 000000000..1b49d4f1c --- /dev/null +++ b/login_user_detail/views/login_user_views.xml @@ -0,0 +1,42 @@ + + + + + Login User Details + login.detail + +
+ + + + + + + +
+
+
+ + + Login User Details + login.detail + + + + + + + + + + + Login User Details + login.detail + tree,form + + + + +
+
\ No newline at end of file diff --git a/product_barcode/README.rst b/product_barcode/README.rst new file mode 100644 index 000000000..cf0061ec2 --- /dev/null +++ b/product_barcode/README.rst @@ -0,0 +1,44 @@ +.. 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 + +Product Barcode Generator +========================= + +Generates EAN13 Standard Barcode for Product. +Also, introduces a new feature to print product variant price and name on the product label. + +Configuration +============= +* No additional configurations needed + +Company +------- +* `Cybrosys Techno Solutions `__ + +Credits +------- +* Developer: Sreejith P @ cybrosys, Contact: odoo@cybrosys.com + Niyas Raphy @cybrosys, Contact: odoo@cybrosys.com + Version 13: Nimisha Murali@cybrosys,Contact: odoo@cybrosys.com +Contacts +-------- +* Mail Contact : odoo@cybrosys.com +* Website : https://cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +.. image:: https://cybrosys.com/images/logo.png + :target: https://cybrosys.com + +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit `Our Website `__ + +Further information +=================== +HTML Description: ``__ diff --git a/product_barcode/__init__.py b/product_barcode/__init__.py new file mode 100644 index 000000000..4cec6ef76 --- /dev/null +++ b/product_barcode/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith P (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import models diff --git a/product_barcode/__manifest__.py b/product_barcode/__manifest__.py new file mode 100644 index 000000000..e98d0b137 --- /dev/null +++ b/product_barcode/__manifest__.py @@ -0,0 +1,41 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith P (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +{ + 'name': 'Product Barcode Generator', + 'version': '13.0.1.0.1', + 'summary': 'Generates EAN13 Standard Barcode for Product.', + 'category': 'Inventory', + 'author': 'Cybrosys Techno solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'website': 'https://www.cybrosys.com', + 'depends': ['stock', 'product'], + 'data': [ + 'views/product_label.xml', + ], + 'images': ['static/description/banner.jpg'], + 'license': 'AGPL-3', + 'installable': True, + 'application': False, + 'auto_install': False, +} diff --git a/product_barcode/doc/RELEASE_NOTES.md b/product_barcode/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..bb13014ac --- /dev/null +++ b/product_barcode/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 10.03.2019 +#### Version 13.0.1.0.0 +##### ADD +- Initial Commit diff --git a/product_barcode/models/__init__.py b/product_barcode/models/__init__.py new file mode 100644 index 000000000..25c5427d7 --- /dev/null +++ b/product_barcode/models/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith P (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import product_form diff --git a/product_barcode/models/product_form.py b/product_barcode/models/product_form.py new file mode 100644 index 000000000..990260216 --- /dev/null +++ b/product_barcode/models/product_form.py @@ -0,0 +1,86 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Niyas Raphy and Sreejith P (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +import math +import re +from odoo import api, models + + +class ProductAutoBarcode(models.Model): + _inherit = 'product.product' + + @api.model + def create(self, vals): + res = super(ProductAutoBarcode, self).create(vals) + ean = generate_ean(str(res.id)) + + res.barcode = ean + return res + + +def ean_checksum(eancode): + """returns the checksum of an ean string of length 13, returns -1 if + the string has the wrong length""" + if len(eancode) != 13: + return -1 + oddsum = 0 + evensum = 0 + eanvalue = eancode + reversevalue = eanvalue[::-1] + finalean = reversevalue[1:] + + for i in range(len(finalean)): + if i % 2 == 0: + oddsum += int(finalean[i]) + else: + evensum += int(finalean[i]) + total = (oddsum * 3) + evensum + + check = int(10 - math.ceil(total % 10.0)) % 10 + return check + + +def check_ean(eancode): + """returns True if eancode is a valid ean13 string, or null""" + if not eancode: + return True + if len(eancode) != 13: + return False + try: + int(eancode) + except: + return False + return ean_checksum(eancode) == int(eancode[-1]) + + +def generate_ean(ean): + """Creates and returns a valid ean13 from an invalid one""" + if not ean: + return "0000000000000" + ean = re.sub("[A-Za-z]", "0", ean) + ean = re.sub("[^0-9]", "", ean) + ean = ean[:13] + if len(ean) < 13: + ean = ean + '0' * (13 - len(ean)) + return ean[:-1] + str(ean_checksum(ean)) + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/product_barcode/static/description/banner.jpg b/product_barcode/static/description/banner.jpg new file mode 100644 index 000000000..2489f0aac Binary files /dev/null and b/product_barcode/static/description/banner.jpg differ diff --git a/product_barcode/static/description/barcode_generate_product.gif b/product_barcode/static/description/barcode_generate_product.gif new file mode 100644 index 000000000..6ad77ddae Binary files /dev/null and b/product_barcode/static/description/barcode_generate_product.gif differ diff --git a/product_barcode/static/description/cybro_logo.png b/product_barcode/static/description/cybro_logo.png new file mode 100644 index 000000000..bb309114c Binary files /dev/null and b/product_barcode/static/description/cybro_logo.png differ diff --git a/product_barcode/static/description/icon.png b/product_barcode/static/description/icon.png new file mode 100644 index 000000000..bcd92a70d Binary files /dev/null and b/product_barcode/static/description/icon.png differ diff --git a/product_barcode/static/description/index.html b/product_barcode/static/description/index.html new file mode 100644 index 000000000..a84708efb --- /dev/null +++ b/product_barcode/static/description/index.html @@ -0,0 +1,82 @@ +
+
+

Product Barcode Generator

+

Generates EAN13 Standard Barcode for Product

+ +

Cybrosys Technologies

+
+

Features:

+
    +
  •    Generates Barcode Automatically.
  • +
  •    Print Variant Price on Product Labels.
  • +
  •    Print Variant Name on Product Labels.
  • +
+
+
+
+ +
+
+
+

Overview

+

+ The module automatically generates EAN13 standard barcode for each product while you create it. + The module also introduces a new feature to print product variant price on the product label. + Presently Odoo doesn’t have these features. +

+
+
+
+ +
+
+

Product Master

+
+

+ ☛ Create a Product.
+

+
+ +
+
+
+
+
+
+

Product Labels

+
+

+ ☛ Variant name on label.
+ ☛ Variant sale price on label.
+

+
+ +
+
+
+
+
+

Need Any Help?

+ +
diff --git a/product_barcode/static/description/product_label.png b/product_barcode/static/description/product_label.png new file mode 100644 index 000000000..8a27d6916 Binary files /dev/null and b/product_barcode/static/description/product_label.png differ diff --git a/product_barcode/views/product_label.xml b/product_barcode/views/product_label.xml new file mode 100644 index 000000000..4aab06a17 --- /dev/null +++ b/product_barcode/views/product_label.xml @@ -0,0 +1,51 @@ + + + + + + + + + diff --git a/project_task_timer/README.rst b/project_task_timer/README.rst new file mode 100644 index 000000000..93b9e49bd --- /dev/null +++ b/project_task_timer/README.rst @@ -0,0 +1,20 @@ +Project Task Timer v13 +====================================== +Task Timer with Start & Stop + +Installation +============ + - www.odoo.com/documentation/13.0/setup/install.html + - Install our custom addon + +Configuration +============= + + No additional configurations needed + +Credits +======= + Developer: Jesni Banu v10 @ cybrosys, Contact: odoo@cybrosys.com + Kavya Raveendran v11 @ cybrosys, Contact: odoo@cybrosys.com + Kavya Raveendran v12 @ cybrosys, Contact: odoo@cybrosys.com + Sreejith sasidharan v13 @ cybrosys, Contact: odoo@cybrosys.com diff --git a/project_task_timer/__init__.py b/project_task_timer/__init__.py new file mode 100644 index 000000000..c30f03536 --- /dev/null +++ b/project_task_timer/__init__.py @@ -0,0 +1,21 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Jesni Banu() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## + +from . import models diff --git a/project_task_timer/__manifest__.py b/project_task_timer/__manifest__.py new file mode 100644 index 000000000..9cd27619a --- /dev/null +++ b/project_task_timer/__manifest__.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Jesni Banu() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +{ + 'name': 'Project Task Timer', + 'version': '13.0.0.1.0', + 'summary': """Task Timer With Start & Stop""", + 'description': """"This module helps you to track time sheet in project automatically.""", + 'category': 'Project', + 'author': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'website': "http://www.cybrosys.com", + 'depends': ['base', 'project', 'hr_timesheet'], + 'data': [ + 'views/project_task_timer_view.xml', + 'views/project_timer_static.xml', + ], + 'images': ['static/description/banner.jpg'], + 'license': 'AGPL-3', + 'demo': [], + 'installable': True, + 'auto_install': False, + 'application': False, +} diff --git a/project_task_timer/doc/RELEASE_NOTES.md b/project_task_timer/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..e263f6cb9 --- /dev/null +++ b/project_task_timer/doc/RELEASE_NOTES.md @@ -0,0 +1,4 @@ +## Module + +#### 18.04.2019 +#### Version 13.0.0.1.0 diff --git a/project_task_timer/models/__init__.py b/project_task_timer/models/__init__.py new file mode 100644 index 000000000..bdb87e104 --- /dev/null +++ b/project_task_timer/models/__init__.py @@ -0,0 +1,21 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Jesni Banu() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## + +from . import project_task_timer diff --git a/project_task_timer/models/project_task_timer.py b/project_task_timer/models/project_task_timer.py new file mode 100644 index 000000000..460b99f0b --- /dev/null +++ b/project_task_timer/models/project_task_timer.py @@ -0,0 +1,84 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# Cybrosys Technologies Pvt. Ltd. +# Copyright (C) 2017-TODAY Cybrosys Technologies(). +# Author: Jesni Banu() +# 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 +# GENERAL PUBLIC LICENSE (LGPL v3) along with this program. +# If not, see . +# +############################################################################## +from datetime import datetime +from odoo import models, fields, api + + +class ProjectTaskTimeSheet(models.Model): + _inherit = 'account.analytic.line' + + date_start = fields.Datetime(string='Start Date') + date_end = fields.Datetime(string='End Date', readonly=1) + timer_duration = fields.Float(invisible=1, string='Time Duration (Minutes)') + + +class ProjectTaskTimer(models.Model): + _inherit = 'project.task' + + task_timer = fields.Boolean(string='Timer', default=False) + is_user_working = fields.Boolean( + 'Is Current User Working', compute='_compute_is_user_working', + help="Technical field indicating whether the current user is working. ") + duration = fields.Float( + 'Real Duration', compute='_compute_duration', store=True) + + def _compute_duration(self): + self + + def _compute_is_user_working(self): + """ Checks whether the current user is working """ + for order in self: + if order.timesheet_ids.filtered(lambda x: (x.user_id.id == self.env.user.id) and (not x.date_end)): + order.is_user_working = True + else: + order.is_user_working = False + + @api.model + @api.constrains('task_timer') + def toggle_start(self): + if self.task_timer is True: + self.write({'is_user_working': True}) + time_line = self.env['account.analytic.line'] + for time_sheet in self: + time_line.create({ + 'name': self.env.user.name + ': ' + time_sheet.name, + 'task_id': time_sheet.id, + 'user_id': self.env.user.id, + 'project_id': time_sheet.project_id.id, + 'date_start': datetime.now(), + }) + else: + self.write({'is_user_working': False}) + time_line_obj = self.env['account.analytic.line'] + domain = [('task_id', 'in', self.ids), ('date_end', '=', False)] + for time_line in time_line_obj.search(domain): + time_line.write({'date_end': fields.Datetime.now()}) + if time_line.date_end: + diff = fields.Datetime.from_string(time_line.date_end) - fields.Datetime.from_string( + time_line.date_start) + time_line.timer_duration = round(diff.total_seconds() / 60.0, 2) + time_line.unit_amount = round(diff.total_seconds() / (60.0 * 60.0), 2) + else: + time_line.unit_amount = 0.0 + time_line.timer_duration = 0.0 + + + + diff --git a/project_task_timer/static/description/icon.png b/project_task_timer/static/description/icon.png new file mode 100644 index 000000000..ef78aa4ee Binary files /dev/null and b/project_task_timer/static/description/icon.png differ diff --git a/project_task_timer/static/description/images/banner.png b/project_task_timer/static/description/images/banner.png new file mode 100644 index 000000000..6b8415776 Binary files /dev/null and b/project_task_timer/static/description/images/banner.png differ diff --git a/project_task_timer/static/description/images/banner_lifeline_for_task.jpeg b/project_task_timer/static/description/images/banner_lifeline_for_task.jpeg new file mode 100644 index 000000000..4a467ea22 Binary files /dev/null and b/project_task_timer/static/description/images/banner_lifeline_for_task.jpeg differ diff --git a/project_task_timer/static/description/images/banner_project_report_xls_pdf.png b/project_task_timer/static/description/images/banner_project_report_xls_pdf.png new file mode 100644 index 000000000..3c430a7eb Binary files /dev/null and b/project_task_timer/static/description/images/banner_project_report_xls_pdf.png differ diff --git a/project_task_timer/static/description/images/banner_project_status_report.png b/project_task_timer/static/description/images/banner_project_status_report.png new file mode 100644 index 000000000..d1b689710 Binary files /dev/null and b/project_task_timer/static/description/images/banner_project_status_report.png differ diff --git a/project_task_timer/static/description/images/banner_subtask.jpeg b/project_task_timer/static/description/images/banner_subtask.jpeg new file mode 100644 index 000000000..f2b224110 Binary files /dev/null and b/project_task_timer/static/description/images/banner_subtask.jpeg differ diff --git a/project_task_timer/static/description/images/banner_task_deadline_reminder.jpeg b/project_task_timer/static/description/images/banner_task_deadline_reminder.jpeg new file mode 100644 index 000000000..998679818 Binary files /dev/null and b/project_task_timer/static/description/images/banner_task_deadline_reminder.jpeg differ diff --git a/project_task_timer/static/description/images/banner_task_statusbar.jpeg b/project_task_timer/static/description/images/banner_task_statusbar.jpeg new file mode 100644 index 000000000..2c57cbb7b Binary files /dev/null and b/project_task_timer/static/description/images/banner_task_statusbar.jpeg differ diff --git a/project_task_timer/static/description/images/checked.png b/project_task_timer/static/description/images/checked.png new file mode 100644 index 000000000..578cedb80 Binary files /dev/null and b/project_task_timer/static/description/images/checked.png differ diff --git a/project_task_timer/static/description/images/cybrosys.png b/project_task_timer/static/description/images/cybrosys.png new file mode 100644 index 000000000..d76b5bafb Binary files /dev/null and b/project_task_timer/static/description/images/cybrosys.png differ diff --git a/project_task_timer/static/description/images/task_timer.gif b/project_task_timer/static/description/images/task_timer.gif new file mode 100644 index 000000000..ba0a1bd3d Binary files /dev/null and b/project_task_timer/static/description/images/task_timer.gif differ diff --git a/project_task_timer/static/description/images/task_timerV13_1.png b/project_task_timer/static/description/images/task_timerV13_1.png new file mode 100644 index 000000000..50cacc8b8 Binary files /dev/null and b/project_task_timer/static/description/images/task_timerV13_1.png differ diff --git a/project_task_timer/static/description/images/task_timerV13_2.png b/project_task_timer/static/description/images/task_timerV13_2.png new file mode 100644 index 000000000..c123ec5c3 Binary files /dev/null and b/project_task_timer/static/description/images/task_timerV13_2.png differ diff --git a/project_task_timer/static/description/images/task_timerV13_3.png b/project_task_timer/static/description/images/task_timerV13_3.png new file mode 100644 index 000000000..309b7af03 Binary files /dev/null and b/project_task_timer/static/description/images/task_timerV13_3.png differ diff --git a/project_task_timer/static/description/images/task_timer_youtube.png b/project_task_timer/static/description/images/task_timer_youtube.png new file mode 100644 index 000000000..fb6579727 Binary files /dev/null and b/project_task_timer/static/description/images/task_timer_youtube.png differ diff --git a/project_task_timer/static/description/index.html b/project_task_timer/static/description/index.html new file mode 100644 index 000000000..2235bd5d4 --- /dev/null +++ b/project_task_timer/static/description/index.html @@ -0,0 +1,308 @@ +
cybrosys-logo
+
+
+
+

Project Task Timer

+

Task Timer with Start & Stop

+
+

Key Highlights

+
    +
  • checkTimer in Task.
  • +
  • check Automatic Timesheet Calculation.
  • +
+
+
+
+
+
+
+
+ +
+
+ +

Overview

+
+

+ You have a toggle button to start & stop your task and record your actual working hours. When you start your task timer, you get a notification, alongside a time sheet entry with starting time that is automatically generated by the timer for that particular task. When you toggle it to stop, the task’s end date shall be updated and the duration gets automatically calculated. +

+
+
+ +

Project Task Timer

+
+
    +
  • + checkTimer in Task. +
  • +
  • + checkNotification when starting the Timer. +
  • +
  • + checkAutomatic Timesheet Calculation. +
  • +
+
+ +
+
+

Screenshots

+
+
+
+ +
+
+
+
+
+ +

Video

+
+
+

POS Booking Order Demo

+ +
+ Cybrosys Cover Video +
+
+
+ +
+
    +
+
+
+
+
+
+
+

Suggested Products

+
+ +
+
+

Our Service

+
+ +
+
+
+

Our Industries

+
+ +
+
+
+ +
+
+

Trading

+

Easily procure and sell your products.

+
+
+
+
+ +
+
+

Manufacturing

+

Plan, track and schedule your operations.

+
+
+
+
+ +
+
+

Restaurant

+

Run your bar or restaurant methodical.

+
+
+
+
+ +
+
+

POS

+

Easy configuring and convivial selling.

+
+
+
+
+ +
+
+

E-commerce & Website

+

Mobile friendly, awe-inspiring product pages.

+
+
+
+
+ +
+
+

Hotel Management

+

An all-inclusive hotel management application.

+
+
+
+
+ +
+
+

Education

+

A Collaborative platform for educational management.

+
+
+
+
+ +
+
+

Service Management

+

Keep track of services and invoice accordingly.

+
+
+
+
+
+ +
+
+
+

Need Any Help?

+
+

If you have anything to share with us based on your use of this module, please let us know. We are ready to offer our support.

+
+

Email us

+

odoo@cybrosys.com / info@cybrosys.com

+
+
+

Contact Us

+ www.cybrosys.com +
+
+
+
+
+
+
+
+
+ +
+ + + + + + + +
+
+
+ \ No newline at end of file diff --git a/project_task_timer/static/src/js/timer.js b/project_task_timer/static/src/js/timer.js new file mode 100644 index 000000000..263ca45de --- /dev/null +++ b/project_task_timer/static/src/js/timer.js @@ -0,0 +1,70 @@ +odoo.define('project_task_timer.timer', function (require) { +"use strict"; +var AbstractField = require('web.AbstractField'); +var core = require('web.core'); +var field_registry = require('web.field_registry'); +var time = require('web.time'); +var FieldManagerMixin = require('web.FieldManagerMixin'); + +var _t = core._t; + +// $(document).on('click','#timer', function(){ +// if ($(this).hasClass('btn-secondary')) +// { $(this).removeClass('btn-secondary'); +// $(this).addClass('btn-primary'); +// } +// }); + +var TimeCounter = AbstractField.extend({ + + willStart: function () { + var self = this; + var def = this._rpc({ + model: 'account.analytic.line', + method: 'search_read', + domain: [['task_id', '=', this.res_id], ['user_id', '=', self.record.context['uid']]], + }).then(function (result) { + if (self.mode === 'readonly') { + var currentDate = new Date(); + self.duration = 0; + _.each(result, function (data) { + self.duration += data.date_end ? + self._getDateDifference(data.date_start, data.date_end): + self._getDateDifference(time.auto_str_to_date(data.date_start), currentDate); + }); + } + }); + return $.when(this._super.apply(this, arguments), def); + }, + destroy: function () { + this._super.apply(this, arguments); + clearTimeout(this.timer); + }, + isSet: function () { + return true; + }, + _getDateDifference: function (dateStart, dateEnd) { + return moment(dateEnd).diff(moment(dateStart)); + }, + + _render: function () { + this._startTimeCounter(); + }, + _startTimeCounter: function () { + var self = this; + clearTimeout(this.timer); + if (this.record.data.is_user_working) { + this.timer = setTimeout(function () { + self.duration += 1000; + self._startTimeCounter(); + }, 1000); + } else { + clearTimeout(this.timer); + } + this.$el.html($('' + moment.utc(this.duration).format("HH:mm:ss") + '')); + }, +}); +field_registry.add('timesheet_uoms', TimeCounter); +}); + + diff --git a/project_task_timer/views/project_task_timer_view.xml b/project_task_timer/views/project_task_timer_view.xml new file mode 100644 index 000000000..0911fcb6d --- /dev/null +++ b/project_task_timer/views/project_task_timer_view.xml @@ -0,0 +1,46 @@ + + + + + project task timer + project.task + + + + + +
+ +
+
+
+
+ + + project task timer1 + project.task + + + + + + + + + + + + +
+
\ No newline at end of file diff --git a/project_task_timer/views/project_timer_static.xml b/project_task_timer/views/project_timer_static.xml new file mode 100644 index 000000000..6c3566376 --- /dev/null +++ b/project_task_timer/views/project_timer_static.xml @@ -0,0 +1,8 @@ + + + + \ No newline at end of file diff --git a/whatsapp_redirect/README.rst b/whatsapp_redirect/README.rst new file mode 100644 index 000000000..018d3e233 --- /dev/null +++ b/whatsapp_redirect/README.rst @@ -0,0 +1,45 @@ +.. 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 + +Send Whatsapp Message +===================== +This module helps you to directly send messages to your +contacts through WhatsApp web. + +Configuration +============= +* No additional configurations needed + +Company +------- +* `Cybrosys Techno Solutions `__ + +Credits +------- +* Developers: Nishad@cybrosys + version 13: Nimisha Murali@cybrosys + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com +* Website : https://cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +.. image:: https://cybrosys.com/images/logo.png + :target: https://cybrosys.com + +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit `Our Website `__ + +Further information +=================== +HTML Description: ``__ + + diff --git a/whatsapp_redirect/__init__.py b/whatsapp_redirect/__init__.py new file mode 100644 index 000000000..b8de71b8a --- /dev/null +++ b/whatsapp_redirect/__init__.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Nishad (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import models +from . import wizard diff --git a/whatsapp_redirect/__manifest__.py b/whatsapp_redirect/__manifest__.py new file mode 100644 index 000000000..8b39ba227 --- /dev/null +++ b/whatsapp_redirect/__manifest__.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Nishad (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +{ + 'name': 'Send Whatsapp Message', + 'version': '13.0.1.0.0', + 'summary': 'Send Message to partner via Whatsapp web', + 'description': 'Send Message to partner via Whatsapp web', + 'category': 'Extra Tools', + 'author': 'Cybrosys Techno solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'website': 'https://www.cybrosys.com', + 'depends': [ + 'base', + ], + 'data': [ + 'views/view.xml', + 'wizard/wizard.xml', + ], + 'images': ['static/description/banner.png'], + 'installable': True, + 'application': False, + 'auto_install': False, + 'license': 'AGPL-3', +} diff --git a/whatsapp_redirect/doc/RELEASE_NOTES.md b/whatsapp_redirect/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..4118406d7 --- /dev/null +++ b/whatsapp_redirect/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 10.03.2019 +#### Version 13.0.1.0.0 +##### ADD +- Initial commit for Send Whatsapp Message Module diff --git a/whatsapp_redirect/models/__init__.py b/whatsapp_redirect/models/__init__.py new file mode 100644 index 000000000..b8d0af2fc --- /dev/null +++ b/whatsapp_redirect/models/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +###################################################################################### +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Nishad (Contact : odoo@cybrosys.com) +# +# This program is under the terms of the Odoo Proprietary License v1.0 (OPL-1) +# It is forbidden to publish, distribute, sublicense, or sell copies of the Software +# or modified copies of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +# IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +# DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +# ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +# DEALINGS IN THE SOFTWARE. +# +######################################################################################## +from . import models diff --git a/whatsapp_redirect/models/models.py b/whatsapp_redirect/models/models.py new file mode 100644 index 000000000..1bd80ce9e --- /dev/null +++ b/whatsapp_redirect/models/models.py @@ -0,0 +1,37 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Nishad (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from odoo import models, fields, api, _ + + +class ResPartner(models.Model): + _inherit = 'res.partner' + + + def send_msg(self): + return {'type': 'ir.actions.act_window', + 'name': _('Whatsapp Message'), + 'res_model': 'whatsapp.message.wizard', + 'target': 'new', + 'view_mode': 'form', + 'view_type': 'form', + 'context': {'default_user_id': self.id}, + } diff --git a/whatsapp_redirect/static/description/banner.png b/whatsapp_redirect/static/description/banner.png new file mode 100644 index 000000000..42824da9a Binary files /dev/null and b/whatsapp_redirect/static/description/banner.png differ diff --git a/whatsapp_redirect/static/description/icon.png b/whatsapp_redirect/static/description/icon.png new file mode 100644 index 000000000..a63c3668a Binary files /dev/null and b/whatsapp_redirect/static/description/icon.png differ diff --git a/whatsapp_redirect/static/description/index.html b/whatsapp_redirect/static/description/index.html new file mode 100644 index 000000000..41e491cda --- /dev/null +++ b/whatsapp_redirect/static/description/index.html @@ -0,0 +1,362 @@ +
+
+

+ Whatsapp Web Integration +

+

+ Send messages via whatsapp +

+
+ Cybrosys Technologies +
+ +
+ cybrosys technologies +
+
+
+
+ +
+
+

+ Overview +

+

+ Now chat with your customers WhatsApp...
+ The Whatsapp Web Integration module allows you to chat with customers through whatsapp, one of the popular messaging app. +

+

+ Configuration +

+

+ No additional configuration required +

+
+
+ +
+
+

+ Features +

+

+ + Send messages to partners +

+

+ + User friendly +

+
+
+ +
+
+

+ Screenshots +

+

+ + Enter the whatsapp number +

+
+ +
+

+ + Select 'whatsapp message' from partner form. +

+
+ +
+

+ + Enter the text that you have to send. +

+
+ +
+

+ + Choose Send option +

+
+ +
+

+ + The message is delivered to whatsapp web. +

+
+ +
+ +
+
+ +
+
+ cybrosys technologies +
+
+
+
+

+ Our Services +

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

+ + Odoo Support +

+ +
+ +
+
+
+
+
+

+ Our Industries +

+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Trading + +

+

+ Easily procure and sell your products. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Manufacturing +

+

+ Plan, track and schedule your operations. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Restaurant +

+

+ Run your bar or restaurant methodical. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + POS +

+

+ Easy configuring and convivial selling. +

+
+ +
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + E-commerce & Website +

+

+ Mobile friendly, awe-inspiring product pages. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Hotel Management +

+

+ An all-inclusive hotel management application. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Education +

+

+ A Collaborative platform for educational management. +

+
+
+
+ +
+
+ + Odoo Industry + +
+
+
+

+ + Service Management +

+

+ Keep track of services and invoice accordingly. +

+
+
+
+
+
+
+ +
diff --git a/whatsapp_redirect/static/description/whatsapp-cybrosys-1.png b/whatsapp_redirect/static/description/whatsapp-cybrosys-1.png new file mode 100644 index 000000000..46b1a9200 Binary files /dev/null and b/whatsapp_redirect/static/description/whatsapp-cybrosys-1.png differ diff --git a/whatsapp_redirect/static/description/whatsapp-cybrosys-2.png b/whatsapp_redirect/static/description/whatsapp-cybrosys-2.png new file mode 100644 index 000000000..888ab3bf8 Binary files /dev/null and b/whatsapp_redirect/static/description/whatsapp-cybrosys-2.png differ diff --git a/whatsapp_redirect/static/description/whatsapp-cybrosys-3.png b/whatsapp_redirect/static/description/whatsapp-cybrosys-3.png new file mode 100644 index 000000000..f502628a3 Binary files /dev/null and b/whatsapp_redirect/static/description/whatsapp-cybrosys-3.png differ diff --git a/whatsapp_redirect/static/description/whatsapp-cybrosys-4.png b/whatsapp_redirect/static/description/whatsapp-cybrosys-4.png new file mode 100644 index 000000000..db0f4d586 Binary files /dev/null and b/whatsapp_redirect/static/description/whatsapp-cybrosys-4.png differ diff --git a/whatsapp_redirect/static/description/whatsapp-cybrosys-5.png b/whatsapp_redirect/static/description/whatsapp-cybrosys-5.png new file mode 100644 index 000000000..345ac3f91 Binary files /dev/null and b/whatsapp_redirect/static/description/whatsapp-cybrosys-5.png differ diff --git a/whatsapp_redirect/views/view.xml b/whatsapp_redirect/views/view.xml new file mode 100644 index 000000000..cef1590ca --- /dev/null +++ b/whatsapp_redirect/views/view.xml @@ -0,0 +1,17 @@ + + + + + res.partner.form + res.partner + + + +
+
+
+
+
+
+
\ No newline at end of file diff --git a/whatsapp_redirect/wizard/__init__.py b/whatsapp_redirect/wizard/__init__.py new file mode 100644 index 000000000..3777c006c --- /dev/null +++ b/whatsapp_redirect/wizard/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Nishad (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import wizard diff --git a/whatsapp_redirect/wizard/wizard.py b/whatsapp_redirect/wizard/wizard.py new file mode 100644 index 000000000..045ab4b5a --- /dev/null +++ b/whatsapp_redirect/wizard/wizard.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Nishad (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from odoo import models, api, fields + + +class WhatsappSendMessage(models.TransientModel): + + _name = 'whatsapp.message.wizard' + + user_id = fields.Many2one('res.partner', string="Recipient") + mobile = fields.Char(related='user_id.mobile', required=True) + message = fields.Text(string="message", required=True) + + def send_message(self): + if self.message and self.mobile: + message_string = '' + message = self.message.split(' ') + for msg in message: + message_string = message_string + msg + '%20' + message_string = message_string[:(len(message_string) - 3)] + return { + 'type': 'ir.actions.act_url', + 'url': "https://api.whatsapp.com/send?phone="+self.user_id.mobile+"&text=" + message_string, + 'target': 'self', + 'res_id': self.id, + } diff --git a/whatsapp_redirect/wizard/wizard.xml b/whatsapp_redirect/wizard/wizard.xml new file mode 100644 index 000000000..30395a65b --- /dev/null +++ b/whatsapp_redirect/wizard/wizard.xml @@ -0,0 +1,25 @@ + + + + + whatsapp.message.wizard.form + whatsapp.message.wizard + + +
+ + + + + + + + +
+
+
+
+
\ No newline at end of file