diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-01-14 14:08:52 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-01-14 14:08:52 -0600 |
commit | 8654cea10f6902719006d5975db7dc07b2fcc713 (patch) | |
tree | 6cf0608a089c234056746a467f739722687b645a /kmymoney2/converter | |
parent | 2a54aa58cfe166f48d6f1395cbc6c9bfd5e31bfc (diff) | |
download | kmymoney-8654cea10f6902719006d5975db7dc07b2fcc713.tar.gz kmymoney-8654cea10f6902719006d5975db7dc07b2fcc713.zip |
Update to upstream stable version 1.0.5
Diffstat (limited to 'kmymoney2/converter')
-rw-r--r-- | kmymoney2/converter/mymoneystatementreader.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/kmymoney2/converter/mymoneystatementreader.cpp b/kmymoney2/converter/mymoneystatementreader.cpp index 6756767..c08dcff 100644 --- a/kmymoney2/converter/mymoneystatementreader.cpp +++ b/kmymoney2/converter/mymoneystatementreader.cpp @@ -664,6 +664,10 @@ void MyMoneyStatementReader::processTransactionEntry(const MyMoneyStatement::Tra if(!t_in.m_price.isZero()) { s1.setPrice(t_in.m_price); } else { + if(t_in.m_shares.isZero()) { + KMessageBox::information(0, i18n("This imported statement contains investment transactions with no share amount. These transactions will be ignored."), i18n("No share amount provided"), TQString("BlankAmount")); + return; + } s1.setPrice(((t_in.m_amount - t_in.m_fees) / t_in.m_shares).convert(MyMoneyMoney::precToDenom(KMyMoneyGlobalSettings::pricePrecision()))); } |