• A Confluence está sendo executada atualmente com todos os plugins que não são do sistema desabilitados. Pode haver perda de algumas funcionalidades
Páginas filhas
  • Bank Transactions - FINA100 - Financial - P12


Notification


This routine was adjusted to comply with the Data Protection General Regulation (Law No. 13.70), so that some fields containing data regarded as sensitive and/or personal are blurred, becoming illegible.


01. OVERVIEW

Through its routines and processes, Protheus controls the banking account inflows and outflows. It is possible to add transactions and to transfer values among banks.
The first stage of implementing bank transactions is in the registration of bank information where your company transacts. Several banks can be registered.

02. EXECUTION 

  • Manually

Procedure manually performed through the Bank Transactions routine (FINA100), with the display of the screens involved in the process - actions/commands from the user are required

  • Automatically

Procedure automatically performed in the Bank Transactions routine (FINA100) without the display of screen - no interaction from the user required.
Used in customizations in which the process does not require user's interactions (MSEXECAUTO).

Documentation: Inclusion of Automatic Bank Transactions - FINA100



Important

As this is internal control, the field "Type of Transaction" (E5_TIPODOC) has these features:

  • In the manual execution, you cannot put it to use;
  • In the automatic execution, even if this field is sent, the system will not consider it.

From 11/04/2020, this field began to be recorded as "DH".




Example of automatic routine  
#INCLUDE "Protheus.ch"

User Function TST100()
Local nOpc     := 0
Local aFINA100 := {}

Private lMsErroAuto := .F.

