예제 #1
0
 private void LoadSaleItems()
 {
     total = 0;
     dgvSaleItems.DataSource = subProductForTransactionController.GetFor(sale);
     UpdateSubTotals();
     sale.Total = total;
     saleController.SaveOrUpdate(sale);
     txtQuoteTotal.Text = total.ToString("$#,##0.00");
 }
예제 #2
0
 private void LoadQuoteItems()
 {
     total = 0;
     quote.SubProductsForTransactions = subProductForTransactionController.GetFor(quote);
     dgvQuoteItems.DataSource         = quote.SubProductsForTransactions;
     UpdateSubTotals();
     quote.Total = total;
     quoteController.SaveOrUpdate(quote);
     txtQuoteTotal.Text = total.ToString("$#,##0.00");
     if (quote.SubProductsForTransactions.Count > 0)
     {
         btnSell.Enabled        = true;
         btnSaveAndSend.Enabled = !string.IsNullOrEmpty(selectedCustomer.Email);
     }
     else
     {
         btnSell.Enabled        = false;
         btnSaveAndSend.Enabled = false;
     }
 }