euscanwww: big commit

- fix commands
- import DataTables
- initial category view

Signed-off-by: Corentin Chary <corentincj@iksaif.net>
This commit is contained in:
Corentin Chary
2011-04-14 19:28:38 +02:00
parent a2cd1f48bc
commit 25964491dd
30 changed files with 7841 additions and 47 deletions

View File

@ -4,7 +4,7 @@
<title>{% block title %}euscan{% endblock %}</title>
<meta http-equiv="Content-Type" content="text/html" charset="utf-8" />
{% block css %}
<link rel="stylesheet" type="text/css" href="{{MEDIA_ROOT}}img/style.css" media="screen" title="Normal" />
<link rel="stylesheet" type="text/css" href="{{MEDIA_URL}}img/style.css" media="screen" title="Normal" />
{% endblock %}
{% block javascript %}
{% endblock %}
@ -31,10 +31,10 @@
<div id="footer">
Powered by:
<a href="http://kernel.org" titke="Linux Kernel">
<img src="{{MEDIA_ROOT}}img/linux.png" alt="Linux" />
<img src="{{MEDIA_URL}}img/linux.png" alt="Linux" />
</a>
<a href="http://gentoo.org" title="Gentoo">
<img src="{{MEDIA_ROOT}}img/gentoo.png" alt="Gentoo Linux" />
<img src="{{MEDIA_URL}}img/gentoo.png" alt="Gentoo Linux" />
</a>
-
Copyright (C) 2011 <strong>Corentin Chary</strong>

View File

@ -0,0 +1,21 @@
{% extends "_base.html" %}
{% block css %}
{{ block.super }}
<link rel="stylesheet" type="text/css" href="{{MEDIA_URL}}css/table.css" media="screen" title="Normal" />
{% endblock %}
{% block javascript %}
{{ block.super }}
<script type="text/javascript" language="javascript" src="{{MEDIA_URL}}js/jquery.js"></script>
<script type="text/javascript" language="javascript" src="{{MEDIA_URL}}js/jquery.dataTables.js"></script>
<script type="text/javascript" charset="utf-8">
$(document).ready(function() {
$('#table').dataTable( {
"bPaginate": false,
"bInfo": false,
} );
});
</script>
{% endblock %}

View File

@ -0,0 +1,21 @@
{% extends "euscan/_datatable.html" %}
{% load sub %}
{% block content %}
<h2>Categories</h2>
<table id="table">
<thead>
<th>Category</th>
<th>Ebuilds</th>
<th>Unpackaged</th>
</thead>
{% for category in categories %}
<tr>
<td>{{ category.category }}</td>
<td>{{ category.n_packaged }}</td>
<td>{{ category.n_versions|sub:category.n_packaged }}</td>
</tr>
{% endfor %}
</table>
{% endblock %}

View File

@ -1,5 +1,15 @@
{% extends "_base.html" %}
{% block content %}
Hello world !
<h2>What's euscan ?</h2>
<p>blabla</p>
<h2>Statistics</h2>
<ul>
<li>Packages: {{ n_packages }}</li>
<li>Versions: {{ n_packaged }}</li>
<li>Versions not-packaged: {{ n_upstream }}</li>
<li>Herds: {{ n_herds }}</li>
<li>Maintainer: {{ n_maintainers }}</li>
<li>Last scan: {{ last_scan }}</li>
</ul>
{% endblock %}