Overslaan naar inhoud
Odoo Menu
  • Aanmelden
  • Probeer het gratis
  • Apps
    Financiën
    • Boekhouding
    • Facturatie
    • Onkosten
    • Spreadsheet (BI)
    • Documenten
    • Ondertekenen
    Verkoop
    • CRM
    • Verkoop
    • Kassasysteem winkel
    • Kassasysteem Restaurant
    • Abonnementen
    • Verhuur
    Websites
    • Websitebouwer
    • E-commerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Bevoorradingsketen
    • Voorraad
    • Productie
    • PLM
    • Inkoop
    • Onderhoud
    • Kwaliteit
    Personeelsbeheer
    • Werknemers
    • Werving & Selectie
    • Verlof
    • Evaluaties
    • Aanbevelingen
    • Wagenpark
    Marketing
    • Social media Marketing
    • E-mailmarketing
    • SMS Marketing
    • Evenementen
    • Marketingautomatisering
    • Enquêtes
    Diensten
    • Project
    • Urenstaten
    • Buitendienst
    • Helpdesk
    • Planning
    • Afspraken
    Productiviteit
    • Chat
    • Goedkeuringen
    • IoT
    • VoIP
    • Kennis
    • WhatsApp
    Apps van derden Odoo Studio Odoo Cloud Platform
  • Bedrijfstakken
    Detailhandel
    • Boekhandel
    • kledingwinkel
    • Meubelzaak
    • Supermarkt
    • Bouwmarkt
    • Speelgoedwinkel
    Food & Hospitality
    • Bar en Pub
    • Restaurant
    • Fastfood
    • Gastenverblijf
    • Drankenhandelaar
    • Hotel
    Vastgoed
    • Makelaarskantoor
    • Architectenbureau
    • Bouw
    • Vastgoedbeheer
    • Tuinieren
    • Vereniging van eigenaren
    Consulting
    • Accountantskantoor
    • Odoo Partner
    • Marketingbureau
    • Advocatenkantoor
    • Talentenwerving
    • Audit & Certificering
    Productie
    • Textiel
    • Metaal
    • Meubels
    • Eten
    • Brewery
    • Relatiegeschenken
    Gezondheid & Fitness
    • Sportclub
    • Opticien
    • Fitnesscentrum
    • Wellness-medewerkers
    • Apotheek
    • Kapper
    Trades
    • Klusjesman
    • IT-hardware & support
    • Zonne-energiesystemen
    • Schoenmaker
    • Schoonmaakdiensten
    • HVAC-diensten
    Andere
    • Non-profitorganisatie
    • Milieuagentschap
    • Verhuur van Billboards
    • Fotograaf
    • Fietsleasing
    • Softwareverkoper
    Browse all Industries
  • Community
    Leren
    • Tutorials
    • Documentatie
    • Certificeringen
    • Training
    • Blog
    • Podcast
    Versterk het onderwijs
    • Onderwijs- programma
    • Scale Up! Business Game
    • Bezoek Odoo
    Download de Software
    • Downloaden
    • Vergelijk edities
    • Releases
    Werk samen
    • Github
    • Forum
    • Evenementen
    • Vertalingen
    • Word een Partner
    • Services for Partners
    • Registreer je accountantskantoor
    Diensten
    • Vind een partner
    • Vind een boekhouder
    • Een adviseur ontmoeten
    • Implementatiediensten
    • Klantreferenties
    • Ondersteuning
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Vraag een demo aan
  • Prijzen
  • Help

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Boekhouding
  • Voorraad
  • PoS
  • Project
  • MRP
All apps
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Alle posts Personen Badges
Labels (Bekijk alle)
odoo accounting v14 pos v15
Over dit forum
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Alle posts Personen Badges
Labels (Bekijk alle)
odoo accounting v14 pos v15
Over dit forum
Help

How to reprint the pos order receipt?

Inschrijven

Ontvang een bericht wanneer er activiteit is op deze post

Deze vraag is gerapporteerd
posreceiptreprintodoo16
2774 Weergaven
Avatar
Zahra Naveed

i have customized my odoo receipt and it works great in a normal cycle of pos but if i want to reprint any order that is paid using orders at the top of pos . it didnt show the complete information.
https://drive.google.com/file/d/1C-pYxlBtSbcI1KRZWpnYemE04VzH1LWW/view?usp=sharing
above link is this is my actual receipt view
this is how it show when i access it from order at the top in odoo 16

https://drive.google.com/file/d/1tzYTLWxKczfExi3b1XkTMkQQLVR_BLHI/view?usp=sharing

