buildingproduct-library 0.2.79 → 0.2.80
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/{buildingproduct-library-0.2.79.tgz → buildingproduct-library-0.2.80.tgz} +0 -0
- package/bundles/buildingproduct-library.umd.js +45 -55
- package/bundles/buildingproduct-library.umd.js.map +1 -1
- package/esm2015/lib/account-dropdown/account-dropdown.component.js +2 -2
- package/esm2015/lib/find-store/find-store.component.js +2 -2
- package/fesm2015/buildingproduct-library.js +2 -2
- package/fesm2015/buildingproduct-library.js.map +1 -1
- package/package.json +1 -1
|
Binary file
|
|
@@ -982,42 +982,37 @@
|
|
|
982
982
|
}
|
|
983
983
|
AccountDropdownComponent.prototype.ngOnInit = function () {
|
|
984
984
|
return __awaiter(this, void 0, void 0, function () {
|
|
985
|
-
var isLoaded;
|
|
986
985
|
var _this = this;
|
|
987
986
|
return __generator(this, function (_c) {
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
_this.
|
|
1001
|
-
|
|
1002
|
-
_this.showWaitCursor.next(false);
|
|
1003
|
-
_this.accounts = data;
|
|
1004
|
-
_this.getAccountsData();
|
|
1005
|
-
}
|
|
1006
|
-
});
|
|
987
|
+
// const isLoaded = await this.fiUserAccountDetailsService.isEnviornmentLoaded();
|
|
988
|
+
this.selecteduserData = JSON.parse(localStorage.getItem('selectedAccout') || '{}');
|
|
989
|
+
this.fiUserAccountDetailsService.getUserAccount().subscribe(function (user) {
|
|
990
|
+
var _a, _b;
|
|
991
|
+
if (user) {
|
|
992
|
+
var username = (_a = user.uid) === null || _a === void 0 ? void 0 : _a.toString();
|
|
993
|
+
var cartObj = localStorage.getItem('spartacus⚿dimond-spa⚿cart');
|
|
994
|
+
var cartId = (_b = JSON.parse(cartObj)) === null || _b === void 0 ? void 0 : _b.active;
|
|
995
|
+
if (cartId) {
|
|
996
|
+
_this.service.getAccountDatawithCartId(cartId).subscribe(function (data) {
|
|
997
|
+
if (data) {
|
|
998
|
+
_this.showWaitCursor.next(false);
|
|
999
|
+
_this.accounts = data;
|
|
1000
|
+
_this.getAccountsData();
|
|
1007
1001
|
}
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1002
|
+
});
|
|
1003
|
+
}
|
|
1004
|
+
else {
|
|
1005
|
+
_this.service.getAccountData().subscribe(function (data) {
|
|
1006
|
+
if (data) {
|
|
1007
|
+
_this.showWaitCursor.next(false);
|
|
1008
|
+
_this.accounts = data;
|
|
1009
|
+
_this.getAccountsData();
|
|
1016
1010
|
}
|
|
1017
|
-
}
|
|
1018
|
-
}
|
|
1019
|
-
|
|
1020
|
-
}
|
|
1011
|
+
});
|
|
1012
|
+
}
|
|
1013
|
+
}
|
|
1014
|
+
});
|
|
1015
|
+
return [2 /*return*/];
|
|
1021
1016
|
});
|
|
1022
1017
|
});
|
|
1023
1018
|
};
|
|
@@ -1219,31 +1214,26 @@
|
|
|
1219
1214
|
}
|
|
1220
1215
|
FindStoreComponent.prototype.ngOnInit = function () {
|
|
1221
1216
|
return __awaiter(this, void 0, void 0, function () {
|
|
1222
|
-
var isLoaded;
|
|
1223
1217
|
var _this = this;
|
|
1224
1218
|
return __generator(this, function (_b) {
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
}, 100);
|
|
1244
|
-
});
|
|
1245
|
-
return [2 /*return*/];
|
|
1246
|
-
}
|
|
1219
|
+
// const isLoaded = await this.fiUserAccountDetailsService.isEnviornmentLoaded();
|
|
1220
|
+
this.findStoreService.homeBranch.subscribe(function (data) {
|
|
1221
|
+
setTimeout(function () {
|
|
1222
|
+
var _a;
|
|
1223
|
+
if (data) {
|
|
1224
|
+
if (localStorage.getItem('branchDetails')) {
|
|
1225
|
+
_this.homeBranchData = localStorage.getItem('branchDetails');
|
|
1226
|
+
_this.branchName = (_a = JSON.parse(_this.homeBranchData)) === null || _a === void 0 ? void 0 : _a.displayName;
|
|
1227
|
+
_this.cd.markForCheck();
|
|
1228
|
+
}
|
|
1229
|
+
else {
|
|
1230
|
+
_this.branchName = data === null || data === void 0 ? void 0 : data.displayName;
|
|
1231
|
+
_this.cd.markForCheck();
|
|
1232
|
+
}
|
|
1233
|
+
}
|
|
1234
|
+
}, 100);
|
|
1235
|
+
});
|
|
1236
|
+
return [2 /*return*/];
|
|
1247
1237
|
});
|
|
1248
1238
|
});
|
|
1249
1239
|
};
|