- 注册时间
- 2014-4-18
- 最后登录
- 2014-7-7
- 阅读权限
- 10
- 积分
- 54
- 精华
- 0
- 帖子
- 12
|
lost 发表于 2014-4-18 17:22
http://www.miniui.com/demo/datagrid/fitsize.html
你测试下官网的示例数据多时滚动滚动条,表头是固定的 ...
网站示例是好的,我的就不管用了
<%@ Page Title="" Language="C#" MasterPageFile="~/Masters/MiniUI/Base.Master" AutoEventWireup="true"
CodeBehind="UsrSelView.aspx.cs" Inherits="Aim.Portal.Web.CommonPages.MiniUI.UsrSelView" %>
<%@ OutputCache Duration="1" VaryByParam="None" %>
<asp:Content ID="HeadContent" ContentPlaceHolderID="HeadHolder" runat="server">
<script type="text/javascript">
var viewport;
var store;
var grid, pgBar;
var qryParams = {};
var pgBar;
function onPgLoad() {
var params = $.getAllQueryStrings() || {};
$.each(params, function () {
qryParams[this.name] = this.value;
});
setPgUI();
}
function setPgUI() {
var columns = [
{ type: "indexcolumn", width: 30, allowResize: false },
{ type: "checkcolumn" },
{ header: "姓名", field: "Name", width: "100%", sortable: true },
{ header: "工号", field: "WorkNo", width: 120, sortable: true },
{ header: "登录名", field: "LoginName", width: 120, sortable: true }
];
grid = new mini.ux.AimDataGrid({
idProperty: "UserID",
dsname: "UsrList",
columns: columns,
data: AimState["UsrList"],
aimpager: 'aimpager',
schpanel: "schPanel",
renderTo: "grid1"
});
}
function doSearch(domid) {
grid.reload({ schtype: "field", schdom: document.getElementById(domid) });
}
// 获取被选中的用户
function GetSelections(type) {
//var recs = grid.getSelectionModel().getSelections();
//if (recs == null || recs.length == 0) {
// return null;
//}
//switch (type) {
// default:
// return recs;
//}
}
</script>
</asp:Content>
<asp:Content ID="BodyContent" ContentPlaceHolderID="BodyHolder" runat="server">
<div id="schPanel" style="padding: 5px 10px; border-left: 1px solid #909aa6; border-right: 1px solid #909aa6;">
<span>姓名:</span><input type="text" id="Name" qryopts="{ mode: 'Like', field: 'Name' }" aimgrp="defgrp" />
<span>工号:</span><input type="text" id="WorkNo" qryopts="{ mode: 'Like', field: 'WorkNo' }" aimgrp="defgrp" />
<input type="button" value="查找" onclick="doSearch('Code')" />
</div>
<div id="fit1" class="mini-fit">
<div id="grid1">
</div>
</div>
<div id="aimpager" style="border-left: 1px solid #909aa6; border-right: 1px solid #909aa6; border-bottom: 1px solid #909aa6; background-color: rgb(231, 234, 238);">
</div>
</asp:Content>
|
|