tin-spa 2.13.15 → 9.1.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 (375) hide show
  1. package/README.md +2 -2
  2. package/bundles/tin-spa.umd.js +6694 -0
  3. package/bundles/tin-spa.umd.js.map +1 -0
  4. package/bundles/tin-spa.umd.min.js +16 -0
  5. package/bundles/tin-spa.umd.min.js.map +1 -0
  6. package/esm2015/lib/classes/Classes.js +254 -0
  7. package/esm2015/lib/classes/TinCore.js +137 -0
  8. package/esm2015/lib/components/activity/activity.component.js +92 -0
  9. package/esm2015/lib/components/attach/attach.component.js +181 -0
  10. package/esm2015/lib/components/change-password/change-password.component.js +179 -0
  11. package/esm2015/lib/components/check/check.component.js +69 -0
  12. package/esm2015/lib/components/chips/chips.component.js +107 -0
  13. package/esm2015/lib/components/create-account/create-account.component.js +160 -0
  14. package/esm2015/lib/components/date/date.component.js +66 -0
  15. package/esm2015/lib/components/datetime/datetime.component.js +57 -0
  16. package/esm2015/lib/components/filter/filter.component.js +64 -0
  17. package/esm2015/lib/components/html/html.component.js +102 -0
  18. package/esm2015/lib/components/label/label.component.js +117 -0
  19. package/esm2015/lib/components/loader/loader.component.js +53 -0
  20. package/esm2015/lib/components/login/login.component.js +240 -0
  21. package/esm2015/lib/components/logs/logs.component.js +195 -0
  22. package/esm2015/lib/components/message/messageDialog.component.js +142 -0
  23. package/esm2015/lib/components/money/currency-input-mask.directive.js +187 -0
  24. package/esm2015/lib/components/money/currency-input-mask.module.js +30 -0
  25. package/esm2015/lib/components/money/money.component.js +152 -0
  26. package/esm2015/lib/components/nav-menu/nav-menu.component.js +204 -0
  27. package/esm2015/lib/components/option/option.component.js +129 -0
  28. package/esm2015/lib/components/profile/profile.component.js +198 -0
  29. package/esm2015/lib/components/recover-account/recover-account.component.js +74 -0
  30. package/esm2015/lib/components/roles/addRoleDialog.component.js +132 -0
  31. package/esm2015/lib/components/roles/roles.component.js +211 -0
  32. package/esm2015/lib/components/select/select.component.js +133 -0
  33. package/esm2015/lib/components/settings/settings.component.js +118 -0
  34. package/esm2015/lib/components/signup/signup.component.js +139 -0
  35. package/esm2015/lib/components/steps/steps.component.js +114 -0
  36. package/esm2015/lib/components/table/table.component.js +375 -0
  37. package/esm2015/lib/components/text/text.component.js +240 -0
  38. package/esm2015/lib/components/tiles/tiles.component.js +95 -0
  39. package/esm2015/lib/components/timeout/timeout.component.js +133 -0
  40. package/esm2015/lib/components/tin-spa.component.js +26 -0
  41. package/esm2015/lib/components/users/users.component.js +373 -0
  42. package/esm2015/lib/components/viewer/viewer.component.js +92 -0
  43. package/esm2015/lib/components/viewer/viewerDialog.component.js +131 -0
  44. package/esm2015/lib/dnd.directive.js +56 -0
  45. package/esm2015/lib/modules/spa-admin.module.js +81 -0
  46. package/esm2015/lib/modules/spa-index.module.js +58 -0
  47. package/esm2015/lib/modules/spa-mat.module.js +68 -0
  48. package/esm2015/lib/modules/spa-user.module.js +55 -0
  49. package/esm2015/lib/services/auth.service.js +142 -0
  50. package/esm2015/lib/services/data.service.js +111 -0
  51. package/esm2015/lib/services/export.service.js +29 -0
  52. package/esm2015/lib/services/http.service.js +79 -0
  53. package/esm2015/lib/services/loader-interceptor.service.js +77 -0
  54. package/esm2015/lib/services/loader.service.js +17 -0
  55. package/esm2015/lib/services/log.service.js +76 -0
  56. package/esm2015/lib/services/message.service.js +52 -0
  57. package/esm2015/lib/services/storage.service.js +43 -0
  58. package/esm2015/lib/services/tin-spa.service.js +14 -0
  59. package/esm2015/lib/tin-spa.module.js +156 -0
  60. package/esm2015/public-api.js +56 -0
  61. package/esm2015/tin-spa.js +5 -0
  62. package/esm5/lib/classes/Classes.js +313 -0
  63. package/esm5/lib/classes/TinCore.js +164 -0
  64. package/esm5/lib/components/activity/activity.component.js +94 -0
  65. package/esm5/lib/components/attach/attach.component.js +195 -0
  66. package/esm5/lib/components/change-password/change-password.component.js +182 -0
  67. package/esm5/lib/components/check/check.component.js +71 -0
  68. package/esm5/lib/components/chips/chips.component.js +110 -0
  69. package/esm5/lib/components/create-account/create-account.component.js +163 -0
  70. package/esm5/lib/components/date/date.component.js +68 -0
  71. package/esm5/lib/components/datetime/datetime.component.js +59 -0
  72. package/esm5/lib/components/filter/filter.component.js +66 -0
  73. package/esm5/lib/components/html/html.component.js +104 -0
  74. package/esm5/lib/components/label/label.component.js +119 -0
  75. package/esm5/lib/components/loader/loader.component.js +56 -0
  76. package/esm5/lib/components/login/login.component.js +244 -0
  77. package/esm5/lib/components/logs/logs.component.js +198 -0
  78. package/esm5/lib/components/message/messageDialog.component.js +144 -0
  79. package/esm5/lib/components/money/currency-input-mask.directive.js +193 -0
  80. package/esm5/lib/components/money/currency-input-mask.module.js +34 -0
  81. package/esm5/lib/components/money/money.component.js +154 -0
  82. package/esm5/lib/components/nav-menu/nav-menu.component.js +207 -0
  83. package/esm5/lib/components/option/option.component.js +131 -0
  84. package/esm5/lib/components/profile/profile.component.js +203 -0
  85. package/esm5/lib/components/recover-account/recover-account.component.js +77 -0
  86. package/esm5/lib/components/roles/addRoleDialog.component.js +135 -0
  87. package/esm5/lib/components/roles/roles.component.js +218 -0
  88. package/esm5/lib/components/select/select.component.js +136 -0
  89. package/esm5/lib/components/settings/settings.component.js +122 -0
  90. package/esm5/lib/components/signup/signup.component.js +142 -0
  91. package/esm5/lib/components/steps/steps.component.js +128 -0
  92. package/esm5/lib/components/table/table.component.js +378 -0
  93. package/esm5/lib/components/text/text.component.js +244 -0
  94. package/esm5/lib/components/tiles/tiles.component.js +97 -0
  95. package/esm5/lib/components/timeout/timeout.component.js +136 -0
  96. package/esm5/lib/components/tin-spa.component.js +25 -0
  97. package/esm5/lib/components/users/users.component.js +380 -0
  98. package/esm5/lib/components/viewer/viewer.component.js +94 -0
  99. package/esm5/lib/components/viewer/viewerDialog.component.js +133 -0
  100. package/esm5/lib/dnd.directive.js +58 -0
  101. package/esm5/lib/modules/spa-admin.module.js +85 -0
  102. package/esm5/lib/modules/spa-index.module.js +62 -0
  103. package/esm5/lib/modules/spa-mat.module.js +72 -0
  104. package/esm5/lib/modules/spa-user.module.js +59 -0
  105. package/esm5/lib/services/auth.service.js +145 -0
  106. package/esm5/lib/services/data.service.js +113 -0
  107. package/esm5/lib/services/export.service.js +31 -0
  108. package/esm5/lib/services/http.service.js +81 -0
  109. package/esm5/lib/services/loader-interceptor.service.js +80 -0
  110. package/esm5/lib/services/loader.service.js +19 -0
  111. package/esm5/lib/services/log.service.js +114 -0
  112. package/esm5/lib/services/message.service.js +54 -0
  113. package/esm5/lib/services/storage.service.js +76 -0
  114. package/esm5/lib/services/tin-spa.service.js +17 -0
  115. package/esm5/lib/tin-spa.module.js +160 -0
  116. package/esm5/public-api.js +56 -0
  117. package/esm5/tin-spa.js +5 -0
  118. package/fesm2015/tin-spa.js +6204 -0
  119. package/fesm2015/tin-spa.js.map +1 -0
  120. package/fesm5/tin-spa.js +6453 -0
  121. package/fesm5/tin-spa.js.map +1 -0
  122. package/lib/classes/Classes.d.ts +228 -375
  123. package/lib/classes/TinCore.d.ts +11 -43
  124. package/lib/components/activity/activity.component.d.ts +2 -2
  125. package/lib/components/attach/attach.component.d.ts +27 -15
  126. package/lib/{pages → components}/change-password/change-password.component.d.ts +4 -4
  127. package/lib/components/check/check.component.d.ts +3 -8
  128. package/lib/components/chips/chips.component.d.ts +2 -2
  129. package/lib/{pages → components}/create-account/create-account.component.d.ts +4 -8
  130. package/lib/components/date/date.component.d.ts +12 -24
  131. package/lib/components/datetime/datetime.component.d.ts +2 -6
  132. package/lib/components/filter/filter.component.d.ts +2 -7
  133. package/lib/components/html/html.component.d.ts +10 -11
  134. package/lib/components/label/label.component.d.ts +2 -4
  135. package/lib/components/loader/loader.component.d.ts +2 -2
  136. package/lib/components/login/login.component.d.ts +32 -0
  137. package/lib/components/logs/logs.component.d.ts +18 -0
  138. package/lib/components/message/messageDialog.component.d.ts +2 -2
  139. package/lib/components/money/currency-input-mask.directive.d.ts +2 -2
  140. package/lib/components/money/currency-input-mask.module.d.ts +2 -3
  141. package/lib/components/money/money.component.d.ts +3 -13
  142. package/lib/components/nav-menu/nav-menu.component.d.ts +4 -22
  143. package/lib/components/option/option.component.d.ts +3 -14
  144. package/lib/{pages → components}/profile/profile.component.d.ts +4 -6
  145. package/lib/{pages → components}/recover-account/recover-account.component.d.ts +3 -3
  146. package/lib/components/roles/addRoleDialog.component.d.ts +22 -0
  147. package/lib/components/roles/roles.component.d.ts +30 -0
  148. package/lib/components/select/select.component.d.ts +20 -20
  149. package/lib/{pages → components}/settings/settings.component.d.ts +3 -3
  150. package/lib/{pages → components}/signup/signup.component.d.ts +4 -4
  151. package/lib/components/steps/steps.component.d.ts +10 -19
  152. package/lib/components/table/table.component.d.ts +21 -84
  153. package/lib/components/text/text.component.d.ts +14 -36
  154. package/lib/components/tiles/tiles.component.d.ts +7 -21
  155. package/lib/components/timeout/timeout.component.d.ts +24 -0
  156. package/lib/components/tin-spa.component.d.ts +6 -3
  157. package/lib/{pages → components}/users/users.component.d.ts +18 -11
  158. package/lib/components/viewer/viewer.component.d.ts +5 -11
  159. package/lib/components/viewer/viewerDialog.component.d.ts +4 -6
  160. package/lib/dnd.directive.d.ts +11 -0
  161. package/lib/modules/spa-admin.module.d.ts +10 -10
  162. package/lib/modules/spa-index.module.d.ts +7 -8
  163. package/lib/modules/spa-mat.module.d.ts +2 -8
  164. package/lib/modules/spa-user.module.d.ts +6 -6
  165. package/lib/services/auth.service.d.ts +4 -16
  166. package/lib/services/data.service.d.ts +38 -0
  167. package/lib/services/export.service.d.ts +6 -2
  168. package/lib/services/http.service.d.ts +2 -2
  169. package/lib/services/loader-interceptor.service.d.ts +3 -4
  170. package/lib/services/loader.service.d.ts +2 -2
  171. package/lib/services/log.service.d.ts +3 -3
  172. package/lib/services/message.service.d.ts +3 -4
  173. package/lib/services/storage.service.d.ts +2 -2
  174. package/lib/services/tin-spa.service.d.ts +2 -2
  175. package/lib/tin-spa.module.d.ts +34 -83
  176. package/package.json +16 -24
  177. package/public-api.d.ts +16 -47
  178. package/esm2020/lib/classes/Classes.mjs +0 -112
  179. package/esm2020/lib/classes/LibClasses.mjs +0 -180
  180. package/esm2020/lib/classes/TinCore.mjs +0 -568
  181. package/esm2020/lib/components/activity/activity.component.mjs +0 -24
  182. package/esm2020/lib/components/alert/alert.component.mjs +0 -43
  183. package/esm2020/lib/components/attach/attach.component.mjs +0 -102
  184. package/esm2020/lib/components/capsules/capsules.component.mjs +0 -63
  185. package/esm2020/lib/components/cards/cards.component.mjs +0 -103
  186. package/esm2020/lib/components/check/check.component.mjs +0 -67
  187. package/esm2020/lib/components/chips/chips.component.mjs +0 -58
  188. package/esm2020/lib/components/date/date.component.mjs +0 -103
  189. package/esm2020/lib/components/datetime/datetime.component.mjs +0 -55
  190. package/esm2020/lib/components/email/email.component.mjs +0 -133
  191. package/esm2020/lib/components/filter/filter.component.mjs +0 -58
  192. package/esm2020/lib/components/form/form.component.mjs +0 -296
  193. package/esm2020/lib/components/html/html.component.mjs +0 -34
  194. package/esm2020/lib/components/label/label.component.mjs +0 -31
  195. package/esm2020/lib/components/list-dialog/list-dialog.component.mjs +0 -68
  196. package/esm2020/lib/components/loader/loader.component.mjs +0 -25
  197. package/esm2020/lib/components/message/messageDialog.component.mjs +0 -33
  198. package/esm2020/lib/components/money/currency-input-mask.directive.mjs +0 -185
  199. package/esm2020/lib/components/money/currency-input-mask.module.mjs +0 -28
  200. package/esm2020/lib/components/money/money.component.mjs +0 -137
  201. package/esm2020/lib/components/multi-select/multi-select.component.mjs +0 -165
  202. package/esm2020/lib/components/multi-text/multi-text.component.mjs +0 -208
  203. package/esm2020/lib/components/nav-menu/nav-menu.component.mjs +0 -88
  204. package/esm2020/lib/components/notes/notes.component.mjs +0 -62
  205. package/esm2020/lib/components/number/number.component.mjs +0 -131
  206. package/esm2020/lib/components/option/option.component.mjs +0 -92
  207. package/esm2020/lib/components/page/page.component.mjs +0 -101
  208. package/esm2020/lib/components/search/search.component.mjs +0 -36
  209. package/esm2020/lib/components/select/select.component.mjs +0 -75
  210. package/esm2020/lib/components/select-bitwise/select-bitwise.component.mjs +0 -87
  211. package/esm2020/lib/components/select-common/select-common.component.mjs +0 -206
  212. package/esm2020/lib/components/select-internal/select-internal.component.mjs +0 -75
  213. package/esm2020/lib/components/select-lite/select-lite.component.mjs +0 -18
  214. package/esm2020/lib/components/statuses/statuses.component.mjs +0 -44
  215. package/esm2020/lib/components/steps/steps.component.mjs +0 -112
  216. package/esm2020/lib/components/suffix/suffix.component.mjs +0 -70
  217. package/esm2020/lib/components/table/detailsDialog.component.mjs +0 -406
  218. package/esm2020/lib/components/table/table.component.mjs +0 -440
  219. package/esm2020/lib/components/table-action/table-action.component.mjs +0 -80
  220. package/esm2020/lib/components/table-header/table-header.component.mjs +0 -148
  221. package/esm2020/lib/components/table-internal/detailsDialog-internal.component.mjs +0 -406
  222. package/esm2020/lib/components/table-internal/table-internal.component.mjs +0 -441
  223. package/esm2020/lib/components/table-lite/detailsDialog-lite.component.mjs +0 -404
  224. package/esm2020/lib/components/table-lite/table-lite.component.mjs +0 -441
  225. package/esm2020/lib/components/table-row/table-row.component.mjs +0 -93
  226. package/esm2020/lib/components/tabs/tabs.component.mjs +0 -74
  227. package/esm2020/lib/components/text/text.component.mjs +0 -255
  228. package/esm2020/lib/components/tiles/tiles.component.mjs +0 -99
  229. package/esm2020/lib/components/tin-spa.component.mjs +0 -19
  230. package/esm2020/lib/components/viewer/viewer.component.mjs +0 -83
  231. package/esm2020/lib/components/viewer/viewerDialog.component.mjs +0 -95
  232. package/esm2020/lib/modules/admin/admin-routing.module.mjs +0 -71
  233. package/esm2020/lib/modules/admin/admin.module.mjs +0 -26
  234. package/esm2020/lib/modules/index/index-routing.module.mjs +0 -27
  235. package/esm2020/lib/modules/index/index.module.mjs +0 -26
  236. package/esm2020/lib/modules/spa-admin.module.mjs +0 -71
  237. package/esm2020/lib/modules/spa-index.module.mjs +0 -54
  238. package/esm2020/lib/modules/spa-mat.module.mjs +0 -84
  239. package/esm2020/lib/modules/spa-user.module.mjs +0 -47
  240. package/esm2020/lib/modules/user/user-routing.module.mjs +0 -23
  241. package/esm2020/lib/modules/user/user.module.mjs +0 -26
  242. package/esm2020/lib/pages/accounts/accountDialog.component.mjs +0 -56
  243. package/esm2020/lib/pages/accounts/accounts.component.mjs +0 -70
  244. package/esm2020/lib/pages/app-models/app-models.component.mjs +0 -56
  245. package/esm2020/lib/pages/approvals/approvals.component.mjs +0 -19
  246. package/esm2020/lib/pages/approvals-config/approvals-config.component.mjs +0 -165
  247. package/esm2020/lib/pages/bug/bug.component.mjs +0 -14
  248. package/esm2020/lib/pages/change-password/change-password.component.mjs +0 -92
  249. package/esm2020/lib/pages/create-account/create-account.component.mjs +0 -110
  250. package/esm2020/lib/pages/customers/customers.component.mjs +0 -21
  251. package/esm2020/lib/pages/departments/departments.component.mjs +0 -22
  252. package/esm2020/lib/pages/employees/employees.component.mjs +0 -20
  253. package/esm2020/lib/pages/grades/grades.component.mjs +0 -14
  254. package/esm2020/lib/pages/inventory/inventory.component.mjs +0 -99
  255. package/esm2020/lib/pages/inventory/quantityDialog.component.mjs +0 -53
  256. package/esm2020/lib/pages/invitations-table/invitations-table.component.mjs +0 -71
  257. package/esm2020/lib/pages/login/login.component.mjs +0 -166
  258. package/esm2020/lib/pages/logs/logs.component.mjs +0 -42
  259. package/esm2020/lib/pages/membership/membership.component.mjs +0 -44
  260. package/esm2020/lib/pages/notifications/notifications.component.mjs +0 -90
  261. package/esm2020/lib/pages/notifications-config/notifications-config.component.mjs +0 -113
  262. package/esm2020/lib/pages/plans/plans.component.mjs +0 -44
  263. package/esm2020/lib/pages/positions/positions.component.mjs +0 -21
  264. package/esm2020/lib/pages/profile/profile.component.mjs +0 -94
  265. package/esm2020/lib/pages/recover-account/recover-account.component.mjs +0 -46
  266. package/esm2020/lib/pages/roles/addRoleDialog.component.mjs +0 -60
  267. package/esm2020/lib/pages/roles/roles.component.mjs +0 -151
  268. package/esm2020/lib/pages/settings/settings.component.mjs +0 -54
  269. package/esm2020/lib/pages/signup/signup.component.mjs +0 -50
  270. package/esm2020/lib/pages/suppliers/suppliers.component.mjs +0 -22
  271. package/esm2020/lib/pages/tasks/tasks.component.mjs +0 -86
  272. package/esm2020/lib/pages/tenant-settings/tenant-settings.component.mjs +0 -228
  273. package/esm2020/lib/pages/tenants/tenants.component.mjs +0 -47
  274. package/esm2020/lib/pages/transactions/transactDialog.component.mjs +0 -80
  275. package/esm2020/lib/pages/transactions/transactions.component.mjs +0 -101
  276. package/esm2020/lib/pages/users/users.component.mjs +0 -167
  277. package/esm2020/lib/pages/welcome/welcome.component.mjs +0 -86
  278. package/esm2020/lib/pipes/camelToWords.pipe.mjs +0 -17
  279. package/esm2020/lib/select-context.directive.mjs +0 -23
  280. package/esm2020/lib/services/auth.service.mjs +0 -175
  281. package/esm2020/lib/services/button.service.mjs +0 -162
  282. package/esm2020/lib/services/condition.service.mjs +0 -32
  283. package/esm2020/lib/services/csv.service.mjs +0 -49
  284. package/esm2020/lib/services/datalib.service.mjs +0 -860
  285. package/esm2020/lib/services/dialog.service.mjs +0 -125
  286. package/esm2020/lib/services/export.service.mjs +0 -16
  287. package/esm2020/lib/services/http.service.mjs +0 -79
  288. package/esm2020/lib/services/loader-interceptor.service.mjs +0 -86
  289. package/esm2020/lib/services/loader.service.mjs +0 -17
  290. package/esm2020/lib/services/log.service.mjs +0 -77
  291. package/esm2020/lib/services/message.service.mjs +0 -59
  292. package/esm2020/lib/services/notifications.service.mjs +0 -33
  293. package/esm2020/lib/services/storage.service.mjs +0 -34
  294. package/esm2020/lib/services/table-config.service.mjs +0 -78
  295. package/esm2020/lib/services/tin-spa.service.mjs +0 -14
  296. package/esm2020/lib/tin-spa.module.mjs +0 -225
  297. package/esm2020/public-api.mjs +0 -90
  298. package/esm2020/tin-spa.mjs +0 -5
  299. package/fesm2015/tin-spa.mjs +0 -11736
  300. package/fesm2015/tin-spa.mjs.map +0 -1
  301. package/fesm2020/tin-spa.mjs +0 -11738
  302. package/fesm2020/tin-spa.mjs.map +0 -1
  303. package/lib/classes/LibClasses.d.ts +0 -173
  304. package/lib/components/alert/alert.component.d.ts +0 -15
  305. package/lib/components/capsules/capsules.component.d.ts +0 -26
  306. package/lib/components/cards/cards.component.d.ts +0 -39
  307. package/lib/components/email/email.component.d.ts +0 -40
  308. package/lib/components/form/form.component.d.ts +0 -47
  309. package/lib/components/list-dialog/list-dialog.component.d.ts +0 -23
  310. package/lib/components/multi-select/multi-select.component.d.ts +0 -47
  311. package/lib/components/multi-text/multi-text.component.d.ts +0 -56
  312. package/lib/components/notes/notes.component.d.ts +0 -19
  313. package/lib/components/number/number.component.d.ts +0 -41
  314. package/lib/components/page/page.component.d.ts +0 -38
  315. package/lib/components/search/search.component.d.ts +0 -15
  316. package/lib/components/select-bitwise/select-bitwise.component.d.ts +0 -31
  317. package/lib/components/select-common/select-common.component.d.ts +0 -53
  318. package/lib/components/select-internal/select-internal.component.d.ts +0 -23
  319. package/lib/components/select-lite/select-lite.component.d.ts +0 -8
  320. package/lib/components/statuses/statuses.component.d.ts +0 -12
  321. package/lib/components/suffix/suffix.component.d.ts +0 -23
  322. package/lib/components/table/detailsDialog.component.d.ts +0 -86
  323. package/lib/components/table-action/table-action.component.d.ts +0 -25
  324. package/lib/components/table-header/table-header.component.d.ts +0 -46
  325. package/lib/components/table-internal/detailsDialog-internal.component.d.ts +0 -86
  326. package/lib/components/table-internal/table-internal.component.d.ts +0 -91
  327. package/lib/components/table-lite/detailsDialog-lite.component.d.ts +0 -86
  328. package/lib/components/table-lite/table-lite.component.d.ts +0 -91
  329. package/lib/components/table-row/table-row.component.d.ts +0 -31
  330. package/lib/components/tabs/tabs.component.d.ts +0 -32
  331. package/lib/modules/admin/admin-routing.module.d.ts +0 -7
  332. package/lib/modules/admin/admin.module.d.ts +0 -9
  333. package/lib/modules/index/index-routing.module.d.ts +0 -7
  334. package/lib/modules/index/index.module.d.ts +0 -9
  335. package/lib/modules/user/user-routing.module.d.ts +0 -7
  336. package/lib/modules/user/user.module.d.ts +0 -9
  337. package/lib/pages/accounts/accountDialog.component.d.ts +0 -27
  338. package/lib/pages/accounts/accounts.component.d.ts +0 -25
  339. package/lib/pages/app-models/app-models.component.d.ts +0 -15
  340. package/lib/pages/approvals/approvals.component.d.ts +0 -10
  341. package/lib/pages/approvals-config/approvals-config.component.d.ts +0 -24
  342. package/lib/pages/bug/bug.component.d.ts +0 -8
  343. package/lib/pages/customers/customers.component.d.ts +0 -12
  344. package/lib/pages/departments/departments.component.d.ts +0 -14
  345. package/lib/pages/employees/employees.component.d.ts +0 -12
  346. package/lib/pages/grades/grades.component.d.ts +0 -8
  347. package/lib/pages/inventory/inventory.component.d.ts +0 -25
  348. package/lib/pages/inventory/quantityDialog.component.d.ts +0 -23
  349. package/lib/pages/invitations-table/invitations-table.component.d.ts +0 -19
  350. package/lib/pages/login/login.component.d.ts +0 -46
  351. package/lib/pages/logs/logs.component.d.ts +0 -14
  352. package/lib/pages/membership/membership.component.d.ts +0 -13
  353. package/lib/pages/notifications/notifications.component.d.ts +0 -16
  354. package/lib/pages/notifications-config/notifications-config.component.d.ts +0 -17
  355. package/lib/pages/plans/plans.component.d.ts +0 -13
  356. package/lib/pages/positions/positions.component.d.ts +0 -12
  357. package/lib/pages/roles/addRoleDialog.component.d.ts +0 -24
  358. package/lib/pages/roles/roles.component.d.ts +0 -42
  359. package/lib/pages/suppliers/suppliers.component.d.ts +0 -14
  360. package/lib/pages/tasks/tasks.component.d.ts +0 -27
  361. package/lib/pages/tenant-settings/tenant-settings.component.d.ts +0 -47
  362. package/lib/pages/tenants/tenants.component.d.ts +0 -17
  363. package/lib/pages/transactions/transactDialog.component.d.ts +0 -26
  364. package/lib/pages/transactions/transactions.component.d.ts +0 -31
  365. package/lib/pages/welcome/welcome.component.d.ts +0 -25
  366. package/lib/pipes/camelToWords.pipe.d.ts +0 -7
  367. package/lib/select-context.directive.d.ts +0 -10
  368. package/lib/services/button.service.d.ts +0 -30
  369. package/lib/services/condition.service.d.ts +0 -10
  370. package/lib/services/csv.service.d.ts +0 -10
  371. package/lib/services/datalib.service.d.ts +0 -125
  372. package/lib/services/dialog.service.d.ts +0 -20
  373. package/lib/services/notifications.service.d.ts +0 -12
  374. package/lib/services/table-config.service.d.ts +0 -17
  375. /package/{index.d.ts → tin-spa.d.ts} +0 -0
