Spring form标签 Select 根据后台传值 动态选中
来源:互联网 发布:seo关键词优化是什意思 编辑:程序博客网 时间:2024/05/20 13:18
<script type="text/javascript">
$(document).ready(function(){
var _orderType=$("#_orderTypes").val();
$("#orderTypes").val(_orderType);
});
</script>
<!-- JSP -->
<form:form modelAttribute="scRepairs" action="${ctx}/estate/repairs/Modify"
<input type="hidden" id="_orderTypes" value="${repairsType }"/>
<form:select id="orderTypes" path="orderType" >
<form:options items="${orderTypes}" itemValue="eleCode" itemLabel="eleName"/>
</form:select>
</form:form>
itemLabel="${screpairs.repairsType}" :对应下拉框的标签值(动态默认选中)
path="orderType":对应表单对象属性值(即scRepairs.orderType)
items="${orderTypes}" :下拉框选项的数据(List、Map、Set)
itemValue="eleCode":对应元素的键
itemLabel="eleName":对应元素的值
public String Modify(@ModelAttribute("scRepairs")ScRepairs scRepairs, HttpServletRequest request,
HttpServletResponse response){
}
1 0
- Spring form标签 Select 根据后台传值 动态选中
- select标签根据后台值选中问题
- select根据后台值选中
- asp.net 后台根据数据库中的值 利用js给select标签赋选中值
- asp.net 后台根据数据库中的值 利用js给select标签赋选中值
- select根据值动态改变选中项
- 根据值来动态选中select option
- Select标签 根据value值默认选中 Jquery
- Select标签 根据value值默认选中 Jquery
- select标签 selected 选中状态动态设置
- <select>标签默认选中值
- 前台根据后台值 操作字段 显示或select选中状态
- Jquery根据后台数居设置select。radio,checkbox选中
- Select标签后台获取动态数据
- 标签 select根据request参数自动选中某个数值
- 根据输入值 让select 选中
- jq select根据text,value值选中
- jQuery获取Select选中的Text和Value,根据Value值动态添加属性等
- 基于jquery实现的弹出层效果实现!
- 从毕业生到企业IT主管的历程
- uva 10161 Ant on a Chessboard(数学推规律)
- 启动 Eclipse 有“Failed to load the JNI shared library jvm.dll” 错误提示
- java.lang.NoSuchMethodError: antlr.collections.AST.getLine()I错误解决
- Spring form标签 Select 根据后台传值 动态选中
- maven本地jar
- javascript 阻止事件冒泡 与 浏览器的默认行为
- 误删除了数码相机内存卡上的照片,还能恢复吗?
- OpenCV学习笔记8 OpenCV图像处理模块ImgProc Module. Image Processing(一)
- android.content.res.Resources$NotFoundException
- 14.0~14.6 文件、文件夹的增删查等,NSCoding
- coco2d-x 纹理研究
- java中常用的工具类——String工具类