diff --git a/platform/src/dbms/db_manager_api/db_manager_api.cpp b/platform/src/dbms/db_manager_api/db_manager_api.cpp index 2f296d6e..a5b4ecde 100644 --- a/platform/src/dbms/db_manager_api/db_manager_api.cpp +++ b/platform/src/dbms/db_manager_api/db_manager_api.cpp @@ -1015,6 +1015,21 @@ bool db_manager_api::initCompleteProjectExe() srcList.append(strProductSrcPath); } + // 处理resource文件夹:当经典工程的文件夹下有resource文件时,覆盖至程序安装目录的resource文件夹 + QString strResourceDstPath = CFileUtil::getSimplePath(CFileUtil::getCurModuleDir() + "../../resource" ).c_str(); + QString strResourceSrcPath = CFileUtil::getSimplePath(CFileUtil::getCurModuleDir() + "../../products/").c_str(); + strResourceSrcPath += QDir::separator()+m_productName + QDir::separator() + m_projectName + QDir::separator()+ "resource"; + if (dbDir.exists(strResourceSrcPath)) + { + dstList.append(strResourceDstPath); + srcList.append(strResourceSrcPath); + sig_showMsg(tr("复制文件resource...")); + } + else + { + sig_showMsg(tr("不复制文件resource...")); + } + m_pFileOpt->deleteDir(strDataDstPath); if (!m_pFileOpt->copyFiles(srcList, dstList)) { diff --git a/platform/src/dbms/db_manager_api/file_opt.cpp b/platform/src/dbms/db_manager_api/file_opt.cpp index 209a79eb..113e19d7 100644 --- a/platform/src/dbms/db_manager_api/file_opt.cpp +++ b/platform/src/dbms/db_manager_api/file_opt.cpp @@ -123,10 +123,14 @@ bool file_opt::copyDirectoryFiles(const QString& fromDir, const QString& toDir, continue; } - /**< 当允许覆盖操作时,将旧文件进行删除操作 */ - if ( coverFileIfExist && targetDir.exists( fileInfo.fileName() ) ) + /**< 当允许覆盖操作时,处理目标文件 */ + if ( coverFileIfExist ) { - targetDir.remove( fileInfo.fileName() ); + // 如果目标文件存在,先删除它 + if ( targetDir.exists( fileInfo.fileName() ) ) + { + targetDir.remove( fileInfo.fileName() ); + } } /// 进行文件copy diff --git a/product/src/fes/include/FesDef.h b/product/src/fes/include/FesDef.h index d837eaec..dfe5594c 100644 --- a/product/src/fes/include/FesDef.h +++ b/product/src/fes/include/FesDef.h @@ -108,7 +108,7 @@ using namespace std; const float CN_FesFloatCompare = 0.000001f;//用于浮点型数据的比较 const int CN_FesMaxProtocolNum = 64; //系统可接入规约数 -const int CN_FesMaxRtuNumPerChan = 32; //每个通道可接设备数(只对通道为polling方式) +const int CN_FesMaxRtuNumPerChan = 64; //每个通道可接设备数(只对通道为polling方式) const int CN_FesMaxChangeMultiple = 5; //变化数据缓冲区为数据个数的倍数 const int CN_FesMaxDzParamSize =800; //定值参数最大长度 const int CN_FesMaxDzNum =40; //定值最大个数一帧的定值个数最大40个(KBD104中规定) diff --git a/product/src/tools/debug_tool/FesDef.h b/product/src/tools/debug_tool/FesDef.h index 9696a067..79a57048 100644 --- a/product/src/tools/debug_tool/FesDef.h +++ b/product/src/tools/debug_tool/FesDef.h @@ -101,7 +101,7 @@ using namespace std; const float CN_FesFloatCompare = 0.000001;//用于浮点型数据的比较 const int CN_FesMaxProtocolNum = 64; //系统可接入规约数 -const int CN_FesMaxRtuNumPerChan = 32; //每个通道可接设备数(只对通道为polling方式) +const int CN_FesMaxRtuNumPerChan = 64; //每个通道可接设备数(只对通道为polling方式) const int CN_FesMaxChangeMultiple = 5; //变化数据缓冲区为数据个数的倍数 const int CN_FesMaxDzParamSize =800; //定值参数最大长度 const int CN_FesMaxDzNum =40; //定值最大个数一帧的定值个数最大40个(KBD104中规定) diff --git a/product/src/tools/debug_tool_v2/FesDef.h b/product/src/tools/debug_tool_v2/FesDef.h index 261d91ff..c8dd9f75 100644 --- a/product/src/tools/debug_tool_v2/FesDef.h +++ b/product/src/tools/debug_tool_v2/FesDef.h @@ -101,7 +101,7 @@ using namespace std; const float CN_FesFloatCompare = 0.000001;//用于浮点型数据的比较 const int CN_FesMaxProtocolNum = 64; //系统可接入规约数 -const int CN_FesMaxRtuNumPerChan = 32; //每个通道可接设备数(只对通道为polling方式) +const int CN_FesMaxRtuNumPerChan = 64; //每个通道可接设备数(只对通道为polling方式) const int CN_FesMaxChangeMultiple = 5; //变化数据缓冲区为数据个数的倍数 const int CN_FesMaxDzParamSize =800; //定值参数最大长度 const int CN_FesMaxDzNum =40; //定值最大个数一帧的定值个数最大40个(KBD104中规定)