import { MockDaffConfigurableProductFacade } from '@daffodil/product-configurable/state/testing'
@Injectable()
class MockDaffConfigurableProductFacade implements DaffConfigurableProductFacadeInterface {
getAllAttributes(id: string): BehaviorSubject<Dictionary<string[]>>
getAllVariants(id: string): BehaviorSubject<DaffConfigurableProductVariant[]>
getAppliedAttributes(id: string): BehaviorSubject<Dictionary<string>>
getMinimumPrice(id: string): BehaviorSubject<number>
getMaximumPrice(id: string): BehaviorSubject<number>
getMinimumDiscountedPrice(id: string): BehaviorSubject<number>
getMaximumDiscountedPrice(id: string): BehaviorSubject<number>
getMinimumPercentDiscount(id: string): BehaviorSubject<number>
getMaximumPercentDiscount(id: string): BehaviorSubject<number>
isPriceRanged(id: string): BehaviorSubject<boolean>
hasDiscount(id: string): BehaviorSubject<boolean>
getSelectableAttributes(id: string): BehaviorSubject<Dictionary<string[]>>
getMatchingVariants(id: string): BehaviorSubject<DaffConfigurableProductVariant[]>
dispatch(action): void
}
BehaviorSubject> All attributes of a configurable product.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubject<DaffConfigurableProductVariant[]>All variants of a configurable product.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubject> The applied attributes of a configurable product.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectGet the current minimum price possible based on the applied attributes and remaining variants.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectGet the current maximum price possible based on the applied attributes and remaining variants.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectGet the current minimum discounted price possible based on the applied attributes and remaining variants.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectGet the current maximum discounted price possible based on the applied attributes and remaining variants.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectGet the current minimum percent discount possible based on the applied attributes and remaining variants.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectGet the current maximum percent discount possible based on the applied attributes and remaining variants.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectReturns whether the possible price for the configurable product is a range of different prices
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubjectReturns whether the variants of the configurable product have (a) discount(s)
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubject> Selectable configurable product attributes derived from the remaining variants and the order of currently applied attributes. The remaining variants of the product are derived from the currently applied attributes.
| Parameter | id: string |
|---|---|
| Description |
BehaviorSubject<DaffConfigurableProductVariant[]>The variants that match the applied attributes of a configurable product.
| Parameter | id: string |
|---|---|
| Description |
void| Parameter | action: undefined |
|---|---|
| Description |