-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
48 lines (45 loc) · 1.5 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<html>
<head>
<meta http-equiv='Content-type'
content='text/html; charset=utf-8'>
<title>Sim.js Example</title>
<link rel="stylesheet"
href="http://bootswatch.com/cosmo/bootstrap.min.css">
</head>
<body>
<div id="log" style="margin:50px;"></div>
<script src="//cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js"></script>
<script src="//cdn.jsdelivr.net/bluebird/latest/bluebird.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/numeral.js/1.5.3/numeral.min.js"></script>
<script src="sim.js"></script>
<script>
(function () {
if (!console) {
console = {};
}
var old = console.log;
var logger = document.getElementById('log');
console.log = function (message) {
if (typeof message == 'object') {
logger.innerHTML += (JSON && JSON.stringify ? JSON.stringify(message) : String(message)) + '<br />';
} else {
logger.innerHTML += message + '<br />';
}
}
})();
Sim.init().then(function () {
console.log('computing zone vars');
Sim.allZoneVars();
console.log('running rsh');
Sim.rsh();
console.log('running hlcm');
Sim.hlcm();
console.log('computing zone price vars');
Sim.zonePriceVars();
console.log('running developer');
Sim.developer();
});
</script>
</body>
</html>