Namespace Microsoft.Finance.Deferral
Provides comprehensive functionality for managing deferred revenue and expense recognition in Business Central. Handles creation, calculation, posting, and archiving of deferral schedules that distribute amounts across multiple accounting periods.
Codeunit
| Name | Description |
|---|---|
| Codeunit Microsoft.Finance.Deferral."Deferral Utilities" | Central utility functions for deferral processing including schedule creation, calculation methods, and posting operations. Handles all core deferral business logic and integrates with various document types and posting routines. |
Table
| Name | Description |
|---|---|
| Table Microsoft.Finance.Deferral."Deferral Header" | Header record for deferral schedules that tracks the overall deferral setup for a specific document line. Links to the source document and contains parameters for generating the detailed deferral schedule. |
| Table Microsoft.Finance.Deferral."Deferral Header Archive" | Archive table for deferral header records, storing historical versions of deferral schedules. Maintains deferral schedule history when documents are archived for audit and reference purposes. |
| Table Microsoft.Finance.Deferral."Deferral Line" | Detail records for deferral schedules that define individual posting dates and amounts. Each line represents one period's worth of deferral recognition entries. |
| Table Microsoft.Finance.Deferral."Deferral Line Archive" | Archive table for deferral line records, storing historical deferral schedule details. Maintains detailed deferral line history when documents are archived for audit and reference purposes. |
| Table Microsoft.Finance.Deferral."Deferral Posting Buffer" | Temporary buffer table that accumulates deferral posting entries before they are written to G/L Entry. Consolidates multiple deferral lines with identical posting parameters into single G/L entries. |
| Table Microsoft.Finance.Deferral."Deferral Template" | Master data table that defines deferral templates for deferred revenue and expense recognition. Templates specify calculation methods, periods, and G/L accounts used to create deferral schedules. |
| Table Microsoft.Finance.Deferral."Posted Deferral Header" | Posted deferral header records that track completed deferral schedules after posting. Maintains a permanent record of deferral parameters for posted transactions. |
| Table Microsoft.Finance.Deferral."Posted Deferral Line" | Posted deferral line records that track individual posted deferral recognition entries. Contains the detailed breakdown of posted deferral amounts by period. |
Page
| Name | Description |
|---|---|
| Page Microsoft.Finance.Deferral."Deferral Lines - G/L" | |
| Page Microsoft.Finance.Deferral."Deferral Lines - Purchasing" | |
| Page Microsoft.Finance.Deferral."Deferral Lines - Sales" | |
| Page Microsoft.Finance.Deferral."Deferral Sched. Arch. Subform" | Read-only subform page displaying archived deferral schedule lines. Shows historical period amounts and posting dates from archived documents. |
| Page Microsoft.Finance.Deferral."Deferral Schedule" | Worksheet page for creating and editing deferral schedules. Allows users to define how deferred amounts are distributed across accounting periods. |
| Page Microsoft.Finance.Deferral."Deferral Schedule Archive" | Read-only worksheet page for viewing archived deferral schedules. Displays historical deferral schedule information from archived documents. |
| Page Microsoft.Finance.Deferral."Deferral Schedule Subform" | Subform page displaying detailed deferral schedule lines. Shows individual period amounts and posting dates for a deferral schedule. |
| Page Microsoft.Finance.Deferral."Deferral Schedule View" | Read-only worksheet page for viewing posted deferral schedules. Displays historical deferral schedule information after posting has occurred. |
| Page Microsoft.Finance.Deferral."Deferral Schedule View Subform" | Read-only subform page displaying posted deferral schedule lines. Shows historical period amounts and posting dates for completed deferral schedules. |
| Page Microsoft.Finance.Deferral."Deferral Template Card" | Card page for creating and editing deferral templates. Provides interface for defining deferral calculation methods, accounts, and schedule parameters. |
| Page Microsoft.Finance.Deferral."Deferral Template List" | List page for browsing and managing deferral templates. Provides overview of all available deferral templates and navigation to the template card. |
Report
| Name | Description |
|---|---|
| Report Microsoft.Finance.Deferral."Deferral Summary - G/L" | Report that summarizes G/L deferral activity by account and period. Provides detailed analysis of deferred amounts and recognition patterns for G/L transactions. |
| Report Microsoft.Finance.Deferral."Deferral Summary - Purchasing" | Report that summarizes purchasing deferral activity by vendor and period. Provides detailed analysis of deferred expense amounts and recognition patterns for purchase transactions. |
| Report Microsoft.Finance.Deferral."Deferral Summary - Sales" | Report that summarizes sales deferral activity by customer and period. Provides detailed analysis of deferred revenue amounts and recognition patterns for sales transactions. |
Enum
| Name | Description |
|---|---|
| Enum Microsoft.Finance.Deferral."Deferral Calculation Method" | Defines the calculation methods available for distributing deferred amounts across periods. Determines how the total deferral amount is split among the scheduled recognition periods. |
| Enum Microsoft.Finance.Deferral."Deferral Calculation Start Date" | Defines when deferral schedules should start relative to the document posting date. Controls the timing of the first deferral recognition entry. |
| Enum Microsoft.Finance.Deferral."Deferral Document Type" | Identifies the source document type that initiated a deferral schedule. Used to differentiate handling logic for deferrals from different modules. |
Events
| Name | |
|---|---|
| OnAfterCalculateDaysPerPeriod | Integration event raised after calculating deferral amounts using days per period method. Enables custom processing or adjustments to deferral calculations. |
| OnAfterCalculateEqualPerPeriod | Integration event raised after calculating deferral amounts using equal per period method. Enables custom processing or adjustments to equal period deferral calculations. |
| OnAfterCalculateStraightline | Integration event raised after calculating deferral amounts using straight-line method. Enables custom processing or adjustments to straight-line deferral calculations. |
| OnAfterCalculateUserDefined | Integration event raised after calculating deferral amounts using user-defined method. Enables custom processing or adjustments to user-defined deferral calculations. |
| OnAfterCreateDeferralSchedule | Integration event raised after creating the complete deferral schedule. Enables custom processing or validation after schedule generation is complete. |
| OnAfterCreateScheduleFromGL | Integration event raised after creating deferral schedule from general journal line posting. Enables custom processing or field updates after G/L deferral schedule creation. |
| OnAfterSetStartDate | Integration event raised after setting the start date for deferral calculations. Enables custom start date logic or adjustments based on deferral template settings. |
| OnBeforeCalculateDaysPerPeriod | Integration event raised before calculating deferral amounts using days per period method. Enables custom preprocessing or parameter modification before days-based calculations. |
| OnBeforeCalculateEqualPerPeriod | Integration event raised before calculating deferral amounts using equal per period method. Enables custom preprocessing or parameter modification before equal period calculations. |
| OnBeforeCalculateStraightline | Integration event raised before calculating deferral amounts using straight-line method. Enables custom preprocessing or parameter modification before straight-line calculations. |
| OnBeforeCalculateUserDefined | Integration event raised before calculating deferral amounts using user-defined method. Enables custom preprocessing or parameter modification before user-defined calculations. |
| OnBeforeCreateDeferralSchedule | Integration event raised before creating a deferral schedule with comprehensive parameters. Enables custom schedule creation logic or parameter validation before schedule generation. |
| OnBeforeDeferralCodeOnValidate | Integration event raised before validating deferral code input. Enables custom deferral code validation logic or preprocessing. |
| OnBeforePostedDeferralHeaderInsert | Integration event raised before inserting posted deferral header record. Enables custom field updates or validation before posted deferral header creation. |
| OnBeforePostedDeferralLineInsert | Integration event raised before inserting posted deferral line record. Enables custom field updates or validation before posted deferral line creation. |
| OnBeforeOpenLineScheduleEdit | Integration event raised before opening deferral schedule editor for line editing. Enables custom preprocessing or parameter modification before schedule editing. |
| OnAfterAdjustTotalAmountForDeferrals | Integration event raised after adjusting total amounts for deferral calculations. Enables custom processing or validation after deferral amount adjustments. |
| OnBeforeCalcDeferralNoOfPeriods | Integration event raised before calculating number of deferral periods. Enables custom period calculation logic based on calculation method and start date. |
| OnBeforeCheckPostingDate | Integration event raised before checking posting date validity for deferral lines. Enables custom posting date validation logic for deferral schedules. |
| OnBeforeGetDeferralDescription | Integration event raised before generating deferral description text. Enables custom description logic for deferral schedule entries. |
| OnCalculateEqualPerPeriodOnBeforeDeferralLineInsert | Integration event raised before inserting deferral line during equal per period calculation. Enables custom field updates or validation before line insertion. |
| OnCalculateStraightlineOnAfterCalcSecondPeriodDate | Integration event raised after calculating the second period date in straight-line deferral calculations. Enables custom period date adjustments for straight-line deferral schedules. |
| OnCalculateStraightlineOnBeforeDeferralLineInsert | Integration event raised before inserting deferral line during straight-line calculation. Enables custom field updates or validation before line insertion. |
| OnCalculateStraightlineOnBeforeCalcPeriodicDeferralAmount | Integration event raised before calculating periodic deferral amount in straight-line method. Enables custom amount calculation logic for straight-line deferral periods. |
| OnCalculateDaysPerPeriodOnAfterCalcEndDate | Integration event raised after calculating end date for days per period deferral method. Enables custom end date adjustments for days-based deferral calculations. |
| OnCalculateDaysPerPeriodOnBeforeDeferralLineInsert | Integration event raised before inserting deferral line during days per period calculation. Enables custom field updates or validation before line insertion. |
| OnCalculateUserDefinedOnBeforeDeferralLineInsert | Integration event raised before inserting deferral line during user-defined calculation. Enables custom field updates or validation before line insertion. |
| OnSetDeferralRecordsOnBeforeDeferralHeaderModify | Integration event raised before modifying deferral header during record setup. Enables custom field updates or validation before deferral header modification. |
| OnBeforeIsDateNotAllowed | Integration event raised before checking if a posting date is allowed for deferral processing. Enables custom date validation logic for deferral schedule processing. |
| OnBeforeUpdateDeferralLineDescription | Integration event raised before updating deferral line description during schedule creation. Enables custom description generation logic for deferral line entries. |
| OnBeforeValidateDeferralTemplate | Integration event raised before validating deferral template settings. Enables custom validation logic for deferral template configuration. |
| OnInitializeDeferralHeaderAndSetPostDateAfterInitDeferralLine | Integration event raised after initializing deferral line during deferral header initialization. Enables custom field updates or additional processing after deferral line setup. |
| OnOpenLineScheduleEditOnBeforeDeferralScheduleSetParameters | |
| OnBeforeCheckDeferralConditionForGenJournal | Integration event raised before checking deferral conditions for general journal lines. Enables custom deferral condition logic for journal line processing. |
| OnBeforeRemoveOrSetDeferralSchedule | Integration event raised before removing or setting up deferral schedule for a document line. Enables custom deferral schedule management logic and validation. |
| OnBeforeRoundDeferralAmount | |
| OnBeforeCalculateSchedule | Integration event raised before calculating the deferral schedule. Enables custom validation or modification of deferral header parameters. |
| OnDeleteOnBeforeDeleteAll | Integration event raised before deleting all deferral lines when the header is deleted. Enables custom cleanup logic or cascade deletion handling. |
| OnValidateStartDateOnAfterCalcThrowScheduleOutOfBoundError | Integration event raised after calculating whether to show schedule out of bounds error. Enables custom logic for determining accounting period validation errors. |
| OnBeforeValidatePostingDate | Integration event raised before validating posting date on deferral line. Enables custom posting date validation logic or preprocessing. |
| OnAfterPrepareSales | Integration event raised after preparing deferral posting buffer for sales line processing. Enables custom field updates or additional processing after sales line preparation. |
| OnAfterPreparePurch | Integration event raised after preparing deferral posting buffer for purchase line processing. Enables custom field updates or additional processing after purchase line preparation. |
| OnUpdateOnAfterSetFilters | Integration event raised after setting filters on deferral posting buffer during update operation. Enables custom filter modification or additional processing on filtered records. |
| OnUpdateOnBeforeDeferralPostBufferInsert | Integration event raised before inserting deferral posting buffer record during update operation. Enables custom field updates or validation before buffer record insertion. |
| OnAfterPrepareRemainderPurchase | Integration event raised after preparing remainder deferral posting buffer for purchase processing. Enables custom processing of remainder amounts for purchase transactions. |
| OnAfterPrepareRemainderSales | Integration event raised after preparing remainder deferral posting buffer for sales processing. Enables custom processing of remainder amounts for sales transactions. |
| OnBeforePostedDeferralHeaderInsert | |
| OnDeleteLinesOnAfterSetFilters | |
| OnBeforeInitFromDeferralLine | |
| OnBeforeInitForm | Integration event raised before initializing the deferral schedule form. Enables custom form initialization logic or parameter modification. |
| OnOnQueryClosePageOnAfterCalcShowNoofPeriodsError | Integration event raised after calculating whether to show number of periods error. Enables custom logic for determining period validation error display. |
| OnOnQueryClosePageOnAfterDeferralLineSetFilters | Integration event raised after setting filters on deferral lines during page close validation. Enables custom filter modification or additional processing on deferral lines. |
Remarks
Architecture: The deferral system uses a template-driven approach where deferral templates define calculation methods and G/L account mappings, deferral schedules manage period-by-period distributions, and archive tables maintain historical records.
Key Workflows:
- **Template Setup:**Configure deferral templates with calculation methods (straight-line, equal per period, days per period, user-defined), period parameters, and G/L account assignments
- **Schedule Generation:**Create deferral schedules from sales/purchase documents, apply template calculations to distribute amounts across periods, and generate recognition entries
- **Period Processing:**Post period recognition entries through G/L integration, update schedule status, and archive completed schedules for audit trail
Integration Points: Integrates with General Ledger for posting and account validation, Sales/Purchase documents for revenue/expense deferrals, and Foundation Period Management for schedule calculations. Supports multi-currency operations through Currency integration.
Extensibility:
Key extension points include calculation method customization through OnBeforeCalculate events, schedule creation hooks via OnBeforeCreateDeferralSchedule,
and posting validation through OnBeforePostedDeferralHeaderInsert. Supports custom calculation methods and template validation.
Dependencies:
Required: Microsoft.Finance.GeneralLedger, Microsoft.Foundation.Period, Microsoft.Finance.Currency
Optional: Microsoft.Sales, Microsoft.Purchases, Microsoft.Inventory.Item, Microsoft.Projects.Resources.Resource