it didnt pick up the orderlines , customer(name,number,address) lastly the subtotal,delivery charges before the GST tax line in the bottom.

this is my xml code with which i am working in the comment.


0
Avatar
Annuleer
Zahra Naveed
Auteur

<?xml version="1.0" encoding="UTF-8"?>
<templates id="template" xml:space="preserve">
<!-- Define a new template 'AddonsRecipt' based on the 'point_of_sale.OrderReceipt' template -->
<t t-name="AddonsReceipt" t-inherit="point_of_sale.OrderReceipt"
t-inherit-mode="extension" owl="1">
<xpath expr="//div[hasclass('orderlines')]" position="replace">
<!-- Divider line -->
<div class="order-line-divider" style="text-align: center;">
<hr style="width: 100%; border: 1px solid black; margin-top: 15px; margin-bottom: 15px" />
</div>
<t t-set="total_quantity" t-value="0"/>
<div class="orderlines" >
<t t-foreach="receipt.orderlines" t-as="line" t-key="line.id">
<t t-set="total_quantity" t-value="total_quantity + line.quantity"/>
<div style="padding-bottom: 10px;">
<!-- Add padding here -->
<t t-if="isSimple(line)">
<!-- Display the product name and price-->
<div style="font-weight: bold;">
<div style="display: flex; justify-content: space-between;">
<div style="flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;">
<span t-esc="Math.round(line.quantity * Math.pow(10, env.pos.dp['Product Unit of Measure'])) / Math.pow(10, env.pos.dp['Product Unit of Measure'])"/>
x
<t t-esc="line.product_name_wrapped[0]"/>
</div>
<div style="flex-shrink: 0;">
<span t-esc="env.pos.format_currency_no_symbol(line.price_display)" class="price_display"/>
</div>
</div>
<div style="margin-left: 22px;">
<WrappedProductNameLines line="line"/>
</div>
</div>
</t>
<t t-else="">
<div style="font-weight: bold;">
<div style="display: flex; justify-content: space-between;">
<div style="flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;">
<span t-esc="Math.round(line.quantity * Math.pow(10, env.pos.dp['Product Unit of Measure'])) / Math.pow(10, env.pos.dp['Product Unit of Measure'])"/>
x
<t t-esc="line.product_name_wrapped[0]"/>
</div>
<div style="flex-shrink: 0;">
<span t-esc="env.pos.format_currency_no_symbol(line.price_display)" class="price_display"/>
</div>
</div>
<div style="margin-left: 22px;">
<WrappedProductNameLines line="line"/>
</div>
</div>
<!-- Check if the discount policy is set to 'without_discount' and the price has changed from the list price -->
<t t-if="line.display_discount_policy == 'without_discount' and line.price != line.price_lst">
<div class="pos-receipt-left-padding">
<t t-esc="env.pos.format_currency_no_symbol(line.price_lst)"/>
->
<t t-esc="env.pos.format_currency_no_symbol(line.price)"/>
</div>
</t>
<t t-elif="line.discount !== 0">
<div class="pos-receipt-left-padding">
<t t-if="env.pos.config.iface_tax_included === 'total'">
<t t-esc="env.pos.format_currency_no_symbol(line.price_with_tax_before_discount)"/>
</t>
<t t-else="">
<t t-esc="env.pos.format_currency_no_symbol(line.price)"/>
</t>
</div>
</t>
<!--Display the discount amount-->
<t t-if="line.discount !== 0">
<div class="pos-receipt-left-padding">
Discount: <t t-esc="line.discount"/>%
</div>
</t>
</t>
<t t-if="line.customer_note">
<div class="pos-receipt-left-padding pos-receipt-customer-note-left-align" style="font-style: italic; margin-left: -7px;">
<t t-esc="'&quot;' + line.customer_note + '&quot;'"/>
</div>
</t>
<!-- Show addon products in Receipt -->
<tr t-foreach="props.order.orderlines" t-as="orderline"
t-key="orderline_index">
<t t-if="line.orderline_id == orderline.id">
<tr t-foreach="orderline.addon_items"
t-as="addon_item" t-key="addon_item_index">
<div class="pos-receipt" >
<span
t-esc="addon_item.addon_name"
style="margin-left: 22px;"/>
<span style="margin-left:8px"
class="pos-receipt-right-align">
<span t-esc="env.pos.format_currency_no_symbol(addon_item.addon_price_without)"/>
</span>
</div>
</tr>
</t>
</tr>
</div> <!-- Close padding div here -->
</t>
</div>
<!-- Divider line -->
<div class="order-line-divider" style="text-align: center;">
<hr style="width: 100%; border: 1px solid black;" />
</div>
<br></br>
<div style="text-align: center;">
<span t-esc="total_quantity"/> Items Ordered.
</div>
<br></br>
</xpath>
<xpath expr="//t[@t-if='!isTaxIncluded']" position="before">
<t t-if="receipt.delivery_line.length > 0">
<t t-if="receipt.delivery_line[0].price">
<div class="pos-receipt-amount-left-align">
Subtotal
<span t-esc="env.pos.format_currency_no_symbol(receipt.total_without_tax - receipt.delivery_line[0].price)"
class="pos-receipt-right-align"/>
</div>
<div class="pos-receipt-amount-left-align">
Delivery Charges<span t-esc="env.pos.format_currency_no_symbol(receipt.delivery_line[0].price)" class="pos-receipt-right-align"/>
</div>
</t>
</t>
</xpath>
<xpath expr="//t[@t-if='!isTaxIncluded']" position="replace">
<t t-if="!isTaxIncluded">
<t t-if="receipt.table != 'DELIVERY'">
<div>Subtotal<span t-esc="env.pos.format_currency_no_symbol(receipt.subtotal)" class="pos-receipt-right-align"/></div>
</t>
<t t-foreach="receipt.tax_details" t-as="tax" t-key="tax.tax.id">
<div class="responsive-price">
<t t-esc="tax.name" />
<span t-esc='env.pos.format_currency_no_symbol(receipt.total_with_tax-receipt.subtotal)' class="pos-receipt-right-align"/>
</div>
</t>
</t>
</xpath>
<xpath expr="//div[hasclass('pos-receipt-amount')][contains(text(), 'Grand Total')]" position="replace">
<div class="pos-receipt" style="text-align: center;">
<hr style="width: 100%; border: 1px solid black; " />
</div>
<div class="pos-receipt-amount-left-align">
Total
<span t-esc="env.pos.format_currency_no_symbol(receipt.total_with_tax)" class="pos-receipt-right-align"/>
</div>
</xpath>
<xpath expr="//t[@t-if='receipt.total_rounded != receipt.total_with_tax']" position="replace">
<t t-if="receipt.total_rounded != receipt.total_with_tax">
<div class="pos-receipt-amount-left-align">
Rounding
<span t-esc='env.pos.format_currency_no_symbol(receipt.rounding_applied)' class="pos-receipt-right-align"/>
</div>
<div class="pos-receipt-amount-divider" style="text-align: center;">
<hr style="width: 100%; border: 1px solid black;" />
</div>
<div class="pos-receipt-amount-left-align" style="font-weight: bold;">
Payable
<span t-esc='env.pos.format_currency_no_symbol(receipt.total_rounded)' class="pos-receipt-right-align"/>
</div>
</t>
<br></br>
<div class="pos-receipt-amount-left-align receipt-change">
Change
<span t-esc="env.pos.format_currency_no_symbol(receipt.change)" class="pos-receipt-right-align"/>
</div>
</xpath>

