Beispiel #1
0
        public bool Create(QT_CongTacModel model)
        {
            string msgError = "";

            try
            {
                var result = _dbHelper.ExecuteScalarSProcedureWithTransaction(out msgError, "congtac_create",
                                                                              "@ID_CT", model.ID_CT,
                                                                              "@ID_GV", model.ID_GV,
                                                                              "@ID_BM", model.ID_BM,
                                                                              "@CoQuan", model.CoQuan,
                                                                              "@Diachi", model.DiaChi,
                                                                              "@ChucVu", model.ChucVu,
                                                                              "@ThoiGian", model.ThoiGian
                                                                              );
                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 QT_CongTacModel UpdateUser([FromBody] QT_CongTacModel model)
 {
     _QT_CongTacBLL.Update(model);
     return(model);
 }
 public QT_CongTacModel CreateItem([FromBody] QT_CongTacModel model)
 {
     model.ID_CT = Guid.NewGuid().ToString();
     _QT_CongTacBLL.Create(model);
     return(model);
 }
Beispiel #4
0
 public bool Update(QT_CongTacModel model)
 {
     return(_res.Update(model));
 }
Beispiel #5
0
 public bool Create(QT_CongTacModel model)
 {
     return(_res.Create(model));
 }