-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex copy.html
131 lines (101 loc) · 4.01 KB
/
index copy.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<!-- main page for data_integrator frontend -->
<html>
<head>
<!--
TODO: Check out Browserify
-->
<script type="text/javascript" src="./js/require.js"></script>
<script type="text/javascript">
var smoothie = {
'requirePaths': [
'./node_modules',
'./classes',
'./widgets']
};
</script>
<script type="text/javascript" src="./js/jquery-1.11.0.min.js"></script>
<!--<script src="//code.jquery.com/jquery-1.11.0.min.js"></script>-->
<script type="text/javascript" src="./ckeditor/ckeditor.js"></script>
<script type="text/javascript" src="./ckeditor/adapters/jquery.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="/path/to/masonry.pkgd.min.js"></script>
<link href="css/bootstrap-responsive.css" rel="stylesheet">
<link href="css/bootstrap.min.css" rel="stylesheet" media="screen">
<link href="css/integrator.css" rel="stylesheet">
<!--<script src="widgets/templaterenderer/widget.templaterenderer.class.js"></script> -->
<!-- <script src="classes/thing/thing.js"></script> -->
<script type="text/javascript" language="javascript">
var IAMONTHECLIENT = true;
var GLOBAL = {};
GLOBAL.context = "client";
GLOBAL.myrequire = function(name){
var fullpath = "";
var required = false;
}
$(document).ready(function(){
// bootstrap-ckeditor-modal-fix.js
// hack to fix ckeditor/bootstrap compatiability bug when ckeditor appears in a bootstrap modal dialog
//
// Include this AFTER both bootstrap and ckeditor are loaded.
// From: http://stackoverflow.com/questions/14420300/bootstrap-with-ckeditor-equals-problems
// Author: http://stackoverflow.com/users/185839/aaron
$.fn.modal.Constructor.prototype.enforceFocus = function() {
modal_this = this
$(document).on('focusin.modal', function (e) {
if (modal_this.$element[0] !== e.target && !modal_this.$element.has(e.target).length
&& !$(e.target.parentNode).hasClass('cke_dialog_ui_input_select')
&& !$(e.target.parentNode).hasClass('cke_dialog_ui_input_text')) {
modal_this.$element.focus()
}
})
};
$(".editor").ckeditor(function(elem){
console.log("editor loaded");
});
var entityManager = require("classes/entity/entity").EntityManager();
var urlparser = require("node_modules/urlparser/index.js");
var renderer = require("classes/renderer/renderer").RenderManager();
var parsed = urlparser.parse(location.href, true);
console.log(parsed);
var entityId = parsed.query.parts[0];
console.log(entityId);
function callback(entity){
console.log("in final callback");
renderer.renderEntityEditable(entity, $(".navbar"), $(".mainview"));
}
entityManager.generateEntity(entityId, callback);
console.log("done");
});
</script>
</head>
<body style="padding-top: 70px;">
<div class="navbar navbar-default navbar-fixed-top" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">Integrator</a>
</div>
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<!-- <li class="actionButton"><a class="actionLabel" >Entity Action 1</a></li> -->
<li class="actionDropdown">
<a href="#" class="dropdown-toggle actionLabel" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
<ul class="dropdown-menu">
</ul>
</li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li class="active"><a class="entityDescriptor">Default</a></li>
</ul>
</div><!--/.nav-collapse -->
</div>
</div>
<div class="container mainview">
</div>
</body>
</html>