Ai un cupon de -20% activ de o săptămână și, la un moment dat, observi că o factură a ieșit cu suma dinainte de reducere. Clientul a plătit mai puțin, dar factura arată alt număr. Asta nu e o toană a sistemului — e o setare pe care ai sărit-o.
De ce apare diferența
WooCommerce calculează reducerea pe comandă corect, dar factura o generează de obicei un plugin separat (WooCommerce PDF Invoices, sau altul asemănător). Dacă pluginul de facturare nu e configurat să citească reducerea din comandă, ia prețul de listă al produsului și îl pune direct pe factură, ignorând cuponul.
Verifici asta simplu: deschizi o comandă cu cupon aplicat din WooCommerce → Comenzi, te uiți la totalul afișat acolo, apoi deschizi PDF-ul facturii generate pentru aceeași comandă. Dacă cifrele nu se potrivesc, problema e la plugin, nu la magazin.
Cum setezi corect calculul
- Intri în setările pluginului de facturare (de obicei WooCommerce → Setări → PDF Invoices sau meniul propriu al pluginului).
- Cauți opțiunea legată de afișarea reducerilor pe factură — de obicei se numește ceva de tipul „Show discount as separate line” (Afișează reducerea ca linie separată).
- Activezi opțiunea și salvezi. Reducerea va apărea ca linie distinctă: preț produs, apoi reducere cupon, apoi total.
- Generezi din nou factura pentru o comandă test cu cupon aplicat și verifici că totalul se potrivește cu ce a plătit clientul.
Dacă lucrezi cu TVA, verifici și ordinea calculului: reducerea trebuie scăzută înainte de aplicarea TVA, nu după. Găsești asta în WooCommerce → Setări → Taxe, la opțiunea „Calculate tax based on” (Calculează taxa în funcție de), care trebuie corelată cu modul în care ai setat cuponul — procent din subtotal, nu din total.
Voucherele nu sunt cupoane
Dacă vinzi și vouchere de valoare fixă (nu procent, ci sumă fixă de cheltuit), problema e alta. Un voucher de 100 de lei folosit la o comandă de 300 de lei trebuie să apară pe factură ca plată parțială, nu ca reducere de preț. Amestecarea celor două duce la facturi care nu se potrivesc cu evidența contabilă, mai ales dacă lucrezi cu un contabil care cere factura să reflecte exact fluxul banilor.
Pentru vouchere, cea mai curată soluție e să le tratezi ca metodă de plată separată în WooCommerce, nu ca discount code. Se configurează din WooCommerce → Setări → Plăți, adăugând o metodă de plată dedicată, pe care o activezi doar când clientul introduce codul de voucher valid.
Ce nu merită să faci
Nu încerca să corectezi facturile greșite manual, una câte una, din interfața pluginului. E timp pierdut și rămâi cu erori la fiecare comandă nouă până nu repari setarea din rădăcină. La notifi.ro am întâlnit exact situația asta la un client care trimitea facturi corectate prin e-mail luni la rând, până am găsit opțiunea greșit setată în pluginul de facturare.
Mâine dimineață deschide o comandă veche cu cupon aplicat, compară totalul din comandă cu PDF-ul facturii și, dacă nu se potrivesc, mergi direct la setarea „Show discount as separate line” din pluginul tău de facturare.
Întrebări frecvente
Dacă schimb setarea acum, se corectează și facturile vechi?
Nu automat. Facturile deja generate rămân cum sunt; setarea corectă se aplică doar comenzilor noi sau celor pentru care regenerezi factura manual.
Ce fac dacă folosesc alt plugin de facturare decât WooCommerce PDF Invoices?
Principiul e același: cauți în setările pluginului tău opțiunea legată de afișarea reducerilor sau a cupoanelor pe document, chiar dacă numele exact diferă.
Trebuie să anunț contabilul dacă am corectat setarea?
Da, mai ales dacă a primit deja facturi greșite generate anterior — trebuie să știe care comenzi au nevoie de factură corectată sau storno.
You've had a -20% coupon running for a week, and then you notice an invoice went out showing the price before the discount. The customer paid less, but the invoice shows a different number. That's not a system glitch — it's a setting you skipped.
Why the mismatch happens
WooCommerce calculates the order discount correctly, but the invoice itself is usually generated by a separate plugin (WooCommerce PDF Invoices, or something similar). If that plugin isn't configured to read the discount from the order, it pulls the product's list price straight onto the invoice, ignoring the coupon entirely.
You can check this yourself: open an order with a coupon applied from WooCommerce → Orders, look at the total shown there, then open the generated PDF invoice for the same order. If the numbers don't match, the problem is in the plugin, not the store.
Setting up the calculation correctly
- Go into your invoicing plugin's settings (usually WooCommerce → Settings → PDF Invoices or the plugin's own menu).
- Look for the option related to displaying discounts on invoices — usually called something like 'Show discount as separate line.'
- Turn it on and save. The discount will now appear as its own line: product price, then coupon discount, then total.
- Generate the invoice again for a test order with a coupon applied and check that the total matches what the customer actually paid.
If you charge tax, also check the calculation order: the discount needs to be subtracted before tax is applied, not after. You'll find this under WooCommerce → Settings → Tax, in the 'Calculate tax based on' option, which needs to line up with how your coupon is set — percentage of subtotal, not of total.
Vouchers aren't coupons
If you also sell fixed-value vouchers (not a percentage, but a fixed amount to spend), the problem is different. A 100 lei voucher used on a 300 lei order needs to show on the invoice as a partial payment, not as a price discount. Mixing the two leads to invoices that don't match your accounting records, especially if you work with an accountant who needs the invoice to reflect the actual money flow.
For vouchers, the cleanest approach is treating them as a separate payment method in WooCommerce, not as a discount code. You set this up under WooCommerce → Settings → Payments, adding a dedicated payment method that only activates when the customer enters a valid voucher code.
What's not worth doing
Don't try to fix wrong invoices manually, one by one, from the plugin's interface. It's wasted time, and you'll keep getting errors on every new order until you fix the setting at the root. At notifi.ro I ran into exactly this with a client who was emailing corrected invoices for weeks before we found the misconfigured option in the invoicing plugin.
Tomorrow morning, open an old order with a coupon applied, compare its total to the invoice PDF, and if they don't match, go straight to the 'Show discount as separate line' setting in your invoicing plugin.
Frequently asked
If I change the setting now, does it fix old invoices too?
Not automatically. Invoices already generated stay as they are; the corrected setting only applies to new orders or ones where you manually regenerate the invoice.
What if I use a different invoicing plugin than WooCommerce PDF Invoices?
The principle stays the same: look in your plugin's settings for the option tied to displaying discounts or coupons on the document, even if the exact label is different.
Do I need to tell my accountant if I fixed the setting?
Yes, especially if they've already received incorrect invoices generated earlier — they need to know which orders require a corrected or reversed invoice.


