use FS::Record qw( qsearchs qsearch );
use FS::addr_block;
-@ISA = qw( FS::Record );
+@ISA = qw( FS::Record FS::m2m_Common );
=head1 NAME
my $error =
$self->ut_numbern('routernum')
- || $self->ut_text('routername');
+ || $self->ut_text('routername')
+ || $self->ut_agentnum_acl('agentnum', 'Broadband global configuration')
+ ;
return $error if $error;
$self->SUPER::check;
$self->part_svc_router;
}
+=item agent
+
+Returns the agent associated with this router, if any.
+
+=cut
+
+sub agent {
+ qsearchs('agent', { 'agentnum' => shift->agentnum });
+}
+
=back
=head1 BUGS