diff --git a/scrap_management/README.rst b/scrap_management/README.rst deleted file mode 100644 index b5e33287d..000000000 --- a/scrap_management/README.rst +++ /dev/null @@ -1,48 +0,0 @@ -.. image:: https://img.shields.io/badge/license-AGPL--3-blue.svg - :target: https://www.gnu.org/licenses/agpl-3.0-standalone.html - :alt: License: AGPL-3 - -Automated Scrap Order -===================== -Manage your scrap products automatically based on their expiration date. - -Configuration -------------- - - www.odoo.com/documentation/16.0/setup/install.html - - Install our custom addon - -Company -------- -* `Cybrosys Techno Solutions `__ - -License -------- -Affero General Public License v3.0 (AGPL v3) -(https://www.gnu.org/licenses/agpl-3.0-standalone.html) - -Credits -------- -Developer : (V16) Shafna K, 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: ``__ \ No newline at end of file diff --git a/scrap_management/__init__.py b/scrap_management/__init__.py deleted file mode 100644 index 9e4996d07..000000000 --- a/scrap_management/__init__.py +++ /dev/null @@ -1,25 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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 controllers -from . import models -from . import report -from . import wizard diff --git a/scrap_management/__manifest__.py b/scrap_management/__manifest__.py deleted file mode 100644 index 94560fc41..000000000 --- a/scrap_management/__manifest__.py +++ /dev/null @@ -1,55 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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': "Automated Scrap Order", - 'version': '16.0.1.0.0', - 'category': 'Warehouse', - 'summary': 'To manage scrap orders automatically based on expiry.', - 'description': "This module automates the creation of scrap orders based" - "on product expiry dates and generates a report for" - " tracking and managing the disposal of expired products" - "which moved to the scrap.", - 'author': " Cybrosys Techno Solutions", - 'company': 'Cybrosys Techno Solutions', - 'maintainer': 'Cybrosys Techno Solutions', - 'website': 'https://www.cybrosys.com', - 'depends': ['stock', 'product_expiry'], - 'data': [ - 'security/ir.model.access.csv', - 'data/ir_cron_data.xml', - 'views/res_config_settings_views.xml', - 'views/stock_lot_views.xml', - 'report/scrap_management_reports.xml', - 'report/scrap_management_templates.xml', - 'wizard/scrap_report_views.xml', - ], - 'assets': { - 'web.assets_backend': [ - 'scrap_management/static/src/js/scrap_management.js' - ], - }, - 'images': ['static/description/banner.jpg'], - 'license': 'AGPL-3', - 'installable': True, - 'auto_install': False, - 'application': False, -} diff --git a/scrap_management/controllers/__init__.py b/scrap_management/controllers/__init__.py deleted file mode 100644 index 9898dd162..000000000 --- a/scrap_management/controllers/__init__.py +++ /dev/null @@ -1,22 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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 scrap_management diff --git a/scrap_management/controllers/scrap_management.py b/scrap_management/controllers/scrap_management.py deleted file mode 100644 index e0034d0f2..000000000 --- a/scrap_management/controllers/scrap_management.py +++ /dev/null @@ -1,57 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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 json -from odoo import http -from odoo.http import content_disposition, request -from odoo.tools import html_escape - - -class ScrapManagementXLSVReport(http.Controller): - """To create the route for xlsx report""" - @http.route('/report_xlsx', type='http', auth='user', methods=['POST'], - csrf=False) - def get_report_xlsx(self, model, options, output_format, report_name): - """To generate the response""" - report_obj = request.env[model].with_user(request.session.uid) - options = json.loads(options) - token = 'dummy-because-api-expects-one' - try: - if output_format == 'xlsx': - response = request.make_response( - None, - headers=[ - ('Content-Type', 'application/vnd.ms-excel'), - ('Content-Disposition', - content_disposition(report_name + '.xlsx')) - ] - ) - report_obj.get_xlsx_report(options, response) - response.set_cookie('fileToken', token) - return response - except Exception as e: - se = http.serialize_exception(e) - error = { - 'code': 200, - 'message': 'Odoo Server Error', - 'data': se - } - return request.make_response(html_escape(json.dumps(error))) diff --git a/scrap_management/data/ir_cron_data.xml b/scrap_management/data/ir_cron_data.xml deleted file mode 100644 index 0a8599464..000000000 --- a/scrap_management/data/ir_cron_data.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - Scrap Management - - code - model.action_scrap_order() - - 1 - days - -1 - - - \ No newline at end of file diff --git a/scrap_management/doc/RELEASE_NOTES.md b/scrap_management/doc/RELEASE_NOTES.md deleted file mode 100644 index 9922a57fa..000000000 --- a/scrap_management/doc/RELEASE_NOTES.md +++ /dev/null @@ -1,7 +0,0 @@ -## Module - -#### 30.11.2023 -#### Version 16.0.1.0.0 -#### ADD - -- Initial Commit for Automated Scrap Order diff --git a/scrap_management/models/__init__.py b/scrap_management/models/__init__.py deleted file mode 100644 index e568ed633..000000000 --- a/scrap_management/models/__init__.py +++ /dev/null @@ -1,23 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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 res_config_settings -from . import stock_lot diff --git a/scrap_management/models/res_config_settings.py b/scrap_management/models/res_config_settings.py deleted file mode 100644 index 8b69573b1..000000000 --- a/scrap_management/models/res_config_settings.py +++ /dev/null @@ -1,35 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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 - - -class ResConfigSettings(models.TransientModel): - """This contains the fields added in configuration settings""" - _inherit = "res.config.settings" - - move_to_scrap = fields.Boolean( - string="Move To Scrap", store=True, - config_parameter='scrap_management.move_to_scrap', - help="Product will move to scrap after expiry") - move_to_scrap_days = fields.Integer( - string="After", config_parameter='scrap_management.move_to_scrap_days', - store=True, help="Move to scrap after these days") diff --git a/scrap_management/models/stock_lot.py b/scrap_management/models/stock_lot.py deleted file mode 100644 index 80d1017eb..000000000 --- a/scrap_management/models/stock_lot.py +++ /dev/null @@ -1,75 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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 datetime -from odoo import api, fields, models - - -class StockLot(models.Model): - """To add fields in stock lot and compute move date""" - _inherit = "stock.lot" - - move_date = fields.Datetime(string="Move Date", - help="Date which product need to be moved to " - "scrap", compute='_compute_move_date') - move_scrap = fields.Boolean(string="Move To Scrap", - help="Enable to automatically move product to " - "scrap based on expiry date", - compute='_compute_move_scrap') - - @api.depends('product_id', 'expiration_date', 'move_scrap') - def _compute_move_date(self): - """Compute function to calculate the date of moving to scrap based on - expiration date and days given in configuration settings""" - self.move_date = False - for rec in self: - if rec.product_id.use_expiration_date: - move_days = self.env['ir.config_parameter'].sudo().get_param( - 'scrap_management.move_to_scrap_days') - if not rec.product_id.use_expiration_date and not \ - rec.move_scrap and rec.product_qty <= 0: - rec.move_date = False - elif rec.expiration_date and rec.move_scrap and \ - rec.product_qty > 0: - rec.move_date = rec.expiration_date + datetime.timedelta( - days=int(move_days)) - - def _compute_move_scrap(self): - """Compute function to get the value of boolean field whether move to - scrap based on expiration date or not""" - for rec in self: - rec.move_scrap = rec.env['ir.config_parameter'].sudo().get_param( - 'scrap_management.move_to_scrap') - - def action_scrap_order(self): - """To create a scrap order automatically when product is expired""" - today_start = fields.Date.start_of(fields.Datetime.today(), 'day') - today_end = fields.Date.end_of(fields.Datetime.today(), 'day') - for rec in self.env['stock.lot'].search([]): - if rec.expiration_date and rec.move_date: - expiry_date = rec.filtered( - lambda date: today_start <= date.move_date <= today_end) - for recs in expiry_date: - self.env['stock.scrap'].create({ - 'product_id': recs.product_id.id, - 'lot_id': recs.id, - 'scrap_qty': recs.product_qty, - }) diff --git a/scrap_management/report/__init__.py b/scrap_management/report/__init__.py deleted file mode 100644 index 8b8b335d6..000000000 --- a/scrap_management/report/__init__.py +++ /dev/null @@ -1,22 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna (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 scrap_management_reports diff --git a/scrap_management/report/scrap_management_reports.py b/scrap_management/report/scrap_management_reports.py deleted file mode 100644 index 8b0e49936..000000000 --- a/scrap_management/report/scrap_management_reports.py +++ /dev/null @@ -1,57 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna (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 api, models - - -class ScrapManagementReport(models.AbstractModel): - """To generate report based on query and get report values""" - _name = "report.scrap_management.report_scrap_order" - - @api.model - def _get_report_values(self, docids, data=None): - """ To get the report values based on the user giving conditions""" - value = self.query_data(data['from_date'], data['to_date'], - data['product_id']) - return { - 'var': value - } - - def query_data(self, from_date, to_date, product_id): - """ To fetch values from database using query""" - query = """select product_template.name as product, - stock_scrap.scrap_qty as quantity,DATE(stock_scrap.date_done) as - date from stock_scrap inner join product_product on - stock_scrap.product_id = product_product.id inner join - product_template on product_template.id = - product_product.product_tmpl_id where stock_scrap.state='done'""" - if product_id: - query += """ and product_template.id=%(product_id)s""" - if from_date: - query += """ and DATE(stock_scrap.date_done) >= %(from_date)s""" - if to_date: - query += """ and DATE(stock_scrap.date_done) <= %(to_date)s""" - self.env.cr.execute(query, - {'from_date': from_date, - 'to_date': to_date, - 'product_id': product_id, - }) - return self.env.cr.dictfetchall() diff --git a/scrap_management/report/scrap_management_reports.xml b/scrap_management/report/scrap_management_reports.xml deleted file mode 100644 index 3f217e0db..000000000 --- a/scrap_management/report/scrap_management_reports.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - Scrap Order Report - stock.scrap - qweb-pdf - scrap_management.report_scrap_order - scrap_management.report_scrap_order - ’Scrap Order Report - %s' - report - - \ No newline at end of file diff --git a/scrap_management/report/scrap_management_templates.xml b/scrap_management/report/scrap_management_templates.xml deleted file mode 100644 index bdfa00ab8..000000000 --- a/scrap_management/report/scrap_management_templates.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - \ No newline at end of file diff --git a/scrap_management/security/ir.model.access.csv b/scrap_management/security/ir.model.access.csv deleted file mode 100644 index 15f324a24..000000000 --- a/scrap_management/security/ir.model.access.csv +++ /dev/null @@ -1,2 +0,0 @@ -id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink -access_scrap_report,access.scrap.report,model_scrap_report,base.group_user,1,1,1,1 diff --git a/scrap_management/static/description/assets/icons/check.png b/scrap_management/static/description/assets/icons/check.png deleted file mode 100644 index c8e85f51d..000000000 Binary files a/scrap_management/static/description/assets/icons/check.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/chevron.png b/scrap_management/static/description/assets/icons/chevron.png deleted file mode 100644 index 2089293d6..000000000 Binary files a/scrap_management/static/description/assets/icons/chevron.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/cogs.png b/scrap_management/static/description/assets/icons/cogs.png deleted file mode 100644 index 95d0bad62..000000000 Binary files a/scrap_management/static/description/assets/icons/cogs.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/consultation.png b/scrap_management/static/description/assets/icons/consultation.png deleted file mode 100644 index 8319d4baa..000000000 Binary files a/scrap_management/static/description/assets/icons/consultation.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/ecom-black.png b/scrap_management/static/description/assets/icons/ecom-black.png deleted file mode 100644 index a9385ff13..000000000 Binary files a/scrap_management/static/description/assets/icons/ecom-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/education-black.png b/scrap_management/static/description/assets/icons/education-black.png deleted file mode 100644 index 3eb09b27b..000000000 Binary files a/scrap_management/static/description/assets/icons/education-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/hotel-black.png b/scrap_management/static/description/assets/icons/hotel-black.png deleted file mode 100644 index 130f613be..000000000 Binary files a/scrap_management/static/description/assets/icons/hotel-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/license.png b/scrap_management/static/description/assets/icons/license.png deleted file mode 100644 index a5869797e..000000000 Binary files a/scrap_management/static/description/assets/icons/license.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/lifebuoy.png b/scrap_management/static/description/assets/icons/lifebuoy.png deleted file mode 100644 index 658d56ccc..000000000 Binary files a/scrap_management/static/description/assets/icons/lifebuoy.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/manufacturing-black.png b/scrap_management/static/description/assets/icons/manufacturing-black.png deleted file mode 100644 index 697eb0e9f..000000000 Binary files a/scrap_management/static/description/assets/icons/manufacturing-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/pos-black.png b/scrap_management/static/description/assets/icons/pos-black.png deleted file mode 100644 index 97c0f90c1..000000000 Binary files a/scrap_management/static/description/assets/icons/pos-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/puzzle.png b/scrap_management/static/description/assets/icons/puzzle.png deleted file mode 100644 index 65cf854e7..000000000 Binary files a/scrap_management/static/description/assets/icons/puzzle.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/restaurant-black.png b/scrap_management/static/description/assets/icons/restaurant-black.png deleted file mode 100644 index 4a35eb939..000000000 Binary files a/scrap_management/static/description/assets/icons/restaurant-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/service-black.png b/scrap_management/static/description/assets/icons/service-black.png deleted file mode 100644 index 301ab51cb..000000000 Binary files a/scrap_management/static/description/assets/icons/service-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/trading-black.png b/scrap_management/static/description/assets/icons/trading-black.png deleted file mode 100644 index 9398ba2f1..000000000 Binary files a/scrap_management/static/description/assets/icons/trading-black.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/training.png b/scrap_management/static/description/assets/icons/training.png deleted file mode 100644 index 884ca024d..000000000 Binary files a/scrap_management/static/description/assets/icons/training.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/update.png b/scrap_management/static/description/assets/icons/update.png deleted file mode 100644 index ecbc5a01a..000000000 Binary files a/scrap_management/static/description/assets/icons/update.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/user.png b/scrap_management/static/description/assets/icons/user.png deleted file mode 100644 index 6ffb23d9f..000000000 Binary files a/scrap_management/static/description/assets/icons/user.png and /dev/null differ diff --git a/scrap_management/static/description/assets/icons/wrench.png b/scrap_management/static/description/assets/icons/wrench.png deleted file mode 100644 index 6c04dea0f..000000000 Binary files a/scrap_management/static/description/assets/icons/wrench.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/categories.png b/scrap_management/static/description/assets/misc/categories.png deleted file mode 100644 index bedf1e0b1..000000000 Binary files a/scrap_management/static/description/assets/misc/categories.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/check-box.png b/scrap_management/static/description/assets/misc/check-box.png deleted file mode 100644 index 42caf24b9..000000000 Binary files a/scrap_management/static/description/assets/misc/check-box.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/compass.png b/scrap_management/static/description/assets/misc/compass.png deleted file mode 100644 index d5fed8faa..000000000 Binary files a/scrap_management/static/description/assets/misc/compass.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/corporate.png b/scrap_management/static/description/assets/misc/corporate.png deleted file mode 100644 index 2eb13edbf..000000000 Binary files a/scrap_management/static/description/assets/misc/corporate.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/customer-support.png b/scrap_management/static/description/assets/misc/customer-support.png deleted file mode 100644 index 79efc72ed..000000000 Binary files a/scrap_management/static/description/assets/misc/customer-support.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/cybrosys-logo.png b/scrap_management/static/description/assets/misc/cybrosys-logo.png deleted file mode 100644 index cc3cc0ccf..000000000 Binary files a/scrap_management/static/description/assets/misc/cybrosys-logo.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/features.png b/scrap_management/static/description/assets/misc/features.png deleted file mode 100644 index b41769f77..000000000 Binary files a/scrap_management/static/description/assets/misc/features.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/logo.png b/scrap_management/static/description/assets/misc/logo.png deleted file mode 100644 index 478462d3e..000000000 Binary files a/scrap_management/static/description/assets/misc/logo.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/pictures.png b/scrap_management/static/description/assets/misc/pictures.png deleted file mode 100644 index 56d255fe9..000000000 Binary files a/scrap_management/static/description/assets/misc/pictures.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/pie-chart.png b/scrap_management/static/description/assets/misc/pie-chart.png deleted file mode 100644 index 426e05244..000000000 Binary files a/scrap_management/static/description/assets/misc/pie-chart.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/right-arrow.png b/scrap_management/static/description/assets/misc/right-arrow.png deleted file mode 100644 index 730984a06..000000000 Binary files a/scrap_management/static/description/assets/misc/right-arrow.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/star.png b/scrap_management/static/description/assets/misc/star.png deleted file mode 100644 index 2eb9ab29f..000000000 Binary files a/scrap_management/static/description/assets/misc/star.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/support.png b/scrap_management/static/description/assets/misc/support.png deleted file mode 100644 index 4f18b8b82..000000000 Binary files a/scrap_management/static/description/assets/misc/support.png and /dev/null differ diff --git a/scrap_management/static/description/assets/misc/whatsapp.png b/scrap_management/static/description/assets/misc/whatsapp.png deleted file mode 100644 index d513a5356..000000000 Binary files a/scrap_management/static/description/assets/misc/whatsapp.png and /dev/null differ diff --git a/scrap_management/static/description/assets/modules/1.jpg b/scrap_management/static/description/assets/modules/1.jpg deleted file mode 100644 index c11ba602a..000000000 Binary files a/scrap_management/static/description/assets/modules/1.jpg and /dev/null differ diff --git a/scrap_management/static/description/assets/modules/2.png b/scrap_management/static/description/assets/modules/2.png deleted file mode 100644 index e281bd660..000000000 Binary files a/scrap_management/static/description/assets/modules/2.png and /dev/null differ diff --git a/scrap_management/static/description/assets/modules/3.png b/scrap_management/static/description/assets/modules/3.png deleted file mode 100644 index 66e5f3dd1..000000000 Binary files a/scrap_management/static/description/assets/modules/3.png and /dev/null differ diff --git a/scrap_management/static/description/assets/modules/4.png b/scrap_management/static/description/assets/modules/4.png deleted file mode 100644 index d21466f5f..000000000 Binary files a/scrap_management/static/description/assets/modules/4.png and /dev/null differ diff --git a/scrap_management/static/description/assets/modules/5.png b/scrap_management/static/description/assets/modules/5.png deleted file mode 100644 index baaa60084..000000000 Binary files a/scrap_management/static/description/assets/modules/5.png and /dev/null differ diff --git a/scrap_management/static/description/assets/modules/6.png b/scrap_management/static/description/assets/modules/6.png deleted file mode 100644 index 956a7e9c7..000000000 Binary files a/scrap_management/static/description/assets/modules/6.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-01.png b/scrap_management/static/description/assets/screenshots/scrap-01.png deleted file mode 100644 index 1db99ea6d..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-01.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-02.png b/scrap_management/static/description/assets/screenshots/scrap-02.png deleted file mode 100644 index fb23c20e0..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-02.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-03.png b/scrap_management/static/description/assets/screenshots/scrap-03.png deleted file mode 100644 index 1437b2a18..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-03.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-04.png b/scrap_management/static/description/assets/screenshots/scrap-04.png deleted file mode 100644 index 11aadaac7..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-04.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-05.png b/scrap_management/static/description/assets/screenshots/scrap-05.png deleted file mode 100644 index 1dadf6cad..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-05.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-06.png b/scrap_management/static/description/assets/screenshots/scrap-06.png deleted file mode 100644 index 4970999f2..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-06.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-07.png b/scrap_management/static/description/assets/screenshots/scrap-07.png deleted file mode 100644 index 39149368b..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-07.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-08.png b/scrap_management/static/description/assets/screenshots/scrap-08.png deleted file mode 100644 index 603868187..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-08.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-09.png b/scrap_management/static/description/assets/screenshots/scrap-09.png deleted file mode 100644 index 0b8e985d2..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-09.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap-10.png b/scrap_management/static/description/assets/screenshots/scrap-10.png deleted file mode 100644 index 486a17904..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap-10.png and /dev/null differ diff --git a/scrap_management/static/description/assets/screenshots/scrap.gif b/scrap_management/static/description/assets/screenshots/scrap.gif deleted file mode 100644 index 4a9e3872c..000000000 Binary files a/scrap_management/static/description/assets/screenshots/scrap.gif and /dev/null differ diff --git a/scrap_management/static/description/banner.jpg b/scrap_management/static/description/banner.jpg deleted file mode 100644 index 31ed9ccbf..000000000 Binary files a/scrap_management/static/description/banner.jpg and /dev/null differ diff --git a/scrap_management/static/description/icon.png b/scrap_management/static/description/icon.png deleted file mode 100644 index bb189eaf7..000000000 Binary files a/scrap_management/static/description/icon.png and /dev/null differ diff --git a/scrap_management/static/description/index.html b/scrap_management/static/description/index.html deleted file mode 100644 index 0f37b8f0f..000000000 --- a/scrap_management/static/description/index.html +++ /dev/null @@ -1,609 +0,0 @@ -
- -
- -
-
- Community -
-
- Enterprise -
-
- Odoo.sh -
-
-
- -
-
-
- -

