ng-easycommerce 0.0.608 → 0.0.610

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.
Files changed (52) hide show
  1. package/README.md +9 -0
  2. package/assets/ec-i18n/ct.json +4 -1
  3. package/assets/ec-i18n/en.json +2 -0
  4. package/assets/ec-i18n/es.json +2 -0
  5. package/assets/ec-i18n/fr.json +4 -1
  6. package/assets/ec-i18n/gl.json +4 -1
  7. package/assets/ec-i18n/pr.json +4 -1
  8. package/bundles/ng-easycommerce.umd.js +147 -79
  9. package/bundles/ng-easycommerce.umd.js.map +1 -1
  10. package/bundles/ng-easycommerce.umd.min.js +1 -1
  11. package/bundles/ng-easycommerce.umd.min.js.map +1 -1
  12. package/esm2015/lib/ec-component/account-ec/order-ec/order-ec.component.js +4 -8
  13. package/esm2015/lib/ec-component/account-ec/orders-list-ec/orders-list-ec.component.js +4 -8
  14. package/esm2015/lib/ec-component/cart-ec/cart-ec.component.js +5 -3
  15. package/esm2015/lib/ec-component/checkout-ec/detail-checkout-block-ec/detail-checkout-block-ec.component.js +22 -18
  16. package/esm2015/lib/ec-component/checkout-ec/payment-ec/payment-ec.component.js +21 -4
  17. package/esm2015/lib/ec-component/header-ec/header-ec.component.js +2 -1
  18. package/esm2015/lib/ec-component/product-detail-ec/product-detail-ec.component.js +2 -2
  19. package/esm2015/lib/ec-component/product-ec/product-ec.component.js +2 -2
  20. package/esm2015/lib/ec-component/sidebar-ec/sidebar-ec.component.js +5 -1
  21. package/esm2015/lib/ec-component/widgets-ec/price-ec/price-ec.component.js +51 -6
  22. package/esm2015/lib/services/cart.service.js +34 -33
  23. package/esm2015/lib/services/checkout/checkout.service.js +5 -5
  24. package/esm2015/lib/services/products/product-detail.service.js +5 -2
  25. package/esm5/lib/ec-component/account-ec/order-ec/order-ec.component.js +4 -8
  26. package/esm5/lib/ec-component/account-ec/orders-list-ec/orders-list-ec.component.js +4 -8
  27. package/esm5/lib/ec-component/cart-ec/cart-ec.component.js +5 -3
  28. package/esm5/lib/ec-component/checkout-ec/detail-checkout-block-ec/detail-checkout-block-ec.component.js +22 -18
  29. package/esm5/lib/ec-component/checkout-ec/payment-ec/payment-ec.component.js +21 -4
  30. package/esm5/lib/ec-component/header-ec/header-ec.component.js +2 -1
  31. package/esm5/lib/ec-component/product-detail-ec/product-detail-ec.component.js +2 -2
  32. package/esm5/lib/ec-component/product-ec/product-ec.component.js +2 -2
  33. package/esm5/lib/ec-component/sidebar-ec/sidebar-ec.component.js +5 -1
  34. package/esm5/lib/ec-component/widgets-ec/price-ec/price-ec.component.js +52 -6
  35. package/esm5/lib/services/cart.service.js +34 -33
  36. package/esm5/lib/services/checkout/checkout.service.js +5 -5
  37. package/esm5/lib/services/products/product-detail.service.js +5 -2
  38. package/fesm2015/ng-easycommerce.js +146 -79
  39. package/fesm2015/ng-easycommerce.js.map +1 -1
  40. package/fesm5/ng-easycommerce.js +147 -79
  41. package/fesm5/ng-easycommerce.js.map +1 -1
  42. package/lib/ec-component/account-ec/order-ec/order-ec.component.d.ts +1 -2
  43. package/lib/ec-component/account-ec/orders-list-ec/orders-list-ec.component.d.ts +1 -2
  44. package/lib/ec-component/cart-ec/cart-ec.component.d.ts +2 -1
  45. package/lib/ec-component/checkout-ec/detail-checkout-block-ec/detail-checkout-block-ec.component.d.ts +5 -4
  46. package/lib/ec-component/checkout-ec/payment-ec/payment-ec.component.d.ts +5 -1
  47. package/lib/ec-component/product-detail-ec/product-detail-ec.component.d.ts +1 -1
  48. package/lib/ec-component/product-ec/product-ec.component.d.ts +1 -1
  49. package/lib/ec-component/sidebar-ec/sidebar-ec.component.d.ts +1 -0
  50. package/lib/ec-component/widgets-ec/price-ec/price-ec.component.d.ts +23 -6
  51. package/ng-easycommerce.metadata.json +1 -1
  52. package/package.json +1 -1
@@ -3138,9 +3138,9 @@ let CheckoutService = class CheckoutService {
3138
3138
  return ({ ok: true, require_login: false, message: '' });
3139
3139
  });
