如何在spring mvc中创建动态表,每行包含一个下拉列表 [英] How can i create a dynamic table in spring mvc each row includes a dropdown list

查看:114
本文介绍了如何在spring mvc中创建动态表,每行包含一个下拉列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



我有一个spring mvc应用程序,我想做两个步骤。

首先阅读数据库中的日期并在jsp文件的表中显示,对于表中的每一行,jsp文件中都有一个下拉列表。

下一步是在表中提交数据,但问题是,它不是从选定的下拉列表中获取数据,而是包含控制器端的所有其他下拉数据。其代码是:



@RequestMapping (method = RequestMethod.POST,value =/ do,params =start)

public String startScheduler(@ModelAttribute(command)String command){

返回eenSimulator;

}



我尝试过:



i试图使用模型属性注释并在spring中选择标签,但它发送的所有数据不仅仅是所选的下拉列表

Hi all,

I have a spring mvc application,there are two steps that I want to do.
First to read date from database and show it in a table in jsp file,for each row in the table,there is a drop down list in the jsp file.
Next step is to submit the data in the table,but the problem is that instead of getting the data from the selected dropdown list,it includes all other dropdown data in the controller side.here is the code:

@RequestMapping(method = RequestMethod.POST, value="/do", params="start")
public String startScheduler(@ModelAttribute("command") String command) {
return "eenSimulator";
}

What I have tried:

i have tried to use model attribute annotation and select tag in spring but it sends all the data not just the selected dropdown

推荐答案

Hope这个链接将给你所有答案。


W2Ui网格



我在很多应用程序中都使用过它。这真是一个很酷的api。
Hope this link will give your all answer.

W2Ui Grid

I have used it in many application. It is really a cool api.


这篇关于如何在spring mvc中创建动态表,每行包含一个下拉列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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