Product |
TOTVS Backoffice
|
Product Line | Linha Protheus |
Segment | Serviços |
Module | TOTVS Backoffice (Linha Protheus) - Contabilidade Gerencial (SIGACTB)
|
Function | CTBA102 |
Country | Brasil |
Ticket | Interno |
Requisite/Story/Issue | DSERCTR1-46829 |
The VCTB102EST entry point is used to validate reversal operations of accounting entries in the system. It allows the implementation of custom logic to approve or reject the reversal according to the user’s specific business rules. This entry point is useful in situations where the company needs to apply additional criteria to allow the reversal, such as financial integrity validations or accounting calendar restrictions.
If ! ExecBlock("VCTB102EST",.F.,.F.,{dDataLanc,cLote,cSubLote,cDoc,nTotInf})
Return .F.
EndIF
User Function VCTB102EST()
Local dDataLanc := PARAMIXB[1]
Local cLote := PARAMIXB[2]
Local cSubLote := PARAMIXB[3]
Local cDoc := PARAMIXB[4]
Local nTotInf := PARAMIXB[5]
Local lRel := .T.
// Checks whether the batch meets the required criteria
If cLote == "RESTRICTED_BATCH"
MsgAlert("Reversal not allowed for restricted batch.")
lRel := .F.
EndIf
// Returns true (.T.) if the reversal is valid, otherwise false (.F.)
Return lRel
Important!