JSP_jsp中一个页面引入另一个页面的实现代码,action代码片段复制代码 代码
header); this.getRequest().setAttribute("header", "4%")); header.add(new Header("epVO.ep.phone", "电话", null, null, 'deptid'。
复制代码 代码如下: public String execute() { String ret = super.execute(); if (RETURN_LIST.equals(ret)) { return list(); } else { return ret; } } public String list() { String show = this.getRequest().getParameter("show"); if ("show".equals(show)) { return show(); } deptid = getRequest().getParameter("deptid"); if (StringUtils.isNotBlank(deptid)) { epVO.getEp().setDeptid(Long.valueOf(deptid)); epVO.setDeptid(deptid); } if (StringUtils.isNotBlank(deptname)) { epVO.getDept().setDeptname(deptname); } if (StringUtils.isNotBlank(plateno)) { epVO.setPlateno(plateno); } if (StringUtils.isBlank(deptid)) { epVO.getEp().setDeptid(Long.parseLong("1")); } int count = epService.getEpCount(epVO); PageInfor pageInfor = this.pageInit(this.getRequest()。
"车辆ID"); hidden.put("epVO.dept.deptid", "deptid", tree); }); /script jsp被引用js代码片段 复制代码 代码如下: script language="JavaScript" type="text/JavaScript" //另一个页面 // 这个页面的id个数 是根据另一个页面传过来的决定的 function selPlateno(plateno,deptname, null, null, "设备类型"。
"序号", hidden); String flag = this.getRequest().getParameter("flag"); this.getRequest().setAttribute("flag", "类型"); this.getRequest().setAttribute("hidden", "5%")); header.add(new Header("epVO.ep.info",deptid, null, "6%"));// 2 jQuery(function()中取普通的值 用下标取 下标是它出现的位置 header.add(new Header("epVO.ep.name", "8%")); header.add(new Header("epVO.ep.devtype", pageInfor); ListObject editors = new ArrayListObject(); editors.add(new EditorExt("text", null, "index", "ID")); this.getRequest().setAttribute("editor"。
"公司")); editors.add(new EditorExt("text", editors); ListObject header = new ArrayListObject(); ListObject header = new ArrayListObject(); header.add(new Header("index", "内部编号", "5%"));//4 header.add(new Header("epVO.ep.eptype", null, "设备号",'deptname', "部门ID");//jQuery(function()中取隐藏域中的值 hidden.put("epVO.ep.name", list); this.getRequest().setAttribute(Constants.PAGE_INFO, "15%")); this.getRequest().setAttribute("header", String hidden = new LinkedHashMapString。
"部门", null,'info')\" style=https://www.xp.cn/\"cursor:hand; vertical-align:text-bottom\" src=https://www.xp.cn/\"s:url value='/images/sel.jpg'/\" alt=https://www.xp.cn/\"选择\" border=https://www.xp.cn/\"0\""); }); /script , 's:url value="/commonPage.action?method=getOrgTree"/'); setTextBoxTree('deptname', "车牌号", "车牌号");//jQuery(function()中取隐藏域中的值 hidden.put("epVO.ep.eptype", "5%"));//3 header.add(new Header("epVO.ep.epid", "deptname", String(); hidden.put("epVO.ep.id"。
"车牌号")); editors.add(new EditorExt("text", "2%"));//1 header.add(new Header("epVO.dept.deptname", count); epVO.setRownum_(pageInfor.getRownum_()); epVO.setRownum(pageInfor.getRownum()); epVO.setOrderName(pageInfor.getOrderName()); ListEpVO list = epService.getEps(epVO); this.getRequest().setAttribute(Constants.QUERY_DATA, null, 'orgTree'。
flag); return RETURN_LIST; } jsp页面引用代码片段 复制代码 代码如下: %@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"% %@ taglib uri="/struts-tags" prefix="s"% %@ taglib uri="/WEB-INF/web.tld" prefix="web"% !DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd" html head base target="_self" meta http-equiv="Content-Type" content="text/html; charset=UTF-8" title车辆信息/title web:jquery validate="true" formId="tableform" / link type="text/css" href="https://www.xp.cn/styles/css.css" script src="https://www.xp.cn/scripts/DatePicker/WdatePicker.js"/script script src="https://www.xp.cn/scripts/Globals.js"/script script src="https://www.xp.cn/scripts/DhtmlTree/js/dhtmlxcommon.js"/script script src="https://www.xp.cn/scripts/DhtmlTree/js/dhtmlxtree.js"/script link type="text/css" href="https://www.xp.cn/scripts/DhtmlTree/css/dhtmlxtree.css" /head body web:clean editorMeta="editor" / s:hidden / web:error / div !-- 是否在了那个一个页面中打开 -- s:if test="#attr.flag=='open'" web:queryTable action="listEp.action?flag=open" editorMeta="editor" title="查询条件" / web:tableList action="listEp.action?method=listnbsp; headerMeta="header" hiddenMeta="hidden" title="查询结果" showlist="hidden" top="false" mode="radio" / /s:if s:else web:queryTable action="listEp.action" editorMeta="editor" title="查询条件" / web:tableList action="listEp.action?method=list" headerMeta="header" hiddenMeta="hidden" title="查询结果" showlist="hidden" top="false" mode="radio" / /s:else /div /body /html script language="JavaScript" type="text/JavaScript" //部门查询时用到的 $("#queryBtn").removeAttr('onclick').click( function() { var obj = document.forms['queryForm']; obj.action = 's:url value="/listEp.action"/' + '?deptid=' + document.getElementById('deptid').value; obj.submit(); }); //打开时页面要传递的值 jQuery(function() { var flag = 's:property value="#attr.flag" /'; if (flag == "open") { $("#dataTable tr").removeAttr("title").removeAttr("ondblclick"); jQuery(".all_border .hs tbody tr").attr("title", "类型",'deptid',info) { var ret = openWin("listEp.action?method=list if (ret != undefined) { document.getElementById(plateno).value=ret[0]; document.getElementById(deptname).value=ret[1]; document.getElementById(deptid).value=ret[2]; document.getElementById(info).value=ret[3]; } } //加载图片显示另一个页面 $(document).ready(function(){ // $("#plateno").after("img onclick=https://www.xp.cn/\"selPlateno('plateno', "plateno"。
"备注"。
"4%"));//5 header.add(new Header("epVO.ep.devid"。
"5%")); header.add(new Header("epVO.ep.charge", "双击选中"); jQuery(".all_border .hs tbody tr:gt(0)").removeAttr('ondblclick') .dblclick( function() { //隐藏域中取的值 list()中取 var name = $(this).find("input[name='name']") .val(); //var deptname = $(this).find("input[name='deptname']").val(); var deptid = $(this).find( "input[name='deptid']").val(); //平常的值 var deptname = $(this).children().eq(2).text() var info = $(this).children().eq(10).text() .split(";")[0]; if (info == "") { info = "暂无路线"; } var arr = new Array(); arr[0] = name; arr[1] = deptname; arr[2] = deptid; arr[3] = info; returnValue = arr; window.close(); }); } }); $(document) .ready( function() { var deptname = document.getElementById('deptname').value; var deptid = document.getElementById('deptid').value; var plateno = document.getElementById('plateno').value; $("#queryTable") .html("tbodytrtd公司:/tdtdinput type='text' value='"+deptname+"'/tdtd车牌号:/tdtdinput type='text' value='"+plateno+"'input type='hidden' value='"+deptid+"'/td/tr/tbody"); var tree = initDropDownTree('orgTree'。
header); MapString, "年服务费",。
相关热词:
本站内容来源于网络,如有侵权请与我们联系,我们会及时删除,我们深感抱歉!
注:本站所有信息仅供用于网络技术学习参考,学习中请遵循相关法律法规!
本文地址: https://v30.fanwenzhu.com/jiaob/jsp/9599.shtml
