cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Limit rendered items in Extendedmlutireferenceeditor

Former Member
0 Likes
741

Hi Experts,

is there any way to limit the displayed items in createSelectedItemsListItemRenderer like rendering the first 5 elements and then enable paging elements like the functionality that the collectionbrowser has?

Cheers, Daniel

Accepted Solutions (1)

Accepted Solutions (1)

former_member682593
Participant
0 Likes

Hi,

For MultiReferenceEditor and ExtendedMultiReferenceEditor the paging is supported out-of-the-box, and you cna set the page with with editor parameter 'pageSize'. See documentation:

https://help.hybris.com/6.7.0/hcd/8bab997f86691014852cfbeabd21a5c8.html#loio8a33c6b0c8164f47841cd67d... ('Settings' section).

You can add the setting in the configuration like:

 <editorArea:attribute qualifier="myProperty">
     <editorArea:editor-parameter>
         <editorArea:name>pageSize</editorArea:name>
         <editorArea:value>10</editorArea:value>
     </editorArea:editor-parameter>
 </editorArea:attribute>

However I'm not sure what do you mean by createSelectedItemsListItemRenderer - but if this is a renederer of items inside the editor, than still the solution above is they ways to go 🙂

Thanks, Marcin

Former Member
0 Likes

Hey Marcin,

thanks for your answer.

the createSelectedItemsListItemRenderer is used for rendering the references between the 2 attributes (lets say between product and medias).

pageSize is not working for me since it only works for the bandbox popup when you are searching for an item as far as I know.

I also tried to set renderOnDemandSize and SelectedItemsMaxSize but tohse are not working either in hybris 6.4.

former_member682593
Participant
0 Likes

Hi, my mistake, indeed the multi reference editors doesn't support paging yet. You would need to create your own editor that extends the existing one, and implement the paging. The sources of cockpitng are provided in commerce-suite, so you should be able to do that, although it might not be easy, as those editors are very robust and generic.

Former Member
0 Likes

no worries, thanks for your help 🙂

I'll see what I'll do with it

Former Member
0 Likes

Hi Daniel,

I have the same problem. Please tell me if you found solution!

Answers (0)