예제 #1
0
        protected override void InitData()
        {
            //var suppData = supplierServer.GetSuppler().Select(a => new InputItem { DisPlayName = a.Alias, Value = a.SuppCode, InputCode1 = a.SuppCode }).ToList();
            //SetGridLookUpEdit(SuppCodeTextEdit, suppData, 1);
            //SetGridLookUpEdit(repositoryMatSpec, materialData, 2);
            //SetGridLookUpEdit(repositoryMatClass2, materialData, 2);
            //repositoryMatClass2.DisplayMember = "InputCode3";
            //repositoryMatSpec.DisplayMember = "InputCode2";
            //repositoryMatClass2.ValueMember = "InputCode3";
            //repositoryMatSpec.ValueMember = "InputCode2";
            this.wMSM104PackingHdBindingSource.DataSource = tempData;
            var storeDetailList = packingService.GetDetailList(tempData.Id);

            if (this.Tag.ToString() == BtnCommandEnum.Add)
            {
                tempData.CustCode = "HANA";
                this.wMSM104PackingHdBindingSource.ResetCurrentItem();
                for (int i = 0; i < 10; i++)
                {
                    WMS_M104_Packing_Detail packingDetail = new WMS_M104_Packing_Detail();
                    packingDetail.PackingHdId = tempData.Id;
                    storeDetailList.Add(packingDetail);
                }
            }
            this.wMSM104PackingDetailBindingSource.DataSource = storeDetailList;
        }
예제 #2
0
        public PackingListReport(Guid id)
        {
            InitializeComponent();
            var hd      = packingService.GetById(id);
            var details = packingService.GetDetailList(id);
            int i       = 1;

            details.ForEach(a => { a.SeqNo = i++; });
            hd.SumQty = details.Sum(a => a.Qty);
            this.bindingSource1.DataSource = hd;
            this.bindingSource2.DataSource = details;
        }
예제 #3
0
        void wMSM104PackingHdBindingSource_CurrentChanged(object sender, EventArgs e)
        {
            WMS_M104_Packing_Hd tempData = this.wMSM104PackingHdBindingSource.Current as WMS_M104_Packing_Hd;

            if (tempData != null)
            {
                this.wMSM104PackingDetailBindingSource.DataSource = packingService.GetDetailList(tempData.Id);
            }
            else
            {
                this.wMSM104PackingDetailBindingSource.DataSource = null;
            }
        }