on 02-25-2014 6:59 AM
Hi Expert,
There is one requirement aboutt authorization check for Pricing.
If the user don't have Display auth, the charge should not display.
If the user don't have Update auth, the charge should be read only.
We try to achive this on BOPF authorization check framework. But it seems don't work.
Do you have any suggestions about it?
Best Regards
Clark Huang
Hi Clark,
You can create a determination for that node, and in that determination class you can check the authorization for particular user using authorization check functional module.
After that check the value of sy-subrc. if it is not initial then you can make that field invisible using lo_property.
check out the following code.
DATA : LO_PROPERTY TYPE REF TO /BOBF/CL_LIB_H_SET_PROPERTY.
CREATE OBJECT LO_PROPERTY
EXPORTING
IS_CONTEXT = IS_CTX " Context Information for Determinations
IO_MODIFY = IO_MODIFY. " Interface to Change Data
you can set your field properties using following code
LO_PROPERTY->SET_ATTRIBUTE_READ_ONLY(
EXPORTING
IV_ATTRIBUTE_NAME = <your constant interface name>=>SC_NODE_ATTRIBUTE-<your Node name>-<Fieldname> " Name of the attribute for which the property is to be set
IV_KEY = <your instance key> " Key of the instance for which the property is to be set
IV_VALUE = ABAP_FALSE " New value of this property (true/false)
).
Thanks and regards,
Chetan P. Patil
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
9 | |
4 | |
3 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.