private void BindSpaceOrgs() { // organization bool orgVisible = (PanelRequest.ItemID > 0 && Request[DefaultPage.PAGE_ID_PARAM].Equals(UserSpaceBreadcrumb.PID_SPACE_EXCHANGE_SERVER, StringComparison.InvariantCultureIgnoreCase)); spanOrgsSelector.Visible = orgVisible; if (orgVisible) { OrganizationsHelper helper = new OrganizationsHelper(); ddlSpaceOrgs.DataSource = helper.GetOrganizations(PanelSecurity.PackageId, false); ddlSpaceOrgs.DataTextField = "ItemName"; ddlSpaceOrgs.DataValueField = "ItemID"; ddlSpaceOrgs.DataBind(); ddlSpaceOrgs.Items.FindByValue(PanelRequest.ItemID.ToString()).Selected = true; lnkOrgnsList.NavigateUrl = PortalUtils.NavigatePageURL( PortalUtils.GetCurrentPageId(), "SpaceID", PanelSecurity.PackageId.ToString()); } }
public void BindMenu(MenuItemCollection items) { if (PackageId == 0) { PackageId = Convert.ToInt32(Session["currentPackage"]); } System.Data.DataTable l_OrgTable; if (PackageId > 0 && ItemID == 0) { l_OrgTable = new OrganizationsHelper().GetOrganizations(PackageId, false); if (l_OrgTable.Rows.Count > 0) { ItemID = Convert.ToInt32(l_OrgTable.Rows[0]["ItemID"]); } } if ((PackageId <= 0) || (ItemID <= 0)) { return; } //Organization menu group; if (Cntx.Groups.ContainsKey(ResourceGroups.HostedOrganizations)) { PrepareOrganizationMenuRoot(items); } //Exchange menu group; if (Cntx.Groups.ContainsKey(ResourceGroups.Exchange)) { PrepareExchangeMenuRoot(items); } //BlackBerry Menu if (Cntx.Groups.ContainsKey(ResourceGroups.BlackBerry)) { PrepareBlackBerryMenuRoot(items); } //SharePoint menu group; if (Cntx.Groups.ContainsKey(ResourceGroups.SharepointFoundationServer)) { PrepareSharePointMenuRoot(items); } if (Cntx.Groups.ContainsKey(ResourceGroups.SharepointEnterpriseServer)) { PrepareSharePointEnterpriseMenuRoot(items); } //CRM Menu if (Cntx.Groups.ContainsKey(ResourceGroups.HostedCRM2013)) { PrepareCRM2013MenuRoot(items); } else if (Cntx.Groups.ContainsKey(ResourceGroups.HostedCRM)) { PrepareCRMMenuRoot(items); } //OCS Menu if (Cntx.Groups.ContainsKey(ResourceGroups.OCS)) { PrepareOCSMenuRoot(items); } //Lync Menu if (Cntx.Groups.ContainsKey(ResourceGroups.Lync)) { PrepareLyncMenuRoot(items); } //SfBMenu if (Cntx.Groups.ContainsKey(ResourceGroups.SfB)) { PrepareSfBMenuRoot(items); } //EnterpriseStorage Menu if (Cntx.Groups.ContainsKey(ResourceGroups.EnterpriseStorage)) { PrepareEnterpriseStorageMenuRoot(items); } //Remote Desktop Services Menu if (Cntx.Groups.ContainsKey(ResourceGroups.RDS)) { PrepareRDSMenuRoot(items); } }