26 lines
901 B
TypeScript
26 lines
901 B
TypeScript
import { AxiosInstance } from 'axios';
|
|
import Config from '../config/Config';
|
|
import AbstractRequest from './AbstractRequest';
|
|
declare class CartRequest extends AbstractRequest {
|
|
entityPath: string;
|
|
prefix: string;
|
|
handlerParams: any;
|
|
params: any;
|
|
constructor(client: AxiosInstance, config: Config);
|
|
withShippings(ids?: Array<number>): this;
|
|
protected buildUrl(): string;
|
|
add(products: IAddToCartProduct | Array<IAddToCartProduct>): Promise<import("axios").AxiosResponse<any>>;
|
|
update(product: any): Promise<import("axios").AxiosResponse<any>>;
|
|
saveUserData(userData: any): Promise<import("axios").AxiosResponse<any>>;
|
|
protected setParams(): void;
|
|
}
|
|
interface IAddToCartProduct {
|
|
product_id: number;
|
|
amount: number;
|
|
product_options?: Array<{
|
|
id: number;
|
|
value: any;
|
|
}>;
|
|
}
|
|
export default CartRequest;
|