CopyFile(fileDlg.GetPathName(), strDataPath, FALSE);
}
}
void CSalesManagementSystemDlg::OnBillamount()
{
// TODO: Add your command handler code here
CDlgReport dlgReport;
CString strSQL;
strSQL = "SELECT * FROM SaleBill";
dlgReport.strTitle = "销售单统计报表";
dlgReport.strSQL = strSQL;
dlgReport.DoModal();
}
void CSalesManagementSystemDlg::OnCommoditysaleamount()
{
// TODO: Add your command handler code here
CDlgReport dlgReport;
CString strSQL;
strSQL = "SELECT * FROM SaleCommodity";
dlgReport.strTitle = "销售商品统计报表";
dlgReport.strSQL = strSQL;
dlgReport.DoModal();
}
void CSalesManagementSystemDlg::OnMonthaccount()
{
// TODO: Add your command handler code here
CDlgReport dlgReport;
CString strSQL;
strSQL = "SELECT * FROM SaleBill";
dlgReport.strTitle = "销售月度结算";
dlgReport.strSQL = strSQL;
dlgReport.DoModal();
}
void CSalesManagementSystemDlg::OnExcessalarm()
{
// TODO: Add your command handler code here
CDlgReport dlgReport;
CString strSQL;
strSQL = "SELECT CommodityInfo.*, StoreInfo.stockprice, StoreInfo.saleprice, StoreInfo.num ";
strSQL = strSQL + "FROM CommodityInfo INNER JOIN StoreInfo ON CommodityInfo.barcode = StoreInfo.barcode ";
strSQL = strSQL + "WHERE StoreInfo.num > CommodityInfo.maxnum";
dlgReport.strTitle = "商品过多统计报表";
dlgReport.strSQL = strSQL;
dlgReport.DoModal();
}
void CSalesManagementSystemDlg::OnIncomereport()
{
// TODO: Add your command handler code here
}
void CSalesManagementSystemDlg::OnLittlealarm()
{
// TODO: Add your command handler code here
CDlgReport dlgReport;
CString strSQL;
strSQL = "SELECT CommodityInfo.*, StoreInfo.stockprice, StoreInfo.saleprice, StoreInfo.num ";
strSQL = strSQL + "FROM CommodityInfo INNER JOIN StoreInfo ON CommodityInfo.barcode = StoreInfo.barcode ";
strSQL = strSQL + "WHERE StoreInfo.num < CommodityInfo.minnum";
dlgReport.strTitle = "商品过少统计报表";
dlgReport.strSQL = strSQL;
dlgReport.DoModal();
}
void CSalesManagementSystemDlg::OnUser()
{
// TODO: Add your command handler code here
CDlgUser dlgUser;
dlgUser.DoModal();
}
void CSalesManagementSystemDlg::OnPassword()
{
// TODO: Add your command handler code here
CDlgPasswd dlgPasswd;
dlgPasswd.strCode = strCode;
dlgPasswd.DoModal();
}
void CSalesManagementSystemDlg::OnClose()
{
// TODO: Add your message handler code here and/or call default
OnEsc();
}
void CSalesManagementSystemDlg::OnEsc()
{
// TODO: Add your command handler code here
CDlgQuit dlgQuit;
if (dlgQuit.DoModal() == IDOK)
{
if (dlgQuit.iBackup == 1)
{
CSalesManagementSystemDlg::OnCopy();
}
CDialog::OnOK();
}
}
void CSalesManagementSystemDlg::OnClientintegral()
{
// TODO: Add your command handler code here
CDlgIntegral dlgIntegral;
dlgIntegral.DoModal();
}