Versões comparadas

Chave

  • Esta linha foi adicionada.
  • Esta linha foi removida.
  • A formatação mudou.

01. GENERAL DATA

Product:

TOTVS Backoffice

Product Line:

Protheus Line

Industry:

Services

Module:

TOTVS Backoffice (Protheus Line) - Fixed Assets (SIGAATF)

Function:

ATFA251

Country:

Brazil

Ticket:

Internal

Requisite/Story/Issue

DSERCTR1-46748

02. DESCRIPTION

You can use entry point AF251AHD to add user fields to the aHeader of routine ATFA251 - Acquisition by Transfer.

...

Bloco de código
languagecpp
themeRDark
titleHandling of EP in the system
aOldHead := aClone(aHeader)
aAF251AHD := ExecBlock('AF251AHD', .F., .F., aClone(aHeader) )
aHeader := aClone( aOldHead )
If ValType( aAF251AHD ) == 'A'
      For nX := 1 To Len( aAF251AHD )
            If Len( aAF251AHD[nX] ) == 9 .and.  ValType( aAF251AHD[nX][1] ) == 'C' .and. ValType( aAF251AHD[nX][2] ) == 'C' .and.;
                  ValType( aAF251AHD[nX][3] ) == 'C' .and. ValType( aAF251AHD[nX][4] ) == 'N' .and. ValType( aAF251AHD[nX][5] ) == 'N' .and.;
                  ValType( aAF251AHD[nX][6] ) == 'C' .and. ValType( aAF251AHD[nX][7] ) == 'C' .and. ValType( aAF251AHD[nX][8] ) == 'C' .and.;
                  ValType( aAF251AHD[nX][9] ) == 'C' .and. aScan( aHeader, {|aHd| aHd[2] == aAF251AHD[nX][2]} ) == 0
                  
                  Aadd( aHeader, aClone(aAF251AHD[nX]) )
            EndIf
      Next nX
EndIf

...