Add account start and end date to import/export
This commit is contained in:
parent
3684c324c0
commit
397096680c
|
@ -72,10 +72,12 @@ bool XMLExportEngine::SaveAccounts()
|
|||
_writer->writeAttribute("number", account.number);
|
||||
// _writer->writeAttribute("shared", (account.shared ? "1" : "0"));
|
||||
_writer->writeAttribute("blocked", (account.blocked ? "1" : "0"));
|
||||
// _writer->writeAttribute("default", (account._default ? "1" : "0"));
|
||||
_writer->writeAttribute("default", (account._default ? "1" : "0"));
|
||||
// _writer->writeAttribute("is_owner", (account.is_owner ? "1" : "0"));
|
||||
_writer->writeAttribute("virtual", (account._virtual ? "1" : "0"));
|
||||
_writer->writeAttribute("hidden", (account.hidden ? "1" : "0"));
|
||||
_writer->writeAttribute("start", account.start_date.toString("dd/MM/yyyy"));
|
||||
_writer->writeAttribute("end", account.end_date.toString("dd/MM/yyyy"));
|
||||
_writer->writeEndElement();
|
||||
}
|
||||
|
||||
|
|
|
@ -111,6 +111,9 @@ void XMLImportEngine::LoadAccount(const QXmlAttributes& attrs)
|
|||
ac.blocked = (attrs.value("blocked") == "1");
|
||||
ac._virtual = (attrs.value("virtual") == "1");
|
||||
ac.hidden = (attrs.value("hidden") == "1");
|
||||
ac._default = (attrs.value("default") == "1");
|
||||
ac.start_date = (QDate::fromString("dd/MM/yyyy", attrs.value("start")));
|
||||
ac.end_date = (QDate::fromString("dd/MM/yyyy", attrs.value("start")));
|
||||
|
||||
UNESCAPE_CHARS(ac.name);
|
||||
UNESCAPE_CHARS(ac.number);
|
||||
|
|
Loading…
Reference in New Issue
Block a user