JSFiddle - React, Tailwind, and code Playground
HTML
<input class="shop" name="shop" type="radio" class="field radio" value="1" tabindex="10"/>
<input class="shop" name="shop" type="radio" class="field radio" value="2" tabindex="11" />
<input type="hidden" size="30" id="fromInput" name="from" value="" />
JavaScript
$('.shop').change(function(){
var place = ( $(this).val()==1?"Paris":"Cairo" );
$('#fromInput').val(place);
alert($('#fromInput').val());
})