songnan.zhang 2 years ago
parent
commit
4865d02a4b
  1. 18
      APPQ5/QMAPP.WinForm/Forms/TianJin/TJFrmPlace.cs
  2. 4
      APPQ5/QMAPP.WinForm/Properties/AssemblyInfo.cs

18
APPQ5/QMAPP.WinForm/Forms/TianJin/TJFrmPlace.cs

@ -1230,27 +1230,30 @@ namespace QMAPP.WinForm.Forms.TianJin
var mach = inputstring.Substring(4, inputstring.Length - 4); var mach = inputstring.Substring(4, inputstring.Length - 4);
var plan = new TJOrderPlan(); var plan = new TJOrderPlan();
plan.PID = Guid.NewGuid().ToString();
plan.PLAN_DATE = DateTime.Now; plan.PLAN_DATE = DateTime.Now;
plan.MATERIAL_CODE = mach; plan.QTY = defaultNum/2;
plan.QTY = defaultNum;
if (mach.Substring(0, 3) == "770") if (mach.Substring(0, 3) == "770")
plan.LINENO = "770B"; plan.LINENO = "770B";
else else
plan.LINENO = "018D"; plan.LINENO = "018D";
foreach (var s in "F,R".Split(','))
{
plan.PID = Guid.NewGuid().ToString();
plan.MATERIAL_CODE = mach.Substring(0, mach.Length - 1) + s + mach.Substring(mach.Length - 1,1);
foreach (var rule in _barcodeRules) foreach (var rule in _barcodeRules)
{ {
if (System.Text.RegularExpressions.Regex.IsMatch(mach+"1", rule.REGEX)) if (System.Text.RegularExpressions.Regex.IsMatch(plan.MATERIAL_CODE + "1", rule.REGEX))
{ {
plan.MATERIAL_CODE = rule.MATERIAL_CODE; plan.MATERIAL_CODE = rule.MATERIAL_CODE;
} }
} }
var list = agent.InvokeServiceFunction<List<Materiel>>("TJDoorPlankPlanBLL_GetListMachine", plan.MATERIAL_CODE); //var list = agent.InvokeServiceFunction<List<Materiel>>("TJDoorPlankPlanBLL_GetListMachine", plan.MATERIAL_CODE);
if (list != null) //if (list != null)
plan.MATERIAL_NAME = list[0].MATERIALNAME; // plan.MATERIAL_NAME = list[0].MATERIALNAME;
//QMAPP.ServicesAgent.ServiceAgent agent = ClientContext.GetServiceAgent(); //QMAPP.ServicesAgent.ServiceAgent agent = ClientContext.GetServiceAgent();
var RESULT = agent.InvokeServiceFunction<DataResult<int>>("TJDoorPlankPlanBLL_Insert", plan); var RESULT = agent.InvokeServiceFunction<DataResult<int>>("TJDoorPlankPlanBLL_Insert", plan);
@ -1258,6 +1261,7 @@ namespace QMAPP.WinForm.Forms.TianJin
{ {
agent.InvokeServiceFunction<DataResult<int>>("TJDoorPlankPlanBLL_PutOut", plan.PID); agent.InvokeServiceFunction<DataResult<int>>("TJDoorPlankPlanBLL_PutOut", plan.PID);
} }
}
return; return;
} }
else else

4
APPQ5/QMAPP.WinForm/Properties/AssemblyInfo.cs

@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
// 可以指定所有这些值,也可以使用“内部版本号”和“修订号”的默认值, // 可以指定所有这些值,也可以使用“内部版本号”和“修订号”的默认值,
// 方法是按如下所示使用“*”: // 方法是按如下所示使用“*”:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2022.08.09.01")] [assembly: AssemblyVersion("2022.08.10.01")]
[assembly: AssemblyFileVersion("2022.08.09.01")] [assembly: AssemblyFileVersion("2022.08.10.01")]

Loading…
Cancel
Save