@ -1,21 +1,22 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2022-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# This program is free software: you can modify |
|||
# it under the terms of the GNU Affero General Public License (AGPL) as |
|||
# published by the Free Software Foundation, either version 3 of the |
|||
# License, or (at your option) any later version. |
|||
# 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 for more details. |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU Affero General Public License |
|||
# along with this program. If not, see <https://www.gnu.org/licenses/>. |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
|
|||
from . import models |
|||
|
@ -1,42 +1,43 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2022-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# This program is free software: you can modify |
|||
# it under the terms of the GNU Affero General Public License (AGPL) as |
|||
# published by the Free Software Foundation, either version 3 of the |
|||
# License, or (at your option) any later version. |
|||
# 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 for more details. |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU Affero General Public License |
|||
# along with this program. If not, see <https://www.gnu.org/licenses/>. |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
|
|||
{ |
|||
'name': 'Out Of Stock Products Restriction On Sales', |
|||
'name': 'Sale Stock Restrict', |
|||
'version': '16.0.1.0.0', |
|||
'summary': 'Out Of Stock Products Restriction On Sales', |
|||
'description': """Out Of Stock Products Restriction On Sales""", |
|||
'category': 'Sales/Sales', |
|||
'category': 'Sales', |
|||
'summary': 'Module helps to restrict out of stock products', |
|||
'description': """This module helps manage out-of-stock products based on |
|||
on-hand or forecast quantity.""", |
|||
'author': 'Cybrosys Techno solutions', |
|||
'company': 'Cybrosys Techno Solutions', |
|||
'maintainer': 'Cybrosys Techno Solutions', |
|||
'website': 'https://www.cybrosys.com', |
|||
'depends': ['base', 'sale_management', 'stock', 'account'], |
|||
'depends': ['base', 'sale_management', 'stock', 'account','website_sale'], |
|||
'data': [ |
|||
'views/res_config_views.xml', |
|||
'views/res_config_settings_views.xml', |
|||
'views/sale_order.xml', |
|||
], |
|||
'images': ['static/description/banner.png'], |
|||
'images': ['static/description/banner.jpg'], |
|||
'license': 'AGPL-3', |
|||
'installable': True, |
|||
'application': False, |
|||
'auto_install': False, |
|||
'license': 'AGPL-3', |
|||
|
|||
'application': False, |
|||
} |
|||
|
@ -1,6 +1,6 @@ |
|||
## Module <sale_stock_restrict> |
|||
|
|||
#### 03.01.2023 |
|||
#### Version 16.0.1.0.0 |
|||
#### 25.01.2024 |
|||
#### Version 17.0.1.0.0 |
|||
#### ADD |
|||
- Initial Commit |
|||
- Initial Commit for Sale Stock Restrict |
|||
|
@ -1,22 +1,23 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2022-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Copyright (C) 2024-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# This program is free software: you can modify |
|||
# it under the terms of the GNU Affero General Public License (AGPL) as |
|||
# published by the Free Software Foundation, either version 3 of the |
|||
# License, or (at your option) any later version. |
|||
# 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 for more details. |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU Affero General Public License |
|||
# along with this program. If not, see <https://www.gnu.org/licenses/>. |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
|
|||
from . import res_config |
|||
from . import res_config_settings |
|||
from . import sale_order |
|||
|
After Width: | Height: | Size: 36 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 11 KiB |
After Width: | Height: | Size: 80 KiB |
Before Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.9 KiB |
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 4.4 KiB |
After Width: | Height: | Size: 3.2 KiB |
Before Width: | Height: | Size: 589 B |
Before Width: | Height: | Size: 3.4 KiB |
After Width: | Height: | Size: 565 B |
Before Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 2.3 KiB |
Before Width: | Height: | Size: 967 B |
After Width: | Height: | Size: 26 KiB |
Before Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 43 KiB |
After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 3.8 KiB |
After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 38 KiB |
Before Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 4.3 KiB |
Before Width: | Height: | Size: 84 KiB After Width: | Height: | Size: 49 KiB |
Before Width: | Height: | Size: 56 KiB After Width: | Height: | Size: 48 KiB |
Before Width: | Height: | Size: 56 KiB After Width: | Height: | Size: 82 KiB |
Before Width: | Height: | Size: 59 KiB After Width: | Height: | Size: 90 KiB |
Before Width: | Height: | Size: 1.3 MiB |
After Width: | Height: | Size: 79 KiB |
After Width: | Height: | Size: 82 KiB |
Before Width: | Height: | Size: 81 KiB |
After Width: | Height: | Size: 107 KiB |
After Width: | Height: | Size: 104 KiB |
After Width: | Height: | Size: 135 KiB |
After Width: | Height: | Size: 155 KiB |
After Width: | Height: | Size: 104 KiB |
After Width: | Height: | Size: 135 KiB |
After Width: | Height: | Size: 171 KiB |
Before Width: | Height: | Size: 247 KiB After Width: | Height: | Size: 302 KiB |
Before Width: | Height: | Size: 121 KiB |
Before Width: | Height: | Size: 121 KiB |
Before Width: | Height: | Size: 114 KiB |
Before Width: | Height: | Size: 138 KiB |
Before Width: | Height: | Size: 119 KiB |
Before Width: | Height: | Size: 106 KiB |
Before Width: | Height: | Size: 115 KiB |
After Width: | Height: | Size: 80 KiB |
Before Width: | Height: | Size: 78 KiB |
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 16 KiB |
@ -0,0 +1,32 @@ |
|||
<?xml version="1.0" encoding="utf-8"?> |
|||
<odoo> |
|||
<!--View for the fields to enable the restriction in settings.--> |
|||
<record id="res_config_settings_view_form" model="ir.ui.view"> |
|||
<field name="name"> |
|||
res.config.settings.view.form.inherit.sale.stock.restrict |
|||
</field> |
|||
<field name="model">res.config.settings</field> |
|||
<field name="priority" eval="40"/> |
|||
<field name="inherit_id" ref="sale.res_config_settings_view_form"/> |
|||
<field name="arch" type="xml"> |
|||
<!-- <xpath expr="//block[@id='connectors_setting_container']"--> |
|||
<!-- position="after">--> |
|||
<xpath expr="//div[hasclass('settings')]//div[@id='connectors_setting_container']" position="after"> |
|||
<block title="Product Restriction" id="stock_product_restriction"> |
|||
<setting help="Restrict the sale if the product is out of stock." |
|||
id="product_restriction"> |
|||
<field name="product_restriction"/> |
|||
<div class="content-group" |
|||
invisible="not product_restriction"> |
|||
<div class="row mt16" |
|||
id="out_of_stock_product_restriction"> |
|||
<label for="check_stock" class="col-lg-3"/> |
|||
<field name="check_stock"/> |
|||
</div> |
|||
</div> |
|||
</setting> |
|||
</block> |
|||
</xpath> |
|||
</field> |
|||
</record> |
|||
</odoo> |
@ -1,36 +0,0 @@ |
|||
<?xml version="1.0" encoding="utf-8"?> |
|||
<odoo> |
|||
<record id="res_config_settings_low_stock_view_form" model="ir.ui.view"> |
|||
<field name="name">res.config.settings.low.stock.view.form.inherit |
|||
</field> |
|||
<field name="model">res.config.settings</field> |
|||
<field name="priority" eval="40"/> |
|||
<field name="inherit_id" ref="sale.res_config_settings_view_form"/> |
|||
<field name="arch" type="xml"> |
|||
|
|||
<xpath expr="//div[hasclass('settings')]//div[@id='connectors_setting_container']" |
|||
position="after"> |
|||
<h2 class="mt32">Out Of Stock Product Restriction</h2> |
|||
<div class="row mt16 o_settings_container" |
|||
id="product_restriction"> |
|||
<div class="col-12 col-lg-6 o_setting_box" |
|||
id="out_of_stock_product_restriction"> |
|||
<div class="o_setting_left_pane"> |
|||
<field name="product_restriction"/> |
|||
</div> |
|||
<div class="o_setting_right_pane"> |
|||
<label for="product_restriction"/> |
|||
</div> |
|||
<div class="o_setting_right_pane" |
|||
attrs="{'invisible':[('product_restriction','!=',True)]}"> |
|||
<label for="check_stock"/> |
|||
|
|||
<field name="check_stock"/> |
|||
|
|||
</div> |
|||
</div> |
|||
</div> |
|||
</xpath> |
|||
</field> |
|||
</record> |
|||
</odoo> |
@ -1,23 +1,21 @@ |
|||
<?xml version="1.0"?> |
|||
<?xml version="1.0" encoding="UTF-8" ?> |
|||
<odoo> |
|||
<record id="inherited_model_sale_view_form_new" model="ir.ui.view"> |
|||
<field name="name">inherited.model.form.inherit.aa</field> |
|||
<!--View for fields in the sale order line.--> |
|||
<record id="view_order_form" model="ir.ui.view"> |
|||
<field name="name">sale.order.view.form.inherit.sale.stock.restrict</field> |
|||
<field name="model">sale.order</field> |
|||
<field name="inherit_id" ref="sale.view_order_form"/> |
|||
<field name="arch" type="xml"> |
|||
<xpath expr="//field[@name='order_line']/tree//field[@name='product_uom_qty']" |
|||
position="after"> |
|||
|
|||
<field name="qty_available"/> |
|||
<field name="forecast_quantity"/> |
|||
</xpath> |
|||
<xpath expr="//field[@name='payment_term_id']" |
|||
position="after"> |
|||
|
|||
<field name="onhand_check" invisible="1"/> |
|||
<field name="forecast_check" invisible="1"/> |
|||
<field name="onhand_check" invisible="True"/> |
|||
<field name="forecast_check" invisible="True"/> |
|||
</xpath> |
|||
|
|||
</field> |
|||
</record> |
|||
</odoo> |