From 315ae8de9631c40bd488563d824203d8e6b20d6e Mon Sep 17 00:00:00 2001 From: randomdan Date: Tue, 14 Dec 2010 00:20:38 +0000 Subject: All new fangled iterators, views, row engines, exceptions, the list goes on Includes site and console updates to match --- gentoobrowse/checks/loggedIn.xml | 2 +- gentoobrowse/console/bugimport.xml | 20 +- gentoobrowse/console/emailebuilds.xml | 8 +- gentoobrowse/console/fileimport.xml | 73 ++++--- gentoobrowse/emails/newpackageversions.xml | 10 +- gentoobrowse/emails/newpackageversions.xslt | 5 +- gentoobrowse/emails/welcome.xml | 12 +- gentoobrowse/present/accountHome.xml | 4 +- gentoobrowse/present/accountTracked.xml | 22 +- gentoobrowse/present/atom.xml | 8 +- gentoobrowse/present/categories.xml | 4 +- gentoobrowse/present/category.xml | 8 +- gentoobrowse/present/confirm.xml | 4 +- gentoobrowse/present/index.xml | 14 +- gentoobrowse/present/login.xml | 2 +- gentoobrowse/present/package.xml | 70 ++++++- gentoobrowse/present/popular.xml | 4 +- gentoobrowse/present/search.xml | 11 +- gentoobrowse/present/signup.xml | 2 +- gentoobrowse/request/doconfirm.xml | 18 +- gentoobrowse/request/dologin.xml | 18 +- gentoobrowse/request/dosignup.xml | 12 +- gentoobrowse/request/track.xml | 8 +- gentoobrowse/request/untrack.xml | 4 +- gentoobrowse/search.xslt | 4 +- gentoobrowse/views/categories.xml | 4 +- gentoobrowse/views/category.xml | 10 +- gentoobrowse/views/newebuilds.xml | 23 +- gentoobrowse/views/newebuildsatom.xml | 9 +- gentoobrowse/views/package.xml | 312 +++++++++++++--------------- gentoobrowse/views/popular.xml | 8 +- gentoobrowse/views/search.xml | 25 +-- gentoobrowse/views/tracked.xml | 21 ++ gentoobrowse/views/user.xml | 14 ++ 34 files changed, 445 insertions(+), 328 deletions(-) create mode 100644 gentoobrowse/views/tracked.xml create mode 100644 gentoobrowse/views/user.xml diff --git a/gentoobrowse/checks/loggedIn.xml b/gentoobrowse/checks/loggedIn.xml index 7e83515..0b120c2 100644 --- a/gentoobrowse/checks/loggedIn.xml +++ b/gentoobrowse/checks/loggedIn.xml @@ -1,6 +1,6 @@ - . + [1-9][0-9]* Not logged in diff --git a/gentoobrowse/console/bugimport.xml b/gentoobrowse/console/bugimport.xml index 090caba..738a62f 100644 --- a/gentoobrowse/console/bugimport.xml +++ b/gentoobrowse/console/bugimport.xml @@ -2,15 +2,19 @@ + + + + - - - - + + + + bugid severity diff --git a/gentoobrowse/console/emailebuilds.xml b/gentoobrowse/console/emailebuilds.xml index 7df144f..051b78c 100644 --- a/gentoobrowse/console/emailebuilds.xml +++ b/gentoobrowse/console/emailebuilds.xml @@ -2,7 +2,7 @@ - + select ut.userid, ut.useremail from (select e.ebuildid, u.userid, u.useremail @@ -14,6 +14,8 @@ where ebe.userid is null group by ut.userid, ut.useremail + + @@ -31,10 +33,10 @@ where ebe.userid is null - + - + diff --git a/gentoobrowse/console/fileimport.xml b/gentoobrowse/console/fileimport.xml index 5d326e9..b65573f 100644 --- a/gentoobrowse/console/fileimport.xml +++ b/gentoobrowse/console/fileimport.xml @@ -2,22 +2,26 @@ + + + SELECT filetypeid, searchroot, LENGTH(searchroot) + 1 || '-' AS rootlen, searchspec + FROM filetypes + ORDER BY filetypeid DESC + + + + + filetypeid + filename + moddate + + + - - - SELECT filetypeid, searchroot, LENGTH(searchroot) + 1 || '-' AS rootlen, searchspec - FROM filetypes - ORDER BY filetypeid DESC - - - - filetypeid - filename - moddate - - - + + + filename moddate @@ -25,31 +29,36 @@ + + + SELECT f.fileid, ft.searchroot || f.filename AS filename, f.cachedat, f.moddate + FROM files f, filetypes ft + WHERE (f.cachedat IS NULL OR f.cachedat != f.moddate) + AND f.filetypeid = ft.filetypeid + ORDER BY f.fileid + + + + + fileid + line + content + + + - - - SELECT f.fileid, ft.searchroot || f.filename AS filename, f.cachedat, f.moddate - FROM files f, filetypes ft - WHERE (f.cachedat IS NULL OR f.cachedat != f.moddate) - AND f.filetypeid = ft.filetypeid - ORDER BY f.fileid; - - - - fileid - line - content - - - + + + fileid line content + UPDATE files SET cachedat = moddate WHERE cachedat != moddate OR cachedat IS NULL diff --git a/gentoobrowse/emails/newpackageversions.xml b/gentoobrowse/emails/newpackageversions.xml index f65a2de..45bba93 100644 --- a/gentoobrowse/emails/newpackageversions.xml +++ b/gentoobrowse/emails/newpackageversions.xml @@ -2,7 +2,7 @@ - + select ut.cname, ut.pname, ut.version from ( @@ -10,7 +10,7 @@ from ebuilds e, user_packages up, users u, packages p, categories c where e.packageid = up.packageid and u.userid = up.userid - and u.userid = ? + and u.userid = and e.packageid = p.packageid and c.categoryid = p.categoryid and e.firstseen > up.trackedsince) as ut left outer join user_ebuild_emails ebe @@ -18,9 +18,11 @@ where ebe.userid is null order by ut.cname, ut.pname, ut.version + + - + - + diff --git a/gentoobrowse/emails/newpackageversions.xslt b/gentoobrowse/emails/newpackageversions.xslt index 67301db..e5e23be 100644 --- a/gentoobrowse/emails/newpackageversions.xslt +++ b/gentoobrowse/emails/newpackageversions.xslt @@ -14,7 +14,10 @@ diff --git a/gentoobrowse/emails/welcome.xml b/gentoobrowse/emails/welcome.xml index 09d2c3d..ad48f66 100644 --- a/gentoobrowse/emails/welcome.xml +++ b/gentoobrowse/emails/welcome.xml @@ -1,16 +1,18 @@ - - + + SELECT userid, CAST(verifyguid AS TEXT) AS guid FROM users u - WHERE useremail = ? + WHERE useremail = AND verifyguid IS NOT NULL + + - + - + diff --git a/gentoobrowse/present/accountHome.xml b/gentoobrowse/present/accountHome.xml index 6ceda4c..f725272 100644 --- a/gentoobrowse/present/accountHome.xml +++ b/gentoobrowse/present/accountHome.xml @@ -1,10 +1,10 @@ -
-

View my tracked packages.

+

View my tracked packages

diff --git a/gentoobrowse/present/accountTracked.xml b/gentoobrowse/present/accountTracked.xml index 590a8db..5dded3f 100644 --- a/gentoobrowse/present/accountTracked.xml +++ b/gentoobrowse/present/accountTracked.xml @@ -1,26 +1,14 @@ - - - - SELECT c.name AS catname, p.name AS pkgname, ( - SELECT e.version - FROM ebuilds e - WHERE e.packageid = p.packageid - ORDER BY e.versioninst - DESC LIMIT 1) AS latestversion - FROM user_packages up, packages p, categories c - WHERE up.packageid = p.packageid - AND c.categoryid = p.categoryid - AND up.userid = ? - ORDER BY c.name, p.name - + + - + - + diff --git a/gentoobrowse/present/atom.xml b/gentoobrowse/present/atom.xml index 72c1695..ecbb0b5 100644 --- a/gentoobrowse/present/atom.xml +++ b/gentoobrowse/present/atom.xml @@ -1,4 +1,10 @@ - + + + + + + diff --git a/gentoobrowse/present/categories.xml b/gentoobrowse/present/categories.xml index 4a6d3dc..aa63a6c 100644 --- a/gentoobrowse/present/categories.xml +++ b/gentoobrowse/present/categories.xml @@ -1,4 +1,6 @@ - + + diff --git a/gentoobrowse/present/category.xml b/gentoobrowse/present/category.xml index 8f0f031..6de3875 100644 --- a/gentoobrowse/present/category.xml +++ b/gentoobrowse/present/category.xml @@ -1,4 +1,10 @@ - + + + + + + diff --git a/gentoobrowse/present/confirm.xml b/gentoobrowse/present/confirm.xml index cdadf68..adf62a7 100644 --- a/gentoobrowse/present/confirm.xml +++ b/gentoobrowse/present/confirm.xml @@ -1,11 +1,11 @@ -

Please enter the confirmation code from your welcome email.

+ xslvalue="/gentoo/project2:params/project2:param[@name='verifyguid']/@value" />
diff --git a/gentoobrowse/present/index.xml b/gentoobrowse/present/index.xml index 15dacee..4fa7946 100644 --- a/gentoobrowse/present/index.xml +++ b/gentoobrowse/present/index.xml @@ -1,4 +1,16 @@ - + + + + + + + + + + + + diff --git a/gentoobrowse/present/login.xml b/gentoobrowse/present/login.xml index 1bab32a..b21689f 100644 --- a/gentoobrowse/present/login.xml +++ b/gentoobrowse/present/login.xml @@ -1,5 +1,5 @@ -
diff --git a/gentoobrowse/present/package.xml b/gentoobrowse/present/package.xml index 9abb818..0b93d04 100644 --- a/gentoobrowse/present/package.xml +++ b/gentoobrowse/present/package.xml @@ -1,4 +1,72 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/gentoobrowse/present/popular.xml b/gentoobrowse/present/popular.xml index 8f89d1a..1ca9850 100644 --- a/gentoobrowse/present/popular.xml +++ b/gentoobrowse/present/popular.xml @@ -1,4 +1,6 @@ - + + diff --git a/gentoobrowse/present/search.xml b/gentoobrowse/present/search.xml index 0c61f35..60610df 100644 --- a/gentoobrowse/present/search.xml +++ b/gentoobrowse/present/search.xml @@ -1,11 +1,16 @@ - + + xslvalue="/gentoo/project2:params/project2:param[@name='criteria']/@value" /> - + + + + + diff --git a/gentoobrowse/present/signup.xml b/gentoobrowse/present/signup.xml index 9e74e3f..44640ce 100644 --- a/gentoobrowse/present/signup.xml +++ b/gentoobrowse/present/signup.xml @@ -1,5 +1,5 @@ -
diff --git a/gentoobrowse/request/doconfirm.xml b/gentoobrowse/request/doconfirm.xml index 71f5d34..9b2b0e5 100644 --- a/gentoobrowse/request/doconfirm.xml +++ b/gentoobrowse/request/doconfirm.xml @@ -2,34 +2,30 @@ + - Invalid username or password + No such pending account SELECT COUNT(*) FROM users WHERE verifyguid = ? - + - - - SELECT userid - FROM users - WHERE verifyguid = ? - + - + - + UPDATE users SET verifyguid = NULL WHERE verifyguid = ? - + diff --git a/gentoobrowse/request/dologin.xml b/gentoobrowse/request/dologin.xml index 672050d..9e1bc19 100644 --- a/gentoobrowse/request/dologin.xml +++ b/gentoobrowse/request/dologin.xml @@ -2,6 +2,7 @@ + .+ User name required @@ -19,8 +20,8 @@ AND userpassword = ? - - + + @@ -32,21 +33,16 @@ AND verifyguid IS NULL - + - - - SELECT userid - FROM users - WHERE username = ? - + - + - + diff --git a/gentoobrowse/request/dosignup.xml b/gentoobrowse/request/dosignup.xml index d1fbe2e..386b585 100644 --- a/gentoobrowse/request/dosignup.xml +++ b/gentoobrowse/request/dosignup.xml @@ -18,7 +18,7 @@ WHERE username = ? - + @@ -29,17 +29,17 @@ WHERE useremail = ? - + INSERT INTO users(username, userrealname, userpassword, useremail, verifyguid) VALUES(?, ?, ?, ?, uuid_generate_v4()) - - - - + + + + - - + + INSERT INTO user_packages(packageid, userid, trackedsince) VALUES(?, ?, NOW()) - - + + diff --git a/gentoobrowse/request/untrack.xml b/gentoobrowse/request/untrack.xml index 4394278..88bcdf9 100644 --- a/gentoobrowse/request/untrack.xml +++ b/gentoobrowse/request/untrack.xml @@ -9,8 +9,8 @@ AND userid = ? - - + + diff --git a/gentoobrowse/search.xslt b/gentoobrowse/search.xslt index 362a827..063c0b7 100644 --- a/gentoobrowse/search.xslt +++ b/gentoobrowse/search.xslt @@ -11,9 +11,9 @@ - + -

Search Results for ""

+

Search Results for ""

diff --git a/gentoobrowse/views/categories.xml b/gentoobrowse/views/categories.xml index 9e05f71..15b74a1 100644 --- a/gentoobrowse/views/categories.xml +++ b/gentoobrowse/views/categories.xml @@ -2,7 +2,7 @@ - + SELECT c.categoryid, MIN(c.name) AS catname, COUNT(*) AS packages FROM categories c, packages p @@ -10,5 +10,5 @@ GROUP BY c.categoryid ORDER BY MIN(c.name) - + diff --git a/gentoobrowse/views/category.xml b/gentoobrowse/views/category.xml index cb810a9..ebb4470 100644 --- a/gentoobrowse/views/category.xml +++ b/gentoobrowse/views/category.xml @@ -2,16 +2,14 @@ - + SELECT c.name AS catname, p.name AS pkgname, p.description FROM categories c, packages p WHERE c.categoryid = p.categoryid - AND c.name = ? + AND c.name = + AND c.categoryid = ORDER BY p.name - - - - + diff --git a/gentoobrowse/views/newebuilds.xml b/gentoobrowse/views/newebuilds.xml index 9a4cbf3..2fc10c4 100644 --- a/gentoobrowse/views/newebuilds.xml +++ b/gentoobrowse/views/newebuilds.xml @@ -1,32 +1,29 @@ - + SELECT description, moddate, p.name AS pkgname, c.name AS catname, e.version, e.firstseen sync, up.trackedsince IS NOT NULL AS tracked FROM ebuilds e, categories c, packages p LEFT OUTER JOIN user_packages up - ON up.userid = ? + ON up.userid = AND up.packageid = p.packageid WHERE e.packageid = p.packageid AND p.categoryid = c.categoryid - AND e.firstseen IN ( + AND e.firstseen IN ( SELECT DISTINCT e.firstseen FROM ebuilds e - ORDER BY e.firstseen - DESC LIMIT 3) + ORDER BY e.firstseen DESC + LIMIT ) ORDER BY tracked DESC, c.name, p.name, e.versioninst - - - - - + + SELECT DISTINCT e.firstseen AS synctime FROM ebuilds e - ORDER BY e.firstseen - DESC LIMIT 3 + ORDER BY e.firstseen DESC + LIMIT - + diff --git a/gentoobrowse/views/newebuildsatom.xml b/gentoobrowse/views/newebuildsatom.xml index 76cc414..d229b45 100644 --- a/gentoobrowse/views/newebuildsatom.xml +++ b/gentoobrowse/views/newebuildsatom.xml @@ -1,22 +1,19 @@ - + SELECT version, description, moddate, p.name AS pkgname, c.name AS catname, e.firstseen sync FROM ebuilds e, categories c, packages p, user_packages up, users u WHERE e.packageid = p.packageid AND p.categoryid = c.categoryid AND up.userid = u.userid - AND u.username = ? + AND u.username = AND up.packageid = p.packageid AND e.firstseen >= up.trackedsince ORDER BY e.firstseen DESC, c.name, p.name, e.versioninst LIMIT 50 - - - - + diff --git a/gentoobrowse/views/package.xml b/gentoobrowse/views/package.xml index 2e18435..e4797e9 100644 --- a/gentoobrowse/views/package.xml +++ b/gentoobrowse/views/package.xml @@ -2,171 +2,157 @@ - + SELECT p.packageid, p.name AS pkgname, p.description, p.firstseen, c.name AS catname FROM packages p, categories c - WHERE c.name = ? - AND p.name = ? - AND p.categoryid = c.categoryid + WHERE p.categoryid = c.categoryid + + AND c.name = + AND p.name = + - - - - - - - SELECT trackedsince - FROM user_packages up - WHERE up.packageid = ? - AND up.userid = ? - - - - - - - - - SELECT e.ebuildid, e.version, e.moddate, e.slot, e.license - FROM ebuilds e - WHERE e.packageid = ? - ORDER BY versioninst desc - - - - - - - - SELECT pu.url - FROM package_urls pu - WHERE pu.packageid = ? - ORDER BY pu.url - - - - - - - - SELECT u.* - FROM ebuilds e, ebuild_uses u - WHERE e.packageid = ? - AND e.ebuildid = u.ebuildid - ORDER BY version - - - - - - - - SELECT a.* - FROM ebuilds e, ebuild_archs a - WHERE e.packageid = ? - AND e.ebuildid = a.ebuildid - ORDER BY version - - - - - - - - SELECT b.bugid, b.summary - FROM bugs b, package_bugs pb - WHERE b.bugid = pb.bugid - AND pb.packageid = ? - ORDER BY b.bugid - - - - - - - - SELECT DISTINCT cd.name AS catname, pd.name AS pkgname, pd.description - FROM ebuilds e, ebuild_deps d, packages pd, categories cd - WHERE e.packageid = ? - AND d.ebuildid = e.ebuildid - AND pd.packageid = d.packageid - AND pd.categoryid = cd.categoryid - ORDER BY cd.name, pd.name - - - - - - - - SELECT DISTINCT cd.name AS catname, pd.name AS pkgname, pd.description - FROM ebuilds e, ebuild_rdeps d, packages pd, categories cd - WHERE e.packageid = ? - AND d.ebuildid = e.ebuildid - AND pd.packageid = d.packageid - AND pd.categoryid = cd.categoryid - ORDER BY cd.name, pd.name - - - - - - - - SELECT DISTINCT cd.name AS catname, pd.name AS pkgname, pd.description - FROM ebuilds e, ( - SELECT ebuildid - FROM ebuild_rdeps d - WHERE d.packageid = ? - UNION - SELECT ebuildid - FROM ebuild_deps d - WHERE d.packageid = ?) d, packages pd, categories cd - WHERE d.ebuildid = e.ebuildid - AND pd.packageid = e.packageid - AND pd.categoryid = cd.categoryid - ORDER BY cd.name, pd.name - - - - - - - - - SELECT em.ebuildid, DENSE_RANK() OVER(ORDER BY em.setno) AS setno - FROM ebuild_masks em, ebuilds e - WHERE em.ebuildid = e.ebuildid - AND e.packageid = ? - - - - - - - - SELECT DISTINCT DENSE_RANK() OVER(ORDER BY em.setno), ms.person, ms.message, ms.dateadded - FROM ebuild_masks em, ebuilds e, masksets ms - WHERE em.ebuildid = e.ebuildid - AND ms.setno = em.setno - AND e.packageid = ? - ORDER BY DENSE_RANK() OVER(ORDER BY em.setno) - - - - - - - - SELECT date, person, email, comment - FROM package_changelogs - WHERE packageid = ? - ORDER BY date DESC, n - - - - - - + + + + SELECT up.packageid, up.trackedsince, up.userid + FROM user_packages up + + WHERE up.packageid = + AND up.userid = + + + + + + SELECT e.ebuildid, e.version, e.moddate, e.slot, e.license + FROM ebuilds e + + WHERE e.packageid = + + ORDER BY versioninst desc + + + + + SELECT pu.url + FROM package_urls pu + + WHERE pu.packageid = + + ORDER BY pu.url + + + + + SELECT u.* + FROM ebuilds e, ebuild_uses u + WHERE e.ebuildid = u.ebuildid + + AND e.packageid = + + ORDER BY version + + + + + SELECT a.* + FROM ebuilds e, ebuild_archs a + WHERE e.ebuildid = a.ebuildid + + AND e.packageid = + + ORDER BY version + + + + + SELECT b.bugid, b.summary + FROM bugs b, package_bugs pb + WHERE b.bugid = pb.bugid + + AND pb.packageid = + + ORDER BY b.bugid + + + + + SELECT DISTINCT cd.name AS catname, pd.name AS pkgname, pd.description + FROM ebuilds e, ebuild_deps d, packages pd, categories cd + WHERE d.ebuildid = e.ebuildid + AND pd.packageid = d.packageid + AND pd.categoryid = cd.categoryid + + AND e.packageid = + + ORDER BY cd.name, pd.name + + + + + SELECT DISTINCT cd.name AS catname, pd.name AS pkgname, pd.description + FROM ebuilds e, ebuild_rdeps d, packages pd, categories cd + WHERE d.ebuildid = e.ebuildid + AND pd.packageid = d.packageid + AND pd.categoryid = cd.categoryid + + AND e.packageid = + + ORDER BY cd.name, pd.name + + + + + SELECT DISTINCT cd.name AS catname, pd.name AS pkgname, pd.description + FROM ebuilds e, ( + SELECT ebuildid + FROM ebuild_rdeps d + + WHERE d.packageid = + + UNION + SELECT ebuildid + FROM ebuild_deps d + + WHERE d.packageid = + ) d, packages pd, categories cd + WHERE d.ebuildid = e.ebuildid + AND pd.packageid = e.packageid + AND pd.categoryid = cd.categoryid + ORDER BY cd.name, pd.name + + + + + SELECT em.ebuildid, DENSE_RANK() OVER(ORDER BY em.setno) AS setno + FROM ebuild_masks em, ebuilds e + WHERE em.ebuildid = e.ebuildid + + AND e.packageid = + + + + + + SELECT DISTINCT DENSE_RANK() OVER(ORDER BY em.setno), ms.person, ms.message, ms.dateadded + FROM ebuild_masks em, ebuilds e, masksets ms + WHERE em.ebuildid = e.ebuildid + AND ms.setno = em.setno + + AND e.packageid = + + ORDER BY DENSE_RANK() OVER(ORDER BY em.setno) + + + + + SELECT date, person, email, comment + FROM package_changelogs + + WHERE packageid = + + ORDER BY date DESC, n + + diff --git a/gentoobrowse/views/popular.xml b/gentoobrowse/views/popular.xml index 873805a..e21a296 100644 --- a/gentoobrowse/views/popular.xml +++ b/gentoobrowse/views/popular.xml @@ -2,15 +2,15 @@ - + - SELECT p.packageid, MIN(c.name) AS catname, MIN(p.name) AS pkgname, MIN(p.description) AS description + SELECT p.packageid, MIN(c.name) AS catname, MIN(p.name) AS pkgname, MIN(p.description) AS description, COUNT(*) AS trackers FROM user_packages up, packages p, categories c WHERE up.packageid = p.packageid AND p.categoryid = c.categoryid GROUP BY p.packageid - ORDER BY COUNT(*), MIN(c.name), MIN(p.name) + ORDER BY COUNT(*) DESC, MIN(c.name), MIN(p.name) LIMIT 50 - + diff --git a/gentoobrowse/views/search.xml b/gentoobrowse/views/search.xml index 1b7a177..820c3ea 100644 --- a/gentoobrowse/views/search.xml +++ b/gentoobrowse/views/search.xml @@ -2,19 +2,20 @@ - + - select c.name as catname, p.name as pkgname, description, - ts_rank((setweight(to_tsvector('english', p.name), 'A') || setweight(to_tsvector('english', p.description), 'B')), - plainto_tsquery('english', ?)) as rank + select c.name as catname, p.name as pkgname, description + , + ts_rank((setweight(to_tsvector('english', p.name), 'A') || setweight(to_tsvector('english', p.description), 'B')), + plainto_tsquery('english', )) as rank + from packages p, categories c - where (setweight(to_tsvector('english', p.name), 'A') || setweight(to_tsvector('english', p.description), 'B')) @@ plainto_tsquery('english', ?) - and p.categoryid = c.categoryid - order by rank desc, p.name + where p.categoryid = c.categoryid + + and (setweight(to_tsvector('english', p.name), 'A') || setweight(to_tsvector('english', p.description), 'B')) + @@ plainto_tsquery('english', ) + order by rank desc, p.name + - - - - - + diff --git a/gentoobrowse/views/tracked.xml b/gentoobrowse/views/tracked.xml new file mode 100644 index 0000000..a7b50a9 --- /dev/null +++ b/gentoobrowse/views/tracked.xml @@ -0,0 +1,21 @@ + + + + + + SELECT c.name AS catname, p.name AS pkgname, ( + SELECT e.version + FROM ebuilds e + WHERE e.packageid = p.packageid + ORDER BY e.versioninst + DESC LIMIT 1) AS latestversion + FROM user_packages up, packages p, categories c + WHERE up.packageid = p.packageid + AND c.categoryid = p.categoryid + AND up.userid = + ORDER BY c.name, p.name + + + + diff --git a/gentoobrowse/views/user.xml b/gentoobrowse/views/user.xml new file mode 100644 index 0000000..a2ea60d --- /dev/null +++ b/gentoobrowse/views/user.xml @@ -0,0 +1,14 @@ + + + + + + SELECT u.* + FROM users u + WHERE u.username = + WHERE u.verifyguid = + + + + -- cgit v1.2.3