mirror of
https://github.com/TandoorRecipes/recipes.git
synced 2025-12-24 02:39:20 -05:00
136 lines
3.4 KiB
TypeScript
136 lines
3.4 KiB
TypeScript
/* tslint:disable */
|
|
/* eslint-disable */
|
|
/**
|
|
* Tandoor
|
|
* Tandoor API Docs
|
|
*
|
|
* The version of the OpenAPI document: 0.0.0
|
|
*
|
|
*
|
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
* https://openapi-generator.tech
|
|
* Do not edit the class manually.
|
|
*/
|
|
|
|
import { mapValues } from '../runtime';
|
|
import type { Group } from './Group';
|
|
import {
|
|
GroupFromJSON,
|
|
GroupFromJSONTyped,
|
|
GroupToJSON,
|
|
} from './Group';
|
|
|
|
/**
|
|
* Adds nested create feature
|
|
* @export
|
|
* @interface PatchedInviteLink
|
|
*/
|
|
export interface PatchedInviteLink {
|
|
/**
|
|
*
|
|
* @type {number}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
readonly id?: number;
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
readonly uuid?: string;
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
email?: string;
|
|
/**
|
|
*
|
|
* @type {Group}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
group?: Group;
|
|
/**
|
|
*
|
|
* @type {Date}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
validUntil?: Date;
|
|
/**
|
|
*
|
|
* @type {number}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
usedBy?: number;
|
|
/**
|
|
*
|
|
* @type {boolean}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
reusable?: boolean;
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
internalNote?: string;
|
|
/**
|
|
*
|
|
* @type {number}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
readonly createdBy?: number;
|
|
/**
|
|
*
|
|
* @type {Date}
|
|
* @memberof PatchedInviteLink
|
|
*/
|
|
readonly createdAt?: Date;
|
|
}
|
|
|
|
/**
|
|
* Check if a given object implements the PatchedInviteLink interface.
|
|
*/
|
|
export function instanceOfPatchedInviteLink(value: object): boolean {
|
|
return true;
|
|
}
|
|
|
|
export function PatchedInviteLinkFromJSON(json: any): PatchedInviteLink {
|
|
return PatchedInviteLinkFromJSONTyped(json, false);
|
|
}
|
|
|
|
export function PatchedInviteLinkFromJSONTyped(json: any, ignoreDiscriminator: boolean): PatchedInviteLink {
|
|
if (json == null) {
|
|
return json;
|
|
}
|
|
return {
|
|
|
|
'id': json['id'] == null ? undefined : json['id'],
|
|
'uuid': json['uuid'] == null ? undefined : json['uuid'],
|
|
'email': json['email'] == null ? undefined : json['email'],
|
|
'group': json['group'] == null ? undefined : GroupFromJSON(json['group']),
|
|
'validUntil': json['valid_until'] == null ? undefined : (new Date(json['valid_until'])),
|
|
'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'],
|
|
'createdBy': json['created_by'] == null ? undefined : json['created_by'],
|
|
'createdAt': json['created_at'] == null ? undefined : (new Date(json['created_at'])),
|
|
};
|
|
}
|
|
|
|
export function PatchedInviteLinkToJSON(value?: Omit<PatchedInviteLink, 'id'|'uuid'|'created_by'|'created_at'> | null): any {
|
|
if (value == null) {
|
|
return value;
|
|
}
|
|
return {
|
|
|
|
'email': value['email'],
|
|
'group': GroupToJSON(value['group']),
|
|
'valid_until': value['validUntil'] == null ? undefined : ((value['validUntil']).toISOString().substring(0,10)),
|
|
'used_by': value['usedBy'],
|
|
'reusable': value['reusable'],
|
|
'internal_note': value['internalNote'],
|
|
};
|
|
}
|
|
|