ng-easycommerce 0.0.632 → 0.0.633

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 (32) hide show
  1. package/README.md +3 -0
  2. package/assets/ec-i18n/ct.json +3 -1
  3. package/assets/ec-i18n/en.json +3 -1
  4. package/assets/ec-i18n/es.json +6 -4
  5. package/assets/ec-i18n/fr.json +3 -1
  6. package/assets/ec-i18n/gl.json +3 -1
  7. package/assets/ec-i18n/pr.json +3 -1
  8. package/bundles/ng-easycommerce.umd.js +62 -41
  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/auth-ec/register-form-ec/register-form-ec.component.js +3 -3
  13. package/esm2015/lib/ec-component/auth-ec/register-wholesaler-form-ec/register-wholesaler-form-ec.component.js +3 -3
  14. package/esm2015/lib/ec-component/checkout-ec/success-ec/success-ec.component.js +15 -3
  15. package/esm2015/lib/ec-component/product-detail-ec/product-detail-ec.component.js +4 -3
  16. package/esm2015/lib/services/channel-config.service.js +1 -9
  17. package/esm2015/lib/services/options.service.js +13 -20
  18. package/esm5/lib/ec-component/auth-ec/register-form-ec/register-form-ec.component.js +3 -3
  19. package/esm5/lib/ec-component/auth-ec/register-wholesaler-form-ec/register-wholesaler-form-ec.component.js +3 -3
  20. package/esm5/lib/ec-component/checkout-ec/success-ec/success-ec.component.js +15 -3
  21. package/esm5/lib/ec-component/product-detail-ec/product-detail-ec.component.js +4 -3
  22. package/esm5/lib/services/channel-config.service.js +1 -9
  23. package/esm5/lib/services/options.service.js +35 -19
  24. package/fesm2015/ng-easycommerce.js +33 -35
  25. package/fesm2015/ng-easycommerce.js.map +1 -1
  26. package/fesm5/ng-easycommerce.js +62 -41
  27. package/fesm5/ng-easycommerce.js.map +1 -1
  28. package/lib/ec-component/checkout-ec/success-ec/success-ec.component.d.ts +3 -0
  29. package/lib/services/channel-config.service.d.ts +0 -5
  30. package/lib/services/options.service.d.ts +1 -1
  31. package/ng-easycommerce.metadata.json +1 -1
  32. package/package.json +1 -1
package/README.md CHANGED
@@ -1,3 +1,6 @@
1
+ # version 0.0.633
2
+ - mejorar la lógica de actualización de cantidad en el carrito
3
+ - optimizar la generación de breadcrumbs
1
4
  # version 0.0.632
2
5
  - mejorar la validación de cantidad y stock en el carrito
3
6
  # version 0.0.631
@@ -295,5 +295,7 @@
295
295
  "taxes": "Impostos",
296
296
  "price-without-national-taxes": "Preu sense impostos nacionals",
297
297
  "this-payment-method-cannot-be-used": "Aquest mètode de pagament no es pot utilitzar",
298
- "must-be-multiple": "La quantitat total ha de ser un múltiple de {{quantity}}"
298
+ "must-be-multiple": "La quantitat total ha de ser un múltiple de {{quantity}}",
299
+ "payment-date": "Data de pagament",
300
+ "total-paid": "Total abonado"
299
301
  }
@@ -406,5 +406,7 @@
406
406
  "email_already_registered": "The email entered is already registered.",
407
407
  "mail-enter": "Mail",
408
408
  "this-payment-method-cannot-be-used": "This payment method cannot be used",
409
- "must-be-multiple": "The total quantity must be a multiple of {{quantity}}"
409
+ "must-be-multiple": "The total quantity must be a multiple of {{quantity}}",
410
+ "payment-date": "Payment date",
411
+ "total-paid": "Total paid"
410
412
  }
@@ -220,7 +220,7 @@
220
220
  "payment-error": "Hubo un error al procesar el pago. Vuelva a intentarlo más tarde.",
221
221
  "payment-preferences-error": "Hubo un problema al intentar obtener las preferencias del pago. Vuelva a intentarlo más tarde",
222
222
  "payment-state": "Estado de compra",
223
- "pending": "Tu pedido está siendo procesado, una vez verificado el pago, recibirás un mail con información adicional del mismo",
223
+ "pending": "Tu compra está siendo procesado, una vez verificado el pago, recibirás un mail con información adicional del mismo",
224
224
  "balance-in-account-message": "El pago ha sido completado automáticamente con el método seleccionado. Su pedido está siendo procesado y pronto recibirá más información.",
