public bool InsertTdefectDetail(callTDefect defectDetail, ref long DefectID) { try { using (IDbConnection conn = WebConnection) { conn.Open(); var tran = conn.BeginTransaction(IsolationLevel.ReadUncommitted); DefectID = conn.Insert(defectDetail, tran); tran.Commit(); return(true); } } catch (Exception ex) { throw ex; } }
public bool UpdateTdefect(callTDefect callTDefect) { try { using (IDbConnection conn = WebConnection) { conn.Open(); var tran = conn.BeginTransaction(IsolationLevel.ReadUncommitted); var result = conn.Update(callTDefect, tran); tran.Commit(); return(result); } } catch (Exception ex) { throw ex; } }