added a Setting Management UI
This commit is contained in:
@ -240,6 +240,19 @@ namespace Oqtane.Services
|
||||
/// <returns></returns>
|
||||
Task DeleteSettingAsync(string entityName, int settingId);
|
||||
|
||||
/// <summary>
|
||||
/// Gets list of unique entity names
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
Task<List<string>> GetEntityNamesAsync();
|
||||
|
||||
/// <summary>
|
||||
/// Gets a list of unique entity IDs for the given entity name
|
||||
/// </summary>
|
||||
/// <param name="entityName"></param>
|
||||
/// <returns></returns>
|
||||
Task<List<int>> GetEntityIdsAsync(string entityName);
|
||||
|
||||
/// <summary>
|
||||
/// Gets the value of the given settingName (key) from the given key-value dictionary
|
||||
/// </summary>
|
||||
@ -494,6 +507,15 @@ namespace Oqtane.Services
|
||||
await DeleteAsync($"{Apiurl}/{settingId}/{entityName}");
|
||||
}
|
||||
|
||||
public async Task<List<string>> GetEntityNamesAsync()
|
||||
{
|
||||
return await GetJsonAsync<List<string>>($"{Apiurl}/entitynames");
|
||||
}
|
||||
|
||||
public async Task<List<int>> GetEntityIdsAsync(string entityName)
|
||||
{
|
||||
return await GetJsonAsync<List<int>>($"{Apiurl}/entityids?entityname={entityName}");
|
||||
}
|
||||
|
||||
public string GetSetting(Dictionary<string, string> settings, string settingName, string defaultValue)
|
||||
{
|
||||
|
Reference in New Issue
Block a user