@ministryofjustice/hmpps-digital-prison-reporting-frontend 4.26.8 → 4.28.0

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.
Files changed (484) hide show
  1. package/dpr/assets/app.js.map +2 -2
  2. package/dpr/components/_async/async-filters-form/sortByTemplate.js +60 -1
  3. package/dpr/components/_async/async-filters-form/sortByTemplate.js.map +2 -2
  4. package/dpr/components/_async/async-filters-form/types.d.js +16 -1
  5. package/dpr/components/_async/async-filters-form/types.d.js.map +2 -2
  6. package/dpr/components/_async/async-filters-form/utils.js +180 -1
  7. package/dpr/components/_async/async-filters-form/utils.js.map +2 -2
  8. package/dpr/components/_catalogue/catalogue/types.js +16 -1
  9. package/dpr/components/_catalogue/catalogue/types.js.map +2 -2
  10. package/dpr/components/_catalogue/catalogue/utils.js +83 -1
  11. package/dpr/components/_catalogue/catalogue/utils.js.map +2 -2
  12. package/dpr/components/_catalogue/catalogue-list/utils.js +140 -1
  13. package/dpr/components/_catalogue/catalogue-list/utils.js.map +2 -2
  14. package/dpr/components/_charts/chart/Chart.js +99 -1
  15. package/dpr/components/_charts/chart/Chart.js.map +2 -2
  16. package/dpr/components/_charts/chart/ChartColours.js +61 -1
  17. package/dpr/components/_charts/chart/ChartColours.js.map +2 -2
  18. package/dpr/components/_charts/chart/ChartTimeseries.js +101 -1
  19. package/dpr/components/_charts/chart/ChartTimeseries.js.map +2 -2
  20. package/dpr/components/_charts/chart/bar/BarChart.js +193 -1
  21. package/dpr/components/_charts/chart/bar/BarChart.js.map +2 -2
  22. package/dpr/components/_charts/chart/bar/types.js +16 -1
  23. package/dpr/components/_charts/chart/bar/types.js.map +2 -2
  24. package/dpr/components/_charts/chart/bar/validate.js +73 -1
  25. package/dpr/components/_charts/chart/bar/validate.js.map +2 -2
  26. package/dpr/components/_charts/chart/bar-timeseries/BarTimeseriesChart.js +80 -1
  27. package/dpr/components/_charts/chart/bar-timeseries/BarTimeseriesChart.js.map +2 -2
  28. package/dpr/components/_charts/chart/bar-timeseries/types.js +16 -1
  29. package/dpr/components/_charts/chart/bar-timeseries/types.js.map +2 -2
  30. package/dpr/components/_charts/chart/bar-timeseries/validate.js +48 -1
  31. package/dpr/components/_charts/chart/bar-timeseries/validate.js.map +2 -2
  32. package/dpr/components/_charts/chart/buckets/Buckets.js +194 -1
  33. package/dpr/components/_charts/chart/buckets/Buckets.js.map +2 -2
  34. package/dpr/components/_charts/chart/buckets/types.js +16 -1
  35. package/dpr/components/_charts/chart/buckets/types.js.map +2 -2
  36. package/dpr/components/_charts/chart/buckets/validate.js +40 -1
  37. package/dpr/components/_charts/chart/buckets/validate.js.map +2 -2
  38. package/dpr/components/_charts/chart/chart-config.js +62 -1
  39. package/dpr/components/_charts/chart/chart-config.js.map +2 -2
  40. package/dpr/components/_charts/chart/doughnut/DoughnutChart.js +96 -1
  41. package/dpr/components/_charts/chart/doughnut/DoughnutChart.js.map +2 -2
  42. package/dpr/components/_charts/chart/doughnut/types.js +16 -1
  43. package/dpr/components/_charts/chart/doughnut/types.js.map +2 -2
  44. package/dpr/components/_charts/chart/doughnut/validate.js +48 -1
  45. package/dpr/components/_charts/chart/doughnut/validate.js.map +2 -2
  46. package/dpr/components/_charts/chart/heatmap/HeatmapChart.js +213 -1
  47. package/dpr/components/_charts/chart/heatmap/HeatmapChart.js.map +2 -2
  48. package/dpr/components/_charts/chart/heatmap/types.js +16 -1
  49. package/dpr/components/_charts/chart/heatmap/types.js.map +2 -2
  50. package/dpr/components/_charts/chart/heatmap/validate.js +40 -1
  51. package/dpr/components/_charts/chart/heatmap/validate.js.map +2 -2
  52. package/dpr/components/_charts/chart/line/LineChart.js +107 -1
  53. package/dpr/components/_charts/chart/line/LineChart.js.map +2 -2
  54. package/dpr/components/_charts/chart/line/types.js +16 -1
  55. package/dpr/components/_charts/chart/line/types.js.map +2 -2
  56. package/dpr/components/_charts/chart/line/validate.js +48 -1
  57. package/dpr/components/_charts/chart/line/validate.js.map +2 -2
  58. package/dpr/components/_charts/chart/line-timeseries/LineTimeseriesChart.js +81 -1
  59. package/dpr/components/_charts/chart/line-timeseries/LineTimeseriesChart.js.map +2 -2
  60. package/dpr/components/_charts/chart/line-timeseries/types.js +16 -1
  61. package/dpr/components/_charts/chart/line-timeseries/types.js.map +2 -2
  62. package/dpr/components/_charts/chart/line-timeseries/validate.js +48 -1
  63. package/dpr/components/_charts/chart/line-timeseries/validate.js.map +2 -2
  64. package/dpr/components/_charts/utils.js +240 -1
  65. package/dpr/components/_charts/utils.js.map +2 -2
  66. package/dpr/components/_dashboards/dashboard-list/types.js +16 -1
  67. package/dpr/components/_dashboards/dashboard-list/types.js.map +2 -2
  68. package/dpr/components/_dashboards/dashboard-list/utils.js +170 -1
  69. package/dpr/components/_dashboards/dashboard-list/utils.js.map +2 -2
  70. package/dpr/components/_dashboards/dashboard-list/validate.js +43 -1
  71. package/dpr/components/_dashboards/dashboard-list/validate.js.map +2 -2
  72. package/dpr/components/_dashboards/dashboard-visualisation/Validate.js +95 -1
  73. package/dpr/components/_dashboards/dashboard-visualisation/Validate.js.map +2 -2
  74. package/dpr/components/_dashboards/dashboard-visualisation/types.js +40 -1
  75. package/dpr/components/_dashboards/dashboard-visualisation/types.js.map +2 -2
  76. package/dpr/components/_dashboards/scorecard/Scorecard.js +176 -1
  77. package/dpr/components/_dashboards/scorecard/Scorecard.js.map +2 -2
  78. package/dpr/components/_dashboards/scorecard/types.js +16 -1
  79. package/dpr/components/_dashboards/scorecard/types.js.map +2 -2
  80. package/dpr/components/_dashboards/scorecard/utils.js +61 -1
  81. package/dpr/components/_dashboards/scorecard/utils.js.map +2 -2
  82. package/dpr/components/_dashboards/scorecard/validate.js +50 -1
  83. package/dpr/components/_dashboards/scorecard/validate.js.map +2 -2
  84. package/dpr/components/_dashboards/scorecard-group/ScorecardGroup.js +212 -1
  85. package/dpr/components/_dashboards/scorecard-group/ScorecardGroup.js.map +2 -2
  86. package/dpr/components/_dashboards/scorecard-group/types.js +16 -1
  87. package/dpr/components/_dashboards/scorecard-group/types.js.map +2 -2
  88. package/dpr/components/_dashboards/scorecard-group/validate.js +50 -1
  89. package/dpr/components/_dashboards/scorecard-group/validate.js.map +2 -2
  90. package/dpr/components/_filters/filter-input/enum.js +38 -1
  91. package/dpr/components/_filters/filter-input/enum.js.map +2 -2
  92. package/dpr/components/_filters/filter-input/filters.js +37 -1
  93. package/dpr/components/_filters/filter-input/filters.js.map +2 -2
  94. package/dpr/components/_filters/filter-input/types.d.js +16 -1
  95. package/dpr/components/_filters/filter-input/types.d.js.map +2 -2
  96. package/dpr/components/_filters/filters-selected/utils.js +314 -1
  97. package/dpr/components/_filters/filters-selected/utils.js.map +2 -2
  98. package/dpr/components/_filters/filtersTypeEnum.js +32 -1
  99. package/dpr/components/_filters/filtersTypeEnum.js.map +2 -2
  100. package/dpr/components/_filters/types.d.js +16 -1
  101. package/dpr/components/_filters/types.d.js.map +2 -2
  102. package/dpr/components/_filters/utils.js +385 -1
  103. package/dpr/components/_filters/utils.js.map +2 -2
  104. package/dpr/components/_inputs/autocomplete-text-input/utils.js +45 -1
  105. package/dpr/components/_inputs/autocomplete-text-input/utils.js.map +2 -2
  106. package/dpr/components/_inputs/date-input/utils.js +88 -1
  107. package/dpr/components/_inputs/date-input/utils.js.map +2 -2
  108. package/dpr/components/_inputs/date-range/types.js +38 -1
  109. package/dpr/components/_inputs/date-range/types.js.map +2 -2
  110. package/dpr/components/_inputs/date-range/utils.js +229 -1
  111. package/dpr/components/_inputs/date-range/utils.js.map +2 -2
  112. package/dpr/components/_inputs/granular-date-range/types.js +70 -1
  113. package/dpr/components/_inputs/granular-date-range/types.js.map +2 -2
  114. package/dpr/components/_inputs/granular-date-range/utils.js +445 -1
  115. package/dpr/components/_inputs/granular-date-range/utils.js.map +2 -2
  116. package/dpr/components/_inputs/multi-select/utils.js +88 -1
  117. package/dpr/components/_inputs/multi-select/utils.js.map +2 -2
  118. package/dpr/components/_inputs/start-end-date/utils.js +84 -1
  119. package/dpr/components/_inputs/start-end-date/utils.js.map +2 -2
  120. package/dpr/components/_reports/report-actions/actionsTemplate.js +59 -1
  121. package/dpr/components/_reports/report-actions/actionsTemplate.js.map +2 -2
  122. package/dpr/components/_reports/report-actions/types.d.js +16 -1
  123. package/dpr/components/_reports/report-actions/types.d.js.map +2 -2
  124. package/dpr/components/_reports/report-actions/utils.js +97 -1
  125. package/dpr/components/_reports/report-actions/utils.js.map +2 -2
  126. package/dpr/components/_reports/report-columns-form/types.d.js +16 -1
  127. package/dpr/components/_reports/report-columns-form/types.d.js.map +2 -2
  128. package/dpr/components/_reports/report-columns-form/utils.js +65 -1
  129. package/dpr/components/_reports/report-columns-form/utils.js.map +2 -2
  130. package/dpr/components/_reports/report-data-table/types.d.js +16 -1
  131. package/dpr/components/_reports/report-data-table/types.d.js.map +2 -2
  132. package/dpr/components/_reports/report-data-table/utils.js +122 -1
  133. package/dpr/components/_reports/report-data-table/utils.js.map +2 -2
  134. package/dpr/components/_reports/report-pagination/types.d.js +16 -1
  135. package/dpr/components/_reports/report-pagination/types.d.js.map +2 -2
  136. package/dpr/components/_reports/report-pagination/utils.js +105 -1
  137. package/dpr/components/_reports/report-pagination/utils.js.map +2 -2
  138. package/dpr/components/_reports/report-totals/utils.js +42 -1
  139. package/dpr/components/_reports/report-totals/utils.js.map +2 -2
  140. package/dpr/components/card-group/utils.js +57 -1
  141. package/dpr/components/card-group/utils.js.map +2 -2
  142. package/dpr/components/report-list/defaultTokenProvider.js +36 -1
  143. package/dpr/components/report-list/defaultTokenProvider.js.map +2 -2
  144. package/dpr/components/report-list/types.d.js +16 -1
  145. package/dpr/components/report-list/types.d.js.map +2 -2
  146. package/dpr/components/report-list/utils.js +238 -1
  147. package/dpr/components/report-list/utils.js.map +2 -2
  148. package/dpr/components/show-more/utils.js +38 -3
  149. package/dpr/components/show-more/utils.js.map +2 -2
  150. package/dpr/components/user-reports/bookmarks/utils.js +198 -1
  151. package/dpr/components/user-reports/bookmarks/utils.js.map +2 -2
  152. package/dpr/components/user-reports/requested/utils.js +65 -1
  153. package/dpr/components/user-reports/requested/utils.js.map +2 -2
  154. package/dpr/components/user-reports/types.d.js +16 -1
  155. package/dpr/components/user-reports/types.d.js.map +2 -2
  156. package/dpr/components/user-reports/utils.js +365 -1
  157. package/dpr/components/user-reports/utils.js.map +2 -2
  158. package/dpr/components/user-reports/viewed/utils.js +37 -1
  159. package/dpr/components/user-reports/viewed/utils.js.map +2 -2
  160. package/dpr/data/agentConfig.js +35 -1
  161. package/dpr/data/agentConfig.js.map +2 -2
  162. package/dpr/data/dashboardClient.js +108 -1
  163. package/dpr/data/dashboardClient.js.map +2 -2
  164. package/dpr/data/dprReportingClient.js +55 -1
  165. package/dpr/data/dprReportingClient.js.map +2 -2
  166. package/dpr/data/missingReportClient.js +55 -1
  167. package/dpr/data/missingReportClient.js.map +2 -2
  168. package/dpr/data/productCollectionClient.js +58 -1
  169. package/dpr/data/productCollectionClient.js.map +2 -2
  170. package/dpr/data/reportDataStore.js +77 -1
  171. package/dpr/data/reportDataStore.js.map +2 -2
  172. package/dpr/data/reportingClient.js +173 -1
  173. package/dpr/data/reportingClient.js.map +2 -2
  174. package/dpr/data/restClient.js +143 -1
  175. package/dpr/data/restClient.js.map +2 -2
  176. package/dpr/data/types.d.js +16 -1
  177. package/dpr/data/types.d.js.map +2 -2
  178. package/dpr/middleware/reportAuthoriser.js +63 -1
  179. package/dpr/middleware/reportAuthoriser.js.map +2 -2
  180. package/dpr/middleware/setUpDprResources.js +173 -1
  181. package/dpr/middleware/setUpDprResources.js.map +3 -3
  182. package/dpr/middleware/setUpDprResources.ts +3 -1
  183. package/dpr/middleware/setUpNestedRoute.js +35 -1
  184. package/dpr/middleware/setUpNestedRoute.js.map +2 -2
  185. package/dpr/routes/index.js +50 -1
  186. package/dpr/routes/index.js.map +2 -2
  187. package/dpr/routes/journeys/api-failures.cy.js +295 -1
  188. package/dpr/routes/journeys/api-failures.cy.js.map +2 -2
  189. package/dpr/routes/journeys/download-report/controller.js +65 -1
  190. package/dpr/routes/journeys/download-report/controller.js.map +2 -2
  191. package/dpr/routes/journeys/download-report/request-download/form/controller.js +98 -1
  192. package/dpr/routes/journeys/download-report/request-download/form/controller.js.map +3 -3
  193. package/dpr/routes/journeys/download-report/request-download/form/controller.ts +1 -1
  194. package/dpr/routes/journeys/download-report/request-download/form/routes.js +50 -1
  195. package/dpr/routes/journeys/download-report/request-download/form/routes.js.map +2 -2
  196. package/dpr/routes/journeys/download-report/request-download/form/submitted/controller.js +68 -1
  197. package/dpr/routes/journeys/download-report/request-download/form/submitted/controller.js.map +2 -2
  198. package/dpr/routes/journeys/download-report/request-download/form/submitted/routes.js +47 -1
  199. package/dpr/routes/journeys/download-report/request-download/form/submitted/routes.js.map +2 -2
  200. package/dpr/routes/journeys/download-report/request-download/form/submitted/tests.cy.js +17 -1
  201. package/dpr/routes/journeys/download-report/request-download/form/submitted/tests.cy.js.map +1 -1
  202. package/dpr/routes/journeys/download-report/request-download/form/tests.cy.js +24 -1
  203. package/dpr/routes/journeys/download-report/request-download/form/tests.cy.js.map +2 -2
  204. package/dpr/routes/journeys/download-report/request-download/routes.js +46 -1
  205. package/dpr/routes/journeys/download-report/request-download/routes.js.map +2 -2
  206. package/dpr/routes/journeys/download-report/request-download/service.js +90 -1
  207. package/dpr/routes/journeys/download-report/request-download/service.js.map +2 -2
  208. package/dpr/routes/journeys/download-report/routes.js +63 -1
  209. package/dpr/routes/journeys/download-report/routes.js.map +2 -2
  210. package/dpr/routes/journeys/download-report/tests.cy.js +104 -1
  211. package/dpr/routes/journeys/download-report/tests.cy.js.map +2 -2
  212. package/dpr/routes/journeys/download-report/utils.js +196 -1
  213. package/dpr/routes/journeys/download-report/utils.js.map +2 -2
  214. package/dpr/routes/journeys/my-reports/bookmarks/controller.js +58 -1
  215. package/dpr/routes/journeys/my-reports/bookmarks/controller.js.map +2 -2
  216. package/dpr/routes/journeys/my-reports/bookmarks/list/controller.js +56 -1
  217. package/dpr/routes/journeys/my-reports/bookmarks/list/controller.js.map +2 -2
  218. package/dpr/routes/journeys/my-reports/bookmarks/list/routes.js +47 -1
  219. package/dpr/routes/journeys/my-reports/bookmarks/list/routes.js.map +2 -2
  220. package/dpr/routes/journeys/my-reports/bookmarks/list/tests.cy.js +32 -1
  221. package/dpr/routes/journeys/my-reports/bookmarks/list/tests.cy.js.map +2 -2
  222. package/dpr/routes/journeys/my-reports/bookmarks/routes.js +49 -1
  223. package/dpr/routes/journeys/my-reports/bookmarks/routes.js.map +2 -2
  224. package/dpr/routes/journeys/my-reports/bookmarks/service.js +123 -4
  225. package/dpr/routes/journeys/my-reports/bookmarks/service.js.map +2 -2
  226. package/dpr/routes/journeys/my-reports/bookmarks/tests.cy.js +448 -1
  227. package/dpr/routes/journeys/my-reports/bookmarks/tests.cy.js.map +2 -2
  228. package/dpr/routes/journeys/my-reports/bookmarks/utils.js +44 -1
  229. package/dpr/routes/journeys/my-reports/bookmarks/utils.js.map +2 -2
  230. package/dpr/routes/journeys/my-reports/recently-viewed/controller.js +53 -1
  231. package/dpr/routes/journeys/my-reports/recently-viewed/controller.js.map +2 -2
  232. package/dpr/routes/journeys/my-reports/recently-viewed/list/controller.js +65 -1
  233. package/dpr/routes/journeys/my-reports/recently-viewed/list/controller.js.map +2 -2
  234. package/dpr/routes/journeys/my-reports/recently-viewed/list/routes.js +47 -1
  235. package/dpr/routes/journeys/my-reports/recently-viewed/list/routes.js.map +2 -2
  236. package/dpr/routes/journeys/my-reports/recently-viewed/list/tests.cy.js +83 -1
  237. package/dpr/routes/journeys/my-reports/recently-viewed/list/tests.cy.js.map +2 -2
  238. package/dpr/routes/journeys/my-reports/recently-viewed/routes.js +49 -1
  239. package/dpr/routes/journeys/my-reports/recently-viewed/routes.js.map +2 -2
  240. package/dpr/routes/journeys/my-reports/recently-viewed/service.js +118 -1
  241. package/dpr/routes/journeys/my-reports/recently-viewed/service.js.map +2 -2
  242. package/dpr/routes/journeys/my-reports/requested-reports/controller.js +52 -1
  243. package/dpr/routes/journeys/my-reports/requested-reports/controller.js.map +2 -2
  244. package/dpr/routes/journeys/my-reports/requested-reports/list/controller.js +65 -1
  245. package/dpr/routes/journeys/my-reports/requested-reports/list/controller.js.map +2 -2
  246. package/dpr/routes/journeys/my-reports/requested-reports/list/routes.js +47 -1
  247. package/dpr/routes/journeys/my-reports/requested-reports/list/routes.js.map +2 -2
  248. package/dpr/routes/journeys/my-reports/requested-reports/list/tests.cy.js +15 -1
  249. package/dpr/routes/journeys/my-reports/requested-reports/list/tests.cy.js.map +2 -2
  250. package/dpr/routes/journeys/my-reports/requested-reports/routes.js +49 -1
  251. package/dpr/routes/journeys/my-reports/requested-reports/routes.js.map +2 -2
  252. package/dpr/routes/journeys/my-reports/requested-reports/service.js +200 -1
  253. package/dpr/routes/journeys/my-reports/requested-reports/service.js.map +2 -2
  254. package/dpr/routes/journeys/my-reports/routes.js +59 -1
  255. package/dpr/routes/journeys/my-reports/routes.js.map +2 -2
  256. package/dpr/routes/journeys/product-collection/routes.js +45 -1
  257. package/dpr/routes/journeys/product-collection/routes.js.map +2 -2
  258. package/dpr/routes/journeys/product-collection/selected/controller.js +55 -1
  259. package/dpr/routes/journeys/product-collection/selected/controller.js.map +2 -2
  260. package/dpr/routes/journeys/product-collection/selected/routes.js +37 -1
  261. package/dpr/routes/journeys/product-collection/selected/routes.js.map +2 -2
  262. package/dpr/routes/journeys/product-collection/selected/tests.cy.js +47 -1
  263. package/dpr/routes/journeys/product-collection/selected/tests.cy.js.map +2 -2
  264. package/dpr/routes/journeys/product-collection/selected/validation.js +41 -1
  265. package/dpr/routes/journeys/product-collection/selected/validation.js.map +2 -2
  266. package/dpr/routes/journeys/request-missing-report/form/controller.js +104 -1
  267. package/dpr/routes/journeys/request-missing-report/form/controller.js.map +3 -3
  268. package/dpr/routes/journeys/request-missing-report/form/controller.ts +6 -3
  269. package/dpr/routes/journeys/request-missing-report/form/routes.js +50 -1
  270. package/dpr/routes/journeys/request-missing-report/form/routes.js.map +2 -2
  271. package/dpr/routes/journeys/request-missing-report/form/tests.cy.js +22 -1
  272. package/dpr/routes/journeys/request-missing-report/form/tests.cy.js.map +2 -2
  273. package/dpr/routes/journeys/request-missing-report/form/validation.js +43 -1
  274. package/dpr/routes/journeys/request-missing-report/form/validation.js.map +2 -2
  275. package/dpr/routes/journeys/request-missing-report/routes.js +57 -1
  276. package/dpr/routes/journeys/request-missing-report/routes.js.map +2 -2
  277. package/dpr/routes/journeys/request-missing-report/submitted/controller.js +65 -1
  278. package/dpr/routes/journeys/request-missing-report/submitted/controller.js.map +3 -3
  279. package/dpr/routes/journeys/request-missing-report/submitted/controller.ts +1 -1
  280. package/dpr/routes/journeys/request-missing-report/submitted/routes.js +47 -1
  281. package/dpr/routes/journeys/request-missing-report/submitted/routes.js.map +2 -2
  282. package/dpr/routes/journeys/request-missing-report/submitted/tests.cy.js +14 -1
  283. package/dpr/routes/journeys/request-missing-report/submitted/tests.cy.js.map +2 -2
  284. package/dpr/routes/journeys/request-missing-report/tests.cy.js +37 -1
  285. package/dpr/routes/journeys/request-missing-report/tests.cy.js.map +2 -2
  286. package/dpr/routes/journeys/request-report/controller.js +79 -1
  287. package/dpr/routes/journeys/request-report/controller.js.map +3 -3
  288. package/dpr/routes/journeys/request-report/controller.ts +3 -1
  289. package/dpr/routes/journeys/request-report/filters/controller.js +127 -1
  290. package/dpr/routes/journeys/request-report/filters/controller.js.map +3 -3
  291. package/dpr/routes/journeys/request-report/filters/controller.ts +3 -3
  292. package/dpr/routes/journeys/request-report/filters/routes.js +50 -1
  293. package/dpr/routes/journeys/request-report/filters/routes.js.map +2 -2
  294. package/dpr/routes/journeys/request-report/filters/tests.cy.js +451 -1
  295. package/dpr/routes/journeys/request-report/filters/tests.cy.js.map +2 -2
  296. package/dpr/routes/journeys/request-report/filters/utils.js +331 -1
  297. package/dpr/routes/journeys/request-report/filters/utils.js.map +2 -2
  298. package/dpr/routes/journeys/request-report/routes.js +100 -1
  299. package/dpr/routes/journeys/request-report/routes.js.map +3 -3
  300. package/dpr/routes/journeys/request-report/routes.ts +2 -0
  301. package/dpr/routes/journeys/request-report/status/controller.js +80 -1
  302. package/dpr/routes/journeys/request-report/status/controller.js.map +3 -3
  303. package/dpr/routes/journeys/request-report/status/controller.ts +1 -1
  304. package/dpr/routes/journeys/request-report/status/routes.js +48 -1
  305. package/dpr/routes/journeys/request-report/status/routes.js.map +2 -2
  306. package/dpr/routes/journeys/request-report/status/tests.cy.js +127 -1
  307. package/dpr/routes/journeys/request-report/status/tests.cy.js.map +2 -2
  308. package/dpr/routes/journeys/request-report/status/utils.js +72 -1
  309. package/dpr/routes/journeys/request-report/status/utils.js.map +2 -2
  310. package/dpr/routes/journeys/request-report/tests.cy.js +307 -1
  311. package/dpr/routes/journeys/request-report/tests.cy.js.map +2 -2
  312. package/dpr/routes/journeys/routes.js +46 -1
  313. package/dpr/routes/journeys/routes.js.map +2 -2
  314. package/dpr/routes/journeys/view-report/async/controller.js +89 -1
  315. package/dpr/routes/journeys/view-report/async/controller.js.map +3 -3
  316. package/dpr/routes/journeys/view-report/async/controller.ts +2 -2
  317. package/dpr/routes/journeys/view-report/async/dashboard/controller.js +82 -1
  318. package/dpr/routes/journeys/view-report/async/dashboard/controller.js.map +3 -3
  319. package/dpr/routes/journeys/view-report/async/dashboard/controller.ts +1 -1
  320. package/dpr/routes/journeys/view-report/async/dashboard/routes.js +48 -1
  321. package/dpr/routes/journeys/view-report/async/dashboard/routes.js.map +2 -2
  322. package/dpr/routes/journeys/view-report/async/dashboard/tests.cy.js +33 -1
  323. package/dpr/routes/journeys/view-report/async/dashboard/tests.cy.js.map +2 -2
  324. package/dpr/routes/journeys/view-report/async/dashboard/utils.js +242 -1
  325. package/dpr/routes/journeys/view-report/async/dashboard/utils.js.map +2 -2
  326. package/dpr/routes/journeys/view-report/async/report/controller.js +83 -1
  327. package/dpr/routes/journeys/view-report/async/report/controller.js.map +3 -3
  328. package/dpr/routes/journeys/view-report/async/report/controller.ts +1 -1
  329. package/dpr/routes/journeys/view-report/async/report/report-variants.cy.js +76 -1
  330. package/dpr/routes/journeys/view-report/async/report/report-variants.cy.js.map +2 -2
  331. package/dpr/routes/journeys/view-report/async/report/routes.js +53 -1
  332. package/dpr/routes/journeys/view-report/async/report/routes.js.map +2 -2
  333. package/dpr/routes/journeys/view-report/async/report/tests.cy.js +895 -1
  334. package/dpr/routes/journeys/view-report/async/report/tests.cy.js.map +2 -2
  335. package/dpr/routes/journeys/view-report/async/report/types.js +16 -1
  336. package/dpr/routes/journeys/view-report/async/report/types.js.map +2 -2
  337. package/dpr/routes/journeys/view-report/async/report/utils.js +427 -1
  338. package/dpr/routes/journeys/view-report/async/report/utils.js.map +2 -2
  339. package/dpr/routes/journeys/view-report/async/routes.js +52 -1
  340. package/dpr/routes/journeys/view-report/async/routes.js.map +2 -2
  341. package/dpr/routes/journeys/view-report/controller.js +62 -1
  342. package/dpr/routes/journeys/view-report/controller.js.map +3 -3
  343. package/dpr/routes/journeys/view-report/controller.ts +7 -4
  344. package/dpr/routes/journeys/view-report/routes.js +87 -1
  345. package/dpr/routes/journeys/view-report/routes.js.map +2 -2
  346. package/dpr/routes/journeys/view-report/sync/dashboard/controller.js +68 -1
  347. package/dpr/routes/journeys/view-report/sync/dashboard/controller.js.map +3 -3
  348. package/dpr/routes/journeys/view-report/sync/dashboard/controller.ts +1 -1
  349. package/dpr/routes/journeys/view-report/sync/dashboard/routes.js +48 -1
  350. package/dpr/routes/journeys/view-report/sync/dashboard/routes.js.map +2 -2
  351. package/dpr/routes/journeys/view-report/sync/dashboard/utils.js +144 -1
  352. package/dpr/routes/journeys/view-report/sync/dashboard/utils.js.map +2 -2
  353. package/dpr/routes/journeys/view-report/sync/load-report/controller.js +102 -1
  354. package/dpr/routes/journeys/view-report/sync/load-report/controller.js.map +3 -3
  355. package/dpr/routes/journeys/view-report/sync/load-report/controller.ts +1 -1
  356. package/dpr/routes/journeys/view-report/sync/load-report/routes.js +47 -1
  357. package/dpr/routes/journeys/view-report/sync/load-report/routes.js.map +2 -2
  358. package/dpr/routes/journeys/view-report/sync/report/controller.js +99 -1
  359. package/dpr/routes/journeys/view-report/sync/report/controller.js.map +3 -3
  360. package/dpr/routes/journeys/view-report/sync/report/controller.ts +3 -3
  361. package/dpr/routes/journeys/view-report/sync/report/routes.js +51 -1
  362. package/dpr/routes/journeys/view-report/sync/report/routes.js.map +2 -2
  363. package/dpr/routes/journeys/view-report/sync/report/utils.js +298 -1
  364. package/dpr/routes/journeys/view-report/sync/report/utils.js.map +2 -2
  365. package/dpr/routes/journeys/view-report/sync/routes.js +51 -1
  366. package/dpr/routes/journeys/view-report/sync/routes.js.map +2 -2
  367. package/dpr/routes/journeys/view-report/sync/tests.cy.js +43 -1
  368. package/dpr/routes/journeys/view-report/sync/tests.cy.js.map +2 -2
  369. package/dpr/routes/journeys/view-report/utils.js +173 -1
  370. package/dpr/routes/journeys/view-report/utils.js.map +2 -2
  371. package/dpr/services/dashboardService.js +66 -1
  372. package/dpr/services/dashboardService.js.map +2 -2
  373. package/dpr/services/defaultFilterValuesService.js +114 -1
  374. package/dpr/services/defaultFilterValuesService.js.map +2 -2
  375. package/dpr/services/featureFlagService.js +65 -1
  376. package/dpr/services/featureFlagService.js.map +2 -2
  377. package/dpr/services/featureFlags.cy.js +72 -1
  378. package/dpr/services/featureFlags.cy.js.map +2 -2
  379. package/dpr/services/index.js +59 -1
  380. package/dpr/services/index.js.map +2 -2
  381. package/dpr/services/missingReport/missingReportService.js +52 -1
  382. package/dpr/services/missingReport/missingReportService.js.map +2 -2
  383. package/dpr/services/productCollection/productCollectionService.js +55 -1
  384. package/dpr/services/productCollection/productCollectionService.js.map +2 -2
  385. package/dpr/services/productCollection/productCollectionStoreService.js +61 -1
  386. package/dpr/services/productCollection/productCollectionStoreService.js.map +2 -2
  387. package/dpr/services/reportStoreService.js +51 -1
  388. package/dpr/services/reportStoreService.js.map +2 -2
  389. package/dpr/services/reportingService.js +81 -1
  390. package/dpr/services/reportingService.js.map +2 -2
  391. package/dpr/setUpNunjucksFilters.js +66 -1
  392. package/dpr/setUpNunjucksFilters.js.map +2 -2
  393. package/dpr/types/AsyncReportUtils.js +16 -1
  394. package/dpr/types/AsyncReportUtils.js.map +2 -2
  395. package/dpr/types/Bookmark.js +16 -1
  396. package/dpr/types/Bookmark.js.map +2 -2
  397. package/dpr/types/Charts.js +16 -1
  398. package/dpr/types/Charts.js.map +2 -2
  399. package/dpr/types/Download.js +16 -1
  400. package/dpr/types/Download.js.map +2 -2
  401. package/dpr/types/DprConfig.js +16 -1
  402. package/dpr/types/DprConfig.js.map +2 -2
  403. package/dpr/types/DprUser.js +43 -1
  404. package/dpr/types/DprUser.js.map +2 -2
  405. package/dpr/types/EmbeddedReportUtils.js +33 -1
  406. package/dpr/types/EmbeddedReportUtils.js.map +2 -2
  407. package/dpr/types/ExecutionData.d.js +16 -1
  408. package/dpr/types/ExecutionData.d.js.map +2 -2
  409. package/dpr/types/Metrics.js +16 -1
  410. package/dpr/types/Metrics.js.map +2 -2
  411. package/dpr/types/ReportQuery.js +168 -1
  412. package/dpr/types/ReportQuery.js.map +2 -2
  413. package/dpr/types/ReportStore.js +16 -1
  414. package/dpr/types/ReportStore.js.map +2 -2
  415. package/dpr/types/Services.d.js +16 -1
  416. package/dpr/types/Services.d.js.map +2 -2
  417. package/dpr/types/Templates.d.js +16 -1
  418. package/dpr/types/Templates.d.js.map +2 -2
  419. package/dpr/types/UserReports.js +55 -1
  420. package/dpr/types/UserReports.js.map +2 -2
  421. package/dpr/types/api.d.js +16 -1
  422. package/dpr/types/api.d.js.map +2 -2
  423. package/dpr/types/index.d.js +16 -1
  424. package/dpr/types/index.d.js.map +2 -2
  425. package/dpr/utils/CollatedSummaryBuilder/CollatedSummaryBuilder.js +91 -1
  426. package/dpr/utils/CollatedSummaryBuilder/CollatedSummaryBuilder.js.map +2 -2
  427. package/dpr/utils/CreateDprServices.js +66 -1
  428. package/dpr/utils/CreateDprServices.js.map +2 -2
  429. package/dpr/utils/DataTableBuilder/DataTableBuilder.js +304 -1
  430. package/dpr/utils/DataTableBuilder/DataTableBuilder.js.map +2 -2
  431. package/dpr/utils/DataTableBuilder/types.d.js +16 -1
  432. package/dpr/utils/DataTableBuilder/types.d.js.map +2 -2
  433. package/dpr/utils/DateMapper/DateMapper.js +125 -1
  434. package/dpr/utils/DateMapper/DateMapper.js.map +2 -2
  435. package/dpr/utils/DateMapper/types.d.js +16 -1
  436. package/dpr/utils/DateMapper/types.d.js.map +2 -2
  437. package/dpr/utils/ErrorHandler.js +94 -1
  438. package/dpr/utils/ErrorHandler.js.map +3 -3
  439. package/dpr/utils/ErrorHandler.ts +1 -1
  440. package/dpr/utils/ParentChildDataTableBuilder/ParentChildDataTableBuilder.js +201 -1
  441. package/dpr/utils/ParentChildDataTableBuilder/ParentChildDataTableBuilder.js.map +2 -2
  442. package/dpr/utils/ParentChildDataTableBuilder/types.d.js +16 -1
  443. package/dpr/utils/ParentChildDataTableBuilder/types.d.js.map +2 -2
  444. package/dpr/utils/Personalisation/personalisationUtils.js +202 -1
  445. package/dpr/utils/Personalisation/personalisationUtils.js.map +2 -2
  446. package/dpr/utils/Personalisation/types.d.js +16 -1
  447. package/dpr/utils/Personalisation/types.d.js.map +2 -2
  448. package/dpr/utils/SectionedDataTableBuilder/SectionedDataTableBuilder.js +310 -1
  449. package/dpr/utils/SectionedDataTableBuilder/SectionedDataTableBuilder.js.map +2 -2
  450. package/dpr/utils/SectionedDataTableBuilder/types.d.js +16 -1
  451. package/dpr/utils/SectionedDataTableBuilder/types.d.js.map +2 -2
  452. package/dpr/utils/SectionedFieldsTableBuilder/SectionedFieldsTableBuilder.js +145 -1
  453. package/dpr/utils/SectionedFieldsTableBuilder/SectionedFieldsTableBuilder.js.map +2 -2
  454. package/dpr/utils/SummaryDataTableBuilder/SummaryDataTableBuilder.js +60 -1
  455. package/dpr/utils/SummaryDataTableBuilder/SummaryDataTableBuilder.js.map +2 -2
  456. package/dpr/utils/UserStoreItemBuilder.js +247 -1
  457. package/dpr/utils/UserStoreItemBuilder.js.map +2 -2
  458. package/dpr/utils/arrayUtils.js +28 -1
  459. package/dpr/utils/arrayUtils.js.map +2 -2
  460. package/dpr/utils/datasetHelper.js +229 -1
  461. package/dpr/utils/datasetHelper.js.map +2 -2
  462. package/dpr/utils/definitionUtils.js +133 -1
  463. package/dpr/utils/definitionUtils.js.map +2 -2
  464. package/dpr/utils/index.js +44 -1
  465. package/dpr/utils/index.js.map +2 -2
  466. package/dpr/utils/indexedAccesHelper.js +41 -1
  467. package/dpr/utils/indexedAccesHelper.js.map +2 -2
  468. package/dpr/utils/localsHelper.js +105 -1
  469. package/dpr/utils/localsHelper.js.map +2 -2
  470. package/dpr/utils/logger.js +48 -1
  471. package/dpr/utils/logger.js.map +2 -2
  472. package/dpr/utils/reportListsHelper.js +128 -12
  473. package/dpr/utils/reportListsHelper.js.map +2 -2
  474. package/dpr/utils/reportStoreHelper.js +65 -1
  475. package/dpr/utils/reportStoreHelper.js.map +2 -2
  476. package/dpr/utils/requestStatusHelper.js +172 -1
  477. package/dpr/utils/requestStatusHelper.js.map +2 -2
  478. package/dpr/utils/sanitisedError.js +45 -1
  479. package/dpr/utils/sanitisedError.js.map +2 -2
  480. package/dpr/utils/urlHelper.js +103 -1
  481. package/dpr/utils/urlHelper.js.map +2 -2
  482. package/dpr/validation/validate.js +52 -1
  483. package/dpr/validation/validate.js.map +2 -2
  484. package/package.json +9 -8
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../src/dpr/routes/journeys/view-report/async/controller.ts"],
4
- "sourcesContent": ["import { RequestHandler } from 'express'\nimport ErrorHandler from '../../../../utils/ErrorHandler'\nimport { Services } from '../../../../types/Services'\nimport UserReportsListUtils from '../../../../components/user-reports/utils'\nimport { FiltersType } from '../../../../components/_filters/filtersTypeEnum'\nimport PersonalisationUtils from '../../../../utils/Personalisation/personalisationUtils'\n\nclass AsyncController {\n layoutPath: string\n\n services: Services\n\n constructor(layoutPath: string, services: Services) {\n this.layoutPath = layoutPath\n this.services = services\n }\n\n POST: RequestHandler = async (req, res, _next) => {\n try {\n const response = await UserReportsListUtils.updateExpiredStatus({\n req,\n res,\n services: this.services,\n })\n res.send({ isExpired: response })\n } catch (error) {\n res.send({ status: 'FAILED' })\n }\n }\n\n saveDefaultFilterValues: RequestHandler = async (req, res, next) => {\n try {\n PersonalisationUtils.saveDefaults(FiltersType.INTERACTIVE, res, req, this.services)\n res.redirect(`${req.baseUrl}?defaultsSaved=true`)\n } catch (error) {\n req.body = {\n title: 'Failed to save defaults',\n error: new ErrorHandler(error).formatError(),\n ...(req.body && { ...req.body }),\n }\n next()\n }\n }\n\n removeDefaultFilterValues: RequestHandler = async (req, res, next) => {\n try {\n PersonalisationUtils.removeDefaults(FiltersType.INTERACTIVE, res, req, this.services)\n res.redirect(req.baseUrl)\n } catch (error) {\n req.body = {\n title: 'Failed to remove defaults',\n error: new ErrorHandler(error).formatError(),\n ...(req.body && { ...req.body }),\n }\n next()\n }\n }\n}\n\nexport { AsyncController }\nexport default AsyncController\n"],
5
- "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,qBAAAE,EAAA,YAAAC,IAAA,eAAAC,EAAAJ,GACA,IAAAK,EAAyB,6CAEzBC,EAAiC,wDACjCC,EAA4B,2DAC5BC,EAAiC,qEAEjC,MAAMN,CAAgB,CACpB,WAEA,SAEA,YAAYO,EAAoBC,EAAoB,CAClD,KAAK,WAAaD,EAClB,KAAK,SAAWC,CAClB,CAEA,KAAuB,MAAOC,EAAKC,EAAKC,IAAU,CAChD,GAAI,CACF,MAAMC,EAAW,MAAM,EAAAC,QAAqB,oBAAoB,CAC9D,IAAAJ,EACA,IAAAC,EACA,SAAU,KAAK,QACjB,CAAC,EACDA,EAAI,KAAK,CAAE,UAAWE,CAAS,CAAC,CAClC,MAAgB,CACdF,EAAI,KAAK,CAAE,OAAQ,QAAS,CAAC,CAC/B,CACF,EAEA,wBAA0C,MAAOD,EAAKC,EAAKI,IAAS,CAClE,GAAI,CACF,EAAAC,QAAqB,aAAa,cAAY,YAAaL,EAAKD,EAAK,KAAK,QAAQ,EAClFC,EAAI,SAAS,GAAGD,EAAI,OAAO,qBAAqB,CAClD,OAASO,EAAO,CACdP,EAAI,KAAO,CACT,MAAO,0BACP,MAAO,IAAI,EAAAQ,QAAaD,CAAK,EAAE,YAAY,EAC3C,GAAIP,EAAI,MAAQ,CAAE,GAAGA,EAAI,IAAK,CAChC,EACAK,EAAK,CACP,CACF,EAEA,0BAA4C,MAAOL,EAAKC,EAAKI,IAAS,CACpE,GAAI,CACF,EAAAC,QAAqB,eAAe,cAAY,YAAaL,EAAKD,EAAK,KAAK,QAAQ,EACpFC,EAAI,SAASD,EAAI,OAAO,CAC1B,OAASO,EAAO,CACdP,EAAI,KAAO,CACT,MAAO,4BACP,MAAO,IAAI,EAAAQ,QAAaD,CAAK,EAAE,YAAY,EAC3C,GAAIP,EAAI,MAAQ,CAAE,GAAGA,EAAI,IAAK,CAChC,EACAK,EAAK,CACP,CACF,CACF,CAGA,IAAOb,EAAQD",
6
- "names": ["controller_exports", "__export", "AsyncController", "controller_default", "__toCommonJS", "import_ErrorHandler", "import_utils", "import_filtersTypeEnum", "import_personalisationUtils", "layoutPath", "services", "req", "res", "_next", "response", "UserReportsListUtils", "next", "PersonalisationUtils", "error", "ErrorHandler"]
4
+ "sourcesContent": ["import { RequestHandler } from 'express'\nimport ErrorHandler from '../../../../utils/ErrorHandler'\nimport { Services } from '../../../../types/Services'\nimport UserReportsListUtils from '../../../../components/user-reports/utils'\nimport { FiltersType } from '../../../../components/_filters/filtersTypeEnum'\nimport PersonalisationUtils from '../../../../utils/Personalisation/personalisationUtils'\n\nclass AsyncController {\n layoutPath: string\n\n services: Services\n\n constructor(layoutPath: string, services: Services) {\n this.layoutPath = layoutPath\n this.services = services\n }\n\n POST: RequestHandler = async (req, res, _next) => {\n try {\n const response = await UserReportsListUtils.updateExpiredStatus({\n req,\n res,\n services: this.services,\n })\n res.send({ isExpired: response })\n } catch (error) {\n res.send({ status: 'FAILED' })\n }\n }\n\n saveDefaultFilterValues: RequestHandler = async (req, res, next) => {\n try {\n PersonalisationUtils.saveDefaults(FiltersType.INTERACTIVE, res, req, this.services)\n res.redirect(`${req.baseUrl}?defaultsSaved=true`)\n } catch (error) {\n req.body = {\n title: 'Failed to save defaults',\n error: new ErrorHandler(error).formatError(),\n ...(req.body && { ...req.body }),\n }\n next(error)\n }\n }\n\n removeDefaultFilterValues: RequestHandler = async (req, res, next) => {\n try {\n PersonalisationUtils.removeDefaults(FiltersType.INTERACTIVE, res, req, this.services)\n res.redirect(req.baseUrl)\n } catch (error) {\n req.body = {\n title: 'Failed to remove defaults',\n error: new ErrorHandler(error).formatError(),\n ...(req.body && { ...req.body }),\n }\n next(error)\n }\n }\n}\n\nexport { AsyncController }\nexport default AsyncController\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,0BAAyB;AAEzB,mBAAiC;AACjC,6BAA4B;AAC5B,kCAAiC;AAEjC,MAAM,gBAAgB;AAAA,EACpB;AAAA,EAEA;AAAA,EAEA,YAAY,YAAoB,UAAoB;AAClD,SAAK,aAAa;AAClB,SAAK,WAAW;AAAA,EAClB;AAAA,EAEA,OAAuB,OAAO,KAAK,KAAK,UAAU;AAChD,QAAI;AACF,YAAM,WAAW,MAAM,aAAAA,QAAqB,oBAAoB;AAAA,QAC9D;AAAA,QACA;AAAA,QACA,UAAU,KAAK;AAAA,MACjB,CAAC;AACD,UAAI,KAAK,EAAE,WAAW,SAAS,CAAC;AAAA,IAClC,SAAS,OAAO;AACd,UAAI,KAAK,EAAE,QAAQ,SAAS,CAAC;AAAA,IAC/B;AAAA,EACF;AAAA,EAEA,0BAA0C,OAAO,KAAK,KAAK,SAAS;AAClE,QAAI;AACF,kCAAAC,QAAqB,aAAa,mCAAY,aAAa,KAAK,KAAK,KAAK,QAAQ;AAClF,UAAI,SAAS,GAAG,IAAI,OAAO,qBAAqB;AAAA,IAClD,SAAS,OAAO;AACd,UAAI,OAAO;AAAA,QACT,OAAO;AAAA,QACP,OAAO,IAAI,oBAAAC,QAAa,KAAK,EAAE,YAAY;AAAA,QAC3C,GAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,KAAK;AAAA,MAChC;AACA,WAAK,KAAK;AAAA,IACZ;AAAA,EACF;AAAA,EAEA,4BAA4C,OAAO,KAAK,KAAK,SAAS;AACpE,QAAI;AACF,kCAAAD,QAAqB,eAAe,mCAAY,aAAa,KAAK,KAAK,KAAK,QAAQ;AACpF,UAAI,SAAS,IAAI,OAAO;AAAA,IAC1B,SAAS,OAAO;AACd,UAAI,OAAO;AAAA,QACT,OAAO;AAAA,QACP,OAAO,IAAI,oBAAAC,QAAa,KAAK,EAAE,YAAY;AAAA,QAC3C,GAAI,IAAI,QAAQ,EAAE,GAAG,IAAI,KAAK;AAAA,MAChC;AACA,WAAK,KAAK;AAAA,IACZ;AAAA,EACF;AACF;AAGA,IAAO,qBAAQ;",
6
+ "names": ["UserReportsListUtils", "PersonalisationUtils", "ErrorHandler"]
7
7
  }
