Exemplo n.º 1
0
 private void btnAdd_Click(object sender, EventArgs e)
 {
     if (!loggedUser.access(Convert.ToInt16(btnAdd.Tag)))
     {
         return;
     }
     InventoryAdd inv = new InventoryAdd(loggedUser);
     inv.ShowDialog();
     LoadItems();
 }
Exemplo n.º 2
0
        private void addToolStripMenuItem4_Click(object sender, EventArgs e)
        {
            if (!loggedIn())
            {
                return;
            }
            if (!loggedUser.access(Convert.ToInt16(addToolStripMenuItem4.Tag)))
            {
                return;
            }
            InventoryAdd inv = new InventoryAdd(loggedUser);

            inv.ShowDialog();
        }
Exemplo n.º 3
0
 private void dgvInv_Click(object sender, EventArgs e)
 {
     pEdt.Enabled = false;
     //dgvInv.Enabled = true;
     try
     {
         numQty.Value = Convert.ToDecimal(dgvInv["SLeft", dgvInv.CurrentCell.RowIndex].Value);
         cmbItems.SelectedValue = Convert.ToInt16(dgvInv["TDeductedMealID", dgvInv.CurrentCell.RowIndex].Value);
         dtpDateAdded.Value = Convert.ToDateTime(dgvInv["LastCreditDate", dgvInv.CurrentCell.RowIndex].Value);
     }
     catch (Exception ex)
     {
         MessageBox.Show("Please add stock to start the inventory count.\n"  + ex.Message);
         if (!loggedUser.access(Convert.ToInt16(btnAdd.Tag)))
         {
             return;
         }
         InventoryAdd inv = new InventoryAdd(loggedUser);
         inv.ShowDialog();
         LoadItems();
     }
 }