make module creator templates extensible

This commit is contained in:
Shaun Walker
2021-03-30 10:06:25 -04:00
parent d8bcc32239
commit 62362b9194
25 changed files with 67 additions and 698 deletions

View File

@ -13,5 +13,6 @@ namespace Oqtane.Services
Task InstallModuleDefinitionsAsync();
Task DeleteModuleDefinitionAsync(int moduleDefinitionId, int siteId);
Task<ModuleDefinition> CreateModuleDefinitionAsync(ModuleDefinition moduleDefinition);
Task<List<string>> GetModuleDefinitionTemplatesAsync();
}
}

View File

@ -53,5 +53,11 @@ namespace Oqtane.Services
{
return await PostJsonAsync($"{Apiurl}", moduleDefinition);
}
public async Task<List<string>> GetModuleDefinitionTemplatesAsync()
{
List<string> templates = await GetJsonAsync<List<string>>($"{Apiurl}/templates");
return templates;
}
}
}