2017-11-11 20:15:19 -06:00
|
|
|
// @flow
|
|
|
|
|
export const QUANTITY_NONE: 'none' = 'none';
|
|
|
|
|
export const QUANTITY_FEW: 'few' = 'few';
|
|
|
|
|
export const QUANTITY_MANY: 'many' = 'many';
|
|
|
|
|
export const QUANTITY_LOTS: 'lots' = 'lots';
|
2017-11-26 19:52:16 -06:00
|
|
|
|
2017-11-11 20:15:19 -06:00
|
|
|
export const QUANTITIES = [QUANTITY_NONE, QUANTITY_FEW, QUANTITY_LOTS, QUANTITY_MANY];
|
2017-11-26 19:52:16 -06:00
|
|
|
|
|
|
|
|
export type Quantity = typeof QUANTITY_NONE | typeof QUANTITY_FEW | typeof QUANTITY_MANY | typeof QUANTITY_LOTS;
|
|
|
|
|
|
|
|
|
|
export type QuantityResponse = {
|
|
|
|
|
food_item_id: string,
|
|
|
|
|
quantity: Quantity,
|
|
|
|
|
date: number,
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
export type QuantityFragment = { quantity: Quantity, lastupdated: number };
|