修改数据

This commit is contained in:
gongxh
2021-12-13 13:37:59 +08:00
parent 257829134f
commit 0317085383
9 changed files with 82 additions and 19 deletions

View File

@@ -7,6 +7,6 @@ namespace NX.ERP.BLL.Model
{ {
public class StoreResult public class StoreResult
{ {
public int ID { get; set; } public string ID { get; set; }
} }
} }

View File

@@ -95,7 +95,7 @@ namespace NX.ERP.BLL.Store
}); });
} }
return new StoreResult() { ID = int.Parse(ID) }; return new StoreResult() { ID =ID};
} }
} }

View File

@@ -96,7 +96,7 @@ namespace NX.ERP.BLL.Store
}); });
} }
return new StoreResult() { ID = int.Parse(ID) }; return new StoreResult() { ID = ID };
} }
} }

View File

@@ -147,5 +147,10 @@ namespace NX.ERP.Model
/// </summary> /// </summary>
public float GrossW { get; set; } public float GrossW { get; set; }
/// <summary>
///
/// </summary>
public string Srpolicy { get; set; }
} }
} }

View File

@@ -31,5 +31,15 @@ namespace NX.ERP.Model.MOM
[Newtonsoft.Json.JsonIgnore] [Newtonsoft.Json.JsonIgnore]
public MomDetail momDetail { get; set; } public MomDetail momDetail { get; set; }
[Newtonsoft.Json.JsonIgnore]
public decimal? iinvexchrate { get; set; }
[Newtonsoft.Json.JsonIgnore]
public string AuxUnitCode { get; set; }
[Newtonsoft.Json.JsonIgnore]
public string Srpolicy { get; set; }
} }
} }

View File

@@ -191,7 +191,7 @@ namespace NX.ERP.U8
// bMPS AS MPS件, // bMPS AS MPS件,
// bROP AS ROP件, // bROP AS ROP件,
// bRePlan AS 是否重复计划, // bRePlan AS 是否重复计划,
// cSRPolicy AS 供需政策, // cSRPolicy AS 供需政策,
// bBillUnite AS 是否令单合并, // bBillUnite AS 是否令单合并,
// iSupplyDay AS 供应期间, // iSupplyDay AS 供应期间,
// fSupplyMulti AS 供应倍数, // fSupplyMulti AS 供应倍数,
@@ -299,9 +299,9 @@ namespace NX.ERP.U8
cInvCCode AS MaterialTypeCode, cInvCCode AS MaterialTypeCode,
bSale AS IsSale, bSale AS IsSale,
bPurchase AS IsPurchase, bPurchase AS IsPurchase,D
bSelf AS IsSelf, bSelf AS IsSelf,
cSRPolicy AS SRPolicy,
bProducing AS IsProducing, bProducing AS IsProducing,
iTaxRate AS TaxRate, iTaxRate AS TaxRate,

View File

@@ -23,7 +23,7 @@ namespace NX.ERP.U8.Mom
string strSQL = @" select a.MoId as ProductOrderId,a.moCode as ProductOrderNo,ISNULL( ModifyDate,createDate) as ModifyDate,CONVERT(BIGINT,a.Ufts) AS pubufts,a.CreateDate as ProductDate,a.CreateUser as PreparedBy, string strSQL = @" select a.MoId as ProductOrderId,a.moCode as ProductOrderNo,ISNULL( ModifyDate,createDate) as ModifyDate,CONVERT(BIGINT,a.Ufts) AS pubufts,a.CreateDate as ProductDate,a.CreateUser as PreparedBy,
b.MoId as id ,b.MoDId as ProductOrderDtlId,b.MoId as ProductOrderId,b.MoTypeId,d.DueDate,b.Remark as Remark,ISNULL( b.MDeptCode,'53') as MDeptCode,a.MoCode as ProductOrderNo, b.MoId as id ,b.MoDId as ProductOrderDtlId,b.MoId as ProductOrderId,b.MoTypeId,d.DueDate,b.Remark as Remark,ISNULL( b.MDeptCode,'53') as MDeptCode,a.MoCode as ProductOrderNo,
a.CreateDate as ProductOrderDate,b.InvCode as ProductCode,b.Qty as Qty,b.QualifiedInQty,b.SortSeq,b.SoCode,b.Status,InvDetail.cInvName as ProductName ,InvDetail.cInvStd ProductSpecsModel, a.CreateDate as ProductOrderDate,b.InvCode as ProductCode,b.Qty as Qty,b.QualifiedInQty,b.SortSeq,b.SoCode,b.Status,InvDetail.cInvName as ProductName ,InvDetail.cInvStd ProductSpecsModel,
c.AllocateId as id ,c.AllocateId as AllocateId,c.MoDId as ProductOrderDtlId,c.InvCode as MaterialCode,InvLocate.cInvName as MaterialName,InvLocate.cInvStd as MaterialSpecsModel,b.MoId as ProductOrderId, c.IssQty as IssQty,c.Qty, c.AllocateId as id ,c.AllocateId as AllocateId,c.MoDId as ProductOrderDtlId,c.ChangeRate as iinvexchrate,c.AuxUnitCode,c.InvCode as MaterialCode,InvLocate.cInvName as MaterialName,InvLocate.cSrpolicy as Srpolicy,InvLocate.cInvStd as MaterialSpecsModel,b.MoId as ProductOrderId, c.IssQty as IssQty,c.Qty,
e.cInvSN as ID e.cInvSN as ID
from mom_order as a from mom_order as a
left join mom_orderdetail as b on a.MoId=b.MoId left join mom_orderdetail as b on a.MoId=b.MoId

View File

@@ -185,7 +185,59 @@ namespace NX.ERP.U8.Store
bodyXml.setAttribute("cvmivencode", ""); bodyXml.setAttribute("cvmivencode", "");
bodyXml.setAttribute("cposition", detail.Position); bodyXml.setAttribute("cposition", detail.Position);
bodyXml.setAttribute("editprop", "A"); bodyXml.setAttribute("editprop", "A");
bodyXml.setAttribute("innum", 10);
//iXMLDOMElement.setAttribute("inquantity", Convert.ToDouble(recordset.Fields["Qty"].Value.ToString()) - Convert.ToDouble(string.IsNullOrEmpty(recordset.Fields["IssQty"].Value.ToString()) ? "0" : recordset.Fields["IssQty"].Value.ToString()));
//if (!string.IsNullOrEmpty(recordset.Fields["iinvexchrate"].Value.ToString()))
//{
// iXMLDOMElement.setAttribute("innum", (Convert.ToDouble(recordset.Fields["Qty"].Value.ToString()) - Convert.ToDouble(string.IsNullOrEmpty(recordset.Fields["IssQty"].Value.ToString()) ? "0" : recordset.Fields["IssQty"].Value.ToString())) / Convert.ToDouble(recordset.Fields["iinvexchrate"].Value.ToString()));
//}
bodyXml.setAttribute("inquantity", alllocate.Qty - alllocate.Issqty);
if (alllocate.iinvexchrate != null && alllocate.iinvexchrate.HasValue && alllocate.iinvexchrate.Value != 0)
{
var _innum = (alllocate.Qty - alllocate.Issqty) / (double)alllocate.iinvexchrate.Value;
bodyXml.setAttribute("innum", _innum);
}
if (alllocate.iinvexchrate.HasValue)
{
bodyXml.setAttribute("inum", detail.Quantity / (double)alllocate.iinvexchrate);
bodyXml.setAttribute("iinvexchrate", alllocate.iinvexchrate);
bodyXml.setAttribute("cassunit", alllocate.AuxUnitCode);
}
//if (csrPolicy.ToUpper() == "PE")
//{
// iXMLDOMElement.setAttribute("ipesotype", "7");
// iXMLDOMElement.setAttribute("cpesocode", recordset.Fields["mocode"].Value.ToString());
// iXMLDOMElement.setAttribute("ipesodid", rdRecords.AutoID.ToString());
// iXMLDOMElement.setAttribute("ipesoseq", recordset.Fields["moseq"].Value.ToString());
//}
//iXMLDOMElement.setAttribute("isotype", recordset.Fields["sotype"].Value.ToString());
//iXMLDOMElement.setAttribute("csocode", recordset.Fields["SoCode"].Value.ToString());
//iXMLDOMElement.setAttribute("isodid", recordset.Fields["SoDId"].Value.ToString());
//iXMLDOMElement.setAttribute("isoseq", recordset.Fields["SoSeq"].Value.ToString());
if (alllocate.Srpolicy=="PE")
{
bodyXml.setAttribute("ipesotype", "7");
bodyXml.setAttribute("cpesocode", storeOut.SourceCode);
bodyXml.setAttribute("ipesodid", detail.SorceDetailId);
bodyXml.setAttribute("ipesoseq", moomDetail.SortSeq);
}
//销售信息
bodyXml.setAttribute("isotype", "");
bodyXml.setAttribute("csocode", "");
bodyXml.setAttribute("isodid", "");
bodyXml.setAttribute("isoseq", "");
//
bodyXml.setAttribute("autoid", storeOut.Id); bodyXml.setAttribute("autoid", storeOut.Id);
bodyXml.setAttribute("id", storeOut.Id); bodyXml.setAttribute("id", storeOut.Id);
bodyXml.setAttribute("impoids", detail.SorceDetailId); bodyXml.setAttribute("impoids", detail.SorceDetailId);
@@ -193,14 +245,10 @@ namespace NX.ERP.U8.Store
bodyXml.setAttribute("invcode", moomDetail.ProductCode);//产品编码 bodyXml.setAttribute("invcode", moomDetail.ProductCode);//产品编码
bodyXml.setAttribute("cwhcode", storeOut.Whcode); bodyXml.setAttribute("cwhcode", storeOut.Whcode);
bodyXml.setAttribute("imoseq", moomDetail.SortSeq); bodyXml.setAttribute("imoseq", moomDetail.SortSeq);
bodyXml.setAttribute("ipesotype", "7");
bodyXml.setAttribute("cpesocode", "");
bodyXml.setAttribute("ipesodid", "");
bodyXml.setAttribute("ipesoseq", "");
bodyXml.setAttribute("isotype", "");
bodyXml.setAttribute("csocode", "");
bodyXml.setAttribute("isodid", "");
bodyXml.setAttribute("isoseq", "");
domBody.selectSingleNode("//rs:data").appendChild(bodyXml); domBody.selectSingleNode("//rs:data").appendChild(bodyXml);
#endregion #endregion
} }
@@ -263,7 +311,7 @@ namespace NX.ERP.U8.Store
if (!string.IsNullOrEmpty(voucherId)) if (!string.IsNullOrEmpty(voucherId))
{ {
var model = this.GetModel(int.Parse(voucherId)); var model = this.GetModel(int.Parse(voucherId));
if (model!=null) if (model != null)
{ {
voucherId = model.Code; voucherId = model.Code;
} }

View File

@@ -6,8 +6,8 @@
<configuration> <configuration>
<appSettings> <appSettings>
<add key="ApiDbName" value="MES_SUBMIT" /> <add key="ApiDbName" value="MES_SUBMIT" />
<add key="server" value="10.0.0.250" /> <add key="server" value="10.0.0.12" />
<add key="AccId" value="u8@887" /> <add key="AccId" value="u8-2@007" />
<add key="UserId" value="wx999" /> <add key="UserId" value="wx999" />
<add key="Password" value="!@#qwe123" /> <add key="Password" value="!@#qwe123" />
<add key="EaiPort" value="80" /> <add key="EaiPort" value="80" />