Created
February 25, 2021 23:00
-
-
Save juniarto-samsudin/13ed339ff7133ed57aa7258d1bfa34cf to your computer and use it in GitHub Desktop.
radio button get first and such
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//GET FIRST VALUE OF RADIO OPTION LIST | |
let firstVal = $('input[type=radio][name=runOption]:first').val() | |
console.log("FIRSTVAL: ", firstVal) | |
{{ form.jobRun(class="btn btn-fill btn-primary pull-right",onclick="revertBack()") }} | |
function revertBack(){ | |
alert("Hello") | |
$('input[type=radio][name=runOption]:first').prop('checked',true) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment