Fixed issue where if DXCC wasn't defined during json callsign call it would cause lookup to fail

pull/425/head
Peter Goodhall 2019-08-13 16:11:12 +01:00
rodzic fac032d506
commit eafae062e5
1 zmienionych plików z 5 dodań i 2 usunięć

Wyświetl plik

@ -245,12 +245,15 @@ $(document).ready(function(){
$.getJSON('logbook/json/' + $(this).val(), function(result)
{
//$('#country').val(result); lotw_info
$('#country').val(convert_case(result.dxcc.entity));
$('#callsign_info').text(convert_case(result.dxcc.entity));
if(result.dxcc.entity != undefined) {
$('#country').val(convert_case(result.dxcc.entity));
$('#callsign_info').text(convert_case(result.dxcc.entity));
}
if(result.lotw_member == "active") {
$('#lotw_info').text("LoTW");
}
$('#dxcc_id').val(result.dxcc.adif);
$('#cqz').val(result.dxcc.cqz);