如何使用jQuery数据表和ASP MVC做批量更新的行 [英] How to do batch row updating using jQuery Datatables and ASP MVC

查看:415
本文介绍了如何使用jQuery数据表和ASP MVC做批量更新的行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 ASP.NET MVC 4 jQuery的数据表

我有需要在网格填充服务器的列表。这是比较容易的部分。我需要编辑的功能。当我选择一排,我需要能够编辑数据。我应该可以编辑任何行的数据。我不想更新发生在单元格编辑。当我与所有的更新完成,然后我点击一个按钮。该按钮将在网格并检查哪些行需要被更新的所有数据。然后,我做我的更新到数据存储。

I have a list of servers that I need to populate in the grid. This is the easy part. I need editable functionality. When I select a row I need to be able to edit the data. I should be able to edit the data of any row. I don't want updating to take place on cell edit. When I have done with all the updating then I click on a button. The button takes all the data in the grid and checks which rows needs to be updated. Then I do my updating to the data store.

这可能与jQuery的数据表和ASP MVC?我所看到的样品似乎做更新单元格被编辑之后。

Is this possible with jQuery Datatables and ASP MVC? The samples that I have seen seems to do the updating after a cell has been edited.

推荐答案

我最近进行的项目是有相似的用例。不过,我很好奇,为什么你的愿望批量数据更新。对于我的项目,我配对 jQuery的数据表,提供的 Jeditable 。作为指导,你可能会发现MVC与jEditable和数据表的jQuery插件是有用的。我个人很享受使用这个组合的异步数据更新的能力。希望这点你在正确的方向!

I recently worked on a project that had similar use cases. However, I am curious as to why you desire a bulk data update. For my project I paired jQuery DataTables with Jeditable. As a guide, you may find "MVC with jEditable and DataTables plugin for jQuery" to be useful. I personally loved the asynchronous data update ability using this combination. Hopefully this points you in the right direction!

这篇关于如何使用jQuery数据表和ASP MVC做批量更新的行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