cancel
Showing results for 
Search instead for 
Did you mean: 

CHARM Process Type in AIC_CM_TRANS_CR component

0 Kudos

Does anyone know how to get the Process Type field ( holds Normal Change/Admin Change/RfC value) while inside the AIC_CM_TRANS_CR component class ZL_AIC_CM_T_TRANSPORTREQP_CN05? I have enhanced the AIC_CM_TRANS_CR/TransportReqPage1 view and redefined the GET_CHKB_REQ_TYPE_CUST ( the checkbox on the transport create screen for workbench or customizing ) .

In the class CL_AIC_CMCD_BTPARTNERSET_CN this is how you get it, iv_process_type = me->mo_view_controller->get_process_type( ), but that won't work in CL_AIC_CM_T_TRANSPORTREQP_CN05.

Any ideas?

Thanks for any help.

Accepted Solutions (0)

Answers (1)

Answers (1)

thalesvb
Active Contributor
0 Kudos

AIC_CM_TRANS_CR component keeps BTAdminH reference into its component controller. If you check the view controller from AIC_CM_TRANS_CR/TransportReqPage1, you'll see that it fetches the Process Type on DO_VIEW_INIT_ON_ACTIVATION method by acessing the component controller context node. Process Type get call isn't on print, but you'll find it on code, I'm just pointing here how to access context node from controller.

You can apply the same logic on context: get the owner from context node (view), then proceed as the standard does.

A better way is to redefine DO_VIEW_INIT_ON_ACTIVATION and then make it propagate Process Type to context node, by setting a new (class) attribute on it. This will make it read Process Type from entity once.

Regards