NAVADMC / ADSM

A simulation of disease spread in livestock populations. Includes detection and containment simulation.
Other
10 stars 5 forks source link

Validation message for Vaccination #891

Closed missyschoenbaum closed 5 years ago

missyschoenbaum commented 6 years ago

If you have a ring and a trigger turned on, but have not set any values in the Control Protocol, Vaccination then vaccination happens with unclear parameters.

Can we have a validation that lets us know there is a disconnect here? This would require that the control protocol assignment (ScenarioCreator_protocolassignment) to production type be compared to the ScenarioCreator_vaccinationringrule_target_group.

Message something like: "A vaccination ring has been turn on to vaccinate XX but Control Protocol vaccination has not been enabled."

missyschoenbaum commented 5 years ago

@BryanHurst the place to look for the on/off switch is within the Control Protocol, and there is the option for vaccination on the list. This used to be connected to use_vaccination, but now vaccination starts when the trigger is sufficient.

Some options to look at - make this so it is automatically checked when a trigger is set, or make this so there is no check box, but the parameters can still be selected and modified. I am unsure the relationship this has with Vaccination rings.

I am willing to take the easiest option at this point.

BryanHurst commented 5 years ago

@missyschoenbaum the easiest route is going to be to disable that Vaccination checkbox and automatically check it if another trigger is created.

Should it be checked if any Vaccination Start Trigger is created?

missyschoenbaum commented 5 years ago

Yes, because any trigger has the possibility of starting vaccination.

missyschoenbaum commented 5 years ago

This was a great solution and works perfectly.

missyschoenbaum commented 5 years ago

Found a hangup with this, but it is minor. It is OK for the check box on the Vaccination to be disabled, but users would still need to access the parameters within vaccination. They can, and can apply changes, but the middle panel still looks disabled.

BryanHurst commented 5 years ago

This is because the value of use_vaccination wasn't being properly saved to the database.

missyschoenbaum commented 5 years ago

Looks great