private void EditConferenceCategory(object sender, EventArgs e) { if (ValidateChildren(ValidationConstraints.Enabled)) { conferenceCategoryRepository.EditCategory(new ConferenceCategoryModel { ConferenceCategoryId = (int)CategoryId, ConferenceCategoryName = CategoryNameTextBox.Text, ConferenceCategoryCode = CategoryCodeTextBox.Text }); Close(); } }
public IActionResult Post(int Id, ConferenceCategoryModel conferenceCategoryModel) { conferenceCategoryModel.ConferenceCategoryId = Id; conferenceCategory.EditCategory(conferenceCategoryModel); return(Ok(conferenceCategoryModel)); }