@crystaldesign/diva-backoffice 24.12.0-beta.3 → 24.12.0-beta.31

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 (244) hide show
  1. package/build/esm/index.js +1711 -813
  2. package/build/types/backoffice/src/Configuration.d.ts +1 -0
  3. package/build/types/backoffice/src/Configuration.d.ts.map +1 -1
  4. package/build/types/backoffice/src/layout/Content/index.d.ts +3 -2
  5. package/build/types/backoffice/src/layout/Content/index.d.ts.map +1 -1
  6. package/build/types/backoffice/src/layout/Detail.d.ts +1 -1
  7. package/build/types/backoffice/src/layout/Detail.d.ts.map +1 -1
  8. package/build/types/backoffice/src/layout/ErrorBoundary.d.ts +2 -2
  9. package/build/types/backoffice/src/layout/ErrorBoundary.d.ts.map +1 -1
  10. package/build/types/backoffice/src/layout/IconRain/index.d.ts +2 -1
  11. package/build/types/backoffice/src/layout/IconRain/index.d.ts.map +1 -1
  12. package/build/types/backoffice/src/layout/MainLayout.d.ts +2 -1
  13. package/build/types/backoffice/src/layout/MainLayout.d.ts.map +1 -1
  14. package/build/types/backoffice/src/layout/Modal.d.ts +2 -1
  15. package/build/types/backoffice/src/layout/Modal.d.ts.map +1 -1
  16. package/build/types/backoffice/src/layout/Navigation/MenuElement.d.ts +1 -1
  17. package/build/types/backoffice/src/layout/Navigation/MenuElement.d.ts.map +1 -1
  18. package/build/types/backoffice/src/layout/Navigation/MenuLabel.d.ts +2 -1
  19. package/build/types/backoffice/src/layout/Navigation/MenuLabel.d.ts.map +1 -1
  20. package/build/types/backoffice/src/layout/Navigation/index.d.ts +2 -1
  21. package/build/types/backoffice/src/layout/Navigation/index.d.ts.map +1 -1
  22. package/build/types/backoffice/src/layout/Navigation/types.d.ts +2 -1
  23. package/build/types/backoffice/src/layout/Navigation/types.d.ts.map +1 -1
  24. package/build/types/backoffice/src/layout/Router.d.ts +2 -1
  25. package/build/types/backoffice/src/layout/Router.d.ts.map +1 -1
  26. package/build/types/backoffice/src/layout/Toolbar/Spinner/index.d.ts +2 -1
  27. package/build/types/backoffice/src/layout/Toolbar/Spinner/index.d.ts.map +1 -1
  28. package/build/types/backoffice/src/layout/Toolbar/Tools/WYSIWYG_Configurator/ArticleSelection/index.d.ts +2 -1
  29. package/build/types/backoffice/src/layout/Toolbar/Tools/WYSIWYG_Configurator/ArticleSelection/index.d.ts.map +1 -1
  30. package/build/types/backoffice/src/layout/Toolbar/Tools/WYSIWYG_Configurator/index.d.ts +2 -1
  31. package/build/types/backoffice/src/layout/Toolbar/Tools/WYSIWYG_Configurator/index.d.ts.map +1 -1
  32. package/build/types/backoffice/src/layout/Toolbar/Tools/WYSIWYG_ContentItem/index.d.ts +2 -1
  33. package/build/types/backoffice/src/layout/Toolbar/Tools/WYSIWYG_ContentItem/index.d.ts.map +1 -1
  34. package/build/types/backoffice/src/layout/Toolbar/index.d.ts +2 -1
  35. package/build/types/backoffice/src/layout/Toolbar/index.d.ts.map +1 -1
  36. package/build/types/backoffice/src/store/ConfigurationStore.d.ts +1 -1
  37. package/build/types/backoffice/src/store/ConfigurationStore.d.ts.map +1 -1
  38. package/build/types/backoffice/src/store/ContentStore.d.ts +1 -1
  39. package/build/types/backoffice/src/store/ContentStore.d.ts.map +1 -1
  40. package/build/types/backoffice/src/store/DownloadStore.d.ts.map +1 -1
  41. package/build/types/backoffice/src/store/ModalStore.d.ts.map +1 -1
  42. package/build/types/backoffice/src/store/RootStore.d.ts +1 -1
  43. package/build/types/backoffice/src/store/RootStore.d.ts.map +1 -1
  44. package/build/types/backoffice/src/store/index.d.ts +1 -1
  45. package/build/types/backoffice/src/store/index.d.ts.map +1 -1
  46. package/build/types/backoffice/src/ui/AGChart/index.d.ts +2 -1
  47. package/build/types/backoffice/src/ui/AGChart/index.d.ts.map +1 -1
  48. package/build/types/backoffice/src/ui/AGGrid/index.d.ts +3 -3
  49. package/build/types/backoffice/src/ui/AGGrid/index.d.ts.map +1 -1
  50. package/build/types/backoffice/src/ui/AGHistogram/index.d.ts +2 -1
  51. package/build/types/backoffice/src/ui/AGHistogram/index.d.ts.map +1 -1
  52. package/build/types/backoffice/src/ui/ActionButton.d.ts +1 -1
  53. package/build/types/backoffice/src/ui/ActionButton.d.ts.map +1 -1
  54. package/build/types/backoffice/src/ui/AssetMananger/MediaItem.d.ts +9 -2
  55. package/build/types/backoffice/src/ui/AssetMananger/MediaItem.d.ts.map +1 -1
  56. package/build/types/backoffice/src/ui/AssetMananger/Upload/FileFromWeb.d.ts +3 -2
  57. package/build/types/backoffice/src/ui/AssetMananger/Upload/FileFromWeb.d.ts.map +1 -1
  58. package/build/types/backoffice/src/ui/AssetMananger/Upload/index.d.ts +2 -1
  59. package/build/types/backoffice/src/ui/AssetMananger/Upload/index.d.ts.map +1 -1
  60. package/build/types/backoffice/src/ui/CatalogEditor/DragDropUpload/index.d.ts +2 -1
  61. package/build/types/backoffice/src/ui/CatalogEditor/DragDropUpload/index.d.ts.map +1 -1
  62. package/build/types/backoffice/src/ui/CatalogEditor/index.d.ts +2 -1
  63. package/build/types/backoffice/src/ui/CatalogEditor/index.d.ts.map +1 -1
  64. package/build/types/backoffice/src/ui/ConfirmationPopup.d.ts +2 -1
  65. package/build/types/backoffice/src/ui/ConfirmationPopup.d.ts.map +1 -1
  66. package/build/types/backoffice/src/ui/CustomButton/Result/index.d.ts +2 -1
  67. package/build/types/backoffice/src/ui/CustomButton/Result/index.d.ts.map +1 -1
  68. package/build/types/backoffice/src/ui/CustomButton/index.d.ts +6 -24
  69. package/build/types/backoffice/src/ui/CustomButton/index.d.ts.map +1 -1
  70. package/build/types/backoffice/src/ui/CustomInput/index.d.ts +3 -17
  71. package/build/types/backoffice/src/ui/CustomInput/index.d.ts.map +1 -1
  72. package/build/types/backoffice/src/ui/CustomInput/useInputData.d.ts +0 -1
  73. package/build/types/backoffice/src/ui/CustomInput/useInputData.d.ts.map +1 -1
  74. package/build/types/backoffice/src/ui/CustomText/index.d.ts +2 -6
  75. package/build/types/backoffice/src/ui/CustomText/index.d.ts.map +1 -1
  76. package/build/types/backoffice/src/ui/Description/index.d.ts +2 -1
  77. package/build/types/backoffice/src/ui/Description/index.d.ts.map +1 -1
  78. package/build/types/backoffice/src/ui/FileUploadBeta/index.d.ts +2 -1
  79. package/build/types/backoffice/src/ui/FileUploadBeta/index.d.ts.map +1 -1
  80. package/build/types/backoffice/src/ui/FilterBox/index.d.ts +2 -2
  81. package/build/types/backoffice/src/ui/FilterBox/index.d.ts.map +1 -1
  82. package/build/types/backoffice/src/ui/FilterBox/useFilterBoxData.d.ts +0 -1
  83. package/build/types/backoffice/src/ui/FilterBox/useFilterBoxData.d.ts.map +1 -1
  84. package/build/types/backoffice/src/ui/Form/Fields/ApiKey/index.d.ts +3 -2
  85. package/build/types/backoffice/src/ui/Form/Fields/ApiKey/index.d.ts.map +1 -1
  86. package/build/types/backoffice/src/ui/Form/Fields/FormList/index.d.ts +5 -25
  87. package/build/types/backoffice/src/ui/Form/Fields/FormList/index.d.ts.map +1 -1
  88. package/build/types/backoffice/src/ui/Form/Fields/Input/index.d.ts +4 -5
  89. package/build/types/backoffice/src/ui/Form/Fields/Input/index.d.ts.map +1 -1
  90. package/build/types/backoffice/src/ui/Form/Fields/Media/index.d.ts +2 -1
  91. package/build/types/backoffice/src/ui/Form/Fields/Media/index.d.ts.map +1 -1
  92. package/build/types/backoffice/src/ui/Form/Fields/Object/index.d.ts +5 -4
  93. package/build/types/backoffice/src/ui/Form/Fields/Object/index.d.ts.map +1 -1
  94. package/build/types/backoffice/src/ui/Form/Fields/SubTitle/index.d.ts +2 -1
  95. package/build/types/backoffice/src/ui/Form/Fields/SubTitle/index.d.ts.map +1 -1
  96. package/build/types/backoffice/src/ui/Form/Fields/Translation/index.d.ts +4 -22
  97. package/build/types/backoffice/src/ui/Form/Fields/Translation/index.d.ts.map +1 -1
  98. package/build/types/backoffice/src/ui/Form/Presets/index.d.ts +2 -1
  99. package/build/types/backoffice/src/ui/Form/Presets/index.d.ts.map +1 -1
  100. package/build/types/backoffice/src/ui/Form/elements.d.ts +2 -1
  101. package/build/types/backoffice/src/ui/Form/elements.d.ts.map +1 -1
  102. package/build/types/backoffice/src/ui/Form/index.d.ts +3 -7
  103. package/build/types/backoffice/src/ui/Form/index.d.ts.map +1 -1
  104. package/build/types/backoffice/src/ui/Form/types.d.ts +2 -1
  105. package/build/types/backoffice/src/ui/Form/types.d.ts.map +1 -1
  106. package/build/types/backoffice/src/ui/Form/useFormData.d.ts +1 -2
  107. package/build/types/backoffice/src/ui/Form/useFormData.d.ts.map +1 -1
  108. package/build/types/backoffice/src/ui/FormList/index.d.ts +3 -7
  109. package/build/types/backoffice/src/ui/FormList/index.d.ts.map +1 -1
  110. package/build/types/backoffice/src/ui/Grid/TooltipInfo/index.d.ts +2 -1
  111. package/build/types/backoffice/src/ui/Grid/TooltipInfo/index.d.ts.map +1 -1
  112. package/build/types/backoffice/src/ui/Grid/index.d.ts +2 -1
  113. package/build/types/backoffice/src/ui/Grid/index.d.ts.map +1 -1
  114. package/build/types/backoffice/src/ui/Grid/useGridData.d.ts +1 -2
  115. package/build/types/backoffice/src/ui/Grid/useGridData.d.ts.map +1 -1
  116. package/build/types/backoffice/src/ui/IDMEnricherEditor/components/PackageSelector/index.d.ts +2 -1
  117. package/build/types/backoffice/src/ui/IDMEnricherEditor/components/PackageSelector/index.d.ts.map +1 -1
  118. package/build/types/backoffice/src/ui/IDMEnricherEditor/components/PrefilterSelector/index.d.ts +2 -1
  119. package/build/types/backoffice/src/ui/IDMEnricherEditor/components/PrefilterSelector/index.d.ts.map +1 -1
  120. package/build/types/backoffice/src/ui/IDMEnricherEditor/index.d.ts +2 -1
  121. package/build/types/backoffice/src/ui/IDMEnricherEditor/index.d.ts.map +1 -1
  122. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableExclusivity/index.d.ts +7 -6
  123. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableExclusivity/index.d.ts.map +1 -1
  124. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TablePackages/index.d.ts +2 -1
  125. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TablePackages/index.d.ts.map +1 -1
  126. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableProperties/index.d.ts +2 -1
  127. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableProperties/index.d.ts.map +1 -1
  128. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableRenaming/index.d.ts +8 -7
  129. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableRenaming/index.d.ts.map +1 -1
  130. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableTabGroups/index.d.ts +2 -1
  131. package/build/types/backoffice/src/ui/IDMEnricherEditor/modules/TableTabGroups/index.d.ts.map +1 -1
  132. package/build/types/backoffice/src/ui/IDMEnricherEditor/useModule.d.ts.map +1 -1
  133. package/build/types/backoffice/src/ui/IFrame/index.d.ts +2 -1
  134. package/build/types/backoffice/src/ui/IFrame/index.d.ts.map +1 -1
  135. package/build/types/backoffice/src/ui/ImageCropper/index.d.ts +4 -16
  136. package/build/types/backoffice/src/ui/ImageCropper/index.d.ts.map +1 -1
  137. package/build/types/backoffice/src/ui/JsonEditor/index.d.ts +7 -27
  138. package/build/types/backoffice/src/ui/JsonEditor/index.d.ts.map +1 -1
  139. package/build/types/backoffice/src/ui/List/index.d.ts +3 -7
  140. package/build/types/backoffice/src/ui/List/index.d.ts.map +1 -1
  141. package/build/types/backoffice/src/ui/MediaUpload/useMediaUpload.d.ts +13 -11
  142. package/build/types/backoffice/src/ui/MediaUpload/useMediaUpload.d.ts.map +1 -1
  143. package/build/types/backoffice/src/ui/ModalProgressBar/index.d.ts +2 -1
  144. package/build/types/backoffice/src/ui/ModalProgressBar/index.d.ts.map +1 -1
  145. package/build/types/backoffice/src/ui/RelationSelector/DropDown/index.d.ts +2 -1
  146. package/build/types/backoffice/src/ui/RelationSelector/DropDown/index.d.ts.map +1 -1
  147. package/build/types/backoffice/src/ui/RelationSelector/RelationSelectorApiHandler.d.ts +1 -1
  148. package/build/types/backoffice/src/ui/RelationSelector/RelationSelectorApiHandler.d.ts.map +1 -1
  149. package/build/types/backoffice/src/ui/RelationSelector/filter/index.d.ts +2 -1
  150. package/build/types/backoffice/src/ui/RelationSelector/filter/index.d.ts.map +1 -1
  151. package/build/types/backoffice/src/ui/RelationSelector/index.d.ts +3 -7
  152. package/build/types/backoffice/src/ui/RelationSelector/index.d.ts.map +1 -1
  153. package/build/types/backoffice/src/ui/RelationSelector/useRelationSelectorData.d.ts +9 -10
  154. package/build/types/backoffice/src/ui/RelationSelector/useRelationSelectorData.d.ts.map +1 -1
  155. package/build/types/backoffice/src/ui/RichTextEditor/index.d.ts +3 -2
  156. package/build/types/backoffice/src/ui/RichTextEditor/index.d.ts.map +1 -1
  157. package/build/types/backoffice/src/ui/RoleSelector/index.d.ts +3 -7
  158. package/build/types/backoffice/src/ui/RoleSelector/index.d.ts.map +1 -1
  159. package/build/types/backoffice/src/ui/RoleSelector/useRoleSelectorData.d.ts +2 -3
  160. package/build/types/backoffice/src/ui/RoleSelector/useRoleSelectorData.d.ts.map +1 -1
  161. package/build/types/backoffice/src/ui/SMChart/types.d.ts +0 -1
  162. package/build/types/backoffice/src/ui/SMChart/types.d.ts.map +1 -1
  163. package/build/types/backoffice/src/ui/Select/index.d.ts +2 -2
  164. package/build/types/backoffice/src/ui/Select/index.d.ts.map +1 -1
  165. package/build/types/backoffice/src/ui/Select/useSelectData.d.ts +0 -1
  166. package/build/types/backoffice/src/ui/Select/useSelectData.d.ts.map +1 -1
  167. package/build/types/backoffice/src/ui/SelectClientRelationCatalog/Select/index.d.ts +2 -1
  168. package/build/types/backoffice/src/ui/SelectClientRelationCatalog/Select/index.d.ts.map +1 -1
  169. package/build/types/backoffice/src/ui/SelectClientRelationCatalog/index.d.ts +2 -1
  170. package/build/types/backoffice/src/ui/SelectClientRelationCatalog/index.d.ts.map +1 -1
  171. package/build/types/backoffice/src/ui/SelectClientRelationCatalog/useSelectClientRelationCatalog.d.ts +0 -1
  172. package/build/types/backoffice/src/ui/SelectClientRelationCatalog/useSelectClientRelationCatalog.d.ts.map +1 -1
  173. package/build/types/backoffice/src/ui/SelectOrCreate/index.d.ts +3 -7
  174. package/build/types/backoffice/src/ui/SelectOrCreate/index.d.ts.map +1 -1
  175. package/build/types/backoffice/src/ui/SelectSimple/index.d.ts +1 -3
  176. package/build/types/backoffice/src/ui/SelectSimple/index.d.ts.map +1 -1
  177. package/build/types/backoffice/src/ui/SelectSimple/types.d.ts +0 -1
  178. package/build/types/backoffice/src/ui/SelectSimple/types.d.ts.map +1 -1
  179. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/BooleanCell/index.d.ts +2 -1
  180. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/BooleanCell/index.d.ts.map +1 -1
  181. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/DropdownCell/index.d.ts +2 -1
  182. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/DropdownCell/index.d.ts.map +1 -1
  183. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/IconCell/index.d.ts +2 -1
  184. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/IconCell/index.d.ts.map +1 -1
  185. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/ImageCell/index.d.ts +2 -1
  186. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/ImageCell/index.d.ts.map +1 -1
  187. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/MediaItemViewerCell/index.d.ts +2 -1
  188. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/MediaItemViewerCell/index.d.ts.map +1 -1
  189. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/MediaViewerCell/index.d.ts +2 -1
  190. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/MediaViewerCell/index.d.ts.map +1 -1
  191. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/StringCell/index.d.ts +2 -1
  192. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/StringCell/index.d.ts.map +1 -1
  193. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/TextCell/index.d.ts +2 -1
  194. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/TextCell/index.d.ts.map +1 -1
  195. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/UnixTimeStamCheckCell/index.d.ts +2 -1
  196. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/UnixTimeStamCheckCell/index.d.ts.map +1 -1
  197. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/UnixTimeStampCell/index.d.ts +2 -1
  198. package/build/types/backoffice/src/ui/Table/BaseTable/cellRenderer/UnixTimeStampCell/index.d.ts.map +1 -1
  199. package/build/types/backoffice/src/ui/Table/BaseTable/getExpandedRowRenderer.d.ts +2 -1
  200. package/build/types/backoffice/src/ui/Table/BaseTable/getExpandedRowRenderer.d.ts.map +1 -1
  201. package/build/types/backoffice/src/ui/Table/BaseTable/index.d.ts +2 -1
  202. package/build/types/backoffice/src/ui/Table/BaseTable/index.d.ts.map +1 -1
  203. package/build/types/backoffice/src/ui/Table/CatalogTable/index.d.ts +2 -1
  204. package/build/types/backoffice/src/ui/Table/CatalogTable/index.d.ts.map +1 -1
  205. package/build/types/backoffice/src/ui/Table/CatalogTable/useTableData.d.ts.map +1 -1
  206. package/build/types/backoffice/src/ui/Table/StandardTable/index.d.ts +2 -1
  207. package/build/types/backoffice/src/ui/Table/StandardTable/index.d.ts.map +1 -1
  208. package/build/types/backoffice/src/ui/Table/StandardTable/useTableData.d.ts.map +1 -1
  209. package/build/types/backoffice/src/ui/Table/index.d.ts +2 -1
  210. package/build/types/backoffice/src/ui/Table/index.d.ts.map +1 -1
  211. package/build/types/backoffice/src/ui/Table/types.d.ts +5 -1
  212. package/build/types/backoffice/src/ui/Table/types.d.ts.map +1 -1
  213. package/build/types/backoffice/src/ui/Table/utils/applyFilterAndSortation.d.ts +108 -0
  214. package/build/types/backoffice/src/ui/Table/utils/applyFilterAndSortation.d.ts.map +1 -0
  215. package/build/types/backoffice/src/ui/Table/utils/mapColumns.d.ts.map +1 -1
  216. package/build/types/backoffice/src/ui/TreeChart/BreadCrumbsTrigger/index.d.ts +2 -1
  217. package/build/types/backoffice/src/ui/TreeChart/BreadCrumbsTrigger/index.d.ts.map +1 -1
  218. package/build/types/backoffice/src/ui/TreeChart/HelpLegend/index.d.ts +2 -1
  219. package/build/types/backoffice/src/ui/TreeChart/HelpLegend/index.d.ts.map +1 -1
  220. package/build/types/backoffice/src/ui/TreeChart/OrgItem/index.d.ts +1 -1
  221. package/build/types/backoffice/src/ui/TreeChart/OrgItem/index.d.ts.map +1 -1
  222. package/build/types/backoffice/src/ui/TreeChart/SearchSelect/index.d.ts +2 -1
  223. package/build/types/backoffice/src/ui/TreeChart/SearchSelect/index.d.ts.map +1 -1
  224. package/build/types/backoffice/src/ui/TreeChart/ZoomWrapper/index.d.ts +2 -1
  225. package/build/types/backoffice/src/ui/TreeChart/ZoomWrapper/index.d.ts.map +1 -1
  226. package/build/types/backoffice/src/ui/TreeChart/index.d.ts +2 -1
  227. package/build/types/backoffice/src/ui/TreeChart/index.d.ts.map +1 -1
  228. package/build/types/backoffice/src/ui/UIBuilder/index.d.ts +2 -1
  229. package/build/types/backoffice/src/ui/UIBuilder/index.d.ts.map +1 -1
  230. package/build/types/backoffice/src/ui/UIBuilder/useUIBuilderData.d.ts +0 -1
  231. package/build/types/backoffice/src/ui/UIBuilder/useUIBuilderData.d.ts.map +1 -1
  232. package/build/types/backoffice/src/utils/{aplyMapping.d.ts → applyMapping.d.ts} +3 -3
  233. package/build/types/backoffice/src/utils/applyMapping.d.ts.map +1 -0
  234. package/build/types/backoffice/src/utils/{aplyRule.d.ts → applyRule.d.ts} +2 -2
  235. package/build/types/backoffice/src/utils/applyRule.d.ts.map +1 -0
  236. package/build/types/backoffice/src/utils/getIcons.d.ts +2 -1
  237. package/build/types/backoffice/src/utils/getIcons.d.ts.map +1 -1
  238. package/build/types/backoffice/src/utils/parseServersideFilters.d.ts +1 -0
  239. package/build/types/backoffice/src/utils/parseServersideFilters.d.ts.map +1 -1
  240. package/package.json +36 -38
  241. package/build/types/backoffice/src/ui/Table/utils/aplyFilterAndSortation.d.ts +0 -53
  242. package/build/types/backoffice/src/ui/Table/utils/aplyFilterAndSortation.d.ts.map +0 -1
  243. package/build/types/backoffice/src/utils/aplyMapping.d.ts.map +0 -1
  244. package/build/types/backoffice/src/utils/aplyRule.d.ts.map +0 -1
@@ -1,7 +1,7 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/defineProperty';
2
- import React, { createElement, createContext, useState, useEffect, useRef, useMemo, useImperativeHandle, useCallback, createRef, useReducer, useContext, memo } from 'react';
2
+ import React, { createElement, createContext, useState, useEffect, useRef, useMemo, forwardRef, useImperativeHandle, useCallback, createRef, useReducer, useContext, memo } from 'react';
3
3
  import 'antd/dist/reset.css';
4
- import { Form as Form$1, Button, Input, Popover, Typography, Divider, Select as Select$1, Avatar, Spin, Radio, Space, DatePicker, Checkbox, InputNumber, Modal as Modal$2, Progress, Cascader, Descriptions, Row, Col, Tooltip as Tooltip$1, Collapse, List as List$1, Skeleton, Alert, Card, Upload as Upload$2, Switch, Table as Table$1, Popconfirm, Tabs, Image, Slider, Breadcrumb, Result as Result$1, message, Layout, Drawer, ConfigProvider, theme } from 'antd';
4
+ import { Form as Form$1, Button, Input, Popover, Typography, Divider, Progress, Select as Select$1, Avatar, Spin, Radio, Space, Dropdown, DatePicker, Checkbox, InputNumber, Modal as Modal$2, Cascader, Descriptions, Row, Col, Tooltip as Tooltip$1, Collapse, List as List$1, Skeleton, Alert, Card, Upload as Upload$2, Switch, Table as Table$1, Popconfirm, Tabs, Image, Slider, Breadcrumb, Result as Result$1, message, Layout, Drawer, ConfigProvider, theme } from 'antd';
5
5
  import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
6
6
  import { observer } from 'mobx-react-lite';
7
7
  import { getLogger, DivaError, useTranslation, useDivaCore, DivaUtils } from '@crystaldesign/diva-core';
@@ -16,12 +16,12 @@ import _get from '@babel/runtime/helpers/get';
16
16
  import _inherits from '@babel/runtime/helpers/inherits';
17
17
  import _regeneratorRuntime from '@babel/runtime/regenerator';
18
18
  import _typeof from '@babel/runtime/helpers/typeof';
19
- import flat, { flatten, unflatten } from 'flat';
19
+ import { flatten, unflatten } from 'flat';
20
20
  import { compare } from 'fast-json-patch';
21
21
  import { io } from 'socket.io-client';
22
22
  import _toConsumableArray from '@babel/runtime/helpers/toConsumableArray';
23
23
  import { toJS, makeAutoObservable, observable, action, makeObservable } from 'mobx';
24
- import merge from 'deepmerge';
24
+ import mergeWith from 'lodash/mergeWith';
25
25
  import Tooltip from 'antd/es/tooltip';
26
26
  import RightOutlined from '@ant-design/icons/RightOutlined';
27
27
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
@@ -64,8 +64,12 @@ import FileExcelOutlined from '@ant-design/icons/FileExcelOutlined';
64
64
  import FolderOutlined from '@ant-design/icons/FolderOutlined';
65
65
  import SettingOutlined from '@ant-design/icons/SettingOutlined';
66
66
  import PieChartOutlined from '@ant-design/icons/PieChartOutlined';
67
+ import ClockCircleOutlined from '@ant-design/icons/ClockCircleOutlined';
68
+ import FileZipOutlined from '@ant-design/icons/FileZipOutlined';
69
+ import PlaySquareOutlined from '@ant-design/icons/PlaySquareOutlined';
67
70
  import InfoCircleOutlined from '@ant-design/icons/InfoCircleOutlined';
68
- import { cloneDeep, merge as merge$1, mergeWith } from 'lodash';
71
+ import merge from 'lodash/merge';
72
+ import cloneDeep from 'lodash/cloneDeep';
69
73
  import DivaUtils$1, { nanoid, DivaError as DivaError$1 } from '@crystaldesign/diva-utils';
70
74
  import DeleteOutlined from '@ant-design/icons/DeleteOutlined';
71
75
  import JSONEditor from 'jsoneditor';
@@ -73,10 +77,11 @@ import 'jsoneditor/dist/jsoneditor.css';
73
77
  import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
74
78
  import { MinusCircleOutlined, PlusOutlined, DownloadOutlined as DownloadOutlined$1, PlusSquareOutlined, DeleteOutlined as DeleteOutlined$1, FullscreenOutlined, FileUnknownOutlined, CloseOutlined as CloseOutlined$1, PlusCircleOutlined as PlusCircleOutlined$1, HomeOutlined as HomeOutlined$1, InboxOutlined, PushpinOutlined, PushpinFilled, ReloadOutlined as ReloadOutlined$1 } from '@ant-design/icons';
75
79
  import classnames from 'classnames';
76
- import { Editor } from '@tinymce/tinymce-react';
80
+ import RTFEditor from '@crystaldesign/rtf-editor';
77
81
  import debounce from 'lodash/debounce';
78
82
  import Button$1 from 'antd/es/button';
79
83
  import Upload$1 from 'antd/es/upload';
84
+ import DownOutlined from '@ant-design/icons/lib/icons/DownOutlined';
80
85
  import Space$1 from 'antd/es/space';
81
86
  import { stringify } from 'csv';
82
87
  import InfiniteScroll from 'react-infinite-scroll-component';
@@ -91,8 +96,9 @@ import QuestionCircleOutlined from '@ant-design/icons/QuestionCircleOutlined';
91
96
  import WarningTwoTone from '@ant-design/icons/WarningTwoTone';
92
97
  import CheckOutlined from '@ant-design/icons/lib/icons/CheckOutlined';
93
98
  import CloseOutlined from '@ant-design/icons/lib/icons/CloseOutlined';
99
+ import merge$1 from 'deepmerge';
94
100
  import { ContentBoxComponent } from '@crystaldesign/content-box';
95
- import { AgChartsReact } from 'ag-charts-react';
101
+ import { AgCharts } from 'ag-charts-react';
96
102
  import { Histogram } from '@crystaldesign/analytics';
97
103
  import dayjs from 'dayjs';
98
104
  import advancedFormat from 'dayjs/plugin/advancedFormat';
