=over 4
+=item typepkgnum - primary key
+
=item typenum - Agent type, see L<FS::agent_type>
=item pkgpart - Billing item definition, see L<FS::part_pkg>
my $self = shift;
my $error =
- $self->ut_number('typenum')
+ $self->ut_numbern('typepkgnum')
+ || $self->ut_number('typenum')
|| $self->ut_number('pkgpart')
;
return $error if $error;
return "Unknown pkgpart"
unless qsearchs( 'part_pkg', { 'pkgpart' => $self->pkgpart } );
- ''; #no error
+ $self->SUPER::check;
}
-=back
+=item part_pkg
+
+Returns the FS::part_pkg object associated with this record.
+
+=cut
-=head1 VERSION
+sub part_pkg {
+ my $self = shift;
+ qsearchs( 'part_pkg', { 'pkgpart' => $self->pkgpart } );
+}
-$Id: type_pkgs.pm,v 1.1 1999-08-04 09:03:53 ivan Exp $
+=cut
+
+=back
=head1 BUGS