1
0
Fork 0

ignore addons

This commit is contained in:
Tobias Brunner 2022-08-06 20:39:49 +02:00
parent aa99070943
commit 8682dc49e8
35 changed files with 576 additions and 417 deletions

2
.gitignore vendored
View File

@ -1,2 +1,4 @@
backup.env
checkup.json
addons/
addons_old/

View File

@ -1,43 +1,22 @@
version: '2'
services:
web:
image: docker.io/tobru/odoo-pos:latest-pos
build: ./odoo
#image: docker.io/tobru/odoo-pos:latest-pos
image: docker.io/library/odoo:15
#build: ./odoo
depends_on:
- db
ports:
- 80:8069
volumes:
- odoo-web-data:/var/lib/odoo
- ./odoo/addons:/mnt/extra-addons
environment:
- HOST=db
- USER=odoo
- PASSWORD=odoo
hostname: web
networks:
localnet:
ipv4_address: 10.5.0.2
iotbox:
image: docker.io/tobru/odoo-pos:latest-iotbox
build: ./iotbox
depends_on:
- db
command: -- --load=web,hw_proxy,hw_posbox_homepage,hw_posbox_upgrade,hw_scale,hw_scanner,hw_escpos,hw_blackbox_be,hw_screen,hw_drivers,hw_printer_network
ports:
- 8070:8069
- 8072:8072
volumes:
- /dev/bus/usb:/dev/bus/usb
environment:
- HOST=db
- USER=odoo
- PASSWORD=odoo
hostname: iotbox
networks:
localnet:
ipv4_address: 10.5.0.3
db:
image: postgres:10
image: postgres:14
environment:
- POSTGRES_DB=postgres
- POSTGRES_PASSWORD=odoo
@ -45,16 +24,6 @@ services:
- PGDATA=/var/lib/postgresql/data/pgdata
volumes:
- odoo-db-data:/var/lib/postgresql/data/pgdata
networks:
localnet:
ipv4_address: 10.5.0.4
volumes:
odoo-web-data:
odoo-db-data:
networks:
localnet:
driver: bridge
ipam:
config:
- subnet: 10.5.0.0/16
gateway: 10.5.0.1

View File

@ -85,11 +85,11 @@ RUN patch -p0 /usr/local/lib/python3.5/dist-packages/v4l2.py < /tmp/python-v4l2
# Strings must be UTF-8 for correct printing
&& patch -p0 /usr/lib/python3/dist-packages/odoo/addons/hw_escpos/escpos/printer.py < /tmp/utf8-to-printer.patch \
# Disable log messages about disconnected drivers - unneeded and clutters logfile with useless messages
&& patch -p0 /usr/lib/python3/dist-packages/odoo/addons/hw_escpos/controllers/main.py < /tmp/disable-disconnected-logging.patch \
&& patch -p0 /usr/lib/python3/dist-packages/odoo/addons/hw_escpos/controllers/main.py < /tmp/disable-disconnected-logging.patch
# Add cashbox networking support
&& patch -p0 /opt/posbox/addons/hw_printer_network/controllers/hw_printer_network_controller.py < /tmp/cashbox-net.patch \
#&& patch -p0 /opt/posbox/addons/hw_printer_network/controllers/hw_printer_network_controller.py < /tmp/cashbox-net.patch \
# Remove fix from https://github.com/odoo/odoo/pull/35368 as this breaks network printing
&& patch -p0 /usr/lib/python3/dist-packages/odoo/addons/hw_escpos/escpos/escpos.py < /tmp/remove_get_printer_status.patch
#&& patch -p0 /usr/lib/python3/dist-packages/odoo/addons/hw_escpos/escpos/escpos.py < /tmp/remove_get_printer_status.patch
## Cannot switch to Odoo as CUPS must run as root and CUPS must run - otherwise IoTBox complains
#USER odoo

View File

