@open-tender/utils
Version:
A library of utils for use with Open Tender applications that utilize our cloud-based Order API.
13 lines (12 loc) • 1 kB
TypeScript
import { Address, OrderType, RevenueCenter, ServiceType } from '@open-tender/types';
export declare const makeOrderAddress: (address: Address | null) => string;
export declare const makeFullAddress: (address: Address) => string;
export declare const makeOrderTypeFromParam: (param: string) => (string | boolean)[] | null;
export declare const makeServiceTypeName: (serviceType: ServiceType, isCatering: boolean, isOutpost: boolean, outpostName: string) => string | undefined;
export declare const makeOrderTypeName: (orderType: OrderType, serviceType: ServiceType) => string | undefined;
export declare const makeNotAcceptingOrdersMsg: (serviceType: ServiceType) => string;
export declare const makeRevenueCenterMsg: (revenueCenter: RevenueCenter, serviceType: ServiceType, requestedAt: string, statusMessages: Record<string, string>) => {
message: any;
color: string;
};
export declare const getRevenueCenterStatus: (revenueCenter: RevenueCenter, serviceType: ServiceType) => string | null;