easyUI loyout tabs自适应宽度
index.html 页面
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/easyui.css">
<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/icon.css">
<script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery.min.js"></script>
<script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery.easyui.min.js"></script>
<script type="text/javascript"> $('#tabs').tabs({
pill:true
}); if(user==""){
window.location="${pageContext.request.contextPath}/index.jsp";
} </script> <title>首页</title>
</head>
<body class="easyui-layout" data-options="fit : true,border : false" > <div data-options="region:'north'" style="height:80px">
<jsp:include page="top.jsp"></jsp:include>
</div> <!-- <div data-options="region:'east',split:true" title="East" style="width:100px;"></div> -->
<div data-options="region:'west',split:true" title="权限菜单" style="width:220px;">
<div class="easyui-accordion" style="height:100%;"> </ul>
</div>
</c:if>
</c:forEach> </div>
</div>
<div data-options="region:'center',split:true" style="padding: 0px;overflow:hidden;">
<div id="tabs" class="easyui-tabs" data-options="fit : true" >
<div title="About" >
系统首页,无法关闭
</div> </div> </div>
</body>
</html> <script type="text/javascript" src="${pageContext.request.contextPath}/js/aup.js"></script>
tabs 内嵌页 包含datagrid ; datagrid 外包一定要套一个div 并且设置高度,不然无法显示.
<%@ page language="java" contentType="text/html; charset=utf-8"
pageEncoding="utf-8"%>
<%@ include file="/include/taglib.jsp"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>系统信息列表</title> <link rel="stylesheet" type="text/css" href="${ctx}/css/easyui.css">
<link rel="stylesheet" type="text/css" href="${ctx}/css/icon.css"> </head>
<body style="margin: 0px auto;" > <div style="height:780px;">
<table id="tt" title="系统列表"></table>
</div> </body>
</html>
datagrid js 代码
$(function() {
$('#tt').datagrid({
url: ctx + '/system/lisSystem.do',
height:'500px',
pagination: true,
/*是否显示下面的分页菜单*/
border: false,
fit : true,
fitColumns:true,//自动使列适应表格宽度以防止出现水平滚动。
rownumbers: true,
toolbar: toolbar,
selectOnCheck: true,
checkOnSelect: true,
loadMsg: '数据加载中,请稍候......',
columns: [[{
field: 'id',
title: '系统id',
checkbox: true,
width: 220
},
{
field: 'sysName',
title: '系统名称',
width: 150
},
{
field: 'sysCode',
title: '系统编码',
width: 150,
align: 'right'
},
{
field: 'status',
title: '系统状态',
width: 80,
align: 'right',
formatter: function(value, row, index) {
if (row.status == 0) {
return "启用";
} else if (row.status == 1) {
return "禁用";
} else {
return "删除";
}
}
},
{
field: 'operate',
title: '操作',
width: 150,
align: 'center',
formatter: formatOper
}]]
});
});
easyUI loyout tabs自适应宽度的更多相关文章
- 第二百节,jQuery EasyUI,Tabs(选项卡)组件
jQuery EasyUI,Tabs(选项卡)组件 学习要点: 1.加载方式 2.属性列表 3.事件列表 4.方法列表 5.选项卡面板 本节课重点了解 EasyUI 中 Tabs(选项卡)组件的使用方 ...
- 从三栏自适应宽度布局到css布局的讨论
如何实现一个三栏自适应布局,左右各100px,中间随着浏览器宽度自适应? 第一个想到的是使用table布局,设置table的宽度为100%,三个td,第1个和第3个固定宽度为100px,那么中间那个就 ...
- UEditor百度富文本编辑器--让编辑器自适应宽度的解决方案
UEditor百度富文本编辑器的initialFrameWidth属性,默认值是1000. 不能够自适应屏幕宽度.如图1: 刚开始的时候,我是直接设置initialFrameWidth=null的.效 ...
- JS实现自适应宽度的Tag切换
效果体验:http://hovertree.com/texiao/js/3.htm 该效果使用纯JavaScript代码,实现TAB页切换效果,TAB标签根据内容自适应宽度,点击TAB标签切换内容页. ...
- RelativeLayout中的格局,自适应宽度布局
RelativeLayout中的布局,自适应宽度布局 该图片中为android布局:总布局为 RelativeLayoutAtLeft 为居左 <TextView android:backgro ...
- Qt的tablewidget行列头自适应宽度
Qt构造一个TableWidget后,窗口最大化后,列头默认不能自适应宽度,研究了一下,Qt提供了两种方式来处理这个问题,如下: 1. 使用horizontalHeader()->setRe ...
- [Winform]DataGridView列自适应宽度
引言 在做winform项目中,数据控件DataGridView的使用多多少少是会用到的,如果不设置它的属性,默认情况下是不会自适应宽度的,你想查看某项的数据,就不得不将标题栏拖来拖去,挺烦的. 方法 ...
- ASP.NET实例——漂亮的自适应宽度的导航条(仿Discuz!)
PHP比较成熟的开放的源代码比较多,比方说PrestaShop,比方说Discuz!...... 虽然语言不同,但基本原理是一样的,有时间的话读一读,对学习ASP.NET应该是非常有好处的(唉,什么时 ...
- 漂亮的自适应宽度的多色彩CSS图片按钮
一.素材 二.效果 三.CSS *{padding:0;margin:0} /*----------------------------------- 自适应宽度图片按钮 ...
随机推荐
- tomcat 部署spring工程乱码解决方案
tomcat的server.xml文件,Connector标签增加useBodyEncodingForURI="true"属性 web.xml如下配置 <filter> ...
- javascript选取文档元素
用指定的id属性 用指定的name属性 用指定的标签名字 用指定的CSS类 匹配指定的CSS选择器 通过ID选取元素 var section1 = document.getElementById(&q ...
- java-类
浏览以下内容前,请点击并阅读 声明 java是面向对象的语言,而对象的创建,则需要借助类,类可以说是一个创建对象的模具(个人理解). 类的定义 以下构成定义类的最简单(不能再简单)语句: class ...
- SQL Prompt激活
SQL脚本越写越多,总是觉得编写效率太过于低下,这和打字速度无关.在我个人编写SQL脚本时,至少会把SQL的格式排列成易于阅读的,因为其他人会阅读到你的SQL,无论是在程序中或是脚本文件中,良好的排版 ...
- ural 1075. Thread in a Space
1075. Thread in a Space Time limit: 1.0 secondMemory limit: 64 MB There are three points in a 3-dime ...
- ccc 使用let
//如果不是恩雅,也不在移动过程中,那么移动 if (!self.hasMoved && !isHold) { var touchLoc = touch.getLocation(); ...
- 【转】推荐UML插件AmaterasUML
基于Green UML在使用过程中的问题(对于大工程,点击生成类图后不响应),自己只能再次寻找其他的插件.在无意中,发现AmaterasUML. 官方网站:http://amateras.source ...
- HDU 3074 (线段树+模P乘法)
题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=3074 题目大意:单点更新.维护序列乘法.mod 1000000007. 解题思路: 10000000 ...
- 隐式调用 Intent 大全, 很全
http://ming-fanglin.iteye.com/blog/1061312 //调用浏览器 Uri uri = Uri.parse(""); Intent it = n ...
- NOI模拟 热身赛T1
设p(m)的值为m的正因数个数(包括1和m本身)给定n,求满足p(x)=n的最小x. 简直弱到不行了... VW做法: 其实蛮简单的,然而想的时候忽略了指数是不增的 然后你以为做完了吗? 愚蠢的贡献了 ...