|
|
@@ -61,21 +61,23 @@ namespace JLHHJSvr.Excutor
|
|
|
var mxlist = mattressHelper.GetMattressMxMtrl(request.mattressid_fu.Value, new List<string>() { "u_mattress_formula.formulatype IN (1)" });
|
|
|
var cwInterfaceList = new List<u_mattress_interface>();
|
|
|
interfaceHelper.AutoSetFormulaTypeOnePz(mxlist, cwInterfaceList);
|
|
|
- interfaceHelper.MattressInterfaceFindERPPz(request.mattressid_fu.Value, cwInterfaceList);
|
|
|
- //
|
|
|
- var cwDict = new Dictionary<int, u_mattress_interface>();
|
|
|
- foreach(var cw in cwInterfaceList)
|
|
|
+ if(cwInterfaceList.Count > 0)
|
|
|
{
|
|
|
- if (cw.erp_pzid > 0 && !cwDict.ContainsKey(cw.erp_pzid.Value)) cwDict.Add(cw.erp_pzid.Value, cw);
|
|
|
- }
|
|
|
- foreach (var copy in copy_list)
|
|
|
- {
|
|
|
- if(cwDict.TryGetValue(copy.erp_pzid.Value,out var mx) && copy.bj_pzname.Contains("床网"))
|
|
|
+ interfaceHelper.MattressInterfaceFindERPPz(request.mattressid_fu.Value, cwInterfaceList);
|
|
|
+ //
|
|
|
+ var cwDict = new Dictionary<int, u_mattress_interface>();
|
|
|
+ foreach (var cw in cwInterfaceList)
|
|
|
{
|
|
|
- copy.bj_namemx = mx.bj_namemx;
|
|
|
+ if (cw.erp_pzid > 0 && !cwDict.ContainsKey(cw.erp_pzid.Value)) cwDict.Add(cw.erp_pzid.Value, cw);
|
|
|
+ }
|
|
|
+ foreach (var copy in copy_list)
|
|
|
+ {
|
|
|
+ if (cwDict.TryGetValue(copy.erp_pzid.Value, out var mx) && copy.bj_pzname.Contains("床网"))
|
|
|
+ {
|
|
|
+ copy.bj_namemx = mx.bj_namemx;
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
} else
|
|
|
{
|
|
|
interfaceHelper.ImportMattressInterfaceList(request.mattressid.Value, copy_list);
|