import {model, property} from '@loopback/repository'; import {UserModifiableEntity} from '@sourcefuse-npm/alivio-lib'; @model() export class MoodFactorLogs extends UserModifiableEntity { @property({ type: 'number', id: true, description: 'This is created when new entity is created.', }) id?: number; @property({ type: 'string', required: true, description: 'This is string and is a required field.', }) mood: string; @property({ type: 'string', required: true, description: 'This is string and is a required field.', }) moodFactor: string; @property({ type: 'string', required: true, name: 'date_time', description: `Date in timestamptz format. This date represents the date you are filling the mood for.`, }) dateTime: Date; @property({ type: 'number', name: 'patient_id', description: 'This is string and is not required from front-end.', }) patientId?: number; @property({ type: 'string', description: 'This is string and is not required.', }) comment?: string; @property({ type: 'string', name: 'alert_key', description: 'This property maps to the logic for alter priority', jsonSchema: { enum: [ 'work_alert', 'relation_ship_alert', 'health_alert', 'family_alert', 'finances_alert', 'others_alert', ], }, }) alertKey?: string; constructor(data?: Partial) { super(data); } } export type MoodFactorWithRelations = MoodFactorLogs;