POS: Set ViewType via optional URL parameter

Falls back to the DefaultView defined in the POS settings.

POS: Fix POST-Route
This commit is contained in:
Dennis Reimann
2020-05-26 17:38:30 +02:00
parent fad53a9fa2
commit b7ec22ee89
6 changed files with 23 additions and 16 deletions

View File

@@ -69,7 +69,7 @@ namespace BTCPayServer.Controllers
var controller = (AppsPublicController)serviceProvider.GetService(typeof(AppsPublicController));
controller.Url = Url;
controller.ControllerContext = ControllerContext;
var res = await controller.ViewPointOfSale(appId) as ViewResult;
var res = await controller.ViewPointOfSale(appId, PosViewType.Unspecified) as ViewResult;
if (res != null)
{
res.ViewName = "/Views/AppsPublic/ViewPointOfSale.cshtml";