X-Git-Url: http://www.dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fshow%2Fdx.pl;h=57271e8f874a192713ee5e1ac5a1c731d3b50be2;hb=290cd395e4bac4a92dfc3c40a2a3fd7de93110eb;hp=6d9ad3add54c47abae7c2203a57dc05b52a91d25;hpb=ef646bd5c8fc8606448c8ac2019e048427741f67;p=spider.git diff --git a/cmd/show/dx.pl b/cmd/show/dx.pl index 6d9ad3ad..57271e8f 100644 --- a/cmd/show/dx.pl +++ b/cmd/show/dx.pl @@ -20,6 +20,7 @@ my $info; my $expr; my $hint; my $dxcc; +my $real; my $fromdxcc; my ($doqsl, $doiota, $doqra); @@ -37,6 +38,10 @@ while ($f = shift @list) { # next field $dxcc = 1; next; } + if (lc $f eq 'rt' || $f =~ /^real/i) { + $real = 1; + next; + } if (lc $f eq 'on' && $list[0]) { # is it freq range? # print "yup freq\n"; if ($list[0] =~ m|^(\d+)(?:\.\d+)?[-/](\d+)(?:\.\d+)?$|) { @@ -82,7 +87,7 @@ while ($f = shift @list) { # next field my ($a, $b); # $DB::single =1; - if ($list[0] && (($a, $b) = $list[0] =~ /(AF|AN|NA|SA|EU|AS|OC)-?(\d?\d\d)/oi)) { + if (@list && $list[0] && (($a, $b) = $list[0] =~ /(AF|AN|NA|SA|EU|AS|OC)-?(\d?\d\d)/oi)) { $a = uc $a; $doiota = "\\b$a\[\-\ \]\?$b\\b"; shift @list; @@ -91,7 +96,7 @@ while ($f = shift @list) { # next field next; } if (lc $f eq 'qra') { - $doqra = uc shift @list if $list[0] =~ /[A-Z][A-Z]\d\d/oi; + $doqra = uc shift @list if @list && $list[0] =~ /[A-Z][A-Z]\d\d/oi; $doqra = '\b([A-Z][A-Z]\d\d|[A-Z][A-Z]\d\d[A-Z][A-Z])\b' unless $doqra; next; } @@ -239,7 +244,11 @@ my @res = Spot::search($expr, $fromday, $today, $from, $to, $hint); my $ref; my @dx; foreach $ref (@res) { - push @out, Spot::formatl(@$ref); + if ($real) { + push @out, $self->format_dx_spot(@$ref); + } else { + push @out, Spot::formatl(@$ref); + } } return (1, @out);