Want To Send All Updated/Selected Rows Using DataProcessor.s

I have a static Grid that is used to catch and modify Drag and Drop data at the User level.

Everything works perfectly until the User drags (inside the same Grid) to correct a row that was already insert/updated. Then nothing seems to get the DataProcessor.serverProcessor to send the now updated and “selected” row up to Php. The $_POST[‘id’] only contains rows that have never been touched before.

I use the basic setup…


sendDataRows = oGrid1DataProcessor.updatedRows; // Needed To Count The Rows


If I poll oGrid1DataProcessor.updatedRows ALL the correct rows are displayed.

I have tried

oGrid1DataProcessor.setUpdated(2,true); and


Interestingly I have also tried

oGrid1.submitOnlySelected(true); and oGrid1.submitOnlyRowID(true);

but these error out saying “Object doesn’t support this property or method”.

How can I get ALL the id’s that are marked “Selected” to go up to Php no matter what?

oGrid1.submitOnlySelected(true); and oGrid1.submitOnlyRowID(true);
This is part of form integration extension, which requires additional js file to be included ( dhtmlxgrid_form.js ) and not related to dataprocessor.

Based on used settings ( second parameter of setUpdateMode ), dataprocessor will count d-n-d operation as combination of insert and delete or as single update operation. In both cases moved row will have changed status and will be sent to the server with next update.
Beware that grid has inner response checking system, so if you have row updated - data sent to the server, now until client side will not receive a response with the same ID, not any new command for row in question will be sent. Client side will wait response with the same “sid” value and only after that allow data sending for the same row.

Here’s an example. Perhaps you can point out what’s missing or in error.


FMFF2.zip (4.38 KB)

The code which you currently using in Check_POST_ids.php is just a test plug, right?
To work correctly, dataprocessor need to receive correct response from server side, for example in case of 3 updated rows, valid response will be similar to next

<?php //Check_POST_ids.php
echo "<?xml version='1.0' ?>";
echo “”;
echo “”;
echo “”;
echo “”;
echo “”;

Of course, in real life code will execute update instruction for each incoming rows and print related action tag in response, such direct outputing is just for test purpose.
After applying correct response your test case starts work correctly - after pressing save first time , all 3 rows marked as saved ( bold text style removed ) , and if any of such rows will be moved again - it will be included in data sending.

Yes the Check_POST_ids.php is just a test plug. And I do make an XML response blah in my code to alert the User to real activity.

I re-added the “”; and it works.

But isn’t there any way to work around the seemingly required xml echo “”;. Shouldn’t we be able to affect the Gird “sendData” behavior in real time without sending XML?


In case of dhtmlxGrid ( it a bit more complex for tree and treegrid ) , you can use next code on client side to inform row that its operation finished ( so it will not require response from the server )

dp - dataprocessor instance
sid,tid,action - same values as in XML

command will trigger the same logic as XML response.

If you need just remove block from sending rows with “not confirmed operation yet”, you can use
delete dp._in_progress[sid];

Very Cool! Thanks so much! I really appreciate that. – Larry