点击单选按钮或文字选中
//html
<div class="dutydateList clearfix"> <div class="dutydateCheck"> <label>
<input type="radio" name="radio" value="ck1" /> <span class="radiotext">上午8点~下午6点</span>
</label> <input type="hidden" id="dutyDateck2" disabled><input type="hidden" id="dutyDatecks2" disabled> </div> <div class="dutydateCheck"> <label>
<input type="radio" name="radio" value="ck2" /> <span class="radiotext">下午4点~凌晨12点</span>
</label> <input type="hidden" id="dutyDateck3" disabled><input type="hidden" id="dutyDatecks3" disabled> </div>
//点击单选按钮
//点击单选按钮选中时间 $("input[name='radio']").on("change",function(event) { var a = $("input[name='radio']:checked").val(); var ckdate1= $("input[name='radio']:checked").parent().siblings('input')[0].value //起始时间 var ckdate2= $("input[name='radio']:checked").parent().siblings('input')[1].value //终止时间 $(".produtydate").val(a) //时间段标识 $(".produtyval1").val(ckdate1) //时间段起始值 });