示例#1
0
        protected override void FillExecuteCmd(System.Data.SqlClient.SqlCommand cmd)
        {
            cmd.CommandType = CommandType.StoredProcedure;
            cmd.CommandText = "usp_SplitLot";

            m_newLotId = LotID.GetNextLotID(m_stockLot.LotID);

            cmd.Parameters.AddWithValue("@newlotid", m_newLotId);
            cmd.Parameters.AddWithValue("@oldlotid", m_stockLot.LotID);
            cmd.Parameters.AddWithValue("@reason", m_reason);
            cmd.Parameters.AddWithValue("@quantity", m_quantity);
            cmd.Parameters.AddWithValue("@user", Security.UserSecurity.CurrentUser.Login);
        }
示例#2
0
        public Receipt MapFrom(ReceiptFacts input)
        {
            Receipt receipt = Scout.Core.Data.CreateEntity <Receipt>(input.Session);

            receipt.SerialNumber       = input.SerialNumber;
            receipt.Qty                = input.Qty;
            receipt.Condition          = input.Condition;
            receipt.Comments           = input.Comments;
            receipt.Part               = input.Part;
            receipt.ReceivingCart      = input.ReceivingCart;
            receipt.RoutingRequired    = input.RoutingRequired;
            receipt.PurchaseOrder      = input.PurchaseOrder;
            receipt.PurchaseLineItem   = input.PurchaseLineItem;
            receipt.Grade              = input.Grade;
            receipt.CustomFields       = input.CustomFields;
            receipt.ReceiveDate        = DateTime.Now;
            receipt.UnitTrackingId     = LotID.Generate();
            receipt.Warnings           = input.Warnings;
            receipt.LineItemIdentifier = input.LineItemIdentifier;
            return(receipt);
        }