projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
RT# 81249 - added ability to validate price plan option fields
[freeside.git]
/
FS
/
FS
/
contact.pm
diff --git
a/FS/FS/contact.pm
b/FS/FS/contact.pm
index
76ebe98
..
8f6b6a3
100644
(file)
--- a/
FS/FS/contact.pm
+++ b/
FS/FS/contact.pm
@@
-12,6
+12,7
@@
use FS::contact_class;
use FS::cust_location;
use FS::contact_phone;
use FS::contact_email;
use FS::cust_location;
use FS::contact_phone;
use FS::contact_email;
+use FS::contact::Import;
use FS::queue;
use FS::cust_pkg;
use FS::phone_type; #for cgi_contact_fields
use FS::queue;
use FS::cust_pkg;
use FS::phone_type; #for cgi_contact_fields
@@
-130,7
+131,6
@@
sub insert {
my $dbh = dbh;
my $error = $self->SUPER::insert;
my $dbh = dbh;
my $error = $self->SUPER::insert;
- $error ||= $self->insert_password_history;
if ( $error ) {
$dbh->rollback if $oldAutoCommit;
if ( $error ) {
$dbh->rollback if $oldAutoCommit;
@@
-190,6
+190,15
@@
sub insert {
}
}
}
}
+ if ( $self->get('password') ) {
+ my $error = $self->is_password_allowed($self->get('password'))
+ || $self->change_password($self->get('password'));
+ if ( $error ) {
+ $dbh->rollback if $oldAutoCommit;
+ return $error;
+ }
+ }
+
$dbh->commit or die $dbh->errstr if $oldAutoCommit;
'';
$dbh->commit or die $dbh->errstr if $oldAutoCommit;
'';
@@
-465,7
+474,7
@@
and replace methods.
sub check {
my $self = shift;
sub check {
my $self = shift;
- if ( $self->selfservice_access eq 'R' || $self->selfservice_access eq 'P' ) {
+ if ( $self->selfservice_access eq 'R' || $self->selfservice_access eq '
E' || $self->selfservice_access eq '
P' ) {
$self->selfservice_access('Y');
$self->_resend('Y');
}
$self->selfservice_access('Y');
$self->_resend('Y');
}
@@
-613,7
+622,7
@@
sub authenticate_password {
$hash eq $check_hash;
$hash eq $check_hash;
- } else {
+ } else {
return 0 if $self->_password eq '';
return 0 if $self->_password eq '';