Ansicht
Dokumentation

SIMG_PSMFG_AP_PRVAL - BAdI: Change Values to be Transmitted to the Asset Record

SIMG_PSMFG_AP_PRVAL - BAdI: Change Values to be Transmitted to the Asset Record

TXBHW - Original Tax Base Amount in Local Currency   BAL_S_LOG - Application Log: Log header data  
This documentation is copyright by SAP AG.
SAP E-Book

Use

This BAdI allows you to change the values to be passed to the asset master record.

Method: CHANGE_VALUES

Requirements

You must be using the Accountable Property program. In the program logic, many fields are calculated and MM Purchasing information is passed to the BAPI which creates the Asset Master. If you want to change any of the data that will be passed to the asset master, you change it here.

Standard settings

One asset or subasset will be created for each item. You can identify which purchasing data the asset represents by the importing fields PO number, PO item number, and account assignment.

You can then change the data in the "changing" tables below, and these updates will be passed back to the Accountable Property program for asset creation or posting.

PO_NUMBER,,,,,,Importing

PO_ITEM,,,,,,,,Importing

ACCOUNT_ASSIGNMENT,,Importing

GEN_DATA,,,,,,,,Changing

GEN_DATAX,,,,,,Changing

ACQUIS_DATA,,,,,,Changing

POSTING_DATA,,,,,,Changing

REAL_ESTATE,,,,,,Changing

REAL_ESTATEX,,,,,,Changing

POST_DATA,,,,,,Changing

POST_DATAX,,,,,,Changing

TIME_DEP_DATA,,,,,,Changing

TIME_DEP_DATAX,,,,,,Changing

Example

You want to assign a unique inventory number for each asset created:

*---- If a field that is required is empty, pass it the value you would

*---- like it to have, here we create a inventory number for the

*---- asset master record

IF gen_data-invent_no IS INITIAL.

*---- Execute customer function to get next inventory number

call function 'ZZ_GET_INVENTNO'

importing

invent_no = new_inventno.

gen_data-invent_no = new_inventno.

gen_datax-invent_no = 'X'.

ENDIF.

Method MESSAGE_EXCEPTION

The method MESSAGE_EXCEPTION allows you to suppress the error messages proposed by the program where required fields are not filled. This can be used where it is known that the required field will be populated later by the BAdI.

In some circumstances, you may want to add required fields to the asset after the program has executed. To suppress errors in posting to assets that are incomplete, perform FI-AA customizing which will allow message AAPO 184 to be displayed as a warning, and not an error. Although it is not recommended, assets can be created in an incomplete state and updated later, after asset record creation and acquisition posting.

The typing for the local table which you assign to the table parameter REQ_FIELD should be similar to the example in the sample implementation.

Activities






PERFORM Short Reference   ROGBILLS - Synchronize billing plans  
This documentation is copyright by SAP AG.

Length: 2998 Date: 20240523 Time: 170143     sap01-206 ( 49 ms )