osmlab / to-fix-backend

The to-fix server
BSD 3-Clause "New" or "Revised" License
15 stars 13 forks source link

Return counts of results #173

Closed batpad closed 6 years ago

batpad commented 6 years ago

Just wanted to drop in documentation for whenever we want to do this: http://docs.sequelizejs.com/manual/tutorial/models-usage.html - look under findAndCountAll

cc @emilymdubois

batpad commented 6 years ago

Started sketching out adding count to the items endpoint: https://github.com/osmlab/to-fix-backend/pull/191 - not sure if this is a great idea

batpad commented 6 years ago

For now, let's stick with the approach of having the separate project stats end-point and revisit here if we do need counts returned with every get-items request.