public ActionResult Create([Bind(Include = "BillReceiptID,Type,BillReceiptNo,CompanyName,IsPrint,DateCreate,DateUpdate,CreateBy,UpdateBy")] Billing billing) { if (ModelState.IsValid) { BillReceipt billreceipt = new BillReceipt(); billreceipt.Type = billing.Type; billreceipt.CompanyName = billing.CompanyName; billreceipt.IsPrint = billing.IsPrint; billreceipt.DateCreate = billing.DateCreate; billreceipt.DateUpdate = billing.DateUpdate; if (billing.Type == "Repair") { billreceipt.BillReceiptNo = "R" + billing.BillReceiptNo; } else if (billing.Type == "Sale") { billreceipt.BillReceiptNo = "S" + billing.BillReceiptNo; } else if (billing.Type == "Destroy") { billreceipt.BillReceiptNo = "D" + billing.BillReceiptNo; } //billreceipt.BillReceiptNo = billing.BillReceiptNo; billreceipt.CreateBy = billing.CreateBy; billreceipt.UpdateBy = billing.UpdateBy; db.BillReceipts.Add(billreceipt); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(billing)); }
public void insert_billing(Billing cd) { SqlConnection C = new SqlConnection(ConnectionString); var insertBill = new SqlCommand("INSERT INTO [dbo].[Billing] ([Bill_ID], [Clientid], [Current_Bill], [Previous_Due], [InvoicePeriod], [Paid] ) VALUES ( @Bill_ID, @Clientid, @Current_Bill, @Previous_Due, @InvoicePeriod, @Paid)", C); SqlParameter p1 = new SqlParameter("@Bill_ID", SqlDbType.VarChar, 50); p1.Value = cd.Bill_ID; SqlParameter p2 = new SqlParameter("@Clientid", SqlDbType.VarChar, 50); p2.Value = cd.ClientId; SqlParameter p3 = new SqlParameter("@Current_Bill", SqlDbType.SmallMoney); p3.Value = cd.Current_Bill; SqlParameter p4 = new SqlParameter("@Previous_Due", SqlDbType.SmallMoney); p4.Value = cd.Previous_Due; SqlParameter p5 = new SqlParameter("@InvoicePeriod", SqlDbType.DateTime, 50); p5.Value = cd.InvoicePeriod; SqlParameter p6 = new SqlParameter("@Paid", SqlDbType.VarChar); p6.Value = cd.paid; insertBill.Parameters.Add(p1); insertBill.Parameters.Add(p2); insertBill.Parameters.Add(p3); insertBill.Parameters.Add(p4); insertBill.Parameters.Add(p5); insertBill.Parameters.Add(p6); C.Open(); insertBill.ExecuteNonQuery(); C.Close(); }
public static Billing GetBilling(int id) { Billing billing = new Billing(); using (MySqlConnection conn = new MySqlConnection(ConnectionString.Build())) { conn.Open(); using (MySqlCommand cmd = new MySqlCommand()) { cmd.Connection = conn; cmd.CommandText = @"SELECT * FROM billings as bi INNER JOIN balances as b ON balance = b.balance_id INNER JOIN residents_addresses as ra ON bi.address = ra.address WHERE resident = @resident"; cmd.Parameters.AddWithValue("@resident", id); using (MySqlDataReader reader = cmd.ExecuteReader()) { while (reader.Read()) { billing.Payed = (double)reader["payed"]; billing.Remain = (double)reader["remain"]; billing.TotalBilling = (double)reader["total_billing"]; } } return(billing); } } }
/// <summary> /// Method returns string value of all values of Billing object /// </summary> /// <param name="oBilling">Billing object to create string from</param> /// <returns>string value containing all Billing object values</returns> public static string BillingToString(this Billing oBilling) { if (oBilling == null) { return(""); } var items = new Dictionary <string, string>() { { "CustomerID", oBilling.CustomerID }, { "Name", oBilling.Name }, { "Company", oBilling.Company }, { "Adress1", oBilling.Address1 }, { "Adress2", oBilling.Address2 }, { "City", oBilling.City }, { "State", oBilling.State }, { "Zip", oBilling.Zip }, { "Country", oBilling.Country }, { "Phone", oBilling.Phone }, { "Fax", oBilling.Fax }, { "Email", oBilling.Email }, { "Addrnum", oBilling.Addrnum } }; return(Environment.NewLine + "Billing Information : " + Environment.NewLine + items.NotNullDataToString()); }
public override int GetHashCode() { unchecked { var hashCode = Billing != null?Billing.GetHashCode() : 0; hashCode = (hashCode * 397) ^ (CartHash != null ? CartHash.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (CartTax != null ? CartTax.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (CreatedVia != null ? CreatedVia.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Currency != null ? Currency.GetHashCode() : 0); hashCode = (hashCode * 397) ^ CustomerId; hashCode = (hashCode * 397) ^ (CustomerIpAddress != null ? CustomerIpAddress.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (CustomerNote != null ? CustomerNote.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (CustomerUserAgent != null ? CustomerUserAgent.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (DiscountTax != null ? DiscountTax.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (DiscountTotal != null ? DiscountTotal.GetHashCode() : 0); hashCode = (hashCode * 397) ^ Id; hashCode = (hashCode * 397) ^ (Number != null ? Number.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (OrderKey != null ? OrderKey.GetHashCode() : 0); hashCode = (hashCode * 397) ^ ParentId; hashCode = (hashCode * 397) ^ (PaymentMethod != null ? PaymentMethod.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (PaymentMethodTitle != null ? PaymentMethodTitle.GetHashCode() : 0); hashCode = (hashCode * 397) ^ PricesIncludeTax.GetHashCode(); hashCode = (hashCode * 397) ^ (Shipping != null ? Shipping.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (ShippingTax != null ? ShippingTax.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (ShippingTotal != null ? ShippingTotal.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Status != null ? Status.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Total != null ? Total.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (TotalTax != null ? TotalTax.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (TransactionId != null ? TransactionId.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (Version != null ? Version.GetHashCode() : 0); return(hashCode); } }
private void AddBindingComponentsIfRequired() { if (m_bindingComponentsAlreadyAdded) { return; } m_bindingComponentsAlreadyAdded = true; // Create compoennts addressBook = AddComponentBasedOnPlatform <AddressBook>(); networkConnectivity = AddComponentBasedOnPlatform <NetworkConnectivity>(); sharing = AddComponentBasedOnPlatform <Sharing>(); userInterface = AddComponentBasedOnPlatform <UI>(); utility = AddComponentBasedOnPlatform <Utility>(); #if !NATIVE_PLUGINS_LITE_VERSION billing = AddComponentBasedOnPlatform <Billing>(); mediaLibrary = AddComponentBasedOnPlatform <MediaLibrary>(); notificationService = AddComponentBasedOnPlatform <NotificationService>(); twitter = AddComponentBasedOnPlatform <Twitter>(); webview = AddComponentBasedOnPlatform <WebViewNative>(); gameServices = AddComponentBasedOnPlatform <GameServices>(); #endif }
private void metroTouchBilling_Click(object sender, EventArgs e) { string tableload = cd.TableLoad(); DataTable dtload = bld.GetFirstLoadDynamic(); if (dtload.Rows.Count > 0) { string load = dtload.Rows[0]["description"].ToString(); //TABLE Load if (load == "Table Load") { if (tableload == "Customer First") { Control ctls = this.Parent; Customer_Management.AllCusomterList vieret = new Customer_Management.AllCusomterList("TableLoad"); ctls.Controls.Clear(); ctls.Controls.Add(vieret); } else { Billing winfor = new Billing(1.ToString(), null); contentpanel.Controls.Clear(); contentpanel.Controls.Add(winfor); } } else { Billing winfor = new Billing(1000.ToString(), null); contentpanel.Controls.Clear(); contentpanel.Controls.Add(winfor); } } }
protected override void Awake() { base.Awake(); // Not interested in non singleton instance if (instance != this) { return; } // Create instances m_addressBook = AddComponentBasedOnPlatform <AddressBook>(); m_networkConnectivity = AddComponentBasedOnPlatform <NetworkConnectivity>(); m_sharing = AddComponentBasedOnPlatform <Sharing>(); m_UI = AddComponentBasedOnPlatform <UI>(); m_utility = AddComponentBasedOnPlatform <Utility>(); #if !NATIVE_PLUGINS_LITE_VERSION m_billing = AddComponentBasedOnPlatform <Billing>(); m_mediaLibrary = AddComponentBasedOnPlatform <MediaLibrary>(); m_notificationService = AddComponentBasedOnPlatform <NotificationService>(); m_twitter = AddComponentBasedOnPlatform <Twitter>(); m_webView = AddComponentBasedOnPlatform <WebViewNative>(); #endif }
/** * \brief <b>Brief Description</b> - Execute <b><i>class method</i></b> - Entry point into the generate monthly report menu * \details <b>Details</b> * * This takes in the scheduling, demographics and billing libraries * * \return <b>void</b> */ public void Execute(Scheduling scheduling, Demographics demographics, Billing billing) { // display a clear screen Container.DisplayContent(new List <Pair <string, string> >() { { new Pair <string, string>("", "") } }, 0, -1, MenuCodes.BILLING, "Billing", Description); // get the month to generate the report for DateTime getMonth = DatePicker.GetDate(scheduling, DateTime.Today, false); // check if the user didnt cancel the month selection if (getMonth.Ticks != 0) { // check if the report generation was successful if (billing.GenerateMonthlyBillingFile(scheduling, demographics, getMonth.Year, getMonth.Month)) { Container.DisplayContent(new List <Pair <string, string> >() { { new Pair <string, string>("Report successfuly generated!", "") } }, 0, -1, MenuCodes.BILLING, "Billing", Description); } else { Container.DisplayContent(new List <Pair <string, string> >() { { new Pair <string, string>("Report failed to generate.", "") } }, 0, -1, MenuCodes.BILLING, "Billing", Description); } // wait for confirmation from user that they read the message Console.ReadKey(); } }
/** * \brief <b>Brief Description</b> - Execute <b><i>class method</i></b> - Entry point into the search patient list menu * \details <b>Details</b> * * This takes in the scheduling, demographics and billing libraries * * \return <b>void</b> */ public void Execute(Scheduling scheduling, Demographics demographics, Billing billing) { // the menu that allows the user to select between searching by first and last names or HCN _searchMenu = new List <Pair <string, string> >() { { new Pair <string, string>(" > First & Last name", "") }, { new Pair <string, string>(" > Health Card Number", "") } }; // the menu for the searching by first and last names _namesSearchContent = new List <Pair <string, string> >() { { new Pair <string, string>("First Name", "") }, { new Pair <string, string>("Last Name", "") }, { new Pair <string, string>(" >> SEARCH PATIENT <<", "") } }; // the menu for the searching by health card number _hcnSearchContent = new List <Pair <string, string> >() { { new Pair <string, string>("Health Card Number", "") }, { new Pair <string, string>(" >> SEARCH PATIENT <<", "") } }; // format the input lines so they look like input lines FormatInputLines(_namesSearchContent); FormatInputLines(_hcnSearchContent); // display the search menu Container.DisplayContent(_searchMenu, 2, _selectedInputField, MenuCodes.PATIENTS, "Patients", Description); // run the main loop MainLoop(); }
public IActionResult Post(string storeName, string txndatetime, string chargetotal, string currency) { try { _secret = GetSecret(); } catch { _secret = string.Empty; } if (!string.IsNullOrEmpty(storeName) && !string.IsNullOrEmpty(txndatetime) && !string.IsNullOrEmpty(chargetotal) && !string.IsNullOrEmpty(currency) && !string.IsNullOrEmpty(_secret)) { string input = storeName + txndatetime + chargetotal + currency + _secret; string output = Billing.sha256(input); return(Json(output)); } else { return(BadRequest()); } }
internal async Task UpdateBillingAddressAsync(Billing billing) { string id = await Utilty.GetSecureStorageValueFor(Utilty.UserId); var Httpclient = new HttpClient(); var url = Constants.BaseApiAddress + "wp-json/wc/v3/customers/" + id + Constants.Consumer_Key; var uri = new Uri(string.Format(url, string.Empty)); var json = JsonConvert.SerializeObject(billing); var content = new StringContent(json, Encoding.UTF8, "application/json"); HttpResponseMessage response = null; response = await Httpclient.PutAsync(uri, content); if (response.StatusCode == HttpStatusCode.OK) { var responseContent = await response.Content.ReadAsStringAsync(); var jObject = JObject.Parse(responseContent); } }
public long GetOrderedDetails(long CompnId, int flag, out List <Billing> lstOrderedDetails, out Billing obj) { long returnCode = -1; obj = new Billing(); using TransactionScope transactionScope = new TransactionScope(); try { returnCode = objDAL.GetOrderDetails(CompnId, flag, out lstOrderedDetails); if (lstOrderedDetails.Count > 0) { foreach (var item in lstOrderedDetails) { obj.TotalOrders = lstOrderedDetails.Count; obj.TotalQtySales += item.Quantity; obj.TotalRevenue += item.UnitPrice * item.Quantity; } } transactionScope.Complete(); transactionScope.Dispose(); } catch (Exception ex) { transactionScope.Dispose(); throw ex; } return(returnCode); }
public Station(Billing billing) { Billing = billing; usersData = new Dictionary <PhoneNumber, IPort>(); callInfo = new CallInfo(); SentDataEvent += Billing.AddCallInfo; }
public string Create(Billing mo) { try { // 1. 主表部分 // 1.1 创建人 //if (Session["LoginUser"] != null) //{ // mo.Creator = (SysUser)Session["loginUser"]; //} // 1.2 报销时间 mo.CreateDate = DateTime.Now; // 2. 明细表 mo.BillingItemList = new List <BillingItem>(); var allBillingItemType = Container.Instance.Resolve <BillingItemTypeService>().GetAll(); // 最大行数 int detailRowCount = int.Parse(Request["detailRowCount"]); // 关于行循环 for (int i = 1; i <= detailRowCount; i++) { // 检查明细行是否存在 if (Request["BillingItemType" + i] == null) { continue; } // 处理明细行输入 BillingItem bi = new BillingItem(); if (Request["ID" + i] != null) { // 原有行 bi.ID = int.Parse(Request["ID" + i]); } bi.Fee = decimal.Parse(Request["Fee" + i]); bi.Remark = Request["Remark" + i]; int billingItemTypeId = int.Parse(Request["BillingItemType" + i]); bi.BillingItemType = (from m in allBillingItemType where m.ID == billingItemTypeId select m).FirstOrDefault(); // 关联主表与从表 bi.Billing = mo; mo.BillingItemList.Add(bi); } // 3. 提交主表(级联提交明细表) Container.Instance.Resolve <BillingService>().Create(mo); // 4. 更新托运单状态 DeliveryForm deliveryForm = Container.Instance.Resolve <DeliveryFormService>().GetEntity(mo.DeliveryForm.ID); TransportOrder transportOrder = deliveryForm.TransportOrder; transportOrder.Status = 3; // 已报账 Container.Instance.Resolve <TransportOrderService>().Edit(transportOrder); return("ok"); } catch (Exception ex) { return(ex.Message); } }
public async Task <IActionResult> Edit(int id, [Bind("BillingID,NameOnCard,CardNumber,ExpirationMonth,ExpirationYear,SecurityCode,AddressNum,AddressStreet,AddressCity,AddressState,AddressZipCode")] Billing billing) { if (id != billing.BillingID) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(billing); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!BillingExists(billing.BillingID)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(billing)); }
public List<Billing> GetAllBillingDetails() { aConnection.Open(); string query = string.Format("SELECT * FROM t_billing_information"); SqlCommand aCommand = new SqlCommand(query, aConnection); SqlDataReader aReader = aCommand.ExecuteReader(); List<Billing> billings = new List<Billing>(); if (aReader.HasRows) { while (aReader.Read()) { aBilling = new Billing(); aBilling.Id = (int) aReader[0]; aBilling.TotalCost = Convert.ToDouble(aReader[1].ToString()); aBilling.Advance = Convert.ToDouble(aReader[2].ToString()); aBilling.Due = Convert.ToDouble(aReader[3].ToString()); aBilling.BillingDate = aReader[4].ToString(); aBilling.BookId = (int)aReader[5]; billings.Add(aBilling); } } aConnection.Close(); return billings; }
public async Task <IEnumerable <Billing> > SaveAsync(IEnumerable <Billing> billings, CancellationToken token = default(CancellationToken)) { var result = new List <Billing>(); var dueAtUpdateTargets = new Dictionary <long, Billing>(); using (var scope = transactionScopeBuilder.Create()) { foreach (var billing in billings) { if (billing.BillingInputId.HasValue && !dueAtUpdateTargets.ContainsKey(billing.BillingInputId.Value)) { dueAtUpdateTargets.Add(billing.BillingInputId.Value, billing); } var updateItem = new Billing { Id = billing.Id, CompanyId = billing.CompanyId, DueAt = billing.DueAt, OffsetAmount = billing.OffsetAmount, ScheduledPaymentKey = billing.ScheduledPaymentKey, UpdateBy = billing.UpdateBy, }; result.Add(await updatebillingQueryProcessor.UpdateScheduledPaymentAsync(updateItem, token)); } foreach (var billing in dueAtUpdateTargets.Values) { var updates = (await updatebillingQueryProcessor.UpdateScheduledPaymentForDueAtAsync(billing, token)) .Where(x => !result.Any(y => y.Id == x.Id)).ToArray(); result.AddRange(updates); } scope.Complete(); } return(result); }
public List <Billing> GetOrderBills(int paystatus, int invoicestatus, int returnstatus, string begintime, string endtime, string keyWords, int pageSize, int pageIndex, ref int totalCount, ref int pageCount, string userid, string agentid, string clientid) { List <Billing> list = new List <Billing>(); DataSet ds = FinanceDAL.BaseProvider.GetOrderBills(paystatus, invoicestatus, returnstatus, begintime, endtime, keyWords, pageSize, pageIndex, ref totalCount, ref pageCount, userid, agentid, clientid); foreach (DataRow dr in ds.Tables[0].Rows) { Billing model = new Billing(); model.FillData(dr); model.CreateUser = OrganizationBusiness.GetUserByUserID(model.CreateUserID, model.AgentID); model.PayStatusStr = model.PayStatus == 0 ? "未收款" : model.PayStatus == 1 ? "部分收款" : model.PayStatus == 2 ? "已收款" : model.PayStatus == 9 ? "已删除" : ""; model.InvoiceStatusStr = model.InvoiceStatus == 0 ? "未开票" : model.InvoiceStatus == 1 ? "已申请" : model.InvoiceStatus == 2 ? "已开票" : model.InvoiceStatus == 9 ? "已删除" : ""; list.Add(model); } return(list); }
async Task <bool> Fetch(ItemType type) { try { var purchases = await Billing.GetPurchasesAsync(type); if (purchases.None()) { return(false); } foreach (var purchase in purchases.Distinct(x => x.Id)) { if (purchase.State != PurchaseState.Purchased) { continue; } if (purchase.IsAcknowledged) { continue; } await BillingContext.Current.PurchaseAttempt(purchase.ToEventArgs()); await Billing.AcknowledgePurchaseAsync(purchase.PurchaseToken); } return(true); } catch (Exception ex) { Log.For(this).Error(ex); return(false); } }
static void Main(string[] args) { Billing b = new Billing("01/02/2019", "Utility Nov 1, 2018 to Dec 31, 2018", 500); Payment p1 = new Cash(230, "01/15/2019", 240); Payment p2 = new Check(100, "Chase", "John Doe", "111111", "01/01/2019"); Payment p3 = new CreditCard(100, "1234-5678-9012-3456", "Visa", "01/01/2022", "John Doe", "01/01/2019"); Console.WriteLine($"Bill Info.:\n{b.getBillInfo()}"); Console.WriteLine("\n--------------new payment-------------------------"); b.addPayment(p1); Console.WriteLine($"Bill Info.:\n{b.getBillInfo()}"); Console.WriteLine("\n--------------new payment-------------------------"); b.addPayment(p2); Console.WriteLine($"Bill Info.:\n{b.getBillInfo()}"); Console.WriteLine("\n--------------new payment-------------------------"); b.addPayment(p3); Console.WriteLine($"Bill Info.:\n{b.getBillInfo()}"); // Uncomment the following line to test Task B.2 of CIDM 5360 assignment //b.makePaymentPlan(5); }
public async void Get([FromForm] string text, [FromForm] string response_url) { var client = new HttpClient(); string hostid = text; XMLBilling billing = new XMLBilling(); string xmlData = await BillingSchemeReader.ReadDataAsync(hostid, billing); if (xmlData.Contains("billing")) { Billing bs = await BillingSchemeReader.ReadXML(xmlData); Result res = new Result(hostid, billing); res.PrepareSlackResponse(bs); await client.PostAsync(response_url, new StringContent( JsonConvert.SerializeObject(res), Encoding.UTF8, "application/json")); } else { Result res = new Result { text = xmlData }; await client.PostAsync(response_url, new StringContent( JsonConvert.SerializeObject(res), Encoding.UTF8, "application/json")); } }
/** * \brief <b>Brief Description</b> - AddBillingCode <b><i>class method</i></b> - This method adds a billing code to a patient * \details <b>Details</b> * * This takes in the appointment ID, the id of the patient and the billing library * * \return <b>int</b> - status flag */ private int AddBillingCode(string aptID, string patientID, Billing billing) { // ask for a billing code Container.DisplayContent(new List <Pair <string, string> >() { { new Pair <string, string>("Enter the billing code: ", "") } }, 0, 1, MenuCodes.SCHEDULING, "Scheduling", Description); // set cursor Console.CursorTop = 6; Console.CursorLeft = 55; // ask the user to enter a billing code Pair <InputRetCode, string> inputReturn = Input.GetInput("", 4, InputType.Ints | InputType.Strings); // check if the user saved the billing code if ((inputReturn.First & InputRetCode.SAVE) != 0 && inputReturn.Second.Length == 4) { // add billing code to record if (billing.AddNewRecord(aptID, patientID, inputReturn.Second)) { return(1); } return(0); } return(-1); }
public ActionResult Checkout(string Name) { Customer customer = db.Customers.Where(x => x.Username == Name).First(); //see if they have a shipping address try { Shipping ship = db.Shippings.Where(x => x.CustomerID == customer.CustomerID).First(); } catch (Exception e) { //RedirectToRoute("Shipping/Create"); return(RedirectToAction("CreateForCheckout", "Shipping", null)); } //see if they have a billing address try { Billing bill = db.Billings.Where(x => x.CustomerID == customer.CustomerID).First(); } catch (Exception e) { return(RedirectToAction("CreateForCheckout", "Billing", null)); } //see if they have a credit card try { Credit_Card card = db.Credit_Card.Where(x => x.CustomerID == customer.CustomerID).First(); } catch (Exception e) { return(RedirectToAction("CreateForCheckout", "CreditCard", null)); } return(RedirectToAction("ReviewInvoice", "Invoice", null)); }
/** * \brief <b>Brief Description</b> - Execute <b><i>class method</i></b> - An overload of the entry point into the reconcile summary viewing menu * \details <b>Details</b> * * This takes in the existing patient information, if it should return a patient and the demographics library * * \return <b>void</b> */ public void Execute(Scheduling scheduling, Demographics demographics, Billing billing) { Container.DisplayContent(new List <Pair <string, string> >() { { new Pair <string, string>("", "") } }, 2, 1, MenuCodes.BILLING, "Billing", Description); // let the user pick a month DateTime getMonth = DatePicker.GetDate(scheduling, DateTime.Today, false); // check if user did not cancel during month selection screen if (getMonth.Ticks != 0) { // generate the government file name string date = string.Format("{0}{1}govFile.txt", getMonth.Year, getMonth.Month); // get the list of the report contents List <string> report = billing.ReconcileMonthlyBilling(date); List <Pair <string, string> > content = new List <Pair <string, string> >(); // create the content using the lines in the report foreach (string line in report) { content.Add(new Pair <string, string>(line, "")); } // display the contents of the report Container.DisplayContent(content, 2, -1, MenuCodes.BILLING, "Billing", Description); Console.ReadKey(); } }
public static Billing GetBillingByBillingID(int BillingID) { Billing billing = new Billing(); SqlBillingProvider sqlBillingProvider = new SqlBillingProvider(); billing = sqlBillingProvider.GetBillingByBillingID(BillingID); return billing; }
/// <summary> /// The bt o k_ click. /// </summary> /// <param name="sender"> /// The sender. /// </param> /// <param name="e"> /// The e. /// </param> protected void BtOkClick(object sender, EventArgs e) { var errorlabel = this.Master?.FindControl("form1").FindControl("divErrorMessage") as Label; this.service = new Service(); this.billing = new Billing(); var myService = Convert.ToInt32(this.serviceComboBox.SelectedItem.Value); this.service = this.serviceEntityController.GetEntity(myService); var myBilling = Convert.ToInt32(this.billingComboBox.SelectedItem.Value); this.billing = this.billingEntityController.GetEntity(myBilling); if (this.idTextBox.Text == string.Empty) { this.idTextBox.Text = "0"; } this.billingService = new BillingService { Id = Convert.ToInt32(this.idTextBox.Text), ServiceId = this.service.Id, Billing = this.billing, Price = Convert.ToDouble(this.priceTextBox.Text), Quantity = Convert.ToInt32(this.quantityTextBox.Text), }; try { this.billing = this.billingEntityController.GetEntity(myBilling); this.billingService = new BillingService { Id = Convert.ToInt32(this.idTextBox.Text), ServiceId = this.service.Id, BillingId = this.billing.Id, Price = Convert.ToDouble(this.priceTextBox.Text), Quantity = Convert.ToInt32(this.quantityTextBox.Text), }; this.billingServiceEntityController.CreateOrUpdateEntity(this.billingService); this.BillingServiceListGridView.DataSource = this.billingServiceEntityController.RefreshEntities(); this.BillingServiceListGridView.DataBind(); this.quantityTextBox.Text = string.Empty; this.idTextBox.Text = string.Empty; this.priceTextBox.Text = string.Empty; } catch (SqlException ex) { if (errorlabel != null) { errorlabel.Text = "Something went wrong with the database.Please check the connection string."; } } catch (ArgumentNullException ex) { if (errorlabel != null) { errorlabel.Text = "Couldn't create the current Billing"; } } }
public ActionResult YourAccount() { Customer customer = db.Customers.Where(x => x.Username == User.Identity.Name).First(); Shipping ship = null; Billing bill = null; Credit_Card card = null; try { ship = db.Shippings.Where(x => x.CustomerID == customer.CustomerID).First(); } catch (Exception e) { } try { bill = db.Billings.Where(x => x.CustomerID == customer.CustomerID).First(); } catch (Exception e) { } try { card = db.Credit_Card.Where(x => x.CustomerID == customer.CustomerID).First(); } catch (Exception e) { } InvoiceModel invoice = new InvoiceModel(); invoice.Invoices = new List <Invoice>(); if (card != null) { var invoices = db.Invoices.Where(x => x.CardID == card.CardID); foreach (var item in invoices) { invoice.Invoices.Add(item); } invoice.CardID = card.CardID; invoice.Card = card; } if (ship != null) { invoice.ShippingID = ship.ShipID; invoice.Shipping = ship; } if (bill != null) { invoice.Billing = bill; invoice.BillingID = bill.BillID; } invoice.CustomerID = customer.CustomerID; return(View(invoice)); }
public IActionResult NewBook(BookViewModel model) { Guid rID = Guid.NewGuid(); if (!ModelState.IsValid) { ModelState.AddModelError("Error", "Required"); return View(model); } Reservation reservation = new Reservation() { FacilityID = model.FacilityID, ReservationID = rID, UserID = User.GetId(), FacilityType = model.FacilityType, CheckIn = model.CheckIn, CheckOut = model.CheckOut }; Billing billing = new Billing() { UserID = User.GetId(), BillingID = Guid.NewGuid(), ReservationID = rID, TotalAmount = model.RentCharges, MiscCharges = 0, RentCharges = model.RentCharges, }; _context.Reservations.Add(reservation); _context.Billings.Add(billing); _context.SaveChanges(); this.SendNow("Hello " + this.User.GetFullName() + "Thank you for Booking in Peninsula Hotel and Resort" + "Check In:" + model.CheckIn + "Check Out:" + model.CheckOut + "Payment:" + model.RentCharges, this.User.GetEmailAddress(), "Peninsula Confirmed Reservation", "Thank you for making a Reservation in Peninsula!"); return Redirect("~/"); }
/// <summary>請求データ検索 から 請求データの取得</summary> private List <Billing> GetBillingDataFromBillingSearch() { Billing selected = null; using (var form = ApplicationContext.Create(nameof(PC0301))) { var screen = form.GetAll <PC0301>().FirstOrDefault(); screen.ReturnScreen = this; form.StartPosition = FormStartPosition.CenterParent; var dialogResult = ApplicationContext.ShowDialog(ParentForm, form); if (dialogResult != DialogResult.OK) { return(null); } selected = screen.grdSearchResult.CurrentRow.DataBoundItem as Billing; } if (selected == null) { return(null); } if (!selected.BillingInputId.HasValue) { return new List <Billing> { selected } } ; var task = GetBillingByInputIdAsync(selected.BillingInputId.Value); ProgressDialog.Start(ParentForm, task, false, SessionKey); return(task.Result); }
public void Test_CardPreAuthorization_Create_WithBilling() { try { CardPreAuthorizationPostDTO cardPreAuthorization = getPreAuthorization(GetJohn().Id); Billing billing = new Billing(); Address address = new Address(); address.City = "Test city"; address.AddressLine1 = "Test address line 1"; address.AddressLine2 = "Test address line 2"; address.Country = CountryIso.RO; address.PostalCode = "65400"; billing.Address = address; cardPreAuthorization.Billing = billing; CardPreAuthorizationDTO cardPreAuthorizationWithBilling = this.Api.CardPreAuthorizations.Create(cardPreAuthorization); Assert.IsNotNull(cardPreAuthorizationWithBilling); Assert.IsNotNull(cardPreAuthorizationWithBilling.Billing); Assert.IsNotNull(cardPreAuthorizationWithBilling.SecurityInfo); Assert.IsNotNull(cardPreAuthorizationWithBilling.SecurityInfo.AVSResult); Assert.AreEqual(cardPreAuthorizationWithBilling.SecurityInfo.AVSResult, AVSResult.NO_CHECK); } catch (Exception ex) { Assert.Fail(ex.Message); } }
public ActionResult Authorize(string sessionId, string year, string month, decimal amount, string orderId, string transId, string currency) { var settingResponse = _checkoutApi.PaymentSetting(PaymentMethodTypes.MasterCard.ToString()); var setting = settingResponse.Result; Billing billingAddress = new Billing(); billingAddress.address = new Address() { }; var orderDetail = _orderApi.GetOrdDetail(orderId); billingAddress.address.country = Utils.GetThreeChracterCountryCode(orderDetail.Result.BillingAddress.CountryCode); // "GBR";//orderDetail.Result.BillingAddress.CountryCode; if (string.IsNullOrEmpty(billingAddress.address.country) == true) { billingAddress.address.country = "GBR"; } billingAddress.address.postcodeZip = orderDetail.Result.BillingAddress.PostCode; billingAddress.address.street = orderDetail.Result.BillingAddress.Address1; billingAddress.address.city = orderDetail.Result.BillingAddress.City; if (!string.IsNullOrEmpty(orderDetail.Result.BillingAddress.Address2)) { billingAddress.address.street2 = orderDetail.Result.BillingAddress.Address2; } billingAddress.address.stateProvince = orderDetail.Result.BillingAddress.State; var mcard = new MasterCardApi(setting); var payResult = mcard.Authorize(sessionId, year, month, amount, orderId, transId, currency, billingAddress); return(JsonSuccess(payResult, JsonRequestBehavior.AllowGet)); }
public void ActOnError(Billing.BillingAccount billingAccount = null) { if (billingAccount != null) { var billingCompany = new BillingCompanyRepository(new DBConnection()).GetBillingCompanyNameById(billingAccount.BillingCompanyId.IdString); if (billingCompany != null) { new Logging().LogMessage(Enumeration.LoggingPriority.Low, "123", string.Format("The script for {0} has been broken", billingCompany.CompanyName)); } } }
public bool AddBilling(Billing model) { try { entities.Billings.Add(model); entities.SaveChanges(); return true; } catch (Exception x) { FileLogger.LogError(x); return false; } }
public void AddBilling(int GuestID, decimal RoomCharge) { using (var context2 = new Sunshine_HotelEntities1()) { //select out the last guest ID, whichis the one above // var NewGuestID = context.Guests.Select(g => g.GuestID).ToList().LastOrDefault(); var saveRoomBilling = new Billing { GuestIDFK = GuestID, BarCharge = 0, WiFiCharge = 0, TelephoneCharge = 0, RoomCharge = RoomCharge }; context2.Billings.Add(saveRoomBilling); context2.SaveChanges(); } }
/// <summary> /// Faz uma Autorização. /// </summary> public ResponseBase Auth(String merchantId, String merchantKey, String referenceNum, decimal chargeTotal, String creditCardNumber , String expMonth, String expYear, String cvvInd, String cvvNumber, String authentication, String processorId , String numberOfInstallments, String chargeInterest, String ipAddress, String customerIdExt, String billingName , String billingAddress, String billingAddress2, String billingCity, String billingState, String billingPostalCode , String billingCountry, String billingPhone, String billingEmail, String shippingName, String shippingAddress , String shippingAddress2, String shippingCity, String shippingState, String shippingPostalCode, String shippingCountry , String shippingPhone, String shippingEmail, String currencyCode, String fraudCheck) { this.FillRequestBase("auth", merchantId, merchantKey, referenceNum, chargeTotal, creditCardNumber, expMonth, expYear , cvvInd, cvvNumber, authentication, processorId, numberOfInstallments , chargeInterest, ipAddress, customerIdExt, currencyCode, fraudCheck); RequestBase auth = this.request.Order.Auth; Billing billing = new Billing(); auth.Billing = billing; billing.Address1 = billingAddress; billing.Address2 = billingAddress2; billing.City = billingCity; billing.Country = billingCountry; billing.Email = billingEmail; billing.Name = billingName; billing.Phone = billingPhone; billing.Postalcode = billingPostalCode; billing.State = billingState; Shipping shipping = new Shipping(); auth.Shipping = shipping; shipping.Address1 = shippingAddress; shipping.Address2 = shippingAddress2; shipping.City = shippingCity; shipping.Country = shippingCountry; shipping.Email = shippingEmail; shipping.Name = shippingName; shipping.Phone = shippingPhone; shipping.Postalcode = shippingPostalCode; shipping.State = shippingState; return new Utils().SendRequest<TransactionRequest>(this.request, this.Environment); }
public bool UpdateBilling(Billing model) { try { Billing billing = entities.Billings.Where(x => x.BillingId == model.BillingId).SingleOrDefault(); if (billing != null) { entities.Entry(billing).CurrentValues.SetValues(model); entities.SaveChanges(); return true; } else { return false; } } catch (Exception x) { FileLogger.LogError(x); return false; } }
public void should_persist() { var customer = new Customer("Name"); var physicalAddress = new Address(AddressType.Physical, "Line1", "Line2", "PostalCode", "City", new Country("South Africa"), "PostalCode", new Province("Limpopo")); var postalAddress = new Address(AddressType.Postal, "Line1", "Line2", "PostalCode", "City", new Country("South Africa"), "PostalCode", new Province("Gauteng")); var billing = new Billing("ContactNumber", "ContactPerson", "RegistrationNumber", DateTime.Now, "PastelId", "VatNumber", PaymentType.DebitOrder); var roles = new HashSet<Role>{new Role("Role")}; var user = new User("FirstName", "LastName", "IdNumber", "ContactNumber", "UserName", "Password", false, UserType.Internal, roles); new PersistenceSpecification<Customer>(Session, new CustomEqualityComparer()) .CheckProperty(c => c.Id, Guid.NewGuid()) .CheckProperty(c => c.Name, "Name") .CheckReference(c => c.AccountOwner, user) .CheckReference(c => c.Billing, billing) .CheckReference(c => c.CommercialState, new CommercialState("CommercialState")) //.CheckReference(c => c.PlatformStatus, new PlatformStatus("PlatformStatus", PlatformStatusType.Activated)) .CheckReference(c => c.ContactDetail, new ContactDetail("Name", "ContactName", "EmailAddress", physicalAddress, postalAddress)) .CheckReference(c => c.CreateSource, CreateSourceType.Web) .CheckComponentList(c => c.CustomerUsers, new HashSet<User>{ user }) .CheckComponentList(c => c.Contracts, new HashSet<Contract> { new Contract(DateTime.Now, "Name", "Detail", "By", DateTime.Now, "RegisteredName", "Reg#", new ContractType("Type"), EscalationType.AnnualPercentageAllProducts, ContractDuration.Custom) }) .CheckComponentList(c => c.Industries, new HashSet<CustomerIndustry> { new CustomerIndustry(customer, Guid.NewGuid())}) .VerifyTheMappings(customer); }
public Billing GetBillingDetails(int customerId) { aConnection.Open(); string query = string.Format("SELECT * FROM t_billing_information WHERE customer_id = {0}", customerId); SqlCommand aCommand = new SqlCommand(query, aConnection); SqlDataReader aReader = aCommand.ExecuteReader(); Billing billing = new Billing(); if (aReader.HasRows) { while (aReader.Read()) { billing.Id = (int)aReader[0]; billing.TotalCost = Convert.ToDouble(aReader[1].ToString()); billing.Advance = Convert.ToDouble(aReader[2].ToString()); billing.Due = Convert.ToDouble(aReader[3].ToString()); billing.BillingDate = aReader[4].ToString(); billing.BookId = Convert.ToInt32(aReader[5].ToString()); billing.CustomerId = Convert.ToInt32(aReader[6].ToString()); } } aConnection.Close(); return billing; }
/// <summary> /// This does Update and New entries /// </summary> /// <returns>The total to the label</returns> public string SaveExpenses() { //save the expenses to the DB and return the Total if (GuestIDFK == 0) { MessageBox.Show("You must chose a Guest first"); return "Invalid"; } //get a list of all guestID to check against var id = new List<int?>(); //put the guestids into the list using (var context = new Sunshine_HotelEntities1()) { id = context.Billings.Select(b => b.GuestIDFK).ToList(); } //IF THERE IS ALREADY A GUEST THEN JUST UPDATE if (id.Contains(GuestIDFK)) { using (var context = new Sunshine_HotelEntities1()) { //get the entry that matches the guestid var update = context.Billings.Where(b => b.GuestIDFK == GuestIDFK); //get the first or only entry var bill = update.FirstOrDefault(); //pass the data across bill.BarCharge = BarCharge; bill.WiFiCharge = WifiCharge; bill.TelephoneCharge = PhoneCharge; bill.RoomCharge = RoomCharge; bill.GuestIDFK = GuestIDFK; //save changes context.SaveChanges(); } //ELSE ADD NEW GUEST } else { using (var context = new Sunshine_HotelEntities1()) { var NewBilling = new Billing(); NewBilling.BarCharge = BarCharge; NewBilling.WiFiCharge = WifiCharge; NewBilling.TelephoneCharge = PhoneCharge; NewBilling.RoomCharge = RoomCharge; NewBilling.GuestIDFK = GuestIDFK; //update db context.Billings.Add(NewBilling); context.SaveChanges(); } } var total = Convert.ToString(BarCharge + WifiCharge + PhoneCharge + RoomCharge); return total; }
/// <summary> /// Passa uma transação salvando o número de cartão automaticamente. /// </summary> private ResponseBase PaySavingCreditCardAutomatically(String operation, String merchantId, String merchantKey, String referenceNum, decimal chargeTotal , String creditCardNumber, String expMonth, String expYear, String cvvInd, String cvvNumber , String processorId, String numberOfInstallments, String chargeInterest, String ipAddress , String customerToken, String onFileEndDate, String onFilePermission, String onFileComment , String onFileMaxChargeAmount, String billingName, String billingAddress, String billingAddress2 , String billingCity, String billingState, String billingPostalCode, String billingCountry , String billingPhone, String billingEmail, String currencyCode, String fraudCheck) { this.request = new TransactionRequest(merchantId, merchantKey); Order order = this.request.Order; RequestBase rBase = new RequestBase(); if (operation.Equals("sale")) order.Sale = rBase; else if (operation.Equals("auth")) order.Auth = rBase; rBase.ReferenceNum = referenceNum; rBase.ProcessorId = processorId; rBase.IpAddress = ipAddress; rBase.FraudCheck = fraudCheck; Billing billing = new Billing(); rBase.Billing = billing; billing.Address1 = billingAddress; billing.Address2 = billingAddress2; billing.City = billingCity; billing.Country = billingCountry; billing.Email = billingEmail; billing.Name = billingName; billing.Phone = billingPhone; billing.Postalcode = billingPostalCode; billing.State = billingState; Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("en-US"); Payment payment = new Payment(); rBase.Payment = payment; payment.ChargeTotal = chargeTotal; payment.CurrencyCode = currencyCode; if (String.IsNullOrEmpty(numberOfInstallments)) numberOfInstallments = "0"; int tranInstallments = int.Parse(numberOfInstallments); //Verifica se vai precisar criar o nó de parcelas e juros. if (!String.IsNullOrEmpty(chargeInterest) && tranInstallments > 1) { payment.CreditInstallment = new CreditInstallment(); payment.CreditInstallment.ChargeInterest = chargeInterest.ToUpper(); payment.CreditInstallment.NumberOfInstallments = numberOfInstallments; } TransactionDetail detail = rBase.TransactionDetail; PayType payType = detail.PayType; CreditCard creditCard = new CreditCard(); payType.CreditCard = creditCard; creditCard.CvvInd = cvvInd; creditCard.CvvNumber = cvvNumber; creditCard.ExpMonth = expMonth; creditCard.ExpYear = expYear; creditCard.Number = creditCardNumber; rBase.SaveOnFile = new SaveOnFile(); rBase.SaveOnFile.CustomerToken = customerToken; rBase.SaveOnFile.OnFileComment = onFileComment; rBase.SaveOnFile.OnFileEndDate = onFileEndDate; rBase.SaveOnFile.OnFileMaxChargeAmount = onFileMaxChargeAmount; rBase.SaveOnFile.OnFilePermission = onFilePermission; return new Utils().SendRequest<TransactionRequest>(this.request, this.Environment); }
public bool UpdateBilling(Billing billing) { using (SqlConnection connection = new SqlConnection(this.ConnectionString)) { SqlCommand cmd = new SqlCommand("UpdateBilling", connection); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@BillingID", SqlDbType.Int).Value = billing.BillingID; cmd.Parameters.Add("@ClientID", SqlDbType.Int).Value = billing.ClientID; cmd.Parameters.Add("@PaymnetDate", SqlDbType.DateTime).Value = billing.PaymnetDate; cmd.Parameters.Add("@PaymnetType", SqlDbType.Int).Value = billing.PaymnetType; cmd.Parameters.Add("@AmountCharge", SqlDbType.Decimal).Value = billing.AmountCharge; cmd.Parameters.Add("@AmountPaid", SqlDbType.Decimal).Value = billing.AmountPaid; cmd.Parameters.Add("@TreatmentServiceID", SqlDbType.Decimal).Value = billing.TreatmentServiceID; cmd.Parameters.Add("@EntryBy", SqlDbType.NVarChar).Value = billing.EntryBy; cmd.Parameters.Add("@EntryDate", SqlDbType.DateTime).Value = billing.EntryDate; connection.Open(); int result = cmd.ExecuteNonQuery(); return result == 1; } }
/// <summary> /// Faz uma requisição de boleto. /// </summary> public ResponseBase Boleto(String merchantId, String merchantKey, String referenceNum, decimal chargeTotal, String processorId , String ipAddress, String customerIdExt, String expirationDate, String number, String instructions , String billingName, String billingAddress, String billingAddress2, String billingCity, String billingState , String billingPostalCode, String billingCountry, String billingPhone, String billingEmail) { this.request = new TransactionRequest(merchantId, merchantKey); Order order = this.request.Order; RequestBase sale = new RequestBase(); order.Sale = sale; sale.ReferenceNum = referenceNum; sale.ProcessorId = processorId; sale.IpAddress = ipAddress; sale.CustomerIdExt = customerIdExt; Billing billing = new Billing(); sale.Billing = billing; billing.Address1 = billingAddress; billing.Address2 = billingAddress2; billing.City = billingCity; billing.Country = billingCountry; billing.Email = billingEmail; billing.Name = billingName; billing.Phone = billingPhone; billing.Postalcode = billingPostalCode; billing.State = billingState; Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("en-US"); Payment payment = new Payment(); sale.Payment = payment; payment.ChargeTotal = chargeTotal; TransactionDetail detail = sale.TransactionDetail; PayType payType = detail.PayType; Boleto boleto = new Boleto(); payType.Boleto = boleto; boleto.ExpirationDate = expirationDate; boleto.Instructions = instructions; boleto.Number = number; return new Utils().SendRequest<TransactionRequest>(this.request, this.Environment); }
public static bool UpdateBilling(Billing billing) { SqlBillingProvider sqlBillingProvider = new SqlBillingProvider(); return sqlBillingProvider.UpdateBilling(billing); }
public Billing GetBillingFromReader(IDataReader reader) { try { Billing billing = new Billing ( DataAccessObject.IsNULL<int>(reader["BillingID"]), DataAccessObject.IsNULL<int>(reader["ClientID"]), DataAccessObject.IsNULL<DateTime>(reader["PaymnetDate"]), DataAccessObject.IsNULL<int>(reader["PaymnetType"]), DataAccessObject.IsNULL<decimal>(reader["AmountCharge"]), DataAccessObject.IsNULL<decimal>(reader["AmountPaid"]), DataAccessObject.IsNULL<int>(reader["TreatmentServiceID"]), DataAccessObject.IsNULL<string>(reader["EntryBy"].ToString()), DataAccessObject.IsNULL<DateTime>(reader["EntryDate"]) ); return billing; } catch(Exception ex) { return null; } }
public static string GetNextCptBillingCodeId(Billing.Model.CptBillingCodeItemCollection cptBillingCodeItemCollection, string masterAccessionNo) { string result = string.Empty; int largestId = 0; foreach (Billing.Model.CptBillingCodeItem cptBillingCodeItem in cptBillingCodeItemCollection) { OrderIdParser orderIdParser = new OrderIdParser(cptBillingCodeItem.CptBillingId); int? cptBillingCodeNo = orderIdParser.CptBillingCodeNo; if (cptBillingCodeNo == null) { int currentId = GetIdNumber(cptBillingCodeItem.CptBillingId, Billing.Model.CptBillingCodeItemCollection.PREFIXID); if (currentId > largestId) largestId = currentId; } else { if (cptBillingCodeNo.Value > largestId) largestId = cptBillingCodeNo.Value; } } return masterAccessionNo + "." + Billing.Model.CptBillingCodeItemCollection.PREFIXID + (largestId + 1).ToString(); }
public static int InsertBilling(Billing billing) { SqlBillingProvider sqlBillingProvider = new SqlBillingProvider(); return sqlBillingProvider.InsertBilling(billing); }
public void ActOnError(Billing.BillingAccount billingAccount = null) { throw new NotImplementedException(); }
// add a credit card for a customer to the database public void AddCreditCard(Billing.CreditCard card, int custID) { try { // insert customer into table int cardID = Convert.ToInt32(cardTableAdapter.InsertAndGetID((int)card.CardType, card.CreditCardNumber)); // set card ID card.CardID = cardID; // inster customer-card mapping customerCardTableAdapter.Insert(custID, cardID); } catch (Exception) { throw new CreditCardException("Could not add credit card to database."); } }
public static string GetNextICD9BillingCodeId(Billing.ICD9BillingCodeCollection icd9BillingCodeCollection, string masterAccessionNo) { string result = string.Empty; int largestId = 0; foreach (Billing.ICD9BillingCode icd9BillingCode in icd9BillingCodeCollection) { OrderIdParser orderIdParser = new OrderIdParser(icd9BillingCode.Icd9BillingId); int? icd9BillingCodeNo = orderIdParser.Icd9BillingCodeNo; if (icd9BillingCodeNo == null) { int currentId = GetIdNumber(icd9BillingCode.Icd9BillingId, Billing.ICD9BillingCodeCollection.PREFIXID); if (currentId > largestId) largestId = currentId; } else { if (icd9BillingCodeNo.Value > largestId) largestId = icd9BillingCodeNo.Value; } } return masterAccessionNo + "." + Billing.ICD9BillingCodeCollection.PREFIXID + (largestId + 1).ToString(); }
public double GetPrice(Billing billing) { return (double)billing; }
public void AddToOrdersLines(Billing.OrderLine orderLine) { base.AddObject("OrdersLines", orderLine); }