Search Results for

    Show / Hide Table of Contents

    Class ShipmentManager

    Manager to work with shipments

    Inheritance
    System.Object
    ShipmentManager
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Simplic.PlugIn.Logistics.Disposition
    Assembly: Simplic.PlugIn.Logistics.dll
    Syntax
    public class ShipmentManager

    Constructors

    | Improve this Doc View Source

    ShipmentManager()

    Initialize new shipment manager

    Declaration
    public ShipmentManager()

    Fields

    | Improve this Doc View Source

    DistancebasedItem

    Declaration
    public const string DistancebasedItem = "20136981-311b-4963-a18c-4433838a8cbd"
    Field Value
    Type Description
    System.String
    | Improve this Doc View Source

    FixedpriceItem

    Declaration
    public const string FixedpriceItem = "5a8ff039-1f37-48b5-b034-910e3f848d78"
    Field Value
    Type Description
    System.String
    | Improve this Doc View Source

    LoadingAidbasedItem

    Declaration
    public const string LoadingAidbasedItem = "8AEFF9F6-1A14-4B92-BD31-56B841F6289D"
    Field Value
    Type Description
    System.String
    | Improve this Doc View Source

    ObjectbasedItem

    Declaration
    public const string ObjectbasedItem = "c8178b9b-689b-4755-b264-6bbbd476d160"
    Field Value
    Type Description
    System.String
    | Improve this Doc View Source

    PythonbasedItem

    Declaration
    public const string PythonbasedItem = "5599ef91-a91b-44f5-9cd4-4cd2b59ec54d"
    Field Value
    Type Description
    System.String
    | Improve this Doc View Source

    TariffbasedItem

    Declaration
    public const string TariffbasedItem = "2244ea00-3b8c-4427-942c-d5ae7207cbd3"
    Field Value
    Type Description
    System.String
    | Improve this Doc View Source

    TimebasedItem

    Declaration
    public const string TimebasedItem = "9f77b1ed-7083-477f-b1e7-5770139afe1d"
    Field Value
    Type Description
    System.String
    | Improve this Doc View Source

    WeightbasedItem

    Declaration
    public const string WeightbasedItem = "f2984102-90ca-4e55-8ad4-4bbac84808dd"
    Field Value
    Type Description
    System.String

    Properties

    | Improve this Doc View Source

    ItemDefinition

    Gets or sets a dictionary of item constructor

    Declaration
    public static IList<ShipmentItemConstructor> ItemDefinition { get; }
    Property Value
    Type Description
    System.Collections.Generic.IList<ShipmentItemConstructor>
    | Improve this Doc View Source

    OutgoingTypeList

    Contains all outgoing transaction types

    Declaration
    public static IDictionary<string, Guid> OutgoingTypeList { get; }
    Property Value
    Type Description
    System.Collections.Generic.IDictionary<System.String, System.Guid>
    | Improve this Doc View Source

    Singleton

    Gets an instance of the shipment manager

    Declaration
    public static ShipmentManager Singleton { get; }
    Property Value
    Type Description
    ShipmentManager

    Methods

    | Improve this Doc View Source

    AddItemDefinition<T>(Guid, Func<T>)

    Add new item definitiom

    Declaration
    public static void AddItemDefinition<T>(Guid id, Func<T> constructor)
        where T : ShipmentItem
    Parameters
    Type Name Description
    System.Guid id

    Item type id

    System.Func<T> constructor

    Delegate to create an item

    Type Parameters
    Name Description
    T

    Shipment item type

    | Improve this Doc View Source

    CanDeleteShipment(Shipment)

    Gets whether the shipment can be deleted.

    Declaration
    public bool CanDeleteShipment(Shipment shipment)
    Parameters
    Type Name Description
    Shipment shipment

    Shipment to get whether it can be deleted or not

    Returns
    Type Description
    System.Boolean

    True if the shipment can be deleted, else false

    | Improve this Doc View Source

    CreateNewItem(Guid, Shipment)

    Create new shipment item by id

    Declaration
    public static ShipmentItem CreateNewItem(Guid typeId, Shipment shipment)
    Parameters
    Type Name Description
    System.Guid typeId
    Shipment shipment
    Returns
    Type Description
    ShipmentItem

    Shipment item instance if id is part of the item map

    | Improve this Doc View Source

    CreateShipmentFromTranship(TranshipPartialShipment, Shipment, Boolean, Nullable<DateTime>)

    Creates a shipment from a tranship

    Declaration
    public Shipment CreateShipmentFromTranship(TranshipPartialShipment tranship, Shipment parentShipment, bool save, DateTime? startDate)
    Parameters
    Type Name Description
    TranshipPartialShipment tranship
    Shipment parentShipment
    System.Boolean save
    System.Nullable<System.DateTime> startDate
    Returns
    Type Description
    Shipment
    | Improve this Doc View Source

    CreateShipmentFromTranship(Guid, Nullable<DateTime>)

    Creates a shipment from a tranship

    Declaration
    public Shipment CreateShipmentFromTranship(Guid transhipId, DateTime? startDate)
    Parameters
    Type Name Description
    System.Guid transhipId
    System.Nullable<System.DateTime> startDate
    Returns
    Type Description
    Shipment
    | Improve this Doc View Source

    CreateShipmentFromTranship(String, Nullable<DateTime>)

    Creates a shipment from a tranship

    Declaration
    public Shipment CreateShipmentFromTranship(string partialShipmentNr, DateTime? startDate)
    Parameters
    Type Name Description
    System.String partialShipmentNr
    System.Nullable<System.DateTime> startDate
    Returns
    Type Description
    Shipment
    | Improve this Doc View Source

    Delete(Shipment, Boolean, Boolean)

    Delete a shipment

    Declaration
    public void Delete(Shipment shipment, bool isSoftDelete = true, bool uploadCloud = true)
    Parameters
    Type Name Description
    Shipment shipment

    Shipment instance

    System.Boolean isSoftDelete

    If is softdelete, only the delete flag will be set

    System.Boolean uploadCloud
    | Improve this Doc View Source

    DeleteAsync(Shipment, Boolean, Boolean)

    Delete a shipment async

    Declaration
    public async Task DeleteAsync(Shipment shipment, bool isSoftDelete = true, bool uploadCloud = true)
    Parameters
    Type Name Description
    Shipment shipment

    Shipment instance

    System.Boolean isSoftDelete

    If is softdelete, only the delete flag will be set

    System.Boolean uploadCloud
    Returns
    Type Description
    System.Threading.Tasks.Task
    | Improve this Doc View Source

    DeleteById(Guid, Boolean, Boolean)

    Delete a shipment by its id

    Declaration
    public void DeleteById(Guid id, bool isSoftDelete = true, bool uploadCloud = true)
    Parameters
    Type Name Description
    System.Guid id

    Unique shipment id

    System.Boolean isSoftDelete

    If is softdelete, only the delete flag will be set

    System.Boolean uploadCloud
    | Improve this Doc View Source

    DeleteByIdAsync(Guid, Boolean, Boolean)

    Delete a shipment by its id async

    Declaration
    public async Task DeleteByIdAsync(Guid id, bool isSoftDelete = true, bool uploadCloud = true)
    Parameters
    Type Name Description
    System.Guid id

    Unique shipment id

    System.Boolean isSoftDelete

    If is softdelete, only the delete flag will be set

    System.Boolean uploadCloud
    Returns
    Type Description
    System.Threading.Tasks.Task
    | Improve this Doc View Source

    DeleteItem(SAConnection, ShipmentItem)

    Declaration
    public void DeleteItem(SAConnection connection, ShipmentItem item)
    Parameters
    Type Name Description
    SAConnection connection
    ShipmentItem item
    | Improve this Doc View Source

    DeleteWeightNote(Guid)

    Remove a weight note by its id

    Declaration
    public void DeleteWeightNote(Guid id)
    Parameters
    Type Name Description
    System.Guid id

    Unique id of the weight note

    | Improve this Doc View Source

    Get(Guid)

    Gets a shipment by its id

    Declaration
    public Shipment Get(Guid id)
    Parameters
    Type Name Description
    System.Guid id

    Unique shipment id

    Returns
    Type Description
    Shipment

    Shipment instance if existing, else null

    | Improve this Doc View Source

    GetAll()

    Gets all shipment

    Declaration
    public IEnumerable<Shipment> GetAll()
    Returns
    Type Description
    System.Collections.Generic.IEnumerable<Shipment>

    Shipment instances

    | Improve this Doc View Source

    GetAsync(Guid)

    Gets a shipment by its id async

    Declaration
    public async Task<Shipment> GetAsync(Guid id)
    Parameters
    Type Name Description
    System.Guid id

    Unique shipment id

    Returns
    Type Description
    System.Threading.Tasks.Task<Shipment>

    Shipment instance if existing, else null

    | Improve this Doc View Source

    GetBySplitParentId(Guid)

    Get shipments by split parent id

    Declaration
    public IEnumerable<Shipment> GetBySplitParentId(Guid splitParentId)
    Parameters
    Type Name Description
    System.Guid splitParentId

    Split parent shipment id

    Returns
    Type Description
    System.Collections.Generic.IEnumerable<Shipment>

    Enumerable of shipments

    | Improve this Doc View Source

    GetByTransportOrder(Guid)

    Gets a list of shipments by its transport order id

    Declaration
    public IEnumerable<Shipment> GetByTransportOrder(Guid transportOrderId)
    Parameters
    Type Name Description
    System.Guid transportOrderId
    Returns
    Type Description
    System.Collections.Generic.IEnumerable<Shipment>

    Shipment instance if existing, else null

    | Improve this Doc View Source

    GetDefaultItemStatus()

    Declaration
    public ShipmentItemStatus GetDefaultItemStatus()
    Returns
    Type Description
    ShipmentItemStatus
    | Improve this Doc View Source

    GetItem(Guid)

    Load a single shipment item

    Declaration
    public ShipmentItem GetItem(Guid shipmentItemId)
    Parameters
    Type Name Description
    System.Guid shipmentItemId

    Unique shipment item id

    Returns
    Type Description
    ShipmentItem

    Shipment item instance

    | Improve this Doc View Source

    GetItems(Shipment)

    Load all shipment items that belongs to a shipment

    Declaration
    public IEnumerable<ShipmentItem> GetItems(Shipment shipment)
    Parameters
    Type Name Description
    Shipment shipment
    Returns
    Type Description
    System.Collections.Generic.IEnumerable<ShipmentItem>

    Enumerable if shipment-items

    | Improve this Doc View Source

    GetItemsAsync(Shipment)

    Load all shipment items that belongs to a shipment

    Declaration
    public async Task<IList<ShipmentItem>> GetItemsAsync(Shipment shipment)
    Parameters
    Type Name Description
    Shipment shipment
    Returns
    Type Description
    System.Threading.Tasks.Task<System.Collections.Generic.IList<ShipmentItem>>

    Enumerable if shipment-items

    | Improve this Doc View Source

    GetItemStatus(Guid)

    Get a item status by Id

    Declaration
    public ShipmentItemStatus GetItemStatus(Guid id)
    Parameters
    Type Name Description
    System.Guid id
    Returns
    Type Description
    ShipmentItemStatus
    | Improve this Doc View Source

    GetItemStatusList()

    get a list of all item status

    Declaration
    public IList<ShipmentItemStatus> GetItemStatusList()
    Returns
    Type Description
    System.Collections.Generic.IList<ShipmentItemStatus>
    | Improve this Doc View Source

    GetItemType(Guid)

    Declaration
    public ShipmentItemType GetItemType(Guid id)
    Parameters
    Type Name Description
    System.Guid id
    Returns
    Type Description
    ShipmentItemType
    | Improve this Doc View Source

    GetItemTypes()

    Declaration
    public IEnumerable<ShipmentItemType> GetItemTypes()
    Returns
    Type Description
    System.Collections.Generic.IEnumerable<ShipmentItemType>
    | Improve this Doc View Source

    GetSchedulerShipmentsAsync(DateTime, DateTime, Boolean)

    Load shipments to show in the scheduler

    Declaration
    public async Task<IList<Shipment>> GetSchedulerShipmentsAsync(DateTime fromDate, DateTime toDate, bool useActualDateTimeData)
    Parameters
    Type Name Description
    System.DateTime fromDate
    System.DateTime toDate
    System.Boolean useActualDateTimeData
    Returns
    Type Description
    System.Threading.Tasks.Task<System.Collections.Generic.IList<Shipment>>
    | Improve this Doc View Source

    GetStatus(Guid)

    Get a status by Id

    Declaration
    public ShipmentStatus GetStatus(Guid id)
    Parameters
    Type Name Description
    System.Guid id
    Returns
    Type Description
    ShipmentStatus
    | Improve this Doc View Source

    GetStatusList()

    get a list of all status

    Declaration
    public IList<ShipmentStatus> GetStatusList()
    Returns
    Type Description
    System.Collections.Generic.IList<ShipmentStatus>
    | Improve this Doc View Source

    GetUnassignedShipments(DateTime, DateTime)

    Get a list of shipments that are not assigned to a tour and are not deleted

    Declaration
    public IEnumerable<Shipment> GetUnassignedShipments(DateTime from = default(DateTime), DateTime to = default(DateTime))
    Parameters
    Type Name Description
    System.DateTime from

    Tour from load datetime

    System.DateTime to

    Tour to unload datetime

    Returns
    Type Description
    System.Collections.Generic.IEnumerable<Shipment>

    Enumerable of shipments

    | Improve this Doc View Source

    GetWeightNotesByItemId(Guid)

    Gets the weightnotes to the position

    Declaration
    public IEnumerable<ShipmentWeightNote> GetWeightNotesByItemId(Guid id)
    Parameters
    Type Name Description
    System.Guid id
    Returns
    Type Description
    System.Collections.Generic.IEnumerable<ShipmentWeightNote>

    A list of weight notes

    | Improve this Doc View Source

    PostProcessShipment(IList<Shipment>, Boolean, Boolean, Boolean, Action<Shipment>)

    Set shipment on tour and post process shipment, like status, ...

    Declaration
    public void PostProcessShipment(IList<Shipment> shipments, bool setTransportOrderStatus, bool calculateTourTotals, bool uploadCloud, Action<Shipment> shipmentCompleted = null)
    Parameters
    Type Name Description
    System.Collections.Generic.IList<Shipment> shipments

    ShiList of shipments

    System.Boolean setTransportOrderStatus

    If set to true, the transport order status will be set to

    System.Boolean calculateTourTotals

    If set to true, tour totals will be calculated

    System.Boolean uploadCloud

    If set to true all tours will uploaded to tour

    System.Action<Shipment> shipmentCompleted

    Called whenever a shipment is completed

    | Improve this Doc View Source

    Save(Shipment)

    Writes shipment to database

    Declaration
    public void Save(Shipment shipment)
    Parameters
    Type Name Description
    Shipment shipment

    selected shipment

    | Improve this Doc View Source

    SaveItem(SAConnection, ShipmentItem, Type)

    Save a list of shipment items

    Declaration
    public int SaveItem(SAConnection connection, ShipmentItem item, Type t)
    Parameters
    Type Name Description
    SAConnection connection

    SA Connection

    ShipmentItem item

    Item to save

    System.Type t
    Returns
    Type Description
    System.Int32

    Amound of affected data

    | Improve this Doc View Source

    SaveItemType(ShipmentItemType)

    Save a ShipmentItemType

    Declaration
    public void SaveItemType(ShipmentItemType obj)
    Parameters
    Type Name Description
    ShipmentItemType obj

    Object to save

    | Improve this Doc View Source

    SaveStatus(ShipmentStatus)

    Writes a status to the database

    Declaration
    public void SaveStatus(ShipmentStatus status)
    Parameters
    Type Name Description
    ShipmentStatus status
    | Improve this Doc View Source

    SaveWeightNote(ShipmentWeightNote)

    Saves the weight note

    Declaration
    public void SaveWeightNote(ShipmentWeightNote obj)
    Parameters
    Type Name Description
    ShipmentWeightNote obj

    Weight note to save

    | Improve this Doc View Source

    Set(Shipment, Boolean, Boolean, Boolean, Boolean)

    Create or update a shipment

    Declaration
    public Shipment Set(Shipment shipment, bool save = true, bool setTransportOrderStatus = true, bool postProcessShipments = true, bool uploadCloud = true)
    Parameters
    Type Name Description
    Shipment shipment

    Unique shipment id

    System.Boolean save

    If set to true, the data will be saved to the database

    System.Boolean setTransportOrderStatus

    If set to true, the transport order status will be calculated

    System.Boolean postProcessShipments

    If set to true, the post process shipment method will be called

    System.Boolean uploadCloud

    If set to true the shipment and all tours will be uploaded to tour

    Returns
    Type Description
    Shipment

    Shipment which enriched with data

    | Improve this Doc View Source

    SetHasBillableShipmentCarrier(Guid, Boolean)

    Sets the HasBillableShipmentCarrier flag state

    Declaration
    public void SetHasBillableShipmentCarrier(Guid shipmentId, bool state)
    Parameters
    Type Name Description
    System.Guid shipmentId
    System.Boolean state
    | Improve this Doc View Source

    SetHasBillableShipmentCustomer(Guid, Boolean)

    Sets the HasBillableShipmentCustomer flag state

    Declaration
    public void SetHasBillableShipmentCustomer(Guid shipmentId, bool state)
    Parameters
    Type Name Description
    System.Guid shipmentId
    System.Boolean state
    | Improve this Doc View Source

    SetProgressData(Shipment)

    Set progress values of a shipment object

    Declaration
    public void SetProgressData(Shipment shipment)
    Parameters
    Type Name Description
    Shipment shipment

    Shipment instance

    | Improve this Doc View Source

    ShipmentHasTour(Guid)

    Returns whether a shipment has a tour

    Declaration
    public bool ShipmentHasTour(Guid shipmentId)
    Parameters
    Type Name Description
    System.Guid shipmentId

    Unique shipment id

    Returns
    Type Description
    System.Boolean

    True if a shipment has a tour

    | Improve this Doc View Source

    StopTranship(IList<Shipment>, Boolean)

    Declaration
    public void StopTranship(IList<Shipment> shipments, bool removeCustomerQuantity)
    Parameters
    Type Name Description
    System.Collections.Generic.IList<Shipment> shipments
    System.Boolean removeCustomerQuantity
    | Improve this Doc View Source

    UpdateContainerLocationByShipment(Shipment)

    Updates the ContainerLocation absed on all shipent items

    Declaration
    public void UpdateContainerLocationByShipment(Shipment shipment)
    Parameters
    Type Name Description
    Shipment shipment
    | Improve this Doc View Source

    ValidateShipmentItemsIndex(Shipment)

    Validate the sortindex of the shipmentitems

    Declaration
    public void ValidateShipmentItemsIndex(Shipment shipment)
    Parameters
    Type Name Description
    Shipment shipment
    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2018 SIMPLIC GmbH
    Generated by DocFx