示例#1
0
 public async Task <int> AddNewContact(AddNewContactModel Addmodel)
 {
     try
     {
         _dbconnection.StoredProcedure = Constants.AddContactStoredProcedure;
         _dbconnection.Parameters      = Addmodel;
         return(await _dapperRepository.Execute(_dbconnection));
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
        public async Task <ActionResult> AddNewContact([FromBody] AddNewContactModel model)
        {
            var result = await _addressbookservice.AddNewContact(model);

            return(Json(new { success = true, response = result }));
        }