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; using WMS.Frm.Base; using WMS.Model.Base; using WMS.Common; using WMS.Business; using WMS.Business.Base; namespace WMS.FrmRK { public partial class FrmLocSelect : FormBase { string high = ""; public FrmLocSelect(string hgh) { InitializeComponent(); high = hgh; //lb_text.Text = "该批次总共需要" + nullLoct.ToString() + "库位"; } List locModel = new List(); private void FrmLocSelect_Load(object sender, EventArgs e) { locModel= IBussFactory.Instance().GetLocationStatus(high); if (locModel != null) { bdcLoc.DataSource = locModel; } } public string locId = string.Empty; private void gdv_Loc_RowClick(object sender, DevExpress.XtraGrid.Views.Grid.RowClickEventArgs e) { if(gdv_Loc.RowCount>0) { locId = gdv_Loc.GetFocusedRowCellValue("LOCATION_ID").ToString(); } } private void ctrlButtons1_Click(object sender, EventArgs e) { DialogResult = System.Windows.Forms.DialogResult.Cancel; } private void ctrlButtons4_Click(object sender, EventArgs e) { if (locId.Trim().Length == 0) { SystemCommon.ShowInfoMessageBox("Location selectc"); gdv_Loc.FocusedRowHandle = 0; return; } DialogResult = System.Windows.Forms.DialogResult.OK; } } }