@@ -142,16 +148,16 @@ function _unsupportedIterableToArray$m(r, a) { if (r) { if ("string" == typeof r
142
148
  function _arrayLikeToArray$m(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
143
149
  function ownKeys$N(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
144
150
  function _objectSpread$N(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$N(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$N(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
145
- var LOG$c = getLogger('Backoffice', 'AplyMapping');
146
- function aplyMapping (_ref) {
147
- var mapable = _ref.mapable,
151
+ var LOG$d = getLogger('Backoffice', 'ApplyMapping');
152
+ function applyMapping (_ref) {
153
+ var mappable = _ref.mappable,
148
154
  mappingData = _ref.mappingData,
149
155
  mapping = _ref.mapping,
150
156
  rootStore = _ref.rootStore,
151
157
  _ref$fallBackToParams = _ref.fallBackToParams,
152
158
  fallBackToParams = _ref$fallBackToParams === void 0 ? true : _ref$fallBackToParams;
153
159
  var isFormData = false;
154
- var returnValue = mapable;
160
+ var returnValue = mappable;
155
161
  function set(key, value, type) {
156
162
  if (isFormData) {
157
163
  returnValue.set(key, value);
@@ -191,10 +197,10 @@ function aplyMapping (_ref) {
191
197
  return false;
192
198
  }
193
199
  try {
194
- if (mapable && mapping) {
200
+ if (mappable && mapping) {
195
201
  var flatMapping = mappingData ? flatten(mappingData) : {};
196
202
  if (mapping.type == 'filter') {
197
- if (typeof mapable !== 'string') {
203
+ if (typeof mappable !== 'string') {
198
204
  throw new Error('Urls can only be processed with mappings of type "query" or "filter".');
199
205
  }
200
206
  var url = new URL(returnValue);
@@ -222,7 +228,7 @@ function aplyMapping (_ref) {
222
228
  }
223
229
  returnValue = url.toString();
224
230
  } else if (mapping.type == 'query') {
225
- if (typeof mapable !== 'string') {
231
+ if (typeof mappable !== 'string') {
226
232
  throw new Error('Urls can only be processed with mappings of type "query" or "filter".');
227
233
  }
228
234
  var _url = new URL(returnValue);
@@ -265,10 +271,10 @@ function aplyMapping (_ref) {
265
271
  }
266
272
  returnValue = _url.toString();
267
273
  } else if (mapping.type == 'body') {
268
- if (_typeof(mapable) !== 'object') {
274
+ if (_typeof(mappable) !== 'object') {
269
275
  throw new Error('Objects can only be processed with mappings of type "body".');
270
276
  }
271
- if (mapable.entries) {
277
+ if (mappable.entries) {
272
278
  isFormData = true;
273
279
  }
274
280
  for (var _i = 0; _i < mapping.map.length; _i++) {
@@ -286,7 +292,7 @@ function aplyMapping (_ref) {
286
292
  }
287
293
  return returnValue;
288
294
  } catch (e) {
289
- LOG$c.debug('Mapabledata', mapable);
295
+ LOG$d.debug('Mapabledata', mappable);
290
296
  throw e;
291
297
  }
292
298
  }
@@ -317,8 +323,21 @@ function parseServersideFilters (_ref) {
317
323
  if (Object.keys(filters !== null && filters !== void 0 ? filters : {}).length || Object.keys(prefilter !== null && prefilter !== void 0 ? prefilter : {}).length) {
318
324
  if (useFullTextSearch(filters !== null && filters !== void 0 ? filters : {})) {
319
325
  url = "".concat(url, "&search=").concat(encodeURIComponent(parseFilter(filters !== null && filters !== void 0 ? filters : {}, prefilter).replaceAll(' ', '%20')).replaceAll('(', '%28').replaceAll(')', '%29'));
320
- } else {
326
+ } else if (!url.includes('filter=')) {
321
327
  url = "".concat(url, "&filter=").concat(encodeURIComponent(parseFilter(filters !== null && filters !== void 0 ? filters : {}, prefilter).replaceAll(' ', '%20')).replaceAll('(', '%28').replaceAll(')', '%29'));
328
+ } else {
329
+ var urlConstruct = new URL(url);
330
+ var params = new URLSearchParams(urlConstruct.search);
331
+
332
+ // Step 2: Get the existing filter parameter
333
+ var existingFilter = params.get('filter');
334
+
335
+ // Step 3: Add another filter parameter
336
+ params.set('filter', '[' + (existingFilter === null || existingFilter === void 0 ? void 0 : existingFilter.slice(1, -1)) + ',' + parseFilter(filters !== null && filters !== void 0 ? filters : {}, prefilter).replaceAll(' ', '%20').replaceAll('(', '%28').replaceAll(')', '%29').slice(1, -1) + ']');
337
+
338
+ // Step 4: Update the URL
339
+ urlConstruct.search = params.toString();
340
+ url = urlConstruct.toString();
322
341
  }
323
342
  }
324
343
  if (genericProps) {
@@ -355,7 +374,7 @@ function parseFilter(filters, prefilter) {
355
374
  }
356
375
  } else {
357
376
  var or = values[2]; //filter[1][2]; // [field, [value, operator, or?]]
358
- var index = or === true ? 0 : or;
377
+ var index = or === true || or === 0 ? false : or;
359
378
  var inFilter = values[values.length - 1] === 'in';
360
379
  if (index == undefined || index === false || inFilter) {
361
380
  if (inFilter) {
@@ -448,7 +467,7 @@ function getLeafColumns(columns) {
448
467
 
449
468
  function ownKeys$M(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
450
469
  function _objectSpread$M(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$M(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$M(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
451
- var LOG$b = getLogger('Backoffice', 'ApiHandler');
470
+ var LOG$c = getLogger('Backoffice', 'ApiHandler');
452
471
  var jp = require('jsonpath');
453
472
  var _default$d = /*#__PURE__*/function () {
454
473
  function _default(configuration, _rootStore) {
@@ -593,8 +612,8 @@ var _default$d = /*#__PURE__*/function () {
593
612
  _context2.next = 10;
594
613
  break;
595
614
  }
596
- data = aplyMapping({
597
- mapable: data,
615
+ data = applyMapping({
616
+ mappable: data,
598
617
  mappingData: data,
599
618
  mapping: mapping,
600
619
  rootStore: this._rootStore,
@@ -607,8 +626,8 @@ var _default$d = /*#__PURE__*/function () {
607
626
  _context2.next = 14;
608
627
  break;
609
628
  }
610
- finalUrl = aplyMapping({
611
- mapable: finalUrl,
629
+ finalUrl = applyMapping({
630
+ mappable: finalUrl,
612
631
  mapping: mapping,
613
632
  rootStore: this._rootStore,
614
633
  fallBackToParams: false
@@ -712,8 +731,8 @@ var _default$d = /*#__PURE__*/function () {
712
731
  if (jwt) header['Authorization'] = 'Bearer ' + jwt;
713
732
  if (sessionGuid) header['SessionGuid'] = sessionGuid;
714
733
  if ((mapping === null || mapping === void 0 ? void 0 : mapping.type) == 'query') {
715
- url = aplyMapping({
716
- mapable: this._createUrl,
734
+ url = applyMapping({
735
+ mappable: this._createUrl,
717
736
  mapping: mapping,
718
737
  mappingData: mappingData,
719
738
  rootStore: this._rootStore,
@@ -721,8 +740,8 @@ var _default$d = /*#__PURE__*/function () {
721
740
  });
722
741
  if (data) createData = _objectSpread$M({}, data);
723
742
  } else if (data !== undefined) {
724
- createData = aplyMapping({
725
- mapable: data,
743
+ createData = applyMapping({
744
+ mappable: data,
726
745
  mapping: mapping,
727
746
  mappingData: mappingData,
728
747
  rootStore: this._rootStore,
@@ -733,8 +752,8 @@ var _default$d = /*#__PURE__*/function () {
733
752
  if (formData !== undefined) {
734
753
  // set metadata doesn't work with content type set
735
754
  delete header['Content-Type'];
736
- createData = aplyMapping({
737
- mapable: formData,
755
+ createData = applyMapping({
756
+ mappable: formData,
738
757
  mappingData: mappingData,
739
758
  mapping: mapping,
740
759
  rootStore: this._rootStore,
@@ -831,8 +850,8 @@ var _default$d = /*#__PURE__*/function () {
831
850
  throw new Error('Delete endpoint is missing in configuration.');
832
851
  case 2:
833
852
  jwt = (_this$_rootStore3 = this._rootStore) === null || _this$_rootStore3 === void 0 ? void 0 : _this$_rootStore3.dataStore.jwt;
834
- url = new URL(aplyMapping({
835
- mapable: this._deleteUrl,
853
+ url = new URL(applyMapping({
854
+ mappable: this._deleteUrl,
836
855
  mapping: mapping,
837
856
  mappingData: mappingData,
838
857
  rootStore: this._rootStore,
@@ -840,8 +859,8 @@ var _default$d = /*#__PURE__*/function () {
840
859
  }));
841
860
  if (id && this._applyIdField) {
842
861
  if (this._deleteUrl.includes("${".concat(this._deleteIdField, "}"))) {
843
- url = new URL(aplyMapping({
844
- mapable: url.toString(),
862
+ url = new URL(applyMapping({
863
+ mappable: url.toString(),
845
864
  mapping: {
846
865
  type: 'query',
847
866
  map: [{
@@ -1029,8 +1048,8 @@ var _default$d = /*#__PURE__*/function () {
1029
1048
  baseUrl: this._readListUrl,
1030
1049
  prefilter: prefilter
1031
1050
  })) : this._readListUrl;
1032
- url = aplyMapping({
1033
- mapable: url,
1051
+ url = applyMapping({
1052
+ mappable: url,
1034
1053
  mapping: mapping,
1035
1054
  mappingData: mappingData,
1036
1055
  rootStore: this._rootStore,
@@ -1046,8 +1065,8 @@ var _default$d = /*#__PURE__*/function () {
1046
1065
  return _regeneratorRuntime.wrap(function _callee9$(_context9) {
1047
1066
  while (1) switch (_context9.prev = _context9.next) {
1048
1067
  case 0:
1049
- url = aplyMapping({
1050
- mapable: baseUrl,
1068
+ url = applyMapping({
1069
+ mappable: baseUrl,
1051
1070
  mapping: mapping,
1052
1071
  mappingData: mappingData,
1053
1072
  rootStore: this._rootStore,
@@ -1108,8 +1127,8 @@ var _default$d = /*#__PURE__*/function () {
1108
1127
  value: function createSocket(data, mapping, namespace) {
1109
1128
  var _this$_rootStore7;
1110
1129
  if (!this._socketUrl) throw new Error('no socket url configured');
1111
- var url = new URL(aplyMapping({
1112
- mapable: this._socketUrl,
1130
+ var url = new URL(applyMapping({
1131
+ mappable: this._socketUrl,
1113
1132
  mapping: mapping,
1114
1133
  mappingData: data,
1115
1134
  rootStore: this._rootStore,
@@ -1125,16 +1144,16 @@ var _default$d = /*#__PURE__*/function () {
1125
1144
  }
1126
1145
  });
1127
1146
  this._socket.on('error', function (error) {
1128
- LOG$b.error(new DivaError('Error on connection', error));
1147
+ LOG$c.error(new DivaError('Error on connection', error));
1129
1148
  });
1130
1149
  this._socket.on('connect_error', function (error) {
1131
- LOG$b.log("connect_error due to ".concat(error.message));
1150
+ LOG$c.log("connect_error due to ".concat(error.message));
1132
1151
  });
1133
1152
  this._socket.on('connect', function () {
1134
- LOG$b.debug('Successfully connected to socket');
1153
+ LOG$c.debug('Successfully connected to socket');
1135
1154
  });
1136
1155
  this._socket.on('disconnect', function () {
1137
- LOG$b.debug('Disconnect from socket');
1156
+ LOG$c.debug('Disconnect from socket');
1138
1157
  });
1139
1158
  return this._socket;
1140
1159
  }
@@ -1273,8 +1292,8 @@ var _default$b = /*#__PURE__*/function (_ApiHandler) {
1273
1292
  _context.next = 8;
1274
1293
  break;
1275
1294
  }
1276
- data = aplyMapping({
1277
- mapable: {},
1295
+ data = applyMapping({
1296
+ mappable: {},
1278
1297
  mapping: this.configuration.targetMapping,
1279
1298
  rootStore: this._rootStore
1280
1299
  });
@@ -1344,8 +1363,8 @@ var _default$b = /*#__PURE__*/function (_ApiHandler) {
1344
1363
  _context2.next = 10;
1345
1364
  break;
1346
1365
  }
1347
- _data = aplyMapping({
1348
- mapable: {},
1366
+ _data = applyMapping({
1367
+ mappable: {},
1349
1368
  mapping: this.configuration.targetMapping,
1350
1369
  mappingData: {
1351
1370
  url: response.ref.url,
@@ -1389,8 +1408,8 @@ var _default$b = /*#__PURE__*/function (_ApiHandler) {
1389
1408
  _context3.next = 6;
1390
1409
  break;
1391
1410
  }
1392
- data = aplyMapping({
1393
- mapable: {},
1411
+ data = applyMapping({
1412
+ mappable: {},
1394
1413
  mapping: this.configuration.targetMapping,
1395
1414
  mappingData: {
1396
1415
  url: '',
@@ -1580,8 +1599,8 @@ var _default$8 = /*#__PURE__*/function (_ApiHandler) {
1580
1599
  // so we merge them into one in order to aply the mapping
1581
1600
  var mergedMappingData = Object.assign({}, mappingData);
1582
1601
  mergedMappingData = Object.assign(mergedMappingData, data);
1583
- var newEntry = aplyMapping({
1584
- mapable: {},
1602
+ var newEntry = applyMapping({
1603
+ mappable: {},
1585
1604
  mapping: _this2.configuration.actionMapping,
1586
1605
  mappingData: mergedMappingData,
1587
1606
  rootStore: _this2._rootStore
@@ -1715,8 +1734,8 @@ var _default$7 = /*#__PURE__*/function () {
1715
1734
  function _default(root) {
1716
1735
  _classCallCheck(this, _default);
1717
1736
  this.root = root;
1718
- _defineProperty(this, "_configuration", void 0);
1719
- _defineProperty(this, "_apiConfig", void 0);
1737
+ _defineProperty(this, "_configuration", undefined);
1738
+ _defineProperty(this, "_apiConfig", undefined);
1720
1739
  makeAutoObservable(this, {
1721
1740
  root: false,
1722
1741
  fetchConfiguration: false
@@ -1760,10 +1779,9 @@ var _default$7 = /*#__PURE__*/function () {
1760
1779
 
1761
1780
  //merge with configuration so everything can changed by config
1762
1781
  if (config.configuration) {
1763
- configuration = merge(configuration, config.configuration, {
1764
- arrayMerge: function arrayMerge(_, s) {
1765
- return s;
1766
- }
1782
+ configuration = mergeWith(configuration, config.configuration, function (obj, src) {
1783
+ if (Array.isArray(obj) && Array.isArray(src) && obj.length != src.length) return src;
1784
+ return undefined;
1767
1785
  });
1768
1786
  }
1769
1787
 
@@ -2512,211 +2530,841 @@ function loadConfiguration(t, root, config, lang) {
2512
2530
  }
2513
2531
  }
2514
2532
  },
2515
- TableClientRelations: {
2533
+ TableTaskStatusVersioning: {
2516
2534
  type: 'Table',
2517
2535
  canRefresh: true,
2518
- title: t('backoffice.table.clientrelations.title'),
2536
+ title: t('backoffice.table.taskstatusversioning.title.taskstatusversioninglist'),
2519
2537
  columns: [{
2520
- title: t('backoffice.table.clientrelations.columns.name'),
2521
- field: 'name',
2522
- defaultSortOrder: 'ascend',
2523
- sorter: 1,
2538
+ title: 'ID',
2539
+ field: '_id',
2540
+ sorter: 2,
2524
2541
  filter: 'search',
2525
2542
  width: 200
2526
2543
  }, {
2527
- title: t('backoffice.table.clientrelations.columns.nameSource'),
2528
- field: 'nameSource',
2529
- sorter: 1,
2544
+ title: t('backoffice.table.taskstatusversioning.columns.model'),
2545
+ field: 'taskName',
2546
+ sorter: 2,
2547
+ filter: 'search',
2548
+ width: 400
2549
+ }, {
2550
+ title: t('backoffice.table.taskstatusversioning.columns.organisationid'),
2551
+ field: 'organizationId',
2552
+ sorter: 200,
2530
2553
  filter: 'search',
2531
2554
  width: 200
2532
2555
  }, {
2533
- title: t('backoffice.table.clientrelations.columns.nameTarget'),
2534
- field: 'nameTarget',
2535
- sorter: 2,
2556
+ title: t('backoffice.table.taskstatusversioning.columns.organisation'),
2557
+ field: 'organizationDisplayName',
2558
+ sorter: 200,
2536
2559
  filter: 'search',
2537
2560
  width: 200
2538
2561
  }, {
2539
- title: t('backoffice.table.clientrelations.columns.externalCloudName'),
2540
- field: 'externalCloudName',
2562
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2563
+ field: 'user.mainEmail',
2541
2564
  sorter: 3,
2542
2565
  filter: 'search',
2543
2566
  width: 200
2544
2567
  }, {
2545
- title: t('backoffice.table.clientrelations.columns.state'),
2546
- field: 'state',
2547
- sorter: 4,
2568
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2569
+ field: 'cancelledByUser.mainEmail',
2570
+ sorter: 3,
2548
2571
  filter: 'search',
2549
- width: 100
2550
- }, {
2551
- title: t('backoffice.table.clientrelations.columns.created'),
2552
- field: 'created',
2553
- sorter: 5,
2554
2572
  width: 200,
2555
- type: 'unixTimeStamp'
2573
+ hidden: true
2556
2574
  }, {
2557
- title: t('backoffice.table.clientrelations.columns.lastUpdated'),
2558
- field: 'lastUpdated',
2559
- sorter: 6,
2560
- width: 200,
2561
- type: 'unixTimeStamp'
2575
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2576
+ field: 'progress.status',
2577
+ filter: 'search',
2578
+ width: 200
2562
2579
  }, {
2563
- title: 'ID',
2564
- field: '_id',
2565
- sorter: 7,
2566
- width: 50,
2580
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2581
+ field: 'progress.step',
2582
+ filter: 'search',
2583
+ width: 200,
2567
2584
  hidden: true
2568
2585
  }, {
2569
- title: t('backoffice.table.clientrelations.columns.externalCloudId'),
2570
- field: 'externalCloudId',
2571
- sorter: 8,
2572
- width: 50,
2586
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2587
+ field: 'progress.percentage',
2588
+ filter: 'search',
2589
+ width: 200,
2573
2590
  hidden: true
2574
2591
  }, {
2575
- title: t('backoffice.table.clientrelations.columns.type'),
2576
- field: 'type',
2577
- sorter: 9,
2578
- width: 50,
2592
+ title: t('backoffice.table.taskstatusversioning.columns.created'),
2593
+ field: 'created',
2594
+ sorter: 1,
2595
+ defaultSortOrder: 'descend',
2596
+ type: 'unixTimeStamp',
2597
+ width: 200
2598
+ }, {
2599
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
2600
+ field: 'lastUpdated',
2601
+ type: 'unixTimeStamp',
2602
+ width: 200
2603
+ }, {
2604
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
2605
+ field: 'startTime',
2606
+ type: 'unixTimeStamp',
2607
+ width: 200,
2579
2608
  hidden: true
2609
+ }, {
2610
+ title: t('backoffice.table.taskstatusversioning.columns.finished'),
2611
+ field: 'endTime',
2612
+ type: 'unixTimeStamp',
2613
+ width: 200
2614
+ }, {
2615
+ title: t('backoffice.table.taskstatusversioning.columns.server'),
2616
+ field: 'serverName',
2617
+ filter: 'search',
2618
+ width: 200
2619
+ }, {
2620
+ title: t('backoffice.table.taskstatusversioning.columns.type'),
2621
+ field: 'taskType',
2622
+ filter: 'search',
2623
+ width: 200
2580
2624
  }],
2625
+ filter: {
2626
+ toggle: {
2627
+ globalValue: 'relevantTypeOrganizationId',
2628
+ fields: ['organizationId'],
2629
+ label: t('backoffice.table.taskstatusversioning.filter.label.allorgs'),
2630
+ labelOff: t('backoffice.table.taskstatusversioning.filter.labelOff.allorgs'),
2631
+ inverted: true,
2632
+ permission: 'backoffice_taskstatus_allorgs',
2633
+ isAnd: true
2634
+ },
2635
+ search: {
2636
+ fields: ['_id', 'progress.dataItems', 'taskName', 'organizationId', 'user.mainEmail', 'status', 'serverName', 'taskType']
2637
+ }
2638
+ },
2581
2639
  apiInterface: {
2582
2640
  read: {
2583
- list: '${authService}/clientrelations',
2641
+ list: '${adminService}/taskStatus?filter=%5B%2B%5B%7BtaskType%2Ceq%2CRETAIL_VERSIONING%7D%2C%7BtaskType%2Ceq%2CSUPPLIER_VERSIONING%7D%5D%5D',
2642
+ fields: true,
2584
2643
  filterServerSide: true
2585
2644
  },
2586
- "delete": {
2587
- url: '${authService}/clientrelation/${_id}/type/${type}',
2588
- applyIdField: false
2589
- }
2590
- },
2591
- onError: {
2592
- AUTH_0030: t('errorcodes._source.labels.error.AUTH_0030'),
2593
- AUTH_0031: t('errorcodes._source.labels.error.AUTH_0031')
2594
- },
2595
- deleteMapping: {
2596
- type: 'query',
2597
- map: [{
2598
- sourceField: '_id',
2599
- targetField: '_id'
2600
- }, {
2601
- targetField: 'type',
2602
- sourceField: 'type'
2603
- }]
2604
- },
2605
- createAction: {
2606
- actionType: 'Detail',
2607
- label: t('backoffice.table.clientrelations.createAction.label.createnewclientrelation'),
2608
- title: t('backoffice.table.clientrelations.createAction.title.ewclientrelation'),
2609
- id: 'FromCreateClientRelation',
2610
- type: 'Form',
2611
- apiInterface: {
2612
- create: '${authService}/clientrelations'
2613
- }
2645
+ "delete": '${adminService}/taskStatus?id=${id}'
2614
2646
  },
2615
2647
  mapping: {
2616
2648
  type: 'query',
2617
2649
  map: [{
2618
- sourceField: 'nameSource',
2619
- targetField: 'nameSource'
2620
- }, {
2621
- sourceField: 'nameTarget',
2622
- targetField: 'nameTarget'
2650
+ globalValue: 'selectedOrganizationId',
2651
+ targetField: 'organizationId'
2623
2652
  }]
2624
2653
  },
2625
- filter: {
2626
- toggle: {
2627
- globalValue: 'relevantTypeOrganizationId',
2628
- fields: ['sourceOrganizationId', 'targetOrganizationId'],
2629
- label: t('backoffice.table.clientrelations.filter.label.allorgs'),
2630
- labelOff: t('backoffice.table.clientrelations.filter.labelOff.allorgs'),
2631
- inverted: true
2632
- },
2633
- search: {
2634
- fields: ['nameSource', 'nameTarget', 'externalCloudName', 'state', 'name']
2654
+ deleteAction: {
2655
+ label: 'backoffice.table.taskstatusversioning.deleteAction.label.cancel',
2656
+ labelDialog: 'backoffice.table.taskstatusversioning.deleteAction.labelDialog.cancel',
2657
+ disabled: function disabled(datas) {
2658
+ return datas === null || datas === void 0 ? void 0 : datas.find(function (d) {
2659
+ return (d === null || d === void 0 ? void 0 : d.progress.status) != 'Created';
2660
+ });
2635
2661
  }
2636
2662
  },
2637
2663
  rowAction: [{
2638
2664
  actionType: 'Detail',
2639
2665
  type: 'Form',
2640
- id: 'FormOrganizationDetailes',
2641
- title: t('backoffice.edit')
2642
- }]
2643
- },
2644
- FormOrganizationDetailes: {
2645
- type: 'Form',
2646
- title: t('backoffice.form.createclientrelation.title'),
2647
- apiInterface: {
2648
- update: {
2649
- url: '${authService}/clientrelation/{_id}/type/{type}',
2650
- method: 'PATCH',
2651
- jsonPatch: true
2652
- }
2653
- },
2654
- triggerRerender: true,
2655
- items: [{
2656
- name: 'name',
2657
- label: t('backoffice.form.createclientrelation.name'),
2658
- type: 'input',
2659
- required: true
2660
- }, {
2661
- label: t('backoffice.form.createclientrelation.aktivate'),
2662
- name: 'state',
2663
- type: 'radio',
2664
- optionType: 'button',
2665
- options: [{
2666
- label: 'INACTIVE',
2667
- value: 'INACTIVE'
2668
- }, {
2669
- label: 'ACTIVE',
2670
- value: 'ACTIVE'
2671
- }],
2672
- required: false
2666
+ id: 'FormTaskStatusDetails',
2667
+ title: t('backoffice.table.taskstatusversioning.rowAction.title')
2673
2668
  }]
2674
2669
  },
2675
- TableExternalClouds: {
2670
+ TableTaskStatusCustom: {
2676
2671
  type: 'Table',
2677
2672
  canRefresh: true,
2678
- title: t('backoffice.table.externalclouds.title.listexternalclouds'),
2673
+ title: t('backoffice.table.taskstatusversioning.title.taskstatuscustom'),
2679
2674
  columns: [{
2680
- title: t('backoffice.table.externalclouds.title.listexternalclouds'),
2681
- field: 'name',
2682
- sorter: 1,
2675
+ title: 'ID',
2676
+ field: '_id',
2677
+ sorter: 2,
2683
2678
  filter: 'search',
2684
2679
  width: 200
2685
2680
  }, {
2686
- title: 'Base URL',
2687
- field: 'url',
2681
+ title: t('backoffice.table.taskstatusversioning.columns.taskname'),
2682
+ field: 'taskName',
2688
2683
  sorter: 2,
2689
2684
  filter: 'search',
2685
+ width: 400
2686
+ }, {
2687
+ title: t('backoffice.table.taskstatusversioning.columns.organisationid'),
2688
+ field: 'organizationId',
2689
+ sorter: 200,
2690
+ filter: 'search',
2690
2691
  width: 200
2691
2692
  }, {
2692
- title: t('backoffice.table.externalclouds.columns.created'),
2693
+ title: t('backoffice.table.taskstatusversioning.columns.organisation'),
2694
+ field: 'organizationDisplayName',
2695
+ sorter: 200,
2696
+ filter: 'search',
2697
+ width: 200
2698
+ }, {
2699
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2700
+ field: 'user.mainEmail',
2701
+ sorter: 3,
2702
+ filter: 'search',
2703
+ width: 200
2704
+ }, {
2705
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2706
+ field: 'cancelledByUser.mainEmail',
2707
+ sorter: 3,
2708
+ filter: 'search',
2709
+ width: 200,
2710
+ hidden: true
2711
+ }, {
2712
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2713
+ field: 'progress.status',
2714
+ filter: 'search',
2715
+ width: 200
2716
+ }, {
2717
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2718
+ field: 'progress.step',
2719
+ filter: 'search',
2720
+ width: 200,
2721
+ hidden: true
2722
+ }, {
2723
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2724
+ field: 'progress.percentage',
2725
+ filter: 'search',
2726
+ width: 200,
2727
+ hidden: true
2728
+ }, {
2729
+ title: t('backoffice.table.taskstatusversioning.columns.created'),
2693
2730
  field: 'created',
2731
+ sorter: 1,
2732
+ defaultSortOrder: 'descend',
2694
2733
  type: 'unixTimeStamp',
2695
- sorter: 8
2734
+ width: 200
2735
+ }, {
2736
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
2737
+ field: 'lastUpdated',
2738
+ type: 'unixTimeStamp',
2739
+ width: 200
2740
+ }, {
2741
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
2742
+ field: 'startTime',
2743
+ type: 'unixTimeStamp',
2744
+ width: 200,
2745
+ hidden: true
2746
+ }, {
2747
+ title: t('backoffice.table.taskstatusversioning.columns.finished'),
2748
+ field: 'endTime',
2749
+ type: 'unixTimeStamp',
2750
+ width: 200
2751
+ }, {
2752
+ title: t('backoffice.table.taskstatusversioning.columns.server'),
2753
+ field: 'serverName',
2754
+ filter: 'search',
2755
+ width: 200
2756
+ }, {
2757
+ title: t('backoffice.table.taskstatusversioning.columns.type'),
2758
+ field: 'taskType',
2759
+ filter: 'search',
2760
+ width: 200
2696
2761
  }],
2697
2762
  filter: {
2763
+ toggle: {
2764
+ globalValue: 'relevantTypeOrganizationId',
2765
+ fields: ['organizationId'],
2766
+ label: t('backoffice.table.taskstatusversioning.filter.label.allorgs'),
2767
+ labelOff: t('backoffice.table.taskstatusversioning.filter.labelOff.allorgs'),
2768
+ inverted: true,
2769
+ permission: 'backoffice_taskstatus_allorgs',
2770
+ isAnd: true
2771
+ },
2698
2772
  search: {
2699
- fields: ['_id', 'name', 'url', 'iln']
2773
+ fields: ['_id', 'progress.dataItems', 'taskName', 'organizationId', 'user.mainEmail', 'status', 'serverName', 'taskType']
2700
2774
  }
2701
2775
  },
2702
2776
  apiInterface: {
2703
2777
  read: {
2704
- list: '${authService}/externalclouds',
2778
+ list: '${adminService}/taskStatus?filter=%5B%2B%5B%7BtaskType%2Ceq%2CSAP_XML_IMPORT%7D%2C%7BtaskType%2Ceq%2CSAP_DROPDOWNITEMS%7D%2C%7BtaskType%2Ceq%2CSAP_TEMPLATEARTICLES%7D%2C%7BtaskType%2Ceq%2CSAP_ARTICLE_IMPORT%7D%2C%7BtaskType%2Ceq%2CSAP_SUPPLIERS%7D%2C%7BtaskType%2Ceq%2CSAP_PRODUCTGROUPS%7D%2C%7BtaskType%2Ceq%2CSAP_AUSP%7D%2C%7BtaskType%2Ceq%2CPIM_SEND_CLASSIFICATION%7D%2C%7BtaskType%2Ceq%2CSEND_SAP_ARTICLES%7D%5D%5D',
2779
+ fields: true,
2705
2780
  filterServerSide: true
2706
2781
  },
2707
- "delete": '${authService}/externalclouds/${id}'
2782
+ "delete": '${adminService}/taskStatus?id=${id}'
2708
2783
  },
2709
- rowAction: [{
2710
- actionType: 'Detail',
2711
- type: 'Form',
2712
- id: 'FormExternalCloudDetail',
2713
- title: t('backoffice.table.externalclouds.rowAction.title.externalcloud'),
2714
- width: '40%',
2715
- footer: true
2716
- }],
2717
- createAction: {
2718
- actionType: 'Detail',
2719
- label: t('backoffice.table.externalclouds.createaction.title.externalcloud'),
2784
+ mapping: {
2785
+ type: 'query',
2786
+ map: [{
2787
+ globalValue: 'selectedOrganizationId',
2788
+ targetField: 'organizationId'
2789
+ }]
2790
+ },
2791
+ deleteAction: {
2792
+ label: 'backoffice.table.taskstatusversioning.deleteAction.label.cancel',
2793
+ labelDialog: 'backoffice.table.taskstatusversioning.deleteAction.labelDialog.cancel',
2794
+ disabled: function disabled(datas) {
2795
+ return datas === null || datas === void 0 ? void 0 : datas.find(function (d) {
2796
+ return (d === null || d === void 0 ? void 0 : d.progress.status) != 'Created';
2797
+ });
2798
+ }
2799
+ },
2800
+ rowAction: [{
2801
+ actionType: 'Detail',
2802
+ type: 'Form',
2803
+ id: 'FormTaskStatusDetails',
2804
+ title: t('backoffice.table.taskstatusversioning.rowAction.title')
2805
+ }]
2806
+ },
2807
+ TableTaskStatusCronJobs: {
2808
+ type: 'Table',
2809
+ canRefresh: true,
2810
+ title: t('backoffice.table.taskstatusversioning.title.taskstatusversioninglist'),
2811
+ columns: [{
2812
+ title: 'ID',
2813
+ field: '_id',
2814
+ sorter: 2,
2815
+ filter: 'search',
2816
+ width: 200
2817
+ }, {
2818
+ title: t('backoffice.table.taskstatusversioning.columns.taskname'),
2819
+ field: 'taskName',
2820
+ sorter: 2,
2821
+ filter: 'search',
2822
+ width: 400
2823
+ }, {
2824
+ title: t('backoffice.table.taskstatusversioning.columns.organisationid'),
2825
+ field: 'organizationId',
2826
+ sorter: 200,
2827
+ filter: 'search',
2828
+ width: 200
2829
+ }, {
2830
+ title: t('backoffice.table.taskstatusversioning.columns.organisation'),
2831
+ field: 'organizationDisplayName',
2832
+ sorter: 200,
2833
+ filter: 'search',
2834
+ width: 200
2835
+ }, {
2836
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2837
+ field: 'user.mainEmail',
2838
+ sorter: 3,
2839
+ filter: 'search',
2840
+ width: 200
2841
+ }, {
2842
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2843
+ field: 'cancelledByUser.mainEmail',
2844
+ sorter: 3,
2845
+ filter: 'search',
2846
+ width: 200,
2847
+ hidden: true
2848
+ }, {
2849
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2850
+ field: 'progress.status',
2851
+ filter: 'search',
2852
+ width: 200
2853
+ }, {
2854
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2855
+ field: 'progress.step',
2856
+ filter: 'search',
2857
+ width: 200,
2858
+ hidden: true
2859
+ }, {
2860
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2861
+ field: 'progress.percentage',
2862
+ filter: 'search',
2863
+ width: 200,
2864
+ hidden: true
2865
+ }, {
2866
+ title: t('backoffice.table.taskstatusversioning.columns.created'),
2867
+ field: 'created',
2868
+ sorter: 1,
2869
+ defaultSortOrder: 'descend',
2870
+ type: 'unixTimeStamp',
2871
+ width: 200
2872
+ }, {
2873
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
2874
+ field: 'lastUpdated',
2875
+ type: 'unixTimeStamp',
2876
+ width: 200
2877
+ }, {
2878
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
2879
+ field: 'startTime',
2880
+ type: 'unixTimeStamp',
2881
+ width: 200,
2882
+ hidden: true
2883
+ }, {
2884
+ title: t('backoffice.table.taskstatusversioning.columns.finished'),
2885
+ field: 'endTime',
2886
+ type: 'unixTimeStamp',
2887
+ width: 200
2888
+ }, {
2889
+ title: t('backoffice.table.taskstatusversioning.columns.server'),
2890
+ field: 'serverName',
2891
+ filter: 'search',
2892
+ width: 200
2893
+ }, {
2894
+ title: t('backoffice.table.taskstatusversioning.columns.type'),
2895
+ field: 'taskType',
2896
+ filter: 'search',
2897
+ width: 200
2898
+ }],
2899
+ filter: {
2900
+ toggle: {
2901
+ globalValue: 'relevantTypeOrganizationId',
2902
+ fields: ['organizationId'],
2903
+ label: t('backoffice.table.taskstatusversioning.filter.label.allorgs'),
2904
+ labelOff: t('backoffice.table.taskstatusversioning.filter.labelOff.allorgs'),
2905
+ inverted: true,
2906
+ permission: 'backoffice_taskstatus_allorgs',
2907
+ isAnd: true
2908
+ },
2909
+ search: {
2910
+ fields: ['_id', 'progress.dataItems', 'taskName', 'organizationId', 'user.mainEmail', 'status', 'serverName', 'taskType']
2911
+ }
2912
+ },
2913
+ apiInterface: {
2914
+ read: {
2915
+ list: '${adminService}/taskStatus?filter=%5B%7BtaskType%2Ceq%2CCRON%7D%5D',
2916
+ fields: true,
2917
+ filterServerSide: true
2918
+ },
2919
+ "delete": '${adminService}/taskStatus?id=${id}'
2920
+ },
2921
+ mapping: {
2922
+ type: 'query',
2923
+ map: [{
2924
+ globalValue: 'selectedOrganizationId',
2925
+ targetField: 'organizationId'
2926
+ }]
2927
+ },
2928
+ deleteAction: {
2929
+ label: 'backoffice.table.taskstatusversioning.deleteAction.label.cancel',
2930
+ labelDialog: 'backoffice.table.taskstatusversioning.deleteAction.labelDialog.cancel',
2931
+ disabled: function disabled(datas) {
2932
+ return datas === null || datas === void 0 ? void 0 : datas.find(function (d) {
2933
+ return (d === null || d === void 0 ? void 0 : d.progress.status) != 'Created';
2934
+ });
2935
+ }
2936
+ },
2937
+ rowAction: [{
2938
+ actionType: 'Detail',
2939
+ type: 'Form',
2940
+ id: 'FormTaskStatusDetails',
2941
+ title: t('backoffice.table.taskstatusversioning.rowAction.title')
2942
+ }]
2943
+ },
2944
+ TableTaskStatusOthers: {
2945
+ type: 'Table',
2946
+ canRefresh: true,
2947
+ title: t('backoffice.table.taskstatusversioning.title.taskstatusothers'),
2948
+ columns: [{
2949
+ title: 'ID',
2950
+ field: '_id',
2951
+ sorter: 2,
2952
+ filter: 'search',
2953
+ width: 200
2954
+ }, {
2955
+ title: t('backoffice.table.taskstatusversioning.columns.taskname'),
2956
+ field: 'taskName',
2957
+ sorter: 2,
2958
+ filter: 'search',
2959
+ width: 400
2960
+ }, {
2961
+ title: t('backoffice.table.taskstatusversioning.columns.organisationid'),
2962
+ field: 'organizationId',
2963
+ sorter: 200,
2964
+ filter: 'search',
2965
+ width: 200
2966
+ }, {
2967
+ title: t('backoffice.table.taskstatusversioning.columns.organisation'),
2968
+ field: 'organizationDisplayName',
2969
+ sorter: 200,
2970
+ filter: 'search',
2971
+ width: 200
2972
+ }, {
2973
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2974
+ field: 'user.mainEmail',
2975
+ sorter: 3,
2976
+ filter: 'search',
2977
+ width: 200
2978
+ }, {
2979
+ title: t('backoffice.table.taskstatusversioning.columns.user'),
2980
+ field: 'cancelledByUser.mainEmail',
2981
+ sorter: 3,
2982
+ filter: 'search',
2983
+ width: 200,
2984
+ hidden: true
2985
+ }, {
2986
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2987
+ field: 'progress.status',
2988
+ filter: 'search',
2989
+ width: 200
2990
+ }, {
2991
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2992
+ field: 'progress.step',
2993
+ filter: 'search',
2994
+ width: 200,
2995
+ hidden: true
2996
+ }, {
2997
+ title: t('backoffice.table.taskstatusversioning.columns.status'),
2998
+ field: 'progress.percentage',
2999
+ filter: 'search',
3000
+ width: 200,
3001
+ hidden: true
3002
+ }, {
3003
+ title: t('backoffice.table.taskstatusversioning.columns.created'),
3004
+ field: 'created',
3005
+ sorter: 1,
3006
+ defaultSortOrder: 'descend',
3007
+ type: 'unixTimeStamp',
3008
+ width: 200
3009
+ }, {
3010
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
3011
+ field: 'lastUpdated',
3012
+ type: 'unixTimeStamp',
3013
+ width: 200
3014
+ }, {
3015
+ title: t('backoffice.table.taskstatusversioning.columns.lastUpdated'),
3016
+ field: 'startTime',
3017
+ type: 'unixTimeStamp',
3018
+ width: 200,
3019
+ hidden: true
3020
+ }, {
3021
+ title: t('backoffice.table.taskstatusversioning.columns.finished'),
3022
+ field: 'endTime',
3023
+ type: 'unixTimeStamp',
3024
+ width: 200
3025
+ }, {
3026
+ title: t('backoffice.table.taskstatusversioning.columns.server'),
3027
+ field: 'serverName',
3028
+ filter: 'search',
3029
+ width: 200
3030
+ }, {
3031
+ title: t('backoffice.table.taskstatusversioning.columns.type'),
3032
+ field: 'taskType',
3033
+ filter: 'search',
3034
+ width: 200
3035
+ }],
3036
+ filter: {
3037
+ toggle: {
3038
+ globalValue: 'relevantTypeOrganizationId',
3039
+ fields: ['organizationId'],
3040
+ label: t('backoffice.table.taskstatusversioning.filter.label.allorgs'),
3041
+ labelOff: t('backoffice.table.taskstatusversioning.filter.labelOff.allorgs'),
3042
+ inverted: true,
3043
+ permission: 'backoffice_taskstatus_allorgs',
3044
+ isAnd: true
3045
+ },
3046
+ search: {
3047
+ fields: ['_id', 'progress.dataItems', 'taskName', 'organizationId', 'user.mainEmail', 'status', 'serverName', 'taskType']
3048
+ }
3049
+ },
3050
+ apiInterface: {
3051
+ read: {
3052
+ list: '${adminService}/taskStatus?filter=%5B%7BtaskType%2Cne%2CSAP_XML_IMPORT%7D%2C%7BtaskType%2Cne%2CSAP_DROPDOWNITEMS%7D%2C%7BtaskType%2Cne%2CSAP_TEMPLATEARTICLES%7D%2C%7BtaskType%2Cne%2CSAP_ARTICLE_IMPORT%7D%2C%7BtaskType%2Cne%2CSAP_SUPPLIERS%7D%2C%7BtaskType%2Cne%2CSAP_PRODUCTGROUPS%7D%2C%7BtaskType%2Cne%2CSAP_AUSP%7D%2C%7BtaskType%2Cne%2CPIM_SEND_CLASSIFICATION%7D%2C%7BtaskType%2Cne%2CSEND_SAP_ARTICLES%7D%2C%7BtaskType%2Cne%2CCRON%7D%2C%7BtaskType%2Cne%2CRETAIL_VERSIONING%7D%2C%7BtaskType%2Cne%2CSUPPLIER_VERSIONING%7D%2C%7BtaskType%2Cne%2CBACKOFFICE_CE_EXPORT%7D%2C%7BtaskType%2Cne%2CBACKOFFICE_CE_IMPORT%7D%5D',
3053
+ fields: true,
3054
+ filterServerSide: true
3055
+ },
3056
+ "delete": '${adminService}/taskStatus?id=${id}'
3057
+ },
3058
+ mapping: {
3059
+ type: 'query',
3060
+ map: [{
3061
+ globalValue: 'selectedOrganizationId',
3062
+ targetField: 'organizationId'
3063
+ }]
3064
+ },
3065
+ deleteAction: {
3066
+ label: 'backoffice.table.taskstatusversioning.deleteAction.label.cancel',
3067
+ labelDialog: 'backoffice.table.taskstatusversioning.deleteAction.labelDialog.cancel',
3068
+ disabled: function disabled(datas) {
3069
+ return datas === null || datas === void 0 ? void 0 : datas.find(function (d) {
3070
+ return (d === null || d === void 0 ? void 0 : d.progress.status) != 'Created';
3071
+ });
3072
+ }
3073
+ },
3074
+ rowAction: [{
3075
+ actionType: 'Detail',
3076
+ type: 'Form',
3077
+ id: 'FormTaskStatusDetails',
3078
+ title: t('backoffice.table.taskstatusversioning.rowAction.title')
3079
+ }]
3080
+ },
3081
+ FormTaskStatusDetails: {
3082
+ type: 'Form',
3083
+ title: t('backoffice.form.taskstatus.title'),
3084
+ triggerRerender: true,
3085
+ disableSave: true,
3086
+ items: [{
3087
+ name: '_id',
3088
+ label: t('backoffice.form.taskstatus._id'),
3089
+ type: 'input',
3090
+ readonly: true
3091
+ }, {
3092
+ name: 'taskName',
3093
+ label: t('backoffice.form.taskstatus.taskName'),
3094
+ type: 'input',
3095
+ readonly: true
3096
+ }, {
3097
+ name: 'created',
3098
+ label: t('backoffice.form.taskstatus.created'),
3099
+ type: 'dateinput',
3100
+ disabled: true
3101
+ }, {
3102
+ name: 'startTime',
3103
+ label: t('backoffice.form.taskstatus.startTime'),
3104
+ type: 'dateinput',
3105
+ readonly: true
3106
+ }, {
3107
+ name: 'endTime',
3108
+ label: t('backoffice.form.taskstatus.endTime'),
3109
+ type: 'dateinput',
3110
+ readonly: true
3111
+ }, {
3112
+ name: 'lastUpdated',
3113
+ label: t('backoffice.form.taskstatus.lastUpdated'),
3114
+ type: 'dateinput',
3115
+ readonly: true
3116
+ }, {
3117
+ name: ['user', 'mainEmail'],
3118
+ label: t('backoffice.form.taskstatus.user'),
3119
+ type: 'input',
3120
+ readonly: true
3121
+ }, {
3122
+ name: 'organizationDisplayName',
3123
+ label: t('backoffice.form.taskstatus.organizationDisplayName'),
3124
+ type: 'input',
3125
+ readonly: true
3126
+ }, {
3127
+ name: 'taskType',
3128
+ label: t('backoffice.form.taskstatus.taskType'),
3129
+ type: 'input',
3130
+ readonly: true
3131
+ }, {
3132
+ label: t('backoffice.form.taskstatus.progress.status'),
3133
+ name: ['progress', 'status'],
3134
+ type: 'input',
3135
+ readonly: true
3136
+ }, {
3137
+ name: ['progress', 'percentage'],
3138
+ label: t('backoffice.form.taskstatus.progress.percentage'),
3139
+ type: 'progress',
3140
+ readonly: true
3141
+ }, {
3142
+ name: ['progress', 'step'],
3143
+ label: t('backoffice.form.taskstatus.progress.step'),
3144
+ type: 'input',
3145
+ readonly: true
3146
+ }, {
3147
+ name: ['cancelledByUser', 'mainEmail'],
3148
+ label: t('backoffice.form.taskstatus.cancelledByUser.mainEmail'),
3149
+ type: 'input',
3150
+ readonly: true
3151
+ }, {
3152
+ name: 'error',
3153
+ label: t('backoffice.form.taskstatus.error'),
3154
+ type: 'input',
3155
+ readonly: true
3156
+ }, {
3157
+ name: 'warning',
3158
+ label: t('backoffice.form.taskstatus.warning'),
3159
+ type: 'input',
3160
+ readonly: true
3161
+ }]
3162
+ },
3163
+ TableClientRelations: {
3164
+ type: 'Table',
3165
+ canRefresh: true,
3166
+ title: t('backoffice.table.clientrelations.title'),
3167
+ columns: [{
3168
+ title: t('backoffice.table.clientrelations.columns.name'),
3169
+ field: 'name',
3170
+ defaultSortOrder: 'ascend',
3171
+ sorter: 1,
3172
+ filter: 'search',
3173
+ width: 200
3174
+ }, {
3175
+ title: t('backoffice.table.clientrelations.columns.nameSource'),
3176
+ field: 'nameSource',
3177
+ sorter: 1,
3178
+ filter: 'search',
3179
+ width: 200
3180
+ }, {
3181
+ title: t('backoffice.table.clientrelations.columns.nameTarget'),
3182
+ field: 'nameTarget',
3183
+ sorter: 2,
3184
+ filter: 'search',
3185
+ width: 200
3186
+ }, {
3187
+ title: t('backoffice.table.clientrelations.columns.externalCloudName'),
3188
+ field: 'externalCloudName',
3189
+ sorter: 3,
3190
+ filter: 'search',
3191
+ width: 200
3192
+ }, {
3193
+ title: t('backoffice.table.clientrelations.columns.state'),
3194
+ field: 'state',
3195
+ sorter: 4,
3196
+ filter: 'search',
3197
+ width: 100
3198
+ }, {
3199
+ title: t('backoffice.table.clientrelations.columns.created'),
3200
+ field: 'created',
3201
+ sorter: 5,
3202
+ width: 200,
3203
+ type: 'unixTimeStamp'
3204
+ }, {
3205
+ title: t('backoffice.table.clientrelations.columns.lastUpdated'),
3206
+ field: 'lastUpdated',
3207
+ sorter: 6,
3208
+ width: 200,
3209
+ type: 'unixTimeStamp'
3210
+ }, {
3211
+ title: 'ID',
3212
+ field: '_id',
3213
+ sorter: 7,
3214
+ width: 50,
3215
+ hidden: true
3216
+ }, {
3217
+ title: t('backoffice.table.clientrelations.columns.externalCloudId'),
3218
+ field: 'externalCloudId',
3219
+ sorter: 8,
3220
+ width: 50,
3221
+ hidden: true
3222
+ }, {
3223
+ title: t('backoffice.table.clientrelations.columns.type'),
3224
+ field: 'type',
3225
+ sorter: 9,
3226
+ width: 50,
3227
+ hidden: true
3228
+ }],
3229
+ apiInterface: {
3230
+ read: {
3231
+ list: '${authService}/clientrelations',
3232
+ filterServerSide: true
3233
+ },
3234
+ "delete": {
3235
+ url: '${authService}/clientrelation/${_id}/type/${type}',
3236
+ applyIdField: false
3237
+ }
3238
+ },
3239
+ onError: {
3240
+ AUTH_0030: t('errorcodes._source.labels.error.AUTH_0030'),
3241
+ AUTH_0031: t('errorcodes._source.labels.error.AUTH_0031')
3242
+ },
3243
+ deleteMapping: {
3244
+ type: 'query',
3245
+ map: [{
3246
+ sourceField: '_id',
3247
+ targetField: '_id'
3248
+ }, {
3249
+ targetField: 'type',
3250
+ sourceField: 'type'
3251
+ }]
3252
+ },
3253
+ createAction: {
3254
+ actionType: 'Detail',
3255
+ label: t('backoffice.table.clientrelations.createAction.label.createnewclientrelation'),
3256
+ title: t('backoffice.table.clientrelations.createAction.title.ewclientrelation'),
3257
+ id: 'FromCreateClientRelation',
3258
+ type: 'Form',
3259
+ apiInterface: {
3260
+ create: '${authService}/clientrelations'
3261
+ }
3262
+ },
3263
+ mapping: {
3264
+ type: 'query',
3265
+ map: [{
3266
+ sourceField: 'nameSource',
3267
+ targetField: 'nameSource'
3268
+ }, {
3269
+ sourceField: 'nameTarget',
3270
+ targetField: 'nameTarget'
3271
+ }]
3272
+ },
3273
+ filter: {
3274
+ toggle: {
3275
+ globalValue: 'relevantTypeOrganizationId',
3276
+ fields: ['sourceOrganizationId', 'targetOrganizationId'],
3277
+ label: t('backoffice.table.clientrelations.filter.label.allorgs'),
3278
+ labelOff: t('backoffice.table.clientrelations.filter.labelOff.allorgs'),
3279
+ inverted: true
3280
+ },
3281
+ search: {
3282
+ fields: ['nameSource', 'nameTarget', 'externalCloudName', 'state', 'name']
3283
+ }
3284
+ },
3285
+ rowAction: [{
3286
+ actionType: 'Detail',
3287
+ type: 'Form',
3288
+ id: 'FormClientRelationDetails',
3289
+ title: t('backoffice.edit')
3290
+ }]
3291
+ },
3292
+ FormClientRelationDetails: {
3293
+ type: 'Form',
3294
+ title: t('backoffice.form.createclientrelation.title'),
3295
+ apiInterface: {
3296
+ update: {
3297
+ url: '${authService}/clientrelation/{_id}/type/{type}',
3298
+ method: 'PATCH',
3299
+ jsonPatch: true
3300
+ }
3301
+ },
3302
+ triggerRerender: true,
3303
+ items: [{
3304
+ name: 'name',
3305
+ label: t('backoffice.form.createclientrelation.name'),
3306
+ type: 'input',
3307
+ required: true
3308
+ }, {
3309
+ label: t('backoffice.form.createclientrelation.aktivate'),
3310
+ name: 'state',
3311
+ type: 'radio',
3312
+ optionType: 'button',
3313
+ options: [{
3314
+ label: 'INACTIVE',
3315
+ value: 'INACTIVE'
3316
+ }, {
3317
+ label: 'ACTIVE',
3318
+ value: 'ACTIVE'
3319
+ }],
3320
+ required: false
3321
+ }]
3322
+ },
3323
+ TableExternalClouds: {
3324
+ type: 'Table',
3325
+ canRefresh: true,
3326
+ title: t('backoffice.table.externalclouds.title.listexternalclouds'),
3327
+ columns: [{
3328
+ title: t('backoffice.table.externalclouds.title.listexternalclouds'),
3329
+ field: 'name',
3330
+ sorter: 1,
3331
+ filter: 'search',
3332
+ width: 200
3333
+ }, {
3334
+ title: 'Base URL',
3335
+ field: 'url',
3336
+ sorter: 2,
3337
+ filter: 'search',
3338
+ width: 200
3339
+ }, {
3340
+ title: t('backoffice.table.externalclouds.columns.created'),
3341
+ field: 'created',
3342
+ type: 'unixTimeStamp',
3343
+ sorter: 8
3344
+ }],
3345
+ filter: {
3346
+ search: {
3347
+ fields: ['_id', 'name', 'url', 'iln']
3348
+ }
3349
+ },
3350
+ apiInterface: {
3351
+ read: {
3352
+ list: '${authService}/externalclouds',
3353
+ filterServerSide: true
3354
+ },
3355
+ "delete": '${authService}/externalclouds/${id}'
3356
+ },
3357
+ rowAction: [{
3358
+ actionType: 'Detail',
3359
+ type: 'Form',
3360
+ id: 'FormExternalCloudDetail',
3361
+ title: t('backoffice.table.externalclouds.rowAction.title.externalcloud'),
3362
+ width: '40%',
3363
+ footer: true
3364
+ }],
3365
+ createAction: {
3366
+ actionType: 'Detail',
3367
+ label: t('backoffice.table.externalclouds.createaction.title.externalcloud'),
2720
3368
  id: 'FormExternalCloudDetail',
2721
3369
  type: 'Form',
2722
3370
  apiInterface: {
@@ -3121,162 +3769,50 @@ function loadConfiguration(t, root, config, lang) {
3121
3769
  sourceField: 'sessionGuID',
3122
3770
  targetField: 'sessionGuID'
3123
3771
  }, {
3124
- sourceField: 'newData',
3125
- targetField: 'newData'
3126
- }]
3127
- },
3128
- downloadAction: {
3129
- actionType: 'Download',
3130
- id: 'DownloadAction',
3131
- rule: [{
3132
- match: {
3133
- sourceField: 'catalogItem',
3134
- value: undefined
3135
- }
3136
- }],
3137
- download: [{
3138
- type: 'prefab',
3139
- prefab: 'connectionFileRetail',
3140
- url: 'https://gwc-app-p-app-api3.azurewebsites.net/odataretail'
3141
- }, {
3142
- type: 'url',
3143
- url: 'https://cdn.diva-portal.com/static/xlsx/RETAIL-p.xlsx'
3144
- }]
3145
- }
3146
- },
3147
- GroupContentItems: {
3148
- type: 'Group',
3149
- items: [{
3150
- id: 'ContentItems',
3151
- type: 'Table'
3152
- }, {
3153
- id: 'ContentItemsTemplate',
3154
- type: 'Table'
3155
- }],
3156
- setSelectedOrganization: true
3157
- },
3158
- ContentItems: {
3159
- title: t('backoffice.table.contentitems.title'),
3160
- type: 'Table',
3161
- canRefresh: true,
3162
- pagination: {
3163
- pageSize: 50
3164
- },
3165
- copyAction: {
3166
- actionType: 'Detail',
3167
- type: 'Form',
3168
- id: 'FormEditContentItem',
3169
- title: t('backoffice.table.contentItem.copyAction.title'),
3170
- label: t('backoffice.table.services.copyAction.label'),
3171
- disableOnMultiselect: true,
3172
- mapping: {
3173
- type: 'body',
3174
- map: [{
3175
- targetField: 'content',
3176
- sourceField: 'content'
3177
- }, {
3178
- targetField: 'description',
3179
- sourceField: 'description'
3180
- }, {
3181
- targetField: 'organizationId',
3182
- globalValue: 'organizationId'
3183
- }]
3184
- }
3185
- },
3186
- deleteAction: {
3187
- disabled: function disabled(datas) {
3188
- return (datas === null || datas === void 0 ? void 0 : datas.find(function (d) {
3189
- return !d.organizationId;
3190
- })) && !root.actions.userHasPermission('backoffice_delete_contentitem_template');
3191
- }
3192
- },
3193
- columns: [{
3194
- title: t('backoffice.table.roles.columns.description'),
3195
- field: 'description',
3196
- sorter: 1,
3197
- filter: 'advanced',
3198
- width: 500
3199
- }, {
3200
- title: t('backoffice.table.roles.columns.supplier'),
3201
- field: 'supplierName',
3202
- sorter: 1,
3203
- filter: 'advanced',
3204
- width: 150
3205
- }, {
3206
- title: t('backoffice.table.roles.columns.catalogName'),
3207
- field: 'catalogName',
3208
- sorter: 1,
3209
- filter: 'advanced',
3210
- width: 150
3211
- }, {
3212
- title: t('backoffice._id'),
3213
- field: '_id',
3214
- sorter: 1,
3215
- filter: 'advanced',
3216
- width: 100
3217
- }, {
3218
- title: t('backoffice.table.views.lastUpdated'),
3219
- field: 'lastUpdated',
3220
- type: 'unixTimeStamp',
3221
- sorter: 1,
3222
- filter: 'advanced',
3223
- width: 200
3224
- }, {
3225
- title: t('backoffice.table.views.lastUpdatedBy'),
3226
- field: 'lastUpdatedBy_displayText',
3227
- sorter: 1,
3228
- filter: 'advanced',
3229
- width: 150
3230
- }, {
3231
- title: 'backoffice.content',
3232
- field: 'content',
3233
- hidden: true
3234
- }, {
3235
- title: t('backoffice.table.medien.columns.title.organizationId'),
3236
- field: 'organizationId',
3237
- sorter: 1,
3238
- filter: 'advanced',
3239
- width: 150
3240
- }],
3241
- rowAction: [{
3242
- actionType: 'Detail',
3243
- disabled: function disabled(data) {
3244
- return !(data !== null && data !== void 0 && data.organizationId) && !root.actions.userHasPermission('backoffice_edit_contentitem_template');
3245
- },
3246
- disableOnMultiselect: true,
3247
- type: 'Form',
3248
- id: 'FormEditContentItem',
3249
- title: t('backoffice.table.contentItem.edit'),
3250
- label: t('backoffice.edit')
3251
- }, {
3252
- disableOnMultiselect: true,
3253
- actionType: 'Detail',
3254
- permission: 'backoffice_edit_contentitem_template',
3255
- type: 'JsonEditor',
3256
- label: t('backoffice.table.contentItem.editjson'),
3257
- id: 'JsonEditorEditContentItem',
3258
- title: t('backoffice.table.contentItem.edit')
3259
- }],
3260
- apiInterface: {
3261
- read: {
3262
- list: '${catalogService}/contentItems',
3263
- filterServerSide: true
3264
- },
3265
- "delete": '${catalogService}/contentItems/${id}'
3772
+ sourceField: 'newData',
3773
+ targetField: 'newData'
3774
+ }]
3775
+ },
3776
+ downloadAction: {
3777
+ actionType: 'Download',
3778
+ id: 'DownloadAction',
3779
+ rule: [{
3780
+ match: {
3781
+ sourceField: 'catalogItem',
3782
+ value: undefined
3783
+ }
3784
+ }],
3785
+ download: [{
3786
+ type: 'prefab',
3787
+ prefab: 'connectionFileRetail',
3788
+ url: 'https://gwc-app-p-app-api3.azurewebsites.net/odataretail'
3789
+ }, {
3790
+ type: 'url',
3791
+ url: 'https://cdn.diva-portal.com/static/xlsx/RETAIL-p.xlsx'
3792
+ }]
3266
3793
  }
3267
3794
  },
3268
- ContentItemsTemplate: {
3269
- title: t('backoffice.table.contentitemstemplate.title'),
3795
+ ContentItems: {
3796
+ title: t('backoffice.table.contentitems.title'),
3270
3797
  type: 'Table',
3271
3798
  canRefresh: true,
3272
3799
  pagination: {
3273
3800
  pageSize: 50
3274
3801
  },
3802
+ filter: {
3803
+ toggle: {
3804
+ fields: ['onlyTemplates'],
3805
+ label: t('backoffice.table.contentitemstemplate.title'),
3806
+ labelOff: t('backoffice.table.contentitems.toggleOff'),
3807
+ inQuery: true
3808
+ }
3809
+ },
3275
3810
  copyAction: {
3276
3811
  actionType: 'Detail',
3277
3812
  type: 'Form',
3278
3813
  id: 'FormEditContentItem',
3279
3814
  disableOnMultiselect: true,
3815
+ resetToggleAfter: true,
3280
3816
  title: t('backoffice.table.contentItem.copyAction.title'),
3281
3817
  label: t('backoffice.table.services.copyAction.label'),
3282
3818
  mapping: {
@@ -3284,6 +3820,12 @@ function loadConfiguration(t, root, config, lang) {
3284
3820
  map: [{
3285
3821
  targetField: 'content',
3286
3822
  sourceField: 'content'
3823
+ }, {
3824
+ targetField: 'catalogName',
3825
+ sourceField: 'catalogName'
3826
+ }, {
3827
+ targetField: 'supplierName',
3828
+ sourceField: 'supplierName'
3287
3829
  }, {
3288
3830
  targetField: 'description',
3289
3831
  sourceField: 'description'
@@ -3304,7 +3846,7 @@ function loadConfiguration(t, root, config, lang) {
3304
3846
  deleteAction: {
3305
3847
  disabled: function disabled(datas) {
3306
3848
  return (datas === null || datas === void 0 ? void 0 : datas.find(function (d) {
3307
- return !d.organizationId;
3849
+ return !(d !== null && d !== void 0 && d.organizationId);
3308
3850
  })) && !root.actions.userHasPermission('backoffice_delete_contentitem_template');
3309
3851
  }
3310
3852
  },
@@ -3315,28 +3857,47 @@ function loadConfiguration(t, root, config, lang) {
3315
3857
  filter: 'advanced',
3316
3858
  width: 500
3317
3859
  }, {
3318
- title: t('backoffice.table.views.lastUpdatedBy'),
3319
- field: 'lastUpdatedBy_displayText',
3860
+ title: t('backoffice.table.roles.columns.supplier'),
3861
+ field: 'supplierName',
3862
+ sorter: 1,
3863
+ filter: 'advanced',
3864
+ width: 150
3865
+ }, {
3866
+ title: t('backoffice.table.roles.columns.catalogName'),
3867
+ field: 'catalogName',
3320
3868
  sorter: 1,
3321
3869
  filter: 'advanced',
3322
3870
  width: 150
3871
+ }, {
3872
+ title: t('backoffice._id'),
3873
+ field: '_id',
3874
+ sorter: 1,
3875
+ filter: 'advanced',
3876
+ width: 100
3323
3877
  }, {
3324
3878
  title: t('backoffice.table.views.lastUpdated'),
3325
3879
  field: 'lastUpdated',
3880
+ defaultSortOrder: 'descend',
3326
3881
  type: 'unixTimeStamp',
3327
3882
  sorter: 1,
3328
3883
  filter: 'advanced',
3329
3884
  width: 200
3885
+ }, {
3886
+ title: t('backoffice.table.views.lastUpdatedBy'),
3887
+ field: 'lastUpdatedBy_displayText',
3888
+ sorter: 1,
3889
+ filter: 'advanced',
3890
+ width: 150
3330
3891
  }, {
3331
3892
  title: 'backoffice.content',
3332
3893
  field: 'content',
3333
3894
  hidden: true
3334
3895
  }, {
3335
- title: t('backoffice._id'),
3336
- field: '_id',
3896
+ title: t('backoffice.table.medien.columns.title.organizationId'),
3897
+ field: 'organizationId',
3337
3898
  sorter: 1,
3338
3899
  filter: 'advanced',
3339
- width: 100
3900
+ width: 150
3340
3901
  }],
3341
3902
  rowAction: [{
3342
3903
  actionType: 'Detail',
@@ -3369,7 +3930,7 @@ function loadConfiguration(t, root, config, lang) {
3369
3930
  }],
3370
3931
  apiInterface: {
3371
3932
  read: {
3372
- list: '${catalogService}/contentItems?onlyTemplates=true',
3933
+ list: '${catalogService}/contentItems',
3373
3934
  filterServerSide: true
3374
3935
  },
3375
3936
  "delete": '${catalogService}/contentItems/${id}'
@@ -7624,6 +8185,7 @@ function loadConfiguration(t, root, config, lang) {
7624
8185
  }, {
7625
8186
  name: 'mediaItemImage',
7626
8187
  type: 'media',
8188
+ hideTrash: true,
7627
8189
  allowedTypes: ['image/*'],
7628
8190
  mediaItemRefField: 'mediaItemRefImage',
7629
8191
  urlField: 'image',
@@ -7644,6 +8206,7 @@ function loadConfiguration(t, root, config, lang) {
7644
8206
  }, {
7645
8207
  name: 'mediaItemVideo',
7646
8208
  type: 'media',
8209
+ hideTrash: true,
7647
8210
  allowedTypes: ['video/*'],
7648
8211
  mediaItemRefField: 'mediaItemRefVideo',
7649
8212
  urlField: 'video',
@@ -8214,6 +8777,9 @@ function loadConfiguration(t, root, config, lang) {
8214
8777
  options: [{
8215
8778
  value: 'HQ',
8216
8779
  label: 'HQ'
8780
+ }, {
8781
+ value: 'MASTER',
8782
+ label: 'MASTER'
8217
8783
  }, {
8218
8784
  value: 'SPIN',
8219
8785
  label: 'SPIN'
@@ -8403,7 +8969,7 @@ function loadConfiguration(t, root, config, lang) {
8403
8969
  label: t('backoffice.form.renderjob.itemSelector'),
8404
8970
  mode: 'single',
8405
8971
  type: 'select',
8406
- values: ['HQ', 'AR', 'SPIN', 'CUTOUT'],
8972
+ values: ['HQ', 'AR', 'MASTER', 'SPIN', 'CUTOUT'],
8407
8973
  readonly: {
8408
8974
  field: 'state',
8409
8975
  op: 'gt',
@@ -8514,7 +9080,7 @@ function loadConfiguration(t, root, config, lang) {
8514
9080
  mode: 'single',
8515
9081
  type: 'select',
8516
9082
  marker: true,
8517
- values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx'],
9083
+ values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx', 'blend'],
8518
9084
  readonly: {
8519
9085
  field: 'state',
8520
9086
  op: 'gt',
@@ -8758,6 +9324,148 @@ function loadConfiguration(t, root, config, lang) {
8758
9324
  op: 'gt',
8759
9325
  value: 3
8760
9326
  }
9327
+ }, {
9328
+ name: 'fileFormat',
9329
+ label: t('backoffice.form.renderjob.items.fileFormat'),
9330
+ mode: 'single',
9331
+ type: 'select',
9332
+ marker: true,
9333
+ values: ['glb', 'gltf', 'fbx', 'blend'],
9334
+ readonly: {
9335
+ field: 'state',
9336
+ op: 'gt',
9337
+ value: 3
9338
+ },
9339
+ placeholder: 'z.B.: jpg, png, tif'
9340
+ }, {
9341
+ name: 'fileName',
9342
+ label: t('backoffice.form.renderjob.items.fileName'),
9343
+ type: 'input',
9344
+ readonly: {
9345
+ field: 'state',
9346
+ op: 'gt',
9347
+ value: 3
9348
+ },
9349
+ placeholder: 'z.B.: testrendering',
9350
+ dynamic: {
9351
+ seperator: '_',
9352
+ fields: ['job', 'divaNr', 'divaNrVariantId']
9353
+ }
9354
+ }, {
9355
+ name: 'group',
9356
+ label: t('backoffice.form.renderjob.items.group'),
9357
+ type: 'input',
9358
+ readonly: {
9359
+ field: 'state',
9360
+ op: 'gt',
9361
+ value: 3
9362
+ }
9363
+ }, {
9364
+ name: 'product',
9365
+ label: t('backoffice.form.renderjob.items.product'),
9366
+ type: 'input',
9367
+ readonly: true
9368
+ }, {
9369
+ name: 'organizationName',
9370
+ label: t('backoffice.form.renderjob.items.organizationName'),
9371
+ type: 'input',
9372
+ readonly: true
9373
+ }, {
9374
+ name: 'organization',
9375
+ label: t('backoffice.form.renderjob.items.organization'),
9376
+ type: 'input',
9377
+ readonly: true
9378
+ }, {
9379
+ name: 'createdByName',
9380
+ label: t('backoffice.form.renderjob.items.createdByName'),
9381
+ type: 'input',
9382
+ readonly: true
9383
+ }, {
9384
+ name: 'createdByEmail',
9385
+ label: t('backoffice.form.renderjob.items.createdByEmail'),
9386
+ type: 'input',
9387
+ readonly: true
9388
+ }, {
9389
+ name: 'createdBy',
9390
+ label: t('backoffice.form.renderjob.items.createdBy'),
9391
+ type: 'input',
9392
+ readonly: true
9393
+ }], [{
9394
+ name: '_id',
9395
+ label: 'ID',
9396
+ type: 'input',
9397
+ readonly: true
9398
+ }, {
9399
+ name: 'debugUser',
9400
+ label: t('backoffice.form.renderjob.items.debugUser'),
9401
+ type: 'checkbox',
9402
+ valueOnEnabled: {
9403
+ globalValue: 'userId'
9404
+ }
9405
+ }, {
9406
+ name: 'state',
9407
+ label: t('backoffice.form.renderjob.items.state'),
9408
+ type: 'display',
9409
+ translationPrefix: 'renderjob.state',
9410
+ readonly: true
9411
+ }, {
9412
+ name: 'productName',
9413
+ label: t('backoffice.form.renderjob.items.productName'),
9414
+ type: 'input',
9415
+ readonly: true
9416
+ }, {
9417
+ name: 'functionType',
9418
+ label: t('backoffice.form.renderjob.items.functionType'),
9419
+ type: 'select',
9420
+ mode: 'single',
9421
+ readonly: {
9422
+ field: 'state',
9423
+ op: 'gt',
9424
+ value: 3
9425
+ },
9426
+ allowClear: true,
9427
+ values: ['PROD', 'PROD_SEC', 'PROD_CLOSE', 'PROD_MILIEU', 'SHO', 'CONFIG_INFO', 'AR_INFO', 'PROD_DETAIL', 'CAT', 'PLN', 'LOG', 'FUNC', 'COMMERCIAL', 'TPL', 'ASI', 'PLT', 'CAI', 'BAN', 'INF', 'OTH', 'ART', 'OPV']
9428
+ }, {
9429
+ name: 'priority',
9430
+ label: t('backoffice.form.renderjob.items.priority'),
9431
+ readonly: {
9432
+ field: 'state',
9433
+ op: 'gt',
9434
+ value: 3
9435
+ }
9436
+ }, {
9437
+ label: t('backoffice.form.renderjob.items.dracoCompression'),
9438
+ name: 'dracoCompression',
9439
+ type: 'checkbox',
9440
+ readonly: {
9441
+ field: 'state',
9442
+ op: 'gt',
9443
+ value: 3
9444
+ }
9445
+ }, {
9446
+ label: t('backoffice.form.renderjob.items.originPosition'),
9447
+ name: 'originPosition',
9448
+ type: 'select',
9449
+ mode: 'single',
9450
+ translationPrefix: 'backoffice.form.renderjob.items',
9451
+ values: ['leftbackbottom', 'center'],
9452
+ readonly: {
9453
+ field: 'state',
9454
+ op: 'gt',
9455
+ value: 3
9456
+ }
9457
+ }, {
9458
+ name: 'engine',
9459
+ label: t('backoffice.form.renderjob.items.engine'),
9460
+ type: 'select',
9461
+ mode: 'single',
9462
+ marker: true,
9463
+ values: ['blender', 'unity', 'max'],
9464
+ readonly: {
9465
+ field: 'state',
9466
+ op: 'gt',
9467
+ value: 3
9468
+ }
8761
9469
  }, {
8762
9470
  name: 'arBakedMapsResolution',
8763
9471
  label: t('backoffice.form.renderjob.items.arBakedMapsResolution'),
@@ -8775,7 +9483,7 @@ function loadConfiguration(t, root, config, lang) {
8775
9483
  mode: 'single',
8776
9484
  type: 'select',
8777
9485
  marker: true,
8778
- values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx'],
9486
+ values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx', 'blend'],
8779
9487
  readonly: {
8780
9488
  field: 'state',
8781
9489
  op: 'gt',
@@ -8910,7 +9618,7 @@ function loadConfiguration(t, root, config, lang) {
8910
9618
  mode: 'single',
8911
9619
  type: 'select',
8912
9620
  marker: true,
8913
- values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx'],
9621
+ values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx', 'blend'],
8914
9622
  readonly: {
8915
9623
  field: 'state',
8916
9624
  op: 'gt',
@@ -9095,7 +9803,7 @@ function loadConfiguration(t, root, config, lang) {
9095
9803
  mode: 'single',
9096
9804
  type: 'select',
9097
9805
  marker: true,
9098
- values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx'],
9806
+ values: ['png', 'jpg', 'tif', 'glb', 'gltf', 'fbx', 'blend'],
9099
9807
  readonly: true,
9100
9808
  placeholder: 'z.B.: jpg, png, tif'
9101
9809
  }, {
@@ -9221,8 +9929,18 @@ function loadConfiguration(t, root, config, lang) {
9221
9929
  },
9222
9930
  requiredFields: ['engine', {
9223
9931
  field: 'fileFormat',
9224
- value: ['glb', 'gltf', 'fbx']
9932
+ value: ['glb', 'gltf', 'fbx', 'blend']
9225
9933
  }, 'arBakedMapsResolution']
9934
+ }, {
9935
+ value: 3,
9936
+ onField: {
9937
+ field: 'job',
9938
+ value: 'MASTER'
9939
+ },
9940
+ requiredFields: ['engine', {
9941
+ field: 'fileFormat',
9942
+ value: ['glb', 'blend', 'fbx', 'glb']
9943
+ }]
9226
9944
  }],
9227
9945
  flow: {
9228
9946
  0: [1, 10],
@@ -11569,7 +12287,7 @@ function MenuLabel (_ref) {
11569
12287
  function _createForOfIteratorHelper$l(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$l(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
11570
12288
  function _unsupportedIterableToArray$l(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$l(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$l(r, a) : void 0; } }
11571
12289
  function _arrayLikeToArray$l(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
11572
- function aplyRule(_ref) {
12290
+ function applyRule(_ref) {
11573
12291
  var rules = _ref.rules,
11574
12292
  data = _ref.data,
11575
12293
  rootStore = _ref.rootStore,
@@ -11601,7 +12319,7 @@ function aplyRule(_ref) {
11601
12319
  result = rule.match.value == sourceValue;
11602
12320
  }
11603
12321
  } else if (rule.or) {
11604
- result = aplyRule({
12322
+ result = applyRule({
11605
12323
  rules: rule.or,
11606
12324
  data: data,
11607
12325
  rootStore: rootStore,
@@ -11635,7 +12353,7 @@ function aplyRules(_ref2) {
11635
12353
  try {
11636
12354
  for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
11637
12355
  var dt = _step2.value;
11638
- if (aplyRule({
12356
+ if (applyRule({
11639
12357
  rules: rules,
11640
12358
  data: dt,
11641
12359
  rootStore: rootStore,
@@ -11654,6 +12372,12 @@ function getIcon(icon) {
11654
12372
  switch (icon) {
11655
12373
  case 'StopFilled':
11656
12374
  return /*#__PURE__*/jsx(StopFilled, {});
12375
+ case 'FileZipOutlined':
12376
+ return /*#__PURE__*/jsx(FileZipOutlined, {});
12377
+ case 'PlaySquareOutlined':
12378
+ return /*#__PURE__*/jsx(PlaySquareOutlined, {});
12379
+ case 'ClockCircleOutlined':
12380
+ return /*#__PURE__*/jsx(ClockCircleOutlined, {});
11657
12381
  case 'ExclamationCircleFilled':
11658
12382
  return /*#__PURE__*/jsx(ExclamationCircleFilled, {});
11659
12383
  case 'ApartmentOutlined':
@@ -12108,7 +12832,7 @@ var _default$6 = /*#__PURE__*/function () {
12108
12832
  value: function getMenuItem(item) {
12109
12833
  var _this3 = this;
12110
12834
  if (item.items) {
12111
- var disabled = item.rules ? !aplyRule({
12835
+ var disabled = item.rules ? !applyRule({
12112
12836
  rules: item.rules,
12113
12837
  data: undefined,
12114
12838
  rootStore: this.root
@@ -12127,7 +12851,7 @@ var _default$6 = /*#__PURE__*/function () {
12127
12851
  };
12128
12852
  return menuItem;
12129
12853
  } else {
12130
- var _disabled = item.rules ? !aplyRule({
12854
+ var _disabled = item.rules ? !applyRule({
12131
12855
  rules: item.rules,
12132
12856
  data: undefined,
12133
12857
  rootStore: this.root
@@ -12250,16 +12974,10 @@ var menu = [{
12250
12974
  }
12251
12975
  }]
12252
12976
  }, {
12253
- id: 'GroupContentItems',
12977
+ id: 'ContentItems',
12254
12978
  path: 'contentitems',
12255
12979
  label: 'backoffice.menu.items.label.ContentItems',
12256
- icon: 'OrderedListOutlined',
12257
- rules: [{
12258
- match: {
12259
- value: ['RETAILER', 'ASSOCIATION'],
12260
- globalValue: 'organization.parentType'
12261
- }
12262
- }]
12980
+ icon: 'OrderedListOutlined'
12263
12981
  }, {
12264
12982
  id: 'idmTables',
12265
12983
  path: 'idm',
@@ -12350,6 +13068,32 @@ var menu = [{
12350
13068
  label: 'backoffice.menu.items.label.organizationAdmin',
12351
13069
  icon: 'ApartmentOutlined',
12352
13070
  permission: 'backoffice_admin_organizations'
13071
+ }, {
13072
+ id: 'taskStatusAdmin',
13073
+ label: 'backoffice.menu.items.label.taskStatusAdmin',
13074
+ icon: 'ClockCircleOutlined',
13075
+ permission: 'backoffice_admin_taskstatus',
13076
+ items: [{
13077
+ id: 'TableTaskStatusVersioning',
13078
+ path: 'taskstatusversioning',
13079
+ label: 'backoffice.menu.items.label.taskStatusAdminVersioning',
13080
+ icon: 'FileZipOutlined'
13081
+ }, {
13082
+ id: 'TableTaskStatusCustom',
13083
+ path: 'taskstatuscustom',
13084
+ label: 'backoffice.table.taskstatusversioning.title.taskstatuscustom',
13085
+ icon: 'SwapOutlined'
13086
+ }, {
13087
+ id: 'TableTaskStatusCronJobs',
13088
+ path: 'taskstatuscronjobs',
13089
+ label: 'backoffice.menu.items.label.taskStatusAdminCronJobs',
13090
+ icon: 'ClockCircleOutlined'
13091
+ }, {
13092
+ id: 'TableTaskStatusOthers',
13093
+ path: 'taskstatuscronothers',
13094
+ label: 'backoffice.table.taskstatusversioning.title.taskstatusothers',
13095
+ icon: 'PlaySquareOutlined'
13096
+ }]
12353
13097
  }, {
12354
13098
  id: 'TableAllUsers',
12355
13099
  path: 'users',
@@ -12787,7 +13531,7 @@ var _default$3 = /*#__PURE__*/function () {
12787
13531
  function _createForOfIteratorHelper$k(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$k(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
12788
13532
  function _unsupportedIterableToArray$k(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$k(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$k(r, a) : void 0; } }
12789
13533
  function _arrayLikeToArray$k(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
12790
- var LOG$a = getLogger('Backoffice', 'DownloadStore');
13534
+ var LOG$b = getLogger('Backoffice', 'DownloadStore');
12791
13535
  var DownloadStore = /*#__PURE__*/function () {
12792
13536
  function DownloadStore(_rootStore) {
12793
13537
  var _this = this;
@@ -12817,7 +13561,7 @@ var DownloadStore = /*#__PURE__*/function () {
12817
13561
  _iterator = _createForOfIteratorHelper$k(action.download);
12818
13562
  _context2.prev = 8;
12819
13563
  _loop = /*#__PURE__*/_regeneratorRuntime.mark(function _loop() {
12820
- var _download$params, _ref3, _data$fileUrl;
13564
+ var _download$params, _data$fileFormat, _data$fileUrl;
12821
13565
  var url;
12822
13566
  return _regeneratorRuntime.wrap(function _loop$(_context) {
12823
13567
  while (1) switch (_context.prev = _context.next) {
@@ -12847,7 +13591,7 @@ var DownloadStore = /*#__PURE__*/function () {
12847
13591
  url.searchParams.append(param.name, param.value);
12848
13592
  });
12849
13593
  _context.next = 14;
12850
- return _this.donwloadFile(url, (_ref3 = (data === null || data === void 0 ? void 0 : data.fileName) + '.' + data.fileFormat) !== null && _ref3 !== void 0 ? _ref3 : data === null || data === void 0 || (_data$fileUrl = data.fileUrl) === null || _data$fileUrl === void 0 ? void 0 : _data$fileUrl.substring((data === null || data === void 0 ? void 0 : data.fileUrl.lastIndexOf('.')) + 1));
13594
+ return _this.donwloadFile(url, (data === null || data === void 0 ? void 0 : data.fileName) + '.' + ((_data$fileFormat = data.fileFormat) !== null && _data$fileFormat !== void 0 ? _data$fileFormat : data === null || data === void 0 || (_data$fileUrl = data.fileUrl) === null || _data$fileUrl === void 0 ? void 0 : _data$fileUrl.substring((data === null || data === void 0 ? void 0 : data.fileUrl.lastIndexOf('.')) + 1)));
12851
13595
  case 14:
12852
13596
  return _context.abrupt("break", 24);
12853
13597
  case 15:
@@ -13003,7 +13747,7 @@ var DownloadStore = /*#__PURE__*/function () {
13003
13747
  _context5.next = 4;
13004
13748
  break;
13005
13749
  }
13006
- LOG$a.debug("The organization ".concat(data._id, " has no parentType of ").concat(validTypes.join(' or ')));
13750
+ LOG$b.debug("The organization ".concat(data._id, " has no parentType of ").concat(validTypes.join(' or ')));
13007
13751
  throw new Error("Current organization is no ".concat(type == 'RETAILER' ? 'retailer, retailer channel or association' : 'supplier or dealer'));
13008
13752
  case 4:
13009
13753
  orgData = data;
@@ -13022,7 +13766,7 @@ var DownloadStore = /*#__PURE__*/function () {
13022
13766
  _context5.next = 14;
13023
13767
  break;
13024
13768
  }
13025
- LOG$a.debug("The organization ".concat(data._id, " has no type of ").concat(validTypes.join(' or '), " nor a parent organization"));
13769
+ LOG$b.debug("The organization ".concat(data._id, " has no type of ").concat(validTypes.join(' or '), " nor a parent organization"));
13026
13770
  throw new Error("Current organization is no ".concat(type == 'RETAILER' ? 'retailer channel or association' : 'supplier or dealer'));
13027
13771
  case 14:
13028
13772
  _context5.prev = 14;
@@ -13063,8 +13807,8 @@ var DownloadStore = /*#__PURE__*/function () {
13063
13807
  return _regeneratorRuntime.wrap(function _callee5$(_context6) {
13064
13808
  while (1) switch (_context6.prev = _context6.next) {
13065
13809
  case 0:
13066
- url = aplyMapping({
13067
- mapable: download.request,
13810
+ url = applyMapping({
13811
+ mappable: download.request,
13068
13812
  mapping: download.mapping,
13069
13813
  //download.mapping,
13070
13814
  mappingData: data,
@@ -13638,24 +14382,34 @@ function isExternalVid(file) {
13638
14382
  }
13639
14383
 
13640
14384
  var VIDEO_THUMB_PLACEHOLDER = 'data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjMDAwMDAwIiBoZWlnaHQ9IjgwMHB4IiB3aWR0aD0iODAwcHgiIHZlcnNpb249IjEuMSIgaWQ9IkNhcGFfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgCgkgdmlld0JveD0iMCAwIDQ5IDQ5IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPGc+Cgk8Zz4KCQk8cGF0aCBkPSJNMzkuMjU2LDYuNUg5Ljc0NEM0LjM3MSw2LjUsMCwxMC44ODUsMCwxNi4yNzR2MTYuNDUxYzAsNS4zOSw0LjM3MSw5Ljc3NCw5Ljc0NCw5Ljc3NGgyOS41MTIKCQkJYzUuMzczLDAsOS43NDQtNC4zODUsOS43NDQtOS43NzRWMTYuMjc0QzQ5LDEwLjg4NSw0NC42MjksNi41LDM5LjI1Niw2LjV6IE00NywzMi43MjZjMCw0LjI4Ny0zLjQ3NCw3Ljc3NC03Ljc0NCw3Ljc3NEg5Ljc0NAoJCQlDNS40NzQsNDAuNSwyLDM3LjAxMiwyLDMyLjcyNlYxNi4yNzRDMiwxMS45ODgsNS40NzQsOC41LDkuNzQ0LDguNWgyOS41MTJjNC4yNywwLDcuNzQ0LDMuNDg4LDcuNzQ0LDcuNzc0VjMyLjcyNnoiLz4KCQk8cGF0aCBkPSJNMzMuMzYsMjQuMTM4bC0xMy44NTUtOC4xMTVjLTAuMzA4LTAuMTgtMC42OTEtMC4xODMtMS4wMDItMC4wMDVTMTgsMTYuNTI3LDE4LDE2Ljg4NnYxNi4yMjkKCQkJYzAsMC4zNTgsMC4xOTIsMC42OSwwLjUwMiwwLjg2OGMwLjE1NCwwLjA4OCwwLjMyNiwwLjEzMiwwLjQ5OCwwLjEzMmMwLjE3NSwwLDAuMzQ5LTAuMDQ2LDAuNTA1LTAuMTM3bDEzLjg1NS04LjExMwoJCQljMC4zMDYtMC4xNzksMC40OTUtMC41MDgsMC40OTUtMC44NjNTMzMuNjY3LDI0LjMxNywzMy4zNiwyNC4xMzh6IE0yMCwzMS4zN1YxOC42M2wxMC44NzYsNi4zNzFMMjAsMzEuMzd6Ii8+Cgk8L2c+CjwvZz4KPC9zdmc+';
14385
+ var LOG$a = getLogger('Backoffice', 'MediaItem');
13641
14386
  var MediaItem = /*#__PURE__*/function () {
13642
- function MediaItem(media, config, mediaItemId, medaItemRefId) {
14387
+ function MediaItem(_ref) {
14388
+ var media = _ref.media,
14389
+ remoteUrl = _ref.remoteUrl,
14390
+ config = _ref.config,
14391
+ mediaItemId = _ref.mediaItemId,
14392
+ mediaItemRefId = _ref.mediaItemRefId;
13643
14393
  _classCallCheck(this, MediaItem);
13644
- this.config = config;
13645
14394
  _defineProperty(this, "_url", void 0);
13646
14395
  _defineProperty(this, "_file", void 0);
13647
14396
  _defineProperty(this, "_mediaItemId", void 0);
13648
14397
  _defineProperty(this, "_mediaItemRefId", void 0);
13649
14398
  _defineProperty(this, "_itemRef", void 0);
13650
14399
  _defineProperty(this, "_isRemoteUrl", void 0);
14400
+ _defineProperty(this, "_config", void 0);
14401
+ this._config = config;
13651
14402
  if (typeof media === 'string') {
13652
14403
  this._url = media;
13653
- this._isRemoteUrl = isExternalVid(media);
14404
+ if (!this._url.startsWith('http')) {
14405
+ this._url = "https://".concat(this._url);
14406
+ }
14407
+ this._isRemoteUrl = remoteUrl ? true : isExternalVid(media);
13654
14408
  } else {
13655
14409
  this._file = media;
13656
14410
  }
13657
14411
  this._mediaItemId = mediaItemId;
13658
- this._mediaItemRefId = medaItemRefId;
14412
+ this._mediaItemRefId = mediaItemRefId;
13659
14413
  }
13660
14414
  return _createClass(MediaItem, [{
13661
14415
  key: "file",
@@ -13680,10 +14434,10 @@ var MediaItem = /*#__PURE__*/function () {
13680
14434
  }, {
13681
14435
  key: "antdFile",
13682
14436
  get: function get() {
13683
- var _this$_itemRef$_id, _this$_itemRef, _ref, _this$_itemRef$fileNa, _this$_itemRef2, _this$_file, _this$_url;
14437
+ var _this$_itemRef$_id, _this$_itemRef, _ref2, _this$_itemRef$fileNa, _this$_itemRef2, _this$_file, _this$_url;
13684
14438
  return {
13685
14439
  uid: (_this$_itemRef$_id = (_this$_itemRef = this._itemRef) === null || _this$_itemRef === void 0 ? void 0 : _this$_itemRef._id) !== null && _this$_itemRef$_id !== void 0 ? _this$_itemRef$_id : nanoid(),
13686
- name: this._isRemoteUrl ? this._url : (_ref = (_this$_itemRef$fileNa = (_this$_itemRef2 = this._itemRef) === null || _this$_itemRef2 === void 0 ? void 0 : _this$_itemRef2.fileName) !== null && _this$_itemRef$fileNa !== void 0 ? _this$_itemRef$fileNa : (_this$_file = this._file) === null || _this$_file === void 0 ? void 0 : _this$_file.name) !== null && _ref !== void 0 ? _ref : nameFromUrl((_this$_url = this._url) !== null && _this$_url !== void 0 ? _this$_url : ''),
14440
+ name: this._isRemoteUrl ? this._url : (_ref2 = (_this$_itemRef$fileNa = (_this$_itemRef2 = this._itemRef) === null || _this$_itemRef2 === void 0 ? void 0 : _this$_itemRef2.fileName) !== null && _this$_itemRef$fileNa !== void 0 ? _this$_itemRef$fileNa : (_this$_file = this._file) === null || _this$_file === void 0 ? void 0 : _this$_file.name) !== null && _ref2 !== void 0 ? _ref2 : nameFromUrl((_this$_url = this._url) !== null && _this$_url !== void 0 ? _this$_url : ''),
13687
14441
  url: this._url,
13688
14442
  thumbUrl: this._isRemoteUrl ? VIDEO_THUMB_PLACEHOLDER : undefined
13689
14443
  };
@@ -13704,7 +14458,7 @@ var MediaItem = /*#__PURE__*/function () {
13704
14458
  return _context.abrupt("return");
13705
14459
  case 4:
13706
14460
  _context.next = 6;
13707
- return removeMediaItemRef(this.config.baseUrl, this.config.jwt, this._mediaItemRefId);
14461
+ return removeMediaItemRef(this._config.baseUrl, this._config.jwt, this._mediaItemRefId);
13708
14462
  case 6:
13709
14463
  this._mediaItemId = undefined;
13710
14464
  this._mediaItemRefId = undefined;
@@ -13728,45 +14482,55 @@ var MediaItem = /*#__PURE__*/function () {
13728
14482
  while (1) switch (_context2.prev = _context2.next) {
13729
14483
  case 0:
13730
14484
  if (!this._mediaItemRefId) {
13731
- _context2.next = 5;
14485
+ _context2.next = 12;
13732
14486
  break;
13733
14487
  }
13734
- _context2.next = 3;
13735
- return getMediaItemRef(this.config.baseUrl, this.config.jwt, this._mediaItemRefId);
13736
- case 3:
14488
+ _context2.prev = 1;
14489
+ _context2.next = 4;
14490
+ return getMediaItemRef(this._config.baseUrl, this._config.jwt, this._mediaItemRefId);
14491
+ case 4:
13737
14492
  this._itemRef = _context2.sent;
13738
14493
  this._url = this._itemRef.url;
13739
- case 5:
14494
+ _context2.next = 12;
14495
+ break;
14496
+ case 8:
14497
+ _context2.prev = 8;
14498
+ _context2.t0 = _context2["catch"](1);
14499
+ this._mediaItemRefId = undefined;
14500
+ LOG$a.error(new DivaError$1('Failed to get media item ref, on next upload a new ref will be created', {
14501
+ cause: _context2.t0
14502
+ }));
14503
+ case 12:
13740
14504
  if (!(this.file && !this._url)) {
13741
- _context2.next = 11;
14505
+ _context2.next = 18;
13742
14506
  break;
13743
14507
  }
13744
- _context2.next = 8;
14508
+ _context2.next = 15;
13745
14509
  return getFileAsDataUri(this.file);
13746
- case 8:
14510
+ case 15:
13747
14511
  this._url = _context2.sent;
13748
- _context2.next = 15;
14512
+ _context2.next = 22;
13749
14513
  break;
13750
- case 11:
14514
+ case 18:
13751
14515
  if (!(this._url && !this._file && !this._isRemoteUrl)) {
13752
- _context2.next = 15;
14516
+ _context2.next = 22;
13753
14517
  break;
13754
14518
  }
13755
- _context2.next = 14;
14519
+ _context2.next = 21;
13756
14520
  return fetchFileData(this._url);
13757
- case 14:
14521
+ case 21:
13758
14522
  this._file = _context2.sent;
13759
- case 15:
14523
+ case 22:
13760
14524
  if (!(this.file && !isFileOfType(this.file, allowedTypes))) {
13761
- _context2.next = 17;
14525
+ _context2.next = 24;
13762
14526
  break;
13763
14527
  }
13764
14528
  throw new Error('File type is not allowed');
13765
- case 17:
14529
+ case 24:
13766
14530
  case "end":
13767
14531
  return _context2.stop();
13768
14532
  }
13769
- }, _callee2, this);
14533
+ }, _callee2, this, [[1, 8]]);
13770
14534
  }));
13771
14535
  function init(_x) {
13772
14536
  return _init.apply(this, arguments);
@@ -13811,7 +14575,7 @@ var MediaItem = /*#__PURE__*/function () {
13811
14575
  }));
13812
14576
  formData.append('file', this._file, this._file.name);
13813
14577
  _context3.next = 12;
13814
- return uploadMediaItem(this.config.baseUrl, this.config.jwt, formData);
14578
+ return uploadMediaItem(this._config.baseUrl, this._config.jwt, formData);
13815
14579
  case 12:
13816
14580
  response = _context3.sent;
13817
14581
  this._mediaItemRefId = response.ref._id;
@@ -13879,6 +14643,7 @@ function useFormData (_ref) {
13879
14643
  removedMedias = _useState12[0],
13880
14644
  setRemovedMedias = _useState12[1];
13881
14645
  var _useMemo = useMemo(function () {
14646
+ setCanSave === null || setCanSave === void 0 || setCanSave(true);
13882
14647
  var c = {
13883
14648
  apiHandler: root.getApiHandler(id, apiInterface),
13884
14649
  configuration: root.configurationStore.getConfiguration(id, 'Form')
@@ -13894,7 +14659,7 @@ function useFormData (_ref) {
13894
14659
  if (configuration.disableSave) setCanSave === null || setCanSave === void 0 || setCanSave(false);
13895
14660
  }, [configuration]);
13896
14661
  var _onLoadFields = function onLoadFields(data) {
13897
- var items = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : selectedItems !== null && selectedItems !== void 0 ? selectedItems : configuration.items;
14662
+ var items = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : (selectedItems !== null && selectedItems !== void 0 ? selectedItems : configuration.itemSelector && Array.isArray(configuration.items[0])) ? configuration.items[0] : configuration.items;
13898
14663
  var _iterator = _createForOfIteratorHelper$j(items),
13899
14664
  _step;
13900
14665
  try {
@@ -13909,10 +14674,15 @@ function useFormData (_ref) {
13909
14674
  var ref = typeof item.mediaItemRefField == 'string' ? [item.mediaItemRefField] : item.mediaItemRefField;
13910
14675
  var media = getData(itemName, data);
13911
14676
  if (media) {
13912
- var mediaItem = new MediaItem(getData(urlName, data), {
13913
- baseUrl: root.configurationStore.apiConfig.mediaService,
13914
- jwt: root.dataStore.jwt
13915
- }, media, getData(ref, data));
14677
+ var mediaItem = new MediaItem({
14678
+ media: getData(urlName, data),
14679
+ config: {
14680
+ baseUrl: root.configurationStore.apiConfig.mediaService,
14681
+ jwt: root.dataStore.jwt
14682
+ },
14683
+ mediaItemId: media,
14684
+ mediaItemRefId: getData(ref, data)
14685
+ });
13916
14686
  mediaItem.init(item.allowedTypes);
13917
14687
  setFieldInObject(itemName, data, mediaItem);
13918
14688
  }
@@ -14015,21 +14785,25 @@ function useFormData (_ref) {
14015
14785
  _context.next = 17;
14016
14786
  break;
14017
14787
  }
14788
+ if (configuration.showProgressBar) setProgressBarPercentage(i > 0 ? Math.floor(i / multipleEditingData.length * 100) : 1);
14018
14789
  original = multipleEditingData[i];
14019
14790
  _newData = setNewData(newData, JSON.parse(JSON.stringify(original)));
14020
14791
  _context.t0 = response;
14021
- _context.next = 11;
14792
+ _context.next = 12;
14022
14793
  return apiHandler.update(_newData, original, configuration.mapping);
14023
- case 11:
14794
+ case 12:
14024
14795
  _context.t1 = _context.sent;
14025
14796
  _context.t0.push.call(_context.t0, _context.t1);
14026
- if (configuration.showProgressBar) setProgressBarPercentage(Math.abs((i + 1 / multipleEditingData.length) * 100));
14027
14797
  case 14:
14028
14798
  i++;
14029
14799
  _context.next = 5;
14030
14800
  break;
14031
14801
  case 17:
14032
- if (configuration.showProgressBar) setProgressBarOpen(false);
14802
+ if (configuration.showProgressBar) {
14803
+ if (configuration.showProgressBar) setProgressBarPercentage(100);
14804
+ setProgressBarOpen(false);
14805
+ setProgressBarPercentage(0);
14806
+ }
14033
14807
  _context.next = 23;
14034
14808
  break;
14035
14809
  case 20:
@@ -14084,34 +14858,44 @@ function useFormData (_ref) {
14084
14858
  return _regeneratorRuntime.wrap(function _callee2$(_context2) {
14085
14859
  while (1) switch (_context2.prev = _context2.next) {
14086
14860
  case 0:
14087
- newData = merge$1(_objectSpread$I({}, state.data), values);
14861
+ newData = merge(_objectSpread$I({}, state.data), values);
14088
14862
  if (!skipApi) {
14089
14863
  _context2.next = 3;
14090
14864
  break;
14091
14865
  }
14092
14866
  return _context2.abrupt("return", newData);
14093
14867
  case 3:
14094
- _context2.next = 5;
14868
+ root.actions.toggleLoading('saving_form');
14869
+ _context2.prev = 4;
14870
+ _context2.next = 7;
14095
14871
  return setDynamicFields(_objectSpread$I({}, state.data), newData);
14096
- case 5:
14872
+ case 7:
14097
14873
  newData = _context2.sent;
14098
- _context2.next = 8;
14874
+ _context2.next = 10;
14099
14875
  return preSaveProcess(newData, selectedItems !== null && selectedItems !== void 0 ? selectedItems : configuration.items);
14100
- case 8:
14876
+ case 10:
14101
14877
  newData = removeEmpty(newData);
14878
+ _context2.next = 17;
14879
+ break;
14880
+ case 13:
14881
+ _context2.prev = 13;
14882
+ _context2.t0 = _context2["catch"](4);
14883
+ root.actions.toggleLoading('saving_form');
14884
+ throw _context2.t0;
14885
+ case 17:
14102
14886
  setState(_objectSpread$I(_objectSpread$I({}, state), {}, {
14103
14887
  loading: true
14104
14888
  }));
14105
14889
  finalData = state.data;
14106
- _context2.prev = 11;
14107
- _context2.next = 14;
14890
+ _context2.prev = 19;
14891
+ _context2.next = 22;
14108
14892
  return apiCall(newData);
14109
- case 14:
14893
+ case 22:
14110
14894
  response = _context2.sent;
14111
14895
  i = 0;
14112
- case 16:
14896
+ case 24:
14113
14897
  if (!(i < (((_configuration$additi = configuration.additionals) === null || _configuration$additi === void 0 ? void 0 : _configuration$additi.length) || 0))) {
14114
- _context2.next = 26;
14898
+ _context2.next = 34;
14115
14899
  break;
14116
14900
  }
14117
14901
  // perform additional server actions before returning the data
@@ -14123,47 +14907,52 @@ function useFormData (_ref) {
14123
14907
  if (additional.addBaseUrl) {
14124
14908
  data[additional.addBaseUrl] = window.location.origin;
14125
14909
  }
14126
- _context2.next = 23;
14910
+ _context2.next = 31;
14127
14911
  return additionalApi.create(data, additional.mapping, response);
14128
- case 23:
14912
+ case 31:
14129
14913
  i++;
14130
- _context2.next = 16;
14914
+ _context2.next = 24;
14131
14915
  break;
14132
- case 26:
14916
+ case 34:
14133
14917
  finalData = response;
14134
14918
  return _context2.abrupt("return", response);
14135
- case 30:
14136
- _context2.prev = 30;
14137
- _context2.t0 = _context2["catch"](11);
14138
- if (!(_context2.t0 instanceof DivaError && _context2.t0.name)) {
14139
- _context2.next = 38;
14919
+ case 38:
14920
+ _context2.prev = 38;
14921
+ _context2.t1 = _context2["catch"](19);
14922
+ if (configuration.showProgressBar) {
14923
+ setProgressBarOpen(false);
14924
+ setProgressBarPercentage(0);
14925
+ }
14926
+ if (!(_context2.t1 instanceof DivaError && _context2.t1.name)) {
14927
+ _context2.next = 47;
14140
14928
  break;
14141
14929
  }
14142
- errorCode = _context2.t0.name;
14930
+ errorCode = _context2.t1.name;
14143
14931
  item = selectedItems === null || selectedItems === void 0 ? void 0 : selectedItems.find(function (item) {
14144
14932
  var _item$onError;
14145
14933
  return (_item$onError = item.onError) === null || _item$onError === void 0 ? void 0 : _item$onError[errorCode];
14146
14934
  });
14147
14935
  if (!item) {
14148
- _context2.next = 38;
14936
+ _context2.next = 47;
14149
14937
  break;
14150
14938
  }
14151
14939
  setFieldErrors(_objectSpread$I(_objectSpread$I({}, fieldErrors), {}, _defineProperty({}, item.name.toString(), item.onError[errorCode])));
14152
14940
  return _context2.abrupt("return", undefined);
14153
- case 38:
14154
- throw _context2.t0;
14155
- case 39:
14156
- _context2.prev = 39;
14941
+ case 47:
14942
+ throw _context2.t1;
14943
+ case 48:
14944
+ _context2.prev = 48;
14945
+ root.actions.toggleLoading('saving_form');
14157
14946
  setState(_objectSpread$I(_objectSpread$I({}, state), {}, {
14158
14947
  data: finalData,
14159
14948
  loading: false
14160
14949
  }));
14161
- return _context2.finish(39);
14162
- case 42:
14950
+ return _context2.finish(48);
14951
+ case 52:
14163
14952
  case "end":
14164
14953
  return _context2.stop();
14165
14954
  }
14166
- }, _callee2, null, [[11, 30, 39, 42]]);
14955
+ }, _callee2, null, [[4, 13], [19, 38, 48, 52]]);
14167
14956
  }));
14168
14957
  return function onSave(_x2) {
14169
14958
  return _ref3.apply(this, arguments);
@@ -14212,7 +15001,7 @@ function useFormData (_ref) {
14212
15001
 
14213
15002
  //if at an array an entry got added or deleted, its handeled by and so we take the data from the formdata
14214
15003
  var mergeCustomizer = function mergeCustomizer(obj, src) {
14215
- if (Array.isArray(obj) && obj.length != src.length) return src;
15004
+ if (Array.isArray(obj) && Array.isArray(src) && obj.length != src.length) return src;
14216
15005
  return undefined;
14217
15006
  };
14218
15007
  var setNewData = function setNewData(newData, orig) {
@@ -14552,7 +15341,7 @@ function useFormData (_ref) {
14552
15341
  }
14553
15342
  return;
14554
15343
  }, [state.data]);
14555
- var _keepRemovedMeidaItem = /*#__PURE__*/function () {
15344
+ var _keepRemovedMediaItem = /*#__PURE__*/function () {
14556
15345
  var _ref7 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee3(data, items) {
14557
15346
  var _iterator2, _step2, item, itemName, media, arrayData, i;
14558
15347
  return _regeneratorRuntime.wrap(function _callee3$(_context3) {
@@ -14582,7 +15371,7 @@ function useFormData (_ref) {
14582
15371
  break;
14583
15372
  }
14584
15373
  _context3.next = 14;
14585
- return _keepRemovedMeidaItem(data, item.items);
15374
+ return _keepRemovedMediaItem(data, item.items);
14586
15375
  case 14:
14587
15376
  _context3.next = 26;
14588
15377
  break;
@@ -14603,7 +15392,7 @@ function useFormData (_ref) {
14603
15392
  break;
14604
15393
  }
14605
15394
  _context3.next = 23;
14606
- return _keepRemovedMeidaItem(arrayData[i], item.items);
15395
+ return _keepRemovedMediaItem(arrayData[i], item.items);
14607
15396
  case 23:
14608
15397
  i++;
14609
15398
  _context3.next = 20;
@@ -14628,7 +15417,7 @@ function useFormData (_ref) {
14628
15417
  }
14629
15418
  }, _callee3, null, [[1, 30, 33, 36]]);
14630
15419
  }));
14631
- return function keepRemovedMeidaItem(_x7, _x8) {
15420
+ return function keepRemovedMediaItem(_x7, _x8) {
14632
15421
  return _ref7.apply(this, arguments);
14633
15422
  };
14634
15423
  }();
@@ -14661,7 +15450,7 @@ function useFormData (_ref) {
14661
15450
  getRules: getRules,
14662
15451
  progressBarOpen: progressBarOpen,
14663
15452
  progressBarPercentage: progressBarPercentage,
14664
- keepRemovedMeidaItem: _keepRemovedMeidaItem,
15453
+ keepRemovedMediaItem: _keepRemovedMediaItem,
14665
15454
  pushRemovedMeidaItem: pushRemovedMeidaItem
14666
15455
  });
14667
15456
  }
@@ -14773,7 +15562,7 @@ var FormList$2 = function FormList(_ref) {
14773
15562
  var remove = function remove(index, r) {
14774
15563
  var _state$getData;
14775
15564
  var data = (_state$getData = state.getData(absoluteName, state.data)) === null || _state$getData === void 0 ? void 0 : _state$getData[index];
14776
- state.keepRemovedMeidaItem(data, item.items);
15565
+ state.keepRemovedMediaItem(data, item.items);
14777
15566
  r(index);
14778
15567
  state.onInputChanged();
14779
15568
  };
@@ -14842,9 +15631,7 @@ var FormList$2 = function FormList(_ref) {
14842
15631
  }
14843
15632
  });
14844
15633
  };
14845
- var FormList$3 = observer(FormList$2, {
14846
- forwardRef: true
14847
- });
15634
+ var FormList$3 = observer(FormList$2);
14848
15635
 
14849
15636
  var ApiKey = function ApiKey(_ref) {
14850
15637
  var value = _ref.value,
@@ -14940,8 +15727,8 @@ function useButtonData (_ref) {
14940
15727
  message: configuration.resultTranslation ? t(configuration.resultTranslation.success) : result !== null && result !== void 0 && result.result ? result.result : 'Success'
14941
15728
  });
14942
15729
  if (callback) {
14943
- newData = aplyMapping({
14944
- mapable: {},
15730
+ newData = applyMapping({
15731
+ mappable: {},
14945
15732
  mappingData: result,
14946
15733
  mapping: configuration.resultMapping,
14947
15734
  rootStore: root,
@@ -15049,9 +15836,7 @@ var CustomButton = function CustomButton(_ref) {
15049
15836
  })
15050
15837
  });
15051
15838
  };
15052
- var CustomButton$1 = observer(CustomButton, {
15053
- forwardRef: true
15054
- });
15839
+ var CustomButton$1 = observer(CustomButton);
15055
15840
 
15056
15841
  var wrapper$5 = "wrapper-GVe2h";
15057
15842
  var buttonGroup = "button-group-GYt-T";
@@ -15089,8 +15874,8 @@ var SubTitle = function SubTitle(_ref) {
15089
15874
  };
15090
15875
  var SubTitle$1 = observer(SubTitle);
15091
15876
 
15092
- var InputComponent = function InputComponent(_ref) {
15093
- var _item$value, _item$value4;
15877
+ var InputComponent = function InputComponent(_ref, ref) {
15878
+ var _item$value, _item$value5, _item$value6;
15094
15879
  var item = _ref.item,
15095
15880
  data = _ref.data,
15096
15881
  value = _ref.value,
@@ -15126,6 +15911,7 @@ var InputComponent = function InputComponent(_ref) {
15126
15911
  };
15127
15912
  if (item.type === 'password') {
15128
15913
  return /*#__PURE__*/jsx(Input.Password, {
15914
+ ref: ref,
15129
15915
  addonBefore: item.prefix,
15130
15916
  addonAfter: item.suffix,
15131
15917
  disabled: isReadonly(item, data),
@@ -15137,20 +15923,25 @@ var InputComponent = function InputComponent(_ref) {
15137
15923
  onBlur: onBlur
15138
15924
  });
15139
15925
  }
15926
+ if (item.type === 'progress') {
15927
+ var _item$value4;
15928
+ return /*#__PURE__*/jsx(Progress, {
15929
+ percent: (_item$value4 = item.value) !== null && _item$value4 !== void 0 ? _item$value4 : value
15930
+ });
15931
+ }
15140
15932
  return /*#__PURE__*/jsx(Input, {
15933
+ ref: ref,
15141
15934
  addonBefore: item.prefix,
15142
15935
  addonAfter: item.suffix,
15143
- disabled: isReadonly(item, data),
15144
- value: (_item$value4 = item.value) !== null && _item$value4 !== void 0 ? _item$value4 : value,
15936
+ disabled: isReadonly(item, data) || (typeof item.disabled === 'function' ? item.disabled(data) : item.disabled),
15937
+ value: item.type === 'dateinput' ? new Date((_item$value5 = item.value) !== null && _item$value5 !== void 0 ? _item$value5 : value).toLocaleString().replace('Invalid Date', '') : (_item$value6 = item.value) !== null && _item$value6 !== void 0 ? _item$value6 : value,
15145
15938
  placeholder: item.placeholder,
15146
15939
  onChange: function onChange(e) {
15147
15940
  return _onChange === null || _onChange === void 0 ? void 0 : _onChange(item.name, e.target.value);
15148
15941
  }
15149
15942
  });
15150
15943
  };
15151
- var InputComponent$1 = observer(InputComponent, {
15152
- forwardRef: true
15153
- });
15944
+ var InputComponent$1 = observer(/*#__PURE__*/React.forwardRef(InputComponent));
15154
15945
 
15155
15946
  function _createForOfIteratorHelper$i(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$i(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
15156
15947
  function _unsupportedIterableToArray$i(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$i(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$i(r, a) : void 0; } }
@@ -15166,7 +15957,7 @@ function getCombinedValues(data, pattern) {
15166
15957
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
15167
15958
  var _flatten$match$;
15168
15959
  var match = _step.value;
15169
- value = value.replace(match[0], (_flatten$match$ = flat(data)[match[1]]) !== null && _flatten$match$ !== void 0 ? _flatten$match$ : '');
15960
+ value = value.replace(match[0], (_flatten$match$ = flatten(data)[match[1]]) !== null && _flatten$match$ !== void 0 ? _flatten$match$ : '');
15170
15961
  }
15171
15962
  } catch (err) {
15172
15963
  _iterator.e(err);
@@ -15314,7 +16105,7 @@ styleInject(css_248z$m);
15314
16105
  var _excluded$2 = ["apiInterface", "selectMapping", "apiMapping", "onChange", "value", "search", "options", "autoSelectFirst", "title"];
15315
16106
  function ownKeys$F(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
15316
16107
  function _objectSpread$F(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$F(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$F(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
15317
- var SelectWrapper$1 = function SelectWrapper(_ref) {
16108
+ var SelectWrapper$1 = function SelectWrapper(_ref, ref) {
15318
16109
  var apiInterface = _ref.apiInterface,
15319
16110
  selectMapping = _ref.selectMapping,
15320
16111
  apiMapping = _ref.apiMapping,
@@ -15336,6 +16127,7 @@ var SelectWrapper$1 = function SelectWrapper(_ref) {
15336
16127
  autoSelectFirst: autoSelectFirst
15337
16128
  });
15338
16129
  return /*#__PURE__*/jsxs("div", {
16130
+ ref: ref,
15339
16131
  className: classnames(title ? wrapper$4 : undefined),
15340
16132
  children: [title, /*#__PURE__*/jsx(Select$1, _objectSpread$F(_objectSpread$F({}, selectProps), {}, {
15341
16133
  showSearch: search,
@@ -15348,9 +16140,7 @@ var SelectWrapper$1 = function SelectWrapper(_ref) {
15348
16140
  }))]
15349
16141
  });
15350
16142
  };
15351
- var SimpleSelect = observer(SelectWrapper$1, {
15352
- forwardRef: true
15353
- });
16143
+ var SimpleSelect = observer(/*#__PURE__*/forwardRef(SelectWrapper$1));
15354
16144
  var filterOption = function filterOption(input, option) {
15355
16145
  var _option$label;
15356
16146
  return ((_option$label = option === null || option === void 0 ? void 0 : option.label) !== null && _option$label !== void 0 ? _option$label : '').toLowerCase().includes(input.toLowerCase());
@@ -15360,28 +16150,16 @@ var RichTextEditor = function RichTextEditor(_ref) {
15360
16150
  var initValue = _ref.initValue,
15361
16151
  onChange = _ref.onChange,
15362
16152
  name = _ref.name;
15363
- var _useDivaCore = useDivaCore(),
15364
- tinyMceApiKey = _useDivaCore.state.tinyMceApiKey;
15365
16153
  var val = useRef(initValue);
15366
- return /*#__PURE__*/jsx(Editor, {
15367
- apiKey: tinyMceApiKey,
15368
- onEditorChange: function onEditorChange(val, e) {
15369
- onChange === null || onChange === void 0 || onChange(name, val);
15370
- },
16154
+ function handleChange(val) {
16155
+ onChange(name, val);
16156
+ }
16157
+ return /*#__PURE__*/jsx(RTFEditor, {
15371
16158
  initialValue: val.current,
15372
- textareaName: "text",
15373
- init: {
15374
- height: 500,
15375
- menubar: false,
15376
- plugins: ['advlist autolink lists link table paste'],
15377
- contextmenu: '',
15378
- resize: false,
15379
- statusbar: false,
15380
- toolbar: 'undo redo | formatselect | ' + 'bold italic backcolor | alignleft aligncenter ' + 'alignright alignjustify | bullist numlist outdent indent | table ',
15381
- content_style: 'body { font-family:Helvetica,Arial,sans-serif; font-size:14px }'
15382
- }
16159
+ onChange: handleChange
15383
16160
  });
15384
16161
  };
16162
+ var RichTextEditor$1 = /*#__PURE__*/React.forwardRef(RichTextEditor);
15385
16163
 
15386
16164
  function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
15387
16165
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
@@ -16204,7 +16982,7 @@ var customSelect = "custom-select-ESUJX";
16204
16982
  var customSelectOption = "custom-select-option-dUA7N";
16205
16983
  var avatarWrapper = "avatar-wrapper-Vg-xe";
16206
16984
  var selectTextWrapper = "select-text-wrapper-hPSZW";
16207
- var css_248z$l = ".custom-select-ESUJX {\n width: 300px;\n}\n\n.custom-select-option-dUA7N {\n margin: 0px 12px;\n padding: 5px 0px;\n border-bottom: 1px solid #ddd;\n}\n\n.avatar-wrapper-Vg-xe {\n margin-right: 5px;\n height: 100%;\n width: 24px;\n float: left;\n position: relative;\n}\n\n.avatar-wrapper-Vg-xe > span {\n position: absolute;\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n}\n\n.select-text-wrapper-hPSZW {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: normal;\n width: calc(100% - 29px);\n}\n";
16985
+ var css_248z$l = ".custom-select-ESUJX {\n width: 300px;\n}\n\n.custom-select-option-dUA7N {\n margin: 0px 12px;\n padding: 5px 0px;\n border-bottom: 1px solid #ddd;\n}\n\n.avatar-wrapper-Vg-xe {\n margin-right: 5px;\n height: 30px;\n width: 24px;\n float: left;\n position: relative;\n}\n\n.avatar-wrapper-Vg-xe > span {\n position: absolute;\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n}\n\n.select-text-wrapper-hPSZW {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: normal;\n width: calc(100% - 29px);\n}\n";
16208
16986
  styleInject(css_248z$l);
16209
16987
 
16210
16988
  var Selector = function Selector(_ref) {
@@ -16483,14 +17261,6 @@ function useSelectData (_ref) {
16483
17261
  disabled: false
16484
17262
  };
16485
17263
  });
16486
- var val = value.length == 1 ? value[0].data : value;
16487
- if (Array.isArray(val) && val.length) {
16488
- val = val.map(function (v) {
16489
- return v.data;
16490
- });
16491
- } else if (Array.isArray(val)) {
16492
- val = initData;
16493
- }
16494
17264
  if (flow && initData.length) {
16495
17265
  var _value$, _flow$value$0$value, _value$2;
16496
17266
  if (mode != 'single') {
@@ -16522,7 +17292,7 @@ function useSelectData (_ref) {
16522
17292
  }
16523
17293
  setOptions(_toConsumableArray(flowData));
16524
17294
  }
16525
- onChange === null || onChange === void 0 || onChange(val, applyDefaultValue, defaultValue);
17295
+ onChange === null || onChange === void 0 || onChange(data, applyDefaultValue, defaultValue);
16526
17296
  setSelected(value);
16527
17297
  }
16528
17298
  }
@@ -16807,7 +17577,7 @@ var SelectWrapper = function SelectWrapper(_ref) {
16807
17577
  filterOption: false,
16808
17578
  placeholder: placeholder !== null && placeholder !== void 0 ? placeholder : t('filter.global'),
16809
17579
  allowClear: allowClear !== null && allowClear !== void 0 ? allowClear : filterServerSide,
16810
- showArrow: !filterServerSide || allowCreate || search,
17580
+ suffixIcon: filterServerSide && !allowCreate && !search ? null : undefined,
16811
17581
  mode: mode == 'single' ? undefined : mode,
16812
17582
  showSearch: filterServerSide || allowCreate || search,
16813
17583
  onSearch: filterServerSide || allowCreate || search ? state.fetch : undefined,
@@ -16823,9 +17593,7 @@ var SelectWrapper = function SelectWrapper(_ref) {
16823
17593
  value: selected
16824
17594
  });
16825
17595
  };
16826
- var Select = observer(SelectWrapper, {
16827
- forwardRef: true
16828
- });
17596
+ var Select = observer(SelectWrapper);
16829
17597
 
16830
17598
  var wrapper$3 = "wrapper-WStAk";
16831
17599
  var headerWrapper = "header-wrapper-gWQuH";
@@ -17089,9 +17857,7 @@ var Translation = function Translation(_ref) {
17089
17857
  })]
17090
17858
  });
17091
17859
  };
17092
- var Translation$1 = observer(Translation, {
17093
- forwardRef: true
17094
- });
17860
+ var Translation$1 = observer(Translation);
17095
17861
 
17096
17862
  function FileFromWeb (_ref) {
17097
17863
  var _onEnter = _ref.onEnter;
@@ -17101,8 +17867,8 @@ function FileFromWeb (_ref) {
17101
17867
  setUploadFromWeb = _useState2[1];
17102
17868
  if (uploadFromWeb) {
17103
17869
  return /*#__PURE__*/jsx(FileInput, {
17104
- onEnter: function onEnter(f) {
17105
- _onEnter(f);
17870
+ onEnter: function onEnter(f, copy) {
17871
+ _onEnter(f, copy);
17106
17872
  setUploadFromWeb(false);
17107
17873
  },
17108
17874
  onAbort: function onAbort() {
@@ -17136,6 +17902,8 @@ function FileInput(_ref3) {
17136
17902
  _useState4 = _slicedToArray(_useState3, 2),
17137
17903
  value = _useState4[0],
17138
17904
  setValue = _useState4[1];
17905
+ var _useTranslation2 = useTranslation(),
17906
+ t = _useTranslation2.t;
17139
17907
  return /*#__PURE__*/jsxs(Space, {
17140
17908
  direction: "horizontal",
17141
17909
  onClick: function onClick(e) {
@@ -17151,17 +17919,26 @@ function FileInput(_ref3) {
17151
17919
  value ? onEnter(value) : undefined;
17152
17920
  },
17153
17921
  allowClear: true
17154
- }), /*#__PURE__*/jsx(Button, {
17155
- onClick: function onClick() {
17156
- onEnter(value);
17922
+ }), /*#__PURE__*/jsx(Dropdown.Button, {
17923
+ icon: /*#__PURE__*/jsx(DownOutlined, {}),
17924
+ menu: {
17925
+ items: [{
17926
+ key: 'use',
17927
+ label: t('backoffice.mediaupload.upload'),
17928
+ onClick: function onClick() {
17929
+ onEnter(value);
17930
+ }
17931
+ }],
17932
+ onClick: function onClick() {
17933
+ return onEnter(value, true);
17934
+ }
17157
17935
  },
17158
- disabled: !value,
17159
- children: "\xDCbernehmen"
17936
+ children: t('backoffice.mediaupload.use')
17160
17937
  })]
17161
17938
  }), /*#__PURE__*/jsx(Button, {
17162
17939
  type: "link",
17163
17940
  onClick: onAbort,
17164
- children: "Abbrechen"
17941
+ children: t('backoffice.mediaupload.cancel')
17165
17942
  })]
17166
17943
  });
17167
17944
  }
@@ -17186,6 +17963,12 @@ function Upload (_ref) {
17186
17963
  return f.antdFile;
17187
17964
  });
17188
17965
  }, [files]);
17966
+ var _useState = useState(),
17967
+ _useState2 = _slicedToArray(_useState, 2),
17968
+ error = _useState2[0],
17969
+ setError = _useState2[1];
17970
+ var _useTranslation = useTranslation(),
17971
+ t = _useTranslation.t;
17189
17972
  useEffect(function () {
17190
17973
  _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
17191
17974
  return _regeneratorRuntime.wrap(function _callee$(_context) {
@@ -17234,21 +18017,22 @@ function Upload (_ref) {
17234
18017
  case 4:
17235
18018
  setFiles([media]);
17236
18019
  onAdd === null || onAdd === void 0 || onAdd(media);
17237
- _context2.next = 11;
18020
+ _context2.next = 12;
17238
18021
  break;
17239
18022
  case 8:
17240
18023
  _context2.prev = 8;
17241
18024
  _context2.t0 = _context2["catch"](1);
17242
18025
  onError === null || onError === void 0 || onError(_context2.t0);
17243
- case 11:
17244
- _context2.prev = 11;
18026
+ setError(_context2.t0.message);
18027
+ case 12:
18028
+ _context2.prev = 12;
17245
18029
  setLoading(false);
17246
- return _context2.finish(11);
17247
- case 14:
18030
+ return _context2.finish(12);
18031
+ case 15:
17248
18032
  case "end":
17249
18033
  return _context2.stop();
17250
18034
  }
17251
- }, _callee2, null, [[1, 8, 11, 14]]);
18035
+ }, _callee2, null, [[1, 8, 12, 15]]);
17252
18036
  }));
17253
18037
  return function addMediaItem(_x) {
17254
18038
  return _ref3.apply(this, arguments);
@@ -17262,31 +18046,45 @@ function Upload (_ref) {
17262
18046
  }
17263
18047
  };
17264
18048
  var beforeUpload = function beforeUpload(file) {
17265
- var mediaItem = new MediaItem(file, config);
18049
+ var mediaItem = new MediaItem({
18050
+ media: file,
18051
+ config: config
18052
+ });
17266
18053
  addMediaItem(mediaItem);
17267
18054
  return Upload$1.LIST_IGNORE;
17268
18055
  };
17269
- var onFileFormWeb = function onFileFormWeb(url) {
17270
- var mediaItem = new MediaItem(url, config);
18056
+ var onFileFormWeb = function onFileFormWeb(url, copy) {
18057
+ var mediaItem = new MediaItem({
18058
+ media: url,
18059
+ remoteUrl: !copy,
18060
+ config: config
18061
+ });
17271
18062
  addMediaItem(mediaItem);
17272
18063
  };
17273
- return /*#__PURE__*/jsx(Upload$1, {
17274
- listType: "picture",
17275
- maxCount: 1,
17276
- fileList: fileList,
17277
- beforeUpload: beforeUpload,
17278
- onRemove: onRemoveMedia,
17279
- accept: allowedTypes === null || allowedTypes === void 0 ? void 0 : allowedTypes.join(','),
17280
- children: /*#__PURE__*/jsxs(Space$1, {
17281
- direction: "horizontal",
17282
- children: [/*#__PURE__*/jsx(Button$1, {
17283
- type: "primary",
17284
- icon: /*#__PURE__*/jsx(UploadOutlined, {}),
17285
- loading: loading,
17286
- children: "Upload"
17287
- }), /*#__PURE__*/jsx(FileFromWeb, {
17288
- onEnter: onFileFormWeb
17289
- })]
18064
+ return /*#__PURE__*/jsx(Form$1.Item, {
18065
+ validateStatus: error ? 'error' : '',
18066
+ help: error ? t(error) : undefined,
18067
+ children: /*#__PURE__*/jsx(Upload$1, {
18068
+ listType: "picture",
18069
+ maxCount: 1,
18070
+ fileList: fileList,
18071
+ beforeUpload: beforeUpload,
18072
+ onRemove: onRemoveMedia,
18073
+ accept: allowedTypes === null || allowedTypes === void 0 ? void 0 : allowedTypes.join(','),
18074
+ showUploadList: {
18075
+ showRemoveIcon: !config.hideTrash
18076
+ },
18077
+ children: /*#__PURE__*/jsxs(Space$1, {
18078
+ direction: "horizontal",
18079
+ children: [/*#__PURE__*/jsx(Button$1, {
18080
+ type: "primary",
18081
+ icon: /*#__PURE__*/jsx(UploadOutlined, {}),
18082
+ loading: loading,
18083
+ children: "Upload"
18084
+ }), /*#__PURE__*/jsx(FileFromWeb, {
18085
+ onEnter: onFileFormWeb
18086
+ })]
18087
+ })
17290
18088
  })
17291
18089
  });
17292
18090
  }
@@ -17300,10 +18098,15 @@ function Media (_ref) {
17300
18098
  var urlPath = item.urlField ? absoluteName.slice(0, -1).concat(item.urlField) : undefined;
17301
18099
  var mediaItemRefId = mediaItemRefIdPath ? state.getData(mediaItemRefIdPath, state.data) : undefined;
17302
18100
  var url = urlPath ? state.getData(urlPath, state.data) : undefined;
17303
- var _React$useState = React.useState(value ? new MediaItem(url, {
17304
- baseUrl: state.root.configurationStore.apiConfig.mediaService,
17305
- jwt: state.root.dataStore.jwt
17306
- }, value, mediaItemRefId) : undefined),
18101
+ var _React$useState = React.useState(value ? new MediaItem({
18102
+ media: url,
18103
+ config: {
18104
+ baseUrl: state.root.configurationStore.apiConfig.mediaService,
18105
+ jwt: state.root.dataStore.jwt
18106
+ },
18107
+ mediaItemId: value,
18108
+ mediaItemRefId: mediaItemRefId
18109
+ }) : undefined),
17307
18110
  _React$useState2 = _slicedToArray(_React$useState, 2),
17308
18111
  media = _React$useState2[0],
17309
18112
  setMedia = _React$useState2[1];
@@ -17339,7 +18142,8 @@ function Media (_ref) {
17339
18142
  onError: onError,
17340
18143
  config: {
17341
18144
  baseUrl: state.root.configurationStore.apiConfig.mediaService,
17342
- jwt: state.root.dataStore.jwt
18145
+ jwt: state.root.dataStore.jwt,
18146
+ hideTrash: item.hideTrash
17343
18147
  }
17344
18148
  });
17345
18149
  }
@@ -17356,6 +18160,7 @@ function getElement(item, setCanSave, state, absoluteName, _onChange, _onError,
17356
18160
  switch (item.type) {
17357
18161
  case 'select':
17358
18162
  return /*#__PURE__*/jsx(Select, {
18163
+ value: item.value,
17359
18164
  initialValue: item.defaultValue,
17360
18165
  apiInterface: item.apiInterface,
17361
18166
  mode: item.mode,
@@ -17467,7 +18272,7 @@ function getElement(item, setCanSave, state, absoluteName, _onChange, _onError,
17467
18272
  children: item.label
17468
18273
  });
17469
18274
  case 'richText':
17470
- return /*#__PURE__*/jsx(RichTextEditor, {
18275
+ return /*#__PURE__*/jsx(RichTextEditor$1, {
17471
18276
  initValue: state.getData(absoluteName, state.data),
17472
18277
  name: absoluteName,
17473
18278
  onChange: _onChange
@@ -17527,6 +18332,18 @@ function getElement(item, setCanSave, state, absoluteName, _onChange, _onError,
17527
18332
  return /*#__PURE__*/jsx(DatePicker, {
17528
18333
  disabled: disabled
17529
18334
  });
18335
+ case 'progress':
18336
+ return /*#__PURE__*/jsx(InputComponent$1, {
18337
+ item: item,
18338
+ data: state.data,
18339
+ onChange: state.onInputChanged
18340
+ });
18341
+ case 'dateinput':
18342
+ return /*#__PURE__*/jsx(InputComponent$1, {
18343
+ item: item,
18344
+ data: state.data,
18345
+ onChange: state.onInputChanged
18346
+ });
17530
18347
  case 'subTitle':
17531
18348
  return /*#__PURE__*/jsx(SubTitle$1, {
17532
18349
  item: item,
@@ -17569,6 +18386,7 @@ function getElement(item, setCanSave, state, absoluteName, _onChange, _onError,
17569
18386
  });
17570
18387
  case 'radio':
17571
18388
  return /*#__PURE__*/jsx(Radio.Group, {
18389
+ defaultValue: item.defaultValue,
17572
18390
  value: item.value,
17573
18391
  options: item.options.map(function (o) {
17574
18392
  var _o$disabled;
@@ -17607,14 +18425,15 @@ function getElement(item, setCanSave, state, absoluteName, _onChange, _onError,
17607
18425
  return /*#__PURE__*/jsx(Fragment, {});
17608
18426
  }
17609
18427
  }
17610
- function DisplayInput(props) {
18428
+ var DisplayInput = /*#__PURE__*/React.forwardRef(function (props, ref) {
17611
18429
  var _useTranslation = useTranslation(),
17612
18430
  t = _useTranslation.t;
17613
18431
  return /*#__PURE__*/jsx(Input, _objectSpread$A(_objectSpread$A({}, props), {}, {
18432
+ ref: ref,
17614
18433
  disabled: true,
17615
18434
  value: t(props.translationPrefix + '.' + props.value)
17616
18435
  }));
17617
- }
18436
+ });
17618
18437
  function isReadonly(item, data) {
17619
18438
  if (_typeof(item.readonly) != 'object') {
17620
18439
  return item.readonly;
@@ -18025,9 +18844,7 @@ function getLabel(item, t) {
18025
18844
  if (!item.label && item.type === 'button') return undefined;
18026
18845
  return item.label ? t(item.label, item.label) : item.name;
18027
18846
  }
18028
- var Form = observer(FormWrapper$1, {
18029
- forwardRef: true
18030
- });
18847
+ var Form = observer(/*#__PURE__*/React.forwardRef(FormWrapper$1));
18031
18848
 
18032
18849
  function ownKeys$y(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
18033
18850
  function _objectSpread$y(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$y(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$y(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
@@ -18781,9 +19598,7 @@ var RoleSelector = function RoleSelector(_ref, ref) {
18781
19598
  })
18782
19599
  });
18783
19600
  };
18784
- var RoleSelector$1 = observer(RoleSelector, {
18785
- forwardRef: true
18786
- });
19601
+ var RoleSelector$1 = observer(/*#__PURE__*/React.forwardRef(RoleSelector));
18787
19602
 
18788
19603
  var permissionButton = "permission-Button-XctsZ";
18789
19604
  var select$1 = "select-lzft-";
@@ -19575,7 +20390,7 @@ function ActionButton (_ref) {
19575
20390
  try {
19576
20391
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
19577
20392
  var dt = _step.value;
19578
- if ((action.rule ? !aplyRule({
20393
+ if ((action.rule ? !applyRule({
19579
20394
  rules: action.rule,
19580
20395
  data: dt,
19581
20396
  rootStore: root
@@ -19590,7 +20405,7 @@ function ActionButton (_ref) {
19590
20405
  _iterator.f();
19591
20406
  }
19592
20407
  } else {
19593
- disable = disabled !== null && disabled !== void 0 ? disabled : action.rule ? !aplyRule({
20408
+ disable = disabled !== null && disabled !== void 0 ? disabled : action.rule ? !applyRule({
19594
20409
  rules: action.rule,
19595
20410
  data: ruleData !== null && ruleData !== void 0 ? ruleData : data,
19596
20411
  rootStore: root
@@ -20285,9 +21100,7 @@ var RelationSelector = function RelationSelector(_ref, ref) {
20285
21100
  })]
20286
21101
  });
20287
21102
  };
20288
- var RelationSelector$1 = observer(RelationSelector, {
20289
- forwardRef: true
20290
- });
21103
+ var RelationSelector$1 = observer(/*#__PURE__*/React.forwardRef(RelationSelector));
20291
21104
 
20292
21105
  function ownKeys$t(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
20293
21106
  function _objectSpread$t(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$t(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$t(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
@@ -20505,9 +21318,7 @@ var FormList = function FormList(_ref, ref) {
20505
21318
  })]
20506
21319
  });
20507
21320
  };
20508
- var FormList$1 = observer(FormList, {
20509
- forwardRef: true
20510
- });
21321
+ var FormList$1 = observer(/*#__PURE__*/React.forwardRef(FormList));
20511
21322
 
20512
21323
  function ownKeys$s(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
20513
21324
  function _objectSpread$s(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$s(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$s(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
@@ -20844,7 +21655,7 @@ var FormWrapper = function FormWrapper(_ref, ref) {
20844
21655
  placeholder: t('filter.global'),
20845
21656
  mode: mode == 'single' ? undefined : mode,
20846
21657
  allowClear: true,
20847
- showArrow: false,
21658
+ suffixIcon: null,
20848
21659
  showSearch: true,
20849
21660
  onSearch: state.fetch,
20850
21661
  notFoundContent: state.fetching ? /*#__PURE__*/jsx(Spin, {
@@ -20864,9 +21675,7 @@ var FormWrapper = function FormWrapper(_ref, ref) {
20864
21675
  })]
20865
21676
  });
20866
21677
  };
20867
- var SelectOrCreate = observer(FormWrapper, {
20868
- forwardRef: true
20869
- });
21678
+ var SelectOrCreate = observer(/*#__PURE__*/React.forwardRef(FormWrapper));
20870
21679
  var Single = function Single(_ref2) {
20871
21680
  var _state$selected$;
20872
21681
  var state = _ref2.state;
@@ -21233,9 +22042,7 @@ var ListWrapper = function ListWrapper(props, ref) {
21233
22042
  }
21234
22043
  });
21235
22044
  };
21236
- var List = observer(ListWrapper, {
21237
- forwardRef: true
21238
- });
22045
+ var List = observer(/*#__PURE__*/React.forwardRef(ListWrapper));
21239
22046
 
21240
22047
  var LOG$5 = getLogger('Backoffice', 'JsonEditor');
21241
22048
  function useJsonEditorData (id, setCanSave, onChange, onError) {
@@ -21485,9 +22292,7 @@ var JsonEditor = function JsonEditor(_ref, ref) {
21485
22292
  })
21486
22293
  });
21487
22294
  };
21488
- var JsonEditor$1 = observer(JsonEditor, {
21489
- forwardRef: true
21490
- });
22295
+ var JsonEditor$1 = observer(/*#__PURE__*/React.forwardRef(JsonEditor));
21491
22296
 
21492
22297
  function ConfirmationPopup(props) {
21493
22298
  var _useTranslation = useTranslation(),
@@ -21728,7 +22533,7 @@ var ImageCropper = function ImageCropper(_ref, ref) {
21728
22533
  onChange: function onChange(e) {
21729
22534
  return aspect ? setKeepAspect(undefined) : setKeepAspect(crop.width / crop.height);
21730
22535
  }
21731
- }), "Echte Gr\xF6\xDFe x: ", realSize.x, "px y: ", realSize.y, "px"]
22536
+ }), "Echte Gr\xF6\xDFe x: ", realSize.x.toString(), "px y: ", realSize.y.toString(), "px"]
21732
22537
  }), /*#__PURE__*/jsx(ReactCrop, {
21733
22538
  crop: crop,
21734
22539
  onChange: function onChange(_, percentCrop) {
@@ -21763,9 +22568,7 @@ var ImageCropper = function ImageCropper(_ref, ref) {
21763
22568
  })]
21764
22569
  });
21765
22570
  };
21766
- var ImageCropper$1 = observer(ImageCropper, {
21767
- forwardRef: true
21768
- });
22571
+ var ImageCropper$1 = observer(/*#__PURE__*/React.forwardRef(ImageCropper));
21769
22572
 
21770
22573
  function _createForOfIteratorHelper$9(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray$9(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
21771
22574
  function _unsupportedIterableToArray$9(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray$9(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray$9(r, a) : void 0; } }
@@ -22213,8 +23016,10 @@ var ToolTipInfo = function ToolTipInfo(props) {
22213
23016
  className: wrapper$2,
22214
23017
  children: /*#__PURE__*/jsx(Card, {
22215
23018
  title: t('backoffice.tooltipinfo.useroverview'),
22216
- bodyStyle: {
22217
- padding: 10
23019
+ styles: {
23020
+ body: {
23021
+ padding: 10
23022
+ }
22218
23023
  },
22219
23024
  bordered: false,
22220
23025
  style: {
@@ -22405,7 +23210,7 @@ var useMediaUpload = function useMediaUpload(_ref) {
22405
23210
  var small = "small-NY1-k";
22406
23211
  var medium = "medium---QcO";
22407
23212
  var big = "big--E39S";
22408
- var css_248z$d = ".diva-component-DIVA_BACKOFFICE_NEW .ant-upload-wrapper {\n width: 100%;\n height: 100%;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-spin-nested-loading {\n width: 100%;\n height: 100%;\n}\n.diva-component-DIVA_BACKOFFICE_NEW .ant-table-wrapper, .diva-component-DIVA_BACKOFFICE_NEW .ant-table {\n height: inherit;\n overflow: auto;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-spin-container {\n width: 100%;\n height: 100%;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .andt-table .ant-spin-container {\n display: flex;\n flex-direction: column;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-space-item .andt-table .ant-spin-container {\n height: calc(60vh - 90px);\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .andt-table .ant-table-container {\n height: calc(100% - 80px);\n}\n.diva-component-DIVA_BACKOFFICE_NEW .ant-upload-list {\n width: 100%;\n height: 100%;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-upload-list-item-container {\n width: 100% !important;\n height: 100% !important;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-upload-select {\n width: 100% !important;\n height: 100% !important;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .small-NY1-k {\n width: 104px;\n height: 104px;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .medium---QcO {\n width: 200px;\n height: 200px;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .big--E39S {\n width: 400px;\n height: 400px;\n}\n";
23213
+ var css_248z$d = ".diva-component-DIVA_BACKOFFICE_NEW .ant-upload-wrapper {\n width: 100%;\n height: 100%;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-spin-nested-loading {\n width: 100%;\n height: 100%;\n}\n.diva-component-DIVA_BACKOFFICE_NEW .ant-table-wrapper, .diva-component-DIVA_BACKOFFICE_NEW .ant-table {\n height: inherit;\n overflow: auto;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-drawer-body .ant-spin-nested-loading {\n width: 100%;\n height: 80%;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-spin-container {\n width: 100%;\n height: 100%;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .andt-table .ant-spin-container {\n display: flex;\n flex-direction: column;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-space-item .andt-table .ant-spin-container {\n height: calc(60vh - 90px);\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .andt-table .ant-table-container {\n height: calc(100% - 80px);\n}\n.diva-component-DIVA_BACKOFFICE_NEW .ant-upload-list {\n width: 100%;\n height: 100%;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-upload-list-item-container {\n width: 100% !important;\n height: 100% !important;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .ant-upload-select {\n width: 100% !important;\n height: 100% !important;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .small-NY1-k {\n width: 104px;\n height: 104px;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .medium---QcO {\n width: 200px;\n height: 200px;\n}\n\n.diva-component-DIVA_BACKOFFICE_NEW .big--E39S {\n width: 400px;\n height: 400px;\n}\n";
22409
23214
  styleInject(css_248z$d);
22410
23215
 
22411
23216
  var MediaUpload = observer(function (_ref) {
@@ -22448,8 +23253,8 @@ function getExpandedRowRenderer (config, root) {
22448
23253
  return function (record) {
22449
23254
  var data = record;
22450
23255
  if (config.mapping) {
22451
- data = aplyMapping({
22452
- mapable: {},
23256
+ data = applyMapping({
23257
+ mappable: {},
22453
23258
  mapping: config.mapping,
22454
23259
  mappingData: record,
22455
23260
  rootStore: root
@@ -22769,7 +23574,7 @@ function DropdownCell (_ref) {
22769
23574
  width: column.width - 20
22770
23575
  },
22771
23576
  onChange: save,
22772
- bordered: false,
23577
+ variant: "borderless",
22773
23578
  disabled: !((_column$flow = column.flow) !== null && _column$flow !== void 0 && (_column$flow = _column$flow[children[1]]) !== null && _column$flow !== void 0 && _column$flow.length),
22774
23579
  options: (_column$flow2 = column.flow) === null || _column$flow2 === void 0 || (_column$flow2 = _column$flow2[children[1]]) === null || _column$flow2 === void 0 ? void 0 : _column$flow2.map(function (opt) {
22775
23580
  return {
@@ -22804,6 +23609,8 @@ if (!window.customElements.get('model-viewer')) {
22804
23609
  function MediaViewerCell (_ref) {
22805
23610
  var children = _ref.children,
22806
23611
  column = _ref.column;
23612
+ var _useDivaCore = useDivaCore(),
23613
+ isFirefox = _useDivaCore.state.isFirefox;
22807
23614
  if (!(children !== null && children !== void 0 && children[1])) {
22808
23615
  return /*#__PURE__*/jsx(Fragment, {});
22809
23616
  }
@@ -22849,7 +23656,7 @@ function MediaViewerCell (_ref) {
22849
23656
  src: children[1],
22850
23657
  ar: true,
22851
23658
  "ar-scale": 'fixed',
22852
- "ar-modes": 'webxr quick-look',
23659
+ "ar-modes": !isFirefox ? 'webxr quick-look' : '',
22853
23660
  "shadow-intensity": "1",
22854
23661
  "camera-controls": true,
22855
23662
  "touch-action": "pan-y",
@@ -22915,12 +23722,12 @@ function UnixTimeStampCell (_ref) {
22915
23722
  }
22916
23723
 
22917
23724
  function UnixTimeStampCheckCell (_ref) {
22918
- var _ref2;
23725
+ var _checkTime;
22919
23726
  var children = _ref.children,
22920
23727
  column = _ref.column;
22921
23728
  _ref.dataIndex;
22922
23729
  _ref.save;
22923
- if ((_ref2 = (Date.now() - children[1]) / 1000 / 60 >= column.checkTime) !== null && _ref2 !== void 0 ? _ref2 : 15) {
23730
+ if ((Date.now() - children[1]) / 1000 / 60 >= ((_checkTime = column.checkTime) !== null && _checkTime !== void 0 ? _checkTime : 15)) {
22924
23731
  return /*#__PURE__*/jsx("span", {
22925
23732
  style: {
22926
23733
  whiteSpace: 'nowrap'
@@ -22989,6 +23796,8 @@ function MediaItemViewerCell (_ref) {
22989
23796
  timeStamp = _useState4[0],
22990
23797
  setTimeStamp = _useState4[1];
22991
23798
  var id;
23799
+ var _useDivaCore = useDivaCore(),
23800
+ isFirefox = _useDivaCore.state.isFirefox;
22992
23801
 
22993
23802
  //! for renderjob table mediaItems because can't filter mediaItems.0
22994
23803
  if (Array.isArray(children[1])) {
@@ -23020,9 +23829,9 @@ function MediaItemViewerCell (_ref) {
23020
23829
  });
23021
23830
  }, [timeStamp, id]);
23022
23831
  if (!id) return /*#__PURE__*/jsx(FileUnknownOutlined, {});
23023
- var _useDivaCore = useDivaCore(),
23024
- handler = _useDivaCore.handler,
23025
- actions = _useDivaCore.actions;
23832
+ var _useDivaCore2 = useDivaCore(),
23833
+ handler = _useDivaCore2.handler,
23834
+ actions = _useDivaCore2.actions;
23026
23835
  var openModelViewer = function openModelViewer() {
23027
23836
  actions.openFullscreen({
23028
23837
  content: /*#__PURE__*/jsx("model-viewer", {
@@ -23030,7 +23839,7 @@ function MediaItemViewerCell (_ref) {
23030
23839
  src: children[1],
23031
23840
  ar: true,
23032
23841
  "ar-scale": 'fixed',
23033
- "ar-modes": 'webxr quick-look',
23842
+ "ar-modes": !isFirefox ? 'webxr quick-look' : '',
23034
23843
  "shadow-intensity": "1",
23035
23844
  "camera-controls": true,
23036
23845
  "touch-action": "pan-y",
@@ -23150,7 +23959,7 @@ var CustomCell = function CustomCell(_ref2) {
23150
23959
  return form.validateFields();
23151
23960
  case 3:
23152
23961
  values = _context.sent;
23153
- handleSave(merge(record, values));
23962
+ handleSave(merge$1(record, values));
23154
23963
  _context.next = 10;
23155
23964
  break;
23156
23965
  case 7:
@@ -23463,7 +24272,6 @@ function AGHistogram (_ref) {
23463
24272
  if (subtitle) parseSubTitle = subtitle.text + eval(subtitle.variable);
23464
24273
  setOptions({
23465
24274
  data: data.bulks,
23466
- autoSize: true,
23467
24275
  theme: {
23468
24276
  baseTheme: root.contentStore.theme == 'darkmode' ? 'ag-default-dark' : 'ag-default'
23469
24277
  },
@@ -23534,7 +24342,7 @@ function AGHistogram (_ref) {
23534
24342
  height: height,
23535
24343
  width: width
23536
24344
  },
23537
- children: options && /*#__PURE__*/jsx(AgChartsReact, {
24345
+ children: options && /*#__PURE__*/jsx(AgCharts, {
23538
24346
  options: options
23539
24347
  })
23540
24348
  }), loadingHistogram && /*#__PURE__*/jsx("div", {
@@ -23587,7 +24395,7 @@ dayjs.extend(weekYear);
23587
24395
  Select$1.Option;
23588
24396
  var LOG$3 = getLogger('Backoffice', 'BaseTable');
23589
24397
  var TableWrapper = function TableWrapper(_ref) {
23590
- var _state$configuration$, _state$configuration$2, _state$configuration$3, _state$configuration$4, _state$configuration$5, _state$configuration$6, _state$globalFilter, _state$globalFilter2, _state$globalFilter3, _state$globalFilter4, _state$configuration$7, _state$configuration$8, _state$globalFilter$s, _state$configuration$9, _state$configuration$10, _state$configuration$11, _state$selected2, _state$configuration$12, _state$configuration$13, _state$configuration$14, _state$configuration$17, _state$configuration$18, _state$configuration$19;
24398
+ var _state$configuration$, _toggleConfig$label, _toggleConfig$labelOf, _state$globalFilter, _state$configuration$2, _state$configuration$3, _state$globalFilter2, _state$globalFilter3, _state$globalFilter4, _state$globalFilter5, _state$configuration$4, _state$configuration$5, _state$globalFilter$s, _state$configuration$6, _state$configuration$7, _state$configuration$8, _state$configuration$9, _state$configuration$10, _state$selected2, _state$configuration$11, _state$configuration$12, _state$configuration$13, _state$configuration$16, _state$configuration$17, _state$configuration$18;
23591
24399
  var state = _ref.state;
23592
24400
  var root = useStore();
23593
24401
  var _useState = useState(0),
@@ -23681,6 +24489,7 @@ var TableWrapper = function TableWrapper(_ref) {
23681
24489
  if (!permission) return true;
23682
24490
  return root.actions.userHasPermission(permission);
23683
24491
  }
24492
+ var toggleConfig = (_state$configuration$ = state.configuration.filter) === null || _state$configuration$ === void 0 ? void 0 : _state$configuration$.toggle;
23684
24493
  return /*#__PURE__*/jsxs(Fragment, {
23685
24494
  children: [(state.canDelete || state.configuration.createAction || state.title || state.configuration.canRefresh || state.configuration.clientRelations) && /*#__PURE__*/jsx(Fragment, {
23686
24495
  children: /*#__PURE__*/jsx(Descriptions, {
@@ -23739,16 +24548,17 @@ var TableWrapper = function TableWrapper(_ref) {
23739
24548
  state.triggerRefresh();
23740
24549
  },
23741
24550
  children: /*#__PURE__*/jsx(ReloadOutlined, {})
23742
- }), ((_state$configuration$ = state.configuration.filter) === null || _state$configuration$ === void 0 ? void 0 : _state$configuration$.toggle) && (!state.configuration.filter.toggle.permission || root.actions.userHasPermission(state.configuration.filter.toggle.permission)) && /*#__PURE__*/jsx("div", {
24551
+ }), toggleConfig && (!toggleConfig.permission || root.actions.userHasPermission(toggleConfig.permission)) && /*#__PURE__*/jsx("div", {
23743
24552
  children: /*#__PURE__*/jsx(Switch, {
23744
- defaultChecked: (_state$configuration$2 = state.configuration.filter) === null || _state$configuration$2 === void 0 ? void 0 : _state$configuration$2.toggle.defaultChecked,
23745
- checkedChildren: (_state$configuration$3 = state.configuration.filter.toggle.label) !== null && _state$configuration$3 !== void 0 ? _state$configuration$3 : 'unfiltered',
23746
- unCheckedChildren: (_state$configuration$4 = state.configuration.filter.toggle.labelOff) !== null && _state$configuration$4 !== void 0 ? _state$configuration$4 : 'filtered',
24553
+ defaultChecked: toggleConfig.defaultChecked,
24554
+ checkedChildren: (_toggleConfig$label = toggleConfig.label) !== null && _toggleConfig$label !== void 0 ? _toggleConfig$label : 'unfiltered',
24555
+ unCheckedChildren: (_toggleConfig$labelOf = toggleConfig.labelOff) !== null && _toggleConfig$labelOf !== void 0 ? _toggleConfig$labelOf : 'filtered',
23747
24556
  onChange: function onChange() {
23748
24557
  return state.onGlobalFilterToggle();
23749
- }
24558
+ },
24559
+ checked: !!((_state$globalFilter = state.globalFilter) !== null && _state$globalFilter !== void 0 && _state$globalFilter.toggle) != !!toggleConfig.inverted
23750
24560
  })
23751
- }), ((_state$configuration$5 = state.configuration.filter) === null || _state$configuration$5 === void 0 ? void 0 : _state$configuration$5.search) && /*#__PURE__*/jsx(Input.Search, {
24561
+ }), ((_state$configuration$2 = state.configuration.filter) === null || _state$configuration$2 === void 0 ? void 0 : _state$configuration$2.search) && /*#__PURE__*/jsx(Input.Search, {
23752
24562
  placeholder: t('filter.global'),
23753
24563
  onSearch: function onSearch(v) {
23754
24564
  return state.onGlobalFilterSearch(v);
@@ -23757,17 +24567,17 @@ var TableWrapper = function TableWrapper(_ref) {
23757
24567
  style: {
23758
24568
  width: 200
23759
24569
  }
23760
- }), ((_state$configuration$6 = state.configuration.filter) === null || _state$configuration$6 === void 0 ? void 0 : _state$configuration$6.period) && /*#__PURE__*/jsx(DatePicker.RangePicker, {
24570
+ }), ((_state$configuration$3 = state.configuration.filter) === null || _state$configuration$3 === void 0 ? void 0 : _state$configuration$3.period) && /*#__PURE__*/jsx(DatePicker.RangePicker, {
23761
24571
  onCalendarChange: function onCalendarChange(values) {
23762
24572
  if (values && values[0] && values[1]) {
23763
24573
  state.onGlobalFilterPeriod(values[0].valueOf(), values[1].valueOf());
23764
24574
  }
23765
24575
  },
23766
- value: [(_state$globalFilter = state.globalFilter) !== null && _state$globalFilter !== void 0 && (_state$globalFilter = _state$globalFilter.timeStamp) !== null && _state$globalFilter !== void 0 && (_state$globalFilter = _state$globalFilter['fromTimeStamp']) !== null && _state$globalFilter !== void 0 && _state$globalFilter[0] ? dayjs((_state$globalFilter2 = state.globalFilter) === null || _state$globalFilter2 === void 0 || (_state$globalFilter2 = _state$globalFilter2.timeStamp) === null || _state$globalFilter2 === void 0 || (_state$globalFilter2 = _state$globalFilter2['fromTimeStamp']) === null || _state$globalFilter2 === void 0 ? void 0 : _state$globalFilter2[0]) : dayjs(new Date(Date.now() - 30 * 24 * 60 * 60 * 1000)),
24576
+ value: [(_state$globalFilter2 = state.globalFilter) !== null && _state$globalFilter2 !== void 0 && (_state$globalFilter2 = _state$globalFilter2.timeStamp) !== null && _state$globalFilter2 !== void 0 && (_state$globalFilter2 = _state$globalFilter2['fromTimeStamp']) !== null && _state$globalFilter2 !== void 0 && _state$globalFilter2[0] ? dayjs((_state$globalFilter3 = state.globalFilter) === null || _state$globalFilter3 === void 0 || (_state$globalFilter3 = _state$globalFilter3.timeStamp) === null || _state$globalFilter3 === void 0 || (_state$globalFilter3 = _state$globalFilter3['fromTimeStamp']) === null || _state$globalFilter3 === void 0 ? void 0 : _state$globalFilter3[0]) : dayjs(new Date(Date.now() - 30 * 24 * 60 * 60 * 1000)),
23767
24577
  // Convert to Dayjs
23768
- (_state$globalFilter3 = state.globalFilter) !== null && _state$globalFilter3 !== void 0 && (_state$globalFilter3 = _state$globalFilter3.timeStamp) !== null && _state$globalFilter3 !== void 0 && (_state$globalFilter3 = _state$globalFilter3['toTimeStamp']) !== null && _state$globalFilter3 !== void 0 && _state$globalFilter3[0] ? dayjs((_state$globalFilter4 = state.globalFilter) === null || _state$globalFilter4 === void 0 || (_state$globalFilter4 = _state$globalFilter4.timeStamp) === null || _state$globalFilter4 === void 0 || (_state$globalFilter4 = _state$globalFilter4['toTimeStamp']) === null || _state$globalFilter4 === void 0 ? void 0 : _state$globalFilter4[0]) : dayjs(new Date()) // Convert to Dayjs
24578
+ (_state$globalFilter4 = state.globalFilter) !== null && _state$globalFilter4 !== void 0 && (_state$globalFilter4 = _state$globalFilter4.timeStamp) !== null && _state$globalFilter4 !== void 0 && (_state$globalFilter4 = _state$globalFilter4['toTimeStamp']) !== null && _state$globalFilter4 !== void 0 && _state$globalFilter4[0] ? dayjs((_state$globalFilter5 = state.globalFilter) === null || _state$globalFilter5 === void 0 || (_state$globalFilter5 = _state$globalFilter5.timeStamp) === null || _state$globalFilter5 === void 0 || (_state$globalFilter5 = _state$globalFilter5['toTimeStamp']) === null || _state$globalFilter5 === void 0 ? void 0 : _state$globalFilter5[0]) : dayjs(new Date()) // Convert to Dayjs
23769
24579
  ]
23770
- }), ((_state$configuration$7 = state.configuration.filter) === null || _state$configuration$7 === void 0 ? void 0 : _state$configuration$7.select) && /*#__PURE__*/jsx(SimpleSelect, _objectSpread$l(_objectSpread$l({}, (_state$configuration$8 = state.configuration.filter) === null || _state$configuration$8 === void 0 ? void 0 : _state$configuration$8.select.settings), {}, {
24580
+ }), ((_state$configuration$4 = state.configuration.filter) === null || _state$configuration$4 === void 0 ? void 0 : _state$configuration$4.select) && /*#__PURE__*/jsx(SimpleSelect, _objectSpread$l(_objectSpread$l({}, (_state$configuration$5 = state.configuration.filter) === null || _state$configuration$5 === void 0 ? void 0 : _state$configuration$5.select.settings), {}, {
23771
24581
  style: {
23772
24582
  minWidth: '200px'
23773
24583
  },
@@ -23780,17 +24590,19 @@ var TableWrapper = function TableWrapper(_ref) {
23780
24590
  }), state.canDelete && /*#__PURE__*/jsx(DeleteButton, {
23781
24591
  selected: state.selected,
23782
24592
  total: state.pagination.total,
23783
- min: (_state$configuration$9 = state.configuration.rules) === null || _state$configuration$9 === void 0 ? void 0 : _state$configuration$9.min,
24593
+ min: (_state$configuration$6 = state.configuration.rules) === null || _state$configuration$6 === void 0 ? void 0 : _state$configuration$6.min,
23784
24594
  deleting: state.deleting,
23785
24595
  onDelete: state.onDelete,
23786
- disabled: !!((_state$configuration$10 = state.configuration.deleteAction) !== null && _state$configuration$10 !== void 0 && (_state$configuration$11 = _state$configuration$10.disabled) !== null && _state$configuration$11 !== void 0 && _state$configuration$11.call(_state$configuration$10, ((_state$selected2 = state.selected) !== null && _state$selected2 !== void 0 ? _state$selected2 : []).map(function (id) {
24596
+ label: (_state$configuration$7 = state.configuration.deleteAction) === null || _state$configuration$7 === void 0 ? void 0 : _state$configuration$7.label,
24597
+ labelDialog: (_state$configuration$8 = state.configuration.deleteAction) === null || _state$configuration$8 === void 0 ? void 0 : _state$configuration$8.labelDialog,
24598
+ disabled: !!((_state$configuration$9 = state.configuration.deleteAction) !== null && _state$configuration$9 !== void 0 && (_state$configuration$10 = _state$configuration$9.disabled) !== null && _state$configuration$10 !== void 0 && _state$configuration$10.call(_state$configuration$9, ((_state$selected2 = state.selected) !== null && _state$selected2 !== void 0 ? _state$selected2 : []).map(function (id) {
23787
24599
  return state.data.find(function (d) {
23788
24600
  return d._id == id;
23789
24601
  });
23790
24602
  })))
23791
24603
  }), state.configuration.copyAction !== undefined && /*#__PURE__*/jsx(CopyButton, {
23792
24604
  state: state
23793
- }), (_state$configuration$12 = state.configuration.bulkActions) === null || _state$configuration$12 === void 0 ? void 0 : _state$configuration$12.map(function (action) {
24605
+ }), (_state$configuration$11 = state.configuration.bulkActions) === null || _state$configuration$11 === void 0 ? void 0 : _state$configuration$11.map(function (action) {
23794
24606
  return /*#__PURE__*/jsx(BulkAction, {
23795
24607
  action: action,
23796
24608
  state: state,
@@ -23801,26 +24613,26 @@ var TableWrapper = function TableWrapper(_ref) {
23801
24613
  setProgressBarPercentage: setProgressBarPercentage
23802
24614
  } : undefined
23803
24615
  }, action.id);
23804
- }), state.configuration.createAction && checkPermission(state.configuration.createAction.permission) && !((_state$configuration$13 = (_state$configuration$14 = state.configuration.createAction).hidden) !== null && _state$configuration$13 !== void 0 && _state$configuration$13.call(_state$configuration$14, data)) && /*#__PURE__*/jsx(ActionButton, {
24616
+ }), state.configuration.createAction && checkPermission(state.configuration.createAction.permission) && !((_state$configuration$12 = (_state$configuration$13 = state.configuration.createAction).hidden) !== null && _state$configuration$12 !== void 0 && _state$configuration$12.call(_state$configuration$13, data)) && /*#__PURE__*/jsx(ActionButton, {
23805
24617
  action: state.configuration.createAction,
23806
24618
  callback: function callback(data) {
23807
- var _state$onUpdate, _state$configuration$15, _state$configuration$16;
24619
+ var _state$onUpdate, _state$configuration$14, _state$configuration$15;
23808
24620
  (_state$onUpdate = state.onUpdate) === null || _state$onUpdate === void 0 || _state$onUpdate.call(state, data);
23809
- (_state$configuration$15 = state.configuration.createAction) === null || _state$configuration$15 === void 0 || (_state$configuration$16 = _state$configuration$15.callback) === null || _state$configuration$16 === void 0 || _state$configuration$16.call(_state$configuration$15, data);
24621
+ (_state$configuration$14 = state.configuration.createAction) === null || _state$configuration$14 === void 0 || (_state$configuration$15 = _state$configuration$14.callback) === null || _state$configuration$15 === void 0 || _state$configuration$15.call(_state$configuration$14, data);
23810
24622
  },
23811
24623
  type: "Button",
23812
24624
  id: 'create',
23813
24625
  defaultLabel: t('backoffice.table.emailtemplates.createAction.title'),
23814
24626
  isCreateButton: true,
23815
- disabled: state.configuration.createAction.disableOnToggle === !!state.globalFilter.toggle || ((_state$configuration$17 = (_state$configuration$18 = state.configuration.createAction).disabled) === null || _state$configuration$17 === void 0 ? void 0 : _state$configuration$17.call(_state$configuration$18, data)),
23816
- data: state.configuration.createActionMapping ? aplyMapping({
23817
- mapable: {},
24627
+ disabled: state.configuration.createAction.disableOnToggle === !!state.globalFilter.toggle || ((_state$configuration$16 = (_state$configuration$17 = state.configuration.createAction).disabled) === null || _state$configuration$16 === void 0 ? void 0 : _state$configuration$16.call(_state$configuration$17, data)),
24628
+ data: state.configuration.createActionMapping ? applyMapping({
24629
+ mappable: {},
23818
24630
  mapping: state.configuration.createActionMapping,
23819
24631
  mappingData: state.mappingData,
23820
24632
  rootStore: root
23821
24633
  }) : undefined,
23822
- ruleData: state.configuration.createActionRuleMapping ? aplyMapping({
23823
- mapable: {},
24634
+ ruleData: state.configuration.createActionRuleMapping ? applyMapping({
24635
+ mappable: {},
23824
24636
  mapping: state.configuration.createActionRuleMapping,
23825
24637
  mappingData: state.mappingData,
23826
24638
  rootStore: root
@@ -23860,13 +24672,13 @@ var TableWrapper = function TableWrapper(_ref) {
23860
24672
  className: "andt-table",
23861
24673
  scroll: {
23862
24674
  x: '100%',
23863
- y: (_state$configuration$19 = state.configuration.height) !== null && _state$configuration$19 !== void 0 ? _state$configuration$19 : '100%'
24675
+ y: (_state$configuration$18 = state.configuration.height) !== null && _state$configuration$18 !== void 0 ? _state$configuration$18 : '100%'
23864
24676
  },
23865
24677
  rowClassName: editableRow,
23866
24678
  components: cellRenderer,
23867
24679
  rowKey: function rowKey(dataRow) {
23868
- var _state$configuration$20, _state$configuration$21;
23869
- return goTroughObject(dataRow, (_state$configuration$20 = (_state$configuration$21 = state.configuration.rowKey) === null || _state$configuration$21 === void 0 ? void 0 : _state$configuration$21.split('.')) !== null && _state$configuration$20 !== void 0 ? _state$configuration$20 : ['_id'], 0);
24680
+ var _state$configuration$19, _state$configuration$20;
24681
+ return goTroughObject(dataRow, (_state$configuration$19 = (_state$configuration$20 = state.configuration.rowKey) === null || _state$configuration$20 === void 0 ? void 0 : _state$configuration$20.split('.')) !== null && _state$configuration$19 !== void 0 ? _state$configuration$19 : ['_id'], 0);
23870
24682
  },
23871
24683
  dataSource: data,
23872
24684
  loading: state.loading,
@@ -23907,13 +24719,15 @@ function DeleteButton(_ref2) {
23907
24719
  min = _ref2$min === void 0 ? 0 : _ref2$min,
23908
24720
  deleting = _ref2.deleting,
23909
24721
  onDelete = _ref2.onDelete,
23910
- disabled = _ref2.disabled;
24722
+ disabled = _ref2.disabled,
24723
+ label = _ref2.label,
24724
+ labelDialog = _ref2.labelDialog;
23911
24725
  var _useTranslation2 = useTranslation(),
23912
24726
  t = _useTranslation2.t;
23913
24727
  var hasSelected = (selected === null || selected === void 0 ? void 0 : selected.length) > 0;
23914
24728
  var leftAfterDelete = total - selected.length;
23915
24729
  var allowDelete = leftAfterDelete >= min;
23916
- var popupText = !allowDelete ? t('backoffice.basezable.allowdelete-false') + " ".concat(min) : t('backoffice.basezable.allowdelete-true') + " ".concat(selected.length, " ");
24730
+ var popupText = !allowDelete ? t('backoffice.basezable.allowdelete-false') + " ".concat(min) : t(labelDialog !== null && labelDialog !== void 0 ? labelDialog : 'backoffice.basezable.allowdelete-true') + " ".concat(selected.length, " ");
23917
24731
  return /*#__PURE__*/jsx(Fragment, {
23918
24732
  children: /*#__PURE__*/jsx(Popconfirm, {
23919
24733
  title: popupText,
@@ -23930,28 +24744,28 @@ function DeleteButton(_ref2) {
23930
24744
  disabled: !hasSelected || disabled,
23931
24745
  loading: deleting,
23932
24746
  danger: true,
23933
- children: t('action.delete')
24747
+ children: t(label !== null && label !== void 0 ? label : 'action.delete')
23934
24748
  })
23935
24749
  })
23936
24750
  });
23937
24751
  }
23938
24752
  function CopyButton(_ref3) {
23939
- var _state$configuration$25;
24753
+ var _state$configuration$24;
23940
24754
  var state = _ref3.state;
23941
24755
  var root = useStore();
23942
- var apiHandler = new _default$d({
24756
+ new _default$d({
23943
24757
  apiInterface: state.configuration.apiInterface,
23944
24758
  type: 'Table'
23945
24759
  }, root);
23946
24760
  var onCopy = /*#__PURE__*/function () {
23947
24761
  var _ref4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
23948
- var _state$configuration$22;
24762
+ var _state$configuration$21;
23949
24763
  var copyAction, _iterator3, _step3, selectedRow;
23950
24764
  return _regeneratorRuntime.wrap(function _callee$(_context) {
23951
24765
  while (1) switch (_context.prev = _context.next) {
23952
24766
  case 0:
23953
24767
  copyAction = state.configuration.copyAction;
23954
- if (((_state$configuration$22 = state.configuration.copyAction) === null || _state$configuration$22 === void 0 ? void 0 : _state$configuration$22.apiInterface) != undefined) {
24768
+ if (((_state$configuration$21 = state.configuration.copyAction) === null || _state$configuration$21 === void 0 ? void 0 : _state$configuration$21.apiInterface) != undefined) {
23955
24769
  _iterator3 = _createForOfIteratorHelper$4(state.selected);
23956
24770
  try {
23957
24771
  for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
@@ -23986,31 +24800,25 @@ function CopyButton(_ref3) {
23986
24800
  }();
23987
24801
  var onCopyAction = /*#__PURE__*/function () {
23988
24802
  var _ref5 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee3() {
23989
- var _state$configuration$23, _state$configuration$24;
23990
- var copyAction, id, filter, data;
24803
+ var _state$configuration$22, _state$configuration$23;
24804
+ var copyAction, id, data;
23991
24805
  return _regeneratorRuntime.wrap(function _callee3$(_context3) {
23992
24806
  while (1) switch (_context3.prev = _context3.next) {
23993
24807
  case 0:
23994
24808
  copyAction = state.configuration.copyAction;
23995
- if (!(copyAction.id == undefined || copyAction.actionType != 'Detail' || ((_state$configuration$23 = state.configuration.createAction) === null || _state$configuration$23 === void 0 ? void 0 : _state$configuration$23.actionType) != 'Detail')) {
24809
+ if (!(copyAction.id == undefined || copyAction.actionType != 'Detail' || ((_state$configuration$22 = state.configuration.createAction) === null || _state$configuration$22 === void 0 ? void 0 : _state$configuration$22.actionType) != 'Detail')) {
23996
24810
  _context3.next = 3;
23997
24811
  break;
23998
24812
  }
23999
24813
  throw new Error('configuration needs to be of type Detail');
24000
24814
  case 3:
24001
24815
  id = state.selected[0];
24002
- filter = {};
24003
- filter['_id'] = [id, 'eq', false];
24004
- _context3.next = 8;
24005
- return apiHandler.readList(undefined, undefined, {
24006
- pagination: {},
24007
- columns: [],
24008
- filters: filter
24009
- });
24010
- case 8:
24816
+ _context3.next = 6;
24817
+ return state.getDataById(id);
24818
+ case 6:
24011
24819
  data = _context3.sent;
24012
- data.data[0] = aplyMapping({
24013
- mapable: {},
24820
+ data.data[0] = applyMapping({
24821
+ mappable: {},
24014
24822
  mappingData: data.data[0],
24015
24823
  mapping: copyAction.mapping,
24016
24824
  rootStore: root
@@ -24022,7 +24830,7 @@ function CopyButton(_ref3) {
24022
24830
  configurationId: copyAction === null || copyAction === void 0 ? void 0 : copyAction.id,
24023
24831
  data: data.data[0],
24024
24832
  type: copyAction === null || copyAction === void 0 ? void 0 : copyAction.type,
24025
- mapping: (_state$configuration$24 = state.configuration.createAction) === null || _state$configuration$24 === void 0 ? void 0 : _state$configuration$24.mapping,
24833
+ mapping: (_state$configuration$23 = state.configuration.createAction) === null || _state$configuration$23 === void 0 ? void 0 : _state$configuration$23.mapping,
24026
24834
  mappingData: data.data[0],
24027
24835
  callback: function () {
24028
24836
  var _callback = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2(e) {
@@ -24032,6 +24840,8 @@ function CopyButton(_ref3) {
24032
24840
  _context2.next = 2;
24033
24841
  return state.onUpdate(e);
24034
24842
  case 2:
24843
+ if (copyAction.resetToggleAfter) state.resetToggle();
24844
+ case 3:
24035
24845
  case "end":
24036
24846
  return _context2.stop();
24037
24847
  }
@@ -24043,7 +24853,7 @@ function CopyButton(_ref3) {
24043
24853
  return callback;
24044
24854
  }()
24045
24855
  });
24046
- case 11:
24856
+ case 9:
24047
24857
  case "end":
24048
24858
  return _context3.stop();
24049
24859
  }
@@ -24058,7 +24868,7 @@ function CopyButton(_ref3) {
24058
24868
  return /*#__PURE__*/jsx(Button, {
24059
24869
  type: "primary",
24060
24870
  onClick: onCopy,
24061
- disabled: state.selected.length == 0 || state.selected.length > 1 && ((_state$configuration$25 = state.configuration.copyAction) === null || _state$configuration$25 === void 0 ? void 0 : _state$configuration$25.disableOnMultiselect),
24871
+ disabled: state.selected.length == 0 || state.selected.length > 1 && ((_state$configuration$24 = state.configuration.copyAction) === null || _state$configuration$24 === void 0 ? void 0 : _state$configuration$24.disableOnMultiselect),
24062
24872
  children: t('backoffice.basetable.copy')
24063
24873
  });
24064
24874
  }
@@ -24210,7 +25020,7 @@ function BulkAction(_ref6) {
24210
25020
  _context4.t5 = _context4.sent;
24211
25021
  _context4.t4.push.call(_context4.t4, _context4.t5);
24212
25022
  case 29:
24213
- if (progressBar) progressBar.setProgressBarPercentage(Math.floor((i + 1 / selectedData.length) * 100));
25023
+ if (progressBar) progressBar.setProgressBarPercentage(Math.floor(i / selectedData.length * 100));
24214
25024
  case 30:
24215
25025
  i++;
24216
25026
  _context4.next = 4;
@@ -24218,22 +25028,27 @@ function BulkAction(_ref6) {
24218
25028
  case 33:
24219
25029
  state.onUpdate(data);
24220
25030
  if (progressBar) {
25031
+ progressBar.setProgressBarPercentage(100);
24221
25032
  progressBar.setProgressBarOpen(false);
24222
25033
  progressBar.setProgressBarPercentage(0);
24223
25034
  }
24224
- _context4.next = 41;
25035
+ _context4.next = 42;
24225
25036
  break;
24226
25037
  case 37:
24227
25038
  _context4.prev = 37;
24228
25039
  _context4.t6 = _context4["catch"](2);
25040
+ if (progressBar) {
25041
+ progressBar.setProgressBarOpen(false);
25042
+ progressBar.setProgressBarPercentage(0);
25043
+ }
24229
25044
  LOG$3.error(new DivaError('Error changing data', {
24230
25045
  cause: _context4.t6,
24231
25046
  code: 'BACKO_0002'
24232
25047
  }));
24233
25048
  setShowPopover(t('errorcodes._source.labels.error.BACKO_0002'));
24234
- case 41:
24235
- (_action$callback = action.callback) === null || _action$callback === void 0 || _action$callback.call(action, updatedData);
24236
25049
  case 42:
25050
+ (_action$callback = action.callback) === null || _action$callback === void 0 || _action$callback.call(action, updatedData);
25051
+ case 43:
24237
25052
  case "end":
24238
25053
  return _context4.stop();
24239
25054
  }
@@ -24272,6 +25087,8 @@ function BulkAction(_ref6) {
24272
25087
  }
24273
25088
  function SelectionText(_ref8) {
24274
25089
  var selected = _ref8.selected;
25090
+ var _useTranslation5 = useTranslation(),
25091
+ t = _useTranslation5.t;
24275
25092
  if (!(selected !== null && selected !== void 0 && selected.length)) {
24276
25093
  return /*#__PURE__*/jsx(Fragment, {});
24277
25094
  }
@@ -24281,7 +25098,7 @@ function SelectionText(_ref8) {
24281
25098
  fontWeight: 'normal',
24282
25099
  fontSize: 'small'
24283
25100
  },
24284
- children: "".concat(selected.length, " Eintr\xE4ge ausgew\xE4hlt")
25101
+ children: "".concat(selected.length, " ") + t('backoffice.table.selected_entries')
24285
25102
  });
24286
25103
  }
24287
25104
 
@@ -24551,10 +25368,10 @@ var searchProps = function searchProps(title, filter) {
24551
25368
  confirm = _ref4.confirm,
24552
25369
  clearFilters = _ref4.clearFilters,
24553
25370
  visible = _ref4.visible;
24554
- var ref = useRef(null);
25371
+ var ref1 = useRef(null);
24555
25372
  useEffect(function () {
24556
25373
  if (visible) {
24557
- ref.current.select();
25374
+ ref1.current.select();
24558
25375
  }
24559
25376
  }, [visible]);
24560
25377
  return /*#__PURE__*/jsxs("div", {
@@ -24562,7 +25379,7 @@ var searchProps = function searchProps(title, filter) {
24562
25379
  padding: 8
24563
25380
  },
24564
25381
  children: [/*#__PURE__*/jsx(Input, {
24565
- ref: ref,
25382
+ ref: ref1,
24566
25383
  placeholder: "Filter ".concat(title),
24567
25384
  value: selectedKeys[0],
24568
25385
  onChange: function onChange(e) {
@@ -24827,6 +25644,7 @@ function mapColumns(configuration, userHasPermission, onUpdate, data, globalFilt
24827
25644
  function mapColumn(column, onUpdate) {
24828
25645
  var _column$field, _column$children;
24829
25646
  return _objectSpread$j(_objectSpread$j(_objectSpread$j({}, column), {}, {
25647
+ hidden: false,
24830
25648
  width: column.width || 100,
24831
25649
  dataIndex: (_column$field = column.field) === null || _column$field === void 0 ? void 0 : _column$field.split('.'),
24832
25650
  key: column.field || column.title,
@@ -24877,7 +25695,7 @@ function updateData (_ref) {
24877
25695
 
24878
25696
  function ownKeys$i(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
24879
25697
  function _objectSpread$i(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$i(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$i(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
24880
- function aplyFilterAndSortation (_ref) {
25698
+ function applyFilterAndSortation (_ref) {
24881
25699
  var data = _ref.data,
24882
25700
  filters = _ref.filters,
24883
25701
  sorter = _ref.sorter,
@@ -24906,7 +25724,7 @@ function aplyFilterAndSortation (_ref) {
24906
25724
  */
24907
25725
  function sort(s, data) {
24908
25726
  var flatData = data.map(function (d) {
24909
- return flat.flatten(d);
25727
+ return flatten(d);
24910
25728
  });
24911
25729
  var sorters = Array.of(s).flat().sort(function (a, b) {
24912
25730
  var _a$column, _b$column;
@@ -24917,7 +25735,7 @@ function sort(s, data) {
24917
25735
  return d[s.columnKey];
24918
25736
  });
24919
25737
  })).map(function (r) {
24920
- return flat.unflatten(r);
25738
+ return unflatten(r);
24921
25739
  });
24922
25740
  }
24923
25741
 
@@ -24936,7 +25754,7 @@ function filter(f, data) {
24936
25754
  return k.includes('.');
24937
25755
  })) {
24938
25756
  filterableData = data.map(function (d) {
24939
- return flat.flatten(d);
25757
+ return flatten(d);
24940
25758
  });
24941
25759
  isFlatted = true;
24942
25760
  }
@@ -24971,7 +25789,7 @@ function filter(f, data) {
24971
25789
  });
24972
25790
  });
24973
25791
  return isFlatted ? result.map(function (r) {
24974
- return flat.unflatten(r);
25792
+ return unflatten(r);
24975
25793
  }) : result;
24976
25794
  }
24977
25795
 
@@ -25032,7 +25850,7 @@ function useTableData$1 (_ref) {
25032
25850
  var _configuration$create;
25033
25851
  if (!dataRow) return;
25034
25852
  var id = v4();
25035
- var processedDataRow = flat.unflatten(_objectSpread$h({
25853
+ var processedDataRow = unflatten(_objectSpread$h({
25036
25854
  _id: id,
25037
25855
  ID: id
25038
25856
  }, dataRow));
@@ -25048,7 +25866,7 @@ function useTableData$1 (_ref) {
25048
25866
  data: newData
25049
25867
  });
25050
25868
  if (!filterServerSide) {
25051
- var res = aplyFilterAndSortation(_objectSpread$h(_objectSpread$h({}, filterData), {}, {
25869
+ var res = applyFilterAndSortation(_objectSpread$h(_objectSpread$h({}, filterData), {}, {
25052
25870
  data: newData
25053
25871
  }));
25054
25872
  newState.data = res.data;
@@ -25091,11 +25909,10 @@ function useTableData$1 (_ref) {
25091
25909
  sorter: mapColumns(configuration, root.actions.userHasPermission, onUpdate).filter(function (c) {
25092
25910
  return c.defaultSortOrder;
25093
25911
  }).map(function (c) {
25094
- var _c$dataIndex;
25095
25912
  return {
25096
25913
  column: c,
25097
25914
  field: c.dataIndex,
25098
- columnKey: (_c$dataIndex = c.dataIndex) === null || _c$dataIndex === void 0 ? void 0 : _c$dataIndex.join('.'),
25915
+ columnKey: c.key,
25099
25916
  order: c.defaultSortOrder
25100
25917
  };
25101
25918
  })
@@ -25108,11 +25925,10 @@ function useTableData$1 (_ref) {
25108
25925
  sorter: mapColumns(configuration, root.actions.userHasPermission, onUpdate).filter(function (c) {
25109
25926
  return c.defaultSortOrder;
25110
25927
  }).map(function (c) {
25111
- var _c$dataIndex2;
25112
25928
  return {
25113
25929
  column: c,
25114
25930
  field: c.dataIndex,
25115
- columnKey: (_c$dataIndex2 = c.dataIndex) === null || _c$dataIndex2 === void 0 ? void 0 : _c$dataIndex2.join('.'),
25931
+ columnKey: c.key,
25116
25932
  order: c.defaultSortOrder
25117
25933
  };
25118
25934
  })
@@ -25125,11 +25941,11 @@ function useTableData$1 (_ref) {
25125
25941
  }));
25126
25942
  if (!filterServerSide) {
25127
25943
  var unfilteredData = dataParam ? dataParam : state.unfilteredData;
25128
- var _aplyFilterAndSortati = aplyFilterAndSortation(_objectSpread$h(_objectSpread$h({}, p), {}, {
25944
+ var _applyFilterAndSortat = applyFilterAndSortation(_objectSpread$h(_objectSpread$h({}, p), {}, {
25129
25945
  data: unfilteredData
25130
25946
  })),
25131
- data = _aplyFilterAndSortati.data,
25132
- pagination = _aplyFilterAndSortati.pagination;
25947
+ data = _applyFilterAndSortat.data,
25948
+ pagination = _applyFilterAndSortat.pagination;
25133
25949
  setState(_objectSpread$h(_objectSpread$h({}, state), {}, {
25134
25950
  data: data,
25135
25951
  pagination: pagination,
@@ -25165,16 +25981,44 @@ function useTableData$1 (_ref) {
25165
25981
  });
25166
25982
  }
25167
25983
  };
25984
+ var getDataById = /*#__PURE__*/function () {
25985
+ var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee(id) {
25986
+ var filters, data;
25987
+ return _regeneratorRuntime.wrap(function _callee$(_context) {
25988
+ while (1) switch (_context.prev = _context.next) {
25989
+ case 0:
25990
+ filters = {};
25991
+ filters['_id'] = [id, 'eq', false];
25992
+ _context.next = 4;
25993
+ return apiHandler.readList(configuration.mapping, {
25994
+ pagination: _objectSpread$h({}, state.pagination),
25995
+ columns: configuration.columns,
25996
+ filters: filters,
25997
+ sorter: filterData.sorter
25998
+ });
25999
+ case 4:
26000
+ data = _context.sent;
26001
+ return _context.abrupt("return", data);
26002
+ case 6:
26003
+ case "end":
26004
+ return _context.stop();
26005
+ }
26006
+ }, _callee);
26007
+ }));
26008
+ return function getDataById(_x) {
26009
+ return _ref2.apply(this, arguments);
26010
+ };
26011
+ }();
25168
26012
  var onSelect = function onSelect(keys) {
25169
26013
  setState(_objectSpread$h(_objectSpread$h({}, state), {}, {
25170
26014
  selected: keys
25171
26015
  }));
25172
26016
  };
25173
26017
  var onDelete = /*#__PURE__*/function () {
25174
- var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
26018
+ var _ref3 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2() {
25175
26019
  var newData, deleted, _loop, mappingData, index, total, pages, current, data;
25176
- return _regeneratorRuntime.wrap(function _callee$(_context2) {
25177
- while (1) switch (_context2.prev = _context2.next) {
26020
+ return _regeneratorRuntime.wrap(function _callee2$(_context3) {
26021
+ while (1) switch (_context3.prev = _context3.next) {
25178
26022
  case 0:
25179
26023
  setState(_objectSpread$h(_objectSpread$h({}, state), {}, {
25180
26024
  deleting: true
@@ -25184,24 +26028,24 @@ function useTableData$1 (_ref) {
25184
26028
  _loop = /*#__PURE__*/_regeneratorRuntime.mark(function _loop(index) {
25185
26029
  var _newData$filter, _configuration$delete;
25186
26030
  var id, deleteResult, deletedIndex;
25187
- return _regeneratorRuntime.wrap(function _loop$(_context) {
25188
- while (1) switch (_context.prev = _context.next) {
26031
+ return _regeneratorRuntime.wrap(function _loop$(_context2) {
26032
+ while (1) switch (_context2.prev = _context2.next) {
25189
26033
  case 0:
25190
26034
  id = state.selected[index];
25191
26035
  mappingData = (_newData$filter = newData.filter(function (nd) {
25192
26036
  return nd._id === state.selected[index];
25193
26037
  })) === null || _newData$filter === void 0 ? void 0 : _newData$filter[0];
25194
26038
  mappingData = _objectSpread$h(_objectSpread$h({}, mappingData), state.mappingData);
25195
- _context.next = 5;
26039
+ _context2.next = 5;
25196
26040
  return apiHandler["delete"](id, (_configuration$delete = configuration.deleteMapping) !== null && _configuration$delete !== void 0 ? _configuration$delete : configuration.mapping, mappingData, true);
25197
26041
  case 5:
25198
- deleteResult = _context.sent;
26042
+ deleteResult = _context2.sent;
25199
26043
  if (deleteResult) {
25200
- _context.next = 9;
26044
+ _context2.next = 9;
25201
26045
  break;
25202
26046
  }
25203
26047
  setError('Fehler beim löschen eines Elementes.');
25204
- return _context.abrupt("return", 1);
26048
+ return _context2.abrupt("return", 1);
25205
26049
  case 9:
25206
26050
  deletedIndex = newData.findIndex(function (d) {
25207
26051
  return (d === null || d === void 0 ? void 0 : d._id) == id;
@@ -25210,36 +26054,36 @@ function useTableData$1 (_ref) {
25210
26054
  deleted++;
25211
26055
  case 12:
25212
26056
  case "end":
25213
- return _context.stop();
26057
+ return _context2.stop();
25214
26058
  }
25215
26059
  }, _loop);
25216
26060
  });
25217
26061
  index = 0;
25218
26062
  case 5:
25219
26063
  if (!(index < state.selected.length)) {
25220
- _context2.next = 12;
26064
+ _context3.next = 12;
25221
26065
  break;
25222
26066
  }
25223
- return _context2.delegateYield(_loop(index), "t0", 7);
26067
+ return _context3.delegateYield(_loop(index), "t0", 7);
25224
26068
  case 7:
25225
- if (!_context2.t0) {
25226
- _context2.next = 9;
26069
+ if (!_context3.t0) {
26070
+ _context3.next = 9;
25227
26071
  break;
25228
26072
  }
25229
- return _context2.abrupt("continue", 9);
26073
+ return _context3.abrupt("continue", 9);
25230
26074
  case 9:
25231
26075
  index++;
25232
- _context2.next = 5;
26076
+ _context3.next = 5;
25233
26077
  break;
25234
26078
  case 12:
25235
26079
  total = state.pagination.total - deleted;
25236
26080
  pages = Math.ceil(total / state.pagination.pageSize);
25237
26081
  current = state.pagination.current > pages ? pages || 1 : state.pagination.current;
25238
26082
  if (!(pages > 0 && state.pagination.current > pages && filterServerSide || state.selected.length === 0)) {
25239
- _context2.next = 21;
26083
+ _context3.next = 21;
25240
26084
  break;
25241
26085
  }
25242
- _context2.next = 18;
26086
+ _context3.next = 18;
25243
26087
  return apiHandler.readList(configuration.mapping, {
25244
26088
  pagination: _objectSpread$h(_objectSpread$h({}, state.pagination), {}, {
25245
26089
  current: current
@@ -25249,7 +26093,7 @@ function useTableData$1 (_ref) {
25249
26093
  sorter: filterData.sorter
25250
26094
  });
25251
26095
  case 18:
25252
- data = _context2.sent;
26096
+ data = _context3.sent;
25253
26097
  newData = data.data;
25254
26098
  total = data.total;
25255
26099
  case 21:
@@ -25264,12 +26108,12 @@ function useTableData$1 (_ref) {
25264
26108
  }));
25265
26109
  case 22:
25266
26110
  case "end":
25267
- return _context2.stop();
26111
+ return _context3.stop();
25268
26112
  }
25269
- }, _callee);
26113
+ }, _callee2);
25270
26114
  }));
25271
26115
  return function onDelete() {
25272
- return _ref2.apply(this, arguments);
26116
+ return _ref3.apply(this, arguments);
25273
26117
  };
25274
26118
  }();
25275
26119
  function setLoading() {
@@ -25289,6 +26133,10 @@ function useTableData$1 (_ref) {
25289
26133
  onChange: onChange,
25290
26134
  onUpdate: onUpdate,
25291
26135
  onDelete: onDelete,
26136
+ getDataById: getDataById,
26137
+ resetToggle: function resetToggle() {
26138
+ throw new Error('not implemented for CatalogTable');
26139
+ },
25292
26140
  triggerRefresh: function triggerRefresh() {
25293
26141
  throw new Error('not implemented for CatalogTable');
25294
26142
  },
@@ -25423,7 +26271,8 @@ function useTableData (_ref) {
25423
26271
  var toggleConfig = (_configuration$filter = configuration.filter) === null || _configuration$filter === void 0 ? void 0 : _configuration$filter.toggle;
25424
26272
  var toggleFilter = {};
25425
26273
  toggleConfig === null || toggleConfig === void 0 || toggleConfig.fields.forEach(function (f) {
25426
- return toggleFilter[f] = [toggleConfig.globalValue ? root.getGlobalValue(toggleConfig.globalValue) : true, 'eq', 1];
26274
+ var _toggleConfig$isAnd;
26275
+ return toggleFilter[f] = [toggleConfig.globalValue ? root.getGlobalValue(toggleConfig.globalValue) : true, 'eq', ((_toggleConfig$isAnd = toggleConfig.isAnd) !== null && _toggleConfig$isAnd !== void 0 ? _toggleConfig$isAnd : false) ? 0 : 1];
25427
26276
  });
25428
26277
  var defaultFilter = {};
25429
26278
  (_configuration$filter2 = configuration.filter) === null || _configuration$filter2 === void 0 || (_configuration$filter2 = _configuration$filter2["default"]) === null || _configuration$filter2 === void 0 || _configuration$filter2.fields.forEach(function (f) {
@@ -25539,7 +26388,7 @@ function useTableData (_ref) {
25539
26388
  dataRow: dataRow
25540
26389
  }),
25541
26390
  nextInitData = _updateData2.data;
25542
- var _aplyFilterAndSortati = aplyFilterAndSortation(_objectSpread$g(_objectSpread$g(_objectSpread$g({}, filterData), {}, {
26391
+ var _applyFilterAndSortat = applyFilterAndSortation(_objectSpread$g(_objectSpread$g(_objectSpread$g({}, filterData), {}, {
25543
26392
  filters: _objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g({}, filterData.filters), globalFilter.search), !(configuration !== null && configuration !== void 0 && (_configuration$filter5 = configuration.filter) !== null && _configuration$filter5 !== void 0 && (_configuration$filter5 = _configuration$filter5.toggle) !== null && _configuration$filter5 !== void 0 && _configuration$filter5.inQuery) ? globalFilter.toggle : undefined), globalFilter.select), globalFilter.timeStamp), globalFilter["default"])
25544
26393
  }, configuration !== null && configuration !== void 0 && (_configuration$filter6 = configuration.filter) !== null && _configuration$filter6 !== void 0 && (_configuration$filter6 = _configuration$filter6.toggle) !== null && _configuration$filter6 !== void 0 && _configuration$filter6.inQuery ? {
25545
26394
  genericProps: globalFilter.toggle
@@ -25547,8 +26396,8 @@ function useTableData (_ref) {
25547
26396
  data: nextInitData,
25548
26397
  filterServerSide: filterServerSide
25549
26398
  })),
25550
- _data2 = _aplyFilterAndSortati.data,
25551
- _pagination2 = _aplyFilterAndSortati.pagination;
26399
+ _data2 = _applyFilterAndSortat.data,
26400
+ _pagination2 = _applyFilterAndSortat.pagination;
25552
26401
  newInitData = nextInitData;
25553
26402
  newState = _objectSpread$g(_objectSpread$g({}, newState), {}, {
25554
26403
  pagination: _pagination2,
@@ -25596,11 +26445,10 @@ function useTableData (_ref) {
25596
26445
  var sorter = columns.filter(function (c) {
25597
26446
  return c.defaultSortOrder;
25598
26447
  }).map(function (c) {
25599
- var _c$dataIndex;
25600
26448
  return {
25601
26449
  column: c,
25602
26450
  field: c.dataIndex,
25603
- columnKey: (_c$dataIndex = c.dataIndex) === null || _c$dataIndex === void 0 ? void 0 : _c$dataIndex.join('.'),
26451
+ columnKey: c.key,
25604
26452
  order: c.defaultSortOrder
25605
26453
  };
25606
26454
  });
@@ -25638,38 +26486,77 @@ function useTableData (_ref) {
25638
26486
  }
25639
26487
  return title;
25640
26488
  }, [configuration.title, parentData]);
26489
+ var getDataById = /*#__PURE__*/function () {
26490
+ var _ref4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2(id) {
26491
+ var _configuration$filter9;
26492
+ var filters, ssf, data;
26493
+ return _regeneratorRuntime.wrap(function _callee2$(_context2) {
26494
+ while (1) switch (_context2.prev = _context2.next) {
26495
+ case 0:
26496
+ filters = {};
26497
+ filters['_id'] = [id, 'eq', false];
26498
+ ssf = _objectSpread$g({
26499
+ pagination: {
26500
+ current: 1,
26501
+ pageSize: 1
26502
+ },
26503
+ columns: configuration.columns,
26504
+ filters: filters
26505
+ }, configuration !== null && configuration !== void 0 && (_configuration$filter9 = configuration.filter) !== null && _configuration$filter9 !== void 0 && (_configuration$filter9 = _configuration$filter9.toggle) !== null && _configuration$filter9 !== void 0 && _configuration$filter9.inQuery ? {
26506
+ genericProps: globalFilter.toggle
26507
+ } : undefined);
26508
+ _context2.next = 5;
26509
+ return apiHandler.readList(parentMapping || configuration.mapping, mapping, ssf);
26510
+ case 5:
26511
+ data = _context2.sent;
26512
+ return _context2.abrupt("return", data);
26513
+ case 7:
26514
+ case "end":
26515
+ return _context2.stop();
26516
+ }
26517
+ }, _callee2);
26518
+ }));
26519
+ return function getDataById(_x2) {
26520
+ return _ref4.apply(this, arguments);
26521
+ };
26522
+ }();
25641
26523
  var onChange = /*#__PURE__*/function () {
25642
- var _ref4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2(p) {
25643
- var _configuration$filter9, _configuration$filter10, _configuration$filter11, _prefilter$select, _configuration$filter12, _configuration$filter13;
26524
+ var _ref5 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee3(p) {
26525
+ var _configuration$filter10, _configuration$filter11, _prefilter$select, _configuration$filter12, _configuration$filter13;
25644
26526
  var prefilter,
25645
26527
  refresh,
26528
+ clearSelection,
25646
26529
  currentData,
25647
26530
  filterData,
25648
26531
  currentFilterHash,
25649
26532
  currentPagination,
25650
26533
  currentUrl,
25651
26534
  _configuration$filter14,
26535
+ _configuration$filter15,
26536
+ _prefilter$toggle,
26537
+ _parseFilter,
25652
26538
  ssf,
25653
26539
  data,
25654
26540
  _data3,
25655
- _aplyFilterAndSortati2,
26541
+ _applyFilterAndSortat2,
25656
26542
  _data4,
25657
26543
  pagination,
25658
- _args2 = arguments;
25659
- return _regeneratorRuntime.wrap(function _callee2$(_context2) {
25660
- while (1) switch (_context2.prev = _context2.next) {
26544
+ _args3 = arguments;
26545
+ return _regeneratorRuntime.wrap(function _callee3$(_context3) {
26546
+ while (1) switch (_context3.prev = _context3.next) {
25661
26547
  case 0:
25662
- prefilter = _args2.length > 1 && _args2[1] !== undefined ? _args2[1] : globalFilter;
25663
- refresh = _args2.length > 2 ? _args2[2] : undefined;
26548
+ prefilter = _args3.length > 1 && _args3[1] !== undefined ? _args3[1] : globalFilter;
26549
+ refresh = _args3.length > 2 ? _args3[2] : undefined;
26550
+ clearSelection = _args3.length > 3 ? _args3[3] : undefined;
25664
26551
  setState(_objectSpread$g(_objectSpread$g({}, state), {}, {
25665
26552
  loading: true
25666
26553
  }));
25667
26554
  currentData = initData;
25668
- filterData = _objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g({}, p.filters), prefilter.search), !(configuration !== null && configuration !== void 0 && (_configuration$filter9 = configuration.filter) !== null && _configuration$filter9 !== void 0 && (_configuration$filter9 = _configuration$filter9.toggle) !== null && _configuration$filter9 !== void 0 && _configuration$filter9.inQuery) ? prefilter.toggle : undefined), ((_configuration$filter10 = configuration.filter) === null || _configuration$filter10 === void 0 || (_configuration$filter10 = _configuration$filter10.select) === null || _configuration$filter10 === void 0 ? void 0 : _configuration$filter10.applyDefaultValue) !== false || ((_configuration$filter11 = configuration.filter) === null || _configuration$filter11 === void 0 || (_configuration$filter11 = _configuration$filter11.select) === null || _configuration$filter11 === void 0 ? void 0 : _configuration$filter11.defaultValue) !== ((_prefilter$select = prefilter.select) === null || _prefilter$select === void 0 || (_prefilter$select = _prefilter$select[(_configuration$filter12 = (_configuration$filter13 = configuration.filter) === null || _configuration$filter13 === void 0 || (_configuration$filter13 = _configuration$filter13.select) === null || _configuration$filter13 === void 0 ? void 0 : _configuration$filter13.filterField) !== null && _configuration$filter12 !== void 0 ? _configuration$filter12 : '']) === null || _prefilter$select === void 0 ? void 0 : _prefilter$select[0]) ? prefilter.select : undefined), prefilter.timeStamp), prefilter["default"]); //remove all null values
25669
- filterData = Object.fromEntries(Object.entries(filterData).filter(function (_ref5) {
25670
- var _ref6 = _slicedToArray(_ref5, 2);
25671
- _ref6[0];
25672
- var v = _ref6[1];
26555
+ filterData = _objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g({}, prefilter.search), ((_configuration$filter10 = configuration.filter) === null || _configuration$filter10 === void 0 || (_configuration$filter10 = _configuration$filter10.select) === null || _configuration$filter10 === void 0 ? void 0 : _configuration$filter10.applyDefaultValue) !== false || ((_configuration$filter11 = configuration.filter) === null || _configuration$filter11 === void 0 || (_configuration$filter11 = _configuration$filter11.select) === null || _configuration$filter11 === void 0 ? void 0 : _configuration$filter11.defaultValue) !== ((_prefilter$select = prefilter.select) === null || _prefilter$select === void 0 || (_prefilter$select = _prefilter$select[(_configuration$filter12 = (_configuration$filter13 = configuration.filter) === null || _configuration$filter13 === void 0 || (_configuration$filter13 = _configuration$filter13.select) === null || _configuration$filter13 === void 0 ? void 0 : _configuration$filter13.filterField) !== null && _configuration$filter12 !== void 0 ? _configuration$filter12 : '']) === null || _prefilter$select === void 0 ? void 0 : _prefilter$select[0]) ? prefilter.select : undefined), prefilter.timeStamp), prefilter["default"]); //remove all null values
26556
+ filterData = Object.fromEntries(Object.entries(filterData).filter(function (_ref6) {
26557
+ var _ref7 = _slicedToArray(_ref6, 2);
26558
+ _ref7[0];
26559
+ var v = _ref7[1];
25673
26560
  return v != null;
25674
26561
  }));
25675
26562
  currentFilterHash = objectHash(filterData);
@@ -25678,7 +26565,7 @@ function useTableData (_ref) {
25678
26565
  });
25679
26566
  filterHash.current = currentFilterHash;
25680
26567
  if (!filterServerSide) {
25681
- _context2.next = 19;
26568
+ _context3.next = 20;
25682
26569
  break;
25683
26570
  }
25684
26571
  ssf = _objectSpread$g({
@@ -25689,38 +26576,38 @@ function useTableData (_ref) {
25689
26576
  }, configuration !== null && configuration !== void 0 && (_configuration$filter14 = configuration.filter) !== null && _configuration$filter14 !== void 0 && (_configuration$filter14 = _configuration$filter14.toggle) !== null && _configuration$filter14 !== void 0 && _configuration$filter14.inQuery ? {
25690
26577
  genericProps: prefilter.toggle
25691
26578
  } : undefined);
25692
- _context2.next = 13;
25693
- return apiHandler.readList(parentMapping || configuration.mapping, mapping, ssf);
25694
- case 13:
25695
- data = _context2.sent;
26579
+ _context3.next = 14;
26580
+ return apiHandler.readList(parentMapping || configuration.mapping, mapping, ssf, undefined, parseFilter(!(configuration !== null && configuration !== void 0 && (_configuration$filter15 = configuration.filter) !== null && _configuration$filter15 !== void 0 && (_configuration$filter15 = _configuration$filter15.toggle) !== null && _configuration$filter15 !== void 0 && _configuration$filter15.inQuery) ? (_prefilter$toggle = prefilter.toggle) !== null && _prefilter$toggle !== void 0 ? _prefilter$toggle : {} : {}, (_parseFilter = parseFilter(p.filters, undefined)) === null || _parseFilter === void 0 ? void 0 : _parseFilter.slice(1, -1)));
26581
+ case 14:
26582
+ data = _context3.sent;
25696
26583
  currentUrl = apiHandler.getReadListUrl(parentMapping || configuration.mapping, mapping, ssf);
25697
26584
  currentData = data.data;
25698
26585
  currentPagination = _objectSpread$g(_objectSpread$g({}, currentPagination), {}, {
25699
26586
  total: data.total
25700
26587
  });
25701
- _context2.next = 28;
26588
+ _context3.next = 29;
25702
26589
  break;
25703
- case 19:
26590
+ case 20:
25704
26591
  if (!(!currentData || currentData.length === 0 || refresh)) {
25705
- _context2.next = 25;
26592
+ _context3.next = 26;
25706
26593
  break;
25707
26594
  }
25708
- _context2.next = 22;
26595
+ _context3.next = 23;
25709
26596
  return apiHandler.readList(parentMapping || configuration.mapping, mapping, undefined);
25710
- case 22:
25711
- _data3 = _context2.sent;
26597
+ case 23:
26598
+ _data3 = _context3.sent;
25712
26599
  currentData = _data3.data;
25713
26600
  setInitData(currentData);
25714
- case 25:
25715
- _aplyFilterAndSortati2 = aplyFilterAndSortation(_objectSpread$g(_objectSpread$g({}, p), {}, {
26601
+ case 26:
26602
+ _applyFilterAndSortat2 = applyFilterAndSortation(_objectSpread$g(_objectSpread$g({}, p), {}, {
25716
26603
  pagination: currentPagination,
25717
26604
  filters: filterData,
25718
26605
  data: currentData,
25719
26606
  filterServerSide: filterServerSide
25720
- })), _data4 = _aplyFilterAndSortati2.data, pagination = _aplyFilterAndSortati2.pagination;
26607
+ })), _data4 = _applyFilterAndSortat2.data, pagination = _applyFilterAndSortat2.pagination;
25721
26608
  currentData = _data4;
25722
26609
  currentPagination = pagination;
25723
- case 28:
26610
+ case 29:
25724
26611
  setState(_objectSpread$g(_objectSpread$g({}, state), {}, {
25725
26612
  loading: false,
25726
26613
  data: currentData,
@@ -25729,19 +26616,21 @@ function useTableData (_ref) {
25729
26616
  prefilter: prefilter
25730
26617
  }),
25731
26618
  currentFetchUrl: currentUrl
25732
- }));
26619
+ }, clearSelection ? {
26620
+ selected: []
26621
+ } : {}));
25733
26622
  setFilter({
25734
26623
  filters: p.filters,
25735
26624
  sorter: p.sorter
25736
26625
  });
25737
- case 30:
26626
+ case 31:
25738
26627
  case "end":
25739
- return _context2.stop();
26628
+ return _context3.stop();
25740
26629
  }
25741
- }, _callee2);
26630
+ }, _callee3);
25742
26631
  }));
25743
- return function onChange(_x2) {
25744
- return _ref4.apply(this, arguments);
26632
+ return function onChange(_x3) {
26633
+ return _ref5.apply(this, arguments);
25745
26634
  };
25746
26635
  }();
25747
26636
  var onSelect = function onSelect(keys) {
@@ -25750,11 +26639,11 @@ function useTableData (_ref) {
25750
26639
  }));
25751
26640
  };
25752
26641
  var onDelete = /*#__PURE__*/function () {
25753
- var _ref7 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee3() {
26642
+ var _ref8 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee4() {
25754
26643
  var _configuration$apiInt2;
25755
- var newData, newInitData, deleted, userPermissions, _loop, mappingData, deleteResult, _ret, index, total, pages, current, _configuration$filter15, _configuration$filter16, data;
25756
- return _regeneratorRuntime.wrap(function _callee3$(_context4) {
25757
- while (1) switch (_context4.prev = _context4.next) {
26644
+ var newData, newInitData, deleted, userPermissions, _loop, mappingData, deleteResult, _ret, index, total, pages, current, _configuration$filter16, _configuration$filter17, data;
26645
+ return _regeneratorRuntime.wrap(function _callee4$(_context5) {
26646
+ while (1) switch (_context5.prev = _context5.next) {
25758
26647
  case 0:
25759
26648
  setState(_objectSpread$g(_objectSpread$g({}, state), {}, {
25760
26649
  deleting: true
@@ -25762,15 +26651,15 @@ function useTableData (_ref) {
25762
26651
  newData = _toConsumableArray(state.data);
25763
26652
  newInitData = initData ? _toConsumableArray(initData) : undefined;
25764
26653
  deleted = 0;
25765
- _context4.next = 6;
26654
+ _context5.next = 6;
25766
26655
  return _typeof(configuration.apiInterface) == 'object' && _typeof(configuration.apiInterface["delete"]) == 'object' ? (_configuration$apiInt2 = configuration.apiInterface["delete"]) === null || _configuration$apiInt2 === void 0 ? void 0 : _configuration$apiInt2.permission : undefined;
25767
26656
  case 6:
25768
- userPermissions = _context4.sent;
26657
+ userPermissions = _context5.sent;
25769
26658
  _loop = /*#__PURE__*/_regeneratorRuntime.mark(function _loop(index) {
25770
- var _configuration$rowKey, _configuration$filter17, _configuration$filter18;
26659
+ var _configuration$filter18, _configuration$filter19;
25771
26660
  var id, _newData$filter, _newData$filter2, mapToggle, _iterator, _step, _globalFilter$toggle, field, _globalFilter$toggle2, _configuration$delete, _configuration$onErro, _configuration$onErro2, deletedIndex, initDeletedIndex;
25772
- return _regeneratorRuntime.wrap(function _loop$(_context3) {
25773
- while (1) switch (_context3.prev = _context3.next) {
26661
+ return _regeneratorRuntime.wrap(function _loop$(_context4) {
26662
+ while (1) switch (_context4.prev = _context4.next) {
25774
26663
  case 0:
25775
26664
  id = state.selected[index];
25776
26665
  if (configuration.rowKey) {
@@ -25783,7 +26672,7 @@ function useTableData (_ref) {
25783
26672
  })) === null || _newData$filter2 === void 0 ? void 0 : _newData$filter2[0];
25784
26673
  }
25785
26674
  mapToggle = {};
25786
- _iterator = _createForOfIteratorHelper$3((_configuration$filter17 = (_configuration$filter18 = configuration.filter) === null || _configuration$filter18 === void 0 || (_configuration$filter18 = _configuration$filter18.toggle) === null || _configuration$filter18 === void 0 ? void 0 : _configuration$filter18.fields) !== null && _configuration$filter17 !== void 0 ? _configuration$filter17 : []);
26675
+ _iterator = _createForOfIteratorHelper$3((_configuration$filter18 = (_configuration$filter19 = configuration.filter) === null || _configuration$filter19 === void 0 || (_configuration$filter19 = _configuration$filter19.toggle) === null || _configuration$filter19 === void 0 ? void 0 : _configuration$filter19.fields) !== null && _configuration$filter18 !== void 0 ? _configuration$filter18 : []);
25787
26676
  try {
25788
26677
  for (_iterator.s(); !(_step = _iterator.n()).done;) {
25789
26678
  field = _step.value;
@@ -25798,107 +26687,106 @@ function useTableData (_ref) {
25798
26687
  }
25799
26688
  mappingData = _objectSpread$g(_objectSpread$g(_objectSpread$g({}, mappingData), state.mappingData), mapToggle);
25800
26689
  deleteResult = undefined;
25801
- _context3.prev = 7;
26690
+ _context4.prev = 7;
25802
26691
  if (!(userPermissions && !root.actions.userHasPermission(userPermissions))) {
25803
- _context3.next = 11;
26692
+ _context4.next = 11;
25804
26693
  break;
25805
26694
  }
25806
26695
  setError('Sie haben keine Berechtigung ein Mediaitem zu löschen.');
25807
- return _context3.abrupt("return", 0);
26696
+ return _context4.abrupt("return", 0);
25808
26697
  case 11:
25809
- _context3.next = 13;
26698
+ _context4.next = 13;
25810
26699
  return apiHandler["delete"](id, (_configuration$delete = configuration.deleteMapping) !== null && _configuration$delete !== void 0 ? _configuration$delete : configuration.mapping, mappingData);
25811
26700
  case 13:
25812
- deleteResult = _context3.sent;
25813
- _context3.next = 24;
26701
+ deleteResult = _context4.sent;
26702
+ _context4.next = 24;
25814
26703
  break;
25815
26704
  case 16:
25816
- _context3.prev = 16;
25817
- _context3.t0 = _context3["catch"](7);
25818
- if (!(_context3.t0 instanceof DivaError && _context3.t0.name)) {
25819
- _context3.next = 22;
26705
+ _context4.prev = 16;
26706
+ _context4.t0 = _context4["catch"](7);
26707
+ if (!(_context4.t0 instanceof DivaError && _context4.t0.name)) {
26708
+ _context4.next = 22;
25820
26709
  break;
25821
26710
  }
25822
- if (!((_configuration$onErro = configuration.onError) !== null && _configuration$onErro !== void 0 && _configuration$onErro[_context3.t0.name])) {
25823
- _context3.next = 22;
26711
+ if (!((_configuration$onErro = configuration.onError) !== null && _configuration$onErro !== void 0 && _configuration$onErro[_context4.t0.name])) {
26712
+ _context4.next = 22;
25824
26713
  break;
25825
26714
  }
25826
- setError((_configuration$onErro2 = configuration.onError) === null || _configuration$onErro2 === void 0 ? void 0 : _configuration$onErro2[_context3.t0.name]);
25827
- return _context3.abrupt("return", 0);
26715
+ setError((_configuration$onErro2 = configuration.onError) === null || _configuration$onErro2 === void 0 ? void 0 : _configuration$onErro2[_context4.t0.name]);
26716
+ return _context4.abrupt("return", 0);
25828
26717
  case 22:
25829
- setError(_context3.t0.message);
25830
- return _context3.abrupt("return", 0);
26718
+ setError(_context4.t0.message);
26719
+ return _context4.abrupt("return", 0);
25831
26720
  case 24:
25832
26721
  if (deleteResult) {
25833
- _context3.next = 27;
26722
+ _context4.next = 27;
25834
26723
  break;
25835
26724
  }
25836
26725
  setError('Fehler beim löschen eines Elementes.');
25837
- return _context3.abrupt("return", 1);
26726
+ return _context4.abrupt("return", 1);
25838
26727
  case 27:
25839
- (_configuration$rowKey = configuration.rowKey) !== null && _configuration$rowKey !== void 0 ? _configuration$rowKey : '_id';
25840
26728
  deletedIndex = newData.findIndex(function (d) {
25841
- var _configuration$rowKey2, _configuration$rowKey3;
25842
- return goTroughObject(d, (_configuration$rowKey2 = (_configuration$rowKey3 = configuration.rowKey) === null || _configuration$rowKey3 === void 0 ? void 0 : _configuration$rowKey3.split('.')) !== null && _configuration$rowKey2 !== void 0 ? _configuration$rowKey2 : ['_id']) == id;
26729
+ var _configuration$rowKey, _configuration$rowKey2;
26730
+ return goTroughObject(d, (_configuration$rowKey = (_configuration$rowKey2 = configuration.rowKey) === null || _configuration$rowKey2 === void 0 ? void 0 : _configuration$rowKey2.split('.')) !== null && _configuration$rowKey !== void 0 ? _configuration$rowKey : ['_id']) == id;
25843
26731
  });
25844
26732
  newData.splice(deletedIndex, 1);
25845
26733
  initDeletedIndex = newInitData === null || newInitData === void 0 ? void 0 : newInitData.findIndex(function (d) {
25846
- var _configuration$rowKey4, _configuration$rowKey5;
25847
- return goTroughObject(d, (_configuration$rowKey4 = (_configuration$rowKey5 = configuration.rowKey) === null || _configuration$rowKey5 === void 0 ? void 0 : _configuration$rowKey5.split('.')) !== null && _configuration$rowKey4 !== void 0 ? _configuration$rowKey4 : ['_id']) == id;
26734
+ var _configuration$rowKey3, _configuration$rowKey4;
26735
+ return goTroughObject(d, (_configuration$rowKey3 = (_configuration$rowKey4 = configuration.rowKey) === null || _configuration$rowKey4 === void 0 ? void 0 : _configuration$rowKey4.split('.')) !== null && _configuration$rowKey3 !== void 0 ? _configuration$rowKey3 : ['_id']) == id;
25848
26736
  });
25849
26737
  newInitData === null || newInitData === void 0 || newInitData.splice(initDeletedIndex, 1);
25850
26738
  deleted++;
25851
- case 33:
26739
+ case 32:
25852
26740
  case "end":
25853
- return _context3.stop();
26741
+ return _context4.stop();
25854
26742
  }
25855
26743
  }, _loop, null, [[7, 16]]);
25856
26744
  });
25857
26745
  index = 0;
25858
26746
  case 9:
25859
26747
  if (!(index < state.selected.length)) {
25860
- _context4.next = 19;
26748
+ _context5.next = 19;
25861
26749
  break;
25862
26750
  }
25863
- return _context4.delegateYield(_loop(index), "t0", 11);
26751
+ return _context5.delegateYield(_loop(index), "t0", 11);
25864
26752
  case 11:
25865
- _ret = _context4.t0;
26753
+ _ret = _context5.t0;
25866
26754
  if (!(_ret === 0)) {
25867
- _context4.next = 14;
26755
+ _context5.next = 14;
25868
26756
  break;
25869
26757
  }
25870
- return _context4.abrupt("break", 19);
26758
+ return _context5.abrupt("break", 19);
25871
26759
  case 14:
25872
26760
  if (!(_ret === 1)) {
25873
- _context4.next = 16;
26761
+ _context5.next = 16;
25874
26762
  break;
25875
26763
  }
25876
- return _context4.abrupt("continue", 16);
26764
+ return _context5.abrupt("continue", 16);
25877
26765
  case 16:
25878
26766
  index++;
25879
- _context4.next = 9;
26767
+ _context5.next = 9;
25880
26768
  break;
25881
26769
  case 19:
25882
26770
  total = state.pagination.total - deleted;
25883
26771
  pages = Math.ceil(total / state.pagination.pageSize);
25884
26772
  current = state.pagination.current > pages ? pages : state.pagination.current;
25885
26773
  if (!(state.pagination.current > pages && filterServerSide || state.selected.length === 0)) {
25886
- _context4.next = 28;
26774
+ _context5.next = 28;
25887
26775
  break;
25888
26776
  }
25889
- _context4.next = 25;
26777
+ _context5.next = 25;
25890
26778
  return apiHandler.readList(parentMapping || configuration.mapping, mapping, _objectSpread$g({
25891
26779
  pagination: _objectSpread$g(_objectSpread$g({}, state.pagination), {}, {
25892
26780
  current: current
25893
26781
  }),
25894
26782
  columns: configuration.columns,
25895
- filters: _objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g({}, filterData.filters), globalFilter.search), !(configuration !== null && configuration !== void 0 && (_configuration$filter15 = configuration.filter) !== null && _configuration$filter15 !== void 0 && (_configuration$filter15 = _configuration$filter15.toggle) !== null && _configuration$filter15 !== void 0 && _configuration$filter15.inQuery) ? globalFilter.toggle : undefined), globalFilter.select), globalFilter.timeStamp), globalFilter["default"]),
26783
+ filters: _objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g(_objectSpread$g({}, filterData.filters), globalFilter.search), !(configuration !== null && configuration !== void 0 && (_configuration$filter16 = configuration.filter) !== null && _configuration$filter16 !== void 0 && (_configuration$filter16 = _configuration$filter16.toggle) !== null && _configuration$filter16 !== void 0 && _configuration$filter16.inQuery) ? globalFilter.toggle : undefined), globalFilter.select), globalFilter.timeStamp), globalFilter["default"]),
25896
26784
  sorter: filterData.sorter
25897
- }, configuration !== null && configuration !== void 0 && (_configuration$filter16 = configuration.filter) !== null && _configuration$filter16 !== void 0 && (_configuration$filter16 = _configuration$filter16.toggle) !== null && _configuration$filter16 !== void 0 && _configuration$filter16.inQuery ? {
26785
+ }, configuration !== null && configuration !== void 0 && (_configuration$filter17 = configuration.filter) !== null && _configuration$filter17 !== void 0 && (_configuration$filter17 = _configuration$filter17.toggle) !== null && _configuration$filter17 !== void 0 && _configuration$filter17.inQuery ? {
25898
26786
  genericProps: globalFilter.toggle
25899
26787
  } : undefined));
25900
26788
  case 25:
25901
- data = _context4.sent;
26789
+ data = _context5.sent;
25902
26790
  newData = data.data;
25903
26791
  total = data.total;
25904
26792
  case 28:
@@ -25914,17 +26802,17 @@ function useTableData (_ref) {
25914
26802
  }));
25915
26803
  case 30:
25916
26804
  case "end":
25917
- return _context4.stop();
26805
+ return _context5.stop();
25918
26806
  }
25919
- }, _callee3);
26807
+ }, _callee4);
25920
26808
  }));
25921
26809
  return function onDelete() {
25922
- return _ref7.apply(this, arguments);
26810
+ return _ref8.apply(this, arguments);
25923
26811
  };
25924
26812
  }();
25925
26813
  var onGlobalFilterSelect = function onGlobalFilterSelect(value) {
25926
- var _configuration$filter19;
25927
- if (!((_configuration$filter19 = configuration.filter) !== null && _configuration$filter19 !== void 0 && _configuration$filter19.select)) {
26814
+ var _configuration$filter20;
26815
+ if (!((_configuration$filter20 = configuration.filter) !== null && _configuration$filter20 !== void 0 && _configuration$filter20.select)) {
25928
26816
  LOG$2.error(new DivaError('No global select filter defiend'));
25929
26817
  return;
25930
26818
  }
@@ -25940,14 +26828,14 @@ function useTableData (_ref) {
25940
26828
  }, filterData), newGlobalFilter);
25941
26829
  };
25942
26830
  var onGlobalFilterToggle = function onGlobalFilterToggle() {
25943
- var _configuration$filter20;
25944
- if (!((_configuration$filter20 = configuration.filter) !== null && _configuration$filter20 !== void 0 && _configuration$filter20.toggle)) {
26831
+ var _configuration$filter21;
26832
+ if (!((_configuration$filter21 = configuration.filter) !== null && _configuration$filter21 !== void 0 && _configuration$filter21.toggle)) {
25945
26833
  LOG$2.error(new DivaError('No global toggle filter defined'));
25946
26834
  return;
25947
26835
  }
25948
26836
  var toggleFilter = {};
25949
26837
  configuration.filter.toggle.fields.forEach(function (f) {
25950
- return toggleFilter[f] = [configuration.filter.toggle.globalValue ? root.getGlobalValue(configuration.filter.toggle.globalValue) : true, 'eq', 1];
26838
+ return toggleFilter[f] = [configuration.filter.toggle.globalValue ? root.getGlobalValue(configuration.filter.toggle.globalValue) : true, 'eq', configuration.filter.toggle.isAnd ? 0 : 1];
25951
26839
  });
25952
26840
  var newGlobalFilter = _objectSpread$g(_objectSpread$g({}, globalFilter), {}, {
25953
26841
  toggle: globalFilter.toggle ? undefined : toggleFilter
@@ -25955,11 +26843,14 @@ function useTableData (_ref) {
25955
26843
  setGlobaFilter(newGlobalFilter);
25956
26844
  onChange(_objectSpread$g({
25957
26845
  pagination: state.pagination
25958
- }, filterData), newGlobalFilter);
26846
+ }, filterData), newGlobalFilter, undefined, true);
26847
+ };
26848
+ var resetToggle = function resetToggle() {
26849
+ if (globalFilter !== null && globalFilter !== void 0 && globalFilter.toggle) onGlobalFilterToggle();
25959
26850
  };
25960
26851
  var onGlobalFilterSearch = function onGlobalFilterSearch(value) {
25961
- var _configuration$filter21;
25962
- if (!((_configuration$filter21 = configuration.filter) !== null && _configuration$filter21 !== void 0 && _configuration$filter21.search)) {
26852
+ var _configuration$filter22;
26853
+ if (!((_configuration$filter22 = configuration.filter) !== null && _configuration$filter22 !== void 0 && _configuration$filter22.search)) {
25963
26854
  LOG$2.error(new DivaError('No global search filter defiend'));
25964
26855
  return;
25965
26856
  }
@@ -25967,12 +26858,12 @@ function useTableData (_ref) {
25967
26858
  search: {}
25968
26859
  });
25969
26860
  if (value) {
25970
- var _configuration$filter22;
25971
- (_configuration$filter22 = configuration.filter) === null || _configuration$filter22 === void 0 || _configuration$filter22.search.fields.forEach(function (f) {
26861
+ var _configuration$filter23;
26862
+ (_configuration$filter23 = configuration.filter) === null || _configuration$filter23 === void 0 || _configuration$filter23.search.fields.forEach(function (f) {
25972
26863
  if (typeof f == 'string') {
25973
- newGlobalFilter.search[f] = [value, 'contains', 0];
26864
+ newGlobalFilter.search[f] = [value, 'contains', 1]; //normally global search should be or, so 1
25974
26865
  } else {
25975
- newGlobalFilter.search[f[0]] = [value, f[1], 0];
26866
+ newGlobalFilter.search[f[0]] = [value, f[1], 1];
25976
26867
  }
25977
26868
  });
25978
26869
  }
@@ -25982,8 +26873,8 @@ function useTableData (_ref) {
25982
26873
  }, filterData), newGlobalFilter);
25983
26874
  };
25984
26875
  var onGlobalFilterPeriod = function onGlobalFilterPeriod(from, to) {
25985
- var _configuration$filter23;
25986
- if (!((_configuration$filter23 = configuration.filter) !== null && _configuration$filter23 !== void 0 && _configuration$filter23.period)) {
26876
+ var _configuration$filter24;
26877
+ if (!((_configuration$filter24 = configuration.filter) !== null && _configuration$filter24 !== void 0 && _configuration$filter24.period)) {
25987
26878
  LOG$2.error(new DivaError('No global period filter defiend'));
25988
26879
  return;
25989
26880
  }
@@ -26005,7 +26896,9 @@ function useTableData (_ref) {
26005
26896
  onUpdate: onUpdate,
26006
26897
  onDelete: onDelete,
26007
26898
  onSelect: onSelect,
26899
+ getDataById: getDataById,
26008
26900
  triggerRefresh: triggerRefresh,
26901
+ resetToggle: resetToggle,
26009
26902
  onSelectedCatalog: onSelectedCatalog,
26010
26903
  error: error,
26011
26904
  catalogItem: catalogItem,
@@ -26324,7 +27217,7 @@ var AGChart = function AGChart(_ref) {
26324
27217
  padding: '50px'
26325
27218
  },
26326
27219
  className: root.contentStore.theme == 'darkmode' ? 'ag-theme-alpine-dark' : 'ag-theme-alpine',
26327
- children: /*#__PURE__*/jsx(AgChartsReact, {
27220
+ children: /*#__PURE__*/jsx(AgCharts, {
26328
27221
  options: {
26329
27222
  data: dt,
26330
27223
  title: {
@@ -26673,9 +27566,7 @@ var CustomInput = function CustomInput(_ref) {
26673
27566
  })]
26674
27567
  });
26675
27568
  };
26676
- var CustomInput$1 = observer(CustomInput, {
26677
- forwardRef: true
26678
- });
27569
+ var CustomInput$1 = observer(CustomInput);
26679
27570
 
26680
27571
  function useTextData (_ref) {
26681
27572
  var id = _ref.id;
@@ -26709,9 +27600,7 @@ var CustomText = function CustomText(_ref) {
26709
27600
  });
26710
27601
  }
26711
27602
  };
26712
- var CustomText$1 = observer(CustomText, {
26713
- forwardRef: true
26714
- });
27603
+ var CustomText$1 = observer(CustomText);
26715
27604
 
26716
27605
  function ownKeys$b(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
26717
27606
  function _objectSpread$b(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$b(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$b(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
@@ -27488,15 +28377,16 @@ var BreadCrumbsTrigger = function BreadCrumbsTrigger(_ref) {
27488
28377
  return e.stopPropagation();
27489
28378
  },
27490
28379
  children: /*#__PURE__*/jsx(Breadcrumb, {
27491
- children: breadcrumbs.map(function (data) {
27492
- return /*#__PURE__*/jsx(Breadcrumb.Item, {
27493
- className: classnames(breadcrumb, root.dataStore.selectedOrganizationId === data.id ? selected : undefined, !data.readPermission ? disabled : undefined),
28380
+ items: breadcrumbs.map(function (data) {
28381
+ return {
28382
+ key: data.id,
28383
+ breadcrumbName: data.displayName,
27494
28384
  onClick: function onClick() {
27495
28385
  var _root$dataStore;
27496
28386
  return root === null || root === void 0 || (_root$dataStore = root.dataStore) === null || _root$dataStore === void 0 ? void 0 : _root$dataStore.setSelectedOrganizationId(data.id);
27497
28387
  },
27498
- children: data.displayName
27499
- }, data.id);
28388
+ className: classnames(breadcrumb, root.dataStore.selectedOrganizationId === data.id ? selected : undefined, !data.readPermission ? disabled : undefined)
28389
+ };
27500
28390
  })
27501
28391
  })
27502
28392
  })]
@@ -27709,6 +28599,7 @@ var ZoomWrapper = function ZoomWrapper(_ref) {
27709
28599
  }), /*#__PURE__*/jsx(TransformComponent, {
27710
28600
  wrapperStyle: {
27711
28601
  width: '100%',
28602
+ maxHeight: 'calc(60vh - 135px)',
27712
28603
  cursor: isZooming ? 'nesw-resize' : isGrapping ? 'grabbing' : 'grab'
27713
28604
  },
27714
28605
  wrapperProps: {
@@ -28835,7 +29726,8 @@ function useModule (currentModules) {
28835
29726
  },
28836
29727
  type: 'Configurator',
28837
29728
  id: 'WYSIWYG',
28838
- startWidth: 600
29729
+ startWidth: 600,
29730
+ defaultPinned: true
28839
29731
  });
28840
29732
  root.contentStore.tools = tools;
28841
29733
  return function () {
@@ -29960,7 +30852,7 @@ var ExclusivityFeatureOption = function ExclusivityFeatureOption() {
29960
30852
  });
29961
30853
  };
29962
30854
  var ExclusivityTable = function ExclusivityTable(_ref) {
29963
- var _ref2;
30855
+ var _selectedSerie$series;
29964
30856
  var type = _ref.type,
29965
30857
  config = _ref.config;
29966
30858
  var _useTranslation = useTranslation(),
@@ -30024,7 +30916,7 @@ var ExclusivityTable = function ExclusivityTable(_ref) {
30024
30916
  })]
30025
30917
  })
30026
30918
  }), showTable() && /*#__PURE__*/jsx(Spreadsheet, {
30027
- gridId: (_ref2 = 'crud-grid_exclusivity_' + type + (selectedSerie === null || selectedSerie === void 0 ? void 0 : selectedSerie.seriesName.DE)) !== null && _ref2 !== void 0 ? _ref2 : '',
30919
+ gridId: 'crud-grid_exclusivity_' + type + ((_selectedSerie$series = selectedSerie === null || selectedSerie === void 0 ? void 0 : selectedSerie.seriesName.DE) !== null && _selectedSerie$series !== void 0 ? _selectedSerie$series : ''),
30028
30920
  jwt: jwt,
30029
30921
  applicationData: applicationData,
30030
30922
  configuration: {
@@ -30401,8 +31293,8 @@ function Detail(_ref) {
30401
31293
  targetField: (_ob$sourceField = ob.sourceField) !== null && _ob$sourceField !== void 0 ? _ob$sourceField : ob.sourceValue
30402
31294
  });
30403
31295
  });
30404
- data = aplyMapping({
30405
- mapable: {},
31296
+ data = applyMapping({
31297
+ mappable: {},
30406
31298
  mappingData: data,
30407
31299
  mapping: {
30408
31300
  map: map,
@@ -30456,8 +31348,10 @@ function Detail(_ref) {
30456
31348
  },
30457
31349
  width: (_info$width = info.width) !== null && _info$width !== void 0 ? _info$width : left ? '800px' : '1000px',
30458
31350
  title: info.title,
30459
- bodyStyle: {
30460
- padding: 0
31351
+ styles: {
31352
+ body: {
31353
+ padding: 0
31354
+ }
30461
31355
  },
30462
31356
  footer: info.footer != false ? /*#__PURE__*/jsxs("div", {
30463
31357
  style: {
@@ -30503,8 +31397,8 @@ function Detail(_ref) {
30503
31397
  apiInterface: info.apiInterface,
30504
31398
  ref: ref,
30505
31399
  id: info.configurationId,
30506
- data: info.mapping ? aplyMapping({
30507
- mapable: {},
31400
+ data: info.mapping ? applyMapping({
31401
+ mappable: {},
30508
31402
  mapping: info.mapping,
30509
31403
  mappingData: info.data,
30510
31404
  rootStore: root
@@ -30515,8 +31409,8 @@ function Detail(_ref) {
30515
31409
  setCanSave: setCanSave
30516
31410
  }), info.type == 'RoleSelector' && /*#__PURE__*/jsx(RoleSelector$1, {
30517
31411
  ref: ref,
30518
- data: info.mapping ? aplyMapping({
30519
- mapable: {},
31412
+ data: info.mapping ? applyMapping({
31413
+ mappable: {},
30520
31414
  mapping: info.mapping,
30521
31415
  mappingData: info.data,
30522
31416
  rootStore: root
@@ -30525,8 +31419,8 @@ function Detail(_ref) {
30525
31419
  onChange: onChange
30526
31420
  }), info.type == 'RelationSelector' && /*#__PURE__*/jsx(RelationSelector$1, {
30527
31421
  ref: ref,
30528
- data: info.mapping ? aplyMapping({
30529
- mapable: {},
31422
+ data: info.mapping ? applyMapping({
31423
+ mappable: {},
30530
31424
  mapping: info.mapping,
30531
31425
  mappingData: info.data,
30532
31426
  rootStore: root
@@ -30539,8 +31433,8 @@ function Detail(_ref) {
30539
31433
  ref: ref,
30540
31434
  id: info.configurationId,
30541
31435
  onChange: onChange,
30542
- data: info.mapping ? aplyMapping({
30543
- mapable: {},
31436
+ data: info.mapping ? applyMapping({
31437
+ mappable: {},
30544
31438
  mapping: info.mapping,
30545
31439
  mappingData: info.data,
30546
31440
  rootStore: root
@@ -30634,8 +31528,8 @@ function Modal() {
30634
31528
  };
30635
31529
  var data = useMemo(function () {
30636
31530
  var _info$action;
30637
- return (_info$action = info.action) !== null && _info$action !== void 0 && _info$action.mapping ? aplyMapping({
30638
- mapable: {},
31531
+ return (_info$action = info.action) !== null && _info$action !== void 0 && _info$action.mapping ? applyMapping({
31532
+ mappable: {},
30639
31533
  mapping: info.action.mapping,
30640
31534
  mappingData: info.data,
30641
31535
  rootStore: root
@@ -30898,7 +31792,8 @@ var ArticleSelection = function ArticleSelection(_ref) {
30898
31792
  }), root.contentStore.toolPinned && /*#__PURE__*/jsx(PushpinFilled, {
30899
31793
  onClick: function onClick() {
30900
31794
  return root.contentStore.toolPinned = !root.contentStore.toolPinned;
30901
- }
31795
+ },
31796
+ className: button
30902
31797
  }), /*#__PURE__*/jsx(Select$2, {
30903
31798
  value: articleList.find(function (a) {
30904
31799
  return a.value == articleCodex;
@@ -31085,6 +31980,7 @@ function useWysiwyg$1(_ref) {
31085
31980
  hideMobileFolder: true,
31086
31981
  showSettingsFolder: true,
31087
31982
  hideRalColorFilter: false,
31983
+ showOptionCodexInOptionHeader: true,
31088
31984
  hideSearchBar: false,
31089
31985
  alwaysShowSearchBar: true,
31090
31986
  displayMetaDatas: ['codex'],
@@ -31445,6 +32341,7 @@ var Toolbar = function Toolbar(_ref) {
31445
32341
  });
31446
32342
  if (_tool) {
31447
32343
  root.contentStore.openedToolId = _tool.id;
32344
+ root.contentStore.toolPinned = !!_tool.defaultPinned;
31448
32345
  root.contentStore.hideTools = false;
31449
32346
  }
31450
32347
  }
@@ -31474,6 +32371,7 @@ var Toolbar = function Toolbar(_ref) {
31474
32371
  onClick: function onClick() {
31475
32372
  if (root.contentStore.openedToolId != t.id) {
31476
32373
  root.contentStore.openedToolId = t.id;
32374
+ root.contentStore.toolPinned = !!t.defaultPinned;
31477
32375
  root.contentStore.hideTools = false;
31478
32376
  } else {
31479
32377
  root.contentStore.hideTools = !root.contentStore.hideTools;