|
|
@ -328,7 +328,7 @@ void ExportDataThread::run()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if ((b_quit || (!timer->isActive() && !readyToSendZip)) && (!tmpListToZip.isEmpty())) {
|
|
|
|
if ((b_quit || (!timer->isActive() && !readyToSendZip)) && (!tmpListToZip.isEmpty())) {
|
|
|
|
listToZip += tmpListToZip;
|
|
|
|
listToZip.unite(tmpListToZip);
|
|
|
|
tmpListToZip.clear();
|
|
|
|
tmpListToZip.clear();
|
|
|
|
zipTimeStamp.append(lastTimeStamp[0]);
|
|
|
|
zipTimeStamp.append(lastTimeStamp[0]);
|
|
|
|
lastTimeStamp.clear();
|
|
|
|
lastTimeStamp.clear();
|
|
|
@ -377,17 +377,16 @@ void ExportDataThread::run()
|
|
|
|
|
|
|
|
|
|
|
|
argsOk.append("a");
|
|
|
|
argsOk.append("a");
|
|
|
|
argsOk.append(zipFilePaths[1]);
|
|
|
|
argsOk.append(zipFilePaths[1]);
|
|
|
|
|
|
|
|
|
|
|
|
// create zip file
|
|
|
|
// create zip file
|
|
|
|
for (int i = 0; i < listToZip.size(); i++) {
|
|
|
|
QMapIterator<QString, bool> iterator(listToZip);
|
|
|
|
QStringList strList = listToZip[i].split("_");
|
|
|
|
while (iterator.hasNext()) {
|
|
|
|
strList = strList[strList.size() - 1].split(".");
|
|
|
|
iterator.next();
|
|
|
|
int index = listToZip[i].lastIndexOf("/\\", 0);
|
|
|
|
if (iterator.value()) {
|
|
|
|
if (strList[0] == okStr) {
|
|
|
|
ngStream << iterator.key() << endl;
|
|
|
|
okStream << listToZip[i] << endl;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
else {
|
|
|
|
|
|
|
|
okStream << iterator.key() << endl;
|
|
|
|
ngStream << listToZip[i] << endl;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
argsNg.append("-i@" + fileList[0]);
|
|
|
|
argsNg.append("-i@" + fileList[0]);
|
|
|
@ -515,7 +514,7 @@ void ExportDataThread::ConnectServer(QString srcPath, QString destPath) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void ExportDataThread::GetDataFromSaveThread(QString filePath) {
|
|
|
|
void ExportDataThread::GetDataFromSaveThread(QString filePath, bool Ng) {
|
|
|
|
QString remotePath;
|
|
|
|
QString remotePath;
|
|
|
|
QStringList currentTimeStamp;
|
|
|
|
QStringList currentTimeStamp;
|
|
|
|
QRegExp rx("((([0-9]{3}[1-9]|[0-9]{2}[1-9][0-9]{1}|[0-9]{1}[1-9][0-9]{2}|[1-9][0-9]{3})-(((0[13578]|1[02])-(0[1-9]|[12][0-9]|3[01]))|((0[469]|11)-(0[1-9]|[12][0-9]|30))|(02-(0[1-9]|[1][0-9]|2[0-8]))))|((([0-9]{2})(0[48]|[2468][048]|[13579][26])|((0[48]|[2468][048]|[3579][26])00))-02-29))_([0-1]?[0-9]|2[0-3])-([0-5][0-9])");
|
|
|
|
QRegExp rx("((([0-9]{3}[1-9]|[0-9]{2}[1-9][0-9]{1}|[0-9]{1}[1-9][0-9]{2}|[1-9][0-9]{3})-(((0[13578]|1[02])-(0[1-9]|[12][0-9]|3[01]))|((0[469]|11)-(0[1-9]|[12][0-9]|30))|(02-(0[1-9]|[1][0-9]|2[0-8]))))|((([0-9]{2})(0[48]|[2468][048]|[13579][26])|((0[48]|[2468][048]|[3579][26])00))-02-29))_([0-1]?[0-9]|2[0-3])-([0-5][0-9])");
|
|
|
@ -534,7 +533,7 @@ void ExportDataThread::GetDataFromSaveThread(QString filePath) {
|
|
|
|
|
|
|
|
|
|
|
|
if (lastTimeStamp.isEmpty() || (currentTimeStamp[0] != lastTimeStamp[0])) {
|
|
|
|
if (lastTimeStamp.isEmpty() || (currentTimeStamp[0] != lastTimeStamp[0])) {
|
|
|
|
if (!tmpListToZip.isEmpty()) {
|
|
|
|
if (!tmpListToZip.isEmpty()) {
|
|
|
|
listToZip = tmpListToZip;
|
|
|
|
listToZip.unite(tmpListToZip);
|
|
|
|
tmpListToZip.clear();
|
|
|
|
tmpListToZip.clear();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!listToZip.isEmpty()) {
|
|
|
|
if (!listToZip.isEmpty()) {
|
|
|
@ -546,7 +545,7 @@ void ExportDataThread::GetDataFromSaveThread(QString filePath) {
|
|
|
|
timer->stop();
|
|
|
|
timer->stop();
|
|
|
|
timer->start(1000 * (60 * 1 + 10));
|
|
|
|
timer->start(1000 * (60 * 1 + 10));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
tmpListToZip.append(filePath);
|
|
|
|
tmpListToZip.insert(filePath, Ng);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|