heroku errors for api

This commit is contained in:
walkews 2017-07-12 09:22:54 -05:00
parent 81e294f489
commit 01b4b766df
9 changed files with 129 additions and 54 deletions

View file

@ -23,35 +23,3 @@
</div>
</div>
<div id='word_cloud'></div>
<script type="text/javascript">
jQuery(document).ready(function(){
jQuery(".chosen").chosen();
update_words()
});
$('#top').change(function(){update_words()})
function update_words(){
var top = $('#top').val()
//+ '&language=' + language + '&country=' + country + '&genre=' + genre + '&end_year=' + end_year + ' &start_year=' + start_year
var words = $.get('http://localhost:5000/api/keywords?top=' + top)
words.done(function(data){
$('#word_cloud').html('')
$('#word_cloud').jQCloud(words.responseJSON, {
width: 500,
height: 350,
classPattern: null,
colors: ['#800026', '#bd0026', '#e31a1c', '#fc4e2a', '#fd8d3c', '#feb24c', '#fed976', '#ffeda0', '#ffffcc'],
fontSize: {
from: 0.1,
to: 0.02
}
});
})
}
</script>

View file

@ -3,14 +3,22 @@
{% block title %}enthusiast{% endblock %}
{% block head %}
{{ super() }}
<!-- Load d3.js and c3.js -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jqcloud/1.0.4/jqcloud.css">
<script src='http://d3js.org/d3.v3.min.js' charset='utf-8'></script>
<script src='http://cdnjs.cloudflare.com/ajax/libs/c3/0.4.10/c3.min.js'></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<link rel="stylesheet" href="static/node_modules/chosen-js/chosen.css">
<script src="static/node_modules/chosen-js/chosen.jquery.js"></script>
<script src='https://cdnjs.cloudflare.com/ajax/libs/jqcloud/1.0.4/jqcloud-1.0.4.min.js'></script>
<link rel='stylesheet' type='text/css' href='static/css/custom.css'>
<!-- Load d3.js and c3.js -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jqcloud/1.0.4/jqcloud.css">
<script src='http://d3js.org/d3.v3.min.js' charset='utf-8'></script>
<script src='http://cdnjs.cloudflare.com/ajax/libs/c3/0.4.10/c3.min.js'></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<link rel="stylesheet" href="static/node_modules/chosen-js/chosen.css">
<script src="static/node_modules/chosen-js/chosen.jquery.js"></script>
<script src='https://cdnjs.cloudflare.com/ajax/libs/jqcloud/1.0.4/jqcloud-1.0.4.min.js'></script>
<link rel='stylesheet' type='text/css' href='static/css/custom.css'>
{% endblock %}
{% block body %}
{{ super ()}}
{{ form | safe }}
<div id='word_cloud'></div>
<script src='static/js/enthusiast.js'></script>
{% endblock %}

View file

@ -12,4 +12,8 @@
<script src="static/node_modules/chosen-js/chosen.jquery.js"></script>
<script src='https://cdnjs.cloudflare.com/ajax/libs/jqcloud/1.0.4/jqcloud-1.0.4.min.js'></script>
<link rel='stylesheet' type='text/css' href='static/css/custom.css/'>
{% endblock %}
{% block body %}
{{ super ()}}
{% endblock %}

View file

@ -12,11 +12,12 @@
<link href='https://cdnjs.cloudflare.com/ajax/libs/c3/0.4.10/c3.min.css' rel='stylesheet' type='text/css'/>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<link rel='stylesheet' type='text/css' href='static/css/custom.css'>
{% endblock %}
</head>
<body>
{% block body %}
{% set navigation_bar = [
('/investor', 'investor', 'Investor'),
@ -44,6 +45,6 @@
</nav>
{{ body | safe }}
{% endblock %}
</body>
</html>