@@ -38,7 +38,7 @@ class AsyncController {
38
38
  error: new ErrorHandler(error).formatError(),
39
39
  ...(req.body && { ...req.body }),
40
40
  }
41
- next()
41
+ next(error)
42
42
  }
43
43
  }
44
44
 
@@ -52,7 +52,7 @@ class AsyncController {
52
52
  error: new ErrorHandler(error).formatError(),
53
53
  ...(req.body && { ...req.body }),
54
54
  }
55
- next()
55
+ next(error)
56
56
  }
57
57
  }
58
58
  }
@@ -1,2 +1,83 @@
1
- "use strict";var v=Object.create;var i=Object.defineProperty;var b=Object.getOwnPropertyDescriptor;var w=Object.getOwnPropertyNames;var E=Object.getPrototypeOf,D=Object.prototype.hasOwnProperty;var H=(t,r)=>{for(var e in r)i(t,e,{get:r[e],enumerable:!0})},p=(t,r,e,a)=>{if(r&&typeof r=="object"||typeof r=="function")for(let s of w(r))!D.call(t,s)&&s!==e&&i(t,s,{get:()=>r[s],enumerable:!(a=b(r,s))||a.enumerable});return t};var c=(t,r,e)=>(e=t!=null?v(E(t)):{},p(r||!t||!t.__esModule?i(e,"default",{value:t,enumerable:!0}):e,t)),P=t=>p(i({},"__esModule",{value:!0}),t);var S={};H(S,{ViewAsyncDashboardController:()=>n,default:()=>R});module.exports=P(S);var y=c(require("../../../../../utils/ErrorHandler")),h=c(require("../../../../../utils/localsHelper")),m=c(require("./utils")),u=c(require("../../utils"));class n{layoutPath;services;constructor(r,e){this.layoutPath=r,this.services=e}GET=async(r,e,a)=>{const{type:s}=r.params;try{const d={req:r,res:e,services:this.services,next:a},o=await m.default.renderAsyncDashboard(d);e.render("dpr/routes/journeys/view-report/dashboard",{layoutPath:this.layoutPath,...o})}catch(d){const o=new y.default(d).formatError();let l;if(o.status==="EXPIRED"){const{dprUser:f}=h.default.getValues(e);l=await this.services.recentlyViewedService.asyncSetToExpiredByTableId(r.params.tableId,f.id)}r.body??={},r.body.title=`Failed to retrieve ${s}`,r.body.error=o,l&&(r.body.refreshLink=l),a()}};applyFilters=async(r,e,a)=>{await u.default.applyDashboardInteractiveQuery(r,e,this.services,"filters")}}var R=n;0&&(module.exports={ViewAsyncDashboardController});
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var controller_exports = {};
30
+ __export(controller_exports, {
31
+ ViewAsyncDashboardController: () => ViewAsyncDashboardController,
32
+ default: () => controller_default
33
+ });
34
+ module.exports = __toCommonJS(controller_exports);
35
+ var import_ErrorHandler = __toESM(require("../../../../../utils/ErrorHandler"));
36
+ var import_localsHelper = __toESM(require("../../../../../utils/localsHelper"));
37
+ var import_utils = __toESM(require("./utils"));
38
+ var import_utils2 = __toESM(require("../../utils"));
39
+ class ViewAsyncDashboardController {
40
+ layoutPath;
41
+ services;
42
+ constructor(layoutPath, services) {
43
+ this.layoutPath = layoutPath;
44
+ this.services = services;
45
+ }
46
+ GET = async (req, res, next) => {
47
+ const { type } = req.params;
48
+ try {
49
+ const params = { req, res, services: this.services, next };
50
+ const renderData = await import_utils.default.renderAsyncDashboard(params);
51
+ res.render(`dpr/routes/journeys/view-report/dashboard`, {
52
+ layoutPath: this.layoutPath,
53
+ ...renderData
54
+ });
55
+ } catch (error) {
56
+ const dprError = new import_ErrorHandler.default(error).formatError();
57
+ let refreshLink;
58
+ if (dprError.status === "EXPIRED") {
59
+ const { dprUser } = import_localsHelper.default.getValues(res);
60
+ refreshLink = await this.services.recentlyViewedService.asyncSetToExpiredByTableId(
61
+ req.params["tableId"],
62
+ dprUser.id
63
+ );
64
+ }
65
+ req.body ??= {};
66
+ req.body.title = `Failed to retrieve ${type}`;
67
+ req.body.error = dprError;
68
+ if (refreshLink) {
69
+ req.body.refreshLink = refreshLink;
70
+ }
71
+ next(error);
72
+ }
73
+ };
74
+ applyFilters = async (req, res, _next) => {
75
+ await import_utils2.default.applyDashboardInteractiveQuery(req, res, this.services, "filters");
76
+ };
77
+ }
78
+ var controller_default = ViewAsyncDashboardController;
79
+ // Annotate the CommonJS export names for ESM import in node:
80
+ 0 && (module.exports = {
81
+ ViewAsyncDashboardController
82
+ });
2
83
  //# sourceMappingURL=controller.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../src/dpr/routes/journeys/view-report/async/dashboard/controller.ts"],
