You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
119 lines
3.6 KiB
119 lines
3.6 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using Win_in.Sfs.Scp.v1.Domain.Asns;
|
|
using Win_in.Sfs.Scp.WebApi;
|
|
|
|
namespace Win_in.Sfs.Scp.WebApi.Console
|
|
{
|
|
internal class Program
|
|
{
|
|
static void Main(string[] args)
|
|
{
|
|
|
|
var asnFactory = new AsnFactory();
|
|
var scpAsn = InitTbAsn();
|
|
var barcodes = InitTsBarcodes();
|
|
var asn = asnFactory.CreateAsnX128563060("IACNA_ID", scpAsn, barcodes);
|
|
var ediString = asn.ToString();
|
|
System.Console.WriteLine(ediString);
|
|
System.Console.Read();
|
|
}
|
|
|
|
private static List<TS_BARCODE> InitTsBarcodes()
|
|
{
|
|
var barcodes = new List<TS_BARCODE>()
|
|
{
|
|
new TS_BARCODE()
|
|
{
|
|
BarCode = "BARCODE_01",
|
|
PartCode = "PART_A",
|
|
Qty=20,
|
|
Batch="20220404",
|
|
PoUnit = "EA",
|
|
PoBillNum = "PO1111",
|
|
PackQty = 20,
|
|
Extend2 = "PALLET_01"
|
|
},
|
|
new TS_BARCODE()
|
|
{
|
|
BarCode = "BARCODE_02",
|
|
PartCode = "PART_A",
|
|
Qty=20,
|
|
Batch="20220404",
|
|
PoUnit = "EA",
|
|
PoBillNum = "PO1111",
|
|
PackQty = 20,
|
|
Extend2 = "PALLET_01"
|
|
},
|
|
new TS_BARCODE()
|
|
{
|
|
BarCode = "BARCODE_03",
|
|
PartCode = "PART_B",
|
|
Qty=15,
|
|
Batch="20220404",
|
|
PoUnit = "EA",
|
|
PoBillNum = "PO2222",
|
|
PackQty = 15,
|
|
Extend2 = "PALLET_01"
|
|
},
|
|
new TS_BARCODE()
|
|
{
|
|
BarCode = "BARCODE_04",
|
|
PartCode = "PART_B",
|
|
Qty=15,
|
|
Batch="20220404",
|
|
PoUnit = "EA",
|
|
PoBillNum = "PO2222",
|
|
PackQty = 15,
|
|
Extend2 = "PALLET_01"
|
|
},
|
|
new TS_BARCODE()
|
|
{
|
|
BarCode = "BARCODE_05",
|
|
PartCode = "PART_C",
|
|
Qty=40,
|
|
Batch="20220404",
|
|
PoUnit = "KG",
|
|
PoBillNum = "PO3333",
|
|
PackQty = 40,
|
|
Extend2 = "PALLET_02"
|
|
},
|
|
new TS_BARCODE()
|
|
{
|
|
BarCode = "BARCODE_06",
|
|
PartCode = "PART_C",
|
|
Qty=40,
|
|
Batch="20220404",
|
|
PoUnit = "KG",
|
|
PoBillNum = "PO3333",
|
|
PackQty = 40,
|
|
Extend2 = "PALLET_02"
|
|
},
|
|
new TS_BARCODE()
|
|
{
|
|
BarCode = "BARCODE_07",
|
|
PartCode = "PART_C",
|
|
Qty=40,
|
|
Batch="20220404",
|
|
PoUnit = "KG",
|
|
PoBillNum = "PO3333",
|
|
PackQty = 23,
|
|
Extend2 = ""
|
|
},
|
|
};
|
|
return barcodes;
|
|
}
|
|
|
|
private static TB_ASN InitTbAsn()
|
|
{
|
|
var scpAsn = new TB_ASN()
|
|
{
|
|
AsnBillNum = "ASN123456",
|
|
VendId = "VENDOR_ID",
|
|
ShipTime = DateTime.Now,
|
|
|
|
};
|
|
return scpAsn;
|
|
}
|
|
}
|
|
}
|
|
|