public bool Create(HoadonbanModel model) { string msgError = ""; try { var result = _dbHelper.ExecuteScalarSProcedureWithTransaction(out msgError, "themhoadonban", "@MAHDB", model.MAHDB, "@MADH", model.MADH, "@NGAYLAP", model.NGAYLAP ); if ((result != null && !string.IsNullOrEmpty(result.ToString())) || !string.IsNullOrEmpty(msgError)) { throw new Exception(Convert.ToString(result) + msgError); } return(true); } catch (Exception ex) { throw ex; } }
public HoadonbanModel CreateHDB([FromBody] HoadonbanModel model) { abc.Create(model); return(model); }
public bool Create(HoadonbanModel model) { return(_res.Create(model)); }