While .T.

    nOpc := 0
    nOpc := Aviso("TESTE EXECAUTO DO FINA100", "Choose the menu option of the FINA100 routine to be executed via EXECAUTO",{"PAY","RECEIVE","DELETE","CANCEL","TRANSF.","ST. TRANSF."})
    
    If nOpc == 1   
        aFINA100 := {    {"E5_DATA"        ,dDataBase                    ,Nil},;
                            {"E5_MOEDA"        ,"M1"                            ,Nil},;
                            {"E5_VALOR"         ,500                            ,Nil},;
                            {"E5_NATUREZ"    ,"001"                    ,Nil},;
                            {"E5_BANCO"        ,"001"                        ,Nil},;
                            {"E5_AGENCIA"    ,"001"                        ,Nil},;
                            {"E5_CONTA"        ,"001"                        ,Nil},;
                            {"E5_BENEF"        ,"TESTE AUTO - BENEF"    ,Nil},;
                            {"E5_HISTOR"    ,"TESTE AUTO - AUTO"        ,Nil},;
                            {"NCTBONLINE"       ,1                    ,Nil}} //1=Sim;2=Não
    
        MSExecAuto({|x,y,z| FinA100(x,y,z)},0,aFINA100,3)
    
        If lMsErroAuto
            MostraErro()
        Else
            MsgAlert("Bank Transfer Pay successfully added !!!")
        EndIf       
        
    ElseIf nOpc == 2
        aFINA100 := {    {"E5_DATA"        ,dDataBase                    ,Nil},;
                            {"E5_MOEDA"        ,"M1"                            ,Nil},;
                            {"E5_VALOR"         ,1500                            ,Nil},;
                            {"E5_NATUREZ"    ,"001"                        ,Nil},;
                            {"E5_BANCO"        ,"001"                        ,Nil},;
                            {"E5_AGENCIA"    ,"001"                        ,Nil},;
                            {"E5_CONTA"        ,"001"                        ,Nil},;
                            {"E5_HISTOR"    ,"TESTE AUTO - AUTO"        ,Nil},}
							{"NCTBONLINE"       ,1                    ,Nil}} //1=Sim;2=Não
    
        MSExecAuto({|x,y,z| FinA100(x,y,z)},0,aFINA100,4)
    
        If lMsErroAuto
            MostraErro()
        Else
            MsgAlert("Bank Transfer Receive successfully added !!!")
        EndIf       
    
    ElseIf nOpc == 3
        dbSelectArea("SE5")
        SE5->(dbSetOrder(1))
        SE5->(dbSeek(xFilial("SE5")+DToS(dDataBase) ))
        aFINA100 := {    {"E5_DATA"             ,SE5->E5_DATA            ,Nil},;
                            {"E5_MOEDA"             ,SE5->E5_MOEDA            ,Nil},;
                            {"E5_VALOR"             ,SE5->E5_VALOR            ,Nil},;
                            {"E5_NATUREZ"        ,SE5->E5_NATUREZ        ,Nil},;
                            {"E5_BANCO"            ,SE5->E5_BANCO            ,Nil},;
                            {"E5_AGENCIA"         ,SE5->E5_AGENCIA        ,Nil},;
                            {"E5_CONTA"         ,SE5->E5_CONTA            ,Nil},;
                            {"E5_HISTOR"        ,SE5->E5_HISTOR        ,Nil},;
                            {"E5_TIPOLAN"        ,SE5->E5_TIPOLAN        ,Nil} }
    
        MSExecAuto({|x,y,z| FinA100(x,y,z)},0,aFINA100,5)
    
        If lMsErroAuto
            MostraErro()
        Else
            MsgAlert("Deletion successfully executed !!!")
        EndIf       

    ElseIf nOpc == 4
        dbSelectArea("SE5")
        SE5->(dbSetOrder(1))
        SE5->(dbSeek(xFilial("SE5")+DToS(dDataBase) ))
        dbSkip() //added only for this tests sequence
        aFINA100 := {    {"E5_DATA"             ,SE5->E5_DATA            ,Nil},;
                            {"E5_MOEDA"             ,SE5->E5_MOEDA            ,Nil},;
                            {"E5_VALOR"             ,SE5->E5_VALOR            ,Nil},;
                            {"E5_NATUREZ"        ,SE5->E5_NATUREZ        ,Nil},;
                            {"E5_BANCO"            ,SE5->E5_BANCO            ,Nil},;
                            {"E5_AGENCIA"         ,SE5->E5_AGENCIA        ,Nil},;
                            {"E5_CONTA"         ,SE5->E5_CONTA            ,Nil},;
                            {"E5_HISTOR"        ,SE5->E5_HISTOR        ,Nil},;
                            {"E5_TIPOLAN"        ,SE5->E5_TIPOLAN        ,Nil} }
    
        MSExecAuto({|x,y,z| FinA100(x,y,z)},0,aFINA100,6)
    
        If lMsErroAuto
            MostraErro()
        Else
            MsgAlert("Cancellation successfully executed !!!")
        EndIf       

    
    ElseIf nOpc == 5
        aFINA100 := {    {"CBCOORIG"             ,"001"                            ,Nil},;
                            {"CAGENORIG"        ,"001"                            ,Nil},;
                            {"CCTAORIG"             ,"001"                            ,Nil},;
                            {"CNATURORI"         ,"001"                            ,Nil},;
                            {"CBCODEST"            ,"002"                            ,Nil},;
                            {"CAGENDEST"         ,"002"                            ,Nil},;
                            {"CCTADEST"         ,"002"                            ,Nil},;
                            {"CNATURDES"        ,"002"                            ,Nil},;
                            {"CTIPOTRAN"        ,"CH"                                ,Nil},;
                            {"CDOCTRAN"            ,"123456"                        ,Nil},;
                            {"NVALORTRAN"        ,2500                                ,Nil},;
                            {"CHIST100"            ,"TESTE TRF VIA EXECAUTO"    ,Nil},;
                            {"CBENEF100"        ,"TESTE TRF VIA EXECAUTO"    ,Nil},;
                            {"NAGLUTINA"        ,2                    ,Nil},; //1=Sim;2=Não
                            {"NCTBONLINE"       ,1                    ,Nil}; //1=Sim;2=Não
                    }
    
        MSExecAuto({|x,y,z| FinA100(x,y,z)},0,aFINA100,7)
    
        If lMsErroAuto
            MostraErro()
        Else
            MsgAlert("Transfer successful !!!")
        EndIf       
                    
    //Transfer Reversal
    ElseIf nOpc == 6
        aFINA100 := {    {"AUTNRODOC"         ,"123456"                ,Nil},;
                            {"AUTDTMOV"            ,dDataBase                ,Nil},;
                            {"AUTBANCO"             ,"001"                    ,Nil},;
                            {"AUTAGENCIA"     ,"001"                    ,Nil},;
                            {"AUTCONTA"            ,"001"                    ,Nil} }
                    
        MSExecAuto({|x,y,z| FinA100(x,y,z)},0,aFINA100,8)
    
        If lMsErroAuto
            MostraErro()
        Else
            MsgAlert("Transfer successfully canceled !!!")
        EndIf       
    EndIf
    If nOpc == 0
        Exit
    Endif
