vc-create-dashboard 2.9.7 → 3.0.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 (367) hide show
  1. package/esm2022/lib/configurations.mjs +7 -0
  2. package/esm2022/lib/create-dashboard-container/categories/categories-config.mjs +2 -0
  3. package/esm2022/lib/create-dashboard-container/categories/categories.component.mjs +210 -0
  4. package/esm2022/lib/create-dashboard-container/configure-widgets/configure-widgets/configure-widgets.component.mjs +549 -0
  5. package/esm2022/lib/create-dashboard-container/configure-widgets/configure-widgets/widget.interface.mjs +2 -0
  6. package/esm2022/lib/create-dashboard-container/configure-widgets/configure-widgets.module.mjs +45 -0
  7. package/esm2022/lib/create-dashboard-container/create-dashboard-config.mjs +2 -0
  8. package/esm2022/lib/create-dashboard-container/create-dashboard.component.mjs +1109 -0
  9. package/esm2022/lib/create-dashboard-container/create-dashboard.module.mjs +125 -0
  10. package/esm2022/lib/create-dashboard-container/directives/directives.module.mjs +24 -0
  11. package/esm2022/lib/create-dashboard-container/directives/scroll-in-view.directive.mjs +36 -0
  12. package/esm2022/lib/create-dashboard-container/form-group/form-group.component.mjs +152 -0
  13. package/esm2022/lib/create-dashboard-container/frequency/frequency.component.mjs +309 -0
  14. package/esm2022/lib/create-dashboard-container/interfaces/widget-data-model.mjs +2 -0
  15. package/esm2022/lib/create-dashboard-container/pipes/filter.pipe.mjs +30 -0
  16. package/esm2022/lib/create-dashboard-container/pipes/search.pipe.mjs +25 -0
  17. package/esm2022/lib/create-dashboard-container/pipes/text-count.pipe.mjs +19 -0
  18. package/esm2022/lib/create-dashboard-container/responsibility-center/responsibility-center.component.mjs +145 -0
  19. package/esm2022/lib/create-dashboard-container/risk-categories/risk-categories-config.mjs +2 -0
  20. package/esm2022/lib/create-dashboard-container/risk-categories/risk-categories.component.mjs +195 -0
  21. package/esm2022/lib/create-dashboard-container/services/auth.service.mjs +31 -0
  22. package/esm2022/lib/create-dashboard-container/services/configure-widgets.service.mjs +227 -0
  23. package/esm2022/lib/create-dashboard-container/services/create-dashboard.service.mjs +160 -0
  24. package/esm2022/lib/create-dashboard-container/services/pagination.service.mjs +28 -0
  25. package/esm2022/lib/create-dashboard-container/user-list/user-list.component.mjs +421 -0
  26. package/esm2022/lib/create-dashboard-container/user-list/user-list.config.mjs +2 -0
  27. package/esm2022/lib/create-dashboard.service.mjs +14 -0
  28. package/esm2022/lib/ui-kit/dashboard-footer/dashboard-footer/dashboard-footer.component.mjs +52 -0
  29. package/esm2022/lib/ui-kit/dashboard-footer/dashboard-footer-config.mjs +2 -0
  30. package/esm2022/lib/ui-kit/dashboard-footer/dashboard-footer.module.mjs +32 -0
  31. package/esm2022/lib/ui-kit/dialog/dialog-config.mjs +7 -0
  32. package/esm2022/lib/ui-kit/dialog/dialog-injector.mjs +17 -0
  33. package/esm2022/lib/ui-kit/dialog/dialog-ref.mjs +11 -0
  34. package/esm2022/lib/ui-kit/dialog/dialog.component.mjs +96 -0
  35. package/esm2022/lib/ui-kit/dialog/dialog.module.mjs +20 -0
  36. package/esm2022/lib/ui-kit/dialog/dialog.service.mjs +56 -0
  37. package/esm2022/lib/ui-kit/dialog/insertion.directive.mjs +17 -0
  38. package/esm2022/lib/ui-kit/floating-bar/floating-bar.component.mjs +57 -0
  39. package/esm2022/lib/ui-kit/floating-bar/floating-bar.module.mjs +32 -0
  40. package/esm2022/lib/ui-kit/formgroup/click-outside.directive.mjs +30 -0
  41. package/esm2022/lib/ui-kit/formgroup/cs-checkbox/cs-checkbox.component.mjs +29 -0
  42. package/esm2022/lib/ui-kit/formgroup/cs-radio/cs-radio.component.mjs +34 -0
  43. package/esm2022/lib/ui-kit/formgroup/cs-radio-group/cs-radio-group.component.mjs +14 -0
  44. package/esm2022/lib/ui-kit/formgroup/cs-select/cs-select.component.mjs +119 -0
  45. package/esm2022/lib/ui-kit/formgroup/cs-switch/cs-switch.component.mjs +39 -0
  46. package/esm2022/lib/ui-kit/formgroup/formgroup.module.mjs +55 -0
  47. package/esm2022/lib/ui-kit/formgroup/pipes/pascal.pipe.mjs +19 -0
  48. package/esm2022/lib/ui-kit/formgroup/pipes/searchMultiSelect.pipe.mjs +24 -0
  49. package/esm2022/lib/ui-kit/no-data/no-data.component.mjs +47 -0
  50. package/esm2022/lib/ui-kit/no-data/no-data.module.mjs +18 -0
  51. package/esm2022/lib/ui-kit/pagination/pagination.component.mjs +130 -0
  52. package/esm2022/lib/ui-kit/pagination/pagination.module.mjs +18 -0
  53. package/esm2022/lib/ui-kit/popover/popover.component.mjs +142 -0
  54. package/esm2022/lib/ui-kit/popover/popover.directive.mjs +93 -0
  55. package/esm2022/lib/ui-kit/popover/popover.module.mjs +21 -0
  56. package/esm2022/lib/ui-kit/popover/popover.service.mjs +23 -0
  57. package/esm2022/lib/ui-kit/select/cs-option/cs-option.component.mjs +41 -0
  58. package/esm2022/lib/ui-kit/select/cs-select/cs-select.component.mjs +105 -0
  59. package/esm2022/lib/ui-kit/select/safe-html.pipe.mjs +21 -0
  60. package/esm2022/lib/ui-kit/select/select.module.mjs +21 -0
  61. package/esm2022/lib/ui-kit/services/cs-select.service.mjs +16 -0
  62. package/esm2022/lib/ui-kit/smiley-dialog/smiley-dialog.component.mjs +52 -0
  63. package/esm2022/lib/ui-kit/smiley-dialog/smiley-dialog.module.mjs +18 -0
  64. package/esm2022/lib/ui-kit/snack-bar/snack-bar/snack-bar.component.mjs +46 -0
  65. package/esm2022/lib/ui-kit/snack-bar/snack-bar.module.mjs +18 -0
  66. package/esm2022/lib/ui-kit/snack-bar/snack-bar.service.mjs +23 -0
  67. package/esm2022/lib/ui-kit/tooltip/tooltip.directive.mjs +161 -0
  68. package/esm2022/lib/ui-kit/tooltip/tooltip.module.mjs +18 -0
  69. package/esm2022/lib/ui-kit/v-loader/loader/loader.component.mjs +23 -0
  70. package/esm2022/lib/ui-kit/v-loader/loader-inline/loader-inline.component.mjs +23 -0
  71. package/esm2022/lib/ui-kit/v-loader/v-loader.module.mjs +19 -0
  72. package/esm2022/public-api.mjs +10 -0
  73. package/esm2022/vc-create-dashboard.mjs +5 -0
  74. package/fesm2022/vc-create-dashboard.mjs +5401 -0
  75. package/fesm2022/vc-create-dashboard.mjs.map +1 -0
  76. package/index.d.ts +5 -0
  77. package/lib/configurations.d.ts +4 -0
  78. package/lib/create-dashboard-container/categories/categories-config.d.ts +18 -0
  79. package/lib/create-dashboard-container/categories/categories.component.d.ts +31 -0
  80. package/lib/create-dashboard-container/configure-widgets/configure-widgets/configure-widgets.component.d.ts +88 -0
  81. package/lib/create-dashboard-container/configure-widgets/configure-widgets/widget.interface.d.ts +9 -0
  82. package/lib/create-dashboard-container/configure-widgets/configure-widgets.module.d.ts +14 -0
  83. package/lib/create-dashboard-container/create-dashboard-config.d.ts +18 -0
  84. package/lib/create-dashboard-container/create-dashboard.component.d.ts +177 -0
  85. package/lib/create-dashboard-container/create-dashboard.module.d.ts +36 -0
  86. package/lib/create-dashboard-container/directives/directives.module.d.ts +8 -0
  87. package/lib/create-dashboard-container/directives/scroll-in-view.directive.d.ts +12 -0
  88. package/lib/create-dashboard-container/form-group/form-group.component.d.ts +47 -0
  89. package/lib/create-dashboard-container/frequency/frequency.component.d.ts +39 -0
  90. package/{src/lib/create-dashboard-container/interfaces/widget-data-model.ts → lib/create-dashboard-container/interfaces/widget-data-model.d.ts} +1 -1
  91. package/lib/create-dashboard-container/pipes/filter.pipe.d.ts +7 -0
  92. package/lib/create-dashboard-container/pipes/search.pipe.d.ts +7 -0
  93. package/lib/create-dashboard-container/pipes/text-count.pipe.d.ts +7 -0
  94. package/lib/create-dashboard-container/responsibility-center/responsibility-center.component.d.ts +27 -0
  95. package/lib/create-dashboard-container/risk-categories/risk-categories-config.d.ts +18 -0
  96. package/lib/create-dashboard-container/risk-categories/risk-categories.component.d.ts +31 -0
  97. package/lib/create-dashboard-container/services/auth.service.d.ts +11 -0
  98. package/lib/create-dashboard-container/services/configure-widgets.service.d.ts +38 -0
  99. package/lib/create-dashboard-container/services/create-dashboard.service.d.ts +45 -0
  100. package/lib/create-dashboard-container/services/pagination.service.d.ts +12 -0
  101. package/lib/create-dashboard-container/user-list/user-list.component.d.ts +88 -0
  102. package/{src/lib/create-dashboard-container/user-list/user-list.config.ts → lib/create-dashboard-container/user-list/user-list.config.d.ts} +6 -6
  103. package/lib/create-dashboard.service.d.ts +6 -0
  104. package/lib/ui-kit/dashboard-footer/dashboard-footer/dashboard-footer.component.d.ts +17 -0
  105. package/lib/ui-kit/dashboard-footer/dashboard-footer-config.d.ts +11 -0
  106. package/lib/ui-kit/dashboard-footer/dashboard-footer.module.d.ts +10 -0
  107. package/lib/ui-kit/dialog/dialog-config.d.ts +6 -0
  108. package/lib/ui-kit/dialog/dialog-injector.d.ts +7 -0
  109. package/lib/ui-kit/dialog/dialog-ref.d.ts +7 -0
  110. package/lib/ui-kit/dialog/dialog.component.d.ts +33 -0
  111. package/lib/ui-kit/dialog/dialog.module.d.ts +9 -0
  112. package/lib/ui-kit/dialog/dialog.service.d.ts +17 -0
  113. package/lib/ui-kit/dialog/insertion.directive.d.ts +8 -0
  114. package/lib/ui-kit/floating-bar/floating-bar.component.d.ts +20 -0
  115. package/lib/ui-kit/floating-bar/floating-bar.module.d.ts +10 -0
  116. package/lib/ui-kit/formgroup/click-outside.directive.d.ts +10 -0
  117. package/lib/ui-kit/formgroup/cs-checkbox/cs-checkbox.component.d.ts +13 -0
  118. package/lib/ui-kit/formgroup/cs-radio/cs-radio.component.d.ts +15 -0
  119. package/lib/ui-kit/formgroup/cs-radio-group/cs-radio-group.component.d.ts +8 -0
  120. package/lib/ui-kit/formgroup/cs-select/cs-select.component.d.ts +36 -0
  121. package/lib/ui-kit/formgroup/cs-switch/cs-switch.component.d.ts +15 -0
  122. package/lib/ui-kit/formgroup/formgroup.module.d.ts +17 -0
  123. package/lib/ui-kit/formgroup/pipes/pascal.pipe.d.ts +7 -0
  124. package/lib/ui-kit/formgroup/pipes/searchMultiSelect.pipe.d.ts +7 -0
  125. package/lib/ui-kit/no-data/no-data.component.d.ts +19 -0
  126. package/lib/ui-kit/no-data/no-data.module.d.ts +8 -0
  127. package/lib/ui-kit/pagination/pagination.component.d.ts +21 -0
  128. package/lib/ui-kit/pagination/pagination.module.d.ts +8 -0
  129. package/lib/ui-kit/popover/popover.component.d.ts +28 -0
  130. package/lib/ui-kit/popover/popover.directive.d.ts +17 -0
  131. package/lib/ui-kit/popover/popover.module.d.ts +9 -0
  132. package/lib/ui-kit/popover/popover.service.d.ts +13 -0
  133. package/lib/ui-kit/select/cs-option/cs-option.component.d.ts +16 -0
  134. package/lib/ui-kit/select/cs-select/cs-select.component.d.ts +32 -0
  135. package/lib/ui-kit/select/safe-html.pipe.d.ts +10 -0
  136. package/lib/ui-kit/select/select.module.d.ts +11 -0
  137. package/lib/ui-kit/services/cs-select.service.d.ts +7 -0
  138. package/lib/ui-kit/smiley-dialog/smiley-dialog.component.d.ts +17 -0
  139. package/lib/ui-kit/smiley-dialog/smiley-dialog.module.d.ts +8 -0
  140. package/lib/ui-kit/snack-bar/snack-bar/snack-bar.component.d.ts +17 -0
  141. package/lib/ui-kit/snack-bar/snack-bar.module.d.ts +8 -0
  142. package/lib/ui-kit/snack-bar/snack-bar.service.d.ts +9 -0
  143. package/lib/ui-kit/tooltip/tooltip.directive.d.ts +27 -0
  144. package/lib/ui-kit/tooltip/tooltip.module.d.ts +8 -0
  145. package/lib/ui-kit/v-loader/loader/loader.component.d.ts +11 -0
  146. package/lib/ui-kit/v-loader/loader-inline/loader-inline.component.d.ts +11 -0
  147. package/lib/ui-kit/v-loader/v-loader.module.d.ts +9 -0
  148. package/package.json +25 -11
  149. package/public-api.d.ts +3 -0
  150. package/karma.conf.js +0 -44
  151. package/ng-package.json +0 -7
  152. package/src/lib/categoryList.ts +0 -23
  153. package/src/lib/configurations.ts +0 -8
  154. package/src/lib/create-dashboard-container/categories/categories-config.ts +0 -18
  155. package/src/lib/create-dashboard-container/categories/categories.component.html +0 -84
  156. package/src/lib/create-dashboard-container/categories/categories.component.less +0 -252
  157. package/src/lib/create-dashboard-container/categories/categories.component.spec.ts +0 -43
  158. package/src/lib/create-dashboard-container/categories/categories.component.ts +0 -205
  159. package/src/lib/create-dashboard-container/configure-widgets/configure-widgets/configure-widgets.component.html +0 -70
  160. package/src/lib/create-dashboard-container/configure-widgets/configure-widgets/configure-widgets.component.less +0 -381
  161. package/src/lib/create-dashboard-container/configure-widgets/configure-widgets/configure-widgets.component.spec.ts +0 -48
  162. package/src/lib/create-dashboard-container/configure-widgets/configure-widgets/configure-widgets.component.ts +0 -545
  163. package/src/lib/create-dashboard-container/configure-widgets/configure-widgets/widget.interface.ts +0 -9
  164. package/src/lib/create-dashboard-container/configure-widgets/configure-widgets.module.ts +0 -29
  165. package/src/lib/create-dashboard-container/create-dashboard-config.ts +0 -24
  166. package/src/lib/create-dashboard-container/create-dashboard-mockData.ts +0 -341
  167. package/src/lib/create-dashboard-container/create-dashboard.component.html +0 -1258
  168. package/src/lib/create-dashboard-container/create-dashboard.component.less +0 -1277
  169. package/src/lib/create-dashboard-container/create-dashboard.component.spec.ts +0 -755
  170. package/src/lib/create-dashboard-container/create-dashboard.component.ts +0 -1281
  171. package/src/lib/create-dashboard-container/create-dashboard.module.ts +0 -76
  172. package/src/lib/create-dashboard-container/directives/directives.module.ts +0 -18
  173. package/src/lib/create-dashboard-container/directives/scroll-in-view.directive.ts +0 -28
  174. package/src/lib/create-dashboard-container/form-group/form-group.component.html +0 -287
  175. package/src/lib/create-dashboard-container/form-group/form-group.component.less +0 -450
  176. package/src/lib/create-dashboard-container/form-group/form-group.component.spec.ts +0 -90
  177. package/src/lib/create-dashboard-container/form-group/form-group.component.ts +0 -162
  178. package/src/lib/create-dashboard-container/frequency/frequency.component.html +0 -61
  179. package/src/lib/create-dashboard-container/frequency/frequency.component.less +0 -183
  180. package/src/lib/create-dashboard-container/frequency/frequency.component.spec.ts +0 -120
  181. package/src/lib/create-dashboard-container/frequency/frequency.component.ts +0 -303
  182. package/src/lib/create-dashboard-container/pipes/filter.pipe.ts +0 -25
  183. package/src/lib/create-dashboard-container/pipes/search.pipe.ts +0 -23
  184. package/src/lib/create-dashboard-container/pipes/text-count.pipe.spec.ts +0 -8
  185. package/src/lib/create-dashboard-container/pipes/text-count.pipe.ts +0 -15
  186. package/src/lib/create-dashboard-container/responsibility-center/responsibility-center.component.html +0 -44
  187. package/src/lib/create-dashboard-container/responsibility-center/responsibility-center.component.less +0 -181
  188. package/src/lib/create-dashboard-container/responsibility-center/responsibility-center.component.spec.ts +0 -41
  189. package/src/lib/create-dashboard-container/responsibility-center/responsibility-center.component.ts +0 -136
  190. package/src/lib/create-dashboard-container/risk-categories/risk-categories-config.ts +0 -18
  191. package/src/lib/create-dashboard-container/risk-categories/risk-categories.component.html +0 -83
  192. package/src/lib/create-dashboard-container/risk-categories/risk-categories.component.less +0 -230
  193. package/src/lib/create-dashboard-container/risk-categories/risk-categories.component.spec.ts +0 -39
  194. package/src/lib/create-dashboard-container/risk-categories/risk-categories.component.ts +0 -191
  195. package/src/lib/create-dashboard-container/services/auth.service.ts +0 -27
  196. package/src/lib/create-dashboard-container/services/configure-widgets.service.spec.ts +0 -19
  197. package/src/lib/create-dashboard-container/services/configure-widgets.service.ts +0 -228
  198. package/src/lib/create-dashboard-container/services/create-dashboard.service.spec.ts +0 -19
  199. package/src/lib/create-dashboard-container/services/create-dashboard.service.ts +0 -139
  200. package/src/lib/create-dashboard-container/services/pagination.service.spec.ts +0 -16
  201. package/src/lib/create-dashboard-container/services/pagination.service.ts +0 -25
  202. package/src/lib/create-dashboard-container/user-list/user-list.component.html +0 -146
  203. package/src/lib/create-dashboard-container/user-list/user-list.component.less +0 -451
  204. package/src/lib/create-dashboard-container/user-list/user-list.component.spec.ts +0 -153
  205. package/src/lib/create-dashboard-container/user-list/user-list.component.ts +0 -433
  206. package/src/lib/create-dashboard.service.ts +0 -8
  207. package/src/lib/ui-kit/action-dialog/access-capability/access-capability.component.html +0 -22
  208. package/src/lib/ui-kit/action-dialog/access-capability/access-capability.component.less +0 -218
  209. package/src/lib/ui-kit/action-dialog/access-capability/access-capability.component.ts +0 -30
  210. package/src/lib/ui-kit/action-dialog/action-dialog.module.ts +0 -53
  211. package/src/lib/ui-kit/action-dialog/active/active.component.html +0 -1
  212. package/src/lib/ui-kit/action-dialog/active/active.component.less +0 -0
  213. package/src/lib/ui-kit/action-dialog/active/active.component.ts +0 -12
  214. package/src/lib/ui-kit/action-dialog/assesment-confirmation/assesment-confirmation.component.html +0 -18
  215. package/src/lib/ui-kit/action-dialog/assesment-confirmation/assesment-confirmation.component.less +0 -98
  216. package/src/lib/ui-kit/action-dialog/assesment-confirmation/assesment-confirmation.component.ts +0 -18
  217. package/src/lib/ui-kit/action-dialog/confirmation/confirmation.component.html +0 -20
  218. package/src/lib/ui-kit/action-dialog/confirmation/confirmation.component.less +0 -325
  219. package/src/lib/ui-kit/action-dialog/confirmation/confirmation.component.ts +0 -26
  220. package/src/lib/ui-kit/action-dialog/delete/delete.component.html +0 -24
  221. package/src/lib/ui-kit/action-dialog/delete/delete.component.less +0 -240
  222. package/src/lib/ui-kit/action-dialog/delete/delete.component.ts +0 -22
  223. package/src/lib/ui-kit/action-dialog/error/error.component.html +0 -20
  224. package/src/lib/ui-kit/action-dialog/error/error.component.less +0 -103
  225. package/src/lib/ui-kit/action-dialog/error/error.component.ts +0 -18
  226. package/src/lib/ui-kit/action-dialog/inactive/inactive.component.html +0 -23
  227. package/src/lib/ui-kit/action-dialog/inactive/inactive.component.less +0 -167
  228. package/src/lib/ui-kit/action-dialog/inactive/inactive.component.ts +0 -12
  229. package/src/lib/ui-kit/action-dialog/link/link.component.html +0 -57
  230. package/src/lib/ui-kit/action-dialog/link/link.component.less +0 -222
  231. package/src/lib/ui-kit/action-dialog/link/link.component.ts +0 -18
  232. package/src/lib/ui-kit/action-dialog/move/move.component.html +0 -43
  233. package/src/lib/ui-kit/action-dialog/move/move.component.less +0 -157
  234. package/src/lib/ui-kit/action-dialog/move/move.component.ts +0 -25
  235. package/src/lib/ui-kit/action-dialog/my-rating/my-rating.component.html +0 -19
  236. package/src/lib/ui-kit/action-dialog/my-rating/my-rating.component.less +0 -97
  237. package/src/lib/ui-kit/action-dialog/my-rating/my-rating.component.ts +0 -18
  238. package/src/lib/ui-kit/action-dialog/upload/upload.component.html +0 -19
  239. package/src/lib/ui-kit/action-dialog/upload/upload.component.less +0 -97
  240. package/src/lib/ui-kit/action-dialog/upload/upload.component.ts +0 -12
  241. package/src/lib/ui-kit/chart/bar/bar.component.html +0 -28
  242. package/src/lib/ui-kit/chart/bar/bar.component.less +0 -13
  243. package/src/lib/ui-kit/chart/bar/bar.component.ts +0 -44
  244. package/src/lib/ui-kit/chart/chart.module.ts +0 -12
  245. package/src/lib/ui-kit/chart/pipes/segmenter.pipe.ts +0 -28
  246. package/src/lib/ui-kit/chart/pipes/x-calculator.pipe.ts +0 -22
  247. package/src/lib/ui-kit/circle-progresss/circle/circle.component.html +0 -37
  248. package/src/lib/ui-kit/circle-progresss/circle/circle.component.less +0 -1448
  249. package/src/lib/ui-kit/circle-progresss/circle/circle.component.ts +0 -19
  250. package/src/lib/ui-kit/circle-progresss/circle-progresss.module.ts +0 -10
  251. package/src/lib/ui-kit/click-outside/click-outside.directive.ts +0 -16
  252. package/src/lib/ui-kit/click-outside/click-outside.module.ts +0 -16
  253. package/src/lib/ui-kit/color-palette/color-palette.component.html +0 -110
  254. package/src/lib/ui-kit/color-palette/color-palette.component.less +0 -54
  255. package/src/lib/ui-kit/color-palette/color-palette.component.ts +0 -28
  256. package/src/lib/ui-kit/color-palette/color-palette.module.ts +0 -10
  257. package/src/lib/ui-kit/dashboard-footer/dashboard-footer/dashboard-footer.component.html +0 -37
  258. package/src/lib/ui-kit/dashboard-footer/dashboard-footer/dashboard-footer.component.less +0 -335
  259. package/src/lib/ui-kit/dashboard-footer/dashboard-footer/dashboard-footer.component.spec.ts +0 -25
  260. package/src/lib/ui-kit/dashboard-footer/dashboard-footer/dashboard-footer.component.ts +0 -44
  261. package/src/lib/ui-kit/dashboard-footer/dashboard-footer-config.ts +0 -11
  262. package/src/lib/ui-kit/dashboard-footer/dashboard-footer.module.ts +0 -22
  263. package/src/lib/ui-kit/dialog/dialog-config.ts +0 -6
  264. package/src/lib/ui-kit/dialog/dialog-injector.ts +0 -18
  265. package/src/lib/ui-kit/dialog/dialog-ref.ts +0 -12
  266. package/src/lib/ui-kit/dialog/dialog.component.css +0 -89
  267. package/src/lib/ui-kit/dialog/dialog.component.html +0 -27
  268. package/src/lib/ui-kit/dialog/dialog.component.ts +0 -96
  269. package/src/lib/ui-kit/dialog/dialog.module.ts +0 -11
  270. package/src/lib/ui-kit/dialog/dialog.service.ts +0 -57
  271. package/src/lib/ui-kit/dialog/insertion.directive.ts +0 -8
  272. package/src/lib/ui-kit/floating-bar/floating-bar.component.html +0 -42
  273. package/src/lib/ui-kit/floating-bar/floating-bar.component.less +0 -355
  274. package/src/lib/ui-kit/floating-bar/floating-bar.component.spec.ts +0 -25
  275. package/src/lib/ui-kit/floating-bar/floating-bar.component.ts +0 -40
  276. package/src/lib/ui-kit/floating-bar/floating-bar.module.ts +0 -22
  277. package/src/lib/ui-kit/formgroup/click-outside.directive.ts +0 -16
  278. package/src/lib/ui-kit/formgroup/cs-checkbox/cs-checkbox.component.html +0 -11
  279. package/src/lib/ui-kit/formgroup/cs-checkbox/cs-checkbox.component.less +0 -102
  280. package/src/lib/ui-kit/formgroup/cs-checkbox/cs-checkbox.component.ts +0 -19
  281. package/src/lib/ui-kit/formgroup/cs-radio/cs-radio.component.html +0 -11
  282. package/src/lib/ui-kit/formgroup/cs-radio/cs-radio.component.less +0 -125
  283. package/src/lib/ui-kit/formgroup/cs-radio/cs-radio.component.ts +0 -21
  284. package/src/lib/ui-kit/formgroup/cs-radio-group/cs-radio-group.component.html +0 -4
  285. package/src/lib/ui-kit/formgroup/cs-radio-group/cs-radio-group.component.less +0 -0
  286. package/src/lib/ui-kit/formgroup/cs-radio-group/cs-radio-group.component.ts +0 -12
  287. package/src/lib/ui-kit/formgroup/cs-select/cs-select.component.html +0 -78
  288. package/src/lib/ui-kit/formgroup/cs-select/cs-select.component.less +0 -259
  289. package/src/lib/ui-kit/formgroup/cs-select/cs-select.component.ts +0 -92
  290. package/src/lib/ui-kit/formgroup/cs-switch/cs-switch.component.html +0 -30
  291. package/src/lib/ui-kit/formgroup/cs-switch/cs-switch.component.less +0 -103
  292. package/src/lib/ui-kit/formgroup/cs-switch/cs-switch.component.ts +0 -23
  293. package/src/lib/ui-kit/formgroup/formgroup.module.ts +0 -35
  294. package/src/lib/ui-kit/formgroup/pipes/pascal.pipe.ts +0 -13
  295. package/src/lib/ui-kit/formgroup/pipes/searchMultiSelect.pipe.ts +0 -18
  296. package/src/lib/ui-kit/line-loader/line-loader.component.html +0 -3
  297. package/src/lib/ui-kit/line-loader/line-loader.component.less +0 -34
  298. package/src/lib/ui-kit/line-loader/line-loader.component.ts +0 -14
  299. package/src/lib/ui-kit/line-loader/line-loader.module.ts +0 -10
  300. package/src/lib/ui-kit/longpress/longpress.directive.ts +0 -28
  301. package/src/lib/ui-kit/longpress/longpress.module.ts +0 -10
  302. package/src/lib/ui-kit/multi-select/cs-multiselect/cs-multiselect.component.html +0 -51
  303. package/src/lib/ui-kit/multi-select/cs-multiselect/cs-multiselect.component.less +0 -365
  304. package/src/lib/ui-kit/multi-select/cs-multiselect/cs-multiselect.component.spec.ts +0 -24
  305. package/src/lib/ui-kit/multi-select/cs-multiselect/cs-multiselect.component.ts +0 -139
  306. package/src/lib/ui-kit/multi-select/cs-multiselect-option/cs-multiselect-option.component.html +0 -9
  307. package/src/lib/ui-kit/multi-select/cs-multiselect-option/cs-multiselect-option.component.less +0 -105
  308. package/src/lib/ui-kit/multi-select/cs-multiselect-option/cs-multiselect-option.component.spec.ts +0 -27
  309. package/src/lib/ui-kit/multi-select/cs-multiselect-option/cs-multiselect-option.component.ts +0 -24
  310. package/src/lib/ui-kit/multi-select/multi-select.module.ts +0 -24
  311. package/src/lib/ui-kit/multi-select/multi-select.service.ts +0 -10
  312. package/src/lib/ui-kit/no-data/no-data.component.html +0 -14
  313. package/src/lib/ui-kit/no-data/no-data.component.less +0 -87
  314. package/src/lib/ui-kit/no-data/no-data.component.ts +0 -26
  315. package/src/lib/ui-kit/no-data/no-data.module.ts +0 -10
  316. package/src/lib/ui-kit/pagination/pagination.component.html +0 -11
  317. package/src/lib/ui-kit/pagination/pagination.component.less +0 -72
  318. package/src/lib/ui-kit/pagination/pagination.component.spec.ts +0 -25
  319. package/src/lib/ui-kit/pagination/pagination.component.ts +0 -138
  320. package/src/lib/ui-kit/pagination/pagination.module.ts +0 -10
  321. package/src/lib/ui-kit/pipes/pipes.module.ts +0 -10
  322. package/src/lib/ui-kit/pipes/safeHTML.pipe.ts +0 -12
  323. package/src/lib/ui-kit/pipes/trim.pipe.ts +0 -10
  324. package/src/lib/ui-kit/popover/popover.component.html +0 -6
  325. package/src/lib/ui-kit/popover/popover.component.less +0 -20
  326. package/src/lib/ui-kit/popover/popover.component.ts +0 -124
  327. package/src/lib/ui-kit/popover/popover.directive.ts +0 -72
  328. package/src/lib/ui-kit/popover/popover.module.ts +0 -13
  329. package/src/lib/ui-kit/popover/popover.service.ts +0 -17
  330. package/src/lib/ui-kit/ripple/ripple.directive.ts +0 -33
  331. package/src/lib/ui-kit/ripple/ripple.module.ts +0 -10
  332. package/src/lib/ui-kit/select/cs-option/cs-option.component.html +0 -8
  333. package/src/lib/ui-kit/select/cs-option/cs-option.component.less +0 -49
  334. package/src/lib/ui-kit/select/cs-option/cs-option.component.ts +0 -31
  335. package/src/lib/ui-kit/select/cs-select/cs-select.component.html +0 -16
  336. package/src/lib/ui-kit/select/cs-select/cs-select.component.less +0 -142
  337. package/src/lib/ui-kit/select/cs-select/cs-select.component.ts +0 -96
  338. package/src/lib/ui-kit/select/safe-html.pipe.ts +0 -13
  339. package/src/lib/ui-kit/select/select.module.ts +0 -13
  340. package/src/lib/ui-kit/services/cs-select.service.ts +0 -10
  341. package/src/lib/ui-kit/smiley-dialog/smiley-dialog.component.html +0 -30
  342. package/src/lib/ui-kit/smiley-dialog/smiley-dialog.component.less +0 -442
  343. package/src/lib/ui-kit/smiley-dialog/smiley-dialog.component.ts +0 -40
  344. package/src/lib/ui-kit/smiley-dialog/smiley-dialog.module.ts +0 -11
  345. package/src/lib/ui-kit/snack-bar/snack-bar/snack-bar.component.html +0 -10
  346. package/src/lib/ui-kit/snack-bar/snack-bar/snack-bar.component.less +0 -110
  347. package/src/lib/ui-kit/snack-bar/snack-bar/snack-bar.component.ts +0 -42
  348. package/src/lib/ui-kit/snack-bar/snack-bar.module.ts +0 -10
  349. package/src/lib/ui-kit/snack-bar/snack-bar.service.ts +0 -18
  350. package/src/lib/ui-kit/time-filter/time-filter.component.html +0 -84
  351. package/src/lib/ui-kit/time-filter/time-filter.component.less +0 -481
  352. package/src/lib/ui-kit/time-filter/time-filter.component.ts +0 -284
  353. package/src/lib/ui-kit/time-filter/time-filter.module.ts +0 -10
  354. package/src/lib/ui-kit/tooltip/tooltip.directive.ts +0 -127
  355. package/src/lib/ui-kit/tooltip/tooltip.module.ts +0 -10
  356. package/src/lib/ui-kit/v-loader/loader/loader.component.html +0 -6
  357. package/src/lib/ui-kit/v-loader/loader/loader.component.less +0 -52
  358. package/src/lib/ui-kit/v-loader/loader/loader.component.ts +0 -22
  359. package/src/lib/ui-kit/v-loader/loader-inline/loader-inline.component.html +0 -6
  360. package/src/lib/ui-kit/v-loader/loader-inline/loader-inline.component.less +0 -52
  361. package/src/lib/ui-kit/v-loader/loader-inline/loader-inline.component.ts +0 -22
  362. package/src/lib/ui-kit/v-loader/v-loader.module.ts +0 -11
  363. package/src/public-api.ts +0 -11
  364. package/src/test.ts +0 -28
  365. package/tsconfig.lib.json +0 -20
  366. package/tsconfig.lib.prod.json +0 -10
  367. package/tsconfig.spec.json +0 -17
