示例#1
0
    protected void save_Click(object sender, EventArgs e)
    {
        try
        {
            check();
            T_ActualProfitAccounting item = new T_ActualProfitAccounting();
            item.SaleBillNo         = txt_sale_bill_no.Text.Trim();
            item.ActualAmount       = Decimal.Parse(txt_actual_amount.Text.Trim());
            item.ReturnTax          = Decimal.Parse(txt_return_tax.Text.Trim());
            item.ActualPay          = Decimal.Parse(txt_actual_pay.Text.Trim());
            item.ExtraCharges       = Decimal.Parse(txt_extra_charges.Text.Trim());
            item.Commission         = Decimal.Parse(txt_commission.Text.Trim());
            item.ActualProfitAmount = Decimal.Parse(lbl_actual_profit_amount.Text.Trim());
            item.ActualProfit       = Decimal.Parse(lbl_actual_profit.Text.Trim());
            item.AuditStatus        = false;


            ProfitAccountingAdapter paa = new ProfitAccountingAdapter();
            paa.IsActualAudit(item.SaleBillNo, true);

            ActualProfitAccountingAdapter apaa = new ActualProfitAccountingAdapter();

            apaa.addData(item);
            Label1.Text = "保存成功";
            clean();
        }
        catch (Exception ex)
        {
            Label1.Text = ex.Message;
            return;
        }
    }
 public void updateData(T_ActualProfitAccounting item)
 {
     Manager.updateData(item);
 }
 public void addData(T_ActualProfitAccounting item)
 {
     Manager.addData(item);
 }