Files
openlayers/master/examples/test_mvc_widget.html
Éric Lemoine 5d14b9e2d4 Updated
2013-02-20 10:38:25 +01:00

79 lines
3.0 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
<title>Test template with Repeat using different exprchars.</title>
<script src="../../../../dojo/dojo.js" type="text/javascript" djConfig="parseOnLoad: true, isDebug: true">
</script>
<style type="text/css">
@import "../css/app-format.css";
@import "../../../../dijit/themes/claro/claro.css";
</style>
<script type="text/javascript">
dojo.require("dojox.mvc");
dojo.require("dojox.mvc.Group");
dojo.require("dojox.mvc.Repeat");
dojo.require("dijit.form.TextBox");
dojo.require("dijit.form.Button");
dojo.require("dojo.parser");
dojo.require("dojox.mvc.tests.test_templatedWidget.myMvcTemplated");
// Raw records for the master detail
var search_results_init = {
"Query": "Engineers",
"Results": [{
"First": "Anne",
"Last": "Ackerman",
"Location": "NY",
"Office": "1S76",
"Email": "a.a@test.com",
"Tel": "123-764-8237",
"Fax": "123-764-8228"
}, {
"First": "Ben",
"Last": "Beckham",
"Location": "NY",
"Office": "5N47",
"Email": "b.b@test.com",
"Tel": "123-764-8599",
"Fax": "123-764-8600"
}, {
"First": "John",
"Last": "Jacklin",
"Location": "CA",
"Office": "6701",
"Email": "j.j@test.com",
"Tel": "408-764-1234",
"Fax": "408-764-4321"
}]
};
// The dojox.mvc.StatefulModel class creates a data model instance
// where each leaf within the data model is decorated with dojo.Stateful
// properties that widgets can bind to and watch for their changes.
var searchRecords = dojox.mvc.newStatefulModel({
data: search_results_init
});
dojo.ready(function(){
//dojo.parser.parse(dojo.byId('container'));
dojo.parser.parse();
});
</script>
</head>
<body class="claro" style="background-image: url(../images/master_detail.png)">
<div id="wrapper">
<div id="main">
<div id="leftNav"></div>
<div id="mainContent">
<div>
Test exprchar. Widget template test uses exprchar of # and others for template:#{this.index} etc.
</div>
<br/>
<div id="container2" data-dojo-type="dojox.mvc.tests.test_templatedWidget.myMvcTemplated">
</div>
</div>
</div>
</div>
</body>