@@ -1,755 +0,0 @@
1
- import { CommonModule } from '@angular/common';
2
- import { HttpClientModule } from '@angular/common/http';
3
- import { NO_ERRORS_SCHEMA } from '@angular/core';
4
- import { ComponentFixture, TestBed } from '@angular/core/testing';
5
- import { FormsModule } from '@angular/forms';
6
- import { DpDatePickerModule } from 'ng2-date-picker';
7
- import { MarxEditorModule } from 'vcomply-editor';
8
- import { CreateDashboardService } from './services/create-dashboard.service';
9
- import { DialogRef } from '../ui-kit/dialog/dialog-ref';
10
- import { CategoriesComponent } from './categories/categories.component';
11
- import { CreateDashboardComponent } from './create-dashboard.component';
12
- import { FormGroupComponent } from './form-group/form-group.component';
13
- import { FrequencyComponent } from './frequency/frequency.component';
14
- import { ResponsibilityCenterComponent } from './responsibility-center/responsibility-center.component';
15
- import { RiskCategoriesComponent } from './risk-categories/risk-categories.component';
16
- import { PaginationService } from './services/pagination.service';
17
- import { UserListComponent } from './user-list/user-list.component';
18
- import { DialogModule } from '../ui-kit/dialog/dialog.module';
19
- import { FilterPipe } from './pipes/filter.pipe';
20
- import { FormgroupModule } from '../ui-kit/formgroup/formgroup.module';
21
- import { TooltipModule } from '../ui-kit/tooltip/tooltip.module';
22
- import { SelectModule } from '../ui-kit/select/select.module';
23
- import { DashboardFooterModule } from '../ui-kit/dashboard-footer/dashboard-footer.module';
24
- import { PaginationModule } from '../ui-kit/pagination/pagination.module';
25
- import { FloatingBarModule } from '../ui-kit/floating-bar/floating-bar.module';
26
- import { ConfigureWidgetsModule } from './configure-widgets/configure-widgets.module';
27
- import { of } from 'rxjs';
28
- import { By } from '@angular/platform-browser';
29
- // import {editform } from '../create-dashboard-container/create-dashboard-mockData'
30
- import * as dayjs from 'dayjs';
31
- import * as customParseFormat from 'dayjs/plugin/customParseFormat';
32
- import { TextCountPipe } from './pipes/text-count.pipe';
33
- import { FeatureFlagService } from 'src/app/layout/featureFlag/feature-flag.service';
34
- import { HttpClientTestingModule } from '@angular/common/http/testing';
35
- import { compileComponentFromMetadata } from '@angular/compiler';
36
- import { Configurations } from '../configurations';
37
- import { editdata } from './create-dashboard-mockData';
38
- dayjs.extend(customParseFormat);
39
- /**
40
- * If unit test is failing then please try to update token as token may get expired
41
- */
42
- const localStorageMock = (() => {
43
- let store: any = {
44
- currentUser: {
45
- token:
46
- 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI1ZTgyMWQzOGY4YmM2MDAwMDdkZjFjYTQiLCJ1c2VyIjp7ImlkIjo5OTY3LCJuYW1lIjoiQWJ1IFRlc3QgQWNjb3VudCAyIiwiZW1haWwiOiJyYWloYW5hYnUwM3pAZ21haWwuY29tIiwib3JnYW5pc2F0aW9uX2lkIjoxLCJzaG9ydF9uYW1lIjoiQTIiLCJrZXlBZG1pbklkIjoxNSwia2V5QWRtaW4iOmZhbHNlLCJhZG1pbiI6ZmFsc2UsIm1hbmFnZXIiOnRydWUsInVzZXIiOnRydWUsImJyb3dzZXJfZmluZ2VycHJpbnQiOjI4MzQ1MjQ4MTcsInRpbWV6b25lIjoiRXVyb3BlL0xvbmRvbiIsImNyZWF0ZWRfdXRjIjoxNjY1NDcwNjAwLCJhY2Nlc3NfdHlwZSI6Mn0sImV4cCI6MTY2NjM0OTAwMCwiaWF0IjoxNjY2MzQ5MDAwfQ.mz5kFamlFeQv6cT9oCsAvBgfiDaXE-wRJzbqCee76LQ',
47
- },
48
- };
49
- return {
50
- getItem(key: any) {
51
- return JSON.stringify(store[key]);
52
- },
53
- setItem(key: any, value: any) {
54
- store[key] = value.toString();
55
- },
56
- clear() {
57
- store = { currentUser: '' };
58
- },
59
- removeItem(key: any) {
60
- delete store[key];
61
- },
62
- };
63
- })();
64
- Object.defineProperty(window, 'localStorage', {
65
- value: localStorageMock,
66
- });
67
- fdescribe('CreateDashboardComponent', () => {
68
- let component: CreateDashboardComponent;
69
- let fixture: ComponentFixture<CreateDashboardComponent>;
70
- let service: FeatureFlagService;
71
- let frequency = [
72
- {
73
- frequencyString: 'Every October',
74
- frequencyType: 'monthly',
75
- frequencies: [9],
76
- },
77
- {
78
- frequencyString: 'Every Thursday',
79
- frequencyType: 'weekly',
80
- frequencies: [3],
81
- },
82
- ];
83
-
84
- let widgetsData = [
85
- {
86
- title: 'Overview',
87
- id: 'overview_flag',
88
- description:
89
- 'Displays all responsibilities that have been assigned to you.',
90
- widgetImage:
91
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/overview.png',
92
- value: 1,
93
- },
94
- {
95
- title: 'Responsibility Calendar',
96
- id: 'compliance_calendar_flag',
97
- description:
98
- 'Displays all responsibilities that are due on a particular day.',
99
- widgetImage:
100
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/responsibility-calender.png',
101
- value: 1,
102
- },
103
- {
104
- title: 'Responsibility Center Overview',
105
- id: 'responsibility_center_overview_flag',
106
- description:
107
- 'Displays all responsibilities that have been assigned to you.',
108
- widgetImage:
109
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/overview.png',
110
- value: 1,
111
- },
112
- {
113
- title: 'My Responsibilities',
114
- id: 'my_responsibilities',
115
- description:
116
- 'Displays all responsibilities that have been assigned to you.',
117
- widgetImage:
118
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/my-responsibilities.png',
119
- tabOption: true,
120
- value: 0,
121
- },
122
- {
123
- title: 'Key Responsibilities',
124
- id: 'key_responsibilities',
125
- description:
126
- 'Displays all responsibilities that are due on a particular day.',
127
- widgetImage:
128
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/key-responsibilities.png',
129
- tabOption: true,
130
- value: 0,
131
- },
132
- {
133
- title: 'Trend Analysis',
134
- id: 'trend_analysis_flag',
135
- description:
136
- 'Displays all responsibilities that have been assigned to you.',
137
- widgetImage:
138
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/trend-analysis.png',
139
- value: 0,
140
- },
141
- {
142
- title: 'Workroom Updates',
143
- id: 'workroom_alert_flag',
144
- description:
145
- 'Displays all responsibilities that have been assigned to you.',
146
- widgetImage:
147
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/workroom-updates.png',
148
- value: 0,
149
- },
150
- {
151
- title: 'Recent Activities',
152
- id: 'recent_activity_flag',
153
- description:
154
- 'Displays all responsibilities that have been assigned to you.',
155
- widgetImage:
156
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/recent-activities.png',
157
- value: 0,
158
- },
159
- {
160
- title: 'Exception Summary',
161
- id: 'exception_summary_flag',
162
- description:
163
- 'Displays all responsibilities that have been assigned to you.',
164
- widgetImage:
165
- 'https://cdn.v-comply.com/libraries/configure-widget/assets/images/exception-summary.png',
166
- value: 0,
167
- },
168
- {
169
- title: 'My Responsibilities',
170
- id: 'my_responsibility_flag',
171
- value: 0,
172
- },
173
- {
174
- title: 'I’m Reviewing',
175
- id: 'reviewer_responsibility_flag',
176
- value: 0,
177
- },
178
- {
179
- title: 'I’m Overseeing',
180
- id: 'cc_responsibility_flag',
181
- value: 0,
182
- },
183
- {
184
- title: 'Overview',
185
- id: 'key_responsibilities_overview_flag',
186
- value: 0,
187
- },
188
- {
189
- title: 'My Responsibilities',
190
- id: 'key_my_responsibilities_flag',
191
- value: 0,
192
- },
193
- {
194
- title: 'I’m Reviewing',
195
- id: 'key_i_am_reviewing_flag',
196
- value: 0,
197
- },
198
- {
199
- title: 'I’m Overseeing',
200
- id: 'key_i_am_overseeing_flag',
201
- value: 0,
202
- },
203
- ];
204
- let groupsdata = [860, 857];
205
- let groupslist = [
206
- {
207
- old_group_id: 0,
208
- member_ids: [18282, 18262, 18503, 18521, 17924],
209
- removed_member_ids: [],
210
- group_type: 'vcomply',
211
- state: 1,
212
- _id: '63807db50067e1000852d62b',
213
- group_name: 'abc',
214
- group_description: '',
215
- roles: [
216
- {
217
- _id: '638d923ebb03890008a2c7b9',
218
- roleId: {
219
- _id: '6387478a721ddf000839fcda',
220
- roleName: 'Manage Program Permission Group',
221
- licenseType: 'power users',
222
- id: '6387478a721ddf000839fcda',
223
- },
224
- },
225
- ],
226
- associatedUsers: [
227
- {
228
- _id: '638d923ebb03890008a2c7b4',
229
- userId: {
230
- profile_pic: '',
231
- license_type: 'power users',
232
- _id: '6361fbe19f6cda0008120e49',
233
- member_name: 'A3',
234
- member_email: 'a3@fdfd.com',
235
- member_id: 18282,
236
- },
237
- },
238
- {
239
- _id: '638d923ebb03890008a2c7b5',
240
- userId: {
241
- profile_pic: '',
242
- license_type: 'power users',
243
- _id: '63523a540aa9a200094da903',
244
- member_name: 'A2',
245
- member_email: 'a2@fdfd.com',
246
- member_id: 18262,
247
- },
248
- },
249
- {
250
- _id: '638d923ebb03890008a2c7b6',
251
- userId: {
252
- profile_pic: '',
253
- license_type: 'power users',
254
- _id: '637f59bd9b20b00008e763a3',
255
- member_name: 'LightUser1',
256
- member_email: 'light@fdfd.com',
257
- member_id: 18503,
258
- },
259
- },
260
- {
261
- _id: '638d923ebb03890008a2c7b7',
262
- userId: {
263
- profile_pic: '',
264
- license_type: 'power users',
265
- _id: '6388501a057eaf000886b647',
266
- member_name: 'A4',
267
- member_email: 'a4@fdfd.com',
268
- member_id: 18521,
269
- },
270
- },
271
- {
272
- _id: '638d923ebb03890008a2c7b8',
273
- userId: {
274
- profile_pic: '',
275
- license_type: 'power users',
276
- _id: '623ac9fa46968d0009c8f0ed',
277
- member_name: 'A1',
278
- member_email: 'a1@fdfd.com',
279
- member_id: 17924,
280
- },
281
- },
282
- ],
283
- organisation_id: 3452,
284
- created_by: {
285
- profile_pic: '',
286
- _id: '623ac7c92498330009104f71',
287
- member_name: 'D1',
288
- member_email: 'test@fdfd.com',
289
- member_id: 17923,
290
- },
291
- modified_by: {
292
- profile_pic: '',
293
- _id: '623ac7c92498330009104f71',
294
- member_name: 'D1',
295
- member_email: 'test@fdfd.com',
296
- member_id: 17923,
297
- },
298
- created_at: 1669365173,
299
- updated_at: 1670222398,
300
- member_count: 5,
301
- group_id: 853,
302
- __v: 0,
303
- },
304
- {
305
- old_group_id: 0,
306
- member_ids: [17924, 18262],
307
- removed_member_ids: [],
308
- group_type: 'vcomply',
309
- state: 1,
310
- _id: '638b19553d93f900082d5f51',
311
- group_name: 'check group with reviewer',
312
- group_description: '',
313
- roles: [
314
- {
315
- _id: '638b19553d93f900082d5f52',
316
- roleId: {
317
- _id: '6387478a721ddf000839fcda',
318
- roleName: 'Manage Program Permission Group',
319
- licenseType: 'power users',
320
- id: '6387478a721ddf000839fcda',
321
- },
322
- },
323
- {
324
- _id: '638b19553d93f900082d5f53',
325
- roleId: {
326
- _id: '623ac7cb249833000910502c',
327
- roleName: 'Manager',
328
- licenseType: 'power users',
329
- id: '623ac7cb249833000910502c',
330
- },
331
- },
332
- {
333
- _id: '638b19553d93f900082d5f54',
334
- roleId: {
335
- _id: '623ac7cb249833000910506c',
336
- roleName: 'Admin',
337
- licenseType: 'power users',
338
- id: '623ac7cb249833000910506c',
339
- },
340
- },
341
- ],
342
- associatedUsers: [
343
- {
344
- _id: '638b19553d93f900082d5f55',
345
- userId: {
346
- profile_pic: '',
347
- license_type: 'power users',
348
- _id: '623ac9fa46968d0009c8f0ed',
349
- member_name: 'A1',
350
- member_email: 'a1@fdfd.com',
351
- member_id: 17924,
352
- },
353
- },
354
- {
355
- _id: '638b19553d93f900082d5f56',
356
- userId: {
357
- profile_pic: '',
358
- license_type: 'power users',
359
- _id: '63523a540aa9a200094da903',
360
- member_name: 'A2',
361
- member_email: 'a2@fdfd.com',
362
- member_id: 18262,
363
- },
364
- },
365
- ],
366
- organisation_id: 3452,
367
- created_by: {
368
- profile_pic: '',
369
- _id: '623ac7c92498330009104f71',
370
- member_name: 'D1',
371
- member_email: 'test@fdfd.com',
372
- member_id: 17923,
373
- },
374
- modified_by: {
375
- profile_pic: '',
376
- _id: '623ac7c92498330009104f71',
377
- member_name: 'D1',
378
- member_email: 'test@fdfd.com',
379
- member_id: 17923,
380
- },
381
- created_at: 1670060373,
382
- updated_at: 1670060373,
383
- member_count: 2,
384
- group_id: 860,
385
- __v: 0,
386
- },
387
- ];
388
- let userlist = [
389
- {
390
- _id: '623ac7c92498330009104f71',
391
- member_id: 17923,
392
- member_name: 'D1',
393
- member_email: 'test@fdfd.com',
394
- member_role: 'Keyadmin',
395
- },
396
- {
397
- _id: '623ac9fa46968d0009c8f0ed',
398
- member_id: 17924,
399
- member_name: 'A1',
400
- member_email: 'a1@fdfd.com',
401
- user_id: '623ac9fa46968d0009c8f0ed',
402
- user_name: 'A1',
403
- user_email: 'a1@fdfd.com',
404
- delete_flag: 1,
405
- status: 'Active',
406
- organisation_id: 3452,
407
- permission:
408
- '{"MEN":1,"MDV":1,"MDP":1,"MCG":1,"MPL":1,"MCC":0,"MCA":1,"MLD":1,"MAP":0,"MST":1,"MSV":1,"MAD":1,"MCO":0,"MLI":1,"MAC":1,"MPO":0,"MLC":1,"MACC":1,"MSC":0,"MQC":1,"MFC":0,"MPC":0,"MSRV":0,"MQZ":1,"MFRM":0,"MPOL":1,"MRISK":0,"MRISKC":0,"MKC":1,"MK":1,"MTC":1,"MTP":1,"ETP":1,"MPOC":1}',
409
- last_password_updated_utc: '14 Nov 2022',
410
- read_only_flag: 0,
411
- profile_pic: '',
412
- short_name: 'A1',
413
- employee_id: 2189509,
414
- employee_group_name: '',
415
- employee_group_name_arr: [],
416
- entity_details: '',
417
- isMember: true,
418
- compliance_score: '',
419
- reports: [],
420
- report_count: 0,
421
- employee_performance: '0,0,0',
422
- selected: false,
423
- member_role: 'Admin',
424
- is_login: 'ALLOW',
425
- multiple_oncompletion_enable: 0,
426
- exceed_user: 0,
427
- loginEnable: false,
428
- RTLEnable: false,
429
- DEnable: false,
430
- ActivateEnable: false,
431
- DeleteEnable: false,
432
- CTMEnable: false,
433
- CTAEnable: false,
434
- CTKAEnable: false,
435
- AddToGroup: false,
436
- SALEnable: false,
437
- ATMEnable: false,
438
- totalReportCount: 27,
439
- view_details_enable: 1,
440
- member_role_no: 2,
441
- MFAEnabled: 0,
442
- RoleCount: 1,
443
- GroupCount: 2,
444
- license_type: 'power users',
445
- GroupDetails: ['abc', 'check group with reviewer'],
446
- RolesDetails: ['Admin', 'Manage Program Permission Group', 'Manager'],
447
- isFaceIdEnabled: false,
448
- inProgress: '',
449
- },
450
- ];
451
- let mockCreateDashboardService: CreateDashboardService;
452
- let mockPaginationService: any;
453
- let mockDialogRef: any;
454
-
455
- beforeEach(async () => {
456
- mockCreateDashboardService = jasmine.createSpyObj([
457
- 'getOrganizationUsersCount',
458
- 'getOrganizationUsers',
459
- 'getCategoryList',
460
- 'getResponsibilityCenterList',
461
- 'getAllGroups',
462
- 'organizationGet',
463
- ]);
464
-
465
- mockPaginationService = jasmine.createSpyObj([
466
- 'currentPage',
467
- 'searchValue',
468
- ]);
469
- // mockDialogRef = jasmine.createSpyObj([]);
470
-
471
- await TestBed.configureTestingModule({
472
- declarations: [
473
- CreateDashboardComponent,
474
- UserListComponent,
475
- FormGroupComponent,
476
- ResponsibilityCenterComponent,
477
- CategoriesComponent,
478
- RiskCategoriesComponent,
479
- FrequencyComponent,
480
- FilterPipe,
481
- TextCountPipe,
482
- ],
483
- imports: [
484
- HttpClientModule,
485
- CommonModule,
486
- MarxEditorModule,
487
- FormgroupModule,
488
- DpDatePickerModule,
489
- FormsModule,
490
- TooltipModule,
491
- SelectModule,
492
- DashboardFooterModule,
493
- PaginationModule,
494
- FloatingBarModule,
495
- DialogModule,
496
- ConfigureWidgetsModule,
497
- HttpClientTestingModule,
498
- ],
499
- providers: [
500
- CreateDashboardService,
501
- { provide: PaginationService, useValue: mockPaginationService },
502
- { provide: DialogRef, useValue: mockDialogRef },
503
- {
504
- provide: FeatureFlagService,
505
- useValue: {
506
- isFeatureEnabled: () =>
507
- of({
508
- ff_groups_improvements: {
509
- enabled: true,
510
- },
511
- }),
512
- },
513
- },
514
- { provide: Configurations, useValue: { envConfig: { dashboard: '' } } },
515
- // CreateDashboardService,
516
- // PaginationService
517
- ],
518
- schemas: [NO_ERRORS_SCHEMA],
519
- }).compileComponents();
520
- });
521
-
522
- beforeEach(() => {
523
- fixture = TestBed.createComponent(CreateDashboardComponent);
524
- component = fixture.componentInstance;
525
- component.groupList = [];
526
- fixture.detectChanges();
527
- });
528
-
529
- it('should create', () => {
530
- expect(component).toBeTruthy();
531
- });
532
-
533
- it('activate Selector function for true', () => {
534
- component.activateSelector('rcList', true);
535
- expect(component.activeSelector).toBe('rcList');
536
- });
537
-
538
- it('activate Selector function for false', () => {
539
- component.activateSelector('rcList', false);
540
- expect(component.activeSelector).toBe('');
541
- });
542
-
543
- it('open From Date Picker function', () => {
544
- component.openFromDatePicker();
545
- expect(component.datePickerOverlay).toBeTruthy();
546
- });
547
-
548
- it('open To Date Picker function', () => {
549
- component.openToDatePicker();
550
- expect(component.datePickerOverlay).toBeTruthy();
551
- });
552
-
553
- // it('close From Date Picker function', () => {
554
- // component.closeFromDatePicker();
555
- // expect(component.datePickerOverlay).toBeFalsy();
556
- // });
557
-
558
- it('close To Date Picker function', () => {
559
- component.closeToDatePicker();
560
- expect(component.datePickerOverlay).toBeFalsy();
561
- });
562
-
563
- it('save Frequency function', () => {
564
- component.saveFrequency(frequency[0]);
565
- expect(component.dashboardForm.selectedFrequencyType).toBe(
566
- frequency[0].frequencyType
567
- );
568
- expect(component.dashboardForm.selectedFrequencies).toBe(
569
- frequency[0].frequencies
570
- );
571
- expect(component.dashboardForm.frequencyMessage).toBe(
572
- frequency[0].frequencyString
573
- );
574
- });
575
-
576
- // it('Check configure Dashboard open', () => {
577
- // component.dashboardForm.dashboardName = 'test';
578
- // component.configureDashboard();
579
- // expect(component.openConfigureWidgets).toBeTruthy();
580
- // });
581
-
582
- // it('widgets Data Modified', () => {
583
- // component.widgetsDataModified(widgetsData);
584
- // expect(widgetsData).toBe(component.dashboardForm.configureWidget);
585
- // expect(component.openConfigureWidgets).toBeFalsy();
586
- // });
587
-
588
- it('close Configure Widgets', () => {
589
- component.closeConfigureWidgets(false);
590
- expect(component.openConfigureWidgets).toBeFalsy();
591
- });
592
-
593
- it('verify fields should return false if dashboard description is more than 250 char', () => {
594
- component.dashboardForm.dashboardName = 'test';
595
- component.dashboardForm.dashboardDescriptionText = new Array(252).join('x');
596
- let status = component.validateDashboard();
597
- expect(status).toBeFalse();
598
- // expect(component.dashboardDescriptionError).toEqual(component.fieldLimitExceededErrorMessage.replace('XYZ', '250'));
599
- });
600
-
601
- it('should clear To Date if a later From Date is chosen', () => {
602
- component.dashboardForm.selectedFromDate = dayjs(
603
- '12-26-2021',
604
- 'MM-DD-YYYY'
605
- );
606
- component.dashboardForm.selectedToDate = dayjs('12-25-2021', 'MM-DD-YYYY');
607
- component.closeFromDatePicker();
608
- expect(component.dashboardForm.selectedToDate).toBeUndefined();
609
- });
610
-
611
- it('should set Frequency value', () => {
612
- component.setFrequency('3~1~1,2~0', 'import');
613
- fixture.detectChanges();
614
- expect(component.dashboardForm.frequencyMessage).toEqual(
615
- '1st of every January, February'
616
- );
617
- });
618
- it('should save the group values to dashboard form', () => {
619
- component.uniqueByProp(groupslist, 'group_id');
620
- component.saveSelectedList('whoCanView', {
621
- users: userlist,
622
- groups: groupslist,
623
- });
624
- fixture.detectChanges();
625
- expect(groupslist).toEqual(component.dashboardForm.selectedGroup);
626
- });
627
- it('should remove the group values from dashboard form', () => {
628
- let removegroup = {
629
- old_group_id: 0,
630
- member_ids: [18282, 18262, 18503, 18521, 17924],
631
- removed_member_ids: [],
632
- group_type: 'vcomply',
633
- state: 1,
634
- _id: '63807db50067e1000852d62b',
635
- group_name: 'abc',
636
- group_description: '',
637
- roles: [
638
- {
639
- _id: '638d923ebb03890008a2c7b9',
640
- roleId: {
641
- _id: '6387478a721ddf000839fcda',
642
- roleName: 'Manage Program Permission Group',
643
- licenseType: 'power users',
644
- id: '6387478a721ddf000839fcda',
645
- },
646
- },
647
- ],
648
- associatedUsers: [
649
- {
650
- _id: '638d923ebb03890008a2c7b4',
651
- userId: {
652
- profile_pic: '',
653
- license_type: 'power users',
654
- _id: '6361fbe19f6cda0008120e49',
655
- member_name: 'A3',
656
- member_email: 'a3@fdfd.com',
657
- member_id: 18282,
658
- },
659
- },
660
- {
661
- _id: '638d923ebb03890008a2c7b5',
662
- userId: {
663
- profile_pic: '',
664
- license_type: 'power users',
665
- _id: '63523a540aa9a200094da903',
666
- member_name: 'A2',
667
- member_email: 'a2@fdfd.com',
668
- member_id: 18262,
669
- },
670
- },
671
- {
672
- _id: '638d923ebb03890008a2c7b6',
673
- userId: {
674
- profile_pic: '',
675
- license_type: 'power users',
676
- _id: '637f59bd9b20b00008e763a3',
677
- member_name: 'LightUser1',
678
- member_email: 'light@fdfd.com',
679
- member_id: 18503,
680
- },
681
- },
682
- {
683
- _id: '638d923ebb03890008a2c7b7',
684
- userId: {
685
- profile_pic: '',
686
- license_type: 'power users',
687
- _id: '6388501a057eaf000886b647',
688
- member_name: 'A4',
689
- member_email: 'a4@fdfd.com',
690
- member_id: 18521,
691
- },
692
- },
693
- {
694
- _id: '638d923ebb03890008a2c7b8',
695
- userId: {
696
- profile_pic: '',
697
- license_type: 'power users',
698
- _id: '623ac9fa46968d0009c8f0ed',
699
- member_name: 'A1',
700
- member_email: 'a1@fdfd.com',
701
- member_id: 17924,
702
- },
703
- },
704
- ],
705
- organisation_id: 3452,
706
- created_by: {
707
- profile_pic: '',
708
- _id: '623ac7c92498330009104f71',
709
- member_name: 'D1',
710
- member_email: 'test@fdfd.com',
711
- member_id: 17923,
712
- },
713
- modified_by: {
714
- profile_pic: '',
715
- _id: '623ac7c92498330009104f71',
716
- member_name: 'D1',
717
- member_email: 'test@fdfd.com',
718
- member_id: 17923,
719
- },
720
- created_at: 1669365173,
721
- updated_at: 1670222398,
722
- member_count: 5,
723
- group_id: 853,
724
- __v: 0,
725
- };
726
- component.remove('whoCanView', removegroup);
727
- fixture.detectChanges();
728
- expect(component.dashboardForm.selectedGroup).toEqual([]);
729
- });
730
- it('only the user list in who can view this dashboard with feature flag as false', () => {
731
- component.groupsEnabled = false;
732
- component.dashboardForm.selectedViewers = userlist;
733
- const user = component.dashboardForm.selectedViewers;
734
- fixture.detectChanges();
735
- const value = fixture.debugElement.query(By.css('#onlyuserslist'));
736
- expect(user[0].member_name).toEqual('D1');
737
- });
738
- it(' the groups in who can view this dashboard with feature flag as true', () => {
739
- component.groupsEnabled = true;
740
- component.dashboardForm.selectedGroup = groupslist;
741
- const groups = component.dashboardForm.selectedGroup;
742
- fixture.detectChanges();
743
- const value = fixture.debugElement.query(By.css('#usersandgroups'));
744
- expect(groups.length).toEqual(2);
745
- });
746
- fit('edit form for populate dashboaard', () => {
747
- component.dashboardId = '637c89bd84fe1a0008aad043';
748
- component.mode = 'EDIT';
749
- component.usersList = userlist;
750
- component.groupList = [];
751
- fixture.detectChanges();
752
- const data = editdata;
753
- expect(component.populateDashboardForm(data)).toBeTruthy();
754
- });
755
- });