summaryrefslogtreecommitdiff
path: root/FS
diff options
context:
space:
mode:
Diffstat (limited to 'FS')
-rw-r--r--FS/FS/Schema.pm2
-rw-r--r--FS/FS/did_order.pm11
2 files changed, 12 insertions, 1 deletions
diff --git a/FS/FS/Schema.pm b/FS/FS/Schema.pm
index 803cb47ad..f1814b3d5 100644
--- a/FS/FS/Schema.pm
+++ b/FS/FS/Schema.pm
@@ -3141,7 +3141,7 @@ sub tables_hashref {
'msa', 'varchar', 'NULL', $char_d, '', '',
'npa', 'int', 'NULL', '', '', '',
'latanum', 'int', 'NULL', '', '', '',
- 'rate_center', 'varchar', 'NULL', $char_d, '', '',
+ 'ratecenter', 'varchar', 'NULL', $char_d, '', '',
'state', 'char', 'NULL', 2, '', '',
'quantity', 'int', '', '', '', '',
],
diff --git a/FS/FS/did_order.pm b/FS/FS/did_order.pm
index f46d72bf8..adc965f91 100644
--- a/FS/FS/did_order.pm
+++ b/FS/FS/did_order.pm
@@ -138,6 +138,17 @@ sub did_order_item {
qsearch( 'did_order_item', { 'ordernum' => $self->ordernum } );
}
+=item cust_main
+
+Returns the cust_main (see L<FS::cust_main>), if any, associated with this bulk DID order.
+
+=cut
+
+sub cust_main {
+ my $self = shift;
+ return '' unless $self->custnum;
+ qsearchs('cust_main', { 'custnum' => $self->custnum } );
+}
=back