Okay
  Public Ticket #2315157
Saving draggable portlets order
Closed

Comments

  • jmansa started the conversation

    Hi support,

    A long time ago I purchased this wonderfull html template, but havent used it for a while. I am using it for a backend of a list of documents. 

    Now. I am creating, using php and mysql categories and links. Categories is viewed with draggable-portlets and in each category I am listing the documents using nestables. The documents and netsables is working perfect with the example you have provided in the template, updating with php and mysql, but... You did not provide an ordering example to the darggable portlets. How do i listen to those when released?

    Hope this question makes sense and thanks in advance for helping ;-)

    Regards,

    Jesper Mansa

  • [deleted] replied

    Hi Jesper Mansa,

    Thank you very much for you kind words, I am sorry to delay your answer but I was busy developing.

    So for your question I can give you this example how to listen for updates when position/sort of items is changed:

    var $draggable_portlets = $(".draggable-portlets");
    $draggable_portlets.on( 'sortupdate', function( ev, ui ) {    
        console.log( 'the list has been updated' );
    } );
    
    See how it works:

    https://d.pr/v/JHh7MX

    I hope this works for you.