Javascript-форум (https://javascript.ru/forum/)
-   ExtJS (https://javascript.ru/forum/extjs/)
-   -   Как только подключаю store таблица Grid - не рисуется.(? (https://javascript.ru/forum/extjs/10299-kak-tolko-podklyuchayu-store-tablica-grid-ne-risuetsya.html)

JSTalker 27.06.2010 09:50

Как только подключаю store таблица Grid - не рисуется.(?
 
Вот код:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
		<title>EditorGridTable with JSON-dataloading</title>
		<link rel='stylesheet' type='text/css' href='lib/ext/resources/css/ext-all.css'>
		<script type='text/javascript' src='lib/ext/adapter/ext/ext-base.js'></script>
		<script type='text/javascript' src='lib/ext/ext-all-debug.js'></script>
		<script type='text/javascript'>
			Ext.onReady(function(){
				
				var myGridPanel = new Ext.grid.EditorGridPanel({
					
					id: 'egrid1',
					renderTo: document.body,
					width: 600,
					height: 300,
					//store: myStore,
					frame: true,
					clickstoEdit: 1,
					columns:[
					{header: 'Title', sortable: true, dataIndex: 'title'},
					{header: 'Color', sortable: true, dataIndex: 'color'},
					{header: 'Width', sortable: true, dataIndex: 'width'},
					{header: 'Height', sortable: true, dataIndex: 'height'}
					]
					
					//buttons: [{text: 'apply'}]
				})
			})
		</script>
	</head>
	<body>
	</body>
</html>


Как только убираю комментарии, таблица перестает отображаться. Моск уже сломал: где я чего не вижу?

Kolyaj 27.06.2010 18:05

Цитата:

Сообщение от JSTalker
где я чего не вижу?

Я вот myStore не вижу.

JSTalker 27.06.2010 19:45

Kolyaj,
эту проблему решил.

почему то с масиивом данных таблица не работала, а вот когда json-данные включил, и бед ридера - все поехало!


Часовой пояс GMT +3, время: 00:38.