Class ModuleDefinitionController
- Namespace
- Oqtane.Controllers
- Assembly
- Oqtane.Server.dll
[Route("api/[controller]")]
public class ModuleDefinitionController : Controller
- Inheritance
-
object
ControllerBase
Controller
ModuleDefinitionController
Constructors
ModuleDefinitionController(IModuleDefinitionRepository, ITenantRepository, ISqlRepository, IUserPermissions, IInstallationManager, IWebHostEnvironment, IServiceProvider, ITenantManager, ISyncManager, ILogManager)
public ModuleDefinitionController(IModuleDefinitionRepository moduleDefinitions, ITenantRepository tenants, ISqlRepository sql, IUserPermissions userPermissions, IInstallationManager installationManager, IWebHostEnvironment environment, IServiceProvider serviceProvider, ITenantManager tenantManager, ISyncManager syncManager, ILogManager logger)
Parameters
moduleDefinitions
IModuleDefinitionRepository
tenants
ITenantRepository
sql
ISqlRepository
userPermissions
IUserPermissions
installationManager
IInstallationManager
environment
IWebHostEnvironment
serviceProvider
IServiceProvider
tenantManager
ITenantManager
syncManager
ISyncManager
logger
ILogManager
Methods
Delete(int, int)
[HttpDelete("{id}")]
[Authorize(Roles = "Host Users")]
public void Delete(int id, int siteid)
Parameters
id
int
siteid
int
Get(int, string)
[HttpGet("{id}")]
public ModuleDefinition Get(int id, string siteid)
Parameters
id
int
siteid
string
Returns
- ModuleDefinition
Get(string)
[HttpGet]
public IEnumerable<ModuleDefinition> Get(string siteid)
Parameters
siteid
string
Returns
- IEnumerable<ModuleDefinition>
GetTemplates()
[HttpGet("templates")]
[Authorize(Roles = "Host Users")]
public List<Template> GetTemplates()
Returns
- List<Template>
Post(ModuleDefinition)
[HttpPost]
[Authorize(Roles = "Host Users")]
public ModuleDefinition Post(ModuleDefinition moduleDefinition)
Parameters
moduleDefinition
ModuleDefinition
Returns
- ModuleDefinition
Put(int, ModuleDefinition)
[HttpPut("{id}")]
[Authorize(Roles = "Administrators")]
public void Put(int id, ModuleDefinition moduleDefinition)
Parameters
id
int
moduleDefinition
ModuleDefinition