RT# 78356 - added ability to create and modify rateplans and access point when change...
[freeside.git] / FS / FS / part_svc.pm
index dcc7843..3415595 100644 (file)
@@ -519,6 +519,18 @@ sub part_export_dsl_pull {
     grep $_->can('dsl_pull'), $self->part_export;
 }
 
+=item part_export_partsvc
+
+Returns a list of any exports (see L<FS::part_export>) for this service that
+are capable of pushing a change after part svc is changed.
+
+=cut
+
+sub part_export_partsvc {
+    my $self = shift;
+    grep $_->can('export_partsvc'), $self->part_export;
+}
+
 =item cust_svc [ PKGPART ] 
 
 Returns a list of associated customer services (FS::cust_svc records).
@@ -909,6 +921,11 @@ sub process {
   );
 
   die "$error\n" if $error;
+
+  foreach my $part_svc_export ( $new->part_export_partsvc ) {
+    $error = $part_svc_export->export_partsvc($new);
+  }
+  return $error if $error;
 }
 
 =item process_bulk_cust_svc