@@ -0,0 +1,16 @@
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/material/dialog"),require("@angular/common"),require("@angular/material/form-field"),require("@angular/material/button"),require("rxjs"),require("rxjs/operators"),require("@angular/material/snack-bar"),require("file-saver"),require("xlsx"),require("@angular/router"),require("@angular/common/http"),require("@angular/material/autocomplete"),require("@angular/material/badge"),require("@angular/material/card"),require("@angular/material/checkbox"),require("@angular/material/chips"),require("@angular/material/core"),require("@angular/material/datepicker"),require("@angular/material/icon"),require("@angular/material/input"),require("@angular/material/list"),require("@angular/material/menu"),require("@angular/material/paginator"),require("@angular/material/progress-spinner"),require("@angular/material/radio"),require("@angular/material/select"),require("@angular/material/slider"),require("@angular/material/sort"),require("@angular/material/stepper"),require("@angular/material/table"),require("@angular/material/tabs"),require("@angular/material/tooltip"),require("@angular/forms"),require("@ng-idle/keepalive"),require("angular2-moment"),require("ngx-doc-viewer"),require("@ng-idle/core"),require("@kolkov/angular-editor"),require("@angular/cdk/stepper")):"function"==typeof define&&define.amd?define("tin-spa",["exports","@angular/core","@angular/material/dialog","@angular/common","@angular/material/form-field","@angular/material/button","rxjs","rxjs/operators","@angular/material/snack-bar","file-saver","xlsx","@angular/router","@angular/common/http","@angular/material/autocomplete","@angular/material/badge","@angular/material/card","@angular/material/checkbox","@angular/material/chips","@angular/material/core","@angular/material/datepicker","@angular/material/icon","@angular/material/input","@angular/material/list","@angular/material/menu","@angular/material/paginator","@angular/material/progress-spinner","@angular/material/radio","@angular/material/select","@angular/material/slider","@angular/material/sort","@angular/material/stepper","@angular/material/table","@angular/material/tabs","@angular/material/tooltip","@angular/forms","@ng-idle/keepalive","angular2-moment","ngx-doc-viewer","@ng-idle/core","@kolkov/angular-editor","@angular/cdk/stepper"],t):t((e=e||self)["tin-spa"]={},e.ng.core,e.ng.material.dialog,e.ng.common,e.ng.material.formField,e.ng.material.button,e.rxjs,e.rxjs.operators,e.ng.material.snackBar,e.fileSaver,e.xlsx,e.ng.router,e.ng.common.http,e.ng.material.autocomplete,e.ng.material.badge,e.ng.material.card,e.ng.material.checkbox,e.ng.material.chips,e.ng.material.core,e.ng.material.datepicker,e.ng.material.icon,e.ng.material.input,e.ng.material.list,e.ng.material.menu,e.ng.material.paginator,e.ng.material.progressSpinner,e.ng.material.radio,e.ng.material.select,e.ng.material.slider,e.ng.material.sort,e.ng.material.stepper,e.ng.material.table,e.ng.material.tabs,e.ng.material.tooltip,e.ng.forms,e.keepalive,e.angular2Moment,e.ngxDocViewer,e.core$2,e.angularEditor,e.ng.cdk.stepper)}(this,(function(e,t,n,i,a,r,o,l,s,c,p,d,m,u,f,g,h,v,y,x,S,C,M,w,b,E,I,k,P,N,D,O,T,F,L,j,A,R,U,V,_){"use strict";
2
+ /*! *****************************************************************************
3
+ Copyright (c) Microsoft Corporation. All rights reserved.
4
+ Licensed under the Apache License, Version 2.0 (the "License"); you may not use
5
+ this file except in compliance with the License. You may obtain a copy of the
6
+ License at http://www.apache.org/licenses/LICENSE-2.0
7
+
8
+ THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
9
+ KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
10
+ WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
11
+ MERCHANTABLITY OR NON-INFRINGEMENT.
12
+
13
+ See the Apache Version 2.0 License for specific language governing permissions
14
+ and limitations under the License.
15
+ ***************************************************************************** */var z=function(e,t){return(z=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function B(e,t){function n(){this.constructor=e}z(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}function q(e,t,n,i){return new(n||(n=Promise))((function(a,r){function o(e){try{s(i.next(e))}catch(e){r(e)}}function l(e){try{s(i.throw(e))}catch(e){r(e)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(o,l)}s((i=i.apply(e,t||[])).next())}))}function H(e,t){var n,i,a,r,o={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return r={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function l(r){return function(l){return function(r){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,i&&(a=2&r[0]?i.return:r[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,r[1])).done)return a;switch(i=0,a&&(r=[2&r[0],a.value]),r[0]){case 0:case 1:a=r;break;case 4:return o.label++,{value:r[1],done:!1};case 5:o.label++,i=r[1],r=[0];continue;case 7:r=o.ops.pop(),o.trys.pop();continue;default:if(!(a=o.trys,(a=a.length>0&&a[a.length-1])||6!==r[0]&&2!==r[0])){o=0;continue}if(3===r[0]&&(!a||r[1]>a[0]&&r[1]<a[3])){o.label=r[1];break}if(6===r[0]&&o.label<a[1]){o.label=a[1],a=r;break}if(a&&o.label<a[2]){o.label=a[2],o.ops.push(r);break}a[2]&&o.ops.pop(),o.trys.pop();continue}r=t.call(e,o)}catch(e){r=[6,e],i=0}finally{n=a=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,l])}}}function $(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}var G=function(){function e(){}return e.ɵfac=function(t){return new(t||e)},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}(),W=function(){function e(){}return e.prototype.store=function(e,t){return q(this,void 0,void 0,(function(){var n;return H(this,(function(i){switch(i.label){case 0:return n=btoa(escape(JSON.stringify(t))),[4,localStorage.setItem(e,n)];case 1:return i.sent(),[2]}}))}))},e.prototype.get=function(e){return q(this,void 0,void 0,(function(){var t;return H(this,(function(n){switch(n.label){case 0:return[4,localStorage.getItem(e)];case 1:return t=n.sent(),[2,JSON.parse(unescape(atob(t)))]}}))}))},e.prototype.removeStorageItem=function(e){return q(this,void 0,void 0,(function(){return H(this,(function(t){switch(t.label){case 0:return[4,localStorage.removeItem(e)];case 1:return t.sent(),[2]}}))}))},e.prototype.clear=function(){return q(this,void 0,void 0,(function(){return H(this,(function(e){switch(e.label){case 0:return[4,localStorage.clear()];case 1:return e.sent(),[2]}}))}))},e.ɵfac=function(t){return new(t||e)},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}();function Z(e,n){1&e&&(t.ɵɵelementStart(0,"mat-label"),t.ɵɵtext(1,"Confirm"),t.ɵɵelementEnd())}function J(e,n){1&e&&(t.ɵɵelementStart(0,"mat-label"),t.ɵɵtext(1,"Information"),t.ɵɵelementEnd())}function Q(e,n){1&e&&(t.ɵɵelementStart(0,"mat-label"),t.ɵɵtext(1,"Error"),t.ɵɵelementEnd())}function K(e,n){if(1&e&&(t.ɵɵelementStart(0,"p"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵtextInterpolate(i._messageDetails)}}function Y(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵelementStart(1,"h3"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"mat-label"),t.ɵɵtext(4),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate(i._messageSubject),t.ɵɵadvance(2),t.ɵɵtextInterpolate(i._messageDetails)}}function X(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate(i._messageDetails)}}function ee(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",6),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().response("yes")})),t.ɵɵtext(1,"Yes"),t.ɵɵelementEnd()}}function te(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",7),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().response("no")})),t.ɵɵtext(1,"No"),t.ɵɵelementEnd()}}function ne(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",8),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().response("ok")})),t.ɵɵtext(1,"OK"),t.ɵɵelementEnd()}}var ie,ae=function(){function e(e,t){this.dialogRef=e,this.data=t}return e.prototype.ngOnInit=function(){this.messageType=this.data.type,this._messageSubject=this.data.subject,this._messageDetails=this.data.details},e.prototype.response=function(e){this.dialogRef.close(e)},e.ɵfac=function(i){return new(i||e)(t.ɵɵdirectiveInject(n.MatDialogRef),t.ɵɵdirectiveInject(n.MAT_DIALOG_DATA))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["lib-app-message"]],decls:12,vars:9,consts:[["mat-dialog-title",""],[4,"ngIf"],[1,"mat-typography"],["id","btnYes","mat-stroked-button","","cdkFocusInitial","",3,"click",4,"ngIf"],["id","btnNo","mat-stroked-button","",3,"click",4,"ngIf"],["id","btnOK","mat-stroked-button","","cdkFocusInitial","",3,"click",4,"ngIf"],["id","btnYes","mat-stroked-button","","cdkFocusInitial","",3,"click"],["id","btnNo","mat-stroked-button","",3,"click"],["id","btnOK","mat-stroked-button","","cdkFocusInitial","",3,"click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h2",0),t.ɵɵtemplate(1,Z,2,0,"mat-label",1),t.ɵɵtemplate(2,J,2,0,"mat-label",1),t.ɵɵtemplate(3,Q,2,0,"mat-label",1),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"mat-dialog-content",2),t.ɵɵtemplate(5,K,2,1,"p",1),t.ɵɵtemplate(6,Y,5,2,"div",1),t.ɵɵtemplate(7,X,3,1,"div",1),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"mat-dialog-actions"),t.ɵɵtemplate(9,ee,2,0,"button",3),t.ɵɵtemplate(10,te,2,0,"button",4),t.ɵɵtemplate(11,ne,2,0,"button",5),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(1),t.ɵɵproperty("ngIf","confirm"==n.messageType),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","info"==n.messageType),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","error"==n.messageType),t.ɵɵadvance(2),t.ɵɵproperty("ngIf","confirm"==n.messageType),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","info"==n.messageType),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","error"==n.messageType),t.ɵɵadvance(2),t.ɵɵproperty("ngIf","confirm"==n.messageType),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","confirm"==n.messageType),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","info"==n.messageType||"error"==n.messageType))},directives:[n.MatDialogTitle,i.NgIf,n.MatDialogContent,n.MatDialogActions,a.MatLabel,r.MatButton],encapsulation:2}),e}(),re=function(){function e(e,t){this.snackBar=e,this.dialog=t}return e.prototype.toast=function(e){this.snackBar.open(e,"OK",{duration:5e3})},e.prototype.info=function(e,t){this.dialog.open(ae,{width:"600px",data:{type:"info",subject:e,details:t}})},e.prototype.error=function(e){this.dialog.open(ae,{width:"600px",data:{type:"error",subject:void 0,details:e}})},e.prototype.confirm=function(e){var t=e;return this.dialog.open(ae,{width:"400px",data:{type:"confirm",subject:"",details:t}}).afterClosed().pipe(l.mergeMap((function(e){return o.of(e)})))},e.ɵfac=function(i){return new(i||e)(t.ɵɵinject(s.MatSnackBar),t.ɵɵinject(n.MatDialog))},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}(),oe=function(){function e(){this.fileType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8",this.fileExtension=".xlsx"}return e.prototype.exportExcel=function(e,t){var n={Sheets:{data:p.utils.json_to_sheet(e)},SheetNames:["data"]},i=p.write(n,{bookType:"xlsx",type:"array"});this.saveExcelFile(i,t)},e.prototype.saveExcelFile=function(e,t){var n=new Blob([e],{type:this.fileType});c.saveAs(n,t+this.fileExtension)},e.ɵfac=function(t){return new(t||e)},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}(),le=function(){function e(){}return e.getClone=function(e){return JSON.parse(JSON.stringify(e))},e.getNumber=function(e){return null==e||""==e?0:e.replace(/[^\d.-]/g,"")},e.getFirstDayOfMonth=function(){var e=new Date;return new Date(e.getFullYear(),e.getMonth(),1)},e.emailIsValid=function(e){return/\S+@\S+\.\S+/.test(e)},e.isValidUNCPath=function(e){return/\\\\([a-zA-Z0-9_.$●-]+)\\([a-zA-Z0-9_.$●-]+).*/.test(e)},e.isValidDate=function(e){var t=Date.parse(e);return!(!isNaN(e)||isNaN(t))},e.isValidEmailList=function(e){var t,n;if(e.includes(";")){var i=e.split(";");try{for(var a=$(i),r=a.next();!r.done;r=a.next()){var o=r.value;if(0==this.emailIsValid(o))return!1}}catch(e){t={error:e}}finally{try{r&&!r.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}}else if(0==this.emailIsValid(e))return!1;return!0},e.isNumber=function(e){return null!=e&&""!==e&&!isNaN(Number(e.toString()))},e.getDiff=function(e,t){void 0===t&&(t=Date());var n=new Date(e),i=new Date(t).valueOf()-n.valueOf();function a(e){return"1"==e.toFixed()?"":"s"}var r=i/6e4,o=i/36e5,l=i/864e5,s=i/6048e5,c=i/24192e5,p=i/31536e6;return p>=1?p.toFixed()+" year"+a(p):c>=1?c.toFixed()+" month"+a(c):s>=1?s.toFixed()+" week"+a(s):l>=1?l.toFixed()+" day"+a(l):o>=1?o.toFixed()+" hour"+a(o):r>=1?r.toFixed()+" minute"+a(r):i>=-6e4?"a minute":"N/A"},e.nowDate=function(e){return void 0===e&&(e=!1),e?this.getFormatedDate(Date(),!0):this.getFormatedDate(Date())},e.getFormatedDate=function(e,t){void 0===t&&(t=!1);var n=new Date(e);return n.setHours(n.getHours()+2),1==t?n.toISOString().split("T")[0]:n.toISOString().split(".")[0]},e.getBusinessDatesCount=function(e,t){for(var n=0,i=new Date(e),a=new Date(t),r=i;r<a;){var o=r.getDay();6!=o&&0!=o&&n++,r.setDate(r.getDate()+1)}return n},e.nullDate="01 Jan 1969",e}(),se=function(){},ce=function(){function e(){}return e.AUTH_USER="a",e.AUTH_NAME="b",e.AUTH_ROLES="c",e.AUTH_TOKEN="d",e.AUTH_TOKEN_EXPIRE="e",e}();(ie=e.LogLevel||(e.LogLevel={}))[ie.All=0]="All",ie[ie.Debug=1]="Debug",ie[ie.Info=2]="Info",ie[ie.Warn=3]="Warn",ie[ie.Error=4]="Error",ie[ie.Fatal=5]="Fatal",ie[ie.Off=6]="Off";var pe,de=function(){},me=function(){},ue=function(){this.enableFilter=!1,this.create=new fe,this.greyout=new ve},fe=function(){},ge=function(){this.name="default",this.display="default",this.type=e.TableColumnType.String};(pe=e.TableColumnType||(e.TableColumnType={}))[pe.String=0]="String",pe[pe.Date=1]="Date",pe[pe.DateTime=2]="DateTime",pe[pe.Image=3]="Image",pe[pe.Icon=4]="Icon",pe[pe.TextIcon=5]="TextIcon",pe[pe.Chip=6]="Chip";var he,ve=function(){this.field="",this.operator=e.Operator.Equal,this.value=""};(he=e.Operator||(e.Operator={}))[he.Equal=0]="Equal",he[he.Less=1]="Less",he[he.Greater=2]="Greater",he[he.NotEqual=3]="NotEqual";var ye=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return B(t,e),t}(ve),xe=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return B(t,e),t}(ve),Se=function(){},Ce=function(){},Me=function(){this.appName="",this.selfService=!1,this.logo="",this.logoSize="normal"},we=function(){this.appName="App Name",this.logo="",this.logoSize="normal",this.ADAuth=!0,this.localAuth=!0,this.selfService=!1},be=function(){this.name="",this.display="New Cap Item",this.enabled=!1,this.type="",this.newLine=!1,this.showMenu=!0,this.ignoreSubsDisplay=!1,this.link="",this.icon="navigate_next"},Ee=function(){},Ie=function(){this.userName="",this.password="",this.tries="0",this.locked="0",this.logged="0",this.disabled="0",this.changepassword="0",this.dateCreated=le.nowDate(),this.dateUpdated=le.nowDate(),this.token="",this.dateExpire=le.nowDate(),this.tokenExpire=le.nowDate(),this.authType=""},ke=function(){this.userName="",this.currentPassword="",this.newPassword="",this.confirmPassword=""},Pe=function(){this.userName="",this.roleID=1,this.firstName="",this.lastName="",this.email="",this.authType="",this.password=""},Ne=function(){this.profileID="",this.userName="",this.roleID=1,this.firstName="",this.lastName="",this.email="",this.empID="",this.arID="0",this.authType="",this.password="",this.role=new De},De=function(){this.roleID=0,this.roleName="New Role",this.cap1=!1,this.cap2=!1,this.cap3=!1,this.cap4=!1,this.cap5=!1,this.cap6=!1,this.cap7=!1,this.cap8=!1,this.cap9=!1,this.cap10=!1,this.cap11=!1,this.cap12=!1,this.cap13=!1,this.cap14=!1,this.cap15=!1,this.cap16=!1,this.cap17=!1,this.cap18=!1,this.cap19=!1,this.cap20=!1,this.cap21=!1,this.cap22=!1,this.cap23=!1,this.cap24=!1,this.cap25=!1,this.cap26=!1,this.cap27=!1,this.cap28=!1,this.cap29=!1,this.cap30=!1,this.cap31=!1,this.cap32=!1,this.cap33=!1,this.cap34=!1,this.cap35=!1,this.cap36=!1,this.cap37=!1,this.cap38=!1,this.cap39=!1,this.cap40=!1,this.cap41=!1,this.cap42=!1,this.cap43=!1,this.cap44=!1,this.cap45=!1,this.cap46=!1,this.cap47=!1,this.cap48=!1,this.cap49=!1,this.cap50=!1,this.cap51=!1,this.cap52=!1,this.cap53=!1,this.cap54=!1,this.cap55=!1,this.cap56=!1,this.cap57=!1,this.cap58=!1,this.cap59=!1,this.cap60=!1,this.cap61=!1,this.cap62=!1,this.cap63=!1,this.cap64=!1,this.cap65=!1,this.cap66=!1,this.cap67=!1,this.cap68=!1,this.cap69=!1,this.cap70=!1,this.cap71=!1,this.cap72=!1,this.cap73=!1,this.cap74=!1,this.cap75=!1,this.cap76=!1,this.cap77=!1,this.cap78=!1,this.cap79=!1,this.cap80=!1,this.cap81=!1,this.cap82=!1,this.cap83=!1,this.cap84=!1,this.cap85=!1,this.cap86=!1,this.cap87=!1,this.cap88=!1,this.cap89=!1,this.cap90=!1,this.cap91=!1,this.cap92=!1,this.cap93=!1,this.cap94=!1,this.cap95=!1,this.cap96=!1,this.cap97=!1,this.cap98=!1,this.cap99=!1,this.cap100=!1},Oe=function(){function e(e,t){this.httpClient=e,this.router=t,this.apiUrl="https://api.solinc.co.zw/",this.httpOptions_Legacy={headers:new m.HttpHeaders({Accept:"application/json","Content-Type":"application/json",Authorization:"Basic "+btoa("emptyUser:emptyToken")}),resposeType:"json"},this.httpOptions_Files={headers:new m.HttpHeaders({Authorization:"Basic "+btoa("tnyagato:j5Toszfr@ys")}),resposeType:"json"}}return e.prototype.Post=function(e,t){return this.httpClient.post(this.apiUrl+e,t,this.httpOptions_Legacy)},e.prototype.Put=function(e,t){return this.httpClient.put(this.apiUrl+e,t,this.httpOptions_Legacy)},e.prototype.Post_Raw=function(e,t){return this.httpClient.post(e,t,this.httpOptions_Legacy)},e.prototype.Post_WithFile=function(e,t,n){var i=new FormData;return n&&i.append("uploadFile",n,n.name),i.append("data",JSON.stringify(t)),this.httpClient.post(this.apiUrl+e,i,this.httpOptions_Files)},e.prototype.Post_FormData=function(e,t){return this.httpClient.post(this.apiUrl+e,t,this.httpOptions_Files)},e.prototype.Get=function(e){return this.httpClient.get(this.apiUrl+e,this.httpOptions_Legacy)},e.prototype.Get_Raw=function(e){return this.httpClient.get(e,this.httpOptions_Legacy)},e.prototype.Error=function(e){return"Unauthorized"==e.statusText?(this.router.navigate(["login"]),"Unauthorized"):"Connection failed"},e.ɵfac=function(n){return new(n||e)(t.ɵɵinject(m.HttpClient),t.ɵɵinject(d.Router))},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}(),Te=function(){function n(){this.level=e.LogLevel.All,this.logToConsole=!0,this.logToApi=!1}return n.prototype.debug=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];this.writeToLog(t,e.LogLevel.Debug,n)},n.prototype.info=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];this.writeToLog(t,e.LogLevel.Info,n)},n.prototype.warn=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];this.writeToLog(t,e.LogLevel.Warn,n)},n.prototype.error=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];this.writeToLog(t,e.LogLevel.Error,n)},n.prototype.fatal=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];this.writeToLog(t,e.LogLevel.Fatal,n)},n.prototype.log=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];this.writeToLog(t,e.LogLevel.All,n)},n.prototype.writeToLog=function(e,t,n){if(this.shouldLog(t)){var i=le.getFormatedDate(Date(),!1).replace("T"," ");i+=" - Message: "+e,n.length&&(i+=" - Extra Info: "+this.formatParams(n)),this.logToConsole&&console.log(i),this.logToApi}},n.prototype.formatParams=function(e){var t,n,i=e.join(",");if(e.some((function(e){return"object"==typeof e}))){i="";try{for(var a=$(e),r=a.next();!r.done;r=a.next()){var o=r.value;i+=JSON.stringify(o)+","}}catch(e){t={error:e}}finally{try{r&&!r.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}}return i},n.prototype.shouldLog=function(t){var n=!1;return(t>=this.level&&t!==e.LogLevel.Off||this.level===e.LogLevel.All)&&(n=!0),n},n.ɵfac=function(e){return new(e||n)},n.ɵprov=t.ɵɵdefineInjectable({token:n,factory:n.ɵfac,providedIn:"root"}),n}(),Fe=function(){function e(e,t,n,i,a,r){this._route=e,this.storage=t,this.router=n,this.httpService=i,this.messageService=a,this.logService=r,this.loggedin=!1,this.loggedinSource=new o.BehaviorSubject(this.loggedin),this.loggedinObserv=this.loggedinSource.asObservable(),this.token="",this.tokenSource=new o.BehaviorSubject(this.token),this.tokenObserv=this.tokenSource.asObservable(),this.tokenExpire="",this.tokenExpireSource=new o.BehaviorSubject(this.tokenExpire),this.tokenExpireObserv=this.tokenExpireSource.asObservable(),this.currentUser="tnyagato",this.currentUserSource=new o.BehaviorSubject(this.currentUser),this.currentUserObserv=this.currentUserSource.asObservable(),this.islineManager=!1,this.isLineManagerSource=new o.BehaviorSubject(this.islineManager),this.isLineManagerObserv=this.isLineManagerSource.asObservable(),this.currentRole=new De,this.currentRoleSource=new o.BehaviorSubject(this.currentRole),this.myRoleObserv=this.currentRoleSource.asObservable(),this.loggedUserSource=new o.BehaviorSubject("tnyagato"),this.loggedUserFullName=this.loggedUserSource.asObservable()}return e.prototype.Updateloggedin=function(e){this.loggedinSource.next(e),this.loggedin=e},e.prototype.UpdateToken=function(e){this.tokenSource.next(e)},e.prototype.UpdateTokenExpire=function(e){this.tokenExpireSource.next(e)},e.prototype.UpdateCurrentUser=function(e){this.currentUserSource.next(e.toLocaleLowerCase()),this.currentUser=e.toLocaleLowerCase()},e.prototype.UpdateIsLineManager=function(e){this.isLineManagerSource.next(e)},e.prototype.UpdateRole=function(e){this.currentRoleSource.next(e)},e.prototype.updateLoggedUserFullName=function(e){this.loggedUserSource.next(e)},e.prototype.isAuthorised=function(e){return!!this.currentRoleSource.value[e]||(this.router.navigate(["home"]),this.messageService.toast("Unauthorised: "+e),!1)},e.prototype.isValidToken=function(){var e=new Date(this.tokenExpireSource.value)>new Date;return e||(this.router.navigate(["login"]),this.messageService.toast("Expired Session")),e},e.prototype.canActivate=function(){var e=this;if(this.loggedin&&this.isValidToken())return!0;if(null===localStorage.getItem(ce.AUTH_USER)){this.Updateloggedin(!1);var t=new URL(window.location.href).hash.replace("#/","");return this.router.navigate(["login"],{relativeTo:this._route,queryParams:{redirectTo:t},queryParamsHandling:"merge",skipLocationChange:!1}),!1}return this.Updateloggedin(!0),this.storage.get(ce.AUTH_USER).then((function(t){e.UpdateCurrentUser(t)})),this.storage.get(ce.AUTH_NAME).then((function(t){e.updateLoggedUserFullName(t)})),this.storage.get(ce.AUTH_ROLES).then((function(t){var n=JSON.parse(t);e.UpdateRole(n)})),this.storage.get(ce.AUTH_TOKEN).then((function(t){e.UpdateToken(t)})),this.storage.get(ce.AUTH_TOKEN_EXPIRE).then((function(t){e.UpdateTokenExpire(t),e.isValidToken()})),!0},e.ɵfac=function(n){return new(n||e)(t.ɵɵinject(d.ActivatedRoute),t.ɵɵinject(W),t.ɵɵinject(d.Router),t.ɵɵinject(Oe),t.ɵɵinject(re),t.ɵɵinject(Te))},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}(),Le=function(){function e(e){this.httpService=e,this.appConfig=new we,this.appConfigSource=new o.BehaviorSubject(this.appConfig),this.appConfigObserv=this.appConfigSource.asObservable(),this.capHome=new be,this.capAdmin=new be,this.capUsers=new be,this.capRoles=new be,this.capLogs=new be,this.capSettings=new be,this.tmpProfileuserName="",this.appConfig.appName="App-Name",this.appConfig.logo="./assets/logo.png",this.appConfig.ADAuth=!0,this.appConfig.capItems=[this.capAdmin,this.capHome],this.capHome.name="cap1",this.capHome.display="Home",this.capHome.link="home",this.capAdmin.name="cap2",this.capAdmin.display="Admin",this.capAdmin.capSubItems=[this.capUsers,this.capRoles,this.capLogs,this.capSettings],this.capUsers.name="cap3",this.capUsers.display="Users",this.capUsers.link="home/admin/users",this.capRoles.name="cap4",this.capRoles.display="Roles",this.capRoles.link="home/admin/roles",this.capLogs.name="cap5",this.capLogs.display="Logs",this.capLogs.link="home/admin/logs",this.capSettings.name="cap6",this.capSettings.display="Settings",this.capSettings.link="home/admin/settings"}return e.prototype.UpdateAppConfig=function(e){this.appConfigSource.next(e),this.appConfig=e},e.prototype.GetUser=function(){return this.httpService.Get("User/all/x")},e.prototype.RegisterAccount=function(e){return this.httpService.Post("User/register",e)},e.prototype.GetUserByID=function(e){return this.httpService.Get("User/id/"+e)},e.prototype.UpdateUser=function(e){return this.httpService.Post("User/edit",e)},e.prototype.UnlockUser=function(e){return this.httpService.Post("User/unlock",e)},e.prototype.LockUser=function(e){return this.httpService.Post("User/lock",e)},e.prototype.DeleteUser=function(e){return this.httpService.Post("User/delete",e)},e.prototype.Login=function(e){return this.httpService.Post("User/login",e)},e.prototype.ChangePassword=function(e){return this.httpService.Post("User/changepassword-self",e)},e.prototype.ChangePasswordAdmin=function(e){return this.httpService.Post("User/changepassword-admin",e)},e.prototype.SelfReset=function(e){return this.httpService.Post("Basic/SelfReset",e)},e.prototype.PostRole=function(e,t){return this.httpService.Post("Role?action="+t,e)},e.prototype.PutRole=function(e){return this.httpService.Put("Role",e)},e.prototype.GetRole=function(e,t){return this.httpService.Get("Role/all/x")},e.prototype.GetLog=function(e,t){return this.httpService.Get("Log/all/x")},e.prototype.GetSetting=function(e,t){return this.httpService.Get("Setting/all/x")},e.prototype.UpdateSetting=function(e,t){return this.httpService.Post("Setting?action="+t,e)},e.ɵfac=function(n){return new(n||e)(t.ɵɵinject(Oe))},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}(),je=function(){function e(){this.isLoading=new o.BehaviorSubject(!1)}return e.ɵfac=function(t){return new(t||e)},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac,providedIn:"root"}),e}();function Ae(e,n){1&e&&t.ɵɵelement(0,"img",5)}function Re(e,n){if(1&e&&t.ɵɵelement(0,"img",6),2&e){var i=t.ɵɵnextContext();t.ɵɵproperty("src",i.logo,t.ɵɵsanitizeUrl)}}var Ue=function(){function e(e){var t=this;this.loaderService=e,this.logo="",this.loaderService.isLoading.subscribe((function(e){t.loading=e}))}return e.prototype.ngOnInit=function(){},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(je))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-loader"]],inputs:{logo:"logo"},decls:6,vars:3,consts:[[1,"progress-loader",2,"z-index","9999",3,"hidden"],[1,"loading-spinner"],["style","width: 100px;","src","data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNTAgMjUwIj4KICAgIDxwYXRoIGZpbGw9IiNERDAwMzEiIGQ9Ik0xMjUgMzBMMzEuOSA2My4ybDE0LjIgMTIzLjFMMTI1IDIzMGw3OC45LTQzLjcgMTQuMi0xMjMuMXoiIC8+CiAgICA8cGF0aCBmaWxsPSIjQzMwMDJGIiBkPSJNMTI1IDMwdjIyLjItLjFWMjMwbDc4LjktNDMuNyAxNC4yLTEyMy4xTDEyNSAzMHoiIC8+CiAgICA8cGF0aCAgZmlsbD0iI0ZGRkZGRiIgZD0iTTEyNSA1Mi4xTDY2LjggMTgyLjZoMjEuN2wxMS43LTI5LjJoNDkuNGwxMS43IDI5LjJIMTgzTDEyNSA1Mi4xem0xNyA4My4zaC0zNGwxNy00MC45IDE3IDQwLjl6IiAvPgogIDwvc3ZnPg==",4,"ngIf"],["style","width: 100px;",3,"src",4,"ngIf"],["id","loadingMessage",1,"loading-message"],["src","data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNTAgMjUwIj4KICAgIDxwYXRoIGZpbGw9IiNERDAwMzEiIGQ9Ik0xMjUgMzBMMzEuOSA2My4ybDE0LjIgMTIzLjFMMTI1IDIzMGw3OC45LTQzLjcgMTQuMi0xMjMuMXoiIC8+CiAgICA8cGF0aCBmaWxsPSIjQzMwMDJGIiBkPSJNMTI1IDMwdjIyLjItLjFWMjMwbDc4LjktNDMuNyAxNC4yLTEyMy4xTDEyNSAzMHoiIC8+CiAgICA8cGF0aCAgZmlsbD0iI0ZGRkZGRiIgZD0iTTEyNSA1Mi4xTDY2LjggMTgyLjZoMjEuN2wxMS43LTI5LjJoNDkuNGwxMS43IDI5LjJIMTgzTDEyNSA1Mi4xem0xNyA4My4zaC0zNGwxNy00MC45IDE3IDQwLjl6IiAvPgogIDwvc3ZnPg==",2,"width","100px"],[2,"width","100px",3,"src"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div",0),t.ɵɵelementStart(1,"div",1),t.ɵɵtemplate(2,Ae,1,0,"img",2),t.ɵɵtemplate(3,Re,1,1,"img",3),t.ɵɵelementStart(4,"span",4),t.ɵɵtext(5,"Please wait..."),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵproperty("hidden",!n.loading),t.ɵɵadvance(2),t.ɵɵproperty("ngIf",""==n.logo),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""!=n.logo))},directives:[i.NgIf],styles:[".loading-spinner[_ngcontent-%COMP%]{background-color:#0000001f;position:absolute;width:100%;top:0;left:0;height:100vh;align-items:center;justify-content:center;display:-ms-grid;display:grid}.loading-spinner[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{-ms-grid-row-align:end;align-self:end}.loading-message[_ngcontent-%COMP%]{text-align:center;-ms-grid-row-align:start;align-self:start}"]}),e}(),Ve=function(){function e(){}return e.ɵmod=t.ɵɵdefineNgModule({type:e}),e.ɵinj=t.ɵɵdefineInjector({factory:function(t){return new(t||e)},providers:[{provide:n.MAT_DIALOG_DEFAULT_OPTIONS,useValue:{disableClose:!0,hasBackdrop:!0}},{provide:y.MAT_DATE_LOCALE,useValue:"en-GB"}],imports:[[],i.CommonModule,L.FormsModule,L.ReactiveFormsModule,w.MatMenuModule,P.MatSliderModule,O.MatTableModule,b.MatPaginatorModule,h.MatCheckboxModule,f.MatBadgeModule,r.MatButtonModule,S.MatIconModule,n.MatDialogModule,s.MatSnackBarModule,T.MatTabsModule,a.MatFormFieldModule,C.MatInputModule,g.MatCardModule,v.MatChipsModule,k.MatSelectModule,y.MatNativeDateModule,E.MatProgressSpinnerModule,M.MatListModule,u.MatAutocompleteModule,F.MatTooltipModule,N.MatSortModule,x.MatDatepickerModule,D.MatStepperModule,I.MatRadioModule]}),e}();("undefined"==typeof ngJitMode||ngJitMode)&&t.ɵɵsetNgModuleScope(Ve,{exports:[i.CommonModule,L.FormsModule,L.ReactiveFormsModule,w.MatMenuModule,P.MatSliderModule,O.MatTableModule,b.MatPaginatorModule,h.MatCheckboxModule,f.MatBadgeModule,r.MatButtonModule,S.MatIconModule,n.MatDialogModule,s.MatSnackBarModule,T.MatTabsModule,a.MatFormFieldModule,C.MatInputModule,g.MatCardModule,v.MatChipsModule,k.MatSelectModule,y.MatNativeDateModule,E.MatProgressSpinnerModule,M.MatListModule,u.MatAutocompleteModule,F.MatTooltipModule,N.MatSortModule,x.MatDatepickerModule,D.MatStepperModule,I.MatRadioModule]});var _e=function(){function e(e,t,n,i,a){this.loaderService=e,this.messageService=t,this.authService=n,this.router=i,this.logService=a,this.requests=[]}return e.prototype.removeRequest=function(e){var t=this.requests.indexOf(e);t>=0&&this.requests.splice(t,1),this.loaderService.isLoading.next(this.requests.length>0)},e.prototype.intercept=function(e,t){var n=this,i=e.clone({setHeaders:{Authorization:"Bearer "+this.authService.tokenSource.value}});return this.requests.push(i),this.requests.length>1&&this.logService.info("Multiple connections detected > "+this.requests.length),this.loaderService.isLoading.next(!0),o.Observable.create((function(e){var a=t.handle(i).subscribe((function(t){t instanceof m.HttpResponse&&(n.removeRequest(i),e.next(t))}),(function(t){n.removeRequest(i),e.error(t),401===t.status?(n.router.navigate(["login"]),n.messageService.toast("Unauthorised: Please login again")):500===t.status?(console.log(t.error),n.messageService.toast("System Error")):"Unknown Error"==t.statusText?n.messageService.toast("Connection Error"):n.messageService.toast("Error: "+t.statusText)}),(function(){n.removeRequest(i),e.complete()}));return function(){n.removeRequest(i),a.unsubscribe()}}))},e.ɵfac=function(n){return new(n||e)(t.ɵɵinject(je),t.ɵɵinject(re),t.ɵɵinject(Fe),t.ɵɵinject(d.Router),t.ɵɵinject(Te))},e.ɵprov=t.ɵɵdefineInjectable({token:e,factory:e.ɵfac}),e}(),ze=function(){function e(){}return e.prototype.ngOnInit=function(){},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["lib-tin-spa"]],decls:2,vars:0,template:function(e,n){1&e&&(t.ɵɵelementStart(0,"p"),t.ɵɵtext(1," tin-spa works! "),t.ɵɵelementEnd())},encapsulation:2}),e}();function Be(e,n){if(1&e&&t.ɵɵelement(0,"img",8),2&e){var i=t.ɵɵnextContext(2);t.ɵɵproperty("src",i.appConfig.logo,t.ɵɵsanitizeUrl)}}function qe(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",19),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext(3).redirectTo(e.link)})),t.ɵɵtext(1),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display)}}function He(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",19),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext(3).redirectTo(e.link)})),t.ɵɵtext(1),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display)}}function $e(e,n){if(1&e&&(t.ɵɵelementStart(0,"button",20),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit,a=t.ɵɵreference(5);t.ɵɵproperty("matMenuTriggerFor",a),t.ɵɵadvance(1),t.ɵɵtextInterpolate(i.display)}}function Ge(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",22),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext(4).redirectTo(e.link)})),t.ɵɵtext(1),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display)}}function We(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵtemplate(1,Ge,2,1,"button",21),t.ɵɵelementEnd()),2&e){var i=n.$implicit,a=t.ɵɵnextContext(4);t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.myRole[i.name]&&i.showMenu)}}function Ze(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵtemplate(1,qe,2,1,"button",16),t.ɵɵtemplate(2,He,2,1,"button",16),t.ɵɵtemplate(3,$e,2,2,"button",17),t.ɵɵelementStart(4,"mat-menu",null,18),t.ɵɵtemplate(6,We,2,1,"div",15),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=n.$implicit,a=t.ɵɵnextContext(3);t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.myRole[i.name]&&!i.capSubItems&&i.showMenu),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.myRole[i.name]&&i.capSubItems&&i.showMenu&&i.ignoreSubsDisplay),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.myRole[i.name]&&i.capSubItems&&i.showMenu&&!i.ignoreSubsDisplay),t.ɵɵadvance(3),t.ɵɵproperty("ngForOf",i.capSubItems)}}var Je=function(e){return{show:e}};function Qe(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",9),t.ɵɵelementStart(1,"button",10),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext(2).redirectTo("login")})),t.ɵɵelementStart(2,"mat-icon"),t.ɵɵtext(3,"logout"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"button",11),t.ɵɵelementStart(5,"mat-icon"),t.ɵɵtext(6,"account_circle"),t.ɵɵelementEnd(),t.ɵɵtext(7),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"mat-menu",null,12),t.ɵɵelementStart(10,"button",13),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext(2).redirectTo("home/user/profile")})),t.ɵɵtext(11,"Profile"),t.ɵɵelementEnd(),t.ɵɵelementStart(12,"button",14),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext(2).redirectTo("login")})),t.ɵɵtext(13,"Log Off"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(14,Ze,7,4,"div",15),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵreference(9),r=t.ɵɵnextContext(2);t.ɵɵproperty("ngClass",t.ɵɵpureFunction1(4,Je,r.isExpanded)),t.ɵɵadvance(4),t.ɵɵproperty("matMenuTriggerFor",a),t.ɵɵadvance(3),t.ɵɵtextInterpolate1("  ",r.loggedUserFullName,""),t.ɵɵadvance(7),t.ɵɵproperty("ngForOf",r.appConfig.capItems)}}function Ke(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"header"),t.ɵɵelementStart(1,"nav",1),t.ɵɵelementStart(2,"div",2),t.ɵɵtemplate(3,Be,1,1,"img",3),t.ɵɵelementStart(4,"div",4),t.ɵɵtext(5),t.ɵɵelementEnd(),t.ɵɵelementStart(6,"button",5),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().toggle()})),t.ɵɵelement(7,"span",6),t.ɵɵelementEnd(),t.ɵɵtemplate(8,Qe,15,6,"div",7),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵadvance(3),t.ɵɵproperty("ngIf",""!=a.appConfig.logo),t.ɵɵadvance(2),t.ɵɵtextInterpolate1(" ",a.appConfig.appName," "),t.ɵɵadvance(1),t.ɵɵattribute("aria-expanded",a.isExpanded),t.ɵɵadvance(2),t.ɵɵproperty("ngIf",a.myRole)}}var Ye=function(){function e(e,t){this.router=e,this.authService=t,this.isExpanded=!1,this.appConfig=new we}return e.prototype.ngOnInit=function(){var e=this;this.authService.loggedUserFullName.subscribe((function(t){return e.loggedUserFullName=t})),this.authService.myRoleObserv.subscribe((function(t){return e.myRole=t})),this.authService.loggedinObserv.subscribe((function(t){return e.loggedin=t}))},e.prototype.collapse=function(){this.isExpanded=!1},e.prototype.toggle=function(){this.isExpanded=!this.isExpanded},e.prototype.redirectTo=function(e){""!=e&&this.router.navigate([e])},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(d.Router),t.ɵɵdirectiveInject(Fe))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-nav-menu"]],inputs:{appConfig:"appConfig"},decls:1,vars:1,consts:[[4,"ngIf"],[1,"toolbar","navbar","navbar-expand-sm","navbar-toggleable-sm","navbar-light","border-bottom","box-shadow","mb-3",2,"padding-right","10px"],[1,"container-fluid",2,"padding-right","0px"],["style","height: 50px; margin-right: 2em",3,"src",4,"ngIf"],[2,"font-size","20px"],["type","button","data-toggle","collapse","data-target",".navbar-collapse","aria-label","Toggle navigation",1,"navbar-toggler",3,"click"],[1,"navbar-toggler-icon"],["class","navbar-collapse collapse d-sm-inline-flex flex-sm-row-reverse stack-top","style","margin-right: 0px;",3,"ngClass",4,"ngIf"],[2,"height","50px","margin-right","2em",3,"src"],[1,"navbar-collapse","collapse","d-sm-inline-flex","flex-sm-row-reverse","stack-top",2,"margin-right","0px",3,"ngClass"],["mat-icon-button","",3,"click"],["id","btnUser","mat-button","",2,"margin-left","2em",3,"matMenuTriggerFor"],["profileMenu","matMenu"],["id","btnProfile","mat-menu-item","",3,"click"],["id","btnLogOff","mat-menu-item","",3,"click"],[4,"ngFor","ngForOf"],["id","btnMenu","mat-button","",3,"click",4,"ngIf"],["id","btnMenu","mat-button","",3,"matMenuTriggerFor",4,"ngIf"],["adminMenu","matMenu"],["id","btnMenu","mat-button","",3,"click"],["id","btnMenu","mat-button","",3,"matMenuTriggerFor"],["mat-menu-item","",3,"click",4,"ngIf"],["mat-menu-item","",3,"click"]],template:function(e,n){1&e&&t.ɵɵtemplate(0,Ke,9,4,"header",0),2&e&&t.ɵɵproperty("ngIf",n.loggedin)},directives:[i.NgIf,i.NgClass,r.MatButton,S.MatIcon,w.MatMenuTrigger,w._MatMenu,w.MatMenuItem,i.NgForOf],styles:["a.navbar-brand[_ngcontent-%COMP%]{white-space:normal;text-align:center;word-break:break-all}html[_ngcontent-%COMP%]{font-size:14px}@media (min-width:768px){html[_ngcontent-%COMP%]{font-size:16px}}.box-shadow[_ngcontent-%COMP%]{box-shadow:0 .25rem .75rem rgba(0,0,0,.05)}.toolbar[_ngcontent-%COMP%]{height:60px;display:flex;align-items:center;background-color:#03a;color:#fff;font-weight:600}.stack-top[_ngcontent-%COMP%]{z-index:9;margin:20px}"]}),e}(),Xe=function(){function e(e,t,n,i){var a=this;this.idle=e,this.keepalive=t,this.authService=n,this.router=i,this.loggedin=!1,this.idleState="Not started.",this.timedOut=!1,this.lastPing=null,this.isWarning=!1,this.authService.loggedinObserv.subscribe((function(e){a.loggedin=e})),e.setIdle(900),e.setTimeout(10),e.setInterrupts(U.DEFAULT_INTERRUPTSOURCES),e.onIdleStart.subscribe((function(){a.idleState="You've gone idle!"})),e.onIdleEnd.subscribe((function(){a.idleState="No longer idle.",a.isWarning=!1})),e.onTimeoutWarning.subscribe((function(e){a.idleState="You will be signed out in "+e+" seconds!",a.loggedin&&(a.isWarning=!0)})),e.onTimeout.subscribe((function(){a.idleState="Timed out!",a.timedOut=!0,a.stopWatch()})),t.interval(15),t.onPing.subscribe((function(){a.lastPing=new Date})),this.startWatch()}return e.prototype.ngOnInit=function(){},e.prototype.startWatch=function(){this.idle.watch(),this.idleState="Started.",this.timedOut=!1,this.isWarning=!1},e.prototype.stopWatch=function(){this.idle.stop(),this.isWarning=!1,this.router.navigate(["login"])},e.prototype.using=function(){this.isWarning=!1},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(U.Idle),t.ɵɵdirectiveInject(j.Keepalive),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(d.Router))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-timeout"]],decls:22,vars:2,consts:[[1,"loading-spinner",3,"hidden"],[2,"width","500px","text-align","center"],[1,"row"],[1,"col"],["src","data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNTAgMjUwIj4KICAgIDxwYXRoIGZpbGw9IiNERDAwMzEiIGQ9Ik0xMjUgMzBMMzEuOSA2My4ybDE0LjIgMTIzLjFMMTI1IDIzMGw3OC45LTQzLjcgMTQuMi0xMjMuMXoiIC8+CiAgICA8cGF0aCBmaWxsPSIjQzMwMDJGIiBkPSJNMTI1IDMwdjIyLjItLjFWMjMwbDc4LjktNDMuNyAxNC4yLTEyMy4xTDEyNSAzMHoiIC8+CiAgICA8cGF0aCAgZmlsbD0iI0ZGRkZGRiIgZD0iTTEyNSA1Mi4xTDY2LjggMTgyLjZoMjEuN2wxMS43LTI5LjJoNDkuNGwxMS43IDI5LjJIMTgzTDEyNSA1Mi4xem0xNyA4My4zaC0zNGwxNy00MC45IDE3IDQwLjl6IiAvPgogIDwvc3ZnPg==",2,"width","100px"],[1,"mat-elevation-z3"],[1,"row","justify-content-around"],[1,"col-2"],["mat-stroked-button","","color","primary",2,"width","100px",3,"click"],[1,"col-4"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div",0),t.ɵɵelementStart(1,"div",1),t.ɵɵelementStart(2,"div",2),t.ɵɵelementStart(3,"div",3),t.ɵɵelement(4,"img",4),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(5,"mat-card",5),t.ɵɵelementStart(6,"mat-card-header"),t.ɵɵelementStart(7,"h5"),t.ɵɵtext(8,"Are you still there ?"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(9,"mat-card-content"),t.ɵɵelement(10,"br"),t.ɵɵelementStart(11,"span"),t.ɵɵtext(12),t.ɵɵelementEnd(),t.ɵɵelement(13,"br"),t.ɵɵelementEnd(),t.ɵɵelementStart(14,"mat-card-actions"),t.ɵɵelementStart(15,"div",6),t.ɵɵelementStart(16,"div",7),t.ɵɵelementStart(17,"button",8),t.ɵɵlistener("click",(function(){return n.using()})),t.ɵɵtext(18,"Yes"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(19,"div",9),t.ɵɵelementStart(20,"button",8),t.ɵɵlistener("click",(function(){return n.stopWatch()})),t.ɵɵtext(21,"No"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵproperty("hidden",!n.isWarning),t.ɵɵadvance(12),t.ɵɵtextInterpolate(n.idleState))},directives:[g.MatCard,g.MatCardHeader,g.MatCardContent,g.MatCardActions,r.MatButton],styles:[".loading-spinner[_ngcontent-%COMP%]{background-color:#0000001f;position:absolute;width:100%;top:0;left:0;height:100vh;align-items:center;justify-content:center;display:-ms-grid;display:grid}.loading-spinner[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{-ms-grid-row-align:end;align-self:end}.loading-message[_ngcontent-%COMP%]{text-align:center;-ms-grid-row-align:start;align-self:start}"]}),e}(),et=["tablePaginator"];function tt(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",8),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext(2).create()})),t.ɵɵtext(1),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext(2);t.ɵɵproperty("disabled",!a.config.create.enabled),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.config.create.display)}}function nt(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",9),t.ɵɵelementStart(1,"mat-form-field",10),t.ɵɵelementStart(2,"mat-label"),t.ɵɵtext(3,"Filter"),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"input",11),t.ɵɵlistener("ngModelChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext(2)._filterText=e}))("keyup",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext(2).applyFilter(e.target.value)})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(5,"button",12),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext(2).load()})),t.ɵɵelementStart(6,"mat-icon",13),t.ɵɵtext(7,"refresh"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext(2);t.ɵɵadvance(4),t.ɵɵproperty("ngModel",a._filterText)}}function it(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",4),t.ɵɵelementStart(1,"div",5),t.ɵɵtemplate(2,tt,2,2,"button",6),t.ɵɵelementEnd(),t.ɵɵtemplate(3,nt,8,1,"div",7),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵproperty("ngIf",i.config.create),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",i.config.enableFilter)}}function at(e,n){if(1&e&&(t.ɵɵelementStart(0,"th",24),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.display," ")}}function rt(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit,a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i[a.name],"")}}var ot=function(e){return{color:e}};function lt(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",29),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit,a=t.ɵɵnextContext().$implicit;t.ɵɵproperty("ngStyle",t.ɵɵpureFunction1(2,ot,a.color.name)),t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i[a.name]," ")}}function st(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit,a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i[a.name]," ")}}function ct(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵtext(1),t.ɵɵpipe(2,"date"),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit,a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",t.ɵɵpipeBind2(2,1,i[a.name],"dd/MM/yyyy"),"")}}function pt(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵtext(1),t.ɵɵpipe(2,"date"),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit,a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",t.ɵɵpipeBind2(2,1,i[a.name],"dd/MM/yyyy HH:mm"),"")}}function dt(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-icon",31),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit;t.ɵɵproperty("ngStyle",t.ɵɵpureFunction1(3,ot,i.color))("matTooltip",i.hint),t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.name," ")}}function mt(e,n){if(1&e&&(t.ɵɵelementContainerStart(0),t.ɵɵtemplate(1,dt,2,5,"mat-icon",30),t.ɵɵelementContainerEnd()),2&e){var i=n.$implicit,a=t.ɵɵnextContext().$implicit,r=t.ɵɵnextContext().$implicit,o=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵproperty("ngIf",r.type==o.colType.Icon&&o.test(a[i.field],i.operator,i.value))}}function ut(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",25),t.ɵɵtemplate(1,rt,2,1,"div",26),t.ɵɵtemplate(2,lt,2,4,"div",27),t.ɵɵtemplate(3,st,2,1,"div",26),t.ɵɵtemplate(4,ct,3,4,"div",26),t.ɵɵtemplate(5,pt,3,4,"div",26),t.ɵɵtemplate(6,mt,2,1,"ng-container",28),t.ɵɵelementEnd()),2&e){var i=n.$implicit,a=t.ɵɵnextContext().$implicit,r=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵproperty("ngIf",(a.type==r.colType.String||null==a.type)&&null==a.color),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",(a.type==r.colType.String||null==a.type)&&null!=a.color&&r.test(i[a.color.field],a.color.operator,a.color.value)),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",(a.type==r.colType.String||null==a.type)&&null!=a.color&&!r.test(i[a.color.field],a.color.operator,a.color.value)),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.type==r.colType.Date),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.type==r.colType.DateTime),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",a.icons)}}function ft(e,n){if(1&e&&(t.ɵɵelementContainerStart(0,22),t.ɵɵtemplate(1,at,2,1,"th",18),t.ɵɵtemplate(2,ut,7,6,"td",23),t.ɵɵelementContainerEnd()),2&e){var i=n.$implicit;t.ɵɵproperty("matColumnDef",i.name)}}function gt(e,n){1&e&&(t.ɵɵelementStart(0,"th",24),t.ɵɵtext(1," Action "),t.ɵɵelementEnd())}function ht(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",33),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit,n=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext(2).do(e.name,n)})),t.ɵɵelementStart(1,"mat-icon"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext().$implicit,r=t.ɵɵnextContext().$implicit;t.ɵɵproperty("disabled",a.disable&&r[a.disable.field]==a.disable.value)("color",null==a.color?"primary":a.color)("matTooltip",a.hint),t.ɵɵadvance(2),t.ɵɵtextInterpolate(a.icon)}}function vt(e,n){if(1&e&&(t.ɵɵelementContainerStart(0),t.ɵɵtemplate(1,ht,3,4,"button",32),t.ɵɵelementContainerEnd()),2&e){var i=n.$implicit,a=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵproperty("ngIf",i.disappear&&a[i.disappear.field]!=i.disappear.value||!i.disappear)}}function yt(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",25),t.ɵɵtemplate(1,vt,2,1,"ng-container",28),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext(2);t.ɵɵstyleMap(i.styleString+";padding-right: 0px;"),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",i.config.actions)}}function xt(e,n){1&e&&t.ɵɵelement(0,"tr",34)}var St=function(e){return{"make-gray":e}};function Ct(e,n){if(1&e&&t.ɵɵelement(0,"tr",35),2&e){var i=n.$implicit,a=t.ɵɵnextContext(2);t.ɵɵproperty("ngClass",t.ɵɵpureFunction1(1,St,i[a.config.greyout.field]==a.config.greyout.value))}}function Mt(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",14),t.ɵɵelementStart(1,"table",15),t.ɵɵtemplate(2,ft,3,1,"ng-container",16),t.ɵɵelementContainerStart(3,17),t.ɵɵtemplate(4,gt,2,0,"th",18),t.ɵɵtemplate(5,yt,2,3,"td",19),t.ɵɵelementContainerEnd(),t.ɵɵtemplate(6,xt,1,0,"tr",20),t.ɵɵtemplate(7,Ct,1,3,"tr",21),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("dataSource",i.data),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",i.config.columns),t.ɵɵadvance(4),t.ɵɵproperty("matHeaderRowDef",i.displayedColumns),t.ɵɵadvance(1),t.ɵɵproperty("matRowDefColumns",i.displayedColumns)}}var wt=function(){return[10,50,100]},bt=function(){function n(){this.dataChange=new t.EventEmitter,this.buttonClick=new t.EventEmitter,this.loadClick=new t.EventEmitter,this.createClick=new t.EventEmitter,this.colType=e.TableColumnType,this.op=e.Operator,this.displayedColumns=[],this._filterText=""}return n.prototype.ngOnInit=function(){var e=this;this.config.columns.forEach((function(t){e.displayedColumns.push(t.name)})),this.displayedColumns.push("Action"),this.styleString="width: "+50*this.config.actions.length+"px"},n.prototype.ngOnChanges=function(){this.data=new O.MatTableDataSource(this.data),this.data.paginator=this.tablePaginator,this.applyFilter(this._filterText)},n.prototype.applyFilter=function(e){this.data.filter=e.trim().toLowerCase()},n.prototype.do=function(e,t){var n=new Ce;n.name=e,n.value=t,this.buttonClick.emit(n)},n.prototype.create=function(){this.createClick.emit()},n.prototype.load=function(){this.loadClick.emit()},n.prototype.test=function(t,n,i){return n==e.Operator.Equal?t==i:n==e.Operator.Greater?t>i:n==e.Operator.Less?t<i:n==e.Operator.NotEqual?t!=i:void 0},n.ɵfac=function(e){return new(e||n)},n.ɵcmp=t.ɵɵdefineComponent({type:n,selectors:[["spa-table"]],viewQuery:function(e,n){var i;(1&e&&t.ɵɵviewQuery(et,!0),2&e)&&(t.ɵɵqueryRefresh(i=t.ɵɵloadQuery())&&(n.tablePaginator=i.first))},inputs:{config:"config",data:"data"},outputs:{dataChange:"dataChange",buttonClick:"buttonClick",loadClick:"loadClick",createClick:"createClick"},features:[t.ɵɵNgOnChangesFeature],decls:5,vars:4,consts:[["class","row justify-content-between","style","padding-bottom: 10px",4,"ngIf"],["class","mat-elevation-z8",4,"ngIf"],["showFirstLastButtons","",3,"pageSizeOptions"],["tablePaginator",""],[1,"row","justify-content-between",2,"padding-bottom","10px"],[1,"col"],["mat-raised-button","","color","primary",3,"disabled","click",4,"ngIf"],["class","col d-flex justify-content-end",4,"ngIf"],["mat-raised-button","","color","primary",3,"disabled","click"],[1,"col","d-flex","justify-content-end"],[2,"font-size","12px","margin-right","5px"],["matInput","","placeholder","Enter Filter text","autocomplete","off",3,"ngModel","ngModelChange","keyup"],["mat-mini-fab","","color","primary","matTooltip","refresh data","matTooltipPosition","right",2,"margin-top","5px",3,"click"],[1,"refreshIcon"],[1,"mat-elevation-z8"],["mat-table","",3,"dataSource"],[3,"matColumnDef",4,"ngFor","ngForOf"],["matColumnDef","Action"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",3,"style",4,"matCellDef"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",3,"ngClass",4,"matRowDef","matRowDefColumns"],[3,"matColumnDef"],["mat-cell","",4,"matCellDef"],["mat-header-cell",""],["mat-cell",""],[4,"ngIf"],[3,"ngStyle",4,"ngIf"],[4,"ngFor","ngForOf"],[3,"ngStyle"],["matTooltipPosition","above",3,"ngStyle","matTooltip",4,"ngIf"],["matTooltipPosition","above",3,"ngStyle","matTooltip"],["mat-mini-fab","","matTooltipPosition","above","style","margin-right:5px",3,"disabled","color","matTooltip","click",4,"ngIf"],["mat-mini-fab","","matTooltipPosition","above",2,"margin-right","5px",3,"disabled","color","matTooltip","click"],["mat-header-row",""],["mat-row","",3,"ngClass"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵtemplate(1,it,4,2,"div",0),t.ɵɵtemplate(2,Mt,8,4,"div",1),t.ɵɵelement(3,"mat-paginator",2,3),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.config.create.enabled||n.config.enableFilter),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.data),t.ɵɵadvance(1),t.ɵɵproperty("pageSizeOptions",t.ɵɵpureFunction0(3,wt)))},directives:[i.NgIf,b.MatPaginator,r.MatButton,a.MatFormField,a.MatLabel,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.NgModel,F.MatTooltip,S.MatIcon,O.MatTable,i.NgForOf,O.MatColumnDef,O.MatHeaderCellDef,O.MatCellDef,O.MatHeaderRowDef,O.MatRowDef,O.MatHeaderCell,O.MatCell,i.NgStyle,O.MatHeaderRow,O.MatRow,i.NgClass],pipes:[i.DatePipe],styles:[".mat-mini-fab[_ngcontent-%COMP%]{width:32px;height:32px}.mat-mini-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:16px;margin-top:-3px}.make-gray[_ngcontent-%COMP%]{background-color:#d3d3d3}"]}),n}(),Et=function(e,t){return{color:e,"font-size":t}},It=function(e){return{"font-size":e}};function kt(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-card",3),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext().clicked(e)})),t.ɵɵelementStart(1,"div",4),t.ɵɵelementStart(2,"mat-label",5),t.ɵɵtext(3),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"div",6),t.ɵɵelementStart(5,"mat-label",7),t.ɵɵtext(6),t.ɵɵelementEnd(),t.ɵɵelementStart(7,"mat-icon",8),t.ɵɵtext(8,"info"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext().$implicit,r=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵproperty("ngStyle",t.ɵɵpureFunction2(6,Et,a.tileColor,a.tileName==r.selected?"35px":"30px")),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.tileValue),t.ɵɵadvance(2),t.ɵɵproperty("ngStyle",t.ɵɵpureFunction1(9,It,a.tileName==r.selected?"18px":"12px")),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.tileName),t.ɵɵadvance(1),t.ɵɵproperty("matTooltip",a.info)("ngStyle",t.ɵɵpureFunction1(11,It,a.tileName==r.selected?"20px":"17px"))}}function Pt(e,n){if(1&e&&(t.ɵɵelementContainerStart(0),t.ɵɵtemplate(1,kt,9,13,"mat-card",2),t.ɵɵelementContainerEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵproperty("ngIf",i.visible)}}var Nt=function(){function e(){this.clickable=!1,this.tileClick=new t.EventEmitter,this.selected=""}return e.prototype.ngOnInit=function(){},e.prototype.clicked=function(e){this.clickable&&(this.selected==e.tileName?(this.tileClick.emit(""),this.selected=""):(this.tileClick.emit(e.tileName),this.selected=e.tileName))},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-tiles"]],inputs:{tiles:"tiles",clickable:"clickable"},outputs:{tileClick:"tileClick"},decls:2,vars:1,consts:[[1,"row","align-items-center"],[4,"ngFor","ngForOf"],["class","col","style","margin-left: 10px;margin-right: 10px",3,"click",4,"ngIf"],[1,"col",2,"margin-left","10px","margin-right","10px",3,"click"],[1,"row","d-flex","justify-content-center"],[2,"font-weight","bold",3,"ngStyle"],[1,"row","d-flex","justify-content-center","row","align-items-center"],[2,"padding-left","5px","padding-right","5px",3,"ngStyle"],["matTooltipPosition","above",2,"color","steelblue",3,"matTooltip","ngStyle"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div",0),t.ɵɵtemplate(1,Pt,2,1,"ng-container",1),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",n.tiles))},directives:[i.NgForOf,i.NgIf,g.MatCard,a.MatLabel,i.NgStyle,S.MatIcon,F.MatTooltip],styles:[""]}),e}(),Dt=function(){function e(){this.date=new L.FormControl(new Date),this.display="",this.readonly=!1,this.currentYear=(new Date).getFullYear(),this.min=new L.FormControl(new Date(this.currentYear-50,0,1)),this.max=new L.FormControl(new Date(this.currentYear+50,0,1)),this.dateChange=new t.EventEmitter}return e.prototype.ngOnInit=function(){},e.prototype.onChangeEvent=function(){this.dateChange.emit()},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-date"]],inputs:{date:"date",display:"display",readonly:"readonly",min:"min",max:"max"},outputs:{dateChange:"dateChange"},decls:5,vars:8,consts:[[2,"width","150px","margin-right","20px"],["matInput","",3,"formControl","min","max","matDatepicker","placeholder","readonly","disabled","dateInput"],["matSuffix","",3,"for"],["picker_date",""]],template:function(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-form-field",0),t.ɵɵelementStart(1,"input",1),t.ɵɵlistener("dateInput",(function(){return n.onChangeEvent()})),t.ɵɵelementEnd(),t.ɵɵelement(2,"mat-datepicker-toggle",2),t.ɵɵelement(3,"mat-datepicker",null,3),t.ɵɵelementEnd()),2&e){var i=t.ɵɵreference(4);t.ɵɵadvance(1),t.ɵɵproperty("formControl",n.date)("min",n.min.value)("max",n.max.value)("matDatepicker",i)("placeholder",n.display)("readonly",!0)("disabled",n.readonly),t.ɵɵadvance(1),t.ɵɵproperty("for",i)}},directives:[a.MatFormField,C.MatInput,L.DefaultValueAccessor,x.MatDatepickerInput,L.NgControlStatus,L.FormControlDirective,x.MatDatepickerToggle,a.MatSuffix,x.MatDatepicker],styles:[""]}),e}();function Ot(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-label"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵtextInterpolate(i.display)}}function Tt(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-label"),t.ɵɵtext(1),t.ɵɵpipe(2,"date"),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵtextInterpolate(t.ɵɵpipeBind2(2,1,i.display,"dd/MM/yyyy"))}}function Ft(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-error"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵtextInterpolate(i.validate())}}var Lt=function(e){return{width:e}};function jt(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-form-field",1),t.ɵɵtemplate(1,Ot,2,1,"mat-label",2),t.ɵɵtemplate(2,Tt,3,4,"mat-label",2),t.ɵɵelementStart(3,"input",3),t.ɵɵlistener("ngModelChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().value=e}))("change",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changed()}))("blur",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().leaved()}))("keyup.enter",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().enterPressed()})),t.ɵɵelementEnd(),t.ɵɵtemplate(4,Ft,2,1,"mat-error",2),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵproperty("hintLabel",a.hint)("ngStyle",t.ɵɵpureFunction1(11,Lt,a.width)),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","text"==a.format),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","date"==a.format),t.ɵɵadvance(1),t.ɵɵproperty("ngModel",a.value)("type",a.type)("placeholder",a.placeholder)("formControl",a.control)("required",a.required)("readonly",a.readonly),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.control.invalid)}}function At(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-error"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵtextInterpolate(i.validate())}}function Rt(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-form-field",1),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"textarea",4),t.ɵɵlistener("ngModelChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().value=e}))("change",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changed()}))("keyup.enter",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().enterPressed()})),t.ɵɵelementEnd(),t.ɵɵtemplate(4,At,2,1,"mat-error",2),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵproperty("hintLabel",a.hint)("ngStyle",t.ɵɵpureFunction1(10,Lt,a.width)),t.ɵɵadvance(2),t.ɵɵtextInterpolate(a.display),t.ɵɵadvance(1),t.ɵɵproperty("rows",a.rows)("ngModel",a.value)("placeholder",a.placeholder)("formControl",a.control)("required",a.required)("readonly",a.readonly),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",a.control.invalid)}}var Ut=function(){function e(){this.hideRequiredControl=new L.FormControl(!0),this.readonly=!1,this.hint="",this.display="",this.placeholder="",this.value="",this.valueChange=new t.EventEmitter,this.format="text",this.type="",this.leave=new t.EventEmitter,this.enterPress=new t.EventEmitter,this.rows="",this.width="100%",this.options=[],this.optionValue="",this.optionDisplay="",this.myControl=new L.FormControl,this.required=!0,this.min=0,this.max=9e15,this.regex="",this.control=new L.FormControl(this.value,[L.Validators.required,L.Validators.minLength(this.min),L.Validators.maxLength(this.max),L.Validators.pattern(this.regex)])}return e.prototype.ngOnInit=function(){this.options.length>0&&this.initFilter(),""==this.placeholder&&(this.placeholder="Enter "+this.display)},e.prototype.ngAfterViewInit=function(){this.readonly&&(this.control.setValidators(null),this.control.updateValueAndValidity()),this.required||this.readonly||(this.control.setValidators([L.Validators.minLength(this.min),L.Validators.maxLength(this.max),L.Validators.pattern(this.regex)]),this.control.updateValueAndValidity())},e.prototype.initFilter=function(){var e=this;this.filteredOptions=this.myControl.valueChanges.pipe(l.startWith(""),l.map((function(t){return e._filter(t)})))},e.prototype._filter=function(e){var t=this,n=e.toLowerCase();return this.options.filter((function(e){return e[""+t.optionDisplay].toLowerCase().includes(n)}))},e.prototype.changed=function(){this.valueChange.emit(this.value)},e.prototype.changed2=function(){this.valueChange.emit(this.myControl.value)},e.prototype.leaved=function(){this.leave.emit()},e.prototype.enterPressed=function(){this.enterPress.emit()},e.prototype.validate=function(){return(this.required||this.min>0)&&this.control.hasError("required")?"Required":this.control.hasError("minlength")?"Minimun length is "+this.min:this.control.hasError("maxlength")?"Maximum length is "+this.max:this.control.hasError("pattern")?"Invalid Input":""},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-text"]],inputs:{readonly:"readonly",hint:"hint",display:"display",placeholder:"placeholder",value:"value",format:"format",type:"type",rows:"rows",width:"width",options:"options",optionValue:"optionValue",optionDisplay:"optionDisplay",required:"required",min:"min",max:"max",regex:"regex"},outputs:{valueChange:"valueChange",leave:"leave",enterPress:"enterPress"},decls:2,vars:2,consts:[["hideRequiredMarker","true","style","padding-right: 20px;",3,"hintLabel","ngStyle",4,"ngIf"],["hideRequiredMarker","true",2,"padding-right","20px",3,"hintLabel","ngStyle"],[4,"ngIf"],["matInput","","autocomplete","off",3,"ngModel","type","placeholder","formControl","required","readonly","ngModelChange","change","blur","keyup.enter"],["matInput","","autocomplete","off",3,"rows","ngModel","placeholder","formControl","required","readonly","ngModelChange","change","keyup.enter"]],template:function(e,n){1&e&&(t.ɵɵtemplate(0,jt,5,13,"mat-form-field",0),t.ɵɵtemplate(1,Rt,5,12,"mat-form-field",0)),2&e&&(t.ɵɵproperty("ngIf",""==n.rows&&0==n.options.length),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""!=n.rows&&0==n.options.length))},directives:[i.NgIf,a.MatFormField,i.NgStyle,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.FormControlDirective,L.RequiredValidator,a.MatLabel,a.MatError],pipes:[i.DatePipe],styles:[""]}),e}();function Vt(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-icon",6),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵtextInterpolate(i.icon)}}function _t(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-icon",7),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext().removed(e)})),t.ɵɵtext(1,"cancel"),t.ɵɵelementEnd()}}var zt=function(e){return{"padding-right":e}};function Bt(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-chip",3),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=n.$implicit;return t.ɵɵnextContext().clicked(e)})),t.ɵɵtemplate(1,Vt,2,1,"mat-icon",4),t.ɵɵtext(2),t.ɵɵtemplate(3,_t,2,0,"mat-icon",5),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext();t.ɵɵproperty("removable",r.removable)("ngStyle",t.ɵɵpureFunction1(5,zt,r.removable?"5px":"12px")),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""!=r.icon),t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",a," "),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",r.removable)}}var qt=function(){function e(e){this.messageService=e,this.icon="",this.removable=!1,this.addable=!1,this.click=new t.EventEmitter,this.remove=new t.EventEmitter}return e.prototype.ngOnInit=function(){},e.prototype.clicked=function(e){"string"==typeof e&&e&&this.click.emit(e)},e.prototype.removed=function(e){var t=this;this.messageService.confirm("Remove "+e+" ?").subscribe((function(n){"yes"==n&&t.remove.emit(e)}))},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(re))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-chips"]],inputs:{icon:"icon",removable:"removable",addable:"addable",chips:"chips"},outputs:{click:"click",remove:"remove"},decls:4,vars:1,consts:[[1,"row","mt-1",2,"margin-left","1em"],["chipList",""],["selectable","","style","font-size: 12px;",3,"removable","ngStyle","click",4,"ngFor","ngForOf"],["selectable","",2,"font-size","12px",3,"removable","ngStyle","click"],["color","primary","style","font-size: 22px;",4,"ngIf"],["style","font-size: 20px; margin-left: 5px;margin-top: 3px;margin-right: 0px; color: grey;",3,"click",4,"ngIf"],["color","primary",2,"font-size","22px"],[2,"font-size","20px","margin-left","5px","margin-top","3px","margin-right","0px","color","grey",3,"click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div",0),t.ɵɵelementStart(1,"mat-chip-list",null,1),t.ɵɵtemplate(3,Bt,4,7,"mat-chip",2),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(3),t.ɵɵproperty("ngForOf",n.chips))},directives:[v.MatChipList,i.NgForOf,v.MatChip,i.NgStyle,i.NgIf,S.MatIcon],styles:[""]}),e}();function Ht(e,n){if(1&e&&t.ɵɵelement(0,"ngx-doc-viewer",9),2&e){var i=t.ɵɵnextContext();t.ɵɵproperty("url",i.currentFileUrl)}}function $t(e,n){1&e&&(t.ɵɵelementStart(0,"div",10),t.ɵɵtext(1," This file type will be downloaded "),t.ɵɵelementEnd())}var Gt=function(){function e(e,t){this.httpService=e,this.data=t,this.isProcessing=!1,this.fileNames=new Array,this.currIndex=0,this.currentFileUrl="",this.imageDoc=!1}return e.prototype.ngOnInit=function(){this.fileNames=this.data.fileNames,this.path=this.data.path,this.fileName=this.data.fileName,this.currIndex=this.data.fileNames.indexOf(this.fileName),this.setURL()},e.prototype.previous=function(){0!=this.fileNames.length&&(this.currIndex-1>=0?this.currIndex=this.currIndex-1:0==this.currIndex&&(this.currIndex=this.fileNames.length-1),this.setURL())},e.prototype.next=function(){0!=this.fileNames.length&&(this.currIndex+1<this.fileNames.length?this.currIndex=this.currIndex+1:this.currIndex+1>this.fileNames.length-1&&(this.currIndex=0),this.setURL())},e.prototype.setURL=function(){this.currentFileUrl=""+this.httpService.apiUrl.replace("/api/","/")+this.path.replace("//","/")+"/"+this.fileNames[this.currIndex],this.currentFileUrl.toLocaleLowerCase().endsWith(".pdf")||this.currentFileUrl.toLocaleLowerCase().endsWith(".jpg")||this.currentFileUrl.toLocaleLowerCase().endsWith(".jpeg")?this.imageDoc=!0:(this.imageDoc=!1,window.open(this.currentFileUrl,"_blank"))},e.prototype.change=function(e){this.currIndex=this.fileNames.indexOf(e),this.setURL()},e.ɵfac=function(i){return new(i||e)(t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(n.MAT_DIALOG_DATA))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["app-editRequest"]],decls:14,vars:5,consts:[[1,"mat-typography"],[1,"row"],[1,"col"],["viewer","url","style","width:100%;height:60vh;",3,"url",4,"ngIf"],["class","d-flex justify-content-center row align-items-center","style","height:60vh;",4,"ngIf"],[1,"col-3"],["display","Documents","icon","description",3,"chips","click"],["mat-button","","cdkFocusInitial","",3,"disabled","click"],["mat-button","","mat-dialog-close",""],["viewer","url",2,"width","100%","height","60vh",3,"url"],[1,"d-flex","justify-content-center","row","align-items-center",2,"height","60vh"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-dialog-content",0),t.ɵɵelementStart(1,"div",1),t.ɵɵelementStart(2,"div",2),t.ɵɵtemplate(3,Ht,1,1,"ngx-doc-viewer",3),t.ɵɵtemplate(4,$t,2,0,"div",4),t.ɵɵelementEnd(),t.ɵɵelementStart(5,"div",5),t.ɵɵelementStart(6,"spa-chips",6),t.ɵɵlistener("click",(function(e){return n.change(e)})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(7,"mat-dialog-actions"),t.ɵɵelementStart(8,"button",7),t.ɵɵlistener("click",(function(){return n.previous()})),t.ɵɵtext(9,"Previous"),t.ɵɵelementEnd(),t.ɵɵelementStart(10,"button",7),t.ɵɵlistener("click",(function(){return n.next()})),t.ɵɵtext(11,"Next"),t.ɵɵelementEnd(),t.ɵɵelementStart(12,"button",8),t.ɵɵtext(13,"Cancel"),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(3),t.ɵɵproperty("ngIf",n.imageDoc),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",!n.imageDoc),t.ɵɵadvance(2),t.ɵɵproperty("chips",n.fileNames),t.ɵɵadvance(2),t.ɵɵproperty("disabled",0==n.currIndex),t.ɵɵadvance(2),t.ɵɵproperty("disabled",n.currIndex+1==n.fileNames.length))},directives:[n.MatDialogContent,i.NgIf,qt,n.MatDialogActions,r.MatButton,n.MatDialogClose,R.NgxDocViewerComponent],styles:[".truncate-text[_ngcontent-%COMP%]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.align-end[_ngcontent-%COMP%]{justify-content:flex-end}.fx-spacer[_ngcontent-%COMP%]{flex:1 1 auto}"]}),e}();function Wt(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",3),t.ɵɵelementStart(1,"mat-label",4),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate1(" ",i.title,"")}}function Zt(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",5),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" No ",i.title.toLowerCase()," ")}}var Jt=function(){function e(e){this.dialog=e,this.dir="",this.folderName="",this.fileNames=new Array,this.removable=!1,this.remove=new t.EventEmitter,this.display="Documents",this.title="Documents"}return e.prototype.ngOnInit=function(){},e.prototype.viewDocs=function(e){if("string"==typeof e)this.dialog.open(Gt,{minWidth:"1500px",maxWidth:"80vw",data:{fileNames:this.fileNames,fileName:e,path:this.dir+"/"+this.folderName}})},e.prototype.removed=function(e){this.remove.emit(e)},e.ɵfac=function(i){return new(i||e)(t.ɵɵdirectiveInject(n.MatDialog))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-viewer"]],inputs:{dir:"dir",folderName:"folderName",fileNames:"fileNames",removable:"removable",display:"display",title:"title"},outputs:{remove:"remove"},decls:3,vars:5,consts:[["class","tin-input-row mt-3",4,"ngIf"],["icon","description",3,"chips","title","removable","click","remove"],["class","d-flex justify-content-center row align-items-center","style","max-height:200px",4,"ngIf"],[1,"tin-input-row","mt-3"],[2,"font-size","20px","font-weight","300"],[1,"d-flex","justify-content-center","row","align-items-center",2,"max-height","200px"]],template:function(e,n){1&e&&(t.ɵɵtemplate(0,Wt,3,1,"div",0),t.ɵɵelementStart(1,"spa-chips",1),t.ɵɵlistener("click",(function(e){return n.viewDocs(e)}))("remove",(function(e){return n.removed(e)})),t.ɵɵelementEnd(),t.ɵɵtemplate(2,Zt,2,1,"div",2)),2&e&&(t.ɵɵproperty("ngIf",""!=n.title),t.ɵɵadvance(1),t.ɵɵproperty("chips",n.fileNames)("title",n.title)("removable",n.removable),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",!n.fileNames))},directives:[i.NgIf,qt,a.MatLabel],styles:[".truncate-text[_ngcontent-%COMP%]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.align-end[_ngcontent-%COMP%]{justify-content:flex-end}.fx-spacer[_ngcontent-%COMP%]{flex:1 1 auto}"]}),e}();function Qt(e,n){if(1&e&&(t.ɵɵelementStart(0,"label"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext().$implicit,a=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵtextInterpolate1("(",i[a.optionDisplayExtra],")")}}function Kt(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-option",5),t.ɵɵtext(1),t.ɵɵtemplate(2,Qt,2,1,"label",4),t.ɵɵelementEnd()),2&e){var i=n.$implicit,a=t.ɵɵnextContext(2);t.ɵɵproperty("value",i[a.optionValue]),t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i[a.optionDisplay]," "),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""!=a.optionDisplayExtra&&i[a.optionDisplayExtra]&&""!=i[a.optionDisplayExtra])}}function Yt(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-hint"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵtextInterpolate(i.hint)}}var Xt=function(e){return{width:e}};function en(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-form-field",1),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"mat-select",2),t.ɵɵlistener("valueChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().value=e}))("selectionChange",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changed()})),t.ɵɵtemplate(4,Kt,3,3,"mat-option",3),t.ɵɵelementEnd(),t.ɵɵtemplate(5,Yt,2,1,"mat-hint",4),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵproperty("ngStyle",t.ɵɵpureFunction1(7,Xt,a.width)),t.ɵɵadvance(2),t.ɵɵtextInterpolate(a.display),t.ɵɵadvance(1),t.ɵɵproperty("value",a.value)("disabled",a.readonly)("placeholder",a.placeholder),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",a.options),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""!=a.hint)}}var tn=function(){function e(){this.width="100%",this.readonly=!1,this.readonlyMode="",this.hint="",this.placeholder="",this.display="",this.value="",this.optionValue="",this.optionDisplay="",this.optionDisplayExtra="",this.valueChange=new t.EventEmitter}return e.prototype.ngOnInit=function(){""==this.placeholder&&(this.placeholder="Select "+this.display)},e.prototype.ngOnChanges=function(){var e=this;""!=this.readonlyMode&&this.options.length>0&&(this.displayValue=this.options.filter((function(t){return t[""+e.optionValue]==e.value}))[0][""+this.optionDisplay])},e.prototype.changed=function(){this.valueChange.emit(this.value)},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-select"]],inputs:{width:"width",readonly:"readonly",readonlyMode:"readonlyMode",hint:"hint",placeholder:"placeholder",display:"display",value:"value",options:"options",optionValue:"optionValue",optionDisplay:"optionDisplay",optionDisplayExtra:"optionDisplayExtra"},outputs:{valueChange:"valueChange"},features:[t.ɵɵNgOnChangesFeature],decls:1,vars:1,consts:[["style","padding-right: 20px;","floatLabel","always",3,"ngStyle",4,"ngIf"],["floatLabel","always",2,"padding-right","20px",3,"ngStyle"],[3,"value","disabled","placeholder","valueChange","selectionChange"],[3,"value",4,"ngFor","ngForOf"],[4,"ngIf"],[3,"value"]],template:function(e,n){1&e&&t.ɵɵtemplate(0,en,6,9,"mat-form-field",0),2&e&&t.ɵɵproperty("ngIf",""==n.readonlyMode)},directives:[i.NgIf,a.MatFormField,i.NgStyle,a.MatLabel,k.MatSelect,i.NgForOf,y.MatOption,a.MatHint],styles:[""]}),e}(),nn=function(){function e(){this.readonly=!1,this.display="",this.value=!1,this.valueChange=new t.EventEmitter,this.click=new t.EventEmitter,this.check=new t.EventEmitter,this.uncheck=new t.EventEmitter}return e.prototype.ngOnInit=function(){},e.prototype.changed=function(){this.valueChange.emit(this.value)},e.prototype.clicked=function(){this.click.emit(),this.value?this.unchecked():this.checked()},e.prototype.checked=function(){this.check.emit()},e.prototype.unchecked=function(){this.uncheck.emit()},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-check"]],inputs:{readonly:"readonly",display:"display",value:"value"},outputs:{valueChange:"valueChange",click:"click",check:"check",uncheck:"uncheck"},decls:2,vars:3,consts:[["color","primary",2,"margin-right","50px","font-size","14px",3,"ngModel","disabled","ngModelChange","change","click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-checkbox",0),t.ɵɵlistener("ngModelChange",(function(e){return n.value=e}))("change",(function(){return n.changed()}))("click",(function(){return n.clicked()})),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e&&(t.ɵɵproperty("ngModel",n.value)("disabled",n.readonly),t.ɵɵadvance(1),t.ɵɵtextInterpolate(n.display))},directives:[h.MatCheckbox,L.NgControlStatus,L.NgModel],styles:[""]}),e}(),an=function(){function e(){this.fileDropped=new t.EventEmitter}return e.prototype.onDragOver=function(e){e.preventDefault(),e.stopPropagation(),this.fileOver=!0},e.prototype.onDragLeave=function(e){e.preventDefault(),e.stopPropagation(),this.fileOver=!1},e.prototype.ondrop=function(e){e.preventDefault(),e.stopPropagation(),this.fileOver=!1;var t=e.dataTransfer.files;t.length>0&&this.fileDropped.emit(t)},e.ɵfac=function(t){return new(t||e)},e.ɵdir=t.ɵɵdefineDirective({type:e,selectors:[["","appDnd",""]],hostVars:2,hostBindings:function(e,n){1&e&&t.ɵɵlistener("dragover",(function(e){return n.onDragOver(e)}))("dragleave",(function(e){return n.onDragLeave(e)}))("drop",(function(e){return n.ondrop(e)})),2&e&&t.ɵɵclassProp("fileover",n.fileOver)},outputs:{fileDropped:"fileDropped"}}),e}();function rn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",9),t.ɵɵelementStart(1,"div",10),t.ɵɵelementStart(2,"h4",11),t.ɵɵtext(3),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"p",12),t.ɵɵtext(5),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(6,"div",13),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=n.index;return t.ɵɵnextContext().deleteFile(e)})),t.ɵɵnamespaceSVG(),t.ɵɵelementStart(7,"svg",14),t.ɵɵelement(8,"path",15),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext();t.ɵɵadvance(3),t.ɵɵtextInterpolate1(" ",null==a?null:a.name," "),t.ɵɵadvance(2),t.ɵɵtextInterpolate1(" ",r.formatBytes(null==a?null:a.size,2)," ")}}function on(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",16),t.ɵɵelementStart(1,"button",17),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().uploaded()})),t.ɵɵelementStart(2,"mat-icon"),t.ɵɵtext(3,"file_upload"),t.ɵɵelementEnd(),t.ɵɵtext(4," Upload"),t.ɵɵelementEnd(),t.ɵɵelementEnd()}}var ln=function(){function e(){this.message="Drag and drop files here",this.files=[],this.filesChange=new t.EventEmitter,this.upload=new t.EventEmitter,this.enableUpload=!1}return e.prototype.ngOnInit=function(){},e.prototype.onFileDropped=function(e){this.prepareFilesList(e)},e.prototype.fileBrowseHandler=function(e){this.prepareFilesList(e)},e.prototype.deleteFile=function(e){this.files.splice(e,1)},e.prototype.prepareFilesList=function(e){var t,n;try{for(var i=$(e),a=i.next();!a.done;a=i.next()){var r=a.value;r.progress=0,this.files.push(r)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}},e.prototype.formatBytes=function(e,t){if(0===e)return"0 Bytes";var n=t<=0?0:t||2,i=Math.floor(Math.log(e)/Math.log(1024));return parseFloat((e/Math.pow(1024,i)).toFixed(n))+" "+["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][i]},e.prototype.uploaded=function(){this.upload.emit()},e.prototype.filesChanged=function(){this.filesChange.emit(this.files)},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-attach"]],inputs:{message:"message",files:"files",enableUpload:"enableUpload"},outputs:{filesChange:"filesChange",upload:"upload"},decls:15,vars:3,consts:[[1,"tin-input-row",2,"width","100%"],[1,"col"],["appDnd","",1,"container",3,"fileDropped"],["type","file","id","fileDropRef","multiple","",3,"change"],["fileDropRef",""],["for","fileDropRef"],[1,"files-list"],["class","single-file ","style","width: 100%;",4,"ngFor","ngForOf"],["class","tin-input-row d-flex justify-content-center","style","width: 100%;",4,"ngIf"],[1,"single-file",2,"width","100%"],[1,"tin-input-row","info"],[1,"name"],[1,"size"],[1,"delete",3,"click"],["xmlns","http://www.w3.org/2000/svg","width","14","height","18","viewBox","0 0 14 18"],["fill","#B1B1B1","fill-rule","nonzero","d","M1 16c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2H3c-1.1 0-2 .9-2 2v10zm3.17-7.83a.996.996 0 0 1 1.41 0L7 9.59l1.42-1.42a.996.996 0 1 1 1.41 1.41L8.41 11l1.42 1.42a.996.996 0 1 1-1.41 1.41L7 12.41l-1.42 1.42a.996.996 0 1 1-1.41-1.41L5.59 11 4.17 9.58a.996.996 0 0 1 0-1.41zM10.5 1L9.79.29C9.61.11 9.35 0 9.09 0H4.91c-.26 0-.52.11-.7.29L3.5 1H1c-.55 0-1 .45-1 1s.45 1 1 1h12c.55 0 1-.45 1-1s-.45-1-1-1h-2.5z"],[1,"tin-input-row","d-flex","justify-content-center",2,"width","100%"],["mat-button","","color","primary","matTooltip","Upload New Documents","matTooltipPosition","above",3,"click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div",0),t.ɵɵelementStart(1,"div",1),t.ɵɵelementStart(2,"div",2),t.ɵɵlistener("fileDropped",(function(e){return n.onFileDropped(e)})),t.ɵɵelementStart(3,"input",3,4),t.ɵɵlistener("change",(function(e){return n.fileBrowseHandler(e.target.files)})),t.ɵɵelementEnd(),t.ɵɵelementStart(5,"h4"),t.ɵɵtext(6),t.ɵɵelementEnd(),t.ɵɵelementStart(7,"h4"),t.ɵɵtext(8,"or"),t.ɵɵelementEnd(),t.ɵɵelementStart(9,"label",5),t.ɵɵtext(10,"Click to Browse"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(11,"div",1),t.ɵɵelementStart(12,"div",6),t.ɵɵtemplate(13,rn,9,2,"div",7),t.ɵɵelementEnd(),t.ɵɵtemplate(14,on,5,0,"div",8),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(6),t.ɵɵtextInterpolate(n.message),t.ɵɵadvance(7),t.ɵɵproperty("ngForOf",n.files),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.files.length>0&&n.enableUpload))},directives:[an,i.NgForOf,i.NgIf,r.MatButton,F.MatTooltip,S.MatIcon],styles:[".container[_ngcontent-%COMP%]{width:100%;height:200px;padding:2rem;text-align:center;border:2px dashed #2a7b94;position:relative;margin:0 auto}.container[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{opacity:0;position:absolute;z-index:2;width:100%;height:100%;top:0;left:0}.container[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{color:#fff;width:183px;height:44px;border-radius:21.5px;background-color:#db202f;padding:8px 16px}.container[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font-size:20px;font-weight:600;color:#38424c}.fileover[_ngcontent-%COMP%]{-webkit-animation:1s infinite shake;animation:1s infinite shake}.files-list[_ngcontent-%COMP%]{margin-top:1.5rem}.files-list[_ngcontent-%COMP%] .single-file[_ngcontent-%COMP%]{display:flex;padding:.5rem;justify-content:space-between;align-items:center;border:1px dashed #1c824d;margin-bottom:1rem;margin-right:1rem;display:flex;flex-grow:1}.files-list[_ngcontent-%COMP%] .single-file[_ngcontent-%COMP%] .delete[_ngcontent-%COMP%]{display:flex;margin-left:.5rem;cursor:pointer;align-self:flex-end}.files-list[_ngcontent-%COMP%] .single-file[_ngcontent-%COMP%] .name[_ngcontent-%COMP%]{font-size:14px;font-weight:500;color:#353f4a;margin:0}.files-list[_ngcontent-%COMP%] .single-file[_ngcontent-%COMP%] .size[_ngcontent-%COMP%]{font-size:12px;font-weight:500;color:#a4a4a4;margin:0 0 0 1rem}.files-list[_ngcontent-%COMP%] .single-file[_ngcontent-%COMP%] .info[_ngcontent-%COMP%]{width:100%}@-webkit-keyframes shake{0%{transform:translate(1px,1px) rotate(0)}10%{transform:translate(-1px,-2px) rotate(-1deg)}20%{transform:translate(-3px,0) rotate(1deg)}30%{transform:translate(3px,2px) rotate(0)}40%{transform:translate(1px,-1px) rotate(1deg)}50%{transform:translate(-1px,2px) rotate(-1deg)}60%{transform:translate(-3px,1px) rotate(0)}70%{transform:translate(3px,1px) rotate(-1deg)}80%{transform:translate(-1px,-1px) rotate(1deg)}90%{transform:translate(1px,2px) rotate(0)}100%{transform:translate(1px,-2px) rotate(-1deg)}}@keyframes shake{0%{transform:translate(1px,1px) rotate(0)}10%{transform:translate(-1px,-2px) rotate(-1deg)}20%{transform:translate(-3px,0) rotate(1deg)}30%{transform:translate(3px,2px) rotate(0)}40%{transform:translate(1px,-1px) rotate(1deg)}50%{transform:translate(-1px,2px) rotate(-1deg)}60%{transform:translate(-3px,1px) rotate(0)}70%{transform:translate(3px,1px) rotate(-1deg)}80%{transform:translate(-1px,-1px) rotate(1deg)}90%{transform:translate(1px,2px) rotate(0)}100%{transform:translate(1px,-2px) rotate(-1deg)}}"]}),e}(),sn=function(){function e(){this.display="",this.value="",this.valueChange=new t.EventEmitter,this.readonly=!1,this.min="01 jan 1900",this.max="31 dec 9999"}return e.prototype.ngOnInit=function(){},e.prototype.changed=function(){this.valueChange.emit(this.value)},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-datetime"]],inputs:{display:"display",value:"value",readonly:"readonly",min:"min",max:"max"},outputs:{valueChange:"valueChange"},decls:4,vars:6,consts:[[2,"width","150px","margin-right","20px"],["matInput","","autocomplete","off","type","datetime-local",3,"ngModel","min","max","placeholder","readonly","ngModelChange","change"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-form-field",0),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"input",1),t.ɵɵlistener("ngModelChange",(function(e){return n.value=e}))("change",(function(){return n.changed()})),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(2),t.ɵɵtextInterpolate(n.display),t.ɵɵadvance(1),t.ɵɵproperty("ngModel",n.value)("min",n.min)("max",n.max)("placeholder",n.display)("readonly",n.readonly))},directives:[a.MatFormField,a.MatLabel,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.NgModel],styles:[""]}),e}(),cn={provide:L.NG_VALUE_ACCESSOR,useExisting:t.forwardRef((function(){return pn})),multi:!0},pn=function(){function e(e,t){this.elementRef=e,this.decimalPipe=t,this.DECIMAL_MARK="."}return e.prototype.ngOnInit=function(){this.el=this.elementRef.nativeElement},e.prototype.handleFocus=function(e){var t=this.getInputValue(),n=this.getUnmaskedValue(t);this.updateInputValue(n)},e.prototype.handleCut=function(e){var t=this;setTimeout((function(){t.inputUpdated()}),0)},e.prototype.handleKeypress=function(e){var t=String.fromCharCode(e.which);if(/^[\d.]+$/.test(t)){var n=e.target.value.indexOf(this.DECIMAL_MARK);if(n>=0&&t===this.DECIMAL_MARK)if(!this.isIdxBetweenSelection(n)){var i=n+1;return this.setCursorPosition(i),void e.preventDefault()}}else e.preventDefault()},e.prototype.handleInput=function(e){this.inputUpdated()},e.prototype.handlePaste=function(e){var t=this;setTimeout((function(){t.inputUpdated()}),1)},e.prototype.handleBlur=function(e){var t=this.getInputValue(),n=this.convertStrToDecimal(t);this.maskInput(n),this.onModelTouched.apply(e)},e.prototype.registerOnChange=function(e){this.onModelChange=e},e.prototype.registerOnTouched=function(e){this.onModelTouched=e},e.prototype.setDisabledState=function(e){this.el.disabled=e},e.prototype.writeValue=function(e){this.maskInput(e)},e.prototype.maskInput=function(e){if(this.isNumeric(e)){var t=this.convertDecimalToStr(e),n=this.transformWithPipe(t);this.updateInputValue(n)}else this.updateInputValue("")},e.prototype.inputUpdated=function(){this.restrictDecimalValue();var e=this.getInputValue(),t=this.getUnmaskedValue(e),n=this.convertStrToDecimal(t);n!==this.lastNumVal&&(this.lastNumVal=n,this.onModelChange(n))},e.prototype.restrictDecimalValue=function(){var e=this.getInputValue(),t=e.indexOf(this.DECIMAL_MARK);if(t>=0&&e.substring(t+1).length>2){var n=e.substring(0,t+3);return void this.updateInputValue(n,!0)}},e.prototype.transformWithPipe=function(e){return this.decimalPipe.transform(e,"1.2-2")},e.prototype.getUnmaskedValue=function(e){return e.replace(/[^-\d\\.]/g,"")},e.prototype.updateInputValue=function(e,t){void 0===t&&(t=!1),t&&this.saveCursorPosition(),this.el.value=e},e.prototype.getInputValue=function(){return this.el.value},e.prototype.convertStrToDecimal=function(e){return this.isNumeric(e)?parseFloat(e):null},e.prototype.convertDecimalToStr=function(e){return this.isNumeric(e)?e+"":""},e.prototype.isNumeric=function(e){return!isNaN(parseFloat(e))&&isFinite(e)},e.prototype.saveCursorPosition=function(){var e=this,t=this.el.selectionStart;setTimeout((function(){e.setCursorPosition(t)}),1)},e.prototype.setCursorPosition=function(e){this.el.selectionStart=e,this.el.selectionEnd=e},e.prototype.isIdxBetweenSelection=function(e){return this.el.selectionStart!==this.el.selectionEnd&&(e>=this.el.selectionStart&&e<this.el.selectionEnd)},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(t.ElementRef),t.ɵɵdirectiveInject(i.DecimalPipe))},e.ɵdir=t.ɵɵdefineDirective({type:e,selectors:[["","appCurrencyInputMask",""]],hostBindings:function(e,n){1&e&&t.ɵɵlistener("focus",(function(e){return n.handleFocus(e)}))("cut",(function(e){return n.handleCut(e)}))("keypress",(function(e){return n.handleKeypress(e)}))("input",(function(e){return n.handleInput(e)}))("paste",(function(e){return n.handlePaste(e)}))("blur",(function(e){return n.handleBlur(e)}))},features:[t.ɵɵProvidersFeature([cn,i.DecimalPipe])]}),e}();function dn(e,n){if(1&e&&(t.ɵɵelementStart(0,"span",4),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵtextInterpolate1("",i.currency," ")}}function mn(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-error"),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵtextInterpolate(i.validate(i.control))}}var un=function(e){return{width:e}},fn=function(){function e(){this.readonly=!1,this.hint="",this.display="",this.placeholder="",this.value="",this.width="100%",this.currency="",this.valueChange=new t.EventEmitter,this.leave=new t.EventEmitter,this.enterPress=new t.EventEmitter,this.required=!0,this.min=0,this.max=9e15,this.control=new L.FormControl(this.value,[L.Validators.required,L.Validators.min(this.min),L.Validators.max(this.max)])}return e.prototype.ngOnInit=function(){""==this.placeholder&&(this.placeholder="Enter "+this.display)},e.prototype.ngOnChanges=function(){},e.prototype.ngAfterViewInit=function(){this.initControl(this.control)},e.prototype.initControl=function(e){this.readonly&&(e.setValidators(null),e.updateValueAndValidity()),this.required||this.readonly||(e.setValidators([L.Validators.min(this.min),L.Validators.max(this.max)]),this.control.updateValueAndValidity())},e.prototype.changed=function(e){this.valueChange.emit(e)},e.prototype.leaved=function(){this.leave.emit()},e.prototype.enterPressed=function(){this.enterPress.emit()},e.prototype.validate=function(e){return this.required&&e.hasError("required")?"Required":parseFloat(this.value)<this.min?"Minimun value is "+this.min:parseFloat(this.value)>this.max?"Maximum value is "+this.max:e.hasError("min")?"Minimun value is "+this.min:e.hasError("max")?"Maximum value is "+this.max:""},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-money"]],inputs:{readonly:"readonly",hint:"hint",display:"display",placeholder:"placeholder",value:"value",width:"width",currency:"currency",required:"required",min:"min",max:"max"},outputs:{valueChange:"valueChange",leave:"leave",enterPress:"enterPress"},features:[t.ɵɵNgOnChangesFeature],decls:6,vars:13,consts:[["hideRequiredMarker","true","hideRequiredMarker","true",2,"margin-right","5px",3,"hintLabel","ngStyle"],["matInput","","appCurrencyInputMask","","autocomplete","off",2,"text-align","right",3,"min","max","ngModel","placeholder","formControl","readonly","ngModelChange","keyup.enter","blur"],["matPrefix","",4,"ngIf"],[4,"ngIf"],["matPrefix",""]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-form-field",0),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"input",1),t.ɵɵlistener("ngModelChange",(function(e){return n.changed(e)}))("keyup.enter",(function(){return n.enterPressed()}))("blur",(function(){return n.leaved()})),t.ɵɵelementEnd(),t.ɵɵtemplate(4,dn,2,1,"span",2),t.ɵɵtemplate(5,mn,2,1,"mat-error",3),t.ɵɵelementEnd()),2&e&&(t.ɵɵproperty("hintLabel",n.hint)("ngStyle",t.ɵɵpureFunction1(11,un,n.width)),t.ɵɵadvance(2),t.ɵɵtextInterpolate(n.display),t.ɵɵadvance(1),t.ɵɵproperty("min",n.min)("max",n.max)("ngModel",n.value)("placeholder",n.placeholder)("formControl",n.control)("readonly",n.readonly),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""!=n.currency),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.control.invalid))},directives:[a.MatFormField,i.NgStyle,a.MatLabel,C.MatInput,L.DefaultValueAccessor,pn,L.NgControlStatus,L.FormControlDirective,i.NgIf,a.MatPrefix,a.MatError],styles:["input.example-right-align[_ngcontent-%COMP%]{-moz-appearance:textfield}.example-right-align[_ngcontent-%COMP%]{text-align:right}input.example-right-align[_ngcontent-%COMP%]::-webkit-inner-spin-button, input.example-right-align[_ngcontent-%COMP%]::-webkit-outer-spin-button{display:none}.curr[_ngcontent-%COMP%]{background-color:red}"]}),e}();function gn(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",3),t.ɵɵelementStart(1,"mat-label",4),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate1(" ",i.title,"")}}function hn(e,n){if(1&e&&(t.ɵɵelementStart(0,"li",7),t.ɵɵelementStart(1,"div",8),t.ɵɵelementStart(2,"div",9),t.ɵɵtext(3),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"small"),t.ɵɵtext(5),t.ɵɵelementStart(6,"em"),t.ɵɵtext(7),t.ɵɵpipe(8,"date"),t.ɵɵelementEnd(),t.ɵɵtext(9,") "),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(3),t.ɵɵtextInterpolate(i.createdByName),t.ɵɵadvance(2),t.ɵɵtextInterpolate1("",i.details," ("),t.ɵɵadvance(2),t.ɵɵtextInterpolate(t.ɵɵpipeBind2(8,3,i.createdDate,"dd MMM yyyy HH:mm"))}}function vn(e,n){if(1&e&&(t.ɵɵelementStart(0,"ul",5),t.ɵɵtemplate(1,hn,10,6,"li",6),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",i.notes)}}function yn(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",10),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" No ",i.title.toLowerCase()," ")}}var xn=function(){function e(){this.notes=new Array,this.notesMessage="Empty",this.title="Notes"}return e.prototype.ngOnInit=function(){},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-activity"]],inputs:{notes:"notes",title:"title"},decls:3,vars:3,consts:[["class","tin-input-row mt-3",4,"ngIf"],["class","list-group list-group-flush","style","max-height:350px; margin-left:5px",4,"ngIf"],["class","d-flex justify-content-center row align-items-center","style","max-height:200px",4,"ngIf"],[1,"tin-input-row","mt-3"],[2,"font-size","20px","font-weight","300"],[1,"list-group","list-group-flush",2,"max-height","350px","margin-left","5px"],["class","list-group-item list-group-item-action flex-column align-items-start",4,"ngFor","ngForOf"],[1,"list-group-item","list-group-item-action","flex-column","align-items-start"],[1,"d-flex","w-100","justify-content-between"],[1,"mb-0"],[1,"d-flex","justify-content-center","row","align-items-center",2,"max-height","200px"]],template:function(e,n){1&e&&(t.ɵɵtemplate(0,gn,3,1,"div",0),t.ɵɵtemplate(1,vn,2,1,"ul",1),t.ɵɵtemplate(2,yn,2,1,"div",2)),2&e&&(t.ɵɵproperty("ngIf",""!=n.title),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.notes&&n.notes.length>0),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.notes&&0==n.notes.length))},directives:[i.NgIf,a.MatLabel,i.NgForOf],pipes:[i.DatePipe],styles:[""]}),e}(),Sn=function(){function e(){this.value="",this.valueChange=new t.EventEmitter,this.readonly=!1,this.config={editable:!0,spellcheck:!0,height:"auto",minHeight:"5rem",placeholder:"Enter text here...",translate:"no",defaultParagraphSeparator:"",defaultFontName:"Arial",toolbarHiddenButtons:[["bold","italic","underline","strikeThrough","subscript","superscript","justifyLeft","justifyCenter","justifyRight","justifyFull","indent","outdent","insertUnorderedList","insertOrderedList","heading","fontName"],["fontSize","textColor","backgroundColor","customClasses","link","unlink","insertImage","insertVideo","insertHorizontalRule","removeFormat","toggleEditorMode"]],customClasses:[{name:"quote",class:"quote"},{name:"redText",class:"redText"},{name:"titleText",class:"titleText",tag:"h1"}]}}return e.prototype.ngOnInit=function(){},e.prototype.changed=function(){this.valueChange.emit(this.value)},e.prototype.ngOnChanges=function(){this.config.editable=!this.readonly},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-html"]],inputs:{value:"value",readonly:"readonly",config:"config"},outputs:{valueChange:"valueChange"},features:[t.ɵɵNgOnChangesFeature],decls:1,vars:2,consts:[[3,"ngModel","config","ngModelChange"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"angular-editor",0),t.ɵɵlistener("ngModelChange",(function(e){return n.value=e}))("ngModelChange",(function(){return n.changed()})),t.ɵɵelementEnd()),2&e&&t.ɵɵproperty("ngModel",n.value)("config",n.config)},directives:[V.AngularEditorComponent,L.NgControlStatus,L.NgModel],styles:[""]}),e}();function Cn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-form-field",5),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"input",6),t.ɵɵlistener("ngModelChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().value=e}))("change",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changed()}))("keyup.enter",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changed()})),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate(a.display),t.ɵɵadvance(1),t.ɵɵproperty("ngModel",a.value)("placeholder","Enter "+a.display)}}function Mn(e,n){if(1&e&&(t.ɵɵelementStart(0,"mat-option",10),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit,a=t.ɵɵnextContext(2);t.ɵɵproperty("value",i[a.optionValue]),t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i[a.optionDisplay]," ")}}function wn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"mat-form-field",7),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"mat-select",8),t.ɵɵlistener("valueChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().value=e}))("selectionChange",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changed()})),t.ɵɵtemplate(4,Mn,2,2,"mat-option",9),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate(a.display),t.ɵɵadvance(1),t.ɵɵproperty("value",a.value)("placeholder","Select "+a.display)("disabled",a.readonly),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",a.options)}}var bn=function(){function e(){this.optionValue="",this.optionDisplay="",this.readonly=!1,this.value="",this.display="",this.show=!1,this.valueChange=new t.EventEmitter,this.enterPress=new t.EventEmitter}return e.prototype.ngOnInit=function(){this.OGValue=this.value},e.prototype.changed=function(){this.valueChange.emit(this.value)},e.prototype.enterPressed=function(){this.valueChange.emit()},e.prototype.resetValue=function(){this.value=this.OGValue,this.changed()},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-option"]],inputs:{options:"options",optionValue:"optionValue",optionDisplay:"optionDisplay",readonly:"readonly",value:"value",display:"display",show:"show"},outputs:{valueChange:"valueChange",enterPress:"enterPress"},decls:6,vars:4,consts:[["color","primary","labelPosition","after",2,"margin-right","5px",3,"ngModel","ngModelChange","change"],[2,"margin-right","10px","width","0px"],["matInput",""],["style","margin-right:30px",4,"ngIf"],["style","margin-right: 20px;","floatLabel","always","width","100",4,"ngIf"],[2,"margin-right","30px"],["matInput","","width","100","autocomplete","off",3,"ngModel","placeholder","ngModelChange","change","keyup.enter"],["floatLabel","always","width","100",2,"margin-right","20px"],[3,"value","placeholder","disabled","valueChange","selectionChange"],[3,"value",4,"ngFor","ngForOf"],[3,"value"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-checkbox",0),t.ɵɵlistener("ngModelChange",(function(e){return n.show=e}))("change",(function(){return n.resetValue()})),t.ɵɵtext(1),t.ɵɵelementEnd(),t.ɵɵelementStart(2,"mat-form-field",1),t.ɵɵelement(3,"input",2),t.ɵɵelementEnd(),t.ɵɵtemplate(4,Cn,4,3,"mat-form-field",3),t.ɵɵtemplate(5,wn,5,5,"mat-form-field",4)),2&e&&(t.ɵɵproperty("ngModel",n.show),t.ɵɵadvance(1),t.ɵɵtextInterpolate(n.display),t.ɵɵadvance(3),t.ɵɵproperty("ngIf",n.show&&!n.options),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.show&&n.options))},directives:[h.MatCheckbox,L.NgControlStatus,L.NgModel,a.MatFormField,C.MatInput,i.NgIf,a.MatLabel,L.DefaultValueAccessor,k.MatSelect,i.NgForOf,y.MatOption],styles:[""]}),e}();function En(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵelementStart(1,"label",1),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵtext(3,"   "),t.ɵɵelementStart(4,"label"),t.ɵɵtext(5),t.ɵɵelementEnd(),t.ɵɵtext(6,"  \n"),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate1("",i.display,": "),t.ɵɵadvance(3),t.ɵɵtextInterpolate1("",i.value," ")}}function In(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵelementStart(1,"label",1),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵtext(3,"   "),t.ɵɵelementStart(4,"label"),t.ɵɵtext(5),t.ɵɵpipe(6,"date"),t.ɵɵelementEnd(),t.ɵɵtext(7,"  \n"),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate1("",i.display,": "),t.ɵɵadvance(3),t.ɵɵtextInterpolate1("",t.ɵɵpipeBind2(6,2,i.value,"dd/MM/yyyy")," ")}}function kn(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵelementStart(1,"label",1),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵtext(3,"   "),t.ɵɵelementStart(4,"label"),t.ɵɵtext(5),t.ɵɵpipe(6,"date"),t.ɵɵelementEnd(),t.ɵɵtext(7,"  \n"),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate1("",i.display,": "),t.ɵɵadvance(3),t.ɵɵtextInterpolate1("",t.ɵɵpipeBind2(6,2,i.value,"dd/MM/yyyy HH:mm")," ")}}function Pn(e,n){if(1&e&&(t.ɵɵelementStart(0,"div"),t.ɵɵelementStart(1,"label",1),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵtext(3,"   "),t.ɵɵelementStart(4,"label"),t.ɵɵtext(5),t.ɵɵpipe(6,"currency"),t.ɵɵelementEnd(),t.ɵɵtext(7,"  \n"),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵtextInterpolate1("",i.display,": "),t.ɵɵadvance(3),t.ɵɵtextInterpolate1("",t.ɵɵpipeBind3(6,2,i.value,"USD","")," ")}}var Nn=function(){function e(){this.display="",this.value="",this.format="text"}return e.prototype.ngOnInit=function(){},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-label"]],inputs:{display:"display",value:"value",format:"format"},decls:4,vars:4,consts:[[4,"ngIf"],[2,"font-weight","500"]],template:function(e,n){1&e&&(t.ɵɵtemplate(0,En,7,2,"div",0),t.ɵɵtemplate(1,In,8,5,"div",0),t.ɵɵtemplate(2,kn,8,5,"div",0),t.ɵɵtemplate(3,Pn,8,6,"div",0)),2&e&&(t.ɵɵproperty("ngIf","text"==n.format),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","date"==n.format),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","datetime"==n.format),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","money"==n.format))},directives:[i.NgIf],pipes:[i.DatePipe,i.CurrencyPipe],styles:[""]}),e}(),Dn=["stepper"];function On(e,n){if(1&e&&t.ɵɵelement(0,"mat-step",3),2&e){var i=n.$implicit;t.ɵɵproperty("editable",!1)("label",i.name)}}var Tn=function(){function e(){this.value=""}return e.prototype.ngOnInit=function(){},e.prototype.ngAfterViewInit=function(){},e.prototype.ngOnChanges=function(){this.pushSteps()},e.prototype.setStepper=function(){if(""!=this.value)switch(this.stepper.selectedIndex=0,this.value){case"Draft":this.stepper.selectedIndex=0;break;case"Head Approval":this.pushStepper(1);break;case"CE Approval":this.pushStepper(2);break;case"Booking":this.pushStepper(3);break;case"BTA Approval":this.pushStepper(4);break;case"Travel":this.pushStepper(5);break;case"BTR Approval":this.pushStepper(6);break;case"Travel Closure":this.pushStepper(7)}},e.prototype.pushStepper=function(e){for(var t=0;t<e+1;t++)this.stepper.selectedIndex=t},e.prototype.pushSteps=function(){var e,t;if(0!=this.steps.length&&""!=this.value){this.stepper.selectedIndex=0;var n=0;try{for(var i=$(this.steps),a=i.next();!a.done;a=i.next()){if(a.value.name==this.value){this.stepper.selectedIndex=n;break}this.stepper.selectedIndex=n,n++}}catch(t){e={error:t}}finally{try{a&&!a.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}}},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-steps"]],viewQuery:function(e,n){var i;(1&e&&t.ɵɵviewQuery(Dn,!0),2&e)&&(t.ɵɵqueryRefresh(i=t.ɵɵloadQuery())&&(n.stepper=i.first))},inputs:{value:"value",steps:"steps"},features:[t.ɵɵProvidersFeature([{provide:_.STEPPER_GLOBAL_OPTIONS,useValue:{displayDefaultIndicatorType:!1}}]),t.ɵɵNgOnChangesFeature],decls:3,vars:1,consts:[["labelPosition","bottom",1,"transparent"],["stepper",""],[3,"editable","label",4,"ngFor","ngForOf"],[3,"editable","label"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-horizontal-stepper",0,1),t.ɵɵtemplate(2,On,1,2,"mat-step",2),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(2),t.ɵɵproperty("ngForOf",n.steps))},directives:[D.MatHorizontalStepper,i.NgForOf,D.MatStep],styles:[".transparent[_ngcontent-%COMP%]{background-color:rgba(0,0,0,0)}[_nghost-%COMP%] .mat-step-header{padding:5px!important}[_nghost-%COMP%] .mat-stepper-horizontal-line{min-width:5px!important}[_nghost-%COMP%] .mat-horizontal-content-container{padding:0!important}[_nghost-%COMP%] .mat-horizontal-stepper-header{pointer-events:none!important}"]}),e}(),Fn=function(){function e(){this.data=new O.MatTableDataSource,this.refreshClick=new t.EventEmitter,this._filterText=""}return e.prototype.ngOnInit=function(){},e.prototype.ngOnChanges=function(){this.applyFilter(this._filterText)},e.prototype.applyFilter=function(e){this.data&&(this.data.filter=e.trim().toLowerCase())},e.prototype.refreshClicked=function(){this.refreshClick.emit()},e.ɵfac=function(t){return new(t||e)},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-filter"]],inputs:{data:"data"},outputs:{refreshClick:"refreshClick"},features:[t.ɵɵNgOnChangesFeature],decls:7,vars:1,consts:[[2,"font-size","12px"],["id","txtFilter","matInput","","placeholder","Enter Filter text","autocomplete","off",3,"ngModel","ngModelChange","keyup"],["id","btnFilter","mat-mini-fab","","color","primary","matTooltip","Refresh Data","matTooltipPosition","above",2,"margin-right","1em","margin-top","5px",3,"click"],[1,"refreshIcon"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-form-field",0),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2,"Filter"),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"input",1),t.ɵɵlistener("ngModelChange",(function(e){return n._filterText=e}))("keyup",(function(e){return n.applyFilter(e.target.value)})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"button",2),t.ɵɵlistener("click",(function(){return n.refreshClicked()})),t.ɵɵelementStart(5,"mat-icon",3),t.ɵɵtext(6,"refresh"),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(3),t.ɵɵproperty("ngModel",n._filterText))},directives:[a.MatFormField,a.MatLabel,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.NgModel,r.MatButton,F.MatTooltip,S.MatIcon],styles:[".mat-mini-fab[_ngcontent-%COMP%]{width:32px;height:32px}.mat-mini-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:16px;margin-top:-3px}.refreshIcon[_ngcontent-%COMP%]{font-size:22px!important;margin-top:-7px!important}"]}),e}(),Ln=function(){function e(){}return e.ɵmod=t.ɵɵdefineNgModule({type:e}),e.ɵinj=t.ɵɵdefineInjector({factory:function(t){return new(t||e)},imports:[[i.CommonModule,L.FormsModule]]}),e}();("undefined"==typeof ngJitMode||ngJitMode)&&t.ɵɵsetNgModuleScope(Ln,{declarations:[pn],imports:[i.CommonModule,L.FormsModule],exports:[pn]});var jn=function(){function e(){}return e.ɵmod=t.ɵɵdefineNgModule({type:e}),e.ɵinj=t.ɵɵdefineInjector({factory:function(t){return new(t||e)},providers:[i.CurrencyPipe,{provide:m.HTTP_INTERCEPTORS,useClass:_e,multi:!0},{provide:i.LocationStrategy,useClass:i.HashLocationStrategy}],imports:[[L.ReactiveFormsModule.withConfig({warnOnNgModelWithFormControl:"never"}),i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,A.MomentModule,R.NgxDocViewerModule,V.AngularEditorModule,Ln,j.NgIdleKeepaliveModule.forRoot()],i.CommonModule,L.FormsModule,Ve]}),e}();function An(e,n){if(1&e&&t.ɵɵelement(0,"img",21),2&e){var i=t.ɵɵnextContext(2);t.ɵɵproperty("src",i.appConfig.logo,t.ɵɵsanitizeUrl)}}function Rn(e,n){if(1&e&&t.ɵɵelement(0,"img",22),2&e){var i=t.ɵɵnextContext(2);t.ɵɵproperty("src",i.appConfig.logo,t.ɵɵsanitizeUrl)}}function Un(e,n){if(1&e&&t.ɵɵelement(0,"img",23),2&e){var i=t.ɵɵnextContext(2);t.ɵɵproperty("src",i.appConfig.logo,t.ɵɵsanitizeUrl)}}function Vn(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",17),t.ɵɵtemplate(1,An,1,1,"img",18),t.ɵɵtemplate(2,Rn,1,1,"img",19),t.ɵɵtemplate(3,Un,1,1,"img",20),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("ngIf","normal"==i.appConfig.logoSize),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","medium"==i.appConfig.logoSize),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","large"==i.appConfig.logoSize)}}function _n(e,n){1&e&&t.ɵɵelement(0,"div",24)}function zn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",13),t.ɵɵelementStart(1,"button",25),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().signup()})),t.ɵɵtext(2,"Signup"),t.ɵɵelementEnd(),t.ɵɵelementEnd()}}function Bn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div"),t.ɵɵelement(1,"br"),t.ɵɵelementStart(2,"a",26),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().recoverAccount()})),t.ɵɵtext(3,"Forgot your password ?"),t.ɵɵelementEnd(),t.ɵɵelementEnd()}}("undefined"==typeof ngJitMode||ngJitMode)&&t.ɵɵsetNgModuleScope(jn,{declarations:[an,ze,ae,Ye,Ue,Xe,bt,Nt,Dt,Ut,Jt,tn,nn,ln,sn,fn,qt,xn,Gt,Sn,bn,Nn,Tn,Fn],imports:[L.ReactiveFormsModule,i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,A.MomentModule,R.NgxDocViewerModule,V.AngularEditorModule,Ln,j.NgIdleKeepaliveModule],exports:[i.CommonModule,L.FormsModule,Ve,ze,ae,Ye,Ue,Xe,bt,Nt,Dt,Jt,tn,Ut,sn,nn,ln,fn,qt,xn,Sn,bn,Nn,Tn,Fn]});var qn=function(){function e(e,t,n,i,a,r,o,l){this.httpService=e,this.storageService=t,this.router=n,this.messageService=i,this.dataService=a,this.authService=r,this.logService=o,this.route=l,this.user=new Ie,this.hide=!0,this.isProcessing=!1,this.appConfig=new we}return e.prototype.ngOnInit=function(){var e=this;this.authService.Updateloggedin(!1),this.authService.UpdateRole(null),this.storageService.clear(),this.dataService.appConfigObserv.subscribe((function(t){return e.appConfig=t})),null!=this.route.snapshot.queryParams.redirectTo?this.redirectPath=this.route.snapshot.queryParams.redirectTo:this.redirectPath="home"},e.prototype.signup=function(){this.router.navigate(["signup"])},e.prototype.recoverAccount=function(){this.router.navigate(["recover-account"])},e.prototype.login=function(){var e=this;""!=this.user.userName&&""!=this.user.password?(this.logService.info("logging in"),this.isProcessing=!0,this.user.userName=this.user.userName,this.dataService.Login(this.user).subscribe((function(t){if(e.isProcessing=!1,t.success){if("local"==t.data.authType&&!e.appConfig.localAuth)return void e.messageService.toast("Contact Admin: Authentication Type error");if("AD"==t.data.authType&&!e.appConfig.ADAuth)return void e.messageService.toast("Contact Admin: Authentication Type error");if(e.authService.Updateloggedin(!0),e.authService.UpdateToken(t.data.token),e.storageService.store(ce.AUTH_TOKEN,t.data.token),e.authService.UpdateTokenExpire(t.data.expiration),e.storageService.store(ce.AUTH_TOKEN_EXPIRE,t.data.expiration),e.authService.UpdateCurrentUser(e.user.userName),e.storageService.store(ce.AUTH_USER,e.user.userName),e.authService.updateLoggedUserFullName(t.data.firstName),e.storageService.store(ce.AUTH_NAME,t.data.firstName),e.authService.UpdateRole(t.data.role),e.storageService.store(ce.AUTH_ROLES,JSON.stringify(t.data.role)),e.logService.info("logged in"),1==t.data.changePassword&&"local"==t.data.authType)return void e.router.navigate(["home/user/change-password"],{queryParams:{redirectTo:e.redirectPath},queryParamsHandling:"merge",skipLocationChange:!1});e.router.navigate([e.redirectPath])}else e.messageService.toast("Error: "+t.message),e.user.password=""}),(function(t){e.isProcessing=!1,e.messageService.toast(e.httpService.Error(t))}))):this.messageService.toast("Please enter your credentials")},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(W),t.ɵɵdirectiveInject(d.Router),t.ɵɵdirectiveInject(re),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(Te),t.ɵɵdirectiveInject(d.ActivatedRoute))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-login"]],decls:27,vars:12,consts:[[1,"tin-bg-login","login-page"],["class","d-flex justify-content-center row align-items-center","style","margin-top:3em;margin-bottom:1em",4,"ngIf"],["style","margin-top:2em",4,"ngIf"],[1,"d-flex","justify-content-center","row","align-items-center",2,"margin-top","3em"],[1,"d-none","d-sm-block"],[2,"margin-left","1em"],[1,"mat-elevation-z3",2,"width","400px"],[1,"tin-input","mt-2"],["id","txtuserName","display","Username",3,"value","valueChange"],["id","txtPassword","matInput","","autocomplete","off",3,"type","ngModel","keyup.enter","ngModelChange"],["mat-icon-button","","matSuffix","",3,"click"],[2,"font-size","18px"],[1,"row"],[1,"col","d-flex","justify-content-center"],["id","btnLogin","mat-raised-button","","color","primary",2,"width","100px",3,"disabled","click"],["class","col d-flex justify-content-center",4,"ngIf"],[4,"ngIf"],[1,"d-flex","justify-content-center","row","align-items-center",2,"margin-top","3em","margin-bottom","1em"],["style","height:100px;margin-right:3em;margin-left:3em",3,"src",4,"ngIf"],["style","height:150px;margin-right:3em;margin-left:3em",3,"src",4,"ngIf"],["style","height:250px;margin-right:3em;margin-left:3em",3,"src",4,"ngIf"],[2,"height","100px","margin-right","3em","margin-left","3em",3,"src"],[2,"height","150px","margin-right","3em","margin-left","3em",3,"src"],[2,"height","250px","margin-right","3em","margin-left","3em",3,"src"],[2,"margin-top","2em"],["id","btnSignup","mat-stroked-button","","color","primary",2,"width","100px",3,"click"],["mat-button","","id","lnkRecover",2,"margin-left","1em",3,"click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div",0),t.ɵɵtemplate(1,Vn,4,3,"div",1),t.ɵɵtemplate(2,_n,1,0,"div",2),t.ɵɵelementStart(3,"div",3),t.ɵɵelement(4,"div",4),t.ɵɵelementStart(5,"div",5),t.ɵɵelementStart(6,"mat-card",6),t.ɵɵelementStart(7,"mat-card-header"),t.ɵɵelementStart(8,"mat-card-title"),t.ɵɵtext(9),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(10,"mat-card-content"),t.ɵɵelementStart(11,"div",7),t.ɵɵelementStart(12,"spa-text",8),t.ɵɵlistener("valueChange",(function(e){return n.user.userName=e})),t.ɵɵelementEnd(),t.ɵɵelementStart(13,"mat-form-field"),t.ɵɵelementStart(14,"mat-label"),t.ɵɵtext(15,"Password"),t.ɵɵelementEnd(),t.ɵɵelementStart(16,"input",9),t.ɵɵlistener("keyup.enter",(function(){return n.login()}))("ngModelChange",(function(e){return n.user.password=e})),t.ɵɵelementEnd(),t.ɵɵelementStart(17,"button",10),t.ɵɵlistener("click",(function(){return n.hide=!n.hide})),t.ɵɵelementStart(18,"mat-icon",11),t.ɵɵtext(19),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(20,"mat-card-actions"),t.ɵɵelementStart(21,"div",12),t.ɵɵelementStart(22,"div",13),t.ɵɵelementStart(23,"button",14),t.ɵɵlistener("click",(function(){return n.login()})),t.ɵɵtext(24,"Login"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(25,zn,3,0,"div",15),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(26,Bn,4,0,"div",16),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""!=n.appConfig.logo),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",""==n.appConfig.logo),t.ɵɵadvance(7),t.ɵɵtextInterpolate(n.appConfig.appName),t.ɵɵadvance(3),t.ɵɵproperty("value",n.user.userName),t.ɵɵadvance(4),t.ɵɵproperty("type",n.hide?"password":"text")("ngModel",n.user.password),t.ɵɵadvance(1),t.ɵɵattribute("aria-label","Hide password")("aria-pressed",n.hide),t.ɵɵadvance(2),t.ɵɵtextInterpolate(n.hide?"visibility_off":"visibility"),t.ɵɵadvance(4),t.ɵɵproperty("disabled",n.isProcessing),t.ɵɵadvance(2),t.ɵɵproperty("ngIf",n.appConfig.selfService),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.appConfig.selfService))},directives:[i.NgIf,g.MatCard,g.MatCardHeader,g.MatCardTitle,g.MatCardContent,Ut,a.MatFormField,a.MatLabel,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.NgModel,r.MatButton,a.MatSuffix,S.MatIcon,g.MatCardActions,r.MatAnchor],styles:[".login-page[_ngcontent-%COMP%]{position:absolute;top:0;left:0;right:0;bottom:0;overflow:auto}.tin-bg-login[_ngcontent-%COMP%]{background-image:url(~/assets/login-bg.jpg);background-size:100%}"]}),e}(),Hn=function(){function e(e,t,n,i){this.httpService=e,this.messageService=t,this.dataService=n,this.authService=i,this.isProcessing=!1,this.user=new Ie,this.profile=new Ne,this.account=new Ee}return e.prototype.ngOnInit=function(){this.account.user=this.user,this.account.profile=this.profile},e.prototype.create=function(){var e=this;this.profile.userName=this.user.userName,this.isProcessing=!0,this.dataService.RegisterAccount(this.account).subscribe((function(t){e.isProcessing=!1,"success"==t.message?(e.messageService.toast("Account Created"),e.user=new Ie,e.profile=new Ne):e.messageService.toast("Error: "+t.message)}),(function(t){e.isProcessing=!1,e.messageService.toast(e.httpService.Error(t))}))},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(re),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(Fe))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-signup"]],decls:37,vars:5,consts:[[2,"margin-top","1em"],[1,"d-flex","justify-content-center","row","align-items-center"],[1,"tin-input",2,"font-size","14px","width","50%"],[1,"tin-input-row"],[1,"col"],[2,"width","100%"],["matInput","","autocomplete","off","placeholder","Enter FirstName",3,"ngModel","ngModelChange"],["matInput","","autocomplete","off","placeholder","Enter LastName",3,"ngModel","ngModelChange"],[1,"tin-input-row","mt-3"],[1,"col-6"],["matInput","","autocomplete","off","placeholder","Enter userName",3,"ngModel","ngModelChange"],["matInput","","autocomplete","off","type","password","placeholder","Enter Password",3,"ngModel","ngModelChange"],["matInput","","autocomplete","off","type","password","placeholder","Enter Confirm Password",3,"ngModel","ngModelChange"],["mat-raised-button","","color","primary","cdkFocusInitial","",3,"click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4",0),t.ɵɵtext(1,"Signup"),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵtext(3,"\nComplete the form below. "),t.ɵɵelementStart(4,"div",1),t.ɵɵelementStart(5,"div",2),t.ɵɵelementStart(6,"div",3),t.ɵɵelementStart(7,"div",4),t.ɵɵelementStart(8,"mat-form-field",5),t.ɵɵelementStart(9,"mat-label"),t.ɵɵtext(10,"FirstName"),t.ɵɵelementEnd(),t.ɵɵelementStart(11,"input",6),t.ɵɵlistener("ngModelChange",(function(e){return n.account.profile.firstName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(12,"div",4),t.ɵɵelementStart(13,"mat-form-field",5),t.ɵɵelementStart(14,"mat-label"),t.ɵɵtext(15,"LastName"),t.ɵɵelementEnd(),t.ɵɵelementStart(16,"input",7),t.ɵɵlistener("ngModelChange",(function(e){return n.profile.lastName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(17,"div",8),t.ɵɵelementStart(18,"div",9),t.ɵɵelementStart(19,"mat-form-field",5),t.ɵɵelementStart(20,"mat-label"),t.ɵɵtext(21,"userName"),t.ɵɵelementEnd(),t.ɵɵelementStart(22,"input",10),t.ɵɵlistener("ngModelChange",(function(e){return n.user.userName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(23,"div",3),t.ɵɵelementStart(24,"div",4),t.ɵɵelementStart(25,"mat-form-field",5),t.ɵɵelementStart(26,"mat-label"),t.ɵɵtext(27,"Password"),t.ɵɵelementEnd(),t.ɵɵelementStart(28,"input",11),t.ɵɵlistener("ngModelChange",(function(e){return n.user.password=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(29,"div",4),t.ɵɵelementStart(30,"mat-form-field",5),t.ɵɵelementStart(31,"mat-label"),t.ɵɵtext(32,"Confirm Password"),t.ɵɵelementEnd(),t.ɵɵelementStart(33,"input",12),t.ɵɵlistener("ngModelChange",(function(e){return n.confirmPassword=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(34,"div",8),t.ɵɵelementStart(35,"button",13),t.ɵɵlistener("click",(function(){return n.create()})),t.ɵɵtext(36,"Create"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(11),t.ɵɵproperty("ngModel",n.account.profile.firstName),t.ɵɵadvance(5),t.ɵɵproperty("ngModel",n.profile.lastName),t.ɵɵadvance(6),t.ɵɵproperty("ngModel",n.user.userName),t.ɵɵadvance(6),t.ɵɵproperty("ngModel",n.user.password),t.ɵɵadvance(5),t.ɵɵproperty("ngModel",n.confirmPassword))},directives:[a.MatFormField,a.MatLabel,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.NgModel,r.MatButton],styles:[""]}),e}(),$n=function(){function e(e,t,n,i){this.location=e,this.dataService=t,this.authService=n,this.messageService=i,this.userName=""}return e.prototype.ngOnInit=function(){},e.prototype.recover=function(){var e=this;if(""!=this.userName){var t=new Ie;t.userName=this.userName,this.dataService.SelfReset(t).subscribe((function(t){"success"==t.message?(e.messageService.toast("The password has been sent to your email"),e.location.back()):e.messageService.toast("Error: "+t.message)}))}else this.messageService.toast("Please enter your userName")},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(i.Location),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(re))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-recover-account"]],decls:11,vars:1,consts:[[2,"margin-top","1em"],[1,"mt-3"],[1,"tin-input",2,"font-size","14px"],[1,"col"],["display","Username",3,"value","valueChange"],[1,"col","mt-3"],["mat-raised-button","","color","primary","cdkFocusInitial","",3,"click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4",0),t.ɵɵtext(1,"Recover Account"),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵtext(3,"\nSubmit your userName and we will send you details to your registered email address. "),t.ɵɵelementStart(4,"div",1),t.ɵɵelementStart(5,"div",2),t.ɵɵelementStart(6,"div",3),t.ɵɵelementStart(7,"spa-text",4),t.ɵɵlistener("valueChange",(function(e){return n.userName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"div",5),t.ɵɵelementStart(9,"button",6),t.ɵɵlistener("click",(function(){return n.recover()})),t.ɵɵtext(10,"Submit"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(7),t.ɵɵproperty("value",n.userName))},directives:[Ut,r.MatButton],styles:[""]}),e}(),Gn=function(){function e(){}return e.ɵmod=t.ɵɵdefineNgModule({type:e}),e.ɵinj=t.ɵɵdefineInjector({factory:function(t){return new(t||e)},imports:[[L.ReactiveFormsModule.withConfig({warnOnNgModelWithFormControl:"never"}),i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,jn],i.CommonModule,L.FormsModule,Ve]}),e}();function Wn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",2),t.ɵɵelementStart(1,"spa-text",10),t.ɵɵlistener("valueChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changePassword.userName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("value",a.changePassword.userName)}}function Zn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",2),t.ɵɵelementStart(1,"spa-text",11),t.ɵɵlistener("valueChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changePassword.currentPassword=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("value",a.changePassword.currentPassword)}}("undefined"==typeof ngJitMode||ngJitMode)&&t.ɵɵsetNgModuleScope(Gn,{declarations:[qn,Hn,$n],imports:[L.ReactiveFormsModule,i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,jn],exports:[i.CommonModule,L.FormsModule,Ve,qn,Hn,$n]});var Jn=function(){function e(e,t,n,i,a,r,o){this.router=e,this.location=t,this.httpService=n,this.messageService=i,this.dataService=a,this.authService=r,this.route=o,this.isProcessing=!1,this.changePassword=new ke}return e.prototype.ngOnInit=function(){this.myRole=this.authService.currentRoleSource.value,""==this.dataService.tmpProfileuserName?this.changePassword.userName=this.authService.currentUser:(this.changePassword.userName=this.dataService.tmpProfileuserName,this.dataService.tmpProfileuserName=""),null!=this.route.snapshot.queryParams.redirectTo?this.redirectPath=this.route.snapshot.queryParams.redirectTo:this.redirectPath="home"},e.prototype.change=function(){var e=this;this.myRole[this.dataService.capUsers.name]||""!=this.changePassword.currentPassword?""!=this.changePassword.newPassword?""!=this.changePassword.confirmPassword?this.changePassword.confirmPassword==this.changePassword.newPassword?(this.isProcessing=!0,this.myRole[this.dataService.capUsers.name]?this.dataService.ChangePasswordAdmin(this.changePassword).subscribe((function(t){e.isProcessing=!1,"success"==t.message?(e.messageService.toast("Password Changed"),e.router.navigate([e.redirectPath])):e.messageService.toast("Error: "+t.message)})):this.dataService.ChangePassword(this.changePassword).subscribe((function(t){e.isProcessing=!1,"success"==t.message?(e.messageService.toast("Password Changed"),e.router.navigate([e.redirectPath])):e.messageService.toast("Error: "+t.message)}))):this.messageService.toast("Passwords do not match"):this.messageService.toast("Please confirm new Password"):this.messageService.toast("Please enter new Password"):this.messageService.toast("Please enter current Password")},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(d.Router),t.ɵɵdirectiveInject(i.Location),t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(re),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(d.ActivatedRoute))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-change-password"]],decls:32,vars:4,consts:[[1,"container"],[1,"d-flex","justify-content-center","row","align-items-center"],[1,"col"],[1,"tin-input",2,"font-size","14px"],["class","col",4,"ngIf"],["id","txtNewPassword","display","New Password","width","300px","type","password",3,"value","valueChange"],["id","txtConfirmPassword","display","Confirm Password","width","300px","type","password",3,"value","valueChange"],[1,"col","mt-3"],["id","btnChange","mat-raised-button","","color","primary","cdkFocusInitial","",3,"click"],["role","alert",1,"alert","alert-info",2,"font-size","14px"],["id","txtuserName","display","Username","width","300px","readonly","true",3,"value","valueChange"],["id","txtPassword","display","Current Password","width","300px","type","password",3,"value","valueChange"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4"),t.ɵɵtext(1,"Change Password"),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵelementStart(3,"div",0),t.ɵɵelementStart(4,"div",1),t.ɵɵelementStart(5,"div",2),t.ɵɵelementStart(6,"div",3),t.ɵɵtemplate(7,Wn,2,1,"div",4),t.ɵɵtemplate(8,Zn,2,1,"div",4),t.ɵɵelementStart(9,"div",2),t.ɵɵelementStart(10,"spa-text",5),t.ɵɵlistener("valueChange",(function(e){return n.changePassword.newPassword=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(11,"div",2),t.ɵɵelementStart(12,"spa-text",6),t.ɵɵlistener("valueChange",(function(e){return n.changePassword.confirmPassword=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(13,"div",7),t.ɵɵelementStart(14,"button",8),t.ɵɵlistener("click",(function(){return n.change()})),t.ɵɵtext(15,"Change"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(16,"div",2),t.ɵɵelementStart(17,"div",9),t.ɵɵelementStart(18,"b"),t.ɵɵtext(19,"*Please consider these requirements for your new password."),t.ɵɵelementEnd(),t.ɵɵelement(20,"br"),t.ɵɵelement(21,"br"),t.ɵɵtext(22," At least 8 characters"),t.ɵɵelement(23,"br"),t.ɵɵtext(24," At least 1 uppercase letter (A-Z)"),t.ɵɵelement(25,"br"),t.ɵɵtext(26," At least 2 lowercase letters (a-z)"),t.ɵɵelement(27,"br"),t.ɵɵtext(28," At least 1 digit (0-9)"),t.ɵɵelement(29,"br"),t.ɵɵtext(30," At least 1 special character (~`! …)"),t.ɵɵelement(31,"br"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(7),t.ɵɵproperty("ngIf",""!=n.changePassword.userName),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",!n.myRole[n.dataService.capUsers.name]),t.ɵɵadvance(2),t.ɵɵproperty("value",n.changePassword.newPassword),t.ɵɵadvance(2),t.ɵɵproperty("value",n.changePassword.confirmPassword))},directives:[i.NgIf,Ut,r.MatButton],styles:[""]}),e}();function Qn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",20),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().updateProfile()})),t.ɵɵtext(1,"Update Profile"),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵproperty("disabled",a.isProcessing)}}function Kn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"a",21),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().gotoUsers()})),t.ɵɵtext(1,"User Manager"),t.ɵɵelementEnd()}}function Yn(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"a",22),t.ɵɵlistener("click",(function(){return t.ɵɵrestoreView(i),t.ɵɵnextContext().changePassword()})),t.ɵɵtext(1,"Change Password"),t.ɵɵelementEnd()}}var Xn=function(){function e(e,t,n,i,a){this.dataService=e,this.messageService=t,this.httpService=n,this.router=i,this.authService=a,this.appConfig=new we,this.selfProfile=!1,this.profile=new Ne}return e.prototype.ngOnInit=function(){this.myRole=this.authService.currentRoleSource.value,""==this.dataService.tmpProfileuserName?this.loadProfile(this.authService.currentUser):(this.loadProfile(this.dataService.tmpProfileuserName),this.dataService.tmpProfileuserName="")},e.prototype.loadProfile=function(e){var t=this;this.dataService.GetUserByID(e).subscribe((function(e){t.profile=e[0],t.profile.userName.toLocaleLowerCase()==t.authService.currentUser.toLocaleLowerCase()&&(t.selfProfile=!0),t.loadRoles(),console.log(t.profile)}),(function(e){t.isProcessing=!1,t.messageService.toast(t.httpService.Error(e))}))},e.prototype.loadRoles=function(){var e=this;this.dataService.GetRole("all","").subscribe((function(t){e.roles=t,console.log(e.roles)}),(function(t){e.isProcessing=!1,e.messageService.toast(e.httpService.Error(t))}))},e.prototype.changePassword=function(){this.dataService.tmpProfileuserName=this.profile.userName,this.router.navigate(["home/user/change-password"])},e.prototype.gotoUsers=function(){this.router.navigate(["home/admin/users"])},e.prototype.update=function(){},e.prototype.updateProfile=function(){var e=this;this.isProcessing=!0,this.dataService.UpdateUser(this.profile).subscribe((function(t){e.isProcessing=!1,t.success?e.messageService.toast("Profile Updated"):e.messageService.toast("Error: "+t.message)}),(function(t){e.messageService.toast("Connection failed "),e.isProcessing=!1}))},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(re),t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(d.Router),t.ɵɵdirectiveInject(Fe))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-profile"]],inputs:{appConfig:"appConfig"},decls:28,vars:15,consts:[[1,"container"],[1,"row","mt-3",2,"font-size","14px"],[1,"col-2","mt-3"],[1,"tin-input"],[1,"col"],[2,"font-size","70px"],["id","lbluserName",2,"font-size","14px"],[1,"col-8","mt-3"],[1,"tin-input",2,"width","70%"],[1,"tin-input-row"],["id","txtFirstName","display","First Name",3,"value","readonly","valueChange"],["id","txtLastName","display","Last Name",3,"value","readonly","valueChange"],["id","txtAuth","display","Authentication",3,"value","readonly","valueChange"],["id","txtEmail","display","Email",3,"value","readonly","valueChange"],["id","cboRole","display","Role","optionDisplay","roleName","optionValue","roleID",3,"options","value","readonly","valueChange"],[1,"tin-input-row","mt-2"],["id","btnUpdate","mat-raised-button","","color","primary",3,"disabled","click",4,"ngIf"],[1,"col-2","mt-4"],["mat-button","","id","lnkUserManager","style","margin-left: 1em",3,"click",4,"ngIf"],["mat-button","","id","lnkChangePassword","style","margin-left: 1em",3,"click",4,"ngIf"],["id","btnUpdate","mat-raised-button","","color","primary",3,"disabled","click"],["mat-button","","id","lnkUserManager",2,"margin-left","1em",3,"click"],["mat-button","","id","lnkChangePassword",2,"margin-left","1em",3,"click"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"div",0),t.ɵɵelementStart(1,"div",1),t.ɵɵelementStart(2,"div",2),t.ɵɵelementStart(3,"div",3),t.ɵɵelementStart(4,"div",4),t.ɵɵelementStart(5,"mat-icon",5),t.ɵɵtext(6,"account_circle"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(7,"div",4),t.ɵɵelementStart(8,"mat-label",6),t.ɵɵtext(9),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(10,"div",7),t.ɵɵelementStart(11,"div",8),t.ɵɵelementStart(12,"div",9),t.ɵɵelementStart(13,"div",4),t.ɵɵelementStart(14,"spa-text",10),t.ɵɵlistener("valueChange",(function(e){return n.profile.firstName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(15,"div",4),t.ɵɵelementStart(16,"spa-text",11),t.ɵɵlistener("valueChange",(function(e){return n.profile.lastName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(17,"div",4),t.ɵɵelementStart(18,"spa-text",12),t.ɵɵlistener("valueChange",(function(e){return n.profile.authType=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(19,"div",4),t.ɵɵelementStart(20,"spa-text",13),t.ɵɵlistener("valueChange",(function(e){return n.profile.email=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(21,"div",4),t.ɵɵelementStart(22,"spa-select",14),t.ɵɵlistener("valueChange",(function(e){return n.profile.roleID=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(23,"div",15),t.ɵɵtemplate(24,Qn,2,1,"button",16),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(25,"div",17),t.ɵɵtemplate(26,Kn,2,0,"a",18),t.ɵɵtemplate(27,Yn,2,0,"a",19),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(9),t.ɵɵtextInterpolate(null==n.profile?null:n.profile.userName),t.ɵɵadvance(5),t.ɵɵproperty("value",n.profile.firstName)("readonly",n.selfProfile),t.ɵɵadvance(2),t.ɵɵproperty("value",n.profile.lastName)("readonly",n.selfProfile),t.ɵɵadvance(2),t.ɵɵproperty("value",n.profile.authType)("readonly",!0),t.ɵɵadvance(2),t.ɵɵproperty("value",n.profile.email)("readonly",n.selfProfile),t.ɵɵadvance(2),t.ɵɵproperty("options",n.roles)("value",n.profile.roleID)("readonly",n.selfProfile),t.ɵɵadvance(2),t.ɵɵproperty("ngIf",!n.selfProfile),t.ɵɵadvance(2),t.ɵɵproperty("ngIf",!n.selfProfile),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",(n.selfProfile||n.myRole[n.dataService.capUsers.name])&&"local"==n.profile.authType))},directives:[S.MatIcon,a.MatLabel,Ut,tn,i.NgIf,r.MatButton,r.MatAnchor],styles:[""]}),e}(),ei=function(){function e(){}return e.ɵmod=t.ɵɵdefineNgModule({type:e}),e.ɵinj=t.ɵɵdefineInjector({factory:function(t){return new(t||e)},imports:[[L.ReactiveFormsModule.withConfig({warnOnNgModelWithFormControl:"never"}),i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,jn],i.CommonModule,L.FormsModule,Ve]}),e}();function ti(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",5),t.ɵɵelementStart(1,"mat-form-field",6),t.ɵɵelementStart(2,"mat-label"),t.ɵɵtext(3),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"input",7),t.ɵɵlistener("ngModelChange",(function(e){return t.ɵɵrestoreView(i),n.$implicit.sValue=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(5,"button",8),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=n.$implicit;return t.ɵɵnextContext().updateSetting(e)})),t.ɵɵelementStart(6,"mat-icon"),t.ɵɵtext(7,"done_all"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"mat-label",9),t.ɵɵtext(9),t.ɵɵpipe(10,"date"),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit;t.ɵɵadvance(3),t.ɵɵtextInterpolate(a.sName),t.ɵɵadvance(1),t.ɵɵproperty("ngModel",a.sValue),t.ɵɵadvance(5),t.ɵɵtextInterpolate2("Last Updated by ",a.updatedBy," on ",t.ɵɵpipeBind2(10,4,a.updatedDate,"dd MMM yy HH:mm"),"")}}("undefined"==typeof ngJitMode||ngJitMode)&&t.ɵɵsetNgModuleScope(ei,{declarations:[Jn,Xn],imports:[L.ReactiveFormsModule,i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,jn],exports:[i.CommonModule,L.FormsModule,Ve,Jn,Xn]});var ni=function(){function e(e,t){this.dataService=e,this.messageService=t,this._filterText="",this.isProcessing=!1}return e.prototype.ngOnInit=function(){this.loadSettings()},e.prototype.applyFilter=function(e){this.settings.filter=e.trim().toLowerCase()},e.prototype.loadSettings=function(){var e=this;this.dataService.GetSetting("all","").subscribe((function(t){e.settings=t}))},e.prototype.updateSetting=function(e){var t=this;this.isProcessing=!0,this.dataService.UpdateSetting(e,"edit").subscribe((function(n){t.isProcessing=!1,n.success?(t.messageService.toast("Setting "+e.sName+" Updated"),t.loadSettings()):t.messageService.toast("Error: "+n.message)}))},e.prototype.addSetting=function(){this.messageService.toast("Feature not Available")},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(re))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-settings"]],decls:10,vars:1,consts:[[1,"container"],[1,"row","justify-content-between",2,"padding-bottom","10px","padding-left","10px"],[1,"col-2"],["mat-raised-button","",3,"click"],["class","row mt-1 mb-1","style","margin-left:10px",4,"ngFor","ngForOf"],[1,"row","mt-1","mb-1",2,"margin-left","10px"],[2,"width","500px","font-size","14px"],["matInput","","autocomplete","off",3,"ngModel","ngModelChange"],["mat-mini-fab","","color","primary",2,"margin-right","150px",3,"click"],[2,"font-size","small"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4"),t.ɵɵtext(1,"Settings"),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵelementStart(3,"div",0),t.ɵɵelementStart(4,"div",1),t.ɵɵelement(5,"div",2),t.ɵɵelementStart(6,"div",2),t.ɵɵelementStart(7,"button",3),t.ɵɵlistener("click",(function(){return n.loadSettings()})),t.ɵɵtext(8,"Refresh"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(9,ti,11,7,"div",4),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(9),t.ɵɵproperty("ngForOf",n.settings))},directives:[r.MatButton,i.NgForOf,a.MatFormField,a.MatLabel,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.NgModel,S.MatIcon],pipes:[i.DatePipe],styles:[".mat-mini-fab[_ngcontent-%COMP%]{width:32px;height:32px}.mat-mini-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:16px;margin-top:-3px}"]}),e}(),ii=["logsPaginator"];function ai(e,n){1&e&&(t.ɵɵelementStart(0,"p"),t.ɵɵelementStart(1,"em"),t.ɵɵtext(2,"Loading..."),t.ɵɵelementEnd(),t.ɵɵelementEnd())}function ri(e,n){1&e&&(t.ɵɵelementStart(0,"th",21),t.ɵɵtext(1," User "),t.ɵɵelementEnd())}function oi(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",22),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.userName," ")}}function li(e,n){1&e&&(t.ɵɵelementStart(0,"th",23),t.ɵɵtext(1," Date Logged "),t.ɵɵelementEnd())}function si(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",22),t.ɵɵtext(1),t.ɵɵpipe(2,"date"),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",t.ɵɵpipeBind2(2,1,i.dateLogged,"dd MMM yy HH:mm:ss")," ")}}function ci(e,n){1&e&&(t.ɵɵelementStart(0,"th",21),t.ɵɵtext(1," Source "),t.ɵɵelementEnd())}function pi(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",22),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.source," ")}}function di(e,n){1&e&&(t.ɵɵelementStart(0,"th",21),t.ɵɵtext(1," Details "),t.ɵɵelementEnd())}function mi(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",22),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.details," ")}}function ui(e,n){1&e&&(t.ɵɵelementStart(0,"th",21),t.ɵɵtext(1," Name "),t.ɵɵelementEnd())}function fi(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",22),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate2("",i.user.firstName," ",i.user.lastName,"")}}function gi(e,n){1&e&&t.ɵɵelement(0,"tr",24)}function hi(e,n){1&e&&t.ɵɵelement(0,"tr",25)}function vi(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",9),t.ɵɵelementStart(1,"table",10),t.ɵɵelementContainerStart(2,11),t.ɵɵtemplate(3,ri,2,0,"th",12),t.ɵɵtemplate(4,oi,2,1,"td",13),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(5,14),t.ɵɵtemplate(6,li,2,0,"th",15),t.ɵɵtemplate(7,si,3,4,"td",13),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(8,16),t.ɵɵtemplate(9,ci,2,0,"th",12),t.ɵɵtemplate(10,pi,2,1,"td",13),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(11,17),t.ɵɵtemplate(12,di,2,0,"th",12),t.ɵɵtemplate(13,mi,2,1,"td",13),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(14,18),t.ɵɵtemplate(15,ui,2,0,"th",12),t.ɵɵtemplate(16,fi,2,2,"td",13),t.ɵɵelementContainerEnd(),t.ɵɵtemplate(17,gi,1,0,"tr",19),t.ɵɵtemplate(18,hi,1,0,"tr",20),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("dataSource",i.logs),t.ɵɵadvance(16),t.ɵɵproperty("matHeaderRowDef",i.displayedColumns),t.ɵɵadvance(1),t.ɵɵproperty("matRowDefColumns",i.displayedColumns)}}var yi=function(){return[50,100,200]},xi=function(){function e(e,t){this.authService=e,this.dataService=t,this.isProcessing=!1,this.displayedColumns=["dateLogged","userName","fullName","source","details"]}return e.prototype.ngOnInit=function(){this.authService.isAuthorised(this.dataService.capLogs.name),this.loadLogs()},e.prototype.loadLogs=function(){var e=this;this.dataService.GetLog("all","").subscribe((function(t){e.logs=new O.MatTableDataSource(t),e.logs.paginator=e.logsPaginator}))},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(Le))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-logs"]],viewQuery:function(e,n){var i;(1&e&&t.ɵɵviewQuery(ii,!0),2&e)&&(t.ɵɵqueryRefresh(i=t.ɵɵloadQuery())&&(n.logsPaginator=i.first))},decls:12,vars:5,consts:[[1,"container-fluid"],[1,"row","justify-content-between",2,"padding-bottom","10px"],[1,"col-2"],[1,"d-flex","justify-content-end"],[3,"data","refreshClick"],[4,"ngIf"],["class","mat-elevation-z8",4,"ngIf"],["showFirstLastButtons","",3,"pageSizeOptions"],["logsPaginator",""],[1,"mat-elevation-z8"],["id","tblTable","mat-table","",3,"dataSource"],["matColumnDef","userName"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","dateLogged"],["mat-header-cell","","class","datetime",4,"matHeaderCellDef"],["matColumnDef","source"],["matColumnDef","details"],["matColumnDef","fullName"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",4,"matRowDef","matRowDefColumns"],["mat-header-cell",""],["mat-cell",""],["mat-header-cell","",1,"datetime"],["mat-header-row",""],["mat-row",""]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4"),t.ɵɵtext(1,"Logs"),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵelementStart(3,"div",0),t.ɵɵelementStart(4,"div",1),t.ɵɵelement(5,"div",2),t.ɵɵelementStart(6,"div",3),t.ɵɵelementStart(7,"spa-filter",4),t.ɵɵlistener("refreshClick",(function(){return n.loadLogs()})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(8,ai,3,0,"p",5),t.ɵɵtemplate(9,vi,19,3,"div",6),t.ɵɵelement(10,"mat-paginator",7,8),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(7),t.ɵɵproperty("data",n.logs),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",!n.logs),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.logs),t.ɵɵadvance(1),t.ɵɵproperty("pageSizeOptions",t.ɵɵpureFunction0(4,yi)))},directives:[Fn,i.NgIf,b.MatPaginator,O.MatTable,O.MatColumnDef,O.MatHeaderCellDef,O.MatCellDef,O.MatHeaderRowDef,O.MatRowDef,O.MatHeaderCell,O.MatCell,O.MatHeaderRow,O.MatRow],pipes:[i.DatePipe],styles:[".mat-mini-fab[_ngcontent-%COMP%]{width:32px;height:32px}.mat-mini-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:16px;margin-top:-3px}.refreshIcon[_ngcontent-%COMP%]{font-size:22px!important;margin-top:-7px!important}"]}),e}(),Si=["usersPaginator"];function Ci(e,n){1&e&&(t.ɵɵelementStart(0,"p"),t.ɵɵelementStart(1,"em"),t.ɵɵtext(2,"Loading..."),t.ɵɵelementEnd(),t.ɵɵelementEnd())}function Mi(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," userName "),t.ɵɵelementEnd())}function wi(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",26),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.userName," ")}}function bi(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," Locked "),t.ɵɵelementEnd())}function Ei(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",26),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.locked," ")}}function Ii(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," Name "),t.ɵɵelementEnd())}function ki(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",26),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate2(" ",i.firstName," ",i.lastName," ")}}function Pi(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," Role "),t.ɵɵelementEnd())}function Ni(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",26),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.role.roleName," ")}}function Di(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," Disabled "),t.ɵɵelementEnd())}function Oi(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",26),t.ɵɵtext(1),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",i.disabled," ")}}function Ti(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," Created "),t.ɵɵelementEnd())}function Fi(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",26),t.ɵɵtext(1),t.ɵɵpipe(2,"date"),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",t.ɵɵpipeBind2(2,1,i.createdDate,"dd/MM/yyyy")," ")}}function Li(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," Updated "),t.ɵɵelementEnd())}function ji(e,n){if(1&e&&(t.ɵɵelementStart(0,"td",26),t.ɵɵtext(1),t.ɵɵpipe(2,"date"),t.ɵɵelementEnd()),2&e){var i=n.$implicit;t.ɵɵadvance(1),t.ɵɵtextInterpolate1(" ",t.ɵɵpipeBind2(2,1,i.updatedDate,"dd/MM/yyyy")," ")}}function Ai(e,n){1&e&&(t.ɵɵelementStart(0,"th",25),t.ɵɵtext(1," Action "),t.ɵɵelementEnd())}function Ri(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",32),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext(2).lock(e)})),t.ɵɵelementStart(1,"mat-icon"),t.ɵɵtext(2,"lock"),t.ɵɵelementEnd(),t.ɵɵelementEnd()}}function Ui(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"button",33),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=t.ɵɵnextContext().$implicit;return t.ɵɵnextContext(2).unlock(e)})),t.ɵɵelementStart(1,"mat-icon"),t.ɵɵtext(2,"lock_open"),t.ɵɵelementEnd(),t.ɵɵelementEnd()}}function Vi(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"td",27),t.ɵɵelementStart(1,"button",28),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=n.$implicit;return t.ɵɵnextContext(2).viewProfile(e)})),t.ɵɵelementStart(2,"mat-icon"),t.ɵɵtext(3,"account_circle"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(4,Ri,3,0,"button",29),t.ɵɵtemplate(5,Ui,3,0,"button",30),t.ɵɵelementStart(6,"button",31),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=n.$implicit;return t.ɵɵnextContext(2).deleteUser(e)})),t.ɵɵelementStart(7,"mat-icon"),t.ɵɵtext(8,"delete"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit;t.ɵɵadvance(4),t.ɵɵproperty("ngIf","0"==a.locked),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","1"==a.locked)}}function _i(e,n){1&e&&t.ɵɵelement(0,"tr",34)}var zi=function(e){return{"make-gray":e}};function Bi(e,n){if(1&e&&t.ɵɵelement(0,"tr",35),2&e){var i=n.$implicit;t.ɵɵproperty("ngClass",t.ɵɵpureFunction1(1,zi,"1"==i.disabled))}}function qi(e,n){if(1&e&&(t.ɵɵelementStart(0,"div",10),t.ɵɵelementStart(1,"table",11),t.ɵɵelementContainerStart(2,12),t.ɵɵtemplate(3,Mi,2,0,"th",13),t.ɵɵtemplate(4,wi,2,1,"td",14),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(5,15),t.ɵɵtemplate(6,bi,2,0,"th",13),t.ɵɵtemplate(7,Ei,2,1,"td",14),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(8,16),t.ɵɵtemplate(9,Ii,2,0,"th",13),t.ɵɵtemplate(10,ki,2,2,"td",14),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(11,17),t.ɵɵtemplate(12,Pi,2,0,"th",13),t.ɵɵtemplate(13,Ni,2,1,"td",14),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(14,18),t.ɵɵtemplate(15,Di,2,0,"th",13),t.ɵɵtemplate(16,Oi,2,1,"td",14),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(17,19),t.ɵɵtemplate(18,Ti,2,0,"th",13),t.ɵɵtemplate(19,Fi,3,4,"td",14),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(20,20),t.ɵɵtemplate(21,Li,2,0,"th",13),t.ɵɵtemplate(22,ji,3,4,"td",14),t.ɵɵelementContainerEnd(),t.ɵɵelementContainerStart(23,21),t.ɵɵtemplate(24,Ai,2,0,"th",13),t.ɵɵtemplate(25,Vi,9,2,"td",22),t.ɵɵelementContainerEnd(),t.ɵɵtemplate(26,_i,1,0,"tr",23),t.ɵɵtemplate(27,Bi,1,3,"tr",24),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e){var i=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("dataSource",i.users),t.ɵɵadvance(25),t.ɵɵproperty("matHeaderRowDef",i.displayedColumns),t.ɵɵadvance(1),t.ɵɵproperty("matRowDefColumns",i.displayedColumns)}}var Hi=function(){return[10,20,50]},$i=function(){function e(e,t,n,i,a,r){this.httpService=e,this.router=t,this.authService=n,this.dataService=i,this.dialog=a,this.messageService=r,this.isProcessing=!1,this._filterText="",this.displayedColumns=["userName","fullName","roleName","locked","dateCreated","Action"]}return e.prototype.ngOnInit=function(){this.authService.isAuthorised(this.dataService.capUsers.name),this.UpdateData()},e.prototype.UpdateData=function(){var e=this;this.dataService.GetUser().subscribe((function(t){e.users=new O.MatTableDataSource(t),e.users.paginator=e.usersPaginator,e.applyFilter(e._filterText)}),(function(t){e.isProcessing=!1,e.messageService.toast(e.httpService.Error(t))}))},e.prototype.applyFilter=function(e){this.users.filter=e.trim().toLowerCase()},e.prototype.createAccount=function(){this.router.navigate(["home/admin/create-account"])},e.prototype.viewProfile=function(e){this.dataService.tmpProfileuserName=e.userName,this.router.navigate(["home/user/profile"])},e.prototype.lock=function(e){var t=this,n={userName:e.userName,password:"Abcdef@123"};this.dataService.LockUser(n).subscribe((function(e){e.success?(t.messageService.toast("User Locked"),t.UpdateData()):t.messageService.toast("Error: "+e)}))},e.prototype.unlock=function(e){var t=this,n={userName:e.userName,password:"Abcdef@123"};this.dataService.UnlockUser(n).subscribe((function(e){e.success?(t.messageService.toast("User Unlocked"),t.UpdateData()):t.messageService.toast("Error: "+e)}))},e.prototype.recover=function(e){var t=this;this.dataService.SelfReset(e).subscribe((function(e){"success"==e.message?t.messageService.toast("The password has been sent on email"):t.messageService.toast("Error: "+e.message)}))},e.prototype.deleteUser=function(e){var t=this;this.messageService.confirm("Delete "+e.userName+" ?").subscribe((function(n){"yes"==n&&(t.isProcessing=!0,t.dataService.DeleteUser(e).subscribe((function(e){t.isProcessing=!1,"success"==e.message?(t.messageService.toast("User Deleted"),t.UpdateData()):t.messageService.toast("Error: "+e.message)}),(function(e){t.messageService.toast("Connection failed "),t.isProcessing=!1})))}))},e.ɵfac=function(i){return new(i||e)(t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(d.Router),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(n.MatDialog),t.ɵɵdirectiveInject(re))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-users"]],viewQuery:function(e,n){var i;(1&e&&t.ɵɵviewQuery(Si,!0),2&e)&&(t.ɵɵqueryRefresh(i=t.ɵɵloadQuery())&&(n.usersPaginator=i.first))},decls:14,vars:5,consts:[[1,"container"],[1,"row","justify-content-between",2,"padding-bottom","10px"],[1,"col-2"],["id","btnCreateAccount","mat-raised-button","","color","primary",3,"click"],[1,"d-flex","justify-content-end"],[3,"data","refreshClick"],[4,"ngIf"],["class","mat-elevation-z8",4,"ngIf"],["showFirstLastButtons","",3,"pageSizeOptions"],["usersPaginator",""],[1,"mat-elevation-z8"],["id","tblTable","mat-table","",3,"dataSource"],["matColumnDef","userName"],["mat-header-cell","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","locked"],["matColumnDef","fullName"],["matColumnDef","roleName"],["matColumnDef","disabled"],["matColumnDef","dateCreated"],["matColumnDef","dateUpdated"],["matColumnDef","Action"],["mat-cell","","style","width: 250px;",4,"matCellDef"],["mat-header-row","",4,"matHeaderRowDef"],["mat-row","",3,"ngClass",4,"matRowDef","matRowDefColumns"],["mat-header-cell",""],["mat-cell",""],["mat-cell","",2,"width","250px"],["mat-mini-fab","","color","primary","matTooltip","View Profile","matTooltipPosition","above",2,"margin-right","30px",3,"click"],["mat-mini-fab","","color","warn","style","margin-right:10px","matTooltip","Lock","matTooltipPosition","above",3,"click",4,"ngIf"],["mat-mini-fab","","style","margin-right:10px; background-color: green;","matTooltip","Unlock","matTooltipPosition","above",3,"click",4,"ngIf"],["mat-mini-fab","","color","warn","matTooltip","Delete","matTooltipPosition","above",2,"margin-right","10px",3,"click"],["mat-mini-fab","","color","warn","matTooltip","Lock","matTooltipPosition","above",2,"margin-right","10px",3,"click"],["mat-mini-fab","","matTooltip","Unlock","matTooltipPosition","above",2,"margin-right","10px","background-color","green",3,"click"],["mat-header-row",""],["mat-row","",3,"ngClass"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4"),t.ɵɵtext(1,"Users"),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵelementStart(3,"div",0),t.ɵɵelementStart(4,"div",1),t.ɵɵelementStart(5,"div",2),t.ɵɵelementStart(6,"button",3),t.ɵɵlistener("click",(function(){return n.createAccount()})),t.ɵɵtext(7,"Create Account"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"div",4),t.ɵɵelementStart(9,"spa-filter",5),t.ɵɵlistener("refreshClick",(function(){return n.UpdateData()})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(10,Ci,3,0,"p",6),t.ɵɵtemplate(11,qi,28,3,"div",7),t.ɵɵelement(12,"mat-paginator",8,9),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(9),t.ɵɵproperty("data",n.users),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",!n.users),t.ɵɵadvance(1),t.ɵɵproperty("ngIf",n.users),t.ɵɵadvance(1),t.ɵɵproperty("pageSizeOptions",t.ɵɵpureFunction0(4,Hi)))},directives:[r.MatButton,Fn,i.NgIf,b.MatPaginator,O.MatTable,O.MatColumnDef,O.MatHeaderCellDef,O.MatCellDef,O.MatHeaderRowDef,O.MatRowDef,O.MatHeaderCell,O.MatCell,F.MatTooltip,S.MatIcon,O.MatHeaderRow,O.MatRow,i.NgClass],pipes:[i.DatePipe],styles:[".mat-mini-fab[_ngcontent-%COMP%]{width:32px;height:32px}.mat-mini-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:16px;margin-top:-3px}.refreshIcon[_ngcontent-%COMP%]{font-size:22px!important;margin-top:-7px!important}.make-gray[_ngcontent-%COMP%]{background-color:#d3d3d3}"]}),e}();function Gi(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div"),t.ɵɵelementStart(1,"mat-checkbox",8),t.ɵɵlistener("ngModelChange",(function(e){t.ɵɵrestoreView(i);var a=n.$implicit;return t.ɵɵnextContext(2).role[a.name]=e})),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext(2);t.ɵɵadvance(1),t.ɵɵproperty("ngModel",r.role[a.name]),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display)}}function Wi(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",7),t.ɵɵelementStart(1,"mat-checkbox",8),t.ɵɵlistener("ngModelChange",(function(e){t.ɵɵrestoreView(i);var a=n.$implicit;return t.ɵɵnextContext().role[a.name]=e})),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵtemplate(3,Gi,3,2,"div",9),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext();t.ɵɵadvance(1),t.ɵɵproperty("ngModel",r.role[a.name]),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",a.capSubItems)}}var Zi=function(){function e(e,t,n,i,a){this.messageService=e,this.dataService=t,this.authService=n,this.dialogRef=i,this.data=a,this.role=new De}return e.prototype.ngOnInit=function(){this.capItems=this.data},e.prototype.submit=function(){var e=this;"New Role"!=this.role.roleName&&""!=this.role.roleName?(this.isProcessing=!0,this.dataService.PostRole(this.role,"add").subscribe((function(t){e.isProcessing=!1,t.success?(e.messageService.toast("Role Added"),e.dialogRef.close("success")):e.messageService.toast("Error: "+t.message)}),(function(t){e.messageService.toast("Connection failed"),e.isProcessing=!1}))):this.messageService.toast("Please enter Role Name")},e.ɵfac=function(i){return new(i||e)(t.ɵɵdirectiveInject(re),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(n.MatDialogRef),t.ɵɵdirectiveInject(n.MAT_DIALOG_DATA))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["app-addRole"]],decls:13,vars:3,consts:[["matInput","","autocomplete","off","placeholder","Enter Role Name",3,"ngModel","ngModelChange"],[1,"mat-typography"],[1,"row"],[1,"row",2,"margin-left","2em","margin-right","2em"],["class","row","style","margin-left: 2em;",4,"ngFor","ngForOf"],["mat-button","","cdkFocusInitial","",3,"disabled","click"],["mat-button","","mat-dialog-close","success"],[1,"row",2,"margin-left","2em"],["color","primary",2,"margin-right","20px","font-size","12px","width","200px",3,"ngModel","ngModelChange"],[4,"ngFor","ngForOf"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"mat-form-field"),t.ɵɵelementStart(1,"mat-label"),t.ɵɵtext(2,"Role Name"),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"input",0),t.ɵɵlistener("ngModelChange",(function(e){return n.role.roleName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(4,"mat-dialog-content",1),t.ɵɵelementStart(5,"div",2),t.ɵɵelementStart(6,"div",3),t.ɵɵtemplate(7,Wi,4,3,"div",4),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"mat-dialog-actions"),t.ɵɵelementStart(9,"button",5),t.ɵɵlistener("click",(function(){return n.submit()})),t.ɵɵtext(10,"Submit"),t.ɵɵelementEnd(),t.ɵɵelementStart(11,"button",6),t.ɵɵtext(12,"Cancel"),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(3),t.ɵɵproperty("ngModel",n.role.roleName),t.ɵɵadvance(4),t.ɵɵproperty("ngForOf",n.capItems),t.ɵɵadvance(2),t.ɵɵproperty("disabled",n.isProcessing))},directives:[a.MatFormField,a.MatLabel,C.MatInput,L.DefaultValueAccessor,L.NgControlStatus,L.NgModel,n.MatDialogContent,i.NgForOf,n.MatDialogActions,r.MatButton,n.MatDialogClose,h.MatCheckbox],styles:[".mat-mini-fab[_ngcontent-%COMP%]{width:32px;height:32px}.mat-mini-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:16px;margin-top:-3px}.refreshIcon[_ngcontent-%COMP%]{font-size:22px!important;margin-top:-7px!important}"]}),e}();function Ji(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",17),t.ɵɵelementStart(1,"mat-checkbox",15),t.ɵɵlistener("ngModelChange",(function(e){t.ɵɵrestoreView(i);var a=n.$implicit;return t.ɵɵnextContext(3).$implicit[a.name]=e})),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext(3).$implicit;t.ɵɵadvance(1),t.ɵɵproperty("ngModel",r[a.name]),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display)}}function Qi(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",17),t.ɵɵelementStart(1,"mat-checkbox",15),t.ɵɵlistener("ngModelChange",(function(e){t.ɵɵrestoreView(i);var a=n.$implicit;return t.ɵɵnextContext(2).$implicit[a.name]=e})),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵtemplate(3,Ji,3,2,"div",18),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext(2).$implicit;t.ɵɵadvance(1),t.ɵɵproperty("ngModel",r[a.name]),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",a.capSubItems)}}function Ki(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",14),t.ɵɵelementStart(1,"mat-checkbox",15),t.ɵɵlistener("ngModelChange",(function(e){t.ɵɵrestoreView(i);var a=n.$implicit;return t.ɵɵnextContext().$implicit[a.name]=e})),t.ɵɵtext(2),t.ɵɵelementEnd(),t.ɵɵtemplate(3,Qi,4,3,"div",16),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext().$implicit;t.ɵɵadvance(1),t.ɵɵproperty("ngModel",r[a.name]),t.ɵɵadvance(1),t.ɵɵtextInterpolate(a.display),t.ɵɵadvance(1),t.ɵɵproperty("ngForOf",a.capSubItems)}}function Yi(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",8),t.ɵɵelementStart(1,"mat-card",9),t.ɵɵelementStart(2,"h4"),t.ɵɵtext(3),t.ɵɵelementEnd(),t.ɵɵelement(4,"hr"),t.ɵɵelementStart(5,"div",10),t.ɵɵtemplate(6,Ki,4,3,"div",11),t.ɵɵelementEnd(),t.ɵɵelementStart(7,"mat-card-actions"),t.ɵɵelementStart(8,"button",12),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=n.$implicit;return t.ɵɵnextContext().updateRole(e)})),t.ɵɵelementStart(9,"mat-icon"),t.ɵɵtext(10,"done_all"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(11,"button",13),t.ɵɵlistener("click",(function(){t.ɵɵrestoreView(i);var e=n.$implicit;return t.ɵɵnextContext().deleteRole(e)})),t.ɵɵelementStart(12,"mat-icon"),t.ɵɵtext(13,"delete"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=n.$implicit,r=t.ɵɵnextContext();t.ɵɵadvance(3),t.ɵɵtextInterpolate(a.roleName),t.ɵɵadvance(3),t.ɵɵproperty("ngForOf",r.appConfig.capItems)}}var Xi=function(){function e(e,t,n,i,a,r){this.httpService=e,this.router=t,this.authService=n,this.dataService=i,this.dialog=a,this.messageService=r,this.isProcessing=!1,this.appConfig=new we}return e.prototype.ngOnInit=function(){var e=this;this.authService.isAuthorised(this.dataService.capRoles.name),this.loadRoles(),this.dataService.appConfigObserv.subscribe((function(t){return e.appConfig=t}))},e.prototype.loadRoles=function(){var e=this;this.dataService.GetRole("all","").subscribe((function(t){e.roles=t}))},e.prototype.refresh=function(){this.loadRoles()},e.prototype.addRole=function(){var e=this;this.dialog.open(Zi,{width:"1100px",data:this.appConfig.capItems}).afterClosed().subscribe((function(t){"success"==t&&e.loadRoles()}))},e.prototype.updateRole=function(e){var t=this;this.messageService.confirm("UPDATE "+e.roleName+" ?").subscribe((function(n){"yes"==n&&t.dataService.PostRole(e,"edit").subscribe((function(e){e.success?(t.messageService.toast("Role Updated"),t.loadRoles()):t.messageService.toast("Error: "+e)}))}))},e.prototype.deleteRole=function(e){var t=this;this.messageService.confirm("DELETE "+e.roleName+" ?").subscribe((function(n){"yes"==n&&t.dataService.PostRole(e,"delete").subscribe((function(e){e.success?(t.messageService.toast("Role Deleted"),t.loadRoles()):t.messageService.toast("Error: "+e)}))}))},e.ɵfac=function(i){return new(i||e)(t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(d.Router),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(n.MatDialog),t.ɵɵdirectiveInject(re))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-roles"]],decls:13,vars:1,consts:[[1,"container","mb-5"],[1,"row","justify-content-between",2,"padding-bottom","10px","padding-left","10px"],[1,"col-2"],["id","btnNewRole","mat-raised-button","","color","primary",3,"click"],[1,"col-1"],["id","btnRefresh","mat-mini-fab","","color","primary","matTooltip","refresh data","matTooltipPosition","right",2,"margin-right","1em","margin-top","5px",3,"click"],[1,"refreshIcon"],["class","row mt-2 mb-1","style","margin-left:10px",4,"ngFor","ngForOf"],[1,"row","mt-2","mb-1",2,"margin-left","10px"],[1,"mat-elevation-z8",2,"width","100%","padding-left","2em"],[1,"row",2,"margin-left","2em"],["class","row","style","margin-right:20px;",4,"ngFor","ngForOf"],["mat-mini-fab","","color","primary",2,"margin-right","10px",3,"click"],["mat-mini-fab","","color","warn",2,"margin-right","10px",3,"click"],[1,"row",2,"margin-right","20px"],["color","primary",2,"font-size","12px","width","200px",3,"ngModel","ngModelChange"],["class","row","style","margin-right:20px;margin-left: 0px; ",4,"ngFor","ngForOf"],[1,"row",2,"margin-right","20px","margin-left","0px"],["class","row","style","margin-right:20px;margin-left: 0px;",4,"ngFor","ngForOf"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4"),t.ɵɵtext(1," Roles "),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵelementStart(3,"div",0),t.ɵɵelementStart(4,"div",1),t.ɵɵelementStart(5,"div",2),t.ɵɵelementStart(6,"button",3),t.ɵɵlistener("click",(function(){return n.addRole()})),t.ɵɵtext(7,"New Role"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"div",4),t.ɵɵelementStart(9,"button",5),t.ɵɵlistener("click",(function(){return n.refresh()})),t.ɵɵelementStart(10,"mat-icon",6),t.ɵɵtext(11,"refresh"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(12,Yi,14,2,"div",7),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(12),t.ɵɵproperty("ngForOf",n.roles))},directives:[r.MatButton,F.MatTooltip,S.MatIcon,i.NgForOf,g.MatCard,g.MatCardActions,h.MatCheckbox,L.NgControlStatus,L.NgModel],styles:[".mat-mini-fab[_ngcontent-%COMP%]{width:32px;height:32px}.mat-mini-fab[_ngcontent-%COMP%] mat-icon[_ngcontent-%COMP%]{font-size:16px;margin-top:-3px}.refreshIcon[_ngcontent-%COMP%]{font-size:22px!important;margin-top:-7px!important}"]}),e}();function ea(e,n){if(1&e){var i=t.ɵɵgetCurrentView();t.ɵɵelementStart(0,"div",2),t.ɵɵelementStart(1,"div",3),t.ɵɵelementStart(2,"spa-text",13),t.ɵɵlistener("valueChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().register.password=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(3,"div",3),t.ɵɵelementStart(4,"spa-text",14),t.ɵɵlistener("valueChange",(function(e){return t.ɵɵrestoreView(i),t.ɵɵnextContext().confirmPassword=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()}if(2&e){var a=t.ɵɵnextContext();t.ɵɵadvance(2),t.ɵɵproperty("value",a.register.password),t.ɵɵadvance(2),t.ɵɵproperty("value",a.confirmPassword)}}var ta=function(){function e(e,t,n,i,a){this.httpService=e,this.messageService=t,this.dataService=n,this.authService=i,this.router=a,this.appConfig=new we,this.isProcessing=!1,this.register=new Pe,this.openProfile=!0,this.authTypes=[{name:"Local Authentication",value:"local"},{name:"AD Authentication",value:"AD"}]}return e.prototype.ngOnInit=function(){this.appConfig=this.dataService.appConfig},e.prototype.create=function(){var e=this;""!=this.register.authType?(this.isProcessing=!0,this.dataService.RegisterAccount(this.register).subscribe((function(t){e.isProcessing=!1,t.success?(e.messageService.toast("Account Created"),e.openProfile?e.viewProfile(e.register.userName):(e.register=new Pe,e.confirmPassword="")):e.messageService.toast("Error: "+t.message)}),(function(t){e.isProcessing=!1,e.messageService.toast(e.httpService.Error(t))}))):this.messageService.toast("Choose Authentication Type")},e.prototype.viewProfile=function(e){this.dataService.tmpProfileuserName=e,this.router.navigate(["home/user/profile"])},e.ɵfac=function(n){return new(n||e)(t.ɵɵdirectiveInject(Oe),t.ɵɵdirectiveInject(re),t.ɵɵdirectiveInject(Le),t.ɵɵdirectiveInject(Fe),t.ɵɵdirectiveInject(d.Router))},e.ɵcmp=t.ɵɵdefineComponent({type:e,selectors:[["spa-create-account"]],inputs:{appConfig:"appConfig"},decls:22,vars:8,consts:[[1,"container"],[1,"tin-input",2,"font-size","14px","width","70%"],[1,"tin-input-row"],[1,"col"],["id","txtFirstName","display","FirstName",3,"value","valueChange"],["id","txtLastName","display","LastName",3,"value","valueChange"],[1,"tin-input-row","mt-3"],["id","txtUserName","display","Username",3,"value","valueChange"],["id","cboAuth","display","Authentication Type","optionDisplay","name","optionValue","value",3,"options","value","valueChange"],["class","tin-input-row",4,"ngIf"],[1,"tin-input-row","mt-3",2,"margin-left","1em"],["id","cbkOpenAfter","color","primary",2,"margin-right","100px","font-size","12px",3,"ngModel","ngModelChange"],["id","btnCreate","mat-raised-button","","color","primary","cdkFocusInitial","",3,"disabled","click"],["id","txtPassword","display","Password","type","password",3,"value","valueChange"],["id","txtConfirmPassword","display","Confirm Password","type","password",3,"value","valueChange"]],template:function(e,n){1&e&&(t.ɵɵelementStart(0,"h4"),t.ɵɵtext(1,"Create Account"),t.ɵɵelementEnd(),t.ɵɵelement(2,"hr"),t.ɵɵelementStart(3,"div",0),t.ɵɵelementStart(4,"div",1),t.ɵɵelementStart(5,"div",2),t.ɵɵelementStart(6,"div",3),t.ɵɵelementStart(7,"spa-text",4),t.ɵɵlistener("valueChange",(function(e){return n.register.firstName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(8,"div",3),t.ɵɵelementStart(9,"spa-text",5),t.ɵɵlistener("valueChange",(function(e){return n.register.lastName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(10,"div",6),t.ɵɵelementStart(11,"div",3),t.ɵɵelementStart(12,"spa-text",7),t.ɵɵlistener("valueChange",(function(e){return n.register.userName=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(13,"div",3),t.ɵɵelementStart(14,"spa-select",8),t.ɵɵlistener("valueChange",(function(e){return n.register.authType=e})),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵtemplate(15,ea,5,2,"div",9),t.ɵɵelementStart(16,"div",10),t.ɵɵelementStart(17,"mat-checkbox",11),t.ɵɵlistener("ngModelChange",(function(e){return n.openProfile=e})),t.ɵɵtext(18,"Open profile after creation"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementStart(19,"div",6),t.ɵɵelementStart(20,"button",12),t.ɵɵlistener("click",(function(){return n.create()})),t.ɵɵtext(21,"Create"),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd(),t.ɵɵelementEnd()),2&e&&(t.ɵɵadvance(7),t.ɵɵproperty("value",n.register.firstName),t.ɵɵadvance(2),t.ɵɵproperty("value",n.register.lastName),t.ɵɵadvance(3),t.ɵɵproperty("value",n.register.userName),t.ɵɵadvance(2),t.ɵɵproperty("options",n.authTypes)("value",n.register.authType),t.ɵɵadvance(1),t.ɵɵproperty("ngIf","local"==n.register.authType),t.ɵɵadvance(2),t.ɵɵproperty("ngModel",n.openProfile),t.ɵɵadvance(3),t.ɵɵproperty("disabled",""==n.register.authType))},directives:[Ut,tn,i.NgIf,h.MatCheckbox,L.NgControlStatus,L.NgModel,r.MatButton],styles:[""]}),e}(),na=function(){function e(){}return e.ɵmod=t.ɵɵdefineNgModule({type:e}),e.ɵinj=t.ɵɵdefineInjector({factory:function(t){return new(t||e)},imports:[[L.ReactiveFormsModule.withConfig({warnOnNgModelWithFormControl:"never"}),i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,jn],i.CommonModule,L.FormsModule,Ve]}),e}();("undefined"==typeof ngJitMode||ngJitMode)&&t.ɵɵsetNgModuleScope(na,{declarations:[$i,Xi,Zi,ta,xi,ni],imports:[L.ReactiveFormsModule,i.CommonModule,L.FormsModule,L.ReactiveFormsModule,Ve,jn],exports:[i.CommonModule,L.FormsModule,Ve,$i,Xi,Zi,ta,xi,ni]}),e.Account=Ee,e.ActionResponse=Ce,e.ActivityComponent=xn,e.ApiResponse=se,e.AppConfig=we,e.AttachComponent=ln,e.AuthService=Fe,e.CapItem=be,e.ChangePasswordComponent=Jn,e.ChangeUserPassword=ke,e.CheckComponent=nn,e.ChipsComponent=qt,e.Color=ye,e.Condition=ve,e.Constants=ce,e.Core=le,e.CreateAccountComponent=ta,e.DataServiceLib=Le,e.DateComponent=Dt,e.DatetimeComponent=sn,e.ExportService=oe,e.FilterComponent=Fn,e.HtmlComponent=Sn,e.HttpService=Oe,e.Icon=xe,e.LabelComponent=Nn,e.LoaderComponent=Ue,e.LogService=Te,e.LoginComponent=qn,e.LogsComponent=xi,e.MessageService=re,e.MoneyComponent=fn,e.NavMenuComponent=Ye,e.OptionComponent=bn,e.Profile=Ne,e.ProfileComponent=Xn,e.RecoverAccountComponent=$n,e.Register=Pe,e.Role=De,e.RolesComponent=Xi,e.SelectComponent=tn,e.SettingsComponent=ni,e.SignupComponent=Hn,e.SpaAdminModule=na,e.SpaIndexModule=Gn,e.SpaMatModule=Ve,e.SpaUserModule=ei,e.Step=me,e.StepsComponent=Tn,e.StorageService=W,e.TableAction=Se,e.TableColumn=ge,e.TableComponent=bt,e.TableConfig=ue,e.TableCreate=fe,e.TextComponent=Ut,e.Tile=de,e.TilesComponent=Nt,e.TimeoutComponent=Xe,e.TinSpaComponent=ze,e.TinSpaModule=jn,e.TinSpaService=G,e.User=Ie,e.UsersComponent=$i,e.ViewerComponent=Jt,e.addRoleDialog=Zi,e.loginConfig=Me,e.messageDialog=ae,Object.defineProperty(e,"__esModule",{value:!0})}));
16
+ //# sourceMappingURL=tin-spa.umd.min.js.map