Initial commit
This commit is contained in:
25
Oqtane.Server/Controllers/ModuleDefinitionController.cs
Normal file
25
Oqtane.Server/Controllers/ModuleDefinitionController.cs
Normal file
@ -0,0 +1,25 @@
|
||||
using System.Collections.Generic;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Oqtane.Repository;
|
||||
using Oqtane.Models;
|
||||
|
||||
namespace Oqtane.Controllers
|
||||
{
|
||||
[Route("{site}/api/[controller]")]
|
||||
public class ModuleDefinitionController : Controller
|
||||
{
|
||||
private readonly IModuleDefinitionRepository moduledefinitions;
|
||||
|
||||
public ModuleDefinitionController(IModuleDefinitionRepository ModuleDefinitions)
|
||||
{
|
||||
moduledefinitions = ModuleDefinitions;
|
||||
}
|
||||
|
||||
// GET: api/<controller>
|
||||
[HttpGet]
|
||||
public IEnumerable<ModuleDefinition> Get()
|
||||
{
|
||||
return moduledefinitions.GetModuleDefinitions();
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user