svc_hardware and svc_dish, #11454
[freeside.git] / FS / FS / cust_pkg.pm
index 2efd4fd..13a3b6e 100644 (file)
@@ -761,6 +761,8 @@ sub cancel {
     map  { [ $_, $_->svc_x->table_info->{'cancel_weight'} ]; }
     qsearch( 'cust_svc', { 'pkgnum' => $self->pkgnum } )
   ) {
+    my $part_svc = $cust_svc->part_svc;
+    next if ( defined($part_svc) and $part_svc->preserve );
     my $error = $cust_svc->cancel( %svc_cancel_opt );
 
     if ( $error ) {