- Automated Scrap Order -

-

- This Module helps to Manage Products Based on Expiry Date - and Moves to Scrap. -

- - -
-
-
-
- -
-
- -
-

- Explore This Module

-
- - - -
-
- -
-

- Overview -

-
-
-
- This module helps to manage the Scrap Orders based on expiration date in - Odoo. This checks the expiry date of a product and move to scrap if it - is expired. We can also get the complete report of it using the scrap - report option. -
-
- - -
-
- -
-

- Features -

-
-
-
-
- - Simplified Scrap Management -
-
- - Manages Scrap orders for Expired Product -
-
- - Automatic creation of orders based on Expiry -
-
- - Easier Analysis using Scrap Order Reports. -
-
-
- - -
-
- -
-

- Screenshots -

-
-
-
-
-

- Enable Move to Scrap Option in Configuration Settings -

- -
-
-

- Enable the Tracking and Expiration Date in Product -

- -
-
-

- Create a Receipt Transfer and Provide Lot Number and Expiration - Date for the Product. -

- -
-
-

- Move Date in Lot and Serial Number will be calculated based on - Expiry of Product -

- -
-
-

- Automatic Scrap Orders in Draft Stage will be created based on - Move Date -

- -
-
-

- Validate the Scrap Orders -

- -
-
-

