on 03-05-2007 9:44 PM
Hi All,
My requirement is that approvers or delegates should not be able to delete attachments from shopping cart. I did take a look at BBP_UI_CONTROL_BADI
but then that doesn't show any thing about field control in shopping cart (BUS 2121).
The other solution i was thinking about is to change the HTML templates to suppress that delete icon in approver screen. can anybody throw light on this issue
Points for sure!!
Rgds
Harshika
Hello Harshika,
Your approvers will have role
SAP_BBP_STAL_MANAGER or APPROVER
right?
in PFCG for this role
go to authorisations
go to change authorisations
you will shown a list of authorisations for this role
(and in turn for the users who are having this role).
Yoo need to deactivate the relevant authorisation so that
the users can not delete or change attachment.
Sorry ,I don't have system, Hence can't explore the correct name for you.
BR
Dinesh
<b>Reward if helps</b>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
As Yann suggested, we can go for the Authorization object.
Or <u>Else, you can also try out implementing the Business - AddIns using SE18 Transaction</u>
<b>BBP_ATT_CHECK</b>
Attachments
<b>BBP_AUTHORITY_CHECK</b>
Further Authorization Checks f. Documents in EBP
<u>Sample code for <b>BBP_ATT_CHECK</b> BADI Implementation -></u>
METHOD if_ex_bbp_att_check~check.
DATA:
lv_prof TYPE vscan_profile,
lo_vsi TYPE REF TO cl_vsi,
lv_xstring TYPE xstring,
lv_scanrc TYPE vscan_scanrc,
lt_bapiret TYPE vscan_bapiret2_t,
lv_bapiret TYPE bapiret2,
lv_size TYPE i,
lv_dummy TYPE bbp_control_value.
* transform the content table to a xstring
lv_size = attachment-phio_fsize.
CALL FUNCTION 'BBP_OUTPUT_X_TABLESIZE_CHG'
EXPORTING
iv_size = lv_size
IMPORTING
ev_xstring = lv_xstring
TABLES
it_data = attachment-phio_content[]
EXCEPTIONS
noentries = 1
OTHERS = 2.
IF sy-subrc = 0 AND NOT lv_xstring IS INITIAL.
* the default profile is used (see transaction SPRO)
CALL METHOD cl_vsi=>get_instance
EXPORTING
if_profile = lv_prof
IMPORTING
eo_instance = lo_vsi
EXCEPTIONS
configuration_error = 1
profile_not_active = 2
internal_error = 3
OTHERS = 4.
IF sy-subrc <> 0.
RETURN.
ENDIF.
* scan binary
CALL METHOD lo_vsi->scan_bytes
EXPORTING
if_data = lv_xstring
IMPORTING
ef_scanrc = lv_scanrc
et_bapiret = lt_bapiret
EXCEPTIONS
not_available = 1
configuration_error = 2
internal_error = 3
OTHERS = 4.
IF sy-subrc <> 0.
* error in call of scan engine
MESSAGE e013(bbp_att) INTO lv_dummy.
CALL FUNCTION 'BBP_PD_MSG_ADD'
EXPORTING
i_msgty = 'W'
i_msgid = sy-msgid
i_msgno = sy-msgno
EXCEPTIONS
log_not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
CALL FUNCTION 'BBP_PD_ABORT'.
ENDIF.
ENDIF.
IF lv_scanrc <> 0.
* scan got results that indicate infection
MESSAGE e014(bbp_att) WITH attachment-description INTO lv_dummy.
CALL FUNCTION 'BBP_PD_MSG_ADD'
EXPORTING
i_msgty = 'E'
i_msgid = sy-msgid
i_msgno = sy-msgno
i_msgv1 = sy-msgv1
EXCEPTIONS
log_not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
CALL FUNCTION 'BBP_PD_ABORT'.
ENDIF.
ENDIF.
LOOP AT lt_bapiret INTO lv_bapiret.
* apply scanmessages to our messagelog
MESSAGE ID lv_bapiret-id TYPE lv_bapiret-type NUMBER lv_bapiret-number
WITH lv_bapiret-message_v1
lv_bapiret-message_v2
lv_bapiret-message_v3
lv_bapiret-message_v4
INTO lv_dummy.
CALL FUNCTION 'BBP_PD_MSG_ADD'
EXPORTING
i_msgty = sy-msgty
i_msgid = sy-msgid
i_msgno = sy-msgno
i_msgv1 = sy-msgv1
i_msgv2 = sy-msgv2
i_msgv3 = sy-msgv3
i_msgv4 = sy-msgv4
EXCEPTIONS
log_not_found = 1
OTHERS = 2.
IF sy-subrc <> 0.
CALL FUNCTION 'BBP_PD_ABORT'.
ENDIF.
ENDLOOP.
ENDIF.
ENDMETHOD.
Hope this will help.
Please reward suitable points, incase it suits your requirements.
Regards
- Atul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Harshika ,
Attachment authorization object should be S_BDS_DS
Then you will have to unset the change or delete activity.
Kind regards,
Yann
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
<u>Couple of ways to get this done.</u>
<b>1) By modifying the HTML Templates of the Internest Service - BBPAPPROVAL using SE80 Transaction.</b>
<u>Note -> HTML Template modifications is not recommeded approach, but incase nothing suits the requirements, we need to go with it.</u>
<b>2) Either using SPRO. For the particular WORKFLOW (Subytpe), make the Task not possible for a set of persons / roles. I don't remember the correct steps, but will try to guide you the detailed steps in my next reply. </b>
<u>We have done this ealier using SPRO settings.</u>
3)This can be tried out. You need to set the attribute "BBP_WFL_SECURITY" to '1' or '2'(Low/Medium) so that the manager/approver is not able to delete the attachments, if any, in the document, in change mode.
Hope this will help.
Please reward suitable points, incase it suits your requirements.
Regards
- Atul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI Atul,
Thanks for the response. we need to have a control on deletion of attachments as in documents or attachments coming from the requestor cannot be deleted by a approver. But then he should be able to delete the attachments that he would be attaching during his approval stage.
Rgds
Harshika
Hi
Either go for authorization object and attach the same to the manager role so that he cannot add any attachements in the shopping cart.
Will give you the details of the authorization object details in my next reply and ask your BASIS person to do the same for you.
Inform your BASIS Team, to provide the authorization access for the Auth Object.
Hope this will help.
Please reward suitable points, incase it suits your requirement.
Regards
- Atul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.