[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb:[3054] addons/1.3/assets/trunk/scripts/asset.pl
- Subject: SF.net SVN: ledger-smb:[3054] addons/1.3/assets/trunk/scripts/asset.pl
- From: ..hidden..
- Date: Fri, 20 Aug 2010 16:22:35 +0000
Revision: 3054
http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=3054&view=rev
Author: einhverfr
Date: 2010-08-20 16:22:34 +0000 (Fri, 20 Aug 2010)
Log Message:
-----------
Correction in mapping logic for dep accounts on import
Modified Paths:
--------------
addons/1.3/assets/trunk/scripts/asset.pl
Modified: addons/1.3/assets/trunk/scripts/asset.pl
===================================================================
--- addons/1.3/assets/trunk/scripts/asset.pl 2010-08-19 19:28:45 UTC (rev 3053)
+++ addons/1.3/assets/trunk/scripts/asset.pl 2010-08-20 16:22:34 UTC (rev 3054)
@@ -897,8 +897,9 @@
$ai->{asset_class_id} = $class->{"$ai->{asset_class}"}->{id};
$ai->{dep_account_id} = $class->{"$ai->{asset_class}"}->{dep_account_id};
$ai->{asset_account_id} = $asset_account->{"$ai->{asset_account}"}->{id};
- $ai->{dep_account_id} = $asset_account->{"$ai->{dep_account}"}->{id};
-
+ if (!$ai->{dep_account_id}){
+ $ai->{dep_account_id} = $dep_account->{$default_dep_account}->{id};
+ }
for my $l (@{$asset->{locations}}){
if ($ai->{location} eq $l->{description}){
$ai->{location} = $l->{id};
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.