|
@ -4,36 +4,40 @@ namespace Win_in.Sfs.Scp.WebApi.Asns; |
|
|
|
|
|
|
|
|
public static class ShipNoticeExtensions |
|
|
public static class ShipNoticeExtensions |
|
|
{ |
|
|
{ |
|
|
public static ShipNotice SetST(this ShipNotice shipNotice,string shipNoticeCode) |
|
|
public static ShipNotice SetST(this ShipNotice shipNotice, string shipNoticeCode) |
|
|
{ |
|
|
{ |
|
|
shipNotice.ST = new ST(shipNoticeCode); |
|
|
shipNotice.ST = new ST(shipNoticeCode); |
|
|
return shipNotice; |
|
|
return shipNotice; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public static ShipNotice SetBSN(this ShipNotice shipNotice,string noticeNumber, DateTime datetime, string purpose = "00") |
|
|
public static ShipNotice SetBSN(this ShipNotice shipNotice, string noticeNumber, DateTime datetime, string purpose = "00") |
|
|
{ |
|
|
{ |
|
|
shipNotice.BSN = new BSN(noticeNumber, datetime, purpose); |
|
|
shipNotice.BSN = new BSN(noticeNumber, datetime, purpose); |
|
|
return shipNotice; } |
|
|
return shipNotice; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
public static ShipNotice SetDTM(this ShipNotice shipNotice, DateTime dateTime,string datetimeType="011") |
|
|
public static ShipNotice SetDTM(this ShipNotice shipNotice, DateTime dateTime, string datetimeType = "011") |
|
|
{ |
|
|
{ |
|
|
shipNotice.DTM = new DTM(dateTime, datetimeType); |
|
|
shipNotice.DTM = new DTM(dateTime, datetimeType); |
|
|
return shipNotice;} |
|
|
return shipNotice; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
public static ShipNotice AddShipment(this ShipNotice shipNotice,Shipment shipment) |
|
|
public static ShipNotice AddShipment(this ShipNotice shipNotice, Shipment shipment) |
|
|
{ |
|
|
{ |
|
|
shipNotice.Shipment = shipment; |
|
|
shipNotice.Shipment = shipment; |
|
|
return shipNotice;} |
|
|
return shipNotice; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
public static ShipNotice SetCTT(this ShipNotice shipNotice) |
|
|
public static ShipNotice SetCTT(this ShipNotice shipNotice) |
|
|
{ |
|
|
{ |
|
|
shipNotice.CTT = new CTT(shipNotice.HlCount,shipNotice.HashTotal); |
|
|
shipNotice.CTT = new CTT(shipNotice.HlCount, shipNotice.HashTotal); |
|
|
return shipNotice; |
|
|
return shipNotice; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public static ShipNotice SetSE(this ShipNotice shipNotice, string shipNoticeCode) |
|
|
public static ShipNotice SetSE(this ShipNotice shipNotice, string shipNoticeCode) |
|
|
{ |
|
|
{ |
|
|
shipNotice.SE = new SE(shipNoticeCode,shipNotice.SegmentCount); |
|
|
shipNotice.SE = new SE(shipNoticeCode, shipNotice.SegmentCount); |
|
|
return shipNotice; } |
|
|
return shipNotice; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |