Server-Side Processing Inputs & Outputs

Server-Side Processing Inputs & Outputs

kaseykrehbielkaseykrehbiel Posts: 18Questions: 2Answers: 0
edited November 2012 in General
I'm planning on using a WCF service to talk back and forth to DataTables, and I was wondering if there is a list anywhere of all variables that DataTables SENDS to the server, as well as a list of all variables that DataTables expects to RECEIVE from the server.

There are a lot of examples to draw from, and I could just examine the HTTP traffic to find this information, but I was hoping that this input/output type list would be located somewhere so it would be easier to reference (and so that I'd be less likely to miss something important.) Any help would be appreciated. Thanks a lot!

Replies

  • allanallan Posts: 63,523Questions: 1Answers: 10,473 Site admin
    Fully documented here: http://datatables.net/usage/server-side

    Allan
  • kaseykrehbielkaseykrehbiel Posts: 18Questions: 2Answers: 0
    I do believe this is exactly what I'm looking for, sir, thank you very much :-)

    And thanks again for this awesome product!
  • kaseykrehbielkaseykrehbiel Posts: 18Questions: 2Answers: 0
    By the way, did you notice that the server-side processing (as of 1.9.4) still uses mDataProp, instead of, as noted here: http://datatables.net/usage/columns#mDataProp, mData? If you go to that link, it just links you to the top of the page. It wasn't until I dug into it just a bit to find that mData has replace mDataProp.
  • kaseykrehbielkaseykrehbiel Posts: 18Questions: 2Answers: 0
    I also noticed that the sColumns variable is being sent over (and it's not documented.) What is sColumns for, and what is an example of the kind of data it would have in it if it were being used?
  • allanallan Posts: 63,523Questions: 1Answers: 10,473 Site admin
    Actually - mDataProp is what is submitted to the server. I could make the client-side change backwards compatible, but not the client/server communications - so mDataProp is still what is sent to the server. The documentation is accurate there.

    > sColumns

    Its deprecated and shouldn't be used (hence why not documented, to discourage use). Use mDataProp instead :-)

    Allan
  • kaseykrehbielkaseykrehbiel Posts: 18Questions: 2Answers: 0
    Do you think you could put something on this page:
    http://datatables.net/examples/server_side/column_ordering.html

    to indicate that it is deprecated? I had found that and submitted its usage to my colleague for writing the WCF service before I saw your response. I do plan on using this server-side code along-side the colReorder plugin, so I'm hoping mDataProp accounts for that. If not, please let me know.

    Thanks again for this plugin, and for your support!
  • allanallan Posts: 63,523Questions: 1Answers: 10,473 Site admin
    I thought I'd removed that example actually - not quick as much as I had thought! Thanks for pointing this out. Its not just deprecated - the code for the recording has already been removed in the 1.10 development :-).

    mData / mDataProp (use it with objects) is a much better solution to column order independence from the data source.

    Allan
This discussion has been closed.