3140
3140
  this.updateAsociatedData = (cart) => {
3141
- var _a, _b, _c;
3141
+ var _a, _b;
3142
3142
  let result = this.orderUtils.getPromotions(cart);
3143
- if (((_a = this.authService.getUserProfileAsUser()) === null || _a === void 0 ? void 0 : _a.isWholesaler()) && cart.totals.taxes != 0) {
3143
+ if (cart.totals.taxes != 0) {
3144
3144
  let total = Object.assign({}, result[result.length - 1]);
3145
3145
  result[result.length - 1] = {
3146
3146
  type: 'taxes',
@@ -3149,9 +3149,9 @@ let CheckoutService = class CheckoutService {
3149
3149
  };
3150
3150
  result.push(total);
3151
3151
  }
3152
- let shipment = (_b = result) === null || _b === void 0 ? void 0 : _b.find(promotion => promotion.type == "shipment");
3152
+ let shipment = (_a = result) === null || _a === void 0 ? void 0 : _a.find(promotion => promotion.type == "shipment");
3153
3153
  if (!shipment && cart.totals.shipping != 0) {
3154
- if (((_c = result) === null || _c === void 0 ? void 0 : _c.length) && !result.find(item => item.type === "shipment")) {
3154
+ if (((_b = result) === null || _b === void 0 ? void 0 : _b.length) && !result.find(item => item.type === "shipment")) {
3155
3155
  let total = Object.assign({}, result[result.length - 1]);
3156
3156
  result[result.length - 1] = {
3157
3157
  type: 'shipment',
@@ -3919,16 +3919,7 @@ let CartService = class CartService {
3919
3919
  this.cartSubject = new BehaviorSubject(null);
3920
3920
  this.requestInProcess = new BehaviorSubject(false);
3921
3921
  this.promotionsSubject = new BehaviorSubject([]);
3922
- this.balanceCustomerSubject = new BehaviorSubject({
3923
- allowAnyPaymentMethod: false,
3924
- allowExceedBalance: false,
3925
- creditAmount: 0,
3926
- showMax: false,
3927
- showPrice: false,
3928
- remainingCredits: 0,
3929
- applyMaxOrders: false,
3930
- maxOrders: Infinity
3931
- });
3922
+ this.balanceCustomerSubject = new BehaviorSubject(null);
3932
3923
  this.items = [];
3933
3924
  this.count = 0;
3934
3925
  this.locale = "";
@@ -3951,11 +3942,11 @@ let CartService = class CartService {
3951
3942
  this.promotions = this.promotionsSubject.asObservable();
3952
3943
  this.deleting = false;
3953
3944
  this.balanceCustomer$ = this.balanceCustomerSubject.asObservable();
3954
- this.allowAnyPaymentMethod$ = this.balanceCustomer$.pipe(map(data => data.allowAnyPaymentMethod));
3955
- this.allowExceedBalance$ = this.balanceCustomer$.pipe(map(data => data.allowExceedBalance));
3956
- this.creditAmount$ = this.balanceCustomer$.pipe(map(data => data.creditAmount));
3957
- this.showMax$ = this.balanceCustomer$.pipe(map(data => data.showMax));
3958
- this.showPrice$ = this.balanceCustomer$.pipe(map(data => data.showPrice));
3945
+ this.allowAnyPaymentMethod$ = this.balanceCustomer$.pipe(map(data => { var _a, _b; return _b = (_a = data) === null || _a === void 0 ? void 0 : _a.allowAnyPaymentMethod, (_b !== null && _b !== void 0 ? _b : null); }));
3946
+ this.allowExceedBalance$ = this.balanceCustomer$.pipe(map(data => { var _a, _b; return _b = (_a = data) === null || _a === void 0 ? void 0 : _a.allowExceedBalance, (_b !== null && _b !== void 0 ? _b : null); }));
3947
+ this.creditAmount$ = this.balanceCustomer$.pipe(map(data => { var _a, _b; return _b = (_a = data) === null || _a === void 0 ? void 0 : _a.creditAmount, (_b !== null && _b !== void 0 ? _b : null); }));
3948
+ this.showMax$ = this.balanceCustomer$.pipe(map(data => { var _a, _b; return _b = (_a = data) === null || _a === void 0 ? void 0 : _a.showMax, (_b !== null && _b !== void 0 ? _b : null); }));
3949
+ this.showPrice$ = this.balanceCustomer$.pipe(map(data => { var _a, _b; return _b = (_a = data) === null || _a === void 0 ? void 0 : _a.showPrice, (_b !== null && _b !== void 0 ? _b : null); }));
3959
3950
  this.getAddressBook = () => __awaiter$5(this, void 0, void 0, function* () { return this.connection.get(this.addressBookApi()).pipe(map(res => { var _a; return ((_a = res) === null || _a === void 0 ? void 0 : _a.length) && res.map(addres => { return addres && Object.assign(Object.assign({}, addres), { selected: addres.default }); }) || null; })).toPromise(); });
3960
3951
  this.getTaxes = () => __awaiter$5(this, void 0, void 0, function* () { return this.connection.post(this.taxesApi(), { token: this.cart_token }).subscribe(res => res); });
3961
3952
  this.getCart = () => __awaiter$5(this, void 0, void 0, function* () {
@@ -4067,8 +4058,11 @@ let CartService = class CartService {
4067
4058
  * CART CRUD
4068
4059
  */
4069
4060
  this.addToCart = (product, quantity, variant_id) => {
4061
+ var _a, _b, _c, _d;
4070
4062
  const balance = this.balanceCustomerSubject.value;
4071
- if (balance.applyMaxOrders && (balance.maxOrders <= 0 || balance.maxOrders === null)) {
4063
+ const applyMaxOrders = (_b = (_a = balance) === null || _a === void 0 ? void 0 : _a.applyMaxOrders, (_b !== null && _b !== void 0 ? _b : false));
4064
+ const maxOrders = (_d = (_c = balance) === null || _c === void 0 ? void 0 : _c.maxOrders, (_d !== null && _d !== void 0 ? _d : Infinity));
4065
+ if (applyMaxOrders && (maxOrders <= 0 || maxOrders === null)) {
4072
4066
  this.toastrService.show('max-orders-reached');
4073
4067
  return;
4074
4068
  }
@@ -4173,10 +4167,11 @@ let CartService = class CartService {
4173
4167
  return true;
4174
4168
  };
4175
4169
  this.validatePriceAndCredits = (item, quantity) => {
4176
- if (this.balanceCustomerSubject.value.creditAmount === null) {
4170
+ const balance = this.balanceCustomerSubject.value;
4171
+ if (!balance || balance.creditAmount === null || balance.creditAmount === undefined) {
4177
4172
  return true;
4178
4173
  }
4179
- if (this.balanceCustomerSubject.value.remainingCredits === undefined) {
4174
+ if (balance.remainingCredits === undefined) {
4180
4175
  return false;
4181
4176
  }
4182
4177
  const unitPrice = item.total / item.quantity;
@@ -4185,20 +4180,21 @@ let CartService = class CartService {
4185
4180
  return true;
4186
4181
  }
4187
4182
  const additionalCost = unitPrice * additionalQuantity;
4188
- if (additionalCost > this.balanceCustomerSubject.value.remainingCredits) {
4183
+ if (additionalCost > balance.remainingCredits) {
4189
4184
  this.toastrService.show('not-enough-credits');
4190
4185
  return false;
4191
4186
  }
4192
4187
  return true;
4193
4188
  };
4194
4189
  this.hasSufficientCreditsForCartTotal = () => {
4195
- if (this.balanceCustomerSubject.value.creditAmount === null) {
4190
+ const balance = this.balanceCustomerSubject.value;
4191
+ if (!balance || balance.creditAmount === null || balance.creditAmount === undefined) {
4196
4192
  return true;
4197
4193
  }
4198
- if (this.balanceCustomerSubject.value.remainingCredits === undefined) {
4194
+ if (balance.remainingCredits === undefined) {
4199
4195
  return false;
4200
4196
  }
4201
- if (this.cartSubject.value.totals.total > this.balanceCustomerSubject.value.creditAmount) {
4197
+ if (this.cartSubject.value.totals.total > balance.creditAmount) {
4202
4198
  this.toastrService.show('not-enough-credits');
4203
4199
  return false;
4204
4200
  }
@@ -4412,18 +4408,23 @@ let CartService = class CartService {
4412
4408
  }));
4413
4409
  }
4414
4410
  updateBalanceAttributes(cartData) {
4415
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
4411
+ var _a, _b, _c;
4412
+ const balance = (_a = cartData) === null || _a === void 0 ? void 0 : _a.balanceCustomer;
4413
+ if (!balance) {
4414
+ this.balanceCustomerSubject.next(null);
4415
+ return;
4416
+ }
4416
4417
  const balanceData = {
4417
- allowAnyPaymentMethod: (_b = (_a = cartData) === null || _a === void 0 ? void 0 : _a.allowAnyPaymentMethod, (_b !== null && _b !== void 0 ? _b : false)),
4418
- allowExceedBalance: (_d = (_c = cartData) === null || _c === void 0 ? void 0 : _c.allowExceedBalance, (_d !== null && _d !== void 0 ? _d : false)),
4419
- creditAmount: (_f = (_e = cartData) === null || _e === void 0 ? void 0 : _e.creditAmount, (_f !== null && _f !== void 0 ? _f : null)),
4420
- showMax: (_h = (_g = cartData) === null || _g === void 0 ? void 0 : _g.showMax, (_h !== null && _h !== void 0 ? _h : false)),
4421
- showPrice: (_k = (_j = cartData) === null || _j === void 0 ? void 0 : _j.showPrice, (_k !== null && _k !== void 0 ? _k : false)),
4422
- remainingCredits: ((_l = cartData) === null || _l === void 0 ? void 0 : _l.creditAmount) && ((_m = cartData) === null || _m === void 0 ? void 0 : _m.creditAmount) >= ((_o = cartData) === null || _o === void 0 ? void 0 : _o.totals.total)
4423
- ? ((_p = cartData) === null || _p === void 0 ? void 0 : _p.creditAmount) - ((_q = cartData) === null || _q === void 0 ? void 0 : _q.totals.total)
4418
+ allowAnyPaymentMethod: balance.allowAnyPaymentMethod,
4419
+ allowExceedBalance: balance.allowExceedBalance,
4420
+ creditAmount: balance.creditAmount,
4421
+ showMax: balance.showMax,
4422
+ showPrice: balance.showPrice,
4423
+ remainingCredits: balance.creditAmount && ((_c = (_b = cartData) === null || _b === void 0 ? void 0 : _b.totals) === null || _c === void 0 ? void 0 : _c.total) && balance.creditAmount >= cartData.totals.total
4424
+ ? balance.creditAmount - cartData.totals.total
4424
4425
  : 0,
4425
- applyMaxOrders: (_s = (_r = cartData) === null || _r === void 0 ? void 0 : _r.applyMaxOrders, (_s !== null && _s !== void 0 ? _s : false)),
4426
- maxOrders: (_u = (_t = cartData) === null || _t === void 0 ? void 0 : _t.maxOrders, (_u !== null && _u !== void 0 ? _u : Infinity))
4426
+ applyMaxOrders: balance.applyMaxOrders,
4427
+ maxOrders: balance.maxOrders
4427
4428
  };
4428
4429
  this.balanceCustomerSubject.next(balanceData);
4429
4430
  }
@@ -6226,7 +6227,8 @@ let CartEcComponent = class CartEcComponent extends ComponentHelper {
6226
6227
  this.hidePrices = false;
6227
6228
  this.hideDiscounts = false;
6228
6229
  this.hideTaxes = false;
6229
- this.creditAccountShowPrices = false;
6230
+ this.creditAccountShowPrices = null;
6231
+ this.showPriceWithoutTaxes = true;
6230
6232
  this.toDecimal = (amount) => this.consts.toDecimal(amount);
6231
6233
  this.actualizarCantidad = (item, cantidad, stock, id) => {
6232
6234
  if (id) {
@@ -6310,10 +6312,11 @@ let CartEcComponent = class CartEcComponent extends ComponentHelper {
6310
6312
  this.cartService.promotions.subscribe(promotions => this.promotions = promotions);
6311
6313
  // console.log(this.cartService.getTaxes());
6312
6314
  this.channelConfigService.channelConfig$.subscribe(channel => {
6313
- var _a, _b, _c, _d, _e, _f;
6315
+ var _a, _b, _c, _d, _e, _f, _g, _h;
6314
6316
  this.hidePrices = (_b = (_a = channel) === null || _a === void 0 ? void 0 : _a.hidePrices, (_b !== null && _b !== void 0 ? _b : false));
6315
6317
  this.hideDiscounts = (_d = (_c = channel) === null || _c === void 0 ? void 0 : _c.hideDiscounts, (_d !== null && _d !== void 0 ? _d : false));
6316
6318
  this.hideTaxes = (_f = (_e = channel) === null || _e === void 0 ? void 0 : _e.hideTaxes, (_f !== null && _f !== void 0 ? _f : false));
6319
+ this.showPriceWithoutTaxes = (_h = (_g = channel) === null || _g === void 0 ? void 0 : _g.showPriceWithoutTaxes, (_h !== null && _h !== void 0 ? _h : false));
6317
6320
  if (this.hidePrices) {
6318
6321
  this.router.navigate(['/']);
6319
6322
  }
@@ -7211,12 +7214,13 @@ var __awaiter$b = (this && this.__awaiter) || function (thisArg, _arguments, P,
7211
7214
  });
7212
7215
  };
7213
7216
  let PaymentEcComponent = class PaymentEcComponent extends ComponentHelper {
7214
- constructor(renderer, toastr, paymentService, checkoutService) {
7217
+ constructor(renderer, toastr, paymentService, checkoutService, cartService) {
7215
7218
  super();
7216
7219
  this.renderer = renderer;
7217
7220
  this.toastr = toastr;
7218
7221
  this.paymentService = paymentService;
7219
7222
  this.checkoutService = checkoutService;
7223
+ this.cartService = cartService;
7220
7224
  this.methodDataSubject = new BehaviorSubject(null);
7221
7225
  this.loadingSubject = new BehaviorSubject(false);
7222
7226
  this.loading_internal = false;
@@ -7224,6 +7228,7 @@ let PaymentEcComponent = class PaymentEcComponent extends ComponentHelper {
7224
7228
  this.loading_internal_mp = false;
7225
7229
  this.method_data$ = this.methodDataSubject.asObservable();
7226
7230
  this.loading$ = this.loadingSubject.asObservable();
7231
+ this.allowAnyPaymentMethod = null;
7227
7232
  this.allData = () => (Object.assign(Object.assign({}, this.paymentService.getUserData().shippingAddress), this.paymentService.getShipmentData()));
7228
7233
  this.setError = (message) => {
7229
7234
  this.error = message;
@@ -7284,6 +7289,9 @@ let PaymentEcComponent = class PaymentEcComponent extends ComponentHelper {
7284
7289
  ngOnInit() {
7285
7290
  this.paymentService.initialize(this.step_id);
7286
7291
  this.checkoutService.asociatedData$.subscribe((data) => this.total_amount = (data.find(item => item.type == 'total')).amount);
7292
+ this.cartService.allowAnyPaymentMethod$.subscribe((value) => {
7293
+ this.allowAnyPaymentMethod = value;
7294
+ });
7287
7295
  this.ecOnInit();
7288
7296
  }
7289
7297
  setActive(e) {
@@ -7295,12 +7303,23 @@ let PaymentEcComponent = class PaymentEcComponent extends ComponentHelper {
7295
7303
  }
7296
7304
  e.target.classList.add("active");
7297
7305
  }
7306
+ // si cuenta corriente tiene la configuración allowAnyPaymentMethod en false, no se debe permitir otros metodos de pago.
7307
+ shouldDisplayMethod(method) {
7308
+ if (!method)
7309
+ return false;
7310
+ if (this.allowAnyPaymentMethod === null)
7311
+ return true;
7312
+ if (this.allowAnyPaymentMethod)
7313
+ return true;
7314
+ return this.isBalanceInAccount(method.code);
7315
+ }
7298
7316
  };
7299
7317
  PaymentEcComponent.ctorParameters = () => [
7300
7318
  { type: Renderer2 },
7301
7319
  { type: ToastService },
7302
7320
  { type: PaymentService },
7303
- { type: CheckoutService }
7321
+ { type: CheckoutService },
7322
+ { type: CartService }
7304
7323
  ];
7305
7324
  __decorate$S([
7306
7325
  Input()
@@ -7311,7 +7330,7 @@ __decorate$S([
7311
7330
  PaymentEcComponent = __decorate$S([
7312
7331
  Component({
7313
7332
  selector: 'app-payment-ec',
7314
- template: "<div class=\"container-fluid\" *ngIf=\"(paymentService.methods$ | async) as methods\">\n\n <div class=\"row\">\n <div class=\"col-12\">\n <div class=\"card \">\n <div class=\"card-header text-dark text-center\">\n <h4>{{ 'select-method' | translate }}</h4>\n <div class=\"btn-toolbar justify-content-center\" role=\"toolbar\" aria-label=\"Envios toolbar\">\n <div class=\"\" role=\"group\" aria-label=\"Grupo botones envio\">\n <div class=\"d-flex align-content-start justify-content-center flex-wrap\">\n <button type=\"button\" class=\"btn btn-outline-secondary mx-1 mb-1\"\n *ngFor=\"let method of methods; let x = index\"\n (click)=\"setMethod(method) ; setActive($event)\">\n {{ method.name | translate }}\n </button>\n </div>\n </div>\n </div>\n </div>\n <div class=\"card-body text-center\">\n <div class=\"row justify-content-center\" *ngIf=\"(method_data$ | async) as method\">\n <ng-container *ngIf=\"!loading_internal ; else loading\">\n <div class=\"method-container text-dark\" *ngIf=\"isMP(method.code)\">\n <p id=\"faqs\" class=\"qt px-5 \">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <app-mp-redirect-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [paymentServiceInst]=\"paymentService\" [allData]=\"allData()\"></app-mp-redirect-ec>\n </div>\n <div class=\"method-container text-dark text-left\" *ngIf=\"isMPTarjetaDeCredito(method.code)\">\n <div class=\"row\">\n <div class=\"col-12\">\n <p id=\"faqs\" class=\"qt px-5 \">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <div app-mp-credit-ec (ready)=\"verifyValidate()\" [public_key]=\"getPK(method)\"\n [user_data]=\"allData()\" [total_amount]=\"total_amount\">\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isRedirectRedsys(method.code)\">\n <div class=\"row\">\n <div class=\"col-12\">\n <ng-container\n *ngIf=\"!method.code.includes('bizum') && !method.code.includes('_out_')\">\n <app-redsys-redirect-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\">\n </app-redsys-redirect-ec>\n </ng-container>\n <ng-container\n *ngIf=\"method.code.includes('bizum') || method.code.includes('_out_')\">\n <app-redsys-redirect-out-ec (ready)=\"verifyValidate($event)\"\n [method]=\"method\" [user_data]=\"allData()\">\n </app-redsys-redirect-out-ec>\n </ng-container>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isRedirectCecaBank(method.code)\">\n <div class=\"row\">\n <div class=\"col-12\">\n <app-ceca-redirect-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\">\n </app-ceca-redirect-ec>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isPeyPalExpress(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-paypal-express-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [total_amount]=\"total_amount\">\n </app-paypal-express-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isMobbex(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-mobbex-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-mobbex-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isBancard(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-bancard-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-bancard-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isDecidir(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-decidir-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-decidir-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark\" *ngIf=\"isMethodOffline(method.code)\">\n <p id=\"faqs\" class=\"qt px-5\">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <div class=\"end-button\">\n <button class=\"btn comprar\" (click)=\"setLoading() && verifyValidate()\">{{\n ('pay-with-offline'| translate) }}</button>\n </div>\n <ng-container *ngIf=\"(loading$ | async) as load\">\n <div class=\"mt-2\" *ngIf=\"load\">\n <app-loading-inline-ec></app-loading-inline-ec>\n </div>\n </ng-container>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isCulqi(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <!-- <app-mobbex-ec (ready)=\"verifyValidate($event)\" [method]=\"method\" [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-mobbex-ec> -->\n <app-culqi-ec [apiKey]=\"getPKCulqi(method)\" [method]=\"method\"\n [amount]=\"total_amount\" [customStyle]=\"true\"\n (ready)=\"verifyValidate()\"></app-culqi-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isCatastro(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-bancard-catastro-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\"></app-bancard-catastro-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isBamboo(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-bamboo-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\"></app-bamboo-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark\" *ngIf=\"isBankTransfer(method.code)\">\n <div class=\"row px-0 description-cont\">\n <ng-container *ngFor=\"let line of method.description.split('\\r\\n'); let i=index\">\n <p [id]=\"'faqs-'+i\" [class]=\"'qt px-5 m-0 line-'+i\">{{ line }}</p>\n </ng-container>\n </div>\n <hr *ngIf=\"method.instructions\">\n <div *ngIf=\"method.instructions\" class=\"row px-0 instructions-cont mb-1\">\n <h5 class=\"instructions-title\">{{ ('instructions' | translate) }}</h5>\n <ng-container *ngFor=\"let line of method.instructions.split('\\r\\n'); let i=index\">\n <p [class]=\"'px-5 m-0 instructions-text line-'+i \">{{ line }}</p>\n </ng-container>\n </div>\n\n <div class=\"end-button\">\n <button class=\"btn comprar\" (click)=\"setLoading() && verifyValidate()\">{{\n ('pay-with-transfer'\n | translate) }}</button>\n </div>\n <ng-container *ngIf=\"(loading$ | async) as load\">\n <div class=\"mt-2\" *ngIf=\"load\">\n <app-loading-inline-ec></app-loading-inline-ec>\n </div>\n </ng-container>\n </div>\n <div class=\"method-container text-dark\" *ngIf=\"isPlaceToPay(method.code)\">\n <p id=\"faqs\" class=\"qt px-5 \">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <app-place-to-pay-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [paymentServiceInst]=\"paymentService\" [allData]=\"allData()\">\n </app-place-to-pay-ec>\n </div>\n <div class=\"method-container text-dark\" *ngIf=\"isBalanceInAccount(method.code)\">\n <div class=\"row px-0 description-cont\" *ngIf=\"method.description\">\n <ng-container *ngFor=\"let line of method.description.split('\\r\\n'); let i = index\">\n <p [id]=\"'cc-desc-'+i\" [class]=\"'qt px-5 m-0 line-'+i\">{{ line }}</p>\n </ng-container>\n </div>\n\n <hr *ngIf=\"method.instructions\">\n\n <div *ngIf=\"method.instructions\" class=\"row px-0 instructions-cont mb-1\">\n <h5 class=\"instructions-title\">{{ ('instructions' | translate) }}</h5>\n <ng-container *ngFor=\"let line of method.instructions.split('\\r\\n'); let i = index\">\n <p [class]=\"'px-5 m-0 instructions-text line-'+i \">{{ line }}</p>\n </ng-container>\n </div>\n\n <div class=\"end-button\">\n <button class=\"btn comprar\" (click)=\"setLoading() && verifyValidate()\">\n {{ 'pay-with' | translate }} {{ method.name }}\n </button>\n </div>\n <ng-container *ngIf=\"(loading$ | async) as load\">\n <div class=\"mt-2\" *ngIf=\"load\">\n <app-loading-inline-ec></app-loading-inline-ec>\n </div>\n </ng-container>\n </div>\n </ng-container>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>\n\n<ng-template #mercadoPago>\n <div class=\"row \">\n <div class=\"col-12 text-center\">\n <app-loading-inline-ec *ngIf=\"loading_internal_mp\"></app-loading-inline-ec>\n <form action=\"javascript:void(0)\" #formContainer></form>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loading>\n <app-loading-inline-ec></app-loading-inline-ec>\n</ng-template>",
7333
+ template: "<div class=\"container-fluid\" *ngIf=\"(paymentService.methods$ | async) as methods\">\n\n <div class=\"row\">\n <div class=\"col-12\">\n <div class=\"card \">\n <div class=\"card-header text-dark text-center\">\n <h4>{{ 'select-method' | translate }}</h4>\n <div class=\"btn-toolbar justify-content-center\" role=\"toolbar\" aria-label=\"Envios toolbar\">\n <div class=\"\" role=\"group\" aria-label=\"Grupo botones envio\">\n <div class=\"d-flex align-content-start justify-content-center flex-wrap\">\n <button type=\"button\" class=\"btn btn-outline-secondary mx-1 mb-1\"\n *ngFor=\"let method of methods; let x = index\"\n (click)=\"setMethod(method) ; setActive($event)\">\n {{ method.name | translate }}\n </button>\n </div>\n </div>\n </div>\n </div>\n <div class=\"card-body text-center\">\n <div class=\"row justify-content-center\" *ngIf=\"(method_data$ | async) as method\">\n <ng-container *ngIf=\"!loading_internal ; else loading\">\n <!-- cuenta corriente tiene una configuari\u00F3n de permitir o no otros metodos de pago -->\n <ng-container *ngIf=\"method && shouldDisplayMethod(method)\">\n <div class=\"method-container text-dark\" *ngIf=\"isMP(method.code)\">\n <p id=\"faqs\" class=\"qt px-5 \">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <app-mp-redirect-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [paymentServiceInst]=\"paymentService\" [allData]=\"allData()\"></app-mp-redirect-ec>\n </div>\n <div class=\"method-container text-dark text-left\" *ngIf=\"isMPTarjetaDeCredito(method.code)\">\n <div class=\"row\">\n <div class=\"col-12\">\n <p id=\"faqs\" class=\"qt px-5 \">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <div app-mp-credit-ec (ready)=\"verifyValidate()\" [public_key]=\"getPK(method)\"\n [user_data]=\"allData()\" [total_amount]=\"total_amount\">\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isRedirectRedsys(method.code)\">\n <div class=\"row\">\n <div class=\"col-12\">\n <ng-container\n *ngIf=\"!method.code.includes('bizum') && !method.code.includes('_out_')\">\n <app-redsys-redirect-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\">\n </app-redsys-redirect-ec>\n </ng-container>\n <ng-container\n *ngIf=\"method.code.includes('bizum') || method.code.includes('_out_')\">\n <app-redsys-redirect-out-ec (ready)=\"verifyValidate($event)\"\n [method]=\"method\" [user_data]=\"allData()\">\n </app-redsys-redirect-out-ec>\n </ng-container>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isRedirectCecaBank(method.code)\">\n <div class=\"row\">\n <div class=\"col-12\">\n <app-ceca-redirect-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\">\n </app-ceca-redirect-ec>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isPeyPalExpress(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-paypal-express-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [total_amount]=\"total_amount\">\n </app-paypal-express-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isMobbex(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-mobbex-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-mobbex-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isBancard(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-bancard-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-bancard-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isDecidir(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-decidir-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-decidir-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark\" *ngIf=\"isMethodOffline(method.code)\">\n <p id=\"faqs\" class=\"qt px-5\">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <div class=\"end-button\">\n <button class=\"btn comprar\" (click)=\"setLoading() && verifyValidate()\">{{\n ('pay-with-offline'| translate) }}</button>\n </div>\n <ng-container *ngIf=\"(loading$ | async) as load\">\n <div class=\"mt-2\" *ngIf=\"load\">\n <app-loading-inline-ec></app-loading-inline-ec>\n </div>\n </ng-container>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isCulqi(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <!-- <app-mobbex-ec (ready)=\"verifyValidate($event)\" [method]=\"method\" [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\">\n </app-mobbex-ec> -->\n <app-culqi-ec [apiKey]=\"getPKCulqi(method)\" [method]=\"method\"\n [amount]=\"total_amount\" [customStyle]=\"true\"\n (ready)=\"verifyValidate()\"></app-culqi-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isCatastro(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-bancard-catastro-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\"></app-bancard-catastro-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark text-start\" *ngIf=\"isBamboo(method.code)\">\n <div class=\"container\">\n <div class=\"row justify-content-center\">\n <div class=\"col-12\">\n <app-bamboo-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [user_data]=\"allData()\" [paymentServiceInst]=\"paymentService\"\n [total_amount]=\"total_amount\"></app-bamboo-ec>\n </div>\n </div>\n </div>\n </div>\n <div class=\"method-container text-dark\" *ngIf=\"isBankTransfer(method.code)\">\n <div class=\"row px-0 description-cont\">\n <ng-container *ngFor=\"let line of method.description.split('\\r\\n'); let i=index\">\n <p [id]=\"'faqs-'+i\" [class]=\"'qt px-5 m-0 line-'+i\">{{ line }}</p>\n </ng-container>\n </div>\n <hr *ngIf=\"method.instructions\">\n <div *ngIf=\"method.instructions\" class=\"row px-0 instructions-cont mb-1\">\n <h5 class=\"instructions-title\">{{ ('instructions' | translate) }}</h5>\n <ng-container *ngFor=\"let line of method.instructions.split('\\r\\n'); let i=index\">\n <p [class]=\"'px-5 m-0 instructions-text line-'+i \">{{ line }}</p>\n </ng-container>\n </div>\n \n <div class=\"end-button\">\n <button class=\"btn comprar\" (click)=\"setLoading() && verifyValidate()\">{{\n ('pay-with-transfer'\n | translate) }}</button>\n </div>\n <ng-container *ngIf=\"(loading$ | async) as load\">\n <div class=\"mt-2\" *ngIf=\"load\">\n <app-loading-inline-ec></app-loading-inline-ec>\n </div>\n </ng-container>\n </div>\n <div class=\"method-container text-dark\" *ngIf=\"isPlaceToPay(method.code)\">\n <p id=\"faqs\" class=\"qt px-5 \">{{ method.description }}</p>\n <p class=\"px-5\">{{ method.instructions }}</p>\n <app-place-to-pay-ec (ready)=\"verifyValidate($event)\" [method]=\"method\"\n [paymentServiceInst]=\"paymentService\" [allData]=\"allData()\">\n </app-place-to-pay-ec>\n </div>\n </ng-container>\n <div class=\"method-container text-dark\" *ngIf=\"isBalanceInAccount(method.code)\">\n <div class=\"row px-0 description-cont\" *ngIf=\"method.description\">\n <ng-container *ngFor=\"let line of method.description.split('\\r\\n'); let i = index\">\n <p [id]=\"'cc-desc-'+i\" [class]=\"'qt px-5 m-0 line-'+i\">{{ line }}</p>\n </ng-container>\n </div>\n\n <hr *ngIf=\"method.instructions\">\n\n <div *ngIf=\"method.instructions\" class=\"row px-0 instructions-cont mb-1\">\n <h5 class=\"instructions-title\">{{ ('instructions' | translate) }}</h5>\n <ng-container *ngFor=\"let line of method.instructions.split('\\r\\n'); let i = index\">\n <p [class]=\"'px-5 m-0 instructions-text line-'+i \">{{ line }}</p>\n </ng-container>\n </div>\n\n <div class=\"end-button\">\n <button class=\"btn comprar\" (click)=\"setLoading() && verifyValidate()\">\n {{ 'pay-with' | translate }} {{ method.name }}\n </button>\n </div>\n <ng-container *ngIf=\"(loading$ | async) as load\">\n <div class=\"mt-2\" *ngIf=\"load\">\n <app-loading-inline-ec></app-loading-inline-ec>\n </div>\n </ng-container>\n </div>\n </ng-container>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>\n\n<ng-template #mercadoPago>\n <div class=\"row \">\n <div class=\"col-12 text-center\">\n <app-loading-inline-ec *ngIf=\"loading_internal_mp\"></app-loading-inline-ec>\n <form action=\"javascript:void(0)\" #formContainer></form>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loading>\n <app-loading-inline-ec></app-loading-inline-ec>\n</ng-template>",
7315
7334
  providers: [PaymentService],
7316
7335
  styles: ["div.col-12 form{text-align:center}.option-container>div{margin-bottom:15px}@media only screen and (min-width:600px){.option-container{display:flex;justify-content:space-between;margin-top:20px}}.method-container{width:100%}.active{background-color:#000!important;color:#fff!important}.comprar{background:#000;color:#fff;display:inline-block;font-size:18px;font-weight:600;padding:10px 25px;text-decoration:none;text-transform:uppercase}"]
7317
7336
  })
@@ -8122,6 +8141,7 @@ let HeaderEcComponent = class HeaderEcComponent extends ComponentHelper {
8122
8141
  this.envetUrlTransparent = ["/home", "/"];
8123
8142
  this.params = {};
8124
8143
  this.toggled = false;
8144
+ this.balanceAttributes = null;
8125
8145
  this.locales = [];
8126
8146
  this.selectedLocale = 'ESP';
8127
8147
  this.hidePrices = false;
@@ -8713,7 +8733,7 @@ let ProductDetailService = class ProductDetailService {
8713
8733
  options && options.forEach(option => Object.keys(option).forEach(key => this.setOption(key, option[key])));
8714
8734
  };
8715
8735
  this.generateAsociatedDataFromVariants = () => {
8716
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
8736
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
8717
8737
  let asociated = {};
8718
8738
  if (this.isReady()) {
8719
8739
  asociated.stock = this.variants[0].stock;
@@ -8746,6 +8766,9 @@ let ProductDetailService = class ProductDetailService {
8746
8766
  taxIncluded: (_r = this.variants[0]) === null || _r === void 0 ? void 0 : _r.taxIncluded,
8747
8767
  taxCategory: (_s = this.variants[0]) === null || _s === void 0 ? void 0 : _s.taxCategory,
8748
8768
  };
8769
+ asociated.taxeAmount = ((_t = this.variants[0]) === null || _t === void 0 ? void 0 : _t.taxes) || undefined;
8770
+ asociated.taxRate = ((_u = this.variants[0]) === null || _u === void 0 ? void 0 : _u.taxRate) || undefined;
8771
+ asociated.priceWithoutTaxes = ((_v = this.variants[0]) === null || _v === void 0 ? void 0 : _v.priceWithoutTaxes) || undefined;
8749
8772
  this.asociatedDataSubject.next(asociated);
8750
8773
  };
8751
8774
  /**
@@ -9003,7 +9026,7 @@ let ProductDetailEcComponent = class ProductDetailEcComponent extends ComponentH
9003
9026
  this.owlOptions = {};
9004
9027
  this.showReviews = false;
9005
9028
  this.hidePrices = false;
9006
- this.creditAccountShowPrices = false;
9029
+ this.creditAccountShowPrices = null;
9007
9030
  this.addToCart = () => {
9008
9031
  this.quantity > 0 && this.productService.addToCart(this.quantity);
9009
9032
  };
@@ -9153,7 +9176,7 @@ let ProductEcComponent = class ProductEcComponent extends ComponentHelper {
9153
9176
  this.stock = 0;
9154
9177
  this.data = null;
9155
9178
  this.hidePrices = false;
9156
- this.creditAccountShowPrices = false;
9179
+ this.creditAccountShowPrices = null;
9157
9180
  /**
9158
9181
  * @description variable utilizada mutar de la vista de lista, a la de box.
9159
9182
  */
@@ -10219,18 +10242,29 @@ var __decorate$1f = (this && this.__decorate) || function (decorators, target, k
10219
10242
  return c > 3 && r && Object.defineProperty(target, key, r), r;
10220
10243
  };
10221
10244
  let PriceEcComponent = class PriceEcComponent extends ComponentHelper {
10222
- constructor(productsService) {
10245
+ constructor(productsService, channelConfigService) {
10223
10246
  super();
10224
10247
  this.productsService = productsService;
10248
+ this.channelConfigService = channelConfigService;
10225
10249
  this.priceSize = true;
10250
+ this.taxeAmount = 0;
10251
+ this.taxes = [];
10252
+ this.showTaxLegendOnly = false;
10253
+ this.disableTaxInfo = false;
10254
+ this.showPriceWithoutTaxes = true;
10226
10255
  this.ecOnConstruct();
10227
10256
  }
10228
10257
  ngOnInit() {
10258
+ this.channelConfigService.channelConfig$.subscribe(channel => {
10259
+ var _a;
10260
+ this.showPriceWithoutTaxes = (_a = channel) === null || _a === void 0 ? void 0 : _a.showPriceWithoutTaxes;
10261
+ });
10229
10262
  this.ecOnInit();
10230
10263
  }
10231
10264
  };
10232
10265
  PriceEcComponent.ctorParameters = () => [
10233
- { type: ProductsService }
10266
+ { type: ProductsService },
10267
+ { type: ChannelConfigService }
10234
10268
  ];
10235
10269
  __decorate$1f([
10236
10270
  Input()
@@ -10244,11 +10278,44 @@ __decorate$1f([
10244
10278
  __decorate$1f([
10245
10279
  Input()
10246
10280
  ], PriceEcComponent.prototype, "classStrSpacing", void 0);
10281
+ __decorate$1f([
10282
+ Input()
10283
+ ], PriceEcComponent.prototype, "basePrice", void 0);
10284
+ __decorate$1f([
10285
+ Input()
10286
+ ], PriceEcComponent.prototype, "taxeAmount", void 0);
10287
+ __decorate$1f([
10288
+ Input()
10289
+ ], PriceEcComponent.prototype, "taxes", void 0);
10290
+ __decorate$1f([
10291
+ Input()
10292
+ ], PriceEcComponent.prototype, "showTaxLegendOnly", void 0);
10293
+ __decorate$1f([
10294
+ Input()
10295
+ ], PriceEcComponent.prototype, "disableTaxInfo", void 0);
10296
+ __decorate$1f([
10297
+ Input()
10298
+ ], PriceEcComponent.prototype, "customPriceTemplate", void 0);
10299
+ __decorate$1f([
10300
+ Input()
10301
+ ], PriceEcComponent.prototype, "customSalePriceTemplate", void 0);
10302
+ __decorate$1f([
10303
+ Input()
10304
+ ], PriceEcComponent.prototype, "customSimplePriceTemplate", void 0);
10305
+ __decorate$1f([
10306
+ Input()
10307
+ ], PriceEcComponent.prototype, "customSimpleSalePriceTemplate", void 0);
10308
+ __decorate$1f([
10309
+ Input()
10310
+ ], PriceEcComponent.prototype, "customTaxTemplate", void 0);
10311
+ __decorate$1f([
10312
+ Input()
10313
+ ], PriceEcComponent.prototype, "customOnlyTaxLabelTemplate", void 0);
10247
10314
  PriceEcComponent = __decorate$1f([
10248
10315
  Component({
10249
10316
  selector: 'app-price-ec',
10250
- template: "<div *ngIf=\"saleprice; else onlyprice\" class=\"line-height-custom\">\n <div [class]=\"(priceSize ? 'price-sm':'price')\" *ngIf=\"price && price.split(' - ').length > 1; else simplePriceDel\">\n <del class=\"tachado\">\n {{ price.split(' - ')[0] | currency:productsService?.currency:'symbol' }}\n {{ price.split(' - ')[1] | currency:productsService?.currency:'symbol' }}\n </del>\n </div>\n <div [class]=\"(priceSize ? 'price-sm':'price')\" *ngIf=\"saleprice && saleprice.split(' - ').length > 1; else simpleSalePrice\">\n {{ saleprice.split(' - ')[0] | currency:productsService?.currency:'symbol' }}\n {{ saleprice.split(' - ')[1] | currency:productsService?.currency:'symbol' }}\n </div>\n</div>\n\n<ng-template #onlyprice>\n <div [class]=\"(priceSize ? 'price-sm':'price')\" *ngIf=\"price && price.split(' - ').length > 1; else simplePrice\">\n {{ price.split(' - ')[0] | currency:productsService?.currency:'symbol' }} - \n {{ price.split(' - ')[1] | currency:productsService?.currency:'symbol' }}\n </div>\n</ng-template>\n\n<ng-template #simplePrice>\n <div [class]=\"'uno line-height-custom ' + (priceSize ? 'price-sm':'price')\" >{{ price | currency:productsService?.currency:'symbol' }} </div>\n</ng-template>\n\n<ng-template #simplePriceDel>\n <div [class]=\"'dos line-height-custom ' + (priceSize ? 'price-sm':'price')\" ><span class=\"lnth\">{{ price | currency:productsService?.currency:'symbol' }}</span></div>\n</ng-template>\n\n<ng-template #simpleSalePrice>\n <div [class]=\"'tres line-height-custom ' + (priceSize ? 'price-sm':'price')\" >{{ saleprice | currency:productsService?.currency:'symbol' }} </div>\n</ng-template>",
10251
- styles: [".price-sm{font-size:13px}.price{font-size:18px}.lnth{text-decoration:line-through;color:gray}"]
10317
+ template: "<!-- Si hay templates personalizados, se proyectan -->\n<ng-container *ngIf=\"customSalePriceTemplate || customPriceTemplate; else defaultPriceBlock\">\n <ng-container *ngTemplateOutlet=\"customPriceTemplate || defaultPriceBlock\"></ng-container>\n</ng-container>\n\n<ng-template #defaultPriceBlock>\n <div *ngIf=\"saleprice; else onlyprice\" class=\"line-height-custom\">\n <div [class]=\"(priceSize ? 'price-sm' : 'price')\"\n *ngIf=\"price && price.split(' - ').length > 1; else simplePriceDel\">\n <del class=\"tachado\">\n {{ price.split(' - ')[0] | ecCurrencySymbol }}\n {{ price.split(' - ')[1] | ecCurrencySymbol }}\n </del>\n </div>\n <div [class]=\"(priceSize ? 'price-sm' : 'price')\"\n *ngIf=\"saleprice && saleprice.split(' - ').length > 1; else simpleSalePrice\">\n {{ saleprice.split(' - ')[0] | ecCurrencySymbol }}\n {{ saleprice.split(' - ')[1] | ecCurrencySymbol }}\n </div>\n </div>\n\n <ng-template #onlyprice>\n <div [class]=\"(priceSize ? 'price-sm' : 'price')\"\n *ngIf=\"price && price.split(' - ').length > 1; else simplePrice\">\n {{ price.split(' - ')[0] | ecCurrencySymbol }} -\n {{ price.split(' - ')[1] | ecCurrencySymbol }}\n </div>\n </ng-template>\n\n <ng-template #simplePrice>\n <ng-container *ngIf=\"customSimplePriceTemplate; else fallbackSimplePrice\">\n <ng-container *ngTemplateOutlet=\"customSimplePriceTemplate\"></ng-container>\n </ng-container>\n </ng-template>\n\n <ng-template #fallbackSimplePrice>\n <div [class]=\"'uno line-height-custom ' + (priceSize ? 'price-sm' : 'price')\">\n {{ price | ecCurrencySymbol }}\n </div>\n </ng-template>\n\n <ng-template #simplePriceDel>\n <div [class]=\"'dos line-height-custom ' + (priceSize ? 'price-sm' : 'price')\">\n <span class=\"lnth\">{{ price | ecCurrencySymbol }}</span>\n </div>\n </ng-template>\n\n <ng-template #simpleSalePrice>\n <ng-container *ngIf=\"customSimpleSalePriceTemplate; else fallbackSimpleSalePrice\">\n <ng-container *ngTemplateOutlet=\"customSimpleSalePriceTemplate\"></ng-container>\n </ng-container>\n </ng-template>\n\n <ng-template #fallbackSimpleSalePrice>\n <div [class]=\"'tres line-height-custom ' + (priceSize ? 'price-sm' : 'price')\">\n {{ saleprice | ecCurrencySymbol }}\n </div>\n </ng-template>\n</ng-template>\n\n<!-- Secci\u00F3n de impuestos -->\n<ng-container *ngIf=\"!disableTaxInfo && !showPriceWithoutTaxes\">\n <ng-container *ngIf=\"showTaxLegendOnly; else detailedTaxBlock\">\n <ng-container *ngIf=\"customOnlyTaxLabelTemplate; else defaultOnlyTaxLabelBlock\">\n <ng-container *ngTemplateOutlet=\"customOnlyTaxLabelTemplate\"></ng-container>\n </ng-container>\n <ng-template #defaultOnlyTaxLabelBlock>\n <p class=\"taxes-title\">{{'price-without-national-taxes' | translate }}: {{ basePrice | ecCurrencySymbol }}</p>\n </ng-template>\n </ng-container>\n\n <ng-template #detailedTaxBlock>\n <ng-container *ngIf=\"customTaxTemplate; else defaultTaxBlock\">\n <ng-container *ngTemplateOutlet=\"customTaxTemplate\"></ng-container>\n </ng-container>\n </ng-template>\n</ng-container>\n\n<ng-template #defaultTaxBlock>\n <div class=\"taxes-section\">\n <p class=\"taxes-title\">{{'price-without-national-taxes' | translate }}: {{ basePrice | ecCurrencySymbol }}</p>\n <ul class=\"taxes-list\">\n <li>\n {{ taxes.Name }}: {{ taxeAmount | ecCurrencySymbol }}\n </li>\n </ul>\n </div>\n</ng-template>",
10318
+ styles: [".price-sm{font-size:13px}.price{font-size:18px}.lnth{text-decoration:line-through;color:gray}.taxes-section{margin-top:.5rem;border-radius:.5rem;font-size:.95rem;color:#333;line-height:1.4;max-width:400px}.taxes-title{font-weight:500;margin-bottom:.2rem;font-size:.7rem;color:#222}.taxes-list{list-style-type:none;padding-left:0;margin:0}.taxes-list li{margin-bottom:.05rem;font-size:.65rem;display:flex;justify-content:space-between}"]
10252
10319
  })
10253
10320
  ], PriceEcComponent);
10254
10321
 
@@ -10728,8 +10795,7 @@ let OrdersEcComponent = class OrdersEcComponent extends ComponentHelper {
10728
10795
  this.channelConfigService = channelConfigService;
10729
10796
  this.loading = true;
10730
10797
  this.showImage = true;
10731
- this.showPrice = false;
10732
- this.creditAmountConfigured = false;
10798
+ this.creditAccountShowPrices = null;
10733
10799
  this.hidePrices = false;
10734
10800
  /**
10735
10801
  * @description name -> nombre de clave de valuesToSort; asc -> true: ascendente, false: descendente
@@ -10868,10 +10934,7 @@ let OrdersEcComponent = class OrdersEcComponent extends ComponentHelper {
10868
10934
  });
10869
10935
  this.ecOnInit();
10870
10936
  this.cartService.showPrice$.subscribe((showPrice) => {
10871
- this.showPrice = showPrice;
10872
- });
10873
- this.cartService.creditAmount$.subscribe((creditAmount) => {
10874
- this.creditAmountConfigured = creditAmount !== null;
10937
+ this.creditAccountShowPrices = showPrice;
10875
10938
  });
10876
10939
  this.channelConfigService.channelConfig$.subscribe(channel => {
10877
10940
  var _a, _b;
@@ -10892,7 +10955,7 @@ __decorate$1k([
10892
10955
  OrdersEcComponent = __decorate$1k([
10893
10956
  Component({
10894
10957
  selector: 'app-orders-ec',
10895
- template: "<div class=\"container-fluid\" id=\"ordersEcComponent\">\n <section id=\"orders\" class=\"w-100\" *ngIf=\"!loading; else loadingView\">\n <ng-container *ngIf=\"!hidePrices\">\n <div *ngIf=\"orders && orders.length; else noOrders\">\n <div class=\"row mb-1 border-bottom\">\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'number' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('number')\">{{ 'order' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'paymentState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('paymentState')\">{{ 'payment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'method' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('method')\">{{ 'shipment-method' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12 \">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'methodState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('methodState')\">\n {{ 'shipment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'date' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('date')\">{{ 'date' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'total' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('total')\">{{ 'total' | translate }}:</p>\n </div>\n </div>\n <div class=\"row item border-bottom py-2\" *ngFor=\"let order of orders\">\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold\">\n {{ order.number }}\n </h5>\n <!-- <ng-container *ngIf=\"showImage\">\n <ng-container *ngIf=\"order.items[0].product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth\" [src]=\"mediaUrl + order.items[0].product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"order.items[0].product.picturesdefault\" class=\"smc maxwidth\"\n [src]=\"mediaUrl + order.items[0].product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </ng-container> -->\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\" *ngIf=\"order.payments && order.payments.length > 0\">\n {{ order.payments[0].state | translate | titlecase }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n\n <p class=\"price\">\n {{ order.shipments[0].method.name }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ order.shipments[0].state | translate | titlecase }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <!-- <button class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</button> -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\"\n class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver\n seguimiento</a>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold text-nowrap\" *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </h5>\n <button class=\"btn px-0 w-100 btdetalle\" (click)=\"goToOrder(order)\">{{\n 'see-order' | translate }}</button>\n </div>\n </div>\n </div>\n </ng-container>\n </section>\n</div>\n\n<ng-template #noOrders>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #errorView>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h4>{{ 'orders-error' | translate }}</h4>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>",
10958
+ template: "<div class=\"container-fluid\" id=\"ordersEcComponent\">\n <section id=\"orders\" class=\"w-100\" *ngIf=\"!loading; else loadingView\">\n <ng-container *ngIf=\"!hidePrices\">\n <div *ngIf=\"orders && orders.length; else noOrders\">\n <div class=\"row mb-1 border-bottom\">\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'number' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('number')\">{{ 'order' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'paymentState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('paymentState')\">{{ 'payment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'method' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('method')\">{{ 'shipment-method' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12 \">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'methodState' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('methodState')\">\n {{ 'shipment-state' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'date' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('date')\">{{ 'date' | translate }}:</p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p [class]=\"'st dropdown-toggle cursor-pointer my-2 '+ (currentSort.name == 'total' ? 'applied ' + (!currentSort.asc ? 'asc' : 'desc') : '')\"\n (click)=\"sortOrders('total')\">{{ 'total' | translate }}:</p>\n </div>\n </div>\n <div class=\"row item border-bottom py-2\" *ngFor=\"let order of orders\">\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold\">\n {{ order.number }}\n </h5>\n <!-- <ng-container *ngIf=\"showImage\">\n <ng-container *ngIf=\"order.items[0].product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth\" [src]=\"mediaUrl + order.items[0].product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"order.items[0].product.picturesdefault\" class=\"smc maxwidth\"\n [src]=\"mediaUrl + order.items[0].product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </ng-container> -->\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\" *ngIf=\"order.payments && order.payments.length > 0\">\n {{ order.payments[0].state | translate | titlecase }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n\n <p class=\"price\">\n {{ order.shipments[0].method.name }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ order.shipments[0].state | translate | titlecase }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <!-- <button class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver seguimiento</button> -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\"\n class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver\n seguimiento</a>\n </div>\n <div class=\"col-lg-2 col-12\">\n <p class=\"price\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-lg-2 col-12\">\n <h5 class=\"fw-bold text-nowrap\" *ngIf=\"(showPrice !== null ? showPrice : true)\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </h5>\n <button class=\"btn px-0 w-100 btdetalle\" (click)=\"goToOrder(order)\">{{\n 'see-order' | translate }}</button>\n </div>\n </div>\n </div>\n </ng-container>\n </section>\n</div>\n\n<ng-template #noOrders>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #errorView>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h4>{{ 'orders-error' | translate }}</h4>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>",
10896
10959
  styles: ["#ordersEcComponent .btn.btdetalle{background-color:#000;color:#fff;border-color:#000;border-width:1px;border-radius:10px;padding:10px 0}#ordersEcComponent .btn.btdetalle:hover{background-color:#fff;color:#000;border-color:#000}.asc.dropdown-toggle::after{transform:rotate(180deg)}.applied.dropdown-toggle::after{color:#198754}"]
10897
10960
  })
10898
10961
  ], OrdersEcComponent);
@@ -10927,8 +10990,7 @@ let OrderEcComponent = class OrderEcComponent extends ComponentHelper {
10927
10990
  this.loading = true;
10928
10991
  this.numberOrder = null;
10929
10992
  this.allowRepeatOrders = false;
10930
- this.showPrice = false;
10931
- this.creditAmountConfigured = false;
10993
+ this.creditAccountShowPrices = null;
10932
10994
  this.hidePrices = false;
10933
10995
  this.hideDiscounts = false;
10934
10996
  this.hideTaxes = false;
@@ -10974,10 +11036,7 @@ let OrderEcComponent = class OrderEcComponent extends ComponentHelper {
10974
11036
  this.hideTaxes = (_f = (_e = config) === null || _e === void 0 ? void 0 : _e.hideTaxes, (_f !== null && _f !== void 0 ? _f : false));
10975
11037
  });
10976
11038
  this.cartService.showPrice$.subscribe((showPrice) => {
10977
- this.showPrice = showPrice;
10978
- });
10979
- this.cartService.creditAmount$.subscribe((creditAmount) => {
10980
- this.creditAmountConfigured = creditAmount !== null;
11039
+ this.creditAccountShowPrices = showPrice;
10981
11040
  });
10982
11041
  this.ecOnInit();
10983
11042
  }
@@ -11001,7 +11060,7 @@ __decorate$1l([
11001
11060
  OrderEcComponent = __decorate$1l([
11002
11061
  Component({
11003
11062
  selector: 'app-order-ec',
11004
- template: "<main class=\"py-5\" id=\"orderEcComponent\">\n <div class=\"container\">\n <div class=\"wrap\" *ngIf=\"!loading; else loadingView\">\n <div *ngIf=\"order; else noOrder\">\n\n <div class=\"row justify-content-between \">\n <div class=\"col-sm-auto col-12 font-brandon\">\n <h4 class=\"tit1 fw-bold\">{{ ('order' | translate) + ': ' + order.number }}</h4>\n </div>\n <ng-container *ngIf=\"order?.invoice\">\n <div class=\"col-sm col-12 font-brandon\">\n <a target=\"_blank\" [href]=\"consts.getUrlBase().slice(0, -1) + order.invoice\"\n class=\"btn btn-link btn-invoice\">\n <i class=\"fas fa-file-download me-1\"></i>\n {{ 'download' | translate }} {{ 'invoices' | translate | titlecase }}\n </a>\n </div>\n </ng-container>\n <a (click)=\"volver()\" class=\"col-auto text-end\">\n <button class=\"btn btvolver bg-gray text-white\">{{ 'back-to-orders' | translate }}</button>\n </a>\n </div>\n\n <section id=\"orders\">\n <div class=\"row pt-2\">\n <div class=\"col-md-2 col-12\">\n <p class=\"st\">{{ 'payment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'payment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0]?.method?.name | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].method.name }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\"\n class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver\n seguimiento</a>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'date' | translate }}:</p>\n <p class=\"\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\" *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n <p class=\"st\">{{ 'total' | translate }}:</p>\n <h5 class=\"fw-bold\">\n {{ (order.totals.total) | ecCurrencySymbol}}\n\n </h5>\n </div>\n </div>\n </section>\n\n <div class=\"text-end mt-3\" *ngIf=\"!hidePrices && allowRepeatOrders\">\n <button class=\"btn btn-primary mb-2\" (click)=\"repeatOrder()\">\n {{ 'repeat-order' | translate }}\n </button>\n </div>\n\n <div class=\"container py-3 border-top border-bottom\">\n <div *ngIf=\"order.items.length; else noProducts\" class=\"row\">\n <div class=\"col-2 font-sm font-brandon d-none d-md-block\">\n {{ 'product' | translate | uppercase }}\n </div>\n <div class=\"col-4 font-sm font-brandon d-none d-md-block\">\n {{ 'description' | translate | uppercase }}\n </div>\n <div id=\"colLots\" *ngIf=\"ordersService.channelConfig.applyOrderLot\"\n class=\"col-1 font-sm font-brandon d-none d-md-block\">\n <!-- {{ 'description' | translate | uppercase }} -->\n {{ 'lots' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-center font-sm font-brandon d-none d-md-block\"\n *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n {{ 'unit-price' | translate | uppercase }}\n </div>\n <div class=\"col-1 text-center font-sm font-brandon d-none d-md-block\">\n {{ 'quantity' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-end font-sm font-brandon d-none d-md-block\"\n *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n {{ 'total' | translate | uppercase }}\n </div>\n </div>\n <ng-container *ngFor=\"let item of order.items; let i = index\">\n <div class=\"row cart-items\">\n <div class=\"col-5 col-md-2 py-2\">\n <ng-container *ngIf=\"item.product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth img-fluid rounded-custom \"\n [src]=\"consts.mediaUrl() + item.product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"item.product.picturesdefault\"\n class=\"smc maxwidth img-fluid rounded-custom\"\n [src]=\"consts.mediaUrl() + item.product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </div>\n <div\n class=\"col-md-4 col-7 flex-column flex-md-row justify-content-start d-flex align-items-center\">\n <p class=\"font-brandon d-flex w-100 mb-0\">\n {{ item.product.name }} (Cod:{{ item.product.variants[0].code }})\n </p>\n </div>\n <div class=\"col-md-1 col-1 flex-column flex-md-row justify-content-start d-flex align-items-center\"\n *ngIf=\"ordersService.channelConfig.applyOrderLot\">\n <input type=\"button\" class=\"btn btn-primary btnSeguir m-0 text-center\" type=\"button\"\n [attr.data-bs-toggle]=\"'collapse'\" [attr.data-bs-target]=\"'#collapseExample'+i\"\n aria-expanded=\"false\" [attr.aria-controls]=\"'collapseExample'+i\"\n value=\"{{ 'see' | translate | uppercase }}\">\n </div>\n <div class=\"container d-md-none\">\n <div class=\"row\">\n <div class=\"col-4\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-4 font-xl\" *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n <p class=\"text-center w-100 m-0\"> {{ (item.product.variants[0].saleprice ?\n item.product.variants[0].saleprice : item.product.variants[0].price) |\n ecCurrencySymbol}}</p>\n </div>\n <div class=\"col-4 font-xl\" *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n <p class=\"text-center w-100 m-0\"> {{ ((item.product.variants[0].saleprice ?\n item.product.variants[0].saleprice : item.product.variants[0].price) *\n item.quantity) | ecCurrencySymbol}}</p>\n </div>\n </div>\n </div>\n\n <div class=\"col-2 d-none d-md-flex align-items-center\"\n *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n <p class=\"text-center w-100 m-0\">\n {{ (item.product.variants[0].saleprice ? item.product.variants[0].saleprice :\n item.product.variants[0].price) | ecCurrencySymbol}}\n </p>\n </div>\n <div class=\"col-1 d-none d-md-flex align-items-center\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\"\n *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n <p class=\"text-end w-100 m-0\">\n {{ ((item.product.variants[0].saleprice ? item.product.variants[0].saleprice :\n item.product.variants[0].price) * item.quantity) | ecCurrencySymbol}}</p>\n </div>\n <div class=\"collapse\" [attr.id]=\"'collapseExample'+i\">\n <div class=\"card card-body\">\n <table class=\"table table-striped\">\n <thead>\n <tr>\n <th scope=\"col\">#</th>\n <th scope=\"col\">Estado</th>\n <th scope=\"col\">Cantidad</th>\n <th scope=\"col\">Fecha Solicitada</th>\n <th scope=\"col\">Fecha Estimada</th>\n <th scope=\"col\">Sede</th>\n <th scope=\"col\">Nota</th>\n <th scope=\"col\">Total Lote</th>\n </tr>\n </thead>\n <tbody>\n <ng-container *ngFor=\"let lot of item.orderItemLot\">\n <tr>\n <th scope=\"row\">{{lot.id}}</th>\n <td>{{lot.lot_status}}</td>\n <td>{{lot.quantity}}</td>\n <td>{{ toDate(lot.date_request, 'DD/MM/YYYY') | translate }}</td>\n <td *ngIf=\"lot.date_deliver; else sinFechaEstimada\">{{\n toDate(lot.date_deliver, 'DD/MM/YYYY') | translate }}</td>\n <ng-template #sinFechaEstimada>\n <td>Pendiente</td>\n </ng-template>\n <td>{{lot.shipping_address_name}}</td>\n <td>{{lot.notes}}</td>\n <td>{{lot.total_lot | ecCurrencySymbol}}</td>\n </tr>\n </ng-container>\n </tbody>\n </table>\n </div>\n </div>\n </div>\n\n </ng-container>\n </div>\n\n <div class=\"container\">\n <div class=\"row\">\n <div class=\"col-12 col-md-6\"></div>\n <div class=\"col-12 col-md-6\" *ngIf=\"(creditAmountConfigured ? showPrice : true)\">\n <div class=\"row py-4\">\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'total-products' |\n translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.items) | ecCurrencySymbol }}\n </div>\n\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'shipment' |\n translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.shipping || '0') | ecCurrencySymbol }}\n\n </div>\n\n <div *ngIf=\"!hideDiscounts && order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'discount' |\n translate }}</div>\n <div *ngIf=\"!hideDiscounts && order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom text-end text-end\">\n {{ (order.totals.promotion) | ecCurrencySymbol }}</div>\n\n <div *ngIf=\"!hideTaxes && order.totals.taxes && order.totals.taxes != 0 \"\n class=\"col-6 font-brandon font-md text-gray border-bottom \">\n {{ 'taxes' | translate }}</div>\n <div *ngIf=\"!hideTaxes && order.totals.taxes && order.totals.taxes != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.taxes) | ecCurrencySymbol }}</div>\n\n <div class=\"col-6 font-brandon font-md\">{{ 'total' | translate | uppercase }}</div>\n <div class=\"col-6 font-brandon font-md text-end\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n</main>\n\n<ng-template #noOrder>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>",
11063
+ template: "<main class=\"py-5\" id=\"orderEcComponent\">\n <div class=\"container\">\n <div class=\"wrap\" *ngIf=\"!loading; else loadingView\">\n <div *ngIf=\"order; else noOrder\">\n\n <div class=\"row justify-content-between \">\n <div class=\"col-sm-auto col-12 font-brandon\">\n <h4 class=\"tit1 fw-bold\">{{ ('order' | translate) + ': ' + order.number }}</h4>\n </div>\n <ng-container *ngIf=\"order?.invoice\">\n <div class=\"col-sm col-12 font-brandon\">\n <a target=\"_blank\" [href]=\"consts.getUrlBase().slice(0, -1) + order.invoice\"\n class=\"btn btn-link btn-invoice\">\n <i class=\"fas fa-file-download me-1\"></i>\n {{ 'download' | translate }} {{ 'invoices' | translate | titlecase }}\n </a>\n </div>\n </ng-container>\n <a (click)=\"volver()\" class=\"col-auto text-end\">\n <button class=\"btn btvolver bg-gray text-white\">{{ 'back-to-orders' | translate }}</button>\n </a>\n </div>\n\n <section id=\"orders\">\n <div class=\"row pt-2\">\n <div class=\"col-md-2 col-12\">\n <p class=\"st\">{{ 'payment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-state' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].state | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'payment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.payments[0]?.method?.name | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'shipment-method' | translate }}:</p>\n <p class=\"\">\n {{ order.shipments[0].method.name }}\n </p>\n <!-- ACA DEBERIA IR EL LINK DE SEGUIMIENTO -->\n <a *ngIf=\"order.tracking\" [href]=\"order.tracking\"\n class=\"btn btn-outline-dark btnLogout px-3 py-1 font-size-10 w-auto btn-sm\">Ver\n seguimiento</a>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\">\n <p class=\"st\">{{ 'date' | translate }}:</p>\n <p class=\"\">\n {{ toDate(order.checkoutCompletedAt, 'DD/MM/YYYY') | translate }}<br>\n {{ toDate(order.checkoutCompletedAt, 'h:mm:ss a') | translate }}\n </p>\n </div>\n <div class=\"col-md-2 col-12 font-brandon\" *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n <p class=\"st\">{{ 'total' | translate }}:</p>\n <h5 class=\"fw-bold\">\n {{ (order.totals.total) | ecCurrencySymbol}}\n\n </h5>\n </div>\n </div>\n </section>\n\n <div class=\"text-end mt-3\" *ngIf=\"!hidePrices && allowRepeatOrders\">\n <button class=\"btn btn-primary mb-2\" (click)=\"repeatOrder()\">\n {{ 'repeat-order' | translate }}\n </button>\n </div>\n\n <div class=\"container py-3 border-top border-bottom\">\n <div *ngIf=\"order.items.length; else noProducts\" class=\"row\">\n <div class=\"col-2 font-sm font-brandon d-none d-md-block\">\n {{ 'product' | translate | uppercase }}\n </div>\n <div class=\"col-4 font-sm font-brandon d-none d-md-block\">\n {{ 'description' | translate | uppercase }}\n </div>\n <div id=\"colLots\" *ngIf=\"ordersService.channelConfig.applyOrderLot\"\n class=\"col-1 font-sm font-brandon d-none d-md-block\">\n <!-- {{ 'description' | translate | uppercase }} -->\n {{ 'lots' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-center font-sm font-brandon d-none d-md-block\"\n *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n {{ 'unit-price' | translate | uppercase }}\n </div>\n <div class=\"col-1 text-center font-sm font-brandon d-none d-md-block\">\n {{ 'quantity' | translate | uppercase }}\n </div>\n <div class=\"col-2 text-end font-sm font-brandon d-none d-md-block\"\n *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n {{ 'total' | translate | uppercase }}\n </div>\n </div>\n <ng-container *ngFor=\"let item of order.items; let i = index\">\n <div class=\"row cart-items\">\n <div class=\"col-5 col-md-2 py-2\">\n <ng-container *ngIf=\"item.product.variants[0]?.images?.length ; else defaultpicture\">\n <img class=\"smc maxwidth img-fluid rounded-custom \"\n [src]=\"consts.mediaUrl() + item.product.variants[0].images[0]\" alt=\"\">\n </ng-container>\n <ng-template #defaultpicture>\n <img *ngIf=\"item.product.picturesdefault\"\n class=\"smc maxwidth img-fluid rounded-custom\"\n [src]=\"consts.mediaUrl() + item.product.picturesdefault[0]\" alt=\"\">\n </ng-template>\n </div>\n <div\n class=\"col-md-4 col-7 flex-column flex-md-row justify-content-start d-flex align-items-center\">\n <p class=\"font-brandon d-flex w-100 mb-0\">\n {{ item.product.name }} (Cod:{{ item.product.variants[0].code }})\n </p>\n </div>\n <div class=\"col-md-1 col-1 flex-column flex-md-row justify-content-start d-flex align-items-center\"\n *ngIf=\"ordersService.channelConfig.applyOrderLot\">\n <input type=\"button\" class=\"btn btn-primary btnSeguir m-0 text-center\" type=\"button\"\n [attr.data-bs-toggle]=\"'collapse'\" [attr.data-bs-target]=\"'#collapseExample'+i\"\n aria-expanded=\"false\" [attr.aria-controls]=\"'collapseExample'+i\"\n value=\"{{ 'see' | translate | uppercase }}\">\n </div>\n <div class=\"container d-md-none\">\n <div class=\"row\">\n <div class=\"col-4\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-4 font-xl\" *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n <p class=\"text-center w-100 m-0\"> {{ (item.product.variants[0].saleprice ?\n item.product.variants[0].saleprice : item.product.variants[0].price) |\n ecCurrencySymbol}}</p>\n </div>\n <div class=\"col-4 font-xl\" *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n <p class=\"text-center w-100 m-0\"> {{ ((item.product.variants[0].saleprice ?\n item.product.variants[0].saleprice : item.product.variants[0].price) *\n item.quantity) | ecCurrencySymbol}}</p>\n </div>\n </div>\n </div>\n\n <div class=\"col-2 d-none d-md-flex align-items-center\"\n *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n <p class=\"text-center w-100 m-0\">\n {{ (item.product.variants[0].saleprice ? item.product.variants[0].saleprice :\n item.product.variants[0].price) | ecCurrencySymbol}}\n </p>\n </div>\n <div class=\"col-1 d-none d-md-flex align-items-center\">\n <p class=\"text-center w-100 m-0\"> {{ item.quantity }}</p>\n </div>\n <div class=\"col-2 d-none d-md-flex align-items-center\"\n *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n <p class=\"text-end w-100 m-0\">\n {{ ((item.product.variants[0].saleprice ? item.product.variants[0].saleprice :\n item.product.variants[0].price) * item.quantity) | ecCurrencySymbol}}</p>\n </div>\n <div class=\"collapse\" [attr.id]=\"'collapseExample'+i\">\n <div class=\"card card-body\">\n <table class=\"table table-striped\">\n <thead>\n <tr>\n <th scope=\"col\">#</th>\n <th scope=\"col\">Estado</th>\n <th scope=\"col\">Cantidad</th>\n <th scope=\"col\">Fecha Solicitada</th>\n <th scope=\"col\">Fecha Estimada</th>\n <th scope=\"col\">Sede</th>\n <th scope=\"col\">Nota</th>\n <th scope=\"col\">Total Lote</th>\n </tr>\n </thead>\n <tbody>\n <ng-container *ngFor=\"let lot of item.orderItemLot\">\n <tr>\n <th scope=\"row\">{{lot.id}}</th>\n <td>{{lot.lot_status}}</td>\n <td>{{lot.quantity}}</td>\n <td>{{ toDate(lot.date_request, 'DD/MM/YYYY') | translate }}</td>\n <td *ngIf=\"lot.date_deliver; else sinFechaEstimada\">{{\n toDate(lot.date_deliver, 'DD/MM/YYYY') | translate }}</td>\n <ng-template #sinFechaEstimada>\n <td>Pendiente</td>\n </ng-template>\n <td>{{lot.shipping_address_name}}</td>\n <td>{{lot.notes}}</td>\n <td>{{lot.total_lot | ecCurrencySymbol}}</td>\n </tr>\n </ng-container>\n </tbody>\n </table>\n </div>\n </div>\n </div>\n\n </ng-container>\n </div>\n\n <div class=\"container\">\n <div class=\"row\">\n <div class=\"col-12 col-md-6\"></div>\n <div class=\"col-12 col-md-6\" *ngIf=\"(creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n <div class=\"row py-4\">\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'total-products' |\n translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.items) | ecCurrencySymbol }}\n </div>\n\n <div class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'shipment' |\n translate }}</div>\n <div class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.shipping || '0') | ecCurrencySymbol }}\n\n </div>\n\n <div *ngIf=\"!hideDiscounts && order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom \">{{ 'discount' |\n translate }}</div>\n <div *ngIf=\"!hideDiscounts && order.totals.promotion && order.totals.promotion != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom text-end text-end\">\n {{ (order.totals.promotion) | ecCurrencySymbol }}</div>\n\n <div *ngIf=\"!hideTaxes && order.totals.taxes && order.totals.taxes != 0 \"\n class=\"col-6 font-brandon font-md text-gray border-bottom \">\n {{ 'taxes' | translate }}</div>\n <div *ngIf=\"!hideTaxes && order.totals.taxes && order.totals.taxes != 0\"\n class=\"col-6 font-brandon font-md text-gray border-bottom text-end\">\n {{ (order.totals.taxes) | ecCurrencySymbol }}</div>\n\n <div class=\"col-6 font-brandon font-md\">{{ 'total' | translate | uppercase }}</div>\n <div class=\"col-6 font-brandon font-md text-end\">\n {{ (order.totals.total) | ecCurrencySymbol }}\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n</main>\n\n<ng-template #noOrder>\n <div class=\"w-100 h-50\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <h5>{{ 'no-orders' | translate }}</h5>\n </div>\n </div>\n</ng-template>\n\n<ng-template #loadingView>\n <div class=\"w-100 h-50 py-5\">\n <div class=\"d-flex flex-row justify-content-center align-items-center text-center\">\n <app-loading-full-ec></app-loading-full-ec>\n </div>\n </div>\n</ng-template>",
11005
11064
  styles: [".maxwidth{max-width:100px}"]
11006
11065
  })
11007
11066
  ], OrderEcComponent);
@@ -11874,25 +11933,25 @@ let DetailCheckoutBlockEcComponent = class DetailCheckoutBlockEcComponent extend
11874
11933
  this.data = null;
11875
11934
  this.discountTotal = 0;
11876
11935
  this.couponTotal = 0;
11877
- this.showPrice = false;
11878
- this.creditAmountConfigured = false;
11936
+ this.creditAccountShowPrices = null;
11879
11937
  this.hideDiscounts = false;
11880
11938
  this.hideTaxes = false;
11939
+ this.showPriceWithoutTaxes = true;
11881
11940
  this.getIcon = (data_item) => {
11882
11941
  switch (data_item.type) {
11883
- case 'coupon': return 'fas fa-ticket-alt fa-3x';
11884
- case 'discount': return 'fas fa-tags fa-3x';
11885
- case 'shipment': return 'fas fa-shipping-fast fa-3x';
11886
- case 'subtotal': return 'fas fa-boxes fa-3x';
11887
- case 'taxes': return 'fas fa-file-invoice-dollar fa-3x';
11888
- case 'total': return 'fas fa-shopping-basket fa-3x';
11889
- default: return 'fas fa-tags fa-3x';
11942
+ case 'coupon': return 'fas fa-ticket-alt fa-2x';
11943
+ case 'discount': return 'fas fa-tags fa-2x';
11944
+ case 'shipment': return 'fas fa-shipping-fast fa-2x';
11945
+ case 'subtotal': return 'fas fa-boxes fa-2x';
11946
+ case 'taxes': return 'fas fa-file-invoice-dollar fa-2x';
11947
+ case 'total': return 'fas fa-shopping-basket fa-2x';
11948
+ default: return 'fas fa-tags fa-2x';
11890
11949
  }
11891
11950
  };
11892
11951
  this.getIcon2 = (data_type) => {
11893
11952
  switch (data_type) {
11894
- case 'coupon': return 'fas fa-ticket-alt fa-3x';
11895
- case 'discount': return 'fas fa-tags fa-3x';
11953
+ case 'coupon': return 'fas fa-ticket-alt fa-2x';
11954
+ case 'discount': return 'fas fa-tags fa-2x';
11896
11955
  }
11897
11956
  };
11898
11957
  this.ecOnConstruct();
@@ -11903,15 +11962,13 @@ let DetailCheckoutBlockEcComponent = class DetailCheckoutBlockEcComponent extend
11903
11962
  this.calcularTotales();
11904
11963
  this.ecOnInit();
11905
11964
  this.cartService.showPrice$.subscribe((showPrice) => {
11906
- this.showPrice = showPrice;
11907
- });
11908
- this.cartService.creditAmount$.subscribe((creditAmount) => {
11909
- this.creditAmountConfigured = creditAmount !== null;
11965
+ this.creditAccountShowPrices = showPrice;
11910
11966
  });
11911
11967
  this.channelConfigService.channelConfig$.subscribe(channel => {
11912
- var _a, _b, _c, _d;
11968
+ var _a, _b, _c, _d, _e, _f;
11913
11969
  this.hideDiscounts = (_b = (_a = channel) === null || _a === void 0 ? void 0 : _a.hideDiscounts, (_b !== null && _b !== void 0 ? _b : false));
11914
11970
  this.hideTaxes = (_d = (_c = channel) === null || _c === void 0 ? void 0 : _c.hideTaxes, (_d !== null && _d !== void 0 ? _d : false));
11971
+ this.showPriceWithoutTaxes = (_f = (_e = channel) === null || _e === void 0 ? void 0 : _e.showPriceWithoutTaxes, (_f !== null && _f !== void 0 ? _f : false));
11915
11972
  });
11916
11973
  }
11917
11974
  calcularTotales() {
@@ -11924,6 +11981,12 @@ let DetailCheckoutBlockEcComponent = class DetailCheckoutBlockEcComponent extend
11924
11981
  .reduce((acc, curr) => acc + curr.amount, 0);
11925
11982
  }
11926
11983
  }
11984
+ getTypeLabel(type) {
11985
+ if (type === 'taxes') {
11986
+ return this.showPriceWithoutTaxes ? 'taxes' : 'national-taxes';
11987
+ }
11988
+ return type;
11989
+ }
11927
11990
  };
11928
11991
  DetailCheckoutBlockEcComponent.ctorParameters = () => [
11929
11992
  { type: CheckoutService },
@@ -11936,7 +11999,7 @@ __decorate$1u([
11936
11999
  DetailCheckoutBlockEcComponent = __decorate$1u([
11937
12000
  Component({
11938
12001
  selector: 'app-detail-checkout-block-ec',
11939
- template: "<div id=\"appDetailCheckoutBlockEc\" class=\"d-flex flex-row w-100 justify-content-center flex-wrap\"\n *ngIf=\"data && (creditAmountConfigured ? showPrice : true)\">\n <ng-container *ngFor=\"let item of data; let i = index\">\n <ng-container *ngIf=\"item.type != 'discount' && item.type != 'coupon'\">\n <div class=\"d-flex flex-column justify-content-center mx-sm-3 mx-2 text-center mb-4 resumen\">\n <i ngClass=\"mb-2 colorIconoCheckout\" [class]=\"getIcon(item)\"></i>\n <strong class=\"text-center w-100 font-brandon font-md mb-1\">{{ item.type | translate }}</strong>\n <span class=\"text-center w-100 font-brandon font-md text-gray\">{{ (item.amount != 0 ) ? (item.amount |\n ecCurrencySymbol) : ('free' | translate) }}</span>\n </div>\n </ng-container>\n\n\n <!-- Mostrar total de descuentos -->\n <div class=\"d-flex flex-column justify-content-center mx-sm-3 mx-2 text-center mb-4 resumen\"\n *ngIf=\"!hideDiscounts && this.discountTotal != 0 && i === 1\">\n <i ngClass=\"mb-2 colorIconoCheckout\" [class]=\"getIcon2('discount')\"></i>\n <strong class=\"text-center w-100 font-brandon font-md mb-1\">Descuento</strong>\n <span class=\"text-center w-100 font-brandon font-md text-gray\">{{ (this.discountTotal | ecCurrencySymbol)\n }}</span>\n </div>\n\n <!-- Mostrar total de cupones -->\n <div class=\"d-flex flex-column justify-content-center mx-sm-3 mx-2 text-center mb-4 resumen\"\n *ngIf=\"!hideDiscounts && this.couponTotal != 0 && i === 1\">\n <i ngClass=\"mb-2 colorIconoCheckout\" [class]=\"getIcon2('coupon')\"></i>\n <strong class=\"text-center w-100 font-brandon font-md mb-1\">Cupon</strong>\n <span class=\"text-center w-100 font-brandon font-md text-gray\">{{(this.couponTotal| ecCurrencySymbol)\n }}</span>\n </div>\n </ng-container>\n</div>",
12002
+ template: "<div id=\"appDetailCheckoutBlockEc\" class=\"d-flex flex-row w-100 justify-content-center flex-wrap\"\n *ngIf=\"data && (creditAccountShowPrices !== null ? creditAccountShowPrices : true)\">\n <ng-container *ngFor=\"let item of data; let i = index\">\n <ng-container *ngIf=\"item.type != 'discount' && item.type != 'coupon'\">\n <div class=\"d-flex flex-column justify-content-center mx-sm-3 mx-2 text-center mb-4 resumen\">\n <i ngClass=\"mb-2 colorIconoCheckout\" [class]=\"getIcon(item)\"></i>\n <strong class=\"text-center w-100 font-brandon font-md mb-1\">\n {{ getTypeLabel(item.type) | translate }}\n </strong>\n <span class=\"text-center w-100 font-brandon font-md text-gray\">{{ (item.amount != 0 ) ? (item.amount |\n ecCurrencySymbol) : ('free' | translate) }}</span>\n </div>\n </ng-container>\n\n\n <!-- Mostrar total de descuentos -->\n <div class=\"d-flex flex-column justify-content-center mx-sm-3 mx-2 text-center mb-4 resumen\"\n *ngIf=\"!hideDiscounts && this.discountTotal != 0 && i === 1\">\n <i ngClass=\"mb-2 colorIconoCheckout\" [class]=\"getIcon2('discount')\"></i>\n <strong class=\"text-center w-100 font-brandon font-md mb-1\">Descuento</strong>\n <span class=\"text-center w-100 font-brandon font-md text-gray\">{{ (this.discountTotal | ecCurrencySymbol)\n }}</span>\n </div>\n\n <!-- Mostrar total de cupones -->\n <div class=\"d-flex flex-column justify-content-center mx-sm-3 mx-2 text-center mb-4 resumen\"\n *ngIf=\"!hideDiscounts && this.couponTotal != 0 && i === 1\">\n <i ngClass=\"mb-2 colorIconoCheckout\" [class]=\"getIcon2('coupon')\"></i>\n <strong class=\"text-center w-100 font-brandon font-md mb-1\">Cupon</strong>\n <span class=\"text-center w-100 font-brandon font-md text-gray\">{{(this.couponTotal| ecCurrencySymbol)\n }}</span>\n </div>\n </ng-container>\n</div>",
11940
12003
  styles: [""]
11941
12004
  })
11942
12005
  ], DetailCheckoutBlockEcComponent);
@@ -15735,6 +15798,7 @@ let SidebarEcComponent = class SidebarEcComponent {
15735
15798
  this.variantsToShow = ['TALLE', 'COLOR'];
15736
15799
  this.hideDiscounts = false;
15737
15800
  this.hideTaxes = false;
15801
+ this.creditAccountShowPrices = null;
15738
15802
  this.actualizarCantidad = (item, cantidad, stock, id) => {
15739
15803
  if (id) {
15740
15804
  const elem = document.getElementById(id);
@@ -15802,6 +15866,9 @@ let SidebarEcComponent = class SidebarEcComponent {
15802
15866
  this.hideDiscounts = (_b = (_a = channel) === null || _a === void 0 ? void 0 : _a.hideDiscounts, (_b !== null && _b !== void 0 ? _b : false));
15803
15867
  this.hideTaxes = (_d = (_c = channel) === null || _c === void 0 ? void 0 : _c.hideTaxes, (_d !== null && _d !== void 0 ? _d : false));
15804
15868
  });
15869
+ this.cartService.showPrice$.subscribe((showPrice) => {
15870
+ this.creditAccountShowPrices = showPrice;
15871
+ });
15805
15872
  }
15806
15873
  redirectDetailProduct(product) {
15807
15874
  let variant = product.variants[0];