Exemplo n.º 1
0
 public IHttpActionResult SaveUserInfo(JObject strUser)
 {
     try
     {
         strUserName = _utilities.ValidateRequestParamenters();
         if (string.IsNullOrEmpty(strUserName))
         {
             return(Unauthorized());
         }
         string strValue = strUser["strUser"].ToString();
         var    res      = _user.SaveUserDetails(strValue);
         return(Ok(res));
     }
     catch (Exception ex)
     {
         return(BadRequest(ex.Message));
     }
 }
Exemplo n.º 2
0
 public IHttpActionResult GetUserDetails(int countryId, string city = "", int payment = -1)
 {
     try
     {
         strUserName = _utilities.ValidateRequestParamenters();
         if (string.IsNullOrEmpty(strUserName))
         {
             return(Unauthorized());
         }
         var res = _user.GetUserDetails(countryId, city, payment);
         return(Ok(res));
     }
     catch (Exception ex)
     {
         return(BadRequest(ex.Message));
     }
 }