forked from evoluteur/evolutility-ui-jquery
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcontroller.html
More file actions
137 lines (98 loc) · 3.3 KB
/
Copy pathcontroller.html
File metadata and controls
137 lines (98 loc) · 3.3 KB
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
132
133
134
135
136
137
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1">
<link href="../dist/css/demo.css" rel="stylesheet" />
<link href="../dist/css/evolutility.css" rel="stylesheet" />
<link id="bwCSS" href="../dist/css/vendors.min.css" rel="stylesheet" />
<title>Evolutility Controller</title>
</head>
<body>
<div class="evo-header">
<div class="evo-logo"><a href="../index.html"><span>evol</span>utility<span>.js</span></a></div>
<ul class="evo-head-links">
<li><a href="../demo/index.html">demo</a></li>
<li><a href="../doc/index.html" class="sel">doc</a></li>
<li><a href="https://github.com/evoluteur/evolutility" target="_new">GitHub</a></li>
</ul>
<ul class="evo-head-links2">
<li><a href="views.html">views</a></li>
<li><a href="ui-model.html">ui-model</a></li>
<li><a href="controller.html" class="sel">controller</a></li>
</ul>
<div class="clearfix"></div>
</div>
<div class="evo-title2">
<h1>Toolbar & Controller</h1>
</div>
<div class="evo-content3">
<p>Still under construction, Evolutility controller is not the usual "C" in "MVC".
Very likely you will want to write your own (at least for now).
</p>
<p>A shell (Evol.Shell) handles routing for a set of toolbars (Evol.ViewToolbar).
Each toolbar controls the set of views to manipulate a Backbone model and collection.
</p>
<p>Using Evolutility shell, toolbar, generic views and one or more Backbone models and UI models,
you can create a SPA (single page application).
</p>
<p>
<code>new Evol.ViewToolbar(myConfig);</code>
</p>
<p>For One model</p>
<p><img src="screenshots/toolbar-one.png"></p>
<p>For Many model</p>
<p><img src="screenshots/toolbar-many.png"></p>
<section>
<h2>Methods</h2>
<p>render()</p>
<p>setData()</p>
<p>getData()</p>
<p>setView(viewName)</p>
<p>setStatus(message)</p>
<p>showFilter()</p>
<p>browse(direction)</p>
<p>saveItem(saveAndAdd)</p>
<p>newItem()</p>
<p>deleteItem()</p>
<p>clearMessage()</p>
<p>setMessage()</p>
</section>
<section>
<h2>Options</h2>
<p>toolbar: true,
<p>defaultView: 'list',
<p>style: 'panel-info',
<p>display: 'label', // tooltip, text, icon, none
<p>titleSelector: '#title',
<p>buttons: {<br/>
// --- views for one ---<br/>
view: true,<br/>
edit: true,<br/>
mini: true,<br/>
wiz: false,<br/>
json: true,<br/>
// --- views for many ---<br/>
list: true,<br/>
badges: true,<br/>
charts: true,<br/>
// --- actions ---<br/>
'new': true,<br/>
'save':true,<br/>
del: true,<br/>
filter: true,<br/>
'export': true,<br/>
group: false,<br/>
customize:false<br/>
},<br/>
<p>pageSize:20
</section>
<section>
<h2>Events</h2>
</section>
<p><br/>evolutility.js at <a href="https://github.com/evoluteur/evolutility" target="download">GitHub</a></p>
</div>
<div class="footer">© 2014 Olivier Giulieri</div>
</body>
</html>