diff options
author | ivan <ivan> | 2002-04-24 09:09:36 +0000 |
---|---|---|
committer | ivan <ivan> | 2002-04-24 09:09:36 +0000 |
commit | 70e1035b6a95d2bb0b2bacc4316e9d0a973db813 (patch) | |
tree | 7200d8992caf431eff62d3c963405d2e29e9c728 | |
parent | f3d48cda02218523b2cafcc3c3edfe5771d8676e (diff) |
require_cardname option
-rw-r--r-- | FS/FS/Conf.pm | 7 | ||||
-rw-r--r-- | FS/FS/cust_main.pm | 2 |
2 files changed, 8 insertions, 1 deletions
diff --git a/FS/FS/Conf.pm b/FS/FS/Conf.pm index 2a7a4c103..3565be965 100644 --- a/FS/FS/Conf.pm +++ b/FS/FS/Conf.pm @@ -909,6 +909,13 @@ httemplate/docs/config.html 'type' => 'checkbox', }, + { + 'key' => 'require_cardname', + 'section' => 'billing', + 'description' => 'Require an "Exact name on card" to be entered explicitly; don\'t default to using the first and last name.', + 'type' => 'checkbox', + }, + ); 1; diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm index 4a6a95251..64e9b5f91 100644 --- a/FS/FS/cust_main.pm +++ b/FS/FS/cust_main.pm @@ -689,7 +689,7 @@ sub check { return gettext('expired_card') if $y<$nowy || ( $y==$nowy && $1<$nowm ); } - if ( $self->payname eq '' ) { + if ( $self->payname eq '' && ! $conf->exists('require_cardname') ) { $self->payname( $self->first. " ". $self->getfield('last') ); } else { $self->payname =~ /^([\w \,\.\-\']+)$/ |