@ -1,21 +1,21 @@
FROM odoo:12
FROM odoo:15
USER root
## Get pos-addons for pos_printer_network
RUN set -x; apt-get update \
&& apt-get -y install --no-install-recommends git \
&& rm -rf /var/lib/apt/lists/* \
&& git clone --depth=1 -b 12.0 https://github.com/it-projects-llc/pos-addons.git \
/opt/posbox/pos-addons \
&& git clone --depth=1 -b 12.0 https://github.com/camptocamp/odoo-cloud-platform.git \
/opt/posbox/cloud-addons \
&& git clone --depth=1 -b 12.0 https://github.com/CybroOdoo/CybroAddons.git \
/opt/posbox/cybro-addons
#RUN set -x; apt-get update \
# && apt-get -y install --no-install-recommends git \
# && rm -rf /var/lib/apt/lists/* \
# && git clone --depth=1 -b 13.0 https://github.com/it-projects-llc/pos-addons.git \
# /opt/posbox/pos-addons \
# && git clone --depth=1 -b 13.0 https://github.com/camptocamp/odoo-cloud-platform.git \
# /opt/posbox/cloud-addons \
# && git clone --depth=1 -b 13.0 https://github.com/CybroOdoo/CybroAddons.git \
# /opt/posbox/cybro-addons
COPY odoo.conf /etc/odoo/odoo.conf
COPY addons/ /opt/posbox/extra-addons
#COPY addons/ /opt/posbox/extra-addons
RUN chown -R odoo.odoo /opt/posbox
#RUN chown -R odoo.odoo /opt/posbox
USER odoo

View File

@ -1 +0,0 @@
# -*- coding: utf-8 -*-

View File

@ -1,26 +0,0 @@
# -*- coding: utf-8 -*-
{
'name': 'POS Tickets Order Number',
'summary': "POS Tickets Order Number",
'description': """POS Tickets Order Number""",
'author': 'iPredict IT Solutions Pvt. Ltd.',
'website': 'http://ipredictitsolutions.com',
"support": "ipredictitsolutions@gmail.com",
'category': 'Point of Sale',
'version': '12.0.0.1.0',
'depends': ['pos_restaurant'],
'data': [
'views/assets.xml',
],
'qweb': [
'static/src/xml/pos.xml',
],
'license': "OPL-1",
'installable': True,
'application': True,
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.0 KiB

View File

@ -1,59 +0,0 @@
odoo.define('ip_pos_ticket_order_number.pos_ticket_order_number', function (require) {
"use strict";
var Screens = require('point_of_sale.screens');
var MultiPrint = require('pos_restaurant.multiprint');
var Models = require('point_of_sale.models');
var PopUpWidget=require('point_of_sale.popups');
var Gui = require('point_of_sale.gui');
var core = require('web.core');
var QWeb = core.qweb;
var _t = core._t;
Screens.ReceiptScreenWidget.include({
get_receipt_render_env: function() {
var receipt = this._super();
var number = receipt.order.name.split(' ')[1].split('-').pop()
receipt['order_number'] = Number(number).toString();
receipt['big_number'] = receipt.order.big_number;
return receipt;
}
});
var _super_order = Models.Order.prototype;
Models.Order = Models.Order.extend({
initialize: function() {
_super_order.initialize.apply(this,arguments);
if (typeof this.big_number === 'undefined') {
this.big_number = false;
}
},
printChanges: function(){
var printers = this.pos.printers;
for(var i = 0; i < printers.length; i++){
var changes = this.computeChanges(printers[i].config.product_categories_ids);
if ( changes['new'].length > 0 || changes['cancelled'].length > 0){
var number = changes.name.split(' ')[1].split('-').pop()
changes['order_number'] = Number(number).toString()
var order = this.pos.get_order()
if (order) {order.set_big_number(true);}
var receipt = QWeb.render('OrderChangeReceipt',{changes:changes, widget:this});
printers[i].print(receipt);
}
}
},
set_big_number: function(val){
this.big_number = val;
this.trigger('change',this);
},
init_from_JSON: function(json) {
_super_order.init_from_JSON.apply(this,arguments);
this.big_number = json.big_number;
},
export_as_JSON: function() {
var json = _super_order.export_as_JSON.apply(this,arguments);
json.big_number = this.big_number;
return json;
},
});
});

View File

@ -1,31 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<templates id="template" xml:space="preserve">
<!-- Printed -->
<t t-extend="XmlReceipt">
<t t-jquery="[t-esc='receipt.name']" t-operation="before">
<div bold="on" size="double" font="a" t-if="big_number">
Bestellnummer: <t t-esc="order_number"/>
</div>
<br/><br/>
</t>
</t>
<!-- Displayed in browser -->
<t t-extend="PosTicket">
<t t-jquery="t[t-if='receipt.footer']" t-operation="after">
<div style="text-align: center; font-size: 80px;" t-if="big_number">
<b><t t-esc="order_number"/></b>
</div>
</t>
</t>
<t t-extend="OrderChangeReceipt">
<t t-jquery="t[t-if='changes.new.length > 0']" t-operation="after">
<div bold="on" size="double">
<t t-esc="changes.order_number"/>
</div>
</t>
</t>
</templates>

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<template id="ip_pos_ticket_order_number_assets" inherit_id="point_of_sale.assets">
<xpath expr="." position="inside">
<script type="text/javascript" src="/ip_pos_ticket_order_number/static/src/js/pos_ticket_order_number.js"></script>
</xpath>
</template>
</odoo>

View File

@ -1,3 +1,5 @@
# -*- coding: utf-8 -*-
# Powered by Kanak Infosystems LLP.
# © 2020 Kanak Infosystems LLP. (<https://www.kanakinfosystems.com>)
from . import models

View File

@ -1,22 +1,33 @@
# -*- coding: utf-8 -*-
# Powered by Kanak Infosystems LLP.
# © 2020 Kanak Infosystems LLP. (<https://www.kanakinfosystems.com>)
{
'name': 'POS Product Sequence',
'version': '1.0',
'summary': 'Point of Sale Product Sequence',
'version': '15.0.1.0',
'summary': 'POS Product Sequence module is used in Odoo POS to display the products position in POS Session according to the sequence or numbers assigned. If you have 5 products in backend and you want to set its sequence from 1 to 5, then same sequence wise product show in POS Session in odoo.',
'description': """
Point of Sale Product Sequence
""",
'license': 'OPL-1',
'author': 'Kanak Infosystems LLP',
'author': 'Kanak Infosystems LLP.',
'website': 'https://www.kanakinfosystems.com',
'images': ['static/description/main_image.jpeg'],
'category': 'Point of Sale',
'images': ['static/description/banner.jpeg'],
'category': 'Sales/Point of Sale',
'depends': ['point_of_sale'],
'data': [
'views/template.xml',
'views/pos_product_sequence_views.xml',
'views/knk_pos_product_sequence_views.xml',
],
'application': True,
'assets': {
'point_of_sale.assets': [
'pos_product_sequence/static/src/js/models.js',
],
},
'sequence': 1,
'installable': True,
'application': False,
'auto_install': False,
'price': 10,
'currency': 'EUR',
'live_test_url': 'https://youtu.be/pYVNy3A3ieE',
}

View File

@ -1,3 +1,5 @@
# -*- coding: utf-8 -*-
# Powered by Kanak Infosystems LLP.
# © 2020 Kanak Infosystems LLP. (<https://www.kanakinfosystems.com>)
from . import product
from . import knk_product

View File

@ -1,25 +0,0 @@
# -*- coding: utf-8 -*-
from odoo import fields, models, api
class ProductProduct(models.Model):
_inherit = "product.product"
_order = 'pos_sequence, default_code, name, id'
class ProductTemplate(models.Model):
_inherit = "product.template"
_order = 'pos_sequence, name'
pos_sequence = fields.Integer(string='POS Sequence', help='POS product display base on product sequence number')
@api.model
def create(self, vals):
res = super(ProductTemplate, self).create(vals)
if res:
rec = self.search([])
if rec:
seq = max(self.search([]).mapped('pos_sequence'))
if seq:
res.pos_sequence = seq + 1;
return res

Binary file not shown.

Before

Width:  |  Height:  |  Size: 143 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 410 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 143 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 771 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 410 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 598 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

View File

@ -1,136 +1,495 @@
<section class="oe_container">
<div class="oe_row oe_spaced">
<div class="oe_span12">
<h2 class="oe_slogan">Product sorting on POS interface base on POS sequence</h2>
</div>
</div>
</section>
<section class="oe_container" style="background-color: #eeeeee;">
<div class="oe_row oe_spaced">
<div class="oe_span12">
<h2 class="oe_slogan">Before POS Product Sequence</h2>
</div>
<div class="oe_span12">
<div class="oe_demo oe_picture oe_screenshot">
<img src="beforeproduct.png" class="oe_screenshot oe_centered" style="max-height: 400px;width:100%">
<div class="container">
<section style="background-color: white;margin-bottom: 20px;">
<div class="row justify-content-center">
<div class="text-center">
<h3 style="font-size: 40px;padding-top: 5px;color: #07386f;font-weight: 700;">
POS Product Sequence
</h3>
</div>
</div>
</div>
</section>
<section class="oe_container oe_dark">
<div class="oe_row oe_spaced">
<div class="oe_span12">
<h2 class="oe_slogan">Before POS Product Views</h2>
<div class="row justify-content-center">
<div class="text-center">
<i class=" fa fa-arrow-down" style="font-size:20px;color: #07386f;">
</i></div>
</div>
<div class="oe_span12">
<div class="oe_demo oe_picture oe_screenshot">
<img src="beforeposview.png" class="oe_screenshot oe_centered" style="max-height: 400px;width:100%">
</section>
<section class="pt16" style="background-color: #f8f9fa;margin-bottom: 35px;">
<div class="text-center">
<h6 class="mb-0 mt-2" style="font-size: 14px;">Supported Editions</h6>
<div class="row justify-content-center">
<h6 class="mb-0 mt-2 mr4" style="font-size: 14px;min-width: 90px;"><span class="badge badge-pill badge-light" style="color: #ffffff;background-color: #7c7bad;border-radius: 0.4rem;padding: 1.00em 0.4em;padding-right: 2em;padding-left: 2em;"> Community </span></h6>
<h6 class="mb-0 mt-2 text-right" style="font-size: 14px;min-width:90px"><span class="badge badge-pill badge-light" style="color: #ffffff;background-color: #007a77;border-radius: 0.4rem;padding: 1.00em 0.4em;padding-right: 2em;padding-left: 2em;"> Enterprise </span></h6>
</div>
</div>
</div>
</section>
<section class="oe_container oe_dark" style="background-color: #eeeeee;">
<div class="oe_row oe_spaced">
<div class="oe_span12">
<h2 class="oe_slogan">After Product POS Sequence</h2>
</div>
<div class="oe_span12">
<div class="oe_demo oe_picture oe_screenshot">
<img src="aftercdsequence.png" class="oe_screenshot oe_centered" style="max-height: 400px;width:100%">
<div class="col-md-10 mx-auto pt16 pb16">
<div class="text-center">
<p style="font-size: 21px;color: #113246;border: 1px solid;border-color: #dee2e6;background-color: #ffffff;" class="px-sm-4 p-2 pt-4"><b>POS Product Sequence</b> module is used in Odoo POS to display the product's position in POS Session according to the sequence of numbers assigned. If you have 5 products in the backend and you want to set its sequence from 1 to 5, then the same sequence wise product show in POS Session in odoo.
</p>
</div>
</div>
</div>
</section>
<section class="oe_container oe_dark">
<div class="oe_row oe_spaced">
<div class="oe_span12">
<h2 class="oe_slogan">After POS Product View. First Display of This Product</h2>
</section>
<section style="background-color: #ffffff;margin-bottom: 18px;">
<div class="row">
<h2 class="text-center mx-auto" style="font-size: 30px;font-weight: 700;border: 1px solid;border-color: #dee2e6;background-color: #f8f9fa;padding: 12px;width: 283px;"><span style="color: #09436d;">Key</span><span style="color: #f90829;"> Features</span></h2>
</div>
<div class="oe_span12">
<div class="oe_demo oe_picture oe_screenshot">
<img src="cdafterposview.png" class="oe_screenshot oe_centered" style="max-height: 400px;width:100%">
<div class="row">
<div class="col-md-6 col-sm-12 mt32">
<p style="font-size: 16px;color: #113246;border: 1px solid;border-color: #dee2e6;background-color: #f8f9fa;padding: 4px;"><i class="fa fa-circle" style="font-size: 11px;color: #cfd2d4;"></i>
User can set the Product sequence number.
</p>
</div>
<div class="col-md-6 col-sm-12 mt32">
<p style="font-size: 16px;color: #113246;border: 1px solid;border-color: #dee2e6;background-color: #ffffff;padding: 4px;"><i class="fa fa-circle" style="font-size: 11px;color: #cfd2d4;"></i>
It shows sequence wise products in Odoo POS.
</p>
</div>
<div class="col-md-6 col-sm-12 mt30">
<p style="font-size: 16px;color: #113246;border: 1px solid;border-color: #dee2e6;background-color: #ffffff;padding: 4px;"><i class="fa fa-circle" style="font-size: 11px;color: #cfd2d4;"></i>
User can manage the POS Sequence of Product in the Backend.
</p>
</div>
</div>
</div>
</section>
<section>
<div class="oe_row">
<div class="container-fluid">
<div class="oe_row">
<div class="col-md-12 col-xs-12 col-sm-12 mt32 mb32 text-center">
<img src="logo.png" style="height:100px;">
</section>
<section class="oe_container">
<div style="padding: 15px 0px;" id="loempia_tabs">
<ul role="tablist" class="nav nav-pills justify-content-center" data-tabs="tabs" id="pills-tab" style="background: transparent;">
<li class="nav-item col-12 col-sm-6 col-md-4" style="padding-right: 1em;">
<a id="pills-config-tab" data-toggle="pill" href="#pills-config" role="tab" aria-controls="pills-config" aria-selected="true" class="nav-link show active mb-sm-2 mb-md-0 mb-lg-0" style="background-color: #f3452b;color: ivory;margin-bottom: 0.5rem;">Configuration &amp; Setup</a>
</li>
<li class="nav-item col-12 col-sm-6 col-md-3">
<a id="pills-release-tab" data-toggle="pill" href="#pills-release" role="tab" aria-controls="pills-release" aria-selected="false" class="nav-link mb-sm-2 mb-md-0 mb-lg-0" style="background-color: #f37e2b;color: ivory;margin-bottom: 0.5rem;">Release Notes</a>
</li>
<li class="nav-item col-12 col-sm-6 col-md-3" style="padding-left:1em;">
<a id="pills-demo-tab" data-toggle="pill" href="#pills-demo" role="tab" aria-controls="pills-demo" aria-selected="false" class="nav-link mb-sm-2 mb-md-0 mb-lg-0" style="background-color: #0870b9;color: ivory;margin-bottom: 0.5rem;">Demo</a>
</li>
<li class="nav-item col-12 col-sm-6 col-md-2" style="padding-left:1em;">
<a style="background-color: #48a03dab;color: ivory;margin-bottom: 0.5rem;" class="nav-link mb-sm-2 mb-md-0 mb-lg-0" aria-selected="false" aria-controls="pills-faq" role="tab" href="#pills-faq" data-toggle="pill" id="pills-faq-tab">FAQ'S</a>
</li>
</ul>
<div class="tab-content" id="pills-tabContent">
<div class="px-3 pt-1 tab-pane fade active show" id="pills-config" role="tabpanel" aria-labelledby="pills-config-tab">
<br>
<section>
<div class="col-md-12 pl-0 pr-0 mx-auto mb16 d-block">
<div>
<div class="p-3" style="border: 1px solid;border-color: #dee2e6;background-color: #f8f9fa;">
<span class="oe_slogan" style="color:#113246;font-size: 35px;font-weight: 800;">Before POS Product Sequence</span>
<p style="border-bottom: 2px solid black;width:1cm;border-color:red;display: inline-flex;margin-left: 14px;position: relative;vertical-align: -webkit-baseline-middle;"></p>
</div>
</div>
</div>
</section>
<section>
<div class="p-3 p-sm-5" style="border: 1px solid #dee2e6;background-color: #f8f9fa;">
<img src="1 before sequence.png" style="width: 99%;margin-bottom:inherit;" class="oe_screenshot oe_centered">
</div>
</section>
<section>
<div class="p-3 mt32" style="border: 1px solid;border-color: #dee2e6;background-color: #f8f9fa;">
<span class="oe_slogan" style="color:#113246;font-size: 35px;font-weight: 800;">Set Product Sequence</span>
<p style="border-bottom: 2px solid black;width:1cm;border-color:red;display: inline-flex;margin-left: 14px;position: relative;vertical-align: -webkit-baseline-middle;"></p>
<ul class="list-unstyled" style="font-size:17px;border-radius: 9px;padding-top: 4px;">
<li class="d-flex align-items-baseline mb-2">
<i class="fa fa-circle" style="font-size:15px;color: #113246;padding-right: 9px;"></i><span style="padding-bottom: 3px;">Navigate to the Point of Sale and click on the Products menu.</span>
</li>
<li class="d-flex align-items-baseline mb-2">
<i class="fa fa-circle" style="font-size:15px;color: #113246;padding-right: 9px;"></i><span style="padding-bottom: 3px;">Open Products Variants sub-menu and click on Point of Sale tab.</span>
</li>
<li class="d-flex align-items-baseline mb-2">
<i class="fa fa-circle" style="font-size:15px;color: #113246;padding-right: 9px;"></i><span style="padding-bottom: 3px;">Now, we will set POS Sequence number.</span>
</li>
</ul>
</div>
</section>
<section>
<div class="p-3 p-sm-5 mt32" style="border: 1px solid #dee2e6;background-color: #f8f9fa;">
<img src="2 set sequence.png" style="width: 99%;margin-bottom:inherit;" class="oe_screenshot oe_centered">
</div>
</section>
<section>
<div class="p-3 mt32" style="border: 1px solid;border-color: #dee2e6;background-color: #f8f9fa;">
<span class="oe_slogan" style="color:#113246;font-size: 35px;font-weight: 800;">After POS Product Sequence</span>
<p style="border-bottom: 2px solid black;width:1cm;border-color:red;display: inline-flex;margin-left: 14px;position: relative;vertical-align: -webkit-baseline-middle;"></p>
<ul class="list-unstyled" style="font-size:17px;border-radius: 9px;padding-top: 4px;">
<li class="d-flex align-items-baseline mb-2">
<i class="fa fa-circle" style="font-size:15px;color: #113246;padding-right: 9px;"></i><span style="padding-bottom: 3px;">Now, we will open Odoo POS and check the position of configured product.</span>
</li>
<li class="d-flex align-items-baseline mb-2">
<i class="fa fa-circle" style="font-size:15px;color: #113246;padding-right: 9px;"></i><span style="padding-bottom: 3px;">Here, we can see configured product is in 2nd position.</span>
</li>
</ul>
</div>
</section>
<section>
<div class="p-3 p-sm-5 mt32" style="border: 1px solid #dee2e6;background-color: #f8f9fa;">
<img src="3 after sequence.png" style="width: 99%;margin-bottom:inherit;" class="oe_screenshot oe_centered">
</div>
</section>
</div>
<div class="px-3 pt-1 tab-pane fade" id="pills-release" role="tabpanel" aria-labelledby="pills-release-tab"><br>
<section class="card mb-5" style="border:none">
<div class="card-body pb-5">
<div class="row justify-content-center">
<div class="pr-0 pl-0 col-sm-12 col-md-8 col-xl-6 mx-auto">
<span style="background-color:#203038;width: 4px;height: 100%;height: 99%;"></span>
<div class="pb-3">
<div class="" style="background-color: #05386e;padding: 9px;text-align: center;color:#fff;border-radius: 10px 10px 10px 10px;">
<span style="font-size:20px; font-weight:700; display:block">4th</span>
<span style="display:block;font-size: 1.0em;text-transform:uppercase;">January, 2021 </span>
</div>
<div style="padding:1.5rem 2rem; border-top-right-radius:10px; background-color:#fff; border-bottom-right-radius:10px">
<div class="timeline__content">
<h3 style="font-weight:400;margin-bottom: 6px;">Latest Release 1.0</h3>
<p style="color:#666; margin-bottom:10px"><span style="font-size:17px"><i class="fa fa-hand-o-right"></i>
First version to release.</span>
</p>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</div>
<div class="px-3 pt-1 tab-pane fade" id="pills-demo" role="tabpanel" aria-labelledby="pills-demo-tab"><br>
<h2 style="font-weight:600;font-size: 2.5rem;color: #06386e;margin-top: 4px;margin-bottom: 31px;text-align: center;">Here See Demo Video:-</h2>
<div class="oe_centeralign oe_websiteonly" style="margin-bottom: 30px;">
<a href="https://www.youtube.com/watch?v=pYVNy3A3ieE" target="new" class="btn btn-primary btn-lg" style="background-color:#06416b;font-size: 20px;">Demo Video</a>
</div>
</div>
<div class="px-3 pt-1 tab-pane fade" id="pills-faq" role="tabpanel" aria-labelledby="pills-faq-tab"><br>
<section>
<div class="card-body p-0">
<div class="text-center pb-5">
<h2 style="color: #06386e;font-weight:600;font-size: 2.5rem;">Frequently Asked Question:-</h2>
</div>
<div class="s_faq mx-2 mx-md-5 mb-5" style="background-color: #fefefe;">
<div id="accordion">
<div class="card shadow mb-4" style="border:none">
<div class="card-header py-4 pl-4 pr-5 bg-white position-relative d-flex justify-content-between" style="border:none;">
<div class="pr-5" style="font-size: 1.4rem;font-weight:600;color: #05376d;">Is this app compatible with Odoo Enterprise?
</div>
<a class="card-link collapsed" data-toggle="collapse" href="#faqOne" style="width:48px;height:40px;line-height:11px;background-color: rgba(5, 55, 109, 0);border-radius:2px;padding:0;font-size: 23px;" aria-expanded="false"></a>
</div>
<div id="faqOne" class="collapse" data-parent="#accordion" style="">
<div class="card-body pt-0 pl-4">
<div style="font-size: 1.2rem;color: #0b3b52a1;">
Yes, our app works with Odoo Enterprise as well as Community.
</div>
</div>
</div>
</div>
</div>
</div>
<div class="s_faq mx-2 mx-md-5 mb-5" style="background-color: #fefefe;">
<div id="accordion">
<div class="card shadow mb-4" style="border:none">
<div class="card-header py-4 pl-4 pr-5 bg-white position-relative d-flex justify-content-between" style="border:none;">
<div class="pr-5" style="font-size: 1.4rem;font-weight:600;color: #05376d;">Is this app compatible with Windows or Ubuntu?
</div>
<a class="card-link collapsed" data-toggle="collapse" href="#faqOne" style="width:48px;height:40px;line-height:11px;background-color: rgba(5, 55, 109, 0);border-radius:2px;padding:0;font-size: 23px;" aria-expanded="false"></a>
</div>
<div id="faqOne" class="collapse" data-parent="#accordion" style="">
<div class="card-body pt-0 pl-4">
<div style="font-size: 1.2rem;color: #0b3b52a1;">
Yes, our app works with Windows or Ubuntu operating system.
</div>
</div>
</div>
</div>
</div>
</div>
<div class="s_faq mx-2 mx-md-5 mb-5" style="background-color: #fefefe;">
<div id="accordion">
<div class="card shadow mb-4" style="border:none">
<div class="card-header py-4 pl-4 pr-5 bg-white position-relative d-flex justify-content-between" style="border:none;">
<div class="pr-5" style="font-size: 1.4rem;font-weight:600;color: #05376d;">Is this app required any additional configuration?
</div>
<a class="card-link collapsed" data-toggle="collapse" href="#faqOne" style="width:48px;height:40px;line-height:11px;background-color: rgba(5, 55, 109, 0);border-radius:2px;padding:0;font-size: 23px;" aria-expanded="false"></a>
</div>
<div id="faqOne" class="collapse" data-parent="#accordion" style="">
<div class="card-body pt-0 pl-4">
<div style="font-size: 1.2rem;color: #0b3b52a1;">
No, install module and use this features.
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</div>
</div>
<div class="oe_row oe_screenshot" style="box-shadow: 3px 4px 25px 6px rgba(0, 0, 0, 0.2);;border-radius: 8px; background: #ECEDF0;">
<div class="col-sm-12">
<div class="text-center">
<a href="https://kanakinfosystems.com/kanak_aboutus"><h3 class="oe_slogan" style="border-bottom: 1px solid #123246; margin-top: 8px; font-size:33px; color:#123246; opacity:1; font-family:segoeuib">About kanak Infosystems</h3></a>
</div>
</section>
<section class="pt32" style="background-color: #f8f9fa;margin-bottom: 35px;">
<div class="text-center mx-auto" style="border:1px solid;background-color: #9e9c9c4f;height: 69px;width: 318px;">
<h2 class="mb-0 mt-2" style="font-size: 20px;font-weight: 900;border: 1px solid;margin-left: 8px;background-color: #06386e;color: white;padding: 12px;width: 300px;">FREE 3 MONTHS SUPPORT</h2>
</div>
<div class="">
<div class="text-center">
<p style="font-size: 21px;color: #686868;font-weight: 300;" class="px-sm-4 p-2 pt-4"> Kanak Infosystem will provide free 3 months support for bug fixes, any doubts or queries, installation, configuration support or any types of issues related to this module.<br></p>
<p class="mx-auto" style="border-bottom:1px solid black;width:4cm;border-color:#dee2e6;"></p>
<span style="color: #113246;font-size: 20px;font-weight: 600;">NOTE:</span> <span style="color: #686868;font-size: 21px;font-weight: 300;">This module do not required extra configuration.</span>
</div>
</div>
<div>
<div class="row mx-0 justify-content-sm-between justify-content-center" style="margin-top: 23px;">
<div class="mb-sm-0 mb-3 ml-0 ml-sm-5">
<i class="fa fa-envelope-o" style="margin-right: 10px;color:#05386e;font-size: 22px;"></i>
<span style="font-size: 20px;color: #686868;">sales@kanakinfosystems.com</span>
</div>
<div class="d-sm-block">
<i class="fa fa-skype" style="margin-right: 10px;color: #3a96cc;font-size: 27px;"></i>
<span style="font-size: 20px;color: #686868;">kanakinfosystems</span>
</div>
<div class="col-sm-12">
<h5 class="oe_slogan" style="margin-top: -9px; color:#123246;margin-bottom: 12px; opacity: 0.6; font-family:segoeuiz;"><i><b>"We are groupies wrapped in Creativity, Skills and Innovation"</b></i></h5>
<p style="font-family:segoeui">We are authorized IT company to offer advanced, hight quality and affordable IT solutions. We have years of rich experience in the field of ODOO Development, ERP Solutions, Web Development, Mobile Apps, Web Designing and Digital marketing. Around a decade are offering quality assured and 100% customer satisfaction services to global clientele.</p>
<p style="font-family:segoeui">Our highly experienced and devoted team of professionals works with there heart, passion and talent to provide the most dedicated IT Business Solutions to our valuable clients globally. Our team works on the real words "Dedication,"Timely Deliverables",And "Happy Clients"!</p>
<div style="margin-right: 120px;">
<i class="fa fa-whatsapp" style="margin-right:10px;color: #29f311;font-size: 30px;"></i>
<span style="font-size: 20px;color: #686868;">+91 9818108884 </span>
</div>
</div>
<div class="oe_row col-md-12 col-sm-12">
<div class="text-center">
<h2 style="color:#123246;font-family:segoeuib"> What We Do</h2>
</div>
</section>
<section class="d-none d-sm-block" style="text-align:center;">
<div style="width: 450px;height: 450px;background-color: #FFFFFF;border-radius: 50%;border: 1px dotted grey;display: inline-block; margin-top: 65px;margin-bottom: 65px;display: inline-flex;">
<div style="display:inline-block;margin-left: 165px;margin-top:-65px;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_category_sale_report/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #f98133;">
<div>
<img src="POS Category Sales Report.png" width="46px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Category Sales Report</span>
</a>
</div>
<div style="display:inline-block;margin-left: -337px;margin-top:46px;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_hourly_sales_report/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #7788fa;">
<div>
<img src="POS Hourly Sales Report.png" width="48px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Hourly Sales Report</span>
</a>
</div>
<div style="display:inline-block;margin-left: -172px;margin-top:254px;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_item_sale_report/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #57c96a;">
<div>
<img src="POS Item Sales Report.png" width="58px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Item Sales Report</span>
</a>
</div>
<div style="display:inline-block;margin-left: 54px;margin-top:356px;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_load_product_location/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #1e72be;">
<div>
<img src="POS Load Product Location.png" width="61px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Load Product Location</span>
</a>
</div>
<div style="display:inline-block;margin-left: 37px;margin-top:253px;">
<a href="https://apps.odoo.com/apps/modules/14.0/pizza_modifiers/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #ffcd58;">
<div>
<img src="POS Pizza Modifiers.png" width="50px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Pizza Modifiers</span>
</a>
</div>
<div style="display:inline-block;margin-left: -150px;margin-top:46px;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_receipt_information/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #7fca5a;">
<div>
<img src="POS Receipt Report.png" width="64px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Receipt Report</span>
</a>
</div>
<div style="display:inline-block;margin-left: -357px;margin-top: 146px;">
<div style="width: 184px;">
<span style="color: #03426a;font-weight: bold;font-size: 26px;text-align: center;display: inline-block;line-height: 33px;">SUGGESTED APPS</span>
<i class="fa fa-arrow-down" style="display: block;text-align: center;color: #3ca89b;height: 40px;font-size: 24px;margin-top: 4px;"></i>
<a href="https://apps.odoo.com/apps/modules/browse?author=Kanak%20Infosystems%20LLP." target="_blank" style="padding: 10px 46px;color: white;background-color: #3ca89b;font-size: 20px;">App Link</a>
</div>
</div>
<div class="row">
<div class="col-md-2 col-sm-2">
<img src="icon1.png">
<h6 style="margin-top: -10px;font-size: 9px;color:#123246;font-family:">Odoo Customization</h6>
</div>
<div class="col-md-2 col-sm-2">
<img src="icon-2.png">
<h6 style="margin-top: -1px;font-size: 9px;color:#123246;font-family:">Odoo Code Migration</h6>
</div>
<div class="col-md-2 col-sm-2">
<img src="icon-3.png">
<h6 style="margin-top: -1px;font-size: 9px;color:#123246;font-family:">Odoo Mobile App</h6>
</div>
<div class="col-md-2 col-sm-2">
<img src="icon-4.png">
<h6 style="margin-top: -1px;font-size: 9px;color:#123246;font-family:">Odoo DB Migration</h6>
</div>
<div class="col-md-2 col-sm-2">
<img src="icon-5.png">
<h6 style="margin-top: -1px;font-size: 9px;color:#123246;font-family:">Odoo Web Development</h6>
</div>
<div class="col-md-2 col-sm-2">
<img src="icon-6.png">
<h6 style="margin-top: -1px;font-size: 9px;color:#123246;font-family:">Odoo Themes</h6>
</div>
</section>
<section class="d-block d-sm-none" style="text-align:center;">
<div class="row mt16">
<div class="col-12 mx-auto">
<div style="display:inline-block;">
<div style="width: 184px;">
<span style="color: #03426a;font-weight: bold;font-size: 26px;text-align: center;display: inline-block;line-height: 33px;">SUGGESTED APPS</span>
<i class="fa fa-arrow-down" style="display: block;text-align: center;color: #3ca89b;height: 40px;font-size: 24px;margin-top: 4px;"></i>
<a href="https://apps.odoo.com/apps/modules/browse?author=Kanak%20Infosystems%20LLP." target="_blank" style="padding: 10px 46px;color: white;background-color: #3ca89b;font-size: 20px;">App Link</a>
</div>
</div>
</div>
<div class="oe_row">
<div class="text-center" style="text-align: center;">
<a style="color:#dc1d1d; border:1px solid #dc1d1d; width:170px;" class="btn btn-lg" rel="nofollow" href="https://kanakinfosystems.com/contactus" target="_blank">
Contact Us
</div>
<div class="row mt32">
<div class="col-6 mx-auto">
<div style="display:inline-block;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_category_sale_report/" target="_blank" style="width:150px;height: 150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #f98133;">
<div>
<img src="POS Category Sales Report.png" width="43px">
</div>
<span style="font-size: 13px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Category Sales Report</span>
</a>
</div>
</div>
<div class="oe_row" style="box-shadow: 3px 5px 18px 6px rgba(0, 0, 0, 0.2);;border-radius: 8px; background: #ECEDF0; height:50px">
<div class="oe_row">
<div class="col-md-12 col-sm-12" style="padding-top: 10px;padding-left: 40px;">
<div class="col-md-4 col-sm-4" style="float: left; text-align: center;">
<span><img src="call-icon.png"/></span>
<span>Help</span>
</div>
<div class="col-md-4 col-sm-4" style="float: left; text-align: center;">
<span><img src="support-icon.png"/></span>
<span>Support</span>
</div>
<div class="col-md-4 col-sm-4" style="float: left; text-align: center;">
<span><img src="support-icon.png"/></span>
<span>Request New Features</span>
</div>
<div class="col-6 mx-auto">
<div style="display:inline-block;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_hourly_sales_report/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #7788fa;">
<div>
<img src="POS Hourly Sales Report.png" width="48px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Hourly Sales Report</span>
</a>
</div>
</div>
</div>
<div class="row mt32">
<div class="col-6 mx-auto">
<div style="display:inline-block;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_item_sale_report/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #57c96a;">
<div>
<img src="POS Item Sales Report.png" width="58px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Item Sales Report</span>
</a>
</div>
</div>
<div class="col-6 mx-auto">
<div style="display:inline-block;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_load_product_location/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #1e72be;">
<div>
<img src="POS Load Product Location.png" width="61px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Load Product Location</span>
</a>
</div>
</div>
</div>
</div>
</section>
<div class="row mt32 mb32">
<div class="col-6 mx-auto">
<div style="display:inline-block;">
<a href="https://apps.odoo.com/apps/modules/14.0/pizza_modifiers/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #ffcd58;">
<div>
<img src="POS Pizza Modifiers.png" width="68px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Pizza Modifiers</span>
</a>
</div>
</div>
<div class="col-6 mx-auto">
<div style="display:inline-block;">
<a href="https://apps.odoo.com/apps/modules/14.0/pos_receipt_information/" target="_blank" style="width:150px;height:150px;display:inline-block;border-radius:50%;text-align:center;padding:30px;background-color: #7fca5a;">
<div>
<img src="POS Receipt Report.png" width="64px">
</div>
<span style="font-size: 14px;color: white;padding-top: 10px;display: block;font-weight: normal;line-height: 16px;">POS Receipt Reports</span>
</a>
</div>
</div>
</div>
</section>
<section style="background-color:white">
<div class="row pb-sm-1 px-4 text-center">
<div class="col-12">
<h2 class="text-center my-3 mx-auto" style="font-weight:800;color:#05386e;font-size:xx-large;border:1px solid #dee2e6;border-radius:5px;background-color:#f8f9fa;padding:10px;width: 310px !important;">OUR SERVICES</h2>
</div>
<div style="margin-bottom:20px;" class="col-md-3">
<div class="text-center" style="min-height: 90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/hire-odoo-developer" target="_blank">
<div class="pt-4">
<img src="Hire-Odoo-Developer.jpg" alt="Developer" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px;font-weight:400;margin-top: -37px;margin-left: 30px;">Hire Odoo Developer</h5>
</div>
</a>
</div>
</div>
<div class="col-md-3" style="margin-bottom:20px">
<div class="text-center" style="min-height:90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/odoo-customization-implementation-services" target="_blank">
<div class="pt-4">
<img src="Odoo-Customization.jpg" alt="custom" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px; font-weight:400;margin-top: -37px;margin-left: 30px;">Odoo Customization</h5>
</div>
</a>
</div>
</div>
<div class="col-md-3" style="margin-bottom:20px">
<div class="text-center" style="min-height:90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/odoo-development-services" target="_blank">
<div class="pt-4">
<img src="Odoo-Development.jpg" alt="Develop" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px; font-weight:400;margin-top: -37px;margin-left: 30px;">Odoo Development</h5>
</div>
</a>
</div>
</div>
<div class="col-md-3" style="margin-bottom:20px">
<div class="text-center" style="min-height:90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/odoo-installation-services" target="_blank">
<div class="pt-4">
<img src="Odoo-Installation.jpg" alt="Install" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px; font-weight:400;margin-top: -37px;margin-left: 30px;">Odoo Installation</h5>
</div>
</a>
</div>
</div>
<div class="col-md-3" style="margin-bottom:20px">
<div class="text-center" style="min-height:90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/odoo-integration-services" target="_blank">
<div class="pt-4">
<img src="Odoo-Integration.jpg" alt="Integ" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px; font-weight:400;margin-top: -37px;margin-left: 30px;">Odoo Integration</h5>
</div>
</a>
</div>
</div>
<div class="col-md-3" style="margin-bottom:20px">
<div class="text-center" style="min-height:90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/odoo-resources" target="_blank">
<div class="pt-4">
<img src="Odoo-Resources.jpg" alt="Resource" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px; font-weight:400;margin-top: -37px;margin-left: 30px;">Odoo Resources</h5>
</div>
</a>
</div>
</div>
<div class="col-md-3" style="margin-bottom:20px">
<div class="text-center" style="min-height:90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/odoo-themes" target="_blank">
<div class="pt-4">
<img src="Odoo-Themes.jpg" alt="Themes" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px; font-weight:400;margin-top: -37px;margin-left: 30px;">Odoo Themes</h5>
</div>
</a>
</div>
</div>
<div class="col-md-3" style="margin-bottom:20px">
<div class="text-center" style="min-height:90px;border-style: none;display: inline-block;box-shadow: none !important;">
<a href="https://kanakinfosystems.com/odoo-training" target="_blank">
<div class="pt-4">
<img src="Odoo-Training.jpg" alt="Training" style="width: 273px;">
</div>
<div>
<h5 class="card-title text-white" style="font-size:19px; font-weight:400;;margin-top: -37px;margin-left: 30px;">Odoo Training</h5>
</div>
</a>
</div>
</div>
</div>
</section>
</div>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 846 B

View File

@ -1,54 +1,70 @@
odoo.define('pos_product_sequence.models', function (require) {
"use strict";
odoo.define('pos_product_sequence.models', function(require) {
"use strict";
var models = require('point_of_sale.models');
var core = require('web.core');
var models = require('point_of_sale.models');
var core = require('web.core');
var QWeb = core.qweb;
var _t = core._t;
var PosDB = require('point_of_sale.DB')
var exports = require('point_of_sale.models');
var QWeb = core.qweb;
var _t = core._t;
var PosDB = require('point_of_sale.DB');
const Registries = require('point_of_sale.Registries');
const ProductsWidget = require('point_of_sale.ProductsWidget');
PosDB.include({
get_product_by_category: function(category_id){
var product_ids = this.product_by_category_id[category_id];
var list = [];
if (product_ids) {
for (var i = 0, len = Math.min(product_ids.length, this.limit); i < len; i++) {
list.push(this.product_by_id[product_ids[i]]);
}
}
if(list.length){
var new_list = _.sortBy(list, function(num) {
return num.pos_sequence;
});
return new_list;
}
return list;
},
});
models.load_models({
model: 'product.product',
// todo remove list_price in master, it is unused
fields: ['display_name', 'list_price', 'lst_price', 'standard_price', 'categ_id', 'pos_categ_id', 'taxes_id',
'barcode', 'default_code', 'to_weight', 'uom_id', 'description_sale', 'description',
'product_tmpl_id','tracking','pos_sequence'],
order: _.map(['pos_sequence','sequence','default_code','name'], function (name) { return {name: name}; }),
domain: [['sale_ok','=',true],['available_in_pos','=',true]],
context: function(self){ return { display_default_code: false }; },
loaded: function(self, products){
var using_company_currency = self.config.currency_id[0] === self.company.currency_id[0];
var conversion_rate = self.currency.rate / self.company_currency.rate;
self.db.add_products(_.map(products, function (product) {
if (!using_company_currency) {
product.lst_price = round_pr(product.lst_price * conversion_rate, self.currency.rounding);
PosDB.include({
get_product_by_category: function(category_id) {
var product_ids = this.product_by_category_id[category_id];
var list = [];
if (product_ids) {
for (var i = 0, len = Math.min(product_ids.length, this.limit); i < len; i++) {
list.push(this.product_by_id[product_ids[i]]);
}
product.categ = _.findWhere(self.product_categories, {'id': product.categ_id[0]});
return new exports.Product({}, product);
}));
}
if (list.length) {
var new_list = _.sortBy(list, function(num) {
return num.pos_sequence;
});
return new_list;
}
return list;
},
});
return exports;
models.PosModel.prototype.models.some(function(model) {
if (model.model !== 'product.product') {
return false;
}
// add name and attribute_value_ids to list of fields
// to fetch for product.product
['pos_sequence'].forEach(function(field) {
if (model.fields.indexOf(field) == -1) {
model.fields.push(field);
}
});
model['order'] = _.map(['pos_sequence', 'sequence', 'default_code', 'name'], function(name) { return { name: name }; });
return true; //exit early the iteration of this.models
});
const BiProductsTemplateWidget = (ProductsWidget) =>
class extends ProductsWidget {
constructor() {
super(...arguments);
}
get productsToDisplay() {
let list = [];
if (this.searchWord !== '') {
list = this.env.pos.db.search_product_in_category(
this.selectedCategoryId,
this.searchWord
);
} else {
list = this.env.pos.db.get_product_by_category(this.selectedCategoryId);
}
return list
}
};
Registries.Component.extend(ProductsWidget, BiProductsTemplateWidget);
return ProductsWidget;
});

View File

@ -1,41 +0,0 @@
<?xml version="1.0"?>
<odoo>
<data>
<record id="pos_product_product_tree_view" model="ir.ui.view">
<field name="name">product.product.tree.inherit</field>
<field name="model">product.product</field>
<field name="inherit_id" ref="product.product_product_tree_view"/>
<field name="arch" type="xml">
<field name="default_code" position="before">
<field name="pos_sequence" widget="handle"/>
</field>
</field>
</record>
<record id="pos_product_template_tree_view" model="ir.ui.view">
<field name="name">product.template.tree.inherit</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="product.product_template_tree_view"/>
<field name="arch" type="xml">
<field name="sequence" position="attributes">
<attribute name="invisible">1</attribute>
</field>
<field name="default_code" position="before">
<field name="pos_sequence" widget="handle"/>
</field>
</field>
</record>
<record id="pos_product_template_form_view" model="ir.ui.view">
<field name="name">product.template.form.inherit</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="point_of_sale.product_template_form_view"/>
<field name="arch" type="xml">
<field name="available_in_pos" position="after">
<field name="pos_sequence"/>
</field>
</field>
</record>
</data>
</odoo>

View File

@ -1,10 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<data>
<template id="assets" inherit_id="point_of_sale.assets">
<xpath expr="." position="inside">
<script type="text/javascript" src="/pos_product_sequence/static/src/js/models.js"></script>
</xpath>
</template>
</data>
</odoo>

View File

@ -1,4 +1,3 @@
[options]
addons_path = /opt/posbox/pos-addons,/opt/posbox/extra-addons,/opt/posbox/cloud-addons,/opt/posbox/cybro-addons
data_dir = /var/lib/odoo
admin_passwd = S3Cur3Passw0rd