4
- "sourcesContent": ["import { RequestHandler } from 'express'\nimport ErrorHandler from '../../../../../utils/ErrorHandler'\nimport { Services } from '../../../../../types/Services'\nimport LocalsHelper from '../../../../../utils/localsHelper'\nimport DashboardUtils from './utils'\nimport ViewReportUtils from '../../utils'\n\nclass ViewAsyncDashboardController {\n layoutPath: string\n\n services: Services\n\n constructor(layoutPath: string, services: Services) {\n this.layoutPath = layoutPath\n this.services = services\n }\n\n GET: RequestHandler = async (req, res, next) => {\n const { type } = req.params\n try {\n const params = { req, res, services: this.services, next }\n\n const renderData = await DashboardUtils.renderAsyncDashboard(params)\n\n res.render(`dpr/routes/journeys/view-report/dashboard`, {\n layoutPath: this.layoutPath,\n ...renderData,\n })\n } catch (error) {\n const dprError = new ErrorHandler(error).formatError()\n let refreshLink\n if (dprError.status === 'EXPIRED') {\n const { dprUser } = LocalsHelper.getValues(res)\n refreshLink = await this.services.recentlyViewedService.asyncSetToExpiredByTableId(\n req.params['tableId'],\n dprUser.id,\n )\n }\n req.body ??= {}\n req.body.title = `Failed to retrieve ${type}`\n req.body.error = dprError\n if (refreshLink) {\n req.body.refreshLink = refreshLink\n }\n next()\n }\n }\n\n applyFilters: RequestHandler = async (req, res, _next) => {\n await ViewReportUtils.applyDashboardInteractiveQuery(req, res, this.services, 'filters')\n }\n}\n\nexport { ViewAsyncDashboardController }\nexport default ViewAsyncDashboardController\n"],
5
- "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,kCAAAE,EAAA,YAAAC,IAAA,eAAAC,EAAAJ,GACA,IAAAK,EAAyB,gDAEzBC,EAAyB,gDACzBC,EAA2B,sBAC3BA,EAA4B,0BAE5B,MAAML,CAA6B,CACjC,WAEA,SAEA,YAAYM,EAAoBC,EAAoB,CAClD,KAAK,WAAaD,EAClB,KAAK,SAAWC,CAClB,CAEA,IAAsB,MAAOC,EAAKC,EAAKC,IAAS,CAC9C,KAAM,CAAE,KAAAC,CAAK,EAAIH,EAAI,OACrB,GAAI,CACF,MAAMI,EAAS,CAAE,IAAAJ,EAAK,IAAAC,EAAK,SAAU,KAAK,SAAU,KAAAC,CAAK,EAEnDG,EAAa,MAAM,EAAAC,QAAe,qBAAqBF,CAAM,EAEnEH,EAAI,OAAO,4CAA6C,CACtD,WAAY,KAAK,WACjB,GAAGI,CACL,CAAC,CACH,OAASE,EAAO,CACd,MAAMC,EAAW,IAAI,EAAAC,QAAaF,CAAK,EAAE,YAAY,EACrD,IAAIG,EACJ,GAAIF,EAAS,SAAW,UAAW,CACjC,KAAM,CAAE,QAAAG,CAAQ,EAAI,EAAAC,QAAa,UAAUX,CAAG,EAC9CS,EAAc,MAAM,KAAK,SAAS,sBAAsB,2BACtDV,EAAI,OAAO,QACXW,EAAQ,EACV,CACF,CACAX,EAAI,OAAS,CAAC,EACdA,EAAI,KAAK,MAAQ,sBAAsBG,CAAI,GAC3CH,EAAI,KAAK,MAAQQ,EACbE,IACFV,EAAI,KAAK,YAAcU,GAEzBR,EAAK,CACP,CACF,EAEA,aAA+B,MAAOF,EAAKC,EAAKY,IAAU,CACxD,MAAM,EAAAC,QAAgB,+BAA+Bd,EAAKC,EAAK,KAAK,SAAU,SAAS,CACzF,CACF,CAGA,IAAOR,EAAQD",
6
- "names": ["controller_exports", "__export", "ViewAsyncDashboardController", "controller_default", "__toCommonJS", "import_ErrorHandler", "import_localsHelper", "import_utils", "layoutPath", "services", "req", "res", "next", "type", "params", "renderData", "DashboardUtils", "error", "dprError", "ErrorHandler", "refreshLink", "dprUser", "LocalsHelper", "_next", "ViewReportUtils"]
4
+ "sourcesContent": ["import { RequestHandler } from 'express'\nimport ErrorHandler from '../../../../../utils/ErrorHandler'\nimport { Services } from '../../../../../types/Services'\nimport LocalsHelper from '../../../../../utils/localsHelper'\nimport DashboardUtils from './utils'\nimport ViewReportUtils from '../../utils'\n\nclass ViewAsyncDashboardController {\n layoutPath: string\n\n services: Services\n\n constructor(layoutPath: string, services: Services) {\n this.layoutPath = layoutPath\n this.services = services\n }\n\n GET: RequestHandler = async (req, res, next) => {\n const { type } = req.params\n try {\n const params = { req, res, services: this.services, next }\n\n const renderData = await DashboardUtils.renderAsyncDashboard(params)\n\n res.render(`dpr/routes/journeys/view-report/dashboard`, {\n layoutPath: this.layoutPath,\n ...renderData,\n })\n } catch (error) {\n const dprError = new ErrorHandler(error).formatError()\n let refreshLink\n if (dprError.status === 'EXPIRED') {\n const { dprUser } = LocalsHelper.getValues(res)\n refreshLink = await this.services.recentlyViewedService.asyncSetToExpiredByTableId(\n req.params['tableId'],\n dprUser.id,\n )\n }\n req.body ??= {}\n req.body.title = `Failed to retrieve ${type}`\n req.body.error = dprError\n if (refreshLink) {\n req.body.refreshLink = refreshLink\n }\n next(error)\n }\n }\n\n applyFilters: RequestHandler = async (req, res, _next) => {\n await ViewReportUtils.applyDashboardInteractiveQuery(req, res, this.services, 'filters')\n }\n}\n\nexport { ViewAsyncDashboardController }\nexport default ViewAsyncDashboardController\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,0BAAyB;AAEzB,0BAAyB;AACzB,mBAA2B;AAC3B,IAAAA,gBAA4B;AAE5B,MAAM,6BAA6B;AAAA,EACjC;AAAA,EAEA;AAAA,EAEA,YAAY,YAAoB,UAAoB;AAClD,SAAK,aAAa;AAClB,SAAK,WAAW;AAAA,EAClB;AAAA,EAEA,MAAsB,OAAO,KAAK,KAAK,SAAS;AAC9C,UAAM,EAAE,KAAK,IAAI,IAAI;AACrB,QAAI;AACF,YAAM,SAAS,EAAE,KAAK,KAAK,UAAU,KAAK,UAAU,KAAK;AAEzD,YAAM,aAAa,MAAM,aAAAC,QAAe,qBAAqB,MAAM;AAEnE,UAAI,OAAO,6CAA6C;AAAA,QACtD,YAAY,KAAK;AAAA,QACjB,GAAG;AAAA,MACL,CAAC;AAAA,IACH,SAAS,OAAO;AACd,YAAM,WAAW,IAAI,oBAAAC,QAAa,KAAK,EAAE,YAAY;AACrD,UAAI;AACJ,UAAI,SAAS,WAAW,WAAW;AACjC,cAAM,EAAE,QAAQ,IAAI,oBAAAC,QAAa,UAAU,GAAG;AAC9C,sBAAc,MAAM,KAAK,SAAS,sBAAsB;AAAA,UACtD,IAAI,OAAO,SAAS;AAAA,UACpB,QAAQ;AAAA,QACV;AAAA,MACF;AACA,UAAI,SAAS,CAAC;AACd,UAAI,KAAK,QAAQ,sBAAsB,IAAI;AAC3C,UAAI,KAAK,QAAQ;AACjB,UAAI,aAAa;AACf,YAAI,KAAK,cAAc;AAAA,MACzB;AACA,WAAK,KAAK;AAAA,IACZ;AAAA,EACF;AAAA,EAEA,eAA+B,OAAO,KAAK,KAAK,UAAU;AACxD,UAAM,cAAAC,QAAgB,+BAA+B,KAAK,KAAK,KAAK,UAAU,SAAS;AAAA,EACzF;AACF;AAGA,IAAO,qBAAQ;",
6
+ "names": ["import_utils", "DashboardUtils", "ErrorHandler", "LocalsHelper", "ViewReportUtils"]
7
7
  }
