Skip to content

Configuration

Nothing in this module is configured in this module. A sales invoice draws on company structure, GL defaults, items, customers, tax codes and printable formats that all live elsewhere. A few of them are checked when you finalise and refuse FINAL; most are read only by the posting that runs after FINAL, where a gap either fails the posting — the invoice sits FINAL with an empty journal status on its Posting tab — or posts a journal that is quietly short. This page lists what must exist, where it is set, and what the failure looks like, so you can recognise a gap from its symptom.

The order below is a dependency order, not a rule the product enforces. Nothing stops you doing it out of sequence; you will simply hit the failures later.

1. Company structure

WhatWhereIf it is missing
Company, branch, locationOrganizationThe platform refuses a document with no company or no location, so no document is saved until they exist
Fiscal periods for the transaction date, not lockedChart of AccountA date inside a locked fiscal period (closing status LOCK_ALL or LOCK_TXN) is refused at FINAL with The selected date falls within a locked fiscal period. A date with no fiscal year or period at all is not refused, and finalises

2. General ledger defaults

The company default GL mapping is where every posting resolves when a line and a header carry no code of their own. For this module you need, at minimum:

DEBTOR (and DEBTOR_NON_TRADE if you invoice non-trade customers) · SALES · SALES_RETURN · OUTPUT_TAX · FOREX_GAIN · FOREX_LOSS — and COGS, which the invoice’s posting does not use but month-end cost-of-goods-sold processing does. SALES_DISCOUNT is among the defaults you can map, but the sales invoice’s journal posting does not read it today.

Set in Chart of Account.

A missing mapping does not stop FINAL. FINAL enqueues the posting processor and returns; the journal is written by that job a moment later. An unmapped DEBTOR fails the job with MISSING_DEFAULT_GL_CODE: DEBTOR: the invoice sits at FINAL with no journal, and Financial Report → Error Checking → Trace Document finds it.

An unmapped SALES or OUTPUT_TAX is worse, because nothing fails. The job leaves out the line it cannot place, builds the customer’s receivable line from whatever is left, and the journal balances and posts. A RM 106 invoice — RM 100 of goods, RM 6 SST — with no SALES code posts as debit trade debtors RM 6, credit output tax RM 6: sales are RM 100 short and the receivable is booked at RM 6. When the customer pays RM 106, trade debtors is left RM 100 in credit. With OUTPUT_TAX unmapped instead, SST payable is RM 6 short and trade debtors ends RM 6 in credit after the receipt.

How you would notice: the receivable account in the trial balance stops agreeing with the debtor ageing. The customer statement and the ageing are built from the documents, not the journal, so they look right; only the GL account shows the gap, and Trace Document finds nothing, because a journal exists. Before go-live, check that every sales, return and tax code has a company default (or every item has its own), then post one test invoice and read its journal.

Two cases do fail loudly: a customer with no AR/AP type has no receivable line to absorb the gap, so the job fails with TOTAL_DEBITS_AND_TOTAL_CREDITS_NOT_BALANCES; and if no line resolves at all (an untaxed invoice with no sales code) it fails with NO_JOURNAL_CREATED.

3. Tax

WhatWhereIf it is missing
Tax codes for the rates you chargeTax ConfigurationNo tax line has a code to carry. A tax code with no OUTPUT_TAX default behind it raises no error: the tax is left out of the journal and lands on trade debtors (§2)

4. What you sell, and who you sell it to

WhatWhereNote
Items, with serial / batch / bin tracking where usedDoc Item MaintenanceSerial validation at FINAL is a setting; when on, a serial not in stock at the location is rejected
Customers, with entity type and currencyCustomer MaintenanceThe invoice has nobody to bill
Customer credit terms, and credit limits if you use themCustomer MaintenanceNothing checks the limit at save. With the credit-limit setting on, the Sales Order and Sales Invoice screens refuse FINAL once the customer’s credit in that company is used up; the blacklist is the stop the server applies on every route
Pricing scheme, and a pricebook if you price by customer or branchPricebook
Return reasonsSales Return applet → Settings → Return ReasonsThe Reason drop-down is empty until you add codes

5. Permissions

Each document type needs its four API permissions (TNT_API_DOC_INTERNAL_SALES_INVOICE_CREATE / READ / UPDATE / DELETE, and the equivalents for quotation, order, return, credit note, debit note and refund note). Each applet’s reference page names its four.

The Sales Report’s API read permission is granted with branch targets. Granted without a branch, the permission exists and the branch drop-down is empty — it is a filter, not a yes/no.

What success looks like

Raise one invoice for one item to a customer on terms, finalise it, then check all three in five minutes:

  1. The invoice has a document number.
  2. The stock report for that item at that branch is one lower.
  3. The ledger shows a debit to the customer’s debtor account and a credit to Sales, with output tax split out. (No cost-of-sales line — that is posted by month-end processing.)

If any one of the three is missing, the failure is in the section above that supplies it.

Common mistakes

MistakeSymptom
SALES or OUTPUT_TAX not mappedNo error. The journal posts without the sales or tax line and trade debtors takes the amount; the receivable GL account stops agreeing with the debtor ageing (§2). Map the default, then repost the affected invoices
Expecting a cost-of-sales line on the invoice’s journalThere is none. Cost of goods sold is a month-end journal (Financial Report → Month End Processing); margin before then comes from the Profit & Loss report’s live calculation
DEBTOR not mappedInvoice is FINAL, no journal — the posting job failed with MISSING_DEFAULT_GL_CODE: DEBTOR
Fiscal period locked for the transaction dateFINAL is refused with The selected date falls within a locked fiscal period. A date with no fiscal period set up finalises without a word
Sales Report permission granted without branch targetsBranch drop-down empty; the report looks broken
Expecting a credit note to put stock backIt does not — its quantity signum is 0. Raise a Sales Return as well
Designing a process around the Sales GINIt moves nothing. The invoice moves the stock