Enddo
    
Return(Nil)


03. OPERATIONS

  • Pay

This option allows adding an amount payable to the bank transactions.

  • Receive 

This option allows adding amounts receivable to the bank transaction.

  • View

This option allows viewing the bank transaction registered, both payable or receivable.

  • Accounting tracker 

It displays the query with the transaction accounting entry if this has been accounted for.

  • Caption 

It displays the caption chart and meanings related to the transaction status


  • Delete

This operation allows deleting the bank transaction both payable and receivable, deleting the database record

  • Cancel

This operation performs the counterpart of the transaction, which means reversing the value paid or received.

  • View Apportionments

This operation allows viewing the accounting apportionment applied to the bank transaction. 

  • Locate 

Research the transaction in the bank transactions file, resulting in the transaction placed and highlighted in the browser.

  • Transfer between Checking Accounts

It executes two bank transactions in a single operation: outflow from the source account and inflow into the target account.

  • Transfer reversal between Checking Accounts

It reverses the transfer executed, returning the values to the source accounts

  • Classification

This option allows the accounting of a bank transaction.

04. PARAMETERS

List of parameters applied to FINA100 and its processing



05. FINANCIAL RULE

The Bank Transaction is used to perform entries between accounts by feeding the balance in the SE8 - Bank Balances table, and by registering the transactions in the SE5 = Bank Transaction table. This basic characteristic does not generate revenues and expenses for the company, only controlling inflows and outflows of values between accounts.

06. MAIN PROCESSES



07. ACCOUNTING

LP

Generator Fact

On

Off (CTBAFIN)

516

Addition of bank transaction payable with apportionment 

X

X

517

Addition of bank transaction receivable with apportionment 

X

X

557

Cancellation of bank transaction payable with apportionment

X

X

558

Cancellation of bank transaction receivable with apportionment 

X

X

560

Bank transfer - source bank outflow 

X

X

561

Financial transfer - source bank inflow 

X

X

562

Bank transaction payable 

X

X

563

Bank transaction receivable

X

X

564

Cancellation bank transaction payable 

X

X

565

Cancellation bank transaction receivable

X

X

Configuration of standard entries for this routine


08. ENTRY POINTS

Entry point

Description 

F100BROW

The entry point is executed before the bank transaction browser.
Document: F100BROW - Bank Transaction – 11684

FA100PAG

The entry point will be used after the recording of the accounting data of accounts payable in the bank transaction.
Document: http://tdn.totvs.com.br/display/public/mp/FA100PAG+-+Grava+dados+--+11930

FA100REC

The entry point is used after the recording of data and the accounting of the accounts receivable in the bank transaction.
Document: http://tdn.totvs.com.br/display/public/mp/FA100REC+-+Grava+dados+--+11931

FINATROC

Executed after the recording of all transactions receivable and accounting data. Used only by the SIGALOJA environment. Document: FINATROC - Recording of transaction receivable data – 12069

FA100VLD

Allows the user to create validations in relation to access to deletion and cancellation of bank transaction.
Document: FA100VLD - Validation of deletion and cancellation – 24109

FA100CA2

executed after the confirmation of Deletion of Bank Transaction, before the deletion and accounting.
Document: FA100CA2 - Cancel bank transaction – 11924

FA100CAN

The entry point will be used after the deletion of bank transactions before the accounting.
Document: FA100CAN - Cancel bank transaction – 11925

FA100Get

allows the customer to fill out the bank transfer screen data automatically.
Document: FA100GET - Completion of bank transfer screen – 109531

FA100TRF

