Ejemplo n.º 1
0
        private void btnOk_Click(object sender, EventArgs e)
        {
            string reason = this.cboReason.Text.Trim();

            if (reason == string.Empty)
            {
                MessageBox.Show("请选择退款原因...", "系统提示");
                return;
            }
            EntityInvoiceRefundReason vo = new EntityInvoiceRefundReason();

            vo.flagId   = this.flagId;
            vo.invoNo   = this.inVoNo;
            vo.reason   = reason;
            vo.operId   = this.operId;
            vo.operDate = DateTime.Now;
            vo.status   = 1;
            clsDcl_Charge dcl = new clsDcl_Charge();
            int           ret = dcl.SaveInvoiceRefundReason(vo);

            dcl = null;
            if (ret > 0)
            {
                MessageBox.Show("退款原因保存成功!", "系统提示");
                this.DialogResult = DialogResult.OK;
            }
            else
            {
                MessageBox.Show("退款原因保存失败。", "系统提示");
            }
        }
Ejemplo n.º 2
0
        private void frmOPInvoiceReturnReason_Load(object sender, EventArgs e)
        {
            clsDcl_Charge             dcl = new clsDcl_Charge();
            DataTable                 dt  = dcl.GetRefundReasonList(this.flagId);
            EntityInvoiceRefundReason vo  = dcl.GetInvoiceRefundReason(this.flagId, this.inVoNo);

            dcl = null;
            if (dt != null)
            {
                foreach (DataRow dr in dt.Rows)
                {
                    this.cboReason.Items.Add(dr["freason"].ToString());
                }
            }
            if (vo != null)
            {
                this.cboReason.Text = vo.reason;
            }
        }