You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficcontrol.apache.org by GitBox <gi...@apache.org> on 2018/06/12 17:36:28 UTC

[GitHub] dewrich closed pull request #2398: [Issue 2387] allow cachegroup select by type id

dewrich closed pull request #2398: [Issue 2387] allow cachegroup select by type id
URL: https://github.com/apache/incubator-trafficcontrol/pull/2398
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/traffic_ops/testing/compare/testroutes.txt b/traffic_ops/testing/compare/testroutes.txt
index 4c9e72c49..cdb34e79a 100644
--- a/traffic_ops/testing/compare/testroutes.txt
+++ b/traffic_ops/testing/compare/testroutes.txt
@@ -8,3 +8,5 @@ api/1.3/regions?orderby=id
 api/1.3/servers?orderby=id
 api/1.3/statuses?orderby=id
 api/1.3/profiles?orderby=id
+api/1.3/cachegroups?orderby=id
+api/1.3/cachegroups?type=4
diff --git a/traffic_ops/traffic_ops_golang/cachegroup/cachegroups.go b/traffic_ops/traffic_ops_golang/cachegroup/cachegroups.go
index 187d380df..1faf7ce19 100644
--- a/traffic_ops/traffic_ops_golang/cachegroup/cachegroups.go
+++ b/traffic_ops/traffic_ops_golang/cachegroup/cachegroups.go
@@ -314,6 +314,7 @@ func (cachegroup *TOCacheGroup) Read(db *sqlx.DB, parameters map[string]string,
 		"id":        dbhelpers.WhereColumnInfo{"cachegroup.id", api.IsInt},
 		"name":      dbhelpers.WhereColumnInfo{"cachegroup.name", nil},
 		"shortName": dbhelpers.WhereColumnInfo{"short_name", nil},
+		"type":      dbhelpers.WhereColumnInfo{"cachegroup.type", nil},
 	}
 	where, orderBy, queryValues, errs := dbhelpers.BuildWhereAndOrderBy(parameters, queryParamsToQueryCols)
 	if len(errs) > 0 {


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services