Ansicht
Dokumentation

FRML984_STATCHNG_AT_CHECK - NOTRANSL: Rezeptformel: Prüfungen bei Statusänderungen

FRML984_STATCHNG_AT_CHECK - NOTRANSL: Rezeptformel: Prüfungen bei Statusänderungen

PERFORM Short Reference   PERFORM Short Reference  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

You use this function to check whether status changes in the scopes of application for a formula are allowed. In the standard system, the function is called when you choose Enter to confirm an entry on the Scope of application formula view (see environment parameter FRML_ASCP_UEXIT_CHK).

Scope of the Check

The function checks whether input materials have been maintained for a formula but no output materials. If this inconsistency exists:

  • You cannot set the Released status in the scope of application
  • The system issues a warning when you set the For release status

Restriction:
Dependent formulas do not have a status of their own. They have the same status as the recipe to which they belong. The above check therefore only takes effect in independent formulas.

Notes on Tailoring the Function Module

If you want to check status changes according to enterprise-specific criteria, you can assign your own function to environment parameter FRML_ASCP_UEXIT_CHK. Use this function module as a template. Do not change the interface of the function module.

The function receives the amount of status changes that exist when saving from the calling environment. In the function, you can check the individual status changes and, if necessary, reject them. You can specify an error message for each status change rejected. This error message is then displayed from the calling environment when necessary. If you do not specify a message, a standard message is displayed.

Interface: Imported Data

The import parameters contain information about the higher-level context (formula key, change number, and key date, OK code, and so on).
In addition, the Boolean parameter I_FLG_DIALOG also informs you if the call is made in the dialog or API logic.

The amount of status changes is specified in three table parameters:

  • Table of current status entries (I_IOTAB_SAV)
  • Table of how the status entries would look like after the planned changes are made (I_IOTAB)
This table contains the LINEMOD attribute. It is used to monitor how each data record was changed:
  • "I": The data record was created.

  • "U": The data record was changed.

  • " ": The data record already existed and was not changed.

  • Table of the planned deletion of status entries (I_IOTAB_DEL)
This table shows the data records to be deleted. The LINENO attribute, which is available in all the tables and specifies the line number, can be used to identify the data records. To compare the new situation with the old for data records in the second table whose LINEMOD value is "U", the function module must determine the data record in the first table that has the same value in the RECN attribute.
The tables need not always be sorted according to the LINENO attribute. Changes to the input parameters do not take effect since they represent local copies of the actual parameters. If required, you can also sort the tables in a different way.

Interface: Exported Data

In the function module, you can use the following attributes to fill the table parameter E_STATUS_CHANGES_REFUSED_TAB and reject planned changes to status entries:

  • DEL (= initial: LINENO refers to the second table;
= 'X': LINENO refers to the third table)
  • LINENO
  • Message number
  • Message class
  • Message type
  • Message placeholder no. 1
  • Message placeholder no. 2
  • Message placeholder no. 3
  • Message placeholder no. 4

The combination of DEL and LINENO refers to the line of the entry table parameters whose changes you want to reject. In the remaining, optional attributes, you can display your own error message. While your data is being saved, your entries in the output table are ignored.

Example

Notes

Further information

IMG activity Define and Assign Values to Environment Parameters





Parameters

E_STATUS_CHANGES_REFUSED_TAB
I_ACTYPE
I_ADDINF
I_FLG_DIALOG
I_IOTAB
I_IOTAB_DEL
I_IOTAB_SAV
I_KEYPATH
I_OKCODE
I_TRTYPE
X_ADD_PARAMS

Exceptions

ILLEGAL_INPUT
INTERNAL_ERROR

Function Group

FRML984

General Data in Customer Master   Fill RESBD Structure from EBP Component Structure  
This documentation is copyright by SAP AG.

Length: 5482 Date: 20240523 Time: 084644     sap01-206 ( 94 ms )