easyui

目录结构

话不多说直接上代码

<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<%@ include file="common/head.jsp" %>
	<title>Insert title here</title>
	<script>
	$(function() {
		$("#funcTree").tree({
			url: ctx+"/moduleServlet",
			onDblClick:function(node) {
				$("#funTab").tabs("add", {
					title:node.text,    
				    content:'Tab Body',    
				    closable:true,    
				    tools:[{
				        iconCls:'icon-mini-refresh',    
				        handler:function(){    
				            alert('refresh');    
				        }    
				    }]
				})
			}
		});
		
	});
	</script>
</head>
<body class="easyui-layout">
		<div data-options="region:'north'" style="height:50px"></div>
		<div data-options="region:'south',split:true" style="height:50px;"></div>
		
		<div data-options="region:'west',split:true" title="West" style="width:230px;">
			<ul id="funcTree" class="easyui-tree"></ul>
		</div>
		
		<div data-options="region:'center',title:'Main Title',iconCls:'icon-ok'" style="border:0px;">
			<div id="funTab" class="easyui-tabs" style="width:100%;height:100%">   
			    <div title="Tab1" style="padding:10px;display:none;">   
			        <table class="easyui-datagrid"
							data-options="url:'${ctx}/data/datagrid_data1.json',method:'get',border:true,singleSelect:true,fit:true,fitColumns:true">
						<thead>
							<tr>
								<th data-options="field:'itemid'" width="80">Item ID</th>
								<th data-options="field:'productid'" width="100">Product ID</th>
								<th data-options="field:'listprice',align:'right'" width="80">List Price</th>
								<th data-options="field:'unitcost',align:'right'" width="80">Unit Cost</th>
								<th data-options="field:'attr1'" width="150">Attribute</th>
								<th data-options="field:'status',align:'center'" width="40">Status</th>
							</tr>
						</thead>
					</table>  
			    </div> 
			</div>
		</div>
	
</body>
</html>

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值