{% extends "layout.jinja2" %}

{% block content %}

<div class="content">
    <a href="/cards/{{date}}/{{datepage}}"><span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span> BACK</a>
    <h1>{{card.timestamp | datetime('long')}}</h1>

    <canvas id="surfacecard" height="120"></canvas>
    <canvas id="downholecard" height="120"></canvas>

</div>

<script>
    var urlparts = decodeURIComponent(window.location).split("/").slice(3)
    var cardID = parseInt(urlparts[2]);

    $.ajax({
        dataType: 'json',
        url:"/json/card/view/" + cardID,
        success: drawCards
    });
</script>
{% endblock content %}
