Exemplo n.º 1
0
        private static CreditLine PopulateFromDBDetailsObject(CreditLineDetails obj)
        {
            CreditLine objNew = new CreditLine();

            objNew.CreditLineId       = obj.CreditLineId;
            objNew.FullPart           = obj.FullPart;
            objNew.Part               = obj.Part;
            objNew.ManufacturerNo     = obj.ManufacturerNo;
            objNew.DateCode           = obj.DateCode;
            objNew.PackageNo          = obj.PackageNo;
            objNew.ProductNo          = obj.ProductNo;
            objNew.CreditNo           = obj.CreditNo;
            objNew.Quantity           = obj.Quantity;
            objNew.Price              = obj.Price;
            objNew.Taxable            = obj.Taxable;
            objNew.CustomerPart       = obj.CustomerPart;
            objNew.LandedCost         = obj.LandedCost;
            objNew.InvoiceLineNo      = obj.InvoiceLineNo;
            objNew.CustomerRMALineNo  = obj.CustomerRMALineNo;
            objNew.ROHS               = obj.ROHS;
            objNew.UpdatedBy          = obj.UpdatedBy;
            objNew.DLUP               = obj.DLUP;
            objNew.StockNo            = obj.StockNo;
            objNew.ServiceNo          = obj.ServiceNo;
            objNew.Notes              = obj.Notes;
            objNew.FullCustomerPart   = obj.FullCustomerPart;
            objNew.CreditId           = obj.CreditId;
            objNew.CreditNumber       = obj.CreditNumber;
            objNew.CreditDate         = obj.CreditDate;
            objNew.CompanyName        = obj.CompanyName;
            objNew.CompanyNo          = obj.CompanyNo;
            objNew.CustomerRMANumber  = obj.CustomerRMANumber;
            objNew.CustomerRMANo      = obj.CustomerRMANo;
            objNew.CustomerPO         = obj.CustomerPO;
            objNew.InvoiceNumber      = obj.InvoiceNumber;
            objNew.InvoiceNo          = obj.InvoiceNo;
            objNew.ContactName        = obj.ContactName;
            objNew.ContactNo          = obj.ContactNo;
            objNew.ManufacturerCode   = obj.ManufacturerCode;
            objNew.RowNum             = obj.RowNum;
            objNew.RowCnt             = obj.RowCnt;
            objNew.LineNotes          = obj.LineNotes;
            objNew.ManufacturerName   = obj.ManufacturerName;
            objNew.PackageName        = obj.PackageName;
            objNew.PackageDescription = obj.PackageDescription;
            objNew.ProductName        = obj.ProductName;
            objNew.ProductDescription = obj.ProductDescription;
            objNew.CurrencyNo         = obj.CurrencyNo;
            objNew.CurrencyCode       = obj.CurrencyCode;
            objNew.RaiserName         = obj.RaiserName;
            objNew.SalesmanName       = obj.SalesmanName;
            objNew.TeamNo             = obj.TeamNo;
            objNew.DivisionName       = obj.DivisionName;
            objNew.ReferenceDate      = obj.ReferenceDate;
            return(objNew);
        }
Exemplo n.º 2
0
 /// <summary>
 /// Get
 /// Calls [usp_select_CreditLine]
 /// </summary>
 public static CreditLine Get(System.Int32?creditLineId)
 {
     Rebound.GlobalTrader.DAL.CreditLineDetails objDetails = Rebound.GlobalTrader.DAL.SiteProvider.CreditLine.Get(creditLineId);
     if (objDetails == null)
     {
         return(null);
     }
     else
     {
         CreditLine obj = new CreditLine();
         obj.CreditLineId       = objDetails.CreditLineId;
         obj.FullPart           = objDetails.FullPart;
         obj.Part               = objDetails.Part;
         obj.ManufacturerNo     = objDetails.ManufacturerNo;
         obj.DateCode           = objDetails.DateCode;
         obj.PackageNo          = objDetails.PackageNo;
         obj.ProductNo          = objDetails.ProductNo;
         obj.CreditNo           = objDetails.CreditNo;
         obj.Quantity           = objDetails.Quantity;
         obj.Price              = objDetails.Price;
         obj.Taxable            = objDetails.Taxable;
         obj.CustomerPart       = objDetails.CustomerPart;
         obj.LandedCost         = objDetails.LandedCost;
         obj.InvoiceLineNo      = objDetails.InvoiceLineNo;
         obj.CustomerRMALineNo  = objDetails.CustomerRMALineNo;
         obj.ROHS               = objDetails.ROHS;
         obj.StockNo            = objDetails.StockNo;
         obj.ServiceNo          = objDetails.ServiceNo;
         obj.LineNotes          = objDetails.LineNotes;
         obj.UpdatedBy          = objDetails.UpdatedBy;
         obj.DLUP               = objDetails.DLUP;
         obj.ManufacturerName   = objDetails.ManufacturerName;
         obj.ManufacturerCode   = objDetails.ManufacturerCode;
         obj.PackageName        = objDetails.PackageName;
         obj.PackageDescription = objDetails.PackageDescription;
         obj.ProductName        = objDetails.ProductName;
         obj.ProductDescription = objDetails.ProductDescription;
         obj.CurrencyNo         = objDetails.CurrencyNo;
         obj.CurrencyCode       = objDetails.CurrencyCode;
         obj.CompanyName        = objDetails.CompanyName;
         obj.ContactName        = objDetails.ContactName;
         obj.RaiserName         = objDetails.RaiserName;
         obj.SalesmanName       = objDetails.SalesmanName;
         obj.TeamNo             = objDetails.TeamNo;
         obj.DivisionName       = objDetails.DivisionName;
         obj.InvoiceNumber      = objDetails.InvoiceNumber;
         obj.CustomerRMANumber  = objDetails.CustomerRMANumber;
         obj.CreditDate         = objDetails.CreditDate;
         obj.ReferenceDate      = objDetails.ReferenceDate;
         objDetails             = null;
         return(obj);
     }
 }
