UIKit/lib/model/cart.ts
2024-03-26 17:27:58 +03:00

32 lines
647 B
TypeScript

import { Discount } from "./discount";
export type PrivilegeCartData = {
serviceKey: string;
privilegeId: string;
description: string;
price: number;
amount: number;
};
export type TariffCartData = {
name: string;
id: string;
price: number;
isCustom: boolean;
privileges: PrivilegeCartData[];
};
export type ServiceCartData = {
serviceKey: string;
tariffs: TariffCartData[];
price: number;
};
export type CartData = {
services: ServiceCartData[];
priceBeforeDiscounts: number;
priceAfterDiscounts: number;
allAppliedDiscounts: Discount[];
};