summaryrefslogtreecommitdiff
path: root/LedgerSMB
diff options
context:
space:
mode:
authortetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2006-11-14 17:08:19 +0000
committertetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2006-11-14 17:08:19 +0000
commitda136cd084b180edf9e3e56ca25a3acb845f08f0 (patch)
tree8f6d86db836f2020790633ab040e9fe4fa27fd32 /LedgerSMB
parent3241fdf7eff0ff4add51477c131a93a7f34bec46 (diff)
Fix db error when creating vendor without both dates set
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@593 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'LedgerSMB')
-rwxr-xr-xLedgerSMB/CT.pm3
1 files changed, 3 insertions, 0 deletions
diff --git a/LedgerSMB/CT.pm b/LedgerSMB/CT.pm
index be768503..19c0411d 100755
--- a/LedgerSMB/CT.pm
+++ b/LedgerSMB/CT.pm
@@ -476,6 +476,9 @@ sub save_vendor {
($null, $language_code) = split /--/, $form->{language};
$form->{vendornumber} = $form->update_defaults($myconfig, "vendornumber", $dbh) if ! $form->{vendornumber};
+
+ $form->{startdate} = undef unless $form->{startdate};
+ $form->{enddate} = undef unless $form->{enddate};
$query = qq|
UPDATE vendor