Implement xCategory Service Registration ...
This commit is contained in:
@@ -3,8 +3,7 @@ using System.Linq;
|
||||
using Microsoft.AspNetCore.Builder;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using xCategoryService.Interfaces;
|
||||
using xCategoryService.Providers;
|
||||
using xCategoryService.DI;
|
||||
using xCommons.Extensions;
|
||||
using xDataService.DI;
|
||||
using xDataService.Models;
|
||||
@@ -208,6 +207,11 @@ namespace xServices.DI
|
||||
app.UseXFileService(
|
||||
isDevelopmentEnvironment: isDevelopmentEnvironment
|
||||
);
|
||||
//
|
||||
// Using Category Service ...
|
||||
app.UseXCategoryService(
|
||||
isDevelopmentEnvironment: isDevelopmentEnvironment
|
||||
);
|
||||
}
|
||||
|
||||
//
|
||||
@@ -295,11 +299,14 @@ namespace xServices.DI
|
||||
services.AddScoped<IXTestRepositoryProvider, XTestRepositoryProvider>();
|
||||
#endregion
|
||||
|
||||
//
|
||||
var repositoryType = xDataService.Constants.XRepositoryType.EF;
|
||||
|
||||
//
|
||||
// Register String Service ...
|
||||
services.AddXStringService<XApiDbContext>(
|
||||
lifeTime: lifeTime,
|
||||
repositoryType: xDataService.Constants.XRepositoryType.EF
|
||||
repositoryType: repositoryType
|
||||
);
|
||||
|
||||
//
|
||||
@@ -313,19 +320,22 @@ namespace xServices.DI
|
||||
// Register Tag Service ...
|
||||
services.AddXTagService<XApiDbContext>(
|
||||
lifeTime: lifeTime,
|
||||
repositoryType: xDataService.Constants.XRepositoryType.EF
|
||||
repositoryType: repositoryType
|
||||
);
|
||||
|
||||
//
|
||||
// Register File Service ...
|
||||
services.AddXFileService<XApiDbContext>(
|
||||
lifeTime: lifeTime,
|
||||
repositoryType: xDataService.Constants.XRepositoryType.EF
|
||||
repositoryType: repositoryType
|
||||
);
|
||||
|
||||
//
|
||||
// TODO: Remove this ...
|
||||
services.AddScoped<IXSubCategoryTitleResourceProvider, XSubCategoryTitleResourceProvider>();
|
||||
// Register Category Service ...
|
||||
services.AddXCategoryService<XApiDbContext>(
|
||||
lifeTime: lifeTime,
|
||||
repositoryType: repositoryType
|
||||
);
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user