git://git.onelab.eu
/
unfold.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
slicestat plugin show function called on click on tabs
[unfold.git]
/
plugins
/
slicestat
/
static
/
js
/
slicestat.js
diff --git
a/plugins/slicestat/static/js/slicestat.js
b/plugins/slicestat/static/js/slicestat.js
index
5c1920a
..
22277a5
100644
(file)
--- a/
plugins/slicestat/static/js/slicestat.js
+++ b/
plugins/slicestat/static/js/slicestat.js
@@
-13,7
+13,7
@@
(function($){
(function($){
- var Slice
s
tat = Plugin.extend({
+ var Slice
S
tat = Plugin.extend({
/** XXX to check
* @brief Plugin constructor
/** XXX to check
* @brief Plugin constructor
@@
-23,6
+23,7
@@
* applied, which allows to maintain chainability of calls
*/
init: function(options, element) {
* applied, which allows to maintain chainability of calls
*/
init: function(options, element) {
+ this.classname="slicestat";
// Call the parent constructor, see FAQ when forgotten
this._super(options, element);
// Call the parent constructor, see FAQ when forgotten
this._super(options, element);
@@
-51,7
+52,7
@@
},
/* PLUGIN EVENTS */
},
/* PLUGIN EVENTS */
- // on_show like in
hazelnut
+ // on_show like in
querytable
/* GUI EVENTS */
/* GUI EVENTS */
@@
-74,6
+75,7
@@
on_show: function(ev)
{
on_show: function(ev)
{
+ console.log('slicestat show triggered');
$('iframe#' + ev.target.id + '-iframe').attr('src','http://plestats.planet-lab.eu/nodes.php?slice='+ev.data.slicename+'&order='+ev.data.o);
},
/* TEMPLATES */
$('iframe#' + ev.target.id + '-iframe').attr('src','http://plestats.planet-lab.eu/nodes.php?slice='+ev.data.slicename+'&order='+ev.data.o);
},
/* TEMPLATES */
@@
-110,7
+112,7
@@
});
/* Plugin registration */
});
/* Plugin registration */
- $.plugin('Slice
stat', Slices
tat);
+ $.plugin('Slice
Stat', SliceS
tat);
// TODO Here use cases for instanciating plugins in different ways like in the pastie.
// TODO Here use cases for instanciating plugins in different ways like in the pastie.