SAP Function SAMPLE_INTERFACE_00001140 - Interface Description for Event 00001140

Parameter Reference Type Length Default Optional Text
I_PARKED XFELD C 1 X Document Already Parked

Parameter Reference Length Optional Text
T_BKPF BKPF 697 Accounting Document Header
T_BSEG BSEG 2012 Accounting Document Segment
T_EXCTAB EXCLTAB_LINE 20 Lines of EXCLTAB with OK Code to be Deactivated


trados = fi
DEFINE &TEXT& = 'Change Document, Transaction Access'
DEFINE &EVENT& = '00001140'
DEFINE &TYPE& = 'INTERFACE'
INCLUDE FI_OPEN_FI_DOCUMENTATION_1 OBJECT DOKU ID TX

EVENT
The event is in the PBO part of the FI posting transactions (FB60, FV60,
FB01, and so on). Here you can determine which pushbuttons or menuoptions are to be deactivated on a user-specific basis.

INTERFACE
Table T_BKPF, with the document headers, and table T_BSEG, with the line
items, are transferred to the additional component. In addition, theparameter I_PARKED is transferred; this has the value X if the documenthas been previously parked. You use this data to determine which actionsthe user is not to be permitted to perform.
Enter the OK codes that are not to be active in table T_EXCTAB. Theseare then hidden in the transaction.

Example
For example, in the parking transactions (such as STCODE = FV60), you ca
n prevent posting (OK code BU) if the user name in the document headeris the same as the current user. This enables you to implement the dualcontrol principle.
Example coding:
if sy-tcode = 'FV60'.
if i_parked = 'X'. " document has already been parked
read table t_bkpf index 1.
if t_bkpf-usnam eq sy-uname. " park user = current user ?
t_exctab-okcod = 'BU'. " do not allow to post
append t_exctab.
endif.
endif.
endif.

361420FB60: User exit for deactivating functions