public IHttpActionResult DenyByManager(ViewModel.tblQuestionAndAnswer QuestionAndAnswer) { try { bool ret = BisQuestionAndAnswer.DenyByManager(QuestionAndAnswer); if (ret) { return(Ok(ret)); } else { return(NotFound()); } } catch { return(NotFound()); } }
public IHttpActionResult AddQuestionAndAnswer(ViewModel.tblQuestionAndAnswer QuestionAndAnswer) { try { QuestionAndAnswer.IDPersonel = AuUser.ReturnIDUser(QuestionAndAnswer.IDLogUser); QuestionAndAnswer.IDLogUser = null; bool ret = BisQuestionAndAnswer.AddQuestionAndAnswer(QuestionAndAnswer); if (ret) { return(Ok(ret)); } else { return(NotFound()); } } catch { return(NotFound()); } }
public IHttpActionResult DeleteQuestionAndAnswer(object obj) { try { JObject JsonObject = JObject.Parse(obj.ToString()); ViewModel.tblQuestionAndAnswer DelQuestionAndAnswer = JsonObject.ToObject <ViewModel.tblQuestionAndAnswer>(); bool ret = BisQuestionAndAnswer.DeleteQuestionAndAnswer(DelQuestionAndAnswer); if (ret) { return(Ok(ret)); } else { return(NotFound()); } } catch { return(NotFound()); } }
public bool DeleteQuestionAndAnswer(ViewModel.tblQuestionAndAnswer QuestionAndAnswer) { return(sqlHelper.RunProcedure("sp_tblQuestionAndAnswer_DeleteRow", QuestionAndAnswer) > 0); }
public bool DenyByManager(ViewModel.tblQuestionAndAnswer QuestionAndAnswer) { return(sqlHelper.RunProcedure("sp_tblQuestionAndAnswer_DenyByManager", QuestionAndAnswer) > 0); }
public bool UpdateQuestionAndAnswer(ViewModel.tblQuestionAndAnswer QuestionAndAnswer) { return(sqlHelper.RunProcedure("sp_tblQuestionAndAnswer_Update", QuestionAndAnswer) > 0); }
public bool AddQuestionAndAnswer(ViewModel.tblQuestionAndAnswer QuestionAndAnswer) { return(sqlHelper.RunProcedure("sp_tblQuestionAndAnswer_Insert", QuestionAndAnswer) > 0); }