@@ -42,7 +42,7 @@ class ViewAsyncDashboardController {
42
42
  if (refreshLink) {
43
43
  req.body.refreshLink = refreshLink
44
44
  }
45
- next()
45
+ next(error)
46
46
  }
47
47
  }
48
48
 
@@ -1,2 +1,49 @@
1
- "use strict";var c=Object.create;var i=Object.defineProperty;var m=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var f=Object.getPrototypeOf,y=Object.prototype.hasOwnProperty;var g=(r,e)=>{for(var t in e)i(r,t,{get:e[t],enumerable:!0})},l=(r,e,t,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of u(e))!y.call(r,s)&&s!==t&&i(r,s,{get:()=>e[s],enumerable:!(o=m(e,s))||o.enumerable});return r};var v=(r,e,t)=>(t=r!=null?c(f(r)):{},l(e||!r||!r.__esModule?i(t,"default",{value:r,enumerable:!0}):t,r)),d=r=>l(i({},"__esModule",{value:!0}),r);var w={};g(w,{default:()=>h,routes:()=>a});module.exports=d(w);var n=require("express"),p=v(require("./controller"));function a({layoutPath:r,services:e}){const t=(0,n.Router)({mergeParams:!0}),o=new p.default(r,e);return t.get("/",o.GET),t.post("/apply-filters",o.applyFilters),t}var h=a;0&&(module.exports={routes});
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var routes_exports = {};
30
+ __export(routes_exports, {
31
+ default: () => routes_default,
32
+ routes: () => routes
33
+ });
34
+ module.exports = __toCommonJS(routes_exports);
35
+ var import_express = require("express");
36
+ var import_controller = __toESM(require("./controller"));
37
+ function routes({ layoutPath, services }) {
38
+ const router = (0, import_express.Router)({ mergeParams: true });
39
+ const controller = new import_controller.default(layoutPath, services);
40
+ router.get(`/`, controller.GET);
41
+ router.post("/apply-filters", controller.applyFilters);
42
+ return router;
43
+ }
44
+ var routes_default = routes;
45
+ // Annotate the CommonJS export names for ESM import in node:
46
+ 0 && (module.exports = {
47
+ routes
48
+ });
2
49
  //# sourceMappingURL=routes.js.map
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../src/dpr/routes/journeys/view-report/async/dashboard/routes.ts"],
4
4
  "sourcesContent": ["/* eslint-disable no-param-reassign */\nimport { Router } from 'express'\nimport ViewAsyncDashboardController from './controller'\nimport { Services } from '../../../../../types/Services'\n\nexport function routes({ layoutPath, services }: { layoutPath: string; services: Services }) {\n const router = Router({ mergeParams: true })\n const controller = new ViewAsyncDashboardController(layoutPath, services)\n\n router.get(`/`, controller.GET)\n router.post('/apply-filters', controller.applyFilters)\n\n return router\n}\n\nexport default routes\n"],
