Usina BRAdvPL Guide
Sign in
← All topics
ENTRY POINTUnder review

OM030VTS

User Function OM030VTS()

Validates service type and time type in two contexts.

Entry pointOFIOM030SIGAOFIExecBlock
01 · OVERVIEW

Overview

Analysis of the OFIOM030.PRW caller in the Workshop module (SIGAOFI). FS_SERTEM / FS_SELECIONA. Calls at lines 2592, 8718. PARAMIXB: [1] numeric context (1 in FS_SERTEM, 2 in FS_SELECIONA); [2] service type; [3] time type; [4] lMensagem; [5] lTpo. Context 2 sends .F. in [4] and [5]. .F. stops the calling function; .T. allows its remaining checks. FS_SERTEM lTpSrvBlq is not passed. Scope: fontes_2210 repository version, commit d6f74ed8f5a2c61a69e9f903b041b4ee425a6ae9, accessed November 9, 2026. Software de Terceiros/MIL contains a customized variant; it does not establish a universal TOTVS contract. Under review: static caller analysis; editorial examples neither compiled nor run in Protheus. Confirm includes, dependencies, release and environment patch.

02 · SYNTAX

Syntax

User Function OM030VTS()

Parameters

PARAMIXB[1]
NExecution context

Context 1: FS_SERTEM; context 2: FS_SELECIONA.

PARAMIXB[2]
CExecution context

Service type.

PARAMIXB[3]
CExecution context

Time type.

PARAMIXB[4]
LExecution context

lMensagem; .F. in context 2.

PARAMIXB[5]
LExecution context

lTpo; .F. in context 2.

Return value

Logical, consumed according to the control described above.

03 · PRACTICAL EXAMPLE

Editorial skeleton preserving current behavior

#Include "Protheus.ch"

/*/{Protheus.doc} OM030VTS
    Validates service type and time type in two contexts.
/*/
User Function OM030VTS()
    // Preserves the value required by this call-site consumer.
    // Add rules only after validating this context in the target release.
Return .T.
Expected result

Original editorial example without an additional business rule. Neither compiled nor run in Protheus. Logical, consumed according to the control described above.

BEST PRACTICES
  • Preserve work areas when adding queries; avoid irreversible external effects and validate interactive and automatic paths separately.
  • Under review: static caller analysis; editorial examples neither compiled nor run in Protheus. Confirm includes, dependencies, release and environment patch.
COMMON PITFALLS
  • The caller does not contain hook implementations or all dependencies. A call site does not prove hook execution or compatibility with other releases.

Related content

REFERENCES
  1. MICHELSEN, Leandro (repository). OFIOM030.PRW. leandromichelsenbr/fontes_2210, Software de Terceiros/MIL. Commit d6f74ed8f5a2c61a69e9f903b041b4ee425a6ae9. Accessed Nov. 9, 2026. Calls at lines 2592.
  2. MICHELSEN, Leandro (repository). OFIOM030.PRW. leandromichelsenbr/fontes_2210, Software de Terceiros/MIL. Commit d6f74ed8f5a2c61a69e9f903b041b4ee425a6ae9. Accessed Nov. 9, 2026. Calls at lines 8718.
Status
Under review
Page created on
Last reviewed on
Original language
Portuguese
Reviewed by
Usina.BR

Was this content helpful?

👍 Like 0👎 Dislike 0

Sign in to rate this article.

0 approved comment(s)

Comments

There are no approved comments yet.

Sign in with Google or Microsoft to comment.

Powered by Usina Docs · Alpha