225
225
  "phone": "Teléfono",
226
226
  "phone-cases": "Fundas de teléfono",
@@ -317,8 +317,8 @@
317
317
  "national-taxes": "Impuestos nacionales",
318
318
  "price-without-national-taxes": "Precio sin impuestos nacionales",
319
319
  "taxon": "Categoría",
320
- "thanks-details": "Su compra se ha realizado con éxito. A continuación recibirá un mail con los detalles de su compra",
321
- "thanks-for-buying": "Gracias por su compra",
320
+ "thanks-details": "Tu compra se ha realizado con éxito. A continuación recibirás un mail con los detalles",
321
+ "thanks-for-buying": "Gracias por tu compra",
322
322
  "thanks-for-register": "Gracias por registrarse",
323
323
  "thanks-for-register-detail": "Ahora ya puede iniciar sesión. A continuación le dejamos el acceso al inicio de sesión",
324
324
  "thumbnail-below": "miniatura",
@@ -413,6 +413,8 @@
413
413
  "email_already_registered": "El email ingresado ya se encuentra registrado.",
414
414
  "quantity-not-exceeded": "Debe realizar un pedido con un monto mínimo de {{ amount }} para finalizar su compra.",
415
415
  "mail-enter": "Correo electronico",
416
- "this-payment-method-cannot-be-used": "Este método de pago no puede ser utilizado"
416
+ "this-payment-method-cannot-be-used": "Este método de pago no puede ser utilizado",
417
+ "payment-date": "Fecha de pago",
418
+ "total-paid": "Total abonado"
417
419
 
418
420
  }
@@ -287,5 +287,7 @@
287
287
  "taxes": "Taxes",
288
288
  "price-without-national-taxes": "Prix sans taxes nationales",
289
289
  "this-payment-method-cannot-be-used": "Ce mode de paiement ne peut pas être utilisé",
290
- "must-be-multiple": "La quantité totale doit être un multiple de {{quantity}}"
290
+ "must-be-multiple": "La quantité totale doit être un multiple de {{quantity}}",
291
+ "payment-date": "Date de paiement",
292
+ "total-paid": "Total payé"
291
293
  }
@@ -295,5 +295,7 @@
295
295
  "taxes": "Impostos",
296
296
  "price-without-national-taxes": "Prezo sen impostos nacionais",
297
297
  "this-payment-method-cannot-be-used": "Este método de pago non pode ser usado",
298
- "must-be-multiple": "A cantidade total debe ser múltiplo de {{quantity}}"
298
+ "must-be-multiple": "A cantidade total debe ser múltiplo de {{quantity}}",
299
+ "payment-date": "Data de pago",
300
+ "total-paid": "Total abonado"
299
301
  }
@@ -295,5 +295,7 @@
295
295
  "taxes": "Impostos",
296
296
  "price-without-national-taxes": "Preço sem impostos nacionais",
297
297
  "this-payment-method-cannot-be-used": "Este método de pagamento não pode ser utilizado",
298
- "must-be-multiple": "A quantidade total deve ser um múltiplo de {{quantity}}"
298
+ "must-be-multiple": "A quantidade total deve ser um múltiplo de {{quantity}}",
299
+ "payment-date": "Data de pagamento",
300
+ "total-paid": "Total pago"
299
301
  }
@@ -989,6 +989,17 @@
989
989
  for (var ar = [], i = 0; i < arguments.length; i++) ar = ar.concat(__read(arguments[i]));
990
990
  return ar;
991
991
  };
992
+ var __values = (this && this.__values) || function(o) {
993
+ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
994
+ if (m) return m.call(o);
995
+ if (o && typeof o.length === "number") return {
996
+ next: function () {
997
+ if (o && i >= o.length) o = void 0;
998
+ return { value: o && o[i++], done: !o };
999
+ }
1000
+ };
1001
+ throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
1002
+ };
992
1003
  var OptionsService = /** @class */ (function () {
993
1004
  function OptionsService(connection, constants) {
994
1005
  var _this = this;
@@ -1122,26 +1133,31 @@
1122
1133
  });
1123
1134
  return final_result;
1124
1135
  };
1125
- this.generateBreadcrumb = function (code, elements, result) {
1126
- var element = elements.find(function (elem) { return elem.code == code; });
1127
- if (element) {
1128
- result.push(element);
1129
- }
1130
- else {
1131
- elements.some(function (elem) {
1132
- if (elem.children && elem.children.length) {
1133
- var length_1 = result.length;
1134
- var new_result = _this.generateBreadcrumb(code, elem.children, result);
1135
- if (new_result.length > length_1) {
1136
- result = new_result;
1137
- result.push(elem);
1138
- return true;
1139
- }
1136
+ this.generateBreadcrumb = function (code, elements, path) {
1137
+ var e_1, _a;
1138
+ if (path === void 0) { path = []; }
1139
+ var _b;
1140
+ try {
1141
+ for (var elements_1 = __values(elements), elements_1_1 = elements_1.next(); !elements_1_1.done; elements_1_1 = elements_1.next()) {
1142
+ var elem = elements_1_1.value;
1143
+ if (elem.code === code) {
1144
+ return __spread(path, [elem]);
1140
1145
  }
1141
- return false;
1142
- });
1146
+ if ((_b = elem.children) === null || _b === void 0 ? void 0 : _b.length) {
1147
+ var childPath = _this.generateBreadcrumb(code, elem.children, __spread(path, [elem]));
1148
+ if (childPath.length)
1149
+ return childPath;
1150
+ }
1151
+ }
1143
1152
  }
1144
- return result;
1153
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
1154
+ finally {
1155
+ try {
1156
+ if (elements_1_1 && !elements_1_1.done && (_a = elements_1.return)) _a.call(elements_1);
1157
+ }
1158
+ finally { if (e_1) throw e_1.error; }
1159
+ }
1160
+ return [];
1145
1161
  };
1146
1162
  this.getAllData();
1147
1163
  // this.authService.loggedIn.subscribe(res => res && this.getAllData());
@@ -4108,14 +4124,6 @@
4108
4124
  this.getChannels();
4109
4125
  this.getLocales();
4110
4126
  }
4111
- /**
4112
- * @description Devuelve si se deben mostrar precios con impuestos durante la navegación.
4113
- * @returns {boolean | null} true/false si está definido, null si aún no hay configuración
4114
- */
4115
- ChannelConfigService$1.prototype.getShowPricesWithTaxes = function () {
4116
- var _a, _b;
4117
- return _b = (_a = this.channel) === null || _a === void 0 ? void 0 : _a.showPriceWithTaxesWhileBrowsing, (_b !== null && _b !== void 0 ? _b : null);
4118
- };
4119
4127
  ChannelConfigService$1.ctorParameters = function () { return [
4120
4128
  { type: Constants },
4121
4129
  { type: undefined, decorators: [{ type: core.Inject, args: ['env',] }] },
@@ -7414,7 +7422,7 @@
7414
7422
  if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
7415
7423
  }
7416
7424
  };
7417
- var __values = (this && this.__values) || function(o) {
7425
+ var __values$1 = (this && this.__values) || function(o) {
7418
7426
  var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
7419
7427
  if (m) return m.call(o);
7420
7428
  if (o && typeof o.length === "number") return {
@@ -7754,7 +7762,7 @@
7754
7762
  CartEcComponent.prototype.checkStock = function (item) {
7755
7763
  var e_1, _a;
7756
7764
  try {
7757
- for (var _b = __values(item.product.variants), _c = _b.next(); !_c.done; _c = _b.next()) {
7765
+ for (var _b = __values$1(item.product.variants), _c = _b.next(); !_c.done; _c = _b.next()) {
7758
7766
  var variant = _c.value;
7759
7767
  if (item.variant_id === variant.code) {
7760
7768
  if (variant.stock === 0) {
@@ -7785,7 +7793,7 @@
7785
7793
  res.forEach(function (item) {
7786
7794
  var e_2, _a;
7787
7795
  try {
7788
- for (var _b = __values(item.product.variants), _c = _b.next(); !_c.done; _c = _b.next()) {
7796
+ for (var _b = __values$1(item.product.variants), _c = _b.next(); !_c.done; _c = _b.next()) {
7789
7797
  var variant = _c.value;
7790
7798
  if (item.variant_id === variant.code && !_this.exitUpdate) {
7791
7799
  if (variant.stock === 0) {
@@ -8690,7 +8698,7 @@
8690
8698
  if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
8691
8699
  }
8692
8700
  };
8693
- var __values$1 = (this && this.__values) || function(o) {
8701
+ var __values$2 = (this && this.__values) || function(o) {
8694
8702
  var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
8695
8703
  if (m) return m.call(o);
8696
8704
  if (o && typeof o.length === "number") return {
@@ -8835,7 +8843,7 @@
8835
8843
  var e_1, _a;
8836
8844
  var parent = e.target.parentElement.children;
8837
8845
  try {
8838
- for (var parent_1 = __values$1(parent), parent_1_1 = parent_1.next(); !parent_1_1.done; parent_1_1 = parent_1.next()) {
8846
+ for (var parent_1 = __values$2(parent), parent_1_1 = parent_1.next(); !parent_1_1.done; parent_1_1 = parent_1.next()) {
8839
8847
  var button = parent_1_1.value;
8840
8848
  if (button.classList.contains('active')) {
8841
8849
  button.classList.remove('active');
@@ -8905,7 +8913,7 @@
8905
8913
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
8906
8914
  return c > 3 && r && Object.defineProperty(target, key, r), r;
8907
8915
  };
8908
- var __values$2 = (this && this.__values) || function(o) {
8916
+ var __values$3 = (this && this.__values) || function(o) {
8909
8917
  var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
8910
8918
  if (m) return m.call(o);
8911
8919
  if (o && typeof o.length === "number") return {
@@ -8994,7 +9002,7 @@
8994
9002
  var e_1, _a;
8995
9003
  var parent = e.target.parentElement.children;
8996
9004
  try {
8997
- for (var parent_1 = __values$2(parent), parent_1_1 = parent_1.next(); !parent_1_1.done; parent_1_1 = parent_1.next()) {
9005
+ for (var parent_1 = __values$3(parent), parent_1_1 = parent_1.next(); !parent_1_1.done; parent_1_1 = parent_1.next()) {
8998
9006
  var button = parent_1_1.value;
8999
9007
  if (button.classList.contains('active')) {
9000
9008
  button.classList.remove('active');
@@ -9062,6 +9070,8 @@
9062
9070
  _this.orderDetails = {};
9063
9071
  _this.params = {};
9064
9072
  _this.from_mp = true;
9073
+ _this.totalAmount = null;
9074
+ _this.paymentDate = null;
9065
9075
  /**
9066
9076
  * @description Chequea si existe un bloque recibido por parametro.
9067
9077
  * @param codeBlock codigo del bloque.
@@ -9069,19 +9079,29 @@
9069
9079
  */
9070
9080
  _this.containsBlock = function (codeBlock) { return _this.blocks.find(function (block) { return block.code == codeBlock; }); };
9071
9081
  _this.isBalanceInAccount = function (code) { return code && code.toLocaleLowerCase().includes('balance_in_account'); };
9082
+ _this.isPlaceToPay = function (code) { return code && code.toLocaleLowerCase().includes('place_to_pay'); };
9072
9083
  _this.ecOnConstruct();
9073
9084
  return _this;
9074
9085
  }
9075
9086
  SuccessEcComponent.prototype.ngOnInit = function () {
9076
9087
  var _this = this;
9077
9088
  this.checkoutService.order$.subscribe(function (res) {
9078
- var _a, _b;
9089
+ var _a, _b, _c, _d, _e, _f, _g, _h;
9079
9090
  //console.log('LO QUE LLEGA EN ORDEN', res);
9080
9091
  ((_a = res) === null || _a === void 0 ? void 0 : _a.number) ? _this.params = {
9081
9092
  external_reference: res.number,
9082
9093
  } : null;
9083
9094
  //this.payments = [{method:{code:'bank_transsfer'}}]
9084
9095
  _this.payments = ((_b = res) === null || _b === void 0 ? void 0 : _b.payments) ? res.payments : null;
9096
+ if (((_e = (_d = (_c = _this.payments) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.method) === null || _e === void 0 ? void 0 : _e.code) && _this.isPlaceToPay(_this.payments[0].method.code)) {
9097
+ _this.totalAmount = (_h = (_g = (_f = res) === null || _f === void 0 ? void 0 : _f.totals) === null || _g === void 0 ? void 0 : _g.total, (_h !== null && _h !== void 0 ? _h : null));
9098
+ var now = new Date();
9099
+ _this.paymentDate = now.toLocaleDateString('es-AR', {
9100
+ day: '2-digit',
9101
+ month: '2-digit',
9102
+ year: 'numeric',
9103
+ });
9104
+ }
9085
9105
  });
9086
9106
  this.blocksService.getBlocks('info_metodo_pago');
9087
9107
  this.blocksService.blocks.subscribe(function (res) { return _this.blocks = res; });
@@ -9098,7 +9118,7 @@
9098
9118
  SuccessEcComponent = __decorate$U([
9099
9119
  core.Component({
9100
9120
  selector: 'app-order-success-ec',
9101
- template: "<div id=\"container\" class=\"flex-center generalContainer container-xl\">\n <div class=\"Main card my-2\" *ngIf=\"this.payments && this.payments[0].method.code; else loading\">\n <ng-container *ngIf=\"this.blocks && this.blocks.length > 0; else notInfoToMethod\">\n <ng-container *ngIf=\"containsBlock(this.payments[0].method.code) as bloque; else notInfoToMethod\">\n <div class=\"wrap my-4 card-body\" [id]=\"bloque.code\">\n <div class=\"row\">\n <div class=\"col-md-12 col-12\">\n <h5 [class]=\"bloque.code+'-title'\">{{ (bloque?.translations[consts.getLocale()]?.name ?\n bloque.translations[consts.getLocale()].name :\n 'thanks-for-buying') | translate\n | uppercase }}</h5>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-md-12 col-12 text-start\">\n <app-blocks-ec [section]=\"'info_metodo_pago'\" [blockFilters]=\"this.payments[0].method.code\">\n </app-blocks-ec>\n <div class=\"d-flex flex-column details\">\n <p class=\"card-text\">{{ ('number' | translate) + ': ' + params.external_reference }}</p>\n <p class=\"card-text\">\n {{ isBalanceInAccount(payments[0].method.code) ?\n ('balance-in-account-message' | translate) :\n ((params.payment_status || 'pending') | translate) }}\n </p>\n </div>\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n <ng-template #notInfoToMethod>\n <ng-template #defaultMessage>\n <div class=\"wrap my-4 card-body\">\n <div class=\"row\">\n <div class=\"col-md-12 col-12\">\n <h5 class=\"card-title titpage center-block text-center\">\n {{ 'thanks-for-buying' | translate | uppercase }}\n </h5>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-md-12 col-12 text-center py-3\">\n <h4 class=\"thanks-details\">{{ 'thanks-details' | translate }}</h4>\n <h5 class=\"number\">{{ ('number' | translate) + ': ' + params.external_reference }}</h5>\n <h5 class=\"pending\">\n {{ isBalanceInAccount(payments[0].method.code) ?\n ('balance-in-account-message' | translate) :\n ((params.payment_status || 'pending') | translate) }}\n </h5>\n <!-- <h5 *ngIf=\"!from_mp\">{{ ('will_contact' | translate) }}</h5> -->\n\n <!-- <a routerLink=\"/collection\"><button class=\"comprar\">{{ 'continue-shopping' | translate }}</button></a> -->\n </div>\n </div>\n </div>\n </ng-template>\n <ng-container [ngTemplateOutlet]=\"notInfoToMethodTemplate ? notInfoToMethodTemplate : defaultMessage\"\n [ngTemplateOutletContext]=\"{params:params}\">\n </ng-container>\n </ng-template>\n </div>\n</div>\n\n<ng-template #loading>\n <app-loading-full-ec></app-loading-full-ec>\n</ng-template>",
9121
+ template: "<div id=\"container\" class=\"flex-center generalContainer container-xl\">\n <div class=\"Main card my-2\" *ngIf=\"this.payments && this.payments[0].method.code; else loading\">\n <ng-container *ngIf=\"this.blocks && this.blocks.length > 0; else notInfoToMethod\">\n <ng-container *ngIf=\"containsBlock(this.payments[0].method.code) as bloque; else notInfoToMethod\">\n <div class=\"wrap my-4 card-body\" [id]=\"bloque.code\">\n <div class=\"row\">\n <div class=\"col-md-12 col-12\">\n <h5 [class]=\"bloque.code+'-title'\">{{ (bloque?.translations[consts.getLocale()]?.name ?\n bloque.translations[consts.getLocale()].name :\n 'thanks-for-buying') | translate\n | uppercase }}</h5>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-md-12 col-12 text-start\">\n <app-blocks-ec [section]=\"'info_metodo_pago'\" [blockFilters]=\"this.payments[0].method.code\">\n </app-blocks-ec>\n <div class=\"d-flex flex-column details\">\n <p class=\"card-text\">{{ ('number' | translate) + ': ' + params.external_reference }}</p>\n <p class=\"card-text\">\n {{ isBalanceInAccount(payments[0].method.code) ?\n ('balance-in-account-message' | translate) :\n ((params.payment_status || 'pending') | translate) }}\n </p>\n </div>\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n <ng-template #notInfoToMethod>\n <ng-template #defaultMessage>\n <div class=\"wrap my-4 card-body\">\n <div class=\"row\">\n <div class=\"col-md-12 col-12\">\n <h5 class=\"card-title titpage center-block text-center\">\n {{ 'thanks-for-buying' | translate | uppercase }}\n </h5>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-md-12 col-12 text-center py-3\">\n <h4 class=\"thanks-details\">{{ 'thanks-details' | translate }}</h4>\n <h5 class=\"number order-info-line\" [ngClass]=\"{ 'compact': paymentDate && totalAmount }\">{{ ('number' | translate) + ': ' + params.external_reference }}</h5>\n <h5 class=\"order-info-line\" *ngIf=\"paymentDate && totalAmount\">\n {{'payment-date' | translate }}: {{ paymentDate }}\n </h5>\n <h5 class=\"order-info-line\" *ngIf=\"paymentDate && totalAmount\">\n {{'total-paid' | translate }}: {{ totalAmount | ecCurrencySymbol }}\n </h5>\n <h5 class=\"pending\">\n {{ isBalanceInAccount(payments[0].method.code) ?\n ('balance-in-account-message' | translate) :\n ((params.payment_status || 'pending') | translate) }}\n </h5>\n <!-- <h5 *ngIf=\"!from_mp\">{{ ('will_contact' | translate) }}</h5> -->\n\n <!-- <a routerLink=\"/collection\"><button class=\"comprar\">{{ 'continue-shopping' | translate }}</button></a> -->\n </div>\n </div>\n </div>\n </ng-template>\n <ng-container [ngTemplateOutlet]=\"notInfoToMethodTemplate ? notInfoToMethodTemplate : defaultMessage\"\n [ngTemplateOutletContext]=\"{params:params}\">\n </ng-container>\n </ng-template>\n </div>\n</div>\n\n<ng-template #loading>\n <app-loading-full-ec></app-loading-full-ec>\n</ng-template>",
9102
9122
  styles: [""]
9103
9123
  })
9104
9124
  ], SuccessEcComponent);
@@ -11101,9 +11121,10 @@
11101
11121
  _this.plus = function (stock, changeAmount, forceMultiple) {
11102
11122
  if (changeAmount === void 0) { changeAmount = 1; }
11103
11123
  if (forceMultiple === void 0) { forceMultiple = false; }
11104
- var newQuantity = _this.quantity + changeAmount;
11124
+ var currentQuantity = Number(_this.quantity);
11125
+ var newQuantity = currentQuantity + changeAmount;
11105
11126
  if (forceMultiple && changeAmount > 0) {
11106
- if (_this.quantity < changeAmount) {
11127
+ if (currentQuantity < changeAmount) {
11107
11128
  newQuantity = changeAmount;
11108
11129
  }
11109
11130
  else {
@@ -13777,8 +13798,8 @@
13777
13798
  RegisterFormEcComponent.prototype.ngOnInit = function () {
13778
13799
  var _this = this;
13779
13800
  this.registerForm = this.formBuilder.group({
13780
- firstName: ['', forms.Validators.required],
13781
- lastName: ['', forms.Validators.required],
13801
+ firstName: ['', [forms.Validators.required, forms.Validators.pattern(/^[A-Za-zÁÉÍÓÚáéíóúÑñ\s]+$/)]],
13802
+ lastName: ['', [forms.Validators.required, forms.Validators.pattern(/^[A-Za-zÁÉÍÓÚáéíóúÑñ\s]+$/)]],
13782
13803
  email: ['', forms.Validators.required],
13783
13804
  plainPassword: ['', forms.Validators.required],
13784
13805
  plainPassword2: ['', forms.Validators.required],
@@ -14374,8 +14395,8 @@
14374
14395
  var _this = this;
14375
14396
  this.paramsService.parameters.subscribe(function (res) { return _this.params = res; });
14376
14397
  this.registerForm = this.formBuilder.group({
14377
- firstName: ['', [forms.Validators.required]],
14378
- lastName: ['', [forms.Validators.required]],
14398
+ firstName: ['', [forms.Validators.required, forms.Validators.pattern(/^[A-Za-zÁÉÍÓÚáéíóúÑñ\s]+$/)]],
14399
+ lastName: ['', [forms.Validators.required, forms.Validators.pattern(/^[A-Za-zÁÉÍÓÚáéíóúÑñ\s]+$/)]],
14379
14400
  documentType: [null, [forms.Validators.required]],
14380
14401
  documentNumber: ['', [forms.Validators.required]],
14381
14402
  email: ['', [forms.Validators.required, forms.Validators.email]],