Editor for asp.net mvc without database

Editor for asp.net mvc without database

mDigitalmDigital Posts: 1Questions: 1Answers: 0

Hi,

We are already using DataTables in our asp.net mvc 5 web application and are considering buying Editor to support local, inline editing. We appreciate the existence of the .net libraries for server side code but are a bit confused about how the whole thing work and if it is going to fit our needs.

More specifically, there is no database in our project. The data are provided by web services, instead. Right now, we are using a simple ajax Datatables call to fetch and show the data. Everything (the columns, the rendering etc) is defined client-side in the DataTables initialization.

Is the Editor .net library any good to us? or is it specifically for database connection only?

Answers

  • SteveHippySteveHippy Posts: 2Questions: 0Answers: 0

    I would like to know this too please
    I have a project where data is got with sql stored procedures and would like to use editor with existing infrastructure

  • allanallan Posts: 61,627Questions: 1Answers: 10,090 Site admin

    Sorry I missed the original question. If you have an existing server-side infrastructure that you don't want to change and it provides the CRUD code for the server, then yes it is still possible to use Editor, but you'll likely need to convert from the data format Editor sends to whatever the server is expecting. The preSubmit event can be used for that. Likewise on return you might need to use postSubmit to convert into the format that Editor expects in return.

    Allan

  • SteveHippySteveHippy Posts: 2Questions: 0Answers: 0

    when you say " convert into the format that Editor expects in return" what format is that and are there any examples.
    I have the inline editor calling a post in controller but cant seem to get the response to editor right. Any pointers?

  • allanallan Posts: 61,627Questions: 1Answers: 10,090 Site admin

    The link I gave in my post ( https://editor.datatables.net/manual/server ) explains the format for the data that is sent to the server, and the format of the data returned.

    You can also see it live in the examples if you edit a row and click the "Ajax data" tab.

    Allan

This discussion has been closed.