From 7ec54cb56257d63188b01042fc72beeba8f1702e Mon Sep 17 00:00:00 2001 From: JordenReuter <149687553+JordenReuter@users.noreply.github.com> Date: Tue, 9 Jan 2024 10:35:40 +0100 Subject: [PATCH] added bff (#14) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * added bff * feat: fixed basepath and import/export and indexhtml * Update index.html * fix: helm configuration, changed role names and set default port to 4200 * fix: harmonize sonar config * fix: correct ui test config and import translations --------- Co-authored-by: Henry Taeschner Co-authored-by: Henry Täschner <129834483+HenryT-CG@users.noreply.github.com> --- angular.json | 4 +- helm/Chart.yaml | 2 +- helm/microfrontend.json | 8 +- helm/permissions.csv | 2 +- helm/values.yaml | 22 +- package.json | 20 +- proxy.conf.js | 6 +- src/app/generated/.openapi-generator/FILES | 122 +- src/app/generated/.openapi-generator/VERSION | 2 +- src/app/generated/README.md | 235 +++- src/app/generated/api.module.ts | 57 +- .../api/adminUserInternal.service.ts | 539 -------- src/app/generated/api/api.ts | 53 +- src/app/generated/api/avatarV1.service.ts | 368 ----- src/app/generated/api/feedbackV1.service.ts | 179 --- src/app/generated/api/imageV1.service.ts | 376 ------ .../api/menuItemsInternal.service.ts | 887 ------------ ...crofrontendRegistrationInternal.service.ts | 279 ---- .../generated/api/microfrontendV1.service.ts | 502 ------- .../api/portalImportRequestV1.service.ts | 185 --- .../generated/api/portalInternal.service.ts | 580 -------- .../generated/api/portalItemsV1.service.ts | 189 --- src/app/generated/api/portalLegacy.service.ts | 273 ---- src/app/generated/api/portalV1.service.ts | 947 ------------- .../generated/api/supportTicketV1.service.ts | 179 --- src/app/generated/api/themes.service.ts | 1183 ++++++++++------- src/app/generated/api/userInfoV1.service.ts | 262 ---- .../generated/api/userProfileV1.service.ts | 952 ------------- src/app/generated/configuration.ts | 248 ++-- src/app/generated/encoder.ts | 26 +- src/app/generated/index.ts | 11 +- src/app/generated/model/accountSettingsDTO.ts | 29 - ...ccountSettingsDTOLayoutAndThemeSettings.ts | 19 - ...accountSettingsDTOLocaleAndTimeSettings.ts | 23 - .../accountSettingsDTOPrivacySettings.ts | 19 - .../generated/model/accountSettingsDTOv1.ts | 27 - ...ountSettingsDTOv1LayoutAndThemeSettings.ts | 19 - ...countSettingsDTOv1LocaleAndTimeSettings.ts | 23 - .../accountSettingsDTOv1PrivacySettings.ts | 19 - src/app/generated/model/colorScheme.ts | 17 - src/app/generated/model/colorSchemeV1.ts | 17 - .../model/createMicrofrontendDTOv1.ts | 26 - src/app/generated/model/createPortalDTO.ts | 40 - src/app/generated/model/createThemeDTO.ts | 31 - src/app/generated/model/createThemeRequest.ts | 18 + .../generated/model/createThemeResponse.ts | 18 + src/app/generated/model/errorResponseDTO.ts | 17 - src/app/generated/model/eximTheme.ts | 24 + src/app/generated/model/exportThemeRequest.ts | 17 + src/app/generated/model/feedbackDTOv1.ts | 18 - src/app/generated/model/getThemeResponse.ts | 20 + src/app/generated/model/getThemesResponse.ts | 22 + src/app/generated/model/imageInfoDTOv1.ts | 27 - src/app/generated/model/importRequestDTOv1.ts | 27 - .../model/importRequestDTOv1Portal.ts | 43 - .../importRequestDTOv1ThemeImportData.ts | 26 - .../generated/model/importThemeResponse.ts | 22 + .../model/importThemeResponseStatus.ts | 19 + src/app/generated/model/layoutAndThemeDTO.ts | 18 - .../generated/model/layoutAndThemeDTOv1.ts | 18 - .../model/localeAndTimeSettingsDTO.ts | 22 - .../model/localeAndTimeSettingsDTOv1.ts | 22 - src/app/generated/model/membershipDTO.ts | 17 - src/app/generated/model/membershipRolesDTO.ts | 17 - src/app/generated/model/menuItemDetailsDTO.ts | 35 - src/app/generated/model/menuItemListDTO.ts | 35 - .../generated/model/menuItemStructureDTO.ts | 34 - .../generated/model/menuItemStructureDTOv1.ts | 34 - .../model/menuItemStructureDtoLegacy.ts | 36 - src/app/generated/model/menuMode.ts | 19 - src/app/generated/model/menuModeV1.ts | 19 - .../generated/model/menuStructureListDTO.ts | 16 - src/app/generated/model/microfrontendDTOv1.ts | 34 - .../model/microfrontendRegistrationDTO.ts | 23 - .../model/microfrontendRegistrationDTOv1.ts | 22 - .../microfrontendRegistrationInputDTO.ts | 22 - .../microfrontendRegistrationRequestDTO.ts | 16 - src/app/generated/model/models.ts | 106 +- src/app/generated/model/moduleTypeV1.ts | 16 - src/app/generated/model/pagingResponse.ts | 20 + src/app/generated/model/permissionDTO.ts | 19 - src/app/generated/model/portalAddressDTO.ts | 25 - src/app/generated/model/portalAddressDTOv1.ts | 19 - src/app/generated/model/portalDTO.ts | 40 - src/app/generated/model/portalDTOv1.ts | 36 - .../generated/model/portalIdentifierDTO.ts | 17 - .../generated/model/portalIdentifierDTOv1.ts | 16 - src/app/generated/model/portalImportDTOv1.ts | 45 - src/app/generated/model/portalMenuItemDTO.ts | 36 - .../generated/model/portalMenuItemDTOv1.ts | 36 - .../model/portalSearchCriteriaDTO.ts | 19 - src/app/generated/model/preferencesDTO.ts | 22 - src/app/generated/model/preferencesDTOv1.ts | 43 - src/app/generated/model/privacySettingsDTO.ts | 18 - .../generated/model/privacySettingsDTOv1.ts | 18 - .../model/problemDetailInvalidParam.ts | 18 + src/app/generated/model/problemDetailParam.ts | 18 + .../generated/model/problemDetailResponse.ts | 22 + src/app/generated/model/resetPasswordDTOv1.ts | 15 - src/app/generated/model/restException.ts | 19 - src/app/generated/model/restExceptionDTO.ts | 18 - src/app/generated/model/scope.ts | 17 - src/app/generated/model/scopeV1.ts | 17 - src/app/generated/model/searchItemDTOv1.ts | 23 - src/app/generated/model/searchItemTypeV1.ts | 15 - .../generated/model/searchTemplateDTOv1.ts | 28 - .../model/searchTemplateSearchCriteria.ts | 18 - src/app/generated/model/searchThemeRequest.ts | 19 + .../generated/model/searchThemeResponse.ts | 22 + src/app/generated/model/status.ts | 54 - src/app/generated/model/subjectLinkDTO.ts | 22 - src/app/generated/model/subjectLinkDTOv1.ts | 16 - src/app/generated/model/supportTicketDTOv1.ts | 18 - src/app/generated/model/theme.ts | 31 + src/app/generated/model/themeDTO.ts | 31 - src/app/generated/model/themeDTOv1.ts | 25 - src/app/generated/model/themeSnapshot.ts | 23 + src/app/generated/model/themeUpdateCreate.ts | 30 + .../model/updateMicrofrontend200Response.ts | 34 - .../model/updateMicrofrontendDTOv1.ts | 26 - src/app/generated/model/updatePortalDTO.ts | 40 - src/app/generated/model/updateThemeDTO.ts | 31 - src/app/generated/model/updateThemeRequest.ts | 18 + .../generated/model/updateThemeResponse.ts | 18 + src/app/generated/model/userInfoDTOv1.ts | 18 - .../generated/model/userPersonAddressDTO.ts | 25 - .../generated/model/userPersonAddressDTOv1.ts | 25 - src/app/generated/model/userPersonDTO.ts | 28 - src/app/generated/model/userPersonDTOv1.ts | 28 - src/app/generated/model/userPersonPhoneDTO.ts | 22 - .../generated/model/userPersonPhoneDTOv1.ts | 22 - src/app/generated/model/userProfileDTO.ts | 40 - .../model/userProfileDTOAccountSettings.ts | 30 - src/app/generated/model/userProfileDTOv1.ts | 42 - .../model/userProfileDTOv1AccountSettings.ts | 28 - .../generated/model/userProfileDTOv1Avatar.ts | 28 - .../generated/model/validationConstraint.ts | 18 + src/app/generated/model/workspace.ts | 18 + src/app/generated/param.ts | 69 + src/app/generated/variables.ts | 12 +- .../theme-designer.component.ts | 50 +- .../theme-detail/theme-detail.component.ts | 42 +- .../theme-intern/theme-intern.component.ts | 4 +- .../theme-import/theme-import.component.html | 6 +- .../theme-search/theme-search.component.html | 2 +- .../theme-search/theme-search.component.ts | 6 +- src/assets/api/themes-bff-api.yaml | 516 +++++++ src/assets/i18n/de.json | 3 +- src/assets/i18n/en.json | 3 +- src/environments/environment.prod.ts | 4 +- src/environments/environment.ts | 2 +- 151 files changed, 2222 insertions(+), 9890 deletions(-) delete mode 100644 src/app/generated/api/adminUserInternal.service.ts delete mode 100644 src/app/generated/api/avatarV1.service.ts delete mode 100644 src/app/generated/api/feedbackV1.service.ts delete mode 100644 src/app/generated/api/imageV1.service.ts delete mode 100644 src/app/generated/api/menuItemsInternal.service.ts delete mode 100644 src/app/generated/api/microfrontendRegistrationInternal.service.ts delete mode 100644 src/app/generated/api/microfrontendV1.service.ts delete mode 100644 src/app/generated/api/portalImportRequestV1.service.ts delete mode 100644 src/app/generated/api/portalInternal.service.ts delete mode 100644 src/app/generated/api/portalItemsV1.service.ts delete mode 100644 src/app/generated/api/portalLegacy.service.ts delete mode 100644 src/app/generated/api/portalV1.service.ts delete mode 100644 src/app/generated/api/supportTicketV1.service.ts delete mode 100644 src/app/generated/api/userInfoV1.service.ts delete mode 100644 src/app/generated/api/userProfileV1.service.ts delete mode 100644 src/app/generated/model/accountSettingsDTO.ts delete mode 100644 src/app/generated/model/accountSettingsDTOLayoutAndThemeSettings.ts delete mode 100644 src/app/generated/model/accountSettingsDTOLocaleAndTimeSettings.ts delete mode 100644 src/app/generated/model/accountSettingsDTOPrivacySettings.ts delete mode 100644 src/app/generated/model/accountSettingsDTOv1.ts delete mode 100644 src/app/generated/model/accountSettingsDTOv1LayoutAndThemeSettings.ts delete mode 100644 src/app/generated/model/accountSettingsDTOv1LocaleAndTimeSettings.ts delete mode 100644 src/app/generated/model/accountSettingsDTOv1PrivacySettings.ts delete mode 100644 src/app/generated/model/colorScheme.ts delete mode 100644 src/app/generated/model/colorSchemeV1.ts delete mode 100644 src/app/generated/model/createMicrofrontendDTOv1.ts delete mode 100644 src/app/generated/model/createPortalDTO.ts delete mode 100644 src/app/generated/model/createThemeDTO.ts create mode 100644 src/app/generated/model/createThemeRequest.ts create mode 100644 src/app/generated/model/createThemeResponse.ts delete mode 100644 src/app/generated/model/errorResponseDTO.ts create mode 100644 src/app/generated/model/eximTheme.ts create mode 100644 src/app/generated/model/exportThemeRequest.ts delete mode 100644 src/app/generated/model/feedbackDTOv1.ts create mode 100644 src/app/generated/model/getThemeResponse.ts create mode 100644 src/app/generated/model/getThemesResponse.ts delete mode 100644 src/app/generated/model/imageInfoDTOv1.ts delete mode 100644 src/app/generated/model/importRequestDTOv1.ts delete mode 100644 src/app/generated/model/importRequestDTOv1Portal.ts delete mode 100644 src/app/generated/model/importRequestDTOv1ThemeImportData.ts create mode 100644 src/app/generated/model/importThemeResponse.ts create mode 100644 src/app/generated/model/importThemeResponseStatus.ts delete mode 100644 src/app/generated/model/layoutAndThemeDTO.ts delete mode 100644 src/app/generated/model/layoutAndThemeDTOv1.ts delete mode 100644 src/app/generated/model/localeAndTimeSettingsDTO.ts delete mode 100644 src/app/generated/model/localeAndTimeSettingsDTOv1.ts delete mode 100644 src/app/generated/model/membershipDTO.ts delete mode 100644 src/app/generated/model/membershipRolesDTO.ts delete mode 100644 src/app/generated/model/menuItemDetailsDTO.ts delete mode 100644 src/app/generated/model/menuItemListDTO.ts delete mode 100644 src/app/generated/model/menuItemStructureDTO.ts delete mode 100644 src/app/generated/model/menuItemStructureDTOv1.ts delete mode 100644 src/app/generated/model/menuItemStructureDtoLegacy.ts delete mode 100644 src/app/generated/model/menuMode.ts delete mode 100644 src/app/generated/model/menuModeV1.ts delete mode 100644 src/app/generated/model/menuStructureListDTO.ts delete mode 100644 src/app/generated/model/microfrontendDTOv1.ts delete mode 100644 src/app/generated/model/microfrontendRegistrationDTO.ts delete mode 100644 src/app/generated/model/microfrontendRegistrationDTOv1.ts delete mode 100644 src/app/generated/model/microfrontendRegistrationInputDTO.ts delete mode 100644 src/app/generated/model/microfrontendRegistrationRequestDTO.ts delete mode 100644 src/app/generated/model/moduleTypeV1.ts create mode 100644 src/app/generated/model/pagingResponse.ts delete mode 100644 src/app/generated/model/permissionDTO.ts delete mode 100644 src/app/generated/model/portalAddressDTO.ts delete mode 100644 src/app/generated/model/portalAddressDTOv1.ts delete mode 100644 src/app/generated/model/portalDTO.ts delete mode 100644 src/app/generated/model/portalDTOv1.ts delete mode 100644 src/app/generated/model/portalIdentifierDTO.ts delete mode 100644 src/app/generated/model/portalIdentifierDTOv1.ts delete mode 100644 src/app/generated/model/portalImportDTOv1.ts delete mode 100644 src/app/generated/model/portalMenuItemDTO.ts delete mode 100644 src/app/generated/model/portalMenuItemDTOv1.ts delete mode 100644 src/app/generated/model/portalSearchCriteriaDTO.ts delete mode 100644 src/app/generated/model/preferencesDTO.ts delete mode 100644 src/app/generated/model/preferencesDTOv1.ts delete mode 100644 src/app/generated/model/privacySettingsDTO.ts delete mode 100644 src/app/generated/model/privacySettingsDTOv1.ts create mode 100644 src/app/generated/model/problemDetailInvalidParam.ts create mode 100644 src/app/generated/model/problemDetailParam.ts create mode 100644 src/app/generated/model/problemDetailResponse.ts delete mode 100644 src/app/generated/model/resetPasswordDTOv1.ts delete mode 100644 src/app/generated/model/restException.ts delete mode 100644 src/app/generated/model/restExceptionDTO.ts delete mode 100644 src/app/generated/model/scope.ts delete mode 100644 src/app/generated/model/scopeV1.ts delete mode 100644 src/app/generated/model/searchItemDTOv1.ts delete mode 100644 src/app/generated/model/searchItemTypeV1.ts delete mode 100644 src/app/generated/model/searchTemplateDTOv1.ts delete mode 100644 src/app/generated/model/searchTemplateSearchCriteria.ts create mode 100644 src/app/generated/model/searchThemeRequest.ts create mode 100644 src/app/generated/model/searchThemeResponse.ts delete mode 100644 src/app/generated/model/status.ts delete mode 100644 src/app/generated/model/subjectLinkDTO.ts delete mode 100644 src/app/generated/model/subjectLinkDTOv1.ts delete mode 100644 src/app/generated/model/supportTicketDTOv1.ts create mode 100644 src/app/generated/model/theme.ts delete mode 100644 src/app/generated/model/themeDTO.ts delete mode 100644 src/app/generated/model/themeDTOv1.ts create mode 100644 src/app/generated/model/themeSnapshot.ts create mode 100644 src/app/generated/model/themeUpdateCreate.ts delete mode 100644 src/app/generated/model/updateMicrofrontend200Response.ts delete mode 100644 src/app/generated/model/updateMicrofrontendDTOv1.ts delete mode 100644 src/app/generated/model/updatePortalDTO.ts delete mode 100644 src/app/generated/model/updateThemeDTO.ts create mode 100644 src/app/generated/model/updateThemeRequest.ts create mode 100644 src/app/generated/model/updateThemeResponse.ts delete mode 100644 src/app/generated/model/userInfoDTOv1.ts delete mode 100644 src/app/generated/model/userPersonAddressDTO.ts delete mode 100644 src/app/generated/model/userPersonAddressDTOv1.ts delete mode 100644 src/app/generated/model/userPersonDTO.ts delete mode 100644 src/app/generated/model/userPersonDTOv1.ts delete mode 100644 src/app/generated/model/userPersonPhoneDTO.ts delete mode 100644 src/app/generated/model/userPersonPhoneDTOv1.ts delete mode 100644 src/app/generated/model/userProfileDTO.ts delete mode 100644 src/app/generated/model/userProfileDTOAccountSettings.ts delete mode 100644 src/app/generated/model/userProfileDTOv1.ts delete mode 100644 src/app/generated/model/userProfileDTOv1AccountSettings.ts delete mode 100644 src/app/generated/model/userProfileDTOv1Avatar.ts create mode 100644 src/app/generated/model/validationConstraint.ts create mode 100644 src/app/generated/model/workspace.ts create mode 100644 src/app/generated/param.ts create mode 100644 src/assets/api/themes-bff-api.yaml diff --git a/angular.json b/angular.json index 44f0b7c..f165add 100644 --- a/angular.json +++ b/angular.json @@ -77,8 +77,8 @@ "builder": "ngx-build-plus:dev-server", "options": { "browserTarget": "onecx-theme-ui:build", - "port": 5020, - "publicHost": "http://localhost:5020", + "port": 4200, + "publicHost": "http://localhost:4200", "extraWebpackConfig": "webpack.config.js", "proxyConfig": "proxy.conf.js" }, diff --git a/helm/Chart.yaml b/helm/Chart.yaml index 543c61d..d98de57 100644 --- a/helm/Chart.yaml +++ b/helm/Chart.yaml @@ -1,7 +1,7 @@ apiVersion: v2 name: onecx-theme-ui version: 0.0.0 -description: Onecx theme UI. +description: OneCX Theme UI. home: https://github.com/onecx/onecx-theme-ui keywords: - theme diff --git a/helm/microfrontend.json b/helm/microfrontend.json index 27b3fa8..5fe7369 100644 --- a/helm/microfrontend.json +++ b/helm/microfrontend.json @@ -1,5 +1,5 @@ { - "id": "THEME_MFE", + "id": "THEME_UI", {{- if .Values.app.routing.hostName }} "remoteEntry": "https://{{ .Values.app.routing.hostName }}{{ .Values.app.routing.path }}remoteEntry.js", {{- else if .Values.global.hostName }} @@ -11,11 +11,11 @@ {{- else if .Values.global.hostName }} "remoteBaseUrl": "https://{{ .Values.global.hostName }}{{ .Values.app.routing.path }}", {{- end }} - "exposedModule": "./ThemeModule", - "displayName": "ThemeModule", + "exposedModule": "./ThemeMgmtModule", + "displayName": "ThemeMgmtModule", "moduleType": "ANGULAR", "wcTagName": "UPMF", "appVersion": "{{ .Chart.Version }}", - "note": "Theme mgmt module auto import via MF operator", + "note": "Theme Mgmt module auto import via MF operator", "contact": "onecx@1000kit.org" } diff --git a/helm/permissions.csv b/helm/permissions.csv index 385ca74..920d11d 100644 --- a/helm/permissions.csv +++ b/helm/permissions.csv @@ -1,4 +1,4 @@ -PERMISSION NAME;PERMISSION_KEY;portal-mgmt-admin;portal-mgmt-user; +PERMISSION NAME;PERMISSION_KEY;onecx-theme-admin;onecx-theme-user; Theme create;THEME#CREATE;x;; Theme delete;THEME#DELETE;x;; Theme edit;THEME#EDIT;x;; diff --git a/helm/values.yaml b/helm/values.yaml index 32b4cde..8b6806d 100644 --- a/helm/values.yaml +++ b/helm/values.yaml @@ -1,7 +1,7 @@ app: name: ui image: - repository: "onecx/onecx-theme-svc" + repository: 'onecx/onecx-theme-ui' routing: enabled: true operator: @@ -9,18 +9,26 @@ app: enabled: false keycloak: enabled: true - client: "{ \n \"clientId\": \"theme-mgmt-ui\",\n \"enabled\": true,\n \"description\": \"Keycloak client for theme-mgmt-ui\",\n \"redirectUris\": [\"*\"],\n \"webOrigins\": [\"*\"],\n \"publicClient\": true,\n \"protocol\": \"openid-connect\"\n}" + client: |- + { + "clientId": "theme-mgmt-ui", + "enabled": true, + "description": "Keycloak client for theme-mgmt-ui", + "redirectUris": ["*"], + "webOrigins": ["*"], + "publicClient": true, + "protocol": "openid-connect" + } roles: |- [ { - "name": "onecx-portal-admin", - "description": "OneCX portal platform admin" + "name": "onecx-theme-admin", + "description": "OneCX Theme admin" }, { - "name": "onecx-portal-user", - "description": "OneCX portal platform user" + "name": "onecx-theme-user", + "description": "OneCX Theme user" } ] # PIPE Config - diff --git a/package.json b/package.json index f9cc0a1..6363c00 100644 --- a/package.json +++ b/package.json @@ -1,30 +1,34 @@ { "name": "onecx-theme-ui", + "private": true, "version": "0.0.0", "license": "Apache-2.0", + "contributors": [ + "OneCX Development Team " + ], "config": { - "openapiYaml": "src/assets/api/portal-mgmt-api.yaml", + "openapiYaml": "src/assets/api/themes-bff-api.yaml", "openapiOutput": "src/app/generated" }, "scripts": { "build": "ng build", - "clean": "npm cache clean --force", + "clean": "npm cache clean --force && npm run clean-angular", + "clean-angular": "ng cache clean", "start": "ng serve --configuration=development --proxy-config=proxy.conf.js", "prepare": "husky install", "lint": "ng lint", - "eslint": "eslint --ext .js,.ts src", + "eslint": "eslint --quiet --ext .js,.ts src/**", "format": "ng lint --fix", "browsers": "npx browserslist", - "sonar": "npx sonarqube-scanner -Dproject.settings=sonar-local-project.properties", "test": "ng test", "test:ci": "ng test --watch=false --browsers=ChromeHeadless --code-coverage", "karma": "rm -rf reports && npm run test:ci", + "sonar": "npx sonarqube-scanner -Dproject.settings=sonar-local-project.properties", "apigen-cleanup": "rm -rf $npm_package_config_openapiOutput", "apigen-format": "npx prettier $npm_package_config_openapiYaml --write && npx prettier $npm_package_config_openapiOutput/**/* --write", - "apigen-generate": "openapi-generator-cli generate -i $npm_package_config_openapiYaml -g typescript-angular -c apigen.yaml -o $npm_package_config_openapiOutput --type-mappings AnyType=object", + "apigen-generate": "openapi-generator-cli generate -i $npm_package_config_openapiYaml -g typescript-angular -c apigen.yaml -o $npm_package_config_openapiOutput --type-mappings=AnyType=object,set=Array", "apigen": "npm run apigen-cleanup && npm run apigen-generate && npm run apigen-format" }, - "private": true, "husky": { "hooks": { "pre-commit": "pretty-quick --staged" @@ -38,9 +42,7 @@ "tsConfig": "tsconfig.spec.json", "karmaConfig": "karma.conf.js", "codeCoverageExclude": [ - "src/app/generated/**/*", - "src/app/**/*.spec.ts", - "src/app/test/**/*" + "src/app/generated/**/*" ] } }, diff --git a/proxy.conf.js b/proxy.conf.js index 5e1c4d7..a572276 100644 --- a/proxy.conf.js +++ b/proxy.conf.js @@ -17,11 +17,11 @@ const bypassFn = function (req, res) { } const PROXY_CONFIG = { - '/portal-api': { - target: 'http://tkit-portal-server', + '/themes-bff': { + target: 'http://onecx-theme-bff', secure: false, pathRewrite: { - '^.*/portal-api': '' + '^.*/themes-bff': '' }, changeOrigin: true, logLevel: 'debug', diff --git a/src/app/generated/.openapi-generator/FILES b/src/app/generated/.openapi-generator/FILES index 889ed96..80baf4a 100644 --- a/src/app/generated/.openapi-generator/FILES +++ b/src/app/generated/.openapi-generator/FILES @@ -2,111 +2,33 @@ .openapi-generator-ignore README.md api.module.ts -api/adminUserInternal.service.ts api/api.ts -api/avatarV1.service.ts -api/feedbackV1.service.ts -api/imageV1.service.ts -api/menuItemsInternal.service.ts -api/microfrontendRegistrationInternal.service.ts -api/microfrontendV1.service.ts -api/portalImportRequestV1.service.ts -api/portalInternal.service.ts -api/portalItemsV1.service.ts -api/portalLegacy.service.ts -api/portalV1.service.ts -api/supportTicketV1.service.ts api/themes.service.ts -api/userInfoV1.service.ts -api/userProfileV1.service.ts configuration.ts encoder.ts git_push.sh index.ts -model/accountSettingsDTO.ts -model/accountSettingsDTOLayoutAndThemeSettings.ts -model/accountSettingsDTOLocaleAndTimeSettings.ts -model/accountSettingsDTOPrivacySettings.ts -model/accountSettingsDTOv1.ts -model/accountSettingsDTOv1LayoutAndThemeSettings.ts -model/accountSettingsDTOv1LocaleAndTimeSettings.ts -model/accountSettingsDTOv1PrivacySettings.ts -model/colorScheme.ts -model/colorSchemeV1.ts -model/createMicrofrontendDTOv1.ts -model/createPortalDTO.ts -model/createThemeDTO.ts -model/errorResponseDTO.ts -model/feedbackDTOv1.ts -model/imageInfoDTOv1.ts -model/importRequestDTOv1.ts -model/importRequestDTOv1Portal.ts -model/importRequestDTOv1ThemeImportData.ts -model/layoutAndThemeDTO.ts -model/layoutAndThemeDTOv1.ts -model/localeAndTimeSettingsDTO.ts -model/localeAndTimeSettingsDTOv1.ts -model/membershipDTO.ts -model/membershipRolesDTO.ts -model/menuItemDetailsDTO.ts -model/menuItemListDTO.ts -model/menuItemStructureDTO.ts -model/menuItemStructureDTOv1.ts -model/menuItemStructureDtoLegacy.ts -model/menuMode.ts -model/menuModeV1.ts -model/menuStructureListDTO.ts -model/microfrontendDTOv1.ts -model/microfrontendRegistrationDTO.ts -model/microfrontendRegistrationDTOv1.ts -model/microfrontendRegistrationInputDTO.ts -model/microfrontendRegistrationRequestDTO.ts +model/createThemeRequest.ts +model/createThemeResponse.ts +model/eximTheme.ts +model/exportThemeRequest.ts +model/getThemeResponse.ts +model/getThemesResponse.ts +model/importThemeResponse.ts +model/importThemeResponseStatus.ts model/models.ts -model/moduleTypeV1.ts -model/permissionDTO.ts -model/portalAddressDTO.ts -model/portalAddressDTOv1.ts -model/portalDTO.ts -model/portalDTOv1.ts -model/portalIdentifierDTO.ts -model/portalIdentifierDTOv1.ts -model/portalImportDTOv1.ts -model/portalMenuItemDTO.ts -model/portalMenuItemDTOv1.ts -model/portalSearchCriteriaDTO.ts -model/preferencesDTO.ts -model/preferencesDTOv1.ts -model/privacySettingsDTO.ts -model/privacySettingsDTOv1.ts -model/resetPasswordDTOv1.ts -model/restException.ts -model/restExceptionDTO.ts -model/scope.ts -model/scopeV1.ts -model/searchItemDTOv1.ts -model/searchItemTypeV1.ts -model/searchTemplateDTOv1.ts -model/searchTemplateSearchCriteria.ts -model/status.ts -model/subjectLinkDTO.ts -model/subjectLinkDTOv1.ts -model/supportTicketDTOv1.ts -model/themeDTO.ts -model/themeDTOv1.ts -model/updateMicrofrontend200Response.ts -model/updateMicrofrontendDTOv1.ts -model/updatePortalDTO.ts -model/updateThemeDTO.ts -model/userInfoDTOv1.ts -model/userPersonAddressDTO.ts -model/userPersonAddressDTOv1.ts -model/userPersonDTO.ts -model/userPersonDTOv1.ts -model/userPersonPhoneDTO.ts -model/userPersonPhoneDTOv1.ts -model/userProfileDTO.ts -model/userProfileDTOAccountSettings.ts -model/userProfileDTOv1.ts -model/userProfileDTOv1AccountSettings.ts -model/userProfileDTOv1Avatar.ts +model/pagingResponse.ts +model/problemDetailInvalidParam.ts +model/problemDetailParam.ts +model/problemDetailResponse.ts +model/searchThemeRequest.ts +model/searchThemeResponse.ts +model/theme.ts +model/themeSnapshot.ts +model/themeUpdateCreate.ts +model/updateThemeRequest.ts +model/updateThemeResponse.ts +model/validationConstraint.ts +model/workspace.ts +param.ts variables.ts diff --git a/src/app/generated/.openapi-generator/VERSION b/src/app/generated/.openapi-generator/VERSION index 6d54bbd..4b49d9b 100644 --- a/src/app/generated/.openapi-generator/VERSION +++ b/src/app/generated/.openapi-generator/VERSION @@ -1 +1 @@ -6.0.1 \ No newline at end of file +7.2.0 \ No newline at end of file diff --git a/src/app/generated/README.md b/src/app/generated/README.md index d13f49a..de16f95 100644 --- a/src/app/generated/README.md +++ b/src/app/generated/README.md @@ -1,93 +1,226 @@ -# OneCX portal core +## @ -This is a monorepo containing all core UI parts of the OneCX portal suite. +### Building -## Structure +To install the required dependencies and to build the typescript sources run: +``` +npm install +npm run build +``` -This project uses NX monorepo: +### publishing -[Nx Documentation](https://nx.dev/angular) +First build the package then run ```npm publish dist``` (don't forget to specify the `dist` folder!) -[10-minute video showing all Nx features](https://nx.dev/getting-started/intro) +### consuming -[Interactive Tutorial](https://nx.dev/tutorial/01-create-application) +Navigate to the folder of your consuming project and run one of next commands. -![S=structure graph](nx-graph.png) +_published:_ -### portal-integration-angular +``` +npm install @ --save +``` -Publishable integration lib for Angular projects +_without publishing (not recommended):_ -## Getting started +``` +npm install PATH_TO_GENERATED_PACKAGE/dist.tgz --save +``` -To run the suite locally, you'll need to launch the required backend & auth services first. You can do that for example by cloning [tkit-dev-env](https://gitlab.com/1000kit/demo-workshop/tkit-dev-env) and running `docker-compose up -d traefik tkit-portal-server keycloak-app apm ahm`. Check the [README.md](https://gitlab.com/1000kit/demo-workshop/tkit-dev-env/-/blob/master/README.md) for more information. +_It's important to take the tgz file, otherwise you'll get trouble with links on windows_ -- use correct node and npm version: `nvm use` -- install dependencies: `npm i` -- start the shell: `nx run portal-mf-shell:serve` -- start welcome page portlet: `nx run portal-welcome:serve` -- run any of the microfrontends you need (e.g. `nx run theme-mgmt:serve`) and import their permissions to APM service (e.g. `npx nx run theme-mgmt:apm-sync`) -- open your browser on [http://localhost:4300/admin](http://localhost:4300/admin) and login as `onecx`/`onecx` user -- use `npx nx format:check --verbose=true --base develop` to format code before committing +_using `npm link`:_ -## Docs +In PATH_TO_GENERATED_PACKAGE/dist: +``` +npm link +``` + +In your project: +``` +npm link +``` + +__Note for Windows users:__ The Angular CLI has troubles to use linked npm packages. +Please refer to this issue https://github.com/angular/angular-cli/issues/8284 for a solution / workaround. +Published packages are not effected by this issue. -Run docs locally using `npx nx serve docs` -## Storybook +#### General usage + +In your Angular project: -Publishable component libraries use storybook for documentation. To start it locally run: ``` -nx run portal-integration-angular:storybook +// without configuring providers +import { ApiModule } from ''; +import { HttpClientModule } from '@angular/common/http'; + +@NgModule({ + imports: [ + ApiModule, + // make sure to import the HttpClientModule in the AppModule only, + // see https://github.com/angular/angular/issues/20575 + HttpClientModule + ], + declarations: [ AppComponent ], + providers: [], + bootstrap: [ AppComponent ] +}) +export class AppModule {} ``` -## Building - -You can build any service locally using standard NX commands e.g. `npx nx run :` or run some target on all affect projects using `npx nx affected`. The CI pipeline in the project will run build, lint and publish stages by default. +``` +// configuring providers +import { ApiModule, Configuration, ConfigurationParameters } from ''; + +export function apiConfigFactory (): Configuration { + const params: ConfigurationParameters = { + // set configuration parameters here. + } + return new Configuration(params); +} + +@NgModule({ + imports: [ ApiModule.forRoot(apiConfigFactory) ], + declarations: [ AppComponent ], + providers: [], + bootstrap: [ AppComponent ] +}) +export class AppModule {} +``` -For apps/microfrontends we build dockerimage and helm chart as release artifacts. You can run the corresponding tasks locally using `npx nx run :docker --push` and `npx nx run :helm`. +``` +// configuring providers with an authentication service that manages your access tokens +import { ApiModule, Configuration } from ''; + +@NgModule({ + imports: [ ApiModule ], + declarations: [ AppComponent ], + providers: [ + { + provide: Configuration, + useFactory: (authService: AuthService) => new Configuration( + { + basePath: environment.apiUrl, + accessToken: authService.getAccessToken.bind(authService) + } + ), + deps: [AuthService], + multi: false + } + ], + bootstrap: [ AppComponent ] +}) +export class AppModule {} +``` -## Other tasks +``` +import { DefaultApi } from ''; -### Sync permissions with APM +export class AppComponent { + constructor(private apiGateway: DefaultApi) { } +} +``` -Each app defines its permissions in a form CSV file (matrix of permission x role). These permissions are then bundled with the app will be rendered as k8s config map in runtime. Locally we dont use Helm/K8s therefore you need to manually push these permissions to APM service. If you use tkit-dev-env setup then we there is a custom nx target defined for this purpose: +Note: The ApiModule is restricted to being instantiated once app wide. +This is to ensure that all services are treated as singletons. +#### Using multiple OpenAPI files / APIs / ApiModules +In order to use multiple `ApiModules` generated from different OpenAPI files, +you can create an alias name when importing the modules +in order to avoid naming conflicts: ``` -npx nx run :apm-sync +import { ApiModule } from 'my-api-path'; +import { ApiModule as OtherApiModule } from 'my-other-api-path'; +import { HttpClientModule } from '@angular/common/http'; + +@NgModule({ + imports: [ + ApiModule, + OtherApiModule, + // make sure to import the HttpClientModule in the AppModule only, + // see https://github.com/angular/angular/issues/20575 + HttpClientModule + ] +}) +export class AppModule { + +} ``` -See `libs/build-plugin/src/executors/permission-sync` for more info. -## Publishing libs & services +### Set service base path +If different than the generated base path, during app bootstrap, you can provide the base path to your service. -### Publishing `@onecx/portal-integration-angular` package +``` +import { BASE_PATH } from ''; -To publish the `@onecx/portal-integration-angular` library to our private npm registry hosted [on Gitlab](https://gitlab.com/1000kit/apps/tkit-portal/onecx-portal-core-ui/-/packages) you need to complete the following steps: +bootstrap(AppComponent, [ + { provide: BASE_PATH, useValue: 'https://your-web-service.com' }, +]); +``` +or -1. Build the library: `npx nx run portal-integration-angular:build` -2. Copy credentials to the output folder: `cp tools/.npmrc_WRITE dist/libs/portal-integration-angular/.npmrc` -3. Publish the library: `cd dist/libs/portal-integration-angular && npm publish` +``` +import { BASE_PATH } from ''; + +@NgModule({ + imports: [], + declarations: [ AppComponent ], + providers: [ provide: BASE_PATH, useValue: 'https://your-web-service.com' ], + bootstrap: [ AppComponent ] +}) +export class AppModule {} +``` -### Publishing `@onecx/portal-layout-styles` package -To publish the `@onecx/portal-layout-styles` library to our private npm registry hosted [on Gitlab](https://gitlab.com/1000kit/apps/tkit-portal/onecx-portal-core-ui/-/packages) you need to complete the following steps: +#### Using @angular/cli +First extend your `src/environments/*.ts` files by adding the corresponding base path: -1. Build the library: `npx nx run portal-layout-styles:build` -2. Copy credentials to the output folder: `cp tools/.npmrc_WRITE dist/libs/portal-layout-styles/.npmrc` -3. Publish the library: `cd dist/libs/portal-layout-styles && npm publish` +``` +export const environment = { + production: false, + API_BASE_PATH: 'http://127.0.0.1:8080' +}; +``` -## Development +In the src/app/app.module.ts: +``` +import { BASE_PATH } from ''; +import { environment } from '../environments/environment'; + +@NgModule({ + declarations: [ + AppComponent + ], + imports: [ ], + providers: [{ provide: BASE_PATH, useValue: environment.API_BASE_PATH }], + bootstrap: [ AppComponent ] +}) +export class AppModule { } +``` -The project uses conventional commits. +### Customizing path parameter encoding -## Known issue +Without further customization, only [path-parameters][parameter-locations-url] of [style][style-values-url] 'simple' +and Dates for format 'date-time' are encoded correctly. -### Tests +Other styles (e.g. "matrix") are not that easy to encode +and thus are best delegated to other libraries (e.g.: [@honoluluhenk/http-param-expander]). -... are missing or failing - should be provided. +To implement your own parameter encoding (or call another library), +pass an arrow-function or method-reference to the `encodeParam` property of the Configuration-object +(see [General Usage](#general-usage) above). -### Husky +Example value for use in your Configuration-Provider: +```typescript +new Configuration({ + encodeParam: (param: Param) => myFancyParamEncoder(param), +}) +``` -If you experience problems on commit whith hooks, make sure the husky is a `nvm` [aware](https://github.com/typicode/husky/issues/77#issuecomment-630065185) +[parameter-locations-url]: https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#parameter-locations +[style-values-url]: https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#style-values +[@honoluluhenk/http-param-expander]: https://www.npmjs.com/package/@honoluluhenk/http-param-expander diff --git a/src/app/generated/api.module.ts b/src/app/generated/api.module.ts index 791cf02..58d341f 100644 --- a/src/app/generated/api.module.ts +++ b/src/app/generated/api.module.ts @@ -1,47 +1,30 @@ -import { NgModule, ModuleWithProviders, SkipSelf, Optional } from '@angular/core' -import { Configuration } from './configuration' -import { HttpClient } from '@angular/common/http' +import { NgModule, ModuleWithProviders, SkipSelf, Optional } from '@angular/core'; +import { Configuration } from './configuration'; +import { HttpClient } from '@angular/common/http'; -import { AdminUserInternalAPIService } from './api/adminUserInternal.service' -import { AvatarV1APIService } from './api/avatarV1.service' -import { FeedbackV1APIService } from './api/feedbackV1.service' -import { ImageV1APIService } from './api/imageV1.service' -import { MenuItemsInternalAPIService } from './api/menuItemsInternal.service' -import { MicrofrontendRegistrationInternalAPIService } from './api/microfrontendRegistrationInternal.service' -import { MicrofrontendV1APIService } from './api/microfrontendV1.service' -import { PortalImportRequestV1APIService } from './api/portalImportRequestV1.service' -import { PortalInternalAPIService } from './api/portalInternal.service' -import { PortalItemsV1APIService } from './api/portalItemsV1.service' -import { PortalLegacyAPIService } from './api/portalLegacy.service' -import { PortalV1APIService } from './api/portalV1.service' -import { SupportTicketV1APIService } from './api/supportTicketV1.service' -import { ThemesAPIService } from './api/themes.service' -import { UserInfoV1APIService } from './api/userInfoV1.service' -import { UserProfileV1APIService } from './api/userProfileV1.service' @NgModule({ - imports: [], + imports: [], declarations: [], - exports: [], - providers: [], + exports: [], + providers: [] }) export class ApiModule { - public static forRoot(configurationFactory: () => Configuration): ModuleWithProviders { - return { - ngModule: ApiModule, - providers: [{ provide: Configuration, useFactory: configurationFactory }], + public static forRoot(configurationFactory: () => Configuration): ModuleWithProviders { + return { + ngModule: ApiModule, + providers: [ { provide: Configuration, useFactory: configurationFactory } ] + }; } - } - constructor(@Optional() @SkipSelf() parentModule: ApiModule, @Optional() http: HttpClient) { - if (parentModule) { - throw new Error('ApiModule is already loaded. Import in your base AppModule only.') + constructor( @Optional() @SkipSelf() parentModule: ApiModule, + @Optional() http: HttpClient) { + if (parentModule) { + throw new Error('ApiModule is already loaded. Import in your base AppModule only.'); + } + if (!http) { + throw new Error('You need to import the HttpClientModule in your AppModule! \n' + + 'See also https://github.com/angular/angular/issues/20575'); + } } - if (!http) { - throw new Error( - 'You need to import the HttpClientModule in your AppModule! \n' + - 'See also https://github.com/angular/angular/issues/20575' - ) - } - } } diff --git a/src/app/generated/api/adminUserInternal.service.ts b/src/app/generated/api/adminUserInternal.service.ts deleted file mode 100644 index 8ac5795..0000000 --- a/src/app/generated/api/adminUserInternal.service.ts +++ /dev/null @@ -1,539 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { AccountSettingsDTO } from '../model/accountSettingsDTO' -// @ts-ignore -import { RestException } from '../model/restException' -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' -// @ts-ignore -import { UserPersonDTO } from '../model/userPersonDTO' -// @ts-ignore -import { UserProfileDTO } from '../model/userProfileDTO' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface AdminUpdateUserSettingsRequestParams { - userId: string - accountSettingsDTO?: AccountSettingsDTO -} - -export interface DeleteUserByIdRequestParams { - userId: string -} - -export interface GetUserProfileByIdRequestParams { - userId: string -} - -export interface GetUserProfilesRequestParams { - email?: string - firstName?: string - lastName?: string - userId?: string -} - -export interface UpdateUserPersonalInfoRequestParams { - userId: string - userPersonDTO?: UserPersonDTO -} - -@Injectable({ - providedIn: 'any', -}) -export class AdminUserInternalAPIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Update Admin User Settings - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public adminUpdateUserSettings( - requestParameters: AdminUpdateUserSettingsRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public adminUpdateUserSettings( - requestParameters: AdminUpdateUserSettingsRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public adminUpdateUserSettings( - requestParameters: AdminUpdateUserSettingsRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public adminUpdateUserSettings( - requestParameters: AdminUpdateUserSettingsRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const userId = requestParameters.userId - if (userId === null || userId === undefined) { - throw new Error('Required parameter userId was null or undefined when calling adminUpdateUserSettings.') - } - const accountSettingsDTO = requestParameters.accountSettingsDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.patch( - `${this.configuration.basePath}/internal/userProfiles/settings/${encodeURIComponent(String(userId))}`, - accountSettingsDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Delete user by given Id - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteUserById( - requestParameters: DeleteUserByIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteUserById( - requestParameters: DeleteUserByIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserById( - requestParameters: DeleteUserByIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserById( - requestParameters: DeleteUserByIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const userId = requestParameters.userId - if (userId === null || userId === undefined) { - throw new Error('Required parameter userId was null or undefined when calling deleteUserById.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/internal/userProfiles/${encodeURIComponent(String(userId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Get User Profile by Id - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getUserProfileById( - requestParameters: GetUserProfileByIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getUserProfileById( - requestParameters: GetUserProfileByIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserProfileById( - requestParameters: GetUserProfileByIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserProfileById( - requestParameters: GetUserProfileByIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const userId = requestParameters.userId - if (userId === null || userId === undefined) { - throw new Error('Required parameter userId was null or undefined when calling getUserProfileById.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/internal/userProfiles/${encodeURIComponent(String(userId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Get User Profiles by given criteria - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getUserProfiles( - requestParameters: GetUserProfilesRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserProfiles( - requestParameters: GetUserProfilesRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getUserProfiles( - requestParameters: GetUserProfilesRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getUserProfiles( - requestParameters: GetUserProfilesRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const email = requestParameters.email - const firstName = requestParameters.firstName - const lastName = requestParameters.lastName - const userId = requestParameters.userId - - let localVarQueryParameters = new HttpParams({ encoder: this.encoder }) - if (email !== undefined && email !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, email, 'email') - } - if (firstName !== undefined && firstName !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, firstName, 'firstName') - } - if (lastName !== undefined && lastName !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, lastName, 'lastName') - } - if (userId !== undefined && userId !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, userId, 'userId') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>(`${this.configuration.basePath}/internal/userProfiles`, { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Update Personal User Info By Admin - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public updateUserPersonalInfo( - requestParameters: UpdateUserPersonalInfoRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateUserPersonalInfo( - requestParameters: UpdateUserPersonalInfoRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public updateUserPersonalInfo( - requestParameters: UpdateUserPersonalInfoRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public updateUserPersonalInfo( - requestParameters: UpdateUserPersonalInfoRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const userId = requestParameters.userId - if (userId === null || userId === undefined) { - throw new Error('Required parameter userId was null or undefined when calling updateUserPersonalInfo.') - } - const userPersonDTO = requestParameters.userPersonDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put>( - `${this.configuration.basePath}/internal/userProfiles/${encodeURIComponent(String(userId))}`, - userPersonDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/api.ts b/src/app/generated/api/api.ts index ec4a49e..78085e9 100644 --- a/src/app/generated/api/api.ts +++ b/src/app/generated/api/api.ts @@ -1,50 +1,3 @@ -export * from './adminUserInternal.service' -import { AdminUserInternalAPIService } from './adminUserInternal.service' -export * from './avatarV1.service' -import { AvatarV1APIService } from './avatarV1.service' -export * from './feedbackV1.service' -import { FeedbackV1APIService } from './feedbackV1.service' -export * from './imageV1.service' -import { ImageV1APIService } from './imageV1.service' -export * from './menuItemsInternal.service' -import { MenuItemsInternalAPIService } from './menuItemsInternal.service' -export * from './microfrontendRegistrationInternal.service' -import { MicrofrontendRegistrationInternalAPIService } from './microfrontendRegistrationInternal.service' -export * from './microfrontendV1.service' -import { MicrofrontendV1APIService } from './microfrontendV1.service' -export * from './portalImportRequestV1.service' -import { PortalImportRequestV1APIService } from './portalImportRequestV1.service' -export * from './portalInternal.service' -import { PortalInternalAPIService } from './portalInternal.service' -export * from './portalItemsV1.service' -import { PortalItemsV1APIService } from './portalItemsV1.service' -export * from './portalLegacy.service' -import { PortalLegacyAPIService } from './portalLegacy.service' -export * from './portalV1.service' -import { PortalV1APIService } from './portalV1.service' -export * from './supportTicketV1.service' -import { SupportTicketV1APIService } from './supportTicketV1.service' -export * from './themes.service' -import { ThemesAPIService } from './themes.service' -export * from './userInfoV1.service' -import { UserInfoV1APIService } from './userInfoV1.service' -export * from './userProfileV1.service' -import { UserProfileV1APIService } from './userProfileV1.service' -export const APIS = [ - AdminUserInternalAPIService, - AvatarV1APIService, - FeedbackV1APIService, - ImageV1APIService, - MenuItemsInternalAPIService, - MicrofrontendRegistrationInternalAPIService, - MicrofrontendV1APIService, - PortalImportRequestV1APIService, - PortalInternalAPIService, - PortalItemsV1APIService, - PortalLegacyAPIService, - PortalV1APIService, - SupportTicketV1APIService, - ThemesAPIService, - UserInfoV1APIService, - UserProfileV1APIService, -] +export * from './themes.service'; +import { ThemesAPIService } from './themes.service'; +export const APIS = [ThemesAPIService]; diff --git a/src/app/generated/api/avatarV1.service.ts b/src/app/generated/api/avatarV1.service.ts deleted file mode 100644 index 1bff493..0000000 --- a/src/app/generated/api/avatarV1.service.ts +++ /dev/null @@ -1,368 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { ImageInfoDTOv1 } from '../model/imageInfoDTOv1' -// @ts-ignore -import { RestException } from '../model/restException' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface V1UserProfileMeAvatarAvatarIdGetRequestParams { - avatarId: string -} - -@Injectable({ - providedIn: 'any', -}) -export class AvatarV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Delete user\'s avatar - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteUserAvatar( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteUserAvatar( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserAvatar( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserAvatar( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete(`${this.configuration.basePath}/v1/userProfile/me/avatar`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Get user avatar info - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getUserAvatarInfo( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getUserAvatarInfo( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserAvatarInfo( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserAvatarInfo( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get(`${this.configuration.basePath}/v1/userProfile/me/avatar`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Upload user avatar - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public uploadAvatar( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public uploadAvatar( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public uploadAvatar( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public uploadAvatar( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put(`${this.configuration.basePath}/v1/userProfile/me/avatar`, null, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public v1UserProfileMeAvatarAvatarIdGet( - requestParameters: V1UserProfileMeAvatarAvatarIdGetRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public v1UserProfileMeAvatarAvatarIdGet( - requestParameters: V1UserProfileMeAvatarAvatarIdGetRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public v1UserProfileMeAvatarAvatarIdGet( - requestParameters: V1UserProfileMeAvatarAvatarIdGetRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public v1UserProfileMeAvatarAvatarIdGet( - requestParameters: V1UserProfileMeAvatarAvatarIdGetRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const avatarId = requestParameters.avatarId - if (avatarId === null || avatarId === undefined) { - throw new Error( - 'Required parameter avatarId was null or undefined when calling v1UserProfileMeAvatarAvatarIdGet.' - ) - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/v1/userProfile/me/avatar/${encodeURIComponent(String(avatarId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/feedbackV1.service.ts b/src/app/generated/api/feedbackV1.service.ts deleted file mode 100644 index 20c8b48..0000000 --- a/src/app/generated/api/feedbackV1.service.ts +++ /dev/null @@ -1,179 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { FeedbackDTOv1 } from '../model/feedbackDTOv1' -// @ts-ignore -import { RestException } from '../model/restException' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface SendFeedbackV1RequestParams { - feedbackDTOv1?: FeedbackDTOv1 -} - -@Injectable({ - providedIn: 'any', -}) -export class FeedbackV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Send feedback for an app - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public sendFeedbackV1( - requestParameters: SendFeedbackV1RequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public sendFeedbackV1( - requestParameters: SendFeedbackV1RequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public sendFeedbackV1( - requestParameters: SendFeedbackV1RequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public sendFeedbackV1( - requestParameters: SendFeedbackV1RequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const feedbackDTOv1 = requestParameters.feedbackDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post(`${this.configuration.basePath}/v1/feedback/send`, feedbackDTOv1, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } -} diff --git a/src/app/generated/api/imageV1.service.ts b/src/app/generated/api/imageV1.service.ts deleted file mode 100644 index f9eacaf..0000000 --- a/src/app/generated/api/imageV1.service.ts +++ /dev/null @@ -1,376 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { ImageInfoDTOv1 } from '../model/imageInfoDTOv1' -// @ts-ignore -import { RestException } from '../model/restException' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface DeleteImageRequestParams { - imageId: string -} - -export interface UploadImageRequestParams { - /** file data */ - image?: Blob - fileName?: string -} - -export interface V1ImagesImageIdGetRequestParams { - imageId: string -} - -@Injectable({ - providedIn: 'any', -}) -export class ImageV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - /** - * @param consumes string[] mime-types - * @return true: consumes contains 'multipart/form-data', false: otherwise - */ - private canConsumeForm(consumes: string[]): boolean { - const form = 'multipart/form-data' - for (const consume of consumes) { - if (form === consume) { - return true - } - } - return false - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Delete Image - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteImage( - requestParameters: DeleteImageRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteImage( - requestParameters: DeleteImageRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteImage( - requestParameters: DeleteImageRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteImage( - requestParameters: DeleteImageRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const imageId = requestParameters.imageId - if (imageId === null || imageId === undefined) { - throw new Error('Required parameter imageId was null or undefined when calling deleteImage.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/v1/images/${encodeURIComponent(String(imageId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Upload Images - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public uploadImage( - requestParameters: UploadImageRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public uploadImage( - requestParameters: UploadImageRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public uploadImage( - requestParameters: UploadImageRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public uploadImage( - requestParameters: UploadImageRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const image = requestParameters.image - const fileName = requestParameters.fileName - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['multipart/form-data'] - - const canConsumeForm = this.canConsumeForm(consumes) - - let localVarFormParams: { append(param: string, value: any): any } - let localVarUseForm = false - let localVarConvertFormParamsToString = false - // use FormData to transmit files using content-type "multipart/form-data" - // see https://stackoverflow.com/questions/4007969/application-x-www-form-urlencoded-or-multipart-form-data - localVarUseForm = canConsumeForm - if (localVarUseForm) { - localVarFormParams = new FormData() - } else { - localVarFormParams = new HttpParams({ encoder: this.encoder }) - } - - if (image !== undefined) { - localVarFormParams = (localVarFormParams.append('image', image) as any) || localVarFormParams - } - if (fileName !== undefined) { - localVarFormParams = (localVarFormParams.append('fileName', fileName) as any) || localVarFormParams - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/v1/images`, - localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public v1ImagesImageIdGet( - requestParameters: V1ImagesImageIdGetRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public v1ImagesImageIdGet( - requestParameters: V1ImagesImageIdGetRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public v1ImagesImageIdGet( - requestParameters: V1ImagesImageIdGetRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public v1ImagesImageIdGet( - requestParameters: V1ImagesImageIdGetRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const imageId = requestParameters.imageId - if (imageId === null || imageId === undefined) { - throw new Error('Required parameter imageId was null or undefined when calling v1ImagesImageIdGet.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/v1/images/${encodeURIComponent(String(imageId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/menuItemsInternal.service.ts b/src/app/generated/api/menuItemsInternal.service.ts deleted file mode 100644 index aa51132..0000000 --- a/src/app/generated/api/menuItemsInternal.service.ts +++ /dev/null @@ -1,887 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { MenuItemDetailsDTO } from '../model/menuItemDetailsDTO' -// @ts-ignore -import { MenuItemListDTO } from '../model/menuItemListDTO' -// @ts-ignore -import { MenuStructureListDTO } from '../model/menuStructureListDTO' -// @ts-ignore -import { PortalMenuItemDTO } from '../model/portalMenuItemDTO' -// @ts-ignore -import { RestException } from '../model/restException' -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface AddMenuItemForPortalRequestParams { - portalId: string - menuItemDetailsDTO?: MenuItemDetailsDTO -} - -export interface BulkPatchMenuItemsRequestParams { - portalId: string - menuItemDetailsDTO?: Array -} - -export interface DeleteAllMenuItemForPortalRequestParams { - portalId: string -} - -export interface DeleteMenuItemByIdRequestParams { - menuItemId: string - portalId: string -} - -export interface GetMenuItemByIdRequestParams { - menuItemId: string - portalId: string -} - -export interface GetMenuStructureForPortalIdRequestParams { - portalId: string -} - -export interface GetPortalMenuItemsRequestParams { - portalId: string -} - -export interface PatchMenuItemRequestParams { - menuItemId: string - portalId: string - menuItemDetailsDTO?: MenuItemDetailsDTO -} - -export interface UploadMenuStructureRequestParams { - portalId: string - menuStructureListDTO?: MenuStructureListDTO -} - -@Injectable({ - providedIn: 'any', -}) -export class MenuItemsInternalAPIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Add a new menu item to portal menu - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public addMenuItemForPortal( - requestParameters: AddMenuItemForPortalRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public addMenuItemForPortal( - requestParameters: AddMenuItemForPortalRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public addMenuItemForPortal( - requestParameters: AddMenuItemForPortalRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public addMenuItemForPortal( - requestParameters: AddMenuItemForPortalRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling addMenuItemForPortal.') - } - const menuItemDetailsDTO = requestParameters.menuItemDetailsDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}/menuItems`, - menuItemDetailsDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Bulk update menu Items - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public bulkPatchMenuItems( - requestParameters: BulkPatchMenuItemsRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public bulkPatchMenuItems( - requestParameters: BulkPatchMenuItemsRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public bulkPatchMenuItems( - requestParameters: BulkPatchMenuItemsRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public bulkPatchMenuItems( - requestParameters: BulkPatchMenuItemsRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling bulkPatchMenuItems.') - } - const menuItemDetailsDTO = requestParameters.menuItemDetailsDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.patch>( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}/menuItems`, - menuItemDetailsDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Delete all menu items in portal - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteAllMenuItemForPortal( - requestParameters: DeleteAllMenuItemForPortalRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteAllMenuItemForPortal( - requestParameters: DeleteAllMenuItemForPortalRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteAllMenuItemForPortal( - requestParameters: DeleteAllMenuItemForPortalRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteAllMenuItemForPortal( - requestParameters: DeleteAllMenuItemForPortalRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling deleteAllMenuItemForPortal.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}/menuItems`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Delete a menuItem by the PortalId and the menuItemId - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteMenuItemById( - requestParameters: DeleteMenuItemByIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteMenuItemById( - requestParameters: DeleteMenuItemByIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteMenuItemById( - requestParameters: DeleteMenuItemByIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteMenuItemById( - requestParameters: DeleteMenuItemByIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const menuItemId = requestParameters.menuItemId - if (menuItemId === null || menuItemId === undefined) { - throw new Error('Required parameter menuItemId was null or undefined when calling deleteMenuItemById.') - } - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling deleteMenuItemById.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent( - String(portalId) - )}/menuItems/${encodeURIComponent(String(menuItemId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Retrieve menu item detail info - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getMenuItemById( - requestParameters: GetMenuItemByIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getMenuItemById( - requestParameters: GetMenuItemByIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMenuItemById( - requestParameters: GetMenuItemByIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMenuItemById( - requestParameters: GetMenuItemByIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const menuItemId = requestParameters.menuItemId - if (menuItemId === null || menuItemId === undefined) { - throw new Error('Required parameter menuItemId was null or undefined when calling getMenuItemById.') - } - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling getMenuItemById.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent( - String(portalId) - )}/menuItems/${encodeURIComponent(String(menuItemId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Fetch the menuItems of the portal in the tree structure - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getMenuStructureForPortalId( - requestParameters: GetMenuStructureForPortalIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMenuStructureForPortalId( - requestParameters: GetMenuStructureForPortalIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalId( - requestParameters: GetMenuStructureForPortalIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalId( - requestParameters: GetMenuStructureForPortalIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling getMenuStructureForPortalId.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}/menuItems/tree`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Returns a list of portal menu items - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getPortalMenuItems( - requestParameters: GetPortalMenuItemsRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalMenuItems( - requestParameters: GetPortalMenuItemsRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getPortalMenuItems( - requestParameters: GetPortalMenuItemsRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getPortalMenuItems( - requestParameters: GetPortalMenuItemsRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling getPortalMenuItems.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}/menuItems`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Update an existing menu item - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public patchMenuItem( - requestParameters: PatchMenuItemRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public patchMenuItem( - requestParameters: PatchMenuItemRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public patchMenuItem( - requestParameters: PatchMenuItemRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public patchMenuItem( - requestParameters: PatchMenuItemRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const menuItemId = requestParameters.menuItemId - if (menuItemId === null || menuItemId === undefined) { - throw new Error('Required parameter menuItemId was null or undefined when calling patchMenuItem.') - } - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling patchMenuItem.') - } - const menuItemDetailsDTO = requestParameters.menuItemDetailsDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.patch( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent( - String(portalId) - )}/menuItems/${encodeURIComponent(String(menuItemId))}`, - menuItemDetailsDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Upload and overwrite menuStructure in portal - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public uploadMenuStructure( - requestParameters: UploadMenuStructureRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public uploadMenuStructure( - requestParameters: UploadMenuStructureRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public uploadMenuStructure( - requestParameters: UploadMenuStructureRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public uploadMenuStructure( - requestParameters: UploadMenuStructureRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling uploadMenuStructure.') - } - const menuStructureListDTO = requestParameters.menuStructureListDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}/menuItems/upload`, - menuStructureListDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/microfrontendRegistrationInternal.service.ts b/src/app/generated/api/microfrontendRegistrationInternal.service.ts deleted file mode 100644 index 2f92d52..0000000 --- a/src/app/generated/api/microfrontendRegistrationInternal.service.ts +++ /dev/null @@ -1,279 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { MicrofrontendRegistrationDTO } from '../model/microfrontendRegistrationDTO' -// @ts-ignore -import { MicrofrontendRegistrationRequestDTO } from '../model/microfrontendRegistrationRequestDTO' -// @ts-ignore -import { RestException } from '../model/restException' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface DeleteMicrofrontendRegistrationRequestParams { - mfeRegId: string - portalId: string -} - -export interface RegisterMicrofrontendRequestParams { - portalId: string - microfrontendRegistrationRequestDTO?: MicrofrontendRegistrationRequestDTO -} - -@Injectable({ - providedIn: 'any', -}) -export class MicrofrontendRegistrationInternalAPIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Removes microfrontend assignment to this portal - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteMicrofrontendRegistration( - requestParameters: DeleteMicrofrontendRegistrationRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteMicrofrontendRegistration( - requestParameters: DeleteMicrofrontendRegistrationRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteMicrofrontendRegistration( - requestParameters: DeleteMicrofrontendRegistrationRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteMicrofrontendRegistration( - requestParameters: DeleteMicrofrontendRegistrationRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const mfeRegId = requestParameters.mfeRegId - if (mfeRegId === null || mfeRegId === undefined) { - throw new Error('Required parameter mfeRegId was null or undefined when calling deleteMicrofrontendRegistration.') - } - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling deleteMicrofrontendRegistration.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent( - String(portalId) - )}/microfrontendregistrations/${encodeURIComponent(String(mfeRegId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Assigns a microfrontend to this portal - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public registerMicrofrontend( - requestParameters: RegisterMicrofrontendRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public registerMicrofrontend( - requestParameters: RegisterMicrofrontendRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public registerMicrofrontend( - requestParameters: RegisterMicrofrontendRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public registerMicrofrontend( - requestParameters: RegisterMicrofrontendRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling registerMicrofrontend.') - } - const microfrontendRegistrationRequestDTO = requestParameters.microfrontendRegistrationRequestDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent( - String(portalId) - )}/microfrontendregistrations`, - microfrontendRegistrationRequestDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/microfrontendV1.service.ts b/src/app/generated/api/microfrontendV1.service.ts deleted file mode 100644 index b9c8d2a..0000000 --- a/src/app/generated/api/microfrontendV1.service.ts +++ /dev/null @@ -1,502 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { CreateMicrofrontendDTOv1 } from '../model/createMicrofrontendDTOv1' -// @ts-ignore -import { MicrofrontendDTOv1 } from '../model/microfrontendDTOv1' -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' -// @ts-ignore -import { UpdateMicrofrontend200Response } from '../model/updateMicrofrontend200Response' -// @ts-ignore -import { UpdateMicrofrontendDTOv1 } from '../model/updateMicrofrontendDTOv1' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface CreateNewMicroFrontendRequestParams { - createMicrofrontendDTOv1?: CreateMicrofrontendDTOv1 -} - -export interface DeleteMicrofrontendRequestParams { - id: string -} - -export interface GetMicrofrontendByIdRequestParams { - id: string -} - -export interface UpdateMicrofrontendRequestParams { - id: string - updateMicrofrontendDTOv1?: UpdateMicrofrontendDTOv1 -} - -@Injectable({ - providedIn: 'any', -}) -export class MicrofrontendV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Create microfrontend. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public createNewMicroFrontend( - requestParameters: CreateNewMicroFrontendRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public createNewMicroFrontend( - requestParameters: CreateNewMicroFrontendRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createNewMicroFrontend( - requestParameters: CreateNewMicroFrontendRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createNewMicroFrontend( - requestParameters: CreateNewMicroFrontendRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const createMicrofrontendDTOv1 = requestParameters.createMicrofrontendDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json', 'text/plain'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/v1/microfrontends`, - createMicrofrontendDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Delete microfrontend by ID when no portals are attached. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteMicrofrontend( - requestParameters: DeleteMicrofrontendRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteMicrofrontend( - requestParameters: DeleteMicrofrontendRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public deleteMicrofrontend( - requestParameters: DeleteMicrofrontendRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public deleteMicrofrontend( - requestParameters: DeleteMicrofrontendRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const id = requestParameters.id - if (id === null || id === undefined) { - throw new Error('Required parameter id was null or undefined when calling deleteMicrofrontend.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete>( - `${this.configuration.basePath}/v1/microfrontends/${encodeURIComponent(String(id))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Returns a microfrontend by ID. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getMicrofrontendById( - requestParameters: GetMicrofrontendByIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMicrofrontendById( - requestParameters: GetMicrofrontendByIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMicrofrontendById( - requestParameters: GetMicrofrontendByIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMicrofrontendById( - requestParameters: GetMicrofrontendByIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const id = requestParameters.id - if (id === null || id === undefined) { - throw new Error('Required parameter id was null or undefined when calling getMicrofrontendById.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>( - `${this.configuration.basePath}/v1/microfrontends/${encodeURIComponent(String(id))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Returns a list of all microfrontends. - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getMicrofrontends( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMicrofrontends( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMicrofrontends( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMicrofrontends( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>(`${this.configuration.basePath}/v1/microfrontends`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Creates or updates a microfrontend. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public updateMicrofrontend( - requestParameters: UpdateMicrofrontendRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public updateMicrofrontend( - requestParameters: UpdateMicrofrontendRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateMicrofrontend( - requestParameters: UpdateMicrofrontendRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateMicrofrontend( - requestParameters: UpdateMicrofrontendRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const id = requestParameters.id - if (id === null || id === undefined) { - throw new Error('Required parameter id was null or undefined when calling updateMicrofrontend.') - } - const updateMicrofrontendDTOv1 = requestParameters.updateMicrofrontendDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json', 'text/plain'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put( - `${this.configuration.basePath}/v1/microfrontends/${encodeURIComponent(String(id))}`, - updateMicrofrontendDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/portalImportRequestV1.service.ts b/src/app/generated/api/portalImportRequestV1.service.ts deleted file mode 100644 index d213c4d..0000000 --- a/src/app/generated/api/portalImportRequestV1.service.ts +++ /dev/null @@ -1,185 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { ImportRequestDTOv1 } from '../model/importRequestDTOv1' -// @ts-ignore -import { PortalDTOv1 } from '../model/portalDTOv1' -// @ts-ignore -import { RestException } from '../model/restException' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface PortalImportRequestRequestParams { - importRequestDTOv1?: ImportRequestDTOv1 -} - -@Injectable({ - providedIn: 'any', -}) -export class PortalImportRequestV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Trigger portal import feature - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public portalImportRequest( - requestParameters: PortalImportRequestRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public portalImportRequest( - requestParameters: PortalImportRequestRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public portalImportRequest( - requestParameters: PortalImportRequestRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public portalImportRequest( - requestParameters: PortalImportRequestRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const importRequestDTOv1 = requestParameters.importRequestDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/v1/portalImportRequest`, - importRequestDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/portalInternal.service.ts b/src/app/generated/api/portalInternal.service.ts deleted file mode 100644 index c690f38..0000000 --- a/src/app/generated/api/portalInternal.service.ts +++ /dev/null @@ -1,580 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { CreatePortalDTO } from '../model/createPortalDTO' -// @ts-ignore -import { PortalDTO } from '../model/portalDTO' -// @ts-ignore -import { PortalSearchCriteriaDTO } from '../model/portalSearchCriteriaDTO' -// @ts-ignore -import { RestException } from '../model/restException' -// @ts-ignore -import { UpdatePortalDTO } from '../model/updatePortalDTO' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface CreateNewPortalRequestParams { - createPortalDTO?: CreatePortalDTO -} - -export interface DeletePortalRequestParams { - portalId: string -} - -export interface GetPortalByPortalIdRequestParams { - portalId: string -} - -export interface GetPortalsRequestParams { - portalSearchCriteriaDTO?: PortalSearchCriteriaDTO -} - -export interface UpdatePortalRequestParams { - portalId: string - updatePortalDTO?: UpdatePortalDTO -} - -@Injectable({ - providedIn: 'any', -}) -export class PortalInternalAPIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Create new portal definition - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public createNewPortal( - requestParameters: CreateNewPortalRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public createNewPortal( - requestParameters: CreateNewPortalRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createNewPortal( - requestParameters: CreateNewPortalRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createNewPortal( - requestParameters: CreateNewPortalRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const createPortalDTO = requestParameters.createPortalDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post(`${this.configuration.basePath}/internal/portals`, createPortalDTO, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Delete given portal - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deletePortal( - requestParameters: DeletePortalRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deletePortal( - requestParameters: DeletePortalRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deletePortal( - requestParameters: DeletePortalRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deletePortal( - requestParameters: DeletePortalRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling deletePortal.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Load all portals - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getAllPortals( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getAllPortals( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getAllPortals( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getAllPortals( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>(`${this.configuration.basePath}/internal/portals`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Load a single portal - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getPortalByPortalId( - requestParameters: GetPortalByPortalIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getPortalByPortalId( - requestParameters: GetPortalByPortalIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalByPortalId( - requestParameters: GetPortalByPortalIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalByPortalId( - requestParameters: GetPortalByPortalIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling getPortalByPortalId.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Get portals by search criteria (name & theme) - * This operation searches portals by criteria. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getPortals( - requestParameters: GetPortalsRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getPortals( - requestParameters: GetPortalsRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortals( - requestParameters: GetPortalsRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortals( - requestParameters: GetPortalsRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalSearchCriteriaDTO = requestParameters.portalSearchCriteriaDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get(`${this.configuration.basePath}/internal/portals/search`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Update portal definition - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public updatePortal( - requestParameters: UpdatePortalRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public updatePortal( - requestParameters: UpdatePortalRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updatePortal( - requestParameters: UpdatePortalRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updatePortal( - requestParameters: UpdatePortalRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error('Required parameter portalId was null or undefined when calling updatePortal.') - } - const updatePortalDTO = requestParameters.updatePortalDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put( - `${this.configuration.basePath}/internal/portals/${encodeURIComponent(String(portalId))}`, - updatePortalDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/portalItemsV1.service.ts b/src/app/generated/api/portalItemsV1.service.ts deleted file mode 100644 index 8a62ba6..0000000 --- a/src/app/generated/api/portalItemsV1.service.ts +++ /dev/null @@ -1,189 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' -// @ts-ignore -import { SearchItemDTOv1 } from '../model/searchItemDTOv1' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface GetPortalItemsByQueryRequestParams { - count?: number - portalName?: string - query?: string -} - -@Injectable({ - providedIn: 'any', -}) -export class PortalItemsV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Returns a list of portal items matching query - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - * @deprecated - */ - public getPortalItemsByQuery( - requestParameters: GetPortalItemsByQueryRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalItemsByQuery( - requestParameters: GetPortalItemsByQueryRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getPortalItemsByQuery( - requestParameters: GetPortalItemsByQueryRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getPortalItemsByQuery( - requestParameters: GetPortalItemsByQueryRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const count = requestParameters.count - const portalName = requestParameters.portalName - const query = requestParameters.query - - let localVarQueryParameters = new HttpParams({ encoder: this.encoder }) - if (count !== undefined && count !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, count, 'count') - } - if (portalName !== undefined && portalName !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, portalName, 'portal-name') - } - if (query !== undefined && query !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, query, 'query') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>(`${this.configuration.basePath}/v1/portalItems/search`, { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } -} diff --git a/src/app/generated/api/portalLegacy.service.ts b/src/app/generated/api/portalLegacy.service.ts deleted file mode 100644 index 0e4e061..0000000 --- a/src/app/generated/api/portalLegacy.service.ts +++ /dev/null @@ -1,273 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { MenuItemStructureDtoLegacy } from '../model/menuItemStructureDtoLegacy' -// @ts-ignore -import { MicrofrontendDTOv1 } from '../model/microfrontendDTOv1' -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface GetMenuStructureForPortalIdAndApplicationIdRequestParams { - applicationId: string - portalId: string -} - -export interface GetMenuStructureForPortalNameRequestParams { - portalName: string -} - -@Injectable({ - providedIn: 'any', -}) -export class PortalLegacyAPIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Fetch the menuItems of the portal and application pair in the tree structure - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - * @deprecated - */ - public getMenuStructureForPortalIdAndApplicationId( - requestParameters: GetMenuStructureForPortalIdAndApplicationIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMenuStructureForPortalIdAndApplicationId( - requestParameters: GetMenuStructureForPortalIdAndApplicationIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalIdAndApplicationId( - requestParameters: GetMenuStructureForPortalIdAndApplicationIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalIdAndApplicationId( - requestParameters: GetMenuStructureForPortalIdAndApplicationIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const applicationId = requestParameters.applicationId - if (applicationId === null || applicationId === undefined) { - throw new Error( - 'Required parameter applicationId was null or undefined when calling getMenuStructureForPortalIdAndApplicationId.' - ) - } - const portalId = requestParameters.portalId - if (portalId === null || portalId === undefined) { - throw new Error( - 'Required parameter portalId was null or undefined when calling getMenuStructureForPortalIdAndApplicationId.' - ) - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>( - `${this.configuration.basePath}/legacy/menustructure/${encodeURIComponent(String(portalId))}/${encodeURIComponent( - String(applicationId) - )}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Fetch the menuItems of the portal in the tree structure - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - * @deprecated - */ - public getMenuStructureForPortalName( - requestParameters: GetMenuStructureForPortalNameRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMenuStructureForPortalName( - requestParameters: GetMenuStructureForPortalNameRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalName( - requestParameters: GetMenuStructureForPortalNameRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalName( - requestParameters: GetMenuStructureForPortalNameRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalName = requestParameters.portalName - if (portalName === null || portalName === undefined) { - throw new Error('Required parameter portalName was null or undefined when calling getMenuStructureForPortalName.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>( - `${this.configuration.basePath}/legacy/menustructure/${encodeURIComponent(String(portalName))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/portalV1.service.ts b/src/app/generated/api/portalV1.service.ts deleted file mode 100644 index 2ad747d..0000000 --- a/src/app/generated/api/portalV1.service.ts +++ /dev/null @@ -1,947 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { PortalDTOv1 } from '../model/portalDTOv1' -// @ts-ignore -import { PortalMenuItemDTOv1 } from '../model/portalMenuItemDTOv1' -// @ts-ignore -import { RestException } from '../model/restException' -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' -// @ts-ignore -import { SearchTemplateDTOv1 } from '../model/searchTemplateDTOv1' -// @ts-ignore -import { SearchTemplateSearchCriteria } from '../model/searchTemplateSearchCriteria' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface CreateSearchTemplateRequestParams { - searchTemplateDTOv1?: SearchTemplateDTOv1 -} - -export interface DeleteSearchTemplateRequestParams { - templateId: string -} - -export interface FindBySearchCriteriaRequestParams { - searchTemplateSearchCriteria?: SearchTemplateSearchCriteria -} - -export interface GetDefaultSearchTemplateRequestParams { - application: string - page: string - user: string -} - -export interface GetMenuStructureForPortalNameV1RequestParams { - portalName: string -} - -export interface GetPortalByUrlRequestParams { - url?: string -} - -export interface GetPortalV1RequestParams { - portalName: string -} - -export interface GetSearchTemplateByIdRequestParams { - templateId: string -} - -export interface SynchronizePermissionsRequestParams { - portalName: string -} - -export interface UpdateSearchTemplateRequestParams { - templateId: string - searchTemplateDTOv1?: SearchTemplateDTOv1 -} - -@Injectable({ - providedIn: 'any', -}) -export class PortalV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Creates the search template. - * Creates the search template. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public createSearchTemplate( - requestParameters: CreateSearchTemplateRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public createSearchTemplate( - requestParameters: CreateSearchTemplateRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createSearchTemplate( - requestParameters: CreateSearchTemplateRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createSearchTemplate( - requestParameters: CreateSearchTemplateRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const searchTemplateDTOv1 = requestParameters.searchTemplateDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/v1/searchTemplates`, - searchTemplateDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Deletes the search template. - * Deletes the search template. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteSearchTemplate( - requestParameters: DeleteSearchTemplateRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteSearchTemplate( - requestParameters: DeleteSearchTemplateRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteSearchTemplate( - requestParameters: DeleteSearchTemplateRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteSearchTemplate( - requestParameters: DeleteSearchTemplateRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const templateId = requestParameters.templateId - if (templateId === null || templateId === undefined) { - throw new Error('Required parameter templateId was null or undefined when calling deleteSearchTemplate.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/v1/searchTemplates/${encodeURIComponent(String(templateId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Finds search templates by criteria. - * The search templates are found by search criteria. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public findBySearchCriteria( - requestParameters: FindBySearchCriteriaRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public findBySearchCriteria( - requestParameters: FindBySearchCriteriaRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public findBySearchCriteria( - requestParameters: FindBySearchCriteriaRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public findBySearchCriteria( - requestParameters: FindBySearchCriteriaRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const searchTemplateSearchCriteria = requestParameters.searchTemplateSearchCriteria - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post>( - `${this.configuration.basePath}/v1/searchTemplates/search/criteria`, - searchTemplateSearchCriteria, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Gets the default template for application, page and user. - * The default template for the application, page and user is returned. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getDefaultSearchTemplate( - requestParameters: GetDefaultSearchTemplateRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getDefaultSearchTemplate( - requestParameters: GetDefaultSearchTemplateRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getDefaultSearchTemplate( - requestParameters: GetDefaultSearchTemplateRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getDefaultSearchTemplate( - requestParameters: GetDefaultSearchTemplateRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const application = requestParameters.application - if (application === null || application === undefined) { - throw new Error('Required parameter application was null or undefined when calling getDefaultSearchTemplate.') - } - const page = requestParameters.page - if (page === null || page === undefined) { - throw new Error('Required parameter page was null or undefined when calling getDefaultSearchTemplate.') - } - const user = requestParameters.user - if (user === null || user === undefined) { - throw new Error('Required parameter user was null or undefined when calling getDefaultSearchTemplate.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/v1/searchTemplates/default/${encodeURIComponent( - String(application) - )}/${encodeURIComponent(String(page))}/${encodeURIComponent(String(user))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Fetch the menuItems of the portal in the tree structure - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getMenuStructureForPortalNameV1( - requestParameters: GetMenuStructureForPortalNameV1RequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getMenuStructureForPortalNameV1( - requestParameters: GetMenuStructureForPortalNameV1RequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalNameV1( - requestParameters: GetMenuStructureForPortalNameV1RequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getMenuStructureForPortalNameV1( - requestParameters: GetMenuStructureForPortalNameV1RequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalName = requestParameters.portalName - if (portalName === null || portalName === undefined) { - throw new Error( - 'Required parameter portalName was null or undefined when calling getMenuStructureForPortalNameV1.' - ) - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>( - `${this.configuration.basePath}/v1/portals/${encodeURIComponent(String(portalName))}/menu`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Load portal-, menu-, mfes- and theme-information by current Url - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getPortalByUrl( - requestParameters: GetPortalByUrlRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getPortalByUrl( - requestParameters: GetPortalByUrlRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalByUrl( - requestParameters: GetPortalByUrlRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalByUrl( - requestParameters: GetPortalByUrlRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const url = requestParameters.url - - let localVarQueryParameters = new HttpParams({ encoder: this.encoder }) - if (url !== undefined && url !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, url, 'url') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get(`${this.configuration.basePath}/v1/portals/current`, { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Load a single portal - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getPortalV1( - requestParameters: GetPortalV1RequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getPortalV1( - requestParameters: GetPortalV1RequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalV1( - requestParameters: GetPortalV1RequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getPortalV1( - requestParameters: GetPortalV1RequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalName = requestParameters.portalName - if (portalName === null || portalName === undefined) { - throw new Error('Required parameter portalName was null or undefined when calling getPortalV1.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/v1/portals/${encodeURIComponent(String(portalName))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Finds search templates by it\'s id. - * Gets the search template by it\'s id. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getSearchTemplateById( - requestParameters: GetSearchTemplateByIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getSearchTemplateById( - requestParameters: GetSearchTemplateByIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getSearchTemplateById( - requestParameters: GetSearchTemplateByIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getSearchTemplateById( - requestParameters: GetSearchTemplateByIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const templateId = requestParameters.templateId - if (templateId === null || templateId === undefined) { - throw new Error('Required parameter templateId was null or undefined when calling getSearchTemplateById.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get( - `${this.configuration.basePath}/v1/searchTemplates/${encodeURIComponent(String(templateId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Synchronize permission to apm - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public synchronizePermissions( - requestParameters: SynchronizePermissionsRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public synchronizePermissions( - requestParameters: SynchronizePermissionsRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public synchronizePermissions( - requestParameters: SynchronizePermissionsRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public synchronizePermissions( - requestParameters: SynchronizePermissionsRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const portalName = requestParameters.portalName - if (portalName === null || portalName === undefined) { - throw new Error('Required parameter portalName was null or undefined when calling synchronizePermissions.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/v1/portals/${encodeURIComponent(String(portalName))}/permissionSyncRequest`, - null, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Updates the search template. - * Updates the search template. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public updateSearchTemplate( - requestParameters: UpdateSearchTemplateRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public updateSearchTemplate( - requestParameters: UpdateSearchTemplateRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateSearchTemplate( - requestParameters: UpdateSearchTemplateRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateSearchTemplate( - requestParameters: UpdateSearchTemplateRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const templateId = requestParameters.templateId - if (templateId === null || templateId === undefined) { - throw new Error('Required parameter templateId was null or undefined when calling updateSearchTemplate.') - } - const searchTemplateDTOv1 = requestParameters.searchTemplateDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put( - `${this.configuration.basePath}/v1/searchTemplates/${encodeURIComponent(String(templateId))}`, - searchTemplateDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/api/supportTicketV1.service.ts b/src/app/generated/api/supportTicketV1.service.ts deleted file mode 100644 index 196bb22..0000000 --- a/src/app/generated/api/supportTicketV1.service.ts +++ /dev/null @@ -1,179 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { RestException } from '../model/restException' -// @ts-ignore -import { SupportTicketDTOv1 } from '../model/supportTicketDTOv1' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface SendSupportTicketV1RequestParams { - supportTicketDTOv1?: SupportTicketDTOv1 -} - -@Injectable({ - providedIn: 'any', -}) -export class SupportTicketV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Send support Ticket for an app - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public sendSupportTicketV1( - requestParameters: SendSupportTicketV1RequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public sendSupportTicketV1( - requestParameters: SendSupportTicketV1RequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public sendSupportTicketV1( - requestParameters: SendSupportTicketV1RequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public sendSupportTicketV1( - requestParameters: SendSupportTicketV1RequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const supportTicketDTOv1 = requestParameters.supportTicketDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post(`${this.configuration.basePath}/v1/supportTicket/send`, supportTicketDTOv1, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } -} diff --git a/src/app/generated/api/themes.service.ts b/src/app/generated/api/themes.service.ts index 43aaec8..cba3aa4 100644 --- a/src/app/generated/api/themes.service.ts +++ b/src/app/generated/api/themes.service.ts @@ -1,9 +1,9 @@ /** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT + * onecx-theme-bff + * OneCx theme Bff * + * The version of the OpenAPI document: 1.0 + * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -11,569 +11,732 @@ */ /* tslint:disable:no-unused-variable member-ordering */ -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' +import { Inject, Injectable, Optional } from '@angular/core'; +import { HttpClient, HttpHeaders, HttpParams, + HttpResponse, HttpEvent, HttpParameterCodec, HttpContext + } from '@angular/common/http'; +import { CustomHttpParameterCodec } from '../encoder'; +import { Observable } from 'rxjs'; // @ts-ignore -import { CreateThemeDTO } from '../model/createThemeDTO' +import { CreateThemeRequest } from '../model/createThemeRequest'; +// @ts-ignore +import { CreateThemeResponse } from '../model/createThemeResponse'; +// @ts-ignore +import { ExportThemeRequest } from '../model/exportThemeRequest'; +// @ts-ignore +import { GetThemeResponse } from '../model/getThemeResponse'; +// @ts-ignore +import { GetThemesResponse } from '../model/getThemesResponse'; // @ts-ignore -import { ErrorResponseDTO } from '../model/errorResponseDTO' +import { ImportThemeResponse } from '../model/importThemeResponse'; // @ts-ignore -import { RestException } from '../model/restException' +import { ProblemDetailResponse } from '../model/problemDetailResponse'; // @ts-ignore -import { ThemeDTO } from '../model/themeDTO' +import { SearchThemeRequest } from '../model/searchThemeRequest'; // @ts-ignore -import { UpdateThemeDTO } from '../model/updateThemeDTO' +import { SearchThemeResponse } from '../model/searchThemeResponse'; +// @ts-ignore +import { ThemeSnapshot } from '../model/themeSnapshot'; +// @ts-ignore +import { UpdateThemeRequest } from '../model/updateThemeRequest'; +// @ts-ignore +import { UpdateThemeResponse } from '../model/updateThemeResponse'; // @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' +import { BASE_PATH, COLLECTION_FORMATS } from '../variables'; +import { Configuration } from '../configuration'; + -export interface CreateNewThemeRequestParams { - createThemeDTO?: CreateThemeDTO +export interface CreateThemeRequestParams { + createThemeRequest?: CreateThemeRequest; } export interface DeleteThemeRequestParams { - id: string + id: string; +} + +export interface ExportThemesRequestParams { + exportThemeRequest: ExportThemeRequest; } export interface GetThemeByIdRequestParams { - id: string + id: string; } -export interface GetThemeByThemeDefinitionNameRequestParams { - name: string +export interface GetThemeByNameRequestParams { + name: string; +} + +export interface GetThemesRequestParams { + pageNumber?: number; + pageSize?: number; +} + +export interface ImportThemesRequestParams { + themeSnapshot: ThemeSnapshot; +} + +export interface SearchThemesRequestParams { + searchThemeRequest: SearchThemeRequest; } export interface UpdateThemeRequestParams { - id: string - updateThemeDTO?: UpdateThemeDTO + id: string; + updateThemeRequest?: UpdateThemeRequest; } + @Injectable({ - providedIn: 'any', + providedIn: 'any' }) export class ThemesAPIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams + protected basePath = 'http://onecx-theme-bff:8080'; + public defaultHeaders = new HttpHeaders(); + public configuration = new Configuration(); + public encoder: HttpParameterCodec; + + constructor(protected httpClient: HttpClient, @Optional()@Inject(BASE_PATH) basePath: string|string[], @Optional() configuration: Configuration) { + if (configuration) { + this.configuration = configuration; + } + if (typeof this.configuration.basePath !== 'string') { + if (Array.isArray(basePath) && basePath.length > 0) { + basePath = basePath[0]; + } + + if (typeof basePath !== 'string') { + basePath = this.basePath; + } + this.configuration.basePath = basePath; + } + this.encoder = this.configuration.encoder || new CustomHttpParameterCodec(); } - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) + + // @ts-ignore + private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { + if (typeof value === "object" && value instanceof Date === false) { + httpParams = this.addToHttpParamsRecursive(httpParams, value); } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Create new theme - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public createNewTheme( - requestParameters: CreateNewThemeRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public createNewTheme( - requestParameters: CreateNewThemeRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createNewTheme( - requestParameters: CreateNewThemeRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public createNewTheme( - requestParameters: CreateNewThemeRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const createThemeDTO = requestParameters.createThemeDTO - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) + httpParams = this.addToHttpParamsRecursive(httpParams, value, key); + } + return httpParams; } - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } + private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { + if (value == null) { + return httpParams; + } - // to determine the Content-Type header - const consumes: string[] = ['application/json', 'text/plain'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } + if (typeof value === "object") { + if (Array.isArray(value)) { + (value as any[]).forEach( elem => httpParams = this.addToHttpParamsRecursive(httpParams, elem, key)); + } else if (value instanceof Date) { + if (key != null) { + httpParams = httpParams.append(key, (value as Date).toISOString().substring(0, 10)); + } else { + throw Error("key may not be null if value is Date"); + } + } else { + Object.keys(value).forEach( k => httpParams = this.addToHttpParamsRecursive( + httpParams, value[k], key != null ? `${key}.${k}` : k)); + } + } else if (key != null) { + httpParams = httpParams.append(key, value); + } else { + throw Error("key may not be null if value is not object or array"); + } + return httpParams; + } + + /** + * Create theme + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public createTheme(requestParameters: CreateThemeRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public createTheme(requestParameters: CreateThemeRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public createTheme(requestParameters: CreateThemeRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public createTheme(requestParameters: CreateThemeRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const createThemeRequest = requestParameters.createThemeRequest; + + let localVarHeaders = this.defaultHeaders; + + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - return this.httpClient.post(`${this.configuration.basePath}/internal/themes`, createThemeDTO, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Delete theme by ID - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteTheme( - requestParameters: DeleteThemeRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteTheme( - requestParameters: DeleteThemeRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteTheme( - requestParameters: DeleteThemeRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteTheme( - requestParameters: DeleteThemeRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const id = requestParameters.id - if (id === null || id === undefined) { - throw new Error('Required parameter id was null or undefined when calling deleteTheme.') - } - let localVarHeaders = this.defaultHeaders + // to determine the Content-Type header + const consumes: string[] = [ + 'application/json' + ]; + const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes); + if (httpContentTypeSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected); + } - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } + let localVarPath = `/themes`; + return this.httpClient.request('post', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + body: createThemeRequest, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Delete theme + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public deleteTheme(requestParameters: DeleteThemeRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public deleteTheme(requestParameters: DeleteThemeRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public deleteTheme(requestParameters: DeleteThemeRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public deleteTheme(requestParameters: DeleteThemeRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const id = requestParameters.id; + if (id === null || id === undefined) { + throw new Error('Required parameter id was null or undefined when calling deleteTheme.'); + } - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } + let localVarHeaders = this.defaultHeaders; - return this.httpClient.delete( - `${this.configuration.basePath}/internal/themes/${encodeURIComponent(String(id))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Return theme by ID - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getThemeById( - requestParameters: GetThemeByIdRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getThemeById( - requestParameters: GetThemeByIdRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getThemeById( - requestParameters: GetThemeByIdRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getThemeById( - requestParameters: GetThemeByIdRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const id = requestParameters.id - if (id === null || id === undefined) { - throw new Error('Required parameter id was null or undefined when calling getThemeById.') - } + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } - let localVarHeaders = this.defaultHeaders + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } + let localVarPath = `/themes/${this.configuration.encodeParam({name: "id", value: id, in: "path", style: "simple", explode: false, dataType: "string", dataFormat: undefined})}`; + return this.httpClient.request('delete', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Export list of themes + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public exportThemes(requestParameters: ExportThemesRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public exportThemes(requestParameters: ExportThemesRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public exportThemes(requestParameters: ExportThemesRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public exportThemes(requestParameters: ExportThemesRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const exportThemeRequest = requestParameters.exportThemeRequest; + if (exportThemeRequest === null || exportThemeRequest === undefined) { + throw new Error('Required parameter exportThemeRequest was null or undefined when calling exportThemes.'); + } - return this.httpClient.get( - `${this.configuration.basePath}/internal/themes/id/${encodeURIComponent(String(id))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Load a single theme definition - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - * @deprecated - */ - public getThemeByThemeDefinitionName( - requestParameters: GetThemeByThemeDefinitionNameRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getThemeByThemeDefinitionName( - requestParameters: GetThemeByThemeDefinitionNameRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getThemeByThemeDefinitionName( - requestParameters: GetThemeByThemeDefinitionNameRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getThemeByThemeDefinitionName( - requestParameters: GetThemeByThemeDefinitionNameRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const name = requestParameters.name - if (name === null || name === undefined) { - throw new Error('Required parameter name was null or undefined when calling getThemeByThemeDefinitionName.') - } + let localVarHeaders = this.defaultHeaders; - let localVarHeaders = this.defaultHeaders + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } + // to determine the Content-Type header + const consumes: string[] = [ + 'application/json' + ]; + const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes); + if (httpContentTypeSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected); + } - return this.httpClient.get( - `${this.configuration.basePath}/internal/themes/${encodeURIComponent(String(name))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Return list of themes - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getThemes( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getThemes( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getThemes( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getThemes( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } + let localVarPath = `/themes/export`; + return this.httpClient.request('post', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + body: exportThemeRequest, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Find theme by id + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public getThemeById(requestParameters: GetThemeByIdRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public getThemeById(requestParameters: GetThemeByIdRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public getThemeById(requestParameters: GetThemeByIdRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public getThemeById(requestParameters: GetThemeByIdRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const id = requestParameters.id; + if (id === null || id === undefined) { + throw new Error('Required parameter id was null or undefined when calling getThemeById.'); + } - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } + let localVarHeaders = this.defaultHeaders; - return this.httpClient.get>(`${this.configuration.basePath}/internal/themes`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Update theme by ID - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public updateTheme( - requestParameters: UpdateThemeRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public updateTheme( - requestParameters: UpdateThemeRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateTheme( - requestParameters: UpdateThemeRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateTheme( - requestParameters: UpdateThemeRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const id = requestParameters.id - if (id === null || id === undefined) { - throw new Error('Required parameter id was null or undefined when calling updateTheme.') - } - const updateThemeDTO = requestParameters.updateThemeDTO + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } - let localVarHeaders = this.defaultHeaders + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } - // to determine the Content-Type header - const consumes: string[] = ['application/json', 'text/plain'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } + let localVarPath = `/themes/${this.configuration.encodeParam({name: "id", value: id, in: "path", style: "simple", explode: false, dataType: "string", dataFormat: undefined})}`; + return this.httpClient.request('get', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Find theme by name including workspace + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public getThemeByName(requestParameters: GetThemeByNameRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public getThemeByName(requestParameters: GetThemeByNameRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public getThemeByName(requestParameters: GetThemeByNameRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public getThemeByName(requestParameters: GetThemeByNameRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const name = requestParameters.name; + if (name === null || name === undefined) { + throw new Error('Required parameter name was null or undefined when calling getThemeByName.'); + } + + let localVarHeaders = this.defaultHeaders; + + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } + + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } + + let localVarPath = `/themes/name/${this.configuration.encodeParam({name: "name", value: name, in: "path", style: "simple", explode: false, dataType: "string", dataFormat: undefined})}`; + return this.httpClient.request('get', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Find all themes + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public getThemes(requestParameters: GetThemesRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public getThemes(requestParameters: GetThemesRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public getThemes(requestParameters: GetThemesRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public getThemes(requestParameters: GetThemesRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const pageNumber = requestParameters.pageNumber; + const pageSize = requestParameters.pageSize; + + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); + if (pageNumber !== undefined && pageNumber !== null) { + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, + pageNumber, 'pageNumber'); + } + if (pageSize !== undefined && pageSize !== null) { + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, + pageSize, 'pageSize'); + } + + let localVarHeaders = this.defaultHeaders; + + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } + + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } + + let localVarPath = `/themes`; + return this.httpClient.request('get', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Import themes + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public importThemes(requestParameters: ImportThemesRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public importThemes(requestParameters: ImportThemesRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public importThemes(requestParameters: ImportThemesRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public importThemes(requestParameters: ImportThemesRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const themeSnapshot = requestParameters.themeSnapshot; + if (themeSnapshot === null || themeSnapshot === undefined) { + throw new Error('Required parameter themeSnapshot was null or undefined when calling importThemes.'); + } + + let localVarHeaders = this.defaultHeaders; + + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } + + + // to determine the Content-Type header + const consumes: string[] = [ + 'application/json' + ]; + const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes); + if (httpContentTypeSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected); + } + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } + + let localVarPath = `/themes/import`; + return this.httpClient.request('post', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + body: themeSnapshot, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Search themes by criteria + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public searchThemes(requestParameters: SearchThemesRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public searchThemes(requestParameters: SearchThemesRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public searchThemes(requestParameters: SearchThemesRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public searchThemes(requestParameters: SearchThemesRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const searchThemeRequest = requestParameters.searchThemeRequest; + if (searchThemeRequest === null || searchThemeRequest === undefined) { + throw new Error('Required parameter searchThemeRequest was null or undefined when calling searchThemes.'); + } + + let localVarHeaders = this.defaultHeaders; + + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } + + + // to determine the Content-Type header + const consumes: string[] = [ + 'application/json' + ]; + const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes); + if (httpContentTypeSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected); + } + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } + + let localVarPath = `/themes/search`; + return this.httpClient.request('post', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + body: searchThemeRequest, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); + } + + /** + * Update theme + * @param requestParameters + * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. + * @param reportProgress flag to report request and response progress. + */ + public updateTheme(requestParameters: UpdateThemeRequestParams, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable; + public updateTheme(requestParameters: UpdateThemeRequestParams, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public updateTheme(requestParameters: UpdateThemeRequestParams, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable>; + public updateTheme(requestParameters: UpdateThemeRequestParams, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable { + const id = requestParameters.id; + if (id === null || id === undefined) { + throw new Error('Required parameter id was null or undefined when calling updateTheme.'); + } + const updateThemeRequest = requestParameters.updateThemeRequest; + + let localVarHeaders = this.defaultHeaders; + + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { + // to determine the Accept header + const httpHeaderAccepts: string[] = [ + 'application/json' + ]; + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } + + + // to determine the Content-Type header + const consumes: string[] = [ + 'application/json' + ]; + const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes); + if (httpContentTypeSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected); + } + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } + let localVarPath = `/themes/${this.configuration.encodeParam({name: "id", value: id, in: "path", style: "simple", explode: false, dataType: "string", dataFormat: undefined})}`; + return this.httpClient.request('put', `${this.configuration.basePath}${localVarPath}`, + { + context: localVarHttpContext, + body: updateThemeRequest, + responseType: responseType_, + withCredentials: this.configuration.withCredentials, + headers: localVarHeaders, + observe: observe, + reportProgress: reportProgress + } + ); } - return this.httpClient.put( - `${this.configuration.basePath}/internal/themes/${encodeURIComponent(String(id))}`, - updateThemeDTO, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } } diff --git a/src/app/generated/api/userInfoV1.service.ts b/src/app/generated/api/userInfoV1.service.ts deleted file mode 100644 index fde7ac7..0000000 --- a/src/app/generated/api/userInfoV1.service.ts +++ /dev/null @@ -1,262 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' -// @ts-ignore -import { UserInfoDTOv1 } from '../model/userInfoDTOv1' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface SearchAvatarIdsRequestParams { - userId?: Array -} - -export interface SearchUsersRequestParams { - q?: string -} - -@Injectable({ - providedIn: 'any', -}) -export class UserInfoV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Search for Avatar ids for selected users - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - * @deprecated - */ - public searchAvatarIds( - requestParameters: SearchAvatarIdsRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable> - public searchAvatarIds( - requestParameters: SearchAvatarIdsRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable>> - public searchAvatarIds( - requestParameters: SearchAvatarIdsRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable>> - public searchAvatarIds( - requestParameters: SearchAvatarIdsRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable { - const userId = requestParameters.userId - - let localVarQueryParameters = new HttpParams({ encoder: this.encoder }) - if (userId) { - userId.forEach((element) => { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, element, 'userId') - }) - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json', 'text/plain'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>(`${this.configuration.basePath}/v1/userInfo/avatarIds`, { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Search for users - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - * @deprecated - */ - public searchUsers( - requestParameters: SearchUsersRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable> - public searchUsers( - requestParameters: SearchUsersRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable>> - public searchUsers( - requestParameters: SearchUsersRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable>> - public searchUsers( - requestParameters: SearchUsersRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json' | 'text/plain'; context?: HttpContext } - ): Observable { - const q = requestParameters.q - - let localVarQueryParameters = new HttpParams({ encoder: this.encoder }) - if (q !== undefined && q !== null) { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, q, 'q') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json', 'text/plain'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>(`${this.configuration.basePath}/v1/userInfo`, { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } -} diff --git a/src/app/generated/api/userProfileV1.service.ts b/src/app/generated/api/userProfileV1.service.ts deleted file mode 100644 index 1517066..0000000 --- a/src/app/generated/api/userProfileV1.service.ts +++ /dev/null @@ -1,952 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -/* tslint:disable:no-unused-variable member-ordering */ - -import { Inject, Injectable, Optional } from '@angular/core' -import { - HttpClient, - HttpHeaders, - HttpParams, - HttpResponse, - HttpEvent, - HttpParameterCodec, - HttpContext, -} from '@angular/common/http' -import { CustomHttpParameterCodec } from '../encoder' -import { Observable } from 'rxjs' - -// @ts-ignore -import { AccountSettingsDTOv1 } from '../model/accountSettingsDTOv1' -// @ts-ignore -import { PreferencesDTOv1 } from '../model/preferencesDTOv1' -// @ts-ignore -import { ResetPasswordDTOv1 } from '../model/resetPasswordDTOv1' -// @ts-ignore -import { RestException } from '../model/restException' -// @ts-ignore -import { RestExceptionDTO } from '../model/restExceptionDTO' -// @ts-ignore -import { UserPersonDTOv1 } from '../model/userPersonDTOv1' -// @ts-ignore -import { UserProfileDTOv1 } from '../model/userProfileDTOv1' - -// @ts-ignore -import { BASE_PATH, COLLECTION_FORMATS } from '../variables' -import { Configuration } from '../configuration' - -export interface DeleteUserPreferenceRequestParams { - preferenceId: string -} - -export interface GetUserProfileRequestParams { - applicationIds?: Array -} - -export interface PatchUserPreferenceRequestParams { - preferenceId: string - body?: string -} - -export interface ResetKeycloakUserPasswordRequestParams { - resetPasswordDTOv1?: ResetPasswordDTOv1 -} - -export interface StoreUserPreferenceRequestParams { - preferencesDTOv1?: PreferencesDTOv1 -} - -export interface UpdateUserPersonRequestParams { - userPersonDTOv1?: UserPersonDTOv1 -} - -export interface UpdateUserSettingsRequestParams { - accountSettingsDTOv1?: AccountSettingsDTOv1 -} - -@Injectable({ - providedIn: 'any', -}) -export class UserProfileV1APIService { - protected basePath = 'http://localhost' - public defaultHeaders = new HttpHeaders() - public configuration = new Configuration() - public encoder: HttpParameterCodec - - constructor( - protected httpClient: HttpClient, - @Optional() @Inject(BASE_PATH) basePath: string, - @Optional() configuration: Configuration - ) { - if (configuration) { - this.configuration = configuration - } - if (typeof this.configuration.basePath !== 'string') { - if (typeof basePath !== 'string') { - basePath = this.basePath - } - this.configuration.basePath = basePath - } - this.encoder = this.configuration.encoder || new CustomHttpParameterCodec() - } - - // @ts-ignore - private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { - if (typeof value === 'object' && value instanceof Date === false) { - httpParams = this.addToHttpParamsRecursive(httpParams, value) - } else { - httpParams = this.addToHttpParamsRecursive(httpParams, value, key) - } - return httpParams - } - - private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams { - if (value == null) { - return httpParams - } - - if (typeof value === 'object') { - if (Array.isArray(value)) { - ;(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key))) - } else if (value instanceof Date) { - if (key != null) { - httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10)) - } else { - throw Error('key may not be null if value is Date') - } - } else { - Object.keys(value).forEach( - (k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)) - ) - } - } else if (key != null) { - httpParams = httpParams.append(key, value) - } else { - throw Error('key may not be null if value is not object or array') - } - return httpParams - } - - /** - * Delete user\'s preference - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteUserPreference( - requestParameters: DeleteUserPreferenceRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteUserPreference( - requestParameters: DeleteUserPreferenceRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserPreference( - requestParameters: DeleteUserPreferenceRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserPreference( - requestParameters: DeleteUserPreferenceRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const preferenceId = requestParameters.preferenceId - if (preferenceId === null || preferenceId === undefined) { - throw new Error('Required parameter preferenceId was null or undefined when calling deleteUserPreference.') - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete( - `${this.configuration.basePath}/v1/userProfile/me/preference/${encodeURIComponent(String(preferenceId))}`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Delete current user - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public deleteUserProfile( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public deleteUserProfile( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserProfile( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public deleteUserProfile( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.delete(`${this.configuration.basePath}/v1/userProfile/me`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Load user profile by user Id - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getUserPerson( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getUserPerson( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserPerson( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserPerson( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get(`${this.configuration.basePath}/v1/userProfile/me/userPerson`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Get user\'s preferences - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getUserPreferences( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserPreferences( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getUserPreferences( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable>> - public getUserPreferences( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get>( - `${this.configuration.basePath}/v1/userProfile/me/preferences`, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Load user profile by user Id - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getUserProfile( - requestParameters: GetUserProfileRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getUserProfile( - requestParameters: GetUserProfileRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserProfile( - requestParameters: GetUserProfileRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserProfile( - requestParameters: GetUserProfileRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const applicationIds = requestParameters.applicationIds - - let localVarQueryParameters = new HttpParams({ encoder: this.encoder }) - if (applicationIds) { - applicationIds.forEach((element) => { - localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, element, 'applicationIds') - }) - } - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get(`${this.configuration.basePath}/v1/userProfile/me`, { - context: localVarHttpContext, - params: localVarQueryParameters, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Get user\'s settings - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public getUserSettings( - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public getUserSettings( - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserSettings( - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public getUserSettings( - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.get(`${this.configuration.basePath}/v1/userProfile/me/settings`, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Patch user\'s preference - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public patchUserPreference( - requestParameters: PatchUserPreferenceRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public patchUserPreference( - requestParameters: PatchUserPreferenceRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public patchUserPreference( - requestParameters: PatchUserPreferenceRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public patchUserPreference( - requestParameters: PatchUserPreferenceRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const preferenceId = requestParameters.preferenceId - if (preferenceId === null || preferenceId === undefined) { - throw new Error('Required parameter preferenceId was null or undefined when calling patchUserPreference.') - } - const body = requestParameters.body - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.patch( - `${this.configuration.basePath}/v1/userProfile/me/preference/${encodeURIComponent(String(preferenceId))}`, - body, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Reset Keycloak User\'s password - * The password of user registered in keycloak is set to the new one. - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public resetKeycloakUserPassword( - requestParameters: ResetKeycloakUserPasswordRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: undefined; context?: HttpContext } - ): Observable - public resetKeycloakUserPassword( - requestParameters: ResetKeycloakUserPasswordRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: undefined; context?: HttpContext } - ): Observable> - public resetKeycloakUserPassword( - requestParameters: ResetKeycloakUserPasswordRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: undefined; context?: HttpContext } - ): Observable> - public resetKeycloakUserPassword( - requestParameters: ResetKeycloakUserPasswordRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: undefined; context?: HttpContext } - ): Observable { - const resetPasswordDTOv1 = requestParameters.resetPasswordDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = [] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put( - `${this.configuration.basePath}/v1/userProfile/me/change-password`, - resetPasswordDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Store user\'s preference - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public storeUserPreference( - requestParameters: StoreUserPreferenceRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public storeUserPreference( - requestParameters: StoreUserPreferenceRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public storeUserPreference( - requestParameters: StoreUserPreferenceRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public storeUserPreference( - requestParameters: StoreUserPreferenceRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const preferencesDTOv1 = requestParameters.preferencesDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.post( - `${this.configuration.basePath}/v1/userProfile/me/preference`, - preferencesDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } - - /** - * Update user person data - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public updateUserPerson( - requestParameters: UpdateUserPersonRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'text/plain' | 'application/json'; context?: HttpContext } - ): Observable - public updateUserPerson( - requestParameters: UpdateUserPersonRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'text/plain' | 'application/json'; context?: HttpContext } - ): Observable> - public updateUserPerson( - requestParameters: UpdateUserPersonRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'text/plain' | 'application/json'; context?: HttpContext } - ): Observable> - public updateUserPerson( - requestParameters: UpdateUserPersonRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'text/plain' | 'application/json'; context?: HttpContext } - ): Observable { - const userPersonDTOv1 = requestParameters.userPersonDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['text/plain', 'application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.put(`${this.configuration.basePath}/v1/userProfile/me/userPerson`, userPersonDTOv1, { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - }) - } - - /** - * Update user\'s settings - * @param requestParameters - * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. - * @param reportProgress flag to report request and response progress. - */ - public updateUserSettings( - requestParameters: UpdateUserSettingsRequestParams, - observe?: 'body', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable - public updateUserSettings( - requestParameters: UpdateUserSettingsRequestParams, - observe?: 'response', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateUserSettings( - requestParameters: UpdateUserSettingsRequestParams, - observe?: 'events', - reportProgress?: boolean, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable> - public updateUserSettings( - requestParameters: UpdateUserSettingsRequestParams, - observe: any = 'body', - reportProgress: boolean = false, - options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext } - ): Observable { - const accountSettingsDTOv1 = requestParameters.accountSettingsDTOv1 - - let localVarHeaders = this.defaultHeaders - - let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept - if (localVarHttpHeaderAcceptSelected === undefined) { - // to determine the Accept header - const httpHeaderAccepts: string[] = ['application/json'] - localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts) - } - if (localVarHttpHeaderAcceptSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected) - } - - let localVarHttpContext: HttpContext | undefined = options && options.context - if (localVarHttpContext === undefined) { - localVarHttpContext = new HttpContext() - } - - // to determine the Content-Type header - const consumes: string[] = ['application/json'] - const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes) - if (httpContentTypeSelected !== undefined) { - localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected) - } - - let responseType_: 'text' | 'json' | 'blob' = 'json' - if (localVarHttpHeaderAcceptSelected) { - if (localVarHttpHeaderAcceptSelected.startsWith('text')) { - responseType_ = 'text' - } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { - responseType_ = 'json' - } else { - responseType_ = 'blob' - } - } - - return this.httpClient.patch( - `${this.configuration.basePath}/v1/userProfile/me/settings`, - accountSettingsDTOv1, - { - context: localVarHttpContext, - responseType: responseType_, - withCredentials: this.configuration.withCredentials, - headers: localVarHeaders, - observe: observe, - reportProgress: reportProgress, - } - ) - } -} diff --git a/src/app/generated/configuration.ts b/src/app/generated/configuration.ts index 3d93662..526b454 100644 --- a/src/app/generated/configuration.ts +++ b/src/app/generated/configuration.ts @@ -1,118 +1,166 @@ -import { HttpParameterCodec } from '@angular/common/http' +import { HttpParameterCodec } from '@angular/common/http'; +import { Param } from './param'; export interface ConfigurationParameters { - /** - * @deprecated Since 5.0. Use credentials instead - */ - apiKeys?: { [key: string]: string } - username?: string - password?: string - /** - * @deprecated Since 5.0. Use credentials instead - */ - accessToken?: string | (() => string) - basePath?: string - withCredentials?: boolean - encoder?: HttpParameterCodec - /** - * The keys are the names in the securitySchemes section of the OpenAPI - * document. They should map to the value used for authentication - * minus any standard prefixes such as 'Basic' or 'Bearer'. - */ - credentials?: { [key: string]: string | (() => string | undefined) } + /** + * @deprecated Since 5.0. Use credentials instead + */ + apiKeys?: {[ key: string ]: string}; + username?: string; + password?: string; + /** + * @deprecated Since 5.0. Use credentials instead + */ + accessToken?: string | (() => string); + basePath?: string; + withCredentials?: boolean; + /** + * Takes care of encoding query- and form-parameters. + */ + encoder?: HttpParameterCodec; + /** + * Override the default method for encoding path parameters in various + * styles. + *

+ * See {@link README.md} for more details + *

+ */ + encodeParam?: (param: Param) => string; + /** + * The keys are the names in the securitySchemes section of the OpenAPI + * document. They should map to the value used for authentication + * minus any standard prefixes such as 'Basic' or 'Bearer'. + */ + credentials?: {[ key: string ]: string | (() => string | undefined)}; } export class Configuration { - /** - * @deprecated Since 5.0. Use credentials instead - */ - apiKeys?: { [key: string]: string } - username?: string - password?: string - /** - * @deprecated Since 5.0. Use credentials instead - */ - accessToken?: string | (() => string) - basePath?: string - withCredentials?: boolean - encoder?: HttpParameterCodec - /** - * The keys are the names in the securitySchemes section of the OpenAPI - * document. They should map to the value used for authentication - * minus any standard prefixes such as 'Basic' or 'Bearer'. - */ - credentials: { [key: string]: string | (() => string | undefined) } + /** + * @deprecated Since 5.0. Use credentials instead + */ + apiKeys?: {[ key: string ]: string}; + username?: string; + password?: string; + /** + * @deprecated Since 5.0. Use credentials instead + */ + accessToken?: string | (() => string); + basePath?: string; + withCredentials?: boolean; + /** + * Takes care of encoding query- and form-parameters. + */ + encoder?: HttpParameterCodec; + /** + * Encoding of various path parameter + * styles. + *

+ * See {@link README.md} for more details + *

+ */ + encodeParam: (param: Param) => string; + /** + * The keys are the names in the securitySchemes section of the OpenAPI + * document. They should map to the value used for authentication + * minus any standard prefixes such as 'Basic' or 'Bearer'. + */ + credentials: {[ key: string ]: string | (() => string | undefined)}; - constructor(configurationParameters: ConfigurationParameters = {}) { - this.apiKeys = configurationParameters.apiKeys - this.username = configurationParameters.username - this.password = configurationParameters.password - this.accessToken = configurationParameters.accessToken - this.basePath = configurationParameters.basePath - this.withCredentials = configurationParameters.withCredentials - this.encoder = configurationParameters.encoder - if (configurationParameters.credentials) { - this.credentials = configurationParameters.credentials - } else { - this.credentials = {} + constructor(configurationParameters: ConfigurationParameters = {}) { + this.apiKeys = configurationParameters.apiKeys; + this.username = configurationParameters.username; + this.password = configurationParameters.password; + this.accessToken = configurationParameters.accessToken; + this.basePath = configurationParameters.basePath; + this.withCredentials = configurationParameters.withCredentials; + this.encoder = configurationParameters.encoder; + if (configurationParameters.encodeParam) { + this.encodeParam = configurationParameters.encodeParam; + } + else { + this.encodeParam = param => this.defaultEncodeParam(param); + } + if (configurationParameters.credentials) { + this.credentials = configurationParameters.credentials; + } + else { + this.credentials = {}; + } } - } - /** - * Select the correct content-type to use for a request. - * Uses {@link Configuration#isJsonMime} to determine the correct content-type. - * If no content type is found return the first found type if the contentTypes is not empty - * @param contentTypes - the array of content types that are available for selection - * @returns the selected content-type or undefined if no selection could be made. - */ - public selectHeaderContentType(contentTypes: string[]): string | undefined { - if (contentTypes.length === 0) { - return undefined + /** + * Select the correct content-type to use for a request. + * Uses {@link Configuration#isJsonMime} to determine the correct content-type. + * If no content type is found return the first found type if the contentTypes is not empty + * @param contentTypes - the array of content types that are available for selection + * @returns the selected content-type or undefined if no selection could be made. + */ + public selectHeaderContentType (contentTypes: string[]): string | undefined { + if (contentTypes.length === 0) { + return undefined; + } + + const type = contentTypes.find((x: string) => this.isJsonMime(x)); + if (type === undefined) { + return contentTypes[0]; + } + return type; } - const type = contentTypes.find((x: string) => this.isJsonMime(x)) - if (type === undefined) { - return contentTypes[0] + /** + * Select the correct accept content-type to use for a request. + * Uses {@link Configuration#isJsonMime} to determine the correct accept content-type. + * If no content type is found return the first found type if the contentTypes is not empty + * @param accepts - the array of content types that are available for selection. + * @returns the selected content-type or undefined if no selection could be made. + */ + public selectHeaderAccept(accepts: string[]): string | undefined { + if (accepts.length === 0) { + return undefined; + } + + const type = accepts.find((x: string) => this.isJsonMime(x)); + if (type === undefined) { + return accepts[0]; + } + return type; } - return type - } - /** - * Select the correct accept content-type to use for a request. - * Uses {@link Configuration#isJsonMime} to determine the correct accept content-type. - * If no content type is found return the first found type if the contentTypes is not empty - * @param accepts - the array of content types that are available for selection. - * @returns the selected content-type or undefined if no selection could be made. - */ - public selectHeaderAccept(accepts: string[]): string | undefined { - if (accepts.length === 0) { - return undefined + /** + * Check if the given MIME is a JSON MIME. + * JSON MIME examples: + * application/json + * application/json; charset=UTF8 + * APPLICATION/JSON + * application/vnd.company+json + * @param mime - MIME (Multipurpose Internet Mail Extensions) + * @return True if the given MIME is JSON, false otherwise. + */ + public isJsonMime(mime: string): boolean { + const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i'); + return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json'); } - const type = accepts.find((x: string) => this.isJsonMime(x)) - if (type === undefined) { - return accepts[0] + public lookupCredential(key: string): string | undefined { + const value = this.credentials[key]; + return typeof value === 'function' + ? value() + : value; } - return type - } - /** - * Check if the given MIME is a JSON MIME. - * JSON MIME examples: - * application/json - * application/json; charset=UTF8 - * APPLICATION/JSON - * application/vnd.company+json - * @param mime - MIME (Multipurpose Internet Mail Extensions) - * @return True if the given MIME is JSON, false otherwise. - */ - public isJsonMime(mime: string): boolean { - const jsonMime: RegExp = new RegExp('^(application/json|[^;/ \t]+/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i') - return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json') - } + private defaultEncodeParam(param: Param): string { + // This implementation exists as fallback for missing configuration + // and for backwards compatibility to older typescript-angular generator versions. + // It only works for the 'simple' parameter style. + // Date-handling only works for the 'date-time' format. + // All other styles and Date-formats are probably handled incorrectly. + // + // But: if that's all you need (i.e.: the most common use-case): no need for customization! - public lookupCredential(key: string): string | undefined { - const value = this.credentials[key] - return typeof value === 'function' ? value() : value - } + const value = param.dataFormat === 'date-time' && param.value instanceof Date + ? (param.value as Date).toISOString() + : param.value; + + return encodeURIComponent(String(value)); + } } diff --git a/src/app/generated/encoder.ts b/src/app/generated/encoder.ts index e5d6561..138c4d5 100644 --- a/src/app/generated/encoder.ts +++ b/src/app/generated/encoder.ts @@ -1,20 +1,20 @@ -import { HttpParameterCodec } from '@angular/common/http' +import { HttpParameterCodec } from '@angular/common/http'; /** * Custom HttpParameterCodec * Workaround for https://github.com/angular/angular/issues/18261 */ export class CustomHttpParameterCodec implements HttpParameterCodec { - encodeKey(k: string): string { - return encodeURIComponent(k) - } - encodeValue(v: string): string { - return encodeURIComponent(v) - } - decodeKey(k: string): string { - return decodeURIComponent(k) - } - decodeValue(v: string): string { - return decodeURIComponent(v) - } + encodeKey(k: string): string { + return encodeURIComponent(k); + } + encodeValue(v: string): string { + return encodeURIComponent(v); + } + decodeKey(k: string): string { + return decodeURIComponent(k); + } + decodeValue(v: string): string { + return decodeURIComponent(v); + } } diff --git a/src/app/generated/index.ts b/src/app/generated/index.ts index 8e6723a..104dd3d 100644 --- a/src/app/generated/index.ts +++ b/src/app/generated/index.ts @@ -1,5 +1,6 @@ -export * from './api/api' -export * from './model/models' -export * from './variables' -export * from './configuration' -export * from './api.module' +export * from './api/api'; +export * from './model/models'; +export * from './variables'; +export * from './configuration'; +export * from './api.module'; +export * from './param'; diff --git a/src/app/generated/model/accountSettingsDTO.ts b/src/app/generated/model/accountSettingsDTO.ts deleted file mode 100644 index 5be4c0a..0000000 --- a/src/app/generated/model/accountSettingsDTO.ts +++ /dev/null @@ -1,29 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { AccountSettingsDTOLocaleAndTimeSettings } from './accountSettingsDTOLocaleAndTimeSettings' -import { AccountSettingsDTOPrivacySettings } from './accountSettingsDTOPrivacySettings' -import { AccountSettingsDTOLayoutAndThemeSettings } from './accountSettingsDTOLayoutAndThemeSettings' -import { PreferencesDTO } from './preferencesDTO' - -export interface AccountSettingsDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - privacySettings?: AccountSettingsDTOPrivacySettings - localeAndTimeSettings?: AccountSettingsDTOLocaleAndTimeSettings - preferences?: Array - notificationSettings?: object | null - layoutAndThemeSettings?: AccountSettingsDTOLayoutAndThemeSettings -} diff --git a/src/app/generated/model/accountSettingsDTOLayoutAndThemeSettings.ts b/src/app/generated/model/accountSettingsDTOLayoutAndThemeSettings.ts deleted file mode 100644 index 1c011ed..0000000 --- a/src/app/generated/model/accountSettingsDTOLayoutAndThemeSettings.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { LayoutAndThemeDTO } from './layoutAndThemeDTO' -import { ColorScheme } from './colorScheme' -import { MenuMode } from './menuMode' - -export interface AccountSettingsDTOLayoutAndThemeSettings { - menuMode?: MenuMode | null - colorScheme?: ColorScheme | null -} diff --git a/src/app/generated/model/accountSettingsDTOLocaleAndTimeSettings.ts b/src/app/generated/model/accountSettingsDTOLocaleAndTimeSettings.ts deleted file mode 100644 index f6a23e1..0000000 --- a/src/app/generated/model/accountSettingsDTOLocaleAndTimeSettings.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { LocaleAndTimeSettingsDTO } from './localeAndTimeSettingsDTO' - -export interface AccountSettingsDTOLocaleAndTimeSettings { - /** - * - */ - locale?: string - /** - * - */ - timezone?: string -} diff --git a/src/app/generated/model/accountSettingsDTOPrivacySettings.ts b/src/app/generated/model/accountSettingsDTOPrivacySettings.ts deleted file mode 100644 index 4320a4f..0000000 --- a/src/app/generated/model/accountSettingsDTOPrivacySettings.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PrivacySettingsDTO } from './privacySettingsDTO' - -export interface AccountSettingsDTOPrivacySettings { - /** - * Flag whether profile should be hidden or not - */ - hideMyProfile?: boolean -} diff --git a/src/app/generated/model/accountSettingsDTOv1.ts b/src/app/generated/model/accountSettingsDTOv1.ts deleted file mode 100644 index 7ce4d07..0000000 --- a/src/app/generated/model/accountSettingsDTOv1.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { AccountSettingsDTOv1PrivacySettings } from './accountSettingsDTOv1PrivacySettings' -import { AccountSettingsDTOv1LocaleAndTimeSettings } from './accountSettingsDTOv1LocaleAndTimeSettings' -import { AccountSettingsDTOv1LayoutAndThemeSettings } from './accountSettingsDTOv1LayoutAndThemeSettings' - -export interface AccountSettingsDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - privacySettings?: AccountSettingsDTOv1PrivacySettings - localeAndTimeSettings?: AccountSettingsDTOv1LocaleAndTimeSettings - notificationSettings?: object | null - layoutAndThemeSettings?: AccountSettingsDTOv1LayoutAndThemeSettings -} diff --git a/src/app/generated/model/accountSettingsDTOv1LayoutAndThemeSettings.ts b/src/app/generated/model/accountSettingsDTOv1LayoutAndThemeSettings.ts deleted file mode 100644 index ac8cbbb..0000000 --- a/src/app/generated/model/accountSettingsDTOv1LayoutAndThemeSettings.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ColorSchemeV1 } from './colorSchemeV1' -import { LayoutAndThemeDTOv1 } from './layoutAndThemeDTOv1' -import { MenuModeV1 } from './menuModeV1' - -export interface AccountSettingsDTOv1LayoutAndThemeSettings { - menuMode?: MenuModeV1 | null - colorScheme?: ColorSchemeV1 | null -} diff --git a/src/app/generated/model/accountSettingsDTOv1LocaleAndTimeSettings.ts b/src/app/generated/model/accountSettingsDTOv1LocaleAndTimeSettings.ts deleted file mode 100644 index a1d3709..0000000 --- a/src/app/generated/model/accountSettingsDTOv1LocaleAndTimeSettings.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { LocaleAndTimeSettingsDTOv1 } from './localeAndTimeSettingsDTOv1' - -export interface AccountSettingsDTOv1LocaleAndTimeSettings { - /** - * - */ - locale?: string - /** - * - */ - timezone?: string -} diff --git a/src/app/generated/model/accountSettingsDTOv1PrivacySettings.ts b/src/app/generated/model/accountSettingsDTOv1PrivacySettings.ts deleted file mode 100644 index ed605ea..0000000 --- a/src/app/generated/model/accountSettingsDTOv1PrivacySettings.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PrivacySettingsDTOv1 } from './privacySettingsDTOv1' - -export interface AccountSettingsDTOv1PrivacySettings { - /** - * Flag whether profile should be hidden or not - */ - hideMyProfile?: boolean -} diff --git a/src/app/generated/model/colorScheme.ts b/src/app/generated/model/colorScheme.ts deleted file mode 100644 index c019e99..0000000 --- a/src/app/generated/model/colorScheme.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum ColorScheme { - Auto = 'AUTO', - Light = 'LIGHT', - Dark = 'DARK', -} diff --git a/src/app/generated/model/colorSchemeV1.ts b/src/app/generated/model/colorSchemeV1.ts deleted file mode 100644 index f2d01d2..0000000 --- a/src/app/generated/model/colorSchemeV1.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum ColorSchemeV1 { - Auto = 'AUTO', - Light = 'LIGHT', - Dark = 'DARK', -} diff --git a/src/app/generated/model/createMicrofrontendDTOv1.ts b/src/app/generated/model/createMicrofrontendDTOv1.ts deleted file mode 100644 index 0854fe2..0000000 --- a/src/app/generated/model/createMicrofrontendDTOv1.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ModuleTypeV1 } from './moduleTypeV1' - -export interface CreateMicrofrontendDTOv1 { - remoteEntry: string - remoteName: string - exposedModule: string - displayName: string - moduleType: ModuleTypeV1 | null - wcTagName?: string - appId?: string - appVersion?: string - note?: string - contact?: string - remoteBaseUrl: string -} diff --git a/src/app/generated/model/createPortalDTO.ts b/src/app/generated/model/createPortalDTO.ts deleted file mode 100644 index ea07735..0000000 --- a/src/app/generated/model/createPortalDTO.ts +++ /dev/null @@ -1,40 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { MicrofrontendRegistrationInputDTO } from './microfrontendRegistrationInputDTO' -import { PortalAddressDTO } from './portalAddressDTO' -import { SubjectLinkDTO } from './subjectLinkDTO' - -export interface CreatePortalDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - portalName: string - tenantId?: string - description?: string - themeName: string - themeId: string - homePage?: string - baseUrl: string - companyName?: string - address?: PortalAddressDTO - phoneNumber?: string - rssFeedUrl?: string - footerLabel?: string - subjectLinks?: Set - microfrontendRegistrations?: Set - imageUrls?: Set - portalRoles?: Array - logoUrl?: string -} diff --git a/src/app/generated/model/createThemeDTO.ts b/src/app/generated/model/createThemeDTO.ts deleted file mode 100644 index 3e63a99..0000000 --- a/src/app/generated/model/createThemeDTO.ts +++ /dev/null @@ -1,31 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PortalIdentifierDTO } from './portalIdentifierDTO' - -export interface CreateThemeDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - name: string - cssFile?: string - description?: string - assetsUrl?: string - logoUrl?: string - faviconUrl?: string - previewImageUrl?: string - assetsUpdateDate?: string - properties?: object - portals?: Array -} diff --git a/src/app/generated/model/createThemeRequest.ts b/src/app/generated/model/createThemeRequest.ts new file mode 100644 index 0000000..ac15f90 --- /dev/null +++ b/src/app/generated/model/createThemeRequest.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { ThemeUpdateCreate } from './themeUpdateCreate'; + + +export interface CreateThemeRequest { + resource: ThemeUpdateCreate; +} + diff --git a/src/app/generated/model/createThemeResponse.ts b/src/app/generated/model/createThemeResponse.ts new file mode 100644 index 0000000..57eb52d --- /dev/null +++ b/src/app/generated/model/createThemeResponse.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { Theme } from './theme'; + + +export interface CreateThemeResponse { + resource: Theme; +} + diff --git a/src/app/generated/model/errorResponseDTO.ts b/src/app/generated/model/errorResponseDTO.ts deleted file mode 100644 index bb765d4..0000000 --- a/src/app/generated/model/errorResponseDTO.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface ErrorResponseDTO { - key?: string - parameters?: Array - details?: Array -} diff --git a/src/app/generated/model/eximTheme.ts b/src/app/generated/model/eximTheme.ts new file mode 100644 index 0000000..ebd6d77 --- /dev/null +++ b/src/app/generated/model/eximTheme.ts @@ -0,0 +1,24 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface EximTheme { + cssFile?: string; + description?: string; + assetsUrl?: string; + logoUrl?: string; + faviconUrl?: string; + previewImageUrl?: string; + assetsUpdateDate?: string; + properties?: object; +} + diff --git a/src/app/generated/model/exportThemeRequest.ts b/src/app/generated/model/exportThemeRequest.ts new file mode 100644 index 0000000..cf1c543 --- /dev/null +++ b/src/app/generated/model/exportThemeRequest.ts @@ -0,0 +1,17 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface ExportThemeRequest { + names?: Array; +} + diff --git a/src/app/generated/model/feedbackDTOv1.ts b/src/app/generated/model/feedbackDTOv1.ts deleted file mode 100644 index cba21f1..0000000 --- a/src/app/generated/model/feedbackDTOv1.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface FeedbackDTOv1 { - appId?: string - userId?: string - rating?: number - comment?: string -} diff --git a/src/app/generated/model/getThemeResponse.ts b/src/app/generated/model/getThemeResponse.ts new file mode 100644 index 0000000..43d51a1 --- /dev/null +++ b/src/app/generated/model/getThemeResponse.ts @@ -0,0 +1,20 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { Theme } from './theme'; +import { Workspace } from './workspace'; + + +export interface GetThemeResponse { + resource: Theme; + workspaces?: Array; +} + diff --git a/src/app/generated/model/getThemesResponse.ts b/src/app/generated/model/getThemesResponse.ts new file mode 100644 index 0000000..9d9d1ef --- /dev/null +++ b/src/app/generated/model/getThemesResponse.ts @@ -0,0 +1,22 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { Theme } from './theme'; + + +export interface GetThemesResponse { + totalElements?: number; + number?: number; + size?: number; + totalPages?: number; + stream?: Array; +} + diff --git a/src/app/generated/model/imageInfoDTOv1.ts b/src/app/generated/model/imageInfoDTOv1.ts deleted file mode 100644 index c093945..0000000 --- a/src/app/generated/model/imageInfoDTOv1.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface ImageInfoDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - /** - * flag whether Image was uploaded by user - */ - userUploaded?: boolean - lastUpdateTime?: string | null - imageUrl?: string - smallImageUrl?: string -} diff --git a/src/app/generated/model/importRequestDTOv1.ts b/src/app/generated/model/importRequestDTOv1.ts deleted file mode 100644 index 03e0315..0000000 --- a/src/app/generated/model/importRequestDTOv1.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ImportRequestDTOv1Portal } from './importRequestDTOv1Portal' -import { ImportRequestDTOv1ThemeImportData } from './importRequestDTOv1ThemeImportData' -import { MenuItemStructureDTOv1 } from './menuItemStructureDTOv1' - -export interface ImportRequestDTOv1 { - /** - * Whether menu permissions should be synced to APM after import - */ - synchronizePermissions?: boolean - portal: ImportRequestDTOv1Portal - /** - * Menu Items structure imported with a portal - */ - menuItems?: Array - themeImportData?: ImportRequestDTOv1ThemeImportData -} diff --git a/src/app/generated/model/importRequestDTOv1Portal.ts b/src/app/generated/model/importRequestDTOv1Portal.ts deleted file mode 100644 index 3231f4c..0000000 --- a/src/app/generated/model/importRequestDTOv1Portal.ts +++ /dev/null @@ -1,43 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { MicrofrontendRegistrationDTOv1 } from './microfrontendRegistrationDTOv1' -import { PortalImportDTOv1 } from './portalImportDTOv1' -import { SubjectLinkDTOv1 } from './subjectLinkDTOv1' -import { PortalAddressDTOv1 } from './portalAddressDTOv1' - -export interface ImportRequestDTOv1Portal { - /** - * Name of the portal that should be created/updated - */ - portalName: string - /** - * TenantId which will be set to Portal, when superAdmin Role is assigned - */ - tenantId?: string - /** - * Theme name provided in a case when themeImportData is empty - */ - themeName?: string - description?: string - homePage?: string - baseUrl?: string - companyName?: string - address?: PortalAddressDTOv1 - phoneNumber?: string - rssFeedUrl?: string - footerLabel?: string - subjectLinks?: Set - microfrontendRegistrations?: Set - imageUrls?: Set - portalRoles?: Array - logoUrl?: string -} diff --git a/src/app/generated/model/importRequestDTOv1ThemeImportData.ts b/src/app/generated/model/importRequestDTOv1ThemeImportData.ts deleted file mode 100644 index b4de962..0000000 --- a/src/app/generated/model/importRequestDTOv1ThemeImportData.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ThemeDTOv1 } from './themeDTOv1' - -export interface ImportRequestDTOv1ThemeImportData { - id?: string - version?: number - name: string - cssFile?: string - description?: string - assetsUrl?: string - logoUrl?: string - faviconUrl?: string - previewImageUrl?: string - assetsUpdateDate?: string - properties?: object -} diff --git a/src/app/generated/model/importThemeResponse.ts b/src/app/generated/model/importThemeResponse.ts new file mode 100644 index 0000000..63a88d0 --- /dev/null +++ b/src/app/generated/model/importThemeResponse.ts @@ -0,0 +1,22 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { ImportThemeResponseStatus } from './importThemeResponseStatus'; + + +export interface ImportThemeResponse { + /** + * ID of the request + */ + id?: string; + themes?: { [key: string]: ImportThemeResponseStatus; }; +} + diff --git a/src/app/generated/model/importThemeResponseStatus.ts b/src/app/generated/model/importThemeResponseStatus.ts new file mode 100644 index 0000000..d865bac --- /dev/null +++ b/src/app/generated/model/importThemeResponseStatus.ts @@ -0,0 +1,19 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export enum ImportThemeResponseStatus { + Update = 'UPDATE', + Created = 'CREATED', + Skip = 'SKIP' +} + diff --git a/src/app/generated/model/layoutAndThemeDTO.ts b/src/app/generated/model/layoutAndThemeDTO.ts deleted file mode 100644 index 1de780b..0000000 --- a/src/app/generated/model/layoutAndThemeDTO.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ColorScheme } from './colorScheme' -import { MenuMode } from './menuMode' - -export interface LayoutAndThemeDTO { - menuMode?: MenuMode | null - colorScheme?: ColorScheme | null -} diff --git a/src/app/generated/model/layoutAndThemeDTOv1.ts b/src/app/generated/model/layoutAndThemeDTOv1.ts deleted file mode 100644 index 34ee695..0000000 --- a/src/app/generated/model/layoutAndThemeDTOv1.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ColorSchemeV1 } from './colorSchemeV1' -import { MenuModeV1 } from './menuModeV1' - -export interface LayoutAndThemeDTOv1 { - menuMode?: MenuModeV1 | null - colorScheme?: ColorSchemeV1 | null -} diff --git a/src/app/generated/model/localeAndTimeSettingsDTO.ts b/src/app/generated/model/localeAndTimeSettingsDTO.ts deleted file mode 100644 index a1cdf78..0000000 --- a/src/app/generated/model/localeAndTimeSettingsDTO.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface LocaleAndTimeSettingsDTO { - /** - * - */ - locale?: string - /** - * - */ - timezone?: string -} diff --git a/src/app/generated/model/localeAndTimeSettingsDTOv1.ts b/src/app/generated/model/localeAndTimeSettingsDTOv1.ts deleted file mode 100644 index 45fbfe0..0000000 --- a/src/app/generated/model/localeAndTimeSettingsDTOv1.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface LocaleAndTimeSettingsDTOv1 { - /** - * - */ - locale?: string - /** - * - */ - timezone?: string -} diff --git a/src/app/generated/model/membershipDTO.ts b/src/app/generated/model/membershipDTO.ts deleted file mode 100644 index 55f50ed..0000000 --- a/src/app/generated/model/membershipDTO.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { MembershipRolesDTO } from './membershipRolesDTO' - -export interface MembershipDTO { - application?: string - roleMemberships?: Array -} diff --git a/src/app/generated/model/membershipRolesDTO.ts b/src/app/generated/model/membershipRolesDTO.ts deleted file mode 100644 index 2e35bd0..0000000 --- a/src/app/generated/model/membershipRolesDTO.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PermissionDTO } from './permissionDTO' - -export interface MembershipRolesDTO { - role?: string - permissions?: Array -} diff --git a/src/app/generated/model/menuItemDetailsDTO.ts b/src/app/generated/model/menuItemDetailsDTO.ts deleted file mode 100644 index 99a49d9..0000000 --- a/src/app/generated/model/menuItemDetailsDTO.ts +++ /dev/null @@ -1,35 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { Scope } from './scope' - -export interface MenuItemDetailsDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - key?: string - name?: string - description?: string - url?: string - portalName?: string - applicationId?: string - disabled?: boolean - position?: number - badge?: string - scope?: Scope - portalExit?: boolean - parentItemId?: string - i18n?: { [key: string]: string } - roles?: Array -} diff --git a/src/app/generated/model/menuItemListDTO.ts b/src/app/generated/model/menuItemListDTO.ts deleted file mode 100644 index d641d11..0000000 --- a/src/app/generated/model/menuItemListDTO.ts +++ /dev/null @@ -1,35 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { Scope } from './scope' - -export interface MenuItemListDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - key?: string - name?: string - description?: string - url?: string - portalName?: string - applicationId?: string - disabled?: boolean - position?: number - badge?: string - scope?: Scope - portalExit?: boolean - parentItemId?: string - i18n?: { [key: string]: string } - roles?: Array -} diff --git a/src/app/generated/model/menuItemStructureDTO.ts b/src/app/generated/model/menuItemStructureDTO.ts deleted file mode 100644 index 067658f..0000000 --- a/src/app/generated/model/menuItemStructureDTO.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface MenuItemStructureDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - key?: string - name?: string - description?: string - url?: string - portalName?: string - applicationId?: string - disabled?: boolean - position?: number - badge?: string - portalExit?: boolean - parentItemId?: string - i18n?: { [key: string]: string } - children?: Array - roles?: Array -} diff --git a/src/app/generated/model/menuItemStructureDTOv1.ts b/src/app/generated/model/menuItemStructureDTOv1.ts deleted file mode 100644 index b158a63..0000000 --- a/src/app/generated/model/menuItemStructureDTOv1.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface MenuItemStructureDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - key?: string - name?: string - description?: string - url?: string - portalName?: string - applicationId?: string - disabled?: boolean - position?: number - badge?: string - portalExit?: boolean - parentItemId?: string - i18n?: { [key: string]: string } - children?: Array - roles?: Array -} diff --git a/src/app/generated/model/menuItemStructureDtoLegacy.ts b/src/app/generated/model/menuItemStructureDtoLegacy.ts deleted file mode 100644 index 29e2af1..0000000 --- a/src/app/generated/model/menuItemStructureDtoLegacy.ts +++ /dev/null @@ -1,36 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { Scope } from './scope' - -export interface MenuItemStructureDtoLegacy { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - key?: string - name?: string - description?: string - url?: string - portalId?: string - applicationId?: string - disabled?: boolean - position?: number - badge?: string - portalExit?: boolean - parentItemId?: string - scope?: Scope - i18n?: { [key: string]: string } - children?: Array - parentKey?: string -} diff --git a/src/app/generated/model/menuMode.ts b/src/app/generated/model/menuMode.ts deleted file mode 100644 index 67553b1..0000000 --- a/src/app/generated/model/menuMode.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum MenuMode { - Static = 'STATIC', - Horizontal = 'HORIZONTAL', - Overlay = 'OVERLAY', - Slim = 'SLIM', - Slimplus = 'SLIMPLUS', -} diff --git a/src/app/generated/model/menuModeV1.ts b/src/app/generated/model/menuModeV1.ts deleted file mode 100644 index 91ea428..0000000 --- a/src/app/generated/model/menuModeV1.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum MenuModeV1 { - Static = 'STATIC', - Horizontal = 'HORIZONTAL', - Overlay = 'OVERLAY', - Slim = 'SLIM', - Slimplus = 'SLIMPLUS', -} diff --git a/src/app/generated/model/menuStructureListDTO.ts b/src/app/generated/model/menuStructureListDTO.ts deleted file mode 100644 index 4bba9ec..0000000 --- a/src/app/generated/model/menuStructureListDTO.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { MenuItemStructureDTO } from './menuItemStructureDTO' - -export interface MenuStructureListDTO { - menuItemStructureDTOS?: Array -} diff --git a/src/app/generated/model/microfrontendDTOv1.ts b/src/app/generated/model/microfrontendDTOv1.ts deleted file mode 100644 index c39b4ab..0000000 --- a/src/app/generated/model/microfrontendDTOv1.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PortalIdentifierDTOv1 } from './portalIdentifierDTOv1' -import { ModuleTypeV1 } from './moduleTypeV1' - -export interface MicrofrontendDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - remoteEntry: string - remoteName: string - exposedModule: string - displayName: string - moduleType: ModuleTypeV1 | null - wcTagName?: string - appId?: string - appVersion?: string - note?: string - contact?: string - remoteBaseUrl: string - portals?: Array -} diff --git a/src/app/generated/model/microfrontendRegistrationDTO.ts b/src/app/generated/model/microfrontendRegistrationDTO.ts deleted file mode 100644 index dd8e40b..0000000 --- a/src/app/generated/model/microfrontendRegistrationDTO.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface MicrofrontendRegistrationDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - mfeId?: string - baseUrl?: string - appId?: string -} diff --git a/src/app/generated/model/microfrontendRegistrationDTOv1.ts b/src/app/generated/model/microfrontendRegistrationDTOv1.ts deleted file mode 100644 index 029f6e5..0000000 --- a/src/app/generated/model/microfrontendRegistrationDTOv1.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface MicrofrontendRegistrationDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - mfeId?: string - baseUrl?: string -} diff --git a/src/app/generated/model/microfrontendRegistrationInputDTO.ts b/src/app/generated/model/microfrontendRegistrationInputDTO.ts deleted file mode 100644 index a9b32e5..0000000 --- a/src/app/generated/model/microfrontendRegistrationInputDTO.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface MicrofrontendRegistrationInputDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - mfeId?: string - baseUrl?: string -} diff --git a/src/app/generated/model/microfrontendRegistrationRequestDTO.ts b/src/app/generated/model/microfrontendRegistrationRequestDTO.ts deleted file mode 100644 index cece0ff..0000000 --- a/src/app/generated/model/microfrontendRegistrationRequestDTO.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface MicrofrontendRegistrationRequestDTO { - mfeId?: string - baseUrl?: string -} diff --git a/src/app/generated/model/models.ts b/src/app/generated/model/models.ts index af08c0a..7d2e4c1 100644 --- a/src/app/generated/model/models.ts +++ b/src/app/generated/model/models.ts @@ -1,85 +1,21 @@ -export * from './accountSettingsDTO' -export * from './accountSettingsDTOLayoutAndThemeSettings' -export * from './accountSettingsDTOLocaleAndTimeSettings' -export * from './accountSettingsDTOPrivacySettings' -export * from './accountSettingsDTOv1' -export * from './accountSettingsDTOv1LayoutAndThemeSettings' -export * from './accountSettingsDTOv1LocaleAndTimeSettings' -export * from './accountSettingsDTOv1PrivacySettings' -export * from './colorScheme' -export * from './colorSchemeV1' -export * from './createMicrofrontendDTOv1' -export * from './createPortalDTO' -export * from './createThemeDTO' -export * from './errorResponseDTO' -export * from './feedbackDTOv1' -export * from './imageInfoDTOv1' -export * from './importRequestDTOv1' -export * from './importRequestDTOv1Portal' -export * from './importRequestDTOv1ThemeImportData' -export * from './layoutAndThemeDTO' -export * from './layoutAndThemeDTOv1' -export * from './localeAndTimeSettingsDTO' -export * from './localeAndTimeSettingsDTOv1' -export * from './membershipDTO' -export * from './membershipRolesDTO' -export * from './menuItemDetailsDTO' -export * from './menuItemListDTO' -export * from './menuItemStructureDTO' -export * from './menuItemStructureDTOv1' -export * from './menuItemStructureDtoLegacy' -export * from './menuMode' -export * from './menuModeV1' -export * from './menuStructureListDTO' -export * from './microfrontendDTOv1' -export * from './microfrontendRegistrationDTO' -export * from './microfrontendRegistrationDTOv1' -export * from './microfrontendRegistrationInputDTO' -export * from './microfrontendRegistrationRequestDTO' -export * from './moduleTypeV1' -export * from './permissionDTO' -export * from './portalAddressDTO' -export * from './portalAddressDTOv1' -export * from './portalDTO' -export * from './portalDTOv1' -export * from './portalIdentifierDTO' -export * from './portalIdentifierDTOv1' -export * from './portalImportDTOv1' -export * from './portalMenuItemDTO' -export * from './portalMenuItemDTOv1' -export * from './portalSearchCriteriaDTO' -export * from './preferencesDTO' -export * from './preferencesDTOv1' -export * from './privacySettingsDTO' -export * from './privacySettingsDTOv1' -export * from './resetPasswordDTOv1' -export * from './restException' -export * from './restExceptionDTO' -export * from './scope' -export * from './scopeV1' -export * from './searchItemDTOv1' -export * from './searchItemTypeV1' -export * from './searchTemplateDTOv1' -export * from './searchTemplateSearchCriteria' -export * from './status' -export * from './subjectLinkDTO' -export * from './subjectLinkDTOv1' -export * from './supportTicketDTOv1' -export * from './themeDTO' -export * from './themeDTOv1' -export * from './updateMicrofrontend200Response' -export * from './updateMicrofrontendDTOv1' -export * from './updatePortalDTO' -export * from './updateThemeDTO' -export * from './userInfoDTOv1' -export * from './userPersonAddressDTO' -export * from './userPersonAddressDTOv1' -export * from './userPersonDTO' -export * from './userPersonDTOv1' -export * from './userPersonPhoneDTO' -export * from './userPersonPhoneDTOv1' -export * from './userProfileDTO' -export * from './userProfileDTOAccountSettings' -export * from './userProfileDTOv1' -export * from './userProfileDTOv1AccountSettings' -export * from './userProfileDTOv1Avatar' +export * from './createThemeRequest'; +export * from './createThemeResponse'; +export * from './eximTheme'; +export * from './exportThemeRequest'; +export * from './getThemeResponse'; +export * from './getThemesResponse'; +export * from './importThemeResponse'; +export * from './importThemeResponseStatus'; +export * from './pagingResponse'; +export * from './problemDetailInvalidParam'; +export * from './problemDetailParam'; +export * from './problemDetailResponse'; +export * from './searchThemeRequest'; +export * from './searchThemeResponse'; +export * from './theme'; +export * from './themeSnapshot'; +export * from './themeUpdateCreate'; +export * from './updateThemeRequest'; +export * from './updateThemeResponse'; +export * from './validationConstraint'; +export * from './workspace'; diff --git a/src/app/generated/model/moduleTypeV1.ts b/src/app/generated/model/moduleTypeV1.ts deleted file mode 100644 index 0b564a2..0000000 --- a/src/app/generated/model/moduleTypeV1.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum ModuleTypeV1 { - Angular = 'ANGULAR', - Webcomponent = 'WEBCOMPONENT', -} diff --git a/src/app/generated/model/pagingResponse.ts b/src/app/generated/model/pagingResponse.ts new file mode 100644 index 0000000..82fec4c --- /dev/null +++ b/src/app/generated/model/pagingResponse.ts @@ -0,0 +1,20 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface PagingResponse { + totalElements?: number; + number?: number; + size?: number; + totalPages?: number; +} + diff --git a/src/app/generated/model/permissionDTO.ts b/src/app/generated/model/permissionDTO.ts deleted file mode 100644 index d651d5a..0000000 --- a/src/app/generated/model/permissionDTO.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PermissionDTO { - resource?: string - action?: string - key?: string - name?: string - description?: string -} diff --git a/src/app/generated/model/portalAddressDTO.ts b/src/app/generated/model/portalAddressDTO.ts deleted file mode 100644 index 491cef5..0000000 --- a/src/app/generated/model/portalAddressDTO.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PortalAddressDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - street?: string - streetNo?: string - city?: string - country?: string - postalCode?: string -} diff --git a/src/app/generated/model/portalAddressDTOv1.ts b/src/app/generated/model/portalAddressDTOv1.ts deleted file mode 100644 index c7b1014..0000000 --- a/src/app/generated/model/portalAddressDTOv1.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PortalAddressDTOv1 { - street?: string - streetNo?: string - city?: string - country?: string - postalCode?: string -} diff --git a/src/app/generated/model/portalDTO.ts b/src/app/generated/model/portalDTO.ts deleted file mode 100644 index d1cc336..0000000 --- a/src/app/generated/model/portalDTO.ts +++ /dev/null @@ -1,40 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PortalAddressDTO } from './portalAddressDTO' -import { SubjectLinkDTO } from './subjectLinkDTO' -import { MicrofrontendRegistrationDTO } from './microfrontendRegistrationDTO' - -export interface PortalDTO { - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - portalName: string - tenantId?: string - description?: string - themeName: string - themeId: string - homePage?: string - baseUrl: string - companyName?: string - address?: PortalAddressDTO - phoneNumber?: string - rssFeedUrl?: string - footerLabel?: string - subjectLinks?: Set - microfrontendRegistrations?: Set - imageUrls?: Set - portalRoles?: Array - logoUrl?: string - version?: number -} diff --git a/src/app/generated/model/portalDTOv1.ts b/src/app/generated/model/portalDTOv1.ts deleted file mode 100644 index 66964c8..0000000 --- a/src/app/generated/model/portalDTOv1.ts +++ /dev/null @@ -1,36 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { MicrofrontendRegistrationDTOv1 } from './microfrontendRegistrationDTOv1' -import { SubjectLinkDTOv1 } from './subjectLinkDTOv1' -import { PortalAddressDTOv1 } from './portalAddressDTOv1' - -export interface PortalDTOv1 { - id?: string - portalName: string - tenantId?: string - description?: string - themeName: string - themeId: string - homePage?: string - baseUrl: string - companyName?: string - address?: PortalAddressDTOv1 - phoneNumber?: string - rssFeedUrl?: string - footerLabel?: string - subjectLinks?: Set - microfrontendRegistrations?: Set - imageUrls?: Set - portalRoles?: Array - logoUrl?: string - version?: number -} diff --git a/src/app/generated/model/portalIdentifierDTO.ts b/src/app/generated/model/portalIdentifierDTO.ts deleted file mode 100644 index bdd392d..0000000 --- a/src/app/generated/model/portalIdentifierDTO.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PortalIdentifierDTO { - portalName?: string - portalId?: string - tenantId?: string -} diff --git a/src/app/generated/model/portalIdentifierDTOv1.ts b/src/app/generated/model/portalIdentifierDTOv1.ts deleted file mode 100644 index 5525345..0000000 --- a/src/app/generated/model/portalIdentifierDTOv1.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PortalIdentifierDTOv1 { - portalName?: string - tenantId?: string -} diff --git a/src/app/generated/model/portalImportDTOv1.ts b/src/app/generated/model/portalImportDTOv1.ts deleted file mode 100644 index e9ca07a..0000000 --- a/src/app/generated/model/portalImportDTOv1.ts +++ /dev/null @@ -1,45 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { MicrofrontendRegistrationDTOv1 } from './microfrontendRegistrationDTOv1' -import { SubjectLinkDTOv1 } from './subjectLinkDTOv1' -import { PortalAddressDTOv1 } from './portalAddressDTOv1' - -/** - * Portal data to be imported - */ -export interface PortalImportDTOv1 { - /** - * Name of the portal that should be created/updated - */ - portalName: string - /** - * TenantId which will be set to Portal, when superAdmin Role is assigned - */ - tenantId?: string - /** - * Theme name provided in a case when themeImportData is empty - */ - themeName?: string - description?: string - homePage?: string - baseUrl?: string - companyName?: string - address?: PortalAddressDTOv1 - phoneNumber?: string - rssFeedUrl?: string - footerLabel?: string - subjectLinks?: Set - microfrontendRegistrations?: Set - imageUrls?: Set - portalRoles?: Array - logoUrl?: string -} diff --git a/src/app/generated/model/portalMenuItemDTO.ts b/src/app/generated/model/portalMenuItemDTO.ts deleted file mode 100644 index e2abe8f..0000000 --- a/src/app/generated/model/portalMenuItemDTO.ts +++ /dev/null @@ -1,36 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { Scope } from './scope' - -export interface PortalMenuItemDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - key?: string - name?: string - description?: string - url?: string - portalName?: string - applicationId?: string - disabled?: boolean - scope?: Scope - position?: number - badge?: string - portalExit?: boolean - parentItemId?: string - i18n?: { [key: string]: string } - children?: Array - roles?: Array -} diff --git a/src/app/generated/model/portalMenuItemDTOv1.ts b/src/app/generated/model/portalMenuItemDTOv1.ts deleted file mode 100644 index 9a9131f..0000000 --- a/src/app/generated/model/portalMenuItemDTOv1.ts +++ /dev/null @@ -1,36 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ScopeV1 } from './scopeV1' - -export interface PortalMenuItemDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - key?: string - name?: string - description?: string - url?: string - applicationId?: string - disabled?: boolean - portalName?: string - scope?: ScopeV1 - position?: number - badge?: string - portalExit?: boolean - parentItemId?: string - i18n?: { [key: string]: string } - children?: Array - roles?: Array -} diff --git a/src/app/generated/model/portalSearchCriteriaDTO.ts b/src/app/generated/model/portalSearchCriteriaDTO.ts deleted file mode 100644 index 4cb2ef7..0000000 --- a/src/app/generated/model/portalSearchCriteriaDTO.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -/** - * SearchCriteria DTO for Portals - */ -export interface PortalSearchCriteriaDTO { - portalName?: string - themeName?: string -} diff --git a/src/app/generated/model/preferencesDTO.ts b/src/app/generated/model/preferencesDTO.ts deleted file mode 100644 index 299821b..0000000 --- a/src/app/generated/model/preferencesDTO.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PreferencesDTO { - /** - * name of preference - */ - key?: string - /** - * value of preference - */ - value?: string -} diff --git a/src/app/generated/model/preferencesDTOv1.ts b/src/app/generated/model/preferencesDTOv1.ts deleted file mode 100644 index 3bc8823..0000000 --- a/src/app/generated/model/preferencesDTOv1.ts +++ /dev/null @@ -1,43 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -/** - * DTO representation of one key-value preference of user profile - */ -export interface PreferencesDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - /** - * user id of preference - */ - userId?: string - /** - * application id of preference - */ - applicationId?: string - /** - * name of preference - */ - name?: string - /** - * description of preference - */ - description?: string - /** - * value of preference - */ - value?: string -} diff --git a/src/app/generated/model/privacySettingsDTO.ts b/src/app/generated/model/privacySettingsDTO.ts deleted file mode 100644 index 3839497..0000000 --- a/src/app/generated/model/privacySettingsDTO.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PrivacySettingsDTO { - /** - * Flag whether profile should be hidden or not - */ - hideMyProfile?: boolean -} diff --git a/src/app/generated/model/privacySettingsDTOv1.ts b/src/app/generated/model/privacySettingsDTOv1.ts deleted file mode 100644 index 09760d2..0000000 --- a/src/app/generated/model/privacySettingsDTOv1.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface PrivacySettingsDTOv1 { - /** - * Flag whether profile should be hidden or not - */ - hideMyProfile?: boolean -} diff --git a/src/app/generated/model/problemDetailInvalidParam.ts b/src/app/generated/model/problemDetailInvalidParam.ts new file mode 100644 index 0000000..23a7037 --- /dev/null +++ b/src/app/generated/model/problemDetailInvalidParam.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface ProblemDetailInvalidParam { + name?: string; + message?: string; +} + diff --git a/src/app/generated/model/problemDetailParam.ts b/src/app/generated/model/problemDetailParam.ts new file mode 100644 index 0000000..e4b4c4b --- /dev/null +++ b/src/app/generated/model/problemDetailParam.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface ProblemDetailParam { + key?: string; + value?: string; +} + diff --git a/src/app/generated/model/problemDetailResponse.ts b/src/app/generated/model/problemDetailResponse.ts new file mode 100644 index 0000000..5c937d2 --- /dev/null +++ b/src/app/generated/model/problemDetailResponse.ts @@ -0,0 +1,22 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { ProblemDetailInvalidParam } from './problemDetailInvalidParam'; +import { ProblemDetailParam } from './problemDetailParam'; + + +export interface ProblemDetailResponse { + errorCode?: string; + detail?: string; + params?: Array; + invalidParams?: Array; +} + diff --git a/src/app/generated/model/resetPasswordDTOv1.ts b/src/app/generated/model/resetPasswordDTOv1.ts deleted file mode 100644 index bc9b964..0000000 --- a/src/app/generated/model/resetPasswordDTOv1.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface ResetPasswordDTOv1 { - password?: string -} diff --git a/src/app/generated/model/restException.ts b/src/app/generated/model/restException.ts deleted file mode 100644 index ce6fb5c..0000000 --- a/src/app/generated/model/restException.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { Status } from './status' - -export interface RestException { - status?: Status - errorCode?: object - parameters?: Array - namedParameters?: { [key: string]: object } -} diff --git a/src/app/generated/model/restExceptionDTO.ts b/src/app/generated/model/restExceptionDTO.ts deleted file mode 100644 index 1693c77..0000000 --- a/src/app/generated/model/restExceptionDTO.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface RestExceptionDTO { - errorCode?: string - message?: string - parameters?: Array - namedParameters?: { [key: string]: object } -} diff --git a/src/app/generated/model/scope.ts b/src/app/generated/model/scope.ts deleted file mode 100644 index e10d987..0000000 --- a/src/app/generated/model/scope.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum Scope { - Portal = 'PORTAL', - App = 'APP', - Page = 'PAGE', -} diff --git a/src/app/generated/model/scopeV1.ts b/src/app/generated/model/scopeV1.ts deleted file mode 100644 index 5d9d449..0000000 --- a/src/app/generated/model/scopeV1.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum ScopeV1 { - Portal = 'PORTAL', - App = 'APP', - Page = 'PAGE', -} diff --git a/src/app/generated/model/searchItemDTOv1.ts b/src/app/generated/model/searchItemDTOv1.ts deleted file mode 100644 index 9896875..0000000 --- a/src/app/generated/model/searchItemDTOv1.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { SearchItemTypeV1 } from './searchItemTypeV1' - -export interface SearchItemDTOv1 { - type?: SearchItemTypeV1 - applicationId?: string - portalName?: string - name?: string - description?: string - url?: string - badge?: string - disabled?: boolean -} diff --git a/src/app/generated/model/searchItemTypeV1.ts b/src/app/generated/model/searchItemTypeV1.ts deleted file mode 100644 index a1e7a50..0000000 --- a/src/app/generated/model/searchItemTypeV1.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum SearchItemTypeV1 { - Application = 'APPLICATION', -} diff --git a/src/app/generated/model/searchTemplateDTOv1.ts b/src/app/generated/model/searchTemplateDTOv1.ts deleted file mode 100644 index b250cce..0000000 --- a/src/app/generated/model/searchTemplateDTOv1.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface SearchTemplateDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - user?: string - global?: boolean - application?: string - page?: string - name?: string - defaultTemplate?: boolean - apiVersion?: string - criteriaAsJson?: string -} diff --git a/src/app/generated/model/searchTemplateSearchCriteria.ts b/src/app/generated/model/searchTemplateSearchCriteria.ts deleted file mode 100644 index fe6df86..0000000 --- a/src/app/generated/model/searchTemplateSearchCriteria.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface SearchTemplateSearchCriteria { - user?: string - application?: string - page?: string - includeGlobal?: boolean -} diff --git a/src/app/generated/model/searchThemeRequest.ts b/src/app/generated/model/searchThemeRequest.ts new file mode 100644 index 0000000..a1b4767 --- /dev/null +++ b/src/app/generated/model/searchThemeRequest.ts @@ -0,0 +1,19 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface SearchThemeRequest { + name?: string; + pageNumber?: number; + pageSize?: number; +} + diff --git a/src/app/generated/model/searchThemeResponse.ts b/src/app/generated/model/searchThemeResponse.ts new file mode 100644 index 0000000..ee12840 --- /dev/null +++ b/src/app/generated/model/searchThemeResponse.ts @@ -0,0 +1,22 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { Theme } from './theme'; + + +export interface SearchThemeResponse { + totalElements?: number; + number?: number; + size?: number; + totalPages?: number; + stream?: Array; +} + diff --git a/src/app/generated/model/status.ts b/src/app/generated/model/status.ts deleted file mode 100644 index a4e7d16..0000000 --- a/src/app/generated/model/status.ts +++ /dev/null @@ -1,54 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export enum Status { - Ok = 'OK', - Created = 'CREATED', - Accepted = 'ACCEPTED', - NoContent = 'NO_CONTENT', - ResetContent = 'RESET_CONTENT', - PartialContent = 'PARTIAL_CONTENT', - MovedPermanently = 'MOVED_PERMANENTLY', - Found = 'FOUND', - SeeOther = 'SEE_OTHER', - NotModified = 'NOT_MODIFIED', - UseProxy = 'USE_PROXY', - TemporaryRedirect = 'TEMPORARY_REDIRECT', - BadRequest = 'BAD_REQUEST', - Unauthorized = 'UNAUTHORIZED', - PaymentRequired = 'PAYMENT_REQUIRED', - Forbidden = 'FORBIDDEN', - NotFound = 'NOT_FOUND', - MethodNotAllowed = 'METHOD_NOT_ALLOWED', - NotAcceptable = 'NOT_ACCEPTABLE', - ProxyAuthenticationRequired = 'PROXY_AUTHENTICATION_REQUIRED', - RequestTimeout = 'REQUEST_TIMEOUT', - Conflict = 'CONFLICT', - Gone = 'GONE', - LengthRequired = 'LENGTH_REQUIRED', - PreconditionFailed = 'PRECONDITION_FAILED', - RequestEntityTooLarge = 'REQUEST_ENTITY_TOO_LARGE', - RequestUriTooLong = 'REQUEST_URI_TOO_LONG', - UnsupportedMediaType = 'UNSUPPORTED_MEDIA_TYPE', - RequestedRangeNotSatisfiable = 'REQUESTED_RANGE_NOT_SATISFIABLE', - ExpectationFailed = 'EXPECTATION_FAILED', - PreconditionRequired = 'PRECONDITION_REQUIRED', - TooManyRequests = 'TOO_MANY_REQUESTS', - RequestHeaderFieldsTooLarge = 'REQUEST_HEADER_FIELDS_TOO_LARGE', - InternalServerError = 'INTERNAL_SERVER_ERROR', - NotImplemented = 'NOT_IMPLEMENTED', - BadGateway = 'BAD_GATEWAY', - ServiceUnavailable = 'SERVICE_UNAVAILABLE', - GatewayTimeout = 'GATEWAY_TIMEOUT', - HttpVersionNotSupported = 'HTTP_VERSION_NOT_SUPPORTED', - NetworkAuthenticationRequired = 'NETWORK_AUTHENTICATION_REQUIRED', -} diff --git a/src/app/generated/model/subjectLinkDTO.ts b/src/app/generated/model/subjectLinkDTO.ts deleted file mode 100644 index 57c2003..0000000 --- a/src/app/generated/model/subjectLinkDTO.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface SubjectLinkDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - label?: string - url?: string -} diff --git a/src/app/generated/model/subjectLinkDTOv1.ts b/src/app/generated/model/subjectLinkDTOv1.ts deleted file mode 100644 index 2968f81..0000000 --- a/src/app/generated/model/subjectLinkDTOv1.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface SubjectLinkDTOv1 { - label?: string - url?: string -} diff --git a/src/app/generated/model/supportTicketDTOv1.ts b/src/app/generated/model/supportTicketDTOv1.ts deleted file mode 100644 index 8cf571e..0000000 --- a/src/app/generated/model/supportTicketDTOv1.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface SupportTicketDTOv1 { - processId?: string - processStep?: string - source?: string - sourceDeepLink?: string -} diff --git a/src/app/generated/model/theme.ts b/src/app/generated/model/theme.ts new file mode 100644 index 0000000..ba43bd5 --- /dev/null +++ b/src/app/generated/model/theme.ts @@ -0,0 +1,31 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface Theme { + version?: number; + creationDate?: string; + creationUser?: string; + modificationDate?: string; + modificationUser?: string; + id?: string; + name?: string; + cssFile?: string; + description?: string; + assetsUrl?: string; + logoUrl?: string; + faviconUrl?: string; + previewImageUrl?: string; + assetsUpdateDate?: string; + properties?: object; +} + diff --git a/src/app/generated/model/themeDTO.ts b/src/app/generated/model/themeDTO.ts deleted file mode 100644 index 3e76676..0000000 --- a/src/app/generated/model/themeDTO.ts +++ /dev/null @@ -1,31 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PortalIdentifierDTO } from './portalIdentifierDTO' - -export interface ThemeDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - name: string - cssFile?: string - description?: string - assetsUrl?: string - logoUrl?: string - faviconUrl?: string - previewImageUrl?: string - assetsUpdateDate?: string - properties?: object - portals?: Array -} diff --git a/src/app/generated/model/themeDTOv1.ts b/src/app/generated/model/themeDTOv1.ts deleted file mode 100644 index cab6bf8..0000000 --- a/src/app/generated/model/themeDTOv1.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface ThemeDTOv1 { - id?: string - version?: number - name: string - cssFile?: string - description?: string - assetsUrl?: string - logoUrl?: string - faviconUrl?: string - previewImageUrl?: string - assetsUpdateDate?: string - properties?: object -} diff --git a/src/app/generated/model/themeSnapshot.ts b/src/app/generated/model/themeSnapshot.ts new file mode 100644 index 0000000..366c023 --- /dev/null +++ b/src/app/generated/model/themeSnapshot.ts @@ -0,0 +1,23 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { EximTheme } from './eximTheme'; + + +export interface ThemeSnapshot { + /** + * ID of the request + */ + id?: string; + created?: string; + themes?: { [key: string]: EximTheme; }; +} + diff --git a/src/app/generated/model/themeUpdateCreate.ts b/src/app/generated/model/themeUpdateCreate.ts new file mode 100644 index 0000000..9b490e0 --- /dev/null +++ b/src/app/generated/model/themeUpdateCreate.ts @@ -0,0 +1,30 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface ThemeUpdateCreate { + version?: number; + creationDate?: string; + creationUser?: string; + modificationDate?: string; + modificationUser?: string; + name?: string; + cssFile?: string; + description?: string; + assetsUrl?: string; + logoUrl?: string; + faviconUrl?: string; + previewImageUrl?: string; + assetsUpdateDate?: string; + properties?: object; +} + diff --git a/src/app/generated/model/updateMicrofrontend200Response.ts b/src/app/generated/model/updateMicrofrontend200Response.ts deleted file mode 100644 index c796c18..0000000 --- a/src/app/generated/model/updateMicrofrontend200Response.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PortalIdentifierDTOv1 } from './portalIdentifierDTOv1' -import { ModuleTypeV1 } from './moduleTypeV1' - -export interface UpdateMicrofrontend200Response { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - remoteEntry: string - remoteName: string - exposedModule: string - displayName: string - moduleType: ModuleTypeV1 | null - wcTagName?: string - appId?: string - appVersion?: string - note?: string - contact?: string - remoteBaseUrl: string - portals?: Array -} diff --git a/src/app/generated/model/updateMicrofrontendDTOv1.ts b/src/app/generated/model/updateMicrofrontendDTOv1.ts deleted file mode 100644 index 0cafebc..0000000 --- a/src/app/generated/model/updateMicrofrontendDTOv1.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ModuleTypeV1 } from './moduleTypeV1' - -export interface UpdateMicrofrontendDTOv1 { - remoteEntry: string - remoteName: string - exposedModule: string - displayName: string - moduleType: ModuleTypeV1 | null - wcTagName?: string - appId?: string - appVersion?: string - note?: string - contact?: string - remoteBaseUrl: string -} diff --git a/src/app/generated/model/updatePortalDTO.ts b/src/app/generated/model/updatePortalDTO.ts deleted file mode 100644 index 487f438..0000000 --- a/src/app/generated/model/updatePortalDTO.ts +++ /dev/null @@ -1,40 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { MicrofrontendRegistrationInputDTO } from './microfrontendRegistrationInputDTO' -import { PortalAddressDTO } from './portalAddressDTO' -import { SubjectLinkDTO } from './subjectLinkDTO' - -export interface UpdatePortalDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - portalName: string - tenantId?: string - description?: string - themeName: string - themeId: string - homePage?: string - baseUrl: string - companyName?: string - address?: PortalAddressDTO - phoneNumber?: string - rssFeedUrl?: string - footerLabel?: string - subjectLinks?: Set - microfrontendRegistrations?: Set - imageUrls?: Set - portalRoles?: Array - logoUrl?: string -} diff --git a/src/app/generated/model/updateThemeDTO.ts b/src/app/generated/model/updateThemeDTO.ts deleted file mode 100644 index 003c967..0000000 --- a/src/app/generated/model/updateThemeDTO.ts +++ /dev/null @@ -1,31 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { PortalIdentifierDTO } from './portalIdentifierDTO' - -export interface UpdateThemeDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - name: string - cssFile?: string - description?: string - assetsUrl?: string - logoUrl?: string - faviconUrl?: string - previewImageUrl?: string - assetsUpdateDate?: string - properties?: object - portals?: Array -} diff --git a/src/app/generated/model/updateThemeRequest.ts b/src/app/generated/model/updateThemeRequest.ts new file mode 100644 index 0000000..d7d4db9 --- /dev/null +++ b/src/app/generated/model/updateThemeRequest.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { ThemeUpdateCreate } from './themeUpdateCreate'; + + +export interface UpdateThemeRequest { + resource: ThemeUpdateCreate; +} + diff --git a/src/app/generated/model/updateThemeResponse.ts b/src/app/generated/model/updateThemeResponse.ts new file mode 100644 index 0000000..d34dc6d --- /dev/null +++ b/src/app/generated/model/updateThemeResponse.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ +import { Theme } from './theme'; + + +export interface UpdateThemeResponse { + resource: Theme; +} + diff --git a/src/app/generated/model/userInfoDTOv1.ts b/src/app/generated/model/userInfoDTOv1.ts deleted file mode 100644 index fa2d4ad..0000000 --- a/src/app/generated/model/userInfoDTOv1.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface UserInfoDTOv1 { - familyName?: string - fullName?: string - givenName?: string - userId?: string -} diff --git a/src/app/generated/model/userPersonAddressDTO.ts b/src/app/generated/model/userPersonAddressDTO.ts deleted file mode 100644 index 251f871..0000000 --- a/src/app/generated/model/userPersonAddressDTO.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface UserPersonAddressDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - street?: string - streetNo?: string - city?: string - postalCode?: string - country?: string -} diff --git a/src/app/generated/model/userPersonAddressDTOv1.ts b/src/app/generated/model/userPersonAddressDTOv1.ts deleted file mode 100644 index 6b7f45f..0000000 --- a/src/app/generated/model/userPersonAddressDTOv1.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface UserPersonAddressDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - street?: string - streetNo?: string - city?: string - postalCode?: string - country?: string -} diff --git a/src/app/generated/model/userPersonDTO.ts b/src/app/generated/model/userPersonDTO.ts deleted file mode 100644 index b640f35..0000000 --- a/src/app/generated/model/userPersonDTO.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { UserPersonAddressDTO } from './userPersonAddressDTO' -import { UserPersonPhoneDTO } from './userPersonPhoneDTO' - -export interface UserPersonDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - firstName?: string - lastName?: string - displayName?: string - email?: string - address?: UserPersonAddressDTO - phone?: UserPersonPhoneDTO -} diff --git a/src/app/generated/model/userPersonDTOv1.ts b/src/app/generated/model/userPersonDTOv1.ts deleted file mode 100644 index 56b8f0c..0000000 --- a/src/app/generated/model/userPersonDTOv1.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { UserPersonPhoneDTOv1 } from './userPersonPhoneDTOv1' -import { UserPersonAddressDTOv1 } from './userPersonAddressDTOv1' - -export interface UserPersonDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - firstName?: string - lastName?: string - displayName?: string - email?: string - address?: UserPersonAddressDTOv1 - phone?: UserPersonPhoneDTOv1 -} diff --git a/src/app/generated/model/userPersonPhoneDTO.ts b/src/app/generated/model/userPersonPhoneDTO.ts deleted file mode 100644 index eec9267..0000000 --- a/src/app/generated/model/userPersonPhoneDTO.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface UserPersonPhoneDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - type?: string - number?: string -} diff --git a/src/app/generated/model/userPersonPhoneDTOv1.ts b/src/app/generated/model/userPersonPhoneDTOv1.ts deleted file mode 100644 index 999f253..0000000 --- a/src/app/generated/model/userPersonPhoneDTOv1.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -export interface UserPersonPhoneDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - type?: string - number?: string -} diff --git a/src/app/generated/model/userProfileDTO.ts b/src/app/generated/model/userProfileDTO.ts deleted file mode 100644 index 7d0b376..0000000 --- a/src/app/generated/model/userProfileDTO.ts +++ /dev/null @@ -1,40 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { UserPersonDTO } from './userPersonDTO' -import { MembershipDTO } from './membershipDTO' -import { UserProfileDTOAccountSettings } from './userProfileDTOAccountSettings' - -export interface UserProfileDTO { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - /** - * - */ - userId?: string - identityProvider?: string - /** - * user id in external identity provider, e.g. in keycloak - */ - identityProviderId?: string - /** - * - */ - organization?: string - person?: UserPersonDTO - roles?: Set - memberships?: Array - accountSettings?: UserProfileDTOAccountSettings -} diff --git a/src/app/generated/model/userProfileDTOAccountSettings.ts b/src/app/generated/model/userProfileDTOAccountSettings.ts deleted file mode 100644 index 2132207..0000000 --- a/src/app/generated/model/userProfileDTOAccountSettings.ts +++ /dev/null @@ -1,30 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { AccountSettingsDTO } from './accountSettingsDTO' -import { AccountSettingsDTOLocaleAndTimeSettings } from './accountSettingsDTOLocaleAndTimeSettings' -import { AccountSettingsDTOPrivacySettings } from './accountSettingsDTOPrivacySettings' -import { AccountSettingsDTOLayoutAndThemeSettings } from './accountSettingsDTOLayoutAndThemeSettings' -import { PreferencesDTO } from './preferencesDTO' - -export interface UserProfileDTOAccountSettings { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - privacySettings?: AccountSettingsDTOPrivacySettings - localeAndTimeSettings?: AccountSettingsDTOLocaleAndTimeSettings - preferences?: Array - notificationSettings?: object | null - layoutAndThemeSettings?: AccountSettingsDTOLayoutAndThemeSettings -} diff --git a/src/app/generated/model/userProfileDTOv1.ts b/src/app/generated/model/userProfileDTOv1.ts deleted file mode 100644 index a9ed3cb..0000000 --- a/src/app/generated/model/userProfileDTOv1.ts +++ /dev/null @@ -1,42 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { UserPersonDTOv1 } from './userPersonDTOv1' -import { UserProfileDTOv1AccountSettings } from './userProfileDTOv1AccountSettings' -import { UserProfileDTOv1Avatar } from './userProfileDTOv1Avatar' -import { MembershipDTO } from './membershipDTO' - -export interface UserProfileDTOv1 { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - /** - * - */ - userId?: string - identityProvider?: string - /** - * user id in external identity provider, e.g. in keycloak - */ - identityProviderId?: string - /** - * - */ - organization?: string - person?: UserPersonDTOv1 - accountSettings?: UserProfileDTOv1AccountSettings - roles?: Set - avatar?: UserProfileDTOv1Avatar - memberships?: Array -} diff --git a/src/app/generated/model/userProfileDTOv1AccountSettings.ts b/src/app/generated/model/userProfileDTOv1AccountSettings.ts deleted file mode 100644 index b043d1c..0000000 --- a/src/app/generated/model/userProfileDTOv1AccountSettings.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { AccountSettingsDTOv1PrivacySettings } from './accountSettingsDTOv1PrivacySettings' -import { AccountSettingsDTOv1 } from './accountSettingsDTOv1' -import { AccountSettingsDTOv1LocaleAndTimeSettings } from './accountSettingsDTOv1LocaleAndTimeSettings' -import { AccountSettingsDTOv1LayoutAndThemeSettings } from './accountSettingsDTOv1LayoutAndThemeSettings' - -export interface UserProfileDTOv1AccountSettings { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - privacySettings?: AccountSettingsDTOv1PrivacySettings - localeAndTimeSettings?: AccountSettingsDTOv1LocaleAndTimeSettings - notificationSettings?: object | null - layoutAndThemeSettings?: AccountSettingsDTOv1LayoutAndThemeSettings -} diff --git a/src/app/generated/model/userProfileDTOv1Avatar.ts b/src/app/generated/model/userProfileDTOv1Avatar.ts deleted file mode 100644 index fd9541e..0000000 --- a/src/app/generated/model/userProfileDTOv1Avatar.ts +++ /dev/null @@ -1,28 +0,0 @@ -/** - * tkit-portal-server API - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 4.4.0-SNAPSHOT - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ -import { ImageInfoDTOv1 } from './imageInfoDTOv1' - -export interface UserProfileDTOv1Avatar { - version?: number - creationDate?: string - creationUser?: string - modificationDate?: string - modificationUser?: string - id?: string - /** - * flag whether Image was uploaded by user - */ - userUploaded?: boolean - lastUpdateTime?: string | null - imageUrl?: string - smallImageUrl?: string -} diff --git a/src/app/generated/model/validationConstraint.ts b/src/app/generated/model/validationConstraint.ts new file mode 100644 index 0000000..41f1cc1 --- /dev/null +++ b/src/app/generated/model/validationConstraint.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface ValidationConstraint { + name?: string; + message?: string; +} + diff --git a/src/app/generated/model/workspace.ts b/src/app/generated/model/workspace.ts new file mode 100644 index 0000000..32a5b67 --- /dev/null +++ b/src/app/generated/model/workspace.ts @@ -0,0 +1,18 @@ +/** + * onecx-theme-bff + * OneCx theme Bff + * + * The version of the OpenAPI document: 1.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export interface Workspace { + workspaceName?: string; + description?: string; +} + diff --git a/src/app/generated/param.ts b/src/app/generated/param.ts new file mode 100644 index 0000000..78a2d20 --- /dev/null +++ b/src/app/generated/param.ts @@ -0,0 +1,69 @@ +/** + * Standard parameter styles defined by OpenAPI spec + */ +export type StandardParamStyle = + | 'matrix' + | 'label' + | 'form' + | 'simple' + | 'spaceDelimited' + | 'pipeDelimited' + | 'deepObject' + ; + +/** + * The OpenAPI standard {@link StandardParamStyle}s may be extended by custom styles by the user. + */ +export type ParamStyle = StandardParamStyle | string; + +/** + * Standard parameter locations defined by OpenAPI spec + */ +export type ParamLocation = 'query' | 'header' | 'path' | 'cookie'; + +/** + * Standard types as defined in OpenAPI Specification: Data Types + */ +export type StandardDataType = + | "integer" + | "number" + | "boolean" + | "string" + | "object" + | "array" + ; + +/** + * Standard {@link DataType}s plus your own types/classes. + */ +export type DataType = StandardDataType | string; + +/** + * Standard formats as defined in OpenAPI Specification: Data Types + */ +export type StandardDataFormat = + | "int32" + | "int64" + | "float" + | "double" + | "byte" + | "binary" + | "date" + | "date-time" + | "password" + ; + +export type DataFormat = StandardDataFormat | string; + +/** + * The parameter to encode. + */ +export interface Param { + name: string; + value: unknown; + in: ParamLocation; + style: ParamStyle, + explode: boolean; + dataType: DataType; + dataFormat: DataFormat | undefined; +} diff --git a/src/app/generated/variables.ts b/src/app/generated/variables.ts index f31cb62..6fe5854 100644 --- a/src/app/generated/variables.ts +++ b/src/app/generated/variables.ts @@ -1,9 +1,9 @@ -import { InjectionToken } from '@angular/core' +import { InjectionToken } from '@angular/core'; -export const BASE_PATH = new InjectionToken('basePath') +export const BASE_PATH = new InjectionToken('basePath'); export const COLLECTION_FORMATS = { - csv: ',', - tsv: ' ', - ssv: ' ', - pipes: '|', + 'csv': ',', + 'tsv': ' ', + 'ssv': ' ', + 'pipes': '|' } diff --git a/src/app/theme/theme-designer/theme-designer.component.ts b/src/app/theme/theme-designer/theme-designer.component.ts index bb37a2f..e59382d 100644 --- a/src/app/theme/theme-designer/theme-designer.component.ts +++ b/src/app/theme/theme-designer/theme-designer.component.ts @@ -9,7 +9,7 @@ import { Action, ConfigurationService, ThemeService, PortalMessageService } from import { themeVariables } from '../theme-variables' import { environment } from '../../../environments/environment' -import { CreateThemeDTO, ImageV1APIService, ThemeDTO, ThemesAPIService } from '../../generated' +import { GetThemeResponse, Theme, ThemesAPIService, ThemeUpdateCreate, UpdateThemeResponse } from '../../generated' import { dropDownSortItemsByLabel, dropDownGetLabelByValue, setFetchUrls } from '../../shared/utils' @Component({ @@ -24,8 +24,8 @@ export class ThemeDesignerComponent implements OnInit { @ViewChild('selectedFileInputFavicon') selectedFileInputFavicon: ElementRef | undefined public actions: Action[] = [] - themes: ThemeDTO[] = [] - theme: ThemeDTO | undefined + themes: Theme[] = [] + theme: Theme | undefined themeId: string | null themeVars = themeVariables themeTemplates!: SelectItem[] @@ -59,7 +59,7 @@ export class ThemeDesignerComponent implements OnInit { private router: Router, private themeApi: ThemesAPIService, private themeService: ThemeService, - private imageApi: ImageV1APIService, + //private imageApi: ImageV1APIService, private config: ConfigurationService, private translate: TranslateService, private confirmation: ConfirmationService, @@ -153,10 +153,10 @@ export class ThemeDesignerComponent implements OnInit { ngOnInit(): void { if (this.mode === 'EDIT' && this.themeId) { this.getThemeById(this.themeId).subscribe((data) => { - this.theme = data + this.theme = data.resource this.basicForm.patchValue(data) this.propertiesForm.reset() - this.propertiesForm.patchValue(data.properties || {}) + this.propertiesForm.patchValue(data.resource.properties || {}) this.setFetchUrls() }) } else { @@ -207,12 +207,14 @@ export class ThemeDesignerComponent implements OnInit { // DropDown Theme Template private loadThemeTemplates(): void { - this.themeApi.getThemes().subscribe((data) => { - this.themeTemplates = [...data.map(this.themeDropdownMappingFn).sort(dropDownSortItemsByLabel)] + this.themeApi.getThemes({}).subscribe((data) => { + if (data.stream !== undefined) { + this.themeTemplates = [...data.stream.map(this.themeDropdownMappingFn).sort(dropDownSortItemsByLabel)] + } }) } - private themeDropdownMappingFn = (theme: ThemeDTO) => { + private themeDropdownMappingFn = (theme: Theme) => { return { label: theme.name, value: theme.id @@ -241,15 +243,15 @@ export class ThemeDesignerComponent implements OnInit { () => { this.getThemeById(this.themeTemplateSelectedId).subscribe((result) => { if (this.mode === 'NEW') { - this.basicForm.controls['name'].setValue(data['GENERAL.COPY_OF'] + result.name) - this.basicForm.controls['description'].setValue(result.description) - this.basicForm.controls['faviconUrl'].setValue(result.faviconUrl) - this.basicForm.controls['logoUrl'].setValue(result.logoUrl) + this.basicForm.controls['name'].setValue(data['GENERAL.COPY_OF'] + result.resource.name) + this.basicForm.controls['description'].setValue(result.resource.description) + this.basicForm.controls['faviconUrl'].setValue(result.resource.faviconUrl) + this.basicForm.controls['logoUrl'].setValue(result.resource.logoUrl) this.setFetchUrls() } - if (result.properties) { + if (result.resource.properties) { this.propertiesForm.reset() - this.propertiesForm.patchValue(result.properties) + this.propertiesForm.patchValue(result.resource.properties) } }) }, @@ -286,17 +288,17 @@ export class ThemeDesignerComponent implements OnInit { this.getThemeById(this.themeId!) .pipe( switchMap((data) => { - data.properties = this.propertiesForm.value + data.resource.properties = this.propertiesForm.value Object.assign(data, this.basicForm.value) // eslint-disable-next-line @typescript-eslint/no-non-null-assertion return this.themeApi.updateTheme({ id: this.themeId!, - updateThemeDTO: data + updateThemeRequest: data }) }) ) .subscribe({ - next: (data: ThemeDTO) => { + next: (data: UpdateThemeResponse) => { this.msgService.success({ summaryKey: 'ACTIONS.EDIT.MESSAGE.CHANGE_OK' }) // apply theme changes immediately if it is the theme of the current portal if (this.themeIsCurrentUsedTheme) { @@ -312,18 +314,18 @@ export class ThemeDesignerComponent implements OnInit { } public saveTheme(newThemename: string): void { - const newTheme: CreateThemeDTO = { ...this.basicForm.value } + const newTheme: ThemeUpdateCreate = { ...this.basicForm.value } newTheme.name = newThemename newTheme.properties = this.propertiesForm.value - this.themeApi.createNewTheme({ createThemeDTO: newTheme }).subscribe({ + this.themeApi.createTheme({ createThemeRequest: { resource: newTheme } }).subscribe({ next: (data) => { if (this.mode === 'EDIT') { - this.router.navigate([`../../${data.id}`], { + this.router.navigate([`../../${data.resource.id}`], { relativeTo: this.route }) } else { - this.router.navigate([`../${data.id}`], { relativeTo: this.route }) + this.router.navigate([`../${data.resource.id}`], { relativeTo: this.route }) } this.msgService.success({ summaryKey: 'ACTIONS.CREATE.MESSAGE.CREATE_OK' }) }, @@ -353,7 +355,7 @@ export class ThemeDesignerComponent implements OnInit { } } - private getThemeById(id: string): Observable { + private getThemeById(id: string): Observable { return this.themeApi.getThemeById({ id: id }) } @@ -361,6 +363,7 @@ export class ThemeDesignerComponent implements OnInit { public onFileUpload(ev: Event, fieldType: 'logo' | 'favicon'): void { this.displayFileTypeErrorLogo = false this.displayFileTypeErrorFavicon = false + /** if (ev.target && (ev.target as HTMLInputElement).files) { const files = (ev.target as HTMLInputElement).files if (files) { @@ -378,6 +381,7 @@ export class ThemeDesignerComponent implements OnInit { } } } + */ } private setFetchUrls(): void { this.fetchingLogoUrl = setFetchUrls(this.apiPrefix, this.basicForm.value.logoUrl) diff --git a/src/app/theme/theme-detail/theme-detail.component.ts b/src/app/theme/theme-detail/theme-detail.component.ts index 9d1d069..dd8c8bd 100644 --- a/src/app/theme/theme-detail/theme-detail.component.ts +++ b/src/app/theme/theme-detail/theme-detail.component.ts @@ -6,8 +6,8 @@ import { TranslateService } from '@ngx-translate/core' import FileSaver from 'file-saver' import { Action, ConfigurationService, ObjectDetailItem, PortalMessageService } from '@onecx/portal-integration-angular' -import { filterObject, limitText, sortByLocale } from '../../shared/utils' -import { ThemeDTO, ThemesAPIService, PortalIdentifierDTO } from '../../generated' +import { limitText, sortByLocale } from '../../shared/utils' +import { ExportThemeRequest, Theme, ThemesAPIService, Workspace } from '../../generated' import { environment } from '../../../environments/environment' @Component({ @@ -16,7 +16,8 @@ import { environment } from '../../../environments/environment' providers: [ConfigurationService] }) export class ThemeDetailComponent implements OnInit { - theme: ThemeDTO | undefined + theme: Theme | undefined + usedInWorkspace: Workspace[] | undefined themeId!: string themeDeleteVisible = false themeDeleteMessage = '' @@ -51,7 +52,8 @@ export class ThemeDetailComponent implements OnInit { ) .subscribe({ next: (data) => { - this.theme = data + this.theme = data.resource + this.usedInWorkspace = data.workspaces this.preparePage() this.setHeaderImageUrl() }, @@ -185,18 +187,24 @@ export class ThemeDetailComponent implements OnInit { } onExportTheme(): void { - const themeExportData = filterObject(this.theme, [ - 'creationDate', - 'creationUser', - 'modificationDate', - 'modificationUser', - 'id', - 'portalId', - 'tenantId', - 'portals' - ]) as ThemeDTO - const themeJSON = JSON.stringify(themeExportData, null, 2) - FileSaver.saveAs(new Blob([themeJSON], { type: 'text/json' }), `${this.theme?.name + '_Theme'}.json`) + if (this.theme?.name) { + const exportThemeRequest: ExportThemeRequest = { names: [this.theme.name] } + console.log(exportThemeRequest) + this.themeApi + .exportThemes({ + exportThemeRequest + }) + .subscribe({ + next: (data) => { + const themeJSON = JSON.stringify(data, null, 2) + FileSaver.saveAs(new Blob([themeJSON], { type: 'text/json' }), `${this.theme?.name + '_Theme'}.json`) + }, + error: (err) => { + console.log(err) + this.msgService.error({ summaryKey: 'ACTIONS.EXPORT.EXPORT_THEME_FAIL' }) + } + }) + } } private setHeaderImageUrl(): void { @@ -209,7 +217,7 @@ export class ThemeDetailComponent implements OnInit { } public prepareUsedInPortalList(): string { - const arr = this.theme?.portals?.map((portal: PortalIdentifierDTO) => portal.portalName) + const arr = this.usedInWorkspace?.map((workspace: Workspace) => workspace.workspaceName) return arr?.sort(sortByLocale).join(', ') || '' } } diff --git a/src/app/theme/theme-detail/theme-intern/theme-intern.component.ts b/src/app/theme/theme-detail/theme-intern/theme-intern.component.ts index 069e1fb..63e9b92 100644 --- a/src/app/theme/theme-detail/theme-intern/theme-intern.component.ts +++ b/src/app/theme/theme-detail/theme-intern/theme-intern.component.ts @@ -1,14 +1,14 @@ import { Component, Input } from '@angular/core' import { TranslateService } from '@ngx-translate/core' -import { ThemeDTO } from '../../../generated/model/themeDTO' +import { Theme } from '../../../generated' @Component({ selector: 'tm-theme-intern', templateUrl: './theme-intern.component.html' }) export class ThemeInternComponent { - @Input() theme: ThemeDTO | undefined + @Input() theme: Theme | undefined @Input() dateFormat = 'medium' constructor(private translate: TranslateService) {} diff --git a/src/app/theme/theme-import/theme-import.component.html b/src/app/theme/theme-import/theme-import.component.html index 9d866ac..b8a3e23 100644 --- a/src/app/theme/theme-import/theme-import.component.html +++ b/src/app/theme/theme-import/theme-import.component.html @@ -24,14 +24,14 @@ [chooseLabel]="'ACTIONS.CHOOSE' | translate" > -
+
{{ 'THEME.NO_PROPERTIES' | translate }}
+ themes$!: Observable public actions: Action[] = [] public viewMode = 'grid' public filter: string | undefined @@ -57,7 +57,7 @@ export class ThemeSearchComponent implements OnInit { } public loadThemes(): void { - this.themes$ = this.themeApi.getThemes() + this.themes$ = this.themeApi.getThemes({}) } prepareActionButtons(data: any): void { diff --git a/src/assets/api/themes-bff-api.yaml b/src/assets/api/themes-bff-api.yaml new file mode 100644 index 0000000..58b7289 --- /dev/null +++ b/src/assets/api/themes-bff-api.yaml @@ -0,0 +1,516 @@ +--- +openapi: 3.0.3 +info: + title: onecx-theme-bff + description: OneCx theme Bff + version: '1.0' +servers: + - url: http://onecx-theme-bff:8080/ +tags: + - name: theme +paths: + /themes: + get: + tags: + - themes + description: Find all themes + operationId: getThemes + parameters: + - $ref: '#/components/parameters/pageNumber' + - $ref: '#/components/parameters/pageSize' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/GetThemesResponse' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' + '404': + description: Not found + post: + tags: + - themes + description: Create theme + operationId: createTheme + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/CreateThemeRequest' + responses: + '201': + description: Created + content: + application/json: + schema: + $ref: '#/components/schemas/CreateThemeResponse' + '204': + description: No Content + '400': + description: Bad Request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' + '404': + description: Not Found + /themes/{id}: + get: + tags: + - themes + description: Find theme by id + operationId: getThemeById + parameters: + - $ref: '#/components/parameters/id' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/GetThemeResponse' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' + '404': + description: Not Found + put: + tags: + - themes + description: Update theme + operationId: updateTheme + parameters: + - $ref: '#/components/parameters/id' + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UpdateThemeRequest' + responses: + '200': + description: Ok + content: + application/json: + schema: + $ref: '#/components/schemas/UpdateThemeResponse' + '204': + description: No Content + '400': + description: Bad Request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' + '404': + description: Not Found + delete: + tags: + - themes + description: Delete theme + operationId: deleteTheme + parameters: + - $ref: '#/components/parameters/id' + responses: + '204': + description: No Content + '400': + description: Bad Request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' + /themes/name/{name}: + get: + tags: + - themes + description: Find theme by name including workspace + operationId: getThemeByName + parameters: + - $ref: '#/components/parameters/name' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/GetThemeResponse' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' + '404': + description: Not Found + /themes/search: + post: + tags: + - themes + description: Search themes by criteria + operationId: searchThemes + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/SearchThemeRequest' + responses: + '200': + description: Ok + content: + application/json: + schema: + $ref: '#/components/schemas/SearchThemeResponse' + '204': + description: No Content + '400': + description: Bad Request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' + '404': + description: Not Found + /themes/export: + post: + tags: + - themes + description: Export list of themes + operationId: exportThemes + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/ExportThemeRequest' + responses: + '200': + description: OK + content: + application/json: + schema: + $ref: '#/components/schemas/ThemeSnapshot' + '404': + description: No themes founds + /themes/import: + post: + tags: + - themes + description: Import themes + operationId: importThemes + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/ThemeSnapshot' + responses: + '200': + description: Import result + content: + application/json: + schema: + $ref: '#/components/schemas/ImportThemeResponse' + '400': + description: Bad request + content: + application/json: + schema: + $ref: '#/components/schemas/ProblemDetailResponse' +components: + schemas: + Theme: + type: object + properties: + version: + format: int32 + type: integer + creationDate: + $ref: '#/components/schemas/OffsetDateTime' + creationUser: + type: string + modificationDate: + $ref: '#/components/schemas/OffsetDateTime' + modificationUser: + type: string + id: + type: string + name: + minLength: 2 + type: string + cssFile: + type: string + description: + type: string + assetsUrl: + type: string + logoUrl: + type: string + faviconUrl: + type: string + previewImageUrl: + type: string + assetsUpdateDate: + type: string + properties: + type: object + ThemeUpdateCreate: + type: object + properties: + version: + format: int32 + type: integer + creationDate: + $ref: '#/components/schemas/OffsetDateTime' + creationUser: + type: string + modificationDate: + $ref: '#/components/schemas/OffsetDateTime' + modificationUser: + type: string + name: + minLength: 2 + type: string + cssFile: + type: string + description: + type: string + assetsUrl: + type: string + logoUrl: + type: string + faviconUrl: + type: string + previewImageUrl: + type: string + assetsUpdateDate: + type: string + properties: + type: object + + GetThemeResponse: + required: + - resource + type: object + properties: + resource: + $ref: '#/components/schemas/Theme' + workspaces: + type: array + items: + $ref: '#/components/schemas/Workspace' + GetThemesResponse: + allOf: # Combines the PagingResponse and the Resources + - $ref: '#/components/schemas/PagingResponse' + - type: object + properties: + stream: + type: array + items: + $ref: '#/components/schemas/Theme' + CreateThemeResponse: + required: + - resource + type: object + properties: + resource: + $ref: '#/components/schemas/Theme' + UpdateThemeResponse: + required: + - resource + type: object + properties: + resource: + $ref: '#/components/schemas/Theme' + OffsetDateTime: + format: date-time + type: string + example: 2022-03-10T12:15:50-04:00 + ProblemDetailResponse: + type: object + properties: + errorCode: + type: string + detail: + type: string + params: + type: array + items: + $ref: '#/components/schemas/ProblemDetailParam' + invalidParams: + type: array + items: + $ref: '#/components/schemas/ProblemDetailInvalidParam' + ProblemDetailParam: + type: object + properties: + key: + type: string + value: + type: string + ProblemDetailInvalidParam: + type: object + properties: + name: + type: string + message: + type: string + ValidationConstraint: + type: object + properties: + name: + type: string + message: + type: string + CreateThemeRequest: + required: + - resource + type: object + properties: + resource: + $ref: '#/components/schemas/ThemeUpdateCreate' + UpdateThemeRequest: + required: + - resource + type: object + properties: + resource: + $ref: '#/components/schemas/ThemeUpdateCreate' + SearchThemeRequest: + type: object + properties: + name: + type: string + pageNumber: + type: integer + format: int32 + default: 0 + pageSize: + type: integer + format: int32 + SearchThemeResponse: + allOf: + - $ref: '#/components/schemas/PagingResponse' + - type: object + properties: + stream: + type: array + items: + $ref: '#/components/schemas/Theme' + PagingResponse: + type: object + properties: + totalElements: + format: int64 + type: integer + number: + format: int32 + type: integer + size: + format: int32 + type: integer + totalPages: + format: int64 + type: integer + Workspace: + type: object + properties: + workspaceName: + type: string + description: + type: string + ExportThemeRequest: + type: object + properties: + names: + type: array + uniqueItems: true + items: + type: string + ThemeSnapshot: + type: object + properties: + id: + type: string + minLength: 10 + description: ID of the request + created: + $ref: '#/components/schemas/OffsetDateTime' + themes: + type: object + nullable: false + additionalProperties: + $ref: '#/components/schemas/EximTheme' + ImportThemeResponse: + type: object + properties: + id: + type: string + minLength: 10 + description: ID of the request + themes: + additionalProperties: + $ref: '#/components/schemas/ImportThemeResponseStatus' + ImportThemeResponseStatus: + type: string + enum: + - UPDATE + - CREATED + - SKIP + EximTheme: + type: object + properties: + cssFile: + type: string + description: + type: string + assetsUrl: + type: string + logoUrl: + type: string + faviconUrl: + type: string + previewImageUrl: + type: string + assetsUpdateDate: + type: string + properties: + type: object + parameters: + pageNumber: + in: query + name: pageNumber + required: false + schema: + type: integer + format: int32 + default: 0 + pageSize: + in: query + name: pageSize + required: false + schema: + type: integer + format: int32 + default: 100 + id: + in: path + name: id + required: true + schema: + type: string + name: + in: path + name: name + required: true + schema: + type: string diff --git a/src/assets/i18n/de.json b/src/assets/i18n/de.json index fd87f80..e7f0077 100644 --- a/src/assets/i18n/de.json +++ b/src/assets/i18n/de.json @@ -34,7 +34,8 @@ "EXPORT": { "LABEL": "Export", "TOOLTIP": "Definition als JSON herunterladen", - "THEME": "Theme exportieren" + "THEME": "Theme exportieren", + "EXPORT_THEME_FAIL": "Ein Fehler ist aufgetreten. Das Theme wurde nicht exportiert." }, "IMPORT": { "LABEL": "Import", diff --git a/src/assets/i18n/en.json b/src/assets/i18n/en.json index aa12e0d..1a98407 100644 --- a/src/assets/i18n/en.json +++ b/src/assets/i18n/en.json @@ -34,7 +34,8 @@ "EXPORT": { "LABEL": "Export", "TOOLTIP": "Export definition in JSON format", - "THEME": "Export Theme" + "THEME": "Export Theme", + "EXPORT_THEME_FAIL": "An error occurred, the Theme was not exported." }, "IMPORT": { "LABEL": "Import", diff --git a/src/environments/environment.prod.ts b/src/environments/environment.prod.ts index 15594ad..cc6b58d 100644 --- a/src/environments/environment.prod.ts +++ b/src/environments/environment.prod.ts @@ -1,5 +1,5 @@ export const environment = { production: true, - BASE_PATH: '/portal-api', - apiPrefix: 'portal-api' + BASE_PATH: '/themes-bff', + apiPrefix: 'themes-bff' } diff --git a/src/environments/environment.ts b/src/environments/environment.ts index e26f52d..808435c 100644 --- a/src/environments/environment.ts +++ b/src/environments/environment.ts @@ -9,7 +9,7 @@ export const environment = { KEYCLOAK_CLIENT_ID: 'portal-mf-shell', TKIT_PORTAL_ID: 'ADMIN', skipRemoteConfigLoad: true, - apiPrefix: 'portal-api' + apiPrefix: 'themes-bff' } /*