Exemplo n.º 1
0
 private OrderHistroy FirstOrderHistory()
 {
     var invoice = new FakeClient1Invoices().FirstInvoice();
     Debug.Assert(invoice.OrderId != null, "invoice.OrderId != null");
     var orderHistory = new OrderHistroy
     {
         OrderHistoryId = 1,
         OrderId = (int) invoice.OrderId,
         ClientId = invoice.ClientId,
         CookerId = invoice.ClientId,
         OrderTypeValue = invoice.OrderTypeValue,
         PaymentMethodValue = invoice.PaymentMethodValue,
         PromotionTitle = invoice.PromotionTitle,
         PromotionPrice = invoice.PromotionPrice,
         PromotionCurrencyId = invoice.PromotionCurrencyId,
         CouponTitle = invoice.CouponTitle,
         CouponPrice = invoice.CouponPrice,
         CouponCurrencyId = invoice.CouponCurrencyId,
         PlanTitle = invoice.PlanTitle,
         SalesTax = invoice.SalesTax,
         DeliveryFees = invoice.DeliveryFees,
         SubTotal = invoice.SubTotal,
         Total = invoice.Total,
         CurrencyId = invoice.CurrencyId,
         OrderStatusId = (int)OrderStatus.Values.History
     };
     return orderHistory;
 }
Exemplo n.º 2
0
        public void InitializeInvoiceList()
        {
            MyInvoices = new List<Invoice>();
            var client1Invoices = new FakeClient1Invoices().MyInvoices;
            foreach (var invoice in client1Invoices)
            {
                MyInvoices.Add(invoice);
            }

            //var cooker1Invoices = new FakeCooker1Invoices().MyInvoices;
            //foreach (var invoice in cooker1Invoices)
            //{
            //    MyInvoices.Add(invoice);
            //}
        }
Exemplo n.º 3
0
 public void InitializeInvoicesList()
 {
     MyInvoices = new List<Invoice>();
     var client1Invoices = new FakeClient1Invoices().MyInvoices;
     foreach (var invoice in client1Invoices)
     {
         MyInvoices.Add(invoice);
     }
     var client2Invoices = new FakeClient2Invoices().MyInvoices;
     foreach (var invoice in client2Invoices)
     {
         MyInvoices.Add(invoice);
     }
     var client3Invoices = new FakeClient3Invoices().MyInvoices;
     foreach (var invoice in client3Invoices)
     {
         MyInvoices.Add(invoice);
     }
 }
Exemplo n.º 4
0
        public Payment FirstClient1Payment()
        {
            var FirstInvoice = new FakeClient1Invoices().FirstInvoice();
            if (FirstInvoice.OrderId != null)
            {
                var Payment = new Payment
                {
                    PaymentId = 1,
                    InvoiceId = FirstInvoice.InvoiceId,
                    PaymentDate = DateTime.Now.Date,
                    PaymentAmount = FirstInvoice.Total,
                    OrderId = (int) FirstInvoice.OrderId,
                    ClientId = FirstInvoice.ClientId,
                    CookerId = FirstInvoice.CookerId,
                    TransactionId = "G126F85",
                    OrderModelTypeId = (int)LookUp.OrderModel.OrderModelType.Values.Transaction,
                    PaymentStatusId = (int)PaymentStatusType.Values.Pending

                };

                return Payment;
            }
            return null;
        }