We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Reordering items in ejListBox is not reflected in model.dataSource

Thread ID:

Created:

Updated:

Platform:

Replies:

130883 Jun 8,2017 08:26 AM Jun 9,2017 08:02 AM JavaScript 1
loading
Tags: ejListBox
Alexandru Boboc
Asked On June 8, 2017 08:26 AM

Hi,

I'm trying to use ejListBox to reorder a list of elements, as in your example here: http://js.syncfusion.com/demos/web/#!/bootstrap/listbox/reordering

When using the moveUp() and moveDown() methods of ejGridBox, elements are moving correctly, but the changes are not reflected in the model.dataSource of the ejListBox. 


Checkout the developer console when clicking the buttons: the order in the model.dataSource remains unchanged.

Is there a different way to get the newly ordered list?

Alex

Arun Palaniyandi [Syncfusion]
Replied On June 9, 2017 08:02 AM

Hi Alexandru,   

 

Thanks for contacting Syncfusion support.   

 

When elements are moved up and down, the <li> elements are rearranged visually in the DOM and not in model. But if you want to order the dataSource model value, based on every reorder then you can achieve this in sample side itself.   

 

Please find the modified demo for your reference below:   

http://jsplayground.syncfusion.com/sasgeohg   

   

If the shared details and sample doesn’t meet your requirement, please give us more information to provide an alternative solution.       


Regards,
Arun P.  

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;