$form->{id} = "";
}
+ $query = '
+ SELECT
+ accno
+ FROM chart
+ WHERE accno = ?';
+ my ($accno) = selectrow_query($form, $dbh, $query, $form->{accno});
+
+ if ($accno) {
+ $form->error($::locale->text('Account number not unique!'));
+ }
+
+
if (!$form->{id} || $form->{id} eq "") {
$query = qq|SELECT nextval('id')|;
($form->{"id"}) = selectrow_query($form, $dbh, $query);
$form->{valid_from} = '';
};
- $query = '
- SELECT
- accno
- FROM chart
- WHERE accno = ?';
- my ($accno) = selectrow_query($form, $dbh, $query, $form->{accno});
-
- if ($accno) {
- $form->error($::locale->text('Account number not unique!'));
- }
-
$query = qq|UPDATE chart SET
accno = ?,
description = ?,
my $template = SL::Template::create(type => 'PlainText', form => $form, myconfig => $myconfig);
my $mail = Mailer->new();
+ $mail->{charset} = $::lx_office_conf{system}->{dbcharset} || Common::DEFAULT_CHARSET;
$mail->{from} = $myconfig->{email};
$mail->{to} = $ref->{recipient};
$mail->{subject} = $template->parse_block($ref->{email_subject});
# Security can be 'tls', 'ssl' or 'none'. Unset equals 'none'. This
# determines whether or not encryption is used and which kind. For
# 'tls' the module 'Net::SMTP::TLS' is required; for 'ssl'
-# 'Net::SMTP::TLS' is required and 'none' only uses 'Net::SMTP'.
+# 'Net::SMTP::SSL' is required and 'none' only uses 'Net::SMTP'.
security = none
# Authentication is only used if 'login' is set. You should only use
# that with 'tls' or 'ssl' encryption.