@infrab4a/connect-angular 4.0.0-beta.50 → 4.0.0-beta.51
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/esm2020/angular-hasura-graphql.module.mjs +1 -1
- package/esm2020/services/catalog/wishlist.service.mjs +9 -10
- package/esm2020/services/helpers/util.service.mjs +2 -10
- package/fesm2015/infrab4a-connect-angular.mjs +26 -32
- package/fesm2015/infrab4a-connect-angular.mjs.map +1 -1
- package/fesm2020/infrab4a-connect-angular.mjs +9 -15
- package/fesm2020/infrab4a-connect-angular.mjs.map +1 -1
- package/package.json +1 -1
- package/services/catalog/wishlist.service.d.ts +4 -7
- package/services/helpers/util.service.d.ts +1 -5
|
@@ -1603,8 +1603,7 @@ __decorate([
|
|
|
1603
1603
|
], CategoryWithTree.prototype, "children", void 0);
|
|
1604
1604
|
|
|
1605
1605
|
class UtilService {
|
|
1606
|
-
|
|
1607
|
-
createSlug(name) {
|
|
1606
|
+
static createSlug(name) {
|
|
1608
1607
|
return name
|
|
1609
1608
|
.toLowerCase()
|
|
1610
1609
|
.replace(/\s+/g, '-') // Replace spaces with -
|
|
@@ -1620,11 +1619,6 @@ class UtilService {
|
|
|
1620
1619
|
.replace(/\-\-+/g, '-'); // Replace multiple - with single -
|
|
1621
1620
|
}
|
|
1622
1621
|
}
|
|
1623
|
-
UtilService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: UtilService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1624
|
-
UtilService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: UtilService });
|
|
1625
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: UtilService, decorators: [{
|
|
1626
|
-
type: Injectable
|
|
1627
|
-
}], ctorParameters: function () { return []; } });
|
|
1628
1622
|
|
|
1629
1623
|
class NewCategoryStructureAdapter {
|
|
1630
1624
|
constructor(categoryRepository, categoryCollectionChildrenRepository) {
|
|
@@ -1686,12 +1680,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
|
|
|
1686
1680
|
}] }]; } });
|
|
1687
1681
|
|
|
1688
1682
|
class WishlistService {
|
|
1689
|
-
constructor(wishlistRepository, shop, productRepository, categoryFilterRepository, categoryCollectionChildrenRepository
|
|
1683
|
+
constructor(wishlistRepository, shop, productRepository, categoryFilterRepository, categoryCollectionChildrenRepository) {
|
|
1690
1684
|
this.wishlistRepository = wishlistRepository;
|
|
1691
1685
|
this.shop = shop;
|
|
1692
|
-
|
|
1693
|
-
this.
|
|
1694
|
-
this.
|
|
1686
|
+
const categoryStructureAdapter = new NewCategoryStructureAdapter(wishlistRepository, categoryCollectionChildrenRepository);
|
|
1687
|
+
this.catalogService = new CatalogService(productRepository, categoryStructureAdapter, shop);
|
|
1688
|
+
this.categoryService = new CategoryService(productRepository, wishlistRepository, categoryFilterRepository, categoryStructureAdapter, shop);
|
|
1695
1689
|
}
|
|
1696
1690
|
getCatalogService() {
|
|
1697
1691
|
return this.catalogService;
|
|
@@ -1701,7 +1695,7 @@ class WishlistService {
|
|
|
1701
1695
|
}
|
|
1702
1696
|
async create(personId, title, description, userFullName) {
|
|
1703
1697
|
const data = {
|
|
1704
|
-
slug:
|
|
1698
|
+
slug: UtilService.createSlug(`favoritos ${userFullName} ${title}`),
|
|
1705
1699
|
name: title,
|
|
1706
1700
|
description,
|
|
1707
1701
|
metadata: {
|
|
@@ -1720,7 +1714,7 @@ class WishlistService {
|
|
|
1720
1714
|
update(id, title, description, userFullName) {
|
|
1721
1715
|
const data = {
|
|
1722
1716
|
id,
|
|
1723
|
-
slug:
|
|
1717
|
+
slug: UtilService.createSlug(`${id}-favoritos ${userFullName} ${title}`),
|
|
1724
1718
|
name: title,
|
|
1725
1719
|
description,
|
|
1726
1720
|
metadata: {
|
|
@@ -1760,7 +1754,7 @@ class WishlistService {
|
|
|
1760
1754
|
return wishlist;
|
|
1761
1755
|
}
|
|
1762
1756
|
}
|
|
1763
|
-
WishlistService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService, deps:
|
|
1757
|
+
WishlistService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService, deps: [{ token: 'WishlistRepository' }, { token: DEFAULT_SHOP }, { token: 'ProductRepository' }, { token: 'CategoryFilterRepository' }, { token: 'CategoryCollectionChildrenRepository' }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1764
1758
|
WishlistService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService });
|
|
1765
1759
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImport: i0, type: WishlistService, decorators: [{
|
|
1766
1760
|
type: Injectable
|
|
@@ -1779,7 +1773,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0", ngImpor
|
|
|
1779
1773
|
}] }, { type: undefined, decorators: [{
|
|
1780
1774
|
type: Inject,
|
|
1781
1775
|
args: ['CategoryCollectionChildrenRepository']
|
|
1782
|
-
}] }
|
|
1776
|
+
}] }]; } });
|
|
1783
1777
|
|
|
1784
1778
|
class CheckoutSubscriptionService {
|
|
1785
1779
|
constructor(checkoutSubscriptionRepository, subscriptionRepository, couponService) {
|