Beispiel #1
0
        public ApplyUseOrderInfoForm(T_ApplyUseOrder applyUseOrder)
        {
            InitializeComponent();
            base.formmode = frmmodetype.edit;
            this.ApplyUseOrder = applyUseOrder;

            this.okButton.Enabled = false;
        }
Beispiel #2
0
 public void AddApplyUseOrder(T_ApplyUseOrder applyUseOrder)
 {
     applyUseOrder.ApplyUseDate = DateTime.Now.ToString("yyyy-MM-dd");
     ApplyUseOrderList.Add(applyUseOrder);
 }
Beispiel #3
0
 public void UpdateAddApplyUseOrder(T_ApplyUseOrder applyUseOrder)
 {
     ApplyUseOrderList.Remove(ApplyUseOrderList.Find(o => o.ApplyUseNo == applyUseOrder.ApplyUseNo));
     ApplyUseOrderList.Add(applyUseOrder);
 }
Beispiel #4
0
        protected override void FormLoad()
        {
            this.ApplyUseTypeComboBox.DataSource = EnumTool.GetDataSource(typeof(Enums.ApplyUseTypes));
            this.ApplyUseTypeComboBox.SelectedIndex = 1;
            this.UserComboBox.DataSource = proxy.GetEmployees();
            this.ApplicantComboBox.DataSource = proxy.GetEmployees();
            this.ApplyDeptComboBox.DataSource = proxy.GetAllDepts();

            this.gvUnitEdit.DataSource = proxy.GetUnitList();

            if (formmode == frmmodetype.add)
            {
                ApplyUseOrder = new T_ApplyUseOrder()
                {
                    ApplyUseNo = proxy.GetLatestApplyUseOrderIndex(),
                    Register = Global.UserNo,
                    RegisterDesc = Global.UserName
                };

                _ApplyUseOrderDetails = new List<T_ApplyUseOrderDetail>();
            }
            else
            {
                _ApplyUseOrderDetails = proxy.GetApplyUserOrderDetails(ApplyUseOrder.ApplyUseNo);
            }

            SetData();
        }
Beispiel #5
0
 public ApplyUseOrderInfoForm(frmmodetype type, T_ApplyUseOrder applyUseOrder)
 {
     InitializeComponent();
     base.formmode = type;
     this.ApplyUseOrder = applyUseOrder;
 }