| | |
| | | return; |
| | | } |
| | | var frm = new UcBlclSelect(txt_aboutGuid.GetId(), this.txt_orgId.GetId()); |
| | | |
| | | if (txt_bl017.Text.Trim() == "生产补料") |
| | | { |
| | | frm = new UcBlclSelect(txt_aboutGuid.GetId(), this.txt_orgId.GetId(), txt_bl017.Text.Trim()); |
| | | } |
| | | else |
| | | { |
| | | frm = new UcBlclSelect(txt_aboutGuid.GetId(), this.txt_orgId.GetId()); |
| | | |
| | | } |
| | | //赋值给明细表 |
| | | frm.UpdateParent += (ss, ee) => |
| | | { |
| | |
| | | _row["bld002"] = dym.itemNo;//物料编号 |
| | | _row["bld003"] = dym.itemName;//物料名称 |
| | | _row["bld004"] = dym.itemModel;//规格型号 |
| | | _row["kbsl"] = dym.kbsl; |
| | | _row["dwName"] = dym.dwName; |
| | | _row["dabGuid"] = dym.dabGuid; |
| | | _row["bld013"] = idx.ToString();//项次 |
| | |
| | | gridViews.Add(gvMx1); |
| | | UtilityHelper.CleanValueByControl(this.layoutMx1.Controls, true, gridViews); |
| | | Gs.DevApp.ToolBox.UtilityHelper.SetDefaultTable(gcMx1, gvMx1); |
| | | //增加时,默认组织 |
| | | string deftOrg = UtilityHelper.GetFirstOrg(txt_orgId); |
| | | |
| | | } |
| | | /// <summary> |
| | |
| | | { |
| | | Guid? _guid = UtilityHelper.ToGuid(row["guid"].ToString()); |
| | | string _msl = row["bld007"].ToString(); |
| | | string _kbsl = row["kbsl"].ToString(); |
| | | if (string.IsNullOrEmpty(_msl)) |
| | | { |
| | | MsgHelper.ShowError("数量不能为空!"); |
| | | return; |
| | | } |
| | | |
| | | if (txt_bl017.Text.Trim()=="生产补料") |
| | | { |
| | | if (decimal.TryParse(row["bld007"].ToString(), out decimal msl) && |
| | | decimal.TryParse(row["kbsl"].ToString(), out decimal kbsl)) |
| | | { |
| | | if (msl > kbsl) |
| | | { |
| | | MsgHelper.ShowError("" + |
| | | "申请数量不能大于可补数量!"); |
| | | return; |
| | | } |
| | | } |
| | | else |
| | | { |
| | | // 解析失败的处理 |
| | | MsgHelper.ShowError("" + |
| | | "输入的不是有效数字!"); |
| | | return; |
| | | } |
| | | } |
| | | |
| | | _obj.list.Add(new |
| | | { |
| | | Guid = _guid, |