Browse Source

给subsite赋值

master
qian 6 days ago
parent
commit
11270b29e9
  1. 4
      WebApiService/src/Win_in.Sfs.Scp.WebApi.Agent/AsnBackgroundWorker/AsnBackgroundWorker.cs
  2. 2
      WebApiService/src/Win_in.Sfs.Scp.WebApi.Agent/appsettings.json
  3. 2
      WebApiService/src/Win_in.Sfs.Scp.WebApi.Application.Contracts/Asns/AsnMstrDTO.cs
  4. 4
      WebApiService/src/Win_in.Sfs.Scp.WebApi.Domain/Asns/X12Asn.cs
  5. 1
      WebApiService/src/Win_in.Sfs.Scp.WebApi.EntityFrameworkCore/DbContext/WebApiDbContextModelCreatingExtensions.cs
  6. 2
      WebApiService/src/Win_in.Sfs.Scp.WebApi.HttpApi.Host/appsettings.json

4
WebApiService/src/Win_in.Sfs.Scp.WebApi.Agent/AsnBackgroundWorker/AsnBackgroundWorker.cs

@ -229,7 +229,7 @@ namespace Win_in.Sfs.Scp.WebApi
var jsonString = JsonSerializer.Serialize(asnMstr);
var ediString = jsonString;
var asnX12 = new X12Asn(asn.Id, asn.Site, asn.AsnBillNum, ScpWebApiConsts.NO_PO_ASN, jsonString, ediString,
asn.ShipTime ?? DateTime.Today);
asn.ShipTime ?? DateTime.Today,asn.WebSubSite);
return asnX12;
}
private static X12Asn CreateX12Asn(AsnOptions.Site site, TB_ASN asn, List<TS_BARCODE> barcodes)
@ -240,7 +240,7 @@ namespace Win_in.Sfs.Scp.WebApi
var jsonString = JsonSerializer.Serialize(asnX128563060);
var ediString = asnX128563060.ToString();
var asnX12 = new X12Asn(asn.Id, asn.Site, asn.AsnBillNum, ScpWebApiConsts.ASN, jsonString, ediString,
asn.ShipTime ?? DateTime.Today);
asn.ShipTime ?? DateTime.Today, asn.WebSubSite);
return asnX12;
}

2
WebApiService/src/Win_in.Sfs.Scp.WebApi.Agent/appsettings.json

@ -59,7 +59,7 @@
"Password": "f0475092-c891-4d36-b2c1-dfd39fa0e436",
"Sites": [
{
"Code": "T8",
"Code": "3015",
"Receiver": "00T8USUPPU",
"MinUid": 1024
}

2
WebApiService/src/Win_in.Sfs.Scp.WebApi.Application.Contracts/Asns/AsnMstrDTO.cs

@ -106,6 +106,8 @@ namespace Win_in.Sfs.Scp.WebApi
/// </summary>
public virtual string Remark { get; set; }
public virtual string Subsite { get; set; }
public virtual List<AsnDetDTO> Details { get; set; } = new List<AsnDetDTO>();
}
}

4
WebApiService/src/Win_in.Sfs.Scp.WebApi.Domain/Asns/X12Asn.cs

@ -84,13 +84,14 @@ public class X12Asn: EntityBase<Guid>
public int RetryTimes { get; protected internal set; } = 0;
public string SubSite { get; set; }
public X12Asn()
{
}
public X12Asn(long uid,string site,string billNum,string dataType,string jsonString,string ediString,DateTime effectiveDate)
public X12Asn(long uid,string site,string billNum,string dataType,string jsonString,string ediString,DateTime effectiveDate,string subsite)
{
UID = uid;
Site = site;
@ -102,6 +103,7 @@ public class X12Asn: EntityBase<Guid>
DestinationSystem = "QAD";
SourceSystem = "SCP";
Writer = "SCP";
SubSite = subsite;
}

1
WebApiService/src/Win_in.Sfs.Scp.WebApi.EntityFrameworkCore/DbContext/WebApiDbContextModelCreatingExtensions.cs

@ -304,6 +304,7 @@ namespace Win_in.Sfs.Scp.WebApi.EntityFrameworkCore
b.Property(q => q.ReadTime);
b.Property(q => q.Reader).HasMaxLength(16);
b.Property(q => q.Remark);
b.Property(q => q.SubSite);
b.HasIndex(q => new { q.Site, q.UID }).IsUnique();
});

2
WebApiService/src/Win_in.Sfs.Scp.WebApi.HttpApi.Host/appsettings.json

@ -88,7 +88,7 @@
"Receiver": "IACNA_ID",
"Sites": [
{
"Code": "T8",
"Code": "3015",
"MinUid": 200
},
{

Loading…
Cancel
Save