появилось изделие в заказах
This commit is contained in:
parent
a394b7a123
commit
b95ad316df
@ -2,6 +2,7 @@
|
||||
using PlumbingRepairClientApp.Models;
|
||||
using PlumbingRepairContracts.BindingModels;
|
||||
using PlumbingRepairContracts.ViewModels;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace PlumbingRepairClientApp.Controllers
|
||||
@ -116,10 +117,12 @@ namespace PlumbingRepairClientApp.Controllers
|
||||
{
|
||||
throw new Exception("Количество и сумма должны быть больше 0");
|
||||
}
|
||||
var works = APIClient.GetRequest<List<WorkViewModel>>("api/main/getworklist");
|
||||
APIClient.PostRequest("api/main/createorder", new OrderBindingModel
|
||||
{
|
||||
ClientId = APIClient.Client.Id,
|
||||
WorkId = work,
|
||||
WorkName = (works.FirstOrDefault(x => x.Id == work)).WorkName,
|
||||
Count = count,
|
||||
Sum = Calc(count, work)
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user