Good afternoon, I have a mobile application written in MobileUI and JS, where I have an alert for the company exchange function. In this alert you have the radio inputs, which is to select only one of the options. I would like that when opening the alert it always came with the selected input marked, but it always goes blank.
Could you help me? Follow the code below.
JavaScriptFile
varempresaSelectfunctiontrocarEmpresa(){map.setClickable(false)alert({id:'alertEmpresa',title:'TrocarEmpresa',message:'Realizeatrocadeempresa!',template:'empresaVendedor',width:'60%',buttons:[{label:'OK',onclick:function(){closeAlert('alertEmpresa')map.setClickable(true)findFormVendedor()myLocation()}},{label:'Cancelar',onclick:function(){closeAlert('alertEmpresa')map.setClickable(true)}}]})}functionselectedEmpresa(index){empresaSelect=empresas.filter(function(e,i){returni==index?e:null})empresaSelect=empresaSelect[0]}document.addEventListener('backPage',function(){closeAlert('alertEmpresa')})
HTMLfile
<divclass="hidden" id="empresaVendedor">
<div class="list">
<div class="item" data="empresas">
<h2>${razaoSocial}</h2>
<div class="right">
<input name="radio-emp" type="radio" class="teal" onclick="selectedEmpresa($$index)">
</div>
</div>
</div>
</div>