| Summary: | layerindex: REST API ignores the "orderby" parameter | ||
|---|---|---|---|
| Product: | [Yocto Project Subprojects] Layer Index | Reporter: | Tim Orling <tim.orling> |
| Component: | Layer Index | Assignee: | Tim Orling <tim.orling> |
| Status: | NEW --- | QA Contact: | apoorv sangal <apoorvsangal> |
| Severity: | normal | ||
| Priority: | Medium | ||
| Version: | 6.1 | ||
| Target Milestone: | 6.2 | ||
| Hardware: | All | ||
| OS: | Multiple | ||
| Whiteboard: | |||
| OS type for building Yocto: | --- | Type of Regression: | --- |
| Verified: | Documentation change: | No (bug/feature does not impact docs) | |
params_to_queryset() in layerindex/querysethelper.py validates orderby and works out the column and direction, but never calls order_by() on the queryset, so the parameter has no effect: /layerindex/api/layerItems/?orderby=name:asc /layerindex/api/layerItems/?orderby=name:desc both return the same order. Either apply it (queryset.order_by(column)) or drop the parameter. Found while fuzz testing a bench instance.