X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=cmd%2Fshow%2Fmsg_status.pl;h=1d6054091d149205c7b66cf9094f47328e7e8abb;hb=9e6f8da122e48430e5b56b27cf7d06c688cb2e13;hp=5a2e7e07e4934d7e694f01ca014a5a4d436f3913;hpb=f939c447ca5ef37073054a73e50b48a63533a9bc;p=spider.git diff --git a/cmd/show/msg_status.pl b/cmd/show/msg_status.pl index 5a2e7e07..1d605409 100644 --- a/cmd/show/msg_status.pl +++ b/cmd/show/msg_status.pl @@ -5,17 +5,26 @@ # # $Id$ # -my $self = shift; +my ($self, $line) = @_; return (0, $self->msg('e5')) if $self->priv < 5; my @out; -push @out, "Work Queue"; -for (keys %DXMsg::work) { - push @out, "$_ : $DXMsg::work{$_}\n"; +if (!$line || $line =~ /^b/i) { + push @out, "Busy Queue"; + push @out, "----------"; + for (keys %DXMsg::busy) { + my $r = $DXMsg::busy{$_}; + push @out, "$_ : $r->{msgno}, $r->{from} -> $r->{to}, $r->{subject}\n"; + } } -push @out, "Busy Queue"; -for (keys %DXMsg::busy) { - push @out, "$_ : $DXMsg::busy{$_}\n"; +if (!$line || $line =~ /^w/i) { + push @out, "Work Queue"; + push @out, "----------"; + for (keys %DXMsg::work) { + my $r = $DXMsg::work{$_}; + push @out, print_all_fields($self, $r, "Msg Parameters $r->{msgno}"); + } } + return (0, @out);