=item domain
+=item catchall - optional svcnum of an svc_acct record, designating an email catchall account.
+
=back
=head1 METHODS
'reczone' => '@',
'recaf' => 'IN',
'rectype' => 'SOA',
- 'recdata' => "$soamachine $soaemail ( ". time2str("%Y%m%e", time). "00 ".
+ 'recdata' => "$soamachine $soaemail ( ". time2str("%Y%m%d", time). "00 ".
"$soarefresh $soaretry $soaexpire $soadefaultttl )"
};
$error = $soa->insert;
'svcnum' => $self->svcnum,
'reczone' => '@',
'recaf' => 'IN',
- 'rectype' => 'mx',
+ 'rectype' => 'MX',
'recdata' => $mxmachine,
};
my $error = $mx->insert;
sub check {
my $self = shift;
- my $error;
+ my $error =
+ $self->ut_numbern('svcnum')
+ || $self->ut_numbern('catchall')
+ ;
+ return $error if $error;
my $x = $self->setfixed;
return $x unless ref($x);
$recref->{action} =~ /^(M|N)$/ or return "Illegal action";
$recref->{action} = $1;
+ my $svc_acct = qsearchs( 'svc_acct', { 'svcnum' => $recref->{catchall} } );
+ return "Unknown catchall" unless $svc_acct || ! $recref->{catchall};
+
$self->ut_textn('purpose');
}
=head1 VERSION
-$Id: svc_domain.pm,v 1.9 2001-04-22 01:38:39 ivan Exp $
+$Id: svc_domain.pm,v 1.14 2001-08-17 10:57:23 ivan Exp $
=head1 BUGS
=head1 SEE ALSO
L<FS::svc_Common>, L<FS::Record>, L<FS::Conf>, L<FS::cust_svc>,
-L<FS::part_svc>, L<FS::cust_pkg>, L<FS::SSH>, L<Net::Whois>, L<ssh>,
+L<FS::part_svc>, L<FS::cust_pkg>, L<Net::Whois>, L<ssh>,
L<dot-qmail>, schema.html from the base documentation, config.html from the
base documentation.