diff --git a/pos_product_creation/__init__.py b/pos_product_creation/__init__.py new file mode 100644 index 000000000..5d8a4f372 --- /dev/null +++ b/pos_product_creation/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-TODAY Cybrosys Technologies(). +# Author: Sayooj A O @cybrosys(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 diff --git a/pos_product_creation/__manifest__.py b/pos_product_creation/__manifest__.py new file mode 100644 index 000000000..51d65c1a9 --- /dev/null +++ b/pos_product_creation/__manifest__.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-TODAY Cybrosys Technologies(). +# Author: Sayooj A O @cybrosys(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': 'Create Products From POS', + 'version': '16.0.1.0.0', + 'category': 'Point of Sale', + 'summary': 'Create Products From POS Interface', + 'author': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'website': 'https://www.cybrosys.com', + 'depends': ['point_of_sale'], + 'data': [ + ], + 'assets': { + 'point_of_sale.assets': [ + 'pos_product_creation/static/src/js/product_create_popup.js', + 'pos_product_creation/static/src/js/product_create_button.js', + 'pos_product_creation/static/src/xml/product_create_button.xml', + 'pos_product_creation/static/src/xml/product_create_popup.xml' + ] + }, + + 'images': ['static/description/banner.png'], + 'license': 'AGPL-3', + 'installable': True, + 'auto_install': False, +} diff --git a/pos_product_creation/controllers/__init__.py b/pos_product_creation/controllers/__init__.py new file mode 100644 index 000000000..de31fa4a1 --- /dev/null +++ b/pos_product_creation/controllers/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-TODAY Cybrosys Technologies(). +# Author: Sayooj A O @cybrosys(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 main diff --git a/pos_product_creation/controllers/main.py b/pos_product_creation/controllers/main.py new file mode 100644 index 000000000..47706b415 --- /dev/null +++ b/pos_product_creation/controllers/main.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2021-TODAY Cybrosys Technologies(). +# Author: Sayooj A O @cybrosys(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 request + + +class PosProductCreation(http.Controller): + @http.route('/create_product', type="json", auth="user") + def create_product(self, category, name, price, product_reference, unit_measure, product_categories, **kwargs): + product_category = '' + if category == 'Consumable': + product_category = 'consu' + elif category == 'Service': + product_category = 'service' + elif category == 'Stockable': + product_category = 'product' + else: + product_category = '' + res = request.env['product.template'].sudo().create({ + 'name': name, + 'type': product_category, + 'default_code': product_reference, + 'list_price': float(price), + 'uom_id': int(unit_measure), + 'uom_po_id': int(unit_measure), + 'pos_categ_id': int(product_categories), + 'available_in_pos': True, + }) + diff --git a/pos_product_creation/static/description/assets/icons/check.png b/pos_product_creation/static/description/assets/icons/check.png new file mode 100644 index 000000000..c8e85f51d Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/check.png differ diff --git a/pos_product_creation/static/description/assets/icons/chevron.png b/pos_product_creation/static/description/assets/icons/chevron.png new file mode 100644 index 000000000..2089293d6 Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/chevron.png differ diff --git a/pos_product_creation/static/description/assets/icons/cogs.png b/pos_product_creation/static/description/assets/icons/cogs.png new file mode 100644 index 000000000..95d0bad62 Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/cogs.png differ diff --git a/pos_product_creation/static/description/assets/icons/consultation.png b/pos_product_creation/static/description/assets/icons/consultation.png new file mode 100644 index 000000000..8319d4baa Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/consultation.png differ diff --git a/pos_product_creation/static/description/assets/icons/ecom-black.png b/pos_product_creation/static/description/assets/icons/ecom-black.png new file mode 100644 index 000000000..a9385ff13 Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/ecom-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/education-black.png b/pos_product_creation/static/description/assets/icons/education-black.png new file mode 100644 index 000000000..3eb09b27b Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/education-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/hotel-black.png b/pos_product_creation/static/description/assets/icons/hotel-black.png new file mode 100644 index 000000000..130f613be Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/hotel-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/license.png b/pos_product_creation/static/description/assets/icons/license.png new file mode 100644 index 000000000..a5869797e Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/license.png differ diff --git a/pos_product_creation/static/description/assets/icons/lifebuoy.png b/pos_product_creation/static/description/assets/icons/lifebuoy.png new file mode 100644 index 000000000..658d56ccc Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/lifebuoy.png differ diff --git a/pos_product_creation/static/description/assets/icons/manufacturing-black.png b/pos_product_creation/static/description/assets/icons/manufacturing-black.png new file mode 100644 index 000000000..697eb0e9f Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/manufacturing-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/pos-black.png b/pos_product_creation/static/description/assets/icons/pos-black.png new file mode 100644 index 000000000..97c0f90c1 Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/pos-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/puzzle.png b/pos_product_creation/static/description/assets/icons/puzzle.png new file mode 100644 index 000000000..65cf854e7 Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/puzzle.png differ diff --git a/pos_product_creation/static/description/assets/icons/restaurant-black.png b/pos_product_creation/static/description/assets/icons/restaurant-black.png new file mode 100644 index 000000000..4a35eb939 Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/restaurant-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/service-black.png b/pos_product_creation/static/description/assets/icons/service-black.png new file mode 100644 index 000000000..301ab51cb Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/service-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/trading-black.png b/pos_product_creation/static/description/assets/icons/trading-black.png new file mode 100644 index 000000000..9398ba2f1 Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/trading-black.png differ diff --git a/pos_product_creation/static/description/assets/icons/training.png b/pos_product_creation/static/description/assets/icons/training.png new file mode 100644 index 000000000..884ca024d Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/training.png differ diff --git a/pos_product_creation/static/description/assets/icons/update.png b/pos_product_creation/static/description/assets/icons/update.png new file mode 100644 index 000000000..ecbc5a01a Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/update.png differ diff --git a/pos_product_creation/static/description/assets/icons/user.png b/pos_product_creation/static/description/assets/icons/user.png new file mode 100644 index 000000000..6ffb23d9f Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/user.png differ diff --git a/pos_product_creation/static/description/assets/icons/wrench.png b/pos_product_creation/static/description/assets/icons/wrench.png new file mode 100644 index 000000000..6c04dea0f Binary files /dev/null and b/pos_product_creation/static/description/assets/icons/wrench.png differ diff --git a/pos_product_creation/static/description/assets/misc/categories.png b/pos_product_creation/static/description/assets/misc/categories.png new file mode 100644 index 000000000..bedf1e0b1 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/categories.png differ diff --git a/pos_product_creation/static/description/assets/misc/check-box.png b/pos_product_creation/static/description/assets/misc/check-box.png new file mode 100644 index 000000000..42caf24b9 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/check-box.png differ diff --git a/pos_product_creation/static/description/assets/misc/compass.png b/pos_product_creation/static/description/assets/misc/compass.png new file mode 100644 index 000000000..d5fed8faa Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/compass.png differ diff --git a/pos_product_creation/static/description/assets/misc/corporate.png b/pos_product_creation/static/description/assets/misc/corporate.png new file mode 100644 index 000000000..2eb13edbf Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/corporate.png differ diff --git a/pos_product_creation/static/description/assets/misc/customer-support.png b/pos_product_creation/static/description/assets/misc/customer-support.png new file mode 100644 index 000000000..79efc72ed Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/customer-support.png differ diff --git a/pos_product_creation/static/description/assets/misc/cybrosys-logo.png b/pos_product_creation/static/description/assets/misc/cybrosys-logo.png new file mode 100644 index 000000000..cc3cc0ccf Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/cybrosys-logo.png differ diff --git a/pos_product_creation/static/description/assets/misc/features.png b/pos_product_creation/static/description/assets/misc/features.png new file mode 100644 index 000000000..b41769f77 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/features.png differ diff --git a/pos_product_creation/static/description/assets/misc/logo.png b/pos_product_creation/static/description/assets/misc/logo.png new file mode 100644 index 000000000..478462d3e Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/logo.png differ diff --git a/pos_product_creation/static/description/assets/misc/pictures.png b/pos_product_creation/static/description/assets/misc/pictures.png new file mode 100644 index 000000000..56d255fe9 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/pictures.png differ diff --git a/pos_product_creation/static/description/assets/misc/pie-chart.png b/pos_product_creation/static/description/assets/misc/pie-chart.png new file mode 100644 index 000000000..426e05244 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/pie-chart.png differ diff --git a/pos_product_creation/static/description/assets/misc/right-arrow.png b/pos_product_creation/static/description/assets/misc/right-arrow.png new file mode 100644 index 000000000..730984a06 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/right-arrow.png differ diff --git a/pos_product_creation/static/description/assets/misc/star.png b/pos_product_creation/static/description/assets/misc/star.png new file mode 100644 index 000000000..2eb9ab29f Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/star.png differ diff --git a/pos_product_creation/static/description/assets/misc/support.png b/pos_product_creation/static/description/assets/misc/support.png new file mode 100644 index 000000000..4f18b8b82 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/support.png differ diff --git a/pos_product_creation/static/description/assets/misc/whatsapp.png b/pos_product_creation/static/description/assets/misc/whatsapp.png new file mode 100644 index 000000000..d513a5356 Binary files /dev/null and b/pos_product_creation/static/description/assets/misc/whatsapp.png differ diff --git a/pos_product_creation/static/description/assets/modules/1.png b/pos_product_creation/static/description/assets/modules/1.png new file mode 100644 index 000000000..5238bdeab Binary files /dev/null and b/pos_product_creation/static/description/assets/modules/1.png differ diff --git a/pos_product_creation/static/description/assets/modules/2.png b/pos_product_creation/static/description/assets/modules/2.png new file mode 100644 index 000000000..1ae7cfe3b Binary files /dev/null and b/pos_product_creation/static/description/assets/modules/2.png differ diff --git a/pos_product_creation/static/description/assets/modules/3.png b/pos_product_creation/static/description/assets/modules/3.png new file mode 100644 index 000000000..3c3ff1afb Binary files /dev/null and b/pos_product_creation/static/description/assets/modules/3.png differ diff --git a/pos_product_creation/static/description/assets/modules/4.png b/pos_product_creation/static/description/assets/modules/4.png new file mode 100644 index 000000000..3fae4631e Binary files /dev/null and b/pos_product_creation/static/description/assets/modules/4.png differ diff --git a/pos_product_creation/static/description/assets/modules/5.gif b/pos_product_creation/static/description/assets/modules/5.gif new file mode 100644 index 000000000..2a5f8e659 Binary files /dev/null and b/pos_product_creation/static/description/assets/modules/5.gif differ diff --git a/pos_product_creation/static/description/assets/modules/6.png b/pos_product_creation/static/description/assets/modules/6.png new file mode 100644 index 000000000..7f2815273 Binary files /dev/null and b/pos_product_creation/static/description/assets/modules/6.png differ diff --git a/pos_product_creation/static/description/assets/screenshots/1.png b/pos_product_creation/static/description/assets/screenshots/1.png new file mode 100644 index 000000000..f5ca6ce66 Binary files /dev/null and b/pos_product_creation/static/description/assets/screenshots/1.png differ diff --git a/pos_product_creation/static/description/assets/screenshots/2.png b/pos_product_creation/static/description/assets/screenshots/2.png new file mode 100644 index 000000000..a541bf1df Binary files /dev/null and b/pos_product_creation/static/description/assets/screenshots/2.png differ diff --git a/pos_product_creation/static/description/assets/screenshots/hero.gif b/pos_product_creation/static/description/assets/screenshots/hero.gif new file mode 100644 index 000000000..d78902d6e Binary files /dev/null and b/pos_product_creation/static/description/assets/screenshots/hero.gif differ diff --git a/pos_product_creation/static/description/banner.png b/pos_product_creation/static/description/banner.png new file mode 100644 index 000000000..fd1f87699 Binary files /dev/null and b/pos_product_creation/static/description/banner.png differ diff --git a/pos_product_creation/static/description/icon.png b/pos_product_creation/static/description/icon.png new file mode 100644 index 000000000..6c0aa7088 Binary files /dev/null and b/pos_product_creation/static/description/icon.png differ diff --git a/pos_product_creation/static/description/index.html b/pos_product_creation/static/description/index.html new file mode 100644 index 000000000..b005d314a --- /dev/null +++ b/pos_product_creation/static/description/index.html @@ -0,0 +1,536 @@ +
+
+
+

+ Create Products From POS

+

+ Create Products From POS +

+ +
+
+ + + + +
+
+

+ Overview +

+
+ +
+

+ The module provisions the end user to create products directly from Point of Sale. The new + button "Create Product", shall enable the end user to add details such as + product name, internal reference, price, type, category and more from POS. Upon clicking the + confirm button, a new product shall be created based on provided details.

+ +
+
+ +
+
+

+ Features +

+
+ +
+
+ +
+
+

+ Allows you to create products from Point of Sale

+
+
+
+ +
+
+

+ Screenshots +

+
+ +
+

+ Enter the details of products.

+

+ Enter the details of products right from the POS.

+ + +
+ +
+

+ Real-time product list update.

+

+ The products list will be updated real time. It is not needed to reload the page to show + the newly created product in Point of Sale products list. +

+ + +
+
+ + +
+
+

Suggested 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

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

Need Help?

+
+
+
+ + +
+ +
+ + +
+ +
+ +
+ +
+
+ +
+ +
+ +
+
+ +
+
+
+ + +
\ No newline at end of file diff --git a/pos_product_creation/static/src/img/content.png b/pos_product_creation/static/src/img/content.png new file mode 100644 index 000000000..a2d397083 Binary files /dev/null and b/pos_product_creation/static/src/img/content.png differ diff --git a/pos_product_creation/static/src/js/product_create_button.js b/pos_product_creation/static/src/js/product_create_button.js new file mode 100644 index 000000000..a3bdadb8d --- /dev/null +++ b/pos_product_creation/static/src/js/product_create_button.js @@ -0,0 +1,77 @@ +odoo.define('pos_product_creation.product_create_button', function(require) { + 'use strict'; + const PosComponent = require('point_of_sale.PosComponent'); + const ProductScreen = require('point_of_sale.ProductScreen'); + const { useListener } = require("@web/core/utils/hooks"); + const Registries = require('point_of_sale.Registries'); + const ajax = require('web.ajax'); + + + class ProductCreateButton extends PosComponent { + setup() { + super.setup(); + useListener('click', this.onClick); + } + async onClick() { + var self = this; + const { + confirmed, + payload + } = await this.showPopup('ProductCreatePopup', { + title: this.env._t('POS Product Creation'), + body: this.env._t('You can Create The product.'), + }); + if (confirmed) { + var product_category = payload[0]; + var product_name = payload[1]; + var product_reference = payload[2]; + var product_price = payload[3]; + var unit_measure = payload[4]; + var product_categories = payload[5]; + console.log(product_category, 'product_category') + console.log(product_name, 'product_name') + console.log(product_reference, 'product_reference') + console.log(product_price, 'product_price') + console.log(unit_measure, 'unit_measure') + if (!product_name){ + return this.showPopup('ErrorPopup', { + title: _('A Unit Of Measure Is Required'), + }); + } + if (!unit_measure){ + return this.showPopup('ErrorPopup', { + title: _('A Unit Of Measure Is Required'), + }); + } + console.log(product_category,'-product category in rpc') + console.log(product_name,'-product name in rpc') + console.log(product_price,'-product price in rpc') + console.log(product_reference,'-product product_reference in rpc') + console.log(unit_measure,'-product unit_measure in rpc') + console.log(product_categories,'-product product_categories in rpc') + + ajax.jsonRpc('/create_product', 'call', { + 'category': product_category, + 'name': product_name, + 'price': product_price, + 'product_reference': product_reference, + 'unit_measure': unit_measure, + 'product_categories': product_categories, + + }).then(function(response) {}); + } + } + } + ProductCreateButton.template = 'ProductCreateButton'; + ProductScreen.addControlButton({ + component: ProductCreateButton, + condition: function() { + return this; + }, + position: ['before', 'SetPricelistButton'], + }); + + Registries.Component.add(ProductCreateButton); + + return ProductCreateButton; +}); \ No newline at end of file diff --git a/pos_product_creation/static/src/js/product_create_popup.js b/pos_product_creation/static/src/js/product_create_popup.js new file mode 100644 index 000000000..36aa8d9c5 --- /dev/null +++ b/pos_product_creation/static/src/js/product_create_popup.js @@ -0,0 +1,51 @@ +odoo.define('pos_product_creation.product_create_popup', function(require) { + 'use strict'; + const { useState } = owl; + const AbstractAwaitablePopup = require('point_of_sale.AbstractAwaitablePopup'); + const Registries = require('point_of_sale.Registries'); + + class ProductCreatePopup extends AbstractAwaitablePopup { + setup() { + super.setup(); + console.log(this.env.pos, '<<<<<<<<<<<<<<<') + this.state = useState({ + typeValue: this.props.startingValue, + productValue: this.props.startingValue, + priceValue: this.props.priceValue, + productRef: this.props.startingValue + }); + } + getPayload() { + var selected_vals = []; + var category = this.state.typeValue; + var product = this.state.productValue; + var product_reference = this.state.productRef; + var price = this.state.priceValue; + var unit = this.state.unitValue; + var product_category = this.state.categoryValue; + selected_vals.push(category); + selected_vals.push(product); + selected_vals.push(product_reference); + selected_vals.push(price); + selected_vals.push(unit); + selected_vals.push(product_category); + return selected_vals + } + } + + ProductCreatePopup.defaultProps = { + confirmText: 'Ok', + cancelText: 'Cancel', + array: [], + title: 'Create ?', + body: '', + startingValue: '', + priceValue: 1, + list: [] + } + + ProductCreatePopup.template = 'ProductCreatePopup'; + Registries.Component.add(ProductCreatePopup); + + return ProductCreatePopup; +}); \ No newline at end of file diff --git a/pos_product_creation/static/src/xml/product_create_button.xml b/pos_product_creation/static/src/xml/product_create_button.xml new file mode 100644 index 000000000..a66073065 --- /dev/null +++ b/pos_product_creation/static/src/xml/product_create_button.xml @@ -0,0 +1,10 @@ + + + +
+ + Create Product +
+
+
+ diff --git a/pos_product_creation/static/src/xml/product_create_popup.xml b/pos_product_creation/static/src/xml/product_create_popup.xml new file mode 100644 index 000000000..7e4695b97 --- /dev/null +++ b/pos_product_creation/static/src/xml/product_create_popup.xml @@ -0,0 +1,98 @@ + + + + + + \ No newline at end of file diff --git a/pos_product_creation/views/assets.xml b/pos_product_creation/views/assets.xml new file mode 100644 index 000000000..ced8a5a22 --- /dev/null +++ b/pos_product_creation/views/assets.xml @@ -0,0 +1,9 @@ + + + + \ No newline at end of file