From d909ffcb17b81c617466f4437b696adb9a8d5144 Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Sat, 31 May 2014 11:45:00 +0200 Subject: aurjson: Add a PackageBaseID field This is useful to tools that automatically generate requests to orphan, delete or merge packages. Signed-off-by: Lukas Fleischer --- web/lib/aurjson.class.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'web/lib') diff --git a/web/lib/aurjson.class.php b/web/lib/aurjson.class.php index 983e751..9abb2d6 100644 --- a/web/lib/aurjson.class.php +++ b/web/lib/aurjson.class.php @@ -17,6 +17,7 @@ class AurJSON { ); private static $fields_v1 = array( 'Packages.ID', 'Packages.Name', + 'PackageBases.ID AS PackageBaseID', 'PackageBases.Name AS PackageBase', 'Version', 'CategoryID', 'Description', 'URL', 'NumVotes', 'OutOfDateTS AS OutOfDate', 'Users.UserName AS Maintainer', @@ -25,14 +26,15 @@ class AurJSON { ); private static $fields_v2 = array( 'Packages.ID', 'Packages.Name', + 'PackageBases.ID AS PackageBaseID', 'PackageBases.Name AS PackageBase', 'Version', 'CategoryID', 'Description', 'URL', 'NumVotes', 'OutOfDateTS AS OutOfDate', 'Users.UserName AS Maintainer', 'SubmittedTS AS FirstSubmitted', 'ModifiedTS AS LastModified' ); private static $numeric_fields = array( - 'ID', 'CategoryID', 'NumVotes', 'OutOfDate', 'FirstSubmitted', - 'LastModified' + 'ID', 'PackageBaseID', 'CategoryID', 'NumVotes', 'OutOfDate', + 'FirstSubmitted', 'LastModified' ); /* -- cgit v1.2.3-70-g09d2