AX 2012 - Check if period closed
Views (3245)
Ledger:
FiscalCalendars::checkModuleIsOpen(SysModule::Ledger, LedgerJournalTrans.TransDate,FiscalCalendars::findPeriodByPeriodCodeDate(Ledger::fiscalCalendar(CompanyInfo::find().RecId),LedgerJournalTable.ETGTransDate),false)
Sales:
FiscalCalendars::checkModuleIsOpen(SysModule::Sales, CustInvoiceJour.InvoiceDate,FiscalCalendars::findPeriodByPeriodCodeDate(Ledger::fiscalCalendar(CompanyInfo::find().RecId),CustInvoiceJour.InvoiceDate),false)
Invent closing:
InventClosing::findClosingDate(endmth(InventJournalTrans.TransDate))
FiscalCalendars::checkModuleIsOpen(SysModule::Ledger, LedgerJournalTrans.TransDate,FiscalCalendars::findPeriodByPeriodCodeDate(Ledger::fiscalCalendar(CompanyInfo::find().RecId),LedgerJournalTable.ETGTransDate),false)
Sales:
FiscalCalendars::checkModuleIsOpen(SysModule::Sales, CustInvoiceJour.InvoiceDate,FiscalCalendars::findPeriodByPeriodCodeDate(Ledger::fiscalCalendar(CompanyInfo::find().RecId),CustInvoiceJour.InvoiceDate),false)
Invent closing:
InventClosing::findClosingDate(endmth(InventJournalTrans.TransDate))
This was originally posted here.
*This post is locked for comments