diff options
author | eliott <eliott@cactuswax.net> | 2008-03-23 03:51:01 +0100 |
---|---|---|
committer | eliott <eliott@cactuswax.net> | 2008-03-23 03:51:01 +0100 |
commit | 7640082d14af2827ab22caa6dce3575f5112d7cf (patch) | |
tree | 6fb40e5c0dc734f5646166708b1e39ab5c30859d /templates | |
parent | 37361f664f5092d5f4cc7bb2a20e1e86cbbf558d (diff) | |
download | archweb-7640082d14af2827ab22caa6dce3575f5112d7cf.tar.gz archweb-7640082d14af2827ab22caa6dce3575f5112d7cf.tar.xz |
Refactored the model to remove arch and repo tables.
Refactored the model to remove the arch and repo tables. Those data points
are now encapsulated in the package table as an ENUM field.
Changes to models and templates as needed.
Diffstat (limited to 'templates')
-rw-r--r-- | templates/devel/siteindex.html | 4 | ||||
-rw-r--r-- | templates/packages/details.html | 8 | ||||
-rw-r--r-- | templates/packages/search.html | 10 |
3 files changed, 10 insertions, 12 deletions
diff --git a/templates/devel/siteindex.html b/templates/devel/siteindex.html index 3cbf08a..9747470 100644 --- a/templates/devel/siteindex.html +++ b/templates/devel/siteindex.html @@ -107,8 +107,8 @@ <table id="repolinks"> {% for repo in repos %} <tr> - <th><a href="/packages/?repo={{ repo.name }}">{{ repo.name }}</a></th> - <td>{{ repo.last_update|date:"Y-m-d H:i" }}</td> + <th><a href="/packages/?repo={{ repo }}">{{ repo }}</a></th> + <td>{{ repo }}</td> </tr> {% endfor %} </table> diff --git a/templates/packages/details.html b/templates/packages/details.html index 1435557..873609e 100644 --- a/templates/packages/details.html +++ b/templates/packages/details.html @@ -33,10 +33,10 @@ <table class="listing"> <tr> <th>Architecture:</th> - <td>{{ pkg.arch.name }}</td> + <td>{{ pkg.get_arch_display }}</td> </tr><tr> <th>Repository:</th> - <td>{{ pkg.repo.name }}</td> + <td>{{ pkg.get_repo_display|capfirst }}</td> </tr><tr> <th>Description:</th> <td>{{ pkg.pkgdesc }}</td> @@ -54,7 +54,7 @@ <br /> <table width="100%"> <tr> - <td valign="top"> + <td valign="top" width="50%"> <div class="listing"> <h4>Dependencies:</h4> <ul style="font-size:small;list-style:none"> @@ -62,8 +62,6 @@ </ul> </div> </td> - </tr> - <tr> <td valign="top"> <div class="listing"> <h4>Required By:</h4> diff --git a/templates/packages/search.html b/templates/packages/search.html index 309f926..1e8d265 100644 --- a/templates/packages/search.html +++ b/templates/packages/search.html @@ -26,15 +26,15 @@ <td> <select name="arch"> <option value="all">All</option> - {% for a in archs %} - <option value="{{ a.arch }}"{% ifequal arch a.name %} selected{% endifequal %}>{{ a.name }}</option> + {% for a in arches %} + <option value="{{ a }}"{% ifequal arch a %} selected{% endifequal %}>{{ a }}</option> {% endfor %} </select> </td><td> <select name="repo"> <option value="all">All</option> {% for r in repos %} - <option value="{{ r.name }}"{% ifequal repo r.name %} selected{% endifequal %}>{{ r.name|capfirst }}</option> + <option value="{{ r }}"{% ifequal repo r %} selected{% endifequal %}>{{ r|capfirst }}</option> {% endfor %} </select> </td><td> @@ -87,8 +87,8 @@ {% if not user.is_anonymous %} <td><input type="checkbox" name="pkgid" value="{{ pkg.id }}" /></td> {% endif %} - <td>{{ pkg.arch.name }}</td> - <td>{{ pkg.repo.name }}</td> + <td>{{ pkg.get_arch_display }}</td> + <td>{{ pkg.get_repo_display|capfirst }}</td> <td><a href="{{ pkg.get_absolute_url }}">{{ pkg.pkgname }}</a></td> {% if pkg.needupdate %} <td><span style="color:red">{{ pkg.pkgver }}-{{ pkg.pkgrel }}</span></td> |