X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Felements%2Fselect-user.html;h=e77788f61431a178e78665f3f63913499baf9134;hb=9d5f61a78f7cddeb65f6943f3e58326f47cc0c0b;hp=ec2341be68d6a91806c66c94096dfceb02ba16c7;hpb=0fb307c305e4bc2c9c27dc25a3308beae3a4d33c;p=freeside.git diff --git a/httemplate/elements/select-user.html b/httemplate/elements/select-user.html index ec2341be6..e77788f61 100644 --- a/httemplate/elements/select-user.html +++ b/httemplate/elements/select-user.html @@ -17,17 +17,6 @@ my %opt = @_; -unless ( $opt{'access_user'} ) { - - my $sth = dbh->prepare(" - SELECT usernum, username FROM access_user - WHERE disabled = '' or disabled IS NULL - ") or die dbh->errstr; - $sth->execute or die $sth->errstr; - while ( my $row = $sth->fetchrow_arrayref ) { - $opt{'access_user'}->{$row->[0]} = $row->[1]; - } - -} +$opt{'access_user'} ||= $FS::CurrentUser::CurrentUser->access_users_hashref();