Improve add team page validity check
parent
000905257e
commit
459b1a4a1a
|
@ -39,9 +39,10 @@ async function checkDataValidity() {
|
|||
|
||||
if(!nameTextbox.value) dataIsValid = false;
|
||||
|
||||
const sportHasContent = sportDropdown.options.length;
|
||||
if(!sportHasContent) dataIsValid = false;
|
||||
|
||||
if(dataIsValid) submitButton.disabled = false;
|
||||
else submitButton.disabled = true;
|
||||
submitButton.disabled = !dataIsValid;
|
||||
}
|
||||
|
||||
Form.addRemoveFunction(deleteButton, submissionForm, "team");
|
Reference in New Issue