Merge branch 'KSM-18' of martin/kima2-cpp into master
This commit is contained in:
commit
bc5c63fe0d
1 changed files with 9 additions and 1 deletions
|
@ -11,8 +11,16 @@ std::size_t CsvReader::readSellersFromFile(const fs::path& filePath, Marketplace
|
||||||
csv::CSVFormat format;
|
csv::CSVFormat format;
|
||||||
format.delimiter(';');
|
format.delimiter(';');
|
||||||
|
|
||||||
|
#if defined(_WIN64) || defined(_WIN32)
|
||||||
|
// Windows: Somhow this is necessary in order to open file names with umlauts
|
||||||
|
auto wide = filePath.wstring();
|
||||||
|
std::string fileName(wide.begin(), wide.end());
|
||||||
|
|
||||||
|
csv::CSVReader csvReader(fileName, format);
|
||||||
|
#else
|
||||||
csv::CSVReader csvReader(filePath.string(), format);
|
csv::CSVReader csvReader(filePath.string(), format);
|
||||||
|
#endif
|
||||||
|
|
||||||
for (auto& seller : market->getSellers()) {
|
for (auto& seller : market->getSellers()) {
|
||||||
seller->setState(Seller::State::DELETE);
|
seller->setState(Seller::State::DELETE);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue