Добавил поддержку документации плагинов
This commit is contained in:
@@ -109,6 +109,14 @@ builder.Services.AddSwaggerGen(options =>
|
||||
var pluginXmlPath = Path.Combine(AppContext.BaseDirectory, pluginXmlFile);
|
||||
options.IncludeXmlComments(pluginXmlPath);
|
||||
|
||||
// Добавление документации плагинов
|
||||
foreach (var p in loadedPlugins)
|
||||
{
|
||||
var pluginXmlFullPath = p.Assembly.Location.Replace("dll", "xml");
|
||||
if (File.Exists(pluginXmlFullPath))
|
||||
options.IncludeXmlComments(pluginXmlFullPath);
|
||||
}
|
||||
|
||||
// Добавляем только схему авторизации по ApiKey
|
||||
options.AddSecurityDefinition(ApiKeyAuthenticationDefaults.Scheme, new Microsoft.OpenApi.Models.OpenApiSecurityScheme
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user