ExtJs gridPanel Column 时间格式化
var panel = new Ext.container.Viewport({
items: {
xtype: 'gridpanel',
id: 'gridPanel',
store: store,
height: document.documentElement.clientHeight,
columns: [
{ header: "Id", hidden: true, flex: 1, sortable: false, dataIndex: 'Id' },
{ header: "标题", width: 250, sortable: false, dataIndex: 'Title' },
{ header: "内容", width: 420, sortable: false, dataIndex: 'Contents' },
{ header: "点击数", width: 80, align: 'center', sortable: false, dataIndex: 'ClickCount' },
{ header: "发表时间", width: 150, align: 'center', sortable: false, dataIndex: 'CreateTime',
renderer: function (value) {
return eval("new " + value.split('/')[1]).Format("yyyy-MM-dd HH:mm:ss");
}
}
],
loadMask: true,
disableSelection: true,
viewConfig: {
stripeRows: true
},
tbar: ['->',
{ id: 'btn_add', text: '添加', icon: '../../../Images/extjs/add.png' },
{ id: 'btn_edit', text: '编辑', icon: '../../../Images/extjs/pencil.png' },
{ id: 'btn_delete', text: '删除', icon: '../../../Images/extjs/delete.png' }
],
dockedItems: [{
xtype: 'pagingtoolbar',
store: store,
dock: 'bottom',
displayMsg: '显示 {0} - {1} ,共 {2} 记录',
displayInfo: true
}]
}
});
ExtJs gridPanel Column 时间格式化的更多相关文章
- Extjs GridPanel用法详解
Extjs GridPanel 提供了非常强大数据表格功能,在GridPanel可以展示数据列表,可以对数据列表进行选择.编辑等.在之前的Extjs MVC开发模式详解中,我们已经使用到了GridPa ...
- elementUI 时间格式化(一般方法)
1.html: ... <el-table-column prop="updateTime" label="更新时间" width="160&q ...
- Javascript - ExtJs - GridPanel组件
GridPanel组件(Ext.grid.GridPanel)logogram:Ext.grid.Panel | xtype:gridpanel 此类派生自Ext.Panel,创建表格需要两个必须的对 ...
- strftime 日期时间格式化
strftime() 函数根据区域设置格式化本地时间/日期,函数的功能将时间格式化,或者说格式化一个时间字符串. size_t strftime(char *strDest,size_t maxsiz ...
- javascript 时间格式化
添加扩展 //时间格式化扩展Date.prototype.format = function(format){ var o = { "M+" : this.getMonth()+1 ...
- js时间格式化
const formatDate = timestamp => { const date = new Date(timestamp); const m = date.getMonth() + 1 ...
- js对特殊字符转义、时间格式化、获取URL参数
/*特殊字符转义*/ function replace_html(str) { var str = str.toString().replace(/&/g, "&" ...
- 特殊字符转义&时间格式化&获取URL参数
/*特殊字符转义*/ function htmlspecialchars (str) { var str = str.toString().replace(/&/g, "&& ...
- 【AspNetCore】【WebApi】扩展Webapi中的RouteConstraint中,让DateTime类型,支持时间格式化(DateTimeFormat)
扩展Webapi中的RouteConstraint中,让DateTime类型,支持时间格式化(DateTimeFormat) 一.背景 大家在使用WebApi时,会用到DateTime为参数,类似于这 ...
随机推荐
- hdu 2004 成绩转换
成绩转换 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submi ...
- css3 选择器记
css3 选择器 根据所获取页面中元素的不同,把css3选择器分为五大类: 基本选择器 层次选择器 伪类选择器 动态伪类选择器 目标伪类选择器 语言伪类选择器 UI元素状态伪类选择器 结构伪类选择器 ...
- Quartz Scheduler(2.2.1) - Usage of CronTriggers
Cron is a UNIX tool that has been around for a long time, so its scheduling capabilities are powerfu ...
- asp.net php asp jsp 301重定向的代码
介绍一下针对各类程序系统实施301重定向的代码: 1.Linux主机重定向 Godaddy的Liunx主机,Godaddy本身已经支持Apache,所以直接创建一个.htaccess文件就可以了,一般 ...
- 【转】预编译头文件来自编译器的早期版本,或者预编译头为 C++ 而在 C 中使用它(或相反)
用VC++ 2008 编写C语言程序,编译出现错误: 预编译头文件来自编译器的早期版本,或者预编译头为 C++ 而在 C 中使用它(或相反) 解决方法: 建工程时 建立空项目 或者在项目设置里关闭预编 ...
- [转] Portable Trac 简单介绍 - 兼谈为什么不选择 Redmine
Portable Trac 简单介绍 - 兼谈为什么不选择 Redmine Trac是一个轻量级的软件项目管理环境,如果在工作中涉及一个开发团队的管理并且关心项目管理工具的话,相信都在 Trac. ...
- 前端笔记——获取url里面的参数值
备注 var url=window.location.href;//获取地址栏 url var index=url.indexOf('#');//获取#的位置 var paramVal=url.sub ...
- C#调用WinAPI及窗口过程
C#调用WINAPI及Windows窗口消息的发与送 最近在做一个餐饮项目(C#Winform),其中有一块是做点菜宝接口的对接,点菜宝的厂商提供了一个WX.exe的驱动程序,这个驱动程序无直接打开, ...
- 【转】Linux网络编程入门
(一)Linux网络编程--网络知识介绍 Linux网络编程--网络知识介绍客户端和服务端 网络程序和普通的程序有一个最大的区别是网络程序是由两个部分组成的--客户端和服务器端. 客户 ...
- lex&yacc
LEX: yytext 数组包含匹配模式的文本; 使词法分析程序工作的两条规则是:1. lex 模式只匹配输入字符或字符串一次.2. lex 执行当前输入的最长可能匹配的动作. 由 lex 产生的词法 ...