5
- "mappings": "0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,aAAAE,EAAA,WAAAC,IAAA,eAAAC,EAAAJ,GACA,IAAAK,EAAuB,mBACvBC,EAAyC,2BAGlC,SAASH,EAAO,CAAE,WAAAI,EAAY,SAAAC,CAAS,EAA+C,CAC3F,MAAMC,KAAS,UAAO,CAAE,YAAa,EAAK,CAAC,EACrCC,EAAa,IAAI,EAAAC,QAA6BJ,EAAYC,CAAQ,EAExE,OAAAC,EAAO,IAAI,IAAKC,EAAW,GAAG,EAC9BD,EAAO,KAAK,iBAAkBC,EAAW,YAAY,EAE9CD,CACT,CAEA,IAAOP,EAAQC",
6
- "names": ["routes_exports", "__export", "routes_default", "routes", "__toCommonJS", "import_express", "import_controller", "layoutPath", "services", "router", "controller", "ViewAsyncDashboardController"]
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,qBAAuB;AACvB,wBAAyC;AAGlC,SAAS,OAAO,EAAE,YAAY,SAAS,GAA+C;AAC3F,QAAM,aAAS,uBAAO,EAAE,aAAa,KAAK,CAAC;AAC3C,QAAM,aAAa,IAAI,kBAAAA,QAA6B,YAAY,QAAQ;AAExE,SAAO,IAAI,KAAK,WAAW,GAAG;AAC9B,SAAO,KAAK,kBAAkB,WAAW,YAAY;AAErD,SAAO;AACT;AAEA,IAAO,iBAAQ;",
6
+ "names": ["ViewAsyncDashboardController"]
7
7
  }
