public static SurveyQuestion SurveyQuestion_Edit(SurveyQuestion model) { try { using (var conn = DbHelper.CCService()) { var p = new DynamicParameters(); p.Add("@QuestionID", model.QuestionID); p.Add("@SurveyID", model.SurveyID); p.Add("@Type", model.Type); p.Add("@Conten", model.Conten); p.Add("@IsMust", model.IsMust); p.Add("@IsRandom", model.IsRandom); p.Add("@MinSel", model.MinSel); p.Add("@MaxSel", model.MaxSel); p.Add("@UserID", model.UserID); p.Add("@IsSample", model.IsSample); p.Add("@ChoiceItems", model.ChoiceItems); p.Add("@ChildQuestions", model.ChildQuestions); p.Add("@Orde",model.Orde); conn.Execute("SurveyQuestion_Edit", p, commandType: CommandType.StoredProcedure); //model.QuestionID = p.Get<Int32>("QuestionID"); return model; } } catch (Exception e) { return null; } }
public SurveyQuestion SurveyQuestion_Edit(SurveyQuestion model) { return SurveyQuestionDAL.SurveyQuestion_Edit(model); }