public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/tinderbox-cluster-www:master commit in: python/templates/pages/packages/ebuilds/, python/tbc_www/
@ 2015-07-22 13:39 Magnus Granberg
  0 siblings, 0 replies; only message in thread
From: Magnus Granberg @ 2015-07-22 13:39 UTC (permalink / raw
  To: gentoo-commits

commit:     539bfb87b96725eb415f6b8afb5262b87b8828d7
Author:     Magnus Granberg <zorry <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 22 13:38:20 2015 +0000
Commit:     Magnus Granberg <zorry <AT> gentoo <DOT> org>
CommitDate: Wed Jul 22 13:38:20 2015 +0000
URL:        https://gitweb.gentoo.org/proj/tinderbox-cluster-www.git/commit/?id=539bfb87

include all repos in packages

 python/tbc_www/views.py                            | 10 ++++++----
 python/templates/pages/packages/ebuilds/index.html | 16 ++++++++--------
 2 files changed, 14 insertions(+), 12 deletions(-)

diff --git a/python/tbc_www/views.py b/python/tbc_www/views.py
index 252998e..a025cbf 100644
--- a/python/tbc_www/views.py
+++ b/python/tbc_www/views.py
@@ -95,8 +95,8 @@ def packages(request, category_id):
 		adict['Descriptions'] = PM.Descriptions
 		adict['Changlog'] =PM.Changlog
 		ebuilds = []
-		for E in Ebuilds.objects.filter(Active = True).filter(PackageId_id = PM.PackageId.PackageId):
-			ebuilds.append(E.Version + '::' + E.PackageId.RepoId.Repo + '\n')
+		for E in Ebuilds.objects.filter(Active = True).filter(PackageId__Package = PM.PackageId.Package):
+			ebuilds.append(E.Version + '::' +  E.PackageId.RepoId.Repo + '\n')
 		adict['Ebuilds'] = ebuilds
 		adict2[PM.PackageId.Package] = adict
 	TmpDict['PM_tmp'] = adict2
@@ -106,8 +106,10 @@ def packages(request, category_id):
 def ebuilds(request, package_id):
 	pagerequest = 'packages'
 	TmpDict = default_TmpDict(pagerequest)
-	TmpDict['EB_tmp'] = Ebuilds.objects.filter(PackageId_id = package_id)
-	TmpDict['P'] = get_object_or_404(Packages,  PackageId = package_id)
+	P = get_object_or_404(Packages,  PackageId = package_id)
+	TmpDict['P'] = P
+	TmpDict['EM_tmp'] = EbuildsMetadata.objects.filter(EbuildId__Active = True).filter(EbuildId__PackageId__Package = P.Package)
+	print(TmpDict)
 	return render(request, 'pages/' + pagerequest + '/ebuilds/index.html', TmpDict)
 
 def new(request):

diff --git a/python/templates/pages/packages/ebuilds/index.html b/python/templates/pages/packages/ebuilds/index.html
index a5ed0d6..73f45f2 100644
--- a/python/templates/pages/packages/ebuilds/index.html
+++ b/python/templates/pages/packages/ebuilds/index.html
@@ -4,14 +4,14 @@
   <div class="col-xs-12 col-md-6">
     <h2>{{ P.CategoryId.Category }}/{{ P.Package }}</h2>
     <table class="table table-striped frontpage-table">
-  {% for E in EB_tmp %}
-    <tr>
-      <td class="frontpage-table-package-atom">
-          <a href="/ebuild/{{ E.EbuildId }}/" title="{{ P.CategoryId.Category }}/{{ P.Package }}-{{ E.Version }}::{{ E.PackageId.RepoId.Repo }}">{{ P.Package }}-{{ E.Version }}::{{ E.PackageId.RepoId.Repo }}</a></td>
-        <td><p></p></td>
-    </tr>
-  {% endfor %}
-</table>
+      {% for E in EM_tmp %}
+        <tr>
+          <td class="frontpage-table-package-atom">
+            <a href="/ebuild/{{ E.EbuildId.EbuildId }}/" title="{{ P.CategoryId.Category }}/{{ P.Package }}-{{ E.EbuildId.Version }}::{{ E.EbuildId.PackageId.RepoId.Repo }}">{{ P.Package }}-{{ E.EbuildId.Version }}::{{ E.EbuildId.PackageId.RepoId.Repo }}</a></td>
+          <td><p></p></td>
+        </tr>
+      {% endfor %}
+    </table>
   </div>
 </div>
 {% endblock %}
\ No newline at end of file


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2015-07-22 13:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-22 13:39 [gentoo-commits] proj/tinderbox-cluster-www:master commit in: python/templates/pages/packages/ebuilds/, python/tbc_www/ Magnus Granberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox