11import { fakerEN_GB as faker } from '@faker-js/faker'
22
33import vaccines from '../datasets/vaccines.js'
4- import { PatientStatus , VaccinationOutcome } from '../enums.js'
4+ import { VaccinationOutcome } from '../enums.js'
55import { Vaccination } from '../models.js'
66
77/**
@@ -20,17 +20,14 @@ export function generateVaccination(patientSession, programme, batch, users) {
2020 let injectionSite
2121 let sequence
2222
23- let outcome
24- if ( patientSession . report === PatientStatus . Due ) {
25- outcome = faker . helpers . weightedArrayElement ( [
26- { value : VaccinationOutcome . Vaccinated , weight : 7 } ,
27- { value : VaccinationOutcome . PartVaccinated , weight : 1 } ,
28- { value : VaccinationOutcome . Absent , weight : 1 } ,
29- { value : VaccinationOutcome . DoNotVaccinate , weight : 1 } ,
30- { value : VaccinationOutcome . Refused , weight : 1 } ,
31- { value : VaccinationOutcome . Unwell , weight : 1 }
32- ] )
33- }
23+ const outcome = faker . helpers . weightedArrayElement ( [
24+ { value : VaccinationOutcome . Vaccinated , weight : 7 } ,
25+ { value : VaccinationOutcome . PartVaccinated , weight : 1 } ,
26+ { value : VaccinationOutcome . Absent , weight : 1 } ,
27+ { value : VaccinationOutcome . DoNotVaccinate , weight : 1 } ,
28+ { value : VaccinationOutcome . Refused , weight : 1 } ,
29+ { value : VaccinationOutcome . Unwell , weight : 1 }
30+ ] )
3431
3532 if ( programme . sequence ) {
3633 sequence = programme . sequenceDefault
0 commit comments