diff --git a/app/assets/javascripts/vue/fluent_log.js b/app/assets/javascripts/vue/fluent_log.js index a22bfe5..2cab738 100644 --- a/app/assets/javascripts/vue/fluent_log.js +++ b/app/assets/javascripts/vue/fluent_log.js @@ -6,7 +6,7 @@ new Vue({ el: "#fluent-log", - paramAttributes: ["logUrl"], + paramAttributes: ["logUrl", "initialAutoReload"], data: { "autoFetch": false, "logs": [], @@ -15,6 +15,9 @@ }, created: function(){ + if(this.initialAutoReload) { + this.autoFetch = true; + } this.fetchLogs(); var self = this; diff --git a/app/views/shared/vue/_fluent_log.html.erb b/app/views/shared/vue/_fluent_log.html.erb index f667498..86a1145 100644 --- a/app/views/shared/vue/_fluent_log.html.erb +++ b/app/views/shared/vue/_fluent_log.html.erb @@ -1,5 +1,6 @@ -
+<% auto_reload ||= false %> +
">