This commit is contained in:
gongxh
2021-03-15 13:34:02 +08:00
parent 01e1f930e9
commit f56c8806e7
14 changed files with 45 additions and 39 deletions

View File

@@ -7,6 +7,7 @@ namespace NX.ERP.BLL.Model
{ {
public class OutBound public class OutBound
{ {
public int Id { get; set; }
public string OutboundNo { get; set; } public string OutboundNo { get; set; }
public DateTime OutboundDate { get; set; } public DateTime OutboundDate { get; set; }
public OutBoundType OutboundType { get; set; } public OutBoundType OutboundType { get; set; }

View File

@@ -18,7 +18,8 @@ namespace NX.ERP.BLL.Store
var dal = new NX.ERP.U8.Store.PuStoreInDAL(); var dal = new NX.ERP.U8.Store.PuStoreInDAL();
ID = dal.AddVocher(new ERP.Model.Request.PuStoreIn() ID = dal.AddVocher(new ERP.Model.Request.PuStoreIn()
{ {
Code = "190700000050", Id = inbound.Id,
Code = inbound.InboundNo,
Date = inbound.InboundDate, Date = inbound.InboundDate,
Source = inbound.SourceName, Source = inbound.SourceName,
SourceCode = inbound.SourceNo, SourceCode = inbound.SourceNo,
@@ -45,9 +46,9 @@ namespace NX.ERP.BLL.Store
var dal = new NX.ERP.U8.Store.ProductInDAL(); var dal = new NX.ERP.U8.Store.ProductInDAL();
ID = dal.AddVoucher(new ERP.Model.Request.ProductStoreIn() ID = dal.AddVoucher(new ERP.Model.Request.ProductStoreIn()
{ {
Code= "19100002",
Id = inbound.Id,
Code = inbound.InboundNo,
Date = inbound.InboundDate, Date = inbound.InboundDate,
Source = inbound.SourceName, Source = inbound.SourceName,
SourceCode = inbound.SourceNo, SourceCode = inbound.SourceNo,
@@ -72,7 +73,8 @@ namespace NX.ERP.BLL.Store
var dal = new NX.ERP.U8.Store.OtherStoreInDAL(); var dal = new NX.ERP.U8.Store.OtherStoreInDAL();
ID = dal.AddVocher(new ERP.Model.Request.OtherStoreInOut() ID = dal.AddVocher(new ERP.Model.Request.OtherStoreInOut()
{ {
Code= "19100028", Id = inbound.Id,
Code = inbound.InboundNo,
Date = inbound.InboundDate, Date = inbound.InboundDate,
WhCode = inbound.WarehouseCode, WhCode = inbound.WarehouseCode,
Maker = inbound.Maker, Maker = inbound.Maker,
@@ -90,7 +92,7 @@ namespace NX.ERP.BLL.Store
}); });
} }
return new StoreResult() { ID = int.Parse( ID) }; return new StoreResult() { ID = int.Parse(ID) };
} }
} }

View File

@@ -17,7 +17,8 @@ namespace NX.ERP.BLL.Store
var dal = new U8.Store.MaterialStoreOutDAL(); var dal = new U8.Store.MaterialStoreOutDAL();
ID = dal.AddVocher(new ERP.Model.Request.MaterialStoreOut() ID = dal.AddVocher(new ERP.Model.Request.MaterialStoreOut()
{ {
Code= "191000000007", Id = outBound.Id,
Code = outBound.OutboundNo,
Date = outBound.OutboundDate, Date = outBound.OutboundDate,
Maker = outBound.Maker, Maker = outBound.Maker,
Source = outBound.SourceName, Source = outBound.SourceName,
@@ -44,7 +45,8 @@ namespace NX.ERP.BLL.Store
var dal = new U8.Store.SaleOutDAL(); var dal = new U8.Store.SaleOutDAL();
ID = dal.AddVoucher(new ERP.Model.Request.SaleStoreOut() ID = dal.AddVoucher(new ERP.Model.Request.SaleStoreOut()
{ {
Code = "191000000003", Id = outBound.Id,
Code = outBound.OutboundNo,
Date = outBound.OutboundDate, Date = outBound.OutboundDate,
WhCode = outBound.WarehouseCode, WhCode = outBound.WarehouseCode,
Source = outBound.SourceName, Source = outBound.SourceName,
@@ -70,7 +72,8 @@ namespace NX.ERP.BLL.Store
{ {
Date = outBound.OutboundDate, Date = outBound.OutboundDate,
WhCode = outBound.WarehouseCode, WhCode = outBound.WarehouseCode,
Code= "19100032", Id = outBound.Id,
Code = outBound.OutboundNo,
Maker = outBound.Maker, Maker = outBound.Maker,
details = outBound.OutboundDtlLst.ConvertAll(m => details = outBound.OutboundDtlLst.ConvertAll(m =>
{ {

View File

@@ -7,6 +7,7 @@ namespace NX.ERP.Model.Request
{ {
public class OtherStoreInOut public class OtherStoreInOut
{ {
public int Id { get; set; }
public string Code { get; set; } public string Code { get; set; }
public DateTime Date { get; set; } public DateTime Date { get; set; }
public string WhCode { get; set; } public string WhCode { get; set; }

View File

@@ -7,6 +7,8 @@ namespace NX.ERP.Model.Request
{ {
public class ProductStoreIn: BaseModel public class ProductStoreIn: BaseModel
{ {
public int Id { get; set; }
public string Code { get; set; } public string Code { get; set; }
public string Maker { get; set; } public string Maker { get; set; }
public string Deptcode { get; set; } public string Deptcode { get; set; }

View File

@@ -7,6 +7,7 @@ namespace NX.ERP.Model.Request
{ {
public class SaleStoreOut public class SaleStoreOut
{ {
public int Id { get; set; }
public string Code { get; set; } public string Code { get; set; }
public string Source { get; set; } public string Source { get; set; }
public string SourceCode { get; set; } public string SourceCode { get; set; }

View File

@@ -142,11 +142,9 @@ namespace NX.ERP.U8.Store
public bool UpdateVocher(Model.Request.MaterialStoreOut storeOut) public bool UpdateVocher(Model.Request.MaterialStoreOut storeOut)
{ {
VoucherParameter voucherParameter = this.LoadVoucher($"cCode='{storeOut.Code}'"); VoucherParameter voucherParameter = this.LoadVoucher($"Id='{storeOut.Id}'");
DOMDocument domBody = voucherParameter.DomBody; DOMDocument domBody = voucherParameter.DomBody;
if (storeOut.Source == "生产订单") if (storeOut.Source == "生产订单")
{ {

View File

@@ -98,7 +98,7 @@ namespace NX.ERP.U8.Store
public bool UpdateVocher(Model.Request.OtherStoreInOut storeIn) public bool UpdateVocher(Model.Request.OtherStoreInOut storeIn)
{ {
var voucherParameter = base.LoadVoucher($" cCode={storeIn.Code}"); var voucherParameter = base.LoadVoucher($" id={storeIn.Id}");
DOMDocument domBody = voucherParameter.DomBody; DOMDocument domBody = voucherParameter.DomBody;
for (var n = 0; n < storeIn.details.Count(); n++) for (var n = 0; n < storeIn.details.Count(); n++)

View File

@@ -97,7 +97,7 @@ namespace NX.ERP.U8.Store
{ {
VoucherParameter voucherParameter = this.LoadVoucher($"cCode='{storeIn.Code}'"); VoucherParameter voucherParameter = this.LoadVoucher($"id='{storeIn.Id}'");

View File

@@ -87,7 +87,7 @@ namespace NX.ERP.U8.Store
public bool UpdateVoucher(ProductStoreIn storeIn) public bool UpdateVoucher(ProductStoreIn storeIn)
{ {
var voucherParameter = this.LoadVoucher($"cCode='{storeIn.Code}'"); var voucherParameter = this.LoadVoucher($"id='{storeIn.Id}'");
DOMDocument domBody = voucherParameter.DomBody; DOMDocument domBody = voucherParameter.DomBody;

View File

@@ -140,7 +140,7 @@ namespace NX.ERP.U8.Store
{ {
try try
{ {
var voucherParameter = this.LoadVoucher($"cCode='{puStoreIn.Code}'"); var voucherParameter = this.LoadVoucher($"id='{puStoreIn.Id}'");
//添加一條 //添加一條
DOMDocument domBody = voucherParameter.DomBody; DOMDocument domBody = voucherParameter.DomBody;
if (puStoreIn.Source == "采购到货单") if (puStoreIn.Source == "采购到货单")

View File

@@ -102,7 +102,7 @@ namespace NX.ERP.U8.Store
public bool UpdateVoucher(SaleStoreOut storeOut) public bool UpdateVoucher(SaleStoreOut storeOut)
{ {
VoucherParameter voucherParameter = this.LoadVoucher($"cCode='{storeOut.Code}'"); VoucherParameter voucherParameter = this.LoadVoucher($"id='{storeOut.Id}'");

View File

@@ -53,8 +53,6 @@ namespace NX.ERP.U8
{ {
get get
{ {
if (this._clslogin == null) if (this._clslogin == null)
{ {
lock (locker1) lock (locker1)

View File

@@ -7,7 +7,7 @@
<appSettings> <appSettings>
<add key="server" value="10.0.0.12"/> <add key="server" value="10.0.0.12"/>
<add key="AccId" value="u8-2@001"/> <add key="AccId" value="u8-2@001"/>
<add key="UserId" value="wx993"/> <add key="UserId" value="wx997"/>
<add key="Password" value="1"/> <add key="Password" value="1"/>
<add key="EaiPort" value="80"/> <add key="EaiPort" value="80"/>
<add key="EaiPath" value="U8EAI/import.asp" /> <add key="EaiPath" value="U8EAI/import.asp" />