示例#1
0
 public void Put([FromBody]UserCoreEntity objUserCoreEntity)
 {
     UserCore objUserCore = new UserCore();
         using (objUserCore as IDisposable)
         {
             objUserCore.Edit(ref objUserCoreEntity);
         }
         objUserCore = null;
 }
示例#2
0
 public HttpResponseMessage GetAll()
 {
     List<UserCoreEntity> objSangamCoreEntityList = new List<UserCoreEntity>();
     UserCore objUserCore = new UserCore();
     using (objUserCore as IDisposable)
         objUserCore.GetAll(ref objSangamCoreEntityList);
     objUserCore = null;
     return Request.CreateResponse(HttpStatusCode.OK, objSangamCoreEntityList,
       Configuration.Formatters.JsonFormatter);
 }
示例#3
0
 public HttpResponseMessage Add([FromBody]UserCoreEntity objUserCoreEntity)
 {
     string strUserID = string.Empty;
     UserCore objUserCore = new UserCore();
     using (objUserCore as IDisposable)
     {
         objUserCoreEntity.RoleID = Mugurtham.Core.Constants.RoleIDForSangamAdmin;
         objUserCore.Add(ref objUserCoreEntity, out strUserID);
     }
     objUserCore = null;
     return Request.CreateResponse(HttpStatusCode.OK, strUserID, Configuration.Formatters.JsonFormatter);
 }
示例#4
0
 public HttpResponseMessage GetAllSangamUsers(string ID)
 {
     List<UserCoreEntity> objSangamCoreEntityList = new List<UserCoreEntity>();
     if (!string.IsNullOrWhiteSpace(ID))
     {
         UserCore objUserCore = new UserCore();
         using (objUserCore as IDisposable)
             objUserCore.GetAllSangamUsers(ref objSangamCoreEntityList, ID);
         objUserCore = null;
     }
     return Request.CreateResponse(HttpStatusCode.OK, objSangamCoreEntityList,
       Configuration.Formatters.JsonFormatter);
 }
示例#5
0
 private Mugurtham.Core.User.UserCoreEntity getUserEntity(string strProfileID)
 {
     Mugurtham.Core.User.UserCoreEntity objUserCoreEntity = null;
     try
     {
         Mugurtham.Core.User.UserCore objUserCore = new Mugurtham.Core.User.UserCore();
         using (objUserCore as IDisposable)
         {
             objUserCoreEntity = new Mugurtham.Core.User.UserCoreEntity();
             using (objUserCoreEntity as IDisposable)
             {
                 objUserCoreEntity = objUserCore.GetByLoginID(strProfileID);
             }
         }
         objUserCore = null;
     }
     catch (Exception objEx)
     {
         Helpers.LogExceptionInFlatFile(objEx);
     }
     return objUserCoreEntity;
 }