summaryrefslogtreecommitdiffstats
path: root/extensions/MyDashboard/web/js
diff options
context:
space:
mode:
Diffstat (limited to 'extensions/MyDashboard/web/js')
-rw-r--r--extensions/MyDashboard/web/js/flags.js14
-rw-r--r--extensions/MyDashboard/web/js/query.js8
2 files changed, 16 insertions, 6 deletions
diff --git a/extensions/MyDashboard/web/js/flags.js b/extensions/MyDashboard/web/js/flags.js
index 1ba6bd696..3ac51acac 100644
--- a/extensions/MyDashboard/web/js/flags.js
+++ b/extensions/MyDashboard/web/js/flags.js
@@ -140,8 +140,7 @@ YUI({
dataTable.requestee.plug(Y.Plugin.DataTableSort);
dataTable.requestee.plug(Y.Plugin.DataTableDataSource, {
- datasource: dataSource,
- initialRequest: updateFlagTable("requestee"),
+ datasource: dataSource.requestee
});
dataSource.requestee.plug(Y.Plugin.DataSourceJSONSchema, {
@@ -185,8 +184,7 @@ YUI({
dataTable.requester.plug(Y.Plugin.DataTableSort);
dataTable.requester.plug(Y.Plugin.DataTableDataSource, {
- datasource: dataSource,
- initialRequest: updateFlagTable("requester"),
+ datasource: dataSource.requester
});
dataSource.requester.plug(Y.Plugin.DataSourceJSONSchema, {
@@ -197,6 +195,14 @@ YUI({
}
});
+ // Initial load
+ Y.on("contentready", function (e) {
+ updateFlagTable("requestee");
+ }, "#requestee_table");
+ Y.on("contentready", function (e) {
+ updateFlagTable("requester");
+ }, "#requester_table");
+
Y.one('#requester_refresh').on('click', function(e) {
updateFlagTable('requester');
});
diff --git a/extensions/MyDashboard/web/js/query.js b/extensions/MyDashboard/web/js/query.js
index aaacf753b..cf716fbe3 100644
--- a/extensions/MyDashboard/web/js/query.js
+++ b/extensions/MyDashboard/web/js/query.js
@@ -147,10 +147,14 @@ YUI({
dataTable.plug(Y.Plugin.DataTableSort);
dataTable.plug(Y.Plugin.DataTableDataSource, {
- datasource: dataSource,
- initialRequest: updateQueryTable(default_query),
+ datasource: dataSource
});
+ // Initial load
+ Y.on("contentready", function (e) {
+ updateQueryTable(default_query);
+ }, "#query_table");
+
Y.one('#query').on('change', function(e) {
var index = e.target.get('selectedIndex');
var selected_value = e.target.get("options").item(index).getAttribute('value');