protected override void OrderConfirm() { try { this.resolver.Input = BusinessConstants.BARCODE_SPECIAL_MARK + BusinessConstants.BARCODE_HEAD_OK; this.resolver.PrintUrl = string.Empty; this.resolver = TheClientMgr.ScanBarcode(this.resolver); if (this.resolver.PrintUrl != null && this.resolver.PrintUrl != string.Empty && this.resolver.NeedPrintAsn) { Utility.PrintOrder(this.resolver.PrintUrl, this, null); } this.lblMessage.Text = this.resolver.Result; InitialAll(); } catch (FaultException ex) { this.lblMessage.Text = Utility.FormatExMessage(ex.Message); MessageBox.Show(this, Utility.FormatExMessage(ex.Message)); this.tbBarCode.Focus(); } catch (Exception ex) { MessageBox.Show(this, ex.Message, "程序内部错误,请与管理员联系", MessageBoxButtons.OK, MessageBoxIcon.Error); InitialAll(); } }
private void ShowHuStatus() { try { this.resolver.Input = this.tbBarCode.Text.Trim(); if (this.resolver.Input != string.Empty) { this.resolver = TheClientMgr.ScanBarcode(this.resolver); if (this.resolver.Transformers != null && this.resolver.Transformers.Length == 1 && this.resolver.Transformers[0].TransformerDetails != null && this.resolver.Transformers[0].TransformerDetails.Length == 1) { TransformerDetail t = this.resolver.Transformers[0].TransformerDetails[0]; string text = "条码信息: \n条码:" + t.HuId + "\n物料代码:" + t.ItemCode + "\n物料描述:" + t.ItemDescription + "\n数量:" + t.Qty.ToString("0.########") + "\n批号:" + t.LotNo + "\n库位:" + t.LocationCode + "\n库格:" + t.StorageBinCode + "\n状态:" + t.Status; string caption = "条码信息:"; MessageBox.Show(this, text, caption, MessageBoxButtons.OK); this.resolver.Transformers[0].TransformerDetails = null; this.tbBarCode.Text = string.Empty; this.tbBarCode.Focus(); } } } catch (FaultException ex) { string messageText = Utility.FormatExMessage(ex.Message); this.lblMessage.Text = messageText; MessageBox.Show(this, messageText); this.InitialAll(); this.gvHuList.Visible = false; this.gvList.Visible = false; this.tbBarCode.Text = string.Empty; } catch (Exception ex) { MessageBox.Show(this, ex.Message, "程序内部错误,请与管理员联系", MessageBoxButtons.OK, MessageBoxIcon.Error); this.InitialAll(); this.gvHuList.Visible = false; this.gvList.Visible = false; this.tbBarCode.Text = string.Empty; } }
private void OrderOffline() { if (!Utility.IsHasTransformer(this.resolver)) { this.lblMessage.Text = "明细不能为空"; this.tbBarCode.Focus(); return; } Utility.RemoveLot(resolver); this.resolver.PrintUrl = string.Empty; this.resolver.Input = BusinessConstants.BARCODE_SPECIAL_MARK + BusinessConstants.BARCODE_HEAD_OK; this.resolver = TheClientMgr.ScanBarcode(this.resolver); if (this.resolver.AutoPrintHu && this.resolver.PrintUrl != null && this.resolver.PrintUrl != string.Empty) { Utility.PrintOrder(this.resolver.PrintUrl, this, null); } this.lblMessage.Text = this.resolver.Result; InitialAll(); }