Commit 2d3957a8 authored by Ralf Habacker's avatar Ralf Habacker
Browse files

tools/xea2kmt.cpp: Be more descriptive in warning output

CCBUG:429229
parent 520a4474
......@@ -227,6 +227,7 @@ public:
QString title;
QString longDescription;
QString shortDescription;
QString fileName;
TemplateAccount::List accounts;
TemplateAccount *openingBalanceAccount{nullptr};
......@@ -303,7 +304,10 @@ public:
}
if (account->slotList.contains("equity-type") && account->slotList["equity-type"] == "opening-balance") {
if (openingBalanceAccount) {
qWarning() << "template already has specified '" << openingBalanceAccount->name << "' as opening balance account";
qWarning() << "template" << fileName << "already has specified"
<< openingBalanceAccount->name
<< "as opening balance account,"
<< "ignoring account" << account->name;
continue;
}
xml.writeStartElement("flag");
......@@ -501,6 +505,7 @@ protected:
).arg(fileName));
xml.writeDTD("<!DOCTYPE KMYMONEY-TEMPLATE>");
xml.writeStartElement("","kmymoney-account-template");
_template.fileName = fileName;
bool result = _template.writeAsXml(xml);
xml.writeEndElement();
xml.writeEndDocument();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment