on 01-03-2013 10:51 AM
Hi,
I have a requirement where i hv to create one business role (zaccountant1) by copying existing role(zaccountant) with few changes. Now, client want that the new role should be assigned during mid month and month end (eg on 15th & 16th Jan then on 30th 31st Jan). rest of the days Zaccountant role should work.day
Role Zaccountant1- for mid and month end
Zaccountant - rest 27 days of the month.
Is it possible to change the role automatically, so that we need not to assign it again and again?? possible?
Please share your views and possibility.
Regards,
Himanshu
Hi Himanshu,
You can do it automatically.Just try below steps.
Note :- If you know any other BAdi which is getting called during web ui loading use it.
DATA lr_ui_profile TYPE REF TO cl_crm_ui_profile.
lr_ui_profile ?= cl_crm_ui_profile=>get_instance( ).
IF sy-datum = '20130104'.
lr_ui_profile->if_crm_ui_profile~set_profile(
iv_profile = 'SALESPRO'
).
ELSE.
lr_ui_profile->if_crm_ui_profile~set_profile(
iv_profile = 'SERVICEPRO'
).
ENDIF.
Regards.
Rajarama U
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks Raja..I have another issue raised before implementing this. Enclosing here a screens shot. where i want to hide or deactivate the corporate/individual account option and only search criteria should be there. I tried in Business role and could hide the whole Accounts option. Though i need to hide only create corp/individual accounts option. please share your inputs.thanks
Hi Himanshu.
What you need to do is more or less explained here: http://blog.acorel.nl/2012/01/how-to-hide-buttons-for-unauthorized.html
Just redefine the DO_PREPARE_OUTPUT in the relevant View, and grey out (or delete) the undesired buttons.
You could also create a custom authorization object and validate it in the method redefinition, using the Authority check result to hide the buttons your users are not authorized to see. The standard method code will surely be or great help.
Hope it helps.
Regards,
Federico
Hi Himanshu,
For this you simply need to enhance component 'BP_HEAD_SEARCH' and the view '/MainSearchResult ' after that just go to DO_PREPARE_OUTPUT method of this view and and comment out the code for buttons that you want to delete otherwise if you want to only disable these buttons then you need to make
ls_button-enabled parameter as false .
Hope it helps.
Thanks
Kumar.
Hi Himanshu,
Can you share the logic that you used to solve your Original requirement of changing Business Roles?
Regards
Rajarama U
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raja,
Instead of using two roles, we used only one role. Here, we created a Ztable in CRM, which will have business cycle end dates(which we used to change the dates). Made changes in the program in
component 'BP_HEAD_SEARCH' and the view '/MainSearchResult ', DO_PREPARE_OUTPUT(as given by Gaurav below)
and assign the new role in org structure.
Now its is in production for testing purpose as our client has two closings in a month. Let me know if you want to have a detail document from the same
Cheers!
Himanshu
User | Count |
---|---|
4 | |
1 | |
1 | |
1 | |
1 | |
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.