new-front-common-library 16.1.32-LEG-2 → 16.1.32-ROY-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +28 -28
- package/assets/css/_dark-theme.scss +243 -243
- package/assets/css/_flex.scss +55 -55
- package/assets/css/_global.scss +417 -417
- package/assets/css/_light-theme.scss +221 -221
- package/assets/css/_mat-palettes.scss +98 -98
- package/assets/css/_themes.scss +56 -56
- package/assets/css/_themes_v18.scss +55 -55
- package/assets/css/material/_mdc-dark-theme.scss +265 -265
- package/assets/css/material/_mdc-light-theme.scss +264 -264
- package/assets/css/material/_mdc.scss +408 -408
- package/assets/css/old-themes/_dark-theme.scss +639 -639
- package/assets/css/old-themes/_global.scss +689 -689
- package/assets/css/old-themes/_light-theme.scss +646 -646
- package/assets/css/old-themes/_themes-deprecated.scss +65 -65
- package/assets/i18n/front-common/de.json +30 -30
- package/assets/i18n/front-common/en.json +30 -30
- package/assets/i18n/front-common/fr.json +30 -30
- package/esm2022/lib/util/array.service.mjs +19 -19
- package/esm2022/lib/util/component/header/header.component.mjs +221 -221
- package/esm2022/lib/util/component/header/menu/menu.component.mjs +96 -96
- package/esm2022/lib/util/component/header/menu/menu.const.mjs +544 -544
- package/esm2022/lib/util/component/header/menu/menu.model.mjs +2 -2
- package/esm2022/lib/util/component/overlay/overlay.component.mjs +40 -40
- package/esm2022/lib/util/component/overlay/overlay.service.mjs +24 -24
- package/esm2022/lib/util/component/popup/popup-login/popup-login.component.mjs +90 -90
- package/esm2022/lib/util/component/sub-header/sub-header.component.mjs +44 -44
- package/esm2022/lib/util/config.mjs +8 -8
- package/esm2022/lib/util/date/PeriodModel.mjs +8 -8
- package/esm2022/lib/util/date/date-format-constants.mjs +12 -12
- package/esm2022/lib/util/date/date.util.mjs +218 -218
- package/esm2022/lib/util/decorators/theme.decorator.mjs +22 -22
- package/esm2022/lib/util/decorators/user.decorator.mjs +25 -25
- package/esm2022/lib/util/directives/my-number-formatter-directive.mjs +34 -34
- package/esm2022/lib/util/directives/show-if-truncated.directive.mjs +25 -25
- package/esm2022/lib/util/enums/family.enum.mjs +6 -6
- package/esm2022/lib/util/enums/rapid-search-item-type.enum.mjs +12 -12
- package/esm2022/lib/util/enums/status-color.enum.mjs +11 -11
- package/esm2022/lib/util/event/header/header-events.service.mjs +21 -21
- package/esm2022/lib/util/event/storage/local-storage-events.service.mjs +17 -17
- package/esm2022/lib/util/event/storage/session-storage-events.service.mjs +18 -18
- package/esm2022/lib/util/http/http-params.builder.mjs +27 -27
- package/esm2022/lib/util/i18n/de.mjs +158 -158
- package/esm2022/lib/util/i18n/en.mjs +158 -158
- package/esm2022/lib/util/i18n/fr.mjs +158 -158
- package/esm2022/lib/util/i18n/multi-translate-http-loader.mjs +21 -21
- package/esm2022/lib/util/interfaces/permissions.interface.mjs +2 -2
- package/esm2022/lib/util/models/any-line.model.mjs +37 -37
- package/esm2022/lib/util/models/audio-content.model.mjs +27 -27
- package/esm2022/lib/util/models/authPermission.model.mjs +16 -16
- package/esm2022/lib/util/models/authUser.model.mjs +21 -21
- package/esm2022/lib/util/models/basic.model.mjs +14 -14
- package/esm2022/lib/util/models/box-set-item.model.mjs +19 -19
- package/esm2022/lib/util/models/commercial/deal-rapid-search-model.mjs +3 -3
- package/esm2022/lib/util/models/commercial/invoice-rapid-search-model.mjs +9 -9
- package/esm2022/lib/util/models/commercial/work-record-rapid-search-model.mjs +13 -13
- package/esm2022/lib/util/models/disc-program.model.mjs +26 -26
- package/esm2022/lib/util/models/disc.model.mjs +22 -22
- package/esm2022/lib/util/models/eventType.model.mjs +7 -7
- package/esm2022/lib/util/models/expenditure-commitment/purchase-order-file.model.mjs +22 -22
- package/esm2022/lib/util/models/expenditure-commitment/purchase-order-rapid-search.model.mjs +3 -3
- package/esm2022/lib/util/models/family.model.mjs +7 -7
- package/esm2022/lib/util/models/index.mjs +101 -101
- package/esm2022/lib/util/models/lang-line.model.mjs +27 -27
- package/esm2022/lib/util/models/legal/contract-rapid-search-model.mjs +3 -3
- package/esm2022/lib/util/models/legal/contract-work.model.mjs +23 -23
- package/esm2022/lib/util/models/legal/contract-work2.model.mjs +21 -21
- package/esm2022/lib/util/models/legal/type-status-rapid-search.model.mjs +3 -3
- package/esm2022/lib/util/models/media-line.model.mjs +18 -18
- package/esm2022/lib/util/models/menu-language.model.mjs +15 -15
- package/esm2022/lib/util/models/permission.model.mjs +20 -20
- package/esm2022/lib/util/models/product-box-set.model.mjs +16 -16
- package/esm2022/lib/util/models/product-disc-detail.model.mjs +22 -22
- package/esm2022/lib/util/models/product-disc.model.mjs +27 -27
- package/esm2022/lib/util/models/product-division.model.mjs +29 -29
- package/esm2022/lib/util/models/product-type.model.mjs +22 -22
- package/esm2022/lib/util/models/product.model.mjs +62 -62
- package/esm2022/lib/util/models/program.model.mjs +28 -28
- package/esm2022/lib/util/models/purchase-order/purchase-order.model.mjs +53 -53
- package/esm2022/lib/util/models/referential/WorkVersionArticleDto.mjs +17 -17
- package/esm2022/lib/util/models/referential/adress-type.model.mjs +14 -14
- package/esm2022/lib/util/models/referential/adress.model.mjs +28 -28
- package/esm2022/lib/util/models/referential/attached-file.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/bank-account.model.mjs +24 -24
- package/esm2022/lib/util/models/referential/bank-accounts.model.mjs +31 -31
- package/esm2022/lib/util/models/referential/basic-hierarchy.model.mjs +8 -8
- package/esm2022/lib/util/models/referential/broadcast-list-item.model.mjs +13 -13
- package/esm2022/lib/util/models/referential/color.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/company.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/content-type.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/content.model.mjs +22 -22
- package/esm2022/lib/util/models/referential/cost-center-criteria-values.model.mjs +14 -14
- package/esm2022/lib/util/models/referential/cost-center-criteria.model.mjs +13 -13
- package/esm2022/lib/util/models/referential/cost-center.model.mjs +28 -28
- package/esm2022/lib/util/models/referential/coutry.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/currency.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/editorial-content.model.mjs +18 -18
- package/esm2022/lib/util/models/referential/fixing.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/flat-media.model.mjs +18 -18
- package/esm2022/lib/util/models/referential/format-image.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/format-type.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/format.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/fsk-index.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/fsk.model.mjs +22 -22
- package/esm2022/lib/util/models/referential/function.model.mjs +23 -23
- package/esm2022/lib/util/models/referential/genre.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/invoice-product-type.model.mjs +22 -22
- package/esm2022/lib/util/models/referential/keywords.model.mjs +13 -13
- package/esm2022/lib/util/models/referential/language.model.mjs +18 -18
- package/esm2022/lib/util/models/referential/media-filter.model.mjs +3 -3
- package/esm2022/lib/util/models/referential/media.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/module.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/parameter.model.mjs +2 -2
- package/esm2022/lib/util/models/referential/participant.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/person.model.mjs +23 -23
- package/esm2022/lib/util/models/referential/project-status.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/quota.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/referential-entity-state.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/referential-value.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/referentiel.model.mjs +26 -26
- package/esm2022/lib/util/models/referential/restriction.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/sap-order.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/service-error.model.mjs +15 -15
- package/esm2022/lib/util/models/referential/sound.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/territories-languages.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/territory-filter.model.mjs +3 -3
- package/esm2022/lib/util/models/referential/territory.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/theme.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/third-party-address-rapid-search.model.mjs +3 -3
- package/esm2022/lib/util/models/referential/third-party-creation-request.model.mjs +44 -44
- package/esm2022/lib/util/models/referential/third-party-module.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/third-party-rapid-search.model.mjs +3 -3
- package/esm2022/lib/util/models/referential/third-party.model.mjs +83 -83
- package/esm2022/lib/util/models/referential/translated-value-model.mjs +16 -16
- package/esm2022/lib/util/models/referential/tva.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/type-export.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/type-tva-company-territory.model.mjs +32 -32
- package/esm2022/lib/util/models/referential/type-tva.model.mjs +25 -25
- package/esm2022/lib/util/models/referential/user-form.model.mjs +2 -2
- package/esm2022/lib/util/models/referential/work-addons-model.mjs +16 -16
- package/esm2022/lib/util/models/referential/work-appartenance.model.mjs +17 -17
- package/esm2022/lib/util/models/referential/work-genre.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/work-language.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/work-milo.model.mjs +61 -61
- package/esm2022/lib/util/models/referential/work-participant.model.mjs +21 -21
- package/esm2022/lib/util/models/referential/work-restrictions-model.mjs +13 -13
- package/esm2022/lib/util/models/referential/work-theme.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/work-title.model.mjs +20 -20
- package/esm2022/lib/util/models/referential/work-version-origin.model.mjs +16 -16
- package/esm2022/lib/util/models/referential/work-version-rapid-search.model.mjs +3 -3
- package/esm2022/lib/util/models/referential/work-versions-used.model.mjs +19 -19
- package/esm2022/lib/util/models/referential/work-versions.model.mjs +27 -27
- package/esm2022/lib/util/models/referential/work-year-production.model.mjs +13 -13
- package/esm2022/lib/util/models/referential/work.model.mjs +22 -22
- package/esm2022/lib/util/models/referential/zone.model.mjs +14 -14
- package/esm2022/lib/util/models/referentiel.model.mjs +26 -26
- package/esm2022/lib/util/models/search-response.model.mjs +10 -10
- package/esm2022/lib/util/models/section.model.mjs +8 -8
- package/esm2022/lib/util/models/select/options.model.mjs +8 -8
- package/esm2022/lib/util/models/select/select.model.mjs +7 -7
- package/esm2022/lib/util/models/subsidiary.model.mjs +8 -8
- package/esm2022/lib/util/models/subtitle-content.model.mjs +28 -28
- package/esm2022/lib/util/models/user-video.model.mjs +22 -22
- package/esm2022/lib/util/models/user.model.mjs +35 -36
- package/esm2022/lib/util/models/video/product-rapid-search.model.mjs +3 -3
- package/esm2022/lib/util/models/video/support-rapid-search.model.mjs +3 -3
- package/esm2022/lib/util/models/video-content.model.mjs +18 -18
- package/esm2022/lib/util/number.validator.mjs +129 -129
- package/esm2022/lib/util/paginator/custom-paginator-configuration.mjs +59 -59
- package/esm2022/lib/util/permissions/permissions.service.mjs +49 -49
- package/esm2022/lib/util/pipes/capitalizefirst.pipe.mjs +41 -41
- package/esm2022/lib/util/pipes/comma-separated-number.pipe.mjs +15 -15
- package/esm2022/lib/util/pipes/common-translate.pipe.mjs +38 -38
- package/esm2022/lib/util/pipes/display-html.pipe.mjs +20 -20
- package/esm2022/lib/util/pipes/display-null.pipe.mjs +24 -24
- package/esm2022/lib/util/pipes/format-currency.pipe.mjs +31 -31
- package/esm2022/lib/util/pipes/format-duration.pipe.mjs +23 -23
- package/esm2022/lib/util/pipes/format-number-input.pipe.mjs +22 -22
- package/esm2022/lib/util/pipes/local-date.pipe.mjs +27 -27
- package/esm2022/lib/util/pipes/my-number.pipe.mjs +44 -44
- package/esm2022/lib/util/pipes/third-party-address-search.pipe.mjs +15 -15
- package/esm2022/lib/util/pipes/third-party-address.pipe.mjs +16 -16
- package/esm2022/lib/util/pipes/trim-string.pipe.mjs +25 -25
- package/esm2022/lib/util/regex/regex.service.mjs +94 -94
- package/esm2022/lib/util/services/api/commercial-api.service.mjs +28 -28
- package/esm2022/lib/util/services/api/common-api.service.mjs +98 -98
- package/esm2022/lib/util/services/api/legal-api.service.mjs +32 -32
- package/esm2022/lib/util/services/api/video-api.service.mjs +45 -45
- package/esm2022/lib/util/services/auth/auth.service.mjs +18 -18
- package/esm2022/lib/util/services/elasticsearch/elasticsearch.service.mjs +166 -158
- package/esm2022/lib/util/services/elasticsearch/subsidiaries.service.mjs +48 -54
- package/esm2022/lib/util/services/form-action/form-actions-events.service.mjs +25 -25
- package/esm2022/lib/util/services/guard/auth.guard.mjs +32 -32
- package/esm2022/lib/util/services/guard/login.guard.mjs +23 -23
- package/esm2022/lib/util/services/history/history.service.mjs +39 -39
- package/esm2022/lib/util/services/interceptor/auth.interceptor.mjs +53 -53
- package/esm2022/lib/util/services/jwt-security/aes.service.mjs +34 -34
- package/esm2022/lib/util/services/jwt-security/interceptorhttp.service.mjs +18 -18
- package/esm2022/lib/util/services/jwt-security/jwt.helpher.mjs +34 -34
- package/esm2022/lib/util/services/storage/local-storage.service.mjs +36 -36
- package/esm2022/lib/util/services/storage/session-storage.service.mjs +38 -38
- package/esm2022/lib/util/services/translate-language/lang.service.mjs +31 -31
- package/esm2022/lib/util/services/user/user-subsidiary.service.mjs +22 -22
- package/esm2022/lib/util/sort.mjs +22 -22
- package/esm2022/lib/util/theme/theme-event.service.mjs +17 -17
- package/esm2022/lib/util/toaster/toaster-events.service.mjs +32 -32
- package/esm2022/lib/util/util.module.mjs +281 -281
- package/esm2022/new-front-common-library.mjs +4 -4
- package/esm2022/public-api.mjs +59 -59
- package/fesm2022/new-front-common-library.mjs +5522 -5521
- package/fesm2022/new-front-common-library.mjs.map +1 -1
- package/index.d.ts +5 -5
- package/lib/util/array.service.d.ts +7 -7
- package/lib/util/component/header/header.component.d.ts +74 -74
- package/lib/util/component/header/menu/menu.component.d.ts +27 -27
- package/lib/util/component/header/menu/menu.const.d.ts +2 -2
- package/lib/util/component/header/menu/menu.model.d.ts +23 -23
- package/lib/util/component/overlay/overlay.component.d.ts +17 -17
- package/lib/util/component/overlay/overlay.service.d.ts +13 -13
- package/lib/util/component/popup/popup-login/popup-login.component.d.ts +35 -35
- package/lib/util/component/sub-header/sub-header.component.d.ts +13 -13
- package/lib/util/config.d.ts +8 -8
- package/lib/util/date/PeriodModel.d.ts +6 -6
- package/lib/util/date/date-format-constants.d.ts +25 -25
- package/lib/util/date/date.util.d.ts +16 -16
- package/lib/util/decorators/theme.decorator.d.ts +1 -1
- package/lib/util/decorators/user.decorator.d.ts +1 -1
- package/lib/util/directives/my-number-formatter-directive.d.ts +15 -15
- package/lib/util/directives/show-if-truncated.directive.d.ts +11 -11
- package/lib/util/enums/family.enum.d.ts +4 -4
- package/lib/util/enums/rapid-search-item-type.enum.d.ts +10 -10
- package/lib/util/enums/status-color.enum.d.ts +9 -9
- package/lib/util/event/header/header-events.service.d.ts +11 -11
- package/lib/util/event/storage/local-storage-events.service.d.ts +9 -9
- package/lib/util/event/storage/session-storage-events.service.d.ts +10 -10
- package/lib/util/http/http-params.builder.d.ts +9 -9
- package/lib/util/i18n/de.d.ts +141 -141
- package/lib/util/i18n/en.d.ts +141 -141
- package/lib/util/i18n/fr.d.ts +141 -141
- package/lib/util/i18n/multi-translate-http-loader.d.ts +14 -14
- package/lib/util/interfaces/permissions.interface.d.ts +3 -3
- package/lib/util/models/any-line.model.d.ts +24 -24
- package/lib/util/models/audio-content.model.d.ts +27 -27
- package/lib/util/models/authPermission.model.d.ts +7 -7
- package/lib/util/models/authUser.model.d.ts +16 -16
- package/lib/util/models/basic.model.d.ts +11 -11
- package/lib/util/models/box-set-item.model.d.ts +12 -12
- package/lib/util/models/commercial/deal-rapid-search-model.d.ts +10 -10
- package/lib/util/models/commercial/invoice-rapid-search-model.d.ts +18 -18
- package/lib/util/models/commercial/work-record-rapid-search-model.d.ts +21 -21
- package/lib/util/models/disc-program.model.d.ts +9 -9
- package/lib/util/models/disc.model.d.ts +15 -15
- package/lib/util/models/eventType.model.d.ts +5 -5
- package/lib/util/models/expenditure-commitment/purchase-order-file.model.d.ts +8 -8
- package/lib/util/models/expenditure-commitment/purchase-order-rapid-search.model.d.ts +10 -10
- package/lib/util/models/family.model.d.ts +5 -5
- package/lib/util/models/index.d.ts +100 -100
- package/lib/util/models/lang-line.model.d.ts +18 -18
- package/lib/util/models/legal/contract-rapid-search-model.d.ts +10 -10
- package/lib/util/models/legal/contract-work.model.d.ts +27 -27
- package/lib/util/models/legal/contract-work2.model.d.ts +23 -23
- package/lib/util/models/legal/type-status-rapid-search.model.d.ts +5 -5
- package/lib/util/models/media-line.model.d.ts +9 -9
- package/lib/util/models/menu-language.model.d.ts +6 -6
- package/lib/util/models/permission.model.d.ts +12 -12
- package/lib/util/models/product-box-set.model.d.ts +8 -8
- package/lib/util/models/product-disc-detail.model.d.ts +14 -14
- package/lib/util/models/product-disc.model.d.ts +11 -11
- package/lib/util/models/product-division.model.d.ts +15 -15
- package/lib/util/models/product-type.model.d.ts +7 -7
- package/lib/util/models/product.model.d.ts +52 -52
- package/lib/util/models/program.model.d.ts +21 -21
- package/lib/util/models/purchase-order/purchase-order.model.d.ts +40 -40
- package/lib/util/models/referential/WorkVersionArticleDto.d.ts +10 -10
- package/lib/util/models/referential/adress-type.model.d.ts +5 -5
- package/lib/util/models/referential/adress.model.d.ts +20 -20
- package/lib/util/models/referential/attached-file.model.d.ts +11 -11
- package/lib/util/models/referential/bank-account.model.d.ts +15 -15
- package/lib/util/models/referential/bank-accounts.model.d.ts +17 -17
- package/lib/util/models/referential/basic-hierarchy.model.d.ts +6 -6
- package/lib/util/models/referential/broadcast-list-item.model.d.ts +8 -8
- package/lib/util/models/referential/color.model.d.ts +6 -6
- package/lib/util/models/referential/company.model.d.ts +7 -7
- package/lib/util/models/referential/content-type.model.d.ts +12 -12
- package/lib/util/models/referential/content.model.d.ts +7 -7
- package/lib/util/models/referential/cost-center-criteria-values.model.d.ts +7 -7
- package/lib/util/models/referential/cost-center-criteria.model.d.ts +12 -12
- package/lib/util/models/referential/cost-center.model.d.ts +18 -18
- package/lib/util/models/referential/coutry.model.d.ts +7 -7
- package/lib/util/models/referential/currency.model.d.ts +11 -11
- package/lib/util/models/referential/editorial-content.model.d.ts +25 -25
- package/lib/util/models/referential/fixing.model.d.ts +10 -10
- package/lib/util/models/referential/flat-media.model.d.ts +9 -9
- package/lib/util/models/referential/format-image.model.d.ts +7 -7
- package/lib/util/models/referential/format-type.model.d.ts +6 -6
- package/lib/util/models/referential/format.model.d.ts +7 -7
- package/lib/util/models/referential/fsk-index.model.d.ts +22 -22
- package/lib/util/models/referential/fsk.model.d.ts +37 -37
- package/lib/util/models/referential/function.model.d.ts +8 -8
- package/lib/util/models/referential/genre.model.d.ts +7 -7
- package/lib/util/models/referential/invoice-product-type.model.d.ts +7 -7
- package/lib/util/models/referential/keywords.model.d.ts +6 -6
- package/lib/util/models/referential/language.model.d.ts +11 -11
- package/lib/util/models/referential/media-filter.model.d.ts +10 -10
- package/lib/util/models/referential/media.model.d.ts +11 -11
- package/lib/util/models/referential/module.model.d.ts +11 -11
- package/lib/util/models/referential/parameter.model.d.ts +6 -6
- package/lib/util/models/referential/participant.model.d.ts +11 -11
- package/lib/util/models/referential/person.model.d.ts +13 -13
- package/lib/util/models/referential/project-status.model.d.ts +6 -6
- package/lib/util/models/referential/quota.model.d.ts +7 -7
- package/lib/util/models/referential/referential-entity-state.model.d.ts +11 -11
- package/lib/util/models/referential/referential-value.model.d.ts +11 -11
- package/lib/util/models/referential/referentiel.model.d.ts +12 -12
- package/lib/util/models/referential/restriction.model.d.ts +9 -9
- package/lib/util/models/referential/sap-order.model.d.ts +27 -27
- package/lib/util/models/referential/service-error.model.d.ts +13 -13
- package/lib/util/models/referential/sound.model.d.ts +6 -6
- package/lib/util/models/referential/territories-languages.model.d.ts +8 -8
- package/lib/util/models/referential/territory-filter.model.d.ts +6 -6
- package/lib/util/models/referential/territory.model.d.ts +12 -12
- package/lib/util/models/referential/theme.model.d.ts +7 -7
- package/lib/util/models/referential/third-party-address-rapid-search.model.d.ts +8 -8
- package/lib/util/models/referential/third-party-creation-request.model.d.ts +48 -48
- package/lib/util/models/referential/third-party-module.model.d.ts +11 -11
- package/lib/util/models/referential/third-party-rapid-search.model.d.ts +8 -8
- package/lib/util/models/referential/third-party.model.d.ts +45 -45
- package/lib/util/models/referential/translated-value-model.d.ts +10 -10
- package/lib/util/models/referential/tva.model.d.ts +7 -7
- package/lib/util/models/referential/type-export.model.d.ts +7 -7
- package/lib/util/models/referential/type-tva-company-territory.model.d.ts +18 -18
- package/lib/util/models/referential/type-tva.model.d.ts +10 -10
- package/lib/util/models/referential/user-form.model.d.ts +5 -5
- package/lib/util/models/referential/work-addons-model.d.ts +25 -25
- package/lib/util/models/referential/work-appartenance.model.d.ts +7 -7
- package/lib/util/models/referential/work-genre.model.d.ts +11 -11
- package/lib/util/models/referential/work-language.model.d.ts +11 -11
- package/lib/util/models/referential/work-milo.model.d.ts +46 -46
- package/lib/util/models/referential/work-participant.model.d.ts +10 -10
- package/lib/util/models/referential/work-restrictions-model.d.ts +18 -18
- package/lib/util/models/referential/work-theme.model.d.ts +11 -11
- package/lib/util/models/referential/work-title.model.d.ts +10 -10
- package/lib/util/models/referential/work-version-origin.model.d.ts +10 -10
- package/lib/util/models/referential/work-version-rapid-search.model.d.ts +9 -9
- package/lib/util/models/referential/work-versions-used.model.d.ts +12 -12
- package/lib/util/models/referential/work-versions.model.d.ts +29 -29
- package/lib/util/models/referential/work-year-production.model.d.ts +6 -6
- package/lib/util/models/referential/work.model.d.ts +74 -74
- package/lib/util/models/referential/zone.model.d.ts +6 -6
- package/lib/util/models/referentiel.model.d.ts +12 -12
- package/lib/util/models/search-response.model.d.ts +7 -7
- package/lib/util/models/section.model.d.ts +7 -7
- package/lib/util/models/select/options.model.d.ts +6 -6
- package/lib/util/models/select/select.model.d.ts +5 -5
- package/lib/util/models/subsidiary.model.d.ts +7 -7
- package/lib/util/models/subtitle-content.model.d.ts +26 -26
- package/lib/util/models/user-video.model.d.ts +10 -10
- package/lib/util/models/user.model.d.ts +27 -28
- package/lib/util/models/video/product-rapid-search.model.d.ts +8 -8
- package/lib/util/models/video/support-rapid-search.model.d.ts +6 -6
- package/lib/util/models/video-content.model.d.ts +24 -24
- package/lib/util/number.validator.d.ts +14 -14
- package/lib/util/paginator/custom-paginator-configuration.d.ts +16 -16
- package/lib/util/permissions/permissions.service.d.ts +15 -15
- package/lib/util/pipes/capitalizefirst.pipe.d.ts +8 -8
- package/lib/util/pipes/comma-separated-number.pipe.d.ts +7 -7
- package/lib/util/pipes/common-translate.pipe.d.ts +12 -12
- package/lib/util/pipes/display-html.pipe.d.ts +10 -10
- package/lib/util/pipes/display-null.pipe.d.ts +8 -8
- package/lib/util/pipes/format-currency.pipe.d.ts +10 -10
- package/lib/util/pipes/format-duration.pipe.d.ts +7 -7
- package/lib/util/pipes/format-number-input.pipe.d.ts +7 -7
- package/lib/util/pipes/local-date.pipe.d.ts +9 -9
- package/lib/util/pipes/my-number.pipe.d.ts +11 -11
- package/lib/util/pipes/third-party-address-search.pipe.d.ts +8 -8
- package/lib/util/pipes/third-party-address.pipe.d.ts +8 -8
- package/lib/util/pipes/trim-string.pipe.d.ts +7 -7
- package/lib/util/regex/regex.service.d.ts +12 -12
- package/lib/util/services/api/commercial-api.service.d.ts +12 -12
- package/lib/util/services/api/common-api.service.d.ts +27 -27
- package/lib/util/services/api/legal-api.service.d.ts +15 -15
- package/lib/util/services/api/video-api.service.d.ts +17 -17
- package/lib/util/services/auth/auth.service.d.ts +9 -9
- package/lib/util/services/elasticsearch/elasticsearch.service.d.ts +35 -34
- package/lib/util/services/elasticsearch/subsidiaries.service.d.ts +12 -12
- package/lib/util/services/form-action/form-actions-events.service.d.ts +14 -14
- package/lib/util/services/guard/auth.guard.d.ts +2 -2
- package/lib/util/services/guard/login.guard.d.ts +1 -1
- package/lib/util/services/history/history.service.d.ts +10 -10
- package/lib/util/services/interceptor/auth.interceptor.d.ts +16 -16
- package/lib/util/services/jwt-security/aes.service.d.ts +12 -12
- package/lib/util/services/jwt-security/interceptorhttp.service.d.ts +8 -8
- package/lib/util/services/jwt-security/jwt.helpher.d.ts +4 -4
- package/lib/util/services/storage/local-storage.service.d.ts +13 -13
- package/lib/util/services/storage/session-storage.service.d.ts +13 -13
- package/lib/util/services/translate-language/lang.service.d.ts +14 -14
- package/lib/util/services/user/user-subsidiary.service.d.ts +9 -9
- package/lib/util/sort.d.ts +4 -4
- package/lib/util/theme/theme-event.service.d.ts +9 -9
- package/lib/util/toaster/toaster-events.service.d.ts +15 -15
- package/lib/util/util.module.d.ts +49 -49
- package/package.json +1 -1
- package/public-api.d.ts +56 -56
|
@@ -1,49 +1,49 @@
|
|
|
1
|
-
import { __decorate } from "tslib";
|
|
2
|
-
import { Injectable } from '@angular/core';
|
|
3
|
-
import { User } from '../decorators/user.decorator';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
import * as i1 from "ngx-permissions";
|
|
6
|
-
import * as i2 from "../services/user/user-subsidiary.service";
|
|
7
|
-
export const CANAL_PLUS_INTERNATIONAL_RESTRICTION = 'CANAL_PLUS_INTERNATIONAL_RESTRICTION';
|
|
8
|
-
export class PermissionsService {
|
|
9
|
-
constructor(permissionsService, userSubsidiaryService) {
|
|
10
|
-
this.permissionsService = permissionsService;
|
|
11
|
-
this.userSubsidiaryService = userSubsidiaryService;
|
|
12
|
-
}
|
|
13
|
-
init() {
|
|
14
|
-
if (this.user?.permissions?.length > 0 && this.shouldLoadUserPermissions()) {
|
|
15
|
-
const userPermissions = this.user.permissions.map((p) => p.code);
|
|
16
|
-
// Create a virtual permission that can be used to restrict access if user only has access to "C+I"
|
|
17
|
-
// subsidiaries
|
|
18
|
-
if (this.userSubsidiaryService.isCanalPlusInternationalUser()) {
|
|
19
|
-
userPermissions.push(CANAL_PLUS_INTERNATIONAL_RESTRICTION);
|
|
20
|
-
}
|
|
21
|
-
this.permissionsService.loadPermissions(userPermissions);
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
hasPermission(code) {
|
|
25
|
-
return this.user?.permissions?.filter((p) => p.code === code).length > 0;
|
|
26
|
-
}
|
|
27
|
-
shouldLoadUserPermissions() {
|
|
28
|
-
const loadedPermissions = Object.keys(this.permissionsService.getPermissions());
|
|
29
|
-
if (loadedPermissions.length !== this.user.permissions.length) {
|
|
30
|
-
return true;
|
|
31
|
-
}
|
|
32
|
-
let res = false;
|
|
33
|
-
this.user.permissions.forEach((p) => {
|
|
34
|
-
if (loadedPermissions.indexOf(p.code) === -1) {
|
|
35
|
-
res = true;
|
|
36
|
-
}
|
|
37
|
-
});
|
|
38
|
-
return res;
|
|
39
|
-
}
|
|
40
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PermissionsService, deps: [{ token: i1.NgxPermissionsService }, { token: i2.UserSubsidiaryService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
41
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PermissionsService }); }
|
|
42
|
-
}
|
|
43
|
-
__decorate([
|
|
44
|
-
User()
|
|
45
|
-
], PermissionsService.prototype, "user", void 0);
|
|
46
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PermissionsService, decorators: [{
|
|
47
|
-
type: Injectable
|
|
48
|
-
}], ctorParameters: function () { return [{ type: i1.NgxPermissionsService }, { type: i2.UserSubsidiaryService }]; }, propDecorators: { user: [] } });
|
|
49
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { Injectable } from '@angular/core';
|
|
3
|
+
import { User } from '../decorators/user.decorator';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
import * as i1 from "ngx-permissions";
|
|
6
|
+
import * as i2 from "../services/user/user-subsidiary.service";
|
|
7
|
+
export const CANAL_PLUS_INTERNATIONAL_RESTRICTION = 'CANAL_PLUS_INTERNATIONAL_RESTRICTION';
|
|
8
|
+
export class PermissionsService {
|
|
9
|
+
constructor(permissionsService, userSubsidiaryService) {
|
|
10
|
+
this.permissionsService = permissionsService;
|
|
11
|
+
this.userSubsidiaryService = userSubsidiaryService;
|
|
12
|
+
}
|
|
13
|
+
init() {
|
|
14
|
+
if (this.user?.permissions?.length > 0 && this.shouldLoadUserPermissions()) {
|
|
15
|
+
const userPermissions = this.user.permissions.map((p) => p.code);
|
|
16
|
+
// Create a virtual permission that can be used to restrict access if user only has access to "C+I"
|
|
17
|
+
// subsidiaries
|
|
18
|
+
if (this.userSubsidiaryService.isCanalPlusInternationalUser()) {
|
|
19
|
+
userPermissions.push(CANAL_PLUS_INTERNATIONAL_RESTRICTION);
|
|
20
|
+
}
|
|
21
|
+
this.permissionsService.loadPermissions(userPermissions);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
hasPermission(code) {
|
|
25
|
+
return this.user?.permissions?.filter((p) => p.code === code).length > 0;
|
|
26
|
+
}
|
|
27
|
+
shouldLoadUserPermissions() {
|
|
28
|
+
const loadedPermissions = Object.keys(this.permissionsService.getPermissions());
|
|
29
|
+
if (loadedPermissions.length !== this.user.permissions.length) {
|
|
30
|
+
return true;
|
|
31
|
+
}
|
|
32
|
+
let res = false;
|
|
33
|
+
this.user.permissions.forEach((p) => {
|
|
34
|
+
if (loadedPermissions.indexOf(p.code) === -1) {
|
|
35
|
+
res = true;
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
return res;
|
|
39
|
+
}
|
|
40
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PermissionsService, deps: [{ token: i1.NgxPermissionsService }, { token: i2.UserSubsidiaryService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
41
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PermissionsService }); }
|
|
42
|
+
}
|
|
43
|
+
__decorate([
|
|
44
|
+
User()
|
|
45
|
+
], PermissionsService.prototype, "user", void 0);
|
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: PermissionsService, decorators: [{
|
|
47
|
+
type: Injectable
|
|
48
|
+
}], ctorParameters: function () { return [{ type: i1.NgxPermissionsService }, { type: i2.UserSubsidiaryService }]; }, propDecorators: { user: [] } });
|
|
49
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGVybWlzc2lvbnMuc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25ldy1mcm9udC1jb21tb24tbGlicmFyeS9zcmMvbGliL3V0aWwvcGVybWlzc2lvbnMvcGVybWlzc2lvbnMuc2VydmljZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUMzQyxPQUFPLEVBQUUsSUFBSSxFQUFFLE1BQU0sOEJBQThCLENBQUM7Ozs7QUFJcEQsTUFBTSxDQUFDLE1BQU0sb0NBQW9DLEdBQUcsc0NBQXNDLENBQUM7QUFHM0YsTUFBTSxPQUFPLGtCQUFrQjtJQUczQixZQUE2QixrQkFBeUMsRUFDekMscUJBQTRDO1FBRDVDLHVCQUFrQixHQUFsQixrQkFBa0IsQ0FBdUI7UUFDekMsMEJBQXFCLEdBQXJCLHFCQUFxQixDQUF1QjtJQUN6RSxDQUFDO0lBRU0sSUFBSTtRQUNQLElBQUksSUFBSSxDQUFDLElBQUksRUFBRSxXQUFXLEVBQUUsTUFBTSxHQUFHLENBQUMsSUFBSSxJQUFJLENBQUMseUJBQXlCLEVBQUUsRUFBRTtZQUN4RSxNQUFNLGVBQWUsR0FBYSxJQUFJLENBQUMsSUFBSSxDQUFDLFdBQVcsQ0FBQyxHQUFHLENBQUMsQ0FB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ygpKTtcbiAgICAgICAgaWYgKGxvYWRlZFBlcm1pc3Npb25zLmxlbmd0aCAhPT0gdGhpcy51c2VyLnBlcm1pc3Npb25zLmxlbmd0aCkge1xuICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgIH1cbiAgICAgICAgbGV0IHJlcyA9IGZhbHNlO1xuICAgICAgICB0aGlzLnVzZXIucGVybWlzc2lvbnMuZm9yRWFjaCgocCkgPT4ge1xuICAgICAgICAgICAgaWYgKGxvYWRlZFBlcm1pc3Npb25zLmluZGV4T2YocC5jb2RlKSA9PT0gLTEpIHtcbiAgICAgICAgICAgICAgICByZXMgPSB0cnVlO1xuICAgICAgICAgICAgfVxuICAgICAgICB9KTtcbiAgICAgICAgcmV0dXJuIHJlcztcbiAgICB9XG59XG4iXX0=
|
|
@@ -1,41 +1,41 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
/*
|
|
4
|
-
@Pipe({
|
|
5
|
-
name: 'capitalizeFirst'
|
|
6
|
-
})
|
|
7
|
-
*/
|
|
8
|
-
export class CapitalizefirstPipe {
|
|
9
|
-
constructor() {
|
|
10
|
-
}
|
|
11
|
-
transform(value) {
|
|
12
|
-
if (value == null) {
|
|
13
|
-
return '';
|
|
14
|
-
}
|
|
15
|
-
let valueArgs;
|
|
16
|
-
let args = (value.split('-'));
|
|
17
|
-
if (args.length === 2) {
|
|
18
|
-
for (let i = 0; i < args.length; i++) {
|
|
19
|
-
args[i] = args[i].charAt(0).toUpperCase() + args[i].slice(1).toLowerCase();
|
|
20
|
-
valueArgs = args.join('-');
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
else {
|
|
24
|
-
args = value.split(' ');
|
|
25
|
-
for (let i = 0; i < args.length; i++) {
|
|
26
|
-
args[i] = args[i].charAt(0).toUpperCase() + args[i].slice(1).toLowerCase();
|
|
27
|
-
valueArgs = args.join(' ');
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
return valueArgs;
|
|
31
|
-
}
|
|
32
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CapitalizefirstPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
33
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: CapitalizefirstPipe, name: "myCapitalizeFirst" }); }
|
|
34
|
-
}
|
|
35
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CapitalizefirstPipe, decorators: [{
|
|
36
|
-
type: Pipe,
|
|
37
|
-
args: [{
|
|
38
|
-
name: 'myCapitalizeFirst'
|
|
39
|
-
}]
|
|
40
|
-
}], ctorParameters: function () { return []; } });
|
|
41
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Pipe } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/*
|
|
4
|
+
@Pipe({
|
|
5
|
+
name: 'capitalizeFirst'
|
|
6
|
+
})
|
|
7
|
+
*/
|
|
8
|
+
export class CapitalizefirstPipe {
|
|
9
|
+
constructor() {
|
|
10
|
+
}
|
|
11
|
+
transform(value) {
|
|
12
|
+
if (value == null) {
|
|
13
|
+
return '';
|
|
14
|
+
}
|
|
15
|
+
let valueArgs;
|
|
16
|
+
let args = (value.split('-'));
|
|
17
|
+
if (args.length === 2) {
|
|
18
|
+
for (let i = 0; i < args.length; i++) {
|
|
19
|
+
args[i] = args[i].charAt(0).toUpperCase() + args[i].slice(1).toLowerCase();
|
|
20
|
+
valueArgs = args.join('-');
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
args = value.split(' ');
|
|
25
|
+
for (let i = 0; i < args.length; i++) {
|
|
26
|
+
args[i] = args[i].charAt(0).toUpperCase() + args[i].slice(1).toLowerCase();
|
|
27
|
+
valueArgs = args.join(' ');
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
return valueArgs;
|
|
31
|
+
}
|
|
32
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CapitalizefirstPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
33
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: CapitalizefirstPipe, name: "myCapitalizeFirst" }); }
|
|
34
|
+
}
|
|
35
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CapitalizefirstPipe, decorators: [{
|
|
36
|
+
type: Pipe,
|
|
37
|
+
args: [{
|
|
38
|
+
name: 'myCapitalizeFirst'
|
|
39
|
+
}]
|
|
40
|
+
}], ctorParameters: function () { return []; } });
|
|
41
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2FwaXRhbGl6ZWZpcnN0LnBpcGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9uZXctZnJvbnQtY29tbW9uLWxpYnJhcnkvc3JjL2xpYi91dGlsL3BpcGVzL2NhcGl0YWxpemVmaXJzdC5waXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxJQUFJLEVBQWlCLE1BQU0sZUFBZSxDQUFDOztBQUVwRDs7OztFQUlFO0FBS0YsTUFBTSxPQUFPLG1CQUFtQjtJQUU1QjtJQUNBLENBQUM7SUFFTSxTQUFTLENBQUMsS0FBYTtRQUMxQixJQUFJLEtBQUssSUFBSSxJQUFJLEVBQUU7WUFDZixPQUFPLEVBQUUsQ0FBQztTQUNiO1FBQ0QsSUFBSSxTQUFTLENBQUM7UUFFZCxJQUFJLElBQUksR0FBRyxDQUF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cpO1xuICAgICAgICAgICAgZm9yIChsZXQgaSA9IDA7IGkgPCBhcmdzLmxlbmd0aDsgaSsrKSB7XG4gICAgICAgICAgICAgICAgYXJnc1tpXSA9IGFyZ3NbaV0uY2hhckF0KDApLnRvVXBwZXJDYXNlKCkgKyBhcmdzW2ldLnNsaWNlKDEpLnRvTG93ZXJDYXNlKCk7XG4gICAgICAgICAgICAgICAgdmFsdWVBcmdzID0gYXJncy5qb2luKCcgJyk7XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gdmFsdWVBcmdzO1xuICAgIH1cbn1cbiJdfQ==
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export class SpacesNumberPipe {
|
|
4
|
-
transform(value) {
|
|
5
|
-
// we remove all spaces
|
|
6
|
-
return value.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ' ');
|
|
7
|
-
}
|
|
8
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SpacesNumberPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
9
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: SpacesNumberPipe, name: "mySpacesNumberPipe" }); }
|
|
10
|
-
}
|
|
11
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SpacesNumberPipe, decorators: [{
|
|
12
|
-
type: Pipe,
|
|
13
|
-
args: [{ name: 'mySpacesNumberPipe' }]
|
|
14
|
-
}] });
|
|
15
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Pipe } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class SpacesNumberPipe {
|
|
4
|
+
transform(value) {
|
|
5
|
+
// we remove all spaces
|
|
6
|
+
return value.toString().replace(/\B(?=(\d{3})+(?!\d))/g, ' ');
|
|
7
|
+
}
|
|
8
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SpacesNumberPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
9
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: SpacesNumberPipe, name: "mySpacesNumberPipe" }); }
|
|
10
|
+
}
|
|
11
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SpacesNumberPipe, decorators: [{
|
|
12
|
+
type: Pipe,
|
|
13
|
+
args: [{ name: 'mySpacesNumberPipe' }]
|
|
14
|
+
}] });
|
|
15
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tbWEtc2VwYXJhdGVkLW51bWJlci5waXBlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmV3LWZyb250LWNvbW1vbi1saWJyYXJ5L3NyYy9saWIvdXRpbC9waXBlcy9jb21tYS1zZXBhcmF0ZWQtbnVtYmVyLnBpcGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLElBQUksRUFBaUIsTUFBTSxlQUFlLENBQUM7O0FBR3BELE1BQU0sT0FBTyxnQkFBZ0I7SUFDbEIsU0FBUyxDQUFDLEtBQVU7UUFDdkIsdUJBQXVCO1FBQ3ZCLE9BQU8sS0FBSyxDQUFDLFFBQVEsRUFBRSxDQUFDLE9BQU8sQ0FBQyx1QkFBdUIsRUFBRSxHQUFHLENBQUMsQ0FBQztJQUNsRSxDQUFDOytHQUpRLGdCQUFnQjs2R0FBaEIsZ0JBQWdCOzs0RkFBaEIsZ0JBQWdCO2tCQUQ1QixJQUFJO21CQUFDLEVBQUMsSUFBSSxFQUFFLG9CQUFvQixFQUFDIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgUGlwZSwgUGlwZVRyYW5zZm9ybSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuXG5AUGlwZSh7bmFtZTogJ215U3BhY2VzTnVtYmVyUGlwZSd9KVxuZXhwb3J0IGNsYXNzIFNwYWNlc051bWJlclBpcGUgaW1wbGVtZW50cyBQaXBlVHJhbnNmb3JtIHtcbiAgICBwdWJsaWMgdHJhbnNmb3JtKHZhbHVlOiBhbnkpOiBhbnkge1xuICAgICAgICAvLyB3ZSByZW1vdmUgYWxsIHNwYWNlc1xuICAgICAgICByZXR1cm4gdmFsdWUudG9TdHJpbmcoKS5yZXBsYWNlKC9cXEIoPz0oXFxkezN9KSsoPyFcXGQpKS9nLCAnICcpO1xuICAgIH1cbn1cbiJdfQ==
|
|
@@ -1,38 +1,38 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import { en } from '../i18n/en';
|
|
3
|
-
import { fr } from '../i18n/fr';
|
|
4
|
-
import { de } from '../i18n/de';
|
|
5
|
-
import * as i0 from "@angular/core";
|
|
6
|
-
import * as i1 from "../services/storage/local-storage.service";
|
|
7
|
-
export class CommonTranslatePipe {
|
|
8
|
-
constructor(localStorageService) {
|
|
9
|
-
this.localStorageService = localStorageService;
|
|
10
|
-
this.availableTranslations = { en, fr, de };
|
|
11
|
-
}
|
|
12
|
-
transform(value, lang) {
|
|
13
|
-
let currentLang = lang;
|
|
14
|
-
if (!lang) {
|
|
15
|
-
currentLang = this.localStorageService.get('lang');
|
|
16
|
-
}
|
|
17
|
-
if (this.isValidLang(currentLang)) {
|
|
18
|
-
const currentTranslation = this.availableTranslations[currentLang];
|
|
19
|
-
return currentTranslation[value];
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
isValidLang(lang) {
|
|
23
|
-
if (lang) {
|
|
24
|
-
const languages = ['en', 'fr', 'de'];
|
|
25
|
-
if (languages.indexOf(lang) !== -1) {
|
|
26
|
-
return true;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
return false;
|
|
30
|
-
}
|
|
31
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CommonTranslatePipe, deps: [{ token: i1.LocalStorageService }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
32
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: CommonTranslatePipe, name: "commonTranslate" }); }
|
|
33
|
-
}
|
|
34
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CommonTranslatePipe, decorators: [{
|
|
35
|
-
type: Pipe,
|
|
36
|
-
args: [{ name: 'commonTranslate' }]
|
|
37
|
-
}], ctorParameters: function () { return [{ type: i1.LocalStorageService }]; } });
|
|
38
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Pipe } from '@angular/core';
|
|
2
|
+
import { en } from '../i18n/en';
|
|
3
|
+
import { fr } from '../i18n/fr';
|
|
4
|
+
import { de } from '../i18n/de';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
import * as i1 from "../services/storage/local-storage.service";
|
|
7
|
+
export class CommonTranslatePipe {
|
|
8
|
+
constructor(localStorageService) {
|
|
9
|
+
this.localStorageService = localStorageService;
|
|
10
|
+
this.availableTranslations = { en, fr, de };
|
|
11
|
+
}
|
|
12
|
+
transform(value, lang) {
|
|
13
|
+
let currentLang = lang;
|
|
14
|
+
if (!lang) {
|
|
15
|
+
currentLang = this.localStorageService.get('lang');
|
|
16
|
+
}
|
|
17
|
+
if (this.isValidLang(currentLang)) {
|
|
18
|
+
const currentTranslation = this.availableTranslations[currentLang];
|
|
19
|
+
return currentTranslation[value];
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
isValidLang(lang) {
|
|
23
|
+
if (lang) {
|
|
24
|
+
const languages = ['en', 'fr', 'de'];
|
|
25
|
+
if (languages.indexOf(lang) !== -1) {
|
|
26
|
+
return true;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
return false;
|
|
30
|
+
}
|
|
31
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CommonTranslatePipe, deps: [{ token: i1.LocalStorageService }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
32
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: CommonTranslatePipe, name: "commonTranslate" }); }
|
|
33
|
+
}
|
|
34
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: CommonTranslatePipe, decorators: [{
|
|
35
|
+
type: Pipe,
|
|
36
|
+
args: [{ name: 'commonTranslate' }]
|
|
37
|
+
}], ctorParameters: function () { return [{ type: i1.LocalStorageService }]; } });
|
|
38
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tbW9uLXRyYW5zbGF0ZS5waXBlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmV3LWZyb250LWNvbW1vbi1saWJyYXJ5L3NyYy9saWIvdXRpbC9waXBlcy9jb21tb24tdHJhbnNsYXRlLnBpcGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLElBQUksRUFBaUIsTUFBTSxlQUFlLENBQUM7QUFDcEQsT0FBTyxFQUFFLEVBQUUsRUFBRSxNQUFNLFlBQVksQ0FBQztBQUNoQyxPQUFPLEVBQUUsRUFBRSxFQUFFLE1BQU0sWUFBWSxDQUFDO0FBQ2hDLE9BQU8sRUFBRSxF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W9uc1tjdXJyZW50TGFuZ107XG4gICAgICAgICAgICByZXR1cm4gY3VycmVudFRyYW5zbGF0aW9uW3ZhbHVlXTtcbiAgICAgICAgfVxuICAgIH1cblxuICAgIHByaXZhdGUgaXNWYWxpZExhbmcobGFuZzogc3RyaW5nKSB7XG4gICAgICAgIGlmIChsYW5nKSB7XG4gICAgICAgICAgICBjb25zdCBsYW5ndWFnZXMgPSBbJ2VuJywgJ2ZyJywgJ2RlJ107XG4gICAgICAgICAgICBpZiAobGFuZ3VhZ2VzLmluZGV4T2YobGFuZykgIT09IC0xKSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGZhbHNlO1xuICAgIH1cbn1cbiJdfQ==
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
import * as i1 from "@angular/platform-browser";
|
|
4
|
-
export class SanitizeHtml {
|
|
5
|
-
constructor(_sanitizer) {
|
|
6
|
-
this._sanitizer = _sanitizer;
|
|
7
|
-
}
|
|
8
|
-
transform(html) {
|
|
9
|
-
return this._sanitizer.bypassSecurityTrustHtml(html);
|
|
10
|
-
}
|
|
11
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SanitizeHtml, deps: [{ token: i1.DomSanitizer }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
12
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: SanitizeHtml, name: "mySanitizeHtml" }); }
|
|
13
|
-
}
|
|
14
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SanitizeHtml, decorators: [{
|
|
15
|
-
type: Pipe,
|
|
16
|
-
args: [{
|
|
17
|
-
name: 'mySanitizeHtml'
|
|
18
|
-
}]
|
|
19
|
-
}], ctorParameters: function () { return [{ type: i1.DomSanitizer }]; } });
|
|
20
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Pipe } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
import * as i1 from "@angular/platform-browser";
|
|
4
|
+
export class SanitizeHtml {
|
|
5
|
+
constructor(_sanitizer) {
|
|
6
|
+
this._sanitizer = _sanitizer;
|
|
7
|
+
}
|
|
8
|
+
transform(html) {
|
|
9
|
+
return this._sanitizer.bypassSecurityTrustHtml(html);
|
|
10
|
+
}
|
|
11
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SanitizeHtml, deps: [{ token: i1.DomSanitizer }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
12
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: SanitizeHtml, name: "mySanitizeHtml" }); }
|
|
13
|
+
}
|
|
14
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: SanitizeHtml, decorators: [{
|
|
15
|
+
type: Pipe,
|
|
16
|
+
args: [{
|
|
17
|
+
name: 'mySanitizeHtml'
|
|
18
|
+
}]
|
|
19
|
+
}], ctorParameters: function () { return [{ type: i1.DomSanitizer }]; } });
|
|
20
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGlzcGxheS1odG1sLnBpcGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9uZXctZnJvbnQtY29tbW9uLWxpYnJhcnkvc3JjL2xpYi91dGlsL3BpcGVzL2Rpc3BsYXktaHRtbC5waXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxJQUFJLEVBQWlCLE1BQU0sZUFBZSxDQUFDOzs7QUFNcEQsTUFBTSxPQUFPLFlBQVk7SUFFckIsWUFBb0IsVUFBd0I7UUFBeEIsZUFBVSxHQUFWLFVBQVUsQ0FBYztJQUM1QyxDQUFDO0lBRU0sU0FBUyxDQUFDLElBQVk7UUFDekIsT0FBTyxJQUFJLENBQUMsVUFBVSxDQUFDLHVCQUF1QixDQUFDLElBQUksQ0FBQyxDQUFDO0lBQ3pELENBQUM7K0dBUFEsWUFBWTs2R0FBWixZQUFZOzs0RkFBWixZQUFZO2tCQUh4QixJQUFJO21CQUFDO29CQUNGLElBQUksRUFBRSxnQkFBZ0I7aUJBQ3pCIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgUGlwZSwgUGlwZVRyYW5zZm9ybSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuaW1wb3J0IHsgRG9tU2FuaXRpemVyLCBTYWZlSHRtbCB9IGZyb20gJ0Bhbmd1bGFyL3BsYXRmb3JtLWJyb3dzZXInO1xuXG5AUGlwZSh7XG4gICAgbmFtZTogJ215U2FuaXRpemVIdG1sJ1xufSlcbmV4cG9ydCBjbGFzcyBTYW5pdGl6ZUh0bWwgaW1wbGVtZW50cyBQaXBlVHJhbnNmb3JtIHtcblxuICAgIGNvbnN0cnVjdG9yKHByaXZhdGUgX3Nhbml0aXplcjogRG9tU2FuaXRpemVyKSB7XG4gICAgfVxuXG4gICAgcHVibGljIHRyYW5zZm9ybShodG1sOiBzdHJpbmcpOiBTYWZlSHRtbCB7XG4gICAgICAgIHJldHVybiB0aGlzLl9zYW5pdGl6ZXIuYnlwYXNzU2VjdXJpdHlUcnVzdEh0bWwoaHRtbCk7XG4gICAgfVxufVxuIl19
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export class DisplayNullPipe {
|
|
4
|
-
static returnCorrectFormat(object) {
|
|
5
|
-
return (object) ? object : '-';
|
|
6
|
-
}
|
|
7
|
-
transform(value, fieldName = '') {
|
|
8
|
-
// Case 1: test value param
|
|
9
|
-
if (!fieldName) {
|
|
10
|
-
return DisplayNullPipe.returnCorrectFormat(value);
|
|
11
|
-
}
|
|
12
|
-
else {
|
|
13
|
-
// Case 2: test sub attribut value
|
|
14
|
-
return (value) ? DisplayNullPipe.returnCorrectFormat(value[fieldName]) : '-';
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DisplayNullPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
18
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DisplayNullPipe, name: "myDisplayNullPipe" }); }
|
|
19
|
-
}
|
|
20
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DisplayNullPipe, decorators: [{
|
|
21
|
-
type: Pipe,
|
|
22
|
-
args: [{ name: 'myDisplayNullPipe' }]
|
|
23
|
-
}] });
|
|
24
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Pipe } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class DisplayNullPipe {
|
|
4
|
+
static returnCorrectFormat(object) {
|
|
5
|
+
return (object) ? object : '-';
|
|
6
|
+
}
|
|
7
|
+
transform(value, fieldName = '') {
|
|
8
|
+
// Case 1: test value param
|
|
9
|
+
if (!fieldName) {
|
|
10
|
+
return DisplayNullPipe.returnCorrectFormat(value);
|
|
11
|
+
}
|
|
12
|
+
else {
|
|
13
|
+
// Case 2: test sub attribut value
|
|
14
|
+
return (value) ? DisplayNullPipe.returnCorrectFormat(value[fieldName]) : '-';
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DisplayNullPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
18
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DisplayNullPipe, name: "myDisplayNullPipe" }); }
|
|
19
|
+
}
|
|
20
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DisplayNullPipe, decorators: [{
|
|
21
|
+
type: Pipe,
|
|
22
|
+
args: [{ name: 'myDisplayNullPipe' }]
|
|
23
|
+
}] });
|
|
24
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGlzcGxheS1udWxsLnBpcGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9uZXctZnJvbnQtY29tbW9uLWxpYnJhcnkvc3JjL2xpYi91dGlsL3BpcGVzL2Rpc3BsYXktbnVsbC5waXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxJQUFJLEVBQWlCLE1BQU0sZUFBZSxDQUFDOztBQUdwRCxNQUFNLE9BQU8sZUFBZTtJQUVoQixNQUFNLENBQUMsbUJBQW1CLENBQUMsTUFBVztRQUMxQyxPQUFPLENBQUMsTUFBTSxDQUFDLENBQUMsQ0FBQyxDQUFDLE1BQU0sQ0FBQyxDQUFDLENBQUMsR0FBRyxDQUFDO0lBQ25DLENBQUM7SUFFTSxTQUFTLENBQUMsS0FBVSxFQUFFLFlBQW9CLEVBQUU7UUFDL0MsMkJBQTJCO1FBQzNCLElBQUksQ0FBQyxTQUFTLEVBQUU7WUFDWixPQUFPLGVBQWUsQ0FBQyxtQkFBbUIsQ0FBQyxLQUFLLENBQUMsQ0FBQztTQUNyRDthQU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29ycmVjdEZvcm1hdCh2YWx1ZVtmaWVsZE5hbWVdKSA6ICctJztcbiAgICAgICAgfVxuICAgIH1cbn1cbiJdfQ==
|
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
import * as i1 from "@angular/common";
|
|
4
|
-
export class FormatCurrencyPipe {
|
|
5
|
-
constructor(currencyPipe) {
|
|
6
|
-
this.currencyPipe = currencyPipe;
|
|
7
|
-
}
|
|
8
|
-
transform(value, currencyCode, display, digitsInfo, language) {
|
|
9
|
-
let formattedValue = this.currencyPipe.transform(value, currencyCode, display, digitsInfo);
|
|
10
|
-
if (formattedValue) {
|
|
11
|
-
if (language == 'de') {
|
|
12
|
-
let [thousands, decimal] = formattedValue.split(',');
|
|
13
|
-
thousands = thousands.replace(/\s/g, '.');
|
|
14
|
-
formattedValue = thousands + ',' + decimal;
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
formattedValue = formattedValue.replace(',', '.');
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
return formattedValue ? formattedValue : '';
|
|
21
|
-
}
|
|
22
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatCurrencyPipe, deps: [{ token: i1.CurrencyPipe }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
23
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: FormatCurrencyPipe, name: "formatCurrency" }); }
|
|
24
|
-
}
|
|
25
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatCurrencyPipe, decorators: [{
|
|
26
|
-
type: Pipe,
|
|
27
|
-
args: [{
|
|
28
|
-
name: 'formatCurrency'
|
|
29
|
-
}]
|
|
30
|
-
}], ctorParameters: function () { return [{ type: i1.CurrencyPipe }]; } });
|
|
31
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Pipe } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
import * as i1 from "@angular/common";
|
|
4
|
+
export class FormatCurrencyPipe {
|
|
5
|
+
constructor(currencyPipe) {
|
|
6
|
+
this.currencyPipe = currencyPipe;
|
|
7
|
+
}
|
|
8
|
+
transform(value, currencyCode, display, digitsInfo, language) {
|
|
9
|
+
let formattedValue = this.currencyPipe.transform(value, currencyCode, display, digitsInfo);
|
|
10
|
+
if (formattedValue) {
|
|
11
|
+
if (language == 'de') {
|
|
12
|
+
let [thousands, decimal] = formattedValue.split(',');
|
|
13
|
+
thousands = thousands.replace(/\s/g, '.');
|
|
14
|
+
formattedValue = thousands + ',' + decimal;
|
|
15
|
+
}
|
|
16
|
+
else {
|
|
17
|
+
formattedValue = formattedValue.replace(',', '.');
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
return formattedValue ? formattedValue : '';
|
|
21
|
+
}
|
|
22
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatCurrencyPipe, deps: [{ token: i1.CurrencyPipe }], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
23
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: FormatCurrencyPipe, name: "formatCurrency" }); }
|
|
24
|
+
}
|
|
25
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatCurrencyPipe, decorators: [{
|
|
26
|
+
type: Pipe,
|
|
27
|
+
args: [{
|
|
28
|
+
name: 'formatCurrency'
|
|
29
|
+
}]
|
|
30
|
+
}], ctorParameters: function () { return [{ type: i1.CurrencyPipe }]; } });
|
|
31
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZm9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iAgICAgICAgdGhvdXNhbmRzID0gdGhvdXNhbmRzLnJlcGxhY2UoL1xccy9nLCAnLicpO1xuICAgICAgICBmb3JtYXR0ZWRWYWx1ZSA9IHRob3VzYW5kcyArICcsJyArIGRlY2ltYWw7XG4gICAgICB9IGVsc2Uge1xuICAgICAgICBmb3JtYXR0ZWRWYWx1ZSA9IGZvcm1hdHRlZFZhbHVlLnJlcGxhY2UoJywnLCAnLicpO1xuICAgICAgfVxuICAgIH1cblxuICAgIHJldHVybiBmb3JtYXR0ZWRWYWx1ZSA/IGZvcm1hdHRlZFZhbHVlIDogJyc7XG4gIH1cbn1cbiJdfQ==
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { Pipe } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export class FormatDurationPipe {
|
|
4
|
-
transform(value) {
|
|
5
|
-
if (value > 0 && value < 60) {
|
|
6
|
-
return value + 'min';
|
|
7
|
-
}
|
|
8
|
-
else {
|
|
9
|
-
const h = Math.floor(value / 60);
|
|
10
|
-
const min = value % 60;
|
|
11
|
-
return min === 0 ? h + 'h' : h + 'h ' + min + 'min';
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatDurationPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
15
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: FormatDurationPipe, name: "formatDuration" }); }
|
|
16
|
-
}
|
|
17
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatDurationPipe, decorators: [{
|
|
18
|
-
type: Pipe,
|
|
19
|
-
args: [{
|
|
20
|
-
name: 'formatDuration'
|
|
21
|
-
}]
|
|
22
|
-
}] });
|
|
23
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
1
|
+
import { Pipe } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class FormatDurationPipe {
|
|
4
|
+
transform(value) {
|
|
5
|
+
if (value > 0 && value < 60) {
|
|
6
|
+
return value + 'min';
|
|
7
|
+
}
|
|
8
|
+
else {
|
|
9
|
+
const h = Math.floor(value / 60);
|
|
10
|
+
const min = value % 60;
|
|
11
|
+
return min === 0 ? h + 'h' : h + 'h ' + min + 'min';
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatDurationPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
15
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: FormatDurationPipe, name: "formatDuration" }); }
|
|
16
|
+
}
|
|
17
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: FormatDurationPipe, decorators: [{
|
|
18
|
+
type: Pipe,
|
|
19
|
+
args: [{
|
|
20
|
+
name: 'formatDuration'
|
|
21
|
+
}]
|
|
22
|
+
}] });
|
|
23
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZm9ybWF0LWR1cmF0aW9uLnBpcGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9uZXctZnJvbnQtY29tbW9uLWxpYnJhcnkvc3JjL2xpYi91dGlsL3BpcGVzL2Zvcm1hdC1kdXJhdGlvbi5waXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxJQUFJLEVBQWlCLE1BQU0sZUFBZSxDQUFDOztBQUtwRCxNQUFNLE9BQU8sa0JBQWtCO0lBQzdCLFNBQVMs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