fix bugs
This commit is contained in:
+36
-6
@@ -591,7 +591,6 @@ namespace SafeBagDE70
|
||||
private bool DoCountStart()
|
||||
{
|
||||
bool bSuccess = true;
|
||||
printerFlag = false;
|
||||
|
||||
string currentMethod = MethodBase.GetCurrentMethod().Name;
|
||||
try
|
||||
@@ -620,6 +619,14 @@ namespace SafeBagDE70
|
||||
AutoSerialGet();
|
||||
bIsCounted = true;
|
||||
Log.Information("After AutoCount: " + GetShortInforFromCountItems());
|
||||
var state=GetCDMState();
|
||||
if (state.IsError>0)
|
||||
{
|
||||
string str = "ĐÃ XẢY RA LỖI TRONG QUÁ TRÌNH NỘP TIỀN";
|
||||
Log.Information(str);
|
||||
DoCheck();
|
||||
EndSession(COUNTINGSTATE.FULLIFSTORE, str);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -835,7 +842,7 @@ namespace SafeBagDE70
|
||||
//Debug.WriteLine(quantityStored);
|
||||
|
||||
var previousCassetData = AppData.GetCassetteData();
|
||||
if(CheckPreStoreValid(previousCassetData,300,sessions))
|
||||
if(CheckPreStoreValid(previousCassetData, AppData.MaxNotes, sessions))
|
||||
{
|
||||
cCmdRsp.SendXXCmd((byte)Command.CMD_DE_STORESTART);
|
||||
bSuccess = WaitUntilCountReady(10);
|
||||
@@ -1028,18 +1035,41 @@ namespace SafeBagDE70
|
||||
if (AppData.CurrentCustomerAccount != null)
|
||||
{
|
||||
var strTransactionCode = AppData.CurrentCustomerAccount.TransactionCode;
|
||||
strNotify = strTransactionCode + "\r\n" + strNotify;
|
||||
strNotify = "MÃ GD: "+strTransactionCode + "\r\n" + strNotify;
|
||||
|
||||
}
|
||||
if(strMessage!=null)
|
||||
{
|
||||
strNotify += strMessage;
|
||||
}
|
||||
mainWindow.ShowInformationScreen(strNotify, false, false);
|
||||
}
|
||||
Dispatcher.Invoke(() =>
|
||||
{
|
||||
mainWindow.ShowInformationScreen(strNotify, false, false);
|
||||
});
|
||||
ResetSessions();
|
||||
StartWelcomeTimer();
|
||||
|
||||
}
|
||||
else if(strMessage!=null)
|
||||
{
|
||||
var strNotify = "";
|
||||
if (AppData.CurrentCustomerAccount != null)
|
||||
{
|
||||
var strTransactionCode = AppData.CurrentCustomerAccount.TransactionCode;
|
||||
strNotify = "MÃ GD: "+strTransactionCode + "\r\n" + strNotify;
|
||||
|
||||
}
|
||||
if (strMessage != null)
|
||||
{
|
||||
strNotify += strMessage;
|
||||
}
|
||||
Dispatcher.Invoke(() =>
|
||||
{
|
||||
mainWindow.ShowInformationScreen(strNotify, false, false);
|
||||
});
|
||||
ResetSessions();
|
||||
StartWelcomeTimer();
|
||||
}
|
||||
else
|
||||
{
|
||||
mainWindow.ShowWelcomeScreen();
|
||||
@@ -1171,7 +1201,7 @@ namespace SafeBagDE70
|
||||
var shopName = AppData.CurrentCustomerAccount.Name;
|
||||
var shopCode = AppData.CurrentCustomerAccount.CustomerId;
|
||||
var tradingCode = AppData.CurrentCustomerAccount.TransactionCode;// "TRA04052024CDM";
|
||||
var storeAccountNumber = 686868686688;
|
||||
var storeAccountNumber = AppData.CurrentCustomerAccount.CustomerId;
|
||||
var currentTime = DateTime.Now;
|
||||
var printDocument = new PrintDocument();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user