Journal Entry

You use the journal entry record to adjust balances in your ledger accounts without entering posting transactions.

In the UI, you access this record in the UI at Transactions > Financial > Make Journal Entries.

If your account has the Multi-Book Accounting feature enabled, you can also work with book specific journal entry records, which are available in the UI at Transactions > Financial > Make Book Specific Journal Entries. Although they have different entry forms, both book specific and regular intercompany journal entries are the same record type. Within SuiteScript, they are differentiated by the accountingbook field. In other words, a record that has a value set for accountingbook is book specific. Otherwise, the record is a regular intercompany journal entry.

For help working with this record in the UI, see Making Intercompany Journal Entries and Book-Specific Journal Entries.

The internal ID for this record is journalentry.

See the SuiteScript Records Browser for all internal IDs associated with this record.

Note:

For information about using the SuiteScript Records Browser, see Working with the SuiteScript Records Browser in the NetSuite Help Center.

For information about scripting with this record in SuiteScript, see the following help topics:

Supported Script Types

The journal entry record is scriptable in both client SuiteScript and server SuiteScript.

All three user events are supported: beforeLoad, beforeSubmit, and afterSubmit.

Supported Functions

The journal entry record is fully scriptable — it can be created, copied, updated, deleted, and searched using SuiteScript.

Warning:

If you update any type of journal entry that has been applied as a payment to an invoice or vendor bill, the relationship between the journal entry and payment is removed and the payment is no longer applied.

Usage Notes

With the Advanced Revenue Management (Essentials) feature, you can directly attach a revenue recognition plan to a book specific journal entry or an intercompany journal entry. Before you begin working with advanced revenue management programmatically, see Setup for Advanced Revenue Management (Essentials).

The following table lists the scriptable field associated with this record and advanced revenue management (essentials).

Field

Type

Internal ID

End Date

Date

enddate

Revenue Recognition Rule

List/Record

revenuerecognitionrule

Start Date

Date

startdate

For help working with this record in the UI, see Creating Revenue Elements from Journal Entries

Code Samples

The following sample shows how to create a book-specific journal entry. The record is book-specific because the parameter bookje has been set to T.

          var journalEntry = record.create({
    type: record.Type.JOURNAL_ENTRY,
    isDynamic: true,
    defaultValues: {
        bookje: 'T' // Setting bookje parameter to T makes the journal book specific.
    }
});
journalEntry.setValue({
    fieldId: 'accountingbook',
    value: '2'
});
journalEntry.setValue({
    fieldId: 'subsidiary',
    value: '4'
});
journalEntry.setValue({
    fieldId: 'trandate',
    value: new Date(2019, 04, 16)
});
journalEntry.selectNewLine({
    sublistId: 'line'
});
journalEntry.setCurrentSublistValue({
    sublistId: 'line',
    fieldId: 'account',
    value: '6'
});
journalEntry.setCurrentSublistValue({
    sublistId: 'line',
    fieldId: 'credit',
    value: '2.00'
});
journalEntry.commitLine({
    sublistId: 'line'
});

journalEntry.selectNewLine({
    sublistId: 'line'
});
journalEntry.setCurrentSublistValue({
    sublistId: 'line',
    fieldId: 'account',
    value: '149'
});
journalEntry.setCurrentSublistValue({
    sublistId: 'line',
    fieldId: 'debit',
    value: '2.00'
});
journalEntry.commitLine({
    sublistId: 'line'
});
var id = journalEntry.save(); 

        

Related Topics

General Notices