public IDtoRootUrlStore SetPrimaryRootUrlStore(string RootUrl) { RootUrl = StringSupport.ToLowerFast(RootUrl.StripHttp()); _ServiceBaseUrl ExsistingPrimaryRootURL = this.GetPrimaryPyro_RootUrlStore(); if (ExsistingPrimaryRootURL != null) { ExsistingPrimaryRootURL.IsServersPrimaryUrlRoot = false; } _ServiceBaseUrl ExsistingNonPrimaryRootURL = this.GetPyro_RootUrlStore(RootUrl); if (ExsistingNonPrimaryRootURL != null) { ExsistingNonPrimaryRootURL.IsServersPrimaryUrlRoot = true; } else { _ServiceBaseUrl Pyro_RootUrlStore = new _ServiceBaseUrl(); Pyro_RootUrlStore.IsServersPrimaryUrlRoot = true; Pyro_RootUrlStore.Url = RootUrl; IPyroDbContext.Set <_ServiceBaseUrl>().Add(Pyro_RootUrlStore); } this.Save(); return(this.GetPrimaryRootUrlStore()); }
public IQueryable <ResCurrentType> DbGetAll(Expression <Func <ResCurrentType, bool> > predicate) { IQueryable <ResCurrentType> ResourceEntity = null; ResourceEntity = IPyroDbContext.Set <ResCurrentType>().AsExpandable().Where(predicate); return(ResourceEntity); }
public bool UpdateIfNewOrModifiedServiceConfigration(string Parameter, string Value, string UserUpdating, System.DateTimeOffset UpdateingDateTime) { _ServiceConfiguration DbServiceConfigration = IPyroDbContext.ServiceConfiguration.SingleOrDefault(x => x.Parameter.ToLower() == Parameter.ToLower()); if (DbServiceConfigration != null) { if (DbServiceConfigration.Value.Trim() != Value.Trim()) { DbServiceConfigration.Value = Value; DbServiceConfigration.LastUpdated = UpdateingDateTime; DbServiceConfigration.LastUpdatedUser = UserUpdating; this.Save(); return(true); } else { return(false); } } else { DbServiceConfigration = new _ServiceConfiguration(); DbServiceConfigration.Parameter = Parameter; DbServiceConfigration.Value = Value; DbServiceConfigration.CreatedDate = UpdateingDateTime; DbServiceConfigration.LastUpdated = UpdateingDateTime; DbServiceConfigration.CreatedUser = UserUpdating; DbServiceConfigration.LastUpdatedUser = UserUpdating; DbServiceConfigration = IPyroDbContext.Set <_ServiceConfiguration>().Add(DbServiceConfigration); this.Save(); return(true); } }
public DtoFhirRelease UpdateFhirRelease(DtoFhirRelease DtoFhirRelease) { if (DtoFhirRelease == null) { throw new System.NullReferenceException("DtoFhirRelease cannot be null"); } if (string.IsNullOrWhiteSpace(DtoFhirRelease.FhirVersion)) { throw new System.NullReferenceException("DtoFhirRelease.FhirVersion cannot be null or empty string"); } _FhirRelease DbFhirRelease = IPyroDbContext.FhirRelease.SingleOrDefault(x => x.FhirVersion == DtoFhirRelease.FhirVersion); if (DbFhirRelease == null) { throw new System.NullReferenceException($"Unable to update FhirRelease as no FhirRelease found in the database for the FhirVersion provided: '{DtoFhirRelease.FhirVersion}'"); } else { DbFhirRelease.FhirVersion = DtoFhirRelease.FhirVersion; DbFhirRelease.Description = DtoFhirRelease.Description; DbFhirRelease.Date = DtoFhirRelease.Date; DbFhirRelease.CreatedDate = DtoFhirRelease.CreatedDate; DbFhirRelease.CreatedUser = DtoFhirRelease.CreatedUser; DbFhirRelease.LastUpdated = DtoFhirRelease.LastUpdated; DbFhirRelease.LastUpdatedUser = DtoFhirRelease.LastUpdatedUser; } DbFhirRelease = IPyroDbContext.Set <_FhirRelease>().Add(DbFhirRelease); this.Save(); return(IMapper.Map <DtoFhirRelease>(DbFhirRelease)); }
//---- Resource --------------------------------------------------------------- public ResCurrentType DbGet(Expression <Func <ResCurrentType, bool> > predicate) { ResCurrentType ResourceEntity = null; ResourceEntity = IPyroDbContext.Set <ResCurrentType>().SingleOrDefault(predicate); return(ResourceEntity); }
protected int DbGetALLCount <ResourceBaseType>(Expression <Func <ResourceBaseType, bool> > predicate) where ResourceBaseType : ResourceBase { IQueryable <ResourceBaseType> ResourceEntity = null; ResourceEntity = IPyroDbContext.Set <ResourceBaseType>().AsExpandable().Where(predicate); return(ResourceEntity.Count()); }
public DtoServiceCompartment UpdateServiceCompartment(DtoServiceCompartment DtoServiceCompartment) { _ServiceCompartment ServiceCompartment = IMapper.Map <_ServiceCompartment>(DtoServiceCompartment); DeleteServiceCompartment(ServiceCompartment.Code); ServiceCompartment = IPyroDbContext.Set <_ServiceCompartment>().Add(ServiceCompartment); this.Save(); return(IMapper.Map <DtoServiceCompartment>(ServiceCompartment)); }
protected void DbAddEntity <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>(ResCurrentType Entity) where ResCurrentType : ResourceCurrentBase <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexStringType : ResourceIndexString <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexTokenType : ResourceIndexToken <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexUriType : ResourceIndexUri <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>, new() where ResIndexReferenceType : ResourceIndexReference <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexQuantityType : ResourceIndexQuantity <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexDateTimeType : ResourceIndexDateTime <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> { IPyroDbContext.Set <ResCurrentType>().Add(Entity); this.Save(); }
public DateTimeOffset?GetLastCurrentResourceLastUpdatedValue() { var LastEntity = IPyroDbContext.Set <ResCurrentType>().Max(x => x.LastUpdated); if (LastEntity != null) { return(LastEntity); } else { return(null); } }
public DtoResource DbGetNoXML(Expression <Func <ResCurrentType, bool> > predicate) { return(IPyroDbContext.Set <ResCurrentType>().Where(predicate).Select(x => new DtoResource { Id = x.Id, IsCurrent = x.IsCurrent, FhirId = x.FhirId, IsDeleted = x.IsDeleted, Version = x.VersionId, Received = x.LastUpdated, Method = x.Method, }).FirstOrDefault()); }
public DtoServiceSearchParameterHeavy AddServiceSearchParametersHeavy(DtoServiceSearchParameterHeavy ServiceSearchParameterHeavy) { if (ServiceSearchParameterHeavy == null) { return(null); } var DbSearchParameter = PopulateDbSearchParameter(ServiceSearchParameterHeavy); DbSearchParameter = IPyroDbContext.Set <_ServiceSearchParameter>().Add(DbSearchParameter); this.Save(); ServiceSearchParameterHeavy.Id = DbSearchParameter.Id; return(ServiceSearchParameterHeavy); }
protected IQueryable <ResCurrentType> DbGetAll <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>(Expression <Func <ResCurrentType, bool> > predicate) where ResCurrentType : ResourceCurrentBase <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexStringType : ResourceIndexString <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexTokenType : ResourceIndexToken <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexUriType : ResourceIndexUri <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>, new() where ResIndexReferenceType : ResourceIndexReference <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexQuantityType : ResourceIndexQuantity <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexDateTimeType : ResourceIndexDateTime <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> { IQueryable <ResCurrentType> ResourceEntity = null; ResourceEntity = IPyroDbContext.Set <ResCurrentType>().AsExpandable().Where(predicate); return(ResourceEntity); }
//---- Resource --------------------------------------------------------------- protected ResCurrentType DbGet <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>(Expression <Func <ResCurrentType, bool> > predicate) where ResCurrentType : ResourceCurrentBase <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexStringType : ResourceIndexString <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexTokenType : ResourceIndexToken <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexUriType : ResourceIndexUri <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>, new() where ResIndexReferenceType : ResourceIndexReference <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexQuantityType : ResourceIndexQuantity <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexDateTimeType : ResourceIndexDateTime <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> { ResCurrentType ResourceEntity = null; ResourceEntity = IPyroDbContext.Set <ResCurrentType>().SingleOrDefault(predicate); return(ResourceEntity); }
public CommonResourceRepository(IPyroDbContext Context, IPrimaryServiceRootCache IPrimaryServiceRootCache, IIndexSetterFactory <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> IIndexSetterFactory, IServiceSearchParameterCache IServiceSearchParameterCache, IFhirReleaseCache IFhirReleaseCache, IDatabaseOperationOutcomeFactory IDatabaseOperationOutcomeFactory, IPagingSupport IPagingSupport) : base(Context, IPrimaryServiceRootCache) { this.IIndexSetterFactory = IIndexSetterFactory; this.IServiceSearchParameterCache = IServiceSearchParameterCache; this.IFhirReleaseCache = IFhirReleaseCache; this.IDatabaseOperationOutcomeFactory = IDatabaseOperationOutcomeFactory; this.IPagingSupport = IPagingSupport; }
public ResCurrentType DbQueryEntityWithInclude(Expression <Func <ResCurrentType, bool> > predicate, List <Expression <Func <ResCurrentType, object> > > IncludeList) { ResCurrentType ResourceEntity = null; IQueryable <ResCurrentType> query = IPyroDbContext.Set <ResCurrentType>(); //Apply includes foreach (Expression <Func <ResCurrentType, object> > include in IncludeList) { query = query.Include <ResCurrentType, object>(include); } ResourceEntity = query.SingleOrDefault(predicate); return(ResourceEntity); }
/// <summary> /// Gets the ServiceBaseUrl Instance if found or creates a new instance if not found /// </summary> /// <param name="UrlString"></param> /// <returns></returns> public IDtoRootUrlStore GetAndOrAddService_RootUrlStore(string ServiceRootUrl) { IDtoRootUrlStore Pyro_RootUrlStore = this.GetPyro_RootUrlStore(ServiceRootUrl); if (Pyro_RootUrlStore == null) { var Pyro_RootUrlStoreDb = new _ServiceBaseUrl(); Pyro_RootUrlStoreDb.IsServersPrimaryUrlRoot = false; Pyro_RootUrlStoreDb.Url = StringSupport.ToLowerFast(ServiceRootUrl.StripHttp()); Pyro_RootUrlStoreDb = IPyroDbContext.Set <_ServiceBaseUrl>().Add(Pyro_RootUrlStoreDb); this.Save(); return(Pyro_RootUrlStoreDb); } else { return(Pyro_RootUrlStore); } }
public DtoServiceConfigration UpdateServiceConfigration(DtoServiceConfigration DtoServiceConfigration) { var DateTimeNow = System.DateTimeOffset.Now; _ServiceConfiguration DbServiceConfigration = IPyroDbContext.ServiceConfiguration.SingleOrDefault(x => x.Parameter == DtoServiceConfigration.Parameter); if (DbServiceConfigration != null) { DbServiceConfigration.Value = DtoServiceConfigration.Value; DbServiceConfigration.LastUpdated = DateTimeNow; DbServiceConfigration.LastUpdatedUser = DtoServiceConfigration.LastUpdatedUser; } else { DbServiceConfigration = IMapper.Map <_ServiceConfiguration>(DtoServiceConfigration); DbServiceConfigration.LastUpdated = DateTimeNow; DbServiceConfigration.CreatedDate = DateTimeNow; DbServiceConfigration = IPyroDbContext.Set <_ServiceConfiguration>().Add(DbServiceConfigration); } this.Save(); return(IMapper.Map <DtoServiceConfigration>(DbServiceConfigration)); }
protected DtoResource DbGetNoXML <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>(Expression <Func <ResCurrentType, bool> > predicate) where ResCurrentType : ResourceCurrentBase <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexStringType : ResourceIndexString <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexTokenType : ResourceIndexToken <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexUriType : ResourceIndexUri <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>, new() where ResIndexReferenceType : ResourceIndexReference <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexQuantityType : ResourceIndexQuantity <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexDateTimeType : ResourceIndexDateTime <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> { return(IPyroDbContext.Set <ResCurrentType>().Where(predicate).Select(x => new DtoResource { Id = x.Id, IsCurrent = x.IsCurrent, FhirId = x.FhirId, IsDeleted = x.IsDeleted, Version = x.VersionId, Received = x.LastUpdated, Method = x.Method, }).FirstOrDefault()); }
private _ServiceSearchParameter UpdateServiceSearchParameters(int Id, _ServiceSearchParameter SearchParameter) { var DbSearchParameter = IPyroDbContext.ServiceSearchParameter.SingleOrDefault(x => x.Id == Id); DbSearchParameter.Description = SearchParameter.Description; DbSearchParameter.Expression = SearchParameter.Expression; DbSearchParameter.IsIndexed = SearchParameter.IsIndexed; DbSearchParameter.LastUpdated = DateTimeOffset.Now; DbSearchParameter.Name = SearchParameter.Name; DbSearchParameter.Resource = SearchParameter.Resource; DbSearchParameter.SearchParameterResourceId = SearchParameter.SearchParameterResourceId; DbSearchParameter.SearchParameterResourceVersion = SearchParameter.SearchParameterResourceVersion; DbSearchParameter.Status = SearchParameter.Status; DbSearchParameter.TargetResourceTypeList = SearchParameter.TargetResourceTypeList; DbSearchParameter.Type = SearchParameter.Type; DbSearchParameter.Url = SearchParameter.Url; DbSearchParameter.XPath = SearchParameter.XPath; IPyroDbContext.Entry(DbSearchParameter).State = EntityState.Modified; this.Save(); return(DbSearchParameter); }
private _ServiceSearchParameter UpdateServiceSearchParameters(int Id, _ServiceSearchParameter SearchParameter) { var DbSearchParameter = IPyroDbContext.ServiceSearchParameter .Include(x => x.TargetResourceTypeList) .Include(x => x.ServiceSearchParameterCompositePivotList) .SingleOrDefault(x => x.Id == Id); //We must tell EF to delete each child element not just assign the new list. //We could try and work out the difference between the two lists and only Add, Update and Remove as required //Yet given this is a very infrequent process with very small numbers it is just easier to delete all // and add the entire new list. for (int i = DbSearchParameter.TargetResourceTypeList.Count - 1; i >= 0; i--) { (IPyroDbContext as IObjectContextAdapter).ObjectContext.DeleteObject(DbSearchParameter.TargetResourceTypeList.ElementAt(i)); } for (int i = DbSearchParameter.ServiceSearchParameterCompositePivotList.Count - 1; i >= 0; i--) { (IPyroDbContext as IObjectContextAdapter).ObjectContext.DeleteObject(DbSearchParameter.ServiceSearchParameterCompositePivotList.ElementAt(i)); } DbSearchParameter.Description = SearchParameter.Description; DbSearchParameter.Expression = SearchParameter.Expression; DbSearchParameter.IsIndexed = SearchParameter.IsIndexed; DbSearchParameter.LastUpdated = DateTimeOffset.Now; DbSearchParameter.Name = SearchParameter.Name; DbSearchParameter.Resource = SearchParameter.Resource; DbSearchParameter.SearchParameterResourceId = SearchParameter.SearchParameterResourceId; DbSearchParameter.SearchParameterResourceVersion = SearchParameter.SearchParameterResourceVersion; DbSearchParameter.Status = SearchParameter.Status; DbSearchParameter.TargetResourceTypeList = SearchParameter.TargetResourceTypeList; DbSearchParameter.ServiceSearchParameterCompositePivotList = SearchParameter.ServiceSearchParameterCompositePivotList; DbSearchParameter.Type = SearchParameter.Type; DbSearchParameter.Url = SearchParameter.Url; DbSearchParameter.XPath = SearchParameter.XPath; IPyroDbContext.Entry(DbSearchParameter).State = EntityState.Modified; this.Save(); return(DbSearchParameter); }
protected ResCurrentType DbQueryEntityWithInclude <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>(Expression <Func <ResCurrentType, bool> > predicate, List <Expression <Func <ResCurrentType, object> > > IncludeList) where ResCurrentType : ResourceCurrentBase <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexStringType : ResourceIndexString <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexTokenType : ResourceIndexToken <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexUriType : ResourceIndexUri <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType>, new() where ResIndexReferenceType : ResourceIndexReference <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexQuantityType : ResourceIndexQuantity <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> where ResIndexDateTimeType : ResourceIndexDateTime <ResCurrentType, ResIndexStringType, ResIndexTokenType, ResIndexUriType, ResIndexReferenceType, ResIndexQuantityType, ResIndexDateTimeType> { ResCurrentType ResourceEntity = null; IQueryable <ResCurrentType> query = IPyroDbContext.Set <ResCurrentType>(); //Apply includes foreach (Expression <Func <ResCurrentType, object> > include in IncludeList) { query = query.Include <ResCurrentType, object>(include); } ResourceEntity = query.SingleOrDefault(predicate); return(ResourceEntity); }
public int DeleteNonCurrentResourceIndexes() { int RowsRemovedCount = 0; var StringIndexList = IPyroDbContext.Set <ResIndexStringType>() .Where(w => w.Resource.IsCurrent == false); RowsRemovedCount = RowsRemovedCount + DeleteIndex(StringIndexList, RowsRemovedCount); var TokenIndexList = IPyroDbContext.Set <ResIndexTokenType>() .Where(w => w.Resource.IsCurrent == false); RowsRemovedCount = RowsRemovedCount + DeleteIndex(TokenIndexList, RowsRemovedCount); var UriIndexList = IPyroDbContext.Set <ResIndexUriType>() .Where(w => w.Resource.IsCurrent == false); RowsRemovedCount = RowsRemovedCount + DeleteIndex(UriIndexList, RowsRemovedCount); var ReferenceIndexList = IPyroDbContext.Set <ResIndexReferenceType>() .Where(w => w.Resource.IsCurrent == false); RowsRemovedCount = RowsRemovedCount + DeleteIndex(ReferenceIndexList, RowsRemovedCount); var QuantityIndexList = IPyroDbContext.Set <ResIndexQuantityType>() .Where(w => w.Resource.IsCurrent == false); RowsRemovedCount = RowsRemovedCount + DeleteIndex(QuantityIndexList, RowsRemovedCount); var DateTimeIndexList = IPyroDbContext.Set <ResIndexDateTimeType>() .Where(w => w.Resource.IsCurrent == false); RowsRemovedCount = RowsRemovedCount + DeleteIndex(DateTimeIndexList, RowsRemovedCount); this.Save(); return(RowsRemovedCount); }
public CommonRepository(IPyroDbContext IPyroDbContext, IPrimaryServiceRootCache IPrimaryServiceRootCache) : base(IPyroDbContext) { this.IPrimaryServiceRootCache = IPrimaryServiceRootCache; }
public FhirReleaseRepository(IPyroDbContext IPyroDbContext, IMapper IMapper) : base(IPyroDbContext) { this.IMapper = IMapper; }
public ServiceConfigurationRepository(IPyroDbContext IPyroDbContext, IMapper IMapper) : base(IPyroDbContext) { this.IMapper = IMapper; }
public ServiceCompartmentRepository(IPyroDbContext IPyroDbContext, IMapper IMapper) : base(IPyroDbContext) { this.IMapper = IMapper; }
public ServiceBaseUrlRepository(IPyroDbContext IPyroDbContext, IDtoRootUrlStoreFactory IDtoRootUrlStoreFactory) : base(IPyroDbContext) { this.IDtoRootUrlStoreFactory = IDtoRootUrlStoreFactory; }
private _ServiceSearchParameter AddServiceSearchParameters(_ServiceSearchParameter ServiceSearchParameter) { ServiceSearchParameter = IPyroDbContext.Set <_ServiceSearchParameter>().Add(ServiceSearchParameter); this.Save(); return(ServiceSearchParameter); }
public ServiceSearchParameterRepository(IPyroDbContext IPyroDbContext) : base(IPyroDbContext) { }
public BaseRepository(IPyroDbContext IPyroDbContext) { this.IPyroDbContext = IPyroDbContext; }