refactoring
This commit is contained in:
@@ -1,9 +1,13 @@
|
||||
def getVaccineOptions(vaccines):
|
||||
return ['<option hidden disabled selected value>Select Vaccine</option>'] + _getOptions(vaccines)
|
||||
return _getOptionsWithDefaultOption(defaultOptionText = 'Select Vaccine', values = vaccines)
|
||||
|
||||
|
||||
def getSymptomOptions(symptoms):
|
||||
return ['<option hidden disabled selected value>Select Symptom</option>'] + _getOptions(symptoms)
|
||||
return _getOptionsWithDefaultOption(defaultOptionText = 'Select Symptom', values = symptoms)
|
||||
|
||||
|
||||
def _getOptionsWithDefaultOption(defaultOptionText, values):
|
||||
return ['<option hidden disabled selected value>{defaultOptionText}</option>'.format(defaultOptionText = defaultOptionText)] + _getOptions(values)
|
||||
|
||||
|
||||
def _getOptions(values):
|
||||
|
||||
Reference in New Issue
Block a user