Skip to Content
Author's profile photo Former Member

Charm navigation from WEB UI to SAP GUI SOLAR01/02 based on project Roles

In this document i will describe how we can mannage navigation from Charm documents to SOLAR01/02 based on project roles.

There is a possibility to navigate from Charm Change Transactions only to SOLAR01 directly, so if you work as developer or configuration consult you always need to do additional step jump to SOLAR02 from SOLAR01 and then choose needed tab to start work.

We can manage this behavior! why this need?

SOLAR01/02 can be central workspace for any sort of project memebers: customization consulting, developers, managers, administrators and more…

Main point is to have a single space of truth Project and database as Solution.

Scenario: in project ZXXX we have role (09)Application Implementation and config. When user who has role (09) navigating from Charm Transaction to SOLAR01/02 he directly navigates to SOLAR02 – Configuration tab.

Project members assigned to roles you can find in SOLAR_PROJECT_ADMIN – “Proj. Team Memeber tab” you can find project roles in same tab button Roles in project ( view V_CPIS_PARTROLE )

/wp-content/uploads/2013/11/roles_326468.png

There is no standard for this yet, so for this you need a little development but don’t worry i will explain how to!

We have to do 2 things :

  1. Create Customer Table where we will customize – Role: what transaction will be launched solar01 or 02 and wich tab will be displayed by default.
  2. Enhance Class CL_CHARM_PROJECT_INTERFACE – method GOTO_PROJECT.

1. Customization table

Tcode SE11 need to create 1 domain,  1  data element and 1 customizatoin table all in Z-Y namespace other fields for table exist in standard.

first create domain type Char8 with fix.val NAVSOL01 and NAVSOL02 this will need later.

se11_1.JPG

Second create customizing table how to – https://scn.sap.com/thread/779661

Input this fields

MANDT

ZTSOLI002_LINE

SPROJ_ROLE

TEXT40

PROJ_TABTYPE

PROJ_TABTEXT

Complete table we look like this:

se11_2.JPG

2. Enhance CL_CHARM_PROJECT_INTERFACE

Tcode SE24 enter CL_CHARM_PROJECT_INTERFACE now press menu Class – Enhance

/wp-content/uploads/2013/11/enh1_326469.png

Give Implementation name Z_anytext, short description and Composite Enhancement, if there is no create one

enh2.JPG

Now mark method GOTO_PROJECT and choose menu Edit-Enhancement Operations-Insert Overwrite-Methode.

***************************************************************************************************************************************

TIP( you may skip it )

why we are doing this? because navigation in method GOTO_PROJECT hardcoded to navigate always in SOLAR01

enh4.JPG

TIP end

***************************************************************************************************************************************

You will se icon on right side of method

/wp-content/uploads/2013/11/enh5_326481.png

Now Create own method f.e. ZGOTO_PROJECT and copy all parameters from original GOTO_PROJECT

enh6.JPG


METHOD zgoto_project_sol02 .
**********************************************************************
* Logic:
* For the consults to work via WEB UI f.e. from Normal Change
* and navigate directly to SOLAR02 instead of SOLAR01.
**********************************************************************
  DATA:
      ls_proj_role TYPE tressp
     ,ls_solarxx TYPE ztsole002_nav
     ,lv_check_ok TYPE boolean
     .
  CONSTANTS: aisol_c_dir_proj_nav_solar01(8)   TYPE c VALUE 'NAVSOL01'.
  lv_check_ok = abap_false.
* Check existens of user in project team
  SELECT SINGLE role INTO ls_proj_role-role
    FROM tressp
    WHERE sap_user = sy-uname
      AND project_id = i_project_id.
  IF sy-subrc = 0.
    lv_check_ok = abap_true.
  ENDIF.
* Check mapped tcode and tab
  SELECT SINGLE solarxx tabtype INTO CORRESPONDING FIELDS OF ls_solarxx
    FROM  ztsole002_nav
    WHERE role_id = ls_proj_role-role.
  IF sy-subrc = 0.
    lv_check_ok = abap_true.
  ELSE.
    lv_check_ok = abap_false.
  ENDIF.
* Navigate to mapped transaction SOLARXX and mapped TAB
  CALL METHOD cl_sproject_navigate=>call_ta_solar_static
    EXPORTING
      project_id             = i_project_id
      node_id                = i_node_to_navigate
      rep_type               = ls_solarxx-solarxx
      i_v_tab                = ls_solarxx-tabtype
*     start_in_new_task      = 'X'
    EXCEPTIONS
      no_structure_available = 1.
* if no mapping exist navigate standard SOLAR01
  CHECK lv_check_ok = abap_false.
* Navigate to the project in transaction SOLAR01
  CALL METHOD cl_sproject_navigate=>call_ta_solar_static
    EXPORTING
      project_id             = i_project_id
      node_id                = i_node_to_navigate
      rep_type               = aisol_c_dir_proj_nav_solar01
      i_v_tab                = i_tab
*     start_in_new_task      = 'X'
    EXCEPTIONS
      no_structure_available = 1.
ENDMETHOD.

Last we need to call our Z method in overwrite, now jump in this icon

/wp-content/uploads/2013/11/enh5_326481.png

Copy paste this:


    CALL METHOD core_object->ZGOTO_PROJECT_SOL02
      EXPORTING
        i_node_to_navigate = !i_node_to_navigate
        i_project_id       = !i_project_id
        i_tab              = !i_tab.

Activate everything!

Done! now we just enter needed data in table

MANDT         100

SOLARXX     NAVSOL02

ROLE ID        9

ROLETEXT   Application Implementation and Config.

TABTYPE      CONFIG

TABTEXT      CONFIGURATION

se11_3.JPG

Result:

Check that in project you are exist as team member with role type 09

proj 2.JPG

Launch SM_CRM and choose or create any change document insert Project business scenario and jump in it

proj 3.JPG

You will be navigated to SOLAR02 tab Configuration!

conf 3.png

So now you can play with customization table as much as you need. dont forget also there is a pfcg + project control of tabs. this is other topic.

Assigned Tags

      6 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Former Member
      Former Member

      Nice blog that shows how easy you can extend the standard features and get even more out of it 🙂

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      thanks 🙂

      right now im modeling a precodure to work in spro via SOLAR02.

      and this is a part of it.

      Author's profile photo Former Member
      Former Member

      Hi, Daniyar.


      I've read your usefull topic. In the end you have written "dont forget also there is a pfcg + project control of tabs. this is other topic". I am very interested in this subject, how to connect Role from Proj. Team member tab in SOLAR_PROJECT_ADMIN and PFCG-role. Could you give link on this topic or some advices how to customize it.


      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Hi Denis,

      I will make another Document or blog for this as soon as i have time.

      Hope this/next week, will link it with this document.

      Come back here soon 😉

      Rg Dan

      Author's profile photo Former Member
      Former Member

      Hi Daniyar!

      Have you any progress with my last question? 🙂

      Best regards,
      Denis

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Hi Denis,

      Sorry for the late, yes im working on it this or next week i will update

      Thanks Dan