PIbd-23. Ivanov V.N. Lab Work 07 hard #15

Closed
Vyacheslav wants to merge 23 commits from LabWork7_Hard into LabWork6_Hard
Showing only changes of commit 29cf1a3dae - Show all commits

View File

@ -143,5 +143,15 @@ namespace PizzeriaClientApp.Controllers
var piz = APIClient.GetRequest<PizzaViewModel>($"api/main/getpizza?pizzaId={pizza}");
return count * (piz?.Price ?? 1);
}
[HttpGet]
public IActionResult Mails()
{
if (APIClient.Client == null)
{
return Redirect("~/Home/Enter");
}
return View(APIClient.GetRequest<List<MessageInfoViewModel>>($"api/client/getmessages?clientId={APIClient.Client.Id}"));
}
}
}