コード例 #1
0
ファイル: LocationCore.cs プロジェクト: AnandJS/Mugurtham
 public int Edit(ref Mugurtham.Core.Location.LocationCoreEntity objLocationCoreEntity)
 {
     try
     {
         IUnitOfWork objIUnitOfWork = new UnitOfWork();
         using (objIUnitOfWork as IDisposable)
         {
             Mugurtham.DTO.Profile.Location objDTOLocation = new DTO.Profile.Location();
             using (objDTOLocation as IDisposable)
             {
                 AssignDTOFromEntity(ref objDTOLocation, ref objLocationCoreEntity);
             }
             objIUnitOfWork.RepositoryLocation.Edit(objDTOLocation);
             objDTOLocation = null;
         }
         objIUnitOfWork.commit();
         objIUnitOfWork = null;
     }
     catch (Exception objEx)
     {
         Helpers.LogExceptionInFlatFile(objEx);
     }
     return 0;
 }
コード例 #2
0
 public int Edit(ref Mugurtham.Core.Location.LocationCoreEntity objLocationCoreEntity)
 {
     try
     {
         IUnitOfWork objIUnitOfWork = new UnitOfWork(_objLoggedInUser.ConnectionStringAppKey);
         using (objIUnitOfWork as IDisposable)
         {
             Mugurtham.DTO.Profile.Location objDTOLocation = new DTO.Profile.Location();
             using (objDTOLocation as IDisposable)
             {
                 AssignDTOFromEntity(ref objDTOLocation, ref objLocationCoreEntity);
             }
             objIUnitOfWork.RepositoryLocation.Edit(objDTOLocation);
             objDTOLocation = null;
         }
         objIUnitOfWork.commit();
         objIUnitOfWork = null;
     }
     catch (Exception objEx)
     {
         Helpers.LogExceptionInFlatFile(objEx);
     }
     return(0);
 }