You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
59 lines
1.8 KiB
C#
59 lines
1.8 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel;
|
|
using System.Drawing;
|
|
using System.Data;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Windows.Forms;
|
|
using POSV.ShoppingCart;
|
|
using DevComponents.DotNetBar;
|
|
using POS.Language.Language;
|
|
|
|
namespace POSV.Bill
|
|
{
|
|
[ToolboxItem(true)]
|
|
public partial class BillSummary : BaseUserControl
|
|
{
|
|
public BillSummary()
|
|
{
|
|
InitializeComponent();
|
|
|
|
foreach (var item in doubleBufferTableLayoutPanel1.Controls)
|
|
{
|
|
var _lbl = item as LabelX;
|
|
if (_lbl == null)
|
|
{
|
|
continue;
|
|
}
|
|
_lbl.Text = LangProxy.ToLang(_lbl.Text);
|
|
|
|
}
|
|
}
|
|
|
|
public void Refresh(OrderObject orderObject)
|
|
{
|
|
//总金额
|
|
this.lblTotalAmount.Text = orderObject.Amount.ToString();
|
|
//优惠金额
|
|
this.lblConcessionaryAmount.Text = orderObject.DiscountAmount.ToString();
|
|
//应收金额
|
|
this.lblReceivableAmount.Text = orderObject.ReceivableAmount.ToString();
|
|
//抹零金额
|
|
this.lblMalingAmount.Text = orderObject.MalingAmount.ToString();
|
|
//实收金额
|
|
this.lblPaidAmount.Text = orderObject.PaidAmount.ToString();
|
|
//已收金额
|
|
this.lblReceivedAmount.Text = orderObject.ReceivedAmount.ToString();
|
|
//未收金额
|
|
var unpaidAmount = orderObject.PaidAmount - orderObject.ReceivedAmount;
|
|
this.lblUnpaidAmount.Text = unpaidAmount < 0 ? "0" : unpaidAmount.ToString();
|
|
|
|
//找零金额
|
|
this.lblChangeAmount.Text = orderObject.ChangeAmount.ToString();
|
|
//溢收金额
|
|
this.lblOverAmount.Text = orderObject.OverAmount.ToString();
|
|
}
|
|
}
|
|
}
|