Description | The entry point AF126TOK validates the data before the approval of the asset posting/transfer. |
---|---|
Examples | #INCLUDE "Protheus.ch" User Function AF126TOK() Local nOpc := ParamIxb[1] // 3=Approval, 4=Rejection Local cTipoSol := ParamIxb[2] // 1=Posting, 2=Transfer Local cCodigo := ParamIxb[3] // Code of the transfer Local cBase := '' Local cItem := '' Local lRet := .T. Local aArea := GetArea() dbSelectArea("SNM") SNM->( dbSetOrder(1) ) SNM->( dbSeek( xFilial("SNM") + cCodigo ) ) cBase := SNM->NM_CBASE cItem := SNM->NM_ITEM IF cTipoSol == "1" //Posting If MsgYesNo( "Approve the asset posting " + cBase + " / " + cItem + " ?", "Notice" ) lRet := .T. Else lRet := .F. EndIf ElseIf cTipoSol == "2" //Transfer If MsgYesNo( "Approve the asset transfer " + cBase + " / " + cItem + " ?", "Notice" ) lRet := .T. Else lRet := .F. EndIf EndIf RestArea(aArea) Return lRet |
Language | Portuguese(Brazil) |
Versions | Microsiga_Protheus11 |
Operating Systems Supported | All |
Compatible with the following Databases | All |
Parameters | nOpc : 3 = Approval, 4 = Rejection cTipoSol : 1=Posting, 2=Transfer cCodigo : Code of the Transfer |
Return | lRet : Logical |
Call events of the Entry Point | If ExistBlock("AF126TOK") lRet := ExecBlock("AF126TOK", .F., .F.,{nOpc,cTipoSol,cCodigo}) EndIf |
Source Program | ATFA126.PRW |