Exemplo n.º 1
0
        private void btnAddMenu_Click(object sender, EventArgs e)
        {
            var categoryId = GetSelectedCategoryId();
            var frm        = new MenuProcessing(categoryId, -1);

            frm.ShowDialog(this);
            if (frm.IsChange)
            {
                dgvCategory_SelectionChanged(null, null);
            }
        }
Exemplo n.º 2
0
 private void dgvMenu_CellClick(object sender, DataGridViewCellEventArgs e)
 {
     if (dgvMenu.Columns[e.ColumnIndex].Name == "editMenu")
     {
         var categoryId = GetSelectedCategoryId();
         var menuId     = GetSelectedMenuId();
         var form       = new MenuProcessing(categoryId, menuId);
         form.ShowDialog(this);
         if (form.IsChange)
         {
             dgvCategory_SelectionChanged(null, null);
         }
     }
 }