You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
527 B
21 lines
527 B
2 years ago
|
using Cis.Core;
|
||
|
using Microsoft.Extensions.DependencyInjection;
|
||
|
|
||
|
namespace Cis.Web.Core;
|
||
|
|
||
|
public static class ProjectOptions
|
||
|
{
|
||
|
/// <summary>
|
||
|
/// 注册项目配置选项
|
||
|
/// </summary>
|
||
|
/// <param name="services"></param>
|
||
|
/// <returns></returns>
|
||
|
public static IServiceCollection AddProjectOptions(this IServiceCollection services)
|
||
|
{
|
||
|
services.AddConfigurableOptions<DbConnectionOptions>();
|
||
|
services.AddConfigurableOptions<CacheOptions>();
|
||
|
services.AddConfigurableOptions<SnowIdOptions>();
|
||
|
|
||
|
return services;
|
||
|
}
|
||
|
}
|