@one-commerce/sdk-core 1.19.4-alpha.0 → 1.19.4
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/lib/bundles/bundle.esm.js +157 -135
- package/lib/bundles/bundle.esm.js.map +1 -1
- package/lib/bundles/bundle.esm.min.js +1 -1
- package/lib/bundles/bundle.esm.min.js.map +1 -1
- package/lib/bundles/bundle.umd.js +157 -135
- package/lib/bundles/bundle.umd.js.map +1 -1
- package/lib/bundles/bundle.umd.min.js +1 -1
- package/lib/bundles/bundle.umd.min.js.map +1 -1
- package/lib/cjs/backoffice/context.js +2 -2
- package/lib/cjs/backoffice/context.js.map +1 -1
- package/lib/cjs/backoffice/services.js +42 -68
- package/lib/cjs/backoffice/services.js.map +1 -1
- package/lib/cjs/events.js.map +1 -1
- package/lib/cjs/index.js +9 -5
- package/lib/cjs/index.js.map +1 -1
- package/lib/cjs/shop/services.js +115 -72
- package/lib/cjs/shop/services.js.map +1 -1
- package/lib/cjs/utils.js.map +1 -1
- package/lib/esm/backoffice/context.js.map +1 -1
- package/lib/esm/backoffice/services.js +0 -8
- package/lib/esm/backoffice/services.js.map +1 -1
- package/lib/esm/events.js.map +1 -1
- package/lib/esm/index.js +10 -5
- package/lib/esm/index.js.map +1 -1
- package/lib/esm/shop/services.js +20 -0
- package/lib/esm/shop/services.js.map +1 -1
- package/lib/esm/utils.js.map +1 -1
- package/lib/types/backoffice/services.d.ts +0 -3
- package/lib/types/backoffice/services.d.ts.map +1 -1
- package/lib/types/index.d.ts +4 -4
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/shop/services.d.ts +6 -0
- package/lib/types/shop/services.d.ts.map +1 -1
- package/package.json +3 -3
|
@@ -63,17 +63,18 @@
|
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
function _getPrototypeOf(o) {
|
|
66
|
-
_getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf
|
|
66
|
+
_getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {
|
|
67
67
|
return o.__proto__ || Object.getPrototypeOf(o);
|
|
68
68
|
};
|
|
69
69
|
return _getPrototypeOf(o);
|
|
70
70
|
}
|
|
71
71
|
|
|
72
72
|
function _setPrototypeOf(o, p) {
|
|
73
|
-
_setPrototypeOf = Object.setPrototypeOf
|
|
73
|
+
_setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
|
|
74
74
|
o.__proto__ = p;
|
|
75
75
|
return o;
|
|
76
76
|
};
|
|
77
|
+
|
|
77
78
|
return _setPrototypeOf(o, p);
|
|
78
79
|
}
|
|
79
80
|
|
|
@@ -461,15 +462,15 @@
|
|
|
461
462
|
|
|
462
463
|
return _createClass(BackofficeTenant);
|
|
463
464
|
}(BaseCallClass);
|
|
464
|
-
var
|
|
465
|
-
_inherits(
|
|
465
|
+
var BackofficeLayout = /*#__PURE__*/function (_BaseCallClass4) {
|
|
466
|
+
_inherits(BackofficeLayout, _BaseCallClass4);
|
|
466
467
|
|
|
467
|
-
var _super4 = _createSuper(
|
|
468
|
+
var _super4 = _createSuper(BackofficeLayout);
|
|
468
469
|
|
|
469
|
-
function
|
|
470
|
+
function BackofficeLayout() {
|
|
470
471
|
var _this4;
|
|
471
472
|
|
|
472
|
-
_classCallCheck(this,
|
|
473
|
+
_classCallCheck(this, BackofficeLayout);
|
|
473
474
|
|
|
474
475
|
for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
|
|
475
476
|
args[_key4] = arguments[_key4];
|
|
@@ -477,22 +478,24 @@
|
|
|
477
478
|
|
|
478
479
|
_this4 = _super4.call.apply(_super4, [this].concat(args));
|
|
479
480
|
|
|
480
|
-
_defineProperty(_assertThisInitialized(_this4), "serviceName", '
|
|
481
|
+
_defineProperty(_assertThisInitialized(_this4), "serviceName", 'layout');
|
|
482
|
+
|
|
483
|
+
_defineProperty(_assertThisInitialized(_this4), "isAsideOpened", void 0);
|
|
481
484
|
|
|
482
485
|
return _this4;
|
|
483
486
|
}
|
|
484
487
|
|
|
485
|
-
return _createClass(
|
|
488
|
+
return _createClass(BackofficeLayout);
|
|
486
489
|
}(BaseCallClass);
|
|
487
|
-
var
|
|
488
|
-
_inherits(
|
|
490
|
+
var BackofficeAuthorization = /*#__PURE__*/function (_BaseCallClass5) {
|
|
491
|
+
_inherits(BackofficeAuthorization, _BaseCallClass5);
|
|
489
492
|
|
|
490
|
-
var _super5 = _createSuper(
|
|
493
|
+
var _super5 = _createSuper(BackofficeAuthorization);
|
|
491
494
|
|
|
492
|
-
function
|
|
495
|
+
function BackofficeAuthorization() {
|
|
493
496
|
var _this5;
|
|
494
497
|
|
|
495
|
-
_classCallCheck(this,
|
|
498
|
+
_classCallCheck(this, BackofficeAuthorization);
|
|
496
499
|
|
|
497
500
|
for (var _len5 = arguments.length, args = new Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {
|
|
498
501
|
args[_key5] = arguments[_key5];
|
|
@@ -500,36 +503,11 @@
|
|
|
500
503
|
|
|
501
504
|
_this5 = _super5.call.apply(_super5, [this].concat(args));
|
|
502
505
|
|
|
503
|
-
_defineProperty(_assertThisInitialized(_this5), "serviceName", '
|
|
504
|
-
|
|
505
|
-
_defineProperty(_assertThisInitialized(_this5), "isAsideOpened", void 0);
|
|
506
|
+
_defineProperty(_assertThisInitialized(_this5), "serviceName", 'authorization');
|
|
506
507
|
|
|
507
508
|
return _this5;
|
|
508
509
|
}
|
|
509
510
|
|
|
510
|
-
return _createClass(BackofficeLayout);
|
|
511
|
-
}(BaseCallClass);
|
|
512
|
-
var BackofficeAuthorization = /*#__PURE__*/function (_BaseCallClass6) {
|
|
513
|
-
_inherits(BackofficeAuthorization, _BaseCallClass6);
|
|
514
|
-
|
|
515
|
-
var _super6 = _createSuper(BackofficeAuthorization);
|
|
516
|
-
|
|
517
|
-
function BackofficeAuthorization() {
|
|
518
|
-
var _this6;
|
|
519
|
-
|
|
520
|
-
_classCallCheck(this, BackofficeAuthorization);
|
|
521
|
-
|
|
522
|
-
for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {
|
|
523
|
-
args[_key6] = arguments[_key6];
|
|
524
|
-
}
|
|
525
|
-
|
|
526
|
-
_this6 = _super6.call.apply(_super6, [this].concat(args));
|
|
527
|
-
|
|
528
|
-
_defineProperty(_assertThisInitialized(_this6), "serviceName", 'authorization');
|
|
529
|
-
|
|
530
|
-
return _this6;
|
|
531
|
-
}
|
|
532
|
-
|
|
533
511
|
_createClass(BackofficeAuthorization, [{
|
|
534
512
|
key: "getAuthToken",
|
|
535
513
|
value: function getAuthToken() {
|
|
@@ -539,58 +517,58 @@
|
|
|
539
517
|
|
|
540
518
|
return BackofficeAuthorization;
|
|
541
519
|
}(BaseCallClass);
|
|
542
|
-
var BackofficeCustomer = /*#__PURE__*/function (
|
|
543
|
-
_inherits(BackofficeCustomer,
|
|
520
|
+
var BackofficeCustomer = /*#__PURE__*/function (_BaseCallClass6) {
|
|
521
|
+
_inherits(BackofficeCustomer, _BaseCallClass6);
|
|
544
522
|
|
|
545
|
-
var
|
|
523
|
+
var _super6 = _createSuper(BackofficeCustomer);
|
|
546
524
|
|
|
547
525
|
function BackofficeCustomer() {
|
|
548
|
-
var
|
|
526
|
+
var _this6;
|
|
549
527
|
|
|
550
528
|
_classCallCheck(this, BackofficeCustomer);
|
|
551
529
|
|
|
552
|
-
for (var
|
|
553
|
-
args[
|
|
530
|
+
for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {
|
|
531
|
+
args[_key6] = arguments[_key6];
|
|
554
532
|
}
|
|
555
533
|
|
|
556
|
-
|
|
534
|
+
_this6 = _super6.call.apply(_super6, [this].concat(args));
|
|
557
535
|
|
|
558
|
-
_defineProperty(_assertThisInitialized(
|
|
536
|
+
_defineProperty(_assertThisInitialized(_this6), "serviceName", 'customer');
|
|
559
537
|
|
|
560
|
-
_defineProperty(_assertThisInitialized(
|
|
538
|
+
_defineProperty(_assertThisInitialized(_this6), "id", void 0);
|
|
561
539
|
|
|
562
|
-
_defineProperty(_assertThisInitialized(
|
|
540
|
+
_defineProperty(_assertThisInitialized(_this6), "name", void 0);
|
|
563
541
|
|
|
564
|
-
return
|
|
542
|
+
return _this6;
|
|
565
543
|
}
|
|
566
544
|
|
|
567
545
|
return _createClass(BackofficeCustomer);
|
|
568
546
|
}(BaseCallClass);
|
|
569
|
-
var BackofficePlugin = /*#__PURE__*/function (
|
|
570
|
-
_inherits(BackofficePlugin,
|
|
547
|
+
var BackofficePlugin = /*#__PURE__*/function (_BaseCallClass7) {
|
|
548
|
+
_inherits(BackofficePlugin, _BaseCallClass7);
|
|
571
549
|
|
|
572
|
-
var
|
|
550
|
+
var _super7 = _createSuper(BackofficePlugin);
|
|
573
551
|
|
|
574
552
|
function BackofficePlugin() {
|
|
575
|
-
var
|
|
553
|
+
var _this7;
|
|
576
554
|
|
|
577
555
|
_classCallCheck(this, BackofficePlugin);
|
|
578
556
|
|
|
579
|
-
for (var
|
|
580
|
-
args[
|
|
557
|
+
for (var _len7 = arguments.length, args = new Array(_len7), _key7 = 0; _key7 < _len7; _key7++) {
|
|
558
|
+
args[_key7] = arguments[_key7];
|
|
581
559
|
}
|
|
582
560
|
|
|
583
|
-
|
|
561
|
+
_this7 = _super7.call.apply(_super7, [this].concat(args));
|
|
584
562
|
|
|
585
|
-
_defineProperty(_assertThisInitialized(
|
|
563
|
+
_defineProperty(_assertThisInitialized(_this7), "serviceName", 'plugin');
|
|
586
564
|
|
|
587
|
-
_defineProperty(_assertThisInitialized(
|
|
565
|
+
_defineProperty(_assertThisInitialized(_this7), "id", void 0);
|
|
588
566
|
|
|
589
|
-
_defineProperty(_assertThisInitialized(
|
|
567
|
+
_defineProperty(_assertThisInitialized(_this7), "srcUrl", void 0);
|
|
590
568
|
|
|
591
|
-
_defineProperty(_assertThisInitialized(
|
|
569
|
+
_defineProperty(_assertThisInitialized(_this7), "name", void 0);
|
|
592
570
|
|
|
593
|
-
return
|
|
571
|
+
return _this7;
|
|
594
572
|
}
|
|
595
573
|
|
|
596
574
|
return _createClass(BackofficePlugin);
|
|
@@ -678,15 +656,15 @@
|
|
|
678
656
|
|
|
679
657
|
return ShopCatalog;
|
|
680
658
|
}(BaseCallClass);
|
|
681
|
-
var
|
|
682
|
-
_inherits(
|
|
659
|
+
var ShopWishlist = /*#__PURE__*/function (_BaseCallClass2) {
|
|
660
|
+
_inherits(ShopWishlist, _BaseCallClass2);
|
|
683
661
|
|
|
684
|
-
var _super2 = _createSuper(
|
|
662
|
+
var _super2 = _createSuper(ShopWishlist);
|
|
685
663
|
|
|
686
|
-
function
|
|
664
|
+
function ShopWishlist() {
|
|
687
665
|
var _this2;
|
|
688
666
|
|
|
689
|
-
_classCallCheck(this,
|
|
667
|
+
_classCallCheck(this, ShopWishlist);
|
|
690
668
|
|
|
691
669
|
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
692
670
|
args[_key2] = arguments[_key2];
|
|
@@ -694,17 +672,57 @@
|
|
|
694
672
|
|
|
695
673
|
_this2 = _super2.call.apply(_super2, [this].concat(args));
|
|
696
674
|
|
|
697
|
-
_defineProperty(_assertThisInitialized(_this2), "serviceName", '
|
|
675
|
+
_defineProperty(_assertThisInitialized(_this2), "serviceName", 'wishlist');
|
|
676
|
+
|
|
677
|
+
return _this2;
|
|
678
|
+
}
|
|
679
|
+
|
|
680
|
+
_createClass(ShopWishlist, [{
|
|
681
|
+
key: "addProductsToWishlist",
|
|
682
|
+
value: function addProductsToWishlist(wishlistId, newProduct) {
|
|
683
|
+
return this.call('addProductsToWishlist', wishlistId, newProduct);
|
|
684
|
+
}
|
|
685
|
+
}, {
|
|
686
|
+
key: "getWishlists",
|
|
687
|
+
value: function getWishlists() {
|
|
688
|
+
return this.call('getWishlists');
|
|
689
|
+
}
|
|
690
|
+
}, {
|
|
691
|
+
key: "createWishlist",
|
|
692
|
+
value: function createWishlist(name) {
|
|
693
|
+
return this.call('createWishlist', name);
|
|
694
|
+
}
|
|
695
|
+
}]);
|
|
696
|
+
|
|
697
|
+
return ShopWishlist;
|
|
698
|
+
}(BaseCallClass);
|
|
699
|
+
var ShopAccount = /*#__PURE__*/function (_BaseCallClass3) {
|
|
700
|
+
_inherits(ShopAccount, _BaseCallClass3);
|
|
698
701
|
|
|
699
|
-
|
|
702
|
+
var _super3 = _createSuper(ShopAccount);
|
|
700
703
|
|
|
701
|
-
|
|
704
|
+
function ShopAccount() {
|
|
705
|
+
var _this3;
|
|
702
706
|
|
|
703
|
-
|
|
707
|
+
_classCallCheck(this, ShopAccount);
|
|
704
708
|
|
|
705
|
-
|
|
709
|
+
for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
|
710
|
+
args[_key3] = arguments[_key3];
|
|
711
|
+
}
|
|
706
712
|
|
|
707
|
-
|
|
713
|
+
_this3 = _super3.call.apply(_super3, [this].concat(args));
|
|
714
|
+
|
|
715
|
+
_defineProperty(_assertThisInitialized(_this3), "serviceName", 'account');
|
|
716
|
+
|
|
717
|
+
_defineProperty(_assertThisInitialized(_this3), "client", void 0);
|
|
718
|
+
|
|
719
|
+
_defineProperty(_assertThisInitialized(_this3), "isAuthenticated", void 0);
|
|
720
|
+
|
|
721
|
+
_defineProperty(_assertThisInitialized(_this3), "user", void 0);
|
|
722
|
+
|
|
723
|
+
_defineProperty(_assertThisInitialized(_this3), "manager", void 0);
|
|
724
|
+
|
|
725
|
+
return _this3;
|
|
708
726
|
}
|
|
709
727
|
|
|
710
728
|
_createClass(ShopAccount, [{
|
|
@@ -720,31 +738,31 @@
|
|
|
720
738
|
|
|
721
739
|
return ShopAccount;
|
|
722
740
|
}(BaseCallClass);
|
|
723
|
-
var ShopCart = /*#__PURE__*/function (
|
|
724
|
-
_inherits(ShopCart,
|
|
741
|
+
var ShopCart = /*#__PURE__*/function (_BaseCallClass4) {
|
|
742
|
+
_inherits(ShopCart, _BaseCallClass4);
|
|
725
743
|
|
|
726
|
-
var
|
|
744
|
+
var _super4 = _createSuper(ShopCart);
|
|
727
745
|
|
|
728
746
|
function ShopCart() {
|
|
729
|
-
var
|
|
747
|
+
var _this4;
|
|
730
748
|
|
|
731
749
|
_classCallCheck(this, ShopCart);
|
|
732
750
|
|
|
733
|
-
for (var
|
|
734
|
-
args[
|
|
751
|
+
for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
|
|
752
|
+
args[_key4] = arguments[_key4];
|
|
735
753
|
}
|
|
736
754
|
|
|
737
|
-
|
|
755
|
+
_this4 = _super4.call.apply(_super4, [this].concat(args));
|
|
738
756
|
|
|
739
|
-
_defineProperty(_assertThisInitialized(
|
|
757
|
+
_defineProperty(_assertThisInitialized(_this4), "serviceName", 'cart');
|
|
740
758
|
|
|
741
|
-
_defineProperty(_assertThisInitialized(
|
|
759
|
+
_defineProperty(_assertThisInitialized(_this4), "carts", void 0);
|
|
742
760
|
|
|
743
|
-
_defineProperty(_assertThisInitialized(
|
|
761
|
+
_defineProperty(_assertThisInitialized(_this4), "currentCart", void 0);
|
|
744
762
|
|
|
745
|
-
_defineProperty(_assertThisInitialized(
|
|
763
|
+
_defineProperty(_assertThisInitialized(_this4), "totalCartPrice", void 0);
|
|
746
764
|
|
|
747
|
-
return
|
|
765
|
+
return _this4;
|
|
748
766
|
}
|
|
749
767
|
|
|
750
768
|
_createClass(ShopCart, [{
|
|
@@ -756,25 +774,25 @@
|
|
|
756
774
|
|
|
757
775
|
return ShopCart;
|
|
758
776
|
}(BaseCallClass);
|
|
759
|
-
var ShopAuthorization = /*#__PURE__*/function (
|
|
760
|
-
_inherits(ShopAuthorization,
|
|
777
|
+
var ShopAuthorization = /*#__PURE__*/function (_BaseCallClass5) {
|
|
778
|
+
_inherits(ShopAuthorization, _BaseCallClass5);
|
|
761
779
|
|
|
762
|
-
var
|
|
780
|
+
var _super5 = _createSuper(ShopAuthorization);
|
|
763
781
|
|
|
764
782
|
function ShopAuthorization() {
|
|
765
|
-
var
|
|
783
|
+
var _this5;
|
|
766
784
|
|
|
767
785
|
_classCallCheck(this, ShopAuthorization);
|
|
768
786
|
|
|
769
|
-
for (var
|
|
770
|
-
args[
|
|
787
|
+
for (var _len5 = arguments.length, args = new Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {
|
|
788
|
+
args[_key5] = arguments[_key5];
|
|
771
789
|
}
|
|
772
790
|
|
|
773
|
-
|
|
791
|
+
_this5 = _super5.call.apply(_super5, [this].concat(args));
|
|
774
792
|
|
|
775
|
-
_defineProperty(_assertThisInitialized(
|
|
793
|
+
_defineProperty(_assertThisInitialized(_this5), "serviceName", 'authorization');
|
|
776
794
|
|
|
777
|
-
return
|
|
795
|
+
return _this5;
|
|
778
796
|
}
|
|
779
797
|
|
|
780
798
|
_createClass(ShopAuthorization, [{
|
|
@@ -786,41 +804,41 @@
|
|
|
786
804
|
|
|
787
805
|
return ShopAuthorization;
|
|
788
806
|
}(BaseCallClass);
|
|
789
|
-
var ShopUtils = /*#__PURE__*/function (
|
|
790
|
-
_inherits(ShopUtils,
|
|
807
|
+
var ShopUtils = /*#__PURE__*/function (_BaseCallClass6) {
|
|
808
|
+
_inherits(ShopUtils, _BaseCallClass6);
|
|
791
809
|
|
|
792
|
-
var
|
|
810
|
+
var _super6 = _createSuper(ShopUtils);
|
|
793
811
|
|
|
794
812
|
function ShopUtils(call) {
|
|
795
|
-
var
|
|
813
|
+
var _this6;
|
|
796
814
|
|
|
797
815
|
_classCallCheck(this, ShopUtils);
|
|
798
816
|
|
|
799
|
-
|
|
817
|
+
_this6 = _super6.call(this, call);
|
|
800
818
|
|
|
801
|
-
_defineProperty(_assertThisInitialized(
|
|
819
|
+
_defineProperty(_assertThisInitialized(_this6), "serviceName", 'utils');
|
|
802
820
|
|
|
803
|
-
_defineProperty(_assertThisInitialized(
|
|
821
|
+
_defineProperty(_assertThisInitialized(_this6), "currency", void 0);
|
|
804
822
|
|
|
805
|
-
_defineProperty(_assertThisInitialized(
|
|
823
|
+
_defineProperty(_assertThisInitialized(_this6), "isAnonymousAndPurchaseDisabled", void 0);
|
|
806
824
|
|
|
807
|
-
_defineProperty(_assertThisInitialized(
|
|
825
|
+
_defineProperty(_assertThisInitialized(_this6), "isB2B", void 0);
|
|
808
826
|
|
|
809
|
-
_defineProperty(_assertThisInitialized(
|
|
827
|
+
_defineProperty(_assertThisInitialized(_this6), "isB2BAndPlatformIsNotOpened", void 0);
|
|
810
828
|
|
|
811
|
-
_defineProperty(_assertThisInitialized(
|
|
829
|
+
_defineProperty(_assertThisInitialized(_this6), "isIndexPage", void 0);
|
|
812
830
|
|
|
813
|
-
_defineProperty(_assertThisInitialized(
|
|
831
|
+
_defineProperty(_assertThisInitialized(_this6), "isPurchaseEnabledOrAuthenticated", void 0);
|
|
814
832
|
|
|
815
|
-
_defineProperty(_assertThisInitialized(
|
|
833
|
+
_defineProperty(_assertThisInitialized(_this6), "routes", void 0);
|
|
816
834
|
|
|
817
|
-
|
|
818
|
-
getCategoryPath:
|
|
819
|
-
getManufacturerSearchUrl:
|
|
820
|
-
getProductUrl:
|
|
821
|
-
isExternalUrl:
|
|
835
|
+
_this6.routes = {
|
|
836
|
+
getCategoryPath: _this6.getCategoryPath,
|
|
837
|
+
getManufacturerSearchUrl: _this6.getManufacturerSearchUrl,
|
|
838
|
+
getProductUrl: _this6.getProductUrl,
|
|
839
|
+
isExternalUrl: _this6.isExternalUrl
|
|
822
840
|
};
|
|
823
|
-
return
|
|
841
|
+
return _this6;
|
|
824
842
|
}
|
|
825
843
|
|
|
826
844
|
_createClass(ShopUtils, [{
|
|
@@ -847,43 +865,43 @@
|
|
|
847
865
|
|
|
848
866
|
return ShopUtils;
|
|
849
867
|
}(BaseCallClass);
|
|
850
|
-
var ShopConfig = /*#__PURE__*/function (
|
|
851
|
-
_inherits(ShopConfig,
|
|
868
|
+
var ShopConfig = /*#__PURE__*/function (_BaseCallClass7) {
|
|
869
|
+
_inherits(ShopConfig, _BaseCallClass7);
|
|
852
870
|
|
|
853
|
-
var
|
|
871
|
+
var _super7 = _createSuper(ShopConfig);
|
|
854
872
|
|
|
855
873
|
function ShopConfig() {
|
|
856
|
-
var
|
|
874
|
+
var _this7;
|
|
857
875
|
|
|
858
876
|
_classCallCheck(this, ShopConfig);
|
|
859
877
|
|
|
860
|
-
for (var
|
|
861
|
-
args[
|
|
878
|
+
for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {
|
|
879
|
+
args[_key6] = arguments[_key6];
|
|
862
880
|
}
|
|
863
881
|
|
|
864
|
-
|
|
882
|
+
_this7 = _super7.call.apply(_super7, [this].concat(args));
|
|
865
883
|
|
|
866
|
-
_defineProperty(_assertThisInitialized(
|
|
884
|
+
_defineProperty(_assertThisInitialized(_this7), "serviceName", 'config');
|
|
867
885
|
|
|
868
|
-
_defineProperty(_assertThisInitialized(
|
|
886
|
+
_defineProperty(_assertThisInitialized(_this7), "accessMode", void 0);
|
|
869
887
|
|
|
870
|
-
_defineProperty(_assertThisInitialized(
|
|
888
|
+
_defineProperty(_assertThisInitialized(_this7), "isB2CRegistrationEnabled", void 0);
|
|
871
889
|
|
|
872
|
-
_defineProperty(_assertThisInitialized(
|
|
890
|
+
_defineProperty(_assertThisInitialized(_this7), "isCatalogOpened", void 0);
|
|
873
891
|
|
|
874
|
-
_defineProperty(_assertThisInitialized(
|
|
892
|
+
_defineProperty(_assertThisInitialized(_this7), "isGrossSelected", void 0);
|
|
875
893
|
|
|
876
|
-
_defineProperty(_assertThisInitialized(
|
|
894
|
+
_defineProperty(_assertThisInitialized(_this7), "isPlatformClosed", void 0);
|
|
877
895
|
|
|
878
|
-
_defineProperty(_assertThisInitialized(
|
|
896
|
+
_defineProperty(_assertThisInitialized(_this7), "isPlatformOpened", void 0);
|
|
879
897
|
|
|
880
|
-
_defineProperty(_assertThisInitialized(
|
|
898
|
+
_defineProperty(_assertThisInitialized(_this7), "isPurchaseEnabled", void 0);
|
|
881
899
|
|
|
882
|
-
_defineProperty(_assertThisInitialized(
|
|
900
|
+
_defineProperty(_assertThisInitialized(_this7), "isRegistrationEnabled", void 0);
|
|
883
901
|
|
|
884
|
-
_defineProperty(_assertThisInitialized(
|
|
902
|
+
_defineProperty(_assertThisInitialized(_this7), "currency", void 0);
|
|
885
903
|
|
|
886
|
-
return
|
|
904
|
+
return _this7;
|
|
887
905
|
}
|
|
888
906
|
|
|
889
907
|
return _createClass(ShopConfig);
|
|
@@ -1083,11 +1101,15 @@
|
|
|
1083
1101
|
method: fun,
|
|
1084
1102
|
payload: payload
|
|
1085
1103
|
});
|
|
1086
|
-
return new Promise(function (resolve) {
|
|
1104
|
+
return new Promise(function (resolve, reject) {
|
|
1087
1105
|
var onChannelMessage = function onChannelMessage(response) {
|
|
1088
1106
|
if (response.callId === callId) {
|
|
1089
1107
|
_this4.channel.unsubscribe(main.Message.METHOD_RESULT, onChannelMessage);
|
|
1090
1108
|
|
|
1109
|
+
if (response !== null && response !== void 0 && response.isException) {
|
|
1110
|
+
return reject(response.result);
|
|
1111
|
+
}
|
|
1112
|
+
|
|
1091
1113
|
return resolve(response.result);
|
|
1092
1114
|
}
|
|
1093
1115
|
};
|
|
@@ -1154,7 +1176,6 @@
|
|
|
1154
1176
|
hash: '',
|
|
1155
1177
|
query: {}
|
|
1156
1178
|
},
|
|
1157
|
-
orderpath: new BackofficeOrderpath(_this5.callFunction.bind(_assertThisInitialized(_this5))),
|
|
1158
1179
|
catalog: new BackofficeCatalog(_this5.callFunction.bind(_assertThisInitialized(_this5))),
|
|
1159
1180
|
user: new BackofficeUser(_this5.callFunction.bind(_assertThisInitialized(_this5))),
|
|
1160
1181
|
tenant: new BackofficeTenant(_this5.callFunction.bind(_assertThisInitialized(_this5))),
|
|
@@ -1196,7 +1217,8 @@
|
|
|
1196
1217
|
catalog: new ShopCatalog(_this6.callFunction.bind(_assertThisInitialized(_this6))),
|
|
1197
1218
|
account: new ShopAccount(_this6.callFunction.bind(_assertThisInitialized(_this6))),
|
|
1198
1219
|
utils: new ShopUtils(_this6.callFunction.bind(_assertThisInitialized(_this6))),
|
|
1199
|
-
config: new ShopConfig(_this6.callFunction.bind(_assertThisInitialized(_this6)))
|
|
1220
|
+
config: new ShopConfig(_this6.callFunction.bind(_assertThisInitialized(_this6))),
|
|
1221
|
+
wishlist: new ShopWishlist(_this6.callFunction.bind(_assertThisInitialized(_this6)))
|
|
1200
1222
|
});
|
|
1201
1223
|
|
|
1202
1224
|
return _this6;
|