Exemplo n.º 3
0
        }               /// <summary>

        /// DataListNugget
        /// Calls [usp_datalistnugget_CreditLine]
        /// </summary>
        public static List <CreditLine> DataListNugget(System.Int32?clientId, System.Int32?teamId, System.Int32?divisionId, System.Int32?loginId, System.Int32?orderBy, System.Int32?sortDir, System.Int32?pageIndex, System.Int32?pageSize, System.String partSearch, System.String contactSearch, System.String cmSearch, System.Int32?salesmanSearch, System.String creditNotesSearch, System.String customerPoSearch, System.Int32?creditNoLo, System.Int32?creditNoHi, System.Int32?invoiceNoLo, System.Int32?invoiceNoHi, System.Int32?customerRmaNoLo, System.Int32?customerRmaNoHi, System.DateTime?creditDateFrom, System.DateTime?creditDateTo, System.Boolean?PohubOnly, System.Int32?ClientInvoiceNoLo, System.Int32?ClientInvoiceNoHi, System.Boolean?blnHubCredit)
        {
            List <CreditLineDetails> lstDetails = Rebound.GlobalTrader.DAL.SiteProvider.CreditLine.DataListNugget(clientId, teamId, divisionId, loginId, orderBy, sortDir, pageIndex, pageSize, partSearch, contactSearch, cmSearch, salesmanSearch, creditNotesSearch, customerPoSearch, creditNoLo, creditNoHi, invoiceNoLo, invoiceNoHi, customerRmaNoLo, customerRmaNoHi, creditDateFrom, creditDateTo, PohubOnly, ClientInvoiceNoLo, ClientInvoiceNoHi, blnHubCredit);

            if (lstDetails == null)
            {
                return(new List <CreditLine>());
            }
            else
            {
                List <CreditLine> lst = new List <CreditLine>();
                foreach (CreditLineDetails objDetails in lstDetails)
                {
                    Rebound.GlobalTrader.BLL.CreditLine obj = new Rebound.GlobalTrader.BLL.CreditLine();
                    obj.CreditId            = objDetails.CreditId;
                    obj.CreditNumber        = objDetails.CreditNumber;
                    obj.Part                = objDetails.Part;
                    obj.ROHS                = objDetails.ROHS;
                    obj.CreditDate          = objDetails.CreditDate;
                    obj.CompanyName         = objDetails.CompanyName;
                    obj.CompanyNo           = objDetails.CompanyNo;
                    obj.CustomerRMANumber   = objDetails.CustomerRMANumber;
                    obj.CustomerRMANo       = objDetails.CustomerRMANo;
                    obj.CustomerPO          = objDetails.CustomerPO;
                    obj.InvoiceNumber       = objDetails.InvoiceNumber;
                    obj.InvoiceNo           = objDetails.InvoiceNo;
                    obj.ContactName         = objDetails.ContactName;
                    obj.ContactNo           = objDetails.ContactNo;
                    obj.ManufacturerNo      = objDetails.ManufacturerNo;
                    obj.ManufacturerCode    = objDetails.ManufacturerCode;
                    obj.RowNum              = objDetails.RowNum;
                    obj.RowCnt              = objDetails.RowCnt;
                    obj.ClientInvoiceNumber = objDetails.ClientInvoiceNumber;
                    obj.ClientInvoiceNo     = objDetails.ClientInvoiceNo;
                    lst.Add(obj);
                    obj = null;
                }
                lstDetails = null;
                return(lst);
            }
        }