public IBOOrders BOOrders(IOrdersRepository repo) { BOOrders boOrders = (BOOrders)BOOrders(); boOrders.Repository = repo; return(boOrders); }
public IBOOrders BOOrders() { var boOrders = new BOOrders() { İd = this.İd, Employeeİd = this.Employeeİd, Customerİd = this.Customerİd, OrderDate = this.OrderDate, ShippedDate = this.ShippedDate, Shipperİd = this.Shipperİd, ShipName = this.ShipName, ShipAddress = this.ShipAddress, ShipCity = this.ShipCity, ShipStateProvince = this.ShipStateProvince, ShipZipPostalCode = this.ShipZipPostalCode, ShipCountryRegion = this.ShipCountryRegion, ShippingFee = this.ShippingFee, Taxes = this.Taxes, PaymentType = this.PaymentType, PaidDate = this.PaidDate, Notes = this.Notes, TaxRate = this.TaxRate, TaxStatusİd = this.TaxStatusİd, Statusİd = this.Statusİd }; return(boOrders); }
public async Task <IHttpActionResult> DeleteOrders(string id) { var result = Task.Factory.StartNew(() => { IUnitOfWork uow = new UnitOfWorkImp(new IRepositoryConnection[] { OrdersRepository }); var bo = new BOOrders(); bo.Repository = OrdersRepository; bo.Init(id); uow.Delete(bo); string err; if (!uow.Commit(out err)) { var resp = new HttpResponseMessage(HttpStatusCode.BadRequest) { Content = new StringContent(err) }; throw new HttpResponseException(resp); } return(true); }); await result; if (!result.Result) { return(NotFound()); } return(Ok(result.Result)); }
public IBOOrders BOOrders() { var boOrders = new BOOrders() { OrderID = this.OrderID, CustomerID = this.CustomerID, EmployeeID = this.EmployeeID, OrderDate = this.OrderDate, RequiredDate = this.RequiredDate, ShippedDate = this.ShippedDate, ShipVia = this.ShipVia, Freight = this.Freight, ShipName = this.ShipName, ShipAddress = this.ShipAddress, ShipCity = this.ShipCity, ShipRegion = this.ShipRegion, ShipPostalCode = this.ShipPostalCode, ShipCountry = this.ShipCountry }; return(boOrders); }