JEVAPOS SALES RETURNS AND CREDIT NOTES
27 October 2026

WHERE TO USE IT
Sales > Sales Returns lists all visible returns by default. Search by credit
note, original invoice or customer; filter by branch or a report date range.
Click Print Credit Note for the original invoice reference, customer/seller
PINs when recorded, returned items, original prices, credit values and VAT
summary. A4 / thermal follows Settings > Invoice Setup > Credit Note Template.
The print page also lets the user switch between A4 and thermal.

RETURNS
Create the return from the existing Sales actions. Each saved return receives
a permanent short credit-note number. Reprinting does not restore stock again,
change payments, post accounts again or submit another eTIMS document.
Amounts and VAT are based on original sale-line snapshots, not current product
prices/rates. Repeated partial returns cannot exceed the selected original line.
The last partial return uses remaining cents so VAT and total credits reconcile.
Existing return entries are reconstructed as historical records; no stock,
financial history or original eTIMS records are changed or resubmitted.

ROLES
Sales > View Sales Returns and Print Sales Credit Notes control access.
View Own / View All Sales and branch access also apply. Initial grants follow
existing sales-view and receipt-print permissions; the owner can change them.

KRA / ETIMS
Every note references the original invoice. A printable internal record is not
proof of KRA submission or acceptance. Demo notes are clearly labelled demo.
The current eTIMS service leaves non-demo submissions pending until a certified
connector is installed. No KRA receipt/signature/verification is invented.
Historical records have unverified fiscal status; use the original fiscal note
where one was already issued. Credits must be processed through the eTIMS
solution that raised the original fiscal invoice.
Sources:
https://www.kra.go.ke/component/kra_faq/faq/433
https://www.kra.go.ke/news-center/public-notices/2080-etims-compliance

UPGRADING AN EXISTING CLIENT
Back up the client's files and database. Copy the updated application files,
keeping the client's .env/APP_KEY, storage and client-only licence config.
From the installed project folder use its PHP executable, for example:
  E:\xampp\php\php.exe artisan migrate --force
  E:\xampp\php\php.exe artisan optimize:clear
  E:\xampp\php\php.exe artisan security:check-license-access --client
The feature migration is:
  database/migrations/2026_10_27_000003_add_sales_return_credit_notes.php
It adds sale_returns and sale_return_items and the two permissions, and copies
historical return information into those new tables. It does not redo a refund,
adjust existing stock or change historical sale/payment/journal entries.
The earlier MUTTI_MART_UPDATED_PRICES.sql predates these new tables. Importing
that file alone does not install this feature. Never overwrite newer client
transactions with a stale full database snapshot.

OWNER MAINTENANCE
List/print controller: app/Http/Controllers/SaleReturnController.php
Original return action: app/Http/Controllers/SaleController.php::voidItems
Snapshots, availability and legacy records: app/Services/SaleReturnService.php
List layout: resources/views/sales/returns.blade.php
Credit-note layout: resources/views/sales/credit_note.blade.php
eTIMS submission: app/Services/EtimsService.php::submitCreditNote
