mirror of https://github.com/abpframework/abp.git
8 changed files with 57 additions and 27 deletions
@ -1,22 +1,22 @@ |
|||
using System.Collections.Generic; |
|||
using System.Threading.Tasks; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using Microsoft.AspNetCore.Mvc.RazorPages; |
|||
using Microsoft.Extensions.Options; |
|||
using Volo.Docs; |
|||
using Volo.Docs.Projects; |
|||
|
|||
namespace VoloDocs.Web.Pages |
|||
{ |
|||
public class IndexModel : PageModel |
|||
{ |
|||
private readonly DocsUrlOptions _urlOptions; |
|||
|
|||
public IndexModel() |
|||
public IndexModel(IOptions<DocsUrlOptions> urlOptions) |
|||
{ |
|||
|
|||
_urlOptions = urlOptions.Value; |
|||
} |
|||
|
|||
public IActionResult OnGet() |
|||
{ |
|||
//TODO: Create HomeController & Index instead of Page. Otherwise, we have an empty Index.cshtml file.
|
|||
return Redirect("./documents"); |
|||
} |
|||
} |
|||
|
|||
@ -0,0 +1,10 @@ |
|||
namespace Volo.Docs |
|||
{ |
|||
public class DocsUrlOptions |
|||
{ |
|||
/// <summary>
|
|||
/// Default value: "documents";
|
|||
/// </summary>
|
|||
public string RoutePrefix { get; set; } = "documents"; |
|||
} |
|||
} |
|||
Loading…
Reference in new issue