jorgenio / jquery-datatables-row-reordering

Automatically exported from code.google.com/p/jquery-datatables-row-reordering
0 stars 0 forks source link

Error rowReordering with JQuery ?? #24

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
When I use drag&drop to reorder datatable I have this error from jquery:

Error: Syntax error, unrecognized expression: #

...){var 
t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"=... 

I'm using rowReordering 1.2.1  and jquery 1.9.1 from googleapis.

This is my call:

$('#datatableproyectos').dataTable({
            "bProcessing": true,
            "sAjaxSource": '/admin/load/loadinfo.php?accion=listarproyectos&tipo=' + tipoproyectos,
            "aoColumns": [
                null,
                null,
                null,
                { "bSortable": false },
                { "bSortable": false }
            ],
            "fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {
                $('td:eq(2)', nRow).addClass('hidden-phone');
                $('td:eq(3)', nRow).addClass('hidden-phone');

                // Apply iCheck to checkbox
                $('td input[type="checkbox"]', nRow).iCheck({
                    checkboxClass: 'icheckbox_minimal-grey',
                    radioClass: 'iradio_minimal-grey',
                    increaseArea: '20%' // optional
                });
            }
        }).rowReordering({ 
                sURL:"/admin/proyecto/ajax_acciones.php", sRequestType: "GET", fnAlert: function(message) {

                alert("order"); 

                } 
            });

It's a problem with jquery or my call is wrong?

Thanks!!!!

Original issue reported on code.google.com by victor...@gmail.com on 12 Nov 2013 at 3:22

GoogleCodeExporter commented 9 years ago
Even I am facing the same problem. I am totally stuck.. Any one help us 
please....

Original comment by yunus.as...@gmail.com on 30 Nov 2013 at 8:05

GoogleCodeExporter commented 9 years ago
I fixed the issue :D .... We need to prove ID to row.. On the basis of the ID 
the re ordering is done.. For example..
In the html section
<tbody>
   <tr "We need to provide the id here">
  ........................... Your piece of content ................
   </tr>
</tbody>

Original comment by yunus.as...@gmail.com on 30 Nov 2013 at 8:28

GoogleCodeExporter commented 9 years ago
I set data with an object, so there is no <tr> tag for me to put an ID on.  How 
do I work around this?  This is a solid bug for sure.  Anyone working on this 
project still?

Original comment by ro...@kiosk.tm on 17 Oct 2014 at 12:24

GoogleCodeExporter commented 9 years ago
read this thread you can solve your problem 
http://www.datatables.net/forums/discussion/19011/drag-and-drop-row-reordering-i
ssue

Original comment by hamed.n...@gmail.com on 30 Nov 2014 at 1:19

GoogleCodeExporter commented 9 years ago
everything of this problem is related to fnRowCallback in datatable option

Original comment by hamed.n...@gmail.com on 30 Nov 2014 at 1:20