Esempio n. 1
0
 private void btnBillPlease_Click(object sender, EventArgs e)
 {
     if (lbSubTotal.Text == "0")
     {
         frmMessageNotification ms = new frmMessageNotification();
         frmMessageNotification.text = "Không có gì để thanh toán!";
         ms.Show();
         ms.btnConfirm.Click += (o, er) =>
         {
             ms.Close();
         };
         ms.ptClose.Click += (o, er) =>
         {
             ms.Close();
         };
     }
     else
     {
         btnConfirm.Visible    = true;
         btnCancelAll.Visible  = true;
         btnBillPlease.Visible = false;
         flpListOrder.Enabled  = false;
         cbDiscount.Enabled    = false;
     }
 }
Esempio n. 2
0
 private void btnHistory_Click(object sender, EventArgs e)
 {
     if (FoodListDAO.Instance.Load_Bill(lbCustomerCode.Text).Rows.Count > 0)
     {
         frmHistoryFoods frs = new frmHistoryFoods(lbCustomerCode.Text);
         frs.ShowDialog();
     }
     else
     {
         frmMessageNotification ms = new frmMessageNotification();
         frmMessageNotification.text = "Customers have not ordered!Please order and watch later!";
         ms.Show();
         ms.btnConfirm.Click += (o, er) =>
         {
             ms.Close();
         };
     }
 }