Rev 1314 | Rev 1317 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1314 | Rev 1315 | ||
---|---|---|---|
1 | <%@ page import="pt.estgp.estgweb.web.filters.TopImageFilter" %> |
1 | <%@ page import="pt.estgp.estgweb.web.filters.TopImageFilter" %> |
2 | <%@ page contentType="text/html;charset=UTF-8" language="java" %> |
2 | <%@ page contentType="text/html;charset=UTF-8" language="java" %> |
3 | 3 | ||
4 | <meta name="viewport" content="width=device-width, initial-scale=1"> |
4 | <meta name="viewport" content="width=device-width, initial-scale=1"> |
5 | 5 | ||
6 | 6 | ||
7 | <% |
7 | <% |
8 | String bacoTheme = (String) request.getAttribute("pt_estgp_estgweb_theme"); |
8 | String bacoTheme = (String) request.getAttribute("pt_estgp_estgweb_theme"); |
9 | if(bacoTheme == null) |
9 | if(bacoTheme == null) |
10 | bacoTheme = "estg"; |
10 | bacoTheme = "estg"; |
11 | %> |
11 | %> |
12 | 12 | ||
13 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/menu/assets/skins/sam/menu.css" /> |
13 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/menu/assets/skins/sam/menu.css" /> |
14 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/button/assets/skins/sam/button.css" /> |
14 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/button/assets/skins/sam/button.css" /> |
15 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/fonts/fonts-min.css" /> |
15 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/fonts/fonts-min.css" /> |
16 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/container/assets/skins/sam/container.css" /> |
16 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/container/assets/skins/sam/container.css" /> |
17 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/editor/assets/skins/sam/editor.css" /> |
17 | <link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/yui/build/editor/assets/skins/sam/editor.css" /> |
18 | 18 | ||
19 | <!--OFF CANVAS É PARA METER O BODY ABAIXO DO MENU DESLIZANTE DE TOPO--> |
19 | <!--OFF CANVAS É PARA METER O BODY ABAIXO DO MENU DESLIZANTE DE TOPO--> |
20 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/offcanvas.css"/> |
20 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/offcanvas.css"/> |
21 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/style.css"/> |
- | |
- | 21 | ||
22 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/stylePublicPortal.css"/> |
22 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/stylePublicPortal.css"/> |
23 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/functions.js"></script> |
23 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/functions.js"></script> |
24 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/ajax.js"></script> |
24 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/ajax.js"></script> |
25 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/compactedPopup.js"></script> |
25 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/compactedPopup.js"></script> |
26 | <!-- |
26 | <!-- |
27 | <style> |
27 | <style> |
28 | body |
28 | body |
29 | { |
29 | { |
30 | background: url('http://www.ist.utl.pt/img/page/cubes.png') |
30 | background: url('http://www.ist.utl.pt/img/page/cubes.png') |
31 | } |
31 | } |
32 | </style>--> |
32 | </style>--> |
33 | <!-- |
33 | <!-- |
34 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/js/jquery/style.css"/> |
34 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/js/jquery/style.css"/> |
35 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquery-latest.js"></script> |
35 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquery-latest.js"></script> |
36 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquery.tablesorter.js"></script> |
36 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquery.tablesorter.js"></script> |
37 | --> |
37 | --> |
38 | 38 | ||
39 | <% |
39 | <% |
40 | String link = (String) request.getAttribute(TopImageFilter.TOP_CSS); |
40 | String link = (String) request.getAttribute(TopImageFilter.TOP_CSS); |
41 | if (link != null) |
41 | if (link != null) |
42 | { |
42 | { |
43 | %> |
43 | %> |
44 | <link type="text/css" rel="stylesheet" href="<%=link%>"/> |
44 | <link type="text/css" rel="stylesheet" href="<%=link%>"/> |
45 | <% |
45 | <% |
46 | } |
46 | } |
47 | %> |
47 | %> |
48 | 48 | ||
49 | <script type="text/javascript" language="JavaScript"> |
49 | <script type="text/javascript" language="JavaScript"> |
50 | var cal = new CalendarPopup(); |
50 | var cal = new CalendarPopup(); |
51 | 51 | ||
52 | /* //TABLE SORTER |
52 | /* //TABLE SORTER |
53 | $(document).ready(function() |
53 | $(document).ready(function() |
54 | { |
54 | { |
55 | $("#myTable").tablesorter(); |
55 | $("#myTable").tablesorter(); |
56 | 56 | ||
57 | } |
57 | } |
58 | );*/ |
58 | );*/ |
59 | 59 | ||
60 | </script> |
60 | </script> |
61 | 61 | ||
62 | 62 | ||
63 | 63 | ||
64 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/jquery-2.1.4.min.js"></script> |
64 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/jquery-2.1.4.min.js"></script> |
65 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/jquery.tablesorter.min.js"></script> |
65 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/jquery.tablesorter.min.js"></script> |
66 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/jquery.tablesorter.widgets.js"></script> |
66 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/jquery.tablesorter.widgets.js"></script> |
67 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/bootstrap/js/bootstrap.js"></script> |
67 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/jquerytables/bootstrap/js/bootstrap.js"></script> |
68 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/bootstrap/css/bootstrap.css" type="text/css"/> |
68 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/bootstrap/css/bootstrap.css" type="text/css"/> |
69 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/bootstrap/icomoon/style.css" type="text/css"/> |
69 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/bootstrap/icomoon/style.css" type="text/css"/> |
70 | <!--<link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/bootstrap/css/bootstrap-theme.css" type="text/css"/>--> |
70 | <!--<link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/bootstrap/css/bootstrap-theme.css" type="text/css"/>--> |
71 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/jquerytable/theme.estg.css" type="text/css"/> |
71 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/jquerytable/theme.estg.css" type="text/css"/> |
72 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/jquerytable/filter.formatter.css" type="text/css"/> |
72 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/jquerytables/jquerytable/filter.formatter.css" type="text/css"/> |
73 | <!--<link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/variables.less"/> |
73 | <!--<link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/variables.less"/> |
74 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/lavish-bootstrap.css"/>--> |
74 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/lavish-bootstrap.css"/>--> |
75 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/lavish-bootstrap.css"/> |
75 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/lavish-bootstrap.css"/> |
76 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/variables.scss"/> |
76 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/variables.scss"/> |
77 | 77 | ||
78 | 78 | ||
79 | 79 | ||
80 | <%--SCRIPTS DO CALENDARIO BOOTSTRAP--%> |
80 | <%--SCRIPTS DO CALENDARIO BOOTSTRAP--%> |
81 | <%--<script type="text/javascript" src="/bower_components/jquery/jquery.min.js"></script>--%> |
81 | <%--<script type="text/javascript" src="/bower_components/jquery/jquery.min.js"></script>--%> |
82 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/bower_components/moment/min/moment.min.js"></script> |
82 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/bower_components/moment/min/moment.min.js"></script> |
83 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/bower_components/moment/locale/pt.js"></script> |
83 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/bower_components/moment/locale/pt.js"></script> |
84 | <%--<script type="text/javascript" src="/bower_components/bootstrap/dist/js/bootstrap.min.js"></script>--%> |
84 | <%--<script type="text/javascript" src="/bower_components/bootstrap/dist/js/bootstrap.min.js"></script>--%> |
85 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/bower_components/eonasdan-bootstrap-datetimepicker/build/js/bootstrap-datetimepicker.min.js"></script> |
85 | <script type="text/javascript" src="<%=request.getContextPath()%>/js/bower_components/eonasdan-bootstrap-datetimepicker/build/js/bootstrap-datetimepicker.min.js"></script> |
86 | <%--<link rel="stylesheet" href="/bower_components/bootstrap/dist/css/bootstrap.min.css" />--%> |
86 | <%--<link rel="stylesheet" href="/bower_components/bootstrap/dist/css/bootstrap.min.css" />--%> |
87 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/bower_components/eonasdan-bootstrap-datetimepicker/build/css/bootstrap-datetimepicker.min.css" /> |
87 | <link rel="stylesheet" href="<%=request.getContextPath()%>/js/bower_components/eonasdan-bootstrap-datetimepicker/build/css/bootstrap-datetimepicker.min.css" /> |
88 | 88 | ||
89 | <script type="text/javascript"> |
89 | <script type="text/javascript"> |
90 | $(function () { |
90 | $(function () { |
91 | $('.datetimepicker').datetimepicker({ |
91 | $('.datetimepicker').datetimepicker({ |
92 | locale: 'pt', |
92 | locale: 'pt', |
93 | format: 'YYYY/MM/DD' |
93 | format: 'YYYY/MM/DD' |
94 | }); |
94 | }); |
95 | }); |
95 | }); |
96 | </script> |
96 | </script> |
97 | 97 | ||
98 | <script type="text/javascript" language="JavaScript"> |
98 | <script type="text/javascript" language="JavaScript"> |
99 | var cal = new CalendarPopup(); |
99 | var cal = new CalendarPopup(); |
100 | 100 | ||
101 | /* |
101 | /* |
102 | //TABLE SORTER |
102 | //TABLE SORTER |
103 | $(document).ready(function() |
103 | $(document).ready(function() |
104 | { |
104 | { |
105 | $("#myTable").tablesorter(); |
105 | $("#myTable").tablesorter(); |
106 | 106 | ||
107 | } |
107 | } |
108 | ); |
108 | ); |
109 | */ |
109 | */ |
110 | 110 | ||
111 | function isBreakpoint( alias ) { |
111 | function isBreakpoint( alias ) { |
112 | return $('.device-' + alias).is(':visible'); |
112 | return $('.device-' + alias).is(':visible'); |
113 | } |
113 | } |
114 | 114 | ||
115 | 115 | ||
116 | 116 | ||
117 | 117 | ||
118 | 118 | ||
119 | $(document).ready( |
119 | $(document).ready( |
120 | function(){ |
120 | function(){ |
121 | $("#network").hide(); |
121 | $("#network").hide(); |
122 | $("#network2").hide(); |
122 | $("#network2").hide(); |
123 | $("#network").mouseleave( |
123 | $("#network").mouseleave( |
124 | function(){ |
124 | function(){ |
125 | $("#network").animate({ |
125 | $("#network").animate({ |
126 | height: 'hide' |
126 | height: 'hide' |
127 | }); |
127 | }); |
128 | } |
128 | } |
129 | 129 | ||
130 | ); |
130 | ); |
131 | $("#network2").mouseleave( |
131 | $("#network2").mouseleave( |
132 | function(){ |
132 | function(){ |
133 | $("#network2").animate({ |
133 | $("#network2").animate({ |
134 | height: 'hide' |
134 | height: 'hide' |
135 | }); |
135 | }); |
136 | } |
136 | } |
137 | 137 | ||
138 | ); |
138 | ); |
139 | } |
139 | } |
140 | ); |
140 | ); |
141 | 141 | ||
142 | function openNetwork(id){ |
142 | function openNetwork(id){ |
143 | 143 | ||
144 | $(".slideMenu").each(function() |
144 | $(".slideMenu").each(function() |
145 | { |
145 | { |
146 | if($(this).attr("id") != id) |
146 | if($(this).attr("id") != id) |
147 | { |
147 | { |
148 | $(this).animate({ |
148 | $(this).animate({ |
149 | height: 'hide' |
149 | height: 'hide' |
150 | },200); |
150 | },200); |
151 | } |
151 | } |
152 | }); |
152 | }); |
153 | 153 | ||
154 | $("#"+id).animate({ |
154 | $("#"+id).animate({ |
155 | height: 'toggle' |
155 | height: 'toggle' |
156 | },600); |
156 | },600); |
157 | 157 | ||
158 | } |
158 | } |
159 | 159 | ||
160 | 160 | ||
161 | 161 | ||
162 | </script> |
162 | </script> |
163 | <script language="javascript"> |
163 | <script language="javascript"> |
164 | 164 | ||
165 | function ping() |
165 | function ping() |
166 | { |
166 | { |
167 | $.ajax({ |
167 | $.ajax({ |
168 | url: "<%=request.getContextPath()%>/ping.jsp", |
168 | url: "<%=request.getContextPath()%>/ping.jsp", |
169 | type: "POST", |
169 | type: "POST", |
170 | dataType: "json", |
170 | dataType: "json", |
171 | success: function(resposta) { |
171 | success: function(resposta) { |
172 | setTimeout("ping()",10000); |
172 | setTimeout("ping()",10000); |
173 | }, |
173 | }, |
174 | error: function() { |
174 | error: function() { |
175 | setTimeout("ping()",10000); |
175 | setTimeout("ping()",10000); |
176 | } |
176 | } |
177 | }); |
177 | }); |
178 | 178 | ||
179 | } |
179 | } |
180 | $(document).ready(function() |
180 | $(document).ready(function() |
181 | { |
181 | { |
182 | 182 | ||
183 | return evaluateTableSorters(); |
183 | return evaluateTableSorters(); |
184 | 184 | ||
185 | } |
185 | } |
186 | 186 | ||
187 | ); |
187 | ); |
188 | 188 | ||
189 | function evaluateTableSorters(){ |
189 | function evaluateTableSorters(){ |
190 | if($("#myTable")) |
190 | if($("#myTable")) |
191 | { |
191 | { |
192 | $("#myTable").tablesorter({ |
192 | $("#myTable").tablesorter({ |
193 | theme: 'blue', |
193 | theme: 'blue', |
194 | 194 | ||
195 | 195 | ||
196 | sortMultiSortKey: 'altKey', |
196 | sortMultiSortKey: 'altKey', |
197 | //sortList: [[0,0]], |
197 | //sortList: [[0,0]], |
198 | widgets: ["zebra","filter"], |
198 | widgets: ["zebra","filter"], |
199 | 199 | ||
200 | ignoreCase: false, |
200 | ignoreCase: false, |
201 | widthFixed : true, |
201 | widthFixed : true, |
202 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true}, |
202 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true}, |
203 | textExtraction: function(node) { |
203 | textExtraction: function(node) { |
204 | // extract data from markup and return it |
204 | // extract data from markup and return it |
205 | if($(node).find(':input').size()>0) |
205 | if($(node).find(':input').size()>0) |
206 | { |
206 | { |
207 | var values = $(node).find(":input").map(function() { |
207 | var values = $(node).find(":input").map(function() { |
208 | return $(this).val() |
208 | return $(this).val() |
209 | }).get().join(","); |
209 | }).get().join(","); |
210 | 210 | ||
211 | 211 | ||
212 | return values; |
212 | return values; |
213 | } |
213 | } |
214 | return $(node).text(); |
214 | return $(node).text(); |
215 | }, |
215 | }, |
216 | widgetOptions : { |
216 | widgetOptions : { |
217 | 217 | ||
218 | filter_excludeFilter : { |
218 | filter_excludeFilter : { |
219 | // target a column by class name or column index (zero-based) |
219 | // target a column by class name or column index (zero-based) |
220 | '.filter-false' : 'range' |
220 | '.filter-false' : 'range' |
221 | } |
221 | } |
222 | 222 | ||
223 | } |
223 | } |
224 | 224 | ||
225 | /* , |
225 | /* , |
226 | 226 | ||
227 | widgetOptions : { |
227 | widgetOptions : { |
228 | 228 | ||
229 | // filter_anyMatch options was removed in v2.15; it has been replaced by the filter_external option |
229 | // filter_anyMatch options was removed in v2.15; it has been replaced by the filter_external option |
230 | 230 | ||
231 | // If there are child rows in the table (rows with class name from "cssChildRow" option) |
231 | // If there are child rows in the table (rows with class name from "cssChildRow" option) |
232 | // and this option is true and a match is found anywhere in the child row, then it will make that row |
232 | // and this option is true and a match is found anywhere in the child row, then it will make that row |
233 | // visible; default is false |
233 | // visible; default is false |
234 | filter_childRows : false, |
234 | filter_childRows : false, |
235 | 235 | ||
236 | // if true, filter child row content by column; filter_childRows must also be true |
236 | // if true, filter child row content by column; filter_childRows must also be true |
237 | filter_childByColumn : false, |
237 | filter_childByColumn : false, |
238 | 238 | ||
239 | // if true, a filter will be added to the top of each table column; |
239 | // if true, a filter will be added to the top of each table column; |
240 | // disabled by using -> headers: { 1: { filter: false } } OR add class="filter-false" |
240 | // disabled by using -> headers: { 1: { filter: false } } OR add class="filter-false" |
241 | // if you set this to false, make sure you perform a search using the second method below |
241 | // if you set this to false, make sure you perform a search using the second method below |
242 | filter_columnFilters : true, |
242 | filter_columnFilters : true, |
243 | 243 | ||
244 | // if true, allows using "#:{query}" in AnyMatch searches (column:query; added v2.20.0) |
244 | // if true, allows using "#:{query}" in AnyMatch searches (column:query; added v2.20.0) |
245 | filter_columnAnyMatch: true, |
245 | filter_columnAnyMatch: true, |
246 | 246 | ||
247 | // extra css class name (string or array) added to the filter element (input or select) |
247 | // extra css class name (string or array) added to the filter element (input or select) |
248 | filter_cellFilter : '', |
248 | filter_cellFilter : '', |
249 | 249 | ||
250 | // extra css class name(s) applied to the table row containing the filters & the inputs within that row |
250 | // extra css class name(s) applied to the table row containing the filters & the inputs within that row |
251 | // this option can either be a string (class applied to all filters) or an array (class applied to indexed filter) |
251 | // this option can either be a string (class applied to all filters) or an array (class applied to indexed filter) |
252 | filter_cssFilter : '', // or [] |
252 | filter_cssFilter : '', // or [] |
253 | 253 | ||
254 | // add a default column filter type "~{query}" to make fuzzy searches default; |
254 | // add a default column filter type "~{query}" to make fuzzy searches default; |
255 | // "{q1} AND {q2}" to make all searches use a logical AND. |
255 | // "{q1} AND {q2}" to make all searches use a logical AND. |
256 | filter_defaultFilter : {}, |
256 | filter_defaultFilter : {}, |
257 | 257 | ||
258 | // filters to exclude, per column |
258 | // filters to exclude, per column |
259 | filter_excludeFilter : {}, |
259 | filter_excludeFilter : {}, |
260 | 260 | ||
261 | // jQuery selector (or object) pointing to an input to be used to match the contents of any column |
261 | // jQuery selector (or object) pointing to an input to be used to match the contents of any column |
262 | // please refer to the filter-any-match demo for limitations - new in v2.15 |
262 | // please refer to the filter-any-match demo for limitations - new in v2.15 |
263 | filter_external : '', |
263 | filter_external : '', |
264 | 264 | ||
265 | // class added to filtered rows (rows that are not showing); needed by pager plugin |
265 | // class added to filtered rows (rows that are not showing); needed by pager plugin |
266 | filter_filteredRow : 'filtered', |
266 | filter_filteredRow : 'filtered', |
267 | 267 | ||
268 | // add custom filter elements to the filter row |
268 | // add custom filter elements to the filter row |
269 | // see the filter formatter demos for more specifics |
269 | // see the filter formatter demos for more specifics |
270 | filter_formatter : null, |
270 | filter_formatter : null, |
271 | 271 | ||
272 | // add custom filter functions using this option |
272 | // add custom filter functions using this option |
273 | // see the filter widget custom demo for more specifics on how to use this option |
273 | // see the filter widget custom demo for more specifics on how to use this option |
274 | filter_functions : null, |
274 | filter_functions : null, |
275 | 275 | ||
276 | // hide filter row when table is empty |
276 | // hide filter row when table is empty |
277 | filter_hideEmpty : true, |
277 | filter_hideEmpty : true, |
278 | 278 | ||
279 | // if true, filters are collapsed initially, but can be revealed by hovering over the grey bar immediately |
279 | // if true, filters are collapsed initially, but can be revealed by hovering over the grey bar immediately |
280 | // below the header row. Additionally, tabbing through the document will open the filter row when an input gets focus |
280 | // below the header row. Additionally, tabbing through the document will open the filter row when an input gets focus |
281 | filter_hideFilters : true, |
281 | filter_hideFilters : true, |
282 | 282 | ||
283 | // Set this option to false to make the searches case sensitive |
283 | // Set this option to false to make the searches case sensitive |
284 | filter_ignoreCase : true, |
284 | filter_ignoreCase : true, |
285 | 285 | ||
286 | // if true, search column content while the user types (with a delay) |
286 | // if true, search column content while the user types (with a delay) |
287 | filter_liveSearch : true, |
287 | filter_liveSearch : true, |
288 | 288 | ||
289 | // a header with a select dropdown & this class name will only show available (visible) options within that drop down. |
289 | // a header with a select dropdown & this class name will only show available (visible) options within that drop down. |
290 | 290 | ||
291 | 291 | ||
292 | // default placeholder text (overridden by any header "data-placeholder" setting) |
292 | // default placeholder text (overridden by any header "data-placeholder" setting) |
293 | filter_placeholder : { search : '', select : '' }, |
293 | filter_placeholder : { search : '', select : '' }, |
294 | 294 | ||
295 | // jQuery selector string of an element used to reset the filters |
295 | // jQuery selector string of an element used to reset the filters |
296 | filter_reset : 'button.reset', |
296 | filter_reset : 'button.reset', |
297 | 297 | ||
298 | // Use the $.tablesorter.storage utility to save the most recent filters (default setting is false) |
298 | // Use the $.tablesorter.storage utility to save the most recent filters (default setting is false) |
299 | filter_saveFilters : true, |
299 | filter_saveFilters : true, |
300 | 300 | ||
301 | // Delay in milliseconds before the filter widget starts searching; This option prevents searching for |
301 | // Delay in milliseconds before the filter widget starts searching; This option prevents searching for |
302 | // every character while typing and should make searching large tables faster. |
302 | // every character while typing and should make searching large tables faster. |
303 | filter_searchDelay : 300, |
303 | filter_searchDelay : 300, |
304 | 304 | ||
305 | // allow searching through already filtered rows in special circumstances; will speed up searching in large tables if true |
305 | // allow searching through already filtered rows in special circumstances; will speed up searching in large tables if true |
306 | filter_searchFiltered: true, |
306 | filter_searchFiltered: true, |
307 | 307 | ||
308 | // include a function to return an array of values to be added to the column filter select |
308 | // include a function to return an array of values to be added to the column filter select |
309 | filter_selectSource : null, |
309 | filter_selectSource : null, |
310 | 310 | ||
311 | // if true, server-side filtering should be performed because client-side filtering will be disabled, but |
311 | // if true, server-side filtering should be performed because client-side filtering will be disabled, but |
312 | // the ui and events will still be used. |
312 | // the ui and events will still be used. |
313 | filter_serversideFiltering : false, |
313 | filter_serversideFiltering : false, |
314 | 314 | ||
315 | // Set this option to true to use the filter to find text from the start of the column |
315 | // Set this option to true to use the filter to find text from the start of the column |
316 | // So typing in "a" will find "albert" but not "frank", both have a's; default is false |
316 | // So typing in "a" will find "albert" but not "frank", both have a's; default is false |
317 | filter_startsWith : false, |
317 | filter_startsWith : false, |
318 | 318 | ||
319 | // Filter using parsed content for ALL columns |
319 | // Filter using parsed content for ALL columns |
320 | // be careful on using this on date columns as the date is parsed and stored as time in seconds |
320 | // be careful on using this on date columns as the date is parsed and stored as time in seconds |
321 | filter_useParsedData : false, |
321 | filter_useParsedData : false, |
322 | 322 | ||
323 | // data attribute in the header cell that contains the default filter value |
323 | // data attribute in the header cell that contains the default filter value |
324 | filter_defaultAttrib : 'data-value', |
324 | filter_defaultAttrib : 'data-value', |
325 | 325 | ||
326 | // filter_selectSource array text left of the separator is added to the option value, right into the option text |
326 | // filter_selectSource array text left of the separator is added to the option value, right into the option text |
327 | filter_selectSourceSeparator : '|' |
327 | filter_selectSourceSeparator : '|' |
328 | 328 | ||
329 | }*/ |
329 | }*/ |
330 | } |
330 | } |
331 | ); |
331 | ); |
332 | } |
332 | } |
333 | 333 | ||
334 | if($("#myTable2")) |
334 | if($("#myTable2")) |
335 | { |
335 | { |
336 | $("#myTable2").tablesorter({ |
336 | $("#myTable2").tablesorter({ |
337 | theme: 'blue', |
337 | theme: 'blue', |
338 | sortMultiSortKey: 'altKey', |
338 | sortMultiSortKey: 'altKey', |
339 | //sortList: [[0,0]], |
339 | //sortList: [[0,0]], |
340 | widgets: ["zebra","filter"], |
340 | widgets: ["zebra","filter"], |
341 | ignoreCase: false, |
341 | ignoreCase: false, |
342 | widthFixed : true, |
342 | widthFixed : true, |
343 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true, |
343 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true, |
344 | filter_excludeFilter : { |
344 | filter_excludeFilter : { |
345 | // target a column by class name or column index (zero-based) |
345 | // target a column by class name or column index (zero-based) |
346 | '.filter-false' : 'range' |
346 | '.filter-false' : 'range' |
347 | }}, |
347 | }}, |
348 | textExtraction: function(node) { |
348 | textExtraction: function(node) { |
349 | // extract data from markup and return it |
349 | // extract data from markup and return it |
350 | if($(node).find(':input').size()>0) |
350 | if($(node).find(':input').size()>0) |
351 | { |
351 | { |
352 | var values = $(node).find(":input").map(function() { |
352 | var values = $(node).find(":input").map(function() { |
353 | return $(this).val() |
353 | return $(this).val() |
354 | }).get().join(","); |
354 | }).get().join(","); |
355 | 355 | ||
356 | 356 | ||
357 | return values; |
357 | return values; |
358 | } |
358 | } |
359 | return $(node).text(); |
359 | return $(node).text(); |
360 | } |
360 | } |
361 | } |
361 | } |
362 | ); |
362 | ); |
363 | } |
363 | } |
364 | 364 | ||
365 | if($(".tablesortersimple")) |
365 | if($(".tablesortersimple")) |
366 | { |
366 | { |
367 | $(".tablesortersimple").tablesorter({ |
367 | $(".tablesortersimple").tablesorter({ |
368 | theme: 'blue', |
368 | theme: 'blue', |
369 | sortMultiSortKey: 'altKey', |
369 | sortMultiSortKey: 'altKey', |
370 | //sortList: [[0,0]], |
370 | //sortList: [[0,0]], |
371 | widgets: ["zebra","filter"], |
371 | widgets: ["zebra","filter"], |
372 | ignoreCase: false, |
372 | ignoreCase: false, |
373 | widthFixed : true, |
373 | widthFixed : true, |
374 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true, |
374 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true, |
375 | 375 | ||
376 | filter_excludeFilter : { |
376 | filter_excludeFilter : { |
377 | // target a column by class name or column index (zero-based) |
377 | // target a column by class name or column index (zero-based) |
378 | '.filter-false' : 'range' |
378 | '.filter-false' : 'range' |
379 | } |
379 | } |
380 | }, |
380 | }, |
381 | textExtraction: function(node) { |
381 | textExtraction: function(node) { |
382 | // extract data from markup and return it |
382 | // extract data from markup and return it |
383 | if($(node).find(':input').size()>0) |
383 | if($(node).find(':input').size()>0) |
384 | { |
384 | { |
385 | var values = $(node).find(":input").map(function() { |
385 | var values = $(node).find(":input").map(function() { |
386 | return $(this).val() |
386 | return $(this).val() |
387 | }).get().join(","); |
387 | }).get().join(","); |
388 | 388 | ||
389 | 389 | ||
390 | return values; |
390 | return values; |
391 | } |
391 | } |
392 | return $(node).text(); |
392 | return $(node).text(); |
393 | } |
393 | } |
394 | } |
394 | } |
395 | ); |
395 | ); |
396 | } |
396 | } |
397 | /* |
397 | /* |
398 | if($(".tablesorterfiltered")) |
398 | if($(".tablesorterfiltered")) |
399 | { |
399 | { |
400 | $(".tablesorterfiltered").tablesorter({ |
400 | $(".tablesorterfiltered").tablesorter({ |
401 | theme: 'blue', |
401 | theme: 'blue', |
402 | 402 | ||
403 | 403 | ||
404 | sortMultiSortKey: 'altKey', |
404 | sortMultiSortKey: 'altKey', |
405 | //sortList: [[0,0]], |
405 | //sortList: [[0,0]], |
406 | widgets: ["zebra","filter"], |
406 | widgets: ["zebra","filter"], |
407 | 407 | ||
408 | ignoreCase: false, |
408 | ignoreCase: false, |
409 | widthFixed : true, |
409 | widthFixed : true, |
410 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true}, |
410 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true}, |
411 | textExtraction: function(node) { |
411 | textExtraction: function(node) { |
412 | // extract data from markup and return it |
412 | // extract data from markup and return it |
413 | if($(node).find(':input').size()>0) |
413 | if($(node).find(':input').size()>0) |
414 | { |
414 | { |
415 | var values = $(node).find(":input").map(function() { |
415 | var values = $(node).find(":input").map(function() { |
416 | return $(this).val() |
416 | return $(this).val() |
417 | }).get().join(","); |
417 | }).get().join(","); |
418 | 418 | ||
419 | 419 | ||
420 | return values; |
420 | return values; |
421 | } |
421 | } |
422 | return $(node).text(); |
422 | return $(node).text(); |
423 | } |
423 | } |
424 | } |
424 | } |
425 | ); |
425 | ); |
426 | }*/ |
426 | }*/ |
427 | if($(".tablesorterfiltered")) |
427 | if($(".tablesorterfiltered")) |
428 | { |
428 | { |
429 | $(".tablesorterfiltered").tablesorter({ |
429 | $(".tablesorterfiltered").tablesorter({ |
430 | theme: 'blue', |
430 | theme: 'blue', |
431 | 431 | ||
432 | 432 | ||
433 | sortMultiSortKey: 'altKey', |
433 | sortMultiSortKey: 'altKey', |
434 | //sortList: [[0,0]], |
434 | //sortList: [[0,0]], |
435 | widgets: ["zebra","filter"], |
435 | widgets: ["zebra","filter"], |
436 | 436 | ||
437 | ignoreCase: false, |
437 | ignoreCase: false, |
438 | widthFixed : true, |
438 | widthFixed : true, |
439 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true, |
439 | widgetOptions : {filter_reset : 'button.reset',filter_columnFilters : true, |
440 | 440 | ||
441 | filter_excludeFilter : { |
441 | filter_excludeFilter : { |
442 | // target a column by class name or column index (zero-based) |
442 | // target a column by class name or column index (zero-based) |
443 | '.filter-false' : 'range' |
443 | '.filter-false' : 'range' |
444 | 444 | ||
445 | 445 | ||
446 | } |
446 | } |
447 | }, |
447 | }, |
448 | textExtraction: function(node) { |
448 | textExtraction: function(node) { |
449 | // extract data from markup and return it |
449 | // extract data from markup and return it |
450 | if($(node).find(':input').size()>0) |
450 | if($(node).find(':input').size()>0) |
451 | { |
451 | { |
452 | var values = $(node).find(":input").map(function() { |
452 | var values = $(node).find(":input").map(function() { |
453 | return $(this).val() |
453 | return $(this).val() |
454 | }).get().join(","); |
454 | }).get().join(","); |
455 | 455 | ||
456 | 456 | ||
457 | return values; |
457 | return values; |
458 | } |
458 | } |
459 | return $(node).text(); |
459 | return $(node).text(); |
460 | } |
460 | } |
461 | } |
461 | } |
462 | ); |
462 | ); |
463 | } |
463 | } |
464 | 464 | ||
465 | 465 | ||
466 | 466 | ||
467 | // External search |
467 | // External search |
468 | // buttons set up like this: |
468 | // buttons set up like this: |
469 | // <button type="button" data-filter-column="4" data-filter-text="2?%">Saved Search</button> |
469 | // <button type="button" data-filter-column="4" data-filter-text="2?%">Saved Search</button> |
470 | $('button[data-filter-column]').click(function(){ |
470 | $('button[data-filter-column]').click(function(){ |
471 | /*** first method *** data-filter-column="1" data-filter-text="!son" |
471 | /*** first method *** data-filter-column="1" data-filter-text="!son" |
472 | add search value to Discount column (zero based index) input */ |
472 | add search value to Discount column (zero based index) input */ |
473 | var filters = [], |
473 | var filters = [], |
474 | $t = $(this), |
474 | $t = $(this), |
475 | col = $t.data('filter-column'), // zero-based index |
475 | col = $t.data('filter-column'), // zero-based index |
476 | txt = $t.data('filter-text') || $t.text(); // text to add to filter |
476 | txt = $t.data('filter-text') || $t.text(); // text to add to filter |
477 | 477 | ||
478 | filters[col] = txt; |
478 | filters[col] = txt; |
479 | // using "table.hasFilters" here to make sure we aren't targeting a sticky header |
479 | // using "table.hasFilters" here to make sure we aren't targeting a sticky header |
480 | if($('#myTable')) |
480 | if($('#myTable')) |
481 | $.tablesorter.setFilters( $('#myTable'), filters, true ); // new v2.9 |
481 | $.tablesorter.setFilters( $('#myTable'), filters, true ); // new v2.9 |
482 | if($('#myTable2')) |
482 | if($('#myTable2')) |
483 | $.tablesorter.setFilters( $('#myTable2'), filters, true ); // new v2.9 |
483 | $.tablesorter.setFilters( $('#myTable2'), filters, true ); // new v2.9 |
484 | if($('.tablesorterfiltered')) |
484 | if($('.tablesorterfiltered')) |
485 | $.tablesorter.setFilters( $('.tablesorterfiltered'), filters, true ); // new v2.9 |
485 | $.tablesorter.setFilters( $('.tablesorterfiltered'), filters, true ); // new v2.9 |
486 | 486 | ||
487 | /* |
487 | /* |
488 | if($('.tablesorterfiltered')) |
488 | if($('.tablesorterfiltered')) |
489 | $.tablesorter.setFilters( $('.tablesorterfiltered'), filters, true ); // new v2.9 |
489 | $.tablesorter.setFilters( $('.tablesorterfiltered'), filters, true ); // new v2.9 |
490 | */ |
490 | */ |
491 | /** old method (prior to tablsorter v2.9 *** |
491 | /** old method (prior to tablsorter v2.9 *** |
492 | var filters = $('table.tablesorter').find('input.tablesorter-filter'); |
492 | var filters = $('table.tablesorter').find('input.tablesorter-filter'); |
493 | filters.val(''); // clear all filters |
493 | filters.val(''); // clear all filters |
494 | filters.eq(col).val(txt).trigger('search', false); |
494 | filters.eq(col).val(txt).trigger('search', false); |
495 | ******/ |
495 | ******/ |
496 | 496 | ||
497 | /*** second method *** |
497 | /*** second method *** |
498 | this method bypasses the filter inputs, so the "filter_columnFilters" |
498 | this method bypasses the filter inputs, so the "filter_columnFilters" |
499 | option can be set to false (no column filters showing) |
499 | option can be set to false (no column filters showing) |
500 | ******/ |
500 | ******/ |
501 | /* |
501 | /* |
502 | var columns = []; |
502 | var columns = []; |
503 | columns[5] = '2?%'; // or define the array this way [ '', '', '', '', '', '2?%' ] |
503 | columns[5] = '2?%'; // or define the array this way [ '', '', '', '', '', '2?%' ] |
504 | $('table').trigger('search', [ columns ]); |
504 | $('table').trigger('search', [ columns ]); |
505 | */ |
505 | */ |
506 | 506 | ||
507 | return false; |
507 | return false; |
508 | }); |
508 | }); |
509 | } |
509 | } |
510 | </script> |
510 | </script> |
511 | <style> |
511 | <style> |
512 | th.headerSortUp { |
512 | th.headerSortUp { |
513 | background-image: url(<%=request.getContextPath()%>/js/jquerytables/jquerytable/asc.gif); |
513 | background-image: url(<%=request.getContextPath()%>/js/jquerytables/jquerytable/asc.gif); |
514 | background-color: #3399FF; |
514 | background-color: #3399FF; |
515 | } |
515 | } |
516 | th.headerSortDown { |
516 | th.headerSortDown { |
517 | background-image: url(<%=request.getContextPath()%>/js/jquerytables/jquerytable/desc.gif); |
517 | background-image: url(<%=request.getContextPath()%>/js/jquerytables/jquerytable/desc.gif); |
518 | background-color: #3399FF; |
518 | background-color: #3399FF; |
519 | } |
519 | } |
520 | .dorsalActivado span, .dorsal span |
520 | .dorsalActivado span, .dorsal span |
521 | { |
521 | { |
522 | text-align: center; |
522 | text-align: center; |
523 | background-color: white; |
523 | background-color: white; |
524 | padding: 3px; |
524 | padding: 3px; |
525 | border: 1px solid black; |
525 | border: 1px solid black; |
526 | font-weight: bold; |
526 | font-weight: bold; |
527 | white-space: nowrap; |
527 | white-space: nowrap; |
528 | } |
528 | } |
529 | 529 | ||
530 | .tablesorterfiltered thead .disabled {display: none} |
530 | .tablesorterfiltered thead .disabled {display: none} |
531 | 531 | ||
532 | </style> |
532 | </style> |
533 | 533 | ||
534 | 534 | ||
535 | 535 | ||
536 | 536 | ||
537 | <%--SCRIPTS DO EDITOR DE HTML 5--%> |
537 | <%--SCRIPTS DO EDITOR DE HTML 5--%> |
538 | 538 | ||
539 | <!-- |
539 | <!-- |
540 | 540 | ||
541 | <link rel="apple-touch-icon" href="//mindmup.s3.amazonaws.com/lib/img/apple-touch-icon.png" /> |
541 | <link rel="apple-touch-icon" href="//mindmup.s3.amazonaws.com/lib/img/apple-touch-icon.png" /> |
542 | --> |
542 | --> |
543 | <link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/external/google-code-prettify/prettify.css" rel="stylesheet"> |
543 | <link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/external/google-code-prettify/prettify.css" rel="stylesheet"> |
544 | <!--<link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/netdna/bootstrap-combined.no-icons.min.css" rel="stylesheet">--> |
544 | <!--<link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/netdna/bootstrap-combined.no-icons.min.css" rel="stylesheet">--> |
545 | <%--<link href="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.1/css/bootstrap-responsive.min.css" rel="stylesheet">--%> |
545 | <%--<link href="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.1/css/bootstrap-responsive.min.css" rel="stylesheet">--%> |
546 | <%--<link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/netdna/font-awesome.css" rel="stylesheet">--%> |
546 | <link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/netdna/font-awesome.css" rel="stylesheet"> |
547 | <%--<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>--%> |
547 | <%--<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>--%> |
548 | <script src="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/external/jquery.hotkeys.js"></script> |
548 | <script src="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/external/jquery.hotkeys.js"></script> |
549 | <%--<script src="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.1/js/bootstrap.min.js"></script>--%> |
549 | <%--<script src="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.1/js/bootstrap.min.js"></script>--%> |
550 | <script src="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/external/google-code-prettify/prettify.js"></script> |
550 | <script src="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/external/google-code-prettify/prettify.js"></script> |
551 | <link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/index.css" rel="stylesheet"> |
551 | <link href="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/index.css" rel="stylesheet"> |
552 | <script src="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/bootstrap-wysiwyg.js"></script> |
552 | <script src="<%=request.getContextPath()%>/js/bootstrap-wysiwyg-master/bootstrap-wysiwyg.js"></script> |
553 | 553 | ||
554 | 554 | ||
555 | 555 | ||
556 | 556 | ||
557 | 557 | ||
558 | <script> |
558 | <script> |
559 | 559 | ||
560 | function initToolbarBootstrapBindings() { |
560 | function initToolbarBootstrapBindings() { |
561 | var fonts = ['Serif', 'Sans', 'Arial', 'Arial Black', 'Courier', |
561 | var fonts = ['Serif', 'Sans', 'Arial', 'Arial Black', 'Courier', |
562 | 'Courier New', 'Comic Sans MS', 'Helvetica', 'Impact', 'Lucida Grande', 'Lucida Sans', 'Tahoma', 'Times', |
562 | 'Courier New', 'Comic Sans MS', 'Helvetica', 'Impact', 'Lucida Grande', 'Lucida Sans', 'Tahoma', 'Times', |
563 | 'Times New Roman', 'Verdana'], |
563 | 'Times New Roman', 'Verdana'], |
564 | fontTarget = $('[title=Font]').siblings('.dropdown-menu'); |
564 | fontTarget = $('[title=Font]').siblings('.dropdown-menu'); |
565 | $.each(fonts, function (idx, fontName) { |
565 | $.each(fonts, function (idx, fontName) { |
566 | fontTarget.append($('<li><a data-edit="fontName ' + fontName +'" style="font-family:\''+ fontName +'\'">'+fontName + '</a></li>')); |
566 | fontTarget.append($('<li><a data-edit="fontName ' + fontName +'" style="font-family:\''+ fontName +'\'">'+fontName + '</a></li>')); |
567 | }); |
567 | }); |
568 | $('a[title]').tooltip({container:'body'}); |
568 | $('a[title]').tooltip({container:'body'}); |
569 | $('.dropdown-menu input').click(function() {return false;}) |
569 | $('.dropdown-menu input').click(function() {return false;}) |
570 | .change(function () {$(this).parent('.dropdown-menu').siblings('.dropdown-toggle').dropdown('toggle');}) |
570 | .change(function () {$(this).parent('.dropdown-menu').siblings('.dropdown-toggle').dropdown('toggle');}) |
571 | .keydown('esc', function () {this.value='';$(this).change();}); |
571 | .keydown('esc', function () {this.value='';$(this).change();}); |
572 | 572 | ||
573 | $('[data-role=magic-overlay]').each(function () { |
573 | $('[data-role=magic-overlay]').each(function () { |
574 | var overlay = $(this), target = $(overlay.data('target')); |
574 | var overlay = $(this), target = $(overlay.data('target')); |
575 | overlay.css('opacity', 0).css('position', 'absolute').offset(target.offset()).width(target.outerWidth()).height(target.outerHeight()); |
575 | overlay.css('opacity', 0).css('position', 'absolute').offset(target.offset()).width(target.outerWidth()).height(target.outerHeight()); |
576 | }); |
576 | }); |
577 | if ("onwebkitspeechchange" in document.createElement("input")) { |
577 | if ("onwebkitspeechchange" in document.createElement("input")) { |
578 | var editorOffset = $('#editor').offset(); |
578 | var editorOffset = $('#editor').offset(); |
579 | $('#voiceBtn').css('position','absolute').offset({top: editorOffset.top, left: editorOffset.left+$('#editor').innerWidth()-35}); |
579 | $('#voiceBtn').css('position','absolute').offset({top: editorOffset.top, left: editorOffset.left+$('#editor').innerWidth()-35}); |
580 | } else { |
580 | } else { |
581 | $('#voiceBtn').hide(); |
581 | $('#voiceBtn').hide(); |
582 | } |
582 | } |
583 | }; |
583 | }; |
584 | function showErrorAlert (reason, detail) { |
584 | function showErrorAlert (reason, detail) { |
585 | var msg=''; |
585 | var msg=''; |
586 | if (reason==='unsupported-file-type') { msg = "Unsupported format " +detail; } |
586 | if (reason==='unsupported-file-type') { msg = "Unsupported format " +detail; } |
587 | else { |
587 | else { |
588 | console.log("error uploading file", reason, detail); |
588 | console.log("error uploading file", reason, detail); |
589 | } |
589 | } |
590 | $('<div class="alert"> <button type="button" class="close" data-dismiss="alert">×</button>'+ |
590 | $('<div class="alert"> <button type="button" class="close" data-dismiss="alert">×</button>'+ |
591 | '<strong>File upload error</strong> '+msg+' </div>').prependTo('#alerts'); |
591 | '<strong>File upload error</strong> '+msg+' </div>').prependTo('#alerts'); |
592 | }; |
592 | }; |
593 | $(document).ready(function(){ |
593 | $(document).ready(function(){ |
594 | 594 | ||
595 | initToolbarBootstrapBindings(); |
595 | initToolbarBootstrapBindings(); |
596 | $('#editor').wysiwyg({ fileUploadError: showErrorAlert} ); |
596 | $('#editor').wysiwyg({ fileUploadError: showErrorAlert} ); |
597 | window.prettyPrint && prettyPrint(); |
597 | window.prettyPrint && prettyPrint(); |
598 | }); |
598 | }); |
599 | 599 | ||
600 | 600 | ||
601 | /****** |
601 | /****** |
602 | * Function for Files Version service data.jsp |
602 | * Function for Files Version service data.jsp |
603 | * |
603 | * |
604 | */ |
604 | */ |
605 | function submitDataVersionForm() |
605 | function submitDataVersionForm() |
606 | { |
606 | { |
607 | $.post( "<%=request.getContextPath()%>/user/data.jsp?id=" + $("#filesVersionsId").val(), function( data ) { |
607 | $.post( "<%=request.getContextPath()%>/user/data.jsp?id=" + $("#filesVersionsId").val(), function( data ) { |
608 | $("#contentVersions").html($( data ).find("#contentVersions").html()); |
608 | $("#contentVersions").html($( data ).find("#contentVersions").html()); |
609 | evaluateTableSorters(); |
609 | evaluateTableSorters(); |
610 | }); |
610 | }); |
611 | } |
611 | } |
612 | 612 | ||
613 | function invoqueDataVersionForm(id) |
613 | function invoqueDataVersionForm(id) |
614 | { |
614 | { |
615 | $("#filesVersionsId").val(id); |
615 | $("#filesVersionsId").val(id); |
616 | submitDataVersionForm(); |
616 | submitDataVersionForm(); |
617 | $('#historyFilesModal').modal({ |
617 | $('#historyFilesModal').modal({ |
618 | show: 'true' |
618 | show: 'true' |
619 | }); |
619 | }); |
620 | } |
620 | } |
621 | 621 | ||
622 | </script> |
622 | </script> |
623 | - | ||
- | 623 | <%--O nosso estilo fica aqui para se sobrepor--%> |
|
- | 624 | <link type="text/css" rel="stylesheet" href="<%=request.getContextPath()%>/css/<%=bacoTheme%>/style.css"/> |
|
624 | <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
625 | <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
625 | 626 | ||
626 | Generated by GNU Enscript 1.6.5.2. |
627 | Generated by GNU Enscript 1.6.5.2. |
627 | 628 | ||
628 | 629 |