@galadrim/galadmin 0.1.216 → 0.1.217

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@galadrim/galadmin",
3
- "version": "0.1.216",
3
+ "version": "0.1.217",
4
4
  "main": "dist/index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1",
package/src/api.ts CHANGED
@@ -234,7 +234,7 @@ export default (db, config, user) => {
234
234
  }
235
235
  }
236
236
  }
237
- const { err, rows: counts } = await db.query("SELECT COUNT(*) AS count FROM (SELECT 1 FROM ?? " + (view.join || "") + queryString + " " + (view.groupBy ? "GROUP BY " + view.groupBy : "") + ") s", [view.tableName])
237
+ const { err, rows: counts } = await db.query("SELECT COUNT(*) AS count FROM (SELECT 1 FROM ?? " + (view.join || "") + queryString + " " + (view.groupBy ? "GROUP BY " + view.groupBy : "") + (subview?.having ? " HAVING " + subview?.having : "") + ") s", [view.tableName])
238
238
  if (err) {
239
239
  res.send({
240
240
  records,