@@ -1,2 +1,34 @@
1
- "use strict";var e=require("../../../../../../../cypress-tests/cypressUtils");context("Viewing a report",()=>{const t="/embedded/platform/";describe("dashboard tests",()=>{before(()=>{(0,e.executeDashboardStubs)(),cy.task("stubTestDashboard8"),cy.task("stubDashboardSuccessResult20")}),it("should mark the dashboard as recently viewed",()=>{cy.visit(t),cy.findByRole("tab",{name:/Viewed \(0\)/}).should("be.visible"),(0,e.checkA11y)(),cy.findByLabelText(/Reports catalogue.*/i).within(()=>{cy.findByRole("row",{name:(a,s)=>!!s.textContent?.includes("Test Dashboard")&&!!s.textContent?.includes("Dashboard used for testing testing")}).within(()=>{cy.findByRole("link",{name:"Request dashboard"}).click()})}),(0,e.checkA11y)(),cy.findByRole("button",{name:/Request/}).click(),(0,e.checkA11y)(),cy.findByRole("heading",{level:1,name:/Test Dashboard/}).should("be.visible"),(0,e.checkA11y)(),cy.visit(t),cy.findByRole("tab",{name:/Viewed \(1\)/}).should("be.visible")})})});
1
+ "use strict";
2
+ var import_cypressUtils = require("../../../../../../../cypress-tests/cypressUtils");
3
+ context("Viewing a report", () => {
4
+ const path = "/embedded/platform/";
5
+ describe("dashboard tests", () => {
6
+ before(() => {
7
+ (0, import_cypressUtils.executeDashboardStubs)();
8
+ cy.task("stubTestDashboard8");
9
+ cy.task("stubDashboardSuccessResult20");
10
+ });
11
+ it("should mark the dashboard as recently viewed", () => {
12
+ cy.visit(path);
13
+ cy.findByRole("tab", { name: /Viewed \(0\)/ }).should("be.visible");
14
+ (0, import_cypressUtils.checkA11y)();
15
+ cy.findByLabelText(/Reports catalogue.*/i).within(() => {
16
+ cy.findByRole("row", {
17
+ name: (_, element) => {
18
+ return Boolean(element.textContent?.includes("Test Dashboard")) && Boolean(element.textContent?.includes("Dashboard used for testing testing"));
19
+ }
20
+ }).within(() => {
21
+ cy.findByRole("link", { name: "Request dashboard" }).click();
22
+ });
23
+ });
24
+ (0, import_cypressUtils.checkA11y)();
25
+ cy.findByRole("button", { name: /Request/ }).click();
26
+ (0, import_cypressUtils.checkA11y)();
27
+ cy.findByRole("heading", { level: 1, name: /Test Dashboard/ }).should("be.visible");
28
+ (0, import_cypressUtils.checkA11y)();
29
+ cy.visit(path);
30
+ cy.findByRole("tab", { name: /Viewed \(1\)/ }).should("be.visible");
31
+ });
32
+ });
33
+ });
2
34
  //# sourceMappingURL=tests.cy.js.map
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../src/dpr/routes/journeys/view-report/async/dashboard/tests.cy.ts"],
4
4
  "sourcesContent": ["import { checkA11y, executeDashboardStubs } from '../../../../../../../cypress-tests/cypressUtils'\n\ncontext('Viewing a report', () => {\n const path = '/embedded/platform/'\n\n describe('dashboard tests', () => {\n before(() => {\n executeDashboardStubs()\n cy.task('stubTestDashboard8')\n cy.task('stubDashboardSuccessResult20')\n })\n\n it('should mark the dashboard as recently viewed', () => {\n // Request and run a report so we can go back to it for each test\n cy.visit(path)\n cy.findByRole('tab', { name: /Viewed \\(0\\)/ }).should('be.visible')\n checkA11y()\n cy.findByLabelText(/Reports catalogue.*/i).within(() => {\n cy.findByRole('row', {\n name: (_, element) => {\n return (\n Boolean(element.textContent?.includes('Test Dashboard')) &&\n Boolean(element.textContent?.includes('Dashboard used for testing testing'))\n )\n },\n }).within(() => {\n cy.findByRole('link', { name: 'Request dashboard' }).click()\n })\n })\n checkA11y()\n cy.findByRole('button', { name: /Request/ }).click()\n checkA11y()\n cy.findByRole('heading', { level: 1, name: /Test Dashboard/ }).should('be.visible')\n checkA11y()\n cy.visit(path)\n cy.findByRole('tab', { name: /Viewed \\(1\\)/ }).should('be.visible')\n })\n })\n})\n"],
5
- "mappings": "aAAA,IAAAA,EAAiD,2DAEjD,QAAQ,mBAAoB,IAAM,CAChC,MAAMC,EAAO,sBAEb,SAAS,kBAAmB,IAAM,CAChC,OAAO,IAAM,IACX,yBAAsB,EACtB,GAAG,KAAK,oBAAoB,EAC5B,GAAG,KAAK,8BAA8B,CACxC,CAAC,EAED,GAAG,+CAAgD,IAAM,CAEvD,GAAG,MAAMA,CAAI,EACb,GAAG,WAAW,MAAO,CAAE,KAAM,cAAe,CAAC,EAAE,OAAO,YAAY,KAClE,aAAU,EACV,GAAG,gBAAgB,sBAAsB,EAAE,OAAO,IAAM,CACtD,GAAG,WAAW,MAAO,CACnB,KAAM,CAACC,EAAGC,IAEN,EAAQA,EAAQ,aAAa,SAAS,gBAAgB,GACtD,EAAQA,EAAQ,aAAa,SAAS,oCAAoC,CAGhF,CAAC,EAAE,OAAO,IAAM,CACd,GAAG,WAAW,OAAQ,CAAE,KAAM,mBAAoB,CAAC,EAAE,MAAM,CAC7D,CAAC,CACH,CAAC,KACD,aAAU,EACV,GAAG,WAAW,SAAU,CAAE,KAAM,SAAU,CAAC,EAAE,MAAM,KACnD,aAAU,EACV,GAAG,WAAW,UAAW,CAAE,MAAO,EAAG,KAAM,gBAAiB,CAAC,EAAE,OAAO,YAAY,KAClF,aAAU,EACV,GAAG,MAAMF,CAAI,EACb,GAAG,WAAW,MAAO,CAAE,KAAM,cAAe,CAAC,EAAE,OAAO,YAAY,CACpE,CAAC,CACH,CAAC,CACH,CAAC",
6
- "names": ["import_cypressUtils", "path", "_", "element"]
5
+ "mappings": ";AAAA,0BAAiD;AAEjD,QAAQ,oBAAoB,MAAM;AAChC,QAAM,OAAO;AAEb,WAAS,mBAAmB,MAAM;AAChC,WAAO,MAAM;AACX,qDAAsB;AACtB,SAAG,KAAK,oBAAoB;AAC5B,SAAG,KAAK,8BAA8B;AAAA,IACxC,CAAC;AAED,OAAG,gDAAgD,MAAM;AAEvD,SAAG,MAAM,IAAI;AACb,SAAG,WAAW,OAAO,EAAE,MAAM,eAAe,CAAC,EAAE,OAAO,YAAY;AAClE,yCAAU;AACV,SAAG,gBAAgB,sBAAsB,EAAE,OAAO,MAAM;AACtD,WAAG,WAAW,OAAO;AAAA,UACnB,MAAM,CAAC,GAAG,YAAY;AACpB,mBACE,QAAQ,QAAQ,aAAa,SAAS,gBAAgB,CAAC,KACvD,QAAQ,QAAQ,aAAa,SAAS,oCAAoC,CAAC;AAAA,UAE/E;AAAA,QACF,CAAC,EAAE,OAAO,MAAM;AACd,aAAG,WAAW,QAAQ,EAAE,MAAM,oBAAoB,CAAC,EAAE,MAAM;AAAA,QAC7D,CAAC;AAAA,MACH,CAAC;AACD,yCAAU;AACV,SAAG,WAAW,UAAU,EAAE,MAAM,UAAU,CAAC,EAAE,MAAM;AACnD,yCAAU;AACV,SAAG,WAAW,WAAW,EAAE,OAAO,GAAG,MAAM,iBAAiB,CAAC,EAAE,OAAO,YAAY;AAClF,yCAAU;AACV,SAAG,MAAM,IAAI;AACb,SAAG,WAAW,OAAO,EAAE,MAAM,eAAe,CAAC,EAAE,OAAO,YAAY;AAAA,IACpE,CAAC;AAAA,EACH,CAAC;AACH,CAAC;",
6
+ "names": []
7
7
  }