executed before the transfer and returns .T. to record the transfer or .F. otherwise.
Document: FA100TRF - Record transfer

F100DOC

used to edit the check number during the transfer between banks and bank branches.
Document: F100DOC - Change of the check number – 11685

A100BL01

executed after the recording of bank transfer data.
Document: A100BL01 - Recording of data – 11548

FA100DOC

Is used to manipulate the variable cDocTran. Return: value that must be in cDocTran Parameters: cBcoOrig, cAgenOrig,cCtaOrig,cTipoTran
Document: FA100DOC - Manipulate variable – 11926

A100TR01

used in the recording of bank transaction transfer.
Document: http://tdn.totvs.com.br/display/public/mp/A100TR01+-+Transferencia+de+movimento+bancario+--+11549

A100TRA

A100TRA entry point complements the A100TR01 entry point. This entry points receives a parameters array with this content: lEstorno, cBcoOrig, cBcoDest, cAgenOrig, cAgenDest, cCtaOrig, cCtaDest, cNaturOri, centuries, cDocTran,cHist100.
Document: A100TRA - Bank Transaction – 11552

A100TR02

used during the recording of bank transfer data
Document: A100TR02 - Recording of bank transfer data – 11550

A100TRB

A100TRB entry point complements the A100TR02 entry point.This entry point receives a parameters array with this content: lEstorno, cBcoOrig,cBcoDest, cAgenOrig, cAgenDest,cCtaOrig,cCtaDest,cNaturOri,cNaturDes,cDocTran, cHist100.
Document: A100TRB - Recording of transfer – 11553

A100TR03

executed after the recording of the bank transfer data. After recording the SE5 of Source/Target banks after the accounting.
Document: A100TR03 - Recording of bank transfer data – 11551

A100TRC

A100TRC entry point complements the A100TR03 entry point.This entry point receives a parameters array with this content: lEstorno, cBcoOrig, cBcoDest, cAgenOrig, cAgenDest, cCtaOrig, cCtaDest, cNaturOri, cNaturDes, cDocTran, cHist100.
Document: A100TRC - Record of Transfer – 11554

F100TOK

Validates the bank transaction data.
Document: F100TOK - Validate bank transaction data – 11688

FA100TRF

The entry point FA100TFR is executed before the transfer and returns .T. To record the transfer or .F. otherwise.
Document: FA100TRF - Record Transfer – 11932

FA100ROT

Allows the addition of customized buttons in theEnchoiceBar of the Bank Transaction routine.
Document:  FA100ROT - Addition of customized buttons in the EnchoiceBar – 30104

FA100OKP

Used to block the addition of transactions payable in the Bank Transactions routine. If it returns true, the transaction is regularly performed, otherwise, there will not be addition of transaction. Logic return.
Document: FA100OKP - Block transaction addition – 11928

FA100OKR

Used to block the addition of transactions payable in the Bank Transactions routine. In case the return is true, the transaction is regularly executed, otherwise, the transaction will not be added. Logic return.
Document: FA100OKR -Block addition of transactions – 11929

A85CHPDT

Allows the user to perform the own treatment to select the third party checks that may be used in the type of payment entered in the option differentiated payment.
Document: A85CHPDT - Selection of third party checks – 11564

F100FBRW

The entry point is executed before the bank transaction browser.
Document: F100FBRW - Allows to filter bank transactions


09. TABLES

  • SE5 – Bank Transaction 
  • SE1 - Accounts receivable 
  • SE2 - Accounts payable 
  • SE3 - Sales Commissions
  • SEF - Checks 
  • SI1 - Chart of Accounts. 
  • SI2 - Accounting Entries
  • SI5 - Standardized Entries.
  • SI6 - Totals Batches 
  • SM2 - Currencies
  • FJU - Saves bills deleted  
  • FK1 - Posting Payment receivable
  • FK2 - Posting Payment Payable
  • FK3 - Calculated taxes
  • FK4 - Withheld taxes 
  • SE5 – Bank Transaction
  • FK6 - Accessory values
  • FK8 - Accounting Data
  • FK9 - Transaction complement
  • FKA - Transaction tracking