Adds immediate migration results in progress
This commit is contained in:
2102 files changed
+17482
-15071
No files matched your search
+14
-14
@@ -33,7 +33,7 @@ bool PvSanImport::publishDataPvSan()
|
||||
//b->removePdmTranslation()
|
||||
if (!readFile(procedures, material, injuries, kind, place1, place2))
|
||||
{
|
||||
ERROR_LOG() << "Can't read pvsan file";
|
||||
ERROR_LOG(m_logger) << "Can't read pvsan file";
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -99,13 +99,13 @@ bool PvSanImport::readFile(QVector<QString> &procedures, QVector<QString> &mater
|
||||
{
|
||||
QString vbkFile = NGL::findFile(NGL::FileType::ConfigFile, QStringLiteral("vbk.csv"));
|
||||
QFile csvFile(vbkFile);
|
||||
DEBUG_LOG() << "Start reading File " << vbkFile;
|
||||
DEBUG_LOG(m_logger) << "Start reading File " << vbkFile;
|
||||
|
||||
if (!csvFile.exists())
|
||||
return false;
|
||||
if(!csvFile.open(QIODevice::ReadOnly))
|
||||
return false;
|
||||
DEBUG_LOG() << "Opened File";
|
||||
DEBUG_LOG(m_logger) << "Opened File";
|
||||
|
||||
bool skip = true;
|
||||
QTextStream in(&csvFile);
|
||||
@@ -118,7 +118,7 @@ bool PvSanImport::readFile(QVector<QString> &procedures, QVector<QString> &mater
|
||||
if (!line.startsWith(QStringLiteral("Version")))
|
||||
continue;
|
||||
|
||||
// ERROR_LOG() << line;
|
||||
// ERROR_LOG(m_logger) << line;
|
||||
QStringList versionSplit = line.split(QStringLiteral(";"));
|
||||
if (versionSplit.size() > 1)
|
||||
m_version = versionSplit.at(1);
|
||||
@@ -161,7 +161,7 @@ bool PvSanImport::readFile(QVector<QString> &procedures, QVector<QString> &mater
|
||||
skip = false;
|
||||
continue;
|
||||
}
|
||||
//ERROR_LOG() << line;
|
||||
//ERROR_LOG(m_logger) << line;
|
||||
|
||||
//now we read all lines until the end
|
||||
if (!line.isEmpty())
|
||||
@@ -265,12 +265,12 @@ bool PvSanImport::readFile(QVector<QString> &procedures, QVector<QString> &mater
|
||||
|
||||
csvFile.close();
|
||||
|
||||
// ERROR_LOG() << "read " << procedures.size() << " procedures from file";
|
||||
// ERROR_LOG() << "read " << material.size() << " materials from file";
|
||||
// ERROR_LOG() << "read " << injuries.size() << " injuries from file";
|
||||
// ERROR_LOG() << "read " << kind.size() << " kinds from file";
|
||||
// ERROR_LOG() << "read " << place1.size() << " place1 from file";
|
||||
// ERROR_LOG() << "read " << place2.size() << " place2 from file";
|
||||
// ERROR_LOG(m_logger) << "read " << procedures.size() << " procedures from file";
|
||||
// ERROR_LOG(m_logger) << "read " << material.size() << " materials from file";
|
||||
// ERROR_LOG(m_logger) << "read " << injuries.size() << " injuries from file";
|
||||
// ERROR_LOG(m_logger) << "read " << kind.size() << " kinds from file";
|
||||
// ERROR_LOG(m_logger) << "read " << place1.size() << " place1 from file";
|
||||
// ERROR_LOG(m_logger) << "read " << place2.size() << " place2 from file";
|
||||
|
||||
|
||||
return true;
|
||||
@@ -336,7 +336,7 @@ bool PvSanImport::addProcedures(const QVector<QString> &procedures)
|
||||
{
|
||||
|
||||
QStringList measure = entry.split(QStringLiteral(";"));
|
||||
// ERROR_LOG() << entry << " size of split: " << measure.size();
|
||||
// ERROR_LOG(m_logger) << entry << " size of split: " << measure.size();
|
||||
if (measure.size() < 34 )
|
||||
continue;
|
||||
Database::PdmSanitationProcedures pros;
|
||||
@@ -405,11 +405,11 @@ bool PvSanImport::addMaterial(const QVector<QString> &material)
|
||||
|
||||
q.prepare(stmt);
|
||||
|
||||
DEBUG_LOG() << "Statement: " << stmt;
|
||||
DEBUG_LOG(m_logger) << "Statement: " << stmt;
|
||||
|
||||
if (!q.exec())
|
||||
{
|
||||
WARNING_LOG() << "Could not delete sanitation materials";
|
||||
WARNING_LOG(m_logger) << "Could not delete sanitation materials";
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user