{"version":3,"sources":["components/Table/actions.js","api/helpers/filters.js","components/FullPageLoader/index.js","utils/toFormData.ts","utils/isIE.js","api/api.ts","api/helpers/index.js","components/MatomoHOC/index.tsx","MuiTheme.tsx","ReactQueryProvider.tsx","components/ErrorBoundary/refreshSessionButton.js","components/ErrorBoundary/index.js","components/ErrorBoundary/httpErrorBoundary.js","index.js","api/apiPoller.js","pages/admin/components/Engagement/types/index.ts","api/admin/__generated__/UserManagementAPI.ts","api/admin/adminDataManipulators.ts","api/admin/adminApi.ts","components/PageTitle/index.js","pages/newsAdmin/components/NewsExcelUploadModal/index.js","pages/newsAdmin/components/UploadImport/index.js","api/catalog/__generated__/CatalogueAPI.ts","api/catalog/catalogApi.ts","components/AppLink/index.js","components/CategoryPitch/index.js","components/SwitchWithLoader/index.js","api/catalog/queries/useCatalogueHomepageDetails.tsx","components/Footer/index.js","utils/decodeJWT.js","components/LoginManager/index.js","img/icones/Icons-Outline-Globe-White.svg","components/Menu/index.js","pages/download/index.js","pages/newsletter/NewsletterExport.tsx","pages/news/hooks/useQueryParams.js","utils/scrollTo.js","components/RestoreScroll/index.js","routes.js","App.js","hooks/useClickOutside.ts","components/OIDCMessage/index.js","utils/date.js","components/AvatarWithAsyncPhoto/index.js","api/news/engagementAccessApi.js","components/PhoneInput/codes.js","components/PhoneInput/index.js","img/illustrations/undraw_feeling_blue.svg","pages/error/UnexpectedError.js","img/illustrations/undraw_thoughts_e49y.svg","pages/error/ControlledError.js","components/AsyncSelect/index.js","components/SuspenseLoader/index.js","api/catalog/queries/useServiceGroups.tsx","img/icones/icons-outline-app-launcher-fill.svg","img/icones/icons-outline-app-launcher.svg","constants/module.ts","api/notification/__generated__/NotificationAPI.ts","api/notification/notificationAPI.ts","pages/admin/utils/is3wService.js","redux/actions/newsAdmin.js","hooks/useTableReducer.js","hooks/useData.js","components/MenuList/CustomPanel.js","components/MenuList/index.js","api/tenant/tenantApi.ts","api/utils/index.ts","exceptions/handledPromiseRejectionError.js","img/illustrations/pwc-logo-simple.svg","components/Header/index.js","api/news/articleDataManipulators.js","api/news/articleApi.js","api/news/exportNewsDataManipulator.js","api/news/exportNewsApi.js","utils/base64image.js","components/ImageUploadToBase64/ImageCropperModal/index.js","components/ImageUploadToBase64/index.js","img/icones/icons-outline-start-tour-fill.svg","img/icones/icons-outline-start-tour.svg","pages/admin/utils/model.js","pages/news/constants/index.js","pages/newsAdmin/hooks/useNewsAdminInitialize.js","api/news/newsDataManipulator.js","api/news/newsApi.js","api/news/publicationsManipulators.js","api/news/publicationsApi.js","constants/routes.js","api/data/index.js","pages/news/helpers/filename.js","components/ClearableCalendarPicker/index.js","api/catalog/type.ts","pages/admin/components/Service/type/person.ts","pages/catalogue/types/index.ts","pages/news/utils/videoMatcher.js","utils/draftjs.js","api/catalog/queries/useLifeCycles.tsx","api/catalog/queries/useValueChains.tsx","components/ImageTitle/index.js","components/SearchBar/contextsSearchbar.js","components/SearchBar/searchbar.js","components/SearchBar/index.js","components/Footer/TermsAndConditionsModal/index.js","components/ResizableAppkitModal/index.tsx","pages/newsAdmin/components/FileIcon/index.js","pages/newsAdmin/components/TableToggle/index.js","redux/actions/articles.js","api/news/territoryApi.js","redux/constants.js","api/admin/adminPoller.ts","utils/byId.js","pages/myServices/hooks/useUserServices.ts","utils/index.js","utils/tooltipsMapper.js","components/Select/index.js","pages/admin/components/AddUserToElementModal/UserSelect/index.js","api/news/articleDocumentTypeApi.js","api/news/articleTopicApi.js","api/news/issuerApi.js","api/notification/model.ts","img/illustrations/undraw_empty.svg","pages/userProfile/hooks/useNotificationTypes.ts","api/catalog/queries/useIndustries.tsx","api/catalog/queries/useLiveServices.tsx","pages/news/constants/tabs.js","redux/reducers/articles.js","redux/reducers/global.js","redux/reducers/newsAdmin.js","redux/store/store.js","redux/actions/global.js","utils/random.js","pages/admin/components/Service/type/form.ts","pages/admin/components/Engagement/types/form.ts","pages/admin/components/Engagement/hooks/useSubscriptions.ts","pages/admin/components/Engagement/index.tsx","api/news/engagementAccessPoller.js","pages/admin/components/MultiSelect/index.js","pages/admin/components/ThreeWPermissionsModal/index.js","pages/admin/actions/index.ts","pages/admin/actions/reducer.ts","pages/admin/components/Company/index.js","pages/admin/components/Company/hooks/useCompanyReducer.js","pages/admin/components/CompanySelect/index.js","pages/admin/components/Entity/index.js","pages/admin/components/Entity/hooks/useEntityReducer.js","pages/admin/components/Engagement/AddEngagementModal/EntitySelect/index.js","pages/admin/hooks/useMultilineForm.ts","pages/admin/components/Engagement/AddEngagementModal/LinksForm/LinkForm.tsx","pages/admin/components/Engagement/AddEngagementModal/LinksForm/index.tsx","pages/admin/components/Service/type/index.ts","pages/admin/components/Service/components/AdminServiceContextHOC.tsx","pages/admin/components/Service/hooks/useServiceReducer.ts","pages/admin/components/Engagement/AddEngagementModal/ServiceSelect/index.tsx","pages/admin/components/Engagement/AddEngagementModal/index.tsx","pages/admin/components/Engagement/SubscriptionDetails/index.tsx","pages/admin/constants/index.js","pages/admin/utils/index.js","pages/admin/components/UserTable/index.tsx","pages/admin/components/Engagement/SubscriptionTable/MenuList.tsx","pages/admin/components/Engagement/SubscriptionTable/index.tsx","pages/admin/components/AddUserToElementModal/Modal/index.js","pages/admin/components/Engagement/EngagementsTable/addUserToEngagementModal.js","pages/admin/components/Engagement/EngagementsTable/deleteEngagementModal.js","pages/admin/components/RemoveUserFromElementModal/index.js","pages/admin/components/Engagement/EngagementsTable/deleteUserFromEngagementModal.js","pages/admin/components/Engagement/EngagementsTable/index.tsx","pages/admin/components/Engagement/SubscriptionAdmin/index.jsx","components/Table/hooks/useStickyHeader.js","pages/admin/hooks/useMainTableStickyHeader.js","pages/admin/components/Entity/AddEntityModal/index.js","pages/admin/components/Entity/DeleteEntityModal/index.tsx","pages/admin/components/Entity/EntitiesTable/addMultipleUsersToEntityModal.js","pages/admin/components/Entity/EntitiesTable/addUserToEntityModal.js","pages/admin/components/Entity/EntitiesTable/deleteUserFromEntityModal.js","pages/admin/components/Entity/EntitiesTable/MenuList.tsx","pages/admin/components/Entity/EntitiesTable/index.js","pages/admin/components/Entity/EntityAdmin/index.jsx","pages/admin/components/User/AddUserModal/index.js","pages/admin/components/User/DeleteUserModal/index.js","pages/admin/components/User/NotifyUserModal/index.js","pages/admin/components/User/RefreshUserModal/index.js","pages/admin/components/User/UsersTable/index.js","pages/admin/components/User/UserAdmin/refreshUsersModal.js","pages/admin/components/User/UserAdmin/index.js","pages/admin/components/Company/AddCompanyModal/index.js","pages/admin/components/Company/CompaniesTable/index.js","pages/admin/components/Filters/ContextToggle.js","pages/admin/components/Filters/MyServices.tsx","pages/admin/components/Filters/TrialFilter.tsx","pages/admin/components/Filters/index.js","components/Textarea/index.js","pages/admin/components/Service/components/AddServiceModal/ApplicationsForm/AppForm.tsx","pages/admin/components/Service/components/AddServiceModal/ApplicationsForm/index.tsx","pages/admin/components/Service/components/AddServiceModal/IllustrationList/index.tsx","pages/admin/components/Service/components/AddServiceModal/LifeCycleSelect/index.tsx","pages/admin/components/Service/components/AddServiceModal/OrganizationSelect/index.tsx","pages/admin/components/Service/components/AddServiceModal/ServiceGroupSelect/index.tsx","pages/admin/components/Service/components/AddServiceModal/ServiceIndustryTagSelect/index.tsx","pages/admin/components/Service/components/AddServiceModal/ServiceSelect/index.tsx","pages/admin/components/Service/components/AddServiceModal/ValueChainSelect/ValueChainSelect.tsx","pages/admin/components/Service/components/AddServiceModal/index.tsx","pages/admin/components/Service/components/DeleteServiceModal/index.tsx","pages/admin/components/Service/components/Table/ServiceTableBadge.tsx","pages/admin/components/Service/components/Table/index.tsx","pages/admin/components/Service/components/index.tsx","pages/admin/components/ServiceGroup/AddServiceGroupModal/index.js","api/catalog/queries/useServiceGroupById.tsx","pages/admin/components/ServiceGroup/DeleteServiceGroupModal/index.tsx","pages/admin/components/ServiceGroup/Table/index.js","pages/admin/components/ServiceGroup/index.tsx","pages/admin/img/header.png","pages/admin/index.js","pages/catalogue/constants/index.js","components/Table/expanded.js","components/Table/LoadingComponent.js","components/Table/table.js","components/Table/index.js","hooks/useSubmitable.ts","utils/localeCompare.js","api/catalog/catalogPoller.ts","components/FloatingActionButton/index.js","constants/index.js","components/DeleteModal/index.js","api/auth/config.js"],"names":["Actions","_ref","_ref$handleEdit","handleEdit","undefined","_ref$handleDelete","handleDelete","_ref$handleEditPwcPan","handleEditPwcPanel","_ref$handleRefresh","handleRefresh","_ref$handleNotify","handleNotify","_jsxs","className","children","_jsx","Tooltip","title","placement","enterDelay","IconButton","kind","onClick","process","toDateRangeFilter","range","toDateFilter","start","Date","end","dateFrom","dateTo","UTC","getFullYear","getMonth","getDate","toISOString","toTextFilter","text","trim","length","toSafeNumberFilter","number","isNaN","FullPageLoader","props","_props$message","message","_props$onCancel","onCancel","_props$onCancelLabel","onCancelLabel","ReactDOM","createPortal","Button","document","getElementById","appendValue","formData","key","value","append","Blob","JSON","stringify","concat","isIE","window","documentMode","RET_JSON","RET_RAW","RET_TEXT","CONTENT_TYPE_JSON","CONTENT_TYPE_TEXT","apiFetch","url","body","arguments","method","returnType","headers","_apiFetch","apiFetchFormData","asFormData","showLeafArrayIndexes","mapping","apiFetchFormDataCustom","object","FormData","_i","_Object$entries","Object","entries","_Object$entries$_i","_slicedToArray","Array","isArray","_step","_iterator","_createForOfIteratorHelper","s","n","done","arrayValue","err","e","f","toFormData","appendIEHeaders","_objectSpread","Pragma","appendTokenHeaders","authToken","sessionStorage","getItem","DEFAULT_OIDC_KEY","parse","access_token","error","console","Authorization","Accept","appendAcceptHeader","fetch","then","data","ok","status","json","Error","dataURItoBlob","dataURI","dataTYPE","binary","atob","split","array","i","push","charCodeAt","Uint8Array","type","toUTCISODateString","date","instance","createInstance","urlBase","siteId","Number","parseInt","disabled","linkTracking","MatomoTracker","_ref2","_useMatomo","useMatomo","enableLinkTracking","trackPageView","pushInstruction","loginUser","useSelector","state","global","location","useLocation","useEffect","ppid","isInternal","href","pathname","_Fragment","MatomoHOC","MatomoProvider","theme","createTheme","typography","fontFamily","join","palette","primary","main","secondary","components","MuiIconButton","styleOverrides","sizeSmall","fontSize","MuiTable","root","backgroundColor","MuiTableCell","paddingTop","paddingBottom","MuiAvatar","height","width","MuiBreadcrumbs","marginBottom","MuiListItemText","marginRight","MuiButton","borderRadius","boxShadow","fontWeight","MuiDialogTitle","color","MuiInputAdornment","positionStart","marginLeft","MuiTheme","StyledEngineProvider","injectFirst","ThemeProvider","queryClient","QueryClient","defaultOptions","queries","retry","refetchOnWindowFocus","onError","Promise","reject","ReactQueryProvider","QueryClientProvider","client","RefreshSessionButton","size","removeItem","reload","ErrorBoundary","_Component","_inherits","_super","_createSuper","_this","_classCallCheck","call","loading","_createClass","prevProps","this","hasError","GLOBAL_ERRORS","NO_ERROR","replace","NO_COMPANY","ControlledError","subtitle","description","NO_USER","showReloadButton","SESSION_EXPIRED","showLogoutButton","customButton","NO_TENANT","UNKNOWN","UnexpectedError","Component","withRouter","connect","DEFAULT_MESSAGE","HTTPErrorBoundary","apply","onunhandledrejection","reason","Response","resolve","errorMessages","errors","PopBanner","content","map","itemId","closeable","_unused","HandledPromiseRejectionError","render","Provider","store","AuthenticationProvider","configuration","oidcConfig","loggerLevel","oidcLog","NONE","authenticating","OIDCMessage","timeoutButton","sessionLostComponent","buttonLabel","buttonAction","authenticateUser","getUserManager","callbackComponentOverride","oldOnPopState","onpopstate","search","substr","indexOf","notAuthenticated","notAuthorized","BrowserRouter","PageTitle","App","cookieHandler","PwcCookie","run","delays","getDelay","Math","floor","reduce","acc","delay","attemptNumber","pollData","pollingPromise","checkShouldPoll","timeoutResult","catch","setTimeout","pollerCheck404","pollerCheck204","pollerCheck4XX","pollerCheck2XX","pollerCheckUndefined","toECModules","dto","deliverables","documents","toECSModules","links","tasks","toSubscriptionDetails","_dto$contacts","clientContent","ec","ecModules","ecs","ecsModules","applications","contacts","clientContacts","ContentType","HttpClient","apiConfig","baseUrl","securityData","securityWorker","abortControllers","Map","customFetch","baseApiParams","credentials","redirect","referrerPolicy","setSecurityData","contentFormatters","_defineProperty","Json","input","keys","property","UrlEncoded","toQueryString","createAbortSignal","cancelToken","has","abortController","get","signal","AbortController","set","abortRequest","abort","delete","request","_asyncToGenerator","_regeneratorRuntime","mark","_callee2","secure","path","query","format","params","secureParams","requestParams","queryString","payloadFormatter","responseFormat","wrap","_context2","prev","next","_objectWithoutProperties","_excluded","t1","sent","t0","mergeRequestParams","abrupt","_ref3","_callee","response","r","_context","stop","_x2","_x","assign","encodedKey","encodeURIComponent","encodeQueryParam","_this2","v","rawQuery","_this3","filter","addArrayQueryParam","addQueryParam","params1","params2","Api","_HttpClient","_this4","_len","args","_key","api","v1CompanyList","v1CompanyCreate","v1CompanyUpdate","companyId","v1CompanyDelete","v1EntityList","v1EntityCreate","v1EntityDetail","entityId","v1EntityUpdate","v1EntityDelete","v1EntityMyContactsList","v1EntityUsersUpdate","v1EntityUsersDelete","v1EntityImportList","v1EntityImportCreate","v1IntegrationEntityByUserDetail","v1ExportUsersPermissionsCreate","v1OrganizationPagedCreate","v1IntegrationOrganizationByNamesCreate","v1ServiceList","v1ServiceMyList","v1SubscriptionDetail","subscriptionId","v1SubscriptionUpdate","v1SubscriptionDelete","v1SubscriptionMyServicesList","v1SubscriptionMyClientsList","v1SubscriptionMyClientsServicesCreate","v1SubscriptionByServiceDetail","serviceId","v1SubscriptionPagedUsersCreate","v1SubscriptionCreate","v1SubscriptionUsersUpdate","v1SubscriptionUsersPartialUpdate","v1SubscriptionUsersDelete","v1SubscriptionImportList","v1SubscriptionImportCreate","v1UserCreate","v1UserUpdate","v1UserDelete","v1UserDetail","v1UserMyProfileUpdate","v1UserMyProfileList","v1UserTermsAndConditionsAcceptedPartialUpdate","v1UserSuperuserPartialUpdate","isSuperUser","v1UserServicesDetail","v1UserPagedCreate","v1UserDetail2","id","v1UserExistingUserList","v1UserEntitiesContactsDetail","v1UserImportList","v1UserImportCreate","v1IntegrationUserDetail","v1IntegrationUserByPpidsCreate","v1IntegrationUserByEmailsCreate","integrationUser","v1IntegrationUserLookupByEmailList","v1IntegrationUserLookupByPpidList","v1IntegrationUserLookupByAttributeList","adminAdaptUserToBackEnd","oldData","newData","Email","email","FirstName","firstName","Grade","grade","IsSuperUser","LastName","lastName","PhoneCountryCode","phoneCountryCode","PhoneNumber","phoneNumber","Photo","Entities","entities","Send3WEmail","send3WEmail","SendAmdsEmail","sendAmdsEmail","CreationIdentity","creationIdentity","photo","MIME_PNG","PREFIX","DEFAULT_PAGINATION","pageSize","pageNumber","_clientSingleton","toData","res","getMyProfile","getUsers","filters","pagination","getUsersFromIdArray","ids","getUserDetails","deleteUser","getSubscriptionsUsersPaged","getSubscriptionDetails","upsertSubscriptionCatch","exception","_exception$error","_exception$error$0$me","startsWith","addEngagement","engagement","_engagement","users","user","isMainContact","updateEngagement","getUserFromEmail","createUser","updateUser","downloadUserImportTemplate","blob","downloadBlob","importUsersFromExcel","file","importFile","downloadEntityImportTemplate","importEntitiesFromExcel","updateProfile","addUserToEngagement","subscirptionId","ppids","updateUserEngagement","userPpid","deleteUserFromEngagement","engagementId","deleteEngagement","downloadSubscriptionImportTemplate","importSubscriptionFromExcel","downloadServiceImportTemplate","downloadServiceExport","downloadUserPermissions","importServiceFromExcel","updateSuperUserStatus","getPhoto","photoUri","imageFromBlob","resendUserWelcomeEmails","send3w","sendAmds","getCompanies","createCompany","company","updateCompany","_excluded2","acceptTermsAndConditions","getAllEntities","createEntity","updateEntity","_excluded3","getMyContacts","getUserEntitiesContacs","deleteEntity","addUserToEntity","removeUserFromEntity","getAdminCatalogue","getUserSubscriptions","getMyClientNames","getMyServices","getMyClientSubscriptions","clientIds","getOrganizations","getSubscriptionsByService","getSubscriptionsByUser","userId","getUserContacts","orderBy","name","isDescending","refreshUser","refreshAllUsers","_ref$title","hostInfoName","_state$global$data$ho","hostInfo","suffix","Helmet","NewsExcelUploadModal","_ref$uploadedFile","uploadedFile","onClose","handleConfirm","_ref$type","ResizableAppkitModal","backdropClosable","visible","ModalHeader","ModalBody","FileIcon","mimeType","ModalFooter","UploadImport","onImport","onDownloadTemplate","_useState","useState","_useState2","fileToUpload","setFileToUpload","_useState3","_useState4","uploadingExcel","setUploadingExcel","toUpperCase","substring","duration","finally","Upload","showFileList","onChange","MIME_XLSX","originFile","autoUpload","action","preventDefault","stopPropagation","v1CaptchaCreate","v1IndustryList","v1IndustryAllList","v1IndustryCreate","v1IndustryDetail","industryId","v1IndustryCreate2","v1IndustryUpdate","v1IndustryDelete","v1IndustryDetail2","subIndustryId","v1IndustryUpdate2","v1IndustryDelete2","v1LifecycleList","v1LifecycleAllList","v1LifecycleCreate","v1LifecycleDetail","lifecycleId","v1LifecycleUpdate","v1LifecycleDelete","v1LifecycleOrderUpdate","order","v1PageList","v1PageFieldsUpdate","v1PageOptionsUpdate","v1ServiceDetail","v1ServiceDetailFriendly","v1ServiceUpdate","v1ServiceDelete","v1ServiceCreate","v1ServiceLiveList","v1ServiceDetail2","illustrationId","v1ServiceLivePartialUpdate","v1ServiceNewPartialUpdate","v1ServiceHighlightedPartialUpdate","v1ServiceImportList","v1ServiceImportCreate","v1ServiceExportExcelCreate","v1ServiceContactCreate","v1ServiceGroupList","v1TerritoriesList","v1TerritoryGet","v1TerritoryCreate","v1TerritoryUpdate","v1TerritoryDelete","v1ServiceByidsCreate","v1ServiceGroupCreate","v1ServiceGroupDetail","v1ServiceGroupUpdate","v1ServiceGroupDelete","v1ValueChainList","v1ValueChainAllList","v1ValueChainCreate","v1ValueChainDetail","valueChainId","v1ValueChainUpdate","v1ValueChainDelete","v1ValueChainOrderUpdate","getServiceDetails","match","createService","service","updateService","removeService","updateDisplayStatus","live","updateIsNew","isNew","updateIsHighlighted","isHighlighted","getCatalogue","getCatalogueServiceDetails","getCatalogueHomepageDetails","updateCatalogueHomepageDetails","homepage","updateCatalogueOptions","getCaptcha","resourceId","sendContactForm","form","getLifeCycles","getLifeCyclesAll","addLifeCycle","lifeCycle","deleteLifeCycle","editLifeCycle","editLifeCycleOrder","getLifeCycleById","getIndustries","getIndustriesAll","getIndustryById","getSubIndustryById","parentId","addIndustry","industry","addSubIndustry","deleteIndustry","deleteSubIndustry","editIndustry","editSubIndustry","getValueChains","getValueChainsAll","addValueChain","valueChain","deleteValueChain","editValueChain","editValueChainOrder","getValueChainById","getServiceGroups","getTerritories","addServiceGroup","serviceGroup","editServiceGroup","getServiceGroupById","deleteServiceGroup","addTerritory","territory","editTerritory","deleteTerritory","getTerritoryById","getServiceByIds","AppLink","_ref$className","_ref$external","external","_ref$transparent","transparent","otherProps","allClassNames","classNames","target","rel","Link","CategoryPitch","image","_ref$rightChildren","rightChildren","_ref$marginBottomOffs","marginBottomOffset","_ref$titleMarginBotto","titleMarginBottom","style","backgroundImage","Skeleton","SwitchWithLoader","_ref$onText","onText","_ref$offText","offText","loader","Switch","useCatalogueHomepageDetails","useQuery","Footer","termsAndConditionsOpened","setTermsAndConditionsOpened","TermsAndConditionsModal","opened","termsAndConditionsAccepted","decodeJWT","token","TokenManager","_oidcProps$oidcUser","oidcProps","dispatch","useDispatch","history","useHistory","oidcUser","currentLocation","pollCheckCreatingUser","setSessionExpired","setLoginUserNotFound","upsertLoginUser","globalInitialize","AuthenticationContext","Consumer","outlineAction","MODULE_MENUS","MODULES","MYSERVICES","MYCLIENTS","CLIENT_VIEW","CATALOGUE","NEWS","LeftNav","_PureComponent","onMouseDown","setState","hasOutLine","lastAction","onBlur","self","_assertThisInitialized","keyEvent","keyCode","addEventListener","removeEventListener","evt","KeyCode","ENTER","querySelector","click","_this$props$userServi","userLogged","displayedModules","menu","MODULE_VALUES","requireConnexion","_this2$props$loginUse","isInternalOnly","_this2$props$loginUse2","_this2$props$userServ","userServices","NEWS_MODULE_IS_ENABLED","module","selectedMenu","findCurrentModuleKey","List","rootPath","listitemClasses","active","item","to","ListItem","onKeyDown","handleKeyDown","bind","tabIndex","icon","index","src","fillIcon","outlineIcon","alt","label","_service$links","some","link","showToClient","GlobeIconOutline","PureComponent","useUserServices","Downloader","publicationId","getPublication","publication","getFile","fileUrl","downloadFromResponse","NewsletterExport","setLoading","setError","useMemo","URLSearchParams","useQueryParams","publishDateStart","publishDateEnd","exportAllToExcel","exportAllToWord","published","publishedDateRange","defaultFilename","toLocaleLowerCase","scrollTo","domNodeRef","documentElement","left","top","warn","RestoreScroll","appRef","useContext","ScrollContext","_history$location$sta","current","scrollTop","Error404","lazy","LogoutSuccess","ArticlesLandingPage","ShowArticle","ArticleEditor","NewsAdmin","Admin","UserProfile","CreatingUser","Catalogue2","CatalogueServiceDetails","MyServices","PWCServices","MyClients","ClientView","ModuleSecure","initialized","menus","values","INITIALIZE","TRUE","find","routeModule","findCurrentModule","Routes","Suspense","fallback","SuspenseLoader","Route","exact","component","withOidcSecure","oidcParams","DOWNLOAD_PUBLICATION_BASEURL","articleId","ADMIN","AdminWithInitializer","NEWS_ADMIN","PROFILE","createContext","ref","useRef","currentUser","getTenant","upsertHostInfo","setNoTenant","Header","LoginManager","Menu","useClickOutside","open","ousideRef","rootRef","eventRef","handleClickOutside","_ref$current","contains","containerNode","_ref$subtitle","_ref$illustration","illustration","_ref$buttonLabel","_ref$buttonAction","_ref$timeoutButton","viewTimeout","setViewTimeout","storedTimeout","setStoredTimeout","clearTimeout","authority","client_id","formatDate","pattern","moment","computeCurrentMonth","today","setDate","setUTCHours","getEntireMonthRange","numberOfMonths","getEntireYear","year","atMidnight","toISODateStringIgnoreTime","toString","padStart","AvatarWithAsyncPhoto","_ref$children","setPhoto","initials","getInitialsFromName","Avatar","getThreeWPermissions","idSubscription","updateThreeWPermissions","permissions","getAllSubscriptionsFromType","codes","code","country","DEFAULT_VALUE","validatePhone","_value$number","valueNumber","replaceAll","test","PhoneInput","_ref$value","Select","showSearchOnList","onSelect","SelectOption","Input","placeholder","classList","add","remove","maxWidth","stack","_ref$showLogoutButton","_ref$showReloadButton","_ref$customButton","_ref$dark","dark","classnames","handleLogout","DEFAULT_EQUALS","a","b","AsyncSelect","loadItems","_ref$pageSize","multiple","_ref$disabled","_ref$clickOutsideRef","clickOutsideRef","_ref$isEqual","isEqual","_ref$hasError","_ref$errMsg","errMsg","_ref$clearable","clearable","_ref$selectedLabel","selectedLabel","_ref$getTooltip","getTooltip","setOpen","textSearch","setTextSearch","_useState5","_useState6","items","setItems","_useState7","_useState8","hasMore","setHasMore","_useState9","_useState10","tooltipContent","setTooltipContent","inputRef","scrollWrapper","useCallback","_data$hasNext2","_data$items2","hasNext","isEmptySelection","toggleText","debouncer","clearInterval","useLayoutEffect","findDOMNode","focus","close","selectRef","handleSelect","findIndex","_toConsumableArray","onOpen","display","bottom","marginTop","maxHeight","InfiniteScroll","loadMore","_data$hasNext","_data$items","initialLoad","useWindow","pageStart","getScrollParent","Checkbox","checked","_ref$text","useServiceGroups","queryOptions","host","PSF_PSA_IS_ENABLED","isLuxOnly","CatalogueIconOutline","CatalogueIconFill","NewsIconOutline","NewsIconFill","uri","v1NotificationList","v1NotificationUpdate","v1NotificationDetail","v1NotificationByPpidsCreate","v1NotificationTypesList","v1NotificationUnsubscribeList","v1NotificationRunWeeklyCreate","getNotificationsByPpids","getNotifications","updateNotifications","notifications","getNotificationTypes","unsubscribe","threeWServiceIds","is3wService","includes","NEWS_ADMIN_CHANGE_TAB","newsAdminChangeTab","tab","payload","SORT_CHANGE","PAGE_NUMBER_CHANGE","PAGE_SIZE_CHANGE","reducer","sorted","page","useTableReducer","_useReducer","useReducer","_useReducer2","onPageSizeChange","pageSizeChange","onPageChange","pageChange","onSortedChange","sort","sortChange","useData","apiCall","initialSorted","appendOrderWithName","_data$totalPages","totalCount","setData","tableReducer","fetchData","desc","pages","MAX_VALUE","totalPages","max","optimisticChange","newItem","prevData","CustomPanel","classes","Panel","MenuList","_ref$tooltip","tooltip","node","mouseEnterDelay","adminGetTenants","reader","FileReader","readAsDataURL","onloadend","result","onerror","_Error","_wrapNativeSuper","getProfileData","_props$loginUser","idToken","id_token","origin","LogoutTooltip","profileData","HeaderContent","optionVal","showValue","val","_this$props$loginUser2","showSettings","zIndex","PwcLogo","trigger","refClassName","tooltipTheme","clickToClose","containerid","login","ConnectedHeaderContent","adaptArticleFromBackEnd","publishDate","creationDate","lastUpdateDate","startDate","endDate","businessId","blankRawDraft","adaptArticleToBackEnd","_ref4","toApiFilter","territories","issuers","topics","documentTypes","publishDateRange","linkedNewsDateRange","freeTextSearch","checkedEventDates","businessIdFilters","clientNoteFilter","pwcNoteFilter","PREFIX_3W","PREFIX_GLOBAL","ARTICLE_TYPES","GLOBAL","getPrefixFromType","genericGetList","newsType","_ref$pageNumber","genericDeleteArticle","genericGetArticle","genericUpdateArticle","article","adaptedArticle","genericCreateArticle","_x3","_x4","genericPublishArticle","_callee3","publish","_context3","_x5","_x6","_x7","genericGetBusinessId","getNewsPermissions","getUsedMetadataForType","downloadTemplate","importArticlesFromExcel","getClientNote","getClientNoteFromSubscription","updateClientNote","clientNoteContent","updateClientNotePersonal","note","assignToMe","assignedToMe","personalComments","getPwcNote","updatePwcNote","getAllPwcNotes","mustRead","issuedDateRange","exportAsSubscriptionId","withExtendedInfos","exportArticlesToExcel","articleIds","exportSelectedNewsToExcel","exportFilteredNewsToExcel","exportSelectedEventsToExcel","eventIds","exportFilteredEventsToExcel","exportType","trimMime","b64","splitedValue","ImageCropperModal","onValidate","_ref$aspect","aspect","unit","crop","setCrop","imageRef","setImageRef","onSubmit","makeClientCrop","getCroppedImg","canvas","createElement","scaleX","naturalWidth","scaleY","naturalHeight","getContext","drawImage","x","y","toBlob","Modal","ReactCrop","ruleOfThirds","onImageLoaded","abs","originalIsValidRatio","timeout","availableMIMETypes","INVALID_IMAGE_ERROR","defaultInvalidImageAction","defaultSizeExceededAction","maxSize","formatBytes","ImageUploadToBase64","_ref$onError","_ref$trimMime","_ref$maxSize","_ref$onSizeExceeded","onSizeExceeded","_ref$openCropAfterSel","openCropAfterSelect","_ref$cropRatio","cropRatio","_ref$onCropOpened","onCropOpened","_ref$onCropCanceled","onCropCanceled","isDragging","setIsDragging","isCropping","setIsCropping","addDragListener","onDragOver","removeDragListener","removeDragEndListener","onDragOut","newImage","accept","event","files","eventFunction","imageSrc","Image","onload","newValue","applyTrimMime","fromUserModel","phone","toUserModel","view","_phone$number","THREEW_FUND_DISTRI","THREEW_REG","THREEW_TAX","THREEW_AWM","ARTICLE_CLASSNAME","ARTICLE_SERVICE","ARTICLES_LABELS","SECTION_TITLES","background","whatsNew","whatsNext","freeContent","PERMISSION_TYPES","READ","WRITE","DELETE","useNewsAdminInitialize","triggerInit","newsAdminInitialized","articles","useStore","getState","FALSE","articlesInitNewsAdmin","articlesSetPermissions","repositoryItem","isAlive","adaptNewsToBackEnd","oldNews","news","issueDate","repositoryText","isObject","adaptNewsFromBackend","_adaptNewsFromBackend","_new","getList","getDashboard","getListByArticle","getNews","newsId","getNewsTitlesFromIds","addNews","updateNews","deleteNews","publishNews","setArticleId","newsIds","importNewsFromExcel","adaptDataToBackend","deletePublication","updatePublication","createPublication","publishPublication","_require","require","ClearableCalendarPicker","onClearValue","CalendarPicker","ServiceType","toPersonDTO","_user$phoneNumber","_user$phoneCountryCod","firstname","lastname","toCatalogueService","_dto$responsibles","_dto$team","_dto$industries","subscribed","responsibles","itContact","team","industries","toCatalogueServiceDetails","videoLink","isServiceDetails","serviceDetails","VIDEO_TYPES","YOUTUBE","VIMEO","matchers","matches","exec","splittedId","shift","findFirstMatcher","_matchers","matcher","validateURL","isValidUrl","draftContentIsEmpty","draft","striptags","draftRawToHtml","convertToRaw","EditorState","createEmpty","getCurrentContent","raw","draftToHtml","useLifeCycles","useLifeCyclesAll","useValueChains","useValueChainsAll","SubTitle","ImageTitle","_ref$src","DEFAULT_SRC","_ref$alt","Searchbar","onFiltersChange","columns","setSearch","selectedOption","setSelectedOption","focused","setFocused","addFilter","column","deleteFilter","filterId","possibleContexts","usedContexts","c","columnKeys","resetSearchbar","Tag","isValid","onKeyUp","selectedIndex","newIndex","arrowUp","arrowDown","onFocus","SearchBar","inputProps","prefix","acceptingTermsAndConditions","setAcceptingTermsAndConditions","handleClose","adminAcceptTermsAndConditions","isLoading","_modalProps$style","_ref$width","propsWidth","modalProps","setWidth","ResizableBox","axis","resizeHandles","minConstraints","onResize","_event","MIME_PDF","MIME_DOC","MIME_DOCX","MIME_XLS","MIME_PPT","MIME_PPTX","MIME_JPEG","TABS","ARTICLES","EVENTS","VIDEOS","PUBLICATIONS","TOPICS","ISSUERS","DOCUMENTTYPES","SUBSCRIPTIONS","OPTIONS","TableToggle","selected","newsAdmin","Tabs","_","Tab","ARTICLES_INITIALIZE","ARTICLES_INITIALIZE_SUCCESS","articleInit","articlesGetMetadataForType","NEWS_ADMIN_INITIALIZE","NEWS_ADMIN_INITIALIZE_SUCCESS","all","articlesSetTerritories","articlesSetTopics","articlesSetDocumentTypes","articlesSetIssuers","ARTICLES_CHANGE_FILTERS","articlesChangeFilters","newFilters","ARTICLES_CHANGE_TAB","articlesChangeLandingTab","ARTICLES_RESET_FILTERS","articlesResetFilters","selectedType","ARTICLES_SET_TERRITORIES","dispath","ARTICLES_SET_METADATA_TYPE","_callee4","_context4","ARTICLES_SET_PERMISSIONS","_ref5","_callee5","_context5","ARTICLES_SET_ISSUERS","_ref6","_callee6","_context6","getIssuers","ARTICLES_MANUAL_CREATE_ISSUER","articlesManualCreateIssuer","issuer","ARTICLES_MANUAL_UPDATE_ISSUER","articlesManualUpdateIssuer","ARTICLES_MANUAL_DELETE_ISSUER","articlesManualDeleteIssuer","ARTICLES_SET_ARTICLE","ARTICLES_SET_ARTICLE_FIELD","NEWS_CHANGE_PAGE","NEWS_CHANGE_PAGE_SUCCESS","ARTICLES_SET_TOPICS","_ref8","_callee8","_context8","getTopics","_x8","ARTICLES_MANUAL_CREATE_TOPIC","articlesManualCreateTopic","topic","ARTICLES_MANUAL_UPDATE_TOPIC","articlesManualUpdateTopic","ARTICLES_MANUAL_DELETE_TOPIC","articlesManualDeleteTopic","ARTICLES_SET_DOCUMENT_TYPES","_ref9","_callee9","_context9","getDocumentTypes","_x9","ARTICLES_MANUAL_CREATE_DOCUMENT_TYPE","articlesManualCreateDocumentType","documenttype","ARTICLES_MANUAL_UPDATE_DOCUMENT_TYPE","articlesManualUpdateDocumentType","ARTICLES_MANUAL_DELETE_DOCUMENT_TYPE","articlesManualDeleteDocumentType","CALENDAR_SET_FOCUS_DATE","calendarSetFocusDate","WIP","pollAddCompany","addedCompany","companies","pollUpdateCompany","pollCreateUser","createdUser","pollUpdateUser","initialUser","checkUpdateUserProfile","pollUpdateProfile","userDetails","deepEqual","pollDeleteUser","_ref7","_callee7","_context7","_x10","pollUpdateSuperUserStatus","_x13","_x14","_x11","_x12","pollAddEngagement","_ref10","_callee10","newEngagement","_context10","_x15","pollUpdateEngagement","_ref11","_callee12","subscription","_context12","_ref12","_callee11","subscriptionDetails","_context11","_x17","_x18","_x16","_subscription$contact","getTime","localeCompare","contact","pollDeleteEngagement","_ref13","_callee13","_context13","_x19","pollAddUserToEngagement","_ref14","_callee15","_context15","_ref15","_callee14","_context14","pollCheckUserInSubscription","_x22","_x23","_x20","_x21","pollUpdateUserEngagement","_ref16","_callee17","_context17","_ref17","_callee16","_subscription$users","_context16","_x27","_x28","_x24","_x25","_x26","pollDeleteUserFromEngagement","_ref18","_callee19","_context19","_ref19","_callee18","_context18","_x31","_x32","_x29","_x30","_x33","_x34","_pollCheckUserInSubscription","_callee25","subscriptions","_context25","memberPpid","pollAddEntity","_ref20","_callee20","entity","newEntity","_context20","_x35","pollUpdateEntity","_ref21","_callee21","_context21","updatedEntity","_e$contacts$map","_e$contacts","_e$name","_entity$name","_entity$contacts2","prid","every","p","_entity$contacts","viewInMyServices","_x36","pollDeleteEntity","_ref22","_callee22","_context22","_x37","pollAddUserToEntity","_ref23","_callee23","_context23","_x38","_x39","pollRemoveUserFromEntity","_ref24","_callee24","_context24","_x40","_x41","byId","setUserServices","services","serviceById","_subscription$clientC","RegExp","bytes","decimals","dm","log","parseFloat","pow","toFixed","filename","contentDisposition","regexp","blobUrl","URL","createObjectURL","download","appendChild","dispatchEvent","MouseEvent","bubbles","cancelable","removeChild","tooltipMap","selectedIds","ValidationSelect","_value$length","_ref2$errMsg","_ref2$hasError","_ref2$className","_ref2$clearable","_ref2$multiple","selectProps","isOpen","setIsOpen","isEmptyValue","ValidationSelectTooltipHoc","_selectProps$value","_objectDestructuringEmpty","child","_child$props","_child$props2","DEFAULT_FILTERS","EXTERNAL_ONLY_FILTERS","INTERNAL_ONLY_FILTERS","UserSelect","_ref$filters","_ref$alreadyAdded","alreadyAdded","contactImages","setContactImages","loadUsers","alreadyAddedByPpid","forEach","_contact$email","getDocumentType","documentTypeId","createDocumentType","documentType","updateDocumentType","deleteDocumentType","getTopic","topicId","createTopic","updateTopic","deleteTopic","getIssuer","issuerId","createIssuer","updateIssuer","deleteIssuer","FREQUENCIES","WEEKLY","FRENQUENCIES_LABEL","useNotificationTypes","notificationTypes","setNotificationTypes","byValue","useIndustries","useIndustriesAll","useLiveService","defaultArticlesFilters","textFilters","impact","ratings","initialState","itemsByType","territoriesById","topicsById","documentTypesById","issuersById","calendarSourceDate","currentArticle","landingTab","rootReducer","issuersCreate","issuersUpdate","issuersDelete","access","newState","field","topicsCreate","topicsUpdate","topicsDelete","documentTypesCreate","documentTypesUpdate","documentTypesDelete","itemsById","tenants","usersReducer","GLOBAL_INIT","GLOBAL_INIT_SUCCESS","GLOBAL_INIT_ERROR","UPSERT_LOGINUSER","UPSERT_HOSTINFO","UPSERT_TENANTS","ADMIN_ACCEPT_TERMS_AND_CONDITIONS","composeEnhancers","__REDUX_DEVTOOLS_EXTENSION_COMPOSE__","compose","createStore","combineReducers","globalReducer","articlesReducer","newsAdminReducer","applyMiddleware","thunk","userInfo","tenantColors","upsertTenants","tenant","min","isValidGuid","str","findFormErrors","smallDescription","findApplicationErrors","geographicalInformation","targetProfile","mainAddedValue","secondaryAddedValue","deliverable","availableApplication","lifeCycles","valueChains","application","_item$link","_item$name","computeApplicationError","toServiceCreateDTO","_form$itContact$ppid","_form$itContact","_form$relatedServices","_form$serviceGroupId","_form$friendlyUrl","_form$visibleInClient","app","_app$itContact","itContactPpid","ret","Name","Description","Live","ResponsiblesPpids","TeamPpids","VideoLink","Applications","ItContactPpid","Organizations","organizations","Industries","RelatedServices","relatedServices","IsHighlighted","IsNew","IsPSA","isPSA","IsPSF","isPSF","SmallDescription","LifeCycles","ValueChains","MainAddedValue","SecondaryAddedValue","GeographicalInformation","AvailableApplication","Deliverable","TargetProfile","Illustrations","illustrationsToAdd","ServiceGroupId","serviceGroupId","ViewersPpids","viewers","UkViewersPpids","ukViewers","FrViewersPpids","frViewers","Domains","domains","Territories","FriendlyUrl","friendlyUrl","VisibleInClientView","visibleInClientView","processApplications","slice","toServiceUpdateDTO","_toServiceCreateDTO","IllustrationsToAdd","IllustrationsToRemove","illustrationsToRemove","extractor","baseUri","validator","trimed","extracted","splited","tokenizer","extractECLink","isValidECSSite","site","extractECSLink","isValidECSLink","toSubscriptionCreateDTO","hasECLink","hasECSLink","DEFAULT_SORT","AdminEngagementContext","EngagementsTableContextWrapper","apiFilters","filtersArray","rowFilters","trial","myServices","serviceName","companyName","entityName","memberName","my","toSubscriptionApiFilter","upsertSubscription","promise","deleteSubscription","addUserToSubscription","updateUserSubscription","removeUserFromSubscription","useSubscriptions","pollUpdateThreeWPermissions","Item","onPrevious","onNext","MultiSelectColumn","searchFilter","addTo","removeFrom","MultiSelect","selection","onSelectionChange","denied","onDeniedChange","errorMsg","availables","othersById","addToDenied","removeFromDenied","defaultForm","allTerritories","allTopics","deniedTopics","allDocumentTypes","deniedDocumentTypes","toPermissions","territoryIds","topicIds","deniedTopicIds","documentTypeIds","deniedDocumentTypeIds","ThreeWPermissionsModal","_ref6$engagement","_useSelector","oldPermissions","setOldPermissions","_useSubmitable","useSubmitable","handleValueChange","resetForm","submitting","formErrors","submit","handleSubmit","ADMIN_FETCHLIST","fetchList","ADMIN_FETCHLIST_SUCCESS","fetchListSuccess","ADMIN_ITEM_ADDED","itemAdded","ADMIN_ITEM_UPDATED","itemUpdated","ADMIN_ITEM_DELETED","itemDeleted","adminListReducer","listAdded","listUpdated","listDeleted","AdminCompanyContext","React","AdminCompanyContextHOC","adminReducer","fetchCompanyList","setCompanyList","addCompany","useCompanyReducer","CompanySelect","onValueChange","showSearchOnToggle","AdminEntityContext","AdminEntityContextHOC","fetchEntityList","setEntityList","addEntity","useEntityReducer","EntitySelect","companyIdRequired","setValues","newValues","useMultilineForm","onItemsChange","defaultItem","handleChange","newApp","newApplications","oldApp","_items","_items$name","LinkForm","onDelete","onUnfocus","DEFAULT_LINK","LinksForm","_useMultilineForm","toServiceItem","canAddSubscription","AdminServiceContext","AdminServiceContextHOC","reduxDispatch","fetchAdminCatalog","dtos","upsertService","upsertedService","_addedDTO$domains","addedDTO","_updatedDTO$domains","updatedDTO","pollCreateService","pollUpdateService","deleteService","pollRemoveService","patchDisplayed","pollUpdateDisplayStatus","patchIsNew","pollUpdateIsNew","patchIsHighlighted","pollUpdateIsHighlighted","useServiceReducer","ServiceSelect","DEFAULT_FORM","AddEngagementModal","onUpsertSubscription","isEditMode","findFormErrorsWrapper","_form$contacts","_form$users","selectedEntity","handleEcsModulesChange","handleEcModulesChange","_dto$users","toSubscriptionForm","selectedMainContacts","u","u2","navigationLayoutMode","newDate","TextArea","rows","COLUMNS","accessor","filterable","Filter","Cell","SubscriptionDetails","setNotifications","usersByPpid","userNotifications","notificationsByPpid","notification","_notification$types","frequencies","types","Table","defaultSorted","USERS_CONTEXTS","NO_USER_ROW","role","highestLevel","createSuccessBanner","original","String","toLowerCase","UserEngagementTable","onDeleteUser","onMainContactChanged","sortable","displayedData","showPagination","getTheadTrProps","EditList","onAddUser","onEditSubscription","onDeleteSubscription","onNewsAccessRight","onDisplayDetails","TABLE_COLUMNS","SubscriptionTable","expanded","setExpanded","manual","onExpandedChange","SubComponent","findErrors","AddUserToElementModal","Render","submitable","handleUserChange","handleCancel","modalContainerRef","subscriptionPpid","AddUserToEngagementModal","AddUserModal","DeleteEngagementModal","submitDeleteEngagement","DeleteModal","onConfirm","DeleteUserFromElementModal","userName","elementType","elementName","_ref$secondMessage","secondMessage","DeleteUserFromEngagementModal","AdminEngagements","_useContext","addUser","setAddUser","userToDelete","setUserToDelete","setSubscriptionDetails","engagementToDelete","setEngagementToDelete","threeWPermissionsEngagement","setThreeWPermissionsEngagement","_useState11","_useState12","showCreateEngagementModal","setShowCreateEngagementModal","_useState13","_useState14","editedEngagement","setEditedEngagement","FloatingActionButtonPortal","SubscriptionAdmin","EngagementsTable","useStickyHeader","scrollableElementRef","stickyElementRef","offset","onScrollEvent","transform","useMainTableStickyHeader","tableRef","scrollRef","theadRef","setTheadRef","AddEntityModal","_contact$ppid","DeleteSerciceModal","_defaultUser","AddMultipleUsersToEntityModal","_onClose","defaultUser","summaryStatus","setSummaryStatus","usersToAdd","_setUsersToAdd","userToAdd","_setUserToAdd","setSubmitting","setUserValue","newUser","getErrorMessage","_summaryStatus$index$","errorMessage","colSpan","arrow","newUsersToAdd","splice","removeUser","autoFocus","RadioGroup","Radio","promises","allSettled","results","failures","AddUserToEntityModal","UserSelectLegacy","DeleteUserFromEntityModal","EntityMenuList","onAddMultipleUsers","onEditEntity","onDeleteEntity","EntitiesTable","showCreateEntityModal","setShowCreateEntityModal","editedEntity","setEditedEntity","entityToDelete","setEntityToDelete","addMultipleUsers","setAddMultipleUsers","filterMethod","rowFilter","row","DeleteEntityModal","filtered","defaultFilterMethod","_subRows","UsersTable","EntityAdmin","isValidEmail","isInternalEmail","focusInputElement","element","_user$phone","_user$phone$number","_ref$visible","_ref$initialUser","onCreate","onUpdate","ownProfile","handleFormChange","fieldsAvailable","setFieldsAvailable","searchingUser","setSearchingUser","bannerContent","setBannerContent","emailRef","firstNameRef","oldPhoto","setOldPhoto","isInternalUser","searchUser","photoToDisplay","Banner","hidden","onKeyPress","charCode","DeleteUserModal","NotifyUserModal","_user$name","setCreationIdentity","setSendAmds","setSend3w","notifyUser","finish","canSubmit","Badge","RefreshUserModal","refreshing","setRefreshing","userToRefresh","setUserToRefresh","userToNotify","setUserToNotify","showCreateUserModal","setShowCreateUserModal","editedUser","setEditedUser","superUserUpdating","setSuperUserUpdating","context","_useData","setSuperUser","newSuperUserUpdating","_original","updatedUser","deletedUserPpid","newUsers","RefreshUsersModal","confirmRead","setConfirmRead","UserAdmin","openRefreshUsersModal","setOpenRefreshUsersModal","right","AddCompanyModal","CompaniesTable","showCreateCompanyModal","setShowCreateCompanyModal","editedCompany","setEditedCompany","_filters$rowFilters","PivotValue","LABELS","ContextToggle","onContextChange","_ref$superAdmin","superAdmin","tabKeys","userContext","MyServicesFilter","SubscriptionTrialFilterValues","TrialFilter","stringValue","filterValue","Filters","activeTab","downloadLoading","setDownloadLoading","filterColumns","needsContextToggle","ADMIN_TABS","USERS","serviceTab","SERVICES","usersTab","needsMyServices","ENGAGEMENTS","needsTrialFilter","ContextsSearchbar","ValidationTextarea","textareaProps","ApplicationForm","DEFAULT_APPLICATION","ApplicationsForm","onApplicationsChange","IllustrationList","currentIllustrations","illustrations","onFilesAddChange","onFilesDeleteChange","inputFile","filesToAdd","setFilesToAdd","filesToDelete","setFilesToDelete","contentType","isVideo","_inputFile$current","padding","prevFiles","newFiles","_file","ListItemText","from","LifeCycleSelect","_lifecyclesAllSorted$","_useLifeCyclesAll$dat","lifecyclesAll","lifecyclesAllSorted","sortBy","lifecycles","_values$filter","addedValue","valuesToCommit","lifecycle","OrganizationSelect","_response$items","organization","ServiceGroupSelect","_useServiceGroups$dat","serviceGroups","ServiceIndustryTagSelect","_industriesAll$props$","_useIndustriesAll$dat","industriesAll","_industry$subIndustri","subIndustries","flatMap","SelectGroupTitle","subIndustry","_industry$subIndustri2","serviceIdExclude","_useLiveService","select","_useLiveService$data","ValueChainSelect","_useValueChainsAll$da","valueChainsAll","valueChainsAllSorted","_valueChainsAllSorted","valuechain","_tenants$find","t","domain","usePrevious","AddServiceModal","_useQuery","queryFn","staleTime","enabled","_service$lifeCycles","_service$valueChains","_service$smallDescrip","_service$geographical","_service$targetProfil","_service$availableApp","_service$deliverable","_service$mainAddedVal","_service$secondaryAdd","_service$relatedServi","_service$relatedServi2","_service$illustration","_service$viewers","_service$domains","_service$territories$","_service$territories","_service$friendlyUrl","_service$visibleInCli","_service$ukViewers","_service$frViewers","toServiceForm","hasErrors","previousHasErrors","addonBefore","normalize","formatFriendlyUrl","FormGroup","tenantDomain","FormControlLabel","control","formDomain","handleDomainChange","mainFilter","secondaryFilter","tertiaryFilter","ServiceTableBadge","_tenant$name","Chip","emptyFilter","ServicesTable","onEditService","onDeleteService","cols","filterQuery","handleIsNewChange","handleIsHighlightedChange","displayed","handleDisplayedChange","_row$id","EMPTY_SERVICE","AdminServices","initializer","addingService","setAddingService","serviceToUpdate","setServiceToUpdate","serviceToDelete","setServiceToDelete","DeleteServiceModal","AddServiceGroupModal","onServiceGroupChanged","_useMutation","useMutation","pollAddServiceGroup","onSuccess","mutate","submittingAddService","_useMutation2","pollEditServiceGroup","submittingEditService","DeleteServiceGroupModal","onConfirmDelete","submitDeleteServiceGroup","ServiceGroupsTable","onEdit","AdminServiceGroups","showCreateServiceGroupModal","setShowCreateServiceGroupModal","serviceGroupToDelete","setServiceGroupToDelete","editedServiceGroupId","setEditedServiceGroupId","_useServiceGroups","isFetching","refreshServiceGroups","refetch","pollDeleteServiceGroup","deleteServiceGroupLoading","UsersTableColumns","COMPANIES","ENTITIES","EngagementsTableColumns","ServicesTableColumns","SERVICES_GROUPS","steps","STRUCTURING","SETUP","DISTRIBUTION","OPERATION","_Object$entries$find","_useParams","useParams","_initializer$service","setActiveTab","setFilters","replaceState","hash","hashId","hashTab","selectedId","Expanded","isExpanded","LoadingComponent","computeExpandedRows","expandedIndex","PWCTable","forwardRef","trProps","getTrProps","pivotBy","_ref$loading","tableProps","striped","NoDataComponent","_LoadingComponent","ExpanderComponent","getTheadProps","rowInfo","trClassName","subRows","rowIsExpanded","nestingPath","defaultValues","immutableDefaultValues","touched","setTouched","setErrors","autoValidate","setAutoValidate","listener","returnValue","resetAfterSuccess","first","second","_pollCreateService","addedService","_pollUpdateService","compare","_x44","_x45","pollUpdateIndustry","_pollUpdateIndustry","industryDetails","compareFilter","_x46","_x47","pollAddIndustry","_pollAddIndustry","addedIndustry","pollAddLifeCycle","_pollAddLifeCycle","addedLifeCycle","pollRemoveLifeCycle","_pollRemoveLifeCycle","pollUpdateLifeCycle","_pollUpdateLifeCycle","lifeCycleDetails","_x48","_x49","pollUpdateLifeCycleOrder","_pollUpdateLifeCycleOrder","_x50","_x51","pollAddValueChain","_pollAddValueChain","addedValueChain","pollRemoveValueChain","_pollRemoveValueChain","pollUpdateValueChain","_pollUpdateValueChain","valueChainDetails","_x52","_x53","pollUpdateValueChainOrder","_pollUpdateValueChainOrder","_x54","_x55","pollUpdateSubIndustry","_pollUpdateSubIndustry","_x56","_x57","pollAddSubIndustry","_pollAddSubIndustry","pollRemoveIndustry","_pollRemoveIndustry","pollRemoveSubIndustry","_pollRemoveSubIndustry","_pollRemoveService","_pollUpdateDisplayStatus","_pollUpdateIsNew","_callee26","_context26","_pollAddServiceGroup","_callee27","addedServiceGroup","_context27","_pollEditServiceGroup","_callee29","_context29","_callee28","serviceGroupDetails","_context28","compareServiceGroup","_x58","_x59","_pollDeleteServiceGroup","_callee30","_context30","pollAddTerritory","_pollAddTerritory","_callee31","_context31","pollEditTerritory","_pollEditTerritory","_callee33","_context33","_callee32","territoryDetails","_context32","_x60","_x61","pollDeleteTerritory","_pollDeleteTerritory","_callee34","_context34","_pollUpdateIsHighlighted","_callee35","_context35","modified","_service$applications","_service$applications2","_service$description","_service$responsibles","_service$responsibles2","_service$team$map$sor","_service$team","_service$itContact","_service$industries$s","_service$industries","_service$viewers$map$","_service$ukViewers$ma","_service$frViewers$ma","_modified$Application","_modified$Application2","_modified$Description","_modified$Description2","_modified$Live","_modified$Name","_modified$Responsible","_modified$Responsible2","_modified$TeamPpids$s","_modified$TeamPpids","_modified$VideoLink","_modified$IsNew","_modified$IsPSA","_modified$IsPSF","_modified$IsHighlight","_modified$SmallDescri","_modified$SmallDescri2","_modified$ValueChains","_modified$LifeCycles","_modified$RelatedServ","_modified$RelatedServ2","_modified$MainAddedVa","_modified$SecondaryAd","_modified$Geographica","_modified$TargetProfi","_modified$AvailableAp","_modified$Deliverable","_modified$Industries$","_modified$Industries","_modified$ViewersPpid","_modified$ViewersPpid2","_modified$UkViewersPp","_modified$UkViewersPp2","_modified$FrViewersPp","_modified$FrViewersPp2","viewer","serviceGroup1","serviceGroup2","_serviceGroup1$servic","_serviceGroup2$servic","pollUpdateHomepage","_x42","_pollUpdateHomepage","_callee37","_context37","_callee36","_context36","compareHomepage","_x62","_x63","pollUpdateHomepageFilterFields","_x43","_pollUpdateHomepageFilterFields","_callee39","_context39","_callee38","_context38","compareHomepageFilterFields","_x64","_x65","_homepage$contacts","_modified$contacts","value1Title","value1Description","value2Title","value2Description","computeBottom","position","FAB_PORTAL_DIV","_ref$kind","_ref$size","_ref$tooltipClassName","tooltipClassName","_ref$position","_ref$right","FAB","FloatingActionButton","refStyle","OID_CONFIGURATION","redirect_uri","response_type","post_logout_redirect_uri","scope","silent_redirect_uri","automaticSilentRenew","loadUserInfo","acr_values"],"mappings":"2gBAAA,qCA2DeA,IAvDC,SAAHC,GAMN,IAADC,EAAAD,EALJE,kBAAU,IAAAD,OAAGE,EAASF,EAAAG,EAAAJ,EACtBK,oBAAY,IAAAD,OAAGD,EAASC,EAAAE,EAAAN,EACxBO,0BAAkB,IAAAD,OAAGH,EAASG,EAAAE,EAAAR,EAC9BS,qBAAa,IAAAD,OAAGL,EAASK,EAAAE,EAAAV,EACzBW,oBAAY,IAAAD,OAAGP,EAASO,EAExB,OACEE,eAAA,OAAKC,UAAU,gBAAeC,SAAA,CAC3BH,GACCI,cAACC,IAAO,CAACC,MAAM,SAASC,UAAU,MAAMC,WAAY,IAAIL,SACtDC,cAACK,IAAU,CAACC,KAAK,cAAcC,QAASX,EAAaG,SACnDC,cAAA,QAAMF,UAAU,mCAIrBJ,GACCM,cAACC,IAAO,CAACC,MAAM,UAAUC,UAAU,MAAMC,WAAY,IAAIL,SACvDC,cAACK,IAAU,CAACC,KAAK,cAAcC,QAASb,EAAcK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,cAAC6xE,QAAK,CAAC/pE,KAAM,UAAU/H,SAAC,YACxBC,cAAA,QAAMF,UAAU,QAAOC,SAAEG,OAE3BF,cAACqmB,YAAS,CAAAtmB,SAAEA,IACZF,eAAC2mB,cAAW,CAAAzmB,SAAA,CACVC,cAACuC,SAAM,CAACjC,KAAK,cAAciI,SAAUo3D,EAAYp/D,QAASulB,EAAQ/lB,SAAC,WAGnEC,cAACuC,SAAM,CAACk8C,UAAWkhB,EAAYp/D,QAASwlB,EAAchmB,SACnDmR,UAKX,C,mNCpDM49E,EAAiBhpF,YAAA,CACrBi4B,UAAW,MACXgxD,aAAa,GAAD7rF,OAAKE,OAAOgG,SAAS8hC,QAAMhoC,OAAG1C,4BAC1CwuF,cAAe,iBACfC,yBAAyB,GAAD/rF,OAAKE,OAAOgG,SAAS8hC,QAAMhoC,OAAG1C,kBACtD0uF,MAAO,wBACPpxD,UAAWt9B,8CACX2uF,oBAAoB,GAADjsF,OAAKE,OAAOgG,SAAS8hC,QAAMhoC,OAAG1C,mCACjD4uF,sBAAsB,EACtBC,cAAc,GACiD,CAC7DC,WAAY,eAIHlpF,EAAgB,aAAAlD,OAAgB4rF,EAAkBhxD,UAAS,KAAA56B,OAAI4rF,EAAkB/wD,WAE/E+wD,K","file":"static/js/main.8e23aa02.chunk.js","sourcesContent":["import \"./actions.scss\";\r\n\r\nimport { IconButton, Tooltip } from \"@mui/material\";\r\n\r\nconst Actions = ({\r\n handleEdit = undefined,\r\n handleDelete = undefined,\r\n handleEditPwcPanel = undefined,\r\n handleRefresh = undefined,\r\n handleNotify = undefined,\r\n}) => {\r\n return (\r\n
\r\n {handleNotify && (\r\n \r\n \r\n \r\n \r\n \r\n )}\r\n {handleRefresh && (\r\n \r\n \r\n \r\n \r\n \r\n )}\r\n {handleEdit && (\r\n \r\n \r\n \r\n \r\n \r\n )}\r\n\r\n {handleEditPwcPanel &&\r\n process.env.REACT_APP_NEWS_ENABLE_CLIENT_PANEL === \"true\" && (\r\n \r\n \r\n \r\n \r\n \r\n )}\r\n\r\n {handleDelete && (\r\n \r\n \r\n \r\n \r\n \r\n )}\r\n
\r\n );\r\n};\r\n\r\nexport default Actions;\r\n","export const toDateRangeFilter = (range) => {\r\n if (!range) {\r\n return null;\r\n }\r\n return toDateFilter(\r\n range.start ? new Date(range.start) : null,\r\n range.end ? new Date(range.end) : null\r\n );\r\n};\r\n\r\nexport const toDateFilter = (dateFrom, dateTo) => {\r\n const start = dateFrom\r\n ? new Date(\r\n Date.UTC(\r\n dateFrom.getFullYear(),\r\n dateFrom.getMonth(),\r\n dateFrom.getDate(),\r\n 0,\r\n 0,\r\n 0,\r\n 0\r\n )\r\n ).toISOString()\r\n : undefined;\r\n\r\n const end = dateTo\r\n ? new Date(\r\n Date.UTC(\r\n dateTo.getFullYear(),\r\n dateTo.getMonth(),\r\n dateTo.getDate() + 1,\r\n 0,\r\n 0,\r\n -1\r\n )\r\n ).toISOString()\r\n : undefined;\r\n\r\n return {\r\n start,\r\n end,\r\n };\r\n};\r\n\r\nexport const toTextFilter = (text) =>\r\n text?.trim().length > 0 ? text.trim() : null;\r\n\r\nexport const toSafeNumberFilter = (number) => (!isNaN(number) ? number : null);\r\n","import \"./index.scss\";\r\n\r\nimport { Button } from \"appkit-react\";\r\nimport ReactDOM from \"react-dom\";\r\n\r\nconst FullPageLoader = (props) => {\r\n const {\r\n message = \"Processing, please stand by...\",\r\n onCancel = null,\r\n onCancelLabel = \"Cancel\",\r\n } = props;\r\n\r\n return ReactDOM.createPortal(\r\n
\r\n
\r\n
\r\n
{message}
\r\n {onCancel ? (\r\n \r\n ) : null}\r\n
\r\n
,\r\n document.getElementById(\"portal\")\r\n );\r\n};\r\n\r\nexport default FullPageLoader;\r\n","function appendValue(formData: FormData, key: string, value: any) {\r\n formData.append(\r\n key,\r\n value instanceof Blob\r\n ? value\r\n : typeof value === \"object\" && value !== null\r\n ? JSON.stringify(value)\r\n : `${value}`\r\n );\r\n}\r\n\r\nexport function toFormData(object: any) {\r\n const formData = new FormData();\r\n for (const [key, value] of Object.entries(object)) {\r\n if (Array.isArray(value)) {\r\n for (const arrayValue of value) {\r\n if (arrayValue) {\r\n appendValue(formData, key, arrayValue);\r\n }\r\n }\r\n } else if (value) {\r\n appendValue(formData, key, value);\r\n }\r\n }\r\n return formData;\r\n}\r\n","const isIE = !!window.document.documentMode;\r\n\r\nexport default isIE;\r\n","import asFormData from \"json-form-data\";\r\nimport { toFormData } from \"utils/toFormData\";\r\n\r\nimport isIE from \"../utils/isIE\";\r\nimport { DEFAULT_OIDC_KEY } from \"./auth/config\";\r\n\r\nexport const RET_JSON = \"RET_JSON\";\r\nexport const RET_RAW = \"RET_RAW\";\r\nexport const RET_TEXT = \"RET_TEXT\";\r\n\r\nexport const CONTENT_TYPE_JSON = {\r\n \"Content-Type\": \"application/json\",\r\n};\r\nexport const CONTENT_TYPE_TEXT = {\r\n \"Content-Type\": \"text/plain\",\r\n};\r\n\r\nexport function apiFetch(\r\n url: string,\r\n body: any = undefined,\r\n method = \"GET\",\r\n returnType = RET_JSON,\r\n headers: any = CONTENT_TYPE_JSON\r\n): Promise {\r\n if (typeof body === \"object\") {\r\n body = JSON.stringify(body);\r\n }\r\n return _apiFetch(url, body, method, returnType, headers);\r\n}\r\n\r\nexport const apiFetchFormData = (\r\n url: string,\r\n body = {},\r\n method = \"GET\",\r\n returnType = RET_JSON,\r\n headers = {}\r\n) => {\r\n return _apiFetch(\r\n url,\r\n asFormData(body, {\r\n showLeafArrayIndexes: false,\r\n\r\n // @ts-ignore\r\n mapping: function (value) {\r\n return value;\r\n },\r\n }),\r\n method,\r\n returnType,\r\n headers\r\n );\r\n};\r\n\r\nexport const apiFetchFormDataCustom = (\r\n url: string,\r\n body = {},\r\n method = \"GET\",\r\n returnType = RET_JSON,\r\n headers = {}\r\n) => {\r\n return _apiFetch(url, toFormData(body), method, returnType, headers);\r\n};\r\n\r\nexport const appendIEHeaders = (headers = {}) => {\r\n if (isIE) {\r\n return {\r\n ...headers,\r\n Pragma: \"no-cache\",\r\n \"Cache-Control\": \"no-cache\",\r\n };\r\n }\r\n return headers;\r\n};\r\n\r\nexport const appendTokenHeaders = (headers = {}) => {\r\n // grab current state\r\n let authToken = null;\r\n try {\r\n const token = sessionStorage.getItem(DEFAULT_OIDC_KEY);\r\n if (token === null) {\r\n return headers;\r\n }\r\n\r\n const oidcJson = JSON.parse(sessionStorage.getItem(DEFAULT_OIDC_KEY) || \"\");\r\n authToken = oidcJson.access_token;\r\n } catch (error) {\r\n console.error(\"Error accessing JWT!\", error);\r\n }\r\n\r\n return {\r\n ...headers,\r\n Authorization: `Bearer ${authToken}`,\r\n };\r\n};\r\n\r\nconst appendAcceptHeader = (headers: any = {}, returnType: any) => {\r\n switch (returnType) {\r\n case RET_TEXT:\r\n headers.Accept = \"text/plain\";\r\n break;\r\n case RET_RAW:\r\n headers.Accept = \"application/octet-stream\";\r\n break;\r\n case RET_JSON:\r\n default:\r\n headers.Accept = \"application/json\";\r\n break;\r\n }\r\n return headers;\r\n};\r\n\r\nconst _apiFetch = (\r\n url: string,\r\n body: any,\r\n method = \"GET\",\r\n returnType: any,\r\n headers = {}\r\n) => {\r\n headers = appendAcceptHeader(headers, returnType);\r\n headers = appendTokenHeaders(headers);\r\n headers = appendIEHeaders(headers);\r\n\r\n return fetch(url, { method: method, headers: headers, body: body }).then(\r\n (data) => {\r\n if (!data.ok) {\r\n throw data;\r\n } else if (data.status === 204 && returnType !== RET_RAW) {\r\n // No-Content\r\n return null;\r\n } else {\r\n switch (returnType) {\r\n case RET_JSON:\r\n return data.json();\r\n case RET_TEXT:\r\n return data.text();\r\n case RET_RAW:\r\n return data;\r\n default:\r\n throw new Error(\r\n `Unrecognized \"returnType\" supplied (${returnType})`\r\n );\r\n }\r\n }\r\n }\r\n );\r\n};\r\n","export const dataURItoBlob = (dataURI, dataTYPE) => {\r\n const binary = atob(dataURI.split(\",\")[1]);\r\n const array = [];\r\n\r\n for (var i = 0; i < binary.length; i++) {\r\n array.push(binary.charCodeAt(i));\r\n }\r\n\r\n const res = new Blob([new Uint8Array(array)], {\r\n type: dataTYPE,\r\n });\r\n\r\n return res;\r\n};\r\n\r\nexport function toUTCISODateString(date) {\r\n return new Date(\r\n Date.UTC(date.getFullYear(), date.getMonth(), date.getDate(), 0, 0, 0)\r\n ).toISOString();\r\n}\r\n","import {\r\n MatomoProvider,\r\n createInstance,\r\n useMatomo,\r\n} from \"@datapunt/matomo-tracker-react\";\r\nimport { useEffect } from \"react\";\r\nimport { useSelector } from \"react-redux\";\r\nimport { useLocation } from \"react-router-dom\";\r\n\r\nconst instance = createInstance({\r\n urlBase: process.env.REACT_APP_MATOMO_URLBASE!,\r\n siteId: Number.parseInt(process.env.REACT_APP_MATOMO_SITEID!),\r\n disabled: process.env.REACT_APP_MATOMO_ENABLED !== \"true\",\r\n linkTracking: false,\r\n});\r\nconst MatomoHOC: React.FC<{}> = ({ children }) => {\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nconst MatomoTracker: React.FC<{}> = ({ children }) => {\r\n const { enableLinkTracking, trackPageView, pushInstruction } = useMatomo();\r\n const loginUser = useSelector(\r\n (state) => (state as any).global.data.loginUser\r\n );\r\n const location = useLocation();\r\n enableLinkTracking();\r\n\r\n useEffect(() => {\r\n if (loginUser !== null) {\r\n pushInstruction(\"setUserId\", loginUser.ppid);\r\n pushInstruction(\r\n \"setCustomVariable\",\r\n 4,\r\n \"Is Internal User\",\r\n loginUser.isInternal\r\n );\r\n trackPageView({ href: location.pathname });\r\n }\r\n }, [location, trackPageView, loginUser, pushInstruction]);\r\n\r\n return <>{children};\r\n};\r\n\r\nexport default MatomoHOC;\r\n","import {\r\n StyledEngineProvider,\r\n ThemeProvider,\r\n createTheme,\r\n} from \"@mui/material/styles\";\r\n\r\nconst theme = createTheme({\r\n typography: {\r\n fontFamily: [\r\n '\"PwC Helvetica Neue\"',\r\n '\"Helvetica Neue\"',\r\n '\"sans-serif\"',\r\n ].join(\",\"),\r\n },\r\n palette: {\r\n primary: {\r\n main: \"#D04A02\",\r\n },\r\n secondary: {\r\n main: \"#EB8C00\",\r\n },\r\n },\r\n components: {\r\n MuiIconButton: {\r\n styleOverrides: {\r\n sizeSmall: {\r\n fontSize: \"1rem\",\r\n },\r\n },\r\n },\r\n MuiTable: {\r\n styleOverrides: {\r\n root: {\r\n backgroundColor: \"#ffffff\",\r\n },\r\n },\r\n },\r\n MuiTableCell: {\r\n styleOverrides: {\r\n root: {\r\n paddingTop: \"0.5rem\",\r\n paddingBottom: \"0.5rem\",\r\n },\r\n },\r\n },\r\n MuiAvatar: {\r\n styleOverrides: {\r\n root: {\r\n height: \"2.25rem\",\r\n width: \"2.25rem\",\r\n fontSize: \"0.875rem\",\r\n },\r\n },\r\n },\r\n MuiBreadcrumbs: {\r\n styleOverrides: {\r\n root: { marginBottom: \"1rem\" },\r\n },\r\n },\r\n MuiListItemText: {\r\n styleOverrides: {\r\n primary: {\r\n fontSize: \"1rem\",\r\n marginRight: \"1rem\",\r\n },\r\n },\r\n },\r\n MuiButton: {\r\n styleOverrides: {\r\n root: {\r\n borderRadius: \"0\",\r\n boxShadow: \"none\",\r\n fontWeight: 600,\r\n },\r\n },\r\n },\r\n MuiDialogTitle: {\r\n styleOverrides: {\r\n root: {\r\n color: \"#D04A02\",\r\n fontFamily: ['\"PwC ITC Charter\"', '\"ITC Charter\"', \"serif\"].join(\",\"),\r\n fontSize: \"1.4rem\",\r\n },\r\n },\r\n },\r\n MuiInputAdornment: {\r\n styleOverrides: {\r\n root: {\r\n positionStart: {\r\n marginRight: \"0\",\r\n marginLeft: \"0.8rem\",\r\n },\r\n },\r\n },\r\n },\r\n },\r\n});\r\n\r\nconst MuiTheme: React.FC<{}> = ({ children }) => {\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport default MuiTheme;\r\n","import { QueryClient, QueryClientProvider } from \"react-query\";\r\n\r\n// React Query Client\r\nconst queryClient = new QueryClient({\r\n defaultOptions: {\r\n queries: {\r\n retry: false,\r\n refetchOnWindowFocus: false,\r\n onError: (err) => {\r\n Promise.reject(err);\r\n },\r\n },\r\n },\r\n});\r\n\r\nconst ReactQueryProvider: React.FC<{}> = ({ children }) => {\r\n return (\r\n {children}\r\n );\r\n};\r\n\r\nexport default ReactQueryProvider;\r\n","import { DEFAULT_OIDC_KEY } from \"api/auth/config\";\r\nimport { Button } from \"appkit-react\";\r\n\r\nfunction RefreshSessionButton() {\r\n return (\r\n {\r\n sessionStorage.removeItem(DEFAULT_OIDC_KEY);\r\n window.location.reload();\r\n }}\r\n >\r\n Refresh session\r\n \r\n );\r\n}\r\n\r\nexport default RefreshSessionButton;\r\n","import ControlledError from \"pages/error/ControlledError\";\r\nimport UnexpectedError from \"pages/error/UnexpectedError\";\r\nimport { Component } from \"react\";\r\nimport { connect } from \"react-redux\";\r\nimport { withRouter } from \"react-router\";\r\nimport { GLOBAL_ERRORS } from \"redux/constants\";\r\n\r\nimport RefreshSessionButton from \"./refreshSessionButton\";\r\n\r\nclass ErrorBoundary extends Component {\r\n constructor(props) {\r\n super(props);\r\n\r\n this.state = {\r\n error: null,\r\n loading: false,\r\n };\r\n }\r\n\r\n componentDidUpdate(prevProps) {\r\n const error =\r\n this.state.error ||\r\n (this.props.hasError && this.props.hasError !== GLOBAL_ERRORS.NO_ERROR);\r\n if (error && prevProps.location.pathname !== this.props.location.pathname) {\r\n window.location.replace(this.props.location.pathname);\r\n }\r\n }\r\n\r\n static getDerivedStateFromError(error) {\r\n // Update state so the next render will show the fallback UI.\r\n return { error: error };\r\n }\r\n\r\n render() {\r\n if (\r\n this.props.hasError !== undefined &&\r\n this.props.hasError !== GLOBAL_ERRORS.NO_ERROR\r\n ) {\r\n switch (this.props.hasError) {\r\n case GLOBAL_ERRORS.NO_COMPANY:\r\n return (\r\n \r\n );\r\n case GLOBAL_ERRORS.NO_USER:\r\n return (\r\n \r\n );\r\n case GLOBAL_ERRORS.SESSION_EXPIRED:\r\n return (\r\n }\r\n />\r\n );\r\n case GLOBAL_ERRORS.NO_TENANT:\r\n return (\r\n \r\n );\r\n case GLOBAL_ERRORS.UNKNOWN:\r\n default:\r\n return ;\r\n }\r\n }\r\n const error = this.state.error || this.props.hasError;\r\n if (error) {\r\n // You can render any custom fallback UI\r\n return ;\r\n }\r\n\r\n return this.props.children;\r\n }\r\n}\r\n\r\nconst mapStateToProps = (state) => {\r\n return {\r\n hasError: state.global.hasError,\r\n };\r\n};\r\n\r\nexport default withRouter(connect(mapStateToProps)(ErrorBoundary));\r\n","import { PopBanner } from \"appkit-react\";\r\nimport { Component } from \"react\";\r\n\r\nimport HandledPromiseRejectionError from \"../../exceptions/handledPromiseRejectionError\";\r\n\r\nconst DEFAULT_MESSAGE =\r\n \"Something went wrong. Please try again later. If the problem persists, please contact the support team.\";\r\nconst FORBIDDEN_MESSAGE =\r\n \"It seems like you haven't the right permission for this action.\";\r\nconst NOTFOUND_MESSAGE =\r\n \"You're looking for something that doesn't exist, or have been removed.\";\r\nconst UNKNOWN_ERROR_MESSAGE =\r\n \"No response received from the server. Please try again later. If the problem persists, please contact the support team.\";\r\n\r\nconst parseErrors = (errors) => {\r\n return (\r\n
\r\n

An error occured while processing your request :

\r\n
    \r\n {errors.map((error) => (\r\n
  • {error.message}
  • \r\n ))}\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default class HTTPErrorBoundary extends Component {\r\n componentDidMount() {\r\n window.onunhandledrejection = (data) => {\r\n const error = data.reason;\r\n\r\n if (error instanceof Response && error.status === 400) {\r\n try {\r\n const promise = error.error\r\n ? Promise.resolve(error.error)\r\n : error.json();\r\n\r\n promise.then((errorMessages) => {\r\n PopBanner({\r\n content: parseErrors(errorMessages),\r\n closeable: true,\r\n className: \"a-banner-error\",\r\n });\r\n });\r\n } catch {\r\n PopBanner({\r\n content: {DEFAULT_MESSAGE},\r\n closeable: true,\r\n status: \"negative\",\r\n });\r\n }\r\n } else {\r\n let message;\r\n if (error instanceof Response) {\r\n switch (error.status) {\r\n case 401:\r\n case 403:\r\n message = FORBIDDEN_MESSAGE;\r\n break;\r\n case 404:\r\n message = NOTFOUND_MESSAGE;\r\n break;\r\n case 500:\r\n default:\r\n message = DEFAULT_MESSAGE;\r\n }\r\n } else if (error instanceof HandledPromiseRejectionError) {\r\n message = error.message;\r\n } else {\r\n message = UNKNOWN_ERROR_MESSAGE;\r\n }\r\n\r\n PopBanner({\r\n content: {message},\r\n closeable: true,\r\n status: \"negative\",\r\n });\r\n }\r\n };\r\n }\r\n\r\n render() {\r\n return this.props.children;\r\n }\r\n}\r\n","import \"react-app-polyfill/ie11\";\r\nimport \"react-app-polyfill/stable\";\r\nimport \"core-js/es/array/from\";\r\nimport \"core-js/es/array/find\";\r\nimport \"core-js/es/array/includes\";\r\nimport \"core-js/es/array/find-index\";\r\nimport \"core-js/es/array/map\";\r\nimport \"core-js/es/object/assign\";\r\nimport \"core-js/es/promise\";\r\nimport \"core-js/es/map\";\r\nimport \"core-js/es/string/repeat\";\r\nimport \"core-js/es/string/pad-start\";\r\nimport \"core-js/es/string/pad-end\";\r\nimport \"core-js/es/string/starts-with\";\r\nimport \"whatwg-fetch\";\r\nimport \"blueimp-canvas-to-blob\";\r\nimport \"pwc-cookie/dist/pwc-cookie.css\";\r\nimport \"appkit-react/style/main\";\r\n\r\nimport \"./index.scss\";\r\nimport \"./dark-theme.scss\";\r\n\r\nimport {\r\n AuthenticationProvider,\r\n authenticateUser,\r\n getUserManager,\r\n oidcLog,\r\n} from \"@axa-fr/react-oidc-context\";\r\nimport MatomoHOC from \"components/MatomoHOC\";\r\nimport PageTitle from \"components/PageTitle\";\r\nimport MuiTheme from \"MuiTheme\";\r\nimport * as PwcCookie from \"pwc-cookie\";\r\nimport ReactDOM from \"react-dom\";\r\nimport { Provider } from \"react-redux\";\r\nimport { BrowserRouter } from \"react-router-dom\";\r\nimport ReactQueryProvider from \"ReactQueryProvider\";\r\n\r\nimport oidcConfig from \"./api/auth/config\";\r\n// Please preserve the order of this import, changing this may cause style problems\r\nimport App from \"./App\";\r\nimport ErrorBoundary from \"./components/ErrorBoundary\";\r\nimport HTTPErrorBoundary from \"./components/ErrorBoundary/httpErrorBoundary\";\r\nimport OIDCMessage from \"./components/OIDCMessage\";\r\nimport store from \"./redux/store/store\";\r\n\r\n//import * as serviceWorker from './serviceWorker';\r\n\r\nReactDOM.render(\r\n \r\n \r\n (\r\n \r\n )}\r\n sessionLostComponent={() => (\r\n \r\n authenticateUser(getUserManager(), window.location)\r\n }\r\n />\r\n )}\r\n callbackComponentOverride={() => {\r\n const oldOnPopState = window.onpopstate;\r\n window.onpopstate = () => {\r\n if (window.location.pathname === \"/authentication/session-lost\") {\r\n window.location.replace(\r\n window.location.search.substr(\r\n window.location.search.indexOf(\"=\") + 1\r\n )\r\n );\r\n } else if (\r\n window.location.pathname.indexOf(\"/authentication/\") === 0\r\n ) {\r\n window.location.replace(\"/\");\r\n }\r\n window.onpopstate = oldOnPopState;\r\n };\r\n return (\r\n \r\n );\r\n }}\r\n notAuthenticated={() => (\r\n \r\n )}\r\n notAuthorized={() => (\r\n \r\n )}\r\n >\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n ,\r\n document.getElementById(\"root\")\r\n);\r\n\r\nwindow.cookieHandler = new PwcCookie.build();\r\nwindow.cookieHandler.run();\r\n\r\n// If you want your app to work offline and load faster, you can change\r\n// unregister() to register() below. Note this comes with some pitfalls.\r\n// Learn more about service workers: https://bit.ly/CRA-PWA\r\n//serviceWorker.unregister();\r\n","const delays = [100, 150, 200, 300, 400, 500, 600, 750];\r\nconst delayTotal = Math.floor(\r\n delays.reduce((acc, delay) => acc + delay, 0) / 1000\r\n);\r\n\r\nexport const getDelay = (attemptNumber) => {\r\n return delays[attemptNumber - 1];\r\n};\r\n\r\nexport const pollData = (\r\n pollingPromise,\r\n checkShouldPoll,\r\n attemptNumber = 0,\r\n timeoutResult\r\n) => {\r\n return new Promise((resolve, reject) => {\r\n pollingPromise()\r\n .then(resolve)\r\n .catch((error) => {\r\n if (checkShouldPoll(error)) {\r\n attemptNumber++;\r\n if (attemptNumber > delays.length) {\r\n process.env.REACT_APP_BUILD_ENV !== \"prod\" &&\r\n console.warn(\r\n `API Poller Timeout after ${delayTotal} seconds. Resolving with timeoutResult`,\r\n timeoutResult\r\n );\r\n return resolve(timeoutResult); // resolve promise with default data if timeout has been reached\r\n }\r\n setTimeout(() => {\r\n pollData(\r\n pollingPromise,\r\n checkShouldPoll,\r\n attemptNumber,\r\n timeoutResult\r\n ).then(resolve);\r\n }, getDelay(attemptNumber));\r\n } else {\r\n reject(error);\r\n }\r\n });\r\n });\r\n};\r\n\r\nexport const pollerCheck404 = (error) => error.status === 404;\r\nexport const pollerCheck204 = (error) => error.status === 204;\r\nexport const pollerCheck4XX = (error) => Math.floor(error.status / 100) === 4;\r\nexport const pollerCheck2XX = (error) => Math.floor(error.status / 100) === 2;\r\nexport const pollerCheckUndefined = (error) => error === undefined;\r\n","import {\r\n ApplicationReadDTO,\r\n ContactReadDTO,\r\n SubscriptionDetailsReadDTO,\r\n SubscriptionReadDTO,\r\n} from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { CatalogueService } from \"pages/catalogue/types\";\r\n\r\nexport interface ECSModules {\r\n documents: boolean;\r\n tasks: boolean;\r\n links: boolean;\r\n}\r\n\r\nexport interface ECModules {\r\n deliverables: boolean;\r\n documents: boolean;\r\n}\r\n\r\nexport interface SubscriptionDetails {\r\n ec: string | null;\r\n ecs: string | null;\r\n clientContent: string | null;\r\n ecModules: ECModules | null;\r\n ecsModules: ECSModules | null;\r\n links: ApplicationReadDTO[];\r\n contacts: ContactReadDTO[];\r\n service?: CatalogueService;\r\n clientContacts: ContactReadDTO[];\r\n}\r\n\r\nexport function toECModules(dto: Record = {}): ECModules {\r\n if (dto === null) {\r\n return toECModules();\r\n }\r\n return {\r\n deliverables: !!dto.deliverables,\r\n documents: !!dto.documents,\r\n };\r\n}\r\n\r\nexport function toECSModules(dto: Record = {}): ECSModules {\r\n if (dto === null) {\r\n return toECSModules();\r\n }\r\n\r\n return {\r\n documents: !!dto.documents,\r\n links: !!dto.links,\r\n tasks: !!dto.tasks,\r\n };\r\n}\r\n\r\nexport function toSubscriptionDetails(\r\n dto: SubscriptionDetailsReadDTO | SubscriptionReadDTO\r\n): SubscriptionDetails {\r\n return {\r\n clientContent: dto.clientContent || null,\r\n ec: dto.ec,\r\n ecModules: toECModules(dto.ecModules),\r\n ecs: dto.ecs,\r\n ecsModules: toECSModules(dto.ecsModules),\r\n links: dto.applications || [],\r\n contacts: dto.contacts ?? [],\r\n clientContacts: [],\r\n };\r\n}\r\n","/* eslint-disable */\r\n/* tslint:disable */\r\n/*\r\n * ---------------------------------------------------------------\r\n * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##\r\n * ## ##\r\n * ## AUTHOR: acacode ##\r\n * ## SOURCE: https://github.com/acacode/swagger-typescript-api ##\r\n * ---------------------------------------------------------------\r\n */\r\n\r\nexport interface CompanyReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n}\r\n\r\nexport interface CompanyCreateDTO {\r\n name: string | null;\r\n}\r\n\r\nexport interface CompanyUpdateDTO {\r\n name: string | null;\r\n}\r\n\r\nexport interface AssignedUserReadDTO {\r\n ppid: string | null;\r\n name: string | null;\r\n email: string | null;\r\n isMainContact: boolean;\r\n}\r\n\r\nexport interface ContactReadDTO {\r\n ppid: string | null;\r\n name: string | null;\r\n email: string | null;\r\n\r\n /** @format int32 */\r\n phoneCountryCode: number | null;\r\n phoneNumber: string | null;\r\n photoUri: string | null;\r\n}\r\n\r\nexport interface EntityDetailsReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n\r\n /** @format uuid */\r\n companyId: string;\r\n companyName: string | null;\r\n prid: string | null;\r\n viewInMyServices: boolean;\r\n users: AssignedUserReadDTO[] | null;\r\n contacts: ContactReadDTO[] | null;\r\n}\r\n\r\nexport interface EntityCreateDTO {\r\n /** @format uuid */\r\n companyId: string;\r\n name: string | null;\r\n prid: string | null;\r\n viewInMyServices: boolean;\r\n contacts: string[] | null;\r\n}\r\n\r\nexport interface EntityUpdateDTO {\r\n name: string | null;\r\n prid: string | null;\r\n viewInMyServices: boolean;\r\n contacts: string[] | null;\r\n}\r\n\r\nexport interface EntityContactsReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n contacts: ContactReadDTO[] | null;\r\n}\r\n\r\nexport interface EntityUserAddDTO {\r\n ppid: string | null;\r\n}\r\n\r\nexport interface EntityUserRemoveDTO {\r\n ppid: string | null;\r\n}\r\n\r\nexport interface EntityReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n\r\n /** @format uuid */\r\n companyId: string;\r\n companyName: string | null;\r\n prid: string | null;\r\n viewInMyServices: boolean;\r\n}\r\n\r\nexport interface OrganizationFilters {\r\n name: string | null;\r\n}\r\n\r\nexport interface OrderBy {\r\n isDescending: boolean | null;\r\n}\r\n\r\nexport interface OrganizationOrderBy {\r\n name: OrderBy | null;\r\n}\r\n\r\nexport interface OrganizationQueryDTO {\r\n filters: OrganizationFilters | null;\r\n orderBy: OrganizationOrderBy | null;\r\n}\r\n\r\nexport interface OrganizationReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n}\r\n\r\nexport interface OrganizationReadDTOPagedCollection {\r\n /** @format int32 */\r\n currentPage: number;\r\n\r\n /** @format int32 */\r\n totalPages: number;\r\n\r\n /** @format int32 */\r\n pageSize: number;\r\n\r\n /** @format int32 */\r\n totalCount: number;\r\n hasPrevious: boolean;\r\n hasNext: boolean;\r\n items: OrganizationReadDTO[] | null;\r\n}\r\n\r\nexport interface OrganizationFullReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n team: string[] | null;\r\n}\r\n\r\nexport interface ServiceReadForAdminDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n live: boolean;\r\n isNew: boolean;\r\n isHighlighted: boolean;\r\n canAddSubscription: boolean;\r\n domains: string[];\r\n}\r\n\r\nexport interface MyServicePwCReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n}\r\n\r\nexport interface ApplicationReadDTO {\r\n name: string | null;\r\n link: string | null;\r\n showToClient: boolean;\r\n}\r\n\r\nexport interface SubscriptionDetailsReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n\r\n /** @format uuid */\r\n companyId: string;\r\n companyName: string | null;\r\n\r\n /** @format uuid */\r\n entityId: string;\r\n entityName: string | null;\r\n\r\n /** @format uuid */\r\n serviceId: string;\r\n serviceName: string | null;\r\n trial: boolean;\r\n\r\n /** @format date-time */\r\n endDate: string | null;\r\n ec: string | null;\r\n ecModules: Record;\r\n ecs: string | null;\r\n ecsModules: Record;\r\n clientContent: string | null;\r\n applications: ApplicationReadDTO[] | null;\r\n users: AssignedUserReadDTO[] | null;\r\n contacts: ContactReadDTO[] | null;\r\n\r\n /** @format int32 */\r\n userCount: number;\r\n}\r\n\r\nexport interface ApplicationCreateDTO {\r\n name: string | null;\r\n link: string | null;\r\n showToClient: boolean;\r\n}\r\n\r\nexport interface SubscriptionUpdateDTO {\r\n /** @format date-time */\r\n endDate: string | null;\r\n ec: string | null;\r\n ecModules: Record;\r\n ecs: string | null;\r\n ecsModules: Record;\r\n clientContent: string | null;\r\n applications: ApplicationCreateDTO[] | null;\r\n contacts: string[] | null;\r\n}\r\n\r\nexport interface MyServiceClientReadDTO {\r\n /** @format uuid */\r\n serviceId: string;\r\n serviceName: string | null;\r\n ec: string | null;\r\n ecModules: Record;\r\n ecs: string | null;\r\n ecsModules: Record;\r\n clientContent: string | null;\r\n applications: ApplicationReadDTO[] | null;\r\n contacts: ContactReadDTO[] | null;\r\n clientContacts: ContactReadDTO[] | null;\r\n}\r\n\r\nexport interface MyClientReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n}\r\n\r\nexport interface MyClientServiceReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n\r\n /** @format uuid */\r\n serviceId: string;\r\n serviceName: string | null;\r\n myService: boolean;\r\n trial: boolean;\r\n\r\n /** @format date-time */\r\n endDate: string | null;\r\n clientContacts: ContactReadDTO[] | null;\r\n}\r\n\r\nexport interface MyClientServicesReadDTO {\r\n /** @format uuid */\r\n entityId: string;\r\n entityName: string | null;\r\n subscriptions: MyClientServiceReadDTO[] | null;\r\n}\r\n\r\nexport interface SubscriptionReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n\r\n /** @format uuid */\r\n companyId: string;\r\n companyName: string | null;\r\n\r\n /** @format uuid */\r\n entityId: string;\r\n entityName: string | null;\r\n\r\n /** @format uuid */\r\n serviceId: string;\r\n serviceName: string | null;\r\n trial: boolean;\r\n\r\n /** @format date-time */\r\n endDate: string | null;\r\n ec: string | null;\r\n ecModules: Record;\r\n ecs: string | null;\r\n ecsModules: Record;\r\n clientContent: string | null;\r\n applications: ApplicationReadDTO[] | null;\r\n contacts: ContactReadDTO[] | null;\r\n clientContacts: ContactReadDTO[] | null;\r\n}\r\n\r\n/**\r\n * @format int32\r\n */\r\nexport type SubscriptionTrialFilter = 0 | 1 | 2 | 3;\r\n\r\nexport interface SubscriptionFilters {\r\n /** @format uuid */\r\n companyId: string | null;\r\n companyName: string | null;\r\n\r\n /** @format uuid */\r\n entityId: string | null;\r\n entityName: string | null;\r\n\r\n /** @format uuid */\r\n serviceId: string | null;\r\n serviceName: string | null;\r\n memberPpid: string | null;\r\n memberName: string | null;\r\n my: boolean | null;\r\n trial: SubscriptionTrialFilter;\r\n}\r\n\r\nexport interface SubscriptionOrderBy {\r\n companyName: OrderBy | null;\r\n entityName: OrderBy | null;\r\n serviceName: OrderBy | null;\r\n}\r\n\r\nexport interface SubscriptionQueryDTO {\r\n filters: SubscriptionFilters | null;\r\n orderBy: SubscriptionOrderBy | null;\r\n}\r\n\r\nexport interface SubscriptionUserAddDTO {\r\n ppid: string | null;\r\n isMainContact: boolean;\r\n}\r\n\r\nexport interface SubscriptionCreateDTO {\r\n /** @format uuid */\r\n companyId: string;\r\n\r\n /** @format uuid */\r\n entityId: string;\r\n\r\n /** @format uuid */\r\n serviceId: string;\r\n\r\n /** @format date-time */\r\n endDate: string | null;\r\n ec: string | null;\r\n ecModules: Record;\r\n ecs: string | null;\r\n ecsModules: Record;\r\n clientContent: string | null;\r\n applications: ApplicationCreateDTO[] | null;\r\n contacts: string[] | null;\r\n users: SubscriptionUserAddDTO[] | null;\r\n}\r\n\r\nexport interface SubscriptionUserUpdateDTO {\r\n ppid: string | null;\r\n isMainContact: boolean;\r\n}\r\n\r\nexport interface SubscriptionUserRemoveDTO {\r\n ppid: string | null;\r\n}\r\n\r\n/**\r\n * @format int32\r\n */\r\nexport type UserIdentity = 0 | 1 | 2;\r\n\r\nexport interface UserReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n ppid: string | null;\r\n name: string | null;\r\n lastName: string | null;\r\n firstName: string | null;\r\n email: string | null;\r\n\r\n /** @format int32 */\r\n phoneCountryCode: number | null;\r\n phoneNumber: string | null;\r\n grade: string | null;\r\n photoUri: string | null;\r\n isInternal: boolean;\r\n isSuperUser: boolean;\r\n termsAndConditionsAccepted: boolean;\r\n isLu: boolean;\r\n creationIdentity: UserIdentity;\r\n}\r\n\r\nexport interface UserFilters {\r\n name: string | null;\r\n email: string | null;\r\n grade: string | null;\r\n isSuperUser: boolean | null;\r\n isInternal: boolean | null;\r\n subscriptionId?: string | null;\r\n ppids: string[] | null;\r\n\r\n /** @format uuid */\r\n entityId: string | null;\r\n territory: string | null;\r\n}\r\n\r\nexport interface UserOrderBy {\r\n name: OrderBy | null;\r\n email: OrderBy | null;\r\n grade: OrderBy | null;\r\n}\r\n\r\nexport interface UserQueryDTO {\r\n filters: UserFilters | null;\r\n orderBy: UserOrderBy | null;\r\n}\r\n\r\nexport interface UserLookupReadDTO {\r\n ppid: string | null;\r\n firstName: string | null;\r\n lastName: string | null;\r\n displayName: string | null;\r\n pwcEmail: string | null;\r\n cloudEmail: string | null;\r\n preferredEmail: string | null;\r\n territory: string | null;\r\n isPwcUser: boolean;\r\n workPhone: string | null;\r\n mobilePhone: string | null;\r\n grade: string | null;\r\n jobTitle: string | null;\r\n losLevel1: string | null;\r\n losLevel2: string | null;\r\n losGlobalLevel1: string | null;\r\n losGlobalLevel2: string | null;\r\n costCenter: string | null;\r\n}\r\n\r\nexport type QueryParamsType = Record;\r\nexport type ResponseFormat = keyof Omit;\r\n\r\nexport interface FullRequestParams extends Omit {\r\n /** set parameter to `true` for call `securityWorker` for this request */\r\n secure?: boolean;\r\n /** request path */\r\n path: string;\r\n /** content type of request body */\r\n type?: ContentType;\r\n /** query params */\r\n query?: QueryParamsType;\r\n /** format of response (i.e. response.json() -> format: \"json\") */\r\n format?: ResponseFormat;\r\n /** request body */\r\n body?: unknown;\r\n /** base url */\r\n baseUrl?: string;\r\n /** request cancellation token */\r\n cancelToken?: CancelToken;\r\n}\r\n\r\nexport type RequestParams = Omit<\r\n FullRequestParams,\r\n \"body\" | \"method\" | \"query\" | \"path\"\r\n>;\r\n\r\nexport interface ApiConfig {\r\n baseUrl?: string;\r\n baseApiParams?: Omit;\r\n securityWorker?: (\r\n securityData: SecurityDataType | null\r\n ) => Promise | RequestParams | void;\r\n customFetch?: typeof fetch;\r\n}\r\n\r\nexport interface HttpResponse\r\n extends Response {\r\n data: D;\r\n error: E;\r\n}\r\n\r\ntype CancelToken = Symbol | string | number;\r\n\r\nexport enum ContentType {\r\n Json = \"application/json\",\r\n FormData = \"multipart/form-data\",\r\n UrlEncoded = \"application/x-www-form-urlencoded\",\r\n}\r\n\r\nexport class HttpClient {\r\n public baseUrl: string = \"\";\r\n private securityData: SecurityDataType | null = null;\r\n private securityWorker?: ApiConfig[\"securityWorker\"];\r\n private abortControllers = new Map();\r\n private customFetch = (...fetchParams: Parameters) =>\r\n fetch(...fetchParams);\r\n\r\n private baseApiParams: RequestParams = {\r\n credentials: \"same-origin\",\r\n headers: {},\r\n redirect: \"follow\",\r\n referrerPolicy: \"no-referrer\",\r\n };\r\n\r\n constructor(apiConfig: ApiConfig = {}) {\r\n Object.assign(this, apiConfig);\r\n }\r\n\r\n public setSecurityData = (data: SecurityDataType | null) => {\r\n this.securityData = data;\r\n };\r\n\r\n private encodeQueryParam(key: string, value: any) {\r\n const encodedKey = encodeURIComponent(key);\r\n return `${encodedKey}=${encodeURIComponent(\r\n typeof value === \"number\" ? value : `${value}`\r\n )}`;\r\n }\r\n\r\n private addQueryParam(query: QueryParamsType, key: string) {\r\n return this.encodeQueryParam(key, query[key]);\r\n }\r\n\r\n private addArrayQueryParam(query: QueryParamsType, key: string) {\r\n const value = query[key];\r\n return value.map((v: any) => this.encodeQueryParam(key, v)).join(\"&\");\r\n }\r\n\r\n protected toQueryString(rawQuery?: QueryParamsType): string {\r\n const query = rawQuery || {};\r\n const keys = Object.keys(query).filter(\r\n (key) => \"undefined\" !== typeof query[key]\r\n );\r\n return keys\r\n .map((key) =>\r\n Array.isArray(query[key])\r\n ? this.addArrayQueryParam(query, key)\r\n : this.addQueryParam(query, key)\r\n )\r\n .join(\"&\");\r\n }\r\n\r\n protected addQueryParams(rawQuery?: QueryParamsType): string {\r\n const queryString = this.toQueryString(rawQuery);\r\n return queryString ? `?${queryString}` : \"\";\r\n }\r\n\r\n private contentFormatters: Record any> = {\r\n [ContentType.Json]: (input: any) =>\r\n input !== null && (typeof input === \"object\" || typeof input === \"string\")\r\n ? JSON.stringify(input)\r\n : input,\r\n [ContentType.FormData]: (input: any) =>\r\n Object.keys(input || {}).reduce((formData, key) => {\r\n const property = input[key];\r\n formData.append(\r\n key,\r\n property instanceof Blob\r\n ? property\r\n : typeof property === \"object\" && property !== null\r\n ? JSON.stringify(property)\r\n : `${property}`\r\n );\r\n return formData;\r\n }, new FormData()),\r\n [ContentType.UrlEncoded]: (input: any) => this.toQueryString(input),\r\n };\r\n\r\n private mergeRequestParams(\r\n params1: RequestParams,\r\n params2?: RequestParams\r\n ): RequestParams {\r\n return {\r\n ...this.baseApiParams,\r\n ...params1,\r\n ...(params2 || {}),\r\n headers: {\r\n ...(this.baseApiParams.headers || {}),\r\n ...(params1.headers || {}),\r\n ...((params2 && params2.headers) || {}),\r\n },\r\n };\r\n }\r\n\r\n private createAbortSignal = (\r\n cancelToken: CancelToken\r\n ): AbortSignal | undefined => {\r\n if (this.abortControllers.has(cancelToken)) {\r\n const abortController = this.abortControllers.get(cancelToken);\r\n if (abortController) {\r\n return abortController.signal;\r\n }\r\n return void 0;\r\n }\r\n\r\n const abortController = new AbortController();\r\n this.abortControllers.set(cancelToken, abortController);\r\n return abortController.signal;\r\n };\r\n\r\n public abortRequest = (cancelToken: CancelToken) => {\r\n const abortController = this.abortControllers.get(cancelToken);\r\n\r\n if (abortController) {\r\n abortController.abort();\r\n this.abortControllers.delete(cancelToken);\r\n }\r\n };\r\n\r\n public request = async ({\r\n body,\r\n secure,\r\n path,\r\n type,\r\n query,\r\n format,\r\n baseUrl,\r\n cancelToken,\r\n ...params\r\n }: FullRequestParams): Promise> => {\r\n const secureParams =\r\n ((typeof secure === \"boolean\" ? secure : this.baseApiParams.secure) &&\r\n this.securityWorker &&\r\n (await this.securityWorker(this.securityData))) ||\r\n {};\r\n const requestParams = this.mergeRequestParams(params, secureParams);\r\n const queryString = query && this.toQueryString(query);\r\n const payloadFormatter = this.contentFormatters[type || ContentType.Json];\r\n const responseFormat = format || requestParams.format;\r\n\r\n return this.customFetch(\r\n `${baseUrl || this.baseUrl || \"\"}${path}${\r\n queryString ? `?${queryString}` : \"\"\r\n }`,\r\n {\r\n ...requestParams,\r\n headers: {\r\n ...(type && type !== ContentType.FormData\r\n ? { \"Content-Type\": type }\r\n : {}),\r\n ...(requestParams.headers || {}),\r\n },\r\n signal: cancelToken ? this.createAbortSignal(cancelToken) : void 0,\r\n body:\r\n typeof body === \"undefined\" || body === null\r\n ? null\r\n : payloadFormatter(body),\r\n }\r\n ).then(async (response) => {\r\n const r = response as HttpResponse;\r\n r.data = null as unknown as T;\r\n r.error = null as unknown as E;\r\n\r\n const data = !responseFormat\r\n ? r\r\n : await response[responseFormat]()\r\n .then((data) => {\r\n if (r.ok) {\r\n r.data = data;\r\n } else {\r\n r.error = data;\r\n }\r\n return r;\r\n })\r\n .catch((e) => {\r\n r.error = e;\r\n return r;\r\n });\r\n\r\n if (cancelToken) {\r\n this.abortControllers.delete(cancelToken);\r\n }\r\n\r\n if (!response.ok) throw data;\r\n return data;\r\n });\r\n };\r\n}\r\n\r\n/**\r\n * @title User Management Services v1\r\n * @version v1\r\n */\r\nexport class Api<\r\n SecurityDataType extends unknown\r\n> extends HttpClient {\r\n api = {\r\n /**\r\n * No description\r\n *\r\n * @tags Company\r\n * @name V1CompanyList\r\n * @summary Get all companies.\r\n * @request GET:/api/v1/Company\r\n * @secure\r\n */\r\n v1CompanyList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Company`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Company\r\n * @name V1CompanyCreate\r\n * @summary Create a company.\r\n * @request POST:/api/v1/Company\r\n * @secure\r\n */\r\n v1CompanyCreate: (data: CompanyCreateDTO, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Company`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Company\r\n * @name V1CompanyUpdate\r\n * @summary Update a company.\r\n * @request PUT:/api/v1/Company/{companyId}\r\n * @secure\r\n */\r\n v1CompanyUpdate: (\r\n companyId: string,\r\n data: CompanyUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Company/${companyId}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Company\r\n * @name V1CompanyDelete\r\n * @summary Delete a company.\r\n * @request DELETE:/api/v1/Company/{companyId}\r\n * @secure\r\n */\r\n v1CompanyDelete: (companyId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Company/${companyId}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityList\r\n * @summary Get all entities with users.\r\n * @request GET:/api/v1/Entity\r\n * @secure\r\n */\r\n v1EntityList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Entity`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityCreate\r\n * @summary Create an entity.\r\n * @request POST:/api/v1/Entity\r\n * @secure\r\n */\r\n v1EntityCreate: (data: EntityCreateDTO, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Entity`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityDetail\r\n * @summary Get all entities with users.\r\n * @request GET:/api/v1/Entity/{entityId}\r\n * @secure\r\n */\r\n v1EntityDetail: (entityId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Entity/${entityId}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityUpdate\r\n * @summary Update an entity.\r\n * @request PUT:/api/v1/Entity/{entityId}\r\n * @secure\r\n */\r\n v1EntityUpdate: (\r\n entityId: string,\r\n data: EntityUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Entity/${entityId}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityDelete\r\n * @summary Delete an entity.\r\n * @request DELETE:/api/v1/Entity/{entityId}\r\n * @secure\r\n */\r\n v1EntityDelete: (entityId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Entity/${entityId}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityMyContactsList\r\n * @summary Get available contact the client is member of the entity.\r\n * @request GET:/api/v1/Entity/my-contacts\r\n * @secure\r\n */\r\n v1EntityMyContactsList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Entity/my-contacts`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityUsersUpdate\r\n * @summary Add or update a user in a entity.\r\n * @request PUT:/api/v1/Entity/{entityId}/users\r\n * @secure\r\n */\r\n v1EntityUsersUpdate: (\r\n entityId: string,\r\n data: EntityUserAddDTO[],\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Entity/${entityId}/users`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityUsersDelete\r\n * @summary Remove user from an entity.\r\n * @request DELETE:/api/v1/Entity/{entityId}/users\r\n * @secure\r\n */\r\n v1EntityUsersDelete: (\r\n entityId: string,\r\n data: EntityUserRemoveDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Entity/${entityId}/users`,\r\n method: \"DELETE\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityImportList\r\n * @summary Download the template for the import.\r\n * @request GET:/api/v1/Entity/import\r\n * @secure\r\n */\r\n v1EntityImportList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Entity/import`,\r\n method: \"GET\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Entity\r\n * @name V1EntityImportCreate\r\n * @summary Import users from Excel file.\r\n * @request POST:/api/v1/Entity/import\r\n * @secure\r\n */\r\n v1EntityImportCreate: (\r\n data: { importFile?: File },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Entity/import`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags EntityIntegration\r\n * @name V1IntegrationEntityByUserDetail\r\n * @summary Get a user.\r\n * @request GET:/api/v1/Integration/Entity/by-user/{ppid}\r\n * @secure\r\n */\r\n v1IntegrationEntityByUserDetail: (\r\n ppid: string,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/Entity/by-user/${ppid}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Export\r\n * @name V1ExportUsersPermissionsCreate\r\n * @summary Export all permissions in Excel file.\r\n * @request POST:/api/v1/Export/UsersPermissions\r\n * @secure\r\n */\r\n v1ExportUsersPermissionsCreate: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Export/UsersPermissions`,\r\n method: \"POST\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Organization\r\n * @name V1OrganizationPagedCreate\r\n * @summary Get organizations by page.\r\n * @request POST:/api/v1/Organization/paged\r\n * @secure\r\n */\r\n v1OrganizationPagedCreate: (\r\n data: OrganizationQueryDTO,\r\n query?: { pageSize?: number; pageNumber?: number },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Organization/paged`,\r\n method: \"POST\",\r\n query: query,\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags OrganizationIntegration\r\n * @name V1IntegrationOrganizationByNamesCreate\r\n * @summary Get organizations by names.\r\n * @request POST:/api/v1/Integration/Organization/by-names\r\n * @secure\r\n */\r\n v1IntegrationOrganizationByNamesCreate: (\r\n data: string[],\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/Organization/by-names`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceList\r\n * @summary Get all services.\r\n * @request GET:/api/v1/Service\r\n * @secure\r\n */\r\n v1ServiceList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceMyList\r\n * @summary Get my services.\r\n * @request GET:/api/v1/Service/my\r\n * @secure\r\n */\r\n v1ServiceMyList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/my`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionDetail\r\n * @summary Get the specified subscription.\r\n * @request GET:/api/v1/Subscription/{subscriptionId}\r\n * @secure\r\n */\r\n v1SubscriptionDetail: (\r\n subscriptionId: string,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/${subscriptionId}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionUpdate\r\n * @summary Update the specified subscription.\r\n * @request PUT:/api/v1/Subscription/{subscriptionId}\r\n * @secure\r\n */\r\n v1SubscriptionUpdate: (\r\n subscriptionId: string,\r\n data: SubscriptionUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/${subscriptionId}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionDelete\r\n * @summary Delete an subscription.\r\n * @request DELETE:/api/v1/Subscription/{subscriptionId}\r\n * @secure\r\n */\r\n v1SubscriptionDelete: (\r\n subscriptionId: string,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/${subscriptionId}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionMyServicesList\r\n * @summary Get available services the client has a subscription.\r\n * @request GET:/api/v1/Subscription/my-services\r\n * @secure\r\n */\r\n v1SubscriptionMyServicesList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Subscription/my-services`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionMyClientsList\r\n * @summary Get services client has a subscription.\r\n * @request GET:/api/v1/Subscription/my-clients\r\n * @secure\r\n */\r\n v1SubscriptionMyClientsList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Subscription/my-clients`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionMyClientsServicesCreate\r\n * @summary Get paged my clients with services.\r\n * @request POST:/api/v1/Subscription/my-clients/services\r\n * @secure\r\n */\r\n v1SubscriptionMyClientsServicesCreate: (\r\n data: string[],\r\n query?: { pageSize?: number; pageNumber?: number },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/my-clients/services`,\r\n method: \"POST\",\r\n query: query,\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionByServiceDetail\r\n * @summary Get subscriptions by service.\r\n * @request GET:/api/v1/Subscription/by-service/{serviceId}\r\n * @secure\r\n */\r\n v1SubscriptionByServiceDetail: (\r\n serviceId: string,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/by-service/${serviceId}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionPagedUsersCreate\r\n * @summary Get paged subscriptions with client user access.\r\n * @request POST:/api/v1/Subscription/paged/users\r\n * @secure\r\n */\r\n v1SubscriptionPagedUsersCreate: (\r\n data: SubscriptionQueryDTO,\r\n query?: { pageSize?: number; pageNumber?: number },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/paged/users`,\r\n method: \"POST\",\r\n query: query,\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionCreate\r\n * @summary Create a subscription.\r\n * @request POST:/api/v1/Subscription\r\n * @secure\r\n */\r\n v1SubscriptionCreate: (\r\n data: SubscriptionCreateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionUsersUpdate\r\n * @summary Add or update a user in a subscription.\r\n * @request PUT:/api/v1/Subscription/{subscriptionId}/users\r\n * @secure\r\n */\r\n v1SubscriptionUsersUpdate: (\r\n subscriptionId: string,\r\n data: SubscriptionUserAddDTO[],\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/${subscriptionId}/users`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionUsersPartialUpdate\r\n * @summary Update user from an subscription.\r\n * @request PATCH:/api/v1/Subscription/{subscriptionId}/users\r\n * @secure\r\n */\r\n v1SubscriptionUsersPartialUpdate: (\r\n subscriptionId: string,\r\n data: SubscriptionUserUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/${subscriptionId}/users`,\r\n method: \"PATCH\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionUsersDelete\r\n * @summary Remove user from an subscription.\r\n * @request DELETE:/api/v1/Subscription/{subscriptionId}/users\r\n * @secure\r\n */\r\n v1SubscriptionUsersDelete: (\r\n subscriptionId: string,\r\n data: SubscriptionUserRemoveDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/${subscriptionId}/users`,\r\n method: \"DELETE\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionImportList\r\n * @summary Download the template for the import.\r\n * @request GET:/api/v1/Subscription/import\r\n * @secure\r\n */\r\n v1SubscriptionImportList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Subscription/import`,\r\n method: \"GET\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Subscription\r\n * @name V1SubscriptionImportCreate\r\n * @summary Import users from Excel file.\r\n * @request POST:/api/v1/Subscription/import\r\n * @secure\r\n */\r\n v1SubscriptionImportCreate: (\r\n data: { importFile?: File },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Subscription/import`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserCreate\r\n * @summary Create the user (internal or external).\r\n * @request POST:/api/v1/User\r\n * @secure\r\n */\r\n v1UserCreate: (\r\n data: {\r\n LastName?: string;\r\n FirstName?: string;\r\n Email?: string;\r\n PhoneCountryCode?: number;\r\n PhoneNumber?: string;\r\n Grade?: string;\r\n Photo?: File;\r\n IsSuperUser?: boolean;\r\n Entities?: string[];\r\n CreationIdentity?: UserIdentity;\r\n Send3WEmail?: boolean;\r\n SendAmdsEmail?: boolean;\r\n },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserUpdate\r\n * @summary Update the user.\r\n * @request PUT:/api/v1/User/{ppid}\r\n * @secure\r\n */\r\n v1UserUpdate: (\r\n ppid: string,\r\n data: {\r\n LastName?: string;\r\n FirstName?: string;\r\n PhoneCountryCode?: number;\r\n PhoneNumber?: string;\r\n Grade?: string;\r\n Photo?: File;\r\n IsSuperUser?: boolean;\r\n },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User/${ppid}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserDelete\r\n * @summary Delete the user.\r\n * @request DELETE:/api/v1/User/{ppid}\r\n * @secure\r\n */\r\n v1UserDelete: (ppid: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/User/${ppid}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserDetail\r\n * @summary Get a user.\r\n * @request GET:/api/v1/User/{ppid}\r\n * @secure\r\n */\r\n v1UserDetail: (ppid: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/User/${ppid}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserMyProfileUpdate\r\n * @summary Update own user profile.\r\n * @request PUT:/api/v1/User/MyProfile\r\n * @secure\r\n */\r\n v1UserMyProfileUpdate: (\r\n data: {\r\n LastName?: string;\r\n FirstName?: string;\r\n PhoneCountryCode?: number;\r\n PhoneNumber?: string;\r\n Photo?: File;\r\n },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User/MyProfile`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * @description If return code is 418: user is creating during the call.\r\n *\r\n * @tags User\r\n * @name V1UserMyProfileList\r\n * @summary Get own user profile.\r\n * @request GET:/api/v1/User/MyProfile\r\n * @secure\r\n */\r\n v1UserMyProfileList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/User/MyProfile`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserTermsAndConditionsAcceptedPartialUpdate\r\n * @summary Accept the Terms and Conditions.\r\n * @request PATCH:/api/v1/User/TermsAndConditionsAccepted\r\n * @secure\r\n */\r\n v1UserTermsAndConditionsAcceptedPartialUpdate: (\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User/TermsAndConditionsAccepted`,\r\n method: \"PATCH\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserSuperuserPartialUpdate\r\n * @summary Set the user status \"SuperUser\".\r\n * @request PATCH:/api/v1/User/{ppid}/superuser/{isSuperUser}\r\n * @secure\r\n */\r\n v1UserSuperuserPartialUpdate: (\r\n ppid: string,\r\n isSuperUser: boolean,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User/${ppid}/superuser/${isSuperUser}`,\r\n method: \"PATCH\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserServicesDetail\r\n * @summary get user's services.\r\n * @request GET:/api/v1/User/{ppid}/services\r\n * @secure\r\n */\r\n v1UserServicesDetail: (ppid: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/User/${ppid}/services`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserPagedCreate\r\n * @summary Get filtered users.\r\n * @request POST:/api/v1/User/paged\r\n * @secure\r\n */\r\n v1UserPagedCreate: (\r\n query: { pageSize: number; pageNumber: number },\r\n data: UserQueryDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User/paged`,\r\n method: \"POST\",\r\n query: query,\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserDetail2\r\n * @summary Get a user photo.\r\n * @request GET:/api/v1/User/{ppid}/{id}\r\n * @originalName v1UserDetail\r\n * @duplicate\r\n * @secure\r\n */\r\n v1UserDetail2: (ppid: string, id: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/User/${ppid}/${id}`,\r\n method: \"GET\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserExistingUserList\r\n * @summary Check if external user exists.\r\n * @request GET:/api/v1/User/ExistingUser\r\n * @secure\r\n */\r\n v1UserExistingUserList: (\r\n query: { email: string },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User/ExistingUser`,\r\n method: \"GET\",\r\n query: query,\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserEntitiesContactsDetail\r\n * @summary Get contacts of entities the user is linked to.\r\n * @request GET:/api/v1/User/{ppid}/entities/contacts\r\n * @secure\r\n */\r\n v1UserEntitiesContactsDetail: (ppid: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/User/${ppid}/entities/contacts`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserImportList\r\n * @summary Download the template for the import.\r\n * @request GET:/api/v1/User/import\r\n * @secure\r\n */\r\n v1UserImportList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/User/import`,\r\n method: \"GET\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags User\r\n * @name V1UserImportCreate\r\n * @summary Import users from Excel file.\r\n * @request POST:/api/v1/User/import\r\n * @secure\r\n */\r\n v1UserImportCreate: (\r\n data: { importFile?: File },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/User/import`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags UserIntegration\r\n * @name V1IntegrationUserDetail\r\n * @summary Get a user.\r\n * @request GET:/api/v1/Integration/User/{ppid}\r\n * @secure\r\n */\r\n v1IntegrationUserDetail: (ppid: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Integration/User/${ppid}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags UserIntegration\r\n * @name V1IntegrationUserByPpidsCreate\r\n * @summary Get users.\r\n * @request POST:/api/v1/Integration/User/by-ppids\r\n * @secure\r\n */\r\n v1IntegrationUserByPpidsCreate: (\r\n data: string[],\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/User/by-ppids`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags UserIntegration\r\n * @name V1IntegrationUserByEmailsCreate\r\n * @summary Get users.\r\n * @request POST:/api/v1/Integration/User/by-emails\r\n * @secure\r\n */\r\n v1IntegrationUserByEmailsCreate: (\r\n data: string[],\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/User/by-emails`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags UserIntegration\r\n * @name IntegrationUser\r\n * @summary Create the user (internal or external).\r\n * @request POST:/api/v1/Integration/User\r\n * @secure\r\n */\r\n integrationUser: (\r\n data: {\r\n LastName?: string;\r\n FirstName?: string;\r\n Email?: string;\r\n PhoneCountryCode?: number;\r\n PhoneNumber?: string;\r\n Grade?: string;\r\n Photo?: File;\r\n IsSuperUser?: boolean;\r\n Entities?: string[];\r\n CreationIdentity?: UserIdentity;\r\n Send3WEmail?: boolean;\r\n SendAmdsEmail?: boolean;\r\n },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/User`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags UserLookupIntegration\r\n * @name V1IntegrationUserLookupByEmailList\r\n * @summary Get a user info based on his email.\r\n * @request GET:/api/v1/Integration/UserLookup/by-email\r\n * @secure\r\n */\r\n v1IntegrationUserLookupByEmailList: (\r\n query: { email: string },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/UserLookup/by-email`,\r\n method: \"GET\",\r\n query: query,\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags UserLookupIntegration\r\n * @name V1IntegrationUserLookupByPpidList\r\n * @summary Get a user info based on his Ppid.\r\n * @request GET:/api/v1/Integration/UserLookup/by-ppid\r\n * @secure\r\n */\r\n v1IntegrationUserLookupByPpidList: (\r\n query: { ppid: string },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/UserLookup/by-ppid`,\r\n method: \"GET\",\r\n query: query,\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags UserLookupIntegration\r\n * @name V1IntegrationUserLookupByAttributeList\r\n * @summary Get a user info based on a specific attribute.\r\n * @request GET:/api/v1/Integration/UserLookup/by-attribute\r\n * @secure\r\n */\r\n v1IntegrationUserLookupByAttributeList: (\r\n query: { attribute: string; value: string },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Integration/UserLookup/by-attribute`,\r\n method: \"GET\",\r\n query: query,\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n };\r\n}\r\n","import { MIME_PNG } from \"../../constants\";\r\nimport { dataURItoBlob } from \"../helpers\";\r\n\r\nexport const adminAdaptUserToBackEnd = (oldData: any): any => {\r\n const newData = {\r\n Email: oldData.email,\r\n FirstName: oldData.firstName,\r\n Grade: oldData.grade,\r\n IsSuperUser: oldData.isSuperUser,\r\n LastName: oldData.lastName,\r\n PhoneCountryCode: oldData.phoneCountryCode,\r\n PhoneNumber: oldData.phoneNumber,\r\n Photo: null as any,\r\n Entities: oldData.entities,\r\n Send3WEmail: oldData.send3WEmail,\r\n SendAmdsEmail: oldData.sendAmdsEmail,\r\n CreationIdentity: oldData.creationIdentity,\r\n };\r\n\r\n if (oldData.photo) {\r\n newData.Photo = dataURItoBlob(oldData.photo, MIME_PNG);\r\n }\r\n\r\n return newData;\r\n};\r\n","import { imageFromBlob } from \"api/utils\";\r\nimport { downloadBlob } from \"utils\";\r\n\r\nimport {\r\n RET_RAW,\r\n apiFetch,\r\n apiFetchFormData,\r\n appendIEHeaders,\r\n appendTokenHeaders,\r\n} from \"../api\";\r\nimport {\r\n Api,\r\n CompanyCreateDTO,\r\n CompanyReadDTO,\r\n EntityCreateDTO,\r\n EntityReadDTO,\r\n MyClientReadDTO,\r\n MyClientServicesReadDTO,\r\n MyServiceClientReadDTO,\r\n MyServicePwCReadDTO,\r\n OrganizationQueryDTO,\r\n OrganizationReadDTOPagedCollection,\r\n ServiceReadForAdminDTO,\r\n SubscriptionCreateDTO,\r\n SubscriptionDetailsReadDTO,\r\n SubscriptionQueryDTO,\r\n SubscriptionReadDTO,\r\n UserFilters,\r\n UserOrderBy,\r\n UserQueryDTO,\r\n} from \"./__generated__/UserManagementAPI\";\r\nimport { adminAdaptUserToBackEnd } from \"./adminDataManipulators\";\r\nimport { Company } from \"./model/Company\";\r\nimport { EntityUpdate } from \"./model/Entity\";\r\nimport { SubscriptionUpdate } from \"./model/Subscription\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_USERMANAGEMENT;\r\n\r\nconst DEFAULT_PAGINATION = {\r\n pageSize: 20,\r\n pageNumber: 1,\r\n};\r\n\r\nlet _clientSingleton: Api | null = null;\r\nconst client = (): Api => {\r\n if (!_clientSingleton) {\r\n _clientSingleton = new Api({\r\n baseUrl: PREFIX,\r\n baseApiParams: {\r\n headers: {\r\n Accept: \"application/json\",\r\n \"Content-Type\": \"application/json\",\r\n ...appendTokenHeaders(),\r\n ...appendIEHeaders(),\r\n },\r\n },\r\n });\r\n }\r\n return _clientSingleton;\r\n};\r\n\r\nfunction toData(res: { data: T }) {\r\n return res.data;\r\n}\r\n\r\nexport const getMyProfile = () => {\r\n return client().api.v1UserMyProfileList().then(toData);\r\n};\r\n\r\nexport const getUsers = (\r\n filters: UserQueryDTO,\r\n pagination = DEFAULT_PAGINATION\r\n) => {\r\n return client().api.v1UserPagedCreate(pagination, filters).then(toData);\r\n};\r\n\r\nexport const getUsersByPpids = (ppids: string[]) => {\r\n return getUsers(\r\n {\r\n filters: {\r\n ppids,\r\n } as UserFilters,\r\n orderBy: {} as UserOrderBy,\r\n },\r\n {\r\n pageNumber: 1,\r\n pageSize: ppids.length,\r\n }\r\n );\r\n};\r\n\r\nexport const getUsersFromIdArray = (ids: string[]) => {\r\n return apiFetch(`${PREFIX}/api/v1/User/fullnames`, ids, \"POST\");\r\n};\r\nexport const getOrganizationsFromIdArray = (ids: string[]) => {\r\n return apiFetch(`${PREFIX}/api/v1/Organization/names`, ids, \"POST\");\r\n};\r\n\r\nexport const getUserDetails = (ppid: string) => {\r\n return client().api.v1UserDetail(ppid).then(toData);\r\n};\r\n\r\nexport const deleteUser = (id: string) => {\r\n return client().api.v1UserDelete(id).then(toData);\r\n};\r\n\r\nexport const getSubscriptionsUsersPaged = (\r\n filters: SubscriptionQueryDTO,\r\n pagination: any\r\n): Promise => {\r\n return client()\r\n .api.v1SubscriptionPagedUsersCreate(filters, pagination)\r\n .then(toData);\r\n};\r\n\r\nexport const getSubscriptionDetails = (id: string) => {\r\n return client().api.v1SubscriptionDetail(id).then(toData);\r\n};\r\n\r\nfunction upsertSubscriptionCatch(exception: any) {\r\n if (\r\n exception?.error?.length === 1 &&\r\n exception.error[0].message?.startsWith(\"[Duplicate]\")\r\n ) {\r\n exception.error[0].message =\r\n \"A subscription already exists for the selection\";\r\n }\r\n}\r\n\r\nexport const addEngagement = (\r\n engagement: SubscriptionCreateDTO\r\n): Promise => {\r\n const _engagement = {\r\n ...engagement,\r\n users: engagement.users!.map((user) => ({\r\n ppid: user.ppid,\r\n isMainContact: true, // all users added are main contact\r\n })),\r\n };\r\n return client()\r\n .api.v1SubscriptionCreate(_engagement)\r\n .then(toData)\r\n .catch((exception) => {\r\n upsertSubscriptionCatch(exception);\r\n throw exception;\r\n });\r\n};\r\n\r\nexport const updateEngagement = ({\r\n subscriptionId,\r\n ...engagement\r\n}: SubscriptionUpdate): Promise => {\r\n return client()\r\n .api.v1SubscriptionUpdate(subscriptionId, engagement)\r\n .then(toData)\r\n .catch((exception) => {\r\n upsertSubscriptionCatch(exception);\r\n throw exception;\r\n });\r\n};\r\n\r\nexport const getUserFromEmail = (email: string) => {\r\n return client()\r\n .api.v1UserExistingUserList({ email })\r\n .then((response) => {\r\n if (response.status === 204) {\r\n // server returns 204 in case user does not exist, treat it like a 404\r\n // eslint-disable-next-line\r\n throw { ...response, status: 404 };\r\n } else return toData(response);\r\n });\r\n};\r\n\r\nexport const createUser = (user: any) => {\r\n const data = adminAdaptUserToBackEnd(user);\r\n return apiFetchFormData(`${PREFIX}/api/v1/User`, data, \"POST\");\r\n};\r\n\r\nexport const updateUser = (user: any) => {\r\n const data = adminAdaptUserToBackEnd(user);\r\n return apiFetchFormData(`${PREFIX}/api/v1/User/${user.ppid}`, data, \"PUT\");\r\n};\r\n\r\nexport const downloadUserImportTemplate = () => {\r\n return apiFetch(`${PREFIX}/api/v1/User/import`, undefined, \"GET\", RET_RAW)\r\n .then((res: any) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"import_users_template.xlsx\"));\r\n};\r\n\r\nexport const importUsersFromExcel = (file: File) => {\r\n return apiFetchFormData(\r\n `${PREFIX}/api/v1/User/import`,\r\n { importFile: file },\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const downloadEntityImportTemplate = () => {\r\n return apiFetch(`${PREFIX}/api/v1/Entity/import`, undefined, \"GET\", RET_RAW)\r\n .then((res: any) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"import_companies_template.xlsx\"));\r\n};\r\n\r\nexport const importEntitiesFromExcel = (file: File) => {\r\n return apiFetchFormData(\r\n `${PREFIX}/api/v1/Entity/import`,\r\n { importFile: file },\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const updateProfile = (user: any) => {\r\n const data = adminAdaptUserToBackEnd(user);\r\n return apiFetchFormData(`${PREFIX}/api/v1/User/MyProfile`, data, \"PUT\");\r\n};\r\n\r\nexport const addUserToEngagement = (\r\n subscirptionId: string,\r\n ppids: string[]\r\n) => {\r\n return client()\r\n .api.v1SubscriptionUsersUpdate(\r\n subscirptionId,\r\n ppids.map((ppid) => ({ ppid, isMainContact: false }))\r\n )\r\n .then(toData);\r\n};\r\n\r\nexport const updateUserEngagement = (\r\n subscriptionId: string,\r\n userPpid: string,\r\n isMainContact: boolean\r\n) => {\r\n return client()\r\n .api.v1SubscriptionUsersPartialUpdate(subscriptionId, {\r\n ppid: userPpid,\r\n isMainContact,\r\n })\r\n .then(toData);\r\n};\r\n\r\nexport const deleteUserFromEngagement = (\r\n engagementId: string,\r\n ppid: string\r\n) => {\r\n return client()\r\n .api.v1SubscriptionUsersDelete(engagementId, { ppid })\r\n .then(toData);\r\n};\r\n\r\nexport const deleteEngagement = (engagementId: string) => {\r\n return client().api.v1SubscriptionDelete(engagementId).then(toData);\r\n};\r\n\r\nexport const downloadSubscriptionImportTemplate = () => {\r\n return apiFetch(\r\n `${PREFIX}/api/v1/Subscription/import`,\r\n undefined,\r\n \"GET\",\r\n RET_RAW\r\n )\r\n .then((res: any) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"import_subscriptions_template.xlsx\"));\r\n};\r\n\r\nexport const getSubscriptionNamesFromIds = (subscriptionIds: string[]) => {\r\n return apiFetch(\r\n `${PREFIX}/api/v1/Subscription/fullnames`,\r\n subscriptionIds,\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const importSubscriptionFromExcel = (file: File) => {\r\n return apiFetchFormData(\r\n `${PREFIX}/api/v1/Subscription/import`,\r\n { importFile: file },\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const downloadServiceImportTemplate = () => {\r\n return apiFetch(\r\n `${process.env.REACT_APP_URL_CATALOG}/api/v1/Service/import`,\r\n undefined,\r\n \"GET\",\r\n RET_RAW\r\n )\r\n .then((res: any) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"import_services_template.xlsx\"));\r\n};\r\n\r\nexport const downloadServiceExport = () => {\r\n return apiFetch(\r\n `${process.env.REACT_APP_URL_CATALOG}/api/v1/Service/export/excel`,\r\n undefined,\r\n \"POST\",\r\n RET_RAW\r\n )\r\n .then((res: any) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"export_services.xlsx\"));\r\n};\r\n\r\nexport const downloadUserPermissions = () => {\r\n return apiFetch(\r\n `${process.env.REACT_APP_URL_USERMANAGEMENT}/api/v1/Export/UsersPermissions`,\r\n undefined,\r\n \"POST\",\r\n RET_RAW\r\n )\r\n .then((res: any) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"export_user_permissions.xlsx\"));\r\n};\r\n\r\nexport const importServiceFromExcel = (file: File) => {\r\n return apiFetchFormData(\r\n `${process.env.REACT_APP_URL_CATALOG}/api/v1/Service/import`,\r\n { importFile: file },\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const updateSuperUserStatus = (ppid: string, isSuperUser: boolean) => {\r\n return client()\r\n .api.v1UserSuperuserPartialUpdate(ppid, isSuperUser)\r\n .then(toData);\r\n};\r\n\r\nexport const getPhoto = (photoUri: string) => {\r\n return apiFetch(\r\n `${PREFIX}/api/v1/User/${photoUri}`,\r\n undefined,\r\n \"GET\",\r\n RET_RAW,\r\n { \"Cache-Control\": \"max-age=9999\" }\r\n )\r\n .then((data: any) => data.blob())\r\n .then(imageFromBlob)\r\n .catch(() => null);\r\n};\r\n\r\nexport const resendUserWelcomeEmails = (\r\n ppid: string,\r\n send3w: boolean,\r\n sendAmds: boolean,\r\n creationIdentity: string\r\n) => {\r\n return apiFetchFormData(\r\n `${PREFIX}/api/v1/User/${ppid}/resend`,\r\n {\r\n Send3WEmail: send3w,\r\n SendAmdsEmail: sendAmds,\r\n CreationIdentity: creationIdentity,\r\n },\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const getCompanies = (): Promise => {\r\n return client().api.v1CompanyList().then(toData);\r\n};\r\n\r\nexport const createCompany = (company: CompanyCreateDTO) => {\r\n return client().api.v1CompanyCreate(company).then(toData);\r\n};\r\n\r\nexport const updateCompany = (company: Company) => {\r\n const { id, ...data } = company;\r\n return client().api.v1CompanyUpdate(id, data);\r\n};\r\n\r\nexport const acceptTermsAndConditions = () => {\r\n return client()\r\n .api.v1UserTermsAndConditionsAcceptedPartialUpdate()\r\n .then(toData);\r\n};\r\n\r\nexport const getAllEntities = () => {\r\n return client().api.v1EntityList().then(toData);\r\n};\r\nexport const createEntity = (dto: EntityCreateDTO) => {\r\n return client().api.v1EntityCreate(dto).then(toData);\r\n};\r\n\r\nexport const updateEntity = ({ entityId, ...data }: EntityUpdate) => {\r\n return client().api.v1EntityUpdate(entityId, data).then(toData);\r\n};\r\n\r\nexport const getMyContacts = () => {\r\n return client().api.v1EntityMyContactsList().then(toData);\r\n};\r\n\r\nexport const getUserEntitiesContacs = (entityId: string) => {\r\n return client().api.v1UserEntitiesContactsDetail(entityId).then(toData);\r\n};\r\n\r\nexport const deleteEntity = (entityId: string) => {\r\n return client().api.v1EntityDelete(entityId).then(toData);\r\n};\r\n\r\nexport const addUserToEntity = (\r\n entityId: string,\r\n ppids: string[]\r\n): Promise => {\r\n return client()\r\n .api.v1EntityUsersUpdate(\r\n entityId,\r\n ppids.map((ppid) => ({ ppid }))\r\n )\r\n .then(toData);\r\n};\r\n\r\nexport const removeUserFromEntity = (\r\n entityId: string,\r\n ppid: string\r\n): Promise => {\r\n return client().api.v1EntityUsersDelete(entityId, { ppid }).then(toData);\r\n};\r\n\r\nexport const getAdminCatalogue = (): Promise => {\r\n return client().api.v1ServiceList().then(toData);\r\n};\r\n\r\nexport const getUserSubscriptions = (): Promise => {\r\n return client().api.v1SubscriptionMyServicesList().then(toData);\r\n};\r\n\r\nexport const getMyClientNames = (): Promise => {\r\n return client().api.v1SubscriptionMyClientsList().then(toData);\r\n};\r\n\r\nexport const getMyServices = (): Promise => {\r\n return client().api.v1ServiceMyList().then(toData);\r\n};\r\n\r\nexport const getMyClientSubscriptions = (\r\n clientIds: string[],\r\n pagination = DEFAULT_PAGINATION\r\n): Promise => {\r\n return client()\r\n .api.v1SubscriptionMyClientsServicesCreate(clientIds, pagination)\r\n .then(toData);\r\n};\r\n\r\nexport const getOrganizations = (\r\n filters: OrganizationQueryDTO,\r\n pagination = DEFAULT_PAGINATION\r\n): Promise => {\r\n return client()\r\n .api.v1OrganizationPagedCreate(filters, pagination)\r\n .then(toData);\r\n};\r\n\r\nexport function getSubscriptionsByService(\r\n serviceId: string\r\n): Promise {\r\n return client().api.v1SubscriptionByServiceDetail(serviceId).then(toData);\r\n}\r\n\r\nexport function getSubscriptionsByUser(\r\n userId: string\r\n): Promise {\r\n return client().api.v1UserServicesDetail(userId).then(toData);\r\n}\r\n\r\nexport const getUserContacts = (subscriptionId: string) => {\r\n return client()\r\n .api.v1UserPagedCreate(\r\n { pageSize: 9999, pageNumber: 1 },\r\n {\r\n filters: {\r\n isInternal: false,\r\n subscriptionId: subscriptionId,\r\n } as any,\r\n orderBy: {\r\n name: {\r\n isDescending: false,\r\n },\r\n } as any,\r\n }\r\n )\r\n .then(toData);\r\n};\r\n\r\nexport const refreshUser = (userId: string) => {\r\n return apiFetch(`${PREFIX}/api/v1/User/refresh`, [userId], \"PUT\");\r\n};\r\n\r\nexport const refreshAllUsers = () => {\r\n //if (!!1) return new Promise((resolve) => setTimeout(resolve, 5000));\r\n return apiFetch(`${PREFIX}/api/v1/User/refreshAll`, undefined, \"PUT\");\r\n};\r\n","import { Helmet } from \"react-helmet\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nconst PageTitle = ({ title = null }) => {\r\n const hostInfoName = useSelector((state) => state.global.data.hostInfo?.name);\r\n if (!hostInfoName) return null;\r\n const suffix = `${hostInfoName}${\r\n process.env.REACT_APP_APP_NAME_SUFFIX\r\n ? ` ${process.env.REACT_APP_APP_NAME_SUFFIX}`\r\n : \"\"\r\n }`;\r\n\r\n return (\r\n \r\n \r\n {title ? `${title} - ` : \"\"}\r\n {suffix}\r\n \r\n \r\n );\r\n};\r\n\r\nexport default PageTitle;\r\n","import \"./index.scss\";\r\n\r\nimport { Button, ModalBody, ModalFooter, ModalHeader } from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport FileIcon from \"pages/newsAdmin/components/FileIcon\";\r\n\r\nconst NewsExcelUploadModal = ({\r\n uploadedFile = null,\r\n onClose,\r\n handleConfirm,\r\n type = \"News\",\r\n}) => {\r\n return (\r\n \r\n Bulk import {type}\r\n \r\n
\r\n \r\n {uploadedFile?.name}\r\n
\r\n

\r\n {`This file's content will be read and imported into the ${type} list. Are\r\n you sure you wish to proceed?`}\r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default NewsExcelUploadModal;\r\n","import \"./index.scss\";\r\n\r\nimport { Button, PopBanner } from \"appkit-react\";\r\nimport { Upload } from \"appkit-react-upload\";\r\nimport FullPageLoader from \"components/FullPageLoader\";\r\nimport { useState } from \"react\";\r\n\r\nimport { MIME_XLSX } from \"../../../../constants\";\r\nimport NewsExcelUploadModal from \"../NewsExcelUploadModal\";\r\n\r\nconst UploadImport = ({ onImport, type = \"News\", onDownloadTemplate }) => {\r\n const [fileToUpload, setFileToUpload] = useState(null);\r\n const [uploadingExcel, setUploadingExcel] = useState(false);\r\n\r\n const onUploadChange = (file) => {\r\n if (file.type !== MIME_XLSX) {\r\n PopBanner({\r\n content: Only .xlsx files are supported,\r\n duration: 4000,\r\n status: \"warning\",\r\n });\r\n } else {\r\n setFileToUpload(file.originFile);\r\n }\r\n };\r\n\r\n const handleExcelUpload = () => {\r\n setUploadingExcel(true);\r\n onImport(fileToUpload)\r\n .then((data) => {\r\n PopBanner({\r\n content: (\r\n \r\n {`${type[0].toUpperCase()}${type.substring(\r\n 1\r\n )} items successfully imported. They will be available shortly`}\r\n \r\n ),\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n })\r\n .finally(() => {\r\n setUploadingExcel(false);\r\n });\r\n setFileToUpload(null);\r\n };\r\n\r\n const handleDownloadTemplate = (e) => {\r\n e.preventDefault();\r\n e.stopPropagation();\r\n onDownloadTemplate();\r\n };\r\n\r\n return (\r\n <>\r\n setFileToUpload(null)}\r\n uploadedFile={fileToUpload}\r\n type={type}\r\n />\r\n {uploadingExcel && (\r\n \r\n )}\r\n \r\n
\r\n
\r\n Drag and drop or\r\n  choose your file\r\n
\r\n \r\n \r\n Download empty import template file\r\n \r\n
\r\n \r\n \r\n );\r\n};\r\n\r\nexport default UploadImport;\r\n","/* eslint-disable */\r\n/* tslint:disable */\r\n/*\r\n * ---------------------------------------------------------------\r\n * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##\r\n * ## ##\r\n * ## AUTHOR: acacode ##\r\n * ## SOURCE: https://github.com/acacode/swagger-typescript-api ##\r\n * ---------------------------------------------------------------\r\n */\r\n\r\nexport interface CaptchaCreateDTO {\r\n /** @format uuid */\r\n resourceId: string | null;\r\n}\r\n\r\nexport interface CaptchaReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n\r\n /** @format date-time */\r\n expiredAt: string;\r\n captcha: string | null;\r\n\r\n /** @format int32 */\r\n width: number;\r\n\r\n /** @format int32 */\r\n height: number;\r\n}\r\n\r\nexport interface SubIndustryAllReadDTO {\r\n [key: string]: SubIndustryReadDTO;\r\n}\r\n\r\nexport interface SubIndustryReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n}\r\n\r\nexport interface IndustryAllReadDTO {\r\n [key: string]: IndustryReadDTO[];\r\n}\r\n\r\nexport interface IndustryReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n subIndustries: SubIndustryReadDTO[] | null;\r\n}\r\n\r\nexport interface SubIndustryCreateDTO {\r\n name: string | null;\r\n}\r\n\r\nexport interface IndustryCreateDTO {\r\n name: string | null;\r\n subIndustries: SubIndustryCreateDTO[] | null;\r\n}\r\n\r\nexport interface IndustryUpdateDTO {\r\n name: string | null;\r\n}\r\n\r\nexport interface SubIndustryUpdateDTO {\r\n name: string | null;\r\n}\r\n\r\nexport interface LifecycleAllReadDTO {\r\n [key: string]: LifecycleReadDTO[];\r\n}\r\n\r\nexport interface LifecycleReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n\r\n /** @format int32 */\r\n order: number;\r\n domain: string;\r\n}\r\n\r\nexport interface LifecycleCreateDTO {\r\n name: string | null;\r\n\r\n /** @format int32 */\r\n order: number;\r\n}\r\n\r\nexport interface LifecycleUpdateDTO {\r\n name: string | null;\r\n}\r\n\r\nexport interface PageContactReadDTO {\r\n ppid: string | null;\r\n firstname: string | null;\r\n lastname: string | null;\r\n email: string | null;\r\n\r\n /** @format int32 */\r\n phoneCountryCode: number | null;\r\n phoneNumber: string | null;\r\n grade: string | null;\r\n photoUri: string | null;\r\n}\r\n\r\nexport interface PageReadDTO {\r\n title: string | null;\r\n subtitle: string | null;\r\n description: string | null;\r\n value1Title: string | null;\r\n value1Description: string | null;\r\n value2Title: string | null;\r\n value2Description: string | null;\r\n contacts: PageContactReadDTO[] | null;\r\n mainFilter: string | null;\r\n secondaryFilter: string | null;\r\n tertiaryFilter: string | null;\r\n}\r\n\r\nexport interface PageFieldsUpdateDTO {\r\n title: string | null;\r\n subtitle: string | null;\r\n description: string | null;\r\n value1Title: string | null;\r\n value1Description: string | null;\r\n value2Title: string | null;\r\n value2Description: string | null;\r\n contacts: string[] | null;\r\n}\r\n\r\nexport interface PageOptionsUpdateDTO {\r\n mainFilter: string | null;\r\n secondaryFilter: string | null;\r\n tertiaryFilter: string | null;\r\n}\r\n\r\nexport interface ServiceContactReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n ppid: string | null;\r\n firstname: string | null;\r\n lastname: string | null;\r\n email: string | null;\r\n\r\n /** @format int32 */\r\n phoneCountryCode: number | null;\r\n phoneNumber: string | null;\r\n grade: string | null;\r\n photoUri: string | null;\r\n}\r\n\r\nexport interface ApplicationReadDTO {\r\n name: string | null;\r\n link: string | null;\r\n showToClient: boolean;\r\n itContact: ServiceContactReadDTO | null;\r\n}\r\n\r\nexport interface RelatedServicesDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n smallDescription: string | null;\r\n}\r\n\r\nexport interface ServiceIllustrationReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n contentType: string | null;\r\n isVideo: boolean;\r\n}\r\n\r\nexport interface ServiceReadDTO {\r\n team: ServiceContactReadDTO[] | null;\r\n responsibles: ServiceContactReadDTO[] | null;\r\n organizations: string[] | null;\r\n viewers: ServiceContactReadDTO[] | null;\r\n ukViewers: ServiceContactReadDTO[] | null;\r\n frViewers: ServiceContactReadDTO[] | null;\r\n applications: ApplicationReadDTO[] | null;\r\n industries: string[] | null;\r\n itContact: ServiceContactReadDTO | null;\r\n relatedServices: RelatedServicesDTO[] | null;\r\n illustrations: ServiceIllustrationReadDTO[] | null;\r\n domains: string[] | null;\r\n territories: { id: string; name: string }[] | null;\r\n\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n description: string | null;\r\n videoLink: string | null;\r\n live: boolean;\r\n isHighlighted: boolean;\r\n isNew: boolean;\r\n isPSF: boolean;\r\n isPSA: boolean;\r\n lifeCycles: string[] | null;\r\n valueChains: string[] | null;\r\n smallDescription: string | null;\r\n geographicalInformation: string | null;\r\n targetProfile: string | null;\r\n availableApplication: string | null;\r\n deliverable: string | null;\r\n mainAddedValue: string | null;\r\n secondaryAddedValue: string | null;\r\n\r\n /** @format uuid */\r\n serviceGroupId: string | null;\r\n friendlyUrl: string | null;\r\n visibleInClientView: boolean | null;\r\n}\r\n\r\nexport interface ApplicationCreateDTO {\r\n name: string | null;\r\n link: string | null;\r\n showToClient: boolean;\r\n itContactPpid: string | null;\r\n}\r\n\r\nexport interface CaptchaValidationDTO {\r\n /** @format uuid */\r\n id: string;\r\n code: string | null;\r\n}\r\n\r\nexport interface ServiceContactDTO {\r\n message: string | null;\r\n email: string | null;\r\n name: string | null;\r\n phoneNumber: string | null;\r\n jobTitle: string | null;\r\n captchaValidation: CaptchaValidationDTO | null;\r\n}\r\n\r\nexport interface ServiceGroupReadListDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n lifeCycle: string | null;\r\n valueChain: string | null;\r\n smallDescription: string | null;\r\n domain: string;\r\n}\r\n\r\nexport interface ServiceGroupCreateDTO {\r\n name: string | null;\r\n lifeCycles: string[] | null;\r\n valueChains: string[] | null;\r\n smallDescription: string | null;\r\n services: string[] | null;\r\n}\r\n\r\nexport interface ServiceGroupServiceReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n}\r\n\r\nexport interface ServiceGroupReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n lifeCycles: string[] | null;\r\n valueChains: string[] | null;\r\n smallDescription: string | null;\r\n services: ServiceGroupServiceReadDTO[] | null;\r\n}\r\n\r\nexport interface ServiceGroupUpdateDTO {\r\n name: string | null;\r\n lifeCycles: string[] | null;\r\n valueChains: string[] | null;\r\n smallDescription: string | null;\r\n services: string[] | null;\r\n}\r\n\r\nexport interface ValueChainAllReadDTO {\r\n [key: string]: ValueChainReadDTO[];\r\n}\r\n\r\nexport interface ValueChainReadDTO {\r\n /** @format uuid */\r\n id: string;\r\n name: string | null;\r\n\r\n /** @format int32 */\r\n order: number;\r\n domain: string;\r\n}\r\n\r\nexport interface ValueChainCreateDTO {\r\n name: string | null;\r\n\r\n /** @format int32 */\r\n order: number;\r\n}\r\n\r\nexport interface ValueChainUpdateDTO {\r\n name: string | null;\r\n}\r\n\r\nexport type QueryParamsType = Record;\r\nexport type ResponseFormat = keyof Omit;\r\n\r\nexport interface FullRequestParams extends Omit {\r\n /** set parameter to `true` for call `securityWorker` for this request */\r\n secure?: boolean;\r\n /** request path */\r\n path: string;\r\n /** content type of request body */\r\n type?: ContentType;\r\n /** query params */\r\n query?: QueryParamsType;\r\n /** format of response (i.e. response.json() -> format: \"json\") */\r\n format?: ResponseFormat;\r\n /** request body */\r\n body?: unknown;\r\n /** base url */\r\n baseUrl?: string;\r\n /** request cancellation token */\r\n cancelToken?: CancelToken;\r\n}\r\n\r\nexport type RequestParams = Omit<\r\n FullRequestParams,\r\n \"body\" | \"method\" | \"query\" | \"path\"\r\n>;\r\n\r\nexport interface ApiConfig {\r\n baseUrl?: string;\r\n baseApiParams?: Omit;\r\n securityWorker?: (\r\n securityData: SecurityDataType | null\r\n ) => Promise | RequestParams | void;\r\n customFetch?: typeof fetch;\r\n}\r\n\r\nexport interface HttpResponse\r\n extends Response {\r\n data: D;\r\n error: E;\r\n}\r\n\r\ntype CancelToken = Symbol | string | number;\r\n\r\nexport enum ContentType {\r\n Json = \"application/json\",\r\n FormData = \"multipart/form-data\",\r\n UrlEncoded = \"application/x-www-form-urlencoded\",\r\n}\r\n\r\nexport class HttpClient {\r\n public baseUrl: string = \"\";\r\n private securityData: SecurityDataType | null = null;\r\n private securityWorker?: ApiConfig[\"securityWorker\"];\r\n private abortControllers = new Map();\r\n private customFetch = (...fetchParams: Parameters) =>\r\n fetch(...fetchParams);\r\n\r\n private baseApiParams: RequestParams = {\r\n credentials: \"same-origin\",\r\n headers: {},\r\n redirect: \"follow\",\r\n referrerPolicy: \"no-referrer\",\r\n };\r\n\r\n constructor(apiConfig: ApiConfig = {}) {\r\n Object.assign(this, apiConfig);\r\n }\r\n\r\n public setSecurityData = (data: SecurityDataType | null) => {\r\n this.securityData = data;\r\n };\r\n\r\n private encodeQueryParam(key: string, value: any) {\r\n const encodedKey = encodeURIComponent(key);\r\n return `${encodedKey}=${encodeURIComponent(\r\n typeof value === \"number\" ? value : `${value}`\r\n )}`;\r\n }\r\n\r\n private addQueryParam(query: QueryParamsType, key: string) {\r\n return this.encodeQueryParam(key, query[key]);\r\n }\r\n\r\n private addArrayQueryParam(query: QueryParamsType, key: string) {\r\n const value = query[key];\r\n return value.map((v: any) => this.encodeQueryParam(key, v)).join(\"&\");\r\n }\r\n\r\n protected toQueryString(rawQuery?: QueryParamsType): string {\r\n const query = rawQuery || {};\r\n const keys = Object.keys(query).filter(\r\n (key) => \"undefined\" !== typeof query[key]\r\n );\r\n return keys\r\n .map((key) =>\r\n Array.isArray(query[key])\r\n ? this.addArrayQueryParam(query, key)\r\n : this.addQueryParam(query, key)\r\n )\r\n .join(\"&\");\r\n }\r\n\r\n protected addQueryParams(rawQuery?: QueryParamsType): string {\r\n const queryString = this.toQueryString(rawQuery);\r\n return queryString ? `?${queryString}` : \"\";\r\n }\r\n\r\n private contentFormatters: Record any> = {\r\n [ContentType.Json]: (input: any) =>\r\n input !== null && (typeof input === \"object\" || typeof input === \"string\")\r\n ? JSON.stringify(input)\r\n : input,\r\n [ContentType.FormData]: (input: any) =>\r\n Object.keys(input || {}).reduce((formData, key) => {\r\n const property = input[key];\r\n formData.append(\r\n key,\r\n property instanceof Blob\r\n ? property\r\n : typeof property === \"object\" && property !== null\r\n ? JSON.stringify(property)\r\n : `${property}`\r\n );\r\n return formData;\r\n }, new FormData()),\r\n [ContentType.UrlEncoded]: (input: any) => this.toQueryString(input),\r\n };\r\n\r\n private mergeRequestParams(\r\n params1: RequestParams,\r\n params2?: RequestParams\r\n ): RequestParams {\r\n return {\r\n ...this.baseApiParams,\r\n ...params1,\r\n ...(params2 || {}),\r\n headers: {\r\n ...(this.baseApiParams.headers || {}),\r\n ...(params1.headers || {}),\r\n ...((params2 && params2.headers) || {}),\r\n },\r\n };\r\n }\r\n\r\n private createAbortSignal = (\r\n cancelToken: CancelToken\r\n ): AbortSignal | undefined => {\r\n if (this.abortControllers.has(cancelToken)) {\r\n const abortController = this.abortControllers.get(cancelToken);\r\n if (abortController) {\r\n return abortController.signal;\r\n }\r\n return void 0;\r\n }\r\n\r\n const abortController = new AbortController();\r\n this.abortControllers.set(cancelToken, abortController);\r\n return abortController.signal;\r\n };\r\n\r\n public abortRequest = (cancelToken: CancelToken) => {\r\n const abortController = this.abortControllers.get(cancelToken);\r\n\r\n if (abortController) {\r\n abortController.abort();\r\n this.abortControllers.delete(cancelToken);\r\n }\r\n };\r\n\r\n public request = async ({\r\n body,\r\n secure,\r\n path,\r\n type,\r\n query,\r\n format,\r\n baseUrl,\r\n cancelToken,\r\n ...params\r\n }: FullRequestParams): Promise> => {\r\n const secureParams =\r\n ((typeof secure === \"boolean\" ? secure : this.baseApiParams.secure) &&\r\n this.securityWorker &&\r\n (await this.securityWorker(this.securityData))) ||\r\n {};\r\n const requestParams = this.mergeRequestParams(params, secureParams);\r\n const queryString = query && this.toQueryString(query);\r\n const payloadFormatter = this.contentFormatters[type || ContentType.Json];\r\n const responseFormat = format || requestParams.format;\r\n\r\n return this.customFetch(\r\n `${baseUrl || this.baseUrl || \"\"}${path}${\r\n queryString ? `?${queryString}` : \"\"\r\n }`,\r\n {\r\n ...requestParams,\r\n headers: {\r\n ...(type && type !== ContentType.FormData\r\n ? { \"Content-Type\": type }\r\n : {}),\r\n ...(requestParams.headers || {}),\r\n },\r\n signal: cancelToken ? this.createAbortSignal(cancelToken) : void 0,\r\n body:\r\n typeof body === \"undefined\" || body === null\r\n ? null\r\n : payloadFormatter(body),\r\n }\r\n ).then(async (response) => {\r\n const r = response as HttpResponse;\r\n r.data = null as unknown as T;\r\n r.error = null as unknown as E;\r\n\r\n const data = !responseFormat\r\n ? r\r\n : await response[responseFormat]()\r\n .then((data) => {\r\n if (r.ok) {\r\n r.data = data;\r\n } else {\r\n r.error = data;\r\n }\r\n return r;\r\n })\r\n .catch((e) => {\r\n r.error = e;\r\n return r;\r\n });\r\n\r\n if (cancelToken) {\r\n this.abortControllers.delete(cancelToken);\r\n }\r\n\r\n if (!response.ok) throw data;\r\n return data;\r\n });\r\n };\r\n}\r\n\r\n/**\r\n * @title Catalog Services v1\r\n * @version v1\r\n */\r\nexport class Api<\r\n SecurityDataType extends unknown\r\n> extends HttpClient {\r\n api = {\r\n /**\r\n * No description\r\n *\r\n * @tags Captcha\r\n * @name V1CaptchaCreate\r\n * @summary Return a captcha challenge.\r\n * @request POST:/api/v1/Captcha\r\n * @secure\r\n */\r\n v1CaptchaCreate: (data: CaptchaCreateDTO, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Captcha`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryList\r\n * @summary Return all industries.\r\n * @request GET:/api/v1/Industry\r\n * @secure\r\n */\r\n v1IndustryList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Industry/current`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n v1IndustryAllList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Industry`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryCreate\r\n * @summary Create the industry.\r\n * @request POST:/api/v1/Industry\r\n * @secure\r\n */\r\n v1IndustryCreate: (data: IndustryCreateDTO, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Industry`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryDetail\r\n * @summary Return industry.\r\n * @request GET:/api/v1/Industry/{industryId}\r\n * @secure\r\n */\r\n v1IndustryDetail: (industryId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Industry/${industryId}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryCreate2\r\n * @summary Create the sub industry.\r\n * @request POST:/api/v1/Industry/{industryId}\r\n * @originalName v1IndustryCreate\r\n * @duplicate\r\n * @secure\r\n */\r\n v1IndustryCreate2: (\r\n industryId: string,\r\n data: SubIndustryCreateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Industry/${industryId}`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryUpdate\r\n * @summary Update the industry.\r\n * @request PUT:/api/v1/Industry/{industryId}\r\n * @secure\r\n */\r\n v1IndustryUpdate: (\r\n industryId: string,\r\n data: IndustryUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Industry/${industryId}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryDelete\r\n * @summary Delete the industry.\r\n * @request DELETE:/api/v1/Industry/{industryId}\r\n * @secure\r\n */\r\n v1IndustryDelete: (industryId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Industry/${industryId}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryDetail2\r\n * @summary Return sub industry.\r\n * @request GET:/api/v1/Industry/{industryId}/{subIndustryId}\r\n * @originalName v1IndustryDetail\r\n * @duplicate\r\n * @secure\r\n */\r\n v1IndustryDetail2: (\r\n industryId: string,\r\n subIndustryId: string,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Industry/${industryId}/${subIndustryId}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryUpdate2\r\n * @summary Update the sub industry.\r\n * @request PUT:/api/v1/Industry/{industryId}/{subIndustryId}\r\n * @originalName v1IndustryUpdate\r\n * @duplicate\r\n * @secure\r\n */\r\n v1IndustryUpdate2: (\r\n industryId: string,\r\n subIndustryId: string,\r\n data: SubIndustryUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Industry/${industryId}/${subIndustryId}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Industry\r\n * @name V1IndustryDelete2\r\n * @summary Delete the sub industry.\r\n * @request DELETE:/api/v1/Industry/{industryId}/{subIndustryId}\r\n * @originalName v1IndustryDelete\r\n * @duplicate\r\n * @secure\r\n */\r\n v1IndustryDelete2: (\r\n industryId: string,\r\n subIndustryId: string,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Industry/${industryId}/${subIndustryId}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Lifecycle\r\n * @name V1LifecycleList\r\n * @summary Return all lifecycles.\r\n * @request GET:/api/v1/Lifecycle\r\n * @secure\r\n */\r\n v1LifecycleList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Lifecycle/current`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n v1LifecycleAllList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Lifecycle`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Lifecycle\r\n * @name V1LifecycleCreate\r\n * @summary ´Create the lifecycle.\r\n * @request POST:/api/v1/Lifecycle\r\n * @secure\r\n */\r\n v1LifecycleCreate: (data: LifecycleCreateDTO, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Lifecycle`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Lifecycle\r\n * @name V1LifecycleDetail\r\n * @summary Return lifecycle.\r\n * @request GET:/api/v1/Lifecycle/{lifecycleId}\r\n * @secure\r\n */\r\n v1LifecycleDetail: (lifecycleId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Lifecycle/${lifecycleId}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Lifecycle\r\n * @name V1LifecycleUpdate\r\n * @summary Update the lifecycle.\r\n * @request PUT:/api/v1/Lifecycle/{lifecycleId}\r\n * @secure\r\n */\r\n v1LifecycleUpdate: (\r\n lifecycleId: string,\r\n data: LifecycleUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Lifecycle/${lifecycleId}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Lifecycle\r\n * @name V1LifecycleDelete\r\n * @summary Delete the lifecycle.\r\n * @request DELETE:/api/v1/Lifecycle/{lifecycleId}\r\n * @secure\r\n */\r\n v1LifecycleDelete: (lifecycleId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Lifecycle/${lifecycleId}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Lifecycle\r\n * @name V1LifecycleOrderUpdate\r\n * @summary Update the lifecycle order.\r\n * @request PUT:/api/v1/Lifecycle/{lifecycleId}/order/{order}\r\n * @secure\r\n */\r\n v1LifecycleOrderUpdate: (\r\n lifecycleId: string,\r\n order: number,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Lifecycle/${lifecycleId}/order/${order}`,\r\n method: \"PUT\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Page\r\n * @name V1PageList\r\n * @summary Return main page.\r\n * @request GET:/api/v1/Page\r\n * @secure\r\n */\r\n v1PageList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Page`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Page\r\n * @name V1PageFieldsUpdate\r\n * @summary Update main page.\r\n * @request PUT:/api/v1/Page/fields\r\n * @secure\r\n */\r\n v1PageFieldsUpdate: (\r\n data: PageFieldsUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Page/fields`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Page\r\n * @name V1PageOptionsUpdate\r\n * @summary Update main page.\r\n * @request PUT:/api/v1/Page/options\r\n * @secure\r\n */\r\n v1PageOptionsUpdate: (\r\n data: PageOptionsUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Page/options`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceDetail\r\n * @summary Return the specified service.\r\n * @request GET:/api/v1/Service/{id}\r\n * @secure\r\n */\r\n v1ServiceDetail: (id: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/${id}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceDetail\r\n * @summary Return the specified service.\r\n * @request GET:/api/v1/Service/{id}\r\n * @secure\r\n */\r\n v1ServiceDetailFriendly: (url: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/friendly/${url}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceUpdate\r\n * @summary Update the specified service.\r\n * @request PUT:/api/v1/Service/{id}\r\n * @secure\r\n */\r\n v1ServiceUpdate: (\r\n id: string,\r\n data: {\r\n TeamPpids?: string[];\r\n ResponsiblesPpids?: string[];\r\n Organizations?: string[];\r\n ViewersPpids?: string[];\r\n UkViewersPpids?: string[];\r\n FrViewersPpids?: string[];\r\n Applications?: ApplicationCreateDTO[];\r\n Industries?: string[];\r\n IllustrationsToAdd?: File[];\r\n IllustrationsToRemove?: string[];\r\n RelatedServices?: string[];\r\n Name?: string;\r\n Description?: string;\r\n VideoLink?: string;\r\n ItContactPpid?: string;\r\n Live?: boolean;\r\n IsHighlighted?: boolean;\r\n IsNew?: boolean;\r\n LifeCycles?: string;\r\n ValueChains?: string;\r\n SmallDescription?: string;\r\n GeographicalInformation?: string;\r\n TargetProfile?: string;\r\n AvailableApplication?: string;\r\n Deliverable?: string;\r\n MainAddedValue?: string;\r\n SecondaryAddedValue?: string;\r\n ServiceGroupId?: string;\r\n },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service/${id}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceDelete\r\n * @summary Delete the specified service.\r\n * @request DELETE:/api/v1/Service/{id}\r\n * @secure\r\n */\r\n v1ServiceDelete: (id: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/${id}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceList\r\n * @summary Return all services.\r\n * @request GET:/api/v1/Service\r\n * @secure\r\n */\r\n v1ServiceList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceCreate\r\n * @summary Create a new service.\r\n * @request POST:/api/v1/Service\r\n * @secure\r\n */\r\n v1ServiceCreate: (\r\n data: {\r\n TeamPpids?: string[];\r\n ResponsiblesPpids?: string[];\r\n ViewersPpids?: string[];\r\n UkViewersPpids?: string[];\r\n FrViewersPpids?: string[];\r\n Organizations?: string[];\r\n Applications?: ApplicationCreateDTO[];\r\n Industries?: string[];\r\n RelatedServices?: string[];\r\n Illustrations?: File[];\r\n Name?: string;\r\n Description?: string;\r\n VideoLink?: string;\r\n ItContactPpid?: string;\r\n Live?: boolean;\r\n IsHighlighted?: boolean;\r\n IsNew?: boolean;\r\n LifeCycles?: string;\r\n ValueChain?: string;\r\n SmallDescription?: string;\r\n GeographicalInformation?: string;\r\n TargetProfile?: string;\r\n AvailableApplication?: string;\r\n Deliverable?: string;\r\n MainAddedValue?: string;\r\n SecondaryAddedValue?: string;\r\n ServiceGroupId?: string;\r\n },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceLiveList\r\n * @summary Return all services with live property set to true.\r\n * @request GET:/api/v1/Service/live\r\n * @secure\r\n */\r\n v1ServiceLiveList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/live`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceDetail2\r\n * @summary Get a service illustration.\r\n * @request GET:/api/v1/Service/{serviceId}/{illustrationId}\r\n * @originalName v1ServiceDetail\r\n * @duplicate\r\n * @secure\r\n */\r\n v1ServiceDetail2: (\r\n serviceId: string,\r\n illustrationId: string,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service/${serviceId}/${illustrationId}`,\r\n method: \"GET\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceLivePartialUpdate\r\n * @summary Update the specified service live value.\r\n * @request PATCH:/api/v1/Service/{id}/live\r\n * @secure\r\n */\r\n v1ServiceLivePartialUpdate: (\r\n id: string,\r\n query?: { live?: boolean },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service/${id}/live`,\r\n method: \"PATCH\",\r\n query: query,\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceNewPartialUpdate\r\n * @summary Update the specified service new value.\r\n * @request PATCH:/api/v1/Service/{id}/new\r\n * @secure\r\n */\r\n v1ServiceNewPartialUpdate: (\r\n id: string,\r\n query?: { isNew?: boolean },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service/${id}/new`,\r\n method: \"PATCH\",\r\n query: query,\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceHighlightedPartialUpdate\r\n * @summary Update the specified service highlight value.\r\n * @request PATCH:/api/v1/Service/{id}/highlighted\r\n * @secure\r\n */\r\n v1ServiceHighlightedPartialUpdate: (\r\n id: string,\r\n query?: { isHighlighted?: boolean },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service/${id}/highlighted`,\r\n method: \"PATCH\",\r\n query: query,\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceImportList\r\n * @summary Download the template for the import.\r\n * @request GET:/api/v1/Service/import\r\n * @secure\r\n */\r\n v1ServiceImportList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/import`,\r\n method: \"GET\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceImportCreate\r\n * @summary Import services from Excel file.\r\n * @request POST:/api/v1/Service/import\r\n * @secure\r\n */\r\n v1ServiceImportCreate: (\r\n data: { importFile?: File },\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service/import`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.FormData,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceExportExcelCreate\r\n * @summary Export services.\r\n * @request POST:/api/v1/Service/export/excel\r\n * @secure\r\n */\r\n v1ServiceExportExcelCreate: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/export/excel`,\r\n method: \"POST\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceContactCreate\r\n * @summary Send a message to the contacts of a service.\r\n * @request POST:/api/v1/Service/{serviceId}/contact\r\n * @secure\r\n */\r\n v1ServiceContactCreate: (\r\n serviceId: string,\r\n data: ServiceContactDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/Service/${serviceId}/contact`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ServiceGroup\r\n * @name V1ServiceGroupList\r\n * @summary Return all service Group.\r\n * @request GET:/api/v1/ServiceGroup\r\n * @secure\r\n */\r\n v1ServiceGroupList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/ServiceGroup`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n v1TerritoriesList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Territory`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n v1TerritoryGet: (id: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Territory/${id}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n v1TerritoryCreate: (data: any, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Territory`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n v1TerritoryUpdate: (id: string, data: any, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Territory/${id}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n v1TerritoryDelete: (id: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Territory/${id}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Service\r\n * @name V1ServiceByidsCreate\r\n * @request POST:/api/v1/Service/byids\r\n * @secure\r\n */\r\n v1ServiceByidsCreate: (data: string[], params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Service/byids`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ServiceGroup\r\n * @name V1ServiceGroupCreate\r\n * @summary Create a new service group.\r\n * @request POST:/api/v1/ServiceGroup\r\n * @secure\r\n */\r\n v1ServiceGroupCreate: (\r\n data: ServiceGroupCreateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/ServiceGroup`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ServiceGroup\r\n * @name V1ServiceGroupDetail\r\n * @summary Return the specified service Group.\r\n * @request GET:/api/v1/ServiceGroup/{id}\r\n * @secure\r\n */\r\n v1ServiceGroupDetail: (id: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/ServiceGroup/${id}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ServiceGroup\r\n * @name V1ServiceGroupUpdate\r\n * @summary Update a specified service group.\r\n * @request PUT:/api/v1/ServiceGroup/{id}\r\n * @secure\r\n */\r\n v1ServiceGroupUpdate: (\r\n id: string,\r\n data: ServiceGroupUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/ServiceGroup/${id}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ServiceGroup\r\n * @name V1ServiceGroupDelete\r\n * @summary Update a specified service group.\r\n * @request DELETE:/api/v1/ServiceGroup/{id}\r\n * @secure\r\n */\r\n v1ServiceGroupDelete: (id: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/ServiceGroup/${id}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ValueChain\r\n * @name V1ValueChainList\r\n * @summary Return all valueChains.\r\n * @request GET:/api/v1/ValueChain\r\n * @secure\r\n */\r\n v1ValueChainList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/ValueChain/current`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n v1ValueChainAllList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/ValueChain`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ValueChain\r\n * @name V1ValueChainCreate\r\n * @summary ´Create the valueChain.\r\n * @request POST:/api/v1/ValueChain\r\n * @secure\r\n */\r\n v1ValueChainCreate: (\r\n data: ValueChainCreateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/ValueChain`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ValueChain\r\n * @name V1ValueChainDetail\r\n * @summary Return valueChain.\r\n * @request GET:/api/v1/ValueChain/{valueChainId}\r\n * @secure\r\n */\r\n v1ValueChainDetail: (valueChainId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/ValueChain/${valueChainId}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ValueChain\r\n * @name V1ValueChainUpdate\r\n * @summary Update the valueChain.\r\n * @request PUT:/api/v1/ValueChain/{valueChainId}\r\n * @secure\r\n */\r\n v1ValueChainUpdate: (\r\n valueChainId: string,\r\n data: ValueChainUpdateDTO,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/ValueChain/${valueChainId}`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ValueChain\r\n * @name V1ValueChainDelete\r\n * @summary Delete the valueChain.\r\n * @request DELETE:/api/v1/ValueChain/{valueChainId}\r\n * @secure\r\n */\r\n v1ValueChainDelete: (valueChainId: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/ValueChain/${valueChainId}`,\r\n method: \"DELETE\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags ValueChain\r\n * @name V1ValueChainOrderUpdate\r\n * @summary Update the valueChain order.\r\n * @request PUT:/api/v1/ValueChain/{valueChainId}/order/{order}\r\n * @secure\r\n */\r\n v1ValueChainOrderUpdate: (\r\n valueChainId: string,\r\n order: number,\r\n params: RequestParams = {}\r\n ) =>\r\n this.request({\r\n path: `/api/v1/ValueChain/${valueChainId}/order/${order}`,\r\n method: \"PUT\",\r\n secure: true,\r\n ...params,\r\n }),\r\n };\r\n}\r\n","import {\r\n apiFetchFormDataCustom,\r\n appendIEHeaders,\r\n appendTokenHeaders,\r\n} from \"api/api\";\r\nimport {\r\n Api,\r\n CaptchaReadDTO,\r\n IndustryCreateDTO,\r\n IndustryReadDTO,\r\n IndustryUpdateDTO,\r\n LifecycleCreateDTO,\r\n LifecycleReadDTO,\r\n LifecycleUpdateDTO,\r\n PageFieldsUpdateDTO,\r\n PageOptionsUpdateDTO,\r\n PageReadDTO,\r\n ServiceContactDTO,\r\n ServiceGroupCreateDTO,\r\n ServiceGroupReadDTO,\r\n ServiceGroupReadListDTO,\r\n ServiceGroupUpdateDTO,\r\n ServiceReadDTO,\r\n SubIndustryCreateDTO,\r\n SubIndustryReadDTO,\r\n SubIndustryUpdateDTO,\r\n ValueChainCreateDTO,\r\n ValueChainReadDTO,\r\n ValueChainUpdateDTO,\r\n} from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { HttpResponse } from \"api/notification/__generated__/NotificationAPI\";\r\n\r\nimport { ServiceCreateDTO } from \"./type\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_CATALOG;\r\n\r\nlet _clientSingleton: Api | null = null;\r\nconst client = (): Api => {\r\n if (!_clientSingleton) {\r\n _clientSingleton = new Api({\r\n baseUrl: PREFIX,\r\n baseApiParams: {\r\n headers: {\r\n Accept: \"application/json\",\r\n ...appendTokenHeaders(),\r\n ...appendIEHeaders(),\r\n },\r\n },\r\n });\r\n }\r\n return _clientSingleton;\r\n};\r\n\r\nfunction toData(res: { data: T }) {\r\n return res.data;\r\n}\r\n\r\nexport function getServiceDetails(serviceId: string): Promise {\r\n if (\r\n serviceId.match(\r\n /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i\r\n ) !== null\r\n ) {\r\n return client().api.v1ServiceDetail(serviceId).then(toData);\r\n }\r\n return client().api.v1ServiceDetailFriendly(serviceId).then(toData);\r\n}\r\n\r\nexport function createService(\r\n service: ServiceCreateDTO\r\n): Promise {\r\n // we don't use the generated api file here because FormData serialization for Array is incompatible with our .Net backend\r\n return apiFetchFormDataCustom(\r\n `${PREFIX}/api/v1/Service`,\r\n service,\r\n \"POST\"\r\n ) as Promise;\r\n // return client().api.v1ServiceCreate(service).then(toData);\r\n}\r\n\r\nexport function updateService(\r\n service: ServiceCreateDTO,\r\n id: string\r\n): Promise {\r\n // we don't use the generated api file here because FormData serialization for Array is incompatible with our .Net backend\r\n return apiFetchFormDataCustom(\r\n `${PREFIX}/api/v1/Service/${id}`,\r\n service,\r\n \"PUT\"\r\n ).then(toData) as Promise;\r\n // return client().api.v1ServiceUpdate(id, service).then(toData);\r\n}\r\n\r\nexport function removeService(id: string): Promise {\r\n return client().api.v1ServiceDelete(id).then(toData);\r\n}\r\n\r\nexport function updateDisplayStatus(id: string, live: boolean): Promise {\r\n return client().api.v1ServiceLivePartialUpdate(id, { live }).then(toData);\r\n}\r\n\r\nexport function updateIsNew(id: string, isNew: boolean): Promise {\r\n return client().api.v1ServiceNewPartialUpdate(id, { isNew }).then(toData);\r\n}\r\n\r\nexport function updateIsHighlighted(\r\n id: string,\r\n isHighlighted: boolean\r\n): Promise {\r\n return client()\r\n .api.v1ServiceHighlightedPartialUpdate(id, { isHighlighted })\r\n .then(toData);\r\n}\r\n\r\nexport function getCatalogue(): Promise {\r\n return client().api.v1ServiceLiveList().then(toData);\r\n}\r\n\r\nexport function getCatalogueServiceDetails(\r\n serviceId: string\r\n): Promise {\r\n return getServiceDetails(serviceId); // TODO discuss with back-end : should we accept another DTO for client-view ?\r\n}\r\n\r\nexport function getCatalogueHomepageDetails(): Promise {\r\n return client().api.v1PageList().then(toData);\r\n}\r\n\r\nexport function updateCatalogueHomepageDetails(\r\n homepage: PageFieldsUpdateDTO\r\n): Promise {\r\n return client().api.v1PageFieldsUpdate(homepage).then(toData);\r\n}\r\n\r\nexport function updateCatalogueOptions(\r\n homepage: PageOptionsUpdateDTO\r\n): Promise {\r\n return client().api.v1PageOptionsUpdate(homepage).then(toData);\r\n}\r\n\r\nexport function getCaptcha(serviceId: string): Promise {\r\n return client().api.v1CaptchaCreate({ resourceId: serviceId }).then(toData);\r\n}\r\n\r\nexport function sendContactForm(\r\n serviceId: string,\r\n form: ServiceContactDTO\r\n): Promise> {\r\n return client().api.v1ServiceContactCreate(serviceId, form);\r\n}\r\n\r\nexport function getLifeCycles() {\r\n return client().api.v1LifecycleList().then(toData);\r\n}\r\nexport function getLifeCyclesAll() {\r\n return client().api.v1LifecycleAllList().then(toData);\r\n}\r\nexport function addLifeCycle(\r\n lifeCycle: LifecycleCreateDTO\r\n): Promise {\r\n return client().api.v1LifecycleCreate(lifeCycle).then(toData);\r\n}\r\n\r\nexport function deleteLifeCycle(id: string) {\r\n return client().api.v1LifecycleDelete(id);\r\n}\r\n\r\nexport function editLifeCycle(id: string, lifeCycle: LifecycleUpdateDTO) {\r\n return client().api.v1LifecycleUpdate(id, lifeCycle);\r\n}\r\n\r\nexport function editLifeCycleOrder(id: string, order: number) {\r\n return client().api.v1LifecycleOrderUpdate(id, order);\r\n}\r\n\r\nexport function getLifeCycleById(id: string): Promise {\r\n return client().api.v1LifecycleDetail(id).then(toData);\r\n}\r\n\r\nexport function getIndustries() {\r\n return client().api.v1IndustryList().then(toData);\r\n}\r\n\r\nexport function getIndustriesAll() {\r\n return client().api.v1IndustryAllList().then(toData);\r\n}\r\n\r\nexport function getIndustryById(id: string): Promise {\r\n return client().api.v1IndustryDetail(id).then(toData);\r\n}\r\n\r\nexport function getSubIndustryById(\r\n parentId: string,\r\n id: string\r\n): Promise {\r\n return client().api.v1IndustryDetail2(parentId, id).then(toData);\r\n}\r\n\r\nexport function addIndustry(\r\n industry: IndustryCreateDTO\r\n): Promise {\r\n return client().api.v1IndustryCreate(industry).then(toData);\r\n}\r\n\r\nexport function addSubIndustry(\r\n parentId: string,\r\n industry: SubIndustryCreateDTO\r\n): Promise {\r\n return client().api.v1IndustryCreate2(parentId, industry).then(toData);\r\n}\r\n\r\nexport function deleteIndustry(id: string) {\r\n return client().api.v1IndustryDelete(id);\r\n}\r\n\r\nexport function deleteSubIndustry(parentId: string, id: string) {\r\n return client().api.v1IndustryDelete2(parentId, id);\r\n}\r\n\r\nexport function editIndustry(id: string, industry: IndustryUpdateDTO) {\r\n return client().api.v1IndustryUpdate(id, industry);\r\n}\r\n\r\nexport function editSubIndustry(\r\n parentId: string,\r\n id: string,\r\n industry: SubIndustryUpdateDTO\r\n) {\r\n return client().api.v1IndustryUpdate2(parentId, id, industry);\r\n}\r\n\r\nexport function getValueChains() {\r\n return client().api.v1ValueChainList().then(toData);\r\n}\r\nexport function getValueChainsAll() {\r\n return client().api.v1ValueChainAllList().then(toData);\r\n}\r\n\r\nexport function addValueChain(\r\n valueChain: ValueChainCreateDTO\r\n): Promise {\r\n return client().api.v1ValueChainCreate(valueChain).then(toData);\r\n}\r\n\r\nexport function deleteValueChain(id: string) {\r\n return client().api.v1ValueChainDelete(id);\r\n}\r\n\r\nexport function editValueChain(id: string, valueChain: ValueChainUpdateDTO) {\r\n return client().api.v1ValueChainUpdate(id, valueChain);\r\n}\r\n\r\nexport function editValueChainOrder(id: string, order: number): Promise {\r\n return client().api.v1ValueChainOrderUpdate(id, order);\r\n}\r\n\r\nexport function getValueChainById(id: string): Promise {\r\n return client().api.v1ValueChainDetail(id).then(toData);\r\n}\r\n\r\nexport function getServiceGroups(): Promise {\r\n return client().api.v1ServiceGroupList().then(toData);\r\n}\r\n\r\nexport function getTerritories(): Promise {\r\n return client().api.v1TerritoriesList().then(toData);\r\n}\r\n\r\nexport function addServiceGroup(\r\n serviceGroup: ServiceGroupCreateDTO\r\n): Promise {\r\n return client().api.v1ServiceGroupCreate(serviceGroup).then(toData);\r\n}\r\n\r\nexport function editServiceGroup(\r\n id: string,\r\n serviceGroup: ServiceGroupUpdateDTO\r\n): Promise {\r\n return client().api.v1ServiceGroupUpdate(id, serviceGroup).then(toData);\r\n}\r\n\r\nexport function getServiceGroupById(id: string): Promise {\r\n return client().api.v1ServiceGroupDetail(id).then(toData);\r\n}\r\n\r\nexport function deleteServiceGroup(id: string) {\r\n return client().api.v1ServiceGroupDelete(id);\r\n}\r\n\r\nexport function addTerritory(territory: any): Promise {\r\n return client().api.v1TerritoryCreate(territory).then(toData);\r\n}\r\n\r\nexport function editTerritory(id: string, territory: any): Promise {\r\n return client().api.v1TerritoryUpdate(id, territory).then(toData);\r\n}\r\n\r\nexport function deleteTerritory(id: string) {\r\n return client().api.v1TerritoryDelete(id);\r\n}\r\n\r\nexport function getTerritoryById(id: string): Promise {\r\n return client().api.v1TerritoryGet(id).then(toData);\r\n}\r\n\r\nexport function getServiceByIds(ids: Array): Promise {\r\n return client().api.v1ServiceByidsCreate(ids).then(toData);\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport classNames from \"classnames\";\r\nimport { Link } from \"react-router-dom\";\r\n\r\nconst AppLink = ({\r\n children,\r\n className = undefined,\r\n external = false,\r\n transparent = true,\r\n ...otherProps\r\n}) => {\r\n const allClassNames = classNames(\r\n \"app-link\",\r\n transparent && \"transparent\",\r\n className\r\n );\r\n\r\n if (external) {\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n }\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport default AppLink;\r\n","import \"./index.scss\";\r\n\r\nimport classNames from \"classnames\";\r\nimport Skeleton from \"react-loading-skeleton\";\r\n\r\nconst CategoryPitch = ({\r\n title = \"\",\r\n image,\r\n className,\r\n rightChildren = null,\r\n children,\r\n marginBottomOffset = null,\r\n titleMarginBottom = null,\r\n}) => {\r\n return (\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n

\r\n {title === null ? : title}\r\n

\r\n
\r\n
\r\n {rightChildren}\r\n
\r\n
\r\n \r\n\r\n
\r\n {children}\r\n
\r\n \r\n );\r\n};\r\n\r\nexport default CategoryPitch;\r\n","import \"./index.scss\";\r\n\r\nimport { Switch } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\n\r\nconst SwitchWithLoader = ({\r\n loading,\r\n onText = \"On\",\r\n offText = \"Off\",\r\n ...props\r\n}) => {\r\n const className = classNames(\"a-toggle-with-loader\", props.className);\r\n if (loading) {\r\n const loader =
;\r\n return (\r\n \r\n );\r\n }\r\n return (\r\n \r\n );\r\n};\r\n\r\nexport default SwitchWithLoader;\r\n","import { UseTypedQueryOptions } from \"api/UseTypedQueryOptions\";\r\nimport { UseQueryResult, useQuery } from \"react-query\";\r\n\r\nimport { PageReadDTO } from \"../__generated__/CatalogueAPI\";\r\nimport { getCatalogueHomepageDetails } from \"../catalogApi\";\r\n\r\nexport default function useCatalogueHomepageDetails(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\r\n \"catalogue/homepage\",\r\n () => getCatalogueHomepageDetails(),\r\n props\r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport TermsAndConditionsModal from \"components/Footer/TermsAndConditionsModal\";\r\nimport { useState } from \"react\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nconst Footer = () => {\r\n const [termsAndConditionsOpened, setTermsAndConditionsOpened] = useState(\r\n false\r\n );\r\n\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n return (\r\n
\r\n setTermsAndConditionsOpened(false)}\r\n />\r\n
\r\n
\r\n © {new Date().getFullYear()} PwC. PwC refers to the PwC network and/or\r\n one or more of its member firms, each of which is a separate legal\r\n entity. Please see{\" \"}\r\n \r\n www.pwc.com/structure\r\n {\" \"}\r\n for further details.\r\n
\r\n
\r\n \r\n Privacy\r\n \r\n setTermsAndConditionsOpened(true)}>\r\n Terms and Conditions\r\n \r\n
\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default Footer;\r\n","const decodeJWT = (token) => {\r\n return JSON.parse(atob(token.split(\".\")[1]));\r\n};\r\n\r\nexport default decodeJWT;\r\n","import { AuthenticationContext } from \"@axa-fr/react-oidc-context\";\r\nimport { getMyProfile } from \"api/admin/adminApi\";\r\nimport { pollCheckCreatingUser } from \"api/admin/adminPoller\";\r\nimport { useEffect } from \"react\";\r\nimport { useDispatch } from \"react-redux\";\r\nimport { useHistory, withRouter } from \"react-router\";\r\nimport {\r\n globalInitialize,\r\n setLoginUserNotFound,\r\n setSessionExpired,\r\n upsertLoginUser,\r\n} from \"redux/actions/global\";\r\nimport decodeJWT from \"utils/decodeJWT\";\r\n\r\nconst TokenManager = ({ oidcProps }) => {\r\n const dispatch = useDispatch();\r\n const history = useHistory();\r\n\r\n const token = oidcProps?.oidcUser?.access_token;\r\n useEffect(() => {\r\n if (token) {\r\n getMyProfile()\r\n .catch((error) => {\r\n // Back is creating user\r\n // We wait for creation is done (using long-polling)\r\n if (error.status === 418) {\r\n const decoded = decodeJWT(token);\r\n const ppid = decoded[process.env.REACT_APP_ID_CLAIM];\r\n\r\n const currentLocation = history.location;\r\n history.replace(\"/creatingUser\");\r\n return pollCheckCreatingUser(ppid).then((user) => {\r\n history.replace(currentLocation);\r\n return user;\r\n });\r\n } else if (error.status === 401) {\r\n dispatch(setSessionExpired());\r\n throw new Error(\"Session expired error\");\r\n } else {\r\n dispatch(setLoginUserNotFound());\r\n throw new Error(\"Global init no user error\");\r\n }\r\n })\r\n .then((user) => {\r\n dispatch(upsertLoginUser(user));\r\n dispatch(globalInitialize());\r\n });\r\n }\r\n }, [token, dispatch, history]);\r\n\r\n return null;\r\n};\r\nconst LoginManager = ({ children }) => {\r\n return (\r\n \r\n {(oidcProps) => (\r\n {children}\r\n )}\r\n \r\n );\r\n};\r\n\r\nexport default withRouter(LoginManager);\r\n","export default __webpack_public_path__ + \"static/media/Icons-Outline-Globe-White.b0b6ecb7.svg\";","import \"./index.scss\";\r\n\r\nimport {\r\n MODULES,\r\n MODULE_VALUES,\r\n NEWS_MODULE_IS_ENABLED,\r\n} from \"constants/module\";\r\nimport { findCurrentModuleKey } from \"constants/module\";\r\n\r\nimport { List, ListItem } from \"appkit-react\";\r\nimport KeyCode from \"appkit-react-utils/keyCode\";\r\nimport classNames from \"classnames\";\r\nimport GlobeIconOutline from \"img/icones/Icons-Outline-Globe-White.svg\";\r\nimport NewsIconFill from \"img/icones/icons-outline-start-tour-fill.svg\";\r\nimport NewsIconOutline from \"img/icones/icons-outline-start-tour.svg\";\r\nimport useUserServices from \"pages/myServices/hooks/useUserServices\";\r\nimport { PureComponent } from \"react\";\r\nimport { connect } from \"react-redux\";\r\nimport { withRouter } from \"react-router\";\r\n\r\nimport AppLink from \"../AppLink\";\r\n\r\nlet outlineAction = {\r\n NOACTION: 0,\r\n CLICK: 1,\r\n CHANGE: 2,\r\n BLUR: 3,\r\n TAB: 4,\r\n};\r\n\r\nconst MODULE_MENUS = [\r\n MODULES.MYSERVICES,\r\n MODULES.MYCLIENTS,\r\n MODULES.CLIENT_VIEW,\r\n MODULES.CATALOGUE,\r\n MODULES.NEWS,\r\n];\r\n\r\nclass LeftNav extends PureComponent {\r\n constructor(props) {\r\n super(props);\r\n this.state = {\r\n hasOutLine: true,\r\n lastAction: outlineAction.CLICK,\r\n };\r\n const self = this;\r\n this.keyEvent = function (e) {\r\n if (e.keyCode === 9) {\r\n // Tab key\r\n self.setState({\r\n lastAction: outlineAction.BLUR,\r\n });\r\n }\r\n };\r\n }\r\n\r\n componentDidMount() {\r\n window.addEventListener(\"keydown\", this.keyEvent, false);\r\n }\r\n componentWillUnmount() {\r\n window.removeEventListener(\"keydown\", this.keyEvent, false);\r\n }\r\n\r\n handleKeyDown(evt) {\r\n if (evt.keyCode === KeyCode.ENTER) {\r\n const listItemNode = document.querySelector(\r\n \".a-left-navigation .a-list-item:focus\"\r\n );\r\n listItemNode.click();\r\n }\r\n }\r\n onMouseDown = () => {\r\n this.setState({\r\n hasOutLine: false,\r\n lastAction: outlineAction.CLICK,\r\n });\r\n };\r\n\r\n onBlur = () => {\r\n const { lastAction } = this.state;\r\n if (lastAction === outlineAction.CLICK) {\r\n this.setState({\r\n hasOutLine: false,\r\n lastAction: outlineAction.BLUR,\r\n });\r\n } else {\r\n this.setState({\r\n hasOutLine: true,\r\n lastAction: outlineAction.BLUR,\r\n });\r\n }\r\n };\r\n render() {\r\n const userLogged = !!this.props.loginUser;\r\n let displayedModules = MODULE_MENUS.filter((menu) => {\r\n return userLogged || !MODULE_VALUES[menu].requireConnexion;\r\n })\r\n .filter(\r\n (menu) =>\r\n this.props.loginUser?.isInternal ||\r\n !MODULE_VALUES[menu].isInternalOnly\r\n )\r\n .filter((menu) => {\r\n // hide myServices (client) menu enty if no userUservices are available (only for external user)\r\n return menu === \"/myServices\" && !this.props.loginUser?.isInternal\r\n ? !!this.props.userServices?.length\r\n : true;\r\n });\r\n\r\n if (process.env.REACT_APP_HIDE_MODULES_NON_LUX === \"1\") {\r\n displayedModules = displayedModules.filter(\r\n (menu) => this.props.loginUser?.isLu || !MODULE_VALUES[menu].isLuxOnly\r\n );\r\n }\r\n\r\n if (displayedModules.length <= 1) {\r\n return null;\r\n }\r\n\r\n if (!NEWS_MODULE_IS_ENABLED) {\r\n displayedModules = displayedModules.filter(\r\n (module) => module !== MODULES.NEWS\r\n );\r\n }\r\n\r\n const selectedMenu = findCurrentModuleKey(this.props.location.pathname);\r\n\r\n return (\r\n
\r\n \r\n <>\r\n {displayedModules.map((rootPath) => {\r\n const listitemClasses = classNames(\"a-nav-menu-item\", {\r\n active: selectedMenu && selectedMenu === rootPath,\r\n });\r\n const item = MODULE_VALUES[rootPath];\r\n\r\n return (\r\n \r\n \r\n {item.icon ? (\r\n \r\n ) : (\r\n \r\n )}\r\n {item.label}\r\n \r\n \r\n );\r\n })}\r\n \r\n <>\r\n {this.props.userServices\r\n ?.filter((service) =>\r\n service?.links?.some((link) => link?.showToClient === true)\r\n )\r\n .map((service) => {\r\n return service.links\r\n .filter((link) => link.showToClient)\r\n .map((link) => (\r\n \r\n \r\n \r\n {link.name}\r\n \r\n \r\n ));\r\n })}\r\n \r\n <>\r\n {process.env.REACT_APP_ENABLE_ECS_MENU_ITEM === \"true\" && (\r\n \r\n \r\n \r\n ECS\r\n \r\n \r\n )}\r\n \r\n \r\n
\r\n );\r\n }\r\n}\r\n\r\nconst mapStateToProps = (state) => {\r\n return {\r\n loginUser: state.global.data.loginUser,\r\n };\r\n};\r\n\r\nfunction withUserServices(Component) {\r\n return function WrappedComponent(props) {\r\n const userServices = useUserServices();\r\n return ;\r\n };\r\n}\r\n\r\nexport default withRouter(withUserServices(connect(mapStateToProps)(LeftNav)));\r\n","import { getFile } from \"api/data\";\r\nimport { getPublication } from \"api/news/publicationsApi\";\r\nimport { useEffect } from \"react\";\r\nimport { downloadFromResponse } from \"utils\";\r\n\r\nconst Downloader = ({ publicationId }) => {\r\n useEffect(() => {\r\n if (publicationId) {\r\n getPublication(publicationId).then((publication) => {\r\n return getFile(publication.fileUrl).then((data) => {\r\n downloadFromResponse(data, publication.title);\r\n });\r\n });\r\n }\r\n }, [publicationId]);\r\n\r\n return null;\r\n};\r\n\r\nexport default Downloader;\r\n","import \"./NewsletterExport.scss\";\r\n\r\nimport { exportAllToExcel, exportAllToWord } from \"api/news/exportNewsApi\";\r\nimport FullPageLoader from \"components/FullPageLoader\";\r\nimport UnexpectedError from \"pages/error/UnexpectedError\";\r\nimport { defaultFilename } from \"pages/news/helpers/filename\";\r\nimport useQueryParams from \"pages/news/hooks/useQueryParams\";\r\nimport { useEffect, useState } from \"react\";\r\nimport { downloadFromResponse } from \"utils\";\r\n\r\nexport default function NewsletterExport() {\r\n const [loading, setLoading] = useState(false);\r\n const [error, setError] = useState(null);\r\n let query = useQueryParams();\r\n useEffect(() => {\r\n const type = query.get(\"Type\");\r\n const publishDateStart = query.get(\"PublishDateStart\");\r\n const publishDateEnd = query.get(\"PublishDateEnd\");\r\n\r\n let call =\r\n type === \"Excel\"\r\n ? exportAllToExcel\r\n : type === \"Word\"\r\n ? exportAllToWord\r\n : null;\r\n if (type && call) {\r\n setLoading(true);\r\n call({\r\n published: true,\r\n publishedDateRange: { start: publishDateStart, end: publishDateEnd },\r\n })\r\n .then((data) =>\r\n downloadFromResponse(data, defaultFilename(type.toLocaleLowerCase()))\r\n )\r\n .finally(() => {\r\n setLoading(false);\r\n })\r\n .catch((err) => {\r\n setError(err);\r\n });\r\n }\r\n }, [query]);\r\n\r\n return loading ? (\r\n \r\n ) : error ? (\r\n \r\n ) : (\r\n
\r\n File has been downloaded. You can close this browser tab.\r\n
\r\n );\r\n}\r\n","import { useMemo } from \"react\";\r\nimport { useLocation } from \"react-router\";\r\n\r\nexport default function useQueryParams() {\r\n const { search } = useLocation();\r\n return useMemo(() => new URLSearchParams(search), [search]);\r\n}\r\n","export function scrollTo(domNodeRef, params) {\r\n if (!domNodeRef.scrollTo) {\r\n console.warn(\"browser doesn't support scrollTo\");\r\n return;\r\n }\r\n\r\n if (!(\"scrollBehavior\" in document.documentElement.style)) {\r\n domNodeRef.scrollTo(params.left || 0, params.top || 0); // Partial support : no smooth scroll\r\n return;\r\n }\r\n\r\n domNodeRef.scrollTo(params);\r\n}\r\n\r\nexport function scrollToBottom(domNodeRef, params = {}) {\r\n const scrollHeight = domNodeRef.scrollHeight;\r\n const height = domNodeRef.clientHeight;\r\n const top = scrollHeight - height;\r\n\r\n if (top > 0) {\r\n scrollTo(domNodeRef, {\r\n ...params,\r\n top,\r\n });\r\n }\r\n}\r\n","import { useContext, useEffect } from \"react\";\r\nimport { useHistory } from \"react-router-dom\";\r\n\r\nimport { ScrollContext } from \"../../App\";\r\nimport { scrollTo } from \"../../utils/scrollTo\";\r\n\r\nexport const useRedirectWithScrollSave = () => {\r\n const history = useHistory();\r\n const appRef = useContext(ScrollContext);\r\n\r\n return (path, state = {}) => {\r\n history.replace(history.location.pathname, {\r\n ...state,\r\n scrollTop: appRef.current.scrollTop,\r\n });\r\n history.push(path);\r\n };\r\n};\r\n\r\nconst RestoreScroll = ({ children }) => {\r\n const history = useHistory();\r\n const appRef = useContext(ScrollContext);\r\n\r\n useEffect(() => {\r\n const scrollRef = appRef.current;\r\n scrollTo(scrollRef, { top: history.location.state?.scrollTop || 0 });\r\n }, [appRef, history.location]);\r\n\r\n return <>{children};\r\n};\r\n\r\nexport default RestoreScroll;\r\n","import {\r\n MODULES,\r\n MODULE_VALUES,\r\n NEWS_MODULE_IS_ENABLED,\r\n} from \"constants/module\";\r\nimport { findCurrentModule } from \"constants/module\";\r\nimport { DOWNLOAD_PUBLICATION_BASEURL } from \"constants/routes\";\r\n\r\nimport { withOidcSecure } from \"@axa-fr/react-oidc-context\";\r\nimport IFramePage from \"components/IFramePage\";\r\nimport Downloader from \"pages/download\";\r\nimport NewsletterExport from \"pages/newsletter/NewsletterExport\";\r\nimport { Suspense, lazy, useEffect } from \"react\";\r\nimport { useSelector } from \"react-redux\";\r\nimport { Route, Switch } from \"react-router\";\r\nimport { INITIALIZE } from \"redux/constants\";\r\n\r\nimport RestoreScroll from \"./components/RestoreScroll\";\r\nimport SuspenseLoader from \"./components/SuspenseLoader\";\r\nimport { AdminWithInitializer } from \"./pages/admin\";\r\n\r\nconst Error404 = lazy(() => import(\"./pages/error/404\"));\r\nconst UnexpectedError = lazy(() => import(\"./pages/error/UnexpectedError\"));\r\nconst LogoutSuccess = lazy(() => import(\"./pages/logoutSuccess\"));\r\nconst ArticlesLandingPage = lazy(() => import(\"./pages/news\"));\r\nconst ShowArticle = lazy(() => import(\"./pages/news/showArticle\"));\r\nconst ArticleEditor = lazy(() => import(\"./pages/news/editArticle\"));\r\nconst NewsAdmin = lazy(() => import(\"./pages/newsAdmin\"));\r\nconst Admin = lazy(() => import(\"./pages/admin\"));\r\nconst UserProfile = lazy(() => import(\"./pages/userProfile\"));\r\nconst CreatingUser = lazy(() => import(\"./pages/creatingUser\"));\r\nconst Catalogue2 = lazy(() => import(\"./pages/catalogue2/Catalogue2\"));\r\nconst CatalogueServiceDetails = lazy(() =>\r\n import(\"./pages/catalogue2/CatalogueServiceDetails\")\r\n);\r\nconst MyServices = lazy(() => import(\"./pages/myServices\"));\r\nconst PWCServices = lazy(() => import(\"./pages/pwcServices\"));\r\nconst MyClients = lazy(() => import(\"./pages/myClients\"));\r\nconst ClientView = lazy(() => import(\"./pages/ClientView\"));\r\n\r\nconst ModuleSecure = ({ params, children }) => {\r\n const initialized = useSelector((state) => state.global.initialized);\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n\r\n const menus = Object.values(MODULES);\r\n\r\n useEffect(() => {\r\n if (initialized === INITIALIZE.TRUE) {\r\n const selectedKey = Object.keys(MODULE_VALUES).find((key) =>\r\n MODULE_VALUES[key].match(params.location.pathname)\r\n );\r\n\r\n if (!selectedKey) {\r\n params.history.push(\"/404\");\r\n return;\r\n }\r\n }\r\n }, [initialized, menus, params]);\r\n\r\n const hasModulePermission = (routeModule) => {\r\n if (initialized !== INITIALIZE.TRUE || !routeModule) {\r\n return false;\r\n }\r\n return !routeModule.isInternalOnly || !!loginUser?.isInternal;\r\n };\r\n\r\n return hasModulePermission(findCurrentModule(params.location.pathname))\r\n ? children\r\n : null;\r\n};\r\n\r\nconst Routes = () => {\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n\r\n return (\r\n }>\r\n \r\n }\r\n />\r\n\r\n } />\r\n } />\r\n } />\r\n {process.env.REACT_APP_ENABLE_ECS_MENU_ITEM === \"true\" && (\r\n (\r\n \r\n )}\r\n />\r\n )}\r\n\r\n }\r\n />\r\n }\r\n />\r\n\r\n (\r\n \r\n \r\n \r\n process.env.REACT_APP_HIDE_MODULES_NON_LUX !== \"1\" ||\r\n (process.env.REACT_APP_HIDE_MODULES_NON_LUX === \"1\" &&\r\n loginUser?.isLu) ? (\r\n loginUser?.isInternal ? (\r\n \r\n ) : (\r\n \r\n )\r\n ) : null\r\n }\r\n />\r\n\r\n \r\n process.env.REACT_APP_HIDE_MODULES_NON_LUX !== \"1\" ||\r\n (process.env.REACT_APP_HIDE_MODULES_NON_LUX === \"1\" &&\r\n loginUser?.isLu) ? (\r\n \r\n ) : null\r\n }\r\n />\r\n\r\n \r\n process.env.REACT_APP_HIDE_MODULES_NON_LUX !== \"1\" ||\r\n (process.env.REACT_APP_HIDE_MODULES_NON_LUX === \"1\" &&\r\n loginUser?.isLu) ? (\r\n \r\n ) : null\r\n }\r\n />\r\n\r\n (\r\n \r\n )}\r\n />\r\n {NEWS_MODULE_IS_ENABLED && (\r\n (\r\n \r\n )}\r\n />\r\n )}\r\n\r\n {NEWS_MODULE_IS_ENABLED && (\r\n (\r\n \r\n )}\r\n />\r\n )}\r\n {NEWS_MODULE_IS_ENABLED && (\r\n }\r\n />\r\n )}\r\n {NEWS_MODULE_IS_ENABLED && (\r\n (\r\n \r\n )}\r\n />\r\n )}\r\n \r\n \r\n }\r\n />\r\n\r\n \r\n process.env.REACT_APP_HIDE_MODULES_NON_LUX !== \"1\" ||\r\n (process.env.REACT_APP_HIDE_MODULES_NON_LUX === \"1\" &&\r\n loginUser?.isLu) ? (\r\n \r\n ) : null\r\n }\r\n />\r\n \r\n\r\n {NEWS_MODULE_IS_ENABLED && (\r\n }\r\n />\r\n )}\r\n {NEWS_MODULE_IS_ENABLED && (\r\n }\r\n />\r\n )}\r\n\r\n }\r\n />\r\n \r\n \r\n \r\n \r\n ))}\r\n />\r\n \r\n \r\n );\r\n};\r\n\r\nexport default Routes;\r\n","import \"appkit-react/style/appkit-react.default.css\";\r\nimport \"bootstrap/dist/css/bootstrap.css\";\r\nimport \"react-resizable/css/styles.css\";\r\n\r\nimport \"./App.scss\";\r\nimport \"./appkit-overrides.scss\";\r\n\r\nimport { getTenant } from \"api/tenant/tenantApi\";\r\nimport Footer from \"components/Footer\";\r\nimport FullPageLoader from \"components/FullPageLoader\";\r\nimport LoginManager from \"components/LoginManager\";\r\nimport { createContext, useEffect, useRef } from \"react\";\r\nimport { useDispatch, useSelector } from \"react-redux\";\r\nimport { setNoTenant, upsertHostInfo } from \"redux/actions/global\";\r\n\r\nimport Header from \"./components/Header\";\r\nimport Menu from \"./components/Menu\";\r\nimport Routes from \"./routes\";\r\n\r\nexport const ScrollContext = createContext(null);\r\n\r\nconst App = () => {\r\n const ref = useRef(null);\r\n const currentUser = useSelector((state) => state.global.data.loginUser);\r\n const hostInfo = useSelector((state) => state.global.data.hostInfo);\r\n const dispatch = useDispatch();\r\n\r\n useEffect(() => {\r\n if (hostInfo === null)\r\n getTenant()\r\n .then((data) => {\r\n dispatch(upsertHostInfo(data));\r\n })\r\n .catch(() => {\r\n dispatch(setNoTenant());\r\n dispatch(upsertHostInfo({}));\r\n });\r\n }, [dispatch, hostInfo]);\r\n\r\n if (hostInfo === null) {\r\n return ;\r\n }\r\n\r\n return (\r\n \r\n
\r\n
\r\n \r\n
\r\n {currentUser ? : null}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n );\r\n};\r\n\r\nexport default App;\r\n","import { ScrollContext } from \"App\";\r\nimport { RefObject, useContext, useEffect, useRef } from \"react\";\r\n\r\ntype CloseHandler = () => void;\r\n\r\nexport default function useClickOutside(\r\n open: boolean,\r\n onClose: CloseHandler,\r\n ousideRef: RefObject | null = null\r\n): RefObject {\r\n const rootRef = useContext(ScrollContext);\r\n const eventRef = ousideRef || rootRef!;\r\n const ref = useRef(null);\r\n\r\n useEffect(() => {\r\n if (open) {\r\n const handleClickOutside = (e: any) => {\r\n if (!ref.current?.contains(e.target)) {\r\n onClose();\r\n }\r\n };\r\n\r\n const containerNode = eventRef.current;\r\n if (!containerNode) {\r\n return;\r\n }\r\n\r\n containerNode.addEventListener(\"mousedown\", handleClickOutside);\r\n return () =>\r\n containerNode?.removeEventListener(\"mousedown\", handleClickOutside);\r\n }\r\n }, [open, onClose, ousideRef, eventRef]);\r\n\r\n return ref;\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport oidcConfig from \"api/auth/config\";\r\nimport { Button } from \"appkit-react\";\r\nimport { useEffect, useState } from \"react\";\r\n\r\nconst OIDCMessage = ({\r\n title = \"Default title\",\r\n subtitle = \"Default subtitle\",\r\n illustration = null,\r\n buttonLabel = \"Default Button\",\r\n buttonAction = null,\r\n timeoutButton = false,\r\n}) => {\r\n const [viewTimeout, setViewTimeout] = useState(false);\r\n\r\n const [storedTimeout, setStoredTimeout] = useState(null);\r\n\r\n if (timeoutButton && !viewTimeout && storedTimeout === null) {\r\n const timeout = setTimeout(() => {\r\n setViewTimeout(true);\r\n }, 5000);\r\n setStoredTimeout(timeout);\r\n }\r\n\r\n useEffect(() => {\r\n return () => {\r\n clearTimeout(storedTimeout);\r\n };\r\n }, [storedTimeout]);\r\n\r\n return (\r\n
\r\n

{title}

\r\n

{subtitle}

\r\n {buttonAction ? (\r\n \r\n ) : null}\r\n {viewTimeout ? (\r\n
\r\n

\r\n This is taking longer than usual. A page refresh could solve the\r\n problem.\r\n

\r\n {\r\n sessionStorage.removeItem(\r\n `oidc.user:${oidcConfig.authority}:${oidcConfig.client_id}`\r\n );\r\n window.location.reload();\r\n }}\r\n >\r\n Refresh page\r\n \r\n
\r\n ) : null}\r\n {illustration ? (\r\n \r\n ) : null}\r\n
\r\n );\r\n};\r\n\r\nexport default OIDCMessage;\r\n","import moment from \"moment\";\r\n\r\nconst DEFAULT_DATE_FORMAT = \"DD/MM/YYYY\";\r\nconst DEFAULT_DATETIME_FORMAT = \"DD/MM/YYYY HH:mm\";\r\n\r\nexport const formatDate = (date, pattern = DEFAULT_DATE_FORMAT) =>\r\n moment(date).format(pattern);\r\n\r\nexport const formatDateTime = (date, pattern = DEFAULT_DATETIME_FORMAT) =>\r\n formatDate(date, pattern);\r\n\r\nexport const computeCurrentMonth = () => {\r\n const today = new Date();\r\n today.setDate(1);\r\n today.setUTCHours(0, 0, 0, 0);\r\n return today;\r\n};\r\n\r\nexport const getEntireMonthRange = (date, numberOfMonths = 1) => {\r\n const start = new Date(date.getFullYear(), date.getMonth(), 1, 0, 0, 0, 0);\r\n const end = new Date(\r\n date.getFullYear(),\r\n date.getMonth() + numberOfMonths,\r\n 0,\r\n 23,\r\n 59,\r\n 59,\r\n 999\r\n );\r\n return { start, end };\r\n};\r\n\r\nexport const getEntireYear = (year) => {\r\n const start = new Date(`${year}-01-01T00:00:00.000Z`);\r\n const end = new Date(`${year}-12-31T23:59:59.999Z`);\r\n return { start, end };\r\n};\r\n\r\nexport const atMidnight = (date) => {\r\n return new Date(\r\n date.getFullYear(),\r\n date.getMonth(),\r\n date.getDate(),\r\n 0,\r\n 0,\r\n 0,\r\n 0\r\n );\r\n};\r\n\r\nexport const toISODateStringIgnoreTime = (date) => {\r\n return `${date.getFullYear().toString().padStart(2, \"0\")}-${(\r\n date.getMonth() + 1\r\n )\r\n .toString()\r\n .padStart(2, \"0\")}-${date\r\n .getDate()\r\n .toString()\r\n .padStart(2, \"0\")}T00:00:00.000Z`;\r\n};\r\n","import \"./index.scss\";\r\n\r\nimport { getPhoto } from \"api/admin/adminApi\";\r\nimport { Avatar } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport { useEffect, useMemo, useState } from \"react\";\r\n\r\nimport { getInitialsFromName } from \"../../utils/index\";\r\n\r\nconst AvatarWithAsyncPhoto = ({\r\n photoUri,\r\n name,\r\n className = \"\",\r\n children = null,\r\n ...props\r\n}) => {\r\n const [photo, setPhoto] = useState(undefined);\r\n\r\n useEffect(() => {\r\n if (photoUri) {\r\n getPhoto(photoUri).then(setPhoto);\r\n } else {\r\n setPhoto(undefined);\r\n }\r\n }, [photoUri]);\r\n\r\n const initials = useMemo(() => {\r\n if (!name) {\r\n return \" \";\r\n }\r\n return getInitialsFromName(name);\r\n }, [name]);\r\n\r\n return (\r\n \r\n {photo ? {initials} : initials}\r\n {children && (\r\n
{children}
\r\n )}\r\n \r\n );\r\n};\r\n\r\nexport default AvatarWithAsyncPhoto;\r\n","import { apiFetch } from \"../api\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT + \"SubscriptionAccess/\";\r\n\r\nexport const getThreeWPermissions = (idSubscription) => {\r\n return apiFetch(`${PREFIX}${idSubscription}`);\r\n};\r\n\r\nexport const updateThreeWPermissions = (idSubscription, permissions) => {\r\n return apiFetch(`${PREFIX}${idSubscription}`, permissions, \"PUT\");\r\n};\r\n\r\nexport const getAllSubscriptionsFromType = (type) => {\r\n return apiFetch(`${PREFIX}${type}`);\r\n};\r\n","const codes = [\r\n { code: 93, country: \"Afghanistan\" },\r\n { code: 355, country: \"Albania\" },\r\n { code: 213, country: \"Algeria\" },\r\n { code: 1, country: \"American Samoa\" },\r\n { code: 376, country: \"Andorra\" },\r\n { code: 244, country: \"Angola\" },\r\n { code: 1, country: \"Anguilla\" },\r\n { code: 1, country: \"Antigua and Barbuda\" },\r\n { code: 54, country: \"Argentine Republic\" },\r\n { code: 374, country: \"Armenia\" },\r\n { code: 297, country: \"Aruba\" },\r\n { code: 247, country: \"Ascension\" },\r\n { code: 61, country: \"Australia\" },\r\n { code: 672, country: \"Australian External Territories\" },\r\n { code: 43, country: \"Austria\" },\r\n { code: 994, country: \"Azerbaijani Republic\" },\r\n { code: 1, country: \"Bahamas\" },\r\n { code: 973, country: \"Bahrain\" },\r\n { code: 880, country: \"Bangladesh\" },\r\n { code: 1, country: \"Barbados\" },\r\n { code: 375, country: \"Belarus\" },\r\n { code: 32, country: \"Belgium\" },\r\n { code: 501, country: \"Belize\" },\r\n { code: 229, country: \"Benin\" },\r\n { code: 1, country: \"Bermuda\" },\r\n { code: 975, country: \"Bhutan\" },\r\n { code: 591, country: \"Bolivia\" },\r\n { code: 387, country: \"Bosnia and Herzegovina\" },\r\n { code: 267, country: \"Botswana\" },\r\n { code: 55, country: \"Brazil\" },\r\n { code: 1, country: \"British Virgin Islands\" },\r\n { code: 673, country: \"Brunei Darussalam\" },\r\n { code: 359, country: \"Bulgaria\" },\r\n { code: 226, country: \"Burkina Faso\" },\r\n { code: 257, country: \"Burundi\" },\r\n { code: 855, country: \"Cambodia\" },\r\n { code: 237, country: \"Cameroon\" },\r\n { code: 1, country: \"Canada\" },\r\n { code: 238, country: \"Cape Verde\" },\r\n { code: 1, country: \"Cayman Islands\" },\r\n { code: 236, country: \"Central African Republic\" },\r\n { code: 235, country: \"Chad\" },\r\n { code: 56, country: \"Chile\" },\r\n { code: 86, country: \"China\" },\r\n { code: 57, country: \"Colombia\" },\r\n { code: 269, country: \"Comoros\" },\r\n { code: 242, country: \"Congo\" },\r\n { code: 682, country: \"Cook Islands\" },\r\n { code: 506, country: \"Costa Rica\" },\r\n { code: 225, country: \"Côte d'Ivoire\" },\r\n { code: 385, country: \"Croatia\" },\r\n { code: 53, country: \"Cuba\" },\r\n { code: 357, country: \"Cyprus\" },\r\n { code: 420, country: \"Czech Republic\" },\r\n { code: 850, country: \"Democratic People's Republic of Korea\" },\r\n { code: 243, country: \"Democratic Republic of the Congo\" },\r\n { code: 670, country: \"Democratic Republic of Timor-Leste\" },\r\n { code: 45, country: \"Denmark\" },\r\n { code: 246, country: \"Diego Garcia\" },\r\n { code: 253, country: \"Djibouti\" },\r\n { code: 1, country: \"Dominica\" },\r\n { code: 1, country: \"Dominican Republic\" },\r\n { code: 593, country: \"Ecuador\" },\r\n { code: 20, country: \"Egypt\" },\r\n { code: 503, country: \"El Salvador\" },\r\n { code: 240, country: \"Equatorial Guinea\" },\r\n { code: 291, country: \"Eritrea\" },\r\n { code: 372, country: \"Estonia\" },\r\n { code: 251, country: \"Ethiopia\" },\r\n { code: 500, country: \"Falkland Islands\" },\r\n { code: 298, country: \"Faroe Islands\" },\r\n { code: 679, country: \"Fiji\" },\r\n { code: 358, country: \"Finland\" },\r\n { code: 33, country: \"France\" },\r\n { code: 594, country: \"French Guiana\" },\r\n { code: 689, country: \"French Polynesia\" },\r\n { code: 241, country: \"Gabonese Republic\" },\r\n { code: 220, country: \"Gambia\" },\r\n { code: 995, country: \"Georgia\" },\r\n { code: 49, country: \"Germany\" },\r\n { code: 233, country: \"Ghana\" },\r\n { code: 350, country: \"Gibraltar\" },\r\n { code: 30, country: \"Greece\" },\r\n { code: 299, country: \"Greenland\" },\r\n { code: 1, country: \"Grenada\" },\r\n { code: 590, country: \"Guadeloupe\" },\r\n { code: 1, country: \"Guam\" },\r\n { code: 502, country: \"Guatemala\" },\r\n { code: 224, country: \"Guinea\" },\r\n { code: 245, country: \"Guinea-Bissau\" },\r\n { code: 592, country: \"Guyana\" },\r\n { code: 509, country: \"Haiti\" },\r\n { code: 504, country: \"Honduras\" },\r\n { code: 852, country: \"Hong Kong, China\" },\r\n { code: 36, country: \"Hungary\" },\r\n { code: 354, country: \"Iceland\" },\r\n { code: 91, country: \"India\" },\r\n { code: 62, country: \"Indonesia\" },\r\n { code: 98, country: \"Iran\" },\r\n { code: 964, country: \"Iraq\" },\r\n { code: 353, country: \"Ireland\" },\r\n { code: 972, country: \"Israel\" },\r\n { code: 39, country: \"Italy\" },\r\n { code: 1, country: \"Jamaica\" },\r\n { code: 81, country: \"Japan\" },\r\n { code: 962, country: \"Jordan\" },\r\n { code: 7, country: \"Kazakhstan\" },\r\n { code: 254, country: \"Kenya\" },\r\n { code: 686, country: \"Kiribati\" },\r\n { code: 82, country: \"Korea\" },\r\n { code: 965, country: \"Kuwait\" },\r\n { code: 996, country: \"Kyrgyz Republic\" },\r\n { code: 856, country: \"Lao People's Democratic Republic\" },\r\n { code: 371, country: \"Latvia\" },\r\n { code: 961, country: \"Lebanon\" },\r\n { code: 266, country: \"Lesotho\" },\r\n { code: 231, country: \"Liberia\" },\r\n { code: 218, country: \"Libya\" },\r\n { code: 423, country: \"Liechtenstein\" },\r\n { code: 370, country: \"Lithuania\" },\r\n { code: 352, country: \"Luxembourg\" },\r\n { code: 853, country: \"Macao, China\" },\r\n { code: 261, country: \"Madagascar\" },\r\n { code: 265, country: \"Malawi\" },\r\n { code: 60, country: \"Malaysia\" },\r\n { code: 960, country: \"Maldives\" },\r\n { code: 223, country: \"Mali\" },\r\n { code: 356, country: \"Malta\" },\r\n { code: 692, country: \"Marshall Islands\" },\r\n { code: 596, country: \"Martinique\" },\r\n { code: 222, country: \"Mauritania\" },\r\n { code: 230, country: \"Mauritius\" },\r\n { code: 269, country: \"Mayotte\" },\r\n { code: 52, country: \"Mexico\" },\r\n { code: 691, country: \"Micronesia\" },\r\n { code: 373, country: \"Moldova\" },\r\n { code: 377, country: \"Monaco\" },\r\n { code: 976, country: \"Mongolia\" },\r\n { code: 382, country: \"Montenegro\" },\r\n { code: 1, country: \"Montserrat\" },\r\n { code: 212, country: \"Morocco\" },\r\n { code: 258, country: \"Mozambique\" },\r\n { code: 95, country: \"Myanmar\" },\r\n { code: 264, country: \"Namibia\" },\r\n { code: 674, country: \"Nauru\" },\r\n { code: 977, country: \"Nepal\" },\r\n { code: 31, country: \"Netherlands\" },\r\n { code: 599, country: \"Netherlands Antilles\" },\r\n { code: 687, country: \"New Caledonia\" },\r\n { code: 64, country: \"New Zealand\" },\r\n { code: 505, country: \"Nicaragua\" },\r\n { code: 227, country: \"Niger\" },\r\n { code: 234, country: \"Nigeria\" },\r\n { code: 683, country: \"Niue\" },\r\n { code: 1, country: \"Northern Mariana Islands\" },\r\n { code: 47, country: \"Norway\" },\r\n { code: 968, country: \"Oman\" },\r\n { code: 92, country: \"Pakistan\" },\r\n { code: 680, country: \"Palau\" },\r\n { code: 507, country: \"Panama\" },\r\n { code: 675, country: \"Papua New Guinea\" },\r\n { code: 595, country: \"Paraguay\" },\r\n { code: 51, country: \"Peru\" },\r\n { code: 63, country: \"Philippines\" },\r\n { code: 48, country: \"Poland\" },\r\n { code: 351, country: \"Portugal\" },\r\n { code: 1, country: \"Puerto Rico\" },\r\n { code: 974, country: \"Qatar\" },\r\n { code: 40, country: \"Romania\" },\r\n { code: 7, country: \"Russian Federation\" },\r\n { code: 250, country: \"Rwanda\" },\r\n { code: 290, country: \"Saint Helena\" },\r\n { code: 1, country: \"Saint Kitts and Nevis\" },\r\n { code: 1, country: \"Saint Lucia\" },\r\n { code: 508, country: \"Saint Pierre and Miquelon\" },\r\n { code: 1, country: \"Saint Vincent and the Grenadines\" },\r\n { code: 685, country: \"Samoa\" },\r\n { code: 378, country: \"San Marino\" },\r\n { code: 239, country: \"Sao Tome and Principe\" },\r\n { code: 966, country: \"Saudi Arabia\" },\r\n { code: 221, country: \"Senegal\" },\r\n { code: 381, country: \"Serbia\" },\r\n { code: 248, country: \"Seychelles\" },\r\n { code: 232, country: \"Sierra Leone\" },\r\n { code: 65, country: \"Singapore\" },\r\n { code: 421, country: \"Slovak Republic\" },\r\n { code: 386, country: \"Slovenia\" },\r\n { code: 677, country: \"Solomon Islands\" },\r\n { code: 252, country: \"Somali Democratic Republic\" },\r\n { code: 27, country: \"South Africa\" },\r\n { code: 34, country: \"Spain\" },\r\n { code: 94, country: \"Sri Lanka\" },\r\n { code: 249, country: \"Sudan\" },\r\n { code: 597, country: \"Suriname\" },\r\n { code: 268, country: \"Swaziland\" },\r\n { code: 46, country: \"Sweden\" },\r\n { code: 41, country: \"Switzerland\" },\r\n { code: 963, country: \"Syrian Arab Republic\" },\r\n { code: 886, country: \"Taiwan, China\" },\r\n { code: 992, country: \"Tajikistan\" },\r\n { code: 255, country: \"Tanzania\" },\r\n { code: 66, country: \"Thailand\" },\r\n { code: 389, country: \"Macedonia\" },\r\n { code: 228, country: \"Togolese Republic\" },\r\n { code: 690, country: \"Tokelau\" },\r\n { code: 676, country: \"Tonga\" },\r\n { code: 1, country: \"Trinidad and Tobago\" },\r\n { code: 290, country: \"Tristan da Cunha\" },\r\n { code: 216, country: \"Tunisia\" },\r\n { code: 90, country: \"Turkey\" },\r\n { code: 993, country: \"Turkmenistan\" },\r\n { code: 1, country: \"Turks and Caicos Islands\" },\r\n { code: 688, country: \"Tuvalu\" },\r\n { code: 256, country: \"Uganda\" },\r\n { code: 380, country: \"Ukraine\" },\r\n { code: 971, country: \"United Arab Emirates\" },\r\n { code: 44, country: \"United Kingdom\" },\r\n { code: 1, country: \"United States of America\" },\r\n { code: 1, country: \"United States Virgin Islands\" },\r\n { code: 598, country: \"Uruguay\" },\r\n { code: 998, country: \"Uzbekistan\" },\r\n { code: 678, country: \"Vanuatu\" },\r\n { code: 379, country: \"Vatican City State\" },\r\n { code: 58, country: \"Venezuela\" },\r\n { code: 84, country: \"Viet Nam\" },\r\n { code: 681, country: \"Wallis and Futuna\" },\r\n { code: 967, country: \"Yemen\" },\r\n { code: 260, country: \"Zambia\" },\r\n { code: 263, country: \"Zimbabwe\" },\r\n];\r\n\r\nexport default codes;\r\n","import \"./index.scss\";\r\n\r\nimport { Input, Select, SelectOption } from \"appkit-react\";\r\n\r\nimport codes from \"./codes\";\r\n\r\nconst DEFAULT_VALUE = {\r\n code: null,\r\n number: \"\",\r\n};\r\n\r\nexport function validatePhone(value) {\r\n if (value.code === null) {\r\n return \"Please provide a valid dialing code\";\r\n }\r\n\r\n const valueNumber = value?.number?.replaceAll(\" \", \"\") || \"\";\r\n\r\n if (!/^[0-9]{1,15}$/g.test(valueNumber)) {\r\n return \"Please provide a valid phone number (without dialing code number)\";\r\n }\r\n\r\n return null;\r\n}\r\n\r\nconst PhoneInput = ({ value = DEFAULT_VALUE, onChange, ...props }) => {\r\n const handleDialingCodeChange = (code) => onChange({ ...value, code });\r\n const handlePhoneNumberChange = (number) => onChange({ ...value, number });\r\n\r\n return (\r\n
\r\n \r\n {codes.map(({ code, country }) => (\r\n \r\n {country}\r\n (+{code})\r\n \r\n ))}\r\n \r\n\r\n \r\n
\r\n );\r\n};\r\n\r\nexport default PhoneInput;\r\n","export default __webpack_public_path__ + \"static/media/undraw_feeling_blue.a1688c2f.svg\";","import \"./UnexpectedError.scss\";\r\n\r\nimport { Button } from \"appkit-react\";\r\nimport CategoryPitch from \"components/CategoryPitch\";\r\nimport PageTitle from \"components/PageTitle\";\r\nimport { useEffect } from \"react\";\r\n\r\nimport backgroundImage from \"../../img/illustrations/undraw_feeling_blue.svg\";\r\n\r\nconst UnexpectedError = ({ error }) => {\r\n useEffect(() => {\r\n document.body.classList.add(\"has-unrecoverable-error\");\r\n return () => {\r\n document.body.classList.remove(\"has-unrecoverable-error\");\r\n };\r\n }, []);\r\n\r\n return (\r\n
\r\n \r\n \r\n

An unexpected error occurred

\r\n
\r\n

\r\n We're sorry for any inconvenience caused. If this issue persists, do not\r\n hesitate to contact the support team.\r\n

\r\n

Please reload this page.

\r\n
\r\n {\r\n window.location.reload();\r\n }}\r\n >\r\n Reload\r\n \r\n
\r\n {error?.stack && (\r\n
\r\n Error details\r\n
{error.stack}
\r\n
\r\n )}\r\n
\r\n );\r\n};\r\n\r\nexport default UnexpectedError;\r\n","export default __webpack_public_path__ + \"static/media/undraw_thoughts_e49y.39d0bbce.svg\";","import \"./UnexpectedError.scss\";\r\n\r\nimport { Button } from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport CategoryPitch from \"components/CategoryPitch\";\r\nimport { handleLogout } from \"components/Header\";\r\nimport PageTitle from \"components/PageTitle\";\r\nimport { useEffect } from \"react\";\r\n\r\nimport backgroundImage from \"../../img/illustrations/undraw_thoughts_e49y.svg\";\r\n\r\nconst ControlledError = ({\r\n title,\r\n subtitle,\r\n description,\r\n illustration = backgroundImage,\r\n showLogoutButton = true,\r\n showReloadButton = true,\r\n customButton = undefined,\r\n dark = false,\r\n}) => {\r\n useEffect(() => {\r\n document.body.classList.add(\"has-unrecoverable-error\");\r\n return () => {\r\n document.body.classList.remove(\"has-unrecoverable-error\");\r\n };\r\n }, []);\r\n\r\n return (\r\n
\r\n \r\n \r\n

{subtitle}

\r\n
\r\n

{description}

\r\n
\r\n {showLogoutButton && (\r\n \r\n )}\r\n {showReloadButton && (\r\n {\r\n window.location.reload();\r\n }}\r\n >\r\n Reload\r\n \r\n )}\r\n {customButton}\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default ControlledError;\r\n","import \"./index.scss\";\r\n\r\nimport { Tooltip } from \"@mui/material\";\r\nimport { Button, Checkbox, List, ListItem } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport SuspenseLoader from \"components/SuspenseLoader\";\r\nimport useClickOutside from \"hooks/useClickOutside\";\r\nimport {\r\n useCallback,\r\n useEffect,\r\n useLayoutEffect,\r\n useRef,\r\n useState,\r\n} from \"react\";\r\nimport ReactDOM from \"react-dom\";\r\nimport InfiniteScroll from \"react-infinite-scroller\";\r\n\r\nconst DEBOUNCE_TIME = 500;\r\n\r\nconst DEFAULT_EQUALS = (a, b) => a === b;\r\n\r\nconst AsyncSelect = ({\r\n className,\r\n placeholder,\r\n loadItems,\r\n pageSize = 20,\r\n render,\r\n value,\r\n multiple,\r\n onChange,\r\n disabled = false,\r\n clickOutsideRef = null,\r\n isEqual = DEFAULT_EQUALS,\r\n hasError = false,\r\n errMsg = undefined,\r\n clearable = false,\r\n selectedLabel = \"items selected\",\r\n getTooltip = null,\r\n}) => {\r\n const [open, setOpen] = useState(false);\r\n const [textSearch, setTextSearch] = useState(\"\");\r\n const [items, setItems] = useState(null);\r\n const [hasMore, setHasMore] = useState(true);\r\n const [tooltipContent, setTooltipContent] = useState(\"\");\r\n\r\n const inputRef = useRef();\r\n const scrollWrapper = useRef();\r\n\r\n const loadMore = (pageNumber) => {\r\n loadItems(pageNumber, textSearch).then((data) => {\r\n setHasMore(data.hasNext ?? data.length === pageSize);\r\n setItems([...items, ...(data.items ?? data)]);\r\n });\r\n };\r\n\r\n const reload = useCallback(\r\n (textSearch) => {\r\n setItems(null);\r\n\r\n loadItems(1, textSearch).then((data) => {\r\n setHasMore(data.hasNext ?? data.length === pageSize);\r\n setItems(data.items ?? data);\r\n });\r\n },\r\n [loadItems, pageSize]\r\n );\r\n\r\n const isEmptySelection = !value || (multiple && !value.length);\r\n\r\n const toggleText = () => {\r\n if (isEmptySelection) {\r\n return placeholder;\r\n }\r\n\r\n if (!multiple) {\r\n return render(value);\r\n }\r\n\r\n return value.length === 1\r\n ? render(value[0])\r\n : `${value.length} ${selectedLabel}`;\r\n };\r\n\r\n useEffect(() => {\r\n if (open) {\r\n const debouncer = setTimeout(() => {\r\n reload(textSearch);\r\n }, DEBOUNCE_TIME);\r\n return () => {\r\n window.clearInterval(debouncer);\r\n };\r\n }\r\n }, [open, textSearch, reload]);\r\n\r\n useEffect(() => {\r\n if (!open) {\r\n setTextSearch(\"\");\r\n setItems(null);\r\n }\r\n }, [open, reload]);\r\n\r\n useLayoutEffect(() => {\r\n if (open && !!inputRef.current) {\r\n ReactDOM.findDOMNode(inputRef.current).focus();\r\n }\r\n }, [open]);\r\n\r\n const close = useCallback(() => setOpen(false), []);\r\n const selectRef = useClickOutside(open, close, clickOutsideRef);\r\n\r\n useEffect(() => {\r\n if (disabled) {\r\n setOpen(false);\r\n }\r\n }, [disabled]);\r\n\r\n const handleSelect = (item) => {\r\n if (!multiple) {\r\n onChange(item);\r\n setOpen(false);\r\n } else {\r\n onChange(\r\n value.findIndex((v) => isEqual(item, v)) >= 0\r\n ? value.filter((v) => !isEqual(item, v))\r\n : [...value, item]\r\n );\r\n }\r\n };\r\n\r\n return (\r\n
\r\n \r\n setOpen(true))}\r\n >\r\n {!open ? (\r\n <>\r\n \r\n \r\n {getTooltip !== null ? (\r\n {\r\n setTooltipContent(\r\n
\r\n );\r\n getTooltip()\r\n .then((items) =>\r\n items.map((item) => item.value).join(\", \")\r\n )\r\n .then(setTooltipContent);\r\n }}\r\n >\r\n {toggleText()}\r\n \r\n ) : (\r\n <>{toggleText()}\r\n )}\r\n
\r\n\r\n {clearable && !isEmptySelection && (\r\n {\r\n e.preventDefault();\r\n e.stopPropagation();\r\n\r\n onChange(multiple ? [] : null);\r\n }}\r\n >\r\n \r\n \r\n )}\r\n \r\n ) : (\r\n setTextSearch(e.target.value)}\r\n ref={inputRef}\r\n className=\"select-toggle-input\"\r\n />\r\n )}\r\n
\r\n \r\n \r\n \r\n {items ? (\r\n scrollWrapper.current}\r\n >\r\n {items.map((item) => (\r\n handleSelect(item) : null}\r\n >\r\n {multiple ? (\r\n isEqual(v, item)) >= 0\r\n }\r\n onChange={(e) => {\r\n e.stopPropagation();\r\n handleSelect(item);\r\n }}\r\n >\r\n {render(item)}\r\n \r\n ) : (\r\n render(item)\r\n )}\r\n \r\n ))}\r\n \r\n ) : (\r\n \r\n )}\r\n \r\n
\r\n \r\n \r\n {hasError && errMsg && typeof errMsg === \"string\" ? (\r\n

{errMsg}

\r\n ) : null}\r\n \r\n );\r\n};\r\n\r\nexport default AsyncSelect;\r\n","import \"./index.scss\";\r\n\r\nconst SuspenseLoader = ({ text = \"Loading page...\" }) => {\r\n return (\r\n
\r\n
\r\n
\r\n
{text}
\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default SuspenseLoader;\r\n","import { UseTypedQueryOptions } from \"api/UseTypedQueryOptions\";\r\nimport { UseQueryResult, useQuery } from \"react-query\";\r\n\r\nimport { ServiceGroupReadListDTO } from \"../__generated__/CatalogueAPI\";\r\nimport { getServiceGroups } from \"../catalogApi\";\r\n\r\ninterface IUseServiceGroupsProps {\r\n queryOptions?: UseTypedQueryOptions;\r\n}\r\n\r\nexport default function useServiceGroups(\r\n props?: IUseServiceGroupsProps\r\n): UseQueryResult {\r\n return useQuery(\r\n \"serviceGroups\",\r\n () => getServiceGroups(),\r\n props?.queryOptions\r\n );\r\n}\r\n","export default __webpack_public_path__ + \"static/media/icons-outline-app-launcher-fill.9dba4d9d.svg\";","export default __webpack_public_path__ + \"static/media/icons-outline-app-launcher.28c2b5d4.svg\";","import CatalogueIconFill from \"img/icones/icons-outline-app-launcher-fill.svg\";\r\nimport CatalogueIconOutline from \"img/icones/icons-outline-app-launcher.svg\";\r\nimport NewsIconFill from \"img/icones/icons-outline-start-tour-fill.svg\";\r\nimport NewsIconOutline from \"img/icones/icons-outline-start-tour.svg\";\r\n// @ts-ignore\r\nimport startsWith from \"starts-with\";\r\n\r\nexport enum MODULES {\r\n MYSERVICES = \"/myServices\",\r\n MYCLIENTS = \"/myClients\",\r\n CATALOGUE = \"/\",\r\n NEWS = \"/articles\",\r\n NEWS_ADMIN = \"/articlesadmin\",\r\n ADMIN = \"/admin\",\r\n PROFILE = \"/profile\",\r\n CLIENT_VIEW = \"/clientView\",\r\n}\r\n\r\nexport const NEWS_MODULE_IS_ENABLED =\r\n process.env.REACT_APP_FORCE_3W_DISPLAY_MENU === \"true\" ||\r\n window.location.host === process.env.REACT_APP_3W_ENABLED_HOST;\r\nexport const PSF_PSA_IS_ENABLED =\r\n process.env.REACT_APP_FORCE_PSF_PSA_DISPLAY === \"true\" ||\r\n window.location.host === process.env.REACT_APP_PSF_PSA_ENABLED_HOST;\r\n\r\nexport type ModuleValues = {\r\n label: string;\r\n icon?: string;\r\n outlineIcon?: any;\r\n fillIcon?: any;\r\n match: (path: string) => boolean;\r\n requireConnexion?: boolean;\r\n isInternalOnly?: boolean;\r\n isLuxOnly?: boolean;\r\n};\r\n\r\nexport const MODULE_VALUES: Record = {\r\n [MODULES.MYSERVICES]: {\r\n label: \"My services\",\r\n icon: \"icon-grid-view\",\r\n match: (path) => path === MODULES.MYSERVICES,\r\n requireConnexion: true,\r\n isLuxOnly: true,\r\n },\r\n [MODULES.MYCLIENTS]: {\r\n label: \"My clients\",\r\n icon: \"icon-building\",\r\n match: (path) => path === MODULES.MYCLIENTS,\r\n requireConnexion: true,\r\n isInternalOnly: true,\r\n isLuxOnly: true,\r\n },\r\n [MODULES.CATALOGUE]: {\r\n label: \"Catalogue\",\r\n outlineIcon: CatalogueIconOutline,\r\n fillIcon: CatalogueIconFill,\r\n match: (path) => path === MODULES.CATALOGUE,\r\n requireConnexion: false,\r\n },\r\n [MODULES.NEWS]: {\r\n label: \"News\",\r\n outlineIcon: NewsIconOutline,\r\n fillIcon: NewsIconFill,\r\n match: (path) => startsWith(path, MODULES.NEWS),\r\n requireConnexion: true,\r\n },\r\n [MODULES.PROFILE]: {\r\n match: (path) => startsWith(path, MODULES.PROFILE),\r\n requireConnexion: true,\r\n label: \"Profile\",\r\n },\r\n [MODULES.ADMIN]: {\r\n label: \"Admin\",\r\n icon: \"icon-setting\",\r\n match: (path) => startsWith(path, MODULES.ADMIN),\r\n requireConnexion: true,\r\n isLuxOnly: true,\r\n },\r\n\r\n [MODULES.NEWS_ADMIN]: {\r\n label: \"News Admin\",\r\n icon: \"icon-cogs\",\r\n match: (path) => startsWith(path, MODULES.NEWS_ADMIN),\r\n requireConnexion: true,\r\n },\r\n\r\n [MODULES.CLIENT_VIEW]: {\r\n label: \"Client View\",\r\n icon: \"icon-building\",\r\n match: (path) => startsWith(path, MODULES.CLIENT_VIEW),\r\n requireConnexion: true,\r\n isInternalOnly: true,\r\n isLuxOnly: true,\r\n },\r\n};\r\n\r\nexport const findCurrentModuleKey = (uri: string): MODULES | null => {\r\n return Object.keys(MODULE_VALUES).find((key) =>\r\n MODULE_VALUES[key as MODULES].match(uri)\r\n ) as MODULES | null;\r\n};\r\n\r\nexport const findCurrentModule = (uri: string) => {\r\n const key = findCurrentModuleKey(uri);\r\n\r\n return key ? MODULE_VALUES[key] : null;\r\n};\r\n","/* eslint-disable */\r\n/* tslint:disable */\r\n/*\r\n * ---------------------------------------------------------------\r\n * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##\r\n * ## ##\r\n * ## AUTHOR: acacode ##\r\n * ## SOURCE: https://github.com/acacode/swagger-typescript-api ##\r\n * ---------------------------------------------------------------\r\n */\r\n\r\n/**\r\n * @format int32\r\n */\r\nexport type NotificationType = 1 | 2;\r\n\r\n/**\r\n * @format int32\r\n */\r\nexport type NotificationFrequency = 1 | 2 | 3;\r\n\r\nexport interface NotificationSettingsReadDTO {\r\n userPpid: string | null;\r\n types: NotificationType[] | null;\r\n frequencies: NotificationFrequency[] | null;\r\n\r\n /** @format date-time */\r\n creationDate: string;\r\n\r\n /** @format date-time */\r\n lastUpdateDate: string;\r\n}\r\n\r\nexport interface NotificationSettingsUpdateDTO {\r\n types: NotificationType[] | null;\r\n frequencies: NotificationFrequency[] | null;\r\n}\r\n\r\nexport interface NotificationTypeDTO {\r\n /** @format int32 */\r\n value: number;\r\n name: string | null;\r\n}\r\n\r\nexport interface ProblemDetails {\r\n type: string | null;\r\n title: string | null;\r\n\r\n /** @format int32 */\r\n status: number | null;\r\n detail: string | null;\r\n instance: string | null;\r\n}\r\n\r\nexport type QueryParamsType = Record;\r\nexport type ResponseFormat = keyof Omit;\r\n\r\nexport interface FullRequestParams extends Omit {\r\n /** set parameter to `true` for call `securityWorker` for this request */\r\n secure?: boolean;\r\n /** request path */\r\n path: string;\r\n /** content type of request body */\r\n type?: ContentType;\r\n /** query params */\r\n query?: QueryParamsType;\r\n /** format of response (i.e. response.json() -> format: \"json\") */\r\n format?: ResponseFormat;\r\n /** request body */\r\n body?: unknown;\r\n /** base url */\r\n baseUrl?: string;\r\n /** request cancellation token */\r\n cancelToken?: CancelToken;\r\n}\r\n\r\nexport type RequestParams = Omit;\r\n\r\nexport interface ApiConfig {\r\n baseUrl?: string;\r\n baseApiParams?: Omit;\r\n securityWorker?: (securityData: SecurityDataType | null) => Promise | RequestParams | void;\r\n customFetch?: typeof fetch;\r\n}\r\n\r\nexport interface HttpResponse extends Response {\r\n data: D;\r\n error: E;\r\n}\r\n\r\ntype CancelToken = Symbol | string | number;\r\n\r\nexport enum ContentType {\r\n Json = \"application/json\",\r\n FormData = \"multipart/form-data\",\r\n UrlEncoded = \"application/x-www-form-urlencoded\",\r\n}\r\n\r\nexport class HttpClient {\r\n public baseUrl: string = \"\";\r\n private securityData: SecurityDataType | null = null;\r\n private securityWorker?: ApiConfig[\"securityWorker\"];\r\n private abortControllers = new Map();\r\n private customFetch = (...fetchParams: Parameters) => fetch(...fetchParams);\r\n\r\n private baseApiParams: RequestParams = {\r\n credentials: \"same-origin\",\r\n headers: {},\r\n redirect: \"follow\",\r\n referrerPolicy: \"no-referrer\",\r\n };\r\n\r\n constructor(apiConfig: ApiConfig = {}) {\r\n Object.assign(this, apiConfig);\r\n }\r\n\r\n public setSecurityData = (data: SecurityDataType | null) => {\r\n this.securityData = data;\r\n };\r\n\r\n private encodeQueryParam(key: string, value: any) {\r\n const encodedKey = encodeURIComponent(key);\r\n return `${encodedKey}=${encodeURIComponent(typeof value === \"number\" ? value : `${value}`)}`;\r\n }\r\n\r\n private addQueryParam(query: QueryParamsType, key: string) {\r\n return this.encodeQueryParam(key, query[key]);\r\n }\r\n\r\n private addArrayQueryParam(query: QueryParamsType, key: string) {\r\n const value = query[key];\r\n return value.map((v: any) => this.encodeQueryParam(key, v)).join(\"&\");\r\n }\r\n\r\n protected toQueryString(rawQuery?: QueryParamsType): string {\r\n const query = rawQuery || {};\r\n const keys = Object.keys(query).filter((key) => \"undefined\" !== typeof query[key]);\r\n return keys\r\n .map((key) => (Array.isArray(query[key]) ? this.addArrayQueryParam(query, key) : this.addQueryParam(query, key)))\r\n .join(\"&\");\r\n }\r\n\r\n protected addQueryParams(rawQuery?: QueryParamsType): string {\r\n const queryString = this.toQueryString(rawQuery);\r\n return queryString ? `?${queryString}` : \"\";\r\n }\r\n\r\n private contentFormatters: Record any> = {\r\n [ContentType.Json]: (input: any) =>\r\n input !== null && (typeof input === \"object\" || typeof input === \"string\") ? JSON.stringify(input) : input,\r\n [ContentType.FormData]: (input: any) =>\r\n Object.keys(input || {}).reduce((formData, key) => {\r\n const property = input[key];\r\n formData.append(\r\n key,\r\n property instanceof Blob\r\n ? property\r\n : typeof property === \"object\" && property !== null\r\n ? JSON.stringify(property)\r\n : `${property}`,\r\n );\r\n return formData;\r\n }, new FormData()),\r\n [ContentType.UrlEncoded]: (input: any) => this.toQueryString(input),\r\n };\r\n\r\n private mergeRequestParams(params1: RequestParams, params2?: RequestParams): RequestParams {\r\n return {\r\n ...this.baseApiParams,\r\n ...params1,\r\n ...(params2 || {}),\r\n headers: {\r\n ...(this.baseApiParams.headers || {}),\r\n ...(params1.headers || {}),\r\n ...((params2 && params2.headers) || {}),\r\n },\r\n };\r\n }\r\n\r\n private createAbortSignal = (cancelToken: CancelToken): AbortSignal | undefined => {\r\n if (this.abortControllers.has(cancelToken)) {\r\n const abortController = this.abortControllers.get(cancelToken);\r\n if (abortController) {\r\n return abortController.signal;\r\n }\r\n return void 0;\r\n }\r\n\r\n const abortController = new AbortController();\r\n this.abortControllers.set(cancelToken, abortController);\r\n return abortController.signal;\r\n };\r\n\r\n public abortRequest = (cancelToken: CancelToken) => {\r\n const abortController = this.abortControllers.get(cancelToken);\r\n\r\n if (abortController) {\r\n abortController.abort();\r\n this.abortControllers.delete(cancelToken);\r\n }\r\n };\r\n\r\n public request = async ({\r\n body,\r\n secure,\r\n path,\r\n type,\r\n query,\r\n format,\r\n baseUrl,\r\n cancelToken,\r\n ...params\r\n }: FullRequestParams): Promise> => {\r\n const secureParams =\r\n ((typeof secure === \"boolean\" ? secure : this.baseApiParams.secure) &&\r\n this.securityWorker &&\r\n (await this.securityWorker(this.securityData))) ||\r\n {};\r\n const requestParams = this.mergeRequestParams(params, secureParams);\r\n const queryString = query && this.toQueryString(query);\r\n const payloadFormatter = this.contentFormatters[type || ContentType.Json];\r\n const responseFormat = format || requestParams.format;\r\n\r\n return this.customFetch(`${baseUrl || this.baseUrl || \"\"}${path}${queryString ? `?${queryString}` : \"\"}`, {\r\n ...requestParams,\r\n headers: {\r\n ...(type && type !== ContentType.FormData ? { \"Content-Type\": type } : {}),\r\n ...(requestParams.headers || {}),\r\n },\r\n signal: cancelToken ? this.createAbortSignal(cancelToken) : void 0,\r\n body: typeof body === \"undefined\" || body === null ? null : payloadFormatter(body),\r\n }).then(async (response) => {\r\n const r = response as HttpResponse;\r\n r.data = null as unknown as T;\r\n r.error = null as unknown as E;\r\n\r\n const data = !responseFormat\r\n ? r\r\n : await response[responseFormat]()\r\n .then((data) => {\r\n if (r.ok) {\r\n r.data = data;\r\n } else {\r\n r.error = data;\r\n }\r\n return r;\r\n })\r\n .catch((e) => {\r\n r.error = e;\r\n return r;\r\n });\r\n\r\n if (cancelToken) {\r\n this.abortControllers.delete(cancelToken);\r\n }\r\n\r\n if (!response.ok) throw data;\r\n return data;\r\n });\r\n };\r\n}\r\n\r\n/**\r\n * @title Notification Services v1\r\n * @version v1\r\n */\r\nexport class Api extends HttpClient {\r\n api = {\r\n /**\r\n * No description\r\n *\r\n * @tags Notification\r\n * @name V1NotificationList\r\n * @summary Return the notification settings for the current user.\r\n * @request GET:/api/v1/Notification\r\n * @secure\r\n */\r\n v1NotificationList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Notification`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Notification\r\n * @name V1NotificationUpdate\r\n * @summary Update the specified application.\r\n * @request PUT:/api/v1/Notification\r\n * @secure\r\n */\r\n v1NotificationUpdate: (data: NotificationSettingsUpdateDTO, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Notification`,\r\n method: \"PUT\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Notification\r\n * @name V1NotificationDetail\r\n * @summary Return the notification settings for the user.\r\n * @request GET:/api/v1/Notification/{ppid}\r\n * @secure\r\n */\r\n v1NotificationDetail: (ppid: string, params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Notification/${ppid}`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Notification\r\n * @name V1NotificationByPpidsCreate\r\n * @summary Return the notification settings for the users.\r\n * @request POST:/api/v1/Notification/by-ppids\r\n * @secure\r\n */\r\n v1NotificationByPpidsCreate: (data: string[], params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Notification/by-ppids`,\r\n method: \"POST\",\r\n body: data,\r\n secure: true,\r\n type: ContentType.Json,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Notification\r\n * @name V1NotificationTypesList\r\n * @summary Get the notification types list.\r\n * @request GET:/api/v1/Notification/types\r\n * @secure\r\n */\r\n v1NotificationTypesList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Notification/types`,\r\n method: \"GET\",\r\n secure: true,\r\n format: \"json\",\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Notification\r\n * @name V1NotificationUnsubscribeList\r\n * @summary Return the notification settings for the current user.\r\n * @request GET:/api/v1/Notification/unsubscribe\r\n * @secure\r\n */\r\n v1NotificationUnsubscribeList: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Notification/unsubscribe`,\r\n method: \"GET\",\r\n secure: true,\r\n ...params,\r\n }),\r\n\r\n /**\r\n * No description\r\n *\r\n * @tags Notification\r\n * @name V1NotificationRunWeeklyCreate\r\n * @summary Send the notifications.\r\n * @request POST:/api/v1/Notification/run/weekly\r\n * @secure\r\n */\r\n v1NotificationRunWeeklyCreate: (params: RequestParams = {}) =>\r\n this.request({\r\n path: `/api/v1/Notification/run/weekly`,\r\n method: \"POST\",\r\n secure: true,\r\n ...params,\r\n }),\r\n };\r\n}\r\n","import { appendIEHeaders, appendTokenHeaders } from \"api/api\";\r\n\r\nimport {\r\n Api,\r\n NotificationSettingsReadDTO,\r\n NotificationTypeDTO,\r\n} from \"./__generated__/NotificationAPI\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NOTIFICATION;\r\n\r\nlet _clientSingleton: Api | null = null;\r\nconst client = (): Api => {\r\n if (!_clientSingleton) {\r\n _clientSingleton = new Api({\r\n baseUrl: PREFIX,\r\n baseApiParams: {\r\n headers: {\r\n Accept: \"application/json\",\r\n \"Content-Type\": \"application/json\",\r\n ...appendTokenHeaders(),\r\n ...appendIEHeaders(),\r\n },\r\n },\r\n });\r\n }\r\n return _clientSingleton;\r\n};\r\n\r\nfunction toData(res: { data: T }) {\r\n return res.data;\r\n}\r\n\r\nexport function getNotificationsByPpids(\r\n ppids: string[]\r\n): Promise {\r\n return client().api.v1NotificationByPpidsCreate(ppids).then(toData);\r\n}\r\n\r\nexport const getNotifications = (): Promise => {\r\n return client().api.v1NotificationList().then(toData);\r\n};\r\n\r\nexport const updateNotifications = (\r\n notifications: NotificationSettingsReadDTO\r\n) => {\r\n return client().api.v1NotificationUpdate(notifications).then(toData);\r\n};\r\n\r\nexport const getNotificationTypes = (): Promise => {\r\n return client().api.v1NotificationTypesList().then(toData);\r\n};\r\n\r\nexport const unsubscribe = () => {\r\n return client().api.v1NotificationUnsubscribeList().then(toData);\r\n};\r\n","export const threeWServiceIds = [\r\n process.env.REACT_APP_3WDISTIB_SERVICEID,\r\n process.env.REACT_APP_3WREG_SERVICEID,\r\n process.env.REACT_APP_3WTAX_SERVICEID,\r\n process.env.REACT_APP_3WAWM_SERVICEID,\r\n];\r\n\r\nfunction is3wService(id) {\r\n return threeWServiceIds.includes(id);\r\n}\r\n\r\nexport default is3wService;\r\n","export const NEWS_ADMIN_CHANGE_TAB = \"NEWS_ADMIN_CHANGE_TAB\";\r\nexport const newsAdminChangeTab = (tab) => {\r\n return {\r\n type: NEWS_ADMIN_CHANGE_TAB,\r\n payload: tab,\r\n };\r\n};\r\n","import { useCallback, useReducer } from \"react\";\r\n\r\nconst SORT_CHANGE = \"SORT_CHANGE\";\r\nconst PAGE_NUMBER_CHANGE = \"PAGE_NUMBER_CHANGE\";\r\nconst PAGE_SIZE_CHANGE = \"PAGE_SIZE_CHANGE\";\r\n\r\nfunction reducer(state, action) {\r\n switch (action.type) {\r\n case SORT_CHANGE:\r\n return {\r\n ...state,\r\n sorted: action.payload,\r\n };\r\n case PAGE_NUMBER_CHANGE:\r\n return {\r\n ...state,\r\n page: action.payload,\r\n };\r\n case PAGE_SIZE_CHANGE:\r\n return {\r\n ...state,\r\n page: action.payload.page,\r\n pageSize: action.payload.pageSize,\r\n };\r\n default:\r\n return state;\r\n }\r\n}\r\n\r\nconst pageChange = (page) => {\r\n return {\r\n type: PAGE_NUMBER_CHANGE,\r\n payload: page,\r\n };\r\n};\r\n\r\nconst pageSizeChange = (pageSize, page) => {\r\n return {\r\n type: PAGE_SIZE_CHANGE,\r\n payload: { pageSize, page },\r\n };\r\n};\r\n\r\nconst sortChange = (sort) => {\r\n return {\r\n type: SORT_CHANGE,\r\n payload: sort,\r\n };\r\n};\r\n\r\nfunction useTableReducer(sorted = [], page = 0, pageSize = 20) {\r\n const [state, dispatch] = useReducer(reducer, {\r\n sorted,\r\n page,\r\n pageSize,\r\n });\r\n\r\n const onPageSizeChange = useCallback(\r\n (pageSize, page) => dispatch(pageSizeChange(pageSize, page)),\r\n []\r\n );\r\n const onPageChange = useCallback((page) => dispatch(pageChange(page)), []);\r\n const onSortedChange = useCallback((sort) => dispatch(sortChange(sort)), []);\r\n\r\n return {\r\n onPageSizeChange,\r\n onPageChange,\r\n onSortedChange,\r\n state,\r\n };\r\n}\r\n\r\nexport default useTableReducer;\r\n","import useTableReducer from \"hooks/useTableReducer\";\r\nimport { useCallback, useEffect, useState } from \"react\";\r\n\r\nconst useData = (filters, apiCall, initialSorted, appendOrderWithName) => {\r\n const [data, setData] = useState({\r\n loading: true,\r\n items: null,\r\n totalCount: 0,\r\n });\r\n\r\n const tableReducer = useTableReducer(initialSorted);\r\n const { state, onPageChange } = tableReducer;\r\n\r\n const fetchData = useCallback(() => {\r\n setData((data) => ({\r\n ...data,\r\n loading: true,\r\n }));\r\n\r\n apiCall(\r\n {\r\n filters,\r\n orderBy: state.sorted.reduce((acc, sorted) => {\r\n acc[sorted.id + (appendOrderWithName ? \"Name\" : \"\")] = {\r\n isDescending: !!sorted.desc,\r\n };\r\n return acc;\r\n }, {}),\r\n },\r\n {\r\n pageNumber: state.page + 1,\r\n pageSize: state.pageSize,\r\n }\r\n ).then((data) => {\r\n if (Array.isArray(data)) {\r\n setData({\r\n loading: false,\r\n items: data,\r\n totalCount: data.length,\r\n pages:\r\n data?.length < state.pageSize ? state.page + 1 : Number.MAX_VALUE,\r\n });\r\n } else {\r\n const totalPages = Math.max(data.totalPages, 1);\r\n setData({\r\n ...data,\r\n totalPages,\r\n loading: false,\r\n });\r\n\r\n if (totalPages < state.page) {\r\n onPageChange(totalPages - 1);\r\n }\r\n }\r\n });\r\n }, [filters, state, onPageChange, apiCall, appendOrderWithName]);\r\n\r\n const optimisticChange = useCallback((newItem) => {\r\n setData((data) => {\r\n return {\r\n ...data,\r\n items: data.items.map((item) =>\r\n item.id === newItem.id ? newItem : item\r\n ),\r\n };\r\n });\r\n }, []);\r\n\r\n const setItems = useCallback((items) => {\r\n setData((prevData) => ({ ...prevData, items }));\r\n }, []);\r\n\r\n useEffect(() => {\r\n fetchData();\r\n }, [fetchData]);\r\n\r\n return {\r\n ...tableReducer,\r\n ...tableReducer.state,\r\n loading: data.loading,\r\n items: data.items,\r\n pages: data.totalPages ?? data.pages,\r\n setItems,\r\n fetchData,\r\n optimisticChange,\r\n };\r\n};\r\n\r\nexport default useData;\r\n","import \"./index.scss\";\r\n\r\nimport { Panel } from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\n\r\nconst CustomPanel = (props) => {\r\n const classes = classnames([\r\n \"a-custom-panel\",\r\n props.className ? props.className : \"\",\r\n ]);\r\n\r\n return (\r\n \r\n {props.children}\r\n \r\n );\r\n};\r\n\r\nexport default CustomPanel;\r\n","import \"./index.scss\";\r\n\r\nimport { Button, List, Tooltip } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport useClickOutside from \"hooks/useClickOutside\";\r\nimport { useCallback, useState } from \"react\";\r\n\r\nimport CustomPanel from \"./CustomPanel\";\r\n\r\nconst MenuList = ({ className, children, tooltip = \"Actions\", ...props }) => {\r\n const [open, setOpen] = useState(false);\r\n const close = useCallback(() => setOpen(false), []);\r\n const node = useClickOutside(open, close);\r\n\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n setOpen(false)}>{children}\r\n \r\n \r\n );\r\n};\r\n\r\nexport default MenuList;\r\n","import { apiFetch } from \"api/api\";\r\n\r\nconst PREFIX = `${process.env.REACT_APP_URL_CATALOG}/api/v1/`;\r\n\r\nexport function getTenant() {\r\n return apiFetch(`${PREFIX}Tenant/current`).catch(() =>\r\n JSON.parse(`{\r\n \"id\": \"719c8f26-848f-423a-8c87-9494d4ca283a\",\r\n \"name\": \"Managed Service Hub\",\r\n \"url\": \"https://amdigitalsolutions.pwc.lu/\",\r\n \"domain\": \"amdigitalsolutions.pwc.lu\"\r\n}`)\r\n );\r\n}\r\n\r\nexport function adminGetTenants() {\r\n return apiFetch(`${PREFIX}Tenant`);\r\n}\r\n","import HandledPromiseRejectionError from \"exceptions/handledPromiseRejectionError\";\r\n\r\nexport const imageFromBlob = (blob: any): any => {\r\n return new Promise((resolve) => {\r\n var reader = new FileReader();\r\n reader.readAsDataURL(blob);\r\n reader.onloadend = function () {\r\n resolve(reader.result);\r\n };\r\n reader.onerror = function () {\r\n throw new HandledPromiseRejectionError(\"Corrupted image received\");\r\n };\r\n });\r\n};\r\n","export default class HandledPromiseRejectionError extends Error {\r\n constructor(message = \"An error occured in the application\") {\r\n super(message);\r\n }\r\n}\r\n","export default __webpack_public_path__ + \"static/media/pwc-logo-simple.1f884484.svg\";","import \"./index.scss\";\r\n\r\nimport { MODULES, MODULE_VALUES } from \"constants/module\";\r\n\r\nimport { AuthenticationContext } from \"@axa-fr/react-oidc-context\";\r\nimport { DEFAULT_OIDC_KEY } from \"api/auth/config\";\r\nimport { Button } from \"appkit-react\";\r\nimport { Tooltip } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport PwcLogo from \"img/illustrations/pwc-logo-simple.svg\";\r\nimport { Component } from \"react\";\r\nimport { connect } from \"react-redux\";\r\nimport { withRouter } from \"react-router\";\r\n\r\nimport { getInitialsFromName } from \"../../utils/index\";\r\nimport AppLink from \"../AppLink\";\r\nimport AvatarWithAsyncPhoto from \"../AvatarWithAsyncPhoto\";\r\n\r\nconst outlineAction = {\r\n NOACTION: 0,\r\n CLICK: 1,\r\n CHANGE: 2,\r\n BLUR: 3,\r\n TAB: 4,\r\n};\r\n\r\nconst getProfileData = (props) => {\r\n if (props.loginUser) {\r\n return {\r\n name: props.loginUser.name,\r\n initials: getInitialsFromName(props.loginUser.name),\r\n photoUri: props.loginUser?.photoUri,\r\n };\r\n }\r\n return null;\r\n};\r\n\r\nexport const handleLogout = () => {\r\n let idToken = null;\r\n try {\r\n const oidcJson = JSON.parse(sessionStorage.getItem(DEFAULT_OIDC_KEY));\r\n idToken = oidcJson.id_token;\r\n } catch (error) {\r\n console.error(\"Error accessing JWT!\", error);\r\n }\r\n sessionStorage.removeItem(DEFAULT_OIDC_KEY);\r\n window.location.replace(\r\n `${\r\n process.env.REACT_APP_OID_LOGOUT_ROOT\r\n }?id_token_hint=${idToken}&post_logout_redirect_uri=${encodeURIComponent(\r\n `${window.location.origin}${process.env.REACT_APP_OID_POST_LOGOUT_REDIRECT_URI_SUFFIX}`\r\n )}`\r\n );\r\n};\r\n\r\nconst LogoutTooltip = (props) => {\r\n const profileData = getProfileData(props);\r\n if (!profileData) {\r\n return null;\r\n }\r\n return (\r\n
\r\n
\r\n \r\n {profileData.name}\r\n
\r\n \r\n
\r\n \r\n  My profile\r\n
\r\n
\r\n \r\n \r\n  Logout\r\n
\r\n {process.env.REACT_APP_SHOW_VERSION === \"true\" && (\r\n
\r\n version {process.env.REACT_APP_PACKAGE_VERSION}\r\n {process.env.REACT_APP_PACKAGE_HASH &&\r\n `-${process.env.REACT_APP_PACKAGE_HASH.substring(0, 8)}`}\r\n
\r\n )}\r\n \r\n );\r\n};\r\n\r\nclass HeaderContent extends Component {\r\n constructor() {\r\n super();\r\n this.state = {\r\n optionVal: \"1\",\r\n showValue: \"2\",\r\n hasOutLine: true,\r\n lastAction: outlineAction.NOACTION,\r\n };\r\n const self = this;\r\n this.keyEvent = function (e) {\r\n if (e.keyCode === 9) {\r\n // Tab key\r\n self.setState({\r\n lastAction: outlineAction.BLUR,\r\n hasOutLine: true,\r\n });\r\n }\r\n };\r\n }\r\n\r\n componentDidMount() {\r\n window.addEventListener(\"keydown\", this.keyEvent, false);\r\n }\r\n\r\n componentWillUnmount() {\r\n window.removeEventListener(\"keydown\", this.keyEvent, false);\r\n }\r\n\r\n handleSelect(val) {\r\n this.setState({\r\n showValue: val,\r\n });\r\n }\r\n\r\n onMouseDown = () => {\r\n this.setState({\r\n hasOutLine: false,\r\n lastAction: outlineAction.CLICK,\r\n });\r\n };\r\n\r\n onBlur = () => {\r\n const { lastAction } = this.state;\r\n if (lastAction === outlineAction.CLICK) {\r\n this.setState({\r\n hasOutLine: false,\r\n lastAction: outlineAction.BLUR,\r\n });\r\n } else {\r\n this.setState({\r\n hasOutLine: true,\r\n lastAction: outlineAction.BLUR,\r\n });\r\n }\r\n };\r\n\r\n render() {\r\n const showSettings =\r\n process.env.REACT_APP_HIDE_MODULES_NON_LUX === \"1\"\r\n ? this.props.loginUser?.isLu\r\n : this.props.loginUser?.isInternal;\r\n\r\n const backgroundColor = process.env.REACT_APP_ENV_COLOR\r\n ? process.env.REACT_APP_ENV_COLOR\r\n : null;\r\n\r\n return (\r\n <>\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n {`${this.props.hostInfo.name}${\r\n process.env.REACT_APP_APP_NAME_SUFFIX\r\n ? ` ${process.env.REACT_APP_APP_NAME_SUFFIX}`\r\n : \"\"\r\n }`}\r\n \r\n\r\n
\r\n
\r\n {showSettings && (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n )}\r\n\r\n }\r\n trigger=\"click\"\r\n refClassName=\"a-account-info\"\r\n className=\"a-account-options\"\r\n tooltipTheme=\"light\"\r\n clickToClose\r\n style={{ zIndex: 100 }}\r\n containerid=\"a-actions-container\"\r\n placement=\"bottom-end\"\r\n >\r\n {(() => {\r\n const profileData = getProfileData(this.props);\r\n return profileData ? (\r\n \r\n ) : (\r\n \r\n );\r\n })()}\r\n \r\n
\r\n \r\n
\r\n \r\n );\r\n }\r\n}\r\n\r\nconst mapStateToProps = (state) => {\r\n return {\r\n loginUser: state.global.data.loginUser,\r\n hostInfo: state.global.data.hostInfo,\r\n };\r\n};\r\n\r\nconst ConnectedHeaderContent = connect(mapStateToProps, {})(HeaderContent);\r\n\r\nconst Header = (props) => {\r\n return (\r\n
\r\n \r\n {(oidcProps) => }\r\n \r\n
\r\n );\r\n};\r\n\r\nexport default withRouter(Header);\r\n","import { toUTCISODateString } from \"api/helpers\";\r\n\r\nimport { blankRawDraft } from \"../../utils/draftjs\";\r\nimport {\r\n toDateRangeFilter,\r\n toSafeNumberFilter,\r\n toTextFilter,\r\n} from \"../helpers/filters\";\r\n\r\nexport const adaptArticleFromBackEnd = (oldData) => {\r\n let newData = { ...oldData };\r\n // Adapt dates\r\n if (newData.publishDate) {\r\n newData.publishDate = new Date(newData.publishDate);\r\n }\r\n if (newData.creationDate) {\r\n newData.creationDate = new Date(newData.creationDate);\r\n }\r\n if (newData.lastUpdateDate) {\r\n newData.lastUpdateDate = new Date(newData.lastUpdateDate);\r\n }\r\n if (newData.startDate) {\r\n newData.startDate = new Date(newData.startDate);\r\n }\r\n if (newData.endDate) {\r\n newData.endDate = new Date(newData.endDate);\r\n }\r\n\r\n newData.businessId = oldData.businessId.toString();\r\n\r\n // Adapt draftjs content\r\n newData.description = Object.entries(oldData.description).reduce(\r\n (acc, [key, content]) => {\r\n try {\r\n acc[key] = JSON.parse(content);\r\n } catch (e) {\r\n console.error(\r\n `Error while parsing content for article (field: '${key}')`,\r\n e\r\n );\r\n acc[key] = { ...blankRawDraft };\r\n }\r\n\r\n return acc;\r\n },\r\n {}\r\n );\r\n\r\n return newData;\r\n};\r\n\r\nexport const adaptArticleToBackEnd = (oldData) => {\r\n let newData = { ...oldData };\r\n // Adapt dates\r\n if (newData.publishDate) {\r\n newData.publishDate = toUTCISODateString(newData.publishDate);\r\n }\r\n\r\n newData.businessId = parseInt(oldData.businessId);\r\n\r\n newData.description = Object.entries(oldData.description).reduce(\r\n (acc, [key, content]) => {\r\n acc[key] = JSON.stringify(content);\r\n return acc;\r\n },\r\n {}\r\n );\r\n return newData;\r\n};\r\n\r\nexport const toApiFilter = (filters) => {\r\n const {\r\n type,\r\n territories,\r\n issuers,\r\n topics,\r\n documentTypes,\r\n published,\r\n publishDateRange,\r\n linkedNewsDateRange,\r\n freeTextSearch,\r\n businessId,\r\n checkedEventDates,\r\n } = filters;\r\n\r\n const businessIdFilters = parseInt(businessId);\r\n\r\n return {\r\n type,\r\n territories,\r\n issuers,\r\n topics,\r\n documentTypes,\r\n published,\r\n checkedEventDates,\r\n publishDateRange: toDateRangeFilter(publishDateRange),\r\n linkedNewsDateRange: toDateRangeFilter(linkedNewsDateRange),\r\n freeTextSearch: toTextFilter(freeTextSearch),\r\n businessId: toSafeNumberFilter(businessIdFilters),\r\n clientNoteFilter: filters.clientNoteFilter,\r\n pwcNoteFilter: filters.pwcNoteFilter,\r\n };\r\n};\r\n","import { downloadBlob } from \"utils/\";\r\n\r\nimport { RET_RAW, apiFetch, apiFetchFormData } from \"../api\";\r\nimport {\r\n adaptArticleFromBackEnd,\r\n adaptArticleToBackEnd,\r\n toApiFilter,\r\n} from \"./articleDataManipulators\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT;\r\n\r\nconst PREFIX_3W = PREFIX + \"Article3W/\";\r\n\r\nconst PREFIX_GLOBAL = PREFIX + \"ArticleGlobal/\";\r\n\r\nexport const ARTICLE_TYPES = {\r\n \"3W\": 0,\r\n GLOBAL: 1,\r\n};\r\n\r\nconst getPrefixFromType = (type) => {\r\n switch (type) {\r\n case ARTICLE_TYPES[\"3W\"]:\r\n return PREFIX_3W;\r\n case ARTICLE_TYPES.GLOBAL:\r\n return PREFIX_GLOBAL;\r\n default:\r\n throw new Error(\"No valid type specified\");\r\n }\r\n};\r\n\r\nexport const genericGetList = (\r\n filters,\r\n { pageNumber = 1, pageSize = 6 },\r\n newsType\r\n) => {\r\n return apiFetch(\r\n `${getPrefixFromType(\r\n newsType\r\n )}paged?pageNumber=${pageNumber}&pageSize=${pageSize}`,\r\n { filters: toApiFilter(filters.filters), orderBy: filters.orderBy },\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const genericDeleteArticle = (id, newsType) => {\r\n return apiFetch(`${getPrefixFromType(newsType)}${id}`, undefined, \"DELETE\");\r\n};\r\n\r\nexport const genericGetArticle = (articleId, newsType) => {\r\n return apiFetch(`${getPrefixFromType(newsType)}${articleId}`).then((data) =>\r\n adaptArticleFromBackEnd(data)\r\n );\r\n};\r\n\r\nexport const genericUpdateArticle = async (article, newsType) => {\r\n const adaptedArticle = adaptArticleToBackEnd(article);\r\n return await apiFetch(\r\n `${getPrefixFromType(newsType)}/${article.id}`,\r\n adaptedArticle,\r\n \"PUT\"\r\n );\r\n};\r\n\r\nexport const genericCreateArticle = async (article, newsType) => {\r\n const data = await apiFetch(\r\n `${getPrefixFromType(newsType)}`,\r\n adaptArticleToBackEnd(article),\r\n \"POST\"\r\n );\r\n return adaptArticleFromBackEnd(data);\r\n};\r\n\r\nexport const genericPublishArticle = async (id, publish, newsType) => {\r\n return apiFetch(\r\n `${getPrefixFromType(newsType)}${id}/publish`,\r\n publish.toString(),\r\n \"PATCH\"\r\n );\r\n};\r\n\r\nexport const genericGetBusinessId = (type, newsType) => {\r\n return apiFetch(`${getPrefixFromType(newsType)}nextBusinessId/${type}`);\r\n};\r\n\r\nexport const getNewsPermissions = () => {\r\n return apiFetch(`${PREFIX}Metadata/types`);\r\n};\r\n\r\nexport const getUsedMetadataForType = (type) => {\r\n return apiFetch(`${PREFIX}Metadata/used/${type}`);\r\n};\r\n\r\nexport const downloadTemplate = () => {\r\n return apiFetch(`${PREFIX_3W}import`, undefined, \"GET\", RET_RAW)\r\n .then((res) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"import_article_template.xlsx\"));\r\n};\r\n\r\nexport const importArticlesFromExcel = (file) => {\r\n return apiFetchFormData(`${PREFIX_3W}import`, { importFile: file }, \"POST\");\r\n};\r\n\r\nexport const getClientNote = (articleId) => {\r\n return apiFetch(`${PREFIX_3W}${articleId}/ClientNote`);\r\n};\r\n\r\nexport const getClientNoteFromSubscription = (articleId, subscriptionId) => {\r\n return apiFetch(`${PREFIX_3W}${articleId}/ClientNote/${subscriptionId}`);\r\n};\r\n\r\nexport const updateClientNote = (articleId, clientNoteContent) => {\r\n return apiFetch(\r\n `${PREFIX_3W}${articleId}/ClientNote`,\r\n clientNoteContent,\r\n \"PUT\"\r\n );\r\n};\r\n\r\nexport const updateClientNotePersonal = (articleId, note, assignToMe) => {\r\n return apiFetch(\r\n `${PREFIX_3W}${articleId}/ClientNote/Personal`,\r\n {\r\n assignedToMe: assignToMe,\r\n personalComments: note,\r\n },\r\n \"PUT\"\r\n );\r\n};\r\n\r\nexport const getPwcNote = (articleId) => {\r\n return apiFetch(`${PREFIX_3W}${articleId}/PwCNote`);\r\n};\r\n\r\nexport const updatePwcNote = (articleId, content) => {\r\n return apiFetch(`${PREFIX_3W}${articleId}/PwCNote`, content, \"PUT\");\r\n};\r\n\r\nexport const getAllPwcNotes = (articleId) => {\r\n return apiFetch(`${PREFIX_3W}${articleId}/PwCNote/All`);\r\n};\r\n","import { toDateRangeFilter, toTextFilter } from \"api/helpers/filters\";\r\n\r\nexport const toApiFilter = ({\r\n type,\r\n territories,\r\n issuers,\r\n topics,\r\n documentTypes,\r\n published,\r\n mustRead,\r\n issuedDateRange,\r\n freeTextSearch,\r\n exportAsSubscriptionId,\r\n publishedDateRange,\r\n withExtendedInfos,\r\n}) => {\r\n return {\r\n type,\r\n territories,\r\n issuers,\r\n topics,\r\n documentTypes,\r\n published,\r\n mustRead,\r\n issuedDateRange: toDateRangeFilter(issuedDateRange),\r\n freeTextSearch: toTextFilter(freeTextSearch),\r\n exportAsSubscriptionId,\r\n publishedDateRange,\r\n withExtendedInfos,\r\n };\r\n};\r\n","import { RET_RAW, apiFetch } from \"../api\";\r\nimport { toApiFilter } from \"./exportNewsDataManipulator\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_EXPORT_NEWS_ROOT;\r\n\r\nexport const exportAllToExcel = (filters) => {\r\n return apiFetch(`${PREFIX}all/excel`, toApiFilter(filters), \"POST\", RET_RAW);\r\n};\r\n\r\nexport const exportAllToWord = (filters) => {\r\n return apiFetch(`${PREFIX}all/word`, toApiFilter(filters), \"POST\", RET_RAW);\r\n};\r\n\r\nexport const exportArticlesToExcel = (articleIds) => {\r\n return apiFetch(`${PREFIX}article/excel`, articleIds, \"POST\", RET_RAW);\r\n};\r\n\r\nexport const exportSelectedNewsToExcel = (articleIds) => {\r\n return apiFetch(`${PREFIX}news/selected/excel`, articleIds, \"POST\", RET_RAW);\r\n};\r\n\r\nexport const exportFilteredNewsToExcel = (filters) => {\r\n return apiFetch(`${PREFIX}news/filtered/excel`, filters, \"POST\", RET_RAW);\r\n};\r\n\r\nexport const exportSelectedEventsToExcel = (eventIds) => {\r\n return apiFetch(`${PREFIX}event/selected/excel`, eventIds, \"POST\", RET_RAW);\r\n};\r\n\r\nexport const exportFilteredEventsToExcel = (filters) => {\r\n return apiFetch(`${PREFIX}event/filtered/excel`, filters, \"POST\", RET_RAW);\r\n};\r\n\r\nexport const exportType = (type) => {\r\n return apiFetch(`${PREFIX}right/excel/${type}`, null, \"POST\", RET_RAW);\r\n};\r\n","export const trimMime = (b64) => {\r\n let splitedValue = b64.split(\",\");\r\n if (splitedValue.length > 1) {\r\n return splitedValue[1];\r\n }\r\n return b64;\r\n};\r\n\r\nexport const getBase64ImageWeight = (b64) => {\r\n let result = trimMime(b64);\r\n let trailingEquals = 0;\r\n for (trailingEquals; trailingEquals < result.length; trailingEquals++) {\r\n if (result[result.length - 1 - trailingEquals] !== \"=\") {\r\n break;\r\n }\r\n }\r\n return result.length * (3 / 4) - trailingEquals;\r\n};\r\n","import \"react-image-crop/lib/ReactCrop.scss\";\r\n\r\nimport \"./index.scss\";\r\n\r\nimport {\r\n Button,\r\n Modal,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n} from \"appkit-react\";\r\nimport { useEffect, useState } from \"react\";\r\nimport ReactCrop from \"react-image-crop\";\r\n\r\nconst ImageCropperModal = ({\r\n image,\r\n visible,\r\n onValidate,\r\n onCancel,\r\n aspect = null,\r\n}) => {\r\n const [crop, setCrop] = useState({\r\n aspect: aspect,\r\n unit: \"%\",\r\n width: 100,\r\n });\r\n\r\n const [imageRef, setImageRef] = useState(null);\r\n\r\n useEffect(() => {\r\n setTimeout(() => {\r\n setCrop({\r\n aspect: aspect,\r\n unit: \"%\",\r\n width: 100,\r\n });\r\n }, 300);\r\n }, [image, aspect]);\r\n\r\n const onSubmit = async () => {\r\n if (!(crop.width && crop.height)) {\r\n onValidate(image);\r\n return;\r\n }\r\n onValidate(await makeClientCrop());\r\n };\r\n\r\n const getCroppedImg = (image, crop) => {\r\n const canvas = document.createElement(\"canvas\");\r\n const scaleX = image.naturalWidth / image.width;\r\n const scaleY = image.naturalHeight / image.height;\r\n canvas.width = crop.width;\r\n canvas.height = crop.height;\r\n const ctx = canvas.getContext(\"2d\");\r\n\r\n ctx.drawImage(\r\n image,\r\n crop.x * scaleX,\r\n crop.y * scaleY,\r\n crop.width * scaleX,\r\n crop.height * scaleY,\r\n 0,\r\n 0,\r\n crop.width,\r\n crop.height\r\n );\r\n\r\n return new Promise((resolve, reject) => {\r\n canvas.toBlob((blob) => {\r\n if (!blob) {\r\n reject(new Error(\"Canvas is empty\"));\r\n return;\r\n }\r\n var reader = new FileReader();\r\n reader.readAsDataURL(blob);\r\n reader.onloadend = function () {\r\n resolve(reader.result);\r\n };\r\n }, \"image/png\");\r\n });\r\n };\r\n\r\n const makeClientCrop = async () => {\r\n if (crop.width && crop.height) {\r\n return await getCroppedImg(imageRef, crop);\r\n }\r\n };\r\n\r\n const originalIsValidRatio = () => {\r\n if (aspect !== null && imageRef !== null) {\r\n return (\r\n Math.abs(imageRef.naturalWidth / imageRef.naturalHeight - aspect) <=\r\n 0.000000001\r\n );\r\n }\r\n };\r\n\r\n return (\r\n \r\n \r\n
Crop Image
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n Validate\r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default ImageCropperModal;\r\n","import \"./index.scss\";\r\n\r\nimport { PopBanner } from \"appkit-react\";\r\nimport { useEffect, useRef, useState } from \"react\";\r\n\r\nimport { trimMime as applyTrimMime } from \"../../utils/base64image\";\r\nimport { formatBytes } from \"../../utils/index\";\r\nimport ImageCropperModal from \"./ImageCropperModal\";\r\n\r\nlet timeout = false;\r\n\r\nconst availableMIMETypes = [\"image/bmp\", \"image/jpeg\", \"image/png\"];\r\nconst INVALID_IMAGE_ERROR =\r\n \"The selected file doesn't seem to be a valid image.\";\r\n\r\nconst isValidImage = (imageSrc) => {\r\n return new Promise((resolve) => {\r\n var image = new Image();\r\n image.onload = function () {\r\n resolve(true);\r\n };\r\n image.onerror = function () {\r\n resolve(false);\r\n };\r\n image.src = imageSrc;\r\n });\r\n};\r\n\r\nconst defaultInvalidImageAction = (message) => {\r\n PopBanner({\r\n content: {message},\r\n duration: 4000,\r\n status: \"warning\",\r\n });\r\n};\r\n\r\nconst defaultSizeExceededAction = (size, maxSize) => {\r\n PopBanner({\r\n content: (\r\n {`Your file is too heavy. Please submit a file smaller than ${formatBytes(\r\n maxSize\r\n )} (Your file was ${formatBytes(size)})`}\r\n ),\r\n duration: 4000,\r\n status: \"warning\",\r\n });\r\n};\r\n\r\nconst ImageUploadToBase64 = ({\r\n onChange,\r\n onError = defaultInvalidImageAction,\r\n trimMime = false,\r\n maxSize = null,\r\n onSizeExceeded = defaultSizeExceededAction,\r\n openCropAfterSelect = false,\r\n cropRatio = null,\r\n onCropOpened = () => {},\r\n onCropCanceled = () => {},\r\n}) => {\r\n const inputRef = useRef();\r\n\r\n const [isDragging, setIsDragging] = useState(false);\r\n const [isCropping, setIsCropping] = useState(null);\r\n\r\n const addDragListener = () => {\r\n window.addEventListener(\"dragover\", onDragOver);\r\n };\r\n\r\n const addDragEndListener = () => {\r\n window.addEventListener(\"dragleave\", onDragOut);\r\n window.addEventListener(\"drop\", onDragOut);\r\n };\r\n\r\n const removeDragListener = () => {\r\n window.removeEventListener(\"dragover\", onDragOver);\r\n };\r\n\r\n const removeDragEndListener = () => {\r\n window.removeEventListener(\"dragleave\", onDragOut);\r\n window.removeEventListener(\"drop\", onDragOut);\r\n };\r\n\r\n const onDragOver = () => {\r\n timeout = true;\r\n setIsDragging(true);\r\n removeDragListener();\r\n addDragEndListener();\r\n };\r\n\r\n const onDragOut = () => {\r\n timeout = false;\r\n setTimeout(() => {\r\n if (!timeout) {\r\n setIsDragging(false);\r\n }\r\n }, 50);\r\n removeDragEndListener();\r\n addDragListener();\r\n };\r\n\r\n useEffect(() => {\r\n addDragListener();\r\n // eslint-disable-next-line\r\n }, []);\r\n\r\n const onBase64Change = (newValue) => {\r\n if (trimMime) {\r\n newValue = applyTrimMime(newValue);\r\n }\r\n if (openCropAfterSelect) {\r\n setIsCropping(newValue);\r\n onCropOpened();\r\n } else {\r\n onChange(newValue);\r\n }\r\n };\r\n\r\n const onChangeInput = (event) => {\r\n if (event.target && event.target.files && event.target.files[0]) {\r\n const file = event.target.files[0];\r\n if (maxSize !== null && file.size > maxSize) {\r\n onSizeExceeded(file.size, maxSize);\r\n inputRef.current.value = null;\r\n return;\r\n }\r\n if (!availableMIMETypes.includes(file.type)) {\r\n onError(INVALID_IMAGE_ERROR);\r\n return;\r\n }\r\n\r\n const reader = new FileReader();\r\n\r\n const eventFunction = () => {\r\n isValidImage(reader.result).then((result) => {\r\n if (!result) {\r\n onError(INVALID_IMAGE_ERROR);\r\n inputRef.current.value = null;\r\n return;\r\n }\r\n onBase64Change(reader.result);\r\n reader.removeEventListener(\"load\", eventFunction);\r\n });\r\n };\r\n\r\n reader.addEventListener(\"load\", eventFunction, false);\r\n\r\n reader.readAsDataURL(file);\r\n inputRef.current.value = null;\r\n }\r\n };\r\n\r\n return (\r\n <>\r\n {openCropAfterSelect && (\r\n {\r\n setIsCropping(null);\r\n onCropCanceled();\r\n }}\r\n onValidate={(newImage) => {\r\n setIsCropping(null);\r\n onChange(newImage);\r\n }}\r\n aspect={cropRatio}\r\n />\r\n )}\r\n\r\n \r\n \r\n );\r\n};\r\n\r\nexport default ImageUploadToBase64;\r\n","export default __webpack_public_path__ + \"static/media/icons-outline-start-tour-fill.44de689a.svg\";","export default __webpack_public_path__ + \"static/media/icons-outline-start-tour.14f1c2d3.svg\";","export function fromUserModel(user) {\r\n const { phoneCountryCode, phoneNumber, ...data } = user;\r\n data.phone = { code: phoneCountryCode || \"\", number: phoneNumber || \"\" };\r\n\r\n return data;\r\n}\r\n\r\nexport function toUserModel(view) {\r\n const { phone, ...data } = view;\r\n if (phone.number?.trim().length > 0) {\r\n data.phoneCountryCode = phone.code;\r\n data.phoneNumber = phone.number.replaceAll(\" \", \"\");\r\n }\r\n\r\n return data;\r\n}\r\n","export const ARTICLE_TYPES = {\r\n THREEW_FUND_DISTRI: 0,\r\n THREEW_REG: 1,\r\n THREEW_TAX: 2,\r\n THREEW_AWM: 3,\r\n};\r\n\r\nexport const ARTICLE_CLASSNAME = {\r\n [ARTICLE_TYPES.THREEW_FUND_DISTRI]: \"threew-funddistri\",\r\n [ARTICLE_TYPES.THREEW_REG]: \"threew-reg\",\r\n [ARTICLE_TYPES.THREEW_TAX]: \"threew-tax\",\r\n [ARTICLE_TYPES.THREEW_AWM]: \"threew-awm\",\r\n};\r\n\r\nexport const ARTICLE_SERVICE = {\r\n [ARTICLE_TYPES.THREEW_FUND_DISTRI]: process.env.REACT_APP_3WDISTIB_SERVICEID,\r\n [ARTICLE_TYPES.THREEW_REG]: process.env.REACT_APP_3WREG_SERVICEID,\r\n [ARTICLE_TYPES.THREEW_TAX]: process.env.REACT_APP_3WTAX_SERVICEID,\r\n [ARTICLE_TYPES.THREEW_AWM]: null,\r\n};\r\n\r\nexport const ARTICLES_LABELS = {\r\n [ARTICLE_TYPES.THREEW_FUND_DISTRI]: \"3W Fund Distribution\",\r\n [ARTICLE_TYPES.THREEW_REG]: \"3W Regulatory\",\r\n [ARTICLE_TYPES.THREEW_TAX]: \"3W Tax\",\r\n [ARTICLE_TYPES.THREEW_AWM]: \"3W Tax - PwC Internal Database\",\r\n};\r\n\r\nexport const SECTION_TITLES = {\r\n background: \"Background\",\r\n whatsNew: \"What's new?\",\r\n whatsNext: \"What's next?\",\r\n freeContent: \"\",\r\n};\r\n\r\nexport const PERMISSION_TYPES = {\r\n READ: \"READ\",\r\n WRITE: \"WRITE\",\r\n DELETE: \"DELETE\",\r\n};\r\n\r\nexport const DEFAULT_PAGINATION = { pageNumber: 1, pageSize: 15 };\r\n","import { useEffect } from \"react\";\r\nimport { useDispatch, useSelector, useStore } from \"react-redux\";\r\nimport {\r\n articlesInitNewsAdmin,\r\n articlesSetPermissions,\r\n} from \"redux/actions/articles\";\r\nimport { INITIALIZE } from \"redux/constants\";\r\n\r\nconst useNewsAdminInitialize = (triggerInit = true) => {\r\n const dispatch = useDispatch();\r\n const newsAdminInitialized = useSelector(\r\n (state) => state.articles.data.newsAdminInitialized\r\n );\r\n const store = useStore();\r\n\r\n useEffect(() => {\r\n if (\r\n store.getState().articles.data.newsAdminInitialized ===\r\n INITIALIZE.FALSE &&\r\n triggerInit\r\n ) {\r\n dispatch(articlesInitNewsAdmin());\r\n dispatch(articlesSetPermissions());\r\n }\r\n }, [store, dispatch, triggerInit]);\r\n\r\n return newsAdminInitialized === INITIALIZE.TRUE;\r\n};\r\n\r\nexport default useNewsAdminInitialize;\r\n","import { toUTCISODateString } from \"api/helpers\";\r\nimport { toDateRangeFilter, toTextFilter } from \"api/helpers/filters\";\r\nimport { isArray, isObject } from \"lodash\";\r\n\r\nexport const toApiFilter = (filters) => {\r\n const {\r\n type,\r\n territories,\r\n issuers,\r\n topics,\r\n documentTypes,\r\n published,\r\n mustRead,\r\n issuedDateRange,\r\n freeTextSearch,\r\n repositoryItem,\r\n isAlive,\r\n } = filters;\r\n return {\r\n type,\r\n territories,\r\n issuers,\r\n topics,\r\n documentTypes,\r\n published,\r\n mustRead,\r\n repositoryItem,\r\n isAlive,\r\n issuedDateRange: toDateRangeFilter(issuedDateRange),\r\n freeTextSearch: toTextFilter(freeTextSearch),\r\n };\r\n};\r\n\r\nexport function adaptNewsToBackEnd(oldNews) {\r\n const news = { ...oldNews };\r\n\r\n if (oldNews.issueDate) {\r\n news.issueDate = toUTCISODateString(oldNews.issueDate);\r\n }\r\n news.repositoryText = isObject(oldNews.repositoryText)\r\n ? JSON.stringify(oldNews.repositoryText)\r\n : oldNews.repositoryText;\r\n\r\n return news;\r\n}\r\n\r\nexport function adaptNewsFromBackend(news) {\r\n function _adaptNewsFromBackend(_new) {\r\n return {\r\n ..._new,\r\n repositoryText: _new.repositoryText\r\n ? JSON.parse(_new.repositoryText)\r\n : _new.repositoryText,\r\n };\r\n }\r\n return isArray(news)\r\n ? news.map((_new) => _adaptNewsFromBackend(_new))\r\n : _adaptNewsFromBackend(news);\r\n}\r\n","import { downloadBlob } from \"utils\";\r\n\r\nimport { RET_RAW, apiFetch, apiFetchFormData } from \"../api\";\r\nimport {\r\n adaptNewsFromBackend,\r\n adaptNewsToBackEnd,\r\n toApiFilter,\r\n} from \"./newsDataManipulator\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT + \"News/\";\r\n\r\nexport const getList = (\r\n filters,\r\n pagination = { pageNumber: 1, pageSize: 6 }\r\n) => {\r\n return apiFetch(\r\n `${PREFIX}paged?pageNumber=${pagination.pageNumber}&pageSize=${pagination.pageSize}`,\r\n { filters: toApiFilter(filters.filters), orderBy: filters.orderBy },\r\n \"POST\"\r\n ).then(adaptNewsFromBackend);\r\n};\r\n\r\nexport const getDashboard = (filters) => {\r\n return apiFetch(\r\n `${process.env.REACT_APP_URL_NEWS_ROOT}Dashboard`,\r\n filters,\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const getListByArticle = (articleId) => {\r\n return apiFetch(`${PREFIX}byArticle/${articleId}`);\r\n};\r\n\r\nexport const getNews = (newsId) => {\r\n return apiFetch(`${PREFIX}${newsId}`).then(adaptNewsFromBackend);\r\n};\r\n\r\nexport const getNewsTitlesFromIds = (articleIds) => {\r\n return apiFetch(`${PREFIX}titles`, articleIds, \"POST\");\r\n};\r\n\r\nexport const addNews = (news) => {\r\n return apiFetch(PREFIX, adaptNewsToBackEnd(news), \"POST\");\r\n};\r\n\r\nexport const updateNews = (news) => {\r\n return apiFetch(`${PREFIX}${news.id}`, adaptNewsToBackEnd(news), \"PUT\");\r\n};\r\n\r\nexport const deleteNews = (newsId) => {\r\n return apiFetch(`${PREFIX}${newsId}`, undefined, \"DELETE\");\r\n};\r\n\r\nexport const publishNews = (id, publish) => {\r\n return apiFetch(`${PREFIX}${id}/published`, publish.toString(), \"PATCH\");\r\n};\r\n\r\nexport const setArticleId = (newsIds, articleId) => {\r\n return apiFetch(\r\n `${PREFIX}ArticleId`,\r\n {\r\n ids: newsIds,\r\n articleId,\r\n },\r\n \"PATCH\"\r\n );\r\n};\r\n\r\nexport const isAlive = (newsId) => {\r\n return apiFetch(`${PREFIX}${newsId}/IsAlive`, undefined, \"PATCH\");\r\n};\r\n\r\nexport const downloadTemplate = () => {\r\n return apiFetch(`${PREFIX}import`, undefined, \"GET\", RET_RAW)\r\n .then((res) => res.blob())\r\n .then((blob) => downloadBlob(blob, \"import_news_template.xlsx\"));\r\n};\r\n\r\nexport const importNewsFromExcel = (file) => {\r\n return apiFetchFormData(`${PREFIX}import`, { importFile: file }, \"POST\");\r\n};\r\n","import { dataURItoBlob } from \"api/helpers\";\r\n\r\nimport { MIME_PNG } from \"../../constants\";\r\n\r\nexport const adaptDataToBackend = (data) => {\r\n return {\r\n ...data,\r\n image: data.image ? dataURItoBlob(data.image, MIME_PNG) : null,\r\n };\r\n};\r\n","import { imageFromBlob } from \"api/utils\";\r\n\r\nimport { RET_RAW, apiFetch, apiFetchFormData } from \"../api\";\r\nimport { adaptDataToBackend } from \"./publicationsManipulators\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT + \"Publication/\";\r\n\r\nexport const getList = (filters, { pageNumber = 1, pageSize = 20 }) => {\r\n return apiFetch(\r\n `${PREFIX}paged?pageNumber=${pageNumber}&pageSize=${pageSize}`,\r\n filters,\r\n \"POST\"\r\n );\r\n};\r\n\r\nexport const getPublication = (id) => {\r\n return apiFetch(`${PREFIX}${id}`);\r\n};\r\n\r\nexport const deletePublication = (id) => {\r\n return apiFetch(`${PREFIX}${id}`, undefined, \"DELETE\");\r\n};\r\n\r\nexport const updatePublication = async (publication) => {\r\n return apiFetchFormData(\r\n `${PREFIX}${publication.id}`,\r\n adaptDataToBackend(publication),\r\n \"PUT\"\r\n );\r\n};\r\n\r\nexport const createPublication = (publication) => {\r\n return apiFetchFormData(`${PREFIX}`, adaptDataToBackend(publication), \"POST\");\r\n};\r\n\r\nexport const publishPublication = async (id, publish) => {\r\n return apiFetch(`${PREFIX}${id}/publish`, publish.toString(), \"PATCH\");\r\n};\r\n\r\nexport const getImage = (imageUrl) => {\r\n return apiFetch(`${PREFIX}${imageUrl}`, undefined, \"GET\", RET_RAW)\r\n .then((data) => data.blob())\r\n .then(imageFromBlob);\r\n};\r\n","export const DOWNLOAD_PUBLICATION_BASEURL = \"/download/publication/\";\r\n","const { apiFetch, RET_RAW } = require(\"api/api\");\r\nconst { imageFromBlob } = require(\"components/ImageUploadToBase64\");\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_DATA;\r\n\r\nexport const getFile = (uri) => {\r\n return apiFetch(`${PREFIX}${uri}`, undefined, \"GET\", RET_RAW, {\r\n \"Access-Control-Request-Headers\":\r\n \"Content-Disposition, Content-Type, x-requested-with\",\r\n });\r\n};\r\n\r\nexport const getData = (uri) => {\r\n return getFile(uri)\r\n .then((data) => data.blob())\r\n .then(imageFromBlob);\r\n};\r\n","import { formatDate } from \"utils/date\";\r\n\r\nexport const defaultFilename = (type) =>\r\n `export_${formatDate(new Date(), \"YYY-MM-DD_HH-mm\")}.${\r\n type === \"excel\" ? \"xlsx\" : \"docx\"\r\n }`;\r\n","import \"./index.scss\";\r\n\r\nimport CalendarPicker from \"appkit-react-datepicker/lib/CalendarPicker\";\r\nimport classNames from \"classnames\";\r\n\r\nconst ClearableCalendarPicker = ({\r\n onClearValue,\r\n hasError = false,\r\n errMsg = undefined,\r\n ...props\r\n}) => {\r\n return (\r\n
\r\n
\r\n \r\n {props.value && onClearValue && (\r\n \r\n )}\r\n
\r\n {hasError && errMsg && typeof errMsg === \"string\" ? (\r\n

{errMsg}

\r\n ) : null}\r\n
\r\n );\r\n};\r\n\r\nexport default ClearableCalendarPicker;\r\n","import { ApplicationCreateDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\n\r\nexport enum ServiceType {\r\n RECURRING = 1,\r\n CONSULTING = 2,\r\n DATA_DRIVEN = 3,\r\n}\r\n\r\nexport enum ServiceTag {\r\n MANCO = 1,\r\n FUND = 2,\r\n INVESTORS = 3,\r\n INTERMEDIARY_VEHICLES = 4,\r\n INVESTMENTS = 5,\r\n DISTRIBUTION = 6,\r\n THIRD_PARTIES = 7,\r\n REPORTING = 8,\r\n CORPORATE_SECRETARY = 9,\r\n LIQUIDATION = 10,\r\n\r\n PORTFOLIO_MANAGEMENT = 11,\r\n RISK_MANAGEMENT = 12,\r\n VALUATION = 13,\r\n COMPLIANCE = 14,\r\n DELEGATES = 15,\r\n REPORTING_MANAGEMENT = 16,\r\n FINANCE_ACCOUNTING_TAX = 17,\r\n INTERNAL_AUDIT = 18,\r\n DISTRIBUTION_MANAGEMENT = 19,\r\n IT_DATA_MANAGEMENT = 20,\r\n}\r\n\r\nexport interface CatalogueTags {\r\n industries: string[];\r\n}\r\n\r\n// ServiceCreateDTO and ServiceUpdateDTO was previously automatically generated in CalatogueAPI.ts, but once the body type has been switched from json to form data, theses types are not generated anymore\r\nexport interface ServiceUpdateDTO {\r\n TeamPpids?: string[];\r\n ResponsiblesPpids?: string[];\r\n Organizations?: string[];\r\n Applications?: ApplicationCreateDTO[];\r\n Industries?: string[];\r\n IllustrationsToAdd?: File[];\r\n IllustrationsToRemove?: string[];\r\n RelatedServices?: string[];\r\n Name?: string;\r\n Description?: string;\r\n VideoLink?: string;\r\n ItContactPpid?: string;\r\n Live?: boolean;\r\n IsHighlighted?: boolean;\r\n IsNew?: boolean;\r\n IsPSF?: boolean;\r\n IsPSA?: boolean;\r\n LifeCycles?: string[];\r\n ValueChains?: string[];\r\n SmallDescription?: string;\r\n GeographicalInformation?: string;\r\n TargetProfile?: string;\r\n MainAddedValue?: string;\r\n SecondaryAddedValue?: string;\r\n AvailableApplication?: string;\r\n Deliverable?: string;\r\n ServiceGroupId?: string;\r\n ViewersPpids?: string[];\r\n FriendlyUrl?: string;\r\n VisibleInClientView?: boolean;\r\n UkViewersPpids?: string[];\r\n FrViewersPpids?: string[];\r\n}\r\n\r\nexport interface ServiceCreateDTO {\r\n TeamPpids?: string[];\r\n ResponsiblesPpids?: string[];\r\n Organizations?: string[];\r\n Applications?: ApplicationCreateDTO[];\r\n Industries?: string[];\r\n RelatedServices?: string[];\r\n Illustrations?: File[];\r\n Name?: string;\r\n Description?: string;\r\n VideoLink?: string;\r\n ItContactPpid?: string;\r\n Live?: boolean;\r\n IsHighlighted?: boolean;\r\n IsNew?: boolean;\r\n IsPSA?: boolean;\r\n IsPSF?: boolean;\r\n LifeCycles?: string[];\r\n ValueChains?: string[];\r\n SmallDescription?: string;\r\n GeographicalInformation?: string;\r\n TargetProfile?: string;\r\n MainAddedValue?: string;\r\n SecondaryAddedValue?: string;\r\n AvailableApplication?: string;\r\n Deliverable?: string;\r\n ServiceGroupId?: string;\r\n ViewersPpids?: string[];\r\n UkViewersPpids?: string[];\r\n FrViewersPpids?: string[];\r\n Domains?: string[];\r\n Territories?: string[];\r\n FriendlyUrl?: string;\r\n VisibleInClientView?: boolean;\r\n [key: string]: any;\r\n}\r\n","import { ServiceContactReadDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\n\r\nexport interface Person {\r\n id: string;\r\n ppid: string;\r\n name: string;\r\n email: string;\r\n grade?: string;\r\n photo: string | null;\r\n phoneNumber?: string;\r\n phoneCountryCode?: number;\r\n}\r\nexport function toPersonDTO(user: ServiceContactReadDTO): Person {\r\n return {\r\n id: user.id,\r\n ppid: user.ppid!,\r\n name: `${user.firstname} ${user.lastname}`,\r\n photo: user.photoUri,\r\n email: user.email!,\r\n grade: user.grade!,\r\n phoneNumber: user.phoneNumber ?? undefined,\r\n phoneCountryCode: user.phoneCountryCode ?? undefined,\r\n };\r\n}\r\n\r\nexport function toUserReadDTO(person: Person): ServiceContactReadDTO {\r\n return {\r\n ppid: person.ppid,\r\n email: person.email,\r\n firstname: null,\r\n lastname: null,\r\n grade: person.grade,\r\n id: person.id,\r\n photoUri: person.photo,\r\n } as ServiceContactReadDTO;\r\n}\r\n","import {\r\n ApplicationReadDTO,\r\n ServiceReadDTO,\r\n} from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { ServiceType } from \"api/catalog/type\";\r\nimport {\r\n Person,\r\n toPersonDTO,\r\n} from \"pages/admin/components/Service/type/person\";\r\n\r\nexport interface CatalogueService {\r\n id: string;\r\n name: string;\r\n description: string;\r\n responsibles: Person[];\r\n subscribed: boolean;\r\n applications: ApplicationReadDTO[];\r\n itContact: Person | null;\r\n team: Person[];\r\n industries: string[];\r\n}\r\n\r\nexport interface CatalogueServiceDetails extends CatalogueService {\r\n applications: ApplicationReadDTO[];\r\n videoLink?: string | null;\r\n}\r\n\r\nexport type CatalogueServices = CatalogueService[] | null;\r\n\r\nexport function toCatalogueService(dto: ServiceReadDTO): CatalogueService {\r\n return {\r\n id: dto.id,\r\n subscribed: false,\r\n description: dto.description!,\r\n name: dto.name!,\r\n // @ts-ignore\r\n type: ServiceType[ServiceType[dto.type]],\r\n responsibles: dto.responsibles?.map(toPersonDTO) || [],\r\n applications: dto.applications || [],\r\n itContact: dto.itContact ? toPersonDTO(dto.itContact) : null,\r\n team: dto.team?.map(toPersonDTO) || [],\r\n industries: dto.industries ?? [],\r\n };\r\n}\r\n\r\nexport function toCatalogueServiceDetails(\r\n dto: ServiceReadDTO\r\n): CatalogueServiceDetails {\r\n return {\r\n ...toCatalogueService(dto),\r\n applications: dto.applications || [],\r\n videoLink: dto.videoLink,\r\n };\r\n}\r\n\r\nexport function isServiceDetails(\r\n service: CatalogueService | CatalogueServiceDetails\r\n): service is CatalogueServiceDetails {\r\n if (!service) {\r\n return false;\r\n }\r\n const serviceDetails = service as CatalogueServiceDetails;\r\n return (\r\n serviceDetails.applications !== undefined &&\r\n serviceDetails.videoLink !== undefined\r\n );\r\n}\r\n","import { isValidUrl } from \"utils\";\r\n\r\nexport const VIDEO_TYPES = {\r\n YOUTUBE: \"YOUTUBE\",\r\n VIMEO: \"VIMEO\",\r\n};\r\n\r\nconst matchers = [\r\n (url) => {\r\n const matches =\r\n /https:\\/\\/www.youtube.com\\/watch\\?v=([a-zA-Z0-9_\\-?]+)/g.exec(url);\r\n return matches && matches[1]\r\n ? {\r\n type: VIDEO_TYPES.YOUTUBE,\r\n id: matches[1],\r\n }\r\n : null;\r\n },\r\n\r\n (url) => {\r\n const matches = /https:\\/\\/youtu.be\\/([a-zA-Z0-9_\\-?]+)/g.exec(url);\r\n return matches && matches[1]\r\n ? {\r\n type: VIDEO_TYPES.YOUTUBE,\r\n id: matches[1],\r\n }\r\n : null;\r\n },\r\n\r\n (url) => {\r\n const matches = /https:\\/\\/vimeo.com\\/(([a-zA-Z0-9_\\-?]+\\/?)+)/g.exec(url);\r\n if (!matches || !matches[1]) {\r\n return null;\r\n }\r\n const splittedId = matches[1].split(\"/\");\r\n return matches && matches[1]\r\n ? {\r\n type: VIDEO_TYPES.VIMEO,\r\n id: `${splittedId.shift()}${\r\n (splittedId.length > 0 && `?h=${splittedId.join(\"&h=\")}`) || \"\"\r\n }`,\r\n }\r\n : null;\r\n },\r\n];\r\n\r\nexport const findFirstMatcher = (url) => {\r\n for (const matcher of matchers) {\r\n const res = matcher(url);\r\n if (!!res) {\r\n return res;\r\n }\r\n }\r\n return null;\r\n};\r\n\r\nexport const validateURL = (url) =>\r\n !isValidUrl(url)\r\n ? \"Please provide a valid URL\"\r\n : findFirstMatcher(url) === null &&\r\n \"Please provide a URL from Youtube or Vimeo\";\r\n","import { EditorState, convertToRaw } from \"draft-js\";\r\nimport draftToHtml from \"draftjs-to-html\";\r\nimport striptags from \"striptags\";\r\n\r\nexport const draftContentIsEmpty = (draft) => {\r\n if (!draft) {\r\n return true;\r\n }\r\n return striptags(draftRawToHtml(draft)).trim().length === 0;\r\n};\r\n\r\nexport const blankRawDraft = convertToRaw(\r\n EditorState.createEmpty().getCurrentContent()\r\n);\r\n\r\nexport const draftRawToHtml = (raw) => {\r\n try {\r\n return draftToHtml(raw);\r\n } catch (error) {\r\n console.error(\"Error while converting draft raw to HTML\", error);\r\n return \"\";\r\n }\r\n};\r\n","import { UseTypedQueryOptions } from \"api/UseTypedQueryOptions\";\r\nimport { UseQueryResult, useQuery } from \"react-query\";\r\n\r\nimport {\r\n LifecycleAllReadDTO,\r\n LifecycleReadDTO,\r\n} from \"../__generated__/CatalogueAPI\";\r\nimport { getLifeCycles, getLifeCyclesAll } from \"../catalogApi\";\r\n\r\nexport default function useLifeCycles(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\"lifecycles\", () => getLifeCycles(), props);\r\n}\r\n\r\nexport function useLifeCyclesAll(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\"lifecycles-all\", () => getLifeCyclesAll(), props);\r\n}\r\n","import { UseTypedQueryOptions } from \"api/UseTypedQueryOptions\";\r\nimport { UseQueryResult, useQuery } from \"react-query\";\r\n\r\nimport {\r\n ValueChainAllReadDTO,\r\n ValueChainReadDTO,\r\n} from \"../__generated__/CatalogueAPI\";\r\nimport { getValueChains, getValueChainsAll } from \"../catalogApi\";\r\n\r\nexport default function useValueChains(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\"valuechains\", () => getValueChains(), props);\r\n}\r\n\r\nexport function useValueChainsAll(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\"valuechains-all\", () => getValueChainsAll(), props);\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport DEFAULT_SRC from \"../../img/illustrations/undraw_empty.svg\";\r\n\r\nconst DEFAULT_TITLE = \"So empty...\";\r\n\r\nconst ImageTitle = ({\r\n title = DEFAULT_TITLE,\r\n subtitle,\r\n src = DEFAULT_SRC,\r\n alt = title,\r\n}) => (\r\n
\r\n {alt}\r\n
{title}
\r\n\r\n
\r\n {subtitle === undefined ? : subtitle}\r\n
\r\n
\r\n);\r\n\r\nconst SubTitle = () => (\r\n <>\r\n
You're looking for something too specific,
\r\n
try broadening your criteria.
\r\n \r\n);\r\nexport default ImageTitle;\r\n","import \"./contextsSearchbar.scss\";\r\n\r\nimport { List, ListItem, Panel, Tag } from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport useClickOutside from \"hooks/useClickOutside\";\r\nimport { useCallback, useEffect, useMemo, useRef, useState } from \"react\";\r\n\r\nconst Searchbar = ({ filters, onFiltersChange, columns }) => {\r\n const [search, setSearch] = useState(\"\");\r\n const [selectedOption, setSelectedOption] = useState(null);\r\n const [focused, setFocused] = useState(false);\r\n const inputRef = useRef(null);\r\n\r\n const addFilter = useCallback(\r\n (column, value) => {\r\n if (!column) {\r\n return;\r\n }\r\n\r\n onFiltersChange([\r\n ...filters,\r\n {\r\n id: column.id,\r\n Header: column.Header,\r\n value,\r\n },\r\n ]);\r\n\r\n setSearch(\"\");\r\n focus();\r\n },\r\n [filters, onFiltersChange]\r\n );\r\n\r\n const deleteFilter = useCallback(\r\n (filterId) => {\r\n onFiltersChange(filters.filter((f) => f.id !== filterId));\r\n },\r\n [filters, onFiltersChange]\r\n );\r\n\r\n const possibleContexts = useMemo(() => {\r\n const usedContexts = filters.map((f) => f.id);\r\n return columns.filter((c) => !usedContexts.includes(c.id));\r\n }, [filters, columns]);\r\n\r\n const columnKeys = useMemo(() => {\r\n return columns.map((c) => c.id);\r\n }, [columns]);\r\n\r\n useEffect(() => {\r\n if (search.length === 0) {\r\n setSelectedOption(null);\r\n } else if (!selectedOption && possibleContexts.length > 0) {\r\n setSelectedOption(possibleContexts[0]);\r\n }\r\n }, [search, possibleContexts, selectedOption]);\r\n\r\n const focus = () => {\r\n if (inputRef) {\r\n inputRef.current.focus();\r\n }\r\n };\r\n\r\n const handleKeyUp = (event) => {\r\n const arrowUp = () => {\r\n const selectedIndex = possibleContexts.indexOf(selectedOption);\r\n const newIndex =\r\n selectedIndex > 0 ? selectedIndex - 1 : possibleContexts.length - 1;\r\n setSelectedOption(possibleContexts[newIndex]);\r\n };\r\n\r\n const arrowDown = () => {\r\n const selectedIndex = possibleContexts.indexOf(selectedOption);\r\n const newIndex =\r\n selectedIndex < possibleContexts.length - 1 ? selectedIndex + 1 : 0;\r\n setSelectedOption(possibleContexts[newIndex]);\r\n };\r\n\r\n switch (event.keyCode) {\r\n case 13: // Press Enter\r\n addFilter(selectedOption, search.trim());\r\n break;\r\n case 38: // Arrow Up\r\n arrowUp();\r\n break;\r\n case 40: // Arrow Down\r\n arrowDown();\r\n break;\r\n default:\r\n break;\r\n }\r\n };\r\n\r\n const handleKeyDown = (event) => {\r\n if (event.keyCode === 8 && filters.length > 0 && search.length === 0) {\r\n // Backspace\r\n deleteFilter(filters[filters.length - 1].id);\r\n }\r\n };\r\n\r\n const open = !!search.trim().length;\r\n const resetSearchbar = useCallback(() => setSearch(\"\"), []);\r\n const ref = useClickOutside(open, resetSearchbar);\r\n\r\n return (\r\n \r\n \r\n {filters.map((filter) => {\r\n const column = columns.find((column) => column.id === filter.id);\r\n\r\n return (\r\n deleteFilter(filter.id)}\r\n size=\"sm\"\r\n >\r\n {`${filter.Header}: ${filter.value}`}\r\n \r\n );\r\n })}\r\n\r\n
\r\n setSearch(e.target.value)}\r\n onKeyDown={handleKeyDown}\r\n onKeyUp={handleKeyUp}\r\n placeholder=\"Search\"\r\n onFocus={() => setFocused(true)}\r\n onBlur={() => setFocused(false)}\r\n />\r\n\r\n
\r\n {open && (\r\n \r\n {possibleContexts.length > 0 ? (\r\n \r\n {possibleContexts.map((column) => (\r\n addFilter(column, search)}\r\n >\r\n \r\n {column.Header}:  \r\n \r\n \r\n {search}\r\n \r\n \r\n ))}\r\n \r\n ) : (\r\n \"No more columns to search.\"\r\n )}\r\n \r\n )}\r\n
\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default Searchbar;\r\n","import \"./searchbar.scss\";\r\n\r\nimport { Input } from \"appkit-react\";\r\n\r\nconst SearchBar = ({ className = \"\", ...inputProps }) => (\r\n \r\n }\r\n placeholder=\"Search\"\r\n {...inputProps}\r\n />\r\n);\r\n\r\nexport default SearchBar;\r\n","import ContextsSearchbar from \"./contextsSearchbar\";\r\nimport Searchbar from \"./searchbar\";\r\n\r\nexport default Searchbar;\r\nexport { ContextsSearchbar };\r\n","import \"./index.scss\";\r\n\r\nimport { acceptTermsAndConditions } from \"api/admin/adminApi\";\r\nimport { Button, ModalBody, ModalFooter, ModalHeader } from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport { useState } from \"react\";\r\nimport { useDispatch, useSelector } from \"react-redux\";\r\nimport { adminAcceptTermsAndConditions } from \"redux/actions/global\";\r\n\r\nconst TermsAndConditionsModal = ({ opened, onClose }) => {\r\n const dispatch = useDispatch();\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n const [acceptingTermsAndConditions, setAcceptingTermsAndConditions] =\r\n useState(false);\r\n\r\n const handleClose = () => {\r\n if (\r\n !loginUser ||\r\n !loginUser.termsAndConditionsAccepted ||\r\n acceptingTermsAndConditions\r\n ) {\r\n return;\r\n }\r\n onClose();\r\n };\r\n\r\n const acceptTerms = () => {\r\n setAcceptingTermsAndConditions(true);\r\n acceptTermsAndConditions()\r\n .then(() => {\r\n dispatch(adminAcceptTermsAndConditions());\r\n })\r\n .finally(() => {\r\n setAcceptingTermsAndConditions(false);\r\n });\r\n };\r\n\r\n const refuseTerms = () => {\r\n window.location.replace(\"https://www.google.com/\");\r\n };\r\n\r\n return (\r\n \r\n \r\n
Terms and Conditions
\r\n
\r\n \r\n
\r\n

\r\n This statement describes terms and conditions of use (the{\" \"}\r\n \"Terms of Use\" or the \"Statement\")\r\n under which PricewaterhouseCoopers, Société coopérative (\r\n \"PwC\" or \"We\" or{\" \"}\r\n \"Us\"), a Luxembourg company whose principal place\r\n of business is at 2, rue Gerhart Mercator, L-2182 Luxembourg, allows\r\n users (\"You\" or the \"User(s)\"), be\r\n they individuals and/or the business entities they represent (the{\" \"}\r\n \"Company(ies)\"), to access and use online the\r\n Managed Services Platform (the{\" \"}\r\n \"Managed Services Hub Platform\") as well as its\r\n related services (the \"Services\"). By accessing and\r\n using the Managed Services Hub Platform and its related AM Digital\r\n Solutions Platform Services, You manifest your express consent to\r\n the acceptance of the Terms of Use set out below, including all\r\n notices displayed on the Asset Management Digital Solutions\r\n Platform.\r\n

\r\n\r\n

1. ACCESS

\r\n\r\n

1.1. Eligibility

\r\n\r\n

\r\n The Managed Services Hub Platform aims at supporting collaboration\r\n and exchange of information and documents (the \"Information\")\r\n between Users and may only be used in the framework of (i) the\r\n project supported by the Platform and (ii) of a contract (the\r\n \"Contract\") concluded between the Company(ies) and PwC.\r\n

\r\n

\r\n In application of the Contract, PwC (or the Company or one of the\r\n Companies (as designated in the Contract) acting as the AM Digital\r\n Solutions Platform Administrator, if any – the \"Client\r\n Administrator\") attributes a password and a username (the\r\n \"Identifications\") to each person designated as authorized User by\r\n the Company(ies). As such, You have a limited, non-exclusive and\r\n non-transferable authorization to access and navigate the AM Digital\r\n Solutions Platform and its related Asset Management Digital\r\n Solutions Platform Services for strictly professional purposes in\r\n accordance with the tasks entrusted to You by the Company(ies). Any\r\n non-authorized person having accessed, navigated or used the Asset\r\n Management Digital Solutions Platform and/or its related Asset\r\n Management Digital Solutions Platform Services is subject to the\r\n same obligations and responsibilities listed in this Statement as\r\n that of an authorized User.\r\n

\r\n

\r\n For purposes of maintenance and efficiency access, PwC may modify\r\n the Identifications from time to time.\r\n

\r\n

1.2. Your Identification and Security

\r\n

\r\n The Identifications provided to You are strictly personal and\r\n non-transferable. You are fully responsible for maintaining the\r\n confidentiality of your Identification as well as all utilization\r\n thereof. You commit to inform PwC, the Client Administrator if any,\r\n and the Company(ies), of any suspected or actual non-authorized\r\n utilization of your Identifications or of any other suspected or\r\n actual security threat to the Managed Services Hub Platform and/or\r\n its related Managed Services Hub Platform Services.\r\n

\r\n

\r\n PwC cannot be held liable for any damage that may occur due to the\r\n utilization of your Identification by a third party, whether You\r\n knew of this utilization or not. However, You may be held liable if\r\n PwC or a third party incurs damage due to the utilization of your\r\n Identification by a third party.\r\n

\r\n

1.3. Supply of the Managed Services Hub Platform

\r\n

\r\n The Managed Services Hub Platform is expected to be available\r\n 24*7*365, on a reasonable-efforts basis.\r\n

\r\n

\r\n However, PwC cannot guarantee (i) continuous or uninterrupted access\r\n to the Managed Services Hub Platform and its related AM Digital\r\n Solutions Platform Services or the reliability, availability,\r\n performance and other aspects of the Internet, nor (ii) that the\r\n Information will not be captured or monitored by one or more third\r\n parties.\r\n

\r\n

\r\n PwC shall provide service support as regard the Asset Management\r\n Digital Solutions Platform during Luxembourg working hours from\r\n 08:30 CET to 18:00 CET only. Additionally, the Asset Management\r\n Digital Solutions Platform might be temporarily unavailable for\r\n maintenance purposes. For example, in that case, if possible, a\r\n message stating the estimated time of its unavailability will be\r\n posted on the Managed Services Hub Platform homepage in advance\r\n where possible.\r\n

\r\n

\r\n PwC will use standard, commercially-available virus-checking\r\n software in relation to any Information accessible using the AM\r\n Digital Solutions Platform in order to prevent such unauthorized\r\n access. However, and unless otherwise provided in the Contract, PwC\r\n does not represent or warrant that the Asset Management Digital\r\n Solutions Platform or any Information will be error-free, free from\r\n viruses or other harmful components. You warrant that any\r\n Information that You supply, post or otherwise make available via\r\n the AM Digital Solutions Platform, does not contain any viruses or\r\n other computer programming routines which may damage or interfere\r\n with the operations of the Managed Services Hub Platform.\r\n

\r\n

\r\n PwC’s responsibility with regard to the transmission and reception\r\n of data is limited to the interface between the server of PwC and\r\n the Users’ network.{\" \"}\r\n

\r\n

\r\n In no event PwC can be held liable for damages resulting from\r\n interferences, interruptions or limitation of the functioning of the\r\n Managed Services Hub Platform and its related Asset Management\r\n Digital Solutions Platform Services for technical reasons nor for\r\n any costs incurred by You in securing, obtaining or maintaining an\r\n appropriate internet connection.\r\n

\r\n

1.4. Storage

\r\n\r\n

\r\n The Information posted by You on the Asset Management Digital\r\n Solutions Platform will be stored on a server located in PwC\r\n premises and maintained under reasonably appropriate technical and\r\n organizational security measures. PwC cannot be held liable for any\r\n kind of damages in case of unforeseeable events as long as such\r\n security standards have been respected. In this context, You must\r\n ensure that You stored all Information appropriately and maintain\r\n appropriate back-up.\r\n

\r\n\r\n

2. CONTENT

\r\n

\r\n The Information, including all material, data, documents and files\r\n contained in, and/or provided through, the Asset Management Digital\r\n Solutions Platform and its related Asset Management Digital\r\n Solutions Platform Services, is for general guidance on matters of\r\n interest only, unless otherwise provided in the Contract.\r\n

\r\n

\r\n The Managed Services Hub Platform aims at supporting collaboration\r\n and exchange of Information between the Users only and not at giving\r\n any legal value of any Information exchanged, posted or downloaded\r\n from the Managed Services Hub Platform. Therefore, You acknowledge\r\n that all Information, which is necessarily dematerialized, cannot be\r\n considered as original.{\" \"}\r\n

\r\n

\r\n Given the changing nature of the applicable laws, rules and\r\n regulations, the Managed Services Hub Platform, its related AM\r\n Digital Solutions Platform Services and/or the Information are\r\n therefore provided \"as is\", and, to the extent permitted by\r\n applicable law, PwC, any other entity linked to PwC, and their\r\n respective partners, agents, representatives or employees, or\r\n licensors, distributors or suppliers (the{\" \"}\r\n \"PwC Parties\"), disclaim all guarantees of\r\n representation, reliability, timeliness or of the results obtained\r\n from the use of, the Managed Services Hub Platform, its related AM\r\n Digital Solutions Platform Services and/or the Information, as well\r\n as all warranties of any kind, express, implied, or statutory,\r\n including, without limitation, any implied warranties of\r\n merchantability, fitness for a particular purpose, accuracy,\r\n completeness, non-infringement, non-interference, error-free and\r\n uninterrupted service.\r\n

\r\n

\r\n The functionalities ‘request job’ and ‘chat’ of the AM Digital\r\n Solutions Platform are not designed for and shall not be used for\r\n answering and advising You (and/or the Company(ies)) on any\r\n technical and/or material matters. Any dialogue, answers and/or\r\n exchanges which may take place between PwC and You (and/or the\r\n Company(ies)) there trough, do not constitute, final opinions of PwC\r\n and You (and/or the Companies) shall neither act nor refrain from\r\n acting on the basis of such exchanges until they have been\r\n officially confirmed and issued by PwC in their final form as\r\n deliverables to the Company(ies).\r\n

\r\n

\r\n PwC declines all responsibility and You recognize that, in no\r\n circumstances, can the PwC Parties be held liable towards You or any\r\n other person for:\r\n

\r\n
    \r\n
  • \r\n the Information or any other information omitted in the AM Digital\r\n Solutions Platform, unless otherwise provided in the Contract;\r\n
  • \r\n
  • \r\n the consequences of all decisions, taken or not, by Yourself or\r\n any other person, with regards to the Information provided by/on\r\n the Managed Services Hub Platform or resulting from the use of the\r\n Managed Services Hub Platform or its related Managed Services Hub\r\n Platform Services;\r\n
  • \r\n
  • \r\n any kind of damages (notably the damages resulting from the loss\r\n of benefits, interruption of activity, loss of data or any other\r\n kind of financial loss) resulting from the use or impossibility of\r\n use of the Information, the Managed Services Hub Platform or its\r\n related Managed Services Hub Platform Services, even if PwC was\r\n previously informed of the possibility of such damages.\r\n
  • \r\n
\r\n

\r\n You agree to reimburse the PwC Parties for all damages, settlements,\r\n losses and expenses (including legal fees) relating to all actions,\r\n proceedings and claims brought or threatened by a third party in\r\n connection with Your access and use of the Information, the AM\r\n Digital Solutions Platform and/or its related Asset Management\r\n Digital Solutions Platform Services.\r\n

\r\n

3. YOUR OBLIGATIONS

\r\n

\r\n You can only access, navigate or use the Asset Management Digital\r\n Solutions Platform and its related Asset Management Digital\r\n Solutions Platform Services on the condition that You guarantee that\r\n You will not use it to conduct any illicit activity, which is\r\n prohibited by or would violate any applicable law or these Terms of\r\n Use. You may not use the AM Digital Solutions Platform or its\r\n related Managed Services Hub Platform Services in any way that may\r\n harm, hinder, impair or overload the performance of the Managed\r\n Services Hub Platform and/or its related Asset Management Digital\r\n Solutions Platform Services.\r\n

\r\n

You are not authorized to:

\r\n
    \r\n
  1. \r\n unless as expressly foreseen in the Contract, modify, copy,\r\n distribute, transfer, diffuse, represent, reproduce, create\r\n derivative obligations, transfer or sell in whole or in part,\r\n directly or indirectly, free or at a cost, to non-authorized third\r\n parties, by physical or electronic means, any Information or\r\n service obtained from the Managed Services Hub Platform and/or its\r\n related Managed Services Hub Platform Services; nor\r\n
  2. \r\n
  3. \r\n manipulate or use the Managed Services Hub Platform or its related\r\n Managed Services Hub Platform Services to create products or\r\n services which are likely to compete with or to hinder, directly\r\n or indirectly the Asset Management Digital Solutions Platform or\r\n AM Digital Solutions Platform Services delivered or to be\r\n delivered by PwC.\r\n
  4. \r\n
\r\n

\r\n Before making all necessary and sufficient Information available,\r\n You shall verify that it is accurate and comprehensive.{\" \"}\r\n

\r\n

\r\n You commit to use the Managed Services Hub Platform, its related AM\r\n Digital Solutions Platform Services and the Information for the\r\n internal use of the Company(ies) only and in order to attain the\r\n objectives that are defined in the Contract only.\r\n

\r\n

\r\n The abusive use of the Managed Services Hub Platform and its related\r\n Managed Services Hub Platform Services may expose You to the\r\n suspension and/or termination of Your access to the AM Digital\r\n Solutions Platform and its related Services (as well as the access\r\n of the Company(ies)), and may expose You (as well as the\r\n Company(ies)) to legal actions.\r\n

\r\n

\r\n Your obligations resulting from this Statement towards the AM\r\n Digital Solutions Platform, its related Asset Management Digital\r\n Solutions Platform Services and the Information, do not cease at the\r\n end of your utilization or access of the Asset Management Digital\r\n Solutions Platform and of its related Asset Management Digital\r\n Solutions Platform Services.\r\n

\r\n

4. SUSPENSION/TERMINATION OF ACCESS

\r\n

\r\n In case of termination, for any reason, of Your relationship with\r\n the Company(ies), You shall immediately inform PwC (or the Client\r\n Administrator if any), of the effective date of such termination and\r\n cease using Your Identifications up from this date.\r\n

\r\n

\r\n PwC reserves the right to control at any moment and without any\r\n notice the use that You make of this Asset Management Digital\r\n Solutions Platform and its related Services. If PwC suspects an\r\n abuse concerning Your use of the Managed Services Hub Platform or\r\n any use contrary to the terms and conditions of the present\r\n Statement, your right of access will automatically be suspended\r\n without any notice.{\" \"}\r\n

\r\n

\r\n PwC may suspend Your access to the Asset Management Digital\r\n Solutions Platform and to the utilization of the related Asset\r\n Management Digital Solutions Platform Services without any notice:\r\n

\r\n
    \r\n
  • \r\n in order to repair, maintain or improve the Asset Management\r\n Digital Solutions Platform and its related Asset Management\r\n Digital Solutions Platform Services;\r\n
  • \r\n
  • \r\n on the written or verbal demand of the Company(ies) (or the Client\r\n Administrator if any);\r\n
  • \r\n
  • \r\n in order to comply with an order, an instruction or demand from a\r\n tribunal, government or other competent administrative, legal or\r\n statutory authority.\r\n
  • \r\n
\r\n

5. INTELLECTUAL PROPERTY

\r\n

\r\n The Managed Services Hub Platform, the Information and all the\r\n elements constituting the Managed Services Hub Platform and its\r\n related Managed Services Hub Platform Services (for example and\r\n without limitation: general structure, database and software, texts,\r\n animated or non-animated images, titles, documentation, arrangement\r\n and form of the presentation) are the exclusive property of PwC and\r\n are protected by copyrights. Any program, publication, design,\r\n product, process, software, technology, information, know-how, or\r\n idea described in, or related to, the Managed Services Hub Platform\r\n and its related Managed Services Hub Platform Services, may be\r\n subject to other rights, including other intellectual property\r\n rights, which are owned by PwC or other interested parties and are\r\n not licensed in any way to you hereunder.\r\n

\r\n

\r\n The present Statement hereby grants You only a professional and\r\n individual permission to use the Managed Services Hub Platform and\r\n its related Managed Services Hub Platform Services. Any interference\r\n with the stipulation of this clause such as notably the\r\n reproduction, diffusion of any kind of process, commercial or\r\n otherwise, free or at a cost, constitutes a counterfeiting\r\n punishable according to the applicable law.\r\n

\r\n

\r\n All rights not expressly conceded in the present Statement are\r\n reserved.\r\n

\r\n

6. DATA PROTECTION

\r\n

\r\n Information about how PwC collects, processes, protects and disposes\r\n of Users’ personal data and how data subjects can exercise their\r\n rights is available on PwC’s dedicated page:\r\n www.pwc.lu/privacy-statement.\r\n

\r\n

\r\n Should you supply PwC with personal data of a third party, PwC\r\n assumes, and by providing the personal data to us, You confirm,\r\n that:\r\n

\r\n

\r\n - the personal data You provide to PwC are accurate, adequate,\r\n relevant and limited to what is necessary for the specific purpose\r\n for which they are disclosed ;\r\n

\r\n

\r\n - You comply with all applicable laws (including the EU General Data\r\n Protection Regulation) in connection with PwC’s processing of the\r\n personal data (including the lawfulness of the data provision and,\r\n where applicable, collecting and managing the data subject’s consent\r\n accordingly);\r\n

\r\n

\r\n - the data subjects are informed of the conditions and modalities of\r\n the processing of their personal data in the form required by all\r\n applicable laws (including the EU General Data Protection\r\n Regulation), in particular about the processing of their personal\r\n data by PwC as described above; and\r\n

\r\n

\r\n - You will immediately inform PwC if any of the conditions above\r\n ceases to be met.{\" \"}\r\n

\r\n

7. MISCELLANEOUS

\r\n

\r\n All complaints regarding the application, lack or violation of the\r\n obligations or the rights relating to the present Terms of Use will\r\n be subject exclusively to Luxembourg Law. By accepting this\r\n Statement, You agree irrevocably that any litigation caused by or\r\n linked to the access, the navigation, the connection or all other\r\n use of the Managed Services Hub Platform or its related AM Digital\r\n Solutions Platform Services will come under the exclusive competency\r\n of the courts of Luxembourg-Ville.\r\n

\r\n

\r\n Notwithstanding the above provisions dismissing any liability of PwC\r\n toward the User(s) and third parties to the extent permitted by\r\n applicable law, all actions brought against PwC and/or its employees\r\n shall be statute-barred after i) a period of one (1) year from the\r\n date of access or use of the Managed Services Hub Platform or its\r\n related Managed Services Hub Platform Services linked to the damage,\r\n or ii) after a period of one (1) year from the date on which You\r\n should reasonably have become aware of the damage, whichever comes\r\n first.\r\n

\r\n

\r\n PwC reserves the right to modify these Terms of Use at any time.\r\n

\r\n
\r\n
\r\n \r\n {loginUser?.termsAndConditionsAccepted && (\r\n <>\r\n
\r\n You have already accepted the terms and conditions\r\n
\r\n \r\n \r\n )}\r\n {!loginUser?.termsAndConditionsAccepted && (\r\n <>\r\n
\r\n You must read and accept the terms and conditions before using\r\n this application\r\n
\r\n \r\n Refuse\r\n \r\n \r\n Accept\r\n \r\n \r\n )}\r\n
\r\n \r\n );\r\n};\r\n\r\nexport default TermsAndConditionsModal;\r\n","import \"./index.scss\";\r\n\r\nimport { Modal } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport { CSSProperties, useState } from \"react\";\r\nimport { ResizableBox } from \"react-resizable\";\r\n\r\ninterface Props {\r\n // Appkit Modal Props\r\n style?: CSSProperties;\r\n className?: string;\r\n visible?: boolean;\r\n backdropClosable?: boolean;\r\n zIndex?: number;\r\n onCancel: () => void;\r\n // Resizable Props\r\n width?: number;\r\n}\r\n\r\nconst ResizableAppkitModal: React.FC = ({\r\n width: propsWidth = 500,\r\n children,\r\n ...modalProps\r\n}) => {\r\n const [width, setWidth] = useState(propsWidth);\r\n return (\r\n \r\n {\r\n setWidth(data.size.width);\r\n }}\r\n >\r\n \r\n {children}\r\n \r\n \r\n );\r\n};\r\n\r\nexport default ResizableAppkitModal;\r\n","import { useMemo } from \"react\";\r\n\r\nimport {\r\n MIME_DOC,\r\n MIME_DOCX,\r\n MIME_JPEG,\r\n MIME_PDF,\r\n MIME_PNG,\r\n MIME_PPT,\r\n MIME_PPTX,\r\n MIME_XLS,\r\n MIME_XLSX,\r\n} from \"../../../../constants\";\r\n\r\nconst FileIcon = ({ mimeType, type = \"outline\" }) => {\r\n const icon = useMemo(() => {\r\n switch (mimeType) {\r\n case MIME_PDF:\r\n return \"pdf\";\r\n case MIME_DOC:\r\n case MIME_DOCX:\r\n return \"doc\";\r\n case MIME_XLS:\r\n case MIME_XLSX:\r\n return \"xls\";\r\n case MIME_PPT:\r\n case MIME_PPTX:\r\n return \"ppt\";\r\n case MIME_PNG:\r\n case MIME_JPEG:\r\n return \"image\";\r\n default:\r\n return \"file\";\r\n }\r\n }, [mimeType]);\r\n\r\n return ;\r\n};\r\n\r\nexport default FileIcon;\r\n","import \"./index.scss\";\r\n\r\nimport { Tab, Tabs } from \"appkit-react\";\r\nimport { useDispatch, useSelector } from \"react-redux\";\r\nimport { newsAdminChangeTab } from \"redux/actions/newsAdmin\";\r\n\r\nexport const TABS = {\r\n NEWS: \"NEWS\",\r\n ARTICLES: \"ARTICLES\",\r\n EVENTS: \"EVENTS\",\r\n VIDEOS: \"VIDEOS\",\r\n PUBLICATIONS: \"PUBLICATIONS\",\r\n TOPICS: \"TOPICS\",\r\n ISSUERS: \"ISSUERS\",\r\n DOCUMENTTYPES: \"DOCUMENTTYPES\",\r\n SUBSCRIPTIONS: \"SUBSCRIPTIONS\",\r\n};\r\n\r\nconst OPTIONS = {\r\n [TABS.NEWS]: {\r\n label: \"News\",\r\n icon: \"icon-pencil\",\r\n },\r\n [TABS.ARTICLES]: {\r\n label: \"Articles\",\r\n icon: \"icon-news\",\r\n },\r\n [TABS.EVENTS]: {\r\n label: \"Compliance Calendar\",\r\n icon: \"icon-calendar\",\r\n },\r\n [TABS.VIDEOS]: {\r\n label: \"Videos\",\r\n icon: \"icon-play\",\r\n },\r\n [TABS.PUBLICATIONS]: {\r\n label: \"Publications\",\r\n icon: \"icon-survey\",\r\n },\r\n [TABS.TOPICS]: {\r\n label: \"Topics\",\r\n icon: \"icon-tag\",\r\n },\r\n [TABS.ISSUERS]: {\r\n label: \"Issuers\",\r\n icon: \"icon-leader\",\r\n },\r\n [TABS.DOCUMENTTYPES]: {\r\n label: \"Document types\",\r\n icon: \"icon-management\",\r\n },\r\n [TABS.SUBSCRIPTIONS]: {\r\n label: \"Subscriptions\",\r\n icon: \"icon-growth\",\r\n },\r\n};\r\n\r\nconst TableToggle = () => {\r\n const selected = useSelector((state) => state.newsAdmin.tab);\r\n const dispatch = useDispatch();\r\n\r\n const onSelectedChange = (tab) => dispatch(newsAdminChangeTab(tab));\r\n\r\n return (\r\n onSelectedChange(selected)}\r\n >\r\n {Object.entries(OPTIONS).map(([key, tab]) => (\r\n \r\n \r\n  {tab.label}\r\n \r\n }\r\n />\r\n ))}\r\n \r\n );\r\n};\r\n\r\nexport default TableToggle;\r\n","import {\r\n getNewsPermissions,\r\n getUsedMetadataForType,\r\n} from \"api/news/articleApi\";\r\nimport { getDocumentTypes } from \"api/news/articleDocumentTypeApi\";\r\nimport { getTopics } from \"api/news/articleTopicApi\";\r\nimport { getIssuers } from \"api/news/issuerApi\";\r\nimport { getList as fetchNews } from \"api/news/newsApi\";\r\nimport { getTerritories } from \"api/news/territoryApi\";\r\n\r\n// ARTICLES ACTIONS\r\nexport const ARTICLES_INITIALIZE = \"ARTICLES_INITIALIZE\";\r\nexport const ARTICLES_INITIALIZE_SUCCESS = \"ARTICLES_INITIALIZE_SUCCESS\";\r\n\r\nexport const articleInit = (type) => async (dispatch) => {\r\n await articlesGetMetadataForType(type)(dispatch);\r\n};\r\n\r\nexport const NEWS_ADMIN_INITIALIZE = \"NEWS_ADMIN_INITIALIZE\";\r\nexport const NEWS_ADMIN_INITIALIZE_SUCCESS = \"NEWS_ADMIN_INITIALIZE_SUCCESS\";\r\n\r\nexport const articlesInitNewsAdmin = () => async (dispatch) => {\r\n dispatch({ type: NEWS_ADMIN_INITIALIZE });\r\n await Promise.all([\r\n articlesSetTerritories(dispatch),\r\n articlesSetTopics(dispatch),\r\n articlesSetDocumentTypes(dispatch),\r\n articlesSetIssuers(dispatch),\r\n ]);\r\n dispatch({ type: NEWS_ADMIN_INITIALIZE_SUCCESS });\r\n};\r\n\r\nexport const ARTICLES_CHANGE_FILTERS = \"ARTICLES_CHANGE_FILTERS\";\r\n\r\nexport const articlesChangeFilters = (newFilters) => {\r\n return { type: ARTICLES_CHANGE_FILTERS, newFilters: newFilters };\r\n};\r\n\r\nexport const ARTICLES_CHANGE_TAB = \"ARTICLES_CHANGE_TAB\";\r\nexport const articlesChangeLandingTab = (tab) => {\r\n return { type: ARTICLES_CHANGE_TAB, tab };\r\n};\r\n\r\nexport const ARTICLES_RESET_FILTERS = \"ARTICLES_RESET_FILTERS\";\r\n\r\nexport const articlesResetFilters =\r\n (selectedType = null) =>\r\n (dispatch) => {\r\n dispatch({ type: ARTICLES_RESET_FILTERS, selectedType: selectedType });\r\n };\r\n\r\nexport const ARTICLES_SET_TERRITORIES = \"ARTICLES_SET_TERRITORIES\";\r\n\r\nconst articlesSetTerritories = async (dispath) => {\r\n const newData = await getTerritories();\r\n dispath({ type: ARTICLES_SET_TERRITORIES, newData });\r\n};\r\n\r\nexport const ARTICLES_SET_METADATA_TYPE = \"ARTICLES_SET_METADATA_TYPE\";\r\n\r\nconst articlesGetMetadataForType = (type) => async (dispath) => {\r\n const newData = await getUsedMetadataForType(type);\r\n\r\n dispath({\r\n type: ARTICLES_SET_METADATA_TYPE,\r\n payload: {\r\n type,\r\n newData,\r\n },\r\n });\r\n};\r\n\r\nexport const ARTICLES_SET_PERMISSIONS = \"ARTICLES_SET_PERMISSIONS\";\r\nexport const articlesSetPermissions = () => async (dispatch) => {\r\n const newData = await getNewsPermissions();\r\n dispatch({ type: ARTICLES_SET_PERMISSIONS, newData });\r\n};\r\n\r\nexport const ARTICLES_SET_ISSUERS = \"ARTICLES_SET_ISSUERS\";\r\nconst articlesSetIssuers = async (dispath) => {\r\n const newData = await getIssuers();\r\n dispath({ type: ARTICLES_SET_ISSUERS, newData });\r\n};\r\n\r\nexport const ARTICLES_MANUAL_CREATE_ISSUER = \"ARTICLES_MANUAL_CREATE_ISSUER\";\r\n\r\nexport const articlesManualCreateIssuer = (issuer) => {\r\n return {\r\n type: ARTICLES_MANUAL_CREATE_ISSUER,\r\n payload: issuer,\r\n };\r\n};\r\n\r\nexport const ARTICLES_MANUAL_UPDATE_ISSUER = \"ARTICLES_MANUAL_UPDATE_ISSUER\";\r\n\r\nexport const articlesManualUpdateIssuer = (issuer) => {\r\n return {\r\n type: ARTICLES_MANUAL_UPDATE_ISSUER,\r\n payload: issuer,\r\n };\r\n};\r\n\r\nexport const ARTICLES_MANUAL_DELETE_ISSUER = \"ARTICLES_MANUAL_DELETE_ISSUER\";\r\n\r\nexport const articlesManualDeleteIssuer = (issuer) => {\r\n return {\r\n type: ARTICLES_MANUAL_DELETE_ISSUER,\r\n payload: issuer,\r\n };\r\n};\r\n\r\nexport const ARTICLES_SET_ARTICLE = \"ARTICLES_SET_ARTICLE\";\r\n\r\nexport const articlesSetArticle = (newData) => {\r\n return { type: ARTICLES_SET_ARTICLE, newData: newData };\r\n};\r\n\r\nexport const ARTICLES_SET_ARTICLE_FIELD = \"ARTICLES_SET_ARTICLE_FIELD\";\r\n\r\nexport const articlesSetArticleField = (payload) => {\r\n return { type: ARTICLES_SET_ARTICLE_FIELD, payload: payload };\r\n};\r\n\r\nexport const NEWS_CHANGE_PAGE = \"NEWS_CHANGE_PAGE\";\r\nexport const NEWS_CHANGE_PAGE_SUCCESS = \"NEWS_CHANGE_PAGE_SUCCESS\";\r\n\r\nconst newsDefaultFilters = {\r\n published: true,\r\n type: null,\r\n territories: [],\r\n issuers: [],\r\n topics: [],\r\n documentTypes: [],\r\n effectiveDateRange: {},\r\n freeTextSearch: \"\",\r\n};\r\n\r\nconst newsDefaultOrderBy = {\r\n issueDate: {\r\n isDescending: true,\r\n },\r\n};\r\n\r\nexport const newsChangePage = (pageNumber) => async (dispatch) => {\r\n dispatch({ type: NEWS_CHANGE_PAGE, newData: { pageNumber } });\r\n\r\n const newData = await fetchNews(\r\n { filters: newsDefaultFilters, orderBy: newsDefaultOrderBy },\r\n { pageNumber }\r\n );\r\n\r\n dispatch({\r\n type: NEWS_CHANGE_PAGE_SUCCESS,\r\n newData: {\r\n totalCount: newData.totalCount,\r\n items: newData.items,\r\n hasNext: newData.hasNext,\r\n },\r\n });\r\n};\r\n\r\nexport const ARTICLES_SET_TOPICS = \"ARTICLES_SET_TOPICS\";\r\n\r\nconst articlesSetTopics = async (dispath) => {\r\n const newData = await getTopics();\r\n dispath({ type: ARTICLES_SET_TOPICS, newData });\r\n};\r\n\r\nexport const ARTICLES_MANUAL_CREATE_TOPIC = \"ARTICLES_MANUAL_CREATE_TOPIC\";\r\n\r\nexport const articlesManualCreateTopic = (topic) => {\r\n return {\r\n type: ARTICLES_MANUAL_CREATE_TOPIC,\r\n payload: topic,\r\n };\r\n};\r\n\r\nexport const ARTICLES_MANUAL_UPDATE_TOPIC = \"ARTICLES_MANUAL_UPDATE_TOPIC\";\r\n\r\nexport const articlesManualUpdateTopic = (topic) => {\r\n return {\r\n type: ARTICLES_MANUAL_UPDATE_TOPIC,\r\n payload: topic,\r\n };\r\n};\r\n\r\nexport const ARTICLES_MANUAL_DELETE_TOPIC = \"ARTICLES_MANUAL_DELETE_TOPIC\";\r\n\r\nexport const articlesManualDeleteTopic = (topic) => {\r\n return {\r\n type: ARTICLES_MANUAL_DELETE_TOPIC,\r\n payload: topic,\r\n };\r\n};\r\n\r\nexport const ARTICLES_SET_DOCUMENT_TYPES = \"ARTICLES_SET_DOCUMENT_TYPES\";\r\n\r\nconst articlesSetDocumentTypes = async (dispath) => {\r\n const newData = await getDocumentTypes();\r\n dispath({ type: ARTICLES_SET_DOCUMENT_TYPES, newData });\r\n};\r\n\r\nexport const ARTICLES_MANUAL_CREATE_DOCUMENT_TYPE =\r\n \"ARTICLES_MANUAL_CREATE_DOCUMENT_TYPE\";\r\n\r\nexport const articlesManualCreateDocumentType = (documenttype) => {\r\n return {\r\n type: ARTICLES_MANUAL_CREATE_DOCUMENT_TYPE,\r\n payload: documenttype,\r\n };\r\n};\r\n\r\nexport const ARTICLES_MANUAL_UPDATE_DOCUMENT_TYPE =\r\n \"ARTICLES_MANUAL_UPDATE_DOCUMENT_TYPE\";\r\n\r\nexport const articlesManualUpdateDocumentType = (documenttype) => {\r\n return {\r\n type: ARTICLES_MANUAL_UPDATE_DOCUMENT_TYPE,\r\n payload: documenttype,\r\n };\r\n};\r\n\r\nexport const ARTICLES_MANUAL_DELETE_DOCUMENT_TYPE =\r\n \"ARTICLES_MANUAL_DELETE_DOCUMENT_TYPE\";\r\n\r\nexport const articlesManualDeleteDocumentType = (documenttype) => {\r\n return {\r\n type: ARTICLES_MANUAL_DELETE_DOCUMENT_TYPE,\r\n payload: documenttype,\r\n };\r\n};\r\n\r\nexport const CALENDAR_SET_FOCUS_DATE = \"CALENDAR_SET_FOCUS_DATE\";\r\n\r\nexport const calendarSetFocusDate = (date) => {\r\n return {\r\n type: CALENDAR_SET_FOCUS_DATE,\r\n payload: date,\r\n };\r\n};\r\n","import { apiFetch } from \"../api\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT + \"Territory/\";\r\n\r\nexport const getTerritories = () => {\r\n return apiFetch(`${PREFIX}`);\r\n};\r\n","export const INITIALIZE = {\r\n FALSE: 0,\r\n WIP: 1,\r\n TRUE: 2,\r\n};\r\n\r\nexport const GLOBAL_ERRORS = {\r\n NO_ERROR: 0,\r\n UNKNOWN: 1,\r\n NO_COMPANY: 2,\r\n NO_USER: 3,\r\n SESSION_EXPIRED: 4,\r\n NO_TENANT: 5,\r\n};\r\n","import deepEqual from \"deep-equal\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\nimport { pollData, pollerCheck404, pollerCheckUndefined } from \"../apiPoller\";\r\nimport {\r\n CompanyCreateDTO,\r\n EntityCreateDTO,\r\n SubscriptionCreateDTO,\r\n SubscriptionDetailsReadDTO,\r\n SubscriptionFilters,\r\n SubscriptionOrderBy,\r\n SubscriptionUpdateDTO,\r\n} from \"./__generated__/UserManagementAPI\";\r\nimport {\r\n addEngagement,\r\n addUserToEngagement,\r\n addUserToEntity,\r\n createCompany,\r\n createEntity,\r\n createUser,\r\n deleteEngagement,\r\n deleteEntity,\r\n deleteUser,\r\n deleteUserFromEngagement,\r\n getAllEntities,\r\n getCompanies,\r\n getSubscriptionDetails,\r\n getSubscriptionsUsersPaged,\r\n getUserDetails,\r\n removeUserFromEntity,\r\n updateCompany,\r\n updateEngagement,\r\n updateEntity,\r\n updateProfile,\r\n updateSuperUserStatus,\r\n updateUser,\r\n updateUserEngagement,\r\n} from \"./adminApi\";\r\nimport { Company } from \"./model/Company\";\r\nimport { EntityUpdate } from \"./model/Entity\";\r\nimport { SubscriptionUpdate } from \"./model/Subscription\";\r\n\r\nexport const pollCheckCreatingUser = (ppid: string) => {\r\n return pollData(() => getUserDetails(ppid), pollerCheck404);\r\n};\r\n\r\nexport const pollAddCompany = async (company: CompanyCreateDTO) => {\r\n const addedCompany = await createCompany(company);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n return getCompanies().then((companies) => {\r\n companies.find((company) => company.id === addedCompany.id)\r\n ? resolve(addedCompany)\r\n : reject();\r\n });\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n addedCompany\r\n );\r\n};\r\n\r\nexport const pollUpdateCompany = async (company: Company) => {\r\n await updateCompany(company);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n return getCompanies().then((companies) => {\r\n companies.find((c) => c.id === company.id && c.name === company.name)\r\n ? resolve(company)\r\n : reject();\r\n });\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n company\r\n );\r\n};\r\n\r\nexport const pollCreateUser = async (user: any) => {\r\n const createdUser = await createUser(user);\r\n return await pollData(\r\n () => getUserDetails(createdUser.ppid!),\r\n pollerCheck404,\r\n 0,\r\n createdUser\r\n );\r\n};\r\n\r\nexport const pollUpdateUser = async (user: any, initialUser: any) => {\r\n await updateUser(user);\r\n return await checkUpdateUserProfile(user, initialUser);\r\n};\r\n\r\nexport const pollUpdateProfile = async (user: any, initialUser: any) => {\r\n await updateProfile(user);\r\n return await checkUpdateUserProfile(user, initialUser);\r\n};\r\n\r\nconst checkUpdateUserProfile = async (user: any, initialUser: any) => {\r\n return await pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getUserDetails(user.ppid)\r\n .then((userDetails) => {\r\n if (deepEqual(initialUser, userDetails)) {\r\n return reject();\r\n }\r\n resolve(userDetails);\r\n })\r\n .catch(reject);\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n initialUser\r\n );\r\n};\r\n\r\nexport const pollDeleteUser = async (ppid: string) => {\r\n await deleteUser(ppid);\r\n\r\n await pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n return getUserDetails(ppid)\r\n .then(() => reject())\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve();\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n pollerCheckUndefined\r\n );\r\n};\r\n\r\nexport const pollUpdateSuperUserStatus = async (\r\n ppid: string,\r\n isSuperUser: boolean\r\n) => {\r\n await updateSuperUserStatus(ppid, isSuperUser);\r\n return pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const userDetails = await getUserDetails(ppid);\r\n userDetails.isSuperUser === isSuperUser ? resolve(null) : reject();\r\n }),\r\n pollerCheckUndefined\r\n );\r\n};\r\n\r\nexport const pollAddEngagement = async (engagement: SubscriptionCreateDTO) => {\r\n const newEngagement = await addEngagement(engagement);\r\n\r\n return await pollData(\r\n () => getSubscriptionDetails(newEngagement.id).then(() => newEngagement),\r\n pollerCheck404,\r\n 0,\r\n newEngagement\r\n );\r\n};\r\n\r\nexport const pollUpdateEngagement = async (\r\n subscription: SubscriptionUpdate\r\n) => {\r\n await updateEngagement(subscription);\r\n\r\n return await pollData(\r\n () => {\r\n const { subscriptionId, ...data } = subscription;\r\n\r\n return new Promise(async (resolve, reject) => {\r\n const subscriptionDetails = await getSubscriptionDetails(\r\n subscriptionId\r\n );\r\n return isEqual(data, subscriptionDetails)\r\n ? resolve(subscriptionDetails)\r\n : reject();\r\n });\r\n },\r\n pollerCheckUndefined,\r\n 0,\r\n subscription\r\n );\r\n};\r\n\r\nfunction isEqual(\r\n dto: SubscriptionUpdateDTO,\r\n subscription: SubscriptionDetailsReadDTO\r\n) {\r\n return deepEqual(\r\n [\r\n dto.endDate ? new Date(dto.endDate).getTime() : null,\r\n dto.ec,\r\n dto.ecs,\r\n dto.clientContent,\r\n dto.ecModules,\r\n dto.ecsModules,\r\n dto.applications ? dto.applications.sort(localeCompare(\"name\")) : null,\r\n dto.contacts?.sort(),\r\n ],\r\n [\r\n subscription.endDate ? new Date(subscription.endDate).getTime() : null,\r\n subscription.ec,\r\n subscription.ecs,\r\n subscription.clientContent,\r\n subscription.ecModules,\r\n subscription.ecsModules,\r\n subscription.applications\r\n ? subscription.applications.sort(localeCompare(\"name\"))\r\n : null,\r\n subscription.contacts?.map((contact) => contact.ppid).sort(),\r\n ]\r\n );\r\n}\r\n\r\nexport const pollDeleteEngagement = async (subscriptionId: string) => {\r\n await deleteEngagement(subscriptionId);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getSubscriptionDetails(subscriptionId)\r\n .then(() => reject())\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve();\r\n }\r\n return reject();\r\n });\r\n }),\r\n pollerCheckUndefined\r\n );\r\n};\r\n\r\nexport const pollAddUserToEngagement = async (\r\n engagementId: string,\r\n ppids: string[]\r\n) => {\r\n await addUserToEngagement(engagementId, ppids);\r\n\r\n return Promise.all(\r\n ppids.map((ppid) =>\r\n pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const userInSubscription = await pollCheckUserInSubscription(\r\n ppid,\r\n engagementId\r\n );\r\n\r\n userInSubscription ? resolve(undefined) : reject();\r\n }),\r\n pollerCheckUndefined\r\n )\r\n )\r\n );\r\n};\r\n\r\nexport const pollUpdateUserEngagement = async (\r\n engagementId: string,\r\n userPpid: string,\r\n isMainContact: boolean\r\n) => {\r\n await updateUserEngagement(engagementId, userPpid, isMainContact);\r\n\r\n return pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const subscription = await getSubscriptionDetails(engagementId);\r\n subscription.users?.some(\r\n (user) =>\r\n user.ppid === userPpid && user.isMainContact === isMainContact\r\n )\r\n ? resolve(undefined)\r\n : reject();\r\n }),\r\n pollerCheckUndefined\r\n );\r\n};\r\n\r\nexport const pollDeleteUserFromEngagement = async (\r\n engagementId: string,\r\n ppid: string\r\n) => {\r\n await deleteUserFromEngagement(engagementId, ppid);\r\n\r\n return pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const userInSubscription = await pollCheckUserInSubscription(\r\n ppid,\r\n engagementId\r\n );\r\n\r\n userInSubscription ? reject() : resolve(undefined);\r\n }),\r\n pollerCheckUndefined\r\n );\r\n};\r\n\r\nasync function pollCheckUserInSubscription(\r\n ppid: string,\r\n subscriptionId: string\r\n): Promise {\r\n const subscriptions = await getSubscriptionsUsersPaged(\r\n {\r\n filters: {\r\n memberPpid: ppid,\r\n } as SubscriptionFilters,\r\n orderBy: {} as SubscriptionOrderBy,\r\n },\r\n { pageNumber: 1, pageSize: 999 }\r\n );\r\n\r\n return !!subscriptions.find(\r\n (subscription) => subscription.id === subscriptionId\r\n );\r\n}\r\n\r\nexport const pollAddEntity = async (entity: EntityCreateDTO) => {\r\n const newEntity = await createEntity(entity);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n return getAllEntities().then((entities) =>\r\n entities.find((e) => e.id === newEntity.id)\r\n ? resolve(newEntity)\r\n : reject()\r\n );\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n newEntity\r\n );\r\n};\r\n\r\nexport const pollUpdateEntity = async (entity: EntityUpdate) => {\r\n await updateEntity(entity);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n return getAllEntities().then((entities) => {\r\n const updatedEntity = entities.find((e) => {\r\n const ppids = e.contacts?.map((c) => c.ppid!) ?? [];\r\n return (\r\n e.id === entity.entityId &&\r\n e.name?.toUpperCase() === entity.name?.toUpperCase() &&\r\n e.prid === entity.prid &&\r\n ppids?.every((p) => entity.contacts?.includes(p)) &&\r\n entity.contacts?.every((p) => ppids.includes(p)) &&\r\n e.viewInMyServices === entity.viewInMyServices\r\n );\r\n });\r\n\r\n updatedEntity ? resolve(updatedEntity) : reject();\r\n });\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n entity\r\n );\r\n};\r\n\r\nexport const pollDeleteEntity = async (entityId: string) => {\r\n await deleteEntity(entityId);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n return getAllEntities().then((entities) => {\r\n const entityToDelete = entities.find((e) => e.id === entityId);\r\n entityToDelete ? reject() : resolve(undefined);\r\n });\r\n }),\r\n pollerCheckUndefined\r\n );\r\n};\r\n\r\nexport const pollAddUserToEntity = async (\r\n entityId: string,\r\n ppids: string[]\r\n) => {\r\n return addUserToEntity(entityId, ppids);\r\n};\r\n\r\nexport const pollRemoveUserFromEntity = async (\r\n entityId: string,\r\n ppid: string\r\n) => {\r\n return removeUserFromEntity(entityId, ppid);\r\n};\r\n","export const byId = (array, property = \"id\") => {\r\n return array.reduce((acc, item) => {\r\n acc[item[property]] = item;\r\n return acc;\r\n }, {});\r\n};\r\n\r\nexport const recursiveById = (\r\n array,\r\n property = \"id\",\r\n children = \"children\"\r\n) => {\r\n const rec = (acc, array) =>\r\n array.reduce((acc, item) => {\r\n acc[item[property]] = item;\r\n item[children] && rec(acc, item[children]);\r\n return acc;\r\n }, acc);\r\n\r\n return rec({}, array);\r\n};\r\n","import {\r\n ApplicationReadDTO,\r\n ContactReadDTO,\r\n} from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { getUserSubscriptions } from \"api/admin/adminApi\";\r\nimport { getServiceByIds } from \"api/catalog/catalogApi\";\r\nimport {\r\n ECModules,\r\n ECSModules,\r\n toECModules,\r\n toECSModules,\r\n} from \"pages/admin/components/Engagement/types\";\r\nimport { CatalogueService, toCatalogueService } from \"pages/catalogue/types\";\r\nimport { useEffect, useState } from \"react\";\r\nimport { byId } from \"utils/byId\";\r\n\r\nexport interface UserService {\r\n ec: string | null;\r\n ecs: string | null;\r\n clientContent: string | null;\r\n ecModules: ECModules | null;\r\n ecsModules: ECSModules | null;\r\n links: ApplicationReadDTO[];\r\n service: CatalogueService;\r\n contacts: ContactReadDTO[];\r\n clientContacts: ContactReadDTO[];\r\n}\r\n\r\nexport type UserServices = UserService[] | null;\r\n\r\nexport default function useUserServices(): UserServices {\r\n const [userServices, setUserServices] = useState(null);\r\n\r\n useEffect(() => {\r\n getUserSubscriptions().then((subscriptions) => {\r\n getServiceByIds(subscriptions.map((s) => s.serviceId)).then(\r\n (services) => {\r\n const serviceById = byId(services.map(toCatalogueService));\r\n\r\n const userServices: UserService[] = subscriptions\r\n .filter((subscription) => serviceById[subscription.serviceId])\r\n .map((subscription) => ({\r\n ec: subscription.ec,\r\n ecs: subscription.ecs,\r\n clientContent: subscription.clientContent,\r\n ecModules: toECModules(subscription.ecModules),\r\n ecsModules: toECSModules(subscription.ecsModules),\r\n links: subscription.applications || [],\r\n service: {\r\n ...serviceById[subscription.serviceId],\r\n subscribed: true,\r\n },\r\n contacts: subscription.contacts ?? [],\r\n clientContacts: subscription.clientContacts ?? [],\r\n }));\r\n\r\n setUserServices(userServices);\r\n }\r\n );\r\n });\r\n }, []);\r\n\r\n return userServices;\r\n}\r\n","export const isValidUrl = (href) => {\r\n if (typeof href !== \"string\") {\r\n return false;\r\n }\r\n const expression = /https?:\\/\\/(www\\.)?[-a-zA-Z0-9@:%._+~#=]{1,256}\\.[a-zA-Z0-9()]{1,6}\\b([-a-zA-Z0-9()@:%_+.~#?&//=]*)/gi;\r\n return href.match(new RegExp(expression)) !== null;\r\n};\r\n\r\nexport const formatBytes = (bytes, decimals = 2) => {\r\n if (bytes === 0) return \"0 Bytes\";\r\n\r\n const k = 1024;\r\n const dm = decimals < 0 ? 0 : decimals;\r\n const sizes = [\"Bytes\", \"KB\", \"MB\", \"GB\", \"TB\", \"PB\", \"EB\", \"ZB\", \"YB\"];\r\n\r\n const i = Math.floor(Math.log(bytes) / Math.log(k));\r\n\r\n return parseFloat((bytes / Math.pow(k, i)).toFixed(dm)) + \" \" + sizes[i];\r\n};\r\n\r\nexport const getInitialsFromName = (name) => {\r\n let initials = name\r\n .trim()\r\n .split(/ +/)\r\n .map((n) => n[0].toUpperCase())\r\n .join(\"\");\r\n if (initials.length > 3) {\r\n initials = initials.substr(0, 2) + initials.substr(initials.length - 1, 1);\r\n }\r\n return initials;\r\n};\r\n\r\nexport const downloadFromResponse = async (data, defaultFilename) => {\r\n const blob = await data.blob();\r\n\r\n let filename = defaultFilename;\r\n const contentDisposition = data.headers.get(\"Content-Disposition\");\r\n if (!!contentDisposition) {\r\n const regexp = /filename=(.*);/;\r\n const matchers = contentDisposition.match(regexp);\r\n if (matchers[1]) {\r\n filename = matchers[1];\r\n }\r\n }\r\n\r\n downloadBlob(blob, filename);\r\n};\r\n\r\nexport const downloadBlob = (blob, name) => {\r\n // Convert your blob into a Blob URL (a special url that points to an object in the browser's memory)\r\n const blobUrl = URL.createObjectURL(blob);\r\n\r\n // Create a link element\r\n const link = document.createElement(\"a\");\r\n\r\n // Set link's href to point to the Blob URL\r\n link.href = blobUrl;\r\n link.download = name;\r\n\r\n // Append link to the body\r\n document.body.appendChild(link);\r\n\r\n // Dispatch click event on the link\r\n // This is necessary as link.click() does not work on the latest firefox\r\n link.dispatchEvent(\r\n new MouseEvent(\"click\", {\r\n bubbles: true,\r\n cancelable: true,\r\n view: window,\r\n })\r\n );\r\n\r\n // Remove link from body\r\n document.body.removeChild(link);\r\n};\r\n","const tooltipMap = (selectedIds, ids, values) => {\r\n if (\r\n !Array.isArray(selectedIds) ||\r\n !Array.isArray(ids) ||\r\n !Array.isArray(values)\r\n ) {\r\n return undefined;\r\n }\r\n return selectedIds\r\n .map((id) => values[ids.findIndex((item) => item === id)])\r\n .join(\", \");\r\n};\r\n\r\nexport default tooltipMap;\r\n","import \"./index.scss\";\r\n\r\nimport { Tooltip } from \"@mui/material\";\r\nimport { Button, Select } from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport { useState } from \"react\";\r\nimport tooltipMap from \"utils/tooltipsMapper\";\r\n\r\nconst getTooltipContent = (value, children) => {\r\n return tooltipMap(\r\n value,\r\n children?.map((child) => child?.props?.value),\r\n children?.map((child) => child?.props?.children)\r\n );\r\n};\r\n\r\nconst ValidationSelectTooltipHoc = ({ ...selectProps }) => {\r\n const tooltip = getTooltipContent(selectProps?.value, selectProps?.children);\r\n const disabled =\r\n !tooltip || !selectProps.multiple || selectProps.value?.length < 2;\r\n return (\r\n \r\n
\r\n \r\n
\r\n
\r\n );\r\n};\r\n\r\nconst ValidationSelect = ({\r\n value,\r\n errMsg = undefined,\r\n hasError = false,\r\n className = undefined,\r\n clearable = false,\r\n multiple = false,\r\n onSelect,\r\n ...selectProps\r\n}) => {\r\n const [isOpen, setIsOpen] = useState(false);\r\n\r\n const isEmptyValue = multiple ? (value?.length ?? 0) === 0 : !value;\r\n\r\n return (\r\n
\r\n {clearable && !isEmptyValue && !isOpen && (\r\n {\r\n e.preventDefault();\r\n e.stopPropagation();\r\n\r\n onSelect(multiple ? [] : null);\r\n }}\r\n >\r\n \r\n \r\n )}\r\n\r\n setIsOpen(true)}\r\n multiple={multiple}\r\n onSelect={onSelect}\r\n onClose={() => setIsOpen(false)}\r\n className={classnames(hasError && \"a-select-error\", className)}\r\n {...selectProps}\r\n />\r\n {hasError && errMsg && typeof errMsg === \"string\" ? (\r\n

{errMsg}

\r\n ) : null}\r\n
\r\n );\r\n};\r\n\r\nexport default ValidationSelectTooltipHoc;\r\n","import \"./index.scss\";\r\n\r\nimport { getPhoto, getUsers, getUsersFromIdArray } from \"api/admin/adminApi\";\r\nimport classNames from \"classnames\";\r\nimport AsyncSelect from \"components/AsyncSelect\";\r\nimport { useCallback, useState } from \"react\";\r\n\r\nconst DEFAULT_FILTERS = {};\r\n\r\nexport const EXTERNAL_ONLY_FILTERS = {\r\n isInternal: false,\r\n};\r\n\r\nexport const INTERNAL_ONLY_FILTERS = {\r\n isInternal: true,\r\n};\r\n\r\nconst UserSelect = ({\r\n className = undefined,\r\n filters = DEFAULT_FILTERS,\r\n alreadyAdded = null,\r\n ...selectProps\r\n}) => {\r\n const [contactImages, setContactImages] = useState({});\r\n\r\n const loadUsers = useCallback(\r\n async (pageNumber, email) => {\r\n const items = await getUsers(\r\n {\r\n filters: { email, ...filters },\r\n orderBy: {\r\n email: {\r\n isDescending: false,\r\n },\r\n },\r\n },\r\n { pageNumber, pageSize: 20 }\r\n );\r\n\r\n const users = { items };\r\n\r\n if (alreadyAdded) {\r\n const alreadyAddedByPpid = alreadyAdded.reduce((acc, user) => {\r\n acc[user.ppid] = user;\r\n return acc;\r\n }, {});\r\n\r\n users.items = users.items.filter(\r\n (user) => !alreadyAddedByPpid[user.ppid]\r\n );\r\n }\r\n\r\n users.items.forEach((user) => {\r\n if (user.photoUri) {\r\n getPhoto(user.photoUri).then((photo) =>\r\n setContactImages((contactImages) => {\r\n return {\r\n ...contactImages,\r\n [user.photoUri]: photo,\r\n };\r\n })\r\n );\r\n }\r\n });\r\n\r\n return users.items;\r\n },\r\n [filters, alreadyAdded]\r\n );\r\n return (\r\n a.ppid === b.ppid}\r\n getTooltip={\r\n selectProps.multiple\r\n ? () => getUsersFromIdArray(selectProps.value.map((x) => x.id))\r\n : undefined\r\n }\r\n render={(contact) => (\r\n <>\r\n \r\n {contact.email ?? contact.name}\r\n \r\n )}\r\n />\r\n );\r\n};\r\n\r\nexport default UserSelect;\r\n","import { apiFetch } from \"../api\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT + \"DocumentType/\";\r\n\r\nexport const getDocumentTypes = () => {\r\n return apiFetch(`${PREFIX}`);\r\n};\r\n\r\nexport const getDocumentType = (documentTypeId) => {\r\n return apiFetch(`${PREFIX}${documentTypeId}`);\r\n};\r\n\r\nexport const createDocumentType = (documentType) => {\r\n return apiFetch(`${PREFIX}`, documentType, \"POST\");\r\n};\r\n\r\nexport const updateDocumentType = (documentType) => {\r\n return apiFetch(`${PREFIX}${documentType.id}`, documentType, \"PUT\");\r\n};\r\n\r\nexport const deleteDocumentType = (documentTypeId) => {\r\n return apiFetch(`${PREFIX}${documentTypeId}`, undefined, \"DELETE\");\r\n};\r\n","import { apiFetch } from \"../api\";\r\n\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT + \"Topic/\";\r\n\r\nexport const getTopics = () => {\r\n return apiFetch(`${PREFIX}`);\r\n};\r\n\r\nexport const getTopic = (topicId) => {\r\n return apiFetch(`${PREFIX}${topicId}`);\r\n};\r\n\r\nexport const createTopic = (topic) => {\r\n return apiFetch(`${PREFIX}`, topic, \"POST\");\r\n};\r\n\r\nexport const updateTopic = (topic) => {\r\n return apiFetch(`${PREFIX}${topic.id}`, topic, \"PUT\");\r\n};\r\n\r\nexport const deleteTopic = (topicId) => {\r\n return apiFetch(`${PREFIX}${topicId}`, undefined, \"DELETE\");\r\n};\r\n","import { apiFetch } from \"../api\";\r\nconst PREFIX = process.env.REACT_APP_URL_NEWS_ROOT + \"Issuer/\";\r\n\r\nexport const getIssuers = () => {\r\n return apiFetch(`${PREFIX}`);\r\n};\r\n\r\nexport const getIssuer = (issuerId) => {\r\n return apiFetch(`${PREFIX}${issuerId}`);\r\n};\r\n\r\nexport const createIssuer = (issuer) => {\r\n return apiFetch(`${PREFIX}`, issuer, \"POST\");\r\n};\r\n\r\nexport const updateIssuer = (issuer) => {\r\n return apiFetch(`${PREFIX}${issuer.id}`, issuer, \"PUT\");\r\n};\r\n\r\nexport const deleteIssuer = (issuerId) => {\r\n return apiFetch(`${PREFIX}${issuerId}`, undefined, \"DELETE\");\r\n};\r\n","export const FREQUENCIES = {\r\n // DAILY: 1,\r\n WEEKLY: 2,\r\n // MONTHLY: 3,\r\n};\r\n\r\nexport const FRENQUENCIES_LABEL = {\r\n // [FREQUENCIES.DAILY]: \"Daily\",\r\n [FREQUENCIES.WEEKLY]: \"Weekly\",\r\n // [FREQUENCIES.MONTHLY]: \"Monthly\",\r\n};\r\n","export default __webpack_public_path__ + \"static/media/undraw_empty.bb365899.svg\";","import { getNotificationTypes } from \"api/notification/notificationAPI\";\r\nimport { useEffect, useState } from \"react\";\r\n\r\ntype NotificationTypes = Record;\r\nexport type UseNotificationTypes = NotificationTypes | null;\r\n\r\nexport default function useNotificationTypes(): UseNotificationTypes {\r\n const [\r\n notificationTypes,\r\n setNotificationTypes,\r\n ] = useState(null);\r\n\r\n useEffect(() => {\r\n getNotificationTypes().then((notificationTypes) => {\r\n const byValue = notificationTypes.reduce((acc, n) => {\r\n acc[n.value] = n.name!;\r\n return acc;\r\n }, {} as NotificationTypes);\r\n\r\n setNotificationTypes(byValue);\r\n });\r\n }, []);\r\n\r\n return notificationTypes;\r\n}\r\n","import { UseTypedQueryOptions } from \"api/UseTypedQueryOptions\";\r\nimport { UseQueryResult, useQuery } from \"react-query\";\r\n\r\nimport {\r\n IndustryAllReadDTO,\r\n IndustryReadDTO,\r\n} from \"../__generated__/CatalogueAPI\";\r\nimport { getIndustries, getIndustriesAll } from \"../catalogApi\";\r\n\r\nexport default function useIndustries(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\"industries\", () => getIndustries(), props);\r\n}\r\n\r\nexport function useIndustriesAll(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\"industries-all\", () => getIndustriesAll(), props);\r\n}\r\n","import { UseTypedQueryOptions } from \"api/UseTypedQueryOptions\";\r\nimport { UseQueryResult, useQuery } from \"react-query\";\r\n\r\nimport { ServiceReadDTO } from \"../__generated__/CatalogueAPI\";\r\nimport { getCatalogue } from \"../catalogApi\";\r\n\r\nexport default function useLiveService(\r\n props?: UseTypedQueryOptions\r\n): UseQueryResult {\r\n return useQuery(\"service/live\", () => getCatalogue(), props);\r\n}\r\n","export const TABS = [\r\n {\r\n value: \"all\",\r\n label: \"All\",\r\n icon: \"icon-list-view\",\r\n },\r\n {\r\n value: \"news\",\r\n label: \"News\",\r\n icon: \"icon-pencil\",\r\n },\r\n {\r\n value: \"articles\",\r\n label: \"Articles \",\r\n icon: \"icon-news\",\r\n },\r\n {\r\n value: \"calendar\",\r\n label: \"Compliance Calendar\",\r\n icon: \"icon-calendar\",\r\n },\r\n {\r\n value: \"videos\",\r\n label: \"Videos\",\r\n icon: \"icon-play\",\r\n },\r\n {\r\n value: \"publications\",\r\n label: \"Publications\",\r\n icon: \"icon-survey\",\r\n },\r\n];\r\n","import { ARTICLE_TYPES } from \"../../pages/news/constants\";\r\nimport { TABS } from \"../../pages/news/constants/tabs\";\r\nimport { byId } from \"../../utils/byId\";\r\nimport {\r\n ARTICLES_CHANGE_FILTERS,\r\n ARTICLES_CHANGE_TAB,\r\n ARTICLES_INITIALIZE,\r\n ARTICLES_INITIALIZE_SUCCESS,\r\n ARTICLES_MANUAL_CREATE_DOCUMENT_TYPE,\r\n ARTICLES_MANUAL_CREATE_ISSUER,\r\n ARTICLES_MANUAL_CREATE_TOPIC,\r\n ARTICLES_MANUAL_DELETE_DOCUMENT_TYPE,\r\n ARTICLES_MANUAL_DELETE_ISSUER,\r\n ARTICLES_MANUAL_DELETE_TOPIC,\r\n ARTICLES_MANUAL_UPDATE_DOCUMENT_TYPE,\r\n ARTICLES_MANUAL_UPDATE_ISSUER,\r\n ARTICLES_MANUAL_UPDATE_TOPIC,\r\n ARTICLES_RESET_FILTERS,\r\n ARTICLES_SET_ARTICLE,\r\n ARTICLES_SET_ARTICLE_FIELD,\r\n ARTICLES_SET_DOCUMENT_TYPES,\r\n ARTICLES_SET_ISSUERS,\r\n ARTICLES_SET_METADATA_TYPE,\r\n ARTICLES_SET_PERMISSIONS,\r\n ARTICLES_SET_TERRITORIES,\r\n ARTICLES_SET_TOPICS,\r\n CALENDAR_SET_FOCUS_DATE,\r\n NEWS_ADMIN_INITIALIZE,\r\n NEWS_ADMIN_INITIALIZE_SUCCESS,\r\n NEWS_CHANGE_PAGE,\r\n NEWS_CHANGE_PAGE_SUCCESS,\r\n} from \"../actions/articles\";\r\nimport { INITIALIZE } from \"../constants\";\r\n\r\nconst defaultArticlesFilters = {\r\n published: true,\r\n type: null,\r\n territories: [],\r\n issuers: [],\r\n topics: [],\r\n documentTypes: [],\r\n issuedDateRange: {},\r\n freeTextSearch: \"\",\r\n textFilters: [],\r\n clientNoteFilter: {\r\n impact: null,\r\n ratings: [],\r\n assignedToMe: null,\r\n },\r\n pwcNoteFilter: {\r\n impact: null,\r\n ratings: [],\r\n },\r\n};\r\n\r\nconst initialState = {\r\n data: {\r\n itemsByType: Object.values(ARTICLE_TYPES).reduce((acc, key) => {\r\n acc[key] = {\r\n territories: null,\r\n territoriesById: null,\r\n topics: null,\r\n topicsById: null,\r\n documentTypes: null,\r\n documentTypesById: null,\r\n };\r\n return acc;\r\n }, {}),\r\n territories: null,\r\n territoriesById: null,\r\n topics: null,\r\n topicsById: null,\r\n documentTypes: null,\r\n documentTypesById: null,\r\n issuers: null,\r\n issuersById: null,\r\n news: {\r\n items: null,\r\n pageNumber: 1,\r\n totalCount: null,\r\n loading: false,\r\n hasNext: true,\r\n },\r\n articles: {\r\n items: null,\r\n pageNumber: 1,\r\n totalCount: null,\r\n loading: false,\r\n hasNext: true,\r\n },\r\n initialized: INITIALIZE.FALSE,\r\n newsAdminInitialized: INITIALIZE.FALSE,\r\n },\r\n filters: defaultArticlesFilters,\r\n calendarSourceDate: new Date(),\r\n currentArticle: null,\r\n permissions: null,\r\n landingTab: TABS[0].value,\r\n};\r\n\r\nfunction rootReducer(state = initialState, action) {\r\n switch (action.type) {\r\n // ARTICLES REDUCERS\r\n case ARTICLES_INITIALIZE:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n initialized: INITIALIZE.WIP,\r\n },\r\n };\r\n case ARTICLES_INITIALIZE_SUCCESS:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n initialized: INITIALIZE.TRUE,\r\n },\r\n };\r\n case NEWS_ADMIN_INITIALIZE:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n newsAdminInitialized: INITIALIZE.WIP,\r\n },\r\n };\r\n case NEWS_ADMIN_INITIALIZE_SUCCESS:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n newsAdminInitialized: INITIALIZE.TRUE,\r\n },\r\n };\r\n case ARTICLES_CHANGE_FILTERS:\r\n return {\r\n ...state,\r\n filters: action.newFilters,\r\n };\r\n\r\n case ARTICLES_CHANGE_TAB:\r\n return {\r\n ...state,\r\n landingTab: action.tab,\r\n };\r\n\r\n case ARTICLES_RESET_FILTERS:\r\n let newFilters = { ...defaultArticlesFilters };\r\n if (action.selectedType) {\r\n newFilters.type = action.selectedType;\r\n }\r\n return {\r\n ...state,\r\n filters: newFilters,\r\n };\r\n case ARTICLES_SET_TERRITORIES:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n territories: action.newData,\r\n territoriesById: byId(action.newData),\r\n },\r\n };\r\n case ARTICLES_SET_METADATA_TYPE:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n itemsByType: {\r\n ...state.data.itemsByType,\r\n [action.payload.type]: {\r\n ...state.data.itemsByType[action.payload.type],\r\n documentTypes: action.payload.newData.documentTypes,\r\n documentTypesById: byId(action.payload.newData.documentTypes),\r\n issuers: action.payload.newData.issuers,\r\n issuersById: byId(action.payload.newData.issuers),\r\n territories: action.payload.newData.territories,\r\n territoriesById: byId(action.payload.newData.territories),\r\n topics: action.payload.newData.topics,\r\n topicsById: byId(action.payload.newData.topics),\r\n initialized: true,\r\n },\r\n },\r\n },\r\n };\r\n case ARTICLES_SET_ISSUERS:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n issuers: action.newData,\r\n issuersById: byId(action.newData),\r\n },\r\n };\r\n case ARTICLES_MANUAL_CREATE_ISSUER:\r\n const issuersCreate = [...state.data.issuers, action.payload];\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n issuers: issuersCreate,\r\n issuersById: byId(issuersCreate),\r\n },\r\n };\r\n case ARTICLES_MANUAL_UPDATE_ISSUER:\r\n const issuersUpdate = state.data.issuers.map((issuer) =>\r\n issuer.id !== action.payload.id ? issuer : action.payload\r\n );\r\n\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n issuers: issuersUpdate,\r\n issuersById: byId(issuersUpdate),\r\n },\r\n };\r\n case ARTICLES_MANUAL_DELETE_ISSUER:\r\n const issuersDelete = state.data.issuers.filter(\r\n (issuer) => issuer.id !== action.payload.id\r\n );\r\n\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n issuers: issuersDelete,\r\n issuersById: byId(issuersDelete),\r\n },\r\n };\r\n case ARTICLES_SET_PERMISSIONS:\r\n return {\r\n ...state,\r\n permissions: action.newData.access,\r\n };\r\n case ARTICLES_SET_ARTICLE:\r\n return {\r\n ...state,\r\n currentArticle: action.newData,\r\n };\r\n case ARTICLES_SET_ARTICLE_FIELD:\r\n let newState = {\r\n ...state,\r\n currentArticle: {\r\n ...state.currentArticle,\r\n },\r\n };\r\n newState.currentArticle[action.payload.field] = action.payload.newData;\r\n return newState;\r\n\r\n case NEWS_CHANGE_PAGE:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n news: {\r\n ...state.data.news,\r\n pageNumber: action.newData.pageNumber,\r\n loading: true,\r\n },\r\n },\r\n };\r\n case NEWS_CHANGE_PAGE_SUCCESS:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n news: {\r\n ...state.data.news,\r\n items: [...(state.data.news.items || []), ...action.newData.items],\r\n totalCount: action.newData.totalCount,\r\n hasNext: action.newData.hasNext,\r\n loading: false,\r\n },\r\n },\r\n };\r\n case ARTICLES_SET_TOPICS:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n topics: action.newData,\r\n topicsById: byId(action.newData),\r\n },\r\n };\r\n case ARTICLES_MANUAL_CREATE_TOPIC:\r\n const topicsCreate = [...state.data.topics, action.payload];\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n topics: topicsCreate,\r\n topicsById: byId(topicsCreate),\r\n },\r\n };\r\n case ARTICLES_MANUAL_UPDATE_TOPIC:\r\n const topicsUpdate = state.data.topics.map((topic) =>\r\n topic.id !== action.payload.id ? topic : action.payload\r\n );\r\n\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n topics: topicsUpdate,\r\n topicsById: byId(topicsUpdate),\r\n },\r\n };\r\n case ARTICLES_MANUAL_DELETE_TOPIC:\r\n const topicsDelete = state.data.topics.filter(\r\n (topic) => topic.id !== action.payload.id\r\n );\r\n\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n topics: topicsDelete,\r\n topicsById: byId(topicsDelete),\r\n },\r\n };\r\n\r\n case ARTICLES_MANUAL_CREATE_DOCUMENT_TYPE:\r\n const documentTypesCreate = [...state.data.documentTypes, action.payload];\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n documentTypes: documentTypesCreate,\r\n documentTypesById: byId(documentTypesCreate),\r\n },\r\n };\r\n case ARTICLES_MANUAL_UPDATE_DOCUMENT_TYPE:\r\n const documentTypesUpdate = state.data.documentTypes.map((documenttype) =>\r\n documenttype.id !== action.payload.id ? documenttype : action.payload\r\n );\r\n\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n documentTypes: documentTypesUpdate,\r\n documentTypesById: byId(documentTypesUpdate),\r\n },\r\n };\r\n case ARTICLES_MANUAL_DELETE_DOCUMENT_TYPE:\r\n const documentTypesDelete = state.data.documentTypes.filter(\r\n (documenttype) => documenttype.id !== action.payload.id\r\n );\r\n\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n documentTypes: documentTypesDelete,\r\n documentTypesById: byId(documentTypesDelete),\r\n },\r\n };\r\n case ARTICLES_SET_DOCUMENT_TYPES:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n documentTypes: action.newData,\r\n documentTypesById: byId(action.newData),\r\n },\r\n };\r\n\r\n case CALENDAR_SET_FOCUS_DATE:\r\n return {\r\n ...state,\r\n calendarSourceDate: action.payload,\r\n };\r\n // DEFAULT REDUCER\r\n default:\r\n return state;\r\n }\r\n}\r\n\r\nexport default rootReducer;\r\n","import {\r\n ADMIN_ACCEPT_TERMS_AND_CONDITIONS,\r\n GLOBAL_INIT,\r\n GLOBAL_INIT_ERROR,\r\n GLOBAL_INIT_SUCCESS,\r\n UPSERT_HOSTINFO,\r\n UPSERT_LOGINUSER,\r\n UPSERT_TENANTS,\r\n} from \"../actions/global\";\r\nimport { GLOBAL_ERRORS, INITIALIZE } from \"../constants\";\r\n\r\nconst initialState = {\r\n data: {\r\n loginUser: null,\r\n companies: {\r\n items: null,\r\n itemsById: {},\r\n loading: false,\r\n },\r\n hostInfo: null,\r\n tenants: null,\r\n hasError: GLOBAL_ERRORS.NO_ERROR,\r\n },\r\n initialized: INITIALIZE.FALSE,\r\n};\r\n\r\nfunction usersReducer(state = initialState, action) {\r\n switch (action.type) {\r\n case GLOBAL_INIT:\r\n return {\r\n ...state,\r\n initialized: INITIALIZE.WIP,\r\n };\r\n case GLOBAL_INIT_SUCCESS:\r\n return {\r\n ...state,\r\n initialized: INITIALIZE.TRUE,\r\n };\r\n case GLOBAL_INIT_ERROR:\r\n return {\r\n ...state,\r\n hasError: action.error,\r\n initialized: INITIALIZE.TRUE,\r\n };\r\n case UPSERT_LOGINUSER:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n loginUser: {\r\n ...(state.data.loginUser || {}),\r\n ...action.payload,\r\n },\r\n },\r\n };\r\n case UPSERT_HOSTINFO:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n hostInfo: {\r\n ...action.payload,\r\n },\r\n },\r\n };\r\n\r\n case UPSERT_TENANTS:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n tenants: [...action.payload],\r\n },\r\n };\r\n\r\n case ADMIN_ACCEPT_TERMS_AND_CONDITIONS:\r\n return {\r\n ...state,\r\n data: {\r\n ...state.data,\r\n loginUser: {\r\n ...state.data.loginUser,\r\n termsAndConditionsAccepted: true,\r\n },\r\n },\r\n };\r\n default:\r\n return state;\r\n }\r\n}\r\n\r\nexport default usersReducer;\r\n","import { TABS } from \"pages/newsAdmin/components/TableToggle\";\r\n\r\nimport { NEWS_ADMIN_CHANGE_TAB } from \"../actions/newsAdmin\";\r\n\r\nconst initialState = {\r\n tab: TABS.NEWS,\r\n};\r\n\r\nfunction rootReducer(state = initialState, action) {\r\n switch (action.type) {\r\n case NEWS_ADMIN_CHANGE_TAB:\r\n return {\r\n ...state,\r\n tab: action.payload,\r\n };\r\n\r\n // DEFAULT REDUCER\r\n default:\r\n return state;\r\n }\r\n}\r\n\r\nexport default rootReducer;\r\n","import { applyMiddleware, combineReducers, compose, createStore } from \"redux\";\r\nimport thunk from \"redux-thunk\";\r\n\r\nimport articlesReducer from \"../reducers/articles\";\r\nimport globalReducer from \"../reducers/global\";\r\nimport newsAdminReducer from \"../reducers/newsAdmin\";\r\n\r\nconst composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose;\r\n/*window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__({\r\n trace: true, // (action) => { return ‘trace as string’; }\r\n traceLimit: 25,\r\n })*/\r\n\r\nexport default createStore(\r\n combineReducers({\r\n global: globalReducer,\r\n articles: articlesReducer,\r\n newsAdmin: newsAdminReducer,\r\n }),\r\n composeEnhancers(applyMiddleware(thunk))\r\n);\r\n","import { GLOBAL_ERRORS } from \"redux/constants\";\r\n\r\nexport const UPSERT_LOGINUSER = \"UPSERT_LOGINUSER\";\r\nexport const upsertLoginUser = (userInfo) => {\r\n return {\r\n type: UPSERT_LOGINUSER,\r\n payload: userInfo,\r\n };\r\n};\r\n\r\nexport const UPSERT_HOSTINFO = \"UPSERT_HOSTINFO\";\r\nexport const upsertHostInfo = (hostInfo) => {\r\n return {\r\n type: UPSERT_HOSTINFO,\r\n payload: hostInfo,\r\n };\r\n};\r\n\r\nconst tenantColors = [\r\n \"#415385\",\r\n \"#D04A02\",\r\n \"#26776D\",\r\n \"#D93954\",\r\n \"#E0301E\",\r\n \"#757575\",\r\n];\r\n\r\nexport const UPSERT_TENANTS = \"UPSERT_TENANTS\";\r\nexport const upsertTenants = (tenants) => {\r\n return {\r\n type: UPSERT_TENANTS,\r\n payload: tenants.map((tenant, index) => ({\r\n ...tenant,\r\n color: tenantColors[Math.min(tenantColors.length - 1, index)],\r\n })),\r\n };\r\n};\r\n\r\nexport const setLoginUserNotFound = () => {\r\n return {\r\n type: GLOBAL_INIT_ERROR,\r\n error: GLOBAL_ERRORS.NO_USER,\r\n };\r\n};\r\n\r\nexport const setSessionExpired = () => {\r\n return {\r\n type: GLOBAL_INIT_ERROR,\r\n error: GLOBAL_ERRORS.SESSION_EXPIRED,\r\n };\r\n};\r\n\r\nexport const setNoTenant = () => {\r\n return {\r\n type: GLOBAL_INIT_ERROR,\r\n error: GLOBAL_ERRORS.NO_TENANT,\r\n };\r\n};\r\n\r\nexport const GLOBAL_INIT = \"GLOBAL_INIT\";\r\nexport const GLOBAL_INIT_SUCCESS = \"GLOBAL_INIT_SUCCESS\";\r\nexport const GLOBAL_INIT_ERROR = \"GLOBAL_INIT_ERROR\";\r\n\r\n// FIXME JGE how can we manage user permissions\r\nexport const globalInitialize = () => async (dispatch) => {\r\n dispatch({\r\n type: GLOBAL_INIT,\r\n });\r\n dispatch({\r\n type: GLOBAL_INIT_SUCCESS,\r\n });\r\n};\r\n\r\nexport const ADMIN_ACCEPT_TERMS_AND_CONDITIONS =\r\n \"ADMIN_ACCEPT_TERMS_AND_CONDITIONS\";\r\n\r\nexport const adminAcceptTermsAndConditions = () => (dispatch) => {\r\n dispatch({ type: ADMIN_ACCEPT_TERMS_AND_CONDITIONS });\r\n};\r\n","export const getRandomSeededInt = (min, max, rng = Math.random) => {\r\n min = Math.ceil(min);\r\n max = Math.floor(max);\r\n return Math.floor(rng() * (max - min + 1)) + min;\r\n};\r\n\r\nexport const guid = () => {\r\n return \"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx\".replace(/[xy]/g, function (c) {\r\n var r = (Math.random() * 16) | 0,\r\n // eslint-disable-next-line\r\n v = c == \"x\" ? r : (r & 0x3) | 0x8;\r\n return v.toString(16);\r\n });\r\n};\r\n\r\nexport const isValidGuid = (str) => {\r\n return /^[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(\r\n str\r\n );\r\n};\r\n","import { ApplicationCreateDTO } from \"api/admin/__generated__/UserManagementAPI\";\r\nimport {\r\n ApplicationReadDTO,\r\n ServiceContactReadDTO,\r\n ServiceIllustrationReadDTO,\r\n ServiceReadDTO,\r\n} from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { ServiceCreateDTO, ServiceUpdateDTO } from \"api/catalog/type\";\r\nimport { FormErrors, hasError } from \"hooks/useSubmitable\";\r\nimport { validateURL } from \"pages/news/utils/videoMatcher\";\r\nimport { isValidUrl } from \"utils\";\r\n\r\nexport interface ServiceForm {\r\n id?: string;\r\n name: string;\r\n description: string;\r\n live: boolean;\r\n applications: ApplicationReadDTO[];\r\n team: ServiceContactReadDTO[];\r\n responsibles: ServiceContactReadDTO[];\r\n videoLink: string;\r\n itContact: ServiceContactReadDTO | null;\r\n organizations: string[];\r\n industries: string[];\r\n isHighlighted: boolean;\r\n isNew: boolean;\r\n isPSF: boolean;\r\n isPSA: boolean;\r\n lifeCycles: string[];\r\n valueChains: string[];\r\n smallDescription: string;\r\n geographicalInformation: string;\r\n targetProfile: string;\r\n availableApplication: string;\r\n deliverable: string;\r\n mainAddedValue: string;\r\n secondaryAddedValue: string;\r\n relatedServices: string[];\r\n illustrations: ServiceIllustrationReadDTO[];\r\n illustrationsToAdd: File[];\r\n illustrationsToRemove: string[];\r\n serviceGroupId?: string | null;\r\n viewers: ServiceContactReadDTO[];\r\n domains: string[];\r\n territories: string[];\r\n friendlyUrl: string;\r\n visibleInClientView: boolean;\r\n ukViewers: ServiceContactReadDTO[];\r\n frViewers: ServiceContactReadDTO[];\r\n}\r\n\r\ntype ServiceFormErrors = {\r\n [Property in keyof ServiceForm]?: FormErrors | string | boolean | null;\r\n};\r\n\r\ninterface ApplicationForm {\r\n name: string | null;\r\n link: string | null;\r\n}\r\nexport function findFormErrors(form: ServiceForm): ServiceFormErrors {\r\n return {\r\n name: form.name.trim().length <= 0 && \"Please provide a valid name\",\r\n description:\r\n form.description.trim().length <= 0\r\n ? \"Please provide a valid description\"\r\n : null,\r\n smallDescription:\r\n form.smallDescription.trim().length <= 0 ||\r\n form.smallDescription.trim().length > 160\r\n ? \"Please provide a valid short description (max 160 characters)\"\r\n : null,\r\n responsibles:\r\n form.responsibles.length > 3 && \"A maximum of 3 responsibles is allowed.\",\r\n industries:\r\n form.industries.length === 0 && \"Please choose at least one tag\",\r\n videoLink: form.videoLink.trim().length > 0 && validateURL(form.videoLink),\r\n // @ts-ignore\r\n applications: findApplicationErrors(form.applications),\r\n geographicalInformation:\r\n form.geographicalInformation.trim().length <= 0 ||\r\n form.geographicalInformation.trim().length > 160\r\n ? \"Please provide a valid geographical information (max 160 characters)\"\r\n : null,\r\n targetProfile:\r\n form.targetProfile.trim().length <= 0 ||\r\n form.targetProfile.trim().length > 160\r\n ? \"Please provide a valid target profile (max 160 characters)\"\r\n : null,\r\n mainAddedValue:\r\n form.mainAddedValue.trim().length <= 0 ||\r\n form.mainAddedValue.trim().length > 160\r\n ? \"Please provide a valid main added value (max 160 characters)\"\r\n : null,\r\n secondaryAddedValue:\r\n form.secondaryAddedValue.trim().length <= 0 ||\r\n form.secondaryAddedValue.trim().length > 160\r\n ? \"Please provide a valid secondary added value (max 160 characters)\"\r\n : null,\r\n deliverable:\r\n form.deliverable.trim().length <= 0 ||\r\n form.deliverable.trim().length > 160\r\n ? \"Please provide a valid deliverable (max 160 characters)\"\r\n : null,\r\n availableApplication:\r\n form.availableApplication.trim().length <= 0 ||\r\n form.availableApplication.trim().length > 160\r\n ? \"Please provide a valid available application (max 160 characters)\"\r\n : null,\r\n lifeCycles:\r\n form.lifeCycles.length <= 0 ? \"Please provide a life cycle\" : null,\r\n valueChains:\r\n form.valueChains.length <= 0 ? \"Please provide a value chain\" : null,\r\n };\r\n}\r\n\r\nexport function computeApplicationError(item: ApplicationForm) {\r\n const link = item.link?.trim() || \"\";\r\n const name = item.name?.trim() || \"\";\r\n\r\n const errors = {\r\n name:\r\n link.length > 0 && name.length === 0\r\n ? \"Please provide a valid name\"\r\n : null,\r\n link:\r\n name.length > 0 && !isValidUrl(link)\r\n ? \"Please provide a valid URL\"\r\n : null,\r\n };\r\n\r\n return hasError(errors) ? errors : null;\r\n}\r\n\r\nexport function findApplicationErrors(\r\n applications: ApplicationForm[]\r\n): FormErrors | null {\r\n const errors = applications.reduce((errors, application, index) => {\r\n const error = computeApplicationError(application);\r\n if (!!error) {\r\n // @ts-ignore\r\n errors[index] = error;\r\n }\r\n return errors;\r\n }, {});\r\n return Object.keys(errors).length > 0\r\n ? (errors as FormErrors)\r\n : null;\r\n}\r\n\r\nconst toPascalCase = (s: string) => `${s[0].toUpperCase()}${s.slice(1)}`;\r\n\r\nexport function toServiceCreateDTO(form: ServiceForm): ServiceCreateDTO {\r\n const videoLink = form.videoLink.trim();\r\n const applications = form.applications\r\n .filter((app) => app.name!.trim().length > 0 && app.link!.trim().length > 0)\r\n .map((app) => {\r\n return {\r\n name: app.name!.trim(),\r\n link: app.link!.trim(),\r\n itContactPpid: app.itContact?.ppid || null,\r\n showToClient: app.showToClient,\r\n };\r\n });\r\n const ret: ServiceCreateDTO = {\r\n Name: form.name.trim(),\r\n Description: form.description.trim(),\r\n Live: form.live,\r\n ResponsiblesPpids: form.responsibles.map((p) => p.ppid!),\r\n TeamPpids: form.team.map((p) => p.ppid!),\r\n VideoLink: videoLink.length ? videoLink : undefined,\r\n // TODO JGE Check that\r\n // Tags: [...form.lifeCycleTags, ...form.companyManagementTags],\r\n Applications: applications,\r\n ItContactPpid: form.itContact?.ppid ?? undefined,\r\n Organizations: form.organizations,\r\n Industries: form.industries,\r\n RelatedServices: form.relatedServices ?? [],\r\n IsHighlighted: form.isHighlighted,\r\n IsNew: form.isNew,\r\n IsPSA: form.isPSA,\r\n IsPSF: form.isPSF,\r\n SmallDescription: form.smallDescription,\r\n LifeCycles: form.lifeCycles,\r\n ValueChains: form.valueChains,\r\n MainAddedValue: form.mainAddedValue,\r\n SecondaryAddedValue: form.secondaryAddedValue,\r\n GeographicalInformation: form.geographicalInformation,\r\n AvailableApplication: form.availableApplication,\r\n Deliverable: form.deliverable,\r\n TargetProfile: form.targetProfile,\r\n Illustrations: form.illustrationsToAdd,\r\n ServiceGroupId: form.serviceGroupId ?? undefined,\r\n ViewersPpids: form.viewers.map((item) => item.ppid!),\r\n UkViewersPpids: form.ukViewers.map((item) => item.ppid!),\r\n FrViewersPpids: form.frViewers.map((item) => item.ppid!),\r\n Domains: form.domains,\r\n Territories: form.territories,\r\n FriendlyUrl: form.friendlyUrl ?? \"\",\r\n VisibleInClientView: form.visibleInClientView ?? true,\r\n };\r\n processApplications(ret, applications);\r\n return ret;\r\n}\r\n\r\nconst processApplications = (\r\n input: ServiceCreateDTO,\r\n applications: ApplicationCreateDTO[]\r\n) => {\r\n applications.forEach((app, index) => {\r\n Object.entries(app).forEach(([key, value]) => {\r\n input[`Applications[${index}].${toPascalCase(key)}`] = value;\r\n });\r\n });\r\n delete input.Applications;\r\n};\r\n\r\nexport function toServiceUpdateDTO(form: ServiceForm): ServiceUpdateDTO {\r\n const { Illustrations, ...service } = toServiceCreateDTO(form);\r\n return {\r\n ...service,\r\n IllustrationsToAdd: form.illustrationsToAdd,\r\n IllustrationsToRemove: form.illustrationsToRemove,\r\n };\r\n}\r\n\r\nexport function toServiceForm(service: ServiceReadDTO): ServiceForm {\r\n return {\r\n ...service,\r\n name: service.name || \"\",\r\n description: service.description || \"\",\r\n applications: service.applications || [],\r\n responsibles: service.responsibles || [],\r\n team: service.team || [],\r\n videoLink: service.videoLink || \"\",\r\n itContact: service.itContact,\r\n organizations: service.organizations || [],\r\n industries: service.industries ? (service.industries as string[]) : [],\r\n isHighlighted: service.isHighlighted,\r\n isNew: service.isNew,\r\n lifeCycles: service.lifeCycles ?? [],\r\n valueChains: service.valueChains ?? [],\r\n smallDescription: service.smallDescription ?? \"\",\r\n geographicalInformation: service.geographicalInformation ?? \"\",\r\n targetProfile: service.targetProfile ?? \"\",\r\n availableApplication: service.availableApplication ?? \"\",\r\n deliverable: service.deliverable ?? \"\",\r\n mainAddedValue: service.mainAddedValue ?? \"\",\r\n secondaryAddedValue: service.secondaryAddedValue ?? \"\",\r\n relatedServices:\r\n service.relatedServices?.map((service) => service.id) ?? [],\r\n illustrations: service.illustrations ?? [],\r\n illustrationsToAdd: [],\r\n illustrationsToRemove: [],\r\n serviceGroupId: service.serviceGroupId,\r\n viewers: service.viewers ?? [],\r\n domains: service.domains ?? [],\r\n territories: service.territories?.map((territory) => territory.id) ?? [],\r\n friendlyUrl: service.friendlyUrl ?? \"\",\r\n visibleInClientView: service.visibleInClientView ?? true,\r\n ukViewers: service.ukViewers ?? [],\r\n frViewers: service.frViewers ?? [],\r\n };\r\n}\r\n","import {\r\n AssignedUserReadDTO,\r\n ContactReadDTO,\r\n SubscriptionCreateDTO,\r\n SubscriptionDetailsReadDTO,\r\n} from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { toUTCISODateString } from \"api/helpers\";\r\nimport { FormErrors } from \"hooks/useSubmitable\";\r\nimport { isValidGuid } from \"utils/random\";\r\n\r\nimport { findApplicationErrors } from \"../../Service/type/form\";\r\nimport { ECModules, ECSModules, toECModules, toECSModules } from \"./\";\r\n\r\nexport interface SubscriptionLinkForm {\r\n name: string;\r\n link: string;\r\n showToClient: boolean;\r\n}\r\n\r\nexport interface SubscriptionForm {\r\n id?: string | null;\r\n companyId: string | null;\r\n entityId: string | null;\r\n serviceId: string | null;\r\n endDate: Date | null;\r\n clientContent: string;\r\n hasECLink: boolean;\r\n ec: string;\r\n ecModules: ECModules;\r\n hasECSLink: boolean;\r\n ecs: string;\r\n ecsModules: ECSModules;\r\n links: SubscriptionLinkForm[];\r\n contacts: ContactReadDTO[];\r\n users: AssignedUserReadDTO[];\r\n}\r\n\r\ntype SubscriptionFormError = {\r\n [Property in keyof SubscriptionForm]?:\r\n | FormErrors\r\n | string\r\n | boolean\r\n | null;\r\n};\r\n\r\nexport const findFormErrors = (\r\n form: SubscriptionForm,\r\n isEditMode: boolean\r\n): SubscriptionFormError => {\r\n return {\r\n companyId: form.companyId === null,\r\n entityId: form.entityId === null,\r\n serviceId: form.serviceId === null,\r\n ec:\r\n form.hasECLink && !isValidECLink(form.ec)\r\n ? \"Please provide a valid EC id or URL\"\r\n : null,\r\n ecs:\r\n form.hasECSLink && !isValidECSLink(form.ecs)\r\n ? \"Please provide a valide Ecs site name or URL\"\r\n : null,\r\n // @ts-ignore\r\n links: findApplicationErrors(form.links),\r\n contacts: form.contacts?.length < 1 ? \"Please choose a contact.\" : null,\r\n users:\r\n !isEditMode && form.users?.length < 1 ? \"Please choose a contact.\" : null,\r\n };\r\n};\r\n\r\nfunction tokenizer(str: string, prefix: string) {\r\n const splited = str.trim().split(prefix);\r\n if (!splited[1]) {\r\n return null;\r\n }\r\n return splited[1].split(\"/\")[0];\r\n}\r\n\r\nfunction extractor(\r\n str: string,\r\n baseUri: string,\r\n validator: (str: string) => boolean\r\n) {\r\n let res = null;\r\n\r\n const trimed = str.trim();\r\n if (validator(trimed)) {\r\n res = trimed;\r\n } else {\r\n const extracted = tokenizer(str, baseUri);\r\n res = extracted && validator(extracted) ? extracted.trim() : null;\r\n }\r\n\r\n return res && res.length > 0 ? res : null;\r\n}\r\n\r\nfunction extractECLink(link: string) {\r\n return extractor(link, process.env.REACT_APP_EC_BASEURI!, isValidGuid);\r\n}\r\n\r\nfunction isValidECLink(link: string) {\r\n return extractECLink(link) !== null;\r\n}\r\n\r\nfunction isValidECSSite(site: string) {\r\n return /^[^\\\\/:]+$/.test(site);\r\n}\r\n\r\nfunction extractECSLink(link: string) {\r\n return extractor(link, process.env.REACT_APP_ECS_BASEURI!, isValidECSSite);\r\n}\r\n\r\nfunction isValidECSLink(link: string) {\r\n return extractECSLink(link) !== null;\r\n}\r\n\r\nexport function toSubscriptionForm(\r\n dto: SubscriptionDetailsReadDTO\r\n): SubscriptionForm {\r\n return {\r\n id: dto.id,\r\n companyId: dto.companyId,\r\n entityId: dto.entityId,\r\n serviceId: dto.serviceId,\r\n endDate: dto.endDate ? new Date(dto.endDate) : null,\r\n clientContent: dto.clientContent || \"\",\r\n hasECLink: !!dto.ec,\r\n ec: dto.ec || \"\",\r\n ecModules: toECModules(dto.ecModules),\r\n hasECSLink: !!dto.ecs,\r\n ecs: dto.ecs || \"\",\r\n ecsModules: toECSModules(dto.ecsModules),\r\n links: dto.applications\r\n ? dto.applications.map((app) => ({\r\n name: app.name || \"\",\r\n link: app.link || \"\",\r\n showToClient: app.showToClient,\r\n }))\r\n : [],\r\n contacts: dto.contacts ?? [],\r\n users: dto.users ?? [],\r\n };\r\n}\r\n\r\nexport function toSubscriptionCreateDTO(\r\n form: SubscriptionForm\r\n): SubscriptionCreateDTO {\r\n const clientContent = form.clientContent.trim();\r\n const ec = form.ec.trim();\r\n const ecs = form.ecs.trim();\r\n\r\n return {\r\n companyId: form.companyId!,\r\n entityId: form.entityId!,\r\n serviceId: form.serviceId!,\r\n endDate: form.endDate ? toUTCISODateString(form.endDate) : null,\r\n clientContent: clientContent.length > 0 ? clientContent : null,\r\n ec: form.hasECLink ? extractECLink(ec) : null,\r\n ecs: form.hasECSLink ? extractECSLink(ecs) : null,\r\n ecModules: form.hasECLink ? (form.ecModules as any) : null,\r\n ecsModules: form.hasECSLink ? (form.ecsModules as any) : null,\r\n applications: form.links.filter((link) => link.name.trim().length > 0),\r\n contacts: form.contacts.map((contact) => contact.ppid!),\r\n users: form.users,\r\n };\r\n}\r\n","import {\r\n SubscriptionCreateDTO,\r\n SubscriptionFilters,\r\n SubscriptionTrialFilter,\r\n} from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { getSubscriptionsUsersPaged } from \"api/admin/adminApi\";\r\nimport {\r\n pollAddEngagement,\r\n pollAddUserToEngagement,\r\n pollDeleteEngagement,\r\n pollDeleteUserFromEngagement,\r\n pollUpdateEngagement,\r\n pollUpdateUserEngagement,\r\n} from \"api/admin/adminPoller\";\r\nimport { SubscriptionUpdate } from \"api/admin/model/Subscription\";\r\nimport useData from \"hooks/useData\";\r\nimport { useCallback, useMemo } from \"react\";\r\n\r\nimport { SubscriptionForm, toSubscriptionCreateDTO } from \"../types/form\";\r\n\r\nexport interface UseSubscriptions {\r\n data: any; // FIXME JGE\r\n upsertSubscription: (form: SubscriptionForm) => Promise;\r\n deleteSubscription: (SubscriptionId: string) => Promise;\r\n addUserToSubscription: (\r\n subscriptionId: string,\r\n ppid: string[]\r\n ) => Promise;\r\n updateUserSubscription: (\r\n subscriptionId: string,\r\n userPpid: string,\r\n isMainContact: boolean\r\n ) => Promise;\r\n removeUserFromSubscription: (\r\n subscriptionId: string,\r\n ppid: string\r\n ) => Promise;\r\n}\r\n\r\ninterface Filter {\r\n id: string;\r\n value: any;\r\n}\r\n\r\nexport const DEFAULT_SORT = [{ id: \"service\", desc: false }];\r\n\r\n// test-only-export\r\nexport function toSubscriptionApiFilter(\r\n filters: Filter[]\r\n): SubscriptionFilters {\r\n return filters.reduce((acc, filter) => {\r\n const value =\r\n typeof filter.value === \"string\" ? filter.value.trim() : filter.value;\r\n\r\n switch (filter.id) {\r\n case \"service\":\r\n acc.serviceName = value;\r\n break;\r\n case \"company\":\r\n acc.companyName = value;\r\n break;\r\n case \"entity\":\r\n acc.entityName = value;\r\n break;\r\n case \"name\":\r\n acc.memberName = value;\r\n break;\r\n case \"myServices\":\r\n acc.my = value;\r\n break;\r\n case \"trial\":\r\n acc.trial = value;\r\n break;\r\n default:\r\n break;\r\n }\r\n\r\n return acc;\r\n }, {} as SubscriptionFilters);\r\n}\r\n\r\ninterface InputFilters {\r\n rowFilters: Filter[];\r\n myServices?: boolean;\r\n trial: SubscriptionTrialFilter;\r\n}\r\n\r\nexport default function useSubscriptions(\r\n filters: InputFilters\r\n): UseSubscriptions {\r\n const apiFilters = useMemo(() => {\r\n const filtersArray = [...filters.rowFilters];\r\n\r\n filtersArray.push({ id: \"trial\", value: filters.trial });\r\n\r\n if (!!filters.myServices) {\r\n filtersArray.push({ id: \"myServices\", value: true });\r\n }\r\n\r\n return toSubscriptionApiFilter(filtersArray);\r\n }, [filters]);\r\n const data = useData(\r\n apiFilters,\r\n getSubscriptionsUsersPaged,\r\n DEFAULT_SORT,\r\n true\r\n );\r\n const fetchData = data.fetchData;\r\n\r\n const upsertSubscription = useCallback(\r\n (form: SubscriptionForm) => {\r\n let promise;\r\n\r\n if (form.id) {\r\n const subscription: SubscriptionUpdate = {\r\n ...toSubscriptionCreateDTO(form),\r\n subscriptionId: form.id,\r\n contacts: form.contacts.map((contact) => contact.ppid!),\r\n };\r\n\r\n promise = pollUpdateEngagement(subscription);\r\n } else {\r\n const subscription: SubscriptionCreateDTO =\r\n toSubscriptionCreateDTO(form);\r\n\r\n promise = pollAddEngagement(subscription);\r\n }\r\n\r\n return promise.then(fetchData);\r\n },\r\n [fetchData]\r\n );\r\n\r\n const deleteSubscription = useCallback(\r\n (subscriptionId: string) => {\r\n return pollDeleteEngagement(subscriptionId).then(fetchData);\r\n },\r\n [fetchData]\r\n );\r\n\r\n const addUserToSubscription = useCallback(\r\n (subscriptionId: string, ppids: string[]) => {\r\n return pollAddUserToEngagement(subscriptionId, ppids).then(fetchData);\r\n },\r\n [fetchData]\r\n );\r\n\r\n const updateUserSubscription = useCallback(\r\n (subscriptionId: string, userPpid: string, isMainContact: boolean) => {\r\n return pollUpdateUserEngagement(\r\n subscriptionId,\r\n userPpid,\r\n isMainContact\r\n ).then(fetchData);\r\n },\r\n [fetchData]\r\n );\r\n\r\n const removeUserFromSubscription = useCallback(\r\n (subscriptionId: string, ppid: string) => {\r\n return pollDeleteUserFromEngagement(subscriptionId, ppid).then(fetchData);\r\n },\r\n [fetchData]\r\n );\r\n\r\n return {\r\n data,\r\n upsertSubscription,\r\n updateUserSubscription,\r\n deleteSubscription,\r\n addUserToSubscription,\r\n removeUserFromSubscription,\r\n };\r\n}\r\n","import { createContext } from \"react\";\r\n\r\nimport useSubscriptions, { UseSubscriptions } from \"./hooks/useSubscriptions\";\r\n\r\nexport const AdminEngagementContext = createContext(\r\n (undefined as any) as UseSubscriptions\r\n);\r\n\r\nconst EngagementsTableContextWrapper = ({ children, filters }: any) => {\r\n const reducer = useSubscriptions(filters);\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport default EngagementsTableContextWrapper;\r\n","import deepEqual from \"deep-equal\";\r\n\r\nimport { pollData } from \"../apiPoller\";\r\nimport {\r\n getThreeWPermissions,\r\n updateThreeWPermissions,\r\n} from \"./engagementAccessApi\";\r\n\r\nexport const pollUpdateThreeWPermissions = async (\r\n idSubscription,\r\n permissions,\r\n oldData\r\n) => {\r\n if (deepEqual(permissions, oldData)) {\r\n return Promise.resolve(permissions);\r\n }\r\n\r\n await updateThreeWPermissions(idSubscription, permissions);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getThreeWPermissions(idSubscription).then((data) => {\r\n !deepEqual(data, oldData) ? resolve(data) : reject();\r\n });\r\n }),\r\n (err) => err === undefined,\r\n 0,\r\n oldData\r\n );\r\n};\r\n","import \"./index.scss\";\r\n\r\nimport { Button, Input, List, ListItem } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport { useMemo, useState } from \"react\";\r\nimport { byId } from \"utils/byId\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\nconst Item = ({ item, disabled = false, onPrevious, onNext }) => {\r\n return (\r\n \r\n {onPrevious && (\r\n onPrevious(item)}\r\n >\r\n <\r\n \r\n )}\r\n\r\n {item.name}\r\n\r\n {onNext && (\r\n onNext(item)}\r\n >\r\n >\r\n \r\n )}\r\n \r\n );\r\n};\r\n\r\nconst MultiSelectColumn = ({ items, disabled, label, onPrevious, onNext }) => {\r\n const [search, setSearch] = useState(\"\");\r\n\r\n const searchFilter = search.trim().toUpperCase();\r\n return (\r\n
\r\n \r\n }\r\n />\r\n\r\n \r\n {items\r\n .filter((item) => item.name.toUpperCase().includes(searchFilter))\r\n .sort(localeCompare(\"name\"))\r\n .map((item) => (\r\n \r\n ))}\r\n \r\n
\r\n );\r\n};\r\n\r\nconst addTo = (item, array) => {\r\n return [...array, item];\r\n};\r\n\r\nconst removeFrom = (item, array) => {\r\n return array.filter((selected) => selected.id !== item.id);\r\n};\r\n\r\nconst MultiSelect = ({\r\n items,\r\n selection,\r\n onSelectionChange,\r\n denied,\r\n onDeniedChange,\r\n disabled,\r\n hasError,\r\n errorMsg,\r\n}) => {\r\n const availables = useMemo(() => {\r\n let othersById = byId(selection);\r\n\r\n if (denied) {\r\n othersById = {\r\n ...othersById,\r\n ...byId(denied),\r\n };\r\n }\r\n\r\n return items.filter((item) => !othersById[item.id]);\r\n }, [items, selection, denied]);\r\n\r\n const handleSelectAll = () => onSelectionChange([...availables]);\r\n const handleRemoveAll = () => onSelectionChange([]);\r\n\r\n const addToSelection = (item) => onSelectionChange(addTo(item, selection));\r\n const removeFromSelection = (item) =>\r\n onSelectionChange(removeFrom(item, selection));\r\n\r\n const handleSelectAllDenied = () => onDeniedChange([...availables]);\r\n const handleRemoveAllDenied = () => onDeniedChange([]);\r\n\r\n const addToDenied = denied\r\n ? (item) => onDeniedChange(addTo(item, denied))\r\n : undefined;\r\n const removeFromDenied = denied\r\n ? (item) => onDeniedChange(removeFrom(item, denied))\r\n : undefined;\r\n\r\n return (\r\n \r\n
\r\n {denied && (\r\n <>\r\n \r\n\r\n
\r\n \r\n <<\r\n \r\n \r\n >>\r\n \r\n
\r\n \r\n )}\r\n \r\n\r\n
\r\n \r\n <<\r\n \r\n \r\n >>\r\n \r\n
\r\n\r\n \r\n
\r\n\r\n {hasError && errorMsg &&

{errorMsg}

}\r\n
\r\n );\r\n};\r\n\r\nexport default MultiSelect;\r\n","import \"./index.scss\";\r\n\r\nimport { getThreeWPermissions } from \"api/news/engagementAccessApi\";\r\nimport { pollUpdateThreeWPermissions } from \"api/news/engagementAccessPoller\";\r\nimport {\r\n Button,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n Switch,\r\n} from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport useNewsAdminInitialize from \"pages/newsAdmin/hooks/useNewsAdminInitialize\";\r\nimport { useEffect, useState } from \"react\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nimport useSubmitable from \"../../../../hooks/useSubmitable\";\r\nimport MultiSelect from \"../MultiSelect\";\r\n\r\nconst defaultForm = {\r\n allTerritories: false,\r\n territories: [],\r\n allTopics: false,\r\n topics: [],\r\n deniedTopics: [],\r\n allDocumentTypes: false,\r\n documentTypes: [],\r\n deniedDocumentTypes: [],\r\n};\r\n\r\nconst findFormErrors = (form) => {\r\n return {\r\n territories:\r\n !form.allTerritories &&\r\n form.territories.length === 0 &&\r\n \"Please select at least one territory\",\r\n topics:\r\n !form.allTopics &&\r\n form.topics.length === 0 &&\r\n \"Please select at least one topic\",\r\n documentTypes:\r\n !form.allDocumentTypes &&\r\n form.documentTypes.length === 0 &&\r\n \"Please select at least one document type\",\r\n };\r\n};\r\n\r\nconst toPermissions = (form) => {\r\n return {\r\n territoryIds: form.allTerritories\r\n ? null\r\n : form.territories.map(({ id }) => id),\r\n topicIds: form.allTopics ? null : form.topics.map(({ id }) => id),\r\n deniedTopicIds: form.allTopics\r\n ? null\r\n : form.deniedTopics.map(({ id }) => id),\r\n documentTypeIds: form.allDocumentTypes\r\n ? null\r\n : form.documentTypes.map(({ id }) => id),\r\n deniedDocumentTypeIds: form.allDocumentTypes\r\n ? null\r\n : form.deniedDocumentTypes.map(({ id }) => id),\r\n };\r\n};\r\n\r\nconst ThreeWPermissionsModal = ({ engagement = null, onClose }) => {\r\n const initialized = useNewsAdminInitialize();\r\n const {\r\n territories,\r\n territoriesById,\r\n topics,\r\n topicsById,\r\n documentTypes,\r\n documentTypesById,\r\n } = useSelector((state) => state.articles.data);\r\n\r\n const [oldPermissions, setOldPermissions] = useState();\r\n\r\n const visible = !!engagement;\r\n\r\n const {\r\n values: form,\r\n handleValueChange,\r\n resetForm,\r\n submitting,\r\n formErrors,\r\n submit,\r\n } = useSubmitable(defaultForm, findFormErrors);\r\n\r\n const handleSubmit = async () => {\r\n await submit(() => {\r\n return pollUpdateThreeWPermissions(\r\n engagement.id,\r\n { ...toPermissions(form), engagementId: engagement.id },\r\n oldPermissions\r\n ).then(onClose);\r\n });\r\n };\r\n\r\n useEffect(() => {\r\n if (!visible) {\r\n resetForm();\r\n }\r\n }, [visible, resetForm]);\r\n\r\n useEffect(() => {\r\n if (!(engagement && initialized)) {\r\n return;\r\n }\r\n\r\n getThreeWPermissions(engagement.id).then((permissions) => {\r\n setOldPermissions(permissions);\r\n\r\n const form = {\r\n allTerritories: permissions.territoryIds === null,\r\n territories: permissions.territoryIds\r\n ? permissions.territoryIds.map((id) => territoriesById[id])\r\n : defaultForm.territories,\r\n allTopics: permissions.topicIds === null,\r\n topics: permissions.topicIds\r\n ? permissions.topicIds.map((id) => topicsById[id])\r\n : defaultForm.topics,\r\n deniedTopics: permissions.deniedTopicIds\r\n ? permissions.deniedTopicIds.map((id) => topicsById[id])\r\n : defaultForm.deniedTopics,\r\n\r\n allDocumentTypes: permissions.documentTypeIds === null,\r\n documentTypes: permissions.documentTypeIds\r\n ? permissions.documentTypeIds.map((id) => documentTypesById[id])\r\n : defaultForm.documentTypes,\r\n deniedDocumentTypes: permissions.deniedDocumentTypeIds\r\n ? permissions.deniedDocumentTypeIds.map((id) => documentTypesById[id])\r\n : defaultForm.documentTypes,\r\n };\r\n\r\n resetForm(form);\r\n });\r\n }, [\r\n engagement,\r\n initialized,\r\n territoriesById,\r\n topicsById,\r\n documentTypesById,\r\n resetForm,\r\n ]);\r\n\r\n return (\r\n \r\n \r\n
Manage 3W Permissions
\r\n
\r\n \r\n {!!initialized && (\r\n <>\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"allTerritories\", value)\r\n }\r\n label=\"All territories\"\r\n />\r\n
\r\n \r\n handleValueChange(\"territories\", territories)\r\n }\r\n hasError={!!formErrors.territories}\r\n errorMsg={formErrors.territories}\r\n disabled={form.allTerritories}\r\n />\r\n
\r\n\r\n
\r\n
\r\n \r\n handleValueChange(\"allTopics\", value)}\r\n label=\"All topics\"\r\n />\r\n
\r\n \r\n handleValueChange(\"topics\", topics)\r\n }\r\n denied={form.allTopics ? [] : form.deniedTopics}\r\n onDeniedChange={(deniedTopics) =>\r\n handleValueChange(\"deniedTopics\", deniedTopics)\r\n }\r\n hasError={!!formErrors.topics}\r\n errorMsg={formErrors.topics}\r\n disabled={form.allTopics}\r\n />\r\n
\r\n\r\n
\r\n
\r\n \r\n\r\n \r\n handleValueChange(\"allDocumentTypes\", value)\r\n }\r\n label=\"All doc types\"\r\n />\r\n
\r\n \r\n handleValueChange(\"documentTypes\", documentTypes)\r\n }\r\n denied={form.allDocumentTypes ? [] : form.deniedDocumentTypes}\r\n onDeniedChange={(deniedDocumentTypes) =>\r\n handleValueChange(\"deniedDocumentTypes\", deniedDocumentTypes)\r\n }\r\n hasError={!!formErrors.documentTypes}\r\n errorMsg={formErrors.documentTypes}\r\n disabled={form.allDocumentTypes}\r\n />\r\n
\r\n \r\n )}\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default ThreeWPermissionsModal;\r\n","import { Item } from \"./type\";\r\n\r\nexport const ADMIN_FETCHLIST = \"ADMIN_FETCHLIST\";\r\ntype FetchListAction = {\r\n type: typeof ADMIN_FETCHLIST;\r\n};\r\nexport const fetchList = (): FetchListAction => {\r\n return { type: ADMIN_FETCHLIST };\r\n};\r\n\r\nexport const ADMIN_FETCHLIST_SUCCESS = \"ADMIN_FETCHLIST_SUCCESS\";\r\ntype FetchListSuccessAction = {\r\n type: typeof ADMIN_FETCHLIST_SUCCESS;\r\n payload: T[];\r\n};\r\nexport function fetchListSuccess(\r\n payload: T[]\r\n): FetchListSuccessAction {\r\n return {\r\n type: ADMIN_FETCHLIST_SUCCESS,\r\n payload,\r\n };\r\n}\r\n\r\nexport const ADMIN_ITEM_ADDED = \"ADMIN_ITEM_ADDED\";\r\ntype ItemAddedAction = {\r\n type: typeof ADMIN_ITEM_ADDED;\r\n payload: T;\r\n};\r\nexport function itemAdded(payload: T): ItemAddedAction {\r\n return {\r\n type: ADMIN_ITEM_ADDED,\r\n payload,\r\n };\r\n}\r\n\r\nexport const ADMIN_ITEM_UPDATED = \"ADMIN_ITEM_UPDATED\";\r\ntype ItemUpdatedAction = {\r\n type: typeof ADMIN_ITEM_UPDATED;\r\n payload: T;\r\n};\r\nexport function itemUpdated(payload: T): ItemUpdatedAction {\r\n return {\r\n type: ADMIN_ITEM_UPDATED,\r\n payload,\r\n };\r\n}\r\n\r\nexport const ADMIN_ITEM_DELETED = \"ADMIN_ITEM_DELETED\";\r\ntype ItemDeletedAction = {\r\n type: typeof ADMIN_ITEM_DELETED;\r\n payload: T;\r\n};\r\n\r\nexport function itemDeleted(payload: T): ItemDeletedAction {\r\n return {\r\n type: ADMIN_ITEM_DELETED,\r\n payload,\r\n };\r\n}\r\n\r\nexport type Action =\r\n | FetchListAction\r\n | FetchListSuccessAction\r\n | ItemAddedAction\r\n | ItemUpdatedAction\r\n | ItemDeletedAction;\r\n","import { byId } from \"utils/byId\";\r\n\r\nimport { Item, State } from \"./type\";\r\nimport {\r\n ADMIN_FETCHLIST,\r\n ADMIN_FETCHLIST_SUCCESS,\r\n ADMIN_ITEM_ADDED,\r\n ADMIN_ITEM_DELETED,\r\n ADMIN_ITEM_UPDATED,\r\n Action,\r\n} from \".\";\r\n\r\nexport const initialState: State = {\r\n items: null,\r\n itemsById: null,\r\n loading: false,\r\n};\r\n\r\nexport default function adminListReducer(\r\n state: State,\r\n action: Action\r\n): State {\r\n switch (action.type) {\r\n case ADMIN_FETCHLIST:\r\n return {\r\n ...state,\r\n loading: true,\r\n };\r\n\r\n case ADMIN_FETCHLIST_SUCCESS:\r\n return {\r\n ...state,\r\n items: action.payload,\r\n itemsById: byId(action.payload),\r\n loading: false,\r\n };\r\n\r\n case ADMIN_ITEM_ADDED:\r\n const listAdded = [\r\n ...(state.items || []),\r\n {\r\n users: [],\r\n ...action.payload,\r\n },\r\n ];\r\n return {\r\n ...state,\r\n items: listAdded,\r\n itemsById: byId(listAdded),\r\n };\r\n\r\n case ADMIN_ITEM_UPDATED:\r\n const listUpdated = state.items!.map((item) =>\r\n item.id === action.payload.id ? action.payload : item\r\n );\r\n\r\n return {\r\n ...state,\r\n items: listUpdated,\r\n itemsById: byId(listUpdated),\r\n };\r\n\r\n case ADMIN_ITEM_DELETED:\r\n let listDeleted = state.items!.filter(\r\n (item) => item.id !== action.payload.id\r\n );\r\n\r\n return {\r\n ...state,\r\n items: listDeleted,\r\n itemsById: byId(listDeleted),\r\n };\r\n\r\n default:\r\n return state;\r\n }\r\n}\r\n","import React from \"react\";\r\n\r\nimport useCompanyReducer from \"./hooks/useCompanyReducer\";\r\n\r\nexport const AdminCompanyContext = React.createContext();\r\n\r\nconst AdminCompanyContextHOC = ({ children }) => {\r\n const reducer = useCompanyReducer();\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport default AdminCompanyContextHOC;\r\n","import { getCompanies } from \"api/admin/adminApi\";\r\nimport { pollAddCompany, pollUpdateCompany } from \"api/admin/adminPoller\";\r\nimport {\r\n fetchList,\r\n fetchListSuccess,\r\n itemAdded,\r\n itemUpdated,\r\n} from \"pages/admin/actions\";\r\nimport adminReducer, { initialState } from \"pages/admin/actions/reducer\";\r\nimport { useCallback, useEffect, useReducer } from \"react\";\r\n\r\nexport default function useCompanyReducer() {\r\n const [state, dispatch] = useReducer(adminReducer, initialState);\r\n\r\n const fetchCompanyList = useCallback(async () => {\r\n dispatch(fetchList());\r\n\r\n const companies = await getCompanies();\r\n dispatch(fetchListSuccess(companies));\r\n }, []);\r\n\r\n const setCompanyList = useCallback((companies) => {\r\n dispatch(fetchListSuccess(companies));\r\n }, []);\r\n\r\n const addCompany = useCallback((form) => {\r\n return pollAddCompany(form).then((company) => {\r\n dispatch(itemAdded(company));\r\n return company;\r\n });\r\n }, []);\r\n\r\n const updateCompany = useCallback((form) => {\r\n return pollUpdateCompany(form).then((company) => {\r\n dispatch(itemUpdated(company));\r\n return company;\r\n });\r\n }, []);\r\n\r\n useEffect(() => {\r\n fetchCompanyList();\r\n }, [fetchCompanyList]);\r\n\r\n return {\r\n ...state,\r\n fetchCompanyList,\r\n setCompanyList,\r\n addCompany,\r\n updateCompany,\r\n };\r\n}\r\n","import { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { AdminCompanyContext } from \"pages/admin/components/Company\";\r\nimport { useContext } from \"react\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\nconst CompanySelect = ({ value, onValueChange, ...selectProps }) => {\r\n const { items: companies } = useContext(AdminCompanyContext);\r\n\r\n return (\r\n \r\n {companies?.sort(localeCompare(\"name\")).map((company) => (\r\n \r\n {company.name}\r\n \r\n ))}\r\n \r\n );\r\n};\r\n\r\nexport default CompanySelect;\r\n","import React from \"react\";\r\n\r\nimport useEntityReducer from \"./hooks/useEntityReducer\";\r\n\r\nexport const AdminEntityContext = React.createContext();\r\n\r\nconst AdminEntityContextHOC = ({ children }) => {\r\n const reducer = useEntityReducer();\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport default AdminEntityContextHOC;\r\n","import { getAllEntities } from \"api/admin/adminApi\";\r\nimport {\r\n pollAddEntity,\r\n pollAddUserToEntity,\r\n pollDeleteEntity,\r\n pollRemoveUserFromEntity,\r\n pollUpdateEntity,\r\n} from \"api/admin/adminPoller\";\r\nimport {\r\n fetchList,\r\n fetchListSuccess,\r\n itemAdded,\r\n itemDeleted,\r\n itemUpdated,\r\n} from \"pages/admin/actions\";\r\nimport adminReducer, { initialState } from \"pages/admin/actions/reducer\";\r\nimport { useCallback, useEffect, useReducer } from \"react\";\r\n\r\nexport default function useEntityReducer() {\r\n const [state, dispatch] = useReducer(adminReducer, initialState);\r\n\r\n const fetchEntityList = useCallback(async () => {\r\n dispatch(fetchList());\r\n\r\n const entities = await getAllEntities();\r\n dispatch(fetchListSuccess(entities));\r\n }, []);\r\n\r\n const setEntityList = useCallback((entities) => {\r\n dispatch(fetchListSuccess(entities));\r\n }, []);\r\n\r\n const addEntity = useCallback((form) => {\r\n return pollAddEntity(form).then((entity) => {\r\n dispatch(itemAdded(entity));\r\n return entity;\r\n });\r\n }, []);\r\n\r\n const updateEntity = useCallback((form) => {\r\n return pollUpdateEntity(form).then((entity) => {\r\n dispatch(itemUpdated(entity));\r\n return entity;\r\n });\r\n }, []);\r\n\r\n const deleteEntity = useCallback((entity) => {\r\n return pollDeleteEntity(entity.id).then(() => {\r\n dispatch(itemDeleted(entity));\r\n });\r\n }, []);\r\n\r\n const addUserToEntity = useCallback((entityId, ppids) => {\r\n return pollAddUserToEntity(entityId, ppids).then((entity) => {\r\n dispatch(itemUpdated(entity));\r\n return entity;\r\n });\r\n }, []);\r\n\r\n const removeUserFromEntity = useCallback((entityId, ppid) => {\r\n return pollRemoveUserFromEntity(entityId, ppid).then((entity) => {\r\n dispatch(itemUpdated(entity));\r\n return entity;\r\n });\r\n }, []);\r\n\r\n useEffect(() => {\r\n fetchEntityList();\r\n }, [fetchEntityList]);\r\n\r\n return {\r\n ...state,\r\n fetchEntityList,\r\n setEntityList,\r\n addEntity,\r\n updateEntity,\r\n deleteEntity,\r\n addUserToEntity,\r\n removeUserFromEntity,\r\n };\r\n}\r\n","import { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { useContext, useEffect, useState } from \"react\";\r\n\r\nimport { AdminEntityContext } from \"../../../Entity\";\r\n\r\nconst EntitySelect = ({\r\n companyId,\r\n disabled,\r\n value,\r\n onValueChange,\r\n companyIdRequired,\r\n ...selectProps\r\n}) => {\r\n const [values, setValues] = useState(null);\r\n const { items: entities } = useContext(AdminEntityContext);\r\n\r\n useEffect(() => {\r\n if (companyId && entities?.length) {\r\n const newValues = entities\r\n .filter((entity) => entity.companyId === companyId)\r\n .map((entity) => ({\r\n id: entity.id,\r\n name: entity.name,\r\n companyId: entity.companyId,\r\n }));\r\n\r\n newValues.sort((a, b) => a.name.localeCompare(b.name));\r\n\r\n setValues(newValues);\r\n } else {\r\n if (entities && !companyIdRequired) {\r\n const newValues = [...entities];\r\n newValues.sort((a, b) => a.name.localeCompare(b.name));\r\n setValues(newValues);\r\n }\r\n }\r\n }, [companyId, entities, companyIdRequired]);\r\n\r\n return (\r\n \r\n {values?.map((entity) => (\r\n \r\n {entity.name}\r\n \r\n ))}\r\n \r\n );\r\n};\r\n\r\nexport default EntitySelect;\r\n","import { useCallback, useEffect } from \"react\";\r\n\r\ninterface Namable {\r\n name: string | null;\r\n}\r\n\r\ntype OnChange = (items: T[]) => void;\r\n\r\nexport interface UseMultilineForm {\r\n handleChange: (value: T, index: number) => void;\r\n handleDelete: (index: number) => void;\r\n}\r\n\r\nexport default function useMultilineForm(\r\n items: T[],\r\n onItemsChange: OnChange,\r\n defaultItem: T\r\n): UseMultilineForm {\r\n const handleChange = useCallback(\r\n (newApp: T, index: number) => {\r\n let newApplications;\r\n if (index >= items.length) {\r\n newApplications = [...items, newApp];\r\n } else {\r\n newApplications = items.map((oldApp, i) =>\r\n i === index ? newApp : oldApp\r\n );\r\n }\r\n\r\n onItemsChange(newApplications);\r\n },\r\n [items, onItemsChange]\r\n );\r\n\r\n const handleDelete = useCallback(\r\n (index: number) => {\r\n if (index !== items.length - 1) {\r\n onItemsChange(items.filter((_, i) => i !== index));\r\n } else {\r\n onItemsChange(\r\n items.map((app, i) => (i !== index ? app : { ...defaultItem }))\r\n );\r\n }\r\n },\r\n [defaultItem, onItemsChange, items]\r\n );\r\n\r\n useEffect(() => {\r\n if (\r\n items.length === 0 ||\r\n // @ts-ignore\r\n items[items.length - 1]?.name?.length > 0\r\n ) {\r\n onItemsChange([...items, { ...defaultItem }]);\r\n }\r\n }, [items, onItemsChange, defaultItem]);\r\n\r\n return { handleChange, handleDelete };\r\n}\r\n","import \"./LinkForm.scss\";\r\n\r\nimport { Button, Input, Switch } from \"appkit-react\";\r\nimport { FormErrors } from \"hooks/useSubmitable\";\r\n\r\nimport { SubscriptionLinkForm } from \"../../types/form\";\r\n\r\ninterface Props {\r\n value: SubscriptionLinkForm;\r\n errors?: FormErrors | null;\r\n onValueChange: (value: SubscriptionLinkForm) => void;\r\n onDelete?: () => void;\r\n onUnfocus?: () => void;\r\n}\r\nexport default function LinkForm({\r\n value: items,\r\n errors,\r\n onValueChange,\r\n onDelete,\r\n onUnfocus,\r\n}: Props) {\r\n const handleValueChange = (property: keyof SubscriptionLinkForm) => (\r\n value: string\r\n ) => {\r\n onValueChange({\r\n ...items,\r\n [property]: value,\r\n });\r\n };\r\n\r\n return (\r\n
\r\n
\r\n \r\n \r\n\r\n \r\n\r\n \r\n
\r\n
\r\n );\r\n}\r\n","import { FormErrors } from \"hooks/useSubmitable\";\r\nimport useMultilineForm from \"pages/admin/hooks/useMultilineForm\";\r\n\r\nimport { SubscriptionLinkForm } from \"../../types/form\";\r\nimport LinkForm from \"./LinkForm\";\r\n\r\nexport const DEFAULT_LINK: SubscriptionLinkForm = {\r\n name: \"\",\r\n link: \"\",\r\n showToClient: true,\r\n};\r\n\r\ninterface Props {\r\n items: SubscriptionLinkForm[];\r\n errors?: FormErrors;\r\n onItemsChange: (applications: SubscriptionLinkForm[]) => void;\r\n}\r\n\r\nexport default function LinksForm({ items, errors, onItemsChange }: Props) {\r\n const { handleChange, handleDelete } = useMultilineForm(\r\n items,\r\n onItemsChange,\r\n DEFAULT_LINK\r\n );\r\n return (\r\n <>\r\n {items.map((link, index) => (\r\n handleChange(link, index)}\r\n onDelete={() => handleDelete(index)}\r\n />\r\n ))}\r\n\r\n
\r\n (Leave blank to avoid adding a new link)\r\n
\r\n \r\n );\r\n}\r\n","import { ServiceReadForAdminDTO } from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { ServiceTag, ServiceType } from \"api/catalog/type\";\r\n\r\nexport interface ServiceItem {\r\n id: string;\r\n domains: string[];\r\n name: string;\r\n live: boolean;\r\n isNew: boolean;\r\n isHighlighted: boolean;\r\n canAddSubscription: boolean;\r\n}\r\n\r\nexport interface ServiceTenantItem {\r\n id: string;\r\n name: string;\r\n url: string;\r\n domain: string;\r\n}\r\n\r\nexport interface ServiceDetails extends ServiceItem {\r\n description: string;\r\n type: ServiceType;\r\n tags: ServiceTag[];\r\n}\r\n\r\nexport function toServiceItem(dto: ServiceReadForAdminDTO): ServiceItem {\r\n return {\r\n id: dto.id,\r\n name: dto.name!,\r\n live: dto.live || false,\r\n canAddSubscription: dto.canAddSubscription,\r\n isNew: dto.isNew,\r\n isHighlighted: dto.isHighlighted,\r\n domains: dto.domains,\r\n };\r\n}\r\n","import React, { createContext } from \"react\";\r\n\r\nimport useServiceReducer from \"../hooks/useServiceReducer\";\r\nimport { ServiceReducer } from \"../hooks/useServiceReducer\";\r\n\r\nexport const AdminServiceContext = createContext(\r\n (undefined as any) as ServiceReducer\r\n);\r\n\r\nconst AdminServiceContextHOC: React.FC<{}> = ({ children }) => {\r\n const reducer = useServiceReducer();\r\n return (\r\n \r\n {children}\r\n \r\n );\r\n};\r\n\r\nexport default AdminServiceContextHOC;\r\n","import { getAdminCatalogue } from \"api/admin/adminApi\";\r\nimport {\r\n pollCreateService,\r\n pollRemoveService,\r\n pollUpdateDisplayStatus,\r\n pollUpdateIsHighlighted,\r\n pollUpdateIsNew,\r\n pollUpdateService,\r\n} from \"api/catalog/catalogPoller\";\r\nimport { adminGetTenants } from \"api/tenant/tenantApi\";\r\nimport {\r\n Action,\r\n fetchList,\r\n fetchListSuccess,\r\n itemAdded,\r\n itemDeleted,\r\n itemUpdated,\r\n} from \"pages/admin/actions\";\r\nimport adminListReducer, { initialState } from \"pages/admin/actions/reducer\";\r\nimport { State } from \"pages/admin/actions/type\";\r\nimport { Reducer, useCallback, useEffect, useReducer } from \"react\";\r\nimport { useDispatch, useSelector } from \"react-redux\";\r\nimport { upsertTenants } from \"redux/actions/global\";\r\n\r\nimport { ServiceItem, toServiceItem } from \"../type\";\r\nimport {\r\n ServiceForm,\r\n toServiceCreateDTO,\r\n toServiceUpdateDTO,\r\n} from \"../type/form\";\r\n\r\ntype AdminServiceState = State;\r\ntype AdminServiceAction = Action;\r\n\r\nexport interface ServiceReducer extends State {\r\n upsertService: (form: ServiceForm) => Promise;\r\n deleteService: (service: ServiceItem) => Promise;\r\n patchDisplayed: (service: ServiceItem, displayed: boolean) => Promise;\r\n patchIsNew: (service: ServiceItem, isNew: boolean) => Promise;\r\n patchIsHighlighted: (\r\n service: ServiceItem,\r\n isHightlighted: boolean\r\n ) => Promise;\r\n}\r\n\r\nexport default function useServiceReducer(): ServiceReducer {\r\n const tenants = useSelector((state) => (state as any).global.data.tenants);\r\n const reduxDispatch = useDispatch();\r\n\r\n useEffect(() => {\r\n if (tenants === null) {\r\n adminGetTenants().then((data) => reduxDispatch(upsertTenants(data)));\r\n }\r\n }, [tenants, reduxDispatch]);\r\n\r\n const [state, dispatch] = useReducer<\r\n Reducer\r\n >(adminListReducer, {\r\n ...initialState,\r\n } as State);\r\n\r\n const fetchAdminCatalog = useCallback(async (): Promise => {\r\n dispatch(fetchList());\r\n\r\n const dtos = await getAdminCatalogue();\r\n const services = dtos.map(toServiceItem);\r\n dispatch(fetchListSuccess(services));\r\n\r\n return services;\r\n }, []);\r\n\r\n const upsertService = useCallback(\r\n async (service: ServiceForm): Promise => {\r\n let upsertedService;\r\n\r\n if (!service.id) {\r\n const addedDTO = await pollCreateService(toServiceCreateDTO(service));\r\n\r\n upsertedService = toServiceItem({\r\n ...addedDTO,\r\n canAddSubscription: true,\r\n domains: addedDTO.domains ?? [],\r\n });\r\n dispatch(itemAdded(upsertedService));\r\n } else {\r\n const updatedDTO = await pollUpdateService(\r\n toServiceUpdateDTO(service),\r\n service.id\r\n );\r\n\r\n upsertedService = toServiceItem({\r\n ...updatedDTO,\r\n canAddSubscription: true,\r\n domains: updatedDTO.domains ?? [],\r\n });\r\n dispatch(itemUpdated(upsertedService));\r\n }\r\n\r\n return upsertedService;\r\n },\r\n []\r\n );\r\n\r\n const deleteService = useCallback(async (service: ServiceItem) => {\r\n await pollRemoveService(service.id);\r\n dispatch(itemDeleted(service));\r\n }, []);\r\n\r\n const patchDisplayed = useCallback(\r\n async (service: ServiceItem, live: boolean) => {\r\n await pollUpdateDisplayStatus(service.id, live);\r\n dispatch(\r\n itemUpdated({\r\n ...service,\r\n live,\r\n })\r\n );\r\n },\r\n []\r\n );\r\n\r\n const patchIsNew = useCallback(\r\n async (service: ServiceItem, isNew: boolean) => {\r\n await pollUpdateIsNew(service.id, isNew);\r\n dispatch(\r\n itemUpdated({\r\n ...service,\r\n isNew,\r\n })\r\n );\r\n },\r\n []\r\n );\r\n\r\n const patchIsHighlighted = useCallback(\r\n async (service: ServiceItem, isHighlighted: boolean) => {\r\n await pollUpdateIsHighlighted(service.id, isHighlighted);\r\n dispatch(\r\n itemUpdated({\r\n ...service,\r\n isHighlighted,\r\n })\r\n );\r\n },\r\n []\r\n );\r\n\r\n useEffect(() => {\r\n fetchAdminCatalog();\r\n }, [fetchAdminCatalog]);\r\n\r\n return {\r\n ...state,\r\n upsertService,\r\n deleteService,\r\n patchDisplayed,\r\n patchIsNew,\r\n patchIsHighlighted,\r\n };\r\n}\r\n","import { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { AdminServiceContext } from \"pages/admin/components/Service/components/AdminServiceContextHOC\";\r\nimport { useContext } from \"react\";\r\n\r\ninterface Props {\r\n value: string | null;\r\n onValueChange: (value: string) => void;\r\n disabled?: boolean;\r\n hasError?: boolean;\r\n placeholder?: string;\r\n className?: string;\r\n}\r\n\r\nexport default function ServiceSelect({\r\n value,\r\n onValueChange,\r\n ...props\r\n}: Props) {\r\n const { items: services } = useContext(AdminServiceContext);\r\n\r\n return (\r\n \r\n {services\r\n ?.filter((service) => service.canAddSubscription)\r\n .map((service) => (\r\n \r\n {service.name}\r\n \r\n ))}\r\n \r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport { UserReadDTO } from \"api/admin/__generated__/UserManagementAPI\";\r\nimport {\r\n Button,\r\n Input,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n SelectOption,\r\n Switch,\r\n TextArea,\r\n} from \"appkit-react\";\r\nimport ClearableCalendarPicker from \"components/ClearableCalendarPicker\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport Select from \"components/Select\";\r\nimport useSubmitable from \"hooks/useSubmitable\";\r\nimport UserSelect, {\r\n INTERNAL_ONLY_FILTERS,\r\n} from \"pages/admin/components/AddUserToElementModal/UserSelect\";\r\nimport CompanySelect from \"pages/admin/components/CompanySelect\";\r\nimport { useCallback, useContext, useEffect, useMemo, useRef } from \"react\";\r\n\r\nimport { AdminEntityContext } from \"../../Entity\";\r\nimport { ECModules, ECSModules, toECModules, toECSModules } from \"../types\";\r\nimport {\r\n SubscriptionForm,\r\n findFormErrors,\r\n toSubscriptionForm,\r\n} from \"../types/form\";\r\nimport EntitySelect from \"./EntitySelect\";\r\nimport LinksForm from \"./LinksForm\";\r\nimport ServiceSelect from \"./ServiceSelect\";\r\n\r\nconst DEFAULT_FORM: SubscriptionForm = {\r\n id: null,\r\n companyId: null,\r\n entityId: null,\r\n serviceId: null,\r\n endDate: null,\r\n ec: \"\",\r\n ecModules: toECModules(),\r\n hasECLink: false,\r\n ecs: \"\",\r\n ecsModules: toECSModules(),\r\n hasECSLink: false,\r\n clientContent: \"\",\r\n links: [],\r\n contacts: [],\r\n users: [],\r\n};\r\n\r\ninterface Props {\r\n subscription: any;\r\n visible: boolean;\r\n onClose: () => void;\r\n onUpsertSubscription: (form: SubscriptionForm) => Promise;\r\n}\r\n\r\nconst AddEngagementModal = ({\r\n subscription,\r\n visible,\r\n onClose,\r\n onUpsertSubscription,\r\n}: Props) => {\r\n const isEditMode = useMemo(() => !!subscription, [subscription]);\r\n\r\n const findFormErrorsWrapper = useCallback(\r\n (form) => findFormErrors(form, isEditMode),\r\n [isEditMode]\r\n );\r\n\r\n const {\r\n values: form,\r\n handleValueChange,\r\n submitting,\r\n formErrors,\r\n resetForm,\r\n submit,\r\n } = useSubmitable(DEFAULT_FORM, findFormErrorsWrapper);\r\n const clickOutsideRef = useRef(null);\r\n\r\n const { items: entities } = useContext(AdminEntityContext);\r\n\r\n var users = useMemo(() => {\r\n const selectedEntity = entities?.find(\r\n (entity: any) => entity.id === form.entityId\r\n );\r\n return !selectedEntity?.users ? null : selectedEntity.users;\r\n }, [entities, form.entityId]);\r\n\r\n const handleEcsModulesChange = (\r\n property: keyof ECSModules,\r\n checked: boolean\r\n ) => {\r\n handleValueChange(\"ecsModules\", {\r\n ...form.ecsModules,\r\n [property]: checked,\r\n });\r\n };\r\n\r\n const handleEcModulesChange = (\r\n property: keyof ECModules,\r\n checked: boolean\r\n ) => {\r\n handleValueChange(\"ecModules\", {\r\n ...form.ecModules,\r\n [property]: checked,\r\n });\r\n };\r\n\r\n const handleSubmit = () => {\r\n submit((form) => {\r\n return onUpsertSubscription(form).then(() => {\r\n resetForm();\r\n onClose();\r\n });\r\n });\r\n };\r\n\r\n useEffect(() => {\r\n handleValueChange(\"entityId\", null);\r\n }, [form.companyId, handleValueChange]);\r\n\r\n useEffect(() => {\r\n if (visible && subscription) {\r\n resetForm(toSubscriptionForm(subscription));\r\n } else {\r\n resetForm();\r\n }\r\n }, [visible, subscription, resetForm]);\r\n\r\n const selectedMainContacts = useMemo(() => {\r\n if (form.users && users) {\r\n return users.filter((u: any) =>\r\n form.users.some((u2) => u.ppid === u2.ppid)\r\n );\r\n }\r\n }, [form.users, users]);\r\n\r\n return (\r\n \r\n \r\n
\r\n {subscription ? \"Edit subscription\" : \"Create subscription\"}\r\n
\r\n
\r\n \r\n
\r\n
\r\n Subscription information\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"companyId\", companyId)\r\n }\r\n placeholder=\"Company group\"\r\n disabled={!!subscription}\r\n hasError={!!formErrors.companyId}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"entityId\", entityId)\r\n }\r\n placeholder=\"Company\"\r\n disabled={!!subscription}\r\n hasError={!!formErrors.entityId}\r\n className=\"create-subscription-entity-select\"\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"serviceId\", serviceId)\r\n }\r\n placeholder=\"Service\"\r\n disabled={!!subscription}\r\n hasError={!!formErrors.serviceId}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"endDate\", newDate)\r\n }\r\n onClearValue={() => handleValueChange(\"endDate\", null)}\r\n hasError={!!formErrors.endDate}\r\n errMsg={formErrors.endDate as any}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"contacts\", value)\r\n }\r\n placeholder=\"At least one PWC contact is required\"\r\n hasError={!!formErrors.contacts}\r\n errMsg={formErrors.contacts}\r\n multiple\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n {!!users && (\r\n \r\n handleValueChange(\"users\", value)\r\n }\r\n placeholder=\"At least one contact is required\"\r\n >\r\n {users?.map((user: UserReadDTO) => (\r\n \r\n {user.email}\r\n \r\n ))}\r\n \r\n )}\r\n
\r\n
\r\n
\r\n\r\n
\r\n Engagement Center\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"hasECLink\", value)\r\n }\r\n onText=\"Yes\"\r\n offText=\"No\"\r\n />\r\n
\r\n\r\n
\r\n handleValueChange(\"ec\", value)}\r\n hasError={!!formErrors.ec}\r\n errMsg={formErrors.ec}\r\n />\r\n
\r\n
\r\n\r\n {form.hasECLink && (\r\n
\r\n
\r\n
Your engagement has:
\r\n
\r\n
\r\n \r\n handleEcModulesChange(\"deliverables\", value)\r\n }\r\n onText=\"Yes\"\r\n offText=\"No\"\r\n disabled={submitting || !form.hasECLink}\r\n />\r\n
\r\n
\r\n \r\n handleEcModulesChange(\"documents\", value)\r\n }\r\n onText=\"Yes\"\r\n offText=\"No\"\r\n disabled={submitting || !form.hasECLink}\r\n />\r\n
\r\n
\r\n )}\r\n
\r\n\r\n
\r\n eCS\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"hasECSLink\", value)\r\n }\r\n onText=\"Yes\"\r\n offText=\"No\"\r\n />\r\n
\r\n
\r\n handleValueChange(\"ecs\", value)}\r\n hasError={!!formErrors.ecs}\r\n errMsg={formErrors.ecs}\r\n />\r\n
\r\n
\r\n\r\n {form.hasECSLink && (\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleEcsModulesChange(\"documents\", value)\r\n }\r\n onText=\"Yes\"\r\n offText=\"No\"\r\n disabled={submitting || !form.hasECSLink}\r\n />\r\n
\r\n
\r\n \r\n handleEcsModulesChange(\"links\", value)\r\n }\r\n onText=\"Yes\"\r\n offText=\"No\"\r\n disabled={submitting || !form.hasECSLink}\r\n />\r\n
\r\n
\r\n \r\n handleEcsModulesChange(\"tasks\", value)\r\n }\r\n onText=\"Yes\"\r\n offText=\"No\"\r\n disabled={submitting || !form.hasECSLink}\r\n />\r\n
\r\n
\r\n )}\r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"clientContent\", value)\r\n }\r\n placeholder=\"Description\"\r\n rows=\"4\"\r\n />\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n handleValueChange(\"links\", links)}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default AddEngagementModal;\r\n","import \"./index.scss\";\r\n\r\nimport { SubscriptionDetailsReadDTO } from \"api/admin/__generated__/UserManagementAPI\";\r\nimport {\r\n NotificationFrequency,\r\n NotificationSettingsReadDTO,\r\n} from \"api/notification/__generated__/NotificationAPI\";\r\nimport { FRENQUENCIES_LABEL } from \"api/notification/model\";\r\nimport { getNotificationsByPpids } from \"api/notification/notificationAPI\";\r\nimport { ModalBody, ModalHeader } from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport Table from \"components/Table\";\r\nimport useNotificationTypes from \"pages/userProfile/hooks/useNotificationTypes\";\r\nimport { useEffect, useMemo, useState } from \"react\";\r\n\r\ninterface Props {\r\n subscription: SubscriptionDetailsReadDTO | null;\r\n onClose: () => void;\r\n}\r\n\r\ninterface UserNotification {\r\n ppid: string;\r\n name: string;\r\n notification: {\r\n types: string[];\r\n frequencies: NotificationFrequency[];\r\n };\r\n}\r\n\r\ninterface CellProps {\r\n value: T;\r\n}\r\n\r\nconst DEFAULT_SORT = [{ id: \"name\", desc: false }];\r\n\r\nconst COLUMNS = [\r\n {\r\n Header: \"Member\",\r\n id: \"name\",\r\n accessor: \"name\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Notifications\",\r\n accessor: \"notification.types\",\r\n Cell: ({ value }: CellProps) => value.sort().join(\", \"),\r\n },\r\n {\r\n Header: \"Frequency\",\r\n accessor: \"notification.frequencies\",\r\n Cell: ({ value }: CellProps) =>\r\n value\r\n .sort()\r\n .map((id) => FRENQUENCIES_LABEL[id])\r\n .join(\", \"),\r\n },\r\n];\r\n\r\nexport default function SubscriptionDetails({ subscription, onClose }: Props) {\r\n const [notifications, setNotifications] = useState<\r\n NotificationSettingsReadDTO[] | null\r\n >(null);\r\n const notificationTypes = useNotificationTypes();\r\n\r\n useEffect(() => {\r\n if (!subscription?.users) {\r\n setNotifications(null);\r\n return;\r\n }\r\n\r\n const usersByPpid = subscription.users.reduce((acc, user) => {\r\n // @ts-ignore\r\n acc[user.ppid!] = user;\r\n return acc;\r\n }, {});\r\n\r\n getNotificationsByPpids(Object.keys(usersByPpid)).then(setNotifications);\r\n }, [subscription]);\r\n\r\n const userNotifications: UserNotification[] | null = useMemo(() => {\r\n if (!(notifications && notificationTypes && subscription?.users)) {\r\n return null;\r\n }\r\n\r\n const notificationsByPpid = notifications.reduce((acc, notification) => {\r\n //@ts-ignore\r\n acc[notification.userPpid] = notification;\r\n return acc;\r\n }, {} as Record);\r\n\r\n return subscription.users.map((user) => {\r\n const notification =\r\n notificationsByPpid[user.ppid as keyof typeof notificationsByPpid];\r\n return {\r\n ppid: user.ppid!,\r\n name: user.name!,\r\n notification: {\r\n frequencies: notification?.frequencies! || [],\r\n types:\r\n notification?.types?.map((type) => notificationTypes[type]!) || [],\r\n },\r\n };\r\n });\r\n }, [subscription?.users, notifications, notificationTypes]);\r\n\r\n return (\r\n \r\n Subscription Details\r\n \r\n \r\n \r\n \r\n );\r\n}\r\n","export const USERS_CONTEXTS = {\r\n ALL: \"ALL\",\r\n SUPERADMIN: \"SUPERADMIN\",\r\n PWC: \"PWC\",\r\n LUXEMBOURG_STAFF: \"LU\",\r\n CLIENT: \"CLIENT\",\r\n};\r\n","import { PopBanner } from \"appkit-react\";\r\n\r\nimport { USERS_CONTEXTS } from \"../constants\";\r\n\r\nconst FILTER_CONTEXT_RULES = {\r\n [USERS_CONTEXTS.ALL]: () => true,\r\n [USERS_CONTEXTS.SUPERADMIN]: (user) => !!user.isSuperUser,\r\n [USERS_CONTEXTS.PWC]: (user) => !!user.isInternal,\r\n [USERS_CONTEXTS.CLIENT]: (user) => !user.isInternal,\r\n};\r\n\r\nexport const NO_USER_ROW = {\r\n ppid: -1,\r\n name: \"No user\",\r\n lastName: \"\",\r\n firstName: \"\",\r\n isInternal: null,\r\n role: \"\",\r\n highestLevel: \"\",\r\n};\r\n\r\nexport const filterContext = (users, context) => {\r\n const res =\r\n context === null ? users : users.filter(FILTER_CONTEXT_RULES[context]);\r\n\r\n if (res.length === 0) {\r\n res.push({ ...NO_USER_ROW });\r\n }\r\n\r\n return res;\r\n};\r\n\r\nexport const filterPriorities = (users, highestLevel) => {\r\n let counts = {};\r\n let newUsers = [...users];\r\n newUsers.forEach((user) => {\r\n counts[user.ppid] = (counts[user.ppid] || 0) + 1;\r\n });\r\n for (let ppid in counts) {\r\n if (counts[ppid] > 1) {\r\n newUsers = newUsers.filter((user) => {\r\n return (\r\n user.ppid !== ppid ||\r\n (user.ppid === ppid && user.highestLevel === highestLevel)\r\n );\r\n });\r\n }\r\n }\r\n return newUsers;\r\n};\r\n\r\nexport const getPwcClientCellString = (value) => {\r\n if (typeof value === \"boolean\") {\r\n return value ? \"PwC\" : \"Client\";\r\n } else {\r\n return \"\";\r\n }\r\n};\r\n\r\nexport const createSuccessBanner = () => {\r\n PopBanner({\r\n content:\r\n \"Your action has been taken into account and will be treated in a few moments.\",\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n};\r\n","import { Switch } from \"appkit-react\";\r\nimport Table from \"components/Table\";\r\nimport Actions from \"components/Table/actions\";\r\nimport { NO_USER_ROW } from \"pages/admin/utils\";\r\nimport { useMemo } from \"react\";\r\n\r\ninterface User {\r\n ppid: number | string;\r\n name: string;\r\n email: string;\r\n isMainContact: boolean;\r\n}\r\n\r\ninterface Props {\r\n data: User[];\r\n parentId: string;\r\n onDeleteUser:\r\n | (({\r\n ppid,\r\n parentId,\r\n }: {\r\n ppid: number | string;\r\n parentId: string;\r\n }) => void)\r\n | null;\r\n onMainContactChanged: (\r\n subscriptionId: string,\r\n userPpid: string,\r\n isMainContact: boolean\r\n ) => void;\r\n}\r\n\r\nexport const COLUMNS = [\r\n {\r\n Cell: () => null,\r\n width: 35,\r\n },\r\n {\r\n Header: \"Member\",\r\n id: \"name\",\r\n accessor: \"name\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Email\",\r\n id: \"email\",\r\n accessor: \"email\",\r\n filterable: true,\r\n Filter: () => null,\r\n Cell: ({ original }: { original: User }) => formatUserEmail(original),\r\n },\r\n {\r\n Header: \"\",\r\n Cell: () => null,\r\n },\r\n];\r\n\r\nconst DEFAULT_SORT = [{ id: \"name\", desc: false }];\r\n\r\nconst UserEngagementTable = ({\r\n data,\r\n parentId,\r\n onDeleteUser,\r\n onMainContactChanged,\r\n}: Props) => {\r\n const columns = useMemo(() => {\r\n return [\r\n ...COLUMNS,\r\n ...(data?.length && onMainContactChanged\r\n ? [\r\n {\r\n Header: \"Is main contact ?\",\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n width: 120,\r\n Cell: ({ original }: { original: User }) => {\r\n return (\r\n {\r\n onMainContactChanged(\r\n parentId,\r\n original.ppid.toString(),\r\n value\r\n );\r\n }}\r\n />\r\n );\r\n },\r\n },\r\n ]\r\n : []),\r\n {\r\n Header: \"\",\r\n Cell: ({ original }: { original: User }) => (\r\n \r\n onDeleteUser({\r\n ppid: original.ppid,\r\n parentId,\r\n })\r\n : null\r\n }\r\n />\r\n ),\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n width: 80,\r\n },\r\n ];\r\n }, [parentId, onDeleteUser, onMainContactChanged, data]);\r\n\r\n const displayedData = useMemo(() => {\r\n return data && data.length > 0 ? data : [{ ...NO_USER_ROW }];\r\n }, [data]);\r\n\r\n return (\r\n ({\r\n className: \"-padRow\",\r\n })}\r\n />\r\n );\r\n};\r\n\r\nexport default UserEngagementTable;\r\n\r\nfunction formatUserEmail(user: User) {\r\n if (user.email) return user.email;\r\n if (String(user.ppid).includes(\"@\")) return String(user.ppid).toLowerCase();\r\n return \"-\";\r\n}\r\n","import \"./MenuList.scss\";\r\n\r\nimport { ListItem } from \"appkit-react\";\r\nimport MenuList from \"components/MenuList\";\r\nimport is3wService from \"pages/admin/utils/is3wService\";\r\nimport { SyntheticEvent } from \"react\";\r\n\r\ninterface Props {\r\n subscription: any;\r\n onAddUser: (subscription: any) => void;\r\n onEditSubscription: (subscription: any) => void;\r\n onDeleteSubscription: (subscription: any) => void;\r\n onNewsAccessRight: (subscription: any) => void;\r\n onDisplayDetails: (subscription: any) => void;\r\n}\r\n\r\nexport default function EditList({\r\n subscription,\r\n onAddUser,\r\n onEditSubscription,\r\n onDeleteSubscription,\r\n onNewsAccessRight,\r\n onDisplayDetails,\r\n}: Props) {\r\n return (\r\n {\r\n e.stopPropagation();\r\n }}\r\n >\r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onDisplayDetails(subscription);\r\n }}\r\n >\r\n \r\n Show details\r\n \r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onAddUser(subscription);\r\n }}\r\n >\r\n \r\n Add user to subscription\r\n \r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onEditSubscription(subscription);\r\n }}\r\n >\r\n \r\n Edit\r\n \r\n {is3wService(subscription.serviceId) && (\r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onNewsAccessRight(subscription);\r\n }}\r\n >\r\n \r\n Manage news access rights\r\n \r\n )}\r\n\r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onDeleteSubscription(subscription);\r\n }}\r\n >\r\n \r\n Delete\r\n \r\n \r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport classNames from \"classnames\";\r\nimport Table from \"components/Table\";\r\nimport React, { useContext, useMemo, useState } from \"react\";\r\nimport { atMidnight, formatDate } from \"utils/date\";\r\n\r\nimport UserEngagementTable from \"../../UserTable\";\r\nimport { DEFAULT_SORT } from \"../hooks/useSubscriptions\";\r\nimport EditList from \"./MenuList\";\r\nimport { AdminEngagementContext } from \"..\";\r\n\r\nconst TABLE_COLUMNS = [\r\n {\r\n Header: \"Service Name\",\r\n id: \"service\",\r\n accessor: \"serviceName\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Company group name\",\r\n id: \"company\",\r\n accessor: \"companyName\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Company name\",\r\n id: \"entity\",\r\n accessor: \"entityName\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n\r\n {\r\n Header: \"# users\",\r\n id: \"users\",\r\n accessor: \"users\",\r\n filterable: false,\r\n sortable: false,\r\n Filter: () => null,\r\n Cell: ({ value }: { value: any[] }) => value.length,\r\n width: 90,\r\n },\r\n];\r\n\r\nexport const COLUMNS = [\r\n ...TABLE_COLUMNS,\r\n {\r\n Header: \"Member\",\r\n id: \"name\",\r\n accessor: \"name\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n];\r\n\r\ninterface Props {\r\n onEditSubscription: (subscription: any) => void;\r\n onNewsAccessRight: (subscription: any) => void;\r\n onDeleteSubscription: (subscription: any) => void;\r\n onAddUser: (subscription: any) => void;\r\n onDeleteUser: (subscription: any) => void;\r\n onDisplayDetails: (subscription: any) => void;\r\n onMainContactChanged: (\r\n subscriptionId: string,\r\n userPpid: string,\r\n isMainContact: boolean\r\n ) => void;\r\n}\r\n\r\nexport default function SubscriptionTable({\r\n onEditSubscription,\r\n onNewsAccessRight,\r\n onDeleteSubscription,\r\n onAddUser,\r\n onDeleteUser,\r\n onDisplayDetails,\r\n onMainContactChanged,\r\n}: Props) {\r\n const { data } = useContext(AdminEngagementContext);\r\n\r\n const {\r\n loading,\r\n items: subscriptions,\r\n fetchData,\r\n optimisticChange,\r\n ...tableReducer\r\n } = data;\r\n\r\n const [expanded, setExpanded] = useState([]);\r\n\r\n const columns = useMemo(() => {\r\n let cols = [\r\n ...TABLE_COLUMNS,\r\n {\r\n Header: \"End date\",\r\n sortable: false,\r\n accessor: \"endDate\",\r\n width: 100,\r\n Cell: ({ value }: { value: string }) => {\r\n return value ? (\r\n \r\n {formatDate(value)}\r\n \r\n ) : null;\r\n },\r\n },\r\n {\r\n className: \"overflow-td\",\r\n Header: \"Actions\",\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n width: 80,\r\n Cell: ({ original }: any) => {\r\n return (\r\n \r\n );\r\n },\r\n },\r\n ];\r\n\r\n return cols;\r\n }, [\r\n onAddUser,\r\n onDeleteSubscription,\r\n onEditSubscription,\r\n onNewsAccessRight,\r\n onDisplayDetails,\r\n ]);\r\n\r\n return (\r\n {\r\n return (\r\n \r\n );\r\n }}\r\n {...tableReducer}\r\n />\r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport { Button, ModalBody, ModalFooter, ModalHeader } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport useSubmitable from \"hooks/useSubmitable\";\r\nimport { useCallback, useEffect, useRef } from \"react\";\r\n\r\nconst findErrors = (form) => {\r\n return {\r\n users: !form.users?.length,\r\n };\r\n};\r\n\r\nconst DEFAULT_FORM = {\r\n users: [],\r\n};\r\n\r\nconst AddUserToElementModal = ({\r\n visible,\r\n className = \"\",\r\n onCancel,\r\n onSubmit,\r\n Render,\r\n}) => {\r\n const submitable = useSubmitable(DEFAULT_FORM, findErrors);\r\n const {\r\n values,\r\n handleValueChange,\r\n resetForm,\r\n submit,\r\n submitting,\r\n formErrors,\r\n } = submitable;\r\n\r\n const handleUserChange = useCallback(\r\n (value) => handleValueChange(\"users\", value),\r\n [handleValueChange]\r\n );\r\n useEffect(() => {\r\n if (visible === false) {\r\n resetForm();\r\n }\r\n }, [visible, resetForm]);\r\n\r\n const handleCancel = () => {\r\n resetForm();\r\n onCancel();\r\n };\r\n\r\n const modalContainerRef = useRef();\r\n\r\n const handleSubmit = () =>\r\n submit((form) =>\r\n onSubmit({\r\n users: form.users,\r\n })\r\n );\r\n\r\n return (\r\n {\r\n modalContainerRef.current = _ref?.node;\r\n }}\r\n >\r\n \r\n
Please select user(s) to add
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default AddUserToElementModal;\r\n","import { PopBanner, SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { useContext, useMemo } from \"react\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\nimport AddUserModal from \"../../AddUserToElementModal/Modal\";\r\nimport { AdminEntityContext } from \"../../Entity\";\r\nimport { AdminEngagementContext } from \"..\";\r\n\r\nconst UserSelect = ({ entityId, subscription, ...props }) => {\r\n const { items: entities } = useContext(AdminEntityContext);\r\n const users = useMemo(() => {\r\n if (!(entityId && subscription)) {\r\n return null;\r\n }\r\n\r\n const selectedEntity = entities.find((entity) => entity.id === entityId);\r\n if (!selectedEntity?.users) {\r\n return null;\r\n }\r\n\r\n const subscriptionPpid = subscription.users.reduce((acc, user) => {\r\n acc[user.ppid] = user;\r\n return acc;\r\n }, {});\r\n\r\n return selectedEntity.users\r\n .filter((user) => !subscriptionPpid[user.ppid])\r\n .sort(localeCompare(\"name\"));\r\n }, [entities, entityId, subscription]);\r\n\r\n return (\r\n \r\n );\r\n};\r\nconst AddUserToEngagementModal = ({ subscription, onClose, ...modalProps }) => {\r\n const { addUserToSubscription } = useContext(AdminEngagementContext);\r\n\r\n const submitAddUser = (form) => {\r\n const users = form.users;\r\n\r\n return addUserToSubscription(\r\n subscription.id,\r\n users.map((user) => user.ppid)\r\n ).then(() => {\r\n PopBanner({\r\n content:\r\n users.length > 1\r\n ? `The users have been successfully added to the engagement.`\r\n : `The user has been successfully added to the engagement.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n\r\n onClose();\r\n });\r\n };\r\n\r\n return (\r\n (\r\n \r\n )}\r\n {...modalProps}\r\n />\r\n );\r\n};\r\n\r\nexport default AddUserToEngagementModal;\r\n","import { PopBanner } from \"appkit-react\";\r\nimport DeleteModal from \"components/DeleteModal\";\r\nimport { useContext } from \"react\";\r\n\r\nimport { AdminEngagementContext } from \"..\";\r\n\r\nconst DeleteEngagementModal = ({ engagement, onClose, ...modalProps }) => {\r\n const { deleteSubscription } = useContext(AdminEngagementContext);\r\n const submitDeleteEngagement = async () => {\r\n await deleteSubscription(engagement.id);\r\n\r\n PopBanner({\r\n content: \"The subscription has been successfully deleted.\",\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n\r\n onClose();\r\n };\r\n\r\n return (\r\n \r\n

\r\n You're about to remove the subscription {engagement?.name} along with\r\n all of its associated information, including users. \r\n This action cannot be undone.\r\n

\r\n \r\n );\r\n};\r\n\r\nexport default DeleteEngagementModal;\r\n","import DeleteModal from \"components/DeleteModal\";\r\n\r\nconst DeleteUserFromElementModal = ({\r\n visible,\r\n onCancel,\r\n userName,\r\n elementType,\r\n elementName,\r\n secondMessage = null,\r\n onSubmit,\r\n}) => {\r\n return (\r\n \r\n

\r\n You're about to remove the user {userName} from the {elementType} \r\n {elementName}. This action cannot be undone.\r\n

\r\n {secondMessage &&

{secondMessage}

}\r\n (This will not delete the user from Managed Services Hub)\r\n \r\n );\r\n};\r\n\r\nexport default DeleteUserFromElementModal;\r\n","import { PopBanner } from \"appkit-react\";\r\nimport { useContext } from \"react\";\r\n\r\nimport DeleteUserFromElementModal from \"../../RemoveUserFromElementModal\";\r\nimport { AdminEngagementContext } from \"..\";\r\n\r\nconst DeleteUserFromEngagementModal = ({ user, onClose, ...modalProps }) => {\r\n const { removeUserFromSubscription } = useContext(AdminEngagementContext);\r\n const submitDeleteUser = () => {\r\n return removeUserFromSubscription(user.parentId, user.ppid).then(() => {\r\n PopBanner({\r\n content: `The user ${user.name} has been successfully deleted from the subcription.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n\r\n onClose();\r\n });\r\n };\r\n\r\n return (\r\n \r\n );\r\n};\r\n\r\nexport default DeleteUserFromEngagementModal;\r\n","import {\r\n SubscriptionDetailsReadDTO,\r\n SubscriptionReadDTO,\r\n} from \"api/admin/__generated__/UserManagementAPI\";\r\nimport FloatingActionButtonPortal from \"components/FloatingActionButton\";\r\nimport React, { useContext, useState } from \"react\";\r\n\r\nimport ThreeWPermissionsModal from \"../../ThreeWPermissionsModal\";\r\nimport AddEngagementModal from \"../AddEngagementModal\";\r\nimport SubscriptionDetails from \"../SubscriptionDetails\";\r\nimport SubscriptionTable from \"../SubscriptionTable\";\r\nimport AddUserToEngagementModal from \"./addUserToEngagementModal\";\r\nimport DeleteEngagementModal from \"./deleteEngagementModal\";\r\nimport DeleteUserFromEngagementModal from \"./deleteUserFromEngagementModal\";\r\nimport { AdminEngagementContext } from \"..\";\r\n\r\nconst AdminEngagements = () => {\r\n const { upsertSubscription, updateUserSubscription } = useContext(\r\n AdminEngagementContext\r\n );\r\n const [addUser, setAddUser] = useState(null);\r\n const [userToDelete, setUserToDelete] = useState(null);\r\n\r\n const [subscriptionDetails, setSubscriptionDetails] =\r\n useState(null);\r\n const [engagementToDelete, setEngagementToDelete] =\r\n useState(null);\r\n const [threeWPermissionsEngagement, setThreeWPermissionsEngagement] =\r\n useState(null);\r\n\r\n const [showCreateEngagementModal, setShowCreateEngagementModal] =\r\n useState(false);\r\n const [editedEngagement, setEditedEngagement] = useState(null);\r\n\r\n const handleEditEngagement = (engagement: any) => {\r\n setEditedEngagement(engagement);\r\n setShowCreateEngagementModal(true);\r\n };\r\n\r\n const handleMainContactChanged = (\r\n subscriptionId: string,\r\n userPpid: string,\r\n isMainContact: boolean\r\n ) => {\r\n updateUserSubscription(subscriptionId, userPpid, isMainContact);\r\n };\r\n\r\n return (\r\n <>\r\n setThreeWPermissionsEngagement(null)}\r\n />\r\n\r\n setEngagementToDelete(null)}\r\n />\r\n\r\n {\r\n setEditedEngagement(null);\r\n setShowCreateEngagementModal(false);\r\n }}\r\n />\r\n\r\n setSubscriptionDetails(null)}\r\n subscription={subscriptionDetails}\r\n />\r\n setAddUser(null)}\r\n />\r\n setUserToDelete(null)}\r\n />\r\n\r\n \r\n\r\n {\r\n setEditedEngagement(null);\r\n setShowCreateEngagementModal(true);\r\n }}\r\n tooltip=\"Create a new subscription\"\r\n />\r\n \r\n );\r\n};\r\n\r\nexport default AdminEngagements;\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n downloadSubscriptionImportTemplate,\r\n importSubscriptionFromExcel,\r\n} from \"api/admin/adminApi\";\r\nimport EngagementsTable from \"pages/admin/components/Engagement/EngagementsTable\";\r\nimport UploadImport from \"pages/newsAdmin/components/UploadImport\";\r\n\r\nexport default function SubscriptionAdmin() {\r\n\r\n return (\r\n
\r\n \r\n \r\n
\r\n );\r\n}\r\n","import { useEffect } from \"react\";\r\n\r\nexport const ADMIN_TABLE_OFFSET = 234;\r\nexport const DELIVERABLES_TABLE_OFFSET = 263;\r\n\r\nconst useStickyHeader = (\r\n scrollableElementRef,\r\n stickyElementRef,\r\n offset = 0\r\n) => {\r\n useEffect(() => {\r\n if (!scrollableElementRef || !stickyElementRef) {\r\n return;\r\n }\r\n const onScrollEvent = (event) => {\r\n stickyElementRef.style.transform = `translateY(${Math.max(\r\n 0,\r\n event.target.scrollTop - offset\r\n )}px)`;\r\n };\r\n scrollableElementRef.addEventListener(\"scroll\", onScrollEvent);\r\n return () => {\r\n scrollableElementRef.removeEventListener(\"scroll\", onScrollEvent);\r\n };\r\n }, [scrollableElementRef, stickyElementRef, offset]);\r\n};\r\n\r\nexport default useStickyHeader;\r\n","import useStickyHeader, {\r\n ADMIN_TABLE_OFFSET,\r\n} from \"components/Table/hooks/useStickyHeader\";\r\nimport { useContext, useEffect, useState } from \"react\";\r\nimport ReactDOM from \"react-dom\";\r\n\r\nimport { ScrollContext } from \"../../../App\";\r\n\r\nconst useMainTableStickyHeader = (\r\n loading,\r\n tableRef,\r\n offset = ADMIN_TABLE_OFFSET\r\n) => {\r\n const scrollRef = useContext(ScrollContext);\r\n const [theadRef, setTheadRef] = useState(null);\r\n useEffect(() => {\r\n if (tableRef.current) {\r\n setTheadRef(\r\n ReactDOM.findDOMNode(tableRef.current).querySelector(\r\n \".rt-thead.-header\"\r\n )\r\n );\r\n }\r\n }, [loading, tableRef]);\r\n useStickyHeader(scrollRef?.current, theadRef, offset);\r\n};\r\n\r\nexport default useMainTableStickyHeader;\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n Button,\r\n Input,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n Switch,\r\n} from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport UserSelect, {\r\n INTERNAL_ONLY_FILTERS,\r\n} from \"pages/admin/components/AddUserToElementModal/UserSelect\";\r\nimport CompanySelect from \"pages/admin/components/CompanySelect\";\r\nimport { useContext, useEffect, useRef } from \"react\";\r\n\r\nimport useSubmitable from \"../../../../../hooks/useSubmitable\";\r\nimport { AdminEntityContext } from \"..\";\r\n\r\nconst DEFAULT_FORM = {\r\n companyId: null,\r\n entityId: null,\r\n name: \"\",\r\n prid: \"\",\r\n viewInMyServices: false,\r\n contacts: [],\r\n};\r\n\r\nconst findFormErrors = (form) => {\r\n return {\r\n name: form.name.trim().length === 0,\r\n companyId: form.companyId === null || form.companyId === undefined,\r\n };\r\n};\r\n\r\nconst AddEntityModal = ({ entity, visible, onClose }) => {\r\n const { addEntity, updateEntity } = useContext(AdminEntityContext);\r\n const {\r\n values: form,\r\n handleValueChange,\r\n submitting,\r\n formErrors,\r\n resetForm,\r\n submit,\r\n } = useSubmitable(DEFAULT_FORM, findFormErrors);\r\n const clickOutsideRef = useRef();\r\n\r\n useEffect(() => {\r\n resetForm(\r\n entity\r\n ? {\r\n name: entity.name,\r\n companyId: entity.companyId,\r\n entityId: entity.id,\r\n prid: entity.prid,\r\n contacts: entity.contacts,\r\n viewInMyServices: entity.viewInMyServices,\r\n }\r\n : DEFAULT_FORM\r\n );\r\n }, [entity, resetForm]);\r\n\r\n const handleSubmit = () => {\r\n submit((form) => {\r\n const promise = !entity ? addEntity : updateEntity;\r\n form = {\r\n ...form,\r\n contacts: form.contacts.map((contact) => contact.ppid ?? contact),\r\n };\r\n return promise(form).then(onClose);\r\n });\r\n };\r\n\r\n useEffect(() => {\r\n if (!visible) {\r\n resetForm();\r\n }\r\n }, [visible, resetForm]);\r\n\r\n return (\r\n \r\n \r\n
\r\n {entity ? \"Edit company\" : \"Create company\"}\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"companyId\", value)}\r\n placeholder=\"Company group\"\r\n hasError={!!formErrors.companyId}\r\n />\r\n
\r\n
\r\n \r\n handleValueChange(\"name\", value)}\r\n placeholder=\"Company name\"\r\n hasError={!!formErrors.name}\r\n />\r\n
\r\n
\r\n \r\n handleValueChange(\"prid\", value)}\r\n placeholder=\"PRID\"\r\n />\r\n
\r\n
\r\n \r\n handleValueChange(\"contacts\", value)}\r\n placeholder=\"PwC Contacts\"\r\n hasError={!!formErrors.contacts}\r\n errMsg={formErrors.contacts}\r\n multiple\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n
\r\n \r\n handleValueChange(\"viewInMyServices\", value)}\r\n />\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default AddEntityModal;\r\n","import { EntityReadDTO } from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { PopBanner } from \"appkit-react\";\r\nimport DeleteModal from \"components/DeleteModal\";\r\nimport { useContext } from \"react\";\r\n\r\nimport { AdminEntityContext } from \"..\";\r\n\r\ninterface Props {\r\n entity: EntityReadDTO | null;\r\n onClose: () => void;\r\n}\r\nexport default function DeleteSerciceModal({\r\n entity,\r\n onClose,\r\n ...modalProps\r\n}: Props) {\r\n const { deleteEntity } = useContext(AdminEntityContext);\r\n\r\n const submitDeleteEngagement = async () => {\r\n if (!entity) return;\r\n\r\n await deleteEntity(entity);\r\n\r\n PopBanner({\r\n content: `The entity ${entity.name} has been successfully deleted.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n\r\n onClose();\r\n };\r\n\r\n return (\r\n \r\n

\r\n You're about to remove the entity {entity?.name} \r\n This action cannot be undone.\r\n

\r\n \r\n );\r\n}\r\n","import \"./addMultipleUsersToEntityModal.scss\";\r\n\r\nimport { Tooltip } from \"@mui/material\";\r\nimport { pollAddUserToEntity, pollCreateUser } from \"api/admin/adminPoller\";\r\nimport {\r\n Button,\r\n Checkbox,\r\n Input,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n PopBanner,\r\n Radio,\r\n RadioGroup,\r\n} from \"appkit-react\";\r\nimport PhoneInput from \"components/PhoneInput\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport { useMemo, useState } from \"react\";\r\n\r\nconst _defaultUser = {\r\n email: \"\",\r\n photo: \"\",\r\n firstName: \"\",\r\n lastName: \"\",\r\n phone: {\r\n code: null,\r\n number: \"\",\r\n },\r\n grade: \"\",\r\n isSuperUser: false,\r\n entities: [],\r\n send3WEmail: false,\r\n sendAmdsEmail: false,\r\n creationIdentity: \"2\",\r\n};\r\n\r\nconst AddMultipleUsersToEntityModal = ({ entity, onClose: _onClose }) => {\r\n const defaultUser = useMemo(() => {\r\n return { ..._defaultUser, entities: [entity?.id] };\r\n }, [entity]);\r\n const [summaryStatus, setSummaryStatus] = useState(null);\r\n const [usersToAdd, _setUsersToAdd] = useState([]);\r\n const [userToAdd, _setUserToAdd] = useState({ ...defaultUser });\r\n const [submitting, setSubmitting] = useState(false);\r\n\r\n const addUser = () => {\r\n _setUsersToAdd((usersToAdd) => [\r\n ...usersToAdd,\r\n {\r\n ...userToAdd,\r\n phoneCountryCode: userToAdd.code,\r\n phoneNumber: userToAdd.number,\r\n },\r\n ]);\r\n _setUserToAdd(_defaultUser);\r\n };\r\n\r\n const removeUser = (index) => {\r\n const newUsersToAdd = [...usersToAdd];\r\n newUsersToAdd.splice(index, 1);\r\n _setUsersToAdd(newUsersToAdd);\r\n };\r\n\r\n const setUserValue = (key, value) => {\r\n const newUser = { ...userToAdd };\r\n newUser[key] = value;\r\n _setUserToAdd(newUser);\r\n };\r\n const handleSubmit = () => {\r\n setSubmitting(true);\r\n const promises = usersToAdd.map(async (userToAdd) => {\r\n try {\r\n const user = await pollCreateUser(userToAdd);\r\n return await pollAddUserToEntity(entity.id, [user.ppid]);\r\n } catch (error) {\r\n const errorData = await error.json();\r\n throw errorData;\r\n }\r\n });\r\n Promise.allSettled(promises)\r\n .then((results) => {\r\n const status = results.map((result) =>\r\n result.status === \"fulfilled\" ? true : result.reason\r\n );\r\n setSummaryStatus(status);\r\n const failures = status.reduce((acc, res) => {\r\n if (res !== true) {\r\n return acc + 1;\r\n }\r\n return acc;\r\n }, 0);\r\n if (failures === 0) {\r\n PopBanner({\r\n content: All users successfully added,\r\n closeable: true,\r\n status: \"success\",\r\n });\r\n } else if (failures < promises.length) {\r\n PopBanner({\r\n content: (\r\n \r\n Failed to add {failures} users. Please check the summary below\r\n for details\r\n \r\n ),\r\n closeable: true,\r\n status: \"warning\",\r\n });\r\n } else {\r\n PopBanner({\r\n content: (\r\n \r\n No users were added. Please check the summary below for details\r\n \r\n ),\r\n closeable: true,\r\n status: \"negative\",\r\n });\r\n }\r\n })\r\n .finally(() => {\r\n setSubmitting(false);\r\n });\r\n };\r\n\r\n const onClose = () => {\r\n setSummaryStatus(null);\r\n _setUsersToAdd([]);\r\n _setUserToAdd(defaultUser);\r\n if (!submitting) {\r\n _onClose();\r\n }\r\n };\r\n\r\n const getErrorMessage = (index) => {\r\n const DEFAULT_MESSAGE = \"Failed to add this user\";\r\n try {\r\n return summaryStatus[index][0].errorMessage ?? DEFAULT_MESSAGE;\r\n } catch (e) {\r\n return DEFAULT_MESSAGE;\r\n }\r\n };\r\n\r\n return (\r\n \r\n \r\n
Add multiple users to company
\r\n
\r\n \r\n Users to add to the company \"{entity?.name}\"\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {usersToAdd.length === 0 ? (\r\n \r\n \r\n \r\n ) : (\r\n <>\r\n {usersToAdd.map((user, index) => (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n ))}\r\n \r\n )}\r\n \r\n
NameE-MailPhoneTypeNotifications
\r\n No users added yet\r\n
\r\n {summaryStatus !== null && (\r\n \r\n {summaryStatus[index] === true ? (\r\n \r\n ) : (\r\n \r\n
\r\n \r\n
\r\n \r\n )}\r\n
\r\n )}\r\n
\r\n {user.firstName} {user.lastName}\r\n {user.email}\r\n +{user.phone.code} {user.phone.number}\r\n \r\n {user.creationIdentity === \"1\" ? \"Global\" : \"Luxembourg\"}\r\n \r\n
    \r\n {user.send3WEmail &&
  • Send 3W E-Mail
  • }\r\n {user.sendAmdsEmail &&
  • Send AMDS welcome email
  • }\r\n {!user.send3WEmail && !user.sendAmdsEmail && (\r\n
  • \r\n No notifications\r\n
  • \r\n )}\r\n
\r\n
\r\n {summaryStatus === null && !submitting && (\r\n
\r\n removeUser(index)}\r\n className=\"appkiticon icon-circle-delete-outline\"\r\n />\r\n
\r\n )}\r\n
\r\n {!submitting && summaryStatus === null && (\r\n
\r\n
\r\n
\r\n \r\n setUserValue(\"email\", value)}\r\n />\r\n
\r\n
\r\n \r\n setUserValue(\"firstName\", value)}\r\n />\r\n
\r\n
\r\n \r\n setUserValue(\"lastName\", value)}\r\n />\r\n
\r\n
\r\n \r\n setUserValue(\"phone\", value)}\r\n />\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n setUserValue(\"send3WEmail\", !userToAdd.send3WEmail)\r\n }\r\n >\r\n Send 3W email\r\n \r\n \r\n setUserValue(\"sendAmdsEmail\", !userToAdd.sendAmdsEmail)\r\n }\r\n >\r\n Send AMDS welcome email\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n {\r\n setUserValue(\"creationIdentity\", value);\r\n }}\r\n >\r\n Global\r\n Luxembourg\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n )}\r\n
\r\n \r\n {summaryStatus === null ? (\r\n <>\r\n \r\n \r\n Submit\r\n \r\n \r\n ) : (\r\n \r\n )}\r\n \r\n \r\n );\r\n};\r\n\r\nexport default AddMultipleUsersToEntityModal;\r\n","import { PopBanner } from \"appkit-react\";\r\nimport UserSelectLegacy, {\r\n EXTERNAL_ONLY_FILTERS,\r\n} from \"pages/admin/components/AddUserToElementModal/UserSelect\";\r\nimport { useContext } from \"react\";\r\n\r\nimport AddUserModal from \"../../AddUserToElementModal/Modal\";\r\nimport { AdminEntityContext } from \"..\";\r\n\r\nconst AddUserToEntityModal = ({ entity, onClose, ...modalProps }) => {\r\n const { addUserToEntity } = useContext(AdminEntityContext);\r\n\r\n const submitAddUser = (form) => {\r\n const users = form.users;\r\n\r\n return addUserToEntity(\r\n entity.id,\r\n users.map((user) => user.ppid)\r\n ).then(() => {\r\n PopBanner({\r\n content:\r\n users.length > 1\r\n ? `The users have been successfully added to the entity.`\r\n : `The user has been successfully added to the entity.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n\r\n onClose();\r\n });\r\n };\r\n\r\n return (\r\n (\r\n \r\n )}\r\n {...modalProps}\r\n />\r\n );\r\n};\r\n\r\nexport default AddUserToEntityModal;\r\n","import { PopBanner } from \"appkit-react\";\r\nimport { useContext } from \"react\";\r\n\r\nimport DeleteUserFromElementModal from \"../../RemoveUserFromElementModal\";\r\nimport { AdminEntityContext } from \"..\";\r\n\r\nconst DeleteUserFromEntityModal = ({ user, onClose, ...modalProps }) => {\r\n const { removeUserFromEntity } = useContext(AdminEntityContext);\r\n const submitDeleteUser = () => {\r\n return removeUserFromEntity(user.parentId, user.ppid).then(() => {\r\n PopBanner({\r\n content: `The user ${user.name} has been successfully deleted from the entity.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n\r\n onClose();\r\n });\r\n };\r\n\r\n return (\r\n \r\n Be careful that you will also remove the user from all his/her\r\n subscriptions\r\n \r\n }\r\n {...modalProps}\r\n />\r\n );\r\n};\r\n\r\nexport default DeleteUserFromEntityModal;\r\n","import \"./MenuList.scss\";\r\n\r\nimport { ListItem } from \"appkit-react\";\r\nimport MenuList from \"components/MenuList\";\r\nimport { SyntheticEvent } from \"react\";\r\n\r\ninterface Props {\r\n onAddUser: () => void;\r\n onAddMultipleUsers: () => void;\r\n onEditEntity: () => void;\r\n onDeleteEntity: () => void;\r\n}\r\n\r\nexport default function EntityMenuList({\r\n onAddUser,\r\n onAddMultipleUsers,\r\n onEditEntity,\r\n onDeleteEntity,\r\n}: Props) {\r\n return (\r\n {\r\n e.stopPropagation();\r\n }}\r\n >\r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onAddUser();\r\n }}\r\n >\r\n \r\n Add user to company\r\n \r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onAddMultipleUsers();\r\n }}\r\n >\r\n \r\n Add multiple new users to company\r\n \r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onEditEntity();\r\n }}\r\n >\r\n \r\n Edit\r\n \r\n\r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onDeleteEntity();\r\n }}\r\n >\r\n \r\n Delete\r\n \r\n \r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport FloatingActionButtonPortal from \"components/FloatingActionButton\";\r\nimport Table from \"components/Table\";\r\nimport { useContext, useMemo, useRef, useState } from \"react\";\r\nimport Skeleton from \"react-loading-skeleton\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nimport useMainTableStickyHeader from \"../../../hooks/useMainTableStickyHeader\";\r\nimport UsersTable from \"../../UserTable\";\r\nimport AddEntityModal from \"../AddEntityModal\";\r\nimport DeleteEntityModal from \"../DeleteEntityModal\";\r\nimport AddMultipleUsersToEntityModal from \"./addMultipleUsersToEntityModal\";\r\nimport AddUserToEntityModal from \"./addUserToEntityModal\";\r\nimport DeleteUserFromEntityModal from \"./deleteUserFromEntityModal\";\r\nimport EntityMenuList from \"./MenuList\";\r\nimport { AdminEntityContext } from \"..\";\r\n\r\nexport const COLUMNS = [\r\n {\r\n Header: \"Company name\",\r\n id: \"entity\",\r\n filterable: true,\r\n sortable: true,\r\n },\r\n {\r\n Header: \"Company group name\",\r\n id: \"company\",\r\n filterable: true,\r\n sortable: true,\r\n },\r\n {\r\n Header: \"PRID\",\r\n id: \"prid\",\r\n accessor: \"prid\",\r\n filterable: true,\r\n Filter: () => null,\r\n sortable: false,\r\n },\r\n {\r\n Header: \"Show Services\",\r\n id: \"viewInMyServices\",\r\n accessor: \"viewInMyServices\",\r\n filterable: false,\r\n Filter: () => null,\r\n sortable: false,\r\n },\r\n {\r\n Header: \"Member\",\r\n id: \"name\",\r\n accessor: \"users\",\r\n filterable: true,\r\n sortable: false,\r\n },\r\n];\r\n\r\nconst DEFAULT_SORT = [\r\n { id: \"entity\", desc: false },\r\n { id: \"highestLevel\", desc: false },\r\n];\r\n\r\nconst EntitiesTable = ({ filters }) => {\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n\r\n const { rowFilters } = filters;\r\n const { loading, items: entities } = useContext(AdminEntityContext);\r\n\r\n const tableRef = useRef();\r\n useMainTableStickyHeader(loading, tableRef, 310);\r\n\r\n const [showCreateEntityModal, setShowCreateEntityModal] = useState(false);\r\n const [editedEntity, setEditedEntity] = useState(null);\r\n const [entityToDelete, setEntityToDelete] = useState(null);\r\n\r\n const [addUser, setAddUser] = useState(null);\r\n const [addMultipleUsers, setAddMultipleUsers] = useState(null);\r\n const [userToDelete, setUserToDelete] = useState(null);\r\n\r\n const [expanded, setExpanded] = useState([]);\r\n\r\n const columns = useMemo(() => {\r\n return [\r\n {\r\n Header: \"Company name\",\r\n id: \"entity\",\r\n accessor: \"name\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Company group name\",\r\n id: \"company\",\r\n accessor: \"companyName\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"PRID\",\r\n id: \"prid\",\r\n accessor: \"prid\",\r\n filterable: true,\r\n Filter: () => null,\r\n sortable: false,\r\n },\r\n {\r\n Header: \"Show Services\",\r\n id: \"viewInMyServices\",\r\n accessor: \"viewInMyServices\",\r\n filterable: false,\r\n Filter: () => null,\r\n sortable: false,\r\n Cell: ({ value }) => (value ? \"Yes\" : \"No\"),\r\n },\r\n {\r\n Header: \"# users\",\r\n id: \"name\",\r\n accessor: \"users\",\r\n filterable: true,\r\n sortable: false,\r\n Filter: () => null,\r\n filterMethod: (rowFilter, row) => {\r\n // row.name is actually row.users (?!)\r\n // id \"name\" is required to allow to keep the filter through admin tabs\r\n // \"name\" is the id of user column\r\n return row.name.some((user) =>\r\n user.name.toLowerCase().includes(rowFilter.value.toLowerCase())\r\n );\r\n },\r\n Cell: ({ value }) => value.length,\r\n width: 90,\r\n },\r\n {\r\n Header: \"Actions\",\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n className: \"overflow-td\",\r\n Cell: ({ original }) => {\r\n return (\r\n setAddUser(original)}\r\n onAddMultipleUsers={() => setAddMultipleUsers(original)}\r\n onEditEntity={() => {\r\n setShowCreateEntityModal(true);\r\n setEditedEntity(original);\r\n }}\r\n onDeleteEntity={() => setEntityToDelete(original)}\r\n />\r\n );\r\n },\r\n width: 90,\r\n },\r\n ];\r\n }, []);\r\n\r\n return !loading && !!entities ? (\r\n <>\r\n setShowCreateEntityModal(false)}\r\n entity={editedEntity}\r\n />\r\n\r\n setEntityToDelete(null)}\r\n entity={entityToDelete}\r\n />\r\n\r\n setAddUser(null)}\r\n />\r\n\r\n setAddMultipleUsers(null)}\r\n />\r\n\r\n setUserToDelete(null)}\r\n />\r\n\r\n {\r\n setEditedEntity(null);\r\n setShowCreateEntityModal(true);\r\n }}\r\n tooltip=\"Create a new entity\"\r\n />\r\n\r\n {\r\n if (row._subRows && row._subRows.length > 0) {\r\n return true;\r\n }\r\n return row[id] !== null\r\n ? row[id].toUpperCase().indexOf(value.toUpperCase()) >= 0\r\n : false;\r\n }}\r\n className=\"entitiestable\"\r\n columns={columns}\r\n data={entities}\r\n defaultSorted={DEFAULT_SORT}\r\n expanded={expanded}\r\n onExpandedChange={setExpanded}\r\n SubComponent={({ original }) => {\r\n return (\r\n \r\n );\r\n }}\r\n />\r\n \r\n ) : (\r\n \r\n );\r\n};\r\n\r\nexport default EntitiesTable;\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n downloadEntityImportTemplate,\r\n importEntitiesFromExcel,\r\n} from \"api/admin/adminApi\";\r\nimport EntitiesTable from \"pages/admin/components/Entity/EntitiesTable\";\r\nimport UploadImport from \"pages/newsAdmin/components/UploadImport\";\r\n\r\nexport default function EntityAdmin(props) {\r\n return (\r\n
\r\n \r\n \r\n
\r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport { getPhoto, getUserFromEmail } from \"api/admin/adminApi\";\r\nimport {\r\n pollCreateUser,\r\n pollUpdateProfile,\r\n pollUpdateUser,\r\n} from \"api/admin/adminPoller\";\r\nimport {\r\n Banner,\r\n Button,\r\n Checkbox,\r\n Input,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n Radio,\r\n RadioGroup,\r\n} from \"appkit-react\";\r\nimport ImageUploadToBase64 from \"components/ImageUploadToBase64\";\r\nimport PhoneInput, { validatePhone } from \"components/PhoneInput\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport useSubmitable from \"hooks/useSubmitable\";\r\nimport { fromUserModel, toUserModel } from \"pages/admin/utils/model\";\r\nimport { useEffect, useMemo, useRef, useState } from \"react\";\r\nimport ReactDOM from \"react-dom\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nimport EntitySelect from \"../../Engagement/AddEngagementModal/EntitySelect\";\r\n\r\nexport const isValidEmail = (email) => {\r\n const re =\r\n /^(([^<>()[\\]\\\\.,;:\\s@\"]+(\\.[^<>()[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/;\r\n return re.test(String(email).toLowerCase());\r\n};\r\n\r\nconst isInternalEmail = (email) => {\r\n const regexp = /^.*@([a-z]+\\.)*pwc\\.[a-z]{2,3}$/g;\r\n return regexp.test(email);\r\n};\r\n\r\nconst defaultUser = {\r\n email: \"\",\r\n photo: \"\",\r\n firstName: \"\",\r\n lastName: \"\",\r\n phone: {\r\n code: null,\r\n number: \"\",\r\n },\r\n grade: \"\",\r\n isSuperUser: false,\r\n entities: [],\r\n send3WEmail: false,\r\n sendAmdsEmail: false,\r\n creationIdentity: \"2\",\r\n};\r\n\r\nconst focusInputElement = (element) => {\r\n setTimeout(() => {\r\n const ref = ReactDOM.findDOMNode(element);\r\n if (ref) {\r\n const input = ref.querySelector(\"input\");\r\n if (input) {\r\n input.focus();\r\n }\r\n }\r\n }, 0);\r\n};\r\n\r\nconst findFormErrors = (user) => {\r\n return {\r\n email: !isValidEmail(user.email),\r\n firstName: !user.firstName,\r\n lastName: !user.lastName,\r\n phone: user.phone?.number?.trim().length > 0 && validatePhone(user.phone),\r\n grade: isInternalEmail(user.email) && user.grade.trim().length === 0,\r\n };\r\n};\r\n\r\nconst AddUserModal = ({\r\n visible = false,\r\n onClose,\r\n initialUser = null,\r\n onCreate,\r\n onUpdate,\r\n}) => {\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n const ownProfile =\r\n initialUser && loginUser && initialUser.ppid === loginUser.ppid;\r\n\r\n const {\r\n values: user,\r\n handleValueChange,\r\n handleFormChange,\r\n resetForm,\r\n submitting,\r\n formErrors,\r\n submit,\r\n } = useSubmitable(defaultUser, findFormErrors);\r\n\r\n const [fieldsAvailable, setFieldsAvailable] = useState(false);\r\n const [searchingUser, setSearchingUser] = useState(false);\r\n const [bannerContent, setBannerContent] = useState(\"\");\r\n const [isCropping, setIsCropping] = useState(false);\r\n const emailRef = useRef();\r\n const firstNameRef = useRef();\r\n\r\n const [oldPhoto, setOldPhoto] = useState(null);\r\n\r\n const isInternalUser = useMemo(\r\n () => isInternalEmail(user.email),\r\n [user.email]\r\n );\r\n\r\n useEffect(() => {\r\n if (user.photoUri) {\r\n getPhoto(user.photoUri).then(setOldPhoto);\r\n } else {\r\n setOldPhoto(null);\r\n }\r\n }, [user.photoUri]);\r\n\r\n useEffect(() => {\r\n if (visible && emailRef && emailRef.current) {\r\n focusInputElement(emailRef.current);\r\n }\r\n }, [visible, emailRef]);\r\n\r\n useEffect(() => {\r\n if (visible) {\r\n setBannerContent(\"\");\r\n if (initialUser !== null) {\r\n const data = fromUserModel(initialUser);\r\n\r\n handleFormChange(data);\r\n setFieldsAvailable(true);\r\n } else {\r\n resetForm();\r\n setFieldsAvailable(false);\r\n }\r\n } else {\r\n setTimeout(() => {\r\n handleFormChange(defaultUser);\r\n setFieldsAvailable(false);\r\n setBannerContent(\"\");\r\n }, 300);\r\n }\r\n }, [initialUser, handleFormChange, resetForm, visible]);\r\n\r\n const getModalTitle = () => {\r\n if (!initialUser) {\r\n return \"Create new user\";\r\n }\r\n return !ownProfile ? \"Edit user\" : \"Edit profile\";\r\n };\r\n\r\n const searchUser = () => {\r\n if (!isValidEmail(user.email)) {\r\n setBannerContent(\r\n \"The specified e-mail is not valid. Please check your input and try again\"\r\n );\r\n return;\r\n }\r\n setSearchingUser(true);\r\n setFieldsAvailable(false);\r\n\r\n getUserFromEmail(user.email)\r\n .then((data) => {\r\n const phone = {\r\n code: data?.phoneCountryCode || null,\r\n number: data?.phoneNumber || \"\",\r\n };\r\n\r\n handleFormChange({ ...user, ...data, phone, grade: data?.grade || \"\" });\r\n setFieldsAvailable(true);\r\n setSearchingUser(false);\r\n setBannerContent(\"\");\r\n })\r\n .catch((data) => {\r\n setSearchingUser(false);\r\n if (data.status === 404) {\r\n setBannerContent(\r\n \"No user found with the specified E-Mail. Please fill the fields manually\"\r\n );\r\n focusInputElement(firstNameRef.current);\r\n setFieldsAvailable(true);\r\n } else {\r\n throw data;\r\n }\r\n });\r\n };\r\n\r\n const handleSubmit = () => {\r\n submit(() => {\r\n const data = toUserModel(user);\r\n\r\n if (!initialUser) {\r\n return pollCreateUser(data).then((data) => {\r\n onClose();\r\n onCreate(data);\r\n });\r\n } else {\r\n const promise =\r\n !loginUser.isSuperUser && ownProfile\r\n ? pollUpdateProfile(data, initialUser)\r\n : pollUpdateUser(data, initialUser);\r\n\r\n return promise.then((newUser) => {\r\n onClose();\r\n newUser.name = `${user.firstName} ${user.lastName}`;\r\n onUpdate(newUser);\r\n });\r\n }\r\n });\r\n };\r\n\r\n const photoToDisplay = user.photo || oldPhoto;\r\n\r\n return (\r\n \r\n \r\n
{getModalTitle()}
\r\n
\r\n \r\n {!!bannerContent ? (\r\n \r\n ) : null}\r\n
\r\n
\r\n \r\n {\r\n handleValueChange(\"photo\", newValue);\r\n setIsCropping(false);\r\n }}\r\n onCropOpened={() => setIsCropping(true)}\r\n onCropCanceled={() => setIsCropping(false)}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n handleValueChange(\"email\", value)}\r\n onKeyPress={(event) => {\r\n if (event.charCode === 13 /*ENTER*/) {\r\n searchUser();\r\n }\r\n }}\r\n disabled={searchingUser || !!initialUser}\r\n />\r\n
\r\n {!initialUser ? (\r\n \r\n Search{\" \"}\r\n {searchingUser ? (\r\n
\r\n ) : null}\r\n \r\n ) : (\r\n
\r\n )}\r\n
\r\n \r\n handleValueChange(\"firstName\", value)}\r\n disabled={!fieldsAvailable}\r\n ref={firstNameRef}\r\n hasError={formErrors.firstName}\r\n />\r\n
\r\n
\r\n \r\n handleValueChange(\"lastName\", value)}\r\n disabled={!fieldsAvailable}\r\n hasError={formErrors.lastName}\r\n />\r\n
\r\n
\r\n \r\n handleValueChange(\"phone\", value)}\r\n disabled={!fieldsAvailable}\r\n hasError={formErrors.phone}\r\n />\r\n
\r\n {isInternalUser ? (\r\n <>\r\n
\r\n \r\n handleValueChange(\"grade\", value)}\r\n disabled={!fieldsAvailable}\r\n hasError={formErrors.grade}\r\n />\r\n
\r\n\r\n {\r\n handleValueChange(\"isSuperUser\", !user.isSuperUser);\r\n }}\r\n >\r\n Admin\r\n \r\n \r\n ) : (\r\n // As back support entities for user creation only\r\n !initialUser && (\r\n <>\r\n
\r\n \r\n \r\n handleValueChange(\"entities\", value)\r\n }\r\n placeholder=\"Companies\"\r\n />\r\n
\r\n {\r\n handleValueChange(\"send3WEmail\", !user.send3WEmail);\r\n }}\r\n >\r\n Send 3W email\r\n \r\n {\r\n handleValueChange(\"sendAmdsEmail\", !user.sendAmdsEmail);\r\n }}\r\n >\r\n Send AMDS welcome email\r\n \r\n \r\n )\r\n )}\r\n {!initialUser && (\r\n
\r\n
\r\n \r\n
\r\n {\r\n handleValueChange(\"creationIdentity\", value);\r\n }}\r\n >\r\n \r\n Global\r\n \r\n \r\n Luxembourg\r\n \r\n \r\n
\r\n
\r\n )}\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default AddUserModal;\r\n","import { pollDeleteUser } from \"api/admin/adminPoller\";\r\nimport classnames from \"classnames\";\r\nimport DeleteModal from \"components/DeleteModal\";\r\nconst DeleteUserModal = ({\r\n user,\r\n className,\r\n onCancel,\r\n onDelete,\r\n ...modalProps\r\n}) => {\r\n const deleteUser = async () => {\r\n await pollDeleteUser(user.ppid);\r\n onDelete(user.ppid);\r\n };\r\n\r\n return (\r\n \r\n

\r\n You're about to remove {user ? user.name : \"a user\"}\r\n . \r\n This action cannot be undone.\r\n

\r\n \r\n );\r\n};\r\n\r\nexport default DeleteUserModal;\r\n","import { resendUserWelcomeEmails } from \"api/admin/adminApi\";\r\nimport {\r\n Badge,\r\n Button,\r\n Checkbox,\r\n Modal,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n Radio,\r\n RadioGroup,\r\n} from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport { useState } from \"react\";\r\n\r\nconst NotifyUserModal = ({ user, className, onCancel, ...modalProps }) => {\r\n const [submitting, setSubmitting] = useState(false);\r\n const [creationIdentity, setCreationIdentity] = useState(\"2\");\r\n const [sendAmds, setSendAmds] = useState(false);\r\n const [send3w, setSend3w] = useState(false);\r\n\r\n const notifyUser = async () => {\r\n setSubmitting(true);\r\n try {\r\n await resendUserWelcomeEmails(\r\n user.ppid,\r\n send3w,\r\n sendAmds,\r\n creationIdentity\r\n );\r\n setCreationIdentity(\"2\");\r\n setSendAmds(false);\r\n setSend3w(false);\r\n onCancel();\r\n } finally {\r\n setSubmitting(false);\r\n }\r\n };\r\n\r\n const canSubmit = send3w || sendAmds;\r\n\r\n return (\r\n \r\n \r\n Information\r\n Notify user\r\n \r\n \r\n
\r\n {\" \"}\r\n
\r\n
\r\n Resend welcome e-mails to the user{\" \"}\r\n {user?.name ?? \"\"}\r\n
\r\n
\r\n
\r\n
\r\n {\r\n setSend3w(!send3w);\r\n }}\r\n >\r\n Re-Send 3W email\r\n \r\n
\r\n {\r\n setSendAmds(!sendAmds);\r\n }}\r\n >\r\n Re-Send AMDS welcome email\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n {\r\n setCreationIdentity(value);\r\n }}\r\n >\r\n Global\r\n Luxembourg\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n Notify\r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default NotifyUserModal;\r\n","import { refreshUser } from \"api/admin/adminApi\";\r\nimport {\r\n Badge,\r\n Button,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n PopBanner,\r\n} from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport { useState } from \"react\";\r\n\r\nconst RefreshUserModal = ({ user, className, onCancel, ...modalProps }) => {\r\n const [refreshing, setRefreshing] = useState(false);\r\n\r\n const onClose = () => {\r\n if (!refreshing) {\r\n onCancel();\r\n }\r\n };\r\n\r\n const refresh = () => {\r\n setRefreshing(true);\r\n refreshUser(user.id)\r\n .then(() => {\r\n PopBanner({\r\n content:\r\n \"The user will be refreshed. Please check back in a couple of minutes.\",\r\n closeable: true,\r\n className: \"a-banner-success\",\r\n });\r\n onCancel();\r\n })\r\n .finally(() => setRefreshing(false));\r\n };\r\n\r\n return (\r\n \r\n \r\n INFORMATION\r\n Refresh user data\r\n \r\n \r\n

\r\n You're about to refresh {user ? user.name : \"a user\"}\r\n . This will update the user's information such as his phone number and\r\n grade. The refresh could take a couple of minutes to appear in the\r\n application.\r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default RefreshUserModal;\r\n","import \"./index.scss\";\r\n\r\nimport { Tooltip } from \"@mui/material\";\r\nimport { getUsers } from \"api/admin/adminApi\";\r\nimport { pollUpdateSuperUserStatus } from \"api/admin/adminPoller\";\r\nimport { PopBanner } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport AvatarWithAsyncPhoto from \"components/AvatarWithAsyncPhoto\";\r\nimport FloatingActionButtonPortal from \"components/FloatingActionButton\";\r\nimport SwitchWithLoader from \"components/SwitchWithLoader\";\r\nimport Table, { Actions } from \"components/Table\";\r\nimport useData from \"hooks/useData\";\r\nimport { USERS_CONTEXTS } from \"pages/admin/constants\";\r\nimport useMainTableStickyHeader from \"pages/admin/hooks/useMainTableStickyHeader\";\r\nimport { createSuccessBanner } from \"pages/admin/utils\";\r\nimport { useCallback, useMemo, useRef, useState } from \"react\";\r\nimport Skeleton from \"react-loading-skeleton\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nimport AddUserModal from \"../AddUserModal\";\r\nimport DeleteUserModal from \"../DeleteUserModal\";\r\nimport NotifyUserModal from \"../NotifyUserModal\";\r\nimport RefreshUserModal from \"../RefreshUserModal\";\r\n\r\nexport const COLUMNS = [\r\n {\r\n Header: \"\",\r\n id: \"avatar\",\r\n Cell: ({ original }) => {\r\n return (\r\n \r\n );\r\n },\r\n sortable: false,\r\n filterable: false,\r\n width: 64,\r\n },\r\n {\r\n Header: \"Member\",\r\n accessor: \"name\",\r\n id: \"name\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Email\",\r\n accessor: \"email\",\r\n id: \"email\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Telephone\",\r\n accessor: \"phone\",\r\n id: \"phone\",\r\n filterable: false,\r\n sortable: false,\r\n Filter: () => null,\r\n Cell: ({ original }) => {\r\n return original.phoneNumber\r\n ? `+${original.phoneCountryCode} ${original.phoneNumber.replaceAll(\r\n \" \",\r\n \"\"\r\n )}`\r\n : \"\";\r\n },\r\n },\r\n {\r\n Header: \"Grade\",\r\n accessor: \"grade\",\r\n id: \"grade\",\r\n filterable: false,\r\n Filter: () => null,\r\n sortable: false,\r\n },\r\n {\r\n Header: \"Terms accepted\",\r\n accessor: \"termsAndConditionsAccepted\",\r\n id: \"termsAndConditionsAccepted\",\r\n filterable: false,\r\n sortable: false,\r\n width: 120,\r\n className: \"td-center\",\r\n Cell: ({ value }) => (\r\n \r\n ),\r\n },\r\n {\r\n Header: \"User Type\",\r\n accessor: \"creationIdentity\",\r\n id: \"creationIdentity\",\r\n filterable: false,\r\n sortable: true,\r\n width: 78,\r\n className: \"td-center\",\r\n Cell: ({ value }) => {\r\n const tooltip =\r\n value === 0\r\n ? \"PwC Staff User\"\r\n : value === 1\r\n ? \"PwC Global Account\"\r\n : \"PwC Luxembourg Account\";\r\n return (\r\n \r\n \r\n \r\n );\r\n },\r\n },\r\n];\r\n\r\nconst DEFAULT_SORT = [{ id: \"name\", desc: false }];\r\n\r\nconst UsersTable = ({ filters }) => {\r\n const [userToDelete, setUserToDelete] = useState(null);\r\n const [userToRefresh, setUserToRefresh] = useState(null);\r\n const [userToNotify, setUserToNotify] = useState(null);\r\n const [showCreateUserModal, setShowCreateUserModal] = useState(false);\r\n const [editedUser, setEditedUser] = useState(null);\r\n const [superUserUpdating, setSuperUserUpdating] = useState([]);\r\n const user = useSelector((state) => state.global.data.loginUser);\r\n\r\n const apiFilters = useMemo(() => {\r\n const res = {\r\n isSuperUser:\r\n filters.context === USERS_CONTEXTS.SUPERADMIN ? true : undefined,\r\n isInternal:\r\n filters.context === USERS_CONTEXTS.SUPERADMIN ||\r\n filters.context === USERS_CONTEXTS.PWC ||\r\n filters.context === USERS_CONTEXTS.LUXEMBOURG_STAFF\r\n ? true\r\n : filters.context === USERS_CONTEXTS.CLIENT\r\n ? false\r\n : undefined,\r\n ...(filters.context === USERS_CONTEXTS.LUXEMBOURG_STAFF\r\n ? { territory: \"LU\", isInternal: true }\r\n : {}),\r\n };\r\n\r\n return filters.rowFilters.reduce((acc, rowFilter) => {\r\n acc[rowFilter.id] = rowFilter.value;\r\n return acc;\r\n }, res);\r\n }, [filters]);\r\n\r\n const {\r\n loading,\r\n items: users,\r\n fetchData,\r\n optimisticChange,\r\n ...tableReducer\r\n } = useData(apiFilters, getUsers, DEFAULT_SORT);\r\n\r\n const setSuperUser = useCallback(\r\n (ppid, newValue) => {\r\n setSuperUserUpdating([...superUserUpdating, ppid]);\r\n pollUpdateSuperUserStatus(ppid, newValue)\r\n .then(() => {\r\n const user = (users[\r\n users.findIndex((user) => user.ppid === ppid)\r\n ].isSuperUser = newValue);\r\n\r\n optimisticChange(user);\r\n })\r\n .finally(() => {\r\n let newSuperUserUpdating = [...superUserUpdating];\r\n newSuperUserUpdating.splice(newSuperUserUpdating.indexOf(ppid), 1);\r\n setSuperUserUpdating(newSuperUserUpdating);\r\n });\r\n },\r\n [superUserUpdating, users, optimisticChange]\r\n );\r\n\r\n const tableRef = useRef();\r\n useMainTableStickyHeader(loading, tableRef, 310);\r\n\r\n const columns = useMemo(() => {\r\n return [\r\n ...COLUMNS,\r\n {\r\n Header: \"Admin\",\r\n accessor: \"isSuperUser\",\r\n id: \"isSuperUser\",\r\n filterable: false,\r\n sortable: false,\r\n width: 104,\r\n Filter: () => null,\r\n Cell: (row) => {\r\n return row.original.isInternal ? (\r\n {\r\n setSuperUser(row.original.ppid, newValue);\r\n }}\r\n />\r\n ) : null;\r\n },\r\n },\r\n {\r\n Header: \"Actions\",\r\n Cell: ({ row }) => (\r\n setUserToRefresh(row._original)}\r\n handleNotify={() => {\r\n setUserToNotify(row._original);\r\n }}\r\n handleEdit={() => {\r\n setEditedUser(row._original);\r\n setShowCreateUserModal(true);\r\n }}\r\n handleDelete={\r\n user?.isSuperUser\r\n ? () => {\r\n setUserToDelete(row._original);\r\n }\r\n : undefined\r\n }\r\n />\r\n ),\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n width: 180,\r\n },\r\n ];\r\n }, [setSuperUser, superUserUpdating, user.isSuperUser]);\r\n\r\n const updateUser = (updatedUser) => {\r\n fetchData();\r\n\r\n PopBanner({\r\n content: `The user ${updatedUser.name} has been successfully updated.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n };\r\n\r\n const onDelete = (deletedUserPpid) => {\r\n let newUsers = [...users];\r\n newUsers.splice(\r\n newUsers.findIndex((user) => user.ppid === deletedUserPpid),\r\n 1\r\n );\r\n fetchData();\r\n };\r\n\r\n return (\r\n <>\r\n {\r\n setShowCreateUserModal(false);\r\n }}\r\n initialUser={editedUser}\r\n onCreate={createSuccessBanner}\r\n onUpdate={updateUser}\r\n />\r\n {\r\n setEditedUser(null);\r\n setShowCreateUserModal(true);\r\n }}\r\n tooltip=\"Create a new user\"\r\n />\r\n setUserToRefresh(null)}\r\n />\r\n setUserToDelete(null)}\r\n onDelete={onDelete}\r\n />\r\n setUserToNotify(false)}\r\n user={userToNotify}\r\n />\r\n {!loading && !!users ? (\r\n \r\n ) : (\r\n \r\n )}\r\n \r\n );\r\n};\r\n\r\nexport default UsersTable;\r\n","import { refreshAllUsers } from \"api/admin/adminApi\";\r\nimport {\r\n Badge,\r\n Button,\r\n Checkbox,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n PopBanner,\r\n} from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport { useState } from \"react\";\r\n\r\nconst RefreshUsersModal = ({\r\n user,\r\n className,\r\n onCancel,\r\n onDelete,\r\n ...modalProps\r\n}) => {\r\n const [refreshing, setRefreshing] = useState(false);\r\n const [confirmRead, setConfirmRead] = useState(false);\r\n\r\n const onClose = () => {\r\n if (!refreshing) {\r\n onCancel();\r\n }\r\n };\r\n\r\n const refresh = () => {\r\n setRefreshing(true);\r\n refreshAllUsers()\r\n .then(() => {\r\n PopBanner({\r\n content:\r\n \"All of the users are currently being refreshed. This operation will take about 15 minutes to complete.\",\r\n closeable: true,\r\n className: \"a-banner-success\",\r\n });\r\n setConfirmRead(false);\r\n onCancel();\r\n })\r\n .finally(() => setRefreshing(false));\r\n };\r\n\r\n return (\r\n \r\n \r\n INFORMATION\r\n Refresh all user data\r\n \r\n \r\n

\r\n This action will refresh all user information from the users in this\r\n application, which includes names, grades and phone numbers. This\r\n action will take some time and{\" \"}\r\n could slow down the application. Therefore, this\r\n action should only be executed when required and will\r\n be logged. Are you sure you wish to proceed ?\r\n

\r\n setConfirmRead(!confirmRead)}\r\n disabled={refreshing}\r\n >\r\n I aknowledge that I have read and understood the notice above\r\n \r\n
\r\n \r\n \r\n \r\n Refresh all data\r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default RefreshUsersModal;\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n downloadUserImportTemplate,\r\n importUsersFromExcel,\r\n} from \"api/admin/adminApi\";\r\nimport FloatingActionButtonPortal from \"components/FloatingActionButton\";\r\nimport UsersTable from \"pages/admin/components/User/UsersTable\";\r\nimport UploadImport from \"pages/newsAdmin/components/UploadImport\";\r\nimport { useState } from \"react\";\r\n\r\nimport RefreshUsersModal from \"./refreshUsersModal\";\r\n\r\nexport default function UserAdmin(props) {\r\n const [openRefreshUsersModal, setOpenRefreshUsersModal] = useState(false);\r\n return (\r\n
\r\n \r\n new Promise((resolve, reject) => {\r\n importUsersFromExcel(file);\r\n resolve(true);\r\n })\r\n }\r\n onDownloadTemplate={downloadUserImportTemplate}\r\n type=\"User\"\r\n />\r\n \r\n setOpenRefreshUsersModal(false)}\r\n />\r\n setOpenRefreshUsersModal(true)}\r\n />\r\n
\r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n Button,\r\n Input,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n} from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport { useContext, useEffect } from \"react\";\r\n\r\nimport useSubmitable from \"../../../../../hooks/useSubmitable\";\r\nimport { AdminCompanyContext } from \"..\";\r\n\r\nconst DEFAULT_FORM = {\r\n companyId: null,\r\n name: \"\",\r\n};\r\n\r\nconst findFormErrors = (form) => {\r\n return {\r\n name: form.name.trim().length === 0,\r\n };\r\n};\r\n\r\nconst AddCompanyModal = ({ company, visible, onClose }) => {\r\n const { addCompany, updateCompany } = useContext(AdminCompanyContext);\r\n\r\n const {\r\n values: form,\r\n handleValueChange,\r\n submitting,\r\n formErrors,\r\n resetForm,\r\n submit,\r\n } = useSubmitable(DEFAULT_FORM, findFormErrors);\r\n\r\n useEffect(() => {\r\n resetForm(company || DEFAULT_FORM);\r\n }, [company, resetForm]);\r\n\r\n const handleSubmit = () => {\r\n submit((form) => {\r\n const promise = !company ? addCompany : updateCompany;\r\n\r\n return promise(form).then(onClose);\r\n });\r\n };\r\n\r\n useEffect(() => {\r\n if (!visible) {\r\n resetForm();\r\n }\r\n }, [visible, resetForm]);\r\n\r\n return (\r\n \r\n \r\n
\r\n {company ? \"Edit company group\" : \"Create company group\"}\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"name\", value)}\r\n placeholder=\"Company group name\"\r\n hasError={!!formErrors.name}\r\n />\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default AddCompanyModal;\r\n","import \"./index.scss\";\r\n\r\nimport FloatingActionButtonPortal from \"components/FloatingActionButton\";\r\nimport Table from \"components/Table\";\r\nimport Actions from \"components/Table/actions\";\r\nimport { useContext, useMemo, useRef, useState } from \"react\";\r\nimport Skeleton from \"react-loading-skeleton\";\r\n\r\nimport useMainTableStickyHeader from \"../../../hooks/useMainTableStickyHeader\";\r\nimport AddCompanyModal from \"../AddCompanyModal\";\r\nimport { AdminCompanyContext } from \"..\";\r\n\r\nexport const COLUMNS = [\r\n {\r\n Header: \"Company group name\",\r\n id: \"company\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n];\r\n\r\nconst DEFAULT_SORT = [\r\n { id: \"company\", desc: false },\r\n { id: \"highestLevel\", desc: false },\r\n { id: \"name\", desc: false },\r\n];\r\n\r\nconst CompaniesTable = ({ filters }) => {\r\n const { items: companies, loading } = useContext(AdminCompanyContext);\r\n\r\n const [showCreateCompanyModal, setShowCreateCompanyModal] = useState(false);\r\n const [editedCompany, setEditedCompany] = useState(null);\r\n\r\n const { rowFilters = [] } = filters;\r\n\r\n const tableRef = useRef();\r\n useMainTableStickyHeader(loading, tableRef);\r\n\r\n const columns = useMemo(() => {\r\n return [\r\n {\r\n Header: \"Company group name\",\r\n id: \"company\",\r\n accessor: \"name\",\r\n PivotValue: ({ value }) => value,\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Actions\",\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n Cell: ({ original }) => (\r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n setShowCreateCompanyModal(true);\r\n setEditedCompany(original);\r\n }}\r\n />\r\n ),\r\n width: 90,\r\n },\r\n ];\r\n }, []);\r\n\r\n return !loading && !!companies ? (\r\n <>\r\n setShowCreateCompanyModal(false)}\r\n company={editedCompany}\r\n />\r\n {\r\n setEditedCompany(null);\r\n setShowCreateCompanyModal(true);\r\n }}\r\n tooltip=\"Create a new company\"\r\n />\r\n\r\n {\r\n if (row._subRows && row._subRows.length > 0) {\r\n return true;\r\n }\r\n return row[id] !== null\r\n ? row[id].toUpperCase().indexOf(value.toUpperCase()) >= 0\r\n : false;\r\n }}\r\n className=\"companiestable\"\r\n columns={columns}\r\n data={companies}\r\n defaultSorted={DEFAULT_SORT}\r\n />\r\n \r\n ) : (\r\n \r\n );\r\n};\r\n\r\nexport default CompaniesTable;\r\n","import { Select, SelectOption } from \"appkit-react\";\r\nimport { useEffect } from \"react\";\r\n\r\nimport { USERS_CONTEXTS } from \"../../constants/index\";\r\n\r\nconst LABELS = {\r\n [USERS_CONTEXTS.ALL]: \"All\",\r\n [USERS_CONTEXTS.SUPERADMIN]: \"Admin\",\r\n [USERS_CONTEXTS.PWC]: \"PwC\",\r\n [USERS_CONTEXTS.CLIENT]: \"Client\",\r\n [USERS_CONTEXTS.LUXEMBOURG_STAFF]: \"Luxembourg staff\",\r\n};\r\n\r\nconst ContextToggle = ({ context, onContextChange, superAdmin = false }) => {\r\n useEffect(() => {\r\n if (!superAdmin && context === USERS_CONTEXTS.SUPERADMIN) {\r\n onContextChange(USERS_CONTEXTS.ALL);\r\n }\r\n }, [context, onContextChange, superAdmin]);\r\n\r\n const tabKeys = Object.keys(LABELS).filter(\r\n (userContext) => superAdmin || userContext !== USERS_CONTEXTS.SUPERADMIN\r\n );\r\n return (\r\n \r\n {tabKeys.map((key) => {\r\n return (\r\n \r\n {LABELS[key]}\r\n \r\n );\r\n })}\r\n \r\n );\r\n};\r\n\r\nexport default ContextToggle;\r\n","import { Select, SelectOption } from \"appkit-react\";\r\n\r\ninterface Props {\r\n value: boolean;\r\n onValueChange: (value: boolean) => void;\r\n}\r\n\r\nexport default function MyServicesFilter({\r\n value = false,\r\n onValueChange,\r\n}: Props) {\r\n const handleSelect = (value: string) => onValueChange(value === \"true\");\r\n return (\r\n \r\n );\r\n}\r\n","import { SubscriptionTrialFilter } from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\n\r\ninterface Props {\r\n value: SubscriptionTrialFilter;\r\n onValueChange: (value: SubscriptionTrialFilter) => void;\r\n}\r\n\r\nconst SubscriptionTrialFilterValues = [\r\n {\r\n value: 0,\r\n label: \"All trial kind\",\r\n },\r\n {\r\n value: 1,\r\n label: \"Trial only\",\r\n },\r\n {\r\n value: 2,\r\n label: \"Expired trial only\",\r\n },\r\n { value: 3, label: \"Non-trial only\" },\r\n];\r\n\r\nexport default function TrialFilter({ value, onValueChange }: Props) {\r\n const handleFilter = (stringValue: string) =>\r\n onValueChange(parseInt(stringValue) as SubscriptionTrialFilter);\r\n return (\r\n \r\n );\r\n}\r\n","import {\r\n downloadServiceExport,\r\n downloadUserPermissions,\r\n} from \"api/admin/adminApi\";\r\nimport { Button } from \"appkit-react\";\r\nimport { ContextsSearchbar } from \"components/SearchBar\";\r\nimport { useMemo, useState } from \"react\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nimport { ADMIN_TABS } from \"../../index\";\r\nimport ContextToggle from \"./ContextToggle\";\r\nimport MyServicesFilter from \"./MyServices\";\r\nimport TrialFilter from \"./TrialFilter\";\r\n\r\nconst Filters = ({ filters, onFiltersChange, activeTab }) => {\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n const [downloadLoading, setDownloadLoading] = useState(false);\r\n\r\n const filterColumns = useMemo(() => {\r\n return activeTab.columns.filter((column) => !!column.filterable);\r\n }, [activeTab]);\r\n\r\n const handleChange = (property, value) => {\r\n onFiltersChange({\r\n ...filters,\r\n [property]: value,\r\n });\r\n };\r\n\r\n const needsContextToggle = useMemo(\r\n () => activeTab === ADMIN_TABS.USERS,\r\n [activeTab]\r\n );\r\n\r\n const serviceTab = useMemo(\r\n () => activeTab === ADMIN_TABS.SERVICES,\r\n [activeTab]\r\n );\r\n\r\n const usersTab = useMemo(() => activeTab === ADMIN_TABS.USERS, [activeTab]);\r\n\r\n const needsMyServices = useMemo(\r\n () => activeTab === ADMIN_TABS.ENGAGEMENTS && !!loginUser?.isSuperUser,\r\n [activeTab, loginUser]\r\n );\r\n\r\n const needsTrialFilter = useMemo(\r\n () => activeTab === ADMIN_TABS.ENGAGEMENTS,\r\n [activeTab]\r\n );\r\n\r\n return (\r\n
\r\n \r\n handleChange(\"rowFilters\", value)}\r\n columns={filterColumns}\r\n />\r\n
\r\n\r\n {needsContextToggle ? (\r\n
\r\n handleChange(\"context\", value)}\r\n superAdmin={activeTab === ADMIN_TABS.USERS}\r\n />\r\n
\r\n ) : needsTrialFilter ? (\r\n <>\r\n {needsMyServices && (\r\n
\r\n handleChange(\"myServices\", value)}\r\n />\r\n
\r\n )}\r\n
\r\n handleChange(\"trial\", value)}\r\n />\r\n
\r\n \r\n ) : serviceTab ? (\r\n
\r\n {\r\n setDownloadLoading(true);\r\n downloadServiceExport().finally(() => setDownloadLoading(false));\r\n }}\r\n {...(downloadLoading ? { disabled: true } : {})}\r\n >\r\n {downloadLoading ? \"Loading\" : \"Export all services\"}\r\n \r\n
\r\n ) : null}\r\n {usersTab && (\r\n
\r\n {\r\n setDownloadLoading(true);\r\n downloadUserPermissions().finally(() =>\r\n setDownloadLoading(false)\r\n );\r\n }}\r\n {...(downloadLoading ? { disabled: true } : {})}\r\n >\r\n {downloadLoading ? \"Loading\" : \"Export All users\"}\r\n \r\n
\r\n )}\r\n
\r\n );\r\n};\r\n\r\nexport default Filters;\r\n","import \"./index.scss\";\r\n\r\nimport { TextArea } from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\n\r\nconst ValidationTextarea = ({\r\n errMsg = \"\",\r\n hasError = false,\r\n className = undefined,\r\n ...textareaProps\r\n}) => {\r\n return (\r\n <>\r\n \r\n {hasError &&

{errMsg}

}\r\n \r\n );\r\n};\r\n\r\nexport default ValidationTextarea;\r\n","import \"./AppForm.scss\";\r\n\r\nimport { ApplicationReadDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { Button, Input, Switch } from \"appkit-react\";\r\nimport { FormErrors } from \"hooks/useSubmitable\";\r\nimport UserSelect, {\r\n INTERNAL_ONLY_FILTERS,\r\n} from \"pages/admin/components/AddUserToElementModal/UserSelect\";\r\nimport { Ref } from \"react\";\r\n\r\ninterface Props {\r\n value: ApplicationReadDTO;\r\n errors?: FormErrors | null;\r\n onValueChange: (value: ApplicationReadDTO) => void;\r\n onDelete?: () => void;\r\n onUnfocus?: () => void;\r\n clickOutsideRef: Ref;\r\n}\r\nexport default function ApplicationForm({\r\n value: application,\r\n errors,\r\n onValueChange,\r\n onDelete,\r\n onUnfocus,\r\n clickOutsideRef,\r\n}: Props) {\r\n const handleValueChange = (property: keyof ApplicationReadDTO) => (\r\n value: string\r\n ) => {\r\n onValueChange({\r\n ...application,\r\n [property]: value,\r\n });\r\n };\r\n\r\n return (\r\n
\r\n
\r\n \r\n \r\n\r\n \r\n\r\n \r\n\r\n \r\n
\r\n
\r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport { ApplicationReadDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { FormErrors } from \"hooks/useSubmitable\";\r\nimport useMultilineForm from \"pages/admin/hooks/useMultilineForm\";\r\nimport { Ref } from \"react\";\r\n\r\nimport ApplicationForm from \"./AppForm\";\r\n\r\nexport const DEFAULT_APPLICATION = {\r\n name: \"\",\r\n link: \"\",\r\n itContact: null,\r\n showToClient: true,\r\n};\r\n\r\ninterface Props {\r\n applications: ApplicationReadDTO[];\r\n errors?: FormErrors;\r\n onApplicationsChange: (applications: ApplicationReadDTO[]) => void;\r\n clickOutsideRef: Ref;\r\n}\r\n\r\nexport default function ApplicationsForm({\r\n applications,\r\n errors,\r\n onApplicationsChange,\r\n clickOutsideRef,\r\n}: Props) {\r\n const { handleChange, handleDelete } = useMultilineForm(\r\n applications,\r\n onApplicationsChange,\r\n DEFAULT_APPLICATION\r\n );\r\n return (\r\n <>\r\n {applications.map((app, index) => (\r\n handleChange(app, index)}\r\n onDelete={() => handleDelete(index)}\r\n />\r\n ))}\r\n\r\n
\r\n
\r\n (Leave blank to avoid adding a new application)\r\n
\r\n
Display to the client ?
\r\n
\r\n \r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport { ServiceIllustrationReadDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { Avatar, Button, List, ListItem, ListItemText } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport { ChangeEvent, useEffect, useMemo, useRef, useState } from \"react\";\r\n\r\ninterface IIllustrationListProps {\r\n illustrations: ServiceIllustrationReadDTO[];\r\n onFilesAddChange: (files: File[]) => void;\r\n onFilesDeleteChange: (ids: string[]) => void;\r\n}\r\n\r\ninterface LocalServiceIllustration extends ServiceIllustrationReadDTO {\r\n file: File;\r\n}\r\n\r\nexport default function IllustrationList({\r\n illustrations: currentIllustrations,\r\n onFilesAddChange,\r\n onFilesDeleteChange,\r\n}: IIllustrationListProps) {\r\n const inputFile = useRef(null);\r\n const [filesToAdd, setFilesToAdd] = useState([]);\r\n const [filesToDelete, setFilesToDelete] = useState([]);\r\n\r\n useEffect(() => {\r\n setFilesToAdd([]);\r\n setFilesToDelete([]);\r\n }, [currentIllustrations]);\r\n\r\n const handleClick = () => {\r\n inputFile?.current?.click();\r\n };\r\n\r\n const onChange = (event: ChangeEvent) => {\r\n event.stopPropagation();\r\n event.preventDefault();\r\n var files = event.target.files;\r\n if (files) {\r\n setFilesToAdd((prevFiles) => {\r\n const newFiles = [...prevFiles, ...Array.from(files!)];\r\n onFilesAddChange(newFiles);\r\n return newFiles;\r\n });\r\n }\r\n };\r\n\r\n const handleDeleteLocal = (file: LocalServiceIllustration) => {\r\n setFilesToAdd((prevFiles) => {\r\n const newFiles = prevFiles.filter((_file) => _file !== file.file);\r\n onFilesAddChange(newFiles);\r\n return newFiles;\r\n });\r\n };\r\n\r\n const handleDeleteRemote = (file: ServiceIllustrationReadDTO) => {\r\n setFilesToDelete((prevFiles) => {\r\n const newFiles = prevFiles.includes(file.id)\r\n ? prevFiles.filter((id) => id !== file.id)\r\n : [...prevFiles, file.id];\r\n onFilesDeleteChange(newFiles);\r\n return newFiles;\r\n });\r\n };\r\n\r\n const illustrations = useMemo(() => {\r\n return [\r\n ...currentIllustrations,\r\n ...filesToAdd.map((file) => ({\r\n id: file.name,\r\n contentType: file.type,\r\n isVideo: file.type.startsWith(\"video\"),\r\n file,\r\n })),\r\n ];\r\n }, [currentIllustrations, filesToAdd]);\r\n\r\n return (\r\n
\r\n \r\n \r\n {illustrations.map((illustration) => (\r\n \r\n null}\r\n >\r\n \r\n handleDeleteLocal(\r\n illustration as LocalServiceIllustration\r\n )\r\n : () => handleDeleteRemote(illustration)\r\n }\r\n />\r\n \r\n \r\n \r\n \r\n ))}\r\n \r\n \r\n
\r\n );\r\n}\r\n","import {\r\n LifecycleAllReadDTO,\r\n LifecycleReadDTO,\r\n} from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { useLifeCyclesAll } from \"api/catalog/queries/useLifeCycles\";\r\nimport { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { sortBy } from \"lodash\";\r\nimport { useMemo } from \"react\";\r\n\r\ninterface ILifeCycleSelectProps {\r\n tenant: string;\r\n value: string[];\r\n onValueChange: (value: string[]) => void;\r\n hasError?: boolean;\r\n errMsg?: any;\r\n placeholder?: string;\r\n}\r\n\r\nconst LifeCycleSelect = ({\r\n tenant,\r\n value,\r\n onValueChange,\r\n ...selectProps\r\n}: ILifeCycleSelectProps) => {\r\n const { data: lifecyclesAll = {} } = useLifeCyclesAll();\r\n const lifecyclesAllSorted = useMemo(() => {\r\n return Object.entries(lifecyclesAll).reduce((acc, [key, value]) => {\r\n acc[key] = sortBy(value, (item) => item.order);\r\n return acc;\r\n }, {} as LifecycleAllReadDTO);\r\n }, [lifecyclesAll]);\r\n const lifecycles: LifecycleReadDTO[] = lifecyclesAllSorted[tenant] ?? [];\r\n return (\r\n {\r\n if (typeof values === \"string\") {\r\n onValueChange(values);\r\n return;\r\n }\r\n const isAdd = values.length > value.length;\r\n if (isAdd) {\r\n const [addedValue] = values.filter((item) => !value.includes(item));\r\n const valuesToCommit = values.filter((item) => {\r\n if (\r\n !lifecycles.map((lifecycle) => lifecycle.name).includes(item) &&\r\n item !== addedValue\r\n ) {\r\n return false;\r\n }\r\n return true;\r\n });\r\n onValueChange(valuesToCommit);\r\n } else {\r\n onValueChange(values);\r\n }\r\n }}\r\n {...selectProps}\r\n >\r\n {lifecycles?.map((lifecycle) => (\r\n \r\n {lifecycle.name}\r\n \r\n ))}\r\n \r\n );\r\n};\r\n\r\nexport default LifeCycleSelect;\r\n","import { getOrganizations } from \"api/admin/adminApi\";\r\nimport AsyncSelect from \"components/AsyncSelect\";\r\nimport { Ref, useCallback } from \"react\";\r\n\r\ninterface Props {\r\n value: string[];\r\n onChange: (value: string[]) => void;\r\n clickOutsideRef?: Ref;\r\n}\r\n\r\nexport default function OrganizationSelect({\r\n value,\r\n onChange,\r\n clickOutsideRef,\r\n}: Props) {\r\n const loadItems = useCallback(async (pageNumber, name) => {\r\n const response = await getOrganizations(\r\n {\r\n filters: { name },\r\n orderBy: {\r\n name: {\r\n isDescending: false,\r\n },\r\n },\r\n },\r\n { pageNumber, pageSize: 20 }\r\n );\r\n\r\n return {\r\n ...response,\r\n items: response.items?.map((organization) => organization.name) || [],\r\n };\r\n }, []);\r\n\r\n return (\r\n Promise.resolve(value.map((x) => ({ id: x, value: x })))) as any\r\n }\r\n clearable\r\n className=\"organization-select\"\r\n loadItems={loadItems}\r\n placeholder=\"Organizations\"\r\n multiple\r\n render={(name: string) => name}\r\n value={value}\r\n onChange={onChange}\r\n clickOutsideRef={clickOutsideRef as any}\r\n />\r\n );\r\n}\r\n","import useServiceGroups from \"api/catalog/queries/useServiceGroups\";\r\nimport { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\ninterface IServiceGroupSelect {\r\n value: string | null;\r\n onValueChange: (value: string) => void;\r\n}\r\n\r\nconst ServiceGroupSelect = ({\r\n value,\r\n onValueChange,\r\n ...selectProps\r\n}: IServiceGroupSelect) => {\r\n const { data: serviceGroups = [] } = useServiceGroups();\r\n\r\n return (\r\n \r\n {serviceGroups?.sort(localeCompare(\"name\")).map((service) => (\r\n \r\n {service.name}\r\n \r\n ))}\r\n \r\n );\r\n};\r\n\r\nexport default ServiceGroupSelect;\r\n","import { IndustryReadDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { useIndustriesAll } from \"api/catalog/queries/useIndustries\";\r\nimport { SelectGroupTitle, SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\n\r\ninterface Props {\r\n value: string[];\r\n onValueChange: (value: string[]) => void;\r\n placeholder?: string;\r\n hasError?: boolean;\r\n errMsg?: string | boolean | null;\r\n tenant: string;\r\n}\r\nexport default function ServiceIndustryTagSelect({\r\n value,\r\n onValueChange,\r\n ...props\r\n}: Props) {\r\n const { data: industriesAll = {} } = useIndustriesAll();\r\n const industries: IndustryReadDTO[] =\r\n industriesAll[props.tenant] ??\r\n industriesAll[`HTTP://${props.tenant}/`] ??\r\n [];\r\n return (\r\n \r\n {industries\r\n .filter((industry) => industry.subIndustries?.length)\r\n .flatMap((industry) => [\r\n {industry.name},\r\n ...industry.subIndustries!.map((subIndustry) => (\r\n \r\n {subIndustry.name}\r\n \r\n )),\r\n ])}\r\n Others\r\n {industries\r\n .filter((industry) => !industry.subIndustries?.length)\r\n .map((industry) => (\r\n \r\n {industry.name}\r\n \r\n ))}\r\n \r\n );\r\n}\r\n","import useLiveService from \"api/catalog/queries/useLiveServices\";\r\nimport { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\ninterface IServiceSelectProps {\r\n value: string[];\r\n onValueChange: (value: string[]) => void;\r\n serviceIdExclude?: string | null;\r\n}\r\n\r\nconst ServiceSelect = ({\r\n value,\r\n onValueChange,\r\n serviceIdExclude,\r\n ...selectProps\r\n}: IServiceSelectProps) => {\r\n const { data: services = [] } = useLiveService(\r\n serviceIdExclude\r\n ? {\r\n select: (services) =>\r\n services.filter((service) => service.id !== serviceIdExclude),\r\n }\r\n : {}\r\n );\r\n\r\n return (\r\n \r\n {services?.sort(localeCompare(\"name\")).map((service) => (\r\n \r\n {service.name}\r\n \r\n ))}\r\n \r\n );\r\n};\r\n\r\nexport default ServiceSelect;\r\n","import {\r\n ValueChainAllReadDTO,\r\n ValueChainReadDTO,\r\n} from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { useValueChainsAll } from \"api/catalog/queries/useValueChains\";\r\nimport { SelectOption } from \"appkit-react\";\r\nimport Select from \"components/Select\";\r\nimport { sortBy } from \"lodash\";\r\nimport { useMemo } from \"react\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\ninterface IValueChainSelectProps {\r\n tenant?: string;\r\n value: string[];\r\n onValueChange: (value: string[]) => void;\r\n hasError?: boolean;\r\n errMsg?: any;\r\n placeholder?: string;\r\n}\r\n\r\nconst ValueChainSelect = ({\r\n tenant,\r\n value,\r\n onValueChange,\r\n ...selectProps\r\n}: IValueChainSelectProps) => {\r\n const tenants = useSelector((state) => (state as any).global.data.tenants);\r\n const { data: valueChainsAll = {} as ValueChainAllReadDTO } =\r\n useValueChainsAll();\r\n const valueChainsAllSorted = useMemo(() => {\r\n return Object.entries(valueChainsAll).reduce((acc, [key, value]) => {\r\n acc[key] = sortBy(value, (item) => item.order);\r\n return acc;\r\n }, {} as ValueChainAllReadDTO);\r\n }, [valueChainsAll]);\r\n\r\n const valueChains: ValueChainReadDTO[] = useMemo(() => {\r\n if (tenant !== undefined) {\r\n return valueChainsAllSorted[tenant] ?? [];\r\n }\r\n return Object.entries(valueChainsAllSorted).reduce((acc, [key, value]) => {\r\n return [...acc, ...value];\r\n }, [] as ValueChainReadDTO[]);\r\n }, [tenant, valueChainsAllSorted]);\r\n\r\n return (\r\n {\r\n if (typeof values === \"string\") {\r\n onValueChange(values);\r\n return;\r\n }\r\n const isAdd = values.length > value.length;\r\n if (isAdd) {\r\n const [addedValue] = values.filter((item) => !value.includes(item));\r\n const valuesToCommit = values.filter((item) => {\r\n if (\r\n !valueChains\r\n .map((valuechain) => valuechain.name)\r\n .includes(item) &&\r\n item !== addedValue\r\n ) {\r\n return false;\r\n }\r\n return true;\r\n });\r\n onValueChange(valuesToCommit);\r\n } else {\r\n onValueChange(values);\r\n }\r\n }}\r\n {...selectProps}\r\n >\r\n {valueChains?.map((valueChain) => (\r\n \r\n {valueChain.name}\r\n {tenant === undefined &&\r\n ` (${\r\n tenants.find(\r\n (t: any) => t.domain.toUpperCase() === valueChain.domain\r\n )?.name\r\n })`}\r\n \r\n ))}\r\n \r\n );\r\n};\r\n\r\nexport default ValueChainSelect;\r\n","import \"./index.scss\";\r\n\r\nimport { Checkbox, FormControlLabel, FormGroup } from \"@mui/material\";\r\nimport { UserReadDTO } from \"api/admin/__generated__/UserManagementAPI\";\r\nimport { getServiceDetails, getTerritories } from \"api/catalog/catalogApi\";\r\nimport useCatalogueHomepageDetails from \"api/catalog/queries/useCatalogueHomepageDetails\";\r\nimport {\r\n Button,\r\n Input,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n PopBanner,\r\n SelectOption,\r\n Switch,\r\n} from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport Select from \"components/Select\";\r\nimport ValidationTextarea from \"components/Textarea\";\r\nimport useSubmitable from \"hooks/useSubmitable\";\r\nimport UserSelect, {\r\n INTERNAL_ONLY_FILTERS,\r\n} from \"pages/admin/components/AddUserToElementModal/UserSelect\";\r\nimport is3wService from \"pages/admin/utils/is3wService\";\r\nimport { useContext, useEffect, useMemo, useRef } from \"react\";\r\nimport { useQuery } from \"react-query\";\r\nimport { useSelector } from \"react-redux\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\nimport { ServiceForm, findFormErrors, toServiceForm } from \"../../type/form\";\r\nimport { AdminServiceContext } from \"../AdminServiceContextHOC\";\r\nimport ApplicationsForm, { DEFAULT_APPLICATION } from \"./ApplicationsForm\";\r\nimport IllustrationList from \"./IllustrationList\";\r\nimport LifeCycleSelect from \"./LifeCycleSelect\";\r\nimport OrganizationSelect from \"./OrganizationSelect\";\r\nimport ServiceGroupSelect from \"./ServiceGroupSelect\";\r\nimport ServiceIndustryTagSelect from \"./ServiceIndustryTagSelect\";\r\nimport ServiceSelect from \"./ServiceSelect\";\r\nimport ValueChainSelect from \"./ValueChainSelect/ValueChainSelect\";\r\n\r\nconst usePrevious = (value: any) => {\r\n const ref = useRef();\r\n useEffect(() => {\r\n ref.current = value;\r\n });\r\n return ref.current;\r\n};\r\n\r\ninterface Props {\r\n visible: boolean;\r\n onClose: () => void;\r\n serviceId: string | null;\r\n}\r\n\r\nconst DEFAULT_FORM: ServiceForm = {\r\n applications: [{ ...DEFAULT_APPLICATION }],\r\n description: \"\",\r\n live: false,\r\n name: \"\",\r\n responsibles: [],\r\n team: [],\r\n videoLink: \"\",\r\n itContact: null,\r\n organizations: [],\r\n industries: [],\r\n isHighlighted: false,\r\n isNew: false,\r\n isPSF: false,\r\n isPSA: false,\r\n lifeCycles: [],\r\n valueChains: [],\r\n smallDescription: \"\",\r\n geographicalInformation: \"\",\r\n targetProfile: \"\",\r\n mainAddedValue: \"\",\r\n secondaryAddedValue: \"\",\r\n relatedServices: [],\r\n illustrations: [],\r\n illustrationsToAdd: [],\r\n illustrationsToRemove: [],\r\n availableApplication: \"\",\r\n deliverable: \"\",\r\n viewers: [],\r\n domains: [],\r\n territories: [],\r\n friendlyUrl: \"\",\r\n visibleInClientView: true,\r\n ukViewers: [],\r\n frViewers: [],\r\n};\r\n\r\nexport default function AddServiceModal({\r\n serviceId,\r\n visible,\r\n onClose,\r\n}: Props) {\r\n const { upsertService } = useContext(AdminServiceContext);\r\n const { data: homepage } = useCatalogueHomepageDetails();\r\n const tenants = useSelector((state) => (state as any).global.data.tenants);\r\n const { data: territories, isLoading: loadingTerritories } = useQuery(\r\n [\"service-territories\"],\r\n {\r\n queryFn: () => getTerritories(),\r\n staleTime: 1000 * 60,\r\n enabled: process.env.REACT_APP_ENABLE_SERVICE_TERRITORIES === \"true\",\r\n }\r\n );\r\n\r\n const {\r\n values: form,\r\n handleValueChange,\r\n submitting,\r\n formErrors,\r\n resetForm,\r\n submit,\r\n } = useSubmitable(DEFAULT_FORM, findFormErrors);\r\n\r\n useEffect(() => {\r\n if (!visible || serviceId === null) {\r\n resetForm(DEFAULT_FORM);\r\n } else {\r\n getServiceDetails(serviceId).then((service) =>\r\n resetForm(toServiceForm(service))\r\n );\r\n }\r\n }, [visible, serviceId, resetForm]);\r\n\r\n const handleSubmit = () => {\r\n submit(() => upsertService(form).then(onClose));\r\n };\r\n\r\n const clickOutsideRef = useRef(null);\r\n\r\n const hasErrors = useMemo(\r\n () => Object.values(formErrors).some((value) => !!value),\r\n [formErrors]\r\n );\r\n\r\n const previousHasErrors = usePrevious(hasErrors);\r\n\r\n useEffect(() => {\r\n if (hasErrors && !previousHasErrors) {\r\n PopBanner({\r\n content: Errors exist in the form. Please fix them.,\r\n duration: 6000,\r\n status: \"warning\",\r\n });\r\n }\r\n }, [hasErrors, previousHasErrors]);\r\n\r\n const handleDomainChange = (domain: string, newValue: boolean) => {\r\n if (newValue) {\r\n handleValueChange(\"domains\", [...form.domains, domain]);\r\n } else {\r\n handleValueChange(\r\n \"domains\",\r\n form.domains.filter((formDomain) => formDomain !== domain)\r\n );\r\n }\r\n };\r\n\r\n const formatFriendlyUrl = (value: string) => {\r\n return value\r\n .toLocaleLowerCase()\r\n .normalize(\"NFD\")\r\n .replace(/[\\u0300-\\u036f]/g, \"\")\r\n .replace(/([^ ]) $/, \"$1-\")\r\n .trim()\r\n .replaceAll(\" \", \"-\")\r\n .replaceAll(/[^a-z-_]/gm, \"\");\r\n };\r\n\r\n return (\r\n \r\n \r\n
\r\n {serviceId ? \"Edit service\" : \"Create service\"}\r\n
\r\n
\r\n \r\n
\r\n
\r\n Service information\r\n
\r\n
\r\n \r\n handleValueChange(\"name\", value)}\r\n placeholder=\"Service name\"\r\n hasError={!!formErrors.name}\r\n errMsg={formErrors.name || undefined}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"description\", value)\r\n }\r\n placeholder=\"Service description\"\r\n hasError={!!formErrors.description}\r\n errMsg={\r\n typeof formErrors.description === \"string\"\r\n ? formErrors.description\r\n : undefined\r\n }\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"smallDescription\", value)\r\n }\r\n placeholder=\"Service short description\"\r\n hasError={!!formErrors.smallDescription}\r\n errMsg={\r\n typeof formErrors.smallDescription === \"string\"\r\n ? formErrors.smallDescription\r\n : undefined\r\n }\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n {process.env.REACT_APP_URL}service/}\r\n value={form.friendlyUrl}\r\n onChange={(value: string) =>\r\n handleValueChange(\"friendlyUrl\", formatFriendlyUrl(value))\r\n }\r\n hasError={!!formErrors.friendlyUrl}\r\n errMsg={formErrors.friendlyUrl || undefined}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n Service Scope\r\n
\r\n
\r\n \r\n {tenants?.map((tenant: any) => {\r\n const tenantDomain = tenant.domain.toUpperCase();\r\n return (\r\n domain === tenantDomain\r\n )}\r\n onChange={(_event, newValue) =>\r\n handleDomainChange(tenantDomain, newValue)\r\n }\r\n />\r\n }\r\n label={tenant.name}\r\n />\r\n );\r\n })}\r\n \r\n
\r\n
\r\n
\r\n
\r\n Service Details\r\n {tenants &&\r\n tenants\r\n .filter((tenant: any) =>\r\n form.domains.includes(tenant.domain.toUpperCase())\r\n )\r\n .map((tenant: any) => {\r\n return (\r\n
\r\n {tenant.name}\r\n
\r\n \r\n {!!homepage && (\r\n \r\n handleValueChange(\"industries\", value)\r\n }\r\n placeholder={homepage?.mainFilter + \" tags\"}\r\n hasError={!!formErrors.industries}\r\n // @ts-ignore\r\n errMsg={formErrors.industries}\r\n />\r\n )}\r\n
\r\n
\r\n \r\n {!!homepage && (\r\n \r\n handleValueChange(\"lifeCycles\", value)\r\n }\r\n hasError={!!formErrors.lifeCycles}\r\n placeholder={\r\n \"Select a \" + homepage?.secondaryFilter\r\n }\r\n errMsg={\r\n typeof formErrors.lifeCycles === \"string\"\r\n ? formErrors.lifeCycles\r\n : undefined\r\n }\r\n />\r\n )}\r\n
\r\n
\r\n \r\n {!!homepage && (\r\n \r\n handleValueChange(\"valueChains\", value)\r\n }\r\n placeholder={\"Select a \" + homepage?.tertiaryFilter}\r\n hasError={!!formErrors.valueChains}\r\n errMsg={\r\n typeof formErrors.valueChains === \"string\"\r\n ? formErrors.valueChains\r\n : undefined\r\n }\r\n />\r\n )}\r\n
\r\n
\r\n );\r\n })}\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"isNew\", isNew)\r\n }\r\n label=\"New\"\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"isHighlighted\", isHighlighted)\r\n }\r\n label=\"Highlighted\"\r\n />\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"isPSF\", isPSF)\r\n }\r\n label=\"PSF\"\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"isPSA\", isPSA)\r\n }\r\n label=\"PSA\"\r\n />\r\n
\r\n
\r\n
\r\n {process.env.REACT_APP_ENABLE_SERVICE_TERRITORIES === \"true\" && (\r\n <>\r\n
\r\n
\r\n {!loadingTerritories ? (\r\n <>\r\n \r\n {\r\n handleValueChange(\"territories\", values);\r\n }}\r\n multiple\r\n >\r\n {territories\r\n ?.sort(localeCompare(\"name\"))\r\n .map((territory) => (\r\n \r\n {territory.name}\r\n \r\n ))}\r\n \r\n \r\n ) : (\r\n
\r\n )}\r\n
\r\n
\r\n \r\n )}\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"geographicalInformation\", value)\r\n }\r\n placeholder=\"Geographical information\"\r\n hasError={!!formErrors.geographicalInformation}\r\n errMsg={formErrors.geographicalInformation || undefined}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"targetProfile\", value)\r\n }\r\n placeholder=\"Target profile\"\r\n hasError={!!formErrors.targetProfile}\r\n errMsg={formErrors.targetProfile || undefined}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"availableApplication\", value)\r\n }\r\n placeholder=\"Available Applications\"\r\n hasError={!!formErrors.availableApplication}\r\n errMsg={formErrors.availableApplication || undefined}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"deliverable\", value)\r\n }\r\n placeholder=\"Deliverable\"\r\n hasError={!!formErrors.deliverable}\r\n errMsg={formErrors.deliverable || undefined}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"mainAddedValue\", value)\r\n }\r\n placeholder=\"Main added value\"\r\n hasError={!!formErrors.mainAddedValue}\r\n errMsg={formErrors.mainAddedValue || undefined}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"secondaryAddedValue\", value)\r\n }\r\n placeholder=\"Secondary added value\"\r\n hasError={!!formErrors.secondaryAddedValue}\r\n errMsg={formErrors.secondaryAddedValue || undefined}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"relatedServices\", value)\r\n }\r\n serviceIdExclude={serviceId}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"serviceGroupId\", value)\r\n }\r\n />\r\n
\r\n
\r\n
\r\n
\r\n Illustrations\r\n
\r\n
\r\n \r\n handleValueChange(\"illustrationsToAdd\", value)\r\n }\r\n onFilesDeleteChange={(value: string[]) =>\r\n handleValueChange(\"illustrationsToRemove\", value)\r\n }\r\n illustrations={form.illustrations}\r\n />\r\n
\r\n
\r\n {formErrors.illustrations ? (\r\n

{formErrors.illustrations}

\r\n ) : null}\r\n
\r\n
\r\n Applications\r\n
\r\n
\r\n \r\n handleValueChange(\"applications\", applications)\r\n }\r\n />\r\n
\r\n
\r\n
\r\n
\r\n Teams\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"responsibles\", value)\r\n }\r\n placeholder=\"Service responsibles\"\r\n hasError={!!formErrors.responsibles}\r\n errMsg={formErrors.responsibles}\r\n multiple\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"itContact\", value)\r\n }\r\n placeholder=\"IT team\"\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"team\", value)\r\n }\r\n placeholder=\"Service team\"\r\n multiple\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n\r\n
\r\n \r\n \r\n handleValueChange(\"organizations\", value)\r\n }\r\n />\r\n
\r\n
\r\n {is3wService(serviceId) && (\r\n <>\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"viewers\", value)\r\n }\r\n placeholder=\"PwC viewers\"\r\n hasError={!!formErrors.viewers}\r\n errMsg={formErrors.viewers}\r\n multiple\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"ukViewers\", value)\r\n }\r\n placeholder=\"UK\"\r\n hasError={!!formErrors.ukViewers}\r\n errMsg={formErrors.ukViewers}\r\n multiple\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"frViewers\", value)\r\n }\r\n placeholder=\"FR\"\r\n hasError={!!formErrors.frViewers}\r\n errMsg={formErrors.frViewers}\r\n multiple\r\n filters={INTERNAL_ONLY_FILTERS}\r\n />\r\n
\r\n
\r\n \r\n )}\r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n handleValueChange(\"videoLink\", value)\r\n }\r\n hasError={!!formErrors.videoLink}\r\n errMsg={formErrors.videoLink}\r\n />\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n handleValueChange(\"live\", live)}\r\n label=\"Visible\"\r\n />\r\n
\r\n
\r\n \r\n
\r\n \r\n handleValueChange(\"visibleInClientView\", visibleInClientView)\r\n }\r\n label=\"Visible\"\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n}\r\n","import { PopBanner } from \"appkit-react\";\r\nimport DeleteModal from \"components/DeleteModal\";\r\nimport { useContext } from \"react\";\r\n\r\nimport { ServiceItem } from \"../../type\";\r\nimport { AdminServiceContext } from \"../AdminServiceContextHOC\";\r\n\r\ninterface Props {\r\n service: ServiceItem | null;\r\n onClose: () => void;\r\n}\r\nexport default function DeleteSerciceModal({\r\n service,\r\n onClose,\r\n ...modalProps\r\n}: Props) {\r\n const { deleteService } = useContext(AdminServiceContext);\r\n\r\n const submitDeleteEngagement = async () => {\r\n if (!service) return;\r\n\r\n await deleteService(service);\r\n\r\n PopBanner({\r\n content: `The service ${service.name} has been successfully deleted.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n\r\n onClose();\r\n };\r\n\r\n return (\r\n \r\n

\r\n You're about to remove the service {service?.name} \r\n This action cannot be undone.\r\n

\r\n \r\n );\r\n}\r\n","import { Chip } from \"@mui/material\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nconst ServiceTableBadge: React.FC<{ domain: string }> = (props) => {\r\n const tenants = useSelector((state) => (state as any).global.data.tenants);\r\n const tenant = tenants?.find(\r\n (tenant: any) => tenant.domain.toUpperCase() === props.domain\r\n );\r\n return (\r\n \r\n );\r\n};\r\nexport default ServiceTableBadge;\r\n","import \"./index.scss\";\r\n\r\nimport SwitchWithLoader from \"components/SwitchWithLoader\";\r\nimport Table from \"components/Table\";\r\nimport Actions from \"components/Table/actions\";\r\nimport useMainTableStickyHeader from \"pages/admin/hooks/useMainTableStickyHeader\";\r\nimport { useContext, useMemo, useRef, useState } from \"react\";\r\nimport Skeleton from \"react-loading-skeleton\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nimport { ServiceItem } from \"../../type\";\r\nimport { AdminServiceContext } from \"../AdminServiceContextHOC\";\r\nimport ServiceTableBadge from \"./ServiceTableBadge\";\r\n\r\nconst DEFAULT_SORT = [{ id: \"name\", desc: false }];\r\n\r\ninterface Props {\r\n filters: any;\r\n onEditService: (service: ServiceItem) => void;\r\n onDeleteService: (service: ServiceItem) => void;\r\n}\r\n\r\ninterface Submitting {\r\n [serviceId: string]: boolean;\r\n}\r\nconst emptyFilter = () => null;\r\n\r\nexport const COLUMNS = [\r\n {\r\n Header: \"Service Name\",\r\n id: \"service\",\r\n filterable: true,\r\n Filter: emptyFilter,\r\n },\r\n {\r\n Header: \"Domains\",\r\n id: \"domains\",\r\n filterable: true,\r\n Filter: emptyFilter,\r\n },\r\n];\r\n\r\nexport default function ServicesTable({\r\n filters,\r\n onEditService,\r\n onDeleteService,\r\n}: Props) {\r\n const {\r\n items: services,\r\n loading,\r\n patchDisplayed,\r\n patchIsNew,\r\n patchIsHighlighted,\r\n } = useContext(AdminServiceContext);\r\n\r\n const tenants = useSelector((state) => (state as any).global.data.tenants);\r\n\r\n const { rowFilters = [] } = filters;\r\n\r\n var { isSuperUser } = useSelector(\r\n (state: any) => state.global.data.loginUser\r\n );\r\n\r\n const [submitting, setSubmitting] = useState({});\r\n\r\n const tableRef = useRef();\r\n useMainTableStickyHeader(loading, tableRef, 310);\r\n\r\n const columns = useMemo(() => {\r\n const handleDisplayedChange = (\r\n service: ServiceItem,\r\n displayed: boolean\r\n ) => {\r\n setSubmitting((submitting) => {\r\n return {\r\n ...submitting,\r\n [service.id]: true,\r\n };\r\n });\r\n patchDisplayed(service, displayed).then(() => {\r\n setSubmitting((submitting) => {\r\n return {\r\n ...submitting,\r\n [service.id]: false,\r\n };\r\n });\r\n });\r\n };\r\n\r\n const handleIsNewChange = (service: ServiceItem, isNew: boolean) => {\r\n setSubmitting((submitting) => {\r\n return {\r\n ...submitting,\r\n [service.id]: true,\r\n };\r\n });\r\n patchIsNew(service, isNew).then(() => {\r\n setSubmitting((submitting) => {\r\n return {\r\n ...submitting,\r\n [service.id]: false,\r\n };\r\n });\r\n });\r\n };\r\n\r\n const handleIsHighlightedChange = (\r\n service: ServiceItem,\r\n isHighlighted: boolean\r\n ) => {\r\n setSubmitting((submitting) => {\r\n return {\r\n ...submitting,\r\n [service.id]: true,\r\n };\r\n });\r\n patchIsHighlighted(service, isHighlighted).then(() => {\r\n setSubmitting((submitting) => {\r\n return {\r\n ...submitting,\r\n [service.id]: false,\r\n };\r\n });\r\n });\r\n };\r\n\r\n let cols = [\r\n {\r\n Header: \"Service Name\",\r\n id: \"service\",\r\n accessor: \"name\",\r\n filterable: true,\r\n Filter: emptyFilter,\r\n Cell: ({ original }: { original: ServiceItem }) => {\r\n return (\r\n \r\n {original.name}{\" \"}\r\n {original.domains.map((domain) => (\r\n \r\n ))}\r\n \r\n );\r\n },\r\n },\r\n {\r\n Header: \"\",\r\n id: \"domains\",\r\n accessor: \"domains\",\r\n filterable: true,\r\n Filter: emptyFilter,\r\n filterMethod: (\r\n filterQuery: { id: string; Header: string; value: string },\r\n original: ServiceItem\r\n ) => {\r\n const originalDomainNames = original.domains.map(\r\n (domain) =>\r\n tenants.find(\r\n (tenant: any) =>\r\n tenant.domain.toUpperCase() === domain.toUpperCase()\r\n )?.name\r\n );\r\n return originalDomainNames.some((domain: any) => {\r\n return domain\r\n ?.toUpperCase()\r\n .includes(filterQuery.value.toUpperCase());\r\n });\r\n },\r\n Cell: () => null,\r\n width: 0,\r\n className: \"hidden\",\r\n },\r\n {\r\n Header: \"Is New\",\r\n id: \"isNew\",\r\n accessor: \"isNew\",\r\n Cell: ({ original }: { original: ServiceItem }) => {\r\n return (\r\n {\r\n handleIsNewChange(original, isNew);\r\n }}\r\n />\r\n );\r\n },\r\n filterable: true,\r\n Filter: emptyFilter,\r\n width: 90,\r\n },\r\n {\r\n Header: \"Is Highlighted\",\r\n id: \"isHighlighted\",\r\n accessor: \"isHighlighted\",\r\n Cell: ({ original }: { original: ServiceItem }) => {\r\n return (\r\n {\r\n handleIsHighlightedChange(original, isHighlighted);\r\n }}\r\n />\r\n );\r\n },\r\n filterable: true,\r\n Filter: emptyFilter,\r\n width: 110,\r\n },\r\n {\r\n Header: \"Visible\",\r\n id: \"displayed\",\r\n accessor: \"displayed\",\r\n Cell: ({ original }: { original: ServiceItem }) => {\r\n return (\r\n {\r\n handleDisplayedChange(original, displayed);\r\n }}\r\n />\r\n );\r\n },\r\n filterable: true,\r\n Filter: emptyFilter,\r\n width: 90,\r\n },\r\n {\r\n Header: \"Actions\",\r\n Cell: ({ original }: { original: ServiceItem }) => (\r\n <>\r\n onEditService(original))\r\n }\r\n handleDelete={isSuperUser && (() => onDeleteService(original))}\r\n />\r\n \r\n ),\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n width: 90,\r\n },\r\n ];\r\n\r\n return cols;\r\n }, [\r\n isSuperUser,\r\n patchDisplayed,\r\n submitting,\r\n onEditService,\r\n onDeleteService,\r\n patchIsHighlighted,\r\n patchIsNew,\r\n tenants,\r\n ]);\r\n\r\n return !loading && !!services ? (\r\n \r\n row[id]?.toUpperCase().indexOf(value.toUpperCase()) >= 0\r\n }\r\n defaultSorted={DEFAULT_SORT}\r\n />\r\n ) : (\r\n \r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n downloadServiceImportTemplate,\r\n importServiceFromExcel,\r\n} from \"api/admin/adminApi\";\r\nimport FloatingActionButtonPortal from \"components/FloatingActionButton\";\r\nimport UploadImport from \"pages/newsAdmin/components/UploadImport\";\r\nimport { useState } from \"react\";\r\n\r\nimport { ServiceItem } from \"../type\";\r\nimport AddServiceModal from \"./AddServiceModal\";\r\nimport DeleteServiceModal from \"./DeleteServiceModal\";\r\nimport ServicesTable from \"./Table\";\r\n\r\ninterface Props {\r\n filters: any;\r\n initializer?: any;\r\n}\r\n\r\nconst EMPTY_SERVICE: ServiceItem = {\r\n canAddSubscription: false,\r\n domains: [],\r\n id: \"\",\r\n isHighlighted: false,\r\n isNew: false,\r\n live: false,\r\n name: \"\",\r\n};\r\n\r\nexport default function AdminServices({ filters, initializer }: Props) {\r\n const [addingService, setAddingService] = useState(false);\r\n const [serviceToUpdate, setServiceToUpdate] = useState(\r\n initializer?.id ? { ...EMPTY_SERVICE, id: initializer.id } : null\r\n );\r\n const [serviceToDelete, setServiceToDelete] = useState(\r\n null\r\n );\r\n\r\n return (\r\n <>\r\n {\r\n setServiceToUpdate(null);\r\n setAddingService(false);\r\n }}\r\n />\r\n setServiceToDelete(null)}\r\n />\r\n
\r\n \r\n \r\n
\r\n setAddingService(true)}\r\n name=\"icon-plus-fill\"\r\n tooltip=\"Create a new service\"\r\n />\r\n \r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n pollAddServiceGroup,\r\n pollEditServiceGroup,\r\n} from \"api/catalog/catalogPoller\";\r\nimport useCatalogueHomepageDetails from \"api/catalog/queries/useCatalogueHomepageDetails\";\r\nimport useServiceGroupById from \"api/catalog/queries/useServiceGroupById\";\r\nimport {\r\n Button,\r\n Input,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n} from \"appkit-react\";\r\nimport { SelectOption } from \"appkit-react\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport Select from \"components/Select\";\r\nimport ValidationTextarea from \"components/Textarea\";\r\nimport { useEffect } from \"react\";\r\nimport { useMutation } from \"react-query\";\r\nimport { useSelector } from \"react-redux\";\r\n\r\nimport useSubmitable from \"../../../../../hooks/useSubmitable\";\r\nimport ServiceSelect from \"../../Engagement/AddEngagementModal/ServiceSelect\";\r\nimport LifeCycleSelect from \"../../Service/components/AddServiceModal/LifeCycleSelect\";\r\nimport ValueChainSelect from \"../../Service/components/AddServiceModal/ValueChainSelect/ValueChainSelect\";\r\n\r\nconst DEFAULT_FORM = {\r\n name: \"\",\r\n domain: \"\",\r\n smallDescription: \"\",\r\n lifeCycle: \"\",\r\n valueChain: \"\",\r\n services: [],\r\n};\r\n\r\nconst findFormErrors = (form) => {\r\n return {\r\n name: form.name.trim().length === 0,\r\n };\r\n};\r\n\r\nconst AddServiceGroupModal = ({\r\n serviceGroupId,\r\n visible,\r\n onClose,\r\n onServiceGroupChanged,\r\n}) => {\r\n const { data: homepage } = useCatalogueHomepageDetails();\r\n\r\n const { data: serviceGroup } = useServiceGroupById({\r\n serviceGroupId,\r\n queryOptions: {\r\n enabled: !!serviceGroupId && visible,\r\n select: (data) => ({\r\n ...data,\r\n services: data.services.map((service) => service.id),\r\n }),\r\n },\r\n });\r\n const { mutate: addServiceGroup, isLoading: submittingAddService } =\r\n useMutation(\r\n ({ form }) => {\r\n return pollAddServiceGroup(form);\r\n },\r\n {\r\n onSuccess: () => {\r\n onServiceGroupChanged();\r\n },\r\n }\r\n );\r\n const { mutate: editServiceGroup, isLoading: submittingEditService } =\r\n useMutation(\r\n ({ id, form }) => {\r\n return pollEditServiceGroup(id, form);\r\n },\r\n {\r\n onSuccess: () => {\r\n onServiceGroupChanged();\r\n },\r\n }\r\n );\r\n\r\n const submitting = submittingAddService || submittingEditService;\r\n\r\n const {\r\n values: form,\r\n handleValueChange,\r\n formErrors,\r\n resetForm,\r\n } = useSubmitable(DEFAULT_FORM, findFormErrors);\r\n\r\n useEffect(() => {\r\n resetForm(serviceGroup || DEFAULT_FORM);\r\n }, [serviceGroup, resetForm]);\r\n\r\n const handleSubmit = () => {\r\n if (serviceGroupId) {\r\n editServiceGroup({ id: serviceGroupId, form });\r\n } else {\r\n addServiceGroup({ form });\r\n }\r\n };\r\n\r\n useEffect(() => {\r\n if (!visible) {\r\n resetForm();\r\n }\r\n }, [visible, resetForm]);\r\n\r\n const tenants = useSelector((state) => state.global.data.tenants);\r\n\r\n return (\r\n \r\n \r\n
\r\n {serviceGroup ? \"Edit service group\" : \"Create service group\"}\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n handleValueChange(\"name\", value)}\r\n placeholder=\"Company group name\"\r\n hasError={!!formErrors.name}\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n handleValueChange(\"smallDescription\", value)}\r\n placeholder=\"Service short description\"\r\n hasError={!!formErrors.smallDescription}\r\n errMsg={\r\n typeof formErrors.smallDescription === \"string\"\r\n ? formErrors.smallDescription\r\n : undefined\r\n }\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n {\r\n handleValueChange(\"domain\", value);\r\n handleValueChange(\"lifeCycle\", \"\");\r\n handleValueChange(\"valueChain\", \"\");\r\n }}\r\n >\r\n {tenants.map((tenant) => (\r\n \r\n {tenant.name}\r\n \r\n ))}\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n handleValueChange(\"lifeCycle\", value)}\r\n hasError={!!formErrors.lifeCycle}\r\n placeholder={\"Select a \" + homepage?.secondaryFilter}\r\n errMsg={\r\n typeof formErrors.lifeCycle === \"string\"\r\n ? formErrors.lifeCycle\r\n : undefined\r\n }\r\n />\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n handleValueChange(\"valueChain\", value)}\r\n placeholder={\"Select a \" + homepage?.tertiaryFilter}\r\n hasError={!!formErrors.valueChain}\r\n errMsg={\r\n typeof formErrors.valueChain === \"string\"\r\n ? formErrors.valueChain\r\n : undefined\r\n }\r\n />\r\n
\r\n
\r\n
\r\n
\r\n \r\n handleValueChange(\"services\", value)}\r\n placeholder={\"Select some services\"}\r\n hasError={!!formErrors.services}\r\n errMsg={\r\n typeof formErrors.services === \"string\"\r\n ? formErrors.services\r\n : undefined\r\n }\r\n />\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default AddServiceGroupModal;\r\n","import { UseTypedQueryOptions } from \"api/UseTypedQueryOptions\";\r\nimport { UseQueryResult, useQuery } from \"react-query\";\r\n\r\nimport { ServiceGroupReadDTO } from \"../__generated__/CatalogueAPI\";\r\nimport { getServiceGroupById } from \"../catalogApi\";\r\n\r\ninterface IUseServiceGroupByIdProps {\r\n serviceGroupId: string;\r\n queryOptions?: UseTypedQueryOptions;\r\n}\r\n\r\nexport default function useServiceGroupById(\r\n props: IUseServiceGroupByIdProps\r\n): UseQueryResult {\r\n return useQuery(\r\n \"serviceGroup/\" + props.serviceGroupId,\r\n () => getServiceGroupById(props.serviceGroupId),\r\n props.queryOptions\r\n );\r\n}\r\n","import { ServiceGroupReadListDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport DeleteModal from \"components/DeleteModal\";\r\n\r\ninterface Props {\r\n serviceGroup: ServiceGroupReadListDTO | null;\r\n onClose: () => void;\r\n onConfirmDelete: () => void;\r\n}\r\nexport default function DeleteServiceGroupModal({\r\n serviceGroup,\r\n onClose,\r\n onConfirmDelete,\r\n ...modalProps\r\n}: Props) {\r\n const submitDeleteServiceGroup = async () => {\r\n onConfirmDelete();\r\n };\r\n\r\n return (\r\n \r\n

\r\n You're about to remove the service group {serviceGroup?.name} \r\n This action cannot be undone.\r\n

\r\n \r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport useCatalogueHomepageDetails from \"api/catalog/queries/useCatalogueHomepageDetails\";\r\nimport Table from \"components/Table\";\r\nimport Actions from \"components/Table/actions\";\r\nimport { useMemo, useRef } from \"react\";\r\nimport Skeleton from \"react-loading-skeleton\";\r\n\r\nimport useMainTableStickyHeader from \"../../../hooks/useMainTableStickyHeader\";\r\nimport ServiceTableBadge from \"../../Service/components/Table/ServiceTableBadge\";\r\n\r\nexport const COLUMNS = [\r\n {\r\n Header: \"Service group name\",\r\n id: \"name\",\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n];\r\n\r\nconst DEFAULT_SORT = [\r\n { id: \"company\", desc: false },\r\n { id: \"highestLevel\", desc: false },\r\n { id: \"name\", desc: false },\r\n];\r\n\r\nconst ServiceGroupsTable = ({\r\n filters,\r\n serviceGroups,\r\n loading,\r\n onEdit,\r\n onDelete,\r\n}) => {\r\n const { data: homepage } = useCatalogueHomepageDetails();\r\n\r\n const { rowFilters = [] } = filters;\r\n\r\n const tableRef = useRef();\r\n useMainTableStickyHeader(loading, tableRef);\r\n\r\n const columns = useMemo(() => {\r\n return [\r\n {\r\n Header: \"Service group name\",\r\n id: \"name\",\r\n accessor: \"name\",\r\n PivotValue: ({ value }) => value,\r\n filterable: true,\r\n Filter: () => null,\r\n Cell: ({ original }) => (\r\n \r\n {original.name}{\" \"}\r\n \r\n \r\n ),\r\n },\r\n {\r\n Header: homepage?.secondaryFilter,\r\n id: \"lifeCycle\",\r\n accessor: \"lifeCycle\",\r\n PivotValue: ({ value }) => value,\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: homepage?.tertiaryFilter,\r\n id: \"valueChain\",\r\n accessor: \"valueChain\",\r\n PivotValue: ({ value }) => value,\r\n filterable: true,\r\n Filter: () => null,\r\n },\r\n {\r\n Header: \"Actions\",\r\n id: \"actions\",\r\n sortable: false,\r\n filterable: false,\r\n Cell: ({ original }) => (\r\n {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onEdit(original);\r\n }}\r\n handleDelete={(event) => {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n onDelete(original);\r\n }}\r\n />\r\n ),\r\n width: 90,\r\n },\r\n ];\r\n }, [homepage?.secondaryFilter, homepage?.tertiaryFilter, onEdit, onDelete]);\r\n\r\n return !loading ? (\r\n <>\r\n {\r\n if (row._subRows && row._subRows.length > 0) {\r\n return true;\r\n }\r\n return row[id] !== null\r\n ? row[id].toUpperCase().indexOf(value.toUpperCase()) >= 0\r\n : false;\r\n }}\r\n className=\"service-groups-table\"\r\n columns={columns}\r\n data={serviceGroups}\r\n defaultSorted={DEFAULT_SORT}\r\n />\r\n \r\n ) : (\r\n \r\n );\r\n};\r\n\r\nexport default ServiceGroupsTable;\r\n","import \"./index.scss\";\r\n\r\nimport { ServiceGroupReadListDTO } from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { pollDeleteServiceGroup } from \"api/catalog/catalogPoller\";\r\nimport useServiceGroups from \"api/catalog/queries/useServiceGroups\";\r\nimport { PopBanner } from \"appkit-react\";\r\nimport FloatingActionButtonPortal from \"components/FloatingActionButton\";\r\nimport FullPageLoader from \"components/FullPageLoader\";\r\nimport { useState } from \"react\";\r\nimport { useMutation } from \"react-query\";\r\n\r\nimport AddServiceGroupModal from \"./AddServiceGroupModal\";\r\nimport DeleteServiceGroupModal from \"./DeleteServiceGroupModal\";\r\nimport ServiceGroupsTable from \"./Table\";\r\n\r\ninterface Props {\r\n filters: any;\r\n}\r\nexport default function AdminServiceGroups({ filters }: Props) {\r\n const [showCreateServiceGroupModal, setShowCreateServiceGroupModal] =\r\n useState(false);\r\n const [serviceGroupToDelete, setServiceGroupToDelete] =\r\n useState(null);\r\n const [editedServiceGroupId, setEditedServiceGroupId] = useState<\r\n string | null\r\n >(null);\r\n const {\r\n data: serviceGroups,\r\n isFetching,\r\n isLoading,\r\n refetch: refreshServiceGroups,\r\n } = useServiceGroups();\r\n\r\n const { mutate: deleteServiceGroup, isLoading: deleteServiceGroupLoading } =\r\n useMutation(\r\n ({ id }: { id: string }) => {\r\n return pollDeleteServiceGroup(id);\r\n },\r\n {\r\n onSuccess: () => {\r\n refreshServiceGroups();\r\n PopBanner({\r\n content: `The service ${\r\n serviceGroupToDelete!.name\r\n } has been successfully deleted.`,\r\n duration: 4000,\r\n status: \"success\",\r\n });\r\n setServiceGroupToDelete(null);\r\n },\r\n }\r\n );\r\n\r\n return (\r\n <>\r\n {deleteServiceGroupLoading && }\r\n {\r\n setEditedServiceGroupId(null);\r\n setShowCreateServiceGroupModal(false);\r\n }}\r\n onServiceGroupChanged={() => {\r\n setShowCreateServiceGroupModal(false);\r\n setEditedServiceGroupId(null);\r\n refreshServiceGroups();\r\n }}\r\n serviceGroupId={editedServiceGroupId}\r\n />\r\n setServiceGroupToDelete(null)}\r\n onConfirmDelete={() => {\r\n deleteServiceGroup({ id: serviceGroupToDelete!.id });\r\n }}\r\n />\r\n\r\n
\r\n {\r\n setShowCreateServiceGroupModal(true);\r\n setEditedServiceGroupId(serviceGroup.id);\r\n }}\r\n onDelete={(serviceGroup: ServiceGroupReadListDTO) => {\r\n setServiceGroupToDelete(serviceGroup);\r\n }}\r\n />\r\n
\r\n setShowCreateServiceGroupModal(true)}\r\n name=\"icon-plus-fill\"\r\n tooltip=\"Create a new service\"\r\n />\r\n \r\n );\r\n}\r\n","export default __webpack_public_path__ + \"static/media/header.2324fa95.png\";","import \"./index.scss\";\r\n\r\nimport { MODULES } from \"constants/module\";\r\n\r\nimport { Panel, Tab, Tabs } from \"appkit-react\";\r\nimport CategoryPitch from \"components/CategoryPitch\";\r\nimport PageTitle from \"components/PageTitle\";\r\nimport EngagementsTableContextWrapper from \"pages/admin/components/Engagement\";\r\nimport SubscriptionAdmin from \"pages/admin/components/Engagement/SubscriptionAdmin\";\r\nimport EntityAdmin from \"pages/admin/components/Entity/EntityAdmin\";\r\nimport UserAdmin from \"pages/admin/components/User/UserAdmin\";\r\nimport { useEffect, useState } from \"react\";\r\nimport { useSelector } from \"react-redux\";\r\nimport { useHistory, useParams } from \"react-router\";\r\n\r\nimport { SERVICE_STEPS } from \"../catalogue/constants\";\r\nimport AdminCompanyContextHOC from \"./components/Company\";\r\nimport CompaniesTable, {\r\n COLUMNS as CompaniesTableColumns,\r\n} from \"./components/Company/CompaniesTable\";\r\nimport { COLUMNS as EngagementsTableColumns } from \"./components/Engagement/SubscriptionTable\";\r\nimport AdminEntityContextHOC from \"./components/Entity\";\r\nimport { COLUMNS as EntitiesTableColumns } from \"./components/Entity/EntitiesTable\";\r\nimport Filters from \"./components/Filters\";\r\nimport AdminServices from \"./components/Service/components\";\r\nimport AdminServiceContextHOC from \"./components/Service/components/AdminServiceContextHOC\";\r\nimport { COLUMNS as ServicesTableColumns } from \"./components/Service/components/Table\";\r\nimport AdminServiceGroups from \"./components/ServiceGroup\";\r\nimport { COLUMNS as ServiceGroupTableColumns } from \"./components/ServiceGroup/Table\";\r\nimport AdminTerritories from \"./components/Territories\";\r\nimport { COLUMNS as TerritoriesColumns } from \"./components/Territories/Table\";\r\nimport { COLUMNS as UsersTableColumns } from \"./components/User/UsersTable\";\r\nimport { USERS_CONTEXTS } from \"./constants\";\r\nimport backgroundImage from \"./img/header.png\";\r\n\r\nexport const ADMIN_TABS = {\r\n USERS: {\r\n id: \"USERS\",\r\n columns: UsersTableColumns,\r\n label: \"Users\",\r\n icon: \"icon-person\",\r\n },\r\n\r\n COMPANIES: {\r\n id: \"COMPANIES\",\r\n columns: CompaniesTableColumns,\r\n label: \"Company groups\",\r\n icon: \"icon-building\",\r\n },\r\n\r\n ENTITIES: {\r\n id: \"ENTITIES\",\r\n columns: EntitiesTableColumns,\r\n label: \"Companies\",\r\n icon: \"icon-visitor\",\r\n },\r\n\r\n ENGAGEMENTS: {\r\n id: \"ENGAGEMENTS\",\r\n columns: EngagementsTableColumns,\r\n label: \"Subscriptions\",\r\n icon: \"icon-growth\",\r\n },\r\n\r\n SERVICES: {\r\n id: \"SERVICES\",\r\n columns: ServicesTableColumns,\r\n label: \"Services\",\r\n icon: \"icon-management\",\r\n },\r\n\r\n SERVICES_GROUPS: {\r\n id: \"SERVICE_GROUPS\",\r\n columns: ServiceGroupTableColumns,\r\n label: \"Service groups\",\r\n icon: \"icon-bubble-plot\",\r\n },\r\n};\r\nif (process.env.REACT_APP_ENABLE_SERVICE_TERRITORIES === \"true\") {\r\n ADMIN_TABS[\"TERRITORIES\"] = {\r\n id: \"TERRITORIES\",\r\n columns: TerritoriesColumns,\r\n label: \"Territories\",\r\n icon: \"icon-globe-map\",\r\n };\r\n}\r\n\r\nconst DEFAULT_FILTERS = {\r\n context: USERS_CONTEXTS.ALL,\r\n rowFilters: [],\r\n steps: Object.values(SERVICE_STEPS),\r\n myServices: true,\r\n trial: 0,\r\n};\r\n\r\nexport const AdminWithInitializer = () => {\r\n const { service, id } = useParams();\r\n return (\r\n key.toLowerCase() === service\r\n )?.[1],\r\n id,\r\n }}\r\n />\r\n );\r\n};\r\n\r\nconst Admin = ({ initializer }) => {\r\n const [activeTab, setActiveTab] = useState(\r\n initializer?.service ?? ADMIN_TABS.USERS\r\n );\r\n const [filters, setFilters] = useState(DEFAULT_FILTERS);\r\n\r\n useEffect(() => {\r\n if (initializer) {\r\n window.history.replaceState(undefined, \"\", MODULES.ADMIN);\r\n }\r\n }, [initializer]);\r\n\r\n const history = useHistory();\r\n const hash = history.location.hash;\r\n useEffect(() => {\r\n if (hash) {\r\n const hashId = hash.substring(1).toUpperCase();\r\n const hashTab = Object.values(ADMIN_TABS).find(\r\n (tab) => tab.id.toUpperCase() === hashId\r\n );\r\n if (hashTab) {\r\n setActiveTab(hashTab);\r\n }\r\n }\r\n }, [hash]);\r\n\r\n const loginUser = useSelector((state) => state.global.data.loginUser);\r\n useEffect(() => {\r\n // If loginUser is null, that means page is still loading,\r\n // So we don't want to redirect user in such case\r\n // (Otherwise page refreshing would redirect to dashboard for example)\r\n if (loginUser !== null && !loginUser.isInternal) {\r\n history.replace(\"/\");\r\n }\r\n }, [loginUser, history]);\r\n\r\n return (\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n setActiveTab(\r\n Object.values(ADMIN_TABS).find((tab) => tab.id === selectedId)\r\n )\r\n }\r\n >\r\n {Object.values(ADMIN_TABS).map((tab) => (\r\n \r\n \r\n  {tab.label}\r\n \r\n }\r\n />\r\n ))}\r\n \r\n
\r\n
\r\n \r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n {activeTab.id === ADMIN_TABS.USERS.id && (\r\n \r\n )}\r\n {activeTab.id === ADMIN_TABS.COMPANIES.id && (\r\n \r\n )}\r\n {activeTab.id === ADMIN_TABS.ENGAGEMENTS.id && (\r\n \r\n \r\n \r\n )}\r\n {activeTab.id === ADMIN_TABS.ENTITIES.id && (\r\n \r\n )}\r\n {activeTab.id === ADMIN_TABS.SERVICES.id && (\r\n \r\n )}\r\n {activeTab.id === ADMIN_TABS.SERVICES_GROUPS.id && (\r\n \r\n )}\r\n {process.env.REACT_APP_ENABLE_SERVICE_TERRITORIES ===\r\n \"true\" && (\r\n <>\r\n {activeTab.id === ADMIN_TABS.TERRITORIES.id && (\r\n \r\n )}\r\n \r\n )}\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n );\r\n};\r\n\r\nexport default Admin;\r\n","export const SERVICE_STEPS = {\r\n STRUCTURING: 1,\r\n SETUP: 2,\r\n DISTRIBUTION: 3,\r\n OPERATION: 4,\r\n};\r\n","import \"./expanded.scss\";\r\n\r\nimport classnames from \"classnames\";\r\n\r\nconst Expanded = ({ isExpanded }) => (\r\n \r\n);\r\n\r\nexport default Expanded;\r\n","import \"./LoadingComponent.scss\";\r\n\r\nconst LoadingComponent = () => {\r\n return (\r\n
\r\n
\r\n
Loading data...
\r\n
\r\n );\r\n};\r\n\r\nexport default LoadingComponent;\r\n","import \"./table.scss\";\r\n\r\nimport { Table } from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport { forwardRef } from \"react\";\r\n\r\nimport ImageTitle from \"../ImageTitle\";\r\nimport { Expanded, LoadingComponent } from \"./\";\r\n\r\nexport const computeExpandedRows = (expanded) => {\r\n return Object.keys(expanded)\r\n .filter((expandedIndex) => expanded[expandedIndex] !== false)\r\n .map(Number);\r\n};\r\n\r\nconst PWCTable = forwardRef(\r\n (\r\n {\r\n className,\r\n expanded,\r\n onExpandedChange,\r\n getTrProps: trProps,\r\n SubComponent,\r\n pivotBy,\r\n loading = false,\r\n ...tableProps\r\n },\r\n ref\r\n ) => {\r\n return (\r\n \r\n !loading ? :
\r\n }\r\n LoadingComponent={() => loading && }\r\n expanded={expanded}\r\n onExpandedChange={onExpandedChange}\r\n pivotBy={pivotBy}\r\n ExpanderComponent={({ isExpanded }) => (\r\n \r\n )}\r\n SubComponent={SubComponent}\r\n getTheadProps={() => {\r\n return {\r\n className: classnames(\r\n SubComponent && \"thead-subcomponent\",\r\n pivotBy && pivotBy.length && \"expandable-header\"\r\n ),\r\n };\r\n }}\r\n getTrProps={(state, rowInfo, column) => {\r\n const {\r\n onClick,\r\n className: trClassName,\r\n ...getTrProps\r\n } = trProps ? trProps(state, rowInfo, column) : {};\r\n return {\r\n onClick: ({ ...args }) => {\r\n if (!!onExpandedChange) {\r\n // Manage row expansion\r\n if (\r\n SubComponent ||\r\n (rowInfo.subRows && rowInfo.subRows.length)\r\n ) {\r\n const expandedRows = computeExpandedRows(state.expanded);\r\n const rowIsExpanded = expandedRows.includes(\r\n rowInfo.nestingPath[0]\r\n );\r\n\r\n onExpandedChange({\r\n ...state.expanded,\r\n [rowInfo.nestingPath[0]]: rowIsExpanded ? false : {},\r\n });\r\n }\r\n }\r\n\r\n onClick && onClick.apply(this, args);\r\n },\r\n className: classnames(\r\n (SubComponent ||\r\n (rowInfo.subRows && rowInfo.subRows.length > 0)) &&\r\n \"expandable-row\",\r\n (SubComponent ||\r\n (rowInfo.subRows && rowInfo.subRows.length > 0)) &&\r\n computeExpandedRows(expanded).includes(\r\n rowInfo.nestingPath[0]\r\n ) &&\r\n \"expanded-row\",\r\n trClassName\r\n ),\r\n ...getTrProps,\r\n };\r\n }}\r\n {...tableProps}\r\n />\r\n );\r\n }\r\n);\r\n\r\nexport default PWCTable;\r\n","import Actions from \"./actions\";\r\nimport Expanded from \"./expanded\";\r\nimport LoadingComponent from \"./LoadingComponent\";\r\nimport Table from \"./table\";\r\n\r\nexport default Table;\r\nexport { Actions, Expanded, LoadingComponent };\r\n","import deepEqual from \"deep-equal\";\r\nimport { useCallback, useEffect, useRef, useState } from \"react\";\r\n\r\nexport function hasError(errors: FormErrors) {\r\n return typeof errors === \"boolean\"\r\n ? !errors\r\n : !!errors && Object.values(errors).findIndex((value) => !!value) >= 0;\r\n}\r\n\r\ntype Validator = (values: T) => FormErrors;\r\nexport type FormErrors = {\r\n [Property in keyof T]?: FormErrors | string | boolean | null;\r\n};\r\n\r\ninterface Submitable {\r\n values: T;\r\n handleValueChange: (property: keyof T, value: any) => void;\r\n handleFormChange: (form: T) => void;\r\n resetForm: (form?: T) => void;\r\n submitting: boolean;\r\n formErrors: FormErrors;\r\n submit: (\r\n onSubmit: (form: T) => Promise,\r\n onError?: (errors: any) => FormErrors,\r\n resetAfterSuccess?: boolean\r\n ) => void;\r\n}\r\n\r\nexport default function useSubmitable(\r\n defaultValues: T,\r\n validator: Validator\r\n): Submitable {\r\n const immutableDefaultValues = useRef(defaultValues);\r\n\r\n const [touched, setTouched] = useState(false);\r\n const [values, setValues] = useState(defaultValues);\r\n const [submitting, setSubmitting] = useState(false);\r\n const [errors, setErrors] = useState(\r\n Object.keys(immutableDefaultValues.current as any).reduce(\r\n (acc, property) => {\r\n // @ts-ignore\r\n acc[property] = undefined;\r\n return acc;\r\n },\r\n {}\r\n )\r\n );\r\n const [autoValidate, setAutoValidate] = useState(false);\r\n\r\n useEffect(() => {\r\n if (autoValidate) {\r\n setErrors(validator(values));\r\n }\r\n }, [values, validator, autoValidate]);\r\n\r\n useEffect(() => {\r\n setTouched(!deepEqual(immutableDefaultValues.current, values));\r\n }, [values]);\r\n\r\n useEffect(() => {\r\n if (touched) {\r\n const listener = (e: any) => {\r\n e.preventDefault();\r\n e.returnValue = \"\";\r\n };\r\n window.addEventListener(\"beforeunload\", listener);\r\n return () => {\r\n window.removeEventListener(\"beforeunload\", listener);\r\n };\r\n }\r\n }, [touched]);\r\n\r\n const handleValueChange = useCallback((property, value) => {\r\n setValues((values) => {\r\n return {\r\n ...values,\r\n [property]: value,\r\n };\r\n });\r\n }, []);\r\n\r\n const resetForm = useCallback((values) => {\r\n setTouched(false);\r\n setErrors({});\r\n setAutoValidate(false);\r\n setSubmitting(false);\r\n setValues(values || immutableDefaultValues.current);\r\n }, []);\r\n\r\n const submit = useCallback(\r\n (onSubmit, onError, resetAfterSuccess = true) => {\r\n setAutoValidate(true);\r\n\r\n const errors = validator(values);\r\n setErrors(errors);\r\n\r\n if (!hasError(errors)) {\r\n setSubmitting(true);\r\n return onSubmit(values)\r\n .then(() => {\r\n if (resetAfterSuccess) {\r\n resetForm(values);\r\n }\r\n })\r\n .finally(() => {\r\n setTouched(false);\r\n setSubmitting(false);\r\n });\r\n } else if (onError) {\r\n onError(errors);\r\n }\r\n },\r\n [values, validator, resetForm]\r\n );\r\n\r\n return {\r\n values,\r\n handleValueChange,\r\n handleFormChange: setValues,\r\n resetForm,\r\n submitting,\r\n formErrors: errors,\r\n submit,\r\n };\r\n}\r\n","export const localeCompare = (property) => (a, b) => {\r\n let first = a,\r\n second = b;\r\n if (!!property) {\r\n first = a[property];\r\n second = b[property];\r\n }\r\n\r\n return first.trim().localeCompare(second.trim());\r\n};\r\n","import { pollData, pollerCheck404, pollerCheckUndefined } from \"api/apiPoller\";\r\nimport {\r\n IndustryCreateDTO,\r\n IndustryReadDTO,\r\n IndustryUpdateDTO,\r\n LifecycleCreateDTO,\r\n LifecycleReadDTO,\r\n LifecycleUpdateDTO,\r\n PageFieldsUpdateDTO,\r\n PageOptionsUpdateDTO,\r\n PageReadDTO,\r\n ServiceGroupCreateDTO,\r\n ServiceGroupReadDTO,\r\n ServiceGroupUpdateDTO,\r\n ServiceReadDTO,\r\n SubIndustryCreateDTO,\r\n SubIndustryReadDTO,\r\n SubIndustryUpdateDTO,\r\n ValueChainCreateDTO,\r\n ValueChainReadDTO,\r\n ValueChainUpdateDTO,\r\n} from \"api/catalog/__generated__/CatalogueAPI\";\r\nimport { isEqual } from \"lodash\";\r\nimport { localeCompare } from \"utils/localeCompare\";\r\n\r\nimport {\r\n addIndustry,\r\n addLifeCycle,\r\n addServiceGroup,\r\n addSubIndustry,\r\n addTerritory,\r\n addValueChain,\r\n createService,\r\n deleteIndustry,\r\n deleteLifeCycle,\r\n deleteServiceGroup,\r\n deleteSubIndustry,\r\n deleteTerritory,\r\n deleteValueChain,\r\n editIndustry,\r\n editLifeCycle,\r\n editLifeCycleOrder,\r\n editServiceGroup,\r\n editSubIndustry,\r\n editTerritory,\r\n editValueChain,\r\n editValueChainOrder,\r\n getCatalogueHomepageDetails,\r\n getIndustryById,\r\n getLifeCycleById,\r\n getServiceDetails,\r\n getServiceGroupById,\r\n getSubIndustryById,\r\n getTerritoryById,\r\n getValueChainById,\r\n removeService,\r\n updateCatalogueHomepageDetails,\r\n updateCatalogueOptions,\r\n updateDisplayStatus,\r\n updateIsHighlighted,\r\n updateIsNew,\r\n updateService,\r\n} from \"./catalogApi\";\r\nimport { ServiceCreateDTO, ServiceUpdateDTO } from \"./type\";\r\n\r\nexport async function pollCreateService(\r\n service: ServiceCreateDTO\r\n): Promise {\r\n const addedService = await createService(service);\r\n\r\n return await pollData(\r\n () => getServiceDetails(addedService.id),\r\n pollerCheck404,\r\n 0,\r\n addedService\r\n );\r\n}\r\n\r\nexport async function pollUpdateService(\r\n service: ServiceUpdateDTO,\r\n id: string\r\n): Promise {\r\n await updateService(service, id);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const serviceDetails = await getServiceDetails(id);\r\n return compare(serviceDetails, service)\r\n ? resolve(serviceDetails)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n service\r\n );\r\n}\r\n\r\nexport async function pollUpdateIndustry(\r\n id: string,\r\n industry: IndustryUpdateDTO\r\n): Promise {\r\n await editIndustry(id, industry);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const industryDetails = await getIndustryById(id);\r\n return compareFilter(industryDetails, industry)\r\n ? resolve(industryDetails)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n industry\r\n );\r\n}\r\n\r\nexport async function pollAddIndustry(\r\n industry: IndustryCreateDTO\r\n): Promise {\r\n const addedIndustry = await addIndustry(industry);\r\n\r\n return await pollData(\r\n () => getIndustryById(addedIndustry.id),\r\n pollerCheck404,\r\n 0,\r\n addedIndustry\r\n );\r\n}\r\n\r\nexport async function pollAddLifeCycle(\r\n lifecycle: LifecycleCreateDTO\r\n): Promise {\r\n const addedLifeCycle = await addLifeCycle(lifecycle);\r\n\r\n return await pollData(\r\n () => getLifeCycleById(addedLifeCycle.id),\r\n pollerCheck404,\r\n 0,\r\n addedLifeCycle\r\n );\r\n}\r\n\r\nexport async function pollRemoveLifeCycle(id: string): Promise {\r\n await deleteLifeCycle(id);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getLifeCycleById(id)\r\n .then(reject)\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve(undefined);\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n () => true\r\n );\r\n}\r\n\r\nexport async function pollUpdateLifeCycle(\r\n id: string,\r\n lifeCycle: LifecycleUpdateDTO\r\n): Promise {\r\n await editLifeCycle(id, lifeCycle);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const lifeCycleDetails = await getLifeCycleById(id);\r\n return compareFilter(lifeCycleDetails, lifeCycle)\r\n ? resolve(lifeCycleDetails)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n lifeCycle\r\n );\r\n}\r\n\r\nexport async function pollUpdateLifeCycleOrder(\r\n id: string,\r\n order: number\r\n): Promise {\r\n await editLifeCycleOrder(id, order);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const lifeCycleDetails = await getLifeCycleById(id);\r\n return order === lifeCycleDetails.order ? resolve(order) : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n order\r\n );\r\n}\r\n\r\nexport async function pollAddValueChain(\r\n valueChain: ValueChainCreateDTO\r\n): Promise {\r\n const addedValueChain = await addValueChain(valueChain);\r\n\r\n return await pollData(\r\n () => getValueChainById(addedValueChain.id),\r\n pollerCheck404,\r\n 0,\r\n addedValueChain\r\n );\r\n}\r\n\r\nexport async function pollRemoveValueChain(id: string): Promise {\r\n await deleteValueChain(id);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getValueChainById(id)\r\n .then(reject)\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve(undefined);\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n () => true\r\n );\r\n}\r\n\r\nexport async function pollUpdateValueChain(\r\n id: string,\r\n valueChain: ValueChainUpdateDTO\r\n): Promise {\r\n await editValueChain(id, valueChain);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const valueChainDetails = await getValueChainById(id);\r\n return compareFilter(valueChainDetails, valueChain)\r\n ? resolve(valueChainDetails)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n valueChain\r\n );\r\n}\r\n\r\nexport async function pollUpdateValueChainOrder(\r\n id: string,\r\n order: number\r\n): Promise {\r\n await editValueChainOrder(id, order);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const valueChainDetails = await getValueChainById(id);\r\n return valueChainDetails.order === order ? resolve(order) : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n order\r\n );\r\n}\r\n\r\nexport async function pollUpdateSubIndustry(\r\n parentId: string,\r\n id: string,\r\n industry: SubIndustryUpdateDTO\r\n): Promise {\r\n await editSubIndustry(parentId, id, industry);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const industryDetails = await getSubIndustryById(parentId, id);\r\n return compareFilter(industryDetails, industry)\r\n ? resolve(industryDetails)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n industry\r\n );\r\n}\r\n\r\nexport async function pollAddSubIndustry(\r\n parentId: string,\r\n industry: SubIndustryCreateDTO\r\n): Promise {\r\n const addedIndustry = await addSubIndustry(parentId, industry);\r\n\r\n return await pollData(\r\n () => getSubIndustryById(parentId, addedIndustry.id),\r\n pollerCheck404,\r\n 0,\r\n addedIndustry\r\n );\r\n}\r\n\r\nexport async function pollRemoveIndustry(id: string): Promise {\r\n await deleteIndustry(id);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getIndustryById(id)\r\n .then(reject)\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve(undefined);\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n () => true\r\n );\r\n}\r\n\r\nexport async function pollRemoveSubIndustry(\r\n parentId: string,\r\n id: string\r\n): Promise {\r\n await deleteSubIndustry(parentId, id);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getSubIndustryById(parentId, id)\r\n .then(reject)\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve(undefined);\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n () => true\r\n );\r\n}\r\n\r\nexport async function pollRemoveService(id: string): Promise {\r\n await removeService(id);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getServiceDetails(id)\r\n .then(reject)\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve(undefined);\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n () => true\r\n );\r\n}\r\n\r\nexport async function pollUpdateDisplayStatus(\r\n serviceId: string,\r\n live: boolean\r\n): Promise {\r\n await updateDisplayStatus(serviceId, live);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getServiceDetails(serviceId).then((serviceDetails) =>\r\n serviceDetails.live === live ? resolve(undefined) : reject()\r\n );\r\n }),\r\n pollerCheckUndefined\r\n );\r\n}\r\n\r\nexport async function pollUpdateIsNew(\r\n serviceId: string,\r\n isNew: boolean\r\n): Promise {\r\n await updateIsNew(serviceId, isNew);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getServiceDetails(serviceId).then((serviceDetails) =>\r\n serviceDetails.isNew === isNew ? resolve(undefined) : reject()\r\n );\r\n }),\r\n pollerCheckUndefined\r\n );\r\n}\r\n\r\nexport async function pollAddServiceGroup(serviceGroup: ServiceGroupCreateDTO) {\r\n const addedServiceGroup = await addServiceGroup(serviceGroup);\r\n return await pollData(\r\n () => getServiceGroupById(addedServiceGroup.id),\r\n pollerCheck404,\r\n 0,\r\n addedServiceGroup\r\n );\r\n}\r\n\r\nexport async function pollEditServiceGroup(\r\n id: string,\r\n serviceGroup: ServiceGroupUpdateDTO\r\n) {\r\n await editServiceGroup(id, serviceGroup);\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const serviceGroupDetails = await getServiceGroupById(id);\r\n return compareServiceGroup(serviceGroup, serviceGroupDetails)\r\n ? resolve(serviceGroupDetails)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n serviceGroup\r\n );\r\n}\r\n\r\nexport async function pollDeleteServiceGroup(id: string) {\r\n await deleteServiceGroup(id);\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getServiceGroupById(id)\r\n .then(reject)\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve(undefined);\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n () => true\r\n );\r\n}\r\n\r\nexport async function pollAddTerritory(territory: any) {\r\n const addedServiceGroup = await addTerritory(territory);\r\n return await pollData(\r\n () => getTerritoryById(addedServiceGroup.id),\r\n pollerCheck404,\r\n 0,\r\n addedServiceGroup\r\n );\r\n}\r\n\r\nexport async function pollEditTerritory(id: string, territory: any) {\r\n await editTerritory(id, territory);\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const territoryDetails = await getTerritoryById(id);\r\n return territoryDetails.name !== territory.name\r\n ? reject()\r\n : resolve(territoryDetails);\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n territory\r\n );\r\n}\r\n\r\nexport async function pollDeleteTerritory(id: string) {\r\n await deleteTerritory(id);\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getTerritoryById(id)\r\n .then(reject)\r\n .catch((error) => {\r\n if (pollerCheck404(error)) {\r\n return resolve(undefined);\r\n }\r\n return reject(error);\r\n });\r\n }),\r\n () => true\r\n );\r\n}\r\n\r\nexport async function pollUpdateIsHighlighted(\r\n serviceId: string,\r\n isHighlighted: boolean\r\n): Promise {\r\n await updateIsHighlighted(serviceId, isHighlighted);\r\n\r\n return pollData(\r\n () =>\r\n new Promise((resolve, reject) => {\r\n getServiceDetails(serviceId).then((serviceDetails) =>\r\n serviceDetails.isHighlighted === isHighlighted\r\n ? resolve(undefined)\r\n : reject()\r\n );\r\n }),\r\n pollerCheckUndefined\r\n );\r\n}\r\n\r\nfunction compare(service: ServiceReadDTO, modified: ServiceUpdateDTO) {\r\n return (\r\n JSON.stringify([\r\n service.applications?.sort(localeCompare(\"name\")).map((app) => ({\r\n name: app.name,\r\n link: app.link,\r\n ppid: app.itContact?.ppid || null,\r\n })) ?? [],\r\n service.description?.replace(/[^a-zA-Z0-9]/g, \"\"),\r\n service.live,\r\n service.name,\r\n service.responsibles?.map((p) => p.ppid).sort() ?? [],\r\n service.team?.map((p) => p.ppid).sort() ?? [],\r\n service.videoLink,\r\n service.itContact?.ppid || null,\r\n service.organizations && service.organizations.length > 0\r\n ? service.organizations.sort((a, b) => a.localeCompare(b))\r\n : [],\r\n service.isNew,\r\n service.isPSA,\r\n service.isPSF,\r\n service.isHighlighted,\r\n service.smallDescription?.replace(/[^a-zA-Z0-9]/g, \"\"),\r\n service.valueChains,\r\n service.lifeCycles,\r\n service.relatedServices?.map((service) => service.id).sort() ?? [],\r\n service.mainAddedValue,\r\n service.secondaryAddedValue,\r\n service.geographicalInformation,\r\n service.targetProfile,\r\n service.availableApplication,\r\n service.deliverable,\r\n service.industries?.sort((a, b) => a.localeCompare(b)) ?? [],\r\n service.serviceGroupId,\r\n service.viewers?.map((viewer) => viewer.ppid).sort() ?? [],\r\n service.ukViewers?.map((viewer) => viewer.ppid).sort() ?? [],\r\n service.frViewers?.map((viewer) => viewer.ppid).sort() ?? [],\r\n ]) ===\r\n JSON.stringify([\r\n modified.Applications?.sort(localeCompare(\"name\")).map((app) => ({\r\n name: app.name,\r\n link: app.link,\r\n ppid: app.itContactPpid,\r\n })) ?? [],\r\n modified.Description?.replace(/[^a-zA-Z0-9]/g, \"\") ?? null,\r\n modified.Live ?? false,\r\n modified.Name ?? null,\r\n modified.ResponsiblesPpids?.sort() ?? [],\r\n modified.TeamPpids?.sort() ?? [],\r\n modified.VideoLink ?? null,\r\n modified.ItContactPpid || null,\r\n modified.Organizations && modified.Organizations.length > 0\r\n ? modified.Organizations.sort((a, b) => a.localeCompare(b))\r\n : [],\r\n modified.IsNew ?? false,\r\n modified.IsPSA ?? false,\r\n modified.IsPSF ?? false,\r\n modified.IsHighlighted ?? false,\r\n modified.SmallDescription?.replace(/[^a-zA-Z0-9]/g, \"\") ?? null,\r\n modified.ValueChains ?? null,\r\n modified.LifeCycles ?? null,\r\n modified.RelatedServices?.sort() ?? [],\r\n modified.MainAddedValue ?? null,\r\n modified.SecondaryAddedValue ?? null,\r\n modified.GeographicalInformation ?? null,\r\n modified.TargetProfile ?? null,\r\n modified.AvailableApplication ?? null,\r\n modified.Deliverable ?? null,\r\n modified.Industries?.sort((a, b) => a.localeCompare(b)) ?? [],\r\n modified.ServiceGroupId,\r\n modified.ViewersPpids?.sort() ?? [],\r\n modified.UkViewersPpids?.sort() ?? [],\r\n modified.FrViewersPpids?.sort() ?? [],\r\n ])\r\n );\r\n}\r\n\r\nfunction compareFilter(\r\n industry: { name: string | null },\r\n modified: { name: string | null }\r\n) {\r\n return industry.name === modified.name;\r\n}\r\n\r\nfunction compareServiceGroup(\r\n serviceGroup1: ServiceGroupUpdateDTO,\r\n serviceGroup2: ServiceGroupReadDTO\r\n) {\r\n return isEqual(\r\n [\r\n serviceGroup1.name,\r\n serviceGroup1.smallDescription,\r\n serviceGroup1.lifeCycles,\r\n serviceGroup1.valueChains,\r\n (serviceGroup1.services ?? []).sort(),\r\n ],\r\n [\r\n serviceGroup2.name,\r\n serviceGroup2.smallDescription,\r\n serviceGroup2.lifeCycles,\r\n serviceGroup2.valueChains,\r\n (serviceGroup2.services ?? []).map((service) => service.id).sort(),\r\n ]\r\n );\r\n}\r\n\r\nexport async function pollUpdateHomepage(\r\n modified: PageFieldsUpdateDTO\r\n): Promise {\r\n await updateCatalogueHomepageDetails(modified);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const homepage = await getCatalogueHomepageDetails();\r\n return compareHomepage(homepage, modified)\r\n ? resolve(homepage)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n modified\r\n );\r\n}\r\n\r\nexport async function pollUpdateHomepageFilterFields(\r\n modified: PageOptionsUpdateDTO\r\n): Promise {\r\n await updateCatalogueOptions(modified);\r\n\r\n return await pollData(\r\n () =>\r\n new Promise(async (resolve, reject) => {\r\n const homepage = await getCatalogueHomepageDetails();\r\n return compareHomepageFilterFields(homepage, modified)\r\n ? resolve(homepage)\r\n : reject();\r\n }),\r\n pollerCheckUndefined,\r\n 0,\r\n modified\r\n );\r\n}\r\n\r\nfunction compareHomepage(homepage: PageReadDTO, modified: PageFieldsUpdateDTO) {\r\n return isEqual(\r\n [\r\n homepage.title,\r\n homepage.subtitle,\r\n homepage.description,\r\n homepage.value1Title,\r\n homepage.value1Description,\r\n homepage.value2Title,\r\n homepage.value2Description,\r\n homepage.contacts?.map((contact) => contact.ppid).sort(),\r\n ],\r\n [\r\n modified.title,\r\n modified.subtitle,\r\n modified.description,\r\n modified.value1Title,\r\n modified.value1Description,\r\n modified.value2Title,\r\n modified.value2Description,\r\n modified.contacts?.sort(),\r\n ]\r\n );\r\n}\r\n\r\nfunction compareHomepageFilterFields(\r\n homepage: PageReadDTO,\r\n modified: PageOptionsUpdateDTO\r\n) {\r\n return isEqual(\r\n [homepage.mainFilter, homepage.secondaryFilter, homepage.tertiaryFilter],\r\n [modified.mainFilter, modified.secondaryFilter, modified.tertiaryFilter]\r\n );\r\n}\r\n","import \"./index.scss\";\r\n\r\nimport { FloatingActionButton, Tooltip } from \"appkit-react\";\r\nimport classNames from \"classnames\";\r\nimport ReactDOM from \"react-dom\";\r\n\r\nconst computeBottom = (position) => {\r\n return 18 + (45 + 18) * (position - 1);\r\n};\r\n\r\nconst FAB_PORTAL_DIV = \"fab-portal\";\r\n\r\nconst FloatingActionButtonPortal = ({\r\n kind = \"primary\",\r\n disabled = false,\r\n loading = false,\r\n size = \"sm\",\r\n name,\r\n onClick,\r\n className = \"\",\r\n tooltipClassName = \"\",\r\n tooltip,\r\n position = 1,\r\n right = null,\r\n}) => {\r\n const FAB = (\r\n \r\n \r\n \r\n );\r\n\r\n if (tooltip) {\r\n return ReactDOM.createPortal(\r\n \r\n {FAB}\r\n ,\r\n document.getElementById(FAB_PORTAL_DIV)\r\n );\r\n } else {\r\n return ReactDOM.createPortal(FAB, document.getElementById(FAB_PORTAL_DIV));\r\n }\r\n};\r\n\r\nexport default FloatingActionButtonPortal;\r\n","export const MIME_PDF = \"application/pdf\";\r\nexport const MIME_DOC = \"application/msword\";\r\nexport const MIME_DOCX =\r\n \"application/vnd.openxmlformats-officedocument.wordprocessingml.document\";\r\nexport const MIME_XLS = \"application/vnd.ms-excel\";\r\nexport const MIME_XLSX =\r\n \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\";\r\nexport const MIME_PPT = \"application/vnd.ms-powerpoint\";\r\nexport const MIME_PPTX =\r\n \"application/vnd.openxmlformats-officedocument.presentationml.presentation\";\r\nexport const MIME_PNG = \"image/png\";\r\nexport const MIME_JPEG = \"image/jpeg\";\r\n","import \"./index.scss\";\r\n\r\nimport {\r\n Badge,\r\n Button,\r\n ModalBody,\r\n ModalFooter,\r\n ModalHeader,\r\n} from \"appkit-react\";\r\nimport classnames from \"classnames\";\r\nimport ResizableAppkitModal from \"components/ResizableAppkitModal\";\r\nimport { useState } from \"react\";\r\n\r\nconst DeleteModal = ({\r\n children,\r\n className,\r\n onConfirm,\r\n onClose,\r\n buttonLabel = \"Delete\",\r\n title = \"Are you sure ?\",\r\n ...modalProps\r\n}) => {\r\n const [submitting, setSubmitting] = useState(false);\r\n\r\n const handleConfirm = async () => {\r\n setSubmitting(true);\r\n await onConfirm();\r\n setSubmitting(false);\r\n onClose();\r\n };\r\n\r\n return (\r\n \r\n \r\n WARNING\r\n {title}\r\n \r\n {children}\r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default DeleteModal;\r\n","const OID_CONFIGURATION = {\r\n client_id: \"spa\",\r\n redirect_uri: `${window.location.origin}${process.env.REACT_APP_OID_REDIRECT_URI_SUFFIX}`,\r\n response_type: \"id_token token\",\r\n post_logout_redirect_uri: `${window.location.origin}${process.env.REACT_APP_OID_POST_LOGOUT_REDIRECT_URI_SUFFIX}`,\r\n scope: \"openid offline_access\",\r\n authority: process.env.REACT_APP_OID_AUTHORITY,\r\n silent_redirect_uri: `${window.location.origin}${process.env.REACT_APP_OID_SILENT_REDIRECT_URI_SUFFIX}`,\r\n automaticSilentRenew: true,\r\n loadUserInfo: true,\r\n ...(process.env.REACT_APP_AUTOMATIC_SSO_REDIRECT === \"true\" && {\r\n acr_values: \"idp:openAm\",\r\n }),\r\n};\r\n\r\nexport const DEFAULT_OIDC_KEY = `oidc.user:${OID_CONFIGURATION.authority}:${OID_CONFIGURATION.client_id}`;\r\n\r\nexport default OID_CONFIGURATION;\r\n"],"sourceRoot":""}