@@ -1,2 +1,243 @@
1
- "use strict";var Q=Object.create;var y=Object.defineProperty;var J=Object.getOwnPropertyDescriptor;var W=Object.getOwnPropertyNames;var X=Object.getPrototypeOf,j=Object.prototype.hasOwnProperty;var z=(e,t)=>{for(var r in t)y(e,r,{get:t[r],enumerable:!0})},q=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of W(t))!j.call(e,i)&&i!==r&&y(e,i,{get:()=>t[i],enumerable:!(o=J(t,i))||o.enumerable});return e};var c=(e,t,r)=>(r=e!=null?Q(X(e)):{},q(t||!e||!e.__esModule?y(r,"default",{value:e,enumerable:!0}):r,e)),K=e=>q(y({},"__esModule",{value:!0}),e);var ee={};z(ee,{default:()=>$,renderAsyncDashboard:()=>M});module.exports=K(ee);var l=require("../../../../../components/_dashboards/dashboard-visualisation/types"),g=require("../../../../../types/UserReports"),I=c(require("../../../../../components/_charts/utils")),F=c(require("../../../../../utils/definitionUtils")),P=c(require("../../../../../components/user-reports/utils")),C=c(require("../../../../../components/_dashboards/dashboard-list/utils")),w=c(require("../../../../../components/_filters/utils")),B=c(require("../../../../../components/_dashboards/scorecard/utils")),L=c(require("../../../../../components/_dashboards/scorecard/Scorecard")),N=c(require("../../../../../components/_dashboards/scorecard-group/ScorecardGroup")),O=c(require("../../../../../components/_reports/report-actions/utils")),v=c(require("../../../../../types/ReportQuery")),A=c(require("../../../../../utils/localsHelper")),x=require("../../../../../components/_filters/filtersTypeEnum"),G=require("../../../../../components/_filters/filter-input/enum");const V=(e,t,r)=>{const o=t.name,{name:i}=e,s=r?.url?.request?.fullUrl,p=r?.executionId;let a={};return s&&(a={share:{reportName:o,name:i,url:s},copy:{url:s}},p&&(a={...a,refresh:{url:s,executionId:p}})),O.default.getActions(a)},k=async({req:e,res:t,services:r,queryData:o})=>{const{token:i}=A.default.getValues(t),{reportId:s,id:p}=e.params,a=e.query.dataProductDefinitionsPath,d=await r.dashboardService.getDefinition(i,s,p,a,o),f=await F.default.getReportSummary(s,r.reportingService,i,a),n=await w.default.getFilters({fields:d.filterFields||[],req:e,filtersType:x.FiltersType.INTERACTIVE}),m=w.default.setRequestQueryFromFilterValues(n.filters);return{query:new v.default({fields:d.filterFields||[],queryParams:m,definitionsPath:a,reportType:g.ReportType.DASHBOARD}).toRecordWithFilterPrefix(!0),filters:n,dashboardDefinition:d,reportDefinition:f}},E=(e,t,r,o)=>e.sections.map(i=>{const{id:s,display:p,description:a}=i;let d=!1;const f=i.visualisations.map(n=>{const{type:m,display:R,description:D,id:b}=n;let u;switch(m){case l.DashboardVisualisationType.LIST:u=C.default.createList(n,t);break;case l.DashboardVisualisationType.SCORECARD:d=!0,u=new L.default().withDefinition(n).withData(t).build();break;case l.DashboardVisualisationType.SCORECARD_GROUP:u=new N.default().withDefinition(n).withData(t).build();break;case l.DashboardVisualisationType.BAR:case l.DashboardVisualisationType.LINE:case l.DashboardVisualisationType.DONUT:{u=I.default.createChart(n,t,m);break}case l.DashboardVisualisationType.MATRIX_TIMESERIES:case l.DashboardVisualisationType.BAR_TIMESERIES:case l.DashboardVisualisationType.LINE_TIMESERIES:{u=I.default.createTimeseriesCharts(n,t,m,r,o);break}default:break}return{id:b,title:R||"",description:D||"",type:m,data:u}});return d&&B.default.mergeScorecardsIntoGroup(f),{id:s,title:p||"",description:a||"",visualisations:f}}),Y=async(e,t,r,o,i,s)=>{const{requestedReportService:p}=e,a=await p.getReportByTableId(t,r);return o&&o.length&&a&&P.default.updateLastViewed({services:e,reportStateData:a,userId:r,req:i,filters:s}),a},Z=e=>{let t;const r=e.find(o=>o.type===G.FilterType.granularDateRange.toLowerCase());return r&&(t=r.value.partialDate),t},M=async({req:e,res:t,services:r})=>{const{token:o,csrfToken:i,dprUser:s,nestedBaseUrl:p}=A.default.getValues(t),{reportId:a,id:d,tableId:f}=e.params,{bookmarkService:n,requestedReportService:m}=r,{id:R}=s;let D=await m.getReportByTableId(f,R);const b=D?.query?.data,{query:u,filters:S,reportDefinition:T,dashboardDefinition:h}=await k({req:e,res:t,services:r,queryData:b}),_=(await r.dashboardService.getAsyncDashboard(o,d,a,f,u)).flat(),H=Z(S.filters),U=E(h,_,u,H);return m&&(D=await Y(r,f,s.id,U,e,S.filters)),{dashboardData:{token:o,id:d,reportId:a,name:h.name,description:h.description,reportName:T.name,bookmarked:await n.isBookmarked(d,a,s.id),nestedBaseUrl:p,csrfToken:i,sections:U,filters:S,type:g.ReportType.DASHBOARD,actions:V(h,T,D)}}};var $={renderAsyncDashboard:M,getDefinitionData:k,getSections:E,setDashboardActions:V};0&&(module.exports={renderAsyncDashboard});
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+ var utils_exports = {};
30
+ __export(utils_exports, {
31
+ default: () => utils_default,
32
+ renderAsyncDashboard: () => renderAsyncDashboard
33
+ });
34
+ module.exports = __toCommonJS(utils_exports);
35
+ var import_types = require("../../../../../components/_dashboards/dashboard-visualisation/types");
36
+ var import_UserReports = require("../../../../../types/UserReports");
37
+ var import_utils = __toESM(require("../../../../../components/_charts/utils"));
38
+ var import_definitionUtils = __toESM(require("../../../../../utils/definitionUtils"));
39
+ var import_utils2 = __toESM(require("../../../../../components/user-reports/utils"));
40
+ var import_utils3 = __toESM(require("../../../../../components/_dashboards/dashboard-list/utils"));
41
+ var import_utils4 = __toESM(require("../../../../../components/_filters/utils"));
42
+ var import_utils5 = __toESM(require("../../../../../components/_dashboards/scorecard/utils"));
43
+ var import_Scorecard = __toESM(require("../../../../../components/_dashboards/scorecard/Scorecard"));
44
+ var import_ScorecardGroup = __toESM(require("../../../../../components/_dashboards/scorecard-group/ScorecardGroup"));
45
+ var import_utils6 = __toESM(require("../../../../../components/_reports/report-actions/utils"));
46
+ var import_ReportQuery = __toESM(require("../../../../../types/ReportQuery"));
47
+ var import_localsHelper = __toESM(require("../../../../../utils/localsHelper"));
48
+ var import_filtersTypeEnum = require("../../../../../components/_filters/filtersTypeEnum");
49
+ var import_enum = require("../../../../../components/_filters/filter-input/enum");
50
+ const setDashboardActions = (dashboardDefinition, reportDefinition, requestData) => {
51
+ const reportName = reportDefinition.name;
52
+ const { name } = dashboardDefinition;
53
+ const actionsUrl = requestData?.url?.request?.fullUrl;
54
+ const executionId = requestData?.executionId;
55
+ let actions = {};
56
+ if (actionsUrl) {
57
+ actions = {
58
+ share: {
59
+ reportName,
60
+ name,
61
+ url: actionsUrl
62
+ },
63
+ copy: {
64
+ url: actionsUrl
65
+ }
66
+ };
67
+ if (executionId) {
68
+ actions = {
69
+ ...actions,
70
+ refresh: {
71
+ url: actionsUrl,
72
+ executionId
73
+ }
74
+ };
75
+ }
76
+ }
77
+ return import_utils6.default.getActions(actions);
78
+ };
79
+ const getDefinitionData = async ({
80
+ req,
81
+ res,
82
+ services,
83
+ queryData
84
+ }) => {
85
+ const { token } = import_localsHelper.default.getValues(res);
86
+ const { reportId, id } = req.params;
87
+ const dataProductDefinitionsPath = req.query["dataProductDefinitionsPath"];
88
+ const dashboardDefinition = await services.dashboardService.getDefinition(
89
+ token,
90
+ reportId,
91
+ id,
92
+ dataProductDefinitionsPath,
93
+ queryData
94
+ );
95
+ const reportDefinition = await import_definitionUtils.default.getReportSummary(
96
+ reportId,
97
+ services.reportingService,
98
+ token,
99
+ dataProductDefinitionsPath
100
+ );
101
+ const filtersData = await import_utils4.default.getFilters({
102
+ fields: dashboardDefinition.filterFields || [],
103
+ req,
104
+ filtersType: import_filtersTypeEnum.FiltersType.INTERACTIVE
105
+ });
106
+ const filtersQuery = import_utils4.default.setRequestQueryFromFilterValues(filtersData.filters);
107
+ const query = new import_ReportQuery.default({
108
+ fields: dashboardDefinition.filterFields || [],
109
+ queryParams: filtersQuery,
110
+ definitionsPath: dataProductDefinitionsPath,
111
+ reportType: import_UserReports.ReportType.DASHBOARD
112
+ }).toRecordWithFilterPrefix(true);
113
+ return {
114
+ query,
115
+ filters: filtersData,
116
+ dashboardDefinition,
117
+ reportDefinition
118
+ };
119
+ };
120
+ const getSections = (dashboardDefinition, dashboardData, query, partialDate) => {
121
+ return dashboardDefinition.sections.map((section) => {
122
+ const { id, display: title, description } = section;
123
+ let hasScorecard = false;
124
+ const visualisations = section.visualisations.map(
125
+ (visDefinition) => {
126
+ const { type, display, description: visDescription, id: visId } = visDefinition;
127
+ let data;
128
+ switch (type) {
129
+ case import_types.DashboardVisualisationType.LIST:
130
+ data = import_utils3.default.createList(visDefinition, dashboardData);
131
+ break;
132
+ case import_types.DashboardVisualisationType.SCORECARD:
133
+ hasScorecard = true;
134
+ data = new import_Scorecard.default().withDefinition(visDefinition).withData(dashboardData).build();
135
+ break;
136
+ case import_types.DashboardVisualisationType.SCORECARD_GROUP:
137
+ data = new import_ScorecardGroup.default().withDefinition(visDefinition).withData(dashboardData).build();
138
+ break;
139
+ case import_types.DashboardVisualisationType.BAR:
140
+ case import_types.DashboardVisualisationType.LINE:
141
+ case import_types.DashboardVisualisationType.DONUT: {
142
+ data = import_utils.default.createChart(visDefinition, dashboardData, type);
143
+ break;
144
+ }
145
+ case import_types.DashboardVisualisationType.MATRIX_TIMESERIES:
146
+ case import_types.DashboardVisualisationType.BAR_TIMESERIES:
147
+ case import_types.DashboardVisualisationType.LINE_TIMESERIES: {
148
+ data = import_utils.default.createTimeseriesCharts(visDefinition, dashboardData, type, query, partialDate);
149
+ break;
150
+ }
151
+ default:
152
+ break;
153
+ }
154
+ return {
155
+ id: visId,
156
+ title: display || "",
157
+ description: visDescription || "",
158
+ type,
159
+ data
160
+ };
161
+ }
162
+ );
163
+ if (hasScorecard) import_utils5.default.mergeScorecardsIntoGroup(visualisations);
164
+ return { id, title: title || "", description: description || "", visualisations };
165
+ });
166
+ };
167
+ const updateStore = async (services, tableId, userId, sections, req, filters) => {
168
+ const { requestedReportService } = services;
169
+ const dashboardRequestData = await requestedReportService.getReportByTableId(tableId, userId);
170
+ if (sections && sections.length && dashboardRequestData) {
171
+ import_utils2.default.updateLastViewed({
172
+ services,
173
+ reportStateData: dashboardRequestData,
174
+ userId,
175
+ req,
176
+ filters
177
+ });
178
+ }
179
+ return dashboardRequestData;
180
+ };
181
+ const getPartialDate = (filters) => {
182
+ let partialDate;
183
+ const granularDateRangeFilter = filters.find((f) => f.type === import_enum.FilterType.granularDateRange.toLowerCase());
184
+ if (granularDateRangeFilter) {
185
+ partialDate = granularDateRangeFilter.value.partialDate;
186
+ }
187
+ return partialDate;
188
+ };
189
+ const renderAsyncDashboard = async ({ req, res, services }) => {
190
+ const { token, csrfToken, dprUser, nestedBaseUrl } = import_localsHelper.default.getValues(res);
191
+ const { reportId, id, tableId } = req.params;
192
+ const { bookmarkService, requestedReportService } = services;
193
+ const { id: userId } = dprUser;
194
+ let requestData = await requestedReportService.getReportByTableId(tableId, userId);
195
+ const queryData = requestData?.query?.data;
196
+ const { query, filters, reportDefinition, dashboardDefinition } = await getDefinitionData({
197
+ req,
198
+ res,
199
+ services,
200
+ queryData
201
+ });
202
+ const dashboardData = await services.dashboardService.getAsyncDashboard(
203
+ token,
204
+ id,
205
+ reportId,
206
+ tableId,
207
+ query
208
+ );
209
+ const flattenedData = dashboardData.flat();
210
+ const partialDate = getPartialDate(filters.filters);
211
+ const sections = getSections(dashboardDefinition, flattenedData, query, partialDate);
212
+ if (requestedReportService) {
213
+ requestData = await updateStore(services, tableId, dprUser.id, sections, req, filters.filters);
214
+ }
215
+ return {
216
+ dashboardData: {
217
+ token,
218
+ id,
219
+ reportId,
220
+ name: dashboardDefinition.name,
221
+ description: dashboardDefinition.description,
222
+ reportName: reportDefinition.name,
223
+ bookmarked: await bookmarkService.isBookmarked(id, reportId, dprUser.id),
224
+ nestedBaseUrl,
225
+ csrfToken,
226
+ sections,
227
+ filters,
228
+ type: import_UserReports.ReportType.DASHBOARD,
229
+ actions: setDashboardActions(dashboardDefinition, reportDefinition, requestData)
230
+ }
231
+ };
232
+ };
233
+ var utils_default = {
234
+ renderAsyncDashboard,
235
+ getDefinitionData,
236
+ getSections,
237
+ setDashboardActions
238
+ };
239
+ // Annotate the CommonJS export names for ESM import in node:
240
+ 0 && (module.exports = {
241
+ renderAsyncDashboard
242
+ });
2
243
  //# sourceMappingURL=utils.js.map
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../src/dpr/routes/journeys/view-report/async/dashboard/utils.ts"],
4
4
  "sourcesContent": ["import { Request, Response } from 'express'\nimport { Services } from '../../../../../types/Services'\nimport Dict = NodeJS.Dict\nimport {\n DashboardSection,\n DashboardVisualisation,\n DashboardVisualisationType,\n} from '../../../../../components/_dashboards/dashboard-visualisation/types'\nimport type { AsyncReportUtilsParams } from '../../../../../types/AsyncReportUtils'\n\nimport type { DashboardDataResponse } from '../../../../../types/Metrics'\nimport type { RequestedReport } from '../../../../../types/UserReports'\nimport { ReportType } from '../../../../../types/UserReports'\nimport type { components } from '../../../../../types/api'\n\nimport ChartUtils from '../../../../../components/_charts/utils'\nimport DefinitionUtils from '../../../../../utils/definitionUtils'\nimport UserReportsUtils from '../../../../../components/user-reports/utils'\nimport DashboardListUtils from '../../../../../components/_dashboards/dashboard-list/utils'\nimport FilterUtils from '../../../../../components/_filters/utils'\nimport ScorecardsUtils from '../../../../../components/_dashboards/scorecard/utils'\nimport ScorecardVisualisation from '../../../../../components/_dashboards/scorecard/Scorecard'\nimport ScorecardGroupVisualisation from '../../../../../components/_dashboards/scorecard-group/ScorecardGroup'\nimport ReportActionsUtils from '../../../../../components/_reports/report-actions/utils'\nimport ReportQuery from '../../../../../types/ReportQuery'\nimport LocalsHelper from '../../../../../utils/localsHelper'\nimport { FilterValue, GranularDateRangeFilterValue, PartialDate } from '../../../../../components/_filters/types'\nimport { FiltersType } from '../../../../../components/_filters/filtersTypeEnum'\nimport { FilterType } from '../../../../../components/_filters/filter-input/enum'\n\nconst setDashboardActions = (\n dashboardDefinition: components['schemas']['DashboardDefinition'],\n reportDefinition: components['schemas']['ReportDefinitionSummary'],\n requestData?: RequestedReport,\n) => {\n const reportName = reportDefinition.name\n const { name } = dashboardDefinition\n const actionsUrl = requestData?.url?.request?.fullUrl\n const executionId = requestData?.executionId\n\n let actions = {}\n if (actionsUrl) {\n actions = {\n share: {\n reportName,\n name,\n url: actionsUrl,\n },\n copy: {\n url: actionsUrl,\n },\n }\n if (executionId) {\n actions = {\n ...actions,\n refresh: {\n url: actionsUrl,\n executionId,\n },\n }\n }\n }\n\n return ReportActionsUtils.getActions(actions)\n}\n\nconst getDefinitionData = async ({\n req,\n res,\n services,\n queryData,\n}: {\n req: Request\n res: Response\n services: Services\n queryData?: Dict<string | string[]> | undefined\n}) => {\n const { token } = LocalsHelper.getValues(res)\n const { reportId, id } = req.params\n const dataProductDefinitionsPath = <string>req.query['dataProductDefinitionsPath']\n\n // Dashboard Definition,\n const dashboardDefinition = await services.dashboardService.getDefinition(\n token,\n reportId,\n id,\n dataProductDefinitionsPath,\n queryData,\n )\n\n // Report summary data\n const reportDefinition = await DefinitionUtils.getReportSummary(\n reportId,\n services.reportingService,\n token,\n <string>dataProductDefinitionsPath,\n )\n\n // Get the filters\n const filtersData = await FilterUtils.getFilters({\n fields: dashboardDefinition.filterFields || [],\n req,\n filtersType: FiltersType.INTERACTIVE,\n })\n\n const filtersQuery = FilterUtils.setRequestQueryFromFilterValues(filtersData.filters)\n\n // Create the query\n const query = new ReportQuery({\n fields: dashboardDefinition.filterFields || [],\n queryParams: filtersQuery,\n definitionsPath: <string>dataProductDefinitionsPath,\n reportType: ReportType.DASHBOARD,\n }).toRecordWithFilterPrefix(true)\n\n return {\n query,\n filters: filtersData,\n dashboardDefinition,\n reportDefinition,\n }\n}\n\nconst getSections = (\n dashboardDefinition: components['schemas']['DashboardDefinition'],\n dashboardData: DashboardDataResponse[],\n query: Record<string, string | string[]>,\n partialDate?: PartialDate,\n): DashboardSection[] => {\n return dashboardDefinition.sections.map((section: components['schemas']['DashboardSectionDefinition']) => {\n const { id, display: title, description } = section\n\n let hasScorecard = false\n const visualisations: DashboardVisualisation[] = section.visualisations.map(\n (visDefinition: components['schemas']['DashboardVisualisationDefinition']) => {\n const { type, display, description: visDescription, id: visId } = visDefinition\n\n let data: DashboardVisualisation['data'] | undefined\n\n switch (type) {\n case DashboardVisualisationType.LIST:\n data = DashboardListUtils.createList(visDefinition, dashboardData)\n break\n\n case DashboardVisualisationType.SCORECARD:\n hasScorecard = true\n data = new ScorecardVisualisation().withDefinition(visDefinition).withData(dashboardData).build()\n break\n\n case DashboardVisualisationType.SCORECARD_GROUP:\n data = new ScorecardGroupVisualisation().withDefinition(visDefinition).withData(dashboardData).build()\n break\n\n case DashboardVisualisationType.BAR:\n case DashboardVisualisationType.LINE:\n case DashboardVisualisationType.DONUT: {\n data = ChartUtils.createChart(visDefinition, dashboardData, type)\n break\n }\n case DashboardVisualisationType.MATRIX_TIMESERIES:\n case DashboardVisualisationType.BAR_TIMESERIES:\n case DashboardVisualisationType.LINE_TIMESERIES: {\n data = ChartUtils.createTimeseriesCharts(visDefinition, dashboardData, type, query, partialDate)\n break\n }\n default:\n break\n }\n\n return {\n id: visId,\n title: display || '',\n description: visDescription || '',\n type,\n data,\n }\n },\n )\n\n if (hasScorecard) ScorecardsUtils.mergeScorecardsIntoGroup(visualisations)\n\n return { id, title: title || '', description: description || '', visualisations }\n })\n}\n\nconst updateStore = async (\n services: Services,\n tableId: string,\n userId: string,\n sections: DashboardSection[],\n req: Request,\n filters: FilterValue[],\n): Promise<RequestedReport | undefined> => {\n const { requestedReportService } = services\n const dashboardRequestData = await requestedReportService.getReportByTableId(tableId, userId)\n\n // Add to recently viewed\n if (sections && sections.length && dashboardRequestData) {\n UserReportsUtils.updateLastViewed({\n services,\n reportStateData: dashboardRequestData,\n userId,\n req,\n filters,\n })\n }\n\n return dashboardRequestData\n}\n\nconst getPartialDate = (filters: FilterValue[]) => {\n let partialDate: PartialDate | undefined\n const granularDateRangeFilter = <GranularDateRangeFilterValue | undefined>(\n filters.find((f) => f.type === FilterType.granularDateRange.toLowerCase())\n )\n if (granularDateRangeFilter) {\n partialDate = granularDateRangeFilter.value.partialDate\n }\n return partialDate\n}\n\nexport const renderAsyncDashboard = async ({ req, res, services }: AsyncReportUtilsParams) => {\n const { token, csrfToken, dprUser, nestedBaseUrl } = LocalsHelper.getValues(res)\n const { reportId, id, tableId } = req.params\n const { bookmarkService, requestedReportService } = services\n const { id: userId } = dprUser\n\n let requestData: RequestedReport | undefined = await requestedReportService.getReportByTableId(tableId, userId)\n const queryData = requestData?.query?.data\n\n // Get the definition Data\n const { query, filters, reportDefinition, dashboardDefinition } = await getDefinitionData({\n req,\n res,\n services,\n queryData,\n })\n\n // Get the results data\n const dashboardData: DashboardDataResponse[][] = await services.dashboardService.getAsyncDashboard(\n token,\n id,\n reportId,\n tableId,\n query,\n )\n\n const flattenedData: DashboardDataResponse[] = dashboardData.flat()\n const partialDate = getPartialDate(filters.filters)\n\n // Get the dashboard parts\n const sections: DashboardSection[] = getSections(dashboardDefinition, flattenedData, query, partialDate)\n\n // Update the store\n if (requestedReportService) {\n requestData = await updateStore(services, tableId, dprUser.id, sections, req, filters.filters)\n }\n\n return {\n dashboardData: {\n token,\n id,\n reportId,\n name: dashboardDefinition.name,\n description: dashboardDefinition.description,\n reportName: reportDefinition.name,\n bookmarked: await bookmarkService.isBookmarked(id, reportId, dprUser.id),\n nestedBaseUrl,\n csrfToken,\n sections,\n filters,\n type: ReportType.DASHBOARD,\n actions: setDashboardActions(dashboardDefinition, reportDefinition, requestData),\n },\n }\n}\n\nexport default {\n renderAsyncDashboard,\n getDefinitionData,\n getSections,\n setDashboardActions,\n}\n"],
