Ejemplo n.º 1
0
        /// <summary>
        /// Repository for Distribution Centre Stock Report
        /// </summary>
        /// <returns></returns>
        public List <DistributionCentreStock> GetDistributionCentreStock()
        {
            List <DistributionCentreStock> stockList = null;

            stockList = ViewDataAccess.GetDistributionCentreStock(_connectionString);
            return(stockList);
        }
Ejemplo n.º 2
0
        public void ProcessRequest(HttpContext context)
        {
            Guid viewId = Guid.Empty;

            try
            {
                viewId = Guid.Parse(context.Request["id"]);
            }
            catch { }
            if (viewId == Guid.Empty)
            {
                context.Response.ContentType = "text/plain";
                context.Response.Write("parameters error!");
                return;
            }
            ConfigInfo           info = InitConfigs();
            ViewDataAccess       vda  = new ViewDataAccess(info);
            ViewModel            vm   = vda.GetDataFowView(viewId);
            JavaScriptSerializer jss  = new JavaScriptSerializer();
            string json = jss.Serialize(vm);

            context.Response.ContentType = "text/plain";

            context.Response.Write(json);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Repository for Reconciled Package screen in Package Audit Wizard
        /// </summary>
        /// <param name="currentLocation"></param>
        /// <param name="packageType"></param>
        /// <param name="barCodeList"></param>
        /// <returns></returns>
        public List <ReconciledPackage> GetReconciledPackages(DistributionCentre currentLocation, StandardPackageType packageType, List <string> barCodeList)
        {
            List <ReconciledPackage> packageList = null;

            packageList = ViewDataAccess.GetReconciledPackages(_connectionString, currentLocation, packageType, barCodeList);
            return(packageList);
        }
Ejemplo n.º 4
0
        /// <summary>
        /// Repository for Distribution Centre Losses Report
        /// </summary>
        /// <returns></returns>
        public List <DistributionCentreLosses> GetDistributionCentreLosses()
        {
            List <DistributionCentreLosses> centreList = null;

            centreList = ViewDataAccess.GetDistributionCentreLosses(_connectionString);
            return(centreList);
        }
Ejemplo n.º 5
0
        /// <summary>
        /// Repository for Stocktaking Report
        /// </summary>
        /// <param name="centreId"></param>
        /// <returns></returns>
        public List <StockTaking> GetStocktaking(int centreId)
        {
            List <StockTaking> packageList = null;

            packageList = ViewDataAccess.GetStocktaking(_connectionString, centreId);

            return(packageList);
        }
Ejemplo n.º 6
0
        /// <summary>
        /// Repository for Value In Transit Report
        /// </summary>
        /// <returns></returns>
        public List <ValueInTransit> GetValueInTransit()
        {
            List <ValueInTransit> valueList = null;

            valueList = ViewDataAccess.GetValueInTransit(_connectionString);

            return(valueList);
        }
Ejemplo n.º 7
0
        /// <summary>
        /// Repository for Global Stock Report
        /// </summary>
        /// <returns></returns>
        public List <GlobalStock> GetGlobalStock()
        {
            List <GlobalStock> stocks = null;

            stocks = ViewDataAccess.GetGlobalStock(_connectionString);

            return(stocks);
        }
Ejemplo n.º 8
0
        /// <summary>
        /// Repository for Doctor Activity Report
        /// </summary>
        /// <returns></returns>
        public List <DoctorActivity> GetDoctorActivity()
        {
            List <DoctorActivity> doctors = null;

            doctors = ViewDataAccess.GetDoctorActivity(_connectionString);

            return(doctors);
        }
Ejemplo n.º 9
0
        /// <summary>
        /// Repository for Stocktaking Report
        /// </summary>
        /// <param name="centreId"></param>
        /// <returns></returns>
        public List <StocktakingPackage> GetStocktaking(int centreId)
        {
            List <StocktakingPackage> packageList = null;

            using (SqlConnection connection = new SqlConnection(_connectionString))
            {
                connection.Open();
                packageList = ViewDataAccess.GetStocktaking(connection, centreId);
            }
            return(packageList);
        }
Ejemplo n.º 10
0
        /// <summary>
        /// Repository for Value In Transit Report
        /// </summary>
        /// <returns></returns>
        public List <ValueInTransit> GetValueInTransit()
        {
            List <ValueInTransit> valueList = null;

            using (SqlConnection connection = new SqlConnection(_connectionString))
            {
                connection.Open();

                valueList = ViewDataAccess.GetValueInTransit(connection);
            }
            return(valueList);
        }
Ejemplo n.º 11
0
        /// <summary>
        /// Repository for Global Stock Report
        /// </summary>
        /// <returns></returns>
        public List <GlobalStock> GetGlobalStock()
        {
            List <GlobalStock> stocks = null;

            using (SqlConnection connection = new SqlConnection(_connectionString))
            {
                connection.Open();

                stocks = ViewDataAccess.GetGlobalStock(connection);
            }
            return(stocks);
        }
Ejemplo n.º 12
0
        /// <summary>
        /// Repository for Doctor Activity Report
        /// </summary>
        /// <returns></returns>
        public List <DoctorActivity> GetDoctorActivity()
        {
            List <DoctorActivity> doctors = null;

            using (SqlConnection connection = new SqlConnection(_connectionString))
            {
                connection.Open();

                doctors = ViewDataAccess.GetDoctorActivity(connection);
            }
            return(doctors);
        }
Ejemplo n.º 13
0
        /// <summary>
        /// Repository for Distribution Centre Losses Report
        /// </summary>
        /// <returns></returns>
        public List <DistributionCentreLosses> GetDistributionCentreLosses()
        {
            List <DistributionCentreLosses> centreList = null;

            using (SqlConnection connection = new SqlConnection(_connectionString))
            {
                connection.Open();

                centreList = ViewDataAccess.GetDistributionCentreLosses(connection);
            }
            return(centreList);
        }
Ejemplo n.º 14
0
        /// <summary>
        /// Repository for Distribution Centre Stock Report
        /// </summary>
        /// <returns></returns>
        public List <DistributionCentreStock> GetDistributionCentreStock()
        {
            List <DistributionCentreStock> stockList = null;

            using (SqlConnection connection = new SqlConnection(_connectionString))
            {
                connection.Open();

                stockList = ViewDataAccess.GetDistributionCentreStock(connection);
            }
            return(stockList);
        }
Ejemplo n.º 15
0
        /// <summary>
        /// Repository for Reconciled Package screen in Package Audit Wizard
        /// </summary>
        /// <param name="currentLocation"></param>
        /// <param name="packageType"></param>
        /// <param name="barCodeList"></param>
        /// <returns></returns>
        public List <ReconciledPackage> GetReconciledPackages(DistributionCentre currentLocation, StandardPackageType packageType, List <string> barCodeList)
        {
            List <ReconciledPackage> packageList = null;

            using (SqlConnection connection = new SqlConnection(_connectionString))
            {
                connection.Open();

                XElement barCodeXml = barCodeList.GetBarCodeXML();

                packageList = ViewDataAccess.GetReconciledPackages(connection, currentLocation, packageType, barCodeXml);
            }
            return(packageList);
        }