'is default' not working in the drop list

amielel wrote on Tuesday, September 06, 2016:

Hi.
I want to make add attribute ‘selected’ to one of the option in the drop list at the demographic form, I set ‘is default’ to the one of the options in the list but it’s not working.
It’s working just in multiple select element.
I’ve saw that It’s missing in the code at openemr/library/options.inc.php.
Does it’s bug?

visolveemr wrote on Tuesday, September 06, 2016:

Hi Amiel,
We checked for it and came across the same. For multi select element, the default option works and for other items it does not work.

Hence this could be a bug.

Let us know if you require a fix on this.

Thanks,
ViSolve OpenEMR Support Team
ViSolve

amielel wrote on Tuesday, September 06, 2016:

I’ve opened bug - https://sourceforge.net/p/openemr/bugs/458/

bradymiller wrote on Wednesday, September 07, 2016:

Very cool,

This is the first time in OpenEMR that I think there have been 2 bug fixes for the same bug within 24 hours.

The primary bug fix was the same by both Visolve and Amiel, however Amiel’s fix did identify quite the bug in the backup multilist mechanism, so did the following:
Committed Visolve’s fix here:


And then committed Amiel’s commit here(I added some code to fix the identified backup multilist bug):

Very nice teamwork!

-brady
OpenEMR

bradymiller wrote on Wednesday, September 07, 2016:

btw,
Amiel’s primary fix was here: