Ejemplo n.º 1
0
        private void UpdateNavBarName()
        {
            List <bool> ActivedList = new List <bool>();
            List <bool> BlockedList = new List <bool>();

            for (int i = 0; i < GridView.VisibleRowCount; i++)
            {
                ActivedList.Add((bool)GridView.GetRowValues(i, "Actived"));
                BlockedList.Add((bool)GridView.GetRowValues(i, "Blocked"));
            }
            GridView.JSProperties["cpActived"] = ActivedList;
            GridView.JSProperties["cpBlocked"] = BlockedList;


            HttpContext.Current.Session["isActBloChanged_Com"] = false;

            GridView.JSProperties["cpAllCount"] = CompanyProvider.Count(x => true);
            GridView.JSProperties["cpInActivedUnBlockedCount"] = CompanyProvider.Count(x => x.Actived == false && x.Blocked == false);
            GridView.JSProperties["cpActivedBlockedCount"]     = CompanyProvider.Count(x => x.Actived == true && x.Blocked == true);
            GridView.JSProperties["cpInactivedBlockedCount"]   = CompanyProvider.Count(x => x.Actived == false && x.Blocked == true);
            GridView.JSProperties["cpActivedUnBlockedCount"]   = CompanyProvider.Count(x => x.Actived == true && x.Blocked == false);
            GridView.JSProperties["cpUpdatedByCount"]          = CompanyProvider.Count(x => x.CreatedBy == User.Identity.Name || x.UpdatedBy == User.Identity.Name);
            GridView.JSProperties["cpOwnerCount"] = CompanyProvider.Count(x => x.UserName == User.Identity.Name);
        }