Files
mixtape/zero.Backoffice/Controllers/ZeroSetupController.cs
T

49 lines
1.1 KiB
C#
Raw Normal View History

2021-11-27 16:33:05 +01:00
//using Microsoft.AspNetCore.Hosting;
//using Microsoft.AspNetCore.Mvc;
//using zero.Setup;
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
//namespace zero.Backoffice.Endpoints;
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
//[ZeroAuthorize(false)]
//public class ZeroSetupController : Controller
//{
// ISetupApi Api;
// IWebHostEnvironment Env;
// IZeroOptions Options;
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
// public ZeroSetupController(ISetupApi api, IWebHostEnvironment env, IZeroOptions options)
// {
// Api = api;
// Env = env;
// Options = options;
// }
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
// public IActionResult Index()
// {
// //if (!Options.ZeroVersion.IsNullOrEmpty())
// //{
// // return Redirect(Options.BackofficePath);
// //}
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
// return View("/Views/Zero/Setup.cshtml");
// }
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
// [HttpPost]
// public async Task<IActionResult> Install([FromBody] SetupModel model)
// {
// model.ContentRootPath = Env.ContentRootPath;
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
// Result<SetupModel> result = await Api.Install(model);
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
// if (result.IsSuccess)
// {
// return Json(result);
// }
2021-11-23 15:43:21 +01:00
2021-11-27 16:33:05 +01:00
// object value = String.Join("\n\n", result.Errors.Select(error => error.Message + "\n(property: " + error.Property + ")"));
// return StatusCode(500, value);
// }
//}