- View Reporting of Scrap Orders from Reporting → Scrap Order. -

- -
-
-

- A Wizard Opens with Fields to Filter the Reports.Users can - Filter the Records Based on the Values Providing or Leave Empty - to Include All Values. -

- -
-
-

- By Clicking on Print PDF Button, you can get PDF Reporting of - Scrap Orders. Below is the Sample Report. -

- -
-
-

- By Clicking on Print XLSX Button, you can get the Scrap Order - Reporting in Excel Format. -

- -
-
-
- - -
-
- -
-

- Related Products -

-
-
-
- -
-
- - -
-
- -
-

- Our Services

-
-
-
-
-
- -
-
- Odoo Customization
-
-
-
- -
-
- Odoo Implementation
-
-
-
- -
-
- Odoo Support
-
-
-
- -
-
- Hire Odoo Developer
-
-
-
- -
-
- Odoo Integration
-
-
-
- -
-
- Odoo Migration
-
-
-
- -
-
- Odoo Consultancy
-
-
-
- -
-
- Odoo Implementation
-
-
-
- -
-
- Odoo Licensing Consultancy
-
-
-
- - -
-
- -
-

- Our Industries -

-
-
-
-
-
- -
- Trading
-

- Easily procure and sell your products

-
-
-
-
- -
- POS
-

