소스 검색

Z991239-6292 #comment feat: 卡库初始化精简日志

Signed-Off-By: commit-hook
刘文涛80174520 3 달 전
부모
커밋
b7e8c2fe06

+ 4 - 41
Module/mod_cardissuerstore/CardIssuerStoreFSM.cpp

@@ -1404,7 +1404,7 @@ ErrorCodeEnum CCardIssuerFSM::OnInit()
 		DbgWithLink(LOG_LEVEL_WARN, LOG_TYPE_SYSTEM)("create card process failed.");
 		return Error_Resource;
 	}
-	DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("Source Code complied at: %s %s", __DATE__, __TIME__);
+	DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("Source Code complied at: %s %s", __DATE__, __TIME__);
 	CSystemStaticInfo sysInfo;
 	//oilyang 20160331
 	//so many function always return Error_Succeed,so is useless to process it.
@@ -1412,7 +1412,6 @@ ErrorCodeEnum CCardIssuerFSM::OnInit()
 	GetEntityBase()->GetFunction()->GetSystemStaticInfo(sysInfo);
 	m_csMachineType = sysInfo.strMachineType;
 	m_terminalNo = sysInfo.strTerminalID;
-	DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("CardIssuer, MachineType:%s, TerminalNo:%s",m_csMachineType.GetData(), m_terminalNo.GetData());
 #ifdef RVC_OS_WIN
 	//如果是东信卡库,将CardLibDB_CMB.db3文件拷贝到运行时中,若运行时已存在该文件,不再拷贝
 	if(!m_csMachineType.Compare("RVC.CardStore", true))
@@ -1439,8 +1438,8 @@ ErrorCodeEnum CCardIssuerFSM::OnInit()
 				DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("end copy file CardLibDB_CMB.db3 to runinfo.");
 			}
 			else if(FindFirstFileA((LPCTSTR)runinfodbFile, &findData) != INVALID_HANDLE_VALUE){
-				LogWarn(Severity_Low, Error_Unexpect, CardIssuerStore_UserErrorCode_EastCom_Exist_DataFile, "runinfo has CardLibDB_CMB.db3 file.");
-				DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("has exist CardLibDB_CMB.db3 in runinfo");
+				//LogWarn(Severity_Low, Error_Unexpect, CardIssuerStore_UserErrorCode_EastCom_Exist_DataFile, "runinfo has CardLibDB_CMB.db3 file.");
+				DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("has exist CardLibDB_CMB.db3 in runinfo");
 			}else if(FindFirstFileA((LPCTSTR)depdbFile, &findData) == INVALID_HANDLE_VALUE){
 				DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("no CardLibDB_CMB.db3 in dep");
 			}else{
@@ -1449,25 +1448,6 @@ ErrorCodeEnum CCardIssuerFSM::OnInit()
 		}
 	}
 
-	CSimpleStringA runinfoPath(true);
-	ErrorCodeEnum  err = GetEntityBase()->GetFunction()->GetPath("RunInfo", runinfoPath);
-	if (err != Error_Succeed) {
-		DbgWithLink(LOG_LEVEL_WARN, LOG_TYPE_SYSTEM)("get system RunInfo value failed.");
-	}
-	CSimpleStringA runinfoOldFile = runinfoPath + SPLIT_SLASH_STR + "runcfg" + SPLIT_SLASH_STR + "CardIssuer.ini";
-	CSimpleStringA runinfoNewFile = runinfoPath + SPLIT_SLASH_STR + "runcfg" + SPLIT_SLASH_STR + "CardIssuerStore.ini";
-	if (ExistsFile(runinfoNewFile.GetData())) {
-		DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("CardIssuerStore.ini is Exist.");
-	}
-	else {
-		if (ExistsFile(runinfoOldFile.GetData())) {
-			DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("CardIssuerStore.ini is not Exist. CardIssuer.ini is Exist");
-		}
-		else {
-			DbgWithLink(LOG_LEVEL_INFO, LOG_TYPE_SYSTEM)("CardIssuerStore.ini is not Exist. CardIssuer.ini is not Exist");
-		}
-	}
-
 #endif //RVC_OS_WIN
 	m_devStatus.eMedia = CI_MEDIA_NOTPRESENT;
 	m_bHasHopper[0] = false;
@@ -7098,24 +7078,7 @@ int CCardIssuerFSM::JudgeCardType(CSimpleStringA cardno, bool& bMismatch)
 	//	return 3;
 	return cardType;
 }
-void CCardIssuerFSM::SetEnterMainPage()
-{
-	//设置运行时文件
-	CSmartPointer<IConfigInfo> spConfig;
-	int enterMainPageInt = 0;
-	ErrorCodeEnum err = GetEntityBase()->GetFunction()->OpenConfig(Config_Run, spConfig);
-	if (err != Error_Succeed) {
-		DbgWithLink(LOG_LEVEL_WARN, LOG_TYPE_SYSTEM)("SetEnterMainPage, get cfg file failed ");
-	}
-	else {
-		//新在,旧也在,新进入首页则不拷贝,否则重新拷贝
-		spConfig->ReadConfigValueInt("all", "enterMainPage", enterMainPageInt);
-		if (2 != enterMainPageInt) {
-			spConfig->WriteConfigValueInt("all", "enterMainPage", 2);//进入首页
-			LogWarn(Severity_Low, Error_Unexpect, CardIssuerStore_UserErrorCode_EnterMainPage_SetFlag, "CardIssuerStore enterMainPage set succ");
-		}
-	}
-}
+
 
 void CCardIssuerFSM::HttpsLogCallBack(const char* logtxt) {
 	DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM).setAPI(__FUNCTION__)("%s", logtxt);

+ 1 - 1
Module/mod_cardissuerstore/CardIssuerStoreFSM.h

@@ -1305,7 +1305,7 @@ public:
 	void SetCancelByRFICFlag(bool bCancel = true) { m_bCancelByRFIC = bCancel; }
 	CSimpleStringA GetPreOnlineICCardNo() { return m_currCardNo; }
 	void CloseAndClearDevObj(bool bCheckConnecting = true, bool bCloseOnly = false);
-	void SetEnterMainPage();
+
 	static void HttpsLogCallBack(const char* logtxt);
 	//0:unknow(havn't access microservice or access failed),1:both mag & ic ,2:mag only,3:ic only
 	int JudgeCardType(CSimpleStringA cardno, bool &bMismatch);

+ 0 - 3
Module/mod_cardissuerstore/mod_cardissuerStore.cpp

@@ -331,9 +331,6 @@ void CCardIssuerEntity::OnSysVarEvent(const char* pszKey, const char* pszValue,
 	if ((_strnicmp(pszKey, "UIState", strlen("UIState")) == 0))
 	{
 		m_fsm.OnUIState4SetWhatPage(pszValue);
-		if (_strnicmp(pszValue, "M", strlen("M")) == 0) {
-			m_fsm.SetEnterMainPage();//设置进入首页
-		}
 	}
 }