cancel
Showing results for 
Search instead for 
Did you mean: 

Agent Inbox Result enhancement-how to read attribute value from tree?

Former Member
0 Kudos

Hi Experts,

I have a requirement to add custom field in Agent Inbox Search result. I am able to bring the field onto the UI as per the steps given in the below thread:-

Now I am stuck with-how to populate the field.I am planning to do some coding in the getter method of the field.But I have no idea how to read value from the tree node.All the getters are defined in the class-CL_CRM_AUI_WORKITEM and I can't modify that class.

My value is there in below path:-

me->bo gives=CL_BSP_WD_MIXED_NODE

Under CL_BSP_WD_MIXED_NODE, we have MODEL_NODE=CL_CRM_AUI_WORKITEM

under CL_CRM_AUI_WORKITEM, we have BOL_ENTITY.

This BOL_ENTITY has an attribute whose value i need to read and set in the getter.

Any sample coding or any pointers in this regard will be very helpful for me!

Thanks and Regards,

Rohit

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

solved myself! Sample coding below for the Get_SOF_SDR_ADDR method:-

DATA:

lr_entity type ref to if_bol_bo_property_access,

lr_mixed_ent type ref to cl_bsp_wd_mixed_node,

lr_inbox_item type ref to cl_crm_aui_entity,

lv_value type string.

lr_mixed_ent ?= me->bo.

lr_inbox_item ?= lr_mixed_ent->if_bsp_wd_ext_property_access~get_model_node( ).

lr_entity = lr_inbox_item->get_bol_entity( ).

lv_value = lr_entity->get_property_as_string( IV_ATTR_NAME = 'SOF_SDR_ADDR' ).

value = lv_value.