Invoice list — behaviour and permissions
The invoice list query, its filters, the content scope, handling of deleted rows and the auxiliary endpoints around the list.
The invoice module is the system's central register of invoices (incoming, outgoing, interest and recovery fee documents). This article covers the list, the filter and the auxiliary endpoints around the list.
Overview
Based on the filter, the list returns invoices from the invoice model, paged (10/25/50/100/all). Every invoice insert goes through the shared addInvoice() → Dlbtinvoice::add() path. Other modules can embed the list (listembed). Slow queries are written to a performance log.
Data model
Table names carry the installation's own prefix in the database.
| Table | Role | Main fields |
|---|---|---|
invoice | invoice header | company_client_id (owner), status, HUF/currency amounts, outstanding_balance_huf |
invoice_item | invoice lines | item name, amounts |
company | partner and owner company | name, tax number |
transaction_settlement | settlement link | invoice ↔ document |
doc_link, label_link | document and label links | object reference |
Filters
Company group and company (by content scope), partner, invoice number, invoice ID(s), type, payment type, date type and range, quick range from the masterdata/quickrange master, status, settlement state, source, invoice kind, item name, has document. The “left join” diagnostic filter (partner link) is visible to super admins only.
Permissions
- Layer 1: base access to the invoice path.
- Layer 2:
listat the start ofgetList()andlistembed()(without it a warning box); the menu usescanSee(list). Thedebugkey is classified SYSTEM, so it opens the SQL toggle for every logged-in user. The charts (finance/invoice.charts) need thechartkey; without it the output is empty. - Layer 3: the owner (
company_client_id) must be in the user's company scope; partner, type and creator scopes also apply. Rows withstatus = 9are returned only withcanSeeDeleted(); a status filter in the URL cannot bypass this.
Auxiliary endpoints
| Endpoint | Purpose | Right |
|---|---|---|
companiesByGroup, shared company picker | member companies of a group | list + content scope |
getBankaccounts | the partner's valid bank accounts | list |
peekNumber, getClientBlocks | preview of the next number, the client's active invoice blocks (creates a missing default block) | list (+ owner scope) |
navstructure, navrepair, rawdata | analysis of stored NAV responses, repair of header/line fields from NAV data, raw NAV data | super admin only |
The list links to finance/settlement::list and finance/transaction::list only when the user has both canSee and canAction there.
Known limitations
In the seeds the list key is an unclassified (UNMAPPED) list row. This description is derived from the code and has not been verified at run time.