From 931aa447df899ead7e5dd6ded2243d5288f8df6f Mon Sep 17 00:00:00 2001 From: ivan Date: Fri, 11 Jan 2008 22:53:56 +0000 Subject: [PATCH] add option to enable searching of cust_main.agent_custid with one or two letter prefix before the numeric part --- FS/FS/Conf.pm | 11 +++++++++++ FS/FS/cust_main.pm | 3 +-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/FS/FS/Conf.pm b/FS/FS/Conf.pm index 85a2b9b07..fc67c35aa 100644 --- a/FS/FS/Conf.pm +++ b/FS/FS/Conf.pm @@ -2166,6 +2166,17 @@ worry that config_items is freeside-specific and icky. }, }, + { + 'key' => 'cust_main-agent_custid-format', + 'section' => '', + 'description' => 'Enables searching of various formatted values in cust_main.agent_custid', + 'type' => 'select', + 'select_hash' => [ + '' => 'Numeric only', + 'ww?d+' => 'Numeric with one or two letter prefix', + ], + }, + ); 1; diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm index de4d38de9..ff441dbc0 100644 --- a/FS/FS/cust_main.pm +++ b/FS/FS/cust_main.pm @@ -2166,8 +2166,7 @@ sub bill { # only for figuring next bill date, nothing else, so, reset $sdate again # here $sdate = $cust_pkg->bill || $cust_pkg->setup || $time; - $cust_pkg->last_bill($sdate) - if $cust_pkg->dbdef_table->column('last_bill'); + $cust_pkg->last_bill($sdate); if ( $part_pkg->freq =~ /^\d+$/ ) { $mon += $part_pkg->freq; -- 2.11.0