引入js文件后
<body class="easyui-layout">
<div data-options="region:'north',border:true" style="height:80px;background:#B3DFDA;">
<div>
<h1>  AiSell智能销售系统</h1>
</div>
</div>
<div id="menutree" data-options="region:'west',title:'管理菜单'" style="width:150px;padding:10px;"></div>
<div id = "menutabs" class="easyui-tabs" data-options="region:'center'">
<div title="首页" style="padding:20px;display:none;">
<iframe scrolling="auto" frameborder="0" style="width: 100%;height: 100%" src="../../xuanzhuan.html"/>
</div>
</div>
</body>
js配置
$(function(){
$('#menutree').tree({
method:'get',
url:'/menu/list',
onClick:function(node){
//添加选项卡
var text = node.name;
var url = node.url;
//判断选项卡是否有链接并且是否存在,有直接选中,没有就打开页签
if(url&&!$('#menutabs').tabs('exists',text)){
$('#menutabs').tabs('add',{
title:node.name,
content:'<iframe scrolling="auto" frameborder="0" style="width: 100%;height: 100%" src="'+url+'"></iframe>',
closable:true
});
}else{
$('#menutabs').tabs('select',text);
}
}
});
});