|
|
@ -18,17 +18,22 @@ public abstract class SettingManagementProvider : ISettingManagementProvider
|
|
|
|
SettingManagementStore = settingManagementStore;
|
|
|
|
SettingManagementStore = settingManagementStore;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public virtual async Task<string?> GetOrNullAsync(SettingDefinition setting, string providerKey)
|
|
|
|
public virtual async Task<string?> GetOrNullAsync(SettingDefinition setting, string? providerKey)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
return await SettingManagementStore.GetOrNullAsync(setting.Name, Name, NormalizeProviderKey(providerKey));
|
|
|
|
return await SettingManagementStore.GetOrNullAsync(setting.Name, Name, NormalizeProviderKey(providerKey));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public virtual async Task SetAsync(SettingDefinition setting, string value, string providerKey)
|
|
|
|
public virtual async Task<List<SettingValue>> GetByPrefixAsync(string prefix, string? providerKey)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await SettingManagementStore.GetListByPrefixAsync(prefix, Name, NormalizeProviderKey(providerKey));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public virtual async Task SetAsync(SettingDefinition setting, string value, string? providerKey)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
await SettingManagementStore.SetAsync(setting.Name, value, Name, NormalizeProviderKey(providerKey));
|
|
|
|
await SettingManagementStore.SetAsync(setting.Name, value, Name, NormalizeProviderKey(providerKey));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public virtual async Task ClearAsync(SettingDefinition setting, string providerKey)
|
|
|
|
public virtual async Task ClearAsync(SettingDefinition setting, string? providerKey)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
await SettingManagementStore.DeleteAsync(setting.Name, Name, NormalizeProviderKey(providerKey));
|
|
|
|
await SettingManagementStore.DeleteAsync(setting.Name, Name, NormalizeProviderKey(providerKey));
|
|
|
|
}
|
|
|
|
}
|
|
|
|