@spartacus/checkout
Version:
Checkout feature library for Spartacus
51 lines (50 loc) • 2.06 kB
TypeScript
import { Store } from '@ngrx/store';
import { CheckoutPaymentFacade } from '@spartacus/checkout/root';
import { ActiveCartService, CardType, PaymentDetails, StateUtils, StateWithProcess, UserIdService } from '@spartacus/core';
import { Observable } from 'rxjs';
import { StateWithCheckout } from '../store/checkout-state';
import * as i0 from "@angular/core";
export declare class CheckoutPaymentService implements CheckoutPaymentFacade {
protected checkoutStore: Store<StateWithCheckout>;
protected processStateStore: Store<StateWithProcess<void>>;
protected activeCartService: ActiveCartService;
protected userIdService: UserIdService;
constructor(checkoutStore: Store<StateWithCheckout>, processStateStore: Store<StateWithProcess<void>>, activeCartService: ActiveCartService, userIdService: UserIdService);
/**
* Get card types
*/
getCardTypes(): Observable<CardType[]>;
/**
* Get payment details
*/
getPaymentDetails(): Observable<PaymentDetails>;
/**
* Get status about set Payment Details process
*/
getSetPaymentDetailsResultProcess(): Observable<StateUtils.LoaderState<void>>;
/**
* Clear info about process of setting Payment Details
*/
resetSetPaymentDetailsProcess(): void;
/**
* Load the supported card types
*/
loadSupportedCardTypes(): void;
/**
* Create payment details using the given paymentDetails param
* @param paymentDetails: the PaymentDetails to be created
*/
createPaymentDetails(paymentDetails: PaymentDetails): void;
/**
* Set payment details
* @param paymentDetails : the PaymentDetails to be set
*/
setPaymentDetails(paymentDetails: PaymentDetails): void;
/**
* Sets payment loading to true without having the flicker issue (GH-3102)
*/
paymentProcessSuccess(): void;
protected actionAllowed(): boolean;
static ɵfac: i0.ɵɵFactoryDeclaration<CheckoutPaymentService, never>;
static ɵprov: i0.ɵɵInjectableDeclaration<CheckoutPaymentService>;
}