mirror of
https://github.com/TandoorRecipes/recipes.git
synced 2026-01-01 20:28:46 -05:00
fixed api client generation
This commit is contained in:
@@ -24,7 +24,7 @@ export interface AccessToken {
|
||||
* @type {number}
|
||||
* @memberof AccessToken
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -61,6 +61,7 @@ export interface AccessToken {
|
||||
* Check if a given object implements the AccessToken interface.
|
||||
*/
|
||||
export function instanceOfAccessToken(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('token' in value)) return false;
|
||||
if (!('expires' in value)) return false;
|
||||
if (!('created' in value)) return false;
|
||||
@@ -78,7 +79,7 @@ export function AccessTokenFromJSONTyped(json: any, ignoreDiscriminator: boolean
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'token': json['token'],
|
||||
'expires': (new Date(json['expires'])),
|
||||
'scope': json['scope'] == null ? undefined : json['scope'],
|
||||
@@ -93,7 +94,6 @@ export function AccessTokenToJSON(value?: AccessToken | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'expires': ((value['expires']).toISOString()),
|
||||
'scope': value['scope'],
|
||||
};
|
||||
|
||||
@@ -31,6 +31,12 @@ export interface AccessTokenRequest {
|
||||
* @memberof AccessTokenRequest
|
||||
*/
|
||||
scope?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof AccessTokenRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -53,6 +59,7 @@ export function AccessTokenRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
|
||||
'expires': (new Date(json['expires'])),
|
||||
'scope': json['scope'] == null ? undefined : json['scope'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -64,6 +71,7 @@ export function AccessTokenRequestToJSON(value?: AccessTokenRequest | null): any
|
||||
|
||||
'expires': ((value['expires']).toISOString()),
|
||||
'scope': value['scope'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface Automation {
|
||||
* @type {number}
|
||||
* @memberof Automation
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {AutomationTypeEnum}
|
||||
@@ -92,6 +92,7 @@ export interface Automation {
|
||||
* Check if a given object implements the Automation interface.
|
||||
*/
|
||||
export function instanceOfAutomation(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('type' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
return true;
|
||||
@@ -107,7 +108,7 @@ export function AutomationFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'type': AutomationTypeEnumFromJSON(json['type']),
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
@@ -126,7 +127,6 @@ export function AutomationToJSON(value?: Automation | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'type': AutomationTypeEnumToJSON(value['type']),
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
|
||||
@@ -74,6 +74,12 @@ export interface AutomationRequest {
|
||||
* @memberof AutomationRequest
|
||||
*/
|
||||
disabled?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof AutomationRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -102,6 +108,7 @@ export function AutomationRequestFromJSONTyped(json: any, ignoreDiscriminator: b
|
||||
'param3': json['param_3'] == null ? undefined : json['param_3'],
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'disabled': json['disabled'] == null ? undefined : json['disabled'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -119,6 +126,7 @@ export function AutomationRequestToJSON(value?: AutomationRequest | null): any {
|
||||
'param_3': value['param3'],
|
||||
'order': value['order'],
|
||||
'disabled': value['disabled'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface BookmarkletImport {
|
||||
* @type {number}
|
||||
* @memberof BookmarkletImport
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -55,6 +55,7 @@ export interface BookmarkletImport {
|
||||
* Check if a given object implements the BookmarkletImport interface.
|
||||
*/
|
||||
export function instanceOfBookmarkletImport(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('html' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
if (!('createdAt' in value)) return false;
|
||||
@@ -71,7 +72,7 @@ export function BookmarkletImportFromJSONTyped(json: any, ignoreDiscriminator: b
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'url': json['url'] == null ? undefined : json['url'],
|
||||
'html': json['html'],
|
||||
'createdBy': json['created_by'],
|
||||
@@ -85,7 +86,6 @@ export function BookmarkletImportToJSON(value?: BookmarkletImport | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'url': value['url'],
|
||||
'html': value['html'],
|
||||
};
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface BookmarkletImportList {
|
||||
* @type {number}
|
||||
* @memberof BookmarkletImportList
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -49,6 +49,7 @@ export interface BookmarkletImportList {
|
||||
* Check if a given object implements the BookmarkletImportList interface.
|
||||
*/
|
||||
export function instanceOfBookmarkletImportList(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
if (!('createdAt' in value)) return false;
|
||||
return true;
|
||||
@@ -64,7 +65,7 @@ export function BookmarkletImportListFromJSONTyped(json: any, ignoreDiscriminato
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'url': json['url'] == null ? undefined : json['url'],
|
||||
'createdBy': json['created_by'],
|
||||
'createdAt': (new Date(json['created_at'])),
|
||||
@@ -77,7 +78,6 @@ export function BookmarkletImportListToJSON(value?: BookmarkletImportList | null
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'url': value['url'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -31,6 +31,12 @@ export interface BookmarkletImportRequest {
|
||||
* @memberof BookmarkletImportRequest
|
||||
*/
|
||||
html: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof BookmarkletImportRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -53,6 +59,7 @@ export function BookmarkletImportRequestFromJSONTyped(json: any, ignoreDiscrimin
|
||||
|
||||
'url': json['url'] == null ? undefined : json['url'],
|
||||
'html': json['html'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -64,6 +71,7 @@ export function BookmarkletImportRequestToJSON(value?: BookmarkletImportRequest
|
||||
|
||||
'url': value['url'],
|
||||
'html': value['html'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface ConnectorConfigConfig {
|
||||
* @type {number}
|
||||
* @memberof ConnectorConfigConfig
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -79,6 +79,7 @@ export interface ConnectorConfigConfig {
|
||||
* Check if a given object implements the ConnectorConfigConfig interface.
|
||||
*/
|
||||
export function instanceOfConnectorConfigConfig(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
return true;
|
||||
@@ -94,7 +95,7 @@ export function ConnectorConfigConfigFromJSONTyped(json: any, ignoreDiscriminato
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'url': json['url'] == null ? undefined : json['url'],
|
||||
'todoEntity': json['todo_entity'] == null ? undefined : json['todo_entity'],
|
||||
@@ -112,7 +113,6 @@ export function ConnectorConfigConfigToJSON(value?: ConnectorConfigConfig | null
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'url': value['url'],
|
||||
'todo_entity': value['todoEntity'],
|
||||
|
||||
@@ -67,6 +67,12 @@ export interface ConnectorConfigConfigRequest {
|
||||
* @memberof ConnectorConfigConfigRequest
|
||||
*/
|
||||
onShoppingListEntryDeletedEnabled?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof ConnectorConfigConfigRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -95,6 +101,7 @@ export function ConnectorConfigConfigRequestFromJSONTyped(json: any, ignoreDiscr
|
||||
'onShoppingListEntryCreatedEnabled': json['on_shopping_list_entry_created_enabled'] == null ? undefined : json['on_shopping_list_entry_created_enabled'],
|
||||
'onShoppingListEntryUpdatedEnabled': json['on_shopping_list_entry_updated_enabled'] == null ? undefined : json['on_shopping_list_entry_updated_enabled'],
|
||||
'onShoppingListEntryDeletedEnabled': json['on_shopping_list_entry_deleted_enabled'] == null ? undefined : json['on_shopping_list_entry_deleted_enabled'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -112,6 +119,7 @@ export function ConnectorConfigConfigRequestToJSON(value?: ConnectorConfigConfig
|
||||
'on_shopping_list_entry_created_enabled': value['onShoppingListEntryCreatedEnabled'],
|
||||
'on_shopping_list_entry_updated_enabled': value['onShoppingListEntryUpdatedEnabled'],
|
||||
'on_shopping_list_entry_deleted_enabled': value['onShoppingListEntryDeletedEnabled'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface CookLog {
|
||||
* @type {number}
|
||||
* @memberof CookLog
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
@@ -80,6 +80,7 @@ export interface CookLog {
|
||||
* Check if a given object implements the CookLog interface.
|
||||
*/
|
||||
export function instanceOfCookLog(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('recipe' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
if (!('updatedAt' in value)) return false;
|
||||
@@ -96,7 +97,7 @@ export function CookLogFromJSONTyped(json: any, ignoreDiscriminator: boolean): C
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'recipe': json['recipe'],
|
||||
'servings': json['servings'] == null ? undefined : json['servings'],
|
||||
'rating': json['rating'] == null ? undefined : json['rating'],
|
||||
@@ -113,7 +114,6 @@ export function CookLogToJSON(value?: CookLog | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'recipe': value['recipe'],
|
||||
'servings': value['servings'],
|
||||
'rating': value['rating'],
|
||||
|
||||
@@ -49,6 +49,12 @@ export interface CookLogRequest {
|
||||
* @memberof CookLogRequest
|
||||
*/
|
||||
createdAt?: Date;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof CookLogRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -74,6 +80,7 @@ export function CookLogRequestFromJSONTyped(json: any, ignoreDiscriminator: bool
|
||||
'rating': json['rating'] == null ? undefined : json['rating'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'createdAt': json['created_at'] == null ? undefined : (new Date(json['created_at'])),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -88,6 +95,7 @@ export function CookLogRequestToJSON(value?: CookLogRequest | null): any {
|
||||
'rating': value['rating'],
|
||||
'comment': value['comment'],
|
||||
'created_at': value['createdAt'] == null ? undefined : ((value['createdAt']).toISOString()),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface CustomFilter {
|
||||
* @type {number}
|
||||
* @memberof CustomFilter
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -62,6 +62,7 @@ export interface CustomFilter {
|
||||
* Check if a given object implements the CustomFilter interface.
|
||||
*/
|
||||
export function instanceOfCustomFilter(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
if (!('search' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
@@ -78,7 +79,7 @@ export function CustomFilterFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'search': json['search'],
|
||||
'shared': json['shared'] == null ? undefined : ((json['shared'] as Array<any>).map(UserFromJSON)),
|
||||
@@ -92,7 +93,6 @@ export function CustomFilterToJSON(value?: CustomFilter | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'search': value['search'],
|
||||
'shared': value['shared'] == null ? undefined : ((value['shared'] as Array<any>).map(UserToJSON)),
|
||||
|
||||
@@ -44,6 +44,12 @@ export interface CustomFilterRequest {
|
||||
* @memberof CustomFilterRequest
|
||||
*/
|
||||
shared?: Array<UserRequest>;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof CustomFilterRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -68,6 +74,7 @@ export function CustomFilterRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'name': json['name'],
|
||||
'search': json['search'],
|
||||
'shared': json['shared'] == null ? undefined : ((json['shared'] as Array<any>).map(UserRequestFromJSON)),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -80,6 +87,7 @@ export function CustomFilterRequestToJSON(value?: CustomFilterRequest | null): a
|
||||
'name': value['name'],
|
||||
'search': value['search'],
|
||||
'shared': value['shared'] == null ? undefined : ((value['shared'] as Array<any>).map(UserRequestToJSON)),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface ExportLog {
|
||||
* @type {number}
|
||||
* @memberof ExportLog
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -85,6 +85,7 @@ export interface ExportLog {
|
||||
* Check if a given object implements the ExportLog interface.
|
||||
*/
|
||||
export function instanceOfExportLog(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('type' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
if (!('createdAt' in value)) return false;
|
||||
@@ -101,7 +102,7 @@ export function ExportLogFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'type': json['type'],
|
||||
'msg': json['msg'] == null ? undefined : json['msg'],
|
||||
'running': json['running'] == null ? undefined : json['running'],
|
||||
@@ -120,7 +121,6 @@ export function ExportLogToJSON(value?: ExportLog | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'type': value['type'],
|
||||
'msg': value['msg'],
|
||||
'running': value['running'],
|
||||
|
||||
@@ -61,6 +61,12 @@ export interface ExportLogRequest {
|
||||
* @memberof ExportLogRequest
|
||||
*/
|
||||
possiblyNotExpired?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof ExportLogRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -88,6 +94,7 @@ export function ExportLogRequestFromJSONTyped(json: any, ignoreDiscriminator: bo
|
||||
'exportedRecipes': json['exported_recipes'] == null ? undefined : json['exported_recipes'],
|
||||
'cacheDuration': json['cache_duration'] == null ? undefined : json['cache_duration'],
|
||||
'possiblyNotExpired': json['possibly_not_expired'] == null ? undefined : json['possibly_not_expired'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -104,6 +111,7 @@ export function ExportLogRequestToJSON(value?: ExportLogRequest | null): any {
|
||||
'exported_recipes': value['exportedRecipes'],
|
||||
'cache_duration': value['cacheDuration'],
|
||||
'possibly_not_expired': value['possiblyNotExpired'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -95,7 +95,7 @@ export interface Food {
|
||||
* @type {number}
|
||||
* @memberof Food
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -240,6 +240,7 @@ export interface Food {
|
||||
* Check if a given object implements the Food interface.
|
||||
*/
|
||||
export function instanceOfFood(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
if (!('shopping' in value)) return false;
|
||||
if (!('parent' in value)) return false;
|
||||
@@ -259,7 +260,7 @@ export function FoodFromJSONTyped(json: any, ignoreDiscriminator: boolean): Food
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'pluralName': json['plural_name'] == null ? undefined : json['plural_name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
@@ -292,7 +293,6 @@ export function FoodToJSON(value?: Food | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'plural_name': value['pluralName'],
|
||||
'description': value['description'],
|
||||
|
||||
@@ -58,7 +58,7 @@ export interface FoodInheritField {
|
||||
* @type {number}
|
||||
* @memberof FoodInheritField
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -77,6 +77,7 @@ export interface FoodInheritField {
|
||||
* Check if a given object implements the FoodInheritField interface.
|
||||
*/
|
||||
export function instanceOfFoodInheritField(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -90,7 +91,7 @@ export function FoodInheritFieldFromJSONTyped(json: any, ignoreDiscriminator: bo
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'field': json['field'] == null ? undefined : json['field'],
|
||||
};
|
||||
@@ -102,7 +103,6 @@ export function FoodInheritFieldToJSON(value?: FoodInheritField | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'field': value['field'],
|
||||
};
|
||||
|
||||
@@ -65,6 +65,12 @@ export interface FoodInheritFieldRequest {
|
||||
* @memberof FoodInheritFieldRequest
|
||||
*/
|
||||
field?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof FoodInheritFieldRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -86,6 +92,7 @@ export function FoodInheritFieldRequestFromJSONTyped(json: any, ignoreDiscrimina
|
||||
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'field': json['field'] == null ? undefined : json['field'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -97,6 +104,7 @@ export function FoodInheritFieldRequestToJSON(value?: FoodInheritFieldRequest |
|
||||
|
||||
'name': value['name'],
|
||||
'field': value['field'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -198,6 +198,12 @@ export interface FoodRequest {
|
||||
* @memberof FoodRequest
|
||||
*/
|
||||
openDataSlug?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof FoodRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -236,6 +242,7 @@ export function FoodRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean
|
||||
'substituteChildren': json['substitute_children'] == null ? undefined : json['substitute_children'],
|
||||
'childInheritFields': json['child_inherit_fields'] == null ? undefined : ((json['child_inherit_fields'] as Array<any>).map(FoodInheritFieldRequestFromJSON)),
|
||||
'openDataSlug': json['open_data_slug'] == null ? undefined : json['open_data_slug'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -263,6 +270,7 @@ export function FoodRequestToJSON(value?: FoodRequest | null): any {
|
||||
'substitute_children': value['substituteChildren'],
|
||||
'child_inherit_fields': value['childInheritFields'] == null ? undefined : ((value['childInheritFields'] as Array<any>).map(FoodInheritFieldRequestToJSON)),
|
||||
'open_data_slug': value['openDataSlug'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,13 +24,14 @@ export interface FoodShoppingUpdate {
|
||||
* @type {number}
|
||||
* @memberof FoodShoppingUpdate
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a given object implements the FoodShoppingUpdate interface.
|
||||
*/
|
||||
export function instanceOfFoodShoppingUpdate(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -44,7 +45,7 @@ export function FoodShoppingUpdateFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -54,7 +55,6 @@ export function FoodShoppingUpdateToJSON(value?: FoodShoppingUpdate | null): any
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -46,6 +46,12 @@ export interface FoodShoppingUpdateRequest {
|
||||
* @memberof FoodShoppingUpdateRequest
|
||||
*/
|
||||
_delete: DeleteEnum | null;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof FoodShoppingUpdateRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -69,6 +75,7 @@ export function FoodShoppingUpdateRequestFromJSONTyped(json: any, ignoreDiscrimi
|
||||
'amount': json['amount'] == null ? undefined : json['amount'],
|
||||
'unit': json['unit'] == null ? undefined : json['unit'],
|
||||
'_delete': DeleteEnumFromJSON(json['delete']),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -81,6 +88,7 @@ export function FoodShoppingUpdateRequestToJSON(value?: FoodShoppingUpdateReques
|
||||
'amount': value['amount'],
|
||||
'unit': value['unit'],
|
||||
'delete': DeleteEnumToJSON(value['_delete']),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface FoodSimple {
|
||||
* @type {number}
|
||||
* @memberof FoodSimple
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -43,6 +43,7 @@ export interface FoodSimple {
|
||||
* Check if a given object implements the FoodSimple interface.
|
||||
*/
|
||||
export function instanceOfFoodSimple(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
return true;
|
||||
}
|
||||
@@ -57,7 +58,7 @@ export function FoodSimpleFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'pluralName': json['plural_name'] == null ? undefined : json['plural_name'],
|
||||
};
|
||||
@@ -69,7 +70,6 @@ export function FoodSimpleToJSON(value?: FoodSimple | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'plural_name': value['pluralName'],
|
||||
};
|
||||
|
||||
@@ -31,6 +31,12 @@ export interface FoodSimpleRequest {
|
||||
* @memberof FoodSimpleRequest
|
||||
*/
|
||||
pluralName?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof FoodSimpleRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -53,6 +59,7 @@ export function FoodSimpleRequestFromJSONTyped(json: any, ignoreDiscriminator: b
|
||||
|
||||
'name': json['name'],
|
||||
'pluralName': json['plural_name'] == null ? undefined : json['plural_name'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -64,6 +71,7 @@ export function FoodSimpleRequestToJSON(value?: FoodSimpleRequest | null): any {
|
||||
|
||||
'name': value['name'],
|
||||
'plural_name': value['pluralName'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ export interface Group {
|
||||
* @type {number}
|
||||
* @memberof Group
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -71,6 +71,7 @@ export interface Group {
|
||||
* Check if a given object implements the Group interface.
|
||||
*/
|
||||
export function instanceOfGroup(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
return true;
|
||||
}
|
||||
@@ -85,7 +86,7 @@ export function GroupFromJSONTyped(json: any, ignoreDiscriminator: boolean): Gro
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
};
|
||||
}
|
||||
@@ -96,7 +97,6 @@ export function GroupToJSON(value?: Group | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -59,6 +59,12 @@ export interface GroupRequest {
|
||||
* @memberof GroupRequest
|
||||
*/
|
||||
name: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof GroupRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -80,6 +86,7 @@ export function GroupRequestFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
||||
return {
|
||||
|
||||
'name': json['name'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -90,6 +97,7 @@ export function GroupRequestToJSON(value?: GroupRequest | null): any {
|
||||
return {
|
||||
|
||||
'name': value['name'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface ImportLog {
|
||||
* @type {number}
|
||||
* @memberof ImportLog
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -86,6 +86,7 @@ export interface ImportLog {
|
||||
* Check if a given object implements the ImportLog interface.
|
||||
*/
|
||||
export function instanceOfImportLog(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('type' in value)) return false;
|
||||
if (!('keyword' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
@@ -103,7 +104,7 @@ export function ImportLogFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'type': json['type'],
|
||||
'msg': json['msg'] == null ? undefined : json['msg'],
|
||||
'running': json['running'] == null ? undefined : json['running'],
|
||||
@@ -121,7 +122,6 @@ export function ImportLogToJSON(value?: ImportLog | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'type': value['type'],
|
||||
'msg': value['msg'],
|
||||
'running': value['running'],
|
||||
|
||||
@@ -49,6 +49,12 @@ export interface ImportLogRequest {
|
||||
* @memberof ImportLogRequest
|
||||
*/
|
||||
importedRecipes?: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof ImportLogRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -74,6 +80,7 @@ export function ImportLogRequestFromJSONTyped(json: any, ignoreDiscriminator: bo
|
||||
'running': json['running'] == null ? undefined : json['running'],
|
||||
'totalRecipes': json['total_recipes'] == null ? undefined : json['total_recipes'],
|
||||
'importedRecipes': json['imported_recipes'] == null ? undefined : json['imported_recipes'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -88,6 +95,7 @@ export function ImportLogRequestToJSON(value?: ImportLogRequest | null): any {
|
||||
'running': value['running'],
|
||||
'total_recipes': value['totalRecipes'],
|
||||
'imported_recipes': value['importedRecipes'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ export interface Ingredient {
|
||||
* @type {number}
|
||||
* @memberof Ingredient
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {Food}
|
||||
@@ -116,6 +116,7 @@ export interface Ingredient {
|
||||
* Check if a given object implements the Ingredient interface.
|
||||
*/
|
||||
export function instanceOfIngredient(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('food' in value)) return false;
|
||||
if (!('unit' in value)) return false;
|
||||
if (!('amount' in value)) return false;
|
||||
@@ -134,7 +135,7 @@ export function IngredientFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'food': FoodFromJSON(json['food']),
|
||||
'unit': UnitFromJSON(json['unit']),
|
||||
'amount': json['amount'],
|
||||
@@ -156,7 +157,6 @@ export function IngredientToJSON(value?: Ingredient | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'food': FoodToJSON(value['food']),
|
||||
'unit': UnitToJSON(value['unit']),
|
||||
'amount': value['amount'],
|
||||
|
||||
@@ -92,6 +92,12 @@ export interface IngredientRequest {
|
||||
* @memberof IngredientRequest
|
||||
*/
|
||||
alwaysUsePluralFood?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof IngredientRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -124,6 +130,7 @@ export function IngredientRequestFromJSONTyped(json: any, ignoreDiscriminator: b
|
||||
'originalText': json['original_text'] == null ? undefined : json['original_text'],
|
||||
'alwaysUsePluralUnit': json['always_use_plural_unit'] == null ? undefined : json['always_use_plural_unit'],
|
||||
'alwaysUsePluralFood': json['always_use_plural_food'] == null ? undefined : json['always_use_plural_food'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -143,6 +150,7 @@ export function IngredientRequestToJSON(value?: IngredientRequest | null): any {
|
||||
'original_text': value['originalText'],
|
||||
'always_use_plural_unit': value['alwaysUsePluralUnit'],
|
||||
'always_use_plural_food': value['alwaysUsePluralFood'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface InviteLink {
|
||||
* @type {number}
|
||||
* @memberof InviteLink
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -92,6 +92,7 @@ export interface InviteLink {
|
||||
* Check if a given object implements the InviteLink interface.
|
||||
*/
|
||||
export function instanceOfInviteLink(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('uuid' in value)) return false;
|
||||
if (!('group' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
@@ -109,7 +110,7 @@ export function InviteLinkFromJSONTyped(json: any, ignoreDiscriminator: boolean)
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'uuid': json['uuid'],
|
||||
'email': json['email'] == null ? undefined : json['email'],
|
||||
'group': GroupFromJSON(json['group']),
|
||||
@@ -128,7 +129,6 @@ export function InviteLinkToJSON(value?: InviteLink | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'email': value['email'],
|
||||
'group': GroupToJSON(value['group']),
|
||||
'valid_until': value['validUntil'] == null ? undefined : ((value['validUntil']).toISOString().substring(0,10)),
|
||||
|
||||
@@ -62,6 +62,12 @@ export interface InviteLinkRequest {
|
||||
* @memberof InviteLinkRequest
|
||||
*/
|
||||
internalNote?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof InviteLinkRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -88,6 +94,7 @@ export function InviteLinkRequestFromJSONTyped(json: any, ignoreDiscriminator: b
|
||||
'usedBy': json['used_by'] == null ? undefined : json['used_by'],
|
||||
'reusable': json['reusable'] == null ? undefined : json['reusable'],
|
||||
'internalNote': json['internal_note'] == null ? undefined : json['internal_note'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -103,6 +110,7 @@ export function InviteLinkRequestToJSON(value?: InviteLinkRequest | null): any {
|
||||
'used_by': value['usedBy'],
|
||||
'reusable': value['reusable'],
|
||||
'internal_note': value['internalNote'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ export interface Keyword {
|
||||
* @type {number}
|
||||
* @memberof Keyword
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -113,6 +113,7 @@ export interface Keyword {
|
||||
* Check if a given object implements the Keyword interface.
|
||||
*/
|
||||
export function instanceOfKeyword(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
if (!('label' in value)) return false;
|
||||
if (!('parent' in value)) return false;
|
||||
@@ -133,7 +134,7 @@ export function KeywordFromJSONTyped(json: any, ignoreDiscriminator: boolean): K
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'label': json['label'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
@@ -151,7 +152,6 @@ export function KeywordToJSON(value?: Keyword | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
};
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface KeywordLabel {
|
||||
* @type {number}
|
||||
* @memberof KeywordLabel
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -37,6 +37,7 @@ export interface KeywordLabel {
|
||||
* Check if a given object implements the KeywordLabel interface.
|
||||
*/
|
||||
export function instanceOfKeywordLabel(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('label' in value)) return false;
|
||||
return true;
|
||||
}
|
||||
@@ -51,7 +52,7 @@ export function KeywordLabelFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'label': json['label'],
|
||||
};
|
||||
}
|
||||
@@ -62,7 +63,6 @@ export function KeywordLabelToJSON(value?: KeywordLabel | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -65,6 +65,12 @@ export interface KeywordRequest {
|
||||
* @memberof KeywordRequest
|
||||
*/
|
||||
description?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof KeywordRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -87,6 +93,7 @@ export function KeywordRequestFromJSONTyped(json: any, ignoreDiscriminator: bool
|
||||
|
||||
'name': json['name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -98,6 +105,7 @@ export function KeywordRequestToJSON(value?: KeywordRequest | null): any {
|
||||
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ export interface MealPlan {
|
||||
* @type {number}
|
||||
* @memberof MealPlan
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -128,6 +128,7 @@ export interface MealPlan {
|
||||
* Check if a given object implements the MealPlan interface.
|
||||
*/
|
||||
export function instanceOfMealPlan(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('servings' in value)) return false;
|
||||
if (!('noteMarkdown' in value)) return false;
|
||||
if (!('fromDate' in value)) return false;
|
||||
@@ -149,7 +150,7 @@ export function MealPlanFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'title': json['title'] == null ? undefined : json['title'],
|
||||
'recipe': json['recipe'] == null ? undefined : RecipeOverviewFromJSON(json['recipe']),
|
||||
'servings': json['servings'],
|
||||
@@ -172,7 +173,6 @@ export function MealPlanToJSON(value?: MealPlan | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'title': value['title'],
|
||||
'recipe': RecipeOverviewToJSON(value['recipe']),
|
||||
'servings': value['servings'],
|
||||
|
||||
@@ -86,6 +86,12 @@ export interface MealPlanRequest {
|
||||
* @memberof MealPlanRequest
|
||||
*/
|
||||
shared?: Array<UserRequest>;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof MealPlanRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -116,6 +122,7 @@ export function MealPlanRequestFromJSONTyped(json: any, ignoreDiscriminator: boo
|
||||
'toDate': json['to_date'] == null ? undefined : (new Date(json['to_date'])),
|
||||
'mealType': MealTypeRequestFromJSON(json['meal_type']),
|
||||
'shared': json['shared'] == null ? undefined : ((json['shared'] as Array<any>).map(UserRequestFromJSON)),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -133,6 +140,7 @@ export function MealPlanRequestToJSON(value?: MealPlanRequest | null): any {
|
||||
'to_date': value['toDate'] == null ? undefined : ((value['toDate']).toISOString().substring(0,10)),
|
||||
'meal_type': MealTypeRequestToJSON(value['mealType']),
|
||||
'shared': value['shared'] == null ? undefined : ((value['shared'] as Array<any>).map(UserRequestToJSON)),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface MealType {
|
||||
* @type {number}
|
||||
* @memberof MealType
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -61,6 +61,7 @@ export interface MealType {
|
||||
* Check if a given object implements the MealType interface.
|
||||
*/
|
||||
export function instanceOfMealType(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
if (!('createdBy' in value)) return false;
|
||||
return true;
|
||||
@@ -76,7 +77,7 @@ export function MealTypeFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'color': json['color'] == null ? undefined : json['color'],
|
||||
@@ -91,7 +92,6 @@ export function MealTypeToJSON(value?: MealType | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'order': value['order'],
|
||||
'color': value['color'],
|
||||
|
||||
@@ -43,6 +43,12 @@ export interface MealTypeRequest {
|
||||
* @memberof MealTypeRequest
|
||||
*/
|
||||
_default?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof MealTypeRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -67,6 +73,7 @@ export function MealTypeRequestFromJSONTyped(json: any, ignoreDiscriminator: boo
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'color': json['color'] == null ? undefined : json['color'],
|
||||
'_default': json['default'] == null ? undefined : json['default'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -80,6 +87,7 @@ export function MealTypeRequestToJSON(value?: MealTypeRequest | null): any {
|
||||
'order': value['order'],
|
||||
'color': value['color'],
|
||||
'default': value['_default'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface NutritionInformation {
|
||||
* @type {number}
|
||||
* @memberof NutritionInformation
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -61,6 +61,7 @@ export interface NutritionInformation {
|
||||
* Check if a given object implements the NutritionInformation interface.
|
||||
*/
|
||||
export function instanceOfNutritionInformation(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('carbohydrates' in value)) return false;
|
||||
if (!('fats' in value)) return false;
|
||||
if (!('proteins' in value)) return false;
|
||||
@@ -78,7 +79,7 @@ export function NutritionInformationFromJSONTyped(json: any, ignoreDiscriminator
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'carbohydrates': json['carbohydrates'],
|
||||
'fats': json['fats'],
|
||||
'proteins': json['proteins'],
|
||||
@@ -93,7 +94,6 @@ export function NutritionInformationToJSON(value?: NutritionInformation | null):
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'carbohydrates': value['carbohydrates'],
|
||||
'fats': value['fats'],
|
||||
'proteins': value['proteins'],
|
||||
|
||||
@@ -49,6 +49,12 @@ export interface NutritionInformationRequest {
|
||||
* @memberof NutritionInformationRequest
|
||||
*/
|
||||
source?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof NutritionInformationRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -77,6 +83,7 @@ export function NutritionInformationRequestFromJSONTyped(json: any, ignoreDiscri
|
||||
'proteins': json['proteins'],
|
||||
'calories': json['calories'],
|
||||
'source': json['source'] == null ? undefined : json['source'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -91,6 +98,7 @@ export function NutritionInformationRequestToJSON(value?: NutritionInformationRe
|
||||
'proteins': value['proteins'],
|
||||
'calories': value['calories'],
|
||||
'source': value['source'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ export interface OpenDataCategory {
|
||||
* @type {number}
|
||||
* @memberof OpenDataCategory
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataVersion}
|
||||
@@ -108,6 +108,7 @@ export interface OpenDataCategory {
|
||||
* Check if a given object implements the OpenDataCategory interface.
|
||||
*/
|
||||
export function instanceOfOpenDataCategory(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('version' in value)) return false;
|
||||
if (!('slug' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
@@ -125,7 +126,7 @@ export function OpenDataCategoryFromJSONTyped(json: any, ignoreDiscriminator: bo
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'version': OpenDataVersionFromJSON(json['version']),
|
||||
'slug': json['slug'],
|
||||
'name': json['name'],
|
||||
@@ -141,7 +142,6 @@ export function OpenDataCategoryToJSON(value?: OpenDataCategory | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'version': OpenDataVersionToJSON(value['version']),
|
||||
'slug': value['slug'],
|
||||
'name': value['name'],
|
||||
|
||||
@@ -90,6 +90,12 @@ export interface OpenDataCategoryRequest {
|
||||
* @memberof OpenDataCategoryRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataCategoryRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -117,6 +123,7 @@ export function OpenDataCategoryRequestFromJSONTyped(json: any, ignoreDiscrimina
|
||||
'name': json['name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -131,6 +138,7 @@ export function OpenDataCategoryRequestToJSON(value?: OpenDataCategoryRequest |
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ export interface OpenDataConversion {
|
||||
* @type {number}
|
||||
* @memberof OpenDataConversion
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataVersion}
|
||||
@@ -110,6 +110,7 @@ export interface OpenDataConversion {
|
||||
* Check if a given object implements the OpenDataConversion interface.
|
||||
*/
|
||||
export function instanceOfOpenDataConversion(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('version' in value)) return false;
|
||||
if (!('slug' in value)) return false;
|
||||
if (!('food' in value)) return false;
|
||||
@@ -132,7 +133,7 @@ export function OpenDataConversionFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'version': OpenDataVersionFromJSON(json['version']),
|
||||
'slug': json['slug'],
|
||||
'food': OpenDataFoodFromJSON(json['food']),
|
||||
@@ -152,7 +153,6 @@ export function OpenDataConversionToJSON(value?: OpenDataConversion | null): any
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'version': OpenDataVersionToJSON(value['version']),
|
||||
'slug': value['slug'],
|
||||
'food': OpenDataFoodToJSON(value['food']),
|
||||
|
||||
@@ -92,6 +92,12 @@ export interface OpenDataConversionRequest {
|
||||
* @memberof OpenDataConversionRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataConversionRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -128,6 +134,7 @@ export function OpenDataConversionRequestFromJSONTyped(json: any, ignoreDiscrimi
|
||||
'convertedUnit': OpenDataUnitRequestFromJSON(json['converted_unit']),
|
||||
'source': json['source'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -146,6 +153,7 @@ export function OpenDataConversionRequestToJSON(value?: OpenDataConversionReques
|
||||
'converted_unit': OpenDataUnitRequestToJSON(value['convertedUnit']),
|
||||
'source': value['source'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@ export interface OpenDataFood {
|
||||
* @type {number}
|
||||
* @memberof OpenDataFood
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataVersion}
|
||||
@@ -186,6 +186,7 @@ export interface OpenDataFood {
|
||||
* Check if a given object implements the OpenDataFood interface.
|
||||
*/
|
||||
export function instanceOfOpenDataFood(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('version' in value)) return false;
|
||||
if (!('slug' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
@@ -208,7 +209,7 @@ export function OpenDataFoodFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'version': OpenDataVersionFromJSON(json['version']),
|
||||
'slug': json['slug'],
|
||||
'name': json['name'],
|
||||
@@ -234,7 +235,6 @@ export function OpenDataFoodToJSON(value?: OpenDataFood | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'version': OpenDataVersionToJSON(value['version']),
|
||||
'slug': value['slug'],
|
||||
'name': value['name'],
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface OpenDataFoodProperty {
|
||||
* @type {number}
|
||||
* @memberof OpenDataFoodProperty
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataProperty}
|
||||
@@ -50,6 +50,7 @@ export interface OpenDataFoodProperty {
|
||||
* Check if a given object implements the OpenDataFoodProperty interface.
|
||||
*/
|
||||
export function instanceOfOpenDataFoodProperty(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('property' in value)) return false;
|
||||
if (!('propertyAmount' in value)) return false;
|
||||
return true;
|
||||
@@ -65,7 +66,7 @@ export function OpenDataFoodPropertyFromJSONTyped(json: any, ignoreDiscriminator
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'property': OpenDataPropertyFromJSON(json['property']),
|
||||
'propertyAmount': json['property_amount'],
|
||||
};
|
||||
@@ -77,7 +78,6 @@ export function OpenDataFoodPropertyToJSON(value?: OpenDataFoodProperty | null):
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'property': OpenDataPropertyToJSON(value['property']),
|
||||
'property_amount': value['propertyAmount'],
|
||||
};
|
||||
|
||||
@@ -38,6 +38,12 @@ export interface OpenDataFoodPropertyRequest {
|
||||
* @memberof OpenDataFoodPropertyRequest
|
||||
*/
|
||||
propertyAmount: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataFoodPropertyRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -61,6 +67,7 @@ export function OpenDataFoodPropertyRequestFromJSONTyped(json: any, ignoreDiscri
|
||||
|
||||
'property': OpenDataPropertyRequestFromJSON(json['property']),
|
||||
'propertyAmount': json['property_amount'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -72,6 +79,7 @@ export function OpenDataFoodPropertyRequestToJSON(value?: OpenDataFoodPropertyRe
|
||||
|
||||
'property': OpenDataPropertyRequestToJSON(value['property']),
|
||||
'property_amount': value['propertyAmount'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -168,6 +168,12 @@ export interface OpenDataFoodRequest {
|
||||
* @memberof OpenDataFoodRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataFoodRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -210,6 +216,7 @@ export function OpenDataFoodRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'propertiesSource': json['properties_source'] == null ? undefined : json['properties_source'],
|
||||
'fdcId': json['fdc_id'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -234,6 +241,7 @@ export function OpenDataFoodRequestToJSON(value?: OpenDataFoodRequest | null): a
|
||||
'properties_source': value['propertiesSource'],
|
||||
'fdc_id': value['fdcId'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ export interface OpenDataProperty {
|
||||
* @type {number}
|
||||
* @memberof OpenDataProperty
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataVersion}
|
||||
@@ -114,6 +114,7 @@ export interface OpenDataProperty {
|
||||
* Check if a given object implements the OpenDataProperty interface.
|
||||
*/
|
||||
export function instanceOfOpenDataProperty(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('version' in value)) return false;
|
||||
if (!('slug' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
@@ -131,7 +132,7 @@ export function OpenDataPropertyFromJSONTyped(json: any, ignoreDiscriminator: bo
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'version': OpenDataVersionFromJSON(json['version']),
|
||||
'slug': json['slug'],
|
||||
'name': json['name'],
|
||||
@@ -148,7 +149,6 @@ export function OpenDataPropertyToJSON(value?: OpenDataProperty | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'version': OpenDataVersionToJSON(value['version']),
|
||||
'slug': value['slug'],
|
||||
'name': value['name'],
|
||||
|
||||
@@ -96,6 +96,12 @@ export interface OpenDataPropertyRequest {
|
||||
* @memberof OpenDataPropertyRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataPropertyRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -124,6 +130,7 @@ export function OpenDataPropertyRequestFromJSONTyped(json: any, ignoreDiscrimina
|
||||
'unit': json['unit'] == null ? undefined : json['unit'],
|
||||
'fdcId': json['fdc_id'] == null ? undefined : json['fdc_id'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -139,6 +146,7 @@ export function OpenDataPropertyRequestToJSON(value?: OpenDataPropertyRequest |
|
||||
'unit': value['unit'],
|
||||
'fdc_id': value['fdcId'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ export interface OpenDataStore {
|
||||
* @type {number}
|
||||
* @memberof OpenDataStore
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataVersion}
|
||||
@@ -80,6 +80,7 @@ export interface OpenDataStore {
|
||||
* Check if a given object implements the OpenDataStore interface.
|
||||
*/
|
||||
export function instanceOfOpenDataStore(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('version' in value)) return false;
|
||||
if (!('slug' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
@@ -98,7 +99,7 @@ export function OpenDataStoreFromJSONTyped(json: any, ignoreDiscriminator: boole
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'version': OpenDataVersionFromJSON(json['version']),
|
||||
'slug': json['slug'],
|
||||
'name': json['name'],
|
||||
@@ -114,7 +115,6 @@ export function OpenDataStoreToJSON(value?: OpenDataStore | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'version': OpenDataVersionToJSON(value['version']),
|
||||
'slug': value['slug'],
|
||||
'name': value['name'],
|
||||
|
||||
@@ -31,7 +31,7 @@ export interface OpenDataStoreCategory {
|
||||
* @type {number}
|
||||
* @memberof OpenDataStoreCategory
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataCategory}
|
||||
@@ -56,6 +56,7 @@ export interface OpenDataStoreCategory {
|
||||
* Check if a given object implements the OpenDataStoreCategory interface.
|
||||
*/
|
||||
export function instanceOfOpenDataStoreCategory(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('category' in value)) return false;
|
||||
if (!('store' in value)) return false;
|
||||
return true;
|
||||
@@ -71,7 +72,7 @@ export function OpenDataStoreCategoryFromJSONTyped(json: any, ignoreDiscriminato
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'category': OpenDataCategoryFromJSON(json['category']),
|
||||
'store': json['store'],
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
@@ -84,7 +85,6 @@ export function OpenDataStoreCategoryToJSON(value?: OpenDataStoreCategory | null
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'category': OpenDataCategoryToJSON(value['category']),
|
||||
'store': value['store'],
|
||||
'order': value['order'],
|
||||
|
||||
@@ -44,6 +44,12 @@ export interface OpenDataStoreCategoryRequest {
|
||||
* @memberof OpenDataStoreCategoryRequest
|
||||
*/
|
||||
order?: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataStoreCategoryRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -68,6 +74,7 @@ export function OpenDataStoreCategoryRequestFromJSONTyped(json: any, ignoreDiscr
|
||||
'category': OpenDataCategoryRequestFromJSON(json['category']),
|
||||
'store': json['store'],
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -80,6 +87,7 @@ export function OpenDataStoreCategoryRequestToJSON(value?: OpenDataStoreCategory
|
||||
'category': OpenDataCategoryRequestToJSON(value['category']),
|
||||
'store': value['store'],
|
||||
'order': value['order'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -62,6 +62,12 @@ export interface OpenDataStoreRequest {
|
||||
* @memberof OpenDataStoreRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataStoreRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -90,6 +96,7 @@ export function OpenDataStoreRequestFromJSONTyped(json: any, ignoreDiscriminator
|
||||
'name': json['name'],
|
||||
'categoryToStore': (json['category_to_store'] == null ? null : (json['category_to_store'] as Array<any>).map(OpenDataStoreCategoryRequestFromJSON)),
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -104,6 +111,7 @@ export function OpenDataStoreRequestToJSON(value?: OpenDataStoreRequest | null):
|
||||
'name': value['name'],
|
||||
'category_to_store': (value['categoryToStore'] == null ? null : (value['categoryToStore'] as Array<any>).map(OpenDataStoreCategoryRequestToJSON)),
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -77,7 +77,7 @@ export interface OpenDataUnit {
|
||||
* @type {number}
|
||||
* @memberof OpenDataUnit
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {OpenDataVersion}
|
||||
@@ -132,6 +132,7 @@ export interface OpenDataUnit {
|
||||
* Check if a given object implements the OpenDataUnit interface.
|
||||
*/
|
||||
export function instanceOfOpenDataUnit(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('version' in value)) return false;
|
||||
if (!('slug' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
@@ -150,7 +151,7 @@ export function OpenDataUnitFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'version': OpenDataVersionFromJSON(json['version']),
|
||||
'slug': json['slug'],
|
||||
'name': json['name'],
|
||||
@@ -168,7 +169,6 @@ export function OpenDataUnitToJSON(value?: OpenDataUnit | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'version': OpenDataVersionToJSON(value['version']),
|
||||
'slug': value['slug'],
|
||||
'name': value['name'],
|
||||
|
||||
@@ -114,6 +114,12 @@ export interface OpenDataUnitRequest {
|
||||
* @memberof OpenDataUnitRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataUnitRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -144,6 +150,7 @@ export function OpenDataUnitRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'baseUnit': json['base_unit'] == null ? undefined : BaseUnitEnumFromJSON(json['base_unit']),
|
||||
'type': OpenDataUnitTypeEnumFromJSON(json['type']),
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -160,6 +167,7 @@ export function OpenDataUnitRequestToJSON(value?: OpenDataUnitRequest | null): a
|
||||
'base_unit': BaseUnitEnumToJSON(value['baseUnit']),
|
||||
'type': OpenDataUnitTypeEnumToJSON(value['type']),
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ export interface OpenDataVersion {
|
||||
* @type {number}
|
||||
* @memberof OpenDataVersion
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -83,6 +83,7 @@ export interface OpenDataVersion {
|
||||
* Check if a given object implements the OpenDataVersion interface.
|
||||
*/
|
||||
export function instanceOfOpenDataVersion(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
if (!('code' in value)) return false;
|
||||
return true;
|
||||
@@ -98,7 +99,7 @@ export function OpenDataVersionFromJSONTyped(json: any, ignoreDiscriminator: boo
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'code': json['code'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
@@ -111,7 +112,6 @@ export function OpenDataVersionToJSON(value?: OpenDataVersion | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'code': value['code'],
|
||||
'comment': value['comment'],
|
||||
|
||||
@@ -71,6 +71,12 @@ export interface OpenDataVersionRequest {
|
||||
* @memberof OpenDataVersionRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof OpenDataVersionRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -95,6 +101,7 @@ export function OpenDataVersionRequestFromJSONTyped(json: any, ignoreDiscriminat
|
||||
'name': json['name'],
|
||||
'code': json['code'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -107,6 +114,7 @@ export function OpenDataVersionRequestToJSON(value?: OpenDataVersionRequest | nu
|
||||
'name': value['name'],
|
||||
'code': value['code'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,6 +31,12 @@ export interface PatchedAccessTokenRequest {
|
||||
* @memberof PatchedAccessTokenRequest
|
||||
*/
|
||||
scope?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedAccessTokenRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -52,6 +58,7 @@ export function PatchedAccessTokenRequestFromJSONTyped(json: any, ignoreDiscrimi
|
||||
|
||||
'expires': json['expires'] == null ? undefined : (new Date(json['expires'])),
|
||||
'scope': json['scope'] == null ? undefined : json['scope'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -63,6 +70,7 @@ export function PatchedAccessTokenRequestToJSON(value?: PatchedAccessTokenReques
|
||||
|
||||
'expires': value['expires'] == null ? undefined : ((value['expires']).toISOString()),
|
||||
'scope': value['scope'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -74,6 +74,12 @@ export interface PatchedAutomationRequest {
|
||||
* @memberof PatchedAutomationRequest
|
||||
*/
|
||||
disabled?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedAutomationRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -101,6 +107,7 @@ export function PatchedAutomationRequestFromJSONTyped(json: any, ignoreDiscrimin
|
||||
'param3': json['param_3'] == null ? undefined : json['param_3'],
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'disabled': json['disabled'] == null ? undefined : json['disabled'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -118,6 +125,7 @@ export function PatchedAutomationRequestToJSON(value?: PatchedAutomationRequest
|
||||
'param_3': value['param3'],
|
||||
'order': value['order'],
|
||||
'disabled': value['disabled'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,6 +31,12 @@ export interface PatchedBookmarkletImportRequest {
|
||||
* @memberof PatchedBookmarkletImportRequest
|
||||
*/
|
||||
html?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedBookmarkletImportRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -52,6 +58,7 @@ export function PatchedBookmarkletImportRequestFromJSONTyped(json: any, ignoreDi
|
||||
|
||||
'url': json['url'] == null ? undefined : json['url'],
|
||||
'html': json['html'] == null ? undefined : json['html'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -63,6 +70,7 @@ export function PatchedBookmarkletImportRequestToJSON(value?: PatchedBookmarklet
|
||||
|
||||
'url': value['url'],
|
||||
'html': value['html'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -67,6 +67,12 @@ export interface PatchedConnectorConfigConfigRequest {
|
||||
* @memberof PatchedConnectorConfigConfigRequest
|
||||
*/
|
||||
onShoppingListEntryDeletedEnabled?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedConnectorConfigConfigRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -94,6 +100,7 @@ export function PatchedConnectorConfigConfigRequestFromJSONTyped(json: any, igno
|
||||
'onShoppingListEntryCreatedEnabled': json['on_shopping_list_entry_created_enabled'] == null ? undefined : json['on_shopping_list_entry_created_enabled'],
|
||||
'onShoppingListEntryUpdatedEnabled': json['on_shopping_list_entry_updated_enabled'] == null ? undefined : json['on_shopping_list_entry_updated_enabled'],
|
||||
'onShoppingListEntryDeletedEnabled': json['on_shopping_list_entry_deleted_enabled'] == null ? undefined : json['on_shopping_list_entry_deleted_enabled'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -111,6 +118,7 @@ export function PatchedConnectorConfigConfigRequestToJSON(value?: PatchedConnect
|
||||
'on_shopping_list_entry_created_enabled': value['onShoppingListEntryCreatedEnabled'],
|
||||
'on_shopping_list_entry_updated_enabled': value['onShoppingListEntryUpdatedEnabled'],
|
||||
'on_shopping_list_entry_deleted_enabled': value['onShoppingListEntryDeletedEnabled'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -49,6 +49,12 @@ export interface PatchedCookLogRequest {
|
||||
* @memberof PatchedCookLogRequest
|
||||
*/
|
||||
createdAt?: Date;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedCookLogRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -73,6 +79,7 @@ export function PatchedCookLogRequestFromJSONTyped(json: any, ignoreDiscriminato
|
||||
'rating': json['rating'] == null ? undefined : json['rating'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'createdAt': json['created_at'] == null ? undefined : (new Date(json['created_at'])),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -87,6 +94,7 @@ export function PatchedCookLogRequestToJSON(value?: PatchedCookLogRequest | null
|
||||
'rating': value['rating'],
|
||||
'comment': value['comment'],
|
||||
'created_at': value['createdAt'] == null ? undefined : ((value['createdAt']).toISOString()),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -44,6 +44,12 @@ export interface PatchedCustomFilterRequest {
|
||||
* @memberof PatchedCustomFilterRequest
|
||||
*/
|
||||
shared?: Array<UserRequest>;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedCustomFilterRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -66,6 +72,7 @@ export function PatchedCustomFilterRequestFromJSONTyped(json: any, ignoreDiscrim
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'search': json['search'] == null ? undefined : json['search'],
|
||||
'shared': json['shared'] == null ? undefined : ((json['shared'] as Array<any>).map(UserRequestFromJSON)),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -78,6 +85,7 @@ export function PatchedCustomFilterRequestToJSON(value?: PatchedCustomFilterRequ
|
||||
'name': value['name'],
|
||||
'search': value['search'],
|
||||
'shared': value['shared'] == null ? undefined : ((value['shared'] as Array<any>).map(UserRequestToJSON)),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -61,6 +61,12 @@ export interface PatchedExportLogRequest {
|
||||
* @memberof PatchedExportLogRequest
|
||||
*/
|
||||
possiblyNotExpired?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedExportLogRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -87,6 +93,7 @@ export function PatchedExportLogRequestFromJSONTyped(json: any, ignoreDiscrimina
|
||||
'exportedRecipes': json['exported_recipes'] == null ? undefined : json['exported_recipes'],
|
||||
'cacheDuration': json['cache_duration'] == null ? undefined : json['cache_duration'],
|
||||
'possiblyNotExpired': json['possibly_not_expired'] == null ? undefined : json['possibly_not_expired'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -103,6 +110,7 @@ export function PatchedExportLogRequestToJSON(value?: PatchedExportLogRequest |
|
||||
'exported_recipes': value['exportedRecipes'],
|
||||
'cache_duration': value['cacheDuration'],
|
||||
'possibly_not_expired': value['possiblyNotExpired'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -198,6 +198,12 @@ export interface PatchedFoodRequest {
|
||||
* @memberof PatchedFoodRequest
|
||||
*/
|
||||
openDataSlug?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedFoodRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -235,6 +241,7 @@ export function PatchedFoodRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'substituteChildren': json['substitute_children'] == null ? undefined : json['substitute_children'],
|
||||
'childInheritFields': json['child_inherit_fields'] == null ? undefined : ((json['child_inherit_fields'] as Array<any>).map(FoodInheritFieldRequestFromJSON)),
|
||||
'openDataSlug': json['open_data_slug'] == null ? undefined : json['open_data_slug'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -262,6 +269,7 @@ export function PatchedFoodRequestToJSON(value?: PatchedFoodRequest | null): any
|
||||
'substitute_children': value['substituteChildren'],
|
||||
'child_inherit_fields': value['childInheritFields'] == null ? undefined : ((value['childInheritFields'] as Array<any>).map(FoodInheritFieldRequestToJSON)),
|
||||
'open_data_slug': value['openDataSlug'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -49,6 +49,12 @@ export interface PatchedImportLogRequest {
|
||||
* @memberof PatchedImportLogRequest
|
||||
*/
|
||||
importedRecipes?: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedImportLogRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -73,6 +79,7 @@ export function PatchedImportLogRequestFromJSONTyped(json: any, ignoreDiscrimina
|
||||
'running': json['running'] == null ? undefined : json['running'],
|
||||
'totalRecipes': json['total_recipes'] == null ? undefined : json['total_recipes'],
|
||||
'importedRecipes': json['imported_recipes'] == null ? undefined : json['imported_recipes'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -87,6 +94,7 @@ export function PatchedImportLogRequestToJSON(value?: PatchedImportLogRequest |
|
||||
'running': value['running'],
|
||||
'total_recipes': value['totalRecipes'],
|
||||
'imported_recipes': value['importedRecipes'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -92,6 +92,12 @@ export interface PatchedIngredientRequest {
|
||||
* @memberof PatchedIngredientRequest
|
||||
*/
|
||||
alwaysUsePluralFood?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedIngredientRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -121,6 +127,7 @@ export function PatchedIngredientRequestFromJSONTyped(json: any, ignoreDiscrimin
|
||||
'originalText': json['original_text'] == null ? undefined : json['original_text'],
|
||||
'alwaysUsePluralUnit': json['always_use_plural_unit'] == null ? undefined : json['always_use_plural_unit'],
|
||||
'alwaysUsePluralFood': json['always_use_plural_food'] == null ? undefined : json['always_use_plural_food'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -140,6 +147,7 @@ export function PatchedIngredientRequestToJSON(value?: PatchedIngredientRequest
|
||||
'original_text': value['originalText'],
|
||||
'always_use_plural_unit': value['alwaysUsePluralUnit'],
|
||||
'always_use_plural_food': value['alwaysUsePluralFood'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -62,6 +62,12 @@ export interface PatchedInviteLinkRequest {
|
||||
* @memberof PatchedInviteLinkRequest
|
||||
*/
|
||||
internalNote?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedInviteLinkRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -87,6 +93,7 @@ export function PatchedInviteLinkRequestFromJSONTyped(json: any, ignoreDiscrimin
|
||||
'usedBy': json['used_by'] == null ? undefined : json['used_by'],
|
||||
'reusable': json['reusable'] == null ? undefined : json['reusable'],
|
||||
'internalNote': json['internal_note'] == null ? undefined : json['internal_note'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -102,6 +109,7 @@ export function PatchedInviteLinkRequestToJSON(value?: PatchedInviteLinkRequest
|
||||
'used_by': value['usedBy'],
|
||||
'reusable': value['reusable'],
|
||||
'internal_note': value['internalNote'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -65,6 +65,12 @@ export interface PatchedKeywordRequest {
|
||||
* @memberof PatchedKeywordRequest
|
||||
*/
|
||||
description?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedKeywordRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -86,6 +92,7 @@ export function PatchedKeywordRequestFromJSONTyped(json: any, ignoreDiscriminato
|
||||
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -97,6 +104,7 @@ export function PatchedKeywordRequestToJSON(value?: PatchedKeywordRequest | null
|
||||
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -86,6 +86,12 @@ export interface PatchedMealPlanRequest {
|
||||
* @memberof PatchedMealPlanRequest
|
||||
*/
|
||||
shared?: Array<UserRequest>;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedMealPlanRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -113,6 +119,7 @@ export function PatchedMealPlanRequestFromJSONTyped(json: any, ignoreDiscriminat
|
||||
'toDate': json['to_date'] == null ? undefined : (new Date(json['to_date'])),
|
||||
'mealType': json['meal_type'] == null ? undefined : MealTypeRequestFromJSON(json['meal_type']),
|
||||
'shared': json['shared'] == null ? undefined : ((json['shared'] as Array<any>).map(UserRequestFromJSON)),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -130,6 +137,7 @@ export function PatchedMealPlanRequestToJSON(value?: PatchedMealPlanRequest | nu
|
||||
'to_date': value['toDate'] == null ? undefined : ((value['toDate']).toISOString().substring(0,10)),
|
||||
'meal_type': MealTypeRequestToJSON(value['mealType']),
|
||||
'shared': value['shared'] == null ? undefined : ((value['shared'] as Array<any>).map(UserRequestToJSON)),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -43,6 +43,12 @@ export interface PatchedMealTypeRequest {
|
||||
* @memberof PatchedMealTypeRequest
|
||||
*/
|
||||
_default?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedMealTypeRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -66,6 +72,7 @@ export function PatchedMealTypeRequestFromJSONTyped(json: any, ignoreDiscriminat
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'color': json['color'] == null ? undefined : json['color'],
|
||||
'_default': json['default'] == null ? undefined : json['default'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -79,6 +86,7 @@ export function PatchedMealTypeRequestToJSON(value?: PatchedMealTypeRequest | nu
|
||||
'order': value['order'],
|
||||
'color': value['color'],
|
||||
'default': value['_default'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -90,6 +90,12 @@ export interface PatchedOpenDataCategoryRequest {
|
||||
* @memberof PatchedOpenDataCategoryRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedOpenDataCategoryRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -114,6 +120,7 @@ export function PatchedOpenDataCategoryRequestFromJSONTyped(json: any, ignoreDis
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -128,6 +135,7 @@ export function PatchedOpenDataCategoryRequestToJSON(value?: PatchedOpenDataCate
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -92,6 +92,12 @@ export interface PatchedOpenDataConversionRequest {
|
||||
* @memberof PatchedOpenDataConversionRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedOpenDataConversionRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -120,6 +126,7 @@ export function PatchedOpenDataConversionRequestFromJSONTyped(json: any, ignoreD
|
||||
'convertedUnit': json['converted_unit'] == null ? undefined : OpenDataUnitRequestFromJSON(json['converted_unit']),
|
||||
'source': json['source'] == null ? undefined : json['source'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -138,6 +145,7 @@ export function PatchedOpenDataConversionRequestToJSON(value?: PatchedOpenDataCo
|
||||
'converted_unit': OpenDataUnitRequestToJSON(value['convertedUnit']),
|
||||
'source': value['source'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -168,6 +168,12 @@ export interface PatchedOpenDataFoodRequest {
|
||||
* @memberof PatchedOpenDataFoodRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedOpenDataFoodRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -202,6 +208,7 @@ export function PatchedOpenDataFoodRequestFromJSONTyped(json: any, ignoreDiscrim
|
||||
'propertiesSource': json['properties_source'] == null ? undefined : json['properties_source'],
|
||||
'fdcId': json['fdc_id'] == null ? undefined : json['fdc_id'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -226,6 +233,7 @@ export function PatchedOpenDataFoodRequestToJSON(value?: PatchedOpenDataFoodRequ
|
||||
'properties_source': value['propertiesSource'],
|
||||
'fdc_id': value['fdcId'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -96,6 +96,12 @@ export interface PatchedOpenDataPropertyRequest {
|
||||
* @memberof PatchedOpenDataPropertyRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedOpenDataPropertyRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -121,6 +127,7 @@ export function PatchedOpenDataPropertyRequestFromJSONTyped(json: any, ignoreDis
|
||||
'unit': json['unit'] == null ? undefined : json['unit'],
|
||||
'fdcId': json['fdc_id'] == null ? undefined : json['fdc_id'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -136,6 +143,7 @@ export function PatchedOpenDataPropertyRequestToJSON(value?: PatchedOpenDataProp
|
||||
'unit': value['unit'],
|
||||
'fdc_id': value['fdcId'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -62,6 +62,12 @@ export interface PatchedOpenDataStoreRequest {
|
||||
* @memberof PatchedOpenDataStoreRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedOpenDataStoreRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -86,6 +92,7 @@ export function PatchedOpenDataStoreRequestFromJSONTyped(json: any, ignoreDiscri
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'categoryToStore': json['category_to_store'] == null ? undefined : ((json['category_to_store'] as Array<any>).map(OpenDataStoreCategoryRequestFromJSON)),
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -100,6 +107,7 @@ export function PatchedOpenDataStoreRequestToJSON(value?: PatchedOpenDataStoreRe
|
||||
'name': value['name'],
|
||||
'category_to_store': value['categoryToStore'] == null ? undefined : ((value['categoryToStore'] as Array<any>).map(OpenDataStoreCategoryRequestToJSON)),
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -114,6 +114,12 @@ export interface PatchedOpenDataUnitRequest {
|
||||
* @memberof PatchedOpenDataUnitRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedOpenDataUnitRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -140,6 +146,7 @@ export function PatchedOpenDataUnitRequestFromJSONTyped(json: any, ignoreDiscrim
|
||||
'baseUnit': json['base_unit'] == null ? undefined : BaseUnitEnumFromJSON(json['base_unit']),
|
||||
'type': json['type'] == null ? undefined : OpenDataUnitTypeEnumFromJSON(json['type']),
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -156,6 +163,7 @@ export function PatchedOpenDataUnitRequestToJSON(value?: PatchedOpenDataUnitRequ
|
||||
'base_unit': BaseUnitEnumToJSON(value['baseUnit']),
|
||||
'type': OpenDataUnitTypeEnumToJSON(value['type']),
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -71,6 +71,12 @@ export interface PatchedOpenDataVersionRequest {
|
||||
* @memberof PatchedOpenDataVersionRequest
|
||||
*/
|
||||
comment?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedOpenDataVersionRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -93,6 +99,7 @@ export function PatchedOpenDataVersionRequestFromJSONTyped(json: any, ignoreDisc
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'code': json['code'] == null ? undefined : json['code'],
|
||||
'comment': json['comment'] == null ? undefined : json['comment'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -105,6 +112,7 @@ export function PatchedOpenDataVersionRequestToJSON(value?: PatchedOpenDataVersi
|
||||
'name': value['name'],
|
||||
'code': value['code'],
|
||||
'comment': value['comment'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -72,6 +72,12 @@ export interface PatchedPropertyRequest {
|
||||
* @memberof PatchedPropertyRequest
|
||||
*/
|
||||
propertyType?: PropertyTypeRequest;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedPropertyRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -93,6 +99,7 @@ export function PatchedPropertyRequestFromJSONTyped(json: any, ignoreDiscriminat
|
||||
|
||||
'propertyAmount': json['property_amount'] == null ? undefined : json['property_amount'],
|
||||
'propertyType': json['property_type'] == null ? undefined : PropertyTypeRequestFromJSON(json['property_type']),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -104,6 +111,7 @@ export function PatchedPropertyRequestToJSON(value?: PatchedPropertyRequest | nu
|
||||
|
||||
'property_amount': value['propertyAmount'],
|
||||
'property_type': PropertyTypeRequestToJSON(value['propertyType']),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,6 +31,12 @@ export interface PatchedRecipeBookEntryRequest {
|
||||
* @memberof PatchedRecipeBookEntryRequest
|
||||
*/
|
||||
recipe?: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedRecipeBookEntryRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -52,6 +58,7 @@ export function PatchedRecipeBookEntryRequestFromJSONTyped(json: any, ignoreDisc
|
||||
|
||||
'book': json['book'] == null ? undefined : json['book'],
|
||||
'recipe': json['recipe'] == null ? undefined : json['recipe'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -63,6 +70,7 @@ export function PatchedRecipeBookEntryRequestToJSON(value?: PatchedRecipeBookEnt
|
||||
|
||||
'book': value['book'],
|
||||
'recipe': value['recipe'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -62,6 +62,12 @@ export interface PatchedRecipeBookRequest {
|
||||
* @memberof PatchedRecipeBookRequest
|
||||
*/
|
||||
order?: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedRecipeBookRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -86,6 +92,7 @@ export function PatchedRecipeBookRequestFromJSONTyped(json: any, ignoreDiscrimin
|
||||
'shared': json['shared'] == null ? undefined : ((json['shared'] as Array<any>).map(UserRequestFromJSON)),
|
||||
'filter': json['filter'] == null ? undefined : CustomFilterRequestFromJSON(json['filter']),
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -100,6 +107,7 @@ export function PatchedRecipeBookRequestToJSON(value?: PatchedRecipeBookRequest
|
||||
'shared': value['shared'] == null ? undefined : ((value['shared'] as Array<any>).map(UserRequestToJSON)),
|
||||
'filter': CustomFilterRequestToJSON(value['filter']),
|
||||
'order': value['order'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -146,6 +146,12 @@ export interface PatchedRecipeRequest {
|
||||
* @memberof PatchedRecipeRequest
|
||||
*/
|
||||
shared?: Array<UserRequest>;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedRecipeRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -181,6 +187,7 @@ export function PatchedRecipeRequestFromJSONTyped(json: any, ignoreDiscriminator
|
||||
'servingsText': json['servings_text'] == null ? undefined : json['servings_text'],
|
||||
'_private': json['private'] == null ? undefined : json['private'],
|
||||
'shared': json['shared'] == null ? undefined : ((json['shared'] as Array<any>).map(UserRequestFromJSON)),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -206,6 +213,7 @@ export function PatchedRecipeRequestToJSON(value?: PatchedRecipeRequest | null):
|
||||
'servings_text': value['servingsText'],
|
||||
'private': value['_private'],
|
||||
'shared': value['shared'] == null ? undefined : ((value['shared'] as Array<any>).map(UserRequestToJSON)),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -80,6 +80,12 @@ export interface PatchedShoppingListEntryRequest {
|
||||
* @memberof PatchedShoppingListEntryRequest
|
||||
*/
|
||||
delayUntil?: Date;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedShoppingListEntryRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -107,6 +113,7 @@ export function PatchedShoppingListEntryRequestFromJSONTyped(json: any, ignoreDi
|
||||
'checked': json['checked'] == null ? undefined : json['checked'],
|
||||
'completedAt': json['completed_at'] == null ? undefined : (new Date(json['completed_at'])),
|
||||
'delayUntil': json['delay_until'] == null ? undefined : (new Date(json['delay_until'])),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -124,6 +131,7 @@ export function PatchedShoppingListEntryRequestToJSON(value?: PatchedShoppingLis
|
||||
'checked': value['checked'],
|
||||
'completed_at': value['completedAt'] == null ? undefined : ((value['completedAt'] as any).toISOString()),
|
||||
'delay_until': value['delayUntil'] == null ? undefined : ((value['delayUntil'] as any).toISOString()),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -37,6 +37,12 @@ export interface PatchedShoppingListRecipeRequest {
|
||||
* @memberof PatchedShoppingListRecipeRequest
|
||||
*/
|
||||
servings?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedShoppingListRecipeRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -59,6 +65,7 @@ export function PatchedShoppingListRecipeRequestFromJSONTyped(json: any, ignoreD
|
||||
'recipe': json['recipe'] == null ? undefined : json['recipe'],
|
||||
'mealplan': json['mealplan'] == null ? undefined : json['mealplan'],
|
||||
'servings': json['servings'] == null ? undefined : json['servings'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -71,6 +78,7 @@ export function PatchedShoppingListRecipeRequestToJSON(value?: PatchedShoppingLi
|
||||
'recipe': value['recipe'],
|
||||
'mealplan': value['mealplan'],
|
||||
'servings': value['servings'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -140,6 +140,12 @@ export interface PatchedSpaceRequest {
|
||||
* @memberof PatchedSpaceRequest
|
||||
*/
|
||||
logoColorSvg?: UserFileViewRequest;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedSpaceRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -175,6 +181,7 @@ export function PatchedSpaceRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'logoColor192': json['logo_color_192'] == null ? undefined : UserFileViewRequestFromJSON(json['logo_color_192']),
|
||||
'logoColor512': json['logo_color_512'] == null ? undefined : UserFileViewRequestFromJSON(json['logo_color_512']),
|
||||
'logoColorSvg': json['logo_color_svg'] == null ? undefined : UserFileViewRequestFromJSON(json['logo_color_svg']),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -200,6 +207,7 @@ export function PatchedSpaceRequestToJSON(value?: PatchedSpaceRequest | null): a
|
||||
'logo_color_192': UserFileViewRequestToJSON(value['logoColor192']),
|
||||
'logo_color_512': UserFileViewRequestToJSON(value['logoColor512']),
|
||||
'logo_color_svg': UserFileViewRequestToJSON(value['logoColorSvg']),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -86,6 +86,12 @@ export interface PatchedStepRequest {
|
||||
* @memberof PatchedStepRequest
|
||||
*/
|
||||
showIngredientsTable?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedStepRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -114,6 +120,7 @@ export function PatchedStepRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'file': json['file'] == null ? undefined : UserFileViewRequestFromJSON(json['file']),
|
||||
'stepRecipe': json['step_recipe'] == null ? undefined : json['step_recipe'],
|
||||
'showIngredientsTable': json['show_ingredients_table'] == null ? undefined : json['show_ingredients_table'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -132,6 +139,7 @@ export function PatchedStepRequestToJSON(value?: PatchedStepRequest | null): any
|
||||
'file': UserFileViewRequestToJSON(value['file']),
|
||||
'step_recipe': value['stepRecipe'],
|
||||
'show_ingredients_table': value['showIngredientsTable'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -56,6 +56,12 @@ export interface PatchedStorageRequest {
|
||||
* @memberof PatchedStorageRequest
|
||||
*/
|
||||
token?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedStorageRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -80,6 +86,7 @@ export function PatchedStorageRequestFromJSONTyped(json: any, ignoreDiscriminato
|
||||
'username': json['username'] == null ? undefined : json['username'],
|
||||
'password': json['password'] == null ? undefined : json['password'],
|
||||
'token': json['token'] == null ? undefined : json['token'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -94,6 +101,7 @@ export function PatchedStorageRequestToJSON(value?: PatchedStorageRequest | null
|
||||
'username': value['username'],
|
||||
'password': value['password'],
|
||||
'token': value['token'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -44,6 +44,12 @@ export interface PatchedSupermarketCategoryRelationRequest {
|
||||
* @memberof PatchedSupermarketCategoryRelationRequest
|
||||
*/
|
||||
order?: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedSupermarketCategoryRelationRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -66,6 +72,7 @@ export function PatchedSupermarketCategoryRelationRequestFromJSONTyped(json: any
|
||||
'category': json['category'] == null ? undefined : SupermarketCategoryRequestFromJSON(json['category']),
|
||||
'supermarket': json['supermarket'] == null ? undefined : json['supermarket'],
|
||||
'order': json['order'] == null ? undefined : json['order'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -78,6 +85,7 @@ export function PatchedSupermarketCategoryRelationRequestToJSON(value?: PatchedS
|
||||
'category': SupermarketCategoryRequestToJSON(value['category']),
|
||||
'supermarket': value['supermarket'],
|
||||
'order': value['order'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -65,6 +65,12 @@ export interface PatchedSupermarketCategoryRequest {
|
||||
* @memberof PatchedSupermarketCategoryRequest
|
||||
*/
|
||||
description?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedSupermarketCategoryRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -86,6 +92,7 @@ export function PatchedSupermarketCategoryRequestFromJSONTyped(json: any, ignore
|
||||
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -97,6 +104,7 @@ export function PatchedSupermarketCategoryRequestToJSON(value?: PatchedSupermark
|
||||
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -71,6 +71,12 @@ export interface PatchedSupermarketRequest {
|
||||
* @memberof PatchedSupermarketRequest
|
||||
*/
|
||||
openDataSlug?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedSupermarketRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -93,6 +99,7 @@ export function PatchedSupermarketRequestFromJSONTyped(json: any, ignoreDiscrimi
|
||||
'name': json['name'] == null ? undefined : json['name'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
'openDataSlug': json['open_data_slug'] == null ? undefined : json['open_data_slug'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -105,6 +112,7 @@ export function PatchedSupermarketRequestToJSON(value?: PatchedSupermarketReques
|
||||
'name': value['name'],
|
||||
'description': value['description'],
|
||||
'open_data_slug': value['openDataSlug'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -43,6 +43,12 @@ export interface PatchedSyncRequest {
|
||||
* @memberof PatchedSyncRequest
|
||||
*/
|
||||
lastChecked?: Date;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedSyncRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -66,6 +72,7 @@ export function PatchedSyncRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'path': json['path'] == null ? undefined : json['path'],
|
||||
'active': json['active'] == null ? undefined : json['active'],
|
||||
'lastChecked': json['last_checked'] == null ? undefined : (new Date(json['last_checked'])),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -79,6 +86,7 @@ export function PatchedSyncRequestToJSON(value?: PatchedSyncRequest | null): any
|
||||
'path': value['path'],
|
||||
'active': value['active'],
|
||||
'last_checked': value['lastChecked'] == null ? undefined : ((value['lastChecked'] as any).toISOString()),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -68,6 +68,12 @@ export interface PatchedUnitConversionRequest {
|
||||
* @memberof PatchedUnitConversionRequest
|
||||
*/
|
||||
openDataSlug?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedUnitConversionRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -93,6 +99,7 @@ export function PatchedUnitConversionRequestFromJSONTyped(json: any, ignoreDiscr
|
||||
'convertedUnit': json['converted_unit'] == null ? undefined : UnitRequestFromJSON(json['converted_unit']),
|
||||
'food': json['food'] == null ? undefined : FoodRequestFromJSON(json['food']),
|
||||
'openDataSlug': json['open_data_slug'] == null ? undefined : json['open_data_slug'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -108,6 +115,7 @@ export function PatchedUnitConversionRequestToJSON(value?: PatchedUnitConversion
|
||||
'converted_unit': UnitRequestToJSON(value['convertedUnit']),
|
||||
'food': FoodRequestToJSON(value['food']),
|
||||
'open_data_slug': value['openDataSlug'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -83,6 +83,12 @@ export interface PatchedUnitRequest {
|
||||
* @memberof PatchedUnitRequest
|
||||
*/
|
||||
openDataSlug?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedUnitRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -107,6 +113,7 @@ export function PatchedUnitRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
'baseUnit': json['base_unit'] == null ? undefined : json['base_unit'],
|
||||
'openDataSlug': json['open_data_slug'] == null ? undefined : json['open_data_slug'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -121,6 +128,7 @@ export function PatchedUnitRequestToJSON(value?: PatchedUnitRequest | null): any
|
||||
'description': value['description'],
|
||||
'base_unit': value['baseUnit'],
|
||||
'open_data_slug': value['openDataSlug'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -31,6 +31,12 @@ export interface PatchedUserRequest {
|
||||
* @memberof PatchedUserRequest
|
||||
*/
|
||||
lastName?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedUserRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -52,6 +58,7 @@ export function PatchedUserRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
||||
|
||||
'firstName': json['first_name'] == null ? undefined : json['first_name'],
|
||||
'lastName': json['last_name'] == null ? undefined : json['last_name'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -63,6 +70,7 @@ export function PatchedUserRequestToJSON(value?: PatchedUserRequest | null): any
|
||||
|
||||
'first_name': value['firstName'],
|
||||
'last_name': value['lastName'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -44,6 +44,12 @@ export interface PatchedUserSpaceRequest {
|
||||
* @memberof PatchedUserSpaceRequest
|
||||
*/
|
||||
internalNote?: string;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedUserSpaceRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -66,6 +72,7 @@ export function PatchedUserSpaceRequestFromJSONTyped(json: any, ignoreDiscrimina
|
||||
'groups': json['groups'] == null ? undefined : ((json['groups'] as Array<any>).map(GroupRequestFromJSON)),
|
||||
'active': json['active'] == null ? undefined : json['active'],
|
||||
'internalNote': json['internal_note'] == null ? undefined : json['internal_note'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -78,6 +85,7 @@ export function PatchedUserSpaceRequestToJSON(value?: PatchedUserSpaceRequest |
|
||||
'groups': value['groups'] == null ? undefined : ((value['groups'] as Array<any>).map(GroupRequestToJSON)),
|
||||
'active': value['active'],
|
||||
'internal_note': value['internalNote'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -25,6 +25,12 @@ export interface PatchedViewLogRequest {
|
||||
* @memberof PatchedViewLogRequest
|
||||
*/
|
||||
recipe?: number;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PatchedViewLogRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -45,6 +51,7 @@ export function PatchedViewLogRequestFromJSONTyped(json: any, ignoreDiscriminato
|
||||
return {
|
||||
|
||||
'recipe': json['recipe'] == null ? undefined : json['recipe'],
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -55,6 +62,7 @@ export function PatchedViewLogRequestToJSON(value?: PatchedViewLogRequest | null
|
||||
return {
|
||||
|
||||
'recipe': value['recipe'],
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ export interface Property {
|
||||
* @type {number}
|
||||
* @memberof Property
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -84,6 +84,7 @@ export interface Property {
|
||||
* Check if a given object implements the Property interface.
|
||||
*/
|
||||
export function instanceOfProperty(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('propertyAmount' in value)) return false;
|
||||
if (!('propertyType' in value)) return false;
|
||||
return true;
|
||||
@@ -99,7 +100,7 @@ export function PropertyFromJSONTyped(json: any, ignoreDiscriminator: boolean):
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'propertyAmount': json['property_amount'],
|
||||
'propertyType': PropertyTypeFromJSON(json['property_type']),
|
||||
};
|
||||
@@ -111,7 +112,6 @@ export function PropertyToJSON(value?: Property | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'property_amount': value['propertyAmount'],
|
||||
'property_type': PropertyTypeToJSON(value['propertyType']),
|
||||
};
|
||||
|
||||
@@ -72,6 +72,12 @@ export interface PropertyRequest {
|
||||
* @memberof PropertyRequest
|
||||
*/
|
||||
propertyType: PropertyTypeRequest;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof PropertyRequest
|
||||
*/
|
||||
id?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -95,6 +101,7 @@ export function PropertyRequestFromJSONTyped(json: any, ignoreDiscriminator: boo
|
||||
|
||||
'propertyAmount': json['property_amount'],
|
||||
'propertyType': PropertyTypeRequestFromJSON(json['property_type']),
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -106,6 +113,7 @@ export function PropertyRequestToJSON(value?: PropertyRequest | null): any {
|
||||
|
||||
'property_amount': value['propertyAmount'],
|
||||
'property_type': PropertyTypeRequestToJSON(value['propertyType']),
|
||||
'id': value['id'],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ export interface PropertyType {
|
||||
* @type {number}
|
||||
* @memberof PropertyType
|
||||
*/
|
||||
id?: number;
|
||||
readonly id: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
@@ -67,6 +67,7 @@ export interface PropertyType {
|
||||
* Check if a given object implements the PropertyType interface.
|
||||
*/
|
||||
export function instanceOfPropertyType(value: object): boolean {
|
||||
if (!('id' in value)) return false;
|
||||
if (!('name' in value)) return false;
|
||||
return true;
|
||||
}
|
||||
@@ -81,7 +82,7 @@ export function PropertyTypeFromJSONTyped(json: any, ignoreDiscriminator: boolea
|
||||
}
|
||||
return {
|
||||
|
||||
'id': json['id'] == null ? undefined : json['id'],
|
||||
'id': json['id'],
|
||||
'name': json['name'],
|
||||
'unit': json['unit'] == null ? undefined : json['unit'],
|
||||
'description': json['description'] == null ? undefined : json['description'],
|
||||
@@ -97,7 +98,6 @@ export function PropertyTypeToJSON(value?: PropertyType | null): any {
|
||||
}
|
||||
return {
|
||||
|
||||
'id': value['id'],
|
||||
'name': value['name'],
|
||||
'unit': value['unit'],
|
||||
'description': value['description'],
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user