project QadFinancials > class BDebtorReport > business logic query DInvoiceByDebtorByCompIsOpen


Parameters


iiCompanyIdintegerCompany id
ilDInvoiceIsOpenlogical
iiDebtorIdinteger
icCompanyCodecharacter


query condition


  each DInvoice where
DInvoice.Company_Id = iiCompanyId AND
DInvoice.Debtor_ID = iiDebtorId AND
DInvoice.DInvoiceIsOpen = ilDInvoiceIsOpen

      first Company (inner-join) where
Company.Company_Id = iiCompanyId AND
Company.Company_ID = DInvoice.Company_ID AND
Company.CompanyCode can-do icCompanyCode

      first Currency (inner-join) where
Currency.Currency_ID = DInvoice.DInvoiceCurrency_ID AND


query resultset tqDInvoiceByDebtorByCompIsOpen


field namedata typedb fielddescription
tiCompany_IDintegerDInvoice.Company_IDLink to Company
tcCurrencyCodecharacterCurrency.CurrencyCodeCurrency Code
tiDebtor_IDintegerDInvoice.Debtor_IDLink to Debtor
tiDInvoice_IDintegerDInvoice.DInvoice_IDRecord ID
tdDInvoiceBalanceCreditLCdecimalDInvoice.DInvoiceBalanceCreditLCBC Balance Amount CR. This field displays the sum of the credit amounts of all posting lines in transaction currency.
This field is calculated by the system using the TC Base Amount CR and the Exchange rate.
tdDInvoiceBalanceCreditTCdecimalDInvoice.DInvoiceBalanceCreditTCTC Balance Amount CR. This field displays the sum of the credit amounts of all posting lines in transaction currency.
tdDInvoiceBalanceDebitLCdecimalDInvoice.DInvoiceBalanceDebitLCBC Balance Amount DR. This field displays the sum of the debit amounts of all posting lines in transaction currency.
This field is calculated by the system using the TC Base Amount DR and the Exchange rate.
tdDInvoiceBalanceDebitTCdecimalDInvoice.DInvoiceBalanceDebitTCTC Balance Amount DR. This field displays the sum of the debit amounts of all posting lines in transaction currency.
tdDInvoiceBalanceLCdecimalDInvoice.DInvoiceBalanceLCBC Balance. This field displays the sum of the debit and credit amounts of all posting lines in base currency.
This field is calculated by the system using the TC Balance and the Exchange rate.
tdDInvoiceBalanceTCdecimalDInvoice.DInvoiceBalanceTCBalance. This field displays the sum of the debit and credit amounts of all posting lines in transaction currency.
ttDInvoiceDueDatedateDInvoice.DInvoiceDueDateDue Date. This field displays the date when payment is due, calculated by the system based on the credit terms and the invoice date. User can modify the due date without affecting the credit terms.
If the credit terms have a base date specified, this is used in the due date calculations rather than the invoice creation date.
tlDInvoiceIsOpenlogicalDInvoice.DInvoiceIsOpenOpen.This field indicates if the invoice has been completely paid.
This field is updated automatically when complete payment is confirmed.
This field is read-only.
api annotation:PartialUpdate = yes - defaults to true
tcDInvoiceTypecharacterDInvoice.DInvoiceTypeInvoice Type. This field displays the invoice type.
Invoice Correction and Credit Note Correction display as choices only when the appropriate daybook types have already been defined.
api annotation:PartialUpdate = yes - defaults to Invoice
tiDInvoiceVoucherintegerDInvoice.DInvoiceVoucherVoucher.This field displays the numeric identifier assigned to the posting.
When the daybook of the journal entry is charged(after transfer), the voucher is cleared.
Voucher must be unique in one GL period.
When the user input is zero, the system automatically assign a value not used yet for this field.


Internal usage


QadFinancials
method BDebtorReport.CustomerCreditOverview