Ext js Grid
Ext.onReady(function () { var proxy = new Ext.data.HttpProxy({ url: '/Mamage/Dept/JsonResult?pagesize=1' }); //定义reader var reader = new Ext.data.JsonReader( { }, [ { name: 'id', mapping: 'id' }, { name: 'deptName' }, //如果name与mapping同名,可以省略mapping { name: 'add_time' }, { name: 'rntroduce' } ] ) //构建Store var store = new Ext.data.Store({ proxy: proxy, reader: reader }); //载入 store.load(); // create the grid var grid = new Ext.grid.GridPanel({ store: store, columns: [ { header: "编号", width: 60, dataIndex: 'id', sortable: true }, { header: "部门名称", width: 150, dataIndex: 'deptName', sortable: true }, { header: "添加时间", width: 150, dataIndex: 'add_time', sortable: true }, { header: "介绍", width: 150, dataIndex: 'rntroduce', sortable: true } ], renderTo: 'grid_list', width: 850, height: 400 }); });
Ext js Grid的更多相关文章
- 【翻译】将Ext JS Grid转换为Excel表格
原文:Converting an Ext 5 Grid to Excel Spreadsheet 稍微迟来的礼物--Ext JS Grid转为Excel代码,现在支持Ext JS 5! 功能包括: - ...
- [Ext JS 4] Grid 实战之分页功能
前言 分页功能的实现有两种途径: 一种是服务端分页方式, 也就是web客户端传递页码参数给服务端,服务端根据页面参数返回指定条数的数据.也就是要多少取多少.这种方式比较适合Grid 的数据量很大,需 ...
- [转]使用Sencha Ext JS 6打造通用应用程序
原文地址:http://www.uedsc.com/using-sencha-ext-js-6-to-build-universal-apps.html 在Sencha和整个Ext JS团队的支持下, ...
- [Ext JS 4]性能优化
一般的优化技巧 1. 检查你定义的时间监听器 正确的设置事件监听器对性能会有很大的影响. 举例来说, 在定义一个store的时候,设置一个load 的事件去触发从后台读取数据,如果设置single 的 ...
- 【翻译】使用Sencha Ext JS 6打造通用应用程序
原文:Using Sencha Ext JS 6 to Build Universal Apps {.aligncenter} 在Sencha和整个Ext JS团队的支持下,我很高兴能跟大家分享一下有 ...
- Ext JS 6学习文档-第4章-数据包
Ext JS 6学习文档-第4章-数据包 数据包 本章探索 Ext JS 中处理数据可用的工具以及服务器和客户端之间的通信.在本章结束时将写一个调用 RESTful 服务的例子.下面是本章的内容: 模 ...
- [Ext JS 4] 实战之Grid, Tree Gird 添加按钮列
引言 贴一个grid 的例子先: 有这样一个需求: 1. 给 Grid(or Tree Grid)添加一列, 这一列显示是Button. 点击之后可以对这一行进行一些操作 2. 这一列每一行对应的按钮 ...
- [Ext JS 4] 实战之Grid, Tree Gird编辑Cell
前言 本篇这里以稍微复杂一点的Tree Grid 来介绍. 在写编辑grid 之, 先来看一下 grid 的 selType 的配置. 先给一个简单的Tree grid 的例子: Ext.onRead ...
- Ext JS 6学习文档-第5章-表格组件(grid)
Ext JS 6学习文档-第5章-表格组件(grid) 使用 Grid 本章将探索 Ext JS 的高级组件 grid .还将使用它帮助读者建立一个功能齐全的公司目录.本章介绍下列几点主题: 基本的 ...
随机推荐
- [leetcode-598-Range Addition II]
Given an m * n matrix M initialized with all 0's and several update operations. Operations are repre ...
- 【LeetCode】110. Balanced Binary Tree
题目: Given a binary tree, determine if it is height-balanced. For this problem, a height-balanced bin ...
- .NetCore+Jexus代理+Redis模拟秒杀商品活动
开篇叙 本篇将和大家分享一下秒杀商品活动架构,采用的架构方案正如标题名称.NetCore+Jexus代理+Redis,由于精力有限所以这里只设计到商品添加,抢购,订单查询,处理队列抢购订单的功能:有不 ...
- [图形学] Chp9 三维几何变换--栈处理函数与矩阵管理函数的区别
矩阵管理函数:glLoadIdentity()是把当前活动矩阵设置为单位矩阵. 栈处理函数:glPushMatrix()是将当前活动的变换矩阵复制一份,压入栈顶:glPopMatrix()是破坏当前活 ...
- 原生js数组
forEach()遍历:在原来数组上进行操作 var arrF = [2,3,4]; var arrS = arrF.forEach(function (value,index,a) { //val ...
- 有关conv_std_logic_vector和conv_integer
原文地址:关于conv_std_logic_vector 和 conv_integer 这两个函数的使用问题作者:xiphosura std_logic_arithThis is the librar ...
- requireJS 源码(三) data-main 的加载实现
(一)入口 通过 data-main 去加载 JS 模块,是通过 req(cfg) 入口去进行处理的. 为了跟踪,你可以在此 加断点 进行调试跟踪. (二) req({ })执行时,functio ...
- QBC查询、离线条件查询(DetachedCriteric)和分页查询模版
一.QBC检索步骤 QBC检索步骤: 1.调用Session的createCriteria()方法创建一个Criteria对象. 2.设定查询条件.Expression类提供了一系列用于设定查询条件的 ...
- django 表单提交 post 、get
介绍 : django项目开发必须懂的知识点,下面使用的数据库是mysql , models.py 数据库表结构, # -*- coding: utf-8 -*-from __future__ im ...
- (转)Sublime Text2 快捷键汇总
场景:最近在编写项目中越发的感觉到一个得心应手的编辑器是多么的重要,而sublime,无疑是让我用着最舒服,最有感觉的编辑器了! 1 快捷键总结 一个好的编辑器,能大大提高编程的效率.如果能熟知软件的 ...