123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- namespace LYFZ.Software.MainBusiness.MembershipManage.SuperSmallForm
- {
- public partial class PhotographerPaymentSuperSmallForm : LYFZ.Software.UI.MembershipManage.SuperSmallForm.PhotographerPaymentSuperSmallForm
- {
- public PhotographerPaymentSuperSmallForm()
- {
- }
- ///// <summary>
- ///// 是否保存
- ///// </summary>
- //bool IsSaveed = false;
- /// <summary>
- /// 收款金额
- /// </summary>
- public string StrPaymentAoumnt = "";
- /// <summary>
- /// 确定后数据
- /// </summary>
- LYFZ.Software.MainBusiness.MembershipManage.SuperSmallForm.PhotographerPaymentModel model = null;
- /// <summary>
- /// 窗体加载事件
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void PhotographerPaymentSuperSmallForm_Load(object sender, EventArgs e)
- {
- this.txtPaymentItem.Text = "新摄会办理收款";
- this.txtPaymentAoumnt.Text = this.StrPaymentAoumnt;
- LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.BindComboBoxTreeView_PaymentMethod(this.cmbPaymentMethod, false);
- if (!LYFZ.BLL.BLL_ErpUser.GetRights(LYFZ.BLL.BLL_ErpUser.CurrentUserRights.OrdersReceivablesCompetence, LYFZ.CustomAttributes.OperatingAuthority.OrderPaymentMethodSet))
- { this.btnSet.Enabled = false; }
- }
- /// <summary>
- /// 设置
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void btnSet_Click(object sender, EventArgs e)
- {
- LYFZ.Software.MainBusiness.InitialSet.FrmSystemSet frm = new InitialSet.FrmSystemSet();
- frm.TypeName = "BEBACCAFCCEAGAIHH";
- frm.Version = "Version";
- if (frm.ShowDialog() == DialogResult.OK)
- { LYFZ.Software.MainBusiness.DoorCityProcess.PublicCodeClasses.BindComboBoxTreeView_PaymentMethod(this.cmbPaymentMethod); }
- }
- /// <summary>
- /// 收款并打印单据
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void btnPaymentPrintSingle_Click(object sender, EventArgs e)
- {
- if (MessageBoxCustom.Show("您确定要收款吗?", "温馨提示", MessageBoxButtons.OKCancel) == DialogResult.Cancel)
- { return; }
- if (this.cmbPaymentMethod.Text.Trim() == "")
- { MessageBoxCustom.Show("请选择支付方式"); return; }
- model = new PhotographerPaymentModel();
- model.PaymentItem = this.txtPaymentItem.Text.Trim();
- model.PaymentAoumnt = this.txtPaymentAoumnt.Text.Trim();
- model.PaymentMethod = this.cmbPaymentMethod.Tag.ToString().Trim();
- model.IsPrintSingle = true;
- //IsSaveed = true;
- this.Close();
- }
- /// <summary>
- /// 只收款
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void btnPaymentOnly_Click(object sender, EventArgs e)
- {
- if (MessageBoxCustom.Show("您确定要收款吗?", "温馨提示", MessageBoxButtons.OKCancel) == DialogResult.Cancel)
- { return; }
- if (this.cmbPaymentMethod.Text.Trim() == "")
- { MessageBoxCustom.Show("请选择支付方式"); return; }
- model = new PhotographerPaymentModel();
- model.PaymentItem = this.txtPaymentItem.Text.Trim();
- model.PaymentAoumnt = this.txtPaymentAoumnt.Text.Trim();
- model.PaymentMethod = this.cmbPaymentMethod.Tag.ToString().Trim();
- model.IsPrintSingle = false;
- //IsSaveed = true;
- this.Close();
- }
- /// <summary>
- /// 取消
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void btnCancel_Click(object sender, EventArgs e)
- {
- this.Close();
- }
- }
- public class PhotographerPaymentModel
- {
- private string _paymentItem;
- private string _paymentAoumnt;
- private string _paymentMethod;
- private bool _isPrintSingle;
- /// <summary>
- /// 收款项目
- /// </summary>
- public string PaymentItem
- {
- get { return _paymentItem; }
- set { _paymentItem = value; }
- }
- /// <summary>
- /// 收款金额
- /// </summary>
- public string PaymentAoumnt
- {
- get { return _paymentAoumnt; }
- set { _paymentAoumnt = value; }
- }
- /// <summary>
- /// 收款方式
- /// </summary>
- public string PaymentMethod
- {
- get { return _paymentMethod; }
- set { _paymentMethod = value; }
- }
- /// <summary>
- /// 是否打印单据
- /// </summary>
- public bool IsPrintSingle
- {
- get { return _isPrintSingle; }
- set { _isPrintSingle = value; }
- }
- }
- }
|