<!--HIDE FIELDS-->
<xpath expr="//div[@class='pos-receipt-contact']/following-sibling::br[1]" position="attributes">
<attribute name="style">display:none;</attribute>
</xpath>
<xpath expr="//div[@class='pos-receipt-contact']/following-sibling::br[2]" position="attributes">
<attribute name="style">display:none;</attribute>
</xpath>
<xpath expr="//div[@class='pos-receipt-right-align' and text()='--------']" position="replace">
</xpath>
<xpath expr="//t[@t-esc='receipt.name']" position="replace">
</xpath>
<xpath expr="//t[@t-esc='receipt.date.localestring']" position="replace">
</xpath>
<xpath expr="//t[@t-esc='receipt.date.validation_date']" position="replace">
</xpath>
<xpath expr="//t[@t-if='receipt.company.vat']" position="replace">
</xpath>
<xpath expr="//t[@t-if='receipt.table']" position="replace">
</xpath>
<xpath expr="//t[@t-if='receipt.table and receipt.customer_count']" position="replace">
</xpath>
<xpath expr="//t[@t-foreach='receipt.paymentlines']" position="replace">
</xpath>
<xpath expr="//div[contains(@class, 'pos-receipt-amount receipt-change')]" position="replace">
</xpath>
<xpath expr="//t[@t-if='receipt.cashier']" position="replace">
</xpath>
<xpath expr="//t[@t-if='receipt.company.contact_address']" position="replace">
</xpath>
<xpath expr="//t[@t-if='receipt.delivery_line.length>0']" position="replace">
</xpath>
<xpath expr="//t[@t-if='receipt.company.logo']" position="replace">
</xpath>

