KissCount

KissCount Commit Details

Date:2014-11-12 20:48:45 (5 years 8 months ago)
Author:Grégory Soutadé
Branch:dev, master, qt5
Commit:e9e0e35c1267470954e162da26778a0919d1719c
Parents: 628c4a4588514eec505532f2cf35f4523a2e7d6f
Message:Fix problems in export engine

Changes:
Msrc/model/export/CSVExportEngine.cpp (2 diffs)
Msrc/model/export/ExportEngine.cpp (3 diffs)

File differences

src/model/export/CSVExportEngine.cpp
161161
162162
163163
164
164
165165
166166
167167
......
196196
197197
198198
199
200
199
200
201201
202202
203203
ESCAPE_CHARS(tag.name);
*_writer << QString::number(tag.id) << ";";
*_writer << "\"" << tag.name << "\"" << ";";
*_writer << "\"" << tag.name << "\"";
*_writer << endl;
}
*_writer << QString::number(it->transfert) << ";";
*_writer << it->formula << ";";
*_writer << (it->meta ? "1" : "0") << ";";
*_writer << (it->_virtual ? "1" : "0");
*_writer << QString::number(it->tag) << ";";
*_writer << (it->_virtual ? "1" : "0") << ";";
*_writer << QString::number(it->tag);
*_writer << endl;
}
src/model/export/ExportEngine.cpp
4040
4141
4242
43
43
4444
4545
4646
......
5151
5252
5353
54
5455
5556
5657
5758
5859
5960
61
6062
6163
6264
......
7880
7981
8082
81
83
84
85
86
8287
8388
8489
bool ExportEngine::SaveFile(std::vector<Operation>* operations)
{
int i;
int account, category;
int account, category, tag;
AccountAmount accountAmount;
int minMonth = -1, minYear = -1;
unsigned int maxMonth = -1, maxYear = -1;
_accounts.clear();
_categories.clear();
_tags.clear();
_accountAmounts.clear();
for(i=0; i<(int)operations->size(); i++)
{
account = (*operations)[i].account;
category = (*operations)[i].category;
tag = (*operations)[i].tag;
if (minYear == -1 || (int)(*operations)[i].year < minYear)
maxYear = minYear = (*operations)[i].year;
if (category && !_categories.count(category))
_categories[category]++;
}
if (tag && !_tags.count(tag))
_tags[tag]++;
}
for(it=_accounts.begin(); it!=_accounts.end(); it++)
{

Archive Download the corresponding diff file