Skip to content

Commit

Permalink
Open company links in a new window or tab.
Browse files Browse the repository at this point in the history
  • Loading branch information
jace committed Jun 8, 2011
1 parent 722736b commit a92a6b0
Showing 1 changed file with 57 additions and 0 deletions.
57 changes: 57 additions & 0 deletions templates/stats.html
@@ -0,0 +1,57 @@
{% extends "inc/layout.html" %}
{% from "inc/forms.html" import renderfield %}
{% block title %}Job listing statistics{% endblock %}
{% block content %}
<div id="sheet">
<div class="section first">
<h1>
{{ self.title()|e }}
</h1>
<p class="caption">
Nice charts on jobs listed on this site.
</p>
</div>
<div class="section">
<h2>Listings by date</h2>
<div class="chart" id="listings-by-date" style="height: 300px">
</div>
</div>
<div class="section">
<h2>Listings by type</h2>
<div class="chart" id="listings-by-type" style="height: 300px">
</div>
</div>
</div>
{% endblock %}
{% block footerscripts %}
<script type="text/javascript" src="{{ url_for('static', filename='js/libs/jquery.flot.min.js') }}"></script>
<script type="text/javascript">
$(function () {

var onListingsByDate = function (source) {
$.plot($("#listings-by-date"), source.data, source.options);
};

$.ajax({
url: '{{url_for("stats_listings_by_date") }}',
method: 'GET',
dataType: 'json',
success: onListingsByDate
});

var onListingsByType = function (source) {
console.log(source.data);
$.plot($("#listings-by-type"), source.data, source.options);
};

$.ajax({
url: '{{url_for("stats_listings_by_type") }}',
method: 'GET',
dataType: 'json',
success: onListingsByType
});

});
</script>

{% endblock %}

0 comments on commit a92a6b0

Please sign in to comment.