Sort functionality in gallery: Add a button and attach an action.
Background
This is a GitHub task, make sure to read the info.
The gallery is implemented as bootstrap-table. See this.
The code for gallery is in galleryList.controller.js
and index.html
.
The sort functionality description can be found here and here.
The refresh options functionality can be found here. Use this to change any bootstrap table parameter when the button is click. (Hint: change sortName parameter value)
You can also dig deeper into the bootstrap-table library because there are other ways to sort the table too but the mentioned method will do the task.
Task
Implement sort functionality in gallery. Sort the items by likes or views.
The sorted view would be having programs in ascending or descending order of likes or views.
For simplicity just create a button in the gallery itself, clicking on which will sort programs by likes/views.
Deliverables
Send a pull request with the sort functionality at least on one of likes or views.