<!--Contact-->
<xpath expr="//t[@t-if='!receipt.header_html and receipt.header']" position="before">
<t t-if="receipt.company.logo">
<img class="pos-receipt-logo" t-att-src="receipt.company.logo" alt="Logo"/>
</t>
</xpath>
<xpath expr="//div[contains(@style, 'white-space:pre-line') and not(contains(@style, 'line-height'))]" position="attributes">
<attribute name="style">white-space:pre-line; line-height: 1.5; font-size: 14px;</attribute>
</xpath>
<xpath expr="//div[hasclass('pos-receipt-contact')]/div[contains(., 'Customer :')]" position="attributes">
<attribute name="style">text-align: left; font-size: 14px; line-height: 1.5;</attribute>
</xpath>
<xpath expr="//div[hasclass('pos-receipt-contact')]/div[contains(., 'Delivery Address :')]" position="attributes">
<attribute name="t-if">receipt.table == 'DELIVERY'</attribute>
<attribute name="style">text-align: left; font-size: 14px; line-height: 1.5;</attribute>
</xpath>
<xpath expr="//div[hasclass('pos-receipt-contact')]/div[contains(., 'Phone :')]" position="attributes">
<attribute name="t-if">receipt.table == 'DELIVERY'</attribute>
<attribute name="style">text-align: left; font-size: 14px; line-height: 1.5;</attribute>
</xpath>
<xpath expr="//t[@t-if='!receipt.header_html and receipt.header']" position="after">
<br></br>
<div class="flex-container" style="display: flex; justify-content: space-between; margin-top: 20px;">
<div class="table-info" style="text-align: left; font-weight: bold; font-size: 15px; line-height: 1.5;">
<t t-if="receipt.table">
<t t-esc="receipt.table" />
</t>
<t t-foreach="receipt.paymentlines" t-as="line" t-key="line.cid">
<div>
<t t-esc="line.name" />
</div>
</t>
<br></br>
</div>
<div class="pos-receipt-order-data" style="text-align: right; font-size: 13px;">
<t t-if="receipt.date.localestring">
<div><t t-esc="props.order.get_custom_formatted_date(receipt.date.localestring)"/></div>
</t>
<t t-else="">
<div><t t-esc="props.order.get_custom_formatted_date(receipt.date.validation_date)" /></div>
</t>
<div><t t-esc="receipt.name.replace('Order ', 'Order ID: ')" /></div>
<div>Order Taker:
<t t-if="receipt.floor">
<t t-esc="receipt.floor" />
</t>
</div>
</div>
<br></br>
</div>
</xpath>
</t>
</templates>

Geniet je van het gesprek? Blijf niet alleen lezen, doe ook mee!

Maak vandaag nog een account aan om te profiteren van exclusieve functies en deel uit te maken van onze geweldige community!

Aanmelden
Gerelateerde posts Antwoorden Weergaven Activiteit
POS Receipt reprint in odoo V15 CE Opgelost
pos receipt reprint
Avatar
Avatar
Avatar
2
apr. 22
4015
Custom Pos Receipt
pos receipt
Avatar
Avatar
1
dec. 24
3039
Pos Receipt
pos receipt
Avatar
0
aug. 24
2385
Can you customize Pos receipt via studio? Opgelost
pos receipt
Avatar
Avatar
1
aug. 24
3710
How to add index to each order line in POS receipt?
pos receipt
Avatar
0
jul. 24
2207
Community
  • Tutorials
  • Documentatie
  • Forum
Open Source
  • Downloaden
  • Github
  • Runbot
  • Vertalingen
Diensten
  • Odoo.sh Hosting
  • Ondersteuning
  • Upgrade
  • Gepersonaliseerde ontwikkelingen
  • Onderwijs
  • Vind een boekhouder
  • Vind een partner
  • Word een Partner
Over ons
  • Ons bedrijf
  • Merkelementen
  • Neem contact met ons op
  • Vacatures
  • Evenementen
  • Podcast
  • Blog
  • Klanten
  • Juridisch • Privacy
  • Beveiliging
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo is een suite van open source zakelijke apps die aan al je bedrijfsbehoeften voldoet: CRM, E-commerce, boekhouding, inventaris, kassasysteem, projectbeheer, enz.

Odoo's unieke waardepropositie is om tegelijkertijd zeer gebruiksvriendelijk en volledig geïntegreerd te zijn.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now