Skip to content
Snippets Groups Projects
Commit 7da11427 authored by Jérémie BRISON's avatar Jérémie BRISON
Browse files

fix(form) : update model + fix conf

parent f0d1df60
No related branches found
No related tags found
3 merge requests!27Recette,!26Dev,!25Fix/form design create structure
......@@ -14,7 +14,7 @@ export class ConfigurationService {
} else if (process.env.NODE_ENV && process.env.NODE_ENV === 'dev') {
this._config = configDev;
Logger.log('App started with dev conf', 'ConfigurationService');
} else if (process.env.NODE_ENV) {
} else {
this._config = config;
Logger.log('App started with local conf', 'ConfigurationService');
}
......
......@@ -20,6 +20,7 @@ export class structureDto {
@Type(() => Address)
address: Address;
@IsNotEmpty()
contactPhone: string;
@IsNotEmpty()
......@@ -33,6 +34,7 @@ export class structureDto {
lockdownActivity: string;
otherDescription: string;
@IsNotEmpty()
pmrAccess: boolean;
publicsAccompaniment: string[];
proceduresAccompaniment: string[];
......@@ -43,12 +45,20 @@ export class structureDto {
@ArrayNotEmpty()
publics: string[];
@IsNotEmpty()
freeWifi: boolean;
@IsNotEmpty()
freeWorkShop: boolean;
@IsNotEmpty()
nbComputers: number;
@IsNotEmpty()
nbPrinters: number;
@IsNotEmpty()
nbTablets: number;
@IsNotEmpty()
nbNumericTerminal: number;
@IsNotEmpty()
nbScanners: number;
exceptionalClosures: string;
equipmentsAndServices: string[];
hours: Week;
......@@ -58,4 +68,5 @@ export class structureDto {
socialAndProfessional: string[];
digitalCultureSecurity: string[];
coord: number[];
accountVerified: boolean;
}
......@@ -4,6 +4,7 @@ import { IsNotEmpty } from 'class-validator';
export type AddressDocument = Address & Document;
export class Address {
@IsNotEmpty()
numero: string;
@IsNotEmpty()
......
......@@ -111,6 +111,9 @@ export class Structure {
@Prop()
nbNumericTerminal: number;
@Prop()
nbScanners: number;
@Prop()
hours: Week;
......@@ -119,6 +122,9 @@ export class Structure {
@Prop()
deletedAt: Date;
@Prop()
accountVerified: boolean;
}
export const StructureSchema = SchemaFactory.createForClass(Structure);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment