var cm = new Ext.grid.ColumnModel([ 缺少对象
<%@pagelanguage="java"import="java.util.*"pageEncoding="utf-8"%><!DOCTYPEHTMLPUBLIC"-...
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<link rel="stylesheet" type="text/css" href="Ext/extjs4.0/resources/css/ext-all.css">
<script type="text/javascript" src="Ext/extjs4.0/bootstrap.js"></script>
<script type="text/javascript" src="Ext/extjs4.0/ext-all.js"></script>
<script type="text/javascript">
Ext.onReady(function(){
var cm = new Ext.grid.ColumnModel([
{header:'曲目编号', dataIndex:'music_id'},
{header:'曲目名称', dataIndex:'music_name'},
{header:'作曲家', dataIndex:'composer'},
{header:'演奏乐器', dataIndex:'instrument'}
]);
var data = [
['001', 'Oasis', 'Kotaro Oshio', '吉他'],
['002', 'Classical Gas', 'Tommy.Emmanuel','吉他'],
['003', 'THIS WAY', 'Depapepe', '吉他']
];
var store = new Ext.data.Store({
proxy:new Ext.data.MemoryProxy(data),
reader:new Ext.data.ArrayReader([
{name:'music_id'},
{name:'music_name'},
{name:'composer'},
{name:'instrument'}
])
});
store.load();
var gridPanel = new Ext.grid.GridPanel({
renderTo:'gridPanel',
autoHeight:true,
store:store,
cm:cm
});
});
</script>
</head>
<body>
<div id="gridPanel"></div>
</body>
</html> 展开
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<link rel="stylesheet" type="text/css" href="Ext/extjs4.0/resources/css/ext-all.css">
<script type="text/javascript" src="Ext/extjs4.0/bootstrap.js"></script>
<script type="text/javascript" src="Ext/extjs4.0/ext-all.js"></script>
<script type="text/javascript">
Ext.onReady(function(){
var cm = new Ext.grid.ColumnModel([
{header:'曲目编号', dataIndex:'music_id'},
{header:'曲目名称', dataIndex:'music_name'},
{header:'作曲家', dataIndex:'composer'},
{header:'演奏乐器', dataIndex:'instrument'}
]);
var data = [
['001', 'Oasis', 'Kotaro Oshio', '吉他'],
['002', 'Classical Gas', 'Tommy.Emmanuel','吉他'],
['003', 'THIS WAY', 'Depapepe', '吉他']
];
var store = new Ext.data.Store({
proxy:new Ext.data.MemoryProxy(data),
reader:new Ext.data.ArrayReader([
{name:'music_id'},
{name:'music_name'},
{name:'composer'},
{name:'instrument'}
])
});
store.load();
var gridPanel = new Ext.grid.GridPanel({
renderTo:'gridPanel',
autoHeight:true,
store:store,
cm:cm
});
});
</script>
</head>
<body>
<div id="gridPanel"></div>
</body>
</html> 展开
展开全部
//不是很确切地说 应该用GridPanel替代ColumnModel吧 要不然光写这句就要报错了
var cm = new Ext.grid.GridPanel([
{header:'曲目编号', dataIndex:'music_id'},
{header:'曲目名称', dataIndex:'music_name'},
{header:'作曲家', dataIndex:'composer'},
{header:'演奏乐器', dataIndex:'instrument'}
]);
ZESTRON
2024-09-04 广告
2024-09-04 广告
在Dr. O.K. Wack Chemie GmbH,我们高度重视ZESTRON的表界面分析技术。该技术通过深入研究材料表面与界面的性质,为提升产品质量与可靠性提供了有力支持。ZESTRON的表界面分析不仅涵盖了相变化、化学反应、吸附与解吸...
点击进入详情页
本回答由ZESTRON提供
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询