cancel
Showing results for 
Search instead for 
Did you mean: 

Displaying fields from a Z Table on CRM UI

Former Member
0 Kudos

Hello Experts

I am trying to display fields from a custom table onto a CRM UI form view.

1. I created a custom GENIL root object & Search object ie. ZCUSTOMER. & ZCUSTSEARCH

2. Tested this in the GENIL BROWSER to ensure that I could enter update values to the table and retrieve it via the search object.

3. Created a custom component ZCUSTOMER

4. Created a view with this component ZCUSTOMER using the wizard -

Model Name - CUSTINFO

BOL Entity - ZCUSTOMER

No links to the custom controller or higher level objects.(as I do not want to tie this to any standard components)

Type of view - Form view

7. Created a Context node for the component controller with the same info as I did for the view.

8. Performed the binding of the view context node with the component controller context node.

9. Configured 1 field CUST_NAME to be displayed on the view.

10. Configured the run time repository to display the view.

Now the issue is..

When the view gets displayed, the field is displayed with the error "CUST_NAME not bound"

What am i missing?

Thanks

RLX

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi CRM Gurus,

Any one ? Still looking for a solution.

Thanks in advance.

RLX

arunprakash_karuppanan
Active Contributor
0 Kudos

Hi Ravi,

In cases like this, you should create an instance of your custom entity using the factory class(CL_CRM_BOL_CORE->get_entity_factory and so forth...) and add it to the collection wrapper. Where exactly this should be done is up to you. You say that you have already tested this out in the BOL browser. It automatically creates the root objects for testing. Have you coded this part in your component?

Regards,

Arun Prakash

Former Member
0 Kudos

Hi Arun,

Thank you for the feedback. The root object and a search object are visible in the model and I was able to test in the BOL browser. I have not coded anything for the custom entity. Could you please explain to me in more detail where and how this is done.

Thanks

RLX

Former Member
0 Kudos

Hi Ravi

To bind the context of the attributes you will have to create an instance of entity and add it to the collection wrapper in WD_CREATE_CONTEXT method of the controller class.

Hope this helps.

Cheers

Swati.

Former Member
0 Kudos

Hi Swati,

Thanks for the feedback. I re-viewed the WD_CREATE_CONTEXT method of the view controller implementation class and I see the following code in there already-

method WD_CREATE_CONTEXT.

  • create the context

context = cl_bsp_wd_context=>get_instance(

iv_controller = me

iv_type = 'ZL_ZCUSTOMER_BSPWDCOMPONEN_CTXT' ).

typed_context ?= context.

endmethod.

Does that look right or do I need to modify it?

Thanks once again for the help.

RLX

ajaya_kumar
Active Participant
0 Kudos

Hi,

Goto the getter method (get_CUST_NAME() ) of your attribute i.e. CUST_NAME and you will find following line ther

value = 'CUST_NAME not bound'.

Replace above line with

value = ' '.

Hope this hepls!!!

Regards

Ajay

Former Member
0 Kudos

Hi Ajay,

I should have explained this. The intent is to be able to display the field so I can input values and update the table; not just hide the error message. That can also be done my updating a parameter on my user ID.

Thanks

RLX