projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
change the Hello to use default values
[spider.git]
/
perl
/
VE7CC.pm
diff --git
a/perl/VE7CC.pm
b/perl/VE7CC.pm
index e6634b6209c7d80ef8c76f5e879e75f9b0734e30..14ef213105541600bb806abcd3e380b7c899a879 100644
(file)
--- a/
perl/VE7CC.pm
+++ b/
perl/VE7CC.pm
@@
-15,6
+15,7
@@
use DXDebug;
use DXUtil;
use Julian;
use Prefix;
use DXUtil;
use Julian;
use Prefix;
+use DXUser;
use strict;
use strict;
@@
-27,21
+28,34
@@
$main::branch += $BRANCH;
sub dx_spot
{
my $self = shift; # this may be useful some day
sub dx_spot
{
my $self = shift; # this may be useful some day
- my $freq = shift;
- my $spotted = shift;
- my $t = shift;
+ my $spot = ref $_[0] ? shift : \@_;
+ my $freq = $spot->[0];
+ my $spotted = $spot->[1];
+ my $t = $spot->[2];
+ my $loc_spotted = '';
+ my $loc_spotter = '';
+ my $ref = DXUser->get_current($spotted);
+ if ($ref) {
+ my $loc = $ref->qra || '';
+ $loc_spotted =substr($loc, 0, 4) if $loc;
+ }
# remove any items above the top of the max spot data
# remove any items above the top of the max spot data
- pop while @_ > 1
1
;
+ pop while @_ > 1
4
;
# make sure both US states are defined
# make sure both US states are defined
- $_[
9
] ||= '';
- $_[1
0
] ||= '';
+ $_[
12
] ||= '';
+ $_[1
3
] ||= '';
- my $spotter_cc = (Prefix::cty_data($spotted))[5];
- my $spotted_cc = (Prefix::cty_data($_[1]))[5];
+ my $spotted_cc = (Prefix::cty_data($spotted))[5];
+ my $spotter_cc = (Prefix::cty_data($_[4]))[5];
+ $ref = DXUser->get_current($_[4]);
+ if ($ref) {
+ my $loc = $ref->qra || '';
+ $loc_spotter = substr($loc, 0, 4) if $loc;
+ }
- return sprintf("CC11^%0.1f^%s^", $freq, $spotted) . join('^', cldate($t), ztime($t), @
_, $spotter_cc, $spotted_cc
);
+ return sprintf("CC11^%0.1f^%s^", $freq, $spotted) . join('^', cldate($t), ztime($t), @
$spot[3..-1], $spotted_cc, $spotter_cc, $loc_spotted, $loc_spotter
);
}
1;
}
1;