- Easy configuration and convivial experience

-
-
-
-
- -
- Education
-

- A platform for educational management

-
-
-
-
- -
- Manufacturing
-

- Plan, track and schedule your operations

-
-
-
-
- -
- E-commerce & Website
-

- Mobile friendly, awe-inspiring product pages

-
-
-
-
- -
- Service Management
-

- Keep track of services and invoice

-
-
-
-
- -
- Restaurant
-

- Run your bar or restaurant methodically

-
-
-
-
- -
- Hotel Management
-

- An all-inclusive hotel management application

-
-
-
-
- - -
-
- -
-

- Support -

-
-
-
-
-
-
- -
-
-

Need Help?

-

Got questions or need help? - Get in touch.

- -

- odoo@cybrosys.com

-
-
-
-
-
-
-
- -
-
-

WhatsApp

-

Say hi to us on WhatsApp!

- -

- +91 86068 27707

-
-
-
-
-
-
-
- -
-
-
- \ No newline at end of file diff --git a/scrap_management/static/src/js/scrap_management.js b/scrap_management/static/src/js/scrap_management.js deleted file mode 100644 index 6c71771a9..000000000 --- a/scrap_management/static/src/js/scrap_management.js +++ /dev/null @@ -1,21 +0,0 @@ -/** @odoo-module */ -/** - * registers a new handler to generate xlsx report - */ -import { registry } from "@web/core/registry"; -import framework from 'web.framework'; -import session from 'web.session'; -registry.category("ir.actions.report handlers").add("reportXlsx", async (action) => { - if (action.report_type === 'xlsx') { - framework.blockUI(); - var def = $.Deferred(); - session.get_file({ - url: '/report_xlsx', - data: action.data, - success: def.resolve.bind(def), - error: (error) => this.call('crash_manager', 'rpc_error', error), - complete: framework.unblockUI, - }); - return def; - } -}); \ No newline at end of file diff --git a/scrap_management/views/res_config_settings_views.xml b/scrap_management/views/res_config_settings_views.xml deleted file mode 100644 index 4f38c1eb6..000000000 --- a/scrap_management/views/res_config_settings_views.xml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - res.config.settings.view.form.inherit.scrap.management - - res.config.settings - - - -
-
- -
-
-
-
-
-
-
-
\ No newline at end of file diff --git a/scrap_management/views/stock_lot_views.xml b/scrap_management/views/stock_lot_views.xml deleted file mode 100644 index d4aaf7919..000000000 --- a/scrap_management/views/stock_lot_views.xml +++ /dev/null @@ -1,15 +0,0 @@ - - - - - stock.lot.view.form.inherit.scrap.management - stock.lot - - - - - - - - - \ No newline at end of file diff --git a/scrap_management/wizard/__init__.py b/scrap_management/wizard/__init__.py deleted file mode 100644 index 187b6fa30..000000000 --- a/scrap_management/wizard/__init__.py +++ /dev/null @@ -1,22 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna (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 scrap_report diff --git a/scrap_management/wizard/scrap_report.py b/scrap_management/wizard/scrap_report.py deleted file mode 100644 index 347df69cc..000000000 --- a/scrap_management/wizard/scrap_report.py +++ /dev/null @@ -1,134 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################### -# -# Cybrosys Technologies Pvt. Ltd. -# -# Copyright (C) 2023-TODAY Cybrosys Technologies() -# Author: Shafna K(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 io -import json -from odoo import fields, models, _ -from odoo.exceptions import ValidationError -from odoo.tools import date_utils - -try: - from odoo.tools.misc import xlsxwriter -except ImportError: - import xlsxwriter - - -class ScrapReport(models.TransientModel): - """Transient model to give the input values for the - generation of report values""" - _name = "scrap.report" - _description = "Scrap Report Wizard" - - from_date = fields.Date(string="From Date", help="From this date report" - "values are taken") - to_date = fields.Date(string="To Date", help="To this date the report " - "values are taken") - product_id = fields.Many2one('product.product', string="Product", - help="choose the product of which the detail " - "should be known") - - def action_pdf_report(self): - """ To pass values in wizard""" - if self.from_date and self.to_date: - if self.from_date > self.to_date: - raise ValidationError(_("From Date can't be greater than" - " to date")) - if self.from_date: - if self.from_date > fields.Date.today(): - raise ValidationError(_("From date cannot be future date")) - data = { - 'model_id': self.id, - 'from_date': self.from_date, - 'to_date': self.to_date, - 'product_id': self.product_id.product_tmpl_id.id, - } - return self.env.ref( - 'scrap_management.scrap_order_report').report_action( - None, data=data) - - def action_xlsx_report(self): - """ To print the XLSX report type""" - if self.from_date and self.to_date: - if self.from_date > self.to_date: - raise ValidationError(_("From date can't be greater than " - "To date")) - if self.from_date: - if self.from_date > fields.Date.today(): - raise ValidationError(_("From date cannot be future date")) - query = self.env[ - 'report.scrap_management.report_scrap_order'].query_data( - self.from_date, self.to_date, self.product_id.product_tmpl_id.id) - data = { - 'from_date': self.from_date, - 'to_date': self.to_date, - 'product_id': self.product_id.product_tmpl_id.id, - 'var': query - } - return { - 'type': 'ir.actions.report', - 'data': {'model': 'scrap.report', - 'options': json.dumps(data, - default=date_utils.json_default), - 'output_format': 'xlsx', - 'report_name': 'Scrap Order Report', - }, - 'report_type': 'xlsx', - } - - def get_xlsx_report(self, data, response): - """To get the report values for xlsx report""" - from_date = data['from_date'] - to_date = data['to_date'] - output = io.BytesIO() - workbook = xlsxwriter.Workbook(output, {'in_memory': True}) - sheet = workbook.add_worksheet() - cell_format = workbook.add_format( - {'font_size': '12px', 'bold': True, 'align': 'center'}) - head = workbook.add_format( - {'align': 'center', 'bold': True, 'font_size': '20px'}) - txt = workbook.add_format({'font_size': '10px', 'align': 'left'}) - txt_head = workbook.add_format({'font_size': '10px', 'align': 'left', - 'bold': True}) - sheet.set_column(0, 0, 20) - sheet.set_column(1, 1, 10) - sheet.set_column(2, 2, 10) - sheet.merge_range('A1:B1', 'Report Date:'+str(fields.Date.today()), - txt_head) - sheet.merge_range('A2:D3', 'SCRAP ORDER REPORT', head) - if from_date: - sheet.write('A4', 'From Date:', txt_head) - sheet.write('A5', from_date, txt) - if to_date: - sheet.write('B4', 'To Date:', txt_head) - sheet.write('B5', to_date, txt) - sheet.write('A6', 'Product', cell_format) - sheet.write('B6', 'Quantity', cell_format) - sheet.write('C6', 'Date', cell_format) - row = 6 - for records in data['var']: - sheet.write(row, 0, records['product']['en_US'], txt) - sheet.write(row, 1, records['quantity'], txt) - sheet.write(row, 2, records['date'], txt) - row += 1 - workbook.close() - output.seek(0) - response.stream.write(output.read()) - output.close() diff --git a/scrap_management/wizard/scrap_report_views.xml b/scrap_management/wizard/scrap_report_views.xml deleted file mode 100644 index ca8008c9b..000000000 --- a/scrap_management/wizard/scrap_report_views.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - - - scrap.report.view.form - scrap.report - -
- - - - - - - - - -
-
-
-
-
- - - Scrap Order Report - scrap.report - form - - new - - - -
\ No newline at end of file