5
- "mappings": "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",
6
- "names": ["utils_exports", "__export", "utils_default", "renderAsyncDashboard", "__toCommonJS", "import_types", "import_UserReports", "import_utils", "import_definitionUtils", "import_Scorecard", "import_ScorecardGroup", "import_ReportQuery", "import_localsHelper", "import_filtersTypeEnum", "import_enum", "setDashboardActions", "dashboardDefinition", "reportDefinition", "requestData", "reportName", "name", "actionsUrl", "executionId", "actions", "ReportActionsUtils", "getDefinitionData", "req", "res", "services", "queryData", "token", "LocalsHelper", "reportId", "id", "dataProductDefinitionsPath", "DefinitionUtils", "filtersData", "FilterUtils", "filtersQuery", "ReportQuery", "getSections", "dashboardData", "query", "partialDate", "section", "title", "description", "hasScorecard", "visualisations", "visDefinition", "type", "display", "visDescription", "visId", "data", "DashboardListUtils", "ScorecardVisualisation", "ScorecardGroupVisualisation", "ChartUtils", "ScorecardsUtils", "updateStore", "tableId", "userId", "sections", "filters", "requestedReportService", "dashboardRequestData", "UserReportsUtils", "getPartialDate", "granularDateRangeFilter", "f", "csrfToken", "dprUser", "nestedBaseUrl", "bookmarkService", "flattenedData"]
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAGA,mBAIO;AAKP,yBAA2B;AAG3B,mBAAuB;AACvB,6BAA4B;AAC5B,IAAAA,gBAA6B;AAC7B,IAAAA,gBAA+B;AAC/B,IAAAA,gBAAwB;AACxB,IAAAA,gBAA4B;AAC5B,uBAAmC;AACnC,4BAAwC;AACxC,IAAAA,gBAA+B;AAC/B,yBAAwB;AACxB,0BAAyB;AAEzB,6BAA4B;AAC5B,kBAA2B;AAE3B,MAAM,sBAAsB,CAC1B,qBACA,kBACA,gBACG;AACH,QAAM,aAAa,iBAAiB;AACpC,QAAM,EAAE,KAAK,IAAI;AACjB,QAAM,aAAa,aAAa,KAAK,SAAS;AAC9C,QAAM,cAAc,aAAa;AAEjC,MAAI,UAAU,CAAC;AACf,MAAI,YAAY;AACd,cAAU;AAAA,MACR,OAAO;AAAA,QACL;AAAA,QACA;AAAA,QACA,KAAK;AAAA,MACP;AAAA,MACA,MAAM;AAAA,QACJ,KAAK;AAAA,MACP;AAAA,IACF;AACA,QAAI,aAAa;AACf,gBAAU;AAAA,QACR,GAAG;AAAA,QACH,SAAS;AAAA,UACP,KAAK;AAAA,UACL;AAAA,QACF;AAAA,MACF;AAAA,IACF;AAAA,EACF;AAEA,SAAO,cAAAC,QAAmB,WAAW,OAAO;AAC9C;AAEA,MAAM,oBAAoB,OAAO;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAKM;AACJ,QAAM,EAAE,MAAM,IAAI,oBAAAC,QAAa,UAAU,GAAG;AAC5C,QAAM,EAAE,UAAU,GAAG,IAAI,IAAI;AAC7B,QAAM,6BAAqC,IAAI,MAAM,4BAA4B;AAGjF,QAAM,sBAAsB,MAAM,SAAS,iBAAiB;AAAA,IAC1D;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AAGA,QAAM,mBAAmB,MAAM,uBAAAC,QAAgB;AAAA,IAC7C;AAAA,IACA,SAAS;AAAA,IACT;AAAA,IACQ;AAAA,EACV;AAGA,QAAM,cAAc,MAAM,cAAAC,QAAY,WAAW;AAAA,IAC/C,QAAQ,oBAAoB,gBAAgB,CAAC;AAAA,IAC7C;AAAA,IACA,aAAa,mCAAY;AAAA,EAC3B,CAAC;AAED,QAAM,eAAe,cAAAA,QAAY,gCAAgC,YAAY,OAAO;AAGpF,QAAM,QAAQ,IAAI,mBAAAC,QAAY;AAAA,IAC5B,QAAQ,oBAAoB,gBAAgB,CAAC;AAAA,IAC7C,aAAa;AAAA,IACb,iBAAyB;AAAA,IACzB,YAAY,8BAAW;AAAA,EACzB,CAAC,EAAE,yBAAyB,IAAI;AAEhC,SAAO;AAAA,IACL;AAAA,IACA,SAAS;AAAA,IACT;AAAA,IACA;AAAA,EACF;AACF;AAEA,MAAM,cAAc,CAClB,qBACA,eACA,OACA,gBACuB;AACvB,SAAO,oBAAoB,SAAS,IAAI,CAAC,YAAiE;AACxG,UAAM,EAAE,IAAI,SAAS,OAAO,YAAY,IAAI;AAE5C,QAAI,eAAe;AACnB,UAAM,iBAA2C,QAAQ,eAAe;AAAA,MACtE,CAAC,kBAA6E;AAC5E,cAAM,EAAE,MAAM,SAAS,aAAa,gBAAgB,IAAI,MAAM,IAAI;AAElE,YAAI;AAEJ,gBAAQ,MAAM;AAAA,UACZ,KAAK,wCAA2B;AAC9B,mBAAO,cAAAC,QAAmB,WAAW,eAAe,aAAa;AACjE;AAAA,UAEF,KAAK,wCAA2B;AAC9B,2BAAe;AACf,mBAAO,IAAI,iBAAAC,QAAuB,EAAE,eAAe,aAAa,EAAE,SAAS,aAAa,EAAE,MAAM;AAChG;AAAA,UAEF,KAAK,wCAA2B;AAC9B,mBAAO,IAAI,sBAAAC,QAA4B,EAAE,eAAe,aAAa,EAAE,SAAS,aAAa,EAAE,MAAM;AACrG;AAAA,UAEF,KAAK,wCAA2B;AAAA,UAChC,KAAK,wCAA2B;AAAA,UAChC,KAAK,wCAA2B,OAAO;AACrC,mBAAO,aAAAC,QAAW,YAAY,eAAe,eAAe,IAAI;AAChE;AAAA,UACF;AAAA,UACA,KAAK,wCAA2B;AAAA,UAChC,KAAK,wCAA2B;AAAA,UAChC,KAAK,wCAA2B,iBAAiB;AAC/C,mBAAO,aAAAA,QAAW,uBAAuB,eAAe,eAAe,MAAM,OAAO,WAAW;AAC/F;AAAA,UACF;AAAA,UACA;AACE;AAAA,QACJ;AAEA,eAAO;AAAA,UACL,IAAI;AAAA,UACJ,OAAO,WAAW;AAAA,UAClB,aAAa,kBAAkB;AAAA,UAC/B;AAAA,UACA;AAAA,QACF;AAAA,MACF;AAAA,IACF;AAEA,QAAI,aAAc,eAAAC,QAAgB,yBAAyB,cAAc;AAEzE,WAAO,EAAE,IAAI,OAAO,SAAS,IAAI,aAAa,eAAe,IAAI,eAAe;AAAA,EAClF,CAAC;AACH;AAEA,MAAM,cAAc,OAClB,UACA,SACA,QACA,UACA,KACA,YACyC;AACzC,QAAM,EAAE,uBAAuB,IAAI;AACnC,QAAM,uBAAuB,MAAM,uBAAuB,mBAAmB,SAAS,MAAM;AAG5F,MAAI,YAAY,SAAS,UAAU,sBAAsB;AACvD,kBAAAC,QAAiB,iBAAiB;AAAA,MAChC;AAAA,MACA,iBAAiB;AAAA,MACjB;AAAA,MACA;AAAA,MACA;AAAA,IACF,CAAC;AAAA,EACH;AAEA,SAAO;AACT;AAEA,MAAM,iBAAiB,CAAC,YAA2B;AACjD,MAAI;AACJ,QAAM,0BACJ,QAAQ,KAAK,CAAC,MAAM,EAAE,SAAS,uBAAW,kBAAkB,YAAY,CAAC;AAE3E,MAAI,yBAAyB;AAC3B,kBAAc,wBAAwB,MAAM;AAAA,EAC9C;AACA,SAAO;AACT;AAEO,MAAM,uBAAuB,OAAO,EAAE,KAAK,KAAK,SAAS,MAA8B;AAC5F,QAAM,EAAE,OAAO,WAAW,SAAS,cAAc,IAAI,oBAAAT,QAAa,UAAU,GAAG;AAC/E,QAAM,EAAE,UAAU,IAAI,QAAQ,IAAI,IAAI;AACtC,QAAM,EAAE,iBAAiB,uBAAuB,IAAI;AACpD,QAAM,EAAE,IAAI,OAAO,IAAI;AAEvB,MAAI,cAA2C,MAAM,uBAAuB,mBAAmB,SAAS,MAAM;AAC9G,QAAM,YAAY,aAAa,OAAO;AAGtC,QAAM,EAAE,OAAO,SAAS,kBAAkB,oBAAoB,IAAI,MAAM,kBAAkB;AAAA,IACxF;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,CAAC;AAGD,QAAM,gBAA2C,MAAM,SAAS,iBAAiB;AAAA,IAC/E;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AAEA,QAAM,gBAAyC,cAAc,KAAK;AAClE,QAAM,cAAc,eAAe,QAAQ,OAAO;AAGlD,QAAM,WAA+B,YAAY,qBAAqB,eAAe,OAAO,WAAW;AAGvG,MAAI,wBAAwB;AAC1B,kBAAc,MAAM,YAAY,UAAU,SAAS,QAAQ,IAAI,UAAU,KAAK,QAAQ,OAAO;AAAA,EAC/F;AAEA,SAAO;AAAA,IACL,eAAe;AAAA,MACb;AAAA,MACA;AAAA,MACA;AAAA,MACA,MAAM,oBAAoB;AAAA,MAC1B,aAAa,oBAAoB;AAAA,MACjC,YAAY,iBAAiB;AAAA,MAC7B,YAAY,MAAM,gBAAgB,aAAa,IAAI,UAAU,QAAQ,EAAE;AAAA,MACvE;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,MAAM,8BAAW;AAAA,MACjB,SAAS,oBAAoB,qBAAqB,kBAAkB,WAAW;AAAA,IACjF;AAAA,EACF;AACF;AAEA,IAAO,gBAAQ;AAAA,EACb;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;",
6
+ "names": ["import_utils", "ReportActionsUtils", "LocalsHelper", "DefinitionUtils", "FilterUtils", "ReportQuery", "DashboardListUtils", "ScorecardVisualisation", "ScorecardGroupVisualisation", "ChartUtils", "ScorecardsUtils", "UserReportsUtils"]
7
7
  }