[freeside-devel] part_export
ivan
ivan at 420.am
Fri Mar 29 16:42:16 PST 2002
On Wed, Mar 27, 2002 at 02:48:58PM -0800, Mark Wells wrote:
>
> Is the part_svc/part_export relationship meant to be one-to-one?
No, it's one-to-many...
I could see it being many-to-many in the future, but it's not a priority
for 1.4.0...
I ask
> because of the existence of part_export.svcpart, which doesn't seem to be
> used anywhere.
Sure it is... search for the string `new-style exports' in
FS/FS/svc_acct.pm, for example this one in sub insert :
#new-style exports!
unless ( $noexport_hack ) {
foreach my $part_export ( $self->cust_svc->part_svc->part_export ) {
my $error = $part_export->export_insert($self);
if ( $error ) {
$dbh->rollback if $oldAutoCommit;
return "exporting to ". $part_export->exporttype.
" (transaction rolled back): $error";
}
}
}
Note "$self->cust_svc->part_svc->part_export" - and
the part_export sub in FS/FS/part_svc.pm :
sub part_export {
my $self = shift;
my %search = ( 'svcpart' => $self->svcpart );
qsearch('part_export', \%search);
}
Does that help?
--
_ivan
More information about the freeside-devel
mailing list