on 09-14-2010 2:55 PM
Hi,
We are implementing process controlled workflow for Shopping Cart in SRM 7.0 (release 701).
In the rejection scenario of the SC (thru SRM portal), we want to make the "Approval note" as mandatory to be filled in by the Approver, i.e. the "Reason for Rejection" should be made mandatory.
Please advise on the approach.
Note: I already have gone thru the below thread for SRM 5.0. I tried to use BAdi BBP_DOC_CHECK_BADI, but din't get any help.
Key Terms:
SRM 7.0
Process Controlled workflow
SRM Portal
Reason for Rejection
Approval Note
Regards,
Bijaya
Hi,
In the doc check badi, try using the GETDETAIL FM, and check if E_LONGTEXT-TDID = 'NOTM' (Approval Note) exists.
Regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for all your suggestion.
I am using custom implementation of BAdi BBP_DOC_CHECK_BADI with the below logic.
1. Use FM BBP_PD_SC_GETDETAIL to get E_LONGTEXT.
2. Use method GET_CURRENT_DECISION of class /SAPSRM/CL_WF_APV_FACADE to get current decision.
3. Check if current decision is REJECTED.
4. Check if E_LONGTEXT has TDID = NOTM.
5. Populate error message u201CEnter Reason for Rejection in Approval Noteu201D on to ET_MESSAGE.
The above logic works fine when the approver uses u201CDETAILSu201D button on SRM portal (UWL) and then clicks on REJECT button.
But when the approver directly clicks on REJECT button on the UWL, the SRM portal throws an exception. I believe this is because system does not find any place to show the above error message. Can we have our error message be displayed on a pop-up window on the UWL? will this need webdynpro knowledge?
Please advise.
Regards,
Bijaya
Hi Bijay
UWL will behave like this in case of any error in SC. Is Approval or Rejection Note mandatory for every SC in your organization.
If that is the case, disable the Approve Reject button in UWL. Othewise I dont see any mechanism to show the error in UWL.
Approve Reject Buttons in UWL can be disabled by Portal administrator in UWL configuration
Regards
Virender Singh
Thanks for all your help.
Removing / disabling REJECT button on UWL will be the last option we can have.
Please let me know if it is possible to display an error message on a pop-up on the UWL portal. I tried to use FM BBP_PD_MSG_ADD, but it din't help. Please advise.
CALL FUNCTION 'BBP_PD_MSG_ADD'
EXPORTING
i_msgty = c_msgty
i_msgid = c_msgid
i_msgno = c_msgno
I_FIELD_NAME = 'EXPRESS'
EXCEPTIONS
LOG_NOT_FOUND = 1
OTHERS = 2.
Regards,
Bijaya
Hi
This is possible through DOC CHeck BADI.
Regards
Virender Singh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Use the following class in your dynamic class of the field metadata
CALL METHOD /SAPSRM/CL_WF_APV_FACADE=>GET_CURRENT_DECISION
EXPORTING
IV_DOCUMENT_GUID = iv_document_guid
IMPORTING
EV_DECISION = EV_DECISION.
IF EV_DECISION = 'Inquired'.
Here you can change your field as required..
End if.
This is just a suggestion, I never tried it, But I hope this will resolve your issue..
Thanks!!
Bharath
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.