fleetmap-reports 2.0.53 → 2.0.55

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": "fleetmap-reports",
3
- "version": "2.0.53",
3
+ "version": "2.0.55",
4
4
  "description": "",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
package/src/util/utils.js CHANGED
@@ -265,6 +265,12 @@ async function executeServerSide (type, sliced, from, to, userData, totalItems,
265
265
  }))
266
266
  }
267
267
 
268
+ if (userData.byDriver) {
269
+ reportData.sort((a, b) => (a.driver.name > b.driver.name) ? 1 : -1)
270
+ } else {
271
+ reportData.sort((a, b) => (a.device.name > b.device.name) ? 1 : -1)
272
+ }
273
+
268
274
  return reportData
269
275
  }
270
276