ng-easycommerce 0.0.679 → 0.0.680

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.
@@ -45,6 +45,8 @@ export declare class CartEcComponent extends ComponentHelper implements OnInit {
45
45
  ngOnInit(): void;
46
46
  toDecimal: (amount: any) => any;
47
47
  protected actualizarCantidad(item: any, cantidad: number | string, stock: number, id?: string): void;
48
+ cartItemPlus: (item: any) => void;
49
+ cartItemLess: (item: any) => void;
48
50
  redirectCheckout(): boolean;
49
51
  redirectRegister: () => Promise<boolean>;
50
52
  openModal(template: TemplateRef<any>): void;
@@ -17,9 +17,17 @@ export declare class MultipleItemsToCartEcComponent extends ComponentHelper {
17
17
  totalItems: EventEmitter<any>;
18
18
  total: number;
19
19
  countItems: number;
20
+ quantity: number;
21
+ spanInfo: string;
22
+ disablesButton: any;
20
23
  constructor(consts: Constants, productService: ProductDetailService, cartService: CartService, toastService: ToastService);
21
24
  ngOnInit(): void;
22
25
  optionsProductForVariant: () => Product[];
26
+ plus: (product: Product, stock?: any, multipleQuantity?: any) => void;
27
+ less: (product: Product, multipleQuantity?: any, minimumItemsQuantity?: any) => void;
28
+ isQuantityValid: (quantity: number, item: any) => boolean;
29
+ validateQuantity: (quantity: number, item: any) => void;
30
+ buildButtons: (asociatedData: any) => number[];
23
31
  setQuantity: (value: any, product: Product) => void;
24
32
  condition: (value: any, product: Product) => boolean;
25
33
  allWithoutTracking: () => boolean;
@@ -36,6 +36,9 @@ export declare class ProductDetailEcComponent extends ComponentHelper implements
36
36
  hidePrices: boolean;
37
37
  creditAccountShowPrices: boolean | null;
38
38
  enableFieldNotesInArticleFile: boolean;
39
+ quantityError: string;
40
+ minimumItemsQty: number;
41
+ multipleQty: number;
39
42
  private prefillSub?;
40
43
  contact: ElementRef;
41
44
  constructor(productService: ProductDetailService, consts: Constants, activedRoute: ActivatedRoute, cartService: CartService, optionsService: OptionsService, productsService: ProductsService, analyticsService: AnalyticsService, router: Router, toastrService: ToastService, meta: Meta, injector: Injector);
@@ -48,17 +51,25 @@ export declare class ProductDetailEcComponent extends ComponentHelper implements
48
51
  saveRef: (carousel: any) => void;
49
52
  /**
50
53
  * @description actualiza la variable quantity sumandole 'x' contenido.
54
+ * Si hay un multipleQuantity configurado, hace snap al siguiente múltiplo válido
55
+ * cuando la cantidad actual ya es inválida.
51
56
  * @param stock número máximo disponible en stock.
52
- * @param changeAmount cantidad que se quiere sumar.
53
- * @param forceMultiple si es true, obliga a que el resultado sea múltiplo de changeAmount.
57
+ * @param changeAmount cantidad que se quiere sumar (ignorado si multipleQty está seteado).
58
+ * @param forceMultiple legacy — si es true, obliga a que el resultado sea múltiplo de changeAmount.
54
59
  */
55
60
  plus: (stock?: number, changeAmount?: number, forceMultiple?: boolean) => void;
56
61
  /**
57
62
  * @description actualiza la variable quantity restandole 'x' contenido.
58
- * @param changeAmount cantidad que se quiere restar.
59
- * @param forceMultiple si es true, obliga a que el resultado sea múltiplo de changeAmount.
63
+ * Si hay un multipleQuantity configurado, hace snap al múltiplo válido inferior
64
+ * cuando la cantidad actual ya es inválida.
65
+ * @param changeAmount cantidad que se quiere restar (ignorado si multipleQty está seteado).
66
+ * @param minimum cantidad mínima permitida (ignorado si minimumItemsQty está seteado).
67
+ * @param forceMultiple legacy — si es true, obliga a que el resultado sea múltiplo de changeAmount.
60
68
  */
61
69
  less: (changeAmount?: number, minimum?: number, forceMultiple?: boolean) => void;
70
+ onQuantityInput: (value: string) => void;
71
+ validateDetail: () => void;
72
+ isQuantityValidDetail: () => boolean;
62
73
  showContact: () => boolean;
63
74
  hideContact: () => boolean;
64
75
  thereIsMoreInfo: (product: any) => any;