资源描述:
《flexigrid单表增删改案例前台显示》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、这是关于客户表的增删改前台显示页面后台使用SSH框架即可此处暂不提供后台代码(可以试试自己编写,可提高自己的能力和对SSH框架的熟知度)<%@pagelanguage="java"import="java.util.*"pageEncoding="UTF-8"%><%@tagliburi="http://java.sun.com/jsp/jstl/core"prefix="c"%><%@tagliburi="/struts-tags"prefix="s"%><%Stringpath=request.getContextPath();StringbasePath=requ
2、est.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";%>">CRM——客
3、户关系管理系统js/jquery/jquery-1.8.2.js"type="text/javascript">js/flexigrid/css/flexigrid.css"type="text/css"rel="stylesheet"/>
4、js/flexigrid/js/flexigrid.js"type="text/javascript">$(document).ready(function(){vargrid=$("#flexTable").flexigrid({width:'100%',height:340,url:'system/customerAction_queryCustomer.do',dataType:'json',checkbox:true,colModel:
5、[{display:'编号',name:'id',width:100,sortable:true,align:'center',hide:false,toggle:false},{display:'客户名称',name:'customerName',width:170,sortable:true,align:'center'},{display:'客户年龄',name:'customerAge',width:170,sortable:true,align:'center'},{display:'客户性别',name:'customerSex',width:170,sor
6、table:true,align:'center'}],buttons:[{name:'add',displayname:'新增',bclass:'add',onpress:function(){window.location.href="<%=basePath%>/system/customerAction_gotoAddPage.do";}},{separator:true},{name:'modify',displayname:'修改',bclass:'modify',onpress:function(){if($(".trSelected",grid).leng
7、th==1){varid=$('.trSelectedtd:nth-child(2)',grid).text();window.location.href="<%=basePath%>/system/customerAction_update.do?ids="+id;}elseif($(".trSelected",grid).length>1){alert("请选择一个修改,不能同时修改多个记录!");}elseif($(".trSelected",grid).length==0){alert("请选择一个您要修改的记录!")}}},{s