public List<AssetDetail> ChkAssetavailAbility(string Barcode)
        {
            List<AssetDetail> AssdetailList = new List<AssetDetail>();
            try
            {
                CycleCount objCycleCount = new CycleCount();
                objCycleCount.RFTags = Barcode;

                DataTable dtasset = objCycleCount.ChkAssetavailAbility();

                foreach (DataRow drass in dtasset.Rows)
                {
                    AssetDetail objassetdetail = new AssetDetail();
                    objassetdetail.Barcode = (drass["TagID"]).ToString();
                    objassetdetail.Description = drass["Description"].ToString();
                    AssdetailList.Add(objassetdetail);
                }

            }
            catch (Exception ex)
            {
                _log.Error("Error:ChkAssetavailAbility:: " + ex.Message + Environment.NewLine + ex.StackTrace);
                ThrowFaultError(ex.Message, 200);
            }
            return AssdetailList;
        }
        public void CycleCountSave(int CC_ID, string RFTags, int LocID, bool IsNewTransaction,int TotalMin,int Audit_ID,out int CCID,string CatID)
        {
            int OutCC_ID = 0;
            try
            {

                CycleCount objCycleCount = new CycleCount();
                objCycleCount.CC_ID = CC_ID;
                objCycleCount.RFTags = RFTags;
                objCycleCount.LocationID = LocID;
                objCycleCount.IsNewTransaction = IsNewTransaction;
                objCycleCount.Total_Min = TotalMin;
                objCycleCount.Audit_ID = Audit_ID;
                objCycleCount.CatID = CatID;

                OutCC_ID = objCycleCount.CycleCountSave();
            }

            catch (Exception ex)
            {
                _log.Error("Error:CycleCountSave:: " + ex.Message + Environment.NewLine + ex.StackTrace);
                ThrowFaultError(ex.Message, 200);
            }
            CCID = OutCC_ID;
        }
        public void AuditSave(out int AuditID)
        {
            int OutAuditID = 0;
            try
            {

                CycleCount objCycleCount = new CycleCount();

                OutAuditID = objCycleCount.AuditSave();
            }

            catch (Exception ex)
            {
                _log.Error("Error:AuditSave:: " + ex.Message + Environment.NewLine + ex.StackTrace);
                ThrowFaultError(ex.Message, 200);
            }
            AuditID = OutAuditID;
        }
        public List<Location> GetZone( string ZoneDesc)
        {
            List<Location> ZoneList = new List<Location>();
            try
            {
                CycleCount objCycleCount = new CycleCount();

                DataTable dtLoc = objCycleCount.GetZone(ZoneDesc);

                foreach (DataRow drLoc in dtLoc.Rows)
                {
                    Location objloc = new Location();
                    objloc.LocationID = Convert.ToInt32(drLoc["LocationID"]);
                    objloc.DisplayName = drLoc["LocationName"].ToString();
                    ZoneList.Add(objloc);
                }

            }
            catch (Exception ex)
            {
                _log.Error("Error:GetZone:: " + ex.Message + Environment.NewLine + ex.StackTrace);
                ThrowFaultError(ex.Message, 200);
            }
            return ZoneList;
        }
        public List<Category> GetAllCategory()
        {
            List<Category> catList = new List<Category>();
            try
            {
                CycleCount objCycleCount = new CycleCount();

                DataTable dtcat = objCycleCount.GetAllCategory();

                foreach (DataRow drCat in dtcat.Rows)
                {
                    Category objcat = new Category();
                    objcat.CategoryID = (drCat["CategoryID"].ToString());
                    objcat.DisplayName = drCat["Name"].ToString();
                    catList.Add(objcat);
                }

            }
            catch (Exception ex)
            {
                _log.Error("Error:GetAllCategory:: " + ex.Message + Environment.NewLine + ex.StackTrace);
                ThrowFaultError(ex.Message, 200);
            }
            return catList;
        }
        public int GetAllAssetDetailCount(string CatrgoryID, string RFTags)
        {
            int count = 0;

            try
            {
                CycleCount objCycleCount = new CycleCount();
                objCycleCount.RFTags = RFTags;
                objCycleCount.CatID = CatrgoryID;

                count = objCycleCount.GetAllAssetDetailCount();

            }
            catch (Exception ex)
            {
                _log.Error("Error:GetAllAssetDetailCount:: " + ex.Message + Environment.NewLine + ex.StackTrace);
                ThrowFaultError(ex.Message, 200);
            }
            return count;
        }