update_ts() function now flows data to the score_timeseries chart when the chart is ready. Prior this was causing formatting/zoom issues

This commit is contained in:
Walker Waylon Scott 2017-07-13 13:06:45 -05:00
parent 951eadd5cd
commit 04e8135cf0

View file

@ -138,18 +138,22 @@ function url_params(base)
} }
function update_ts() function update_ts()
{
score_timeseries.flow({'done': load_ts()})
}
function load_ts()
{ {
url = url_params('/api/score_timeseries?') url = url_params('/api/score_timeseries?')
score_timeseries.unload()
var updatedData = $.get(url); var updatedData = $.get(url);
updatedData.done(function(results) updatedData.done(function(results)
{ {
score_timeseries.load(updatedData.responseJSON) score_timeseries.load(updatedData.responseJSON)
}); })
} }
function update_words() function update_words()
{ {
url = url_params('/api/keywords?') url = url_params('/api/keywords?')