@colijnit/catalog 256.1.3 → 256.1.5

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.
@@ -53,8 +53,8 @@ class Version {
53
53
  constructor() {
54
54
  this.name = "@colijnit/catalog";
55
55
  this.description = "iOne Catalog module based on Angular 12";
56
- this.symVer = "256.1.3";
57
- this.publishDate = "29-10-2024 22:39:42";
56
+ this.symVer = "256.1.5";
57
+ this.publishDate = "1-11-2024 14:45:45";
58
58
  }
59
59
  }
60
60
 
@@ -2895,7 +2895,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2895
2895
 
2896
2896
  <div class="catalog-filter-wrapper">
2897
2897
  <div class="filter-items-wrapper co-small-scrollbar">
2898
- <div class="filter-item-wrapper">
2898
+ <div class="filter-item-wrapper articlenr">
2899
2899
  <co-catalog-filter-item [placeholder]="'ARTICLENR'"
2900
2900
  [mode]="modes.TextField"
2901
2901
  [(model)]="catalogSearchService.searchRequest.articleNumber"
@@ -2904,7 +2904,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2904
2904
  >
2905
2905
  </co-catalog-filter-item>
2906
2906
  </div>
2907
- <div class="filter-item-wrapper">
2907
+ <div class="filter-item-wrapper barcode">
2908
2908
  <co-catalog-filter-item [placeholder]="'BARCODE'"
2909
2909
  [mode]="modes.TextField"
2910
2910
  [(model)]="catalogSearchService.searchRequest.barcode"
@@ -2913,7 +2913,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2913
2913
  >
2914
2914
  </co-catalog-filter-item>
2915
2915
  </div>
2916
- <div class="filter-item-wrapper">
2916
+ <div class="filter-item-wrapper price">
2917
2917
  <co-catalog-filter-item [placeholder]="'PRICE'"
2918
2918
  [mode]="modes.Slider"
2919
2919
  [sliderDefaultMin]=0
@@ -2924,7 +2924,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2924
2924
  >
2925
2925
  </co-catalog-filter-item>
2926
2926
  </div>
2927
- <div class="filter-item-wrapper">
2927
+ <div class="filter-item-wrapper length">
2928
2928
  <co-catalog-filter-item [placeholder]="'LENGTH'"
2929
2929
  [mode]="modes.Slider"
2930
2930
  [sliderDefaultMin]=0
@@ -2935,7 +2935,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2935
2935
  >
2936
2936
  </co-catalog-filter-item>
2937
2937
  </div>
2938
- <div class="filter-item-wrapper">
2938
+ <div class="filter-item-wrapper width">
2939
2939
  <co-catalog-filter-item [placeholder]="'WIDTH'"
2940
2940
  [mode]="modes.Slider"
2941
2941
  [sliderDefaultMin]=0
@@ -2946,7 +2946,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2946
2946
  >
2947
2947
  </co-catalog-filter-item>
2948
2948
  </div>
2949
- <div class="filter-item-wrapper">
2949
+ <div class="filter-item-wrapper height">
2950
2950
  <co-catalog-filter-item [placeholder]="'HEIGHT'"
2951
2951
  [mode]="modes.Slider"
2952
2952
  [sliderDefaultMin]=0
@@ -2957,7 +2957,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2957
2957
  >
2958
2958
  </co-catalog-filter-item>
2959
2959
  </div>
2960
- <div class="filter-item-wrapper">
2960
+ <div class="filter-item-wrapper depth">
2961
2961
  <co-catalog-filter-item [placeholder]="'DEPTH'"
2962
2962
  [mode]="modes.Slider"
2963
2963
  [sliderDefaultMin]=0
@@ -2968,7 +2968,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2968
2968
  >
2969
2969
  </co-catalog-filter-item>
2970
2970
  </div>
2971
- <div class="filter-item-wrapper">
2971
+ <div class="filter-item-wrapper article-type">
2972
2972
  <co-catalog-filter-item
2973
2973
  [placeholder]="'ARTICLE_TYPE'"
2974
2974
  [customContent]="true"
@@ -2997,7 +2997,7 @@ CatalogFilterContentGeneralComponent.decorators = [
2997
2997
  </co-catalog-filter-item>
2998
2998
  </div>
2999
2999
 
3000
- <div class="filter-item-wrapper">
3000
+ <div class="filter-item-wrapper color">
3001
3001
  <co-catalog-filter-item [placeholder]="'COLOR'"
3002
3002
  [(model)]="catalogSearchService.searchRequest.colourCodes"
3003
3003
  [mode]="modes.SelectListWithStringCollectionOutput"
@@ -3007,7 +3007,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3007
3007
  >
3008
3008
  </co-catalog-filter-item>
3009
3009
  </div>
3010
- <div class="filter-item-wrapper">
3010
+ <div class="filter-item-wrapper delivery-date">
3011
3011
  <co-catalog-filter-item [placeholder]="'LATEST_DELIVERY_DATE'"
3012
3012
  [(model)]="catalogSearchService.searchRequest.latestDeliveryDate"
3013
3013
  [mode]="modes.DateField"
@@ -3017,7 +3017,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3017
3017
  </co-catalog-filter-item>
3018
3018
  </div>
3019
3019
 
3020
- <div class="filter-item-wrapper">
3020
+ <div class="filter-item-wrapper retail-formula">
3021
3021
  <co-catalog-filter-item [placeholder]="'RETAIL_FORMULA'"
3022
3022
  [collection]="storeGroupCollection"
3023
3023
  [mode]="modes.Filterlist"
@@ -3026,7 +3026,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3026
3026
  >
3027
3027
  </co-catalog-filter-item>
3028
3028
  </div>
3029
- <div class="filter-item-wrapper">
3029
+ <div class="filter-item-wrapper in-out-collection">
3030
3030
  <co-catalog-filter-item [placeholder]="'IN_OUT_COLLECTION'"
3031
3031
  [collection]="inOutCollectionCollection"
3032
3032
  [mode]="modes.Filterlist"
@@ -3035,7 +3035,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3035
3035
  >
3036
3036
  </co-catalog-filter-item>
3037
3037
  </div>
3038
- <div class="filter-item-wrapper">
3038
+ <div class="filter-item-wrapper article-kind">
3039
3039
  <co-catalog-filter-item [placeholder]="'ARTICLE_KIND'"
3040
3040
  [collection]="articleTypeCollection"
3041
3041
  [mode]="modes.SelectListWithStringCollectionOutput"
@@ -3044,7 +3044,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3044
3044
  >
3045
3045
  </co-catalog-filter-item>
3046
3046
  </div>
3047
- <div class="filter-item-wrapper">
3047
+ <div class="filter-item-wrapper publish-via">
3048
3048
  <co-catalog-filter-item [placeholder]="'PUBLISH_VIA'"
3049
3049
  [collection]="artPublicationCollection"
3050
3050
  [(model)]="catalogSearchService.searchRequest.publicationCode"
@@ -3054,7 +3054,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3054
3054
  >
3055
3055
  </co-catalog-filter-item>
3056
3056
  </div>
3057
- <div class="filter-item-wrapper">
3057
+ <div class="filter-item-wrapper sell-via">
3058
3058
  <co-catalog-filter-item [placeholder]="'SELL_VIA'"
3059
3059
  [collection]="artPublicationSalesCollection"
3060
3060
  [(model)]="catalogSearchService.searchRequest.publicationWebshopSales"
@@ -3064,7 +3064,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3064
3064
  >
3065
3065
  </co-catalog-filter-item>
3066
3066
  </div>
3067
- <div class="filter-item-wrapper">
3067
+ <div class="filter-item-wrapper pricelist">
3068
3068
  <co-catalog-filter-item [placeholder]="'PRICELIST_SALES'"
3069
3069
  [(model)]="catalogSearchService.searchRequest.pricelistRetail"
3070
3070
  [mode]="modes.SingleSelectList"
@@ -3073,7 +3073,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3073
3073
  >
3074
3074
  </co-catalog-filter-item>
3075
3075
  </div>
3076
- <div class="filter-item-wrapper">
3076
+ <div class="filter-item-wrapper category">
3077
3077
  <co-catalog-filter-item [placeholder]="'CATEGORY'"
3078
3078
  [(model)]="catalogSearchService.searchRequest.category"
3079
3079
  [mode]="modes.Filterlist"
@@ -3082,7 +3082,7 @@ CatalogFilterContentGeneralComponent.decorators = [
3082
3082
  >
3083
3083
  </co-catalog-filter-item>
3084
3084
  </div>
3085
- <div class="filter-item-wrapper" *ngFor="let filter of filterService.filters">
3085
+ <div class="filter-item-wrapper" *ngFor="let filter of filterService.filters" [ngClass]="filter.filterName">
3086
3086
  <co-catalog-filter-item
3087
3087
  [placeholder]="filter.filterName"
3088
3088
  [collection]="filter.filterItems"
@@ -4311,6 +4311,7 @@ class CatalogSearchComponent {
4311
4311
  this.showNavigation = false;
4312
4312
  this.showLandingPage = false;
4313
4313
  this.showFilter = false;
4314
+ this.tempFilter = true;
4314
4315
  this.showViewModes = true;
4315
4316
  this.settingsChange = new EventEmitter();
4316
4317
  this.onLookAtArticleButtonClick = new EventEmitter();
@@ -4400,7 +4401,7 @@ CatalogSearchComponent.decorators = [
4400
4401
  selector: 'co-catalog-search',
4401
4402
  template: `
4402
4403
  <div class="catalog-search-wrapper">
4403
- <ng-container *ngIf="showFilter">
4404
+ <ng-container *ngIf="tempFilter">
4404
4405
  <div class="filter-content" @showHideFilter>
4405
4406
  <div class="search-filter-panel-header-wrapper">
4406
4407
  <div class="search-filter-panel-header">
@@ -4413,7 +4414,7 @@ CatalogSearchComponent.decorators = [
4413
4414
  </div>
4414
4415
  <co-icon class="clickable"
4415
4416
  [iconData]="iconCacheService.getIcon(icons.Cancel)"
4416
- (click)="showFilter = false">
4417
+ (click)="tempFilter = false">
4417
4418
  </co-icon>
4418
4419
  </div>
4419
4420
 
@@ -4433,7 +4434,7 @@ CatalogSearchComponent.decorators = [
4433
4434
  <div class="catalog-sub-title" [textContent]="subTitle"></div>
4434
4435
  </div>
4435
4436
  <co-catalog-search-header [placeholder]="searchPlaceholder"
4436
- (filterIconClick)="showFilter = !showFilter"></co-catalog-search-header>
4437
+ (filterIconClick)="tempFilter = !tempFilter"></co-catalog-search-header>
4437
4438
  </div>
4438
4439
  <div class="view-modes-wrapper">
4439
4440
  <co-button
@@ -4461,12 +4462,14 @@ CatalogSearchComponent.decorators = [
4461
4462
  <co-catalog-search-result-tile
4462
4463
  [createFrozenArticle]="createFrozenArticle"
4463
4464
  [isHomeDecoHub]="isHomeDecoHub"
4465
+ [externalSource]="externalSource"
4464
4466
  ></co-catalog-search-result-tile>
4465
4467
  </ng-container>
4466
4468
  <ng-container *ngIf="mode === 'list'">
4467
4469
  <co-catalog-search-result-list
4468
4470
  [createFrozenArticle]="createFrozenArticle"
4469
4471
  [isHomeDecoHub]="isHomeDecoHub"
4472
+ [externalSource]="externalSource"
4470
4473
  ></co-catalog-search-result-list>
4471
4474
  </ng-container>
4472
4475
  <ng-container *ngIf="mode === 'grid'">
@@ -4527,8 +4530,10 @@ CatalogSearchComponent.propDecorators = {
4527
4530
  showNavigation: [{ type: Input }],
4528
4531
  showLandingPage: [{ type: Input }],
4529
4532
  showFilter: [{ type: Input }],
4533
+ tempFilter: [{ type: Input }],
4530
4534
  showViewModes: [{ type: Input }],
4531
4535
  isHomeDecoHub: [{ type: Input }],
4536
+ externalSource: [{ type: Input }],
4532
4537
  settingsChange: [{ type: Output }],
4533
4538
  onLookAtArticleButtonClick: [{ type: Output }],
4534
4539
  onArButtonClick: [{ type: Output }],
@@ -4639,6 +4644,7 @@ CatalogSearchBaseComponent.ctorParameters = () => [
4639
4644
  ];
4640
4645
  CatalogSearchBaseComponent.propDecorators = {
4641
4646
  createFrozenArticle: [{ type: Input }],
4647
+ externalSource: [{ type: Input }],
4642
4648
  onLookAtArticleButtonClick: [{ type: Output }],
4643
4649
  onArButtonClick: [{ type: Output }],
4644
4650
  onAddArticleButtonClick: [{ type: Output }],
@@ -4715,7 +4721,7 @@ class ArticleBaseComponent {
4715
4721
  return __awaiter(this, void 0, void 0, function* () {
4716
4722
  event.stopPropagation();
4717
4723
  if (this.createFrozenArticle) {
4718
- const json = yield this._getJSONFromArticleObject(this.article);
4724
+ const json = yield this._getJSONFromArticleObject(this.article, !!this.externalSource);
4719
4725
  this._appEventService.addArticleButtonClick.next(json);
4720
4726
  this.onAddArticleButtonClick.emit(json);
4721
4727
  }
@@ -4742,12 +4748,12 @@ class ArticleBaseComponent {
4742
4748
  desc = desc.replace(/\r?\n|\r/, '');
4743
4749
  return desc;
4744
4750
  }
4745
- _getJSONFromArticleObject(article) {
4751
+ _getJSONFromArticleObject(article, externalSource = false) {
4746
4752
  return __awaiter(this, void 0, void 0, function* () {
4747
4753
  if (!article) {
4748
4754
  return "";
4749
4755
  }
4750
- return yield this._iOne.getJsonArticleFlatTree(article.goodId, article.goodType, 1);
4756
+ return yield this._iOne.getJsonArticleFlatTree(article.goodId, article.goodType, 1, externalSource);
4751
4757
  });
4752
4758
  }
4753
4759
  _detectChanges() {
@@ -4820,6 +4826,7 @@ ArticleBaseComponent.propDecorators = {
4820
4826
  isSmallModus: [{ type: Input }, { type: HostBinding, args: ['class.small-modus',] }],
4821
4827
  hasMagnifierButton: [{ type: Input }],
4822
4828
  hasInfoButton: [{ type: Input }],
4829
+ externalSource: [{ type: Input }],
4823
4830
  onLookAtArticleButtonClick: [{ type: Output }],
4824
4831
  onArButtonClick: [{ type: Output }],
4825
4832
  onAddArticleButtonClick: [{ type: Output }],
@@ -4947,6 +4954,7 @@ CatalogSearchResultTileComponent.decorators = [
4947
4954
  [showing]="intersection.isIntersecting"
4948
4955
  [article]="article"
4949
4956
  [isHomeDecoHub]="isHomeDecoHub"
4957
+ [externalSource]="externalSource"
4950
4958
  (onArticleClick)="onArticleClick.emit($event)"
4951
4959
  (onAddArticleButtonClick)="onAddArticleButtonClick.emit($event)"
4952
4960
  (onArButtonClick)="onArButtonClick.emit($event)"
@@ -5245,6 +5253,7 @@ CatalogSearchResultListComponent.decorators = [
5245
5253
  [createFrozenArticle]="createFrozenArticle"
5246
5254
  [showing]="intersection.isIntersecting"
5247
5255
  [article]="article"
5256
+ [externalSource]="externalSource"
5248
5257
  [isHomeDecoHub]="isHomeDecoHub"
5249
5258
  (onArticleClick)="onArticleClick.emit($event)"
5250
5259
  (onAddArticleButtonClick)="onAddArticleButtonClick.emit($event)"
@@ -5352,10 +5361,12 @@ class CatalogExternalSourceComponent {
5352
5361
  this._catalogConnectorService = _catalogConnectorService;
5353
5362
  this._appEventService = _appEventService;
5354
5363
  this.showFilter = true;
5364
+ this.tempFilter = true;
5355
5365
  this.showNavigation = true;
5356
5366
  this.isHomeDecoHub = false;
5357
5367
  this.articleClick = new EventEmitter();
5358
5368
  this.addArticleClick = new EventEmitter();
5369
+ this.lookAtArticleClick = new EventEmitter();
5359
5370
  this.iFrameFeedbackReceived = new EventEmitter();
5360
5371
  this.showClass = true;
5361
5372
  this.showCatalog = false;
@@ -5373,7 +5384,7 @@ class CatalogExternalSourceComponent {
5373
5384
  }
5374
5385
  set externalCatalogStartupInfo(value) {
5375
5386
  this._externalCatalogStartupInfo = value;
5376
- this._externalSource = value.externalSource;
5387
+ this.externalSource = value.externalSource;
5377
5388
  this.loaded = false;
5378
5389
  this._prepareExternalSource();
5379
5390
  }
@@ -5387,7 +5398,7 @@ class CatalogExternalSourceComponent {
5387
5398
  quantity: 1,
5388
5399
  article: article,
5389
5400
  catalogDefinition: this.catalogDefinition,
5390
- externalSource: this._externalSource
5401
+ externalSource: this.externalSource
5391
5402
  });
5392
5403
  }
5393
5404
  }));
@@ -5398,12 +5409,12 @@ class CatalogExternalSourceComponent {
5398
5409
  article: article,
5399
5410
  settings: { name: this.name, settings: this.externalSettings },
5400
5411
  catalogDefinition: this.catalogDefinition,
5401
- externalSource: this._externalSource
5412
+ externalSource: this.externalSource
5402
5413
  });
5403
5414
  }
5404
5415
  }
5405
5416
  receiveMessage(event) {
5406
- if (this._externalSource.type !== '3DIMERCE')
5417
+ if (this.externalSource.type !== '3DIMERCE')
5407
5418
  if (typeof event.data === 'string') {
5408
5419
  this.iFrameFeedbackReceived.emit(event.data);
5409
5420
  }
@@ -5418,10 +5429,10 @@ class CatalogExternalSourceComponent {
5418
5429
  }
5419
5430
  fetchAndCombineThreeDimerseData(hash) {
5420
5431
  return __awaiter(this, void 0, void 0, function* () {
5421
- const customerName = this._externalSource.username;
5432
+ const customerName = this.externalSource.username;
5422
5433
  // two main api urls
5423
- const configurationUrl = this._externalSource.domain + '/configurationData/' + hash;
5424
- const priceDataUrl = this._externalSource.domain + '/rules/api/' + customerName.toLowerCase() + '/' + hash;
5434
+ const configurationUrl = this.externalSource.domain + '/configurationData/' + hash;
5435
+ const priceDataUrl = this.externalSource.domain + '/rules/api/' + customerName.toLowerCase() + '/' + hash;
5425
5436
  //test setup for local testing
5426
5437
  //const configurationUrl: string = "https://bertplantagie.platformapi-accept.3dimerce.com/configurationData/8eb5b35697c96716d3e253294344d98e4dcdcb68969c288189d45829164e3177";
5427
5438
  //console.log(configurationUrl);
@@ -5506,36 +5517,36 @@ class CatalogExternalSourceComponent {
5506
5517
  }
5507
5518
  _prepareExternalSource() {
5508
5519
  return __awaiter(this, void 0, void 0, function* () {
5509
- if (!this._externalSource) {
5520
+ if (!this.externalSource) {
5510
5521
  return;
5511
5522
  }
5512
5523
  this.externalUrl = undefined;
5513
5524
  this.externalSettings = {};
5514
- if (this._externalSource.type === 'CATF') {
5525
+ if (this.externalSource.type === 'CATF') {
5515
5526
  // get bundle settings from external source
5516
- const bundleSettings = yield this._catalogConnectorService.getCatalogBundleSettings(this._externalSource.url, parseInt(this._externalSource.schema));
5527
+ const bundleSettings = yield this._catalogConnectorService.getCatalogBundleSettings(this.externalSource.url, parseInt(this.externalSource.schema));
5517
5528
  this.externalSettings = JSON.parse(bundleSettings);
5518
5529
  if (this.options) {
5519
5530
  this.externalSettings.options = this.options;
5520
5531
  }
5521
- if (this._externalSource.username && this._externalSource.password) {
5522
- this.externalSettings.username = this._externalSource.username;
5523
- this.externalSettings.password = this._externalSource.password;
5532
+ if (this.externalSource.username && this.externalSource.password) {
5533
+ this.externalSettings.username = this.externalSource.username;
5534
+ this.externalSettings.password = this.externalSource.password;
5524
5535
  }
5525
5536
  // finally show the catalog
5526
5537
  this.showCatalog = true;
5527
5538
  }
5528
5539
  else {
5529
- if (this._externalSource.type !== ExternalCatalogTypes.Webshop && this._externalSource.type !== ExternalCatalogTypes.ThreeDimerse) {
5540
+ if (this.externalSource.type !== ExternalCatalogTypes.Webshop && this.externalSource.type !== ExternalCatalogTypes.ThreeDimerse) {
5530
5541
  this.externalUrl = this._externalCatalogStartupInfo.apiUrl;
5531
- if (this._externalSource.type === ExternalCatalogTypes.Vadain) {
5542
+ if (this.externalSource.type === ExternalCatalogTypes.Vadain) {
5532
5543
  this.username = this._externalCatalogStartupInfo.username;
5533
5544
  this.password = this._externalCatalogStartupInfo.password;
5534
5545
  this.externalOrderNr = this._externalCatalogStartupInfo.orderId;
5535
5546
  }
5536
5547
  }
5537
5548
  else {
5538
- this.externalUrl = this._externalSource.url;
5549
+ this.externalUrl = this.externalSource.url;
5539
5550
  }
5540
5551
  this.safeUrl = this._sanitizer.bypassSecurityTrustResourceUrl(this.externalUrl);
5541
5552
  this.showCatalog = false;
@@ -5555,10 +5566,12 @@ CatalogExternalSourceComponent.decorators = [
5555
5566
  <ng-container *ngIf="showCatalog">
5556
5567
  <co-catalog-search
5557
5568
  [(settings)]="externalSettings"
5569
+ [externalSource]="externalSource"
5558
5570
  [title]="title"
5559
5571
  [subTitle]="subTitle"
5560
5572
  [searchPlaceholder]="searchPlaceholder"
5561
5573
  [showFilter]="showFilter"
5574
+ [tempFilter]="tempFilter"
5562
5575
  [showNavigation]="showNavigation"
5563
5576
  [isHomeDecoHub]="isHomeDecoHub"
5564
5577
  (onArticleClick)="handleArticleClick($event)"
@@ -5587,12 +5600,14 @@ CatalogExternalSourceComponent.propDecorators = {
5587
5600
  subTitle: [{ type: Input }],
5588
5601
  searchPlaceholder: [{ type: Input }],
5589
5602
  showFilter: [{ type: Input }],
5603
+ tempFilter: [{ type: Input }],
5590
5604
  showNavigation: [{ type: Input }],
5591
5605
  options: [{ type: Input }],
5592
5606
  isHomeDecoHub: [{ type: Input }],
5593
5607
  name: [{ type: Input }],
5594
5608
  articleClick: [{ type: Output }],
5595
5609
  addArticleClick: [{ type: Output }],
5610
+ lookAtArticleClick: [{ type: Output }],
5596
5611
  iFrameFeedbackReceived: [{ type: Output }],
5597
5612
  showClass: [{ type: HostBinding, args: ['class.co-catalog-external-source',] }]
5598
5613
  };