fleetmap-reports 1.0.921 → 1.0.923

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": "1.0.921",
3
+ "version": "1.0.923",
4
4
  "description": "",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
package/src/kms-report.js CHANGED
@@ -58,8 +58,8 @@ async function createKmsReportByDevice (from, to, userData, traccarInstance) {
58
58
 
59
59
  // Process report data
60
60
  if (trips.length) {
61
- checkTripsKms(traccarInstance, from, to, allDevices, { trips, route })
62
- allData.devices = allData.devices.concat(await processDevices(from, to, allDevices, {
61
+ checkTripsKms(traccarInstance, from, to, devices, { trips, route })
62
+ allData.devices = allData.devices.concat(await processDevices(from, to, devices, {
63
63
  trips,
64
64
  route
65
65
  }, userData, traccarInstance))
@@ -343,7 +343,7 @@ async function exportTripReportToPDF (userData, reportData) {
343
343
  doc.text(name, 20, space + 20)
344
344
  doc.setFontSize(11)
345
345
  doc.text(group ? translations.report.group + ': ' + group.name : '', 200, space + 20)
346
- doc.text(convertToLocaleString(d.from, lang, timezone) + ' - ' + convertToLocaleString(d.to, lang, timezone), 20, space + 25)
346
+ doc.text(convertToLocaleString(d.from, lang, timezone, userData.user) + ' - ' + convertToLocaleString(d.to, lang, timezone, userData.user), 20, space + 25)
347
347
  if (!userData.allWeek && userData.weekDays) {
348
348
  doc.text((userData.weekDays.monday ? ' ' + translations.report.monday + ',' : '') +
349
349
  (userData.weekDays.tuesday ? ' ' + translations.report.tuesday + ',' : '') +