protected override void OnInit(EventArgs e)
        {
            base.OnInit(e);
            IList <ServiceLockTypeEnum> types = ServiceLockTypeEnum.GetAll();

            TypeDropDownList.Items.Add(new ListItem(SR.All));
            foreach (ServiceLockTypeEnum t in types)
            {
                TypeDropDownList.Items.Add(new ListItem(ServerEnumDescription.GetLocalizedDescription(t), t.Lookup));
            }

            EditServiceLockDialog.ServiceLockUpdated += AddEditServiceLockDialog_ServiceLockUpdated;

            // setup child controls
            GridPagerTop.InitializeGridPager(SR.GridPagerServiceSingleItem, SR.GridPagerServiceMultipleItems, ServiceLockGridViewControl.TheGrid, delegate { return(ServiceLockGridViewControl.ServiceLocks != null ? ServiceLockGridViewControl.ServiceLocks.Count : 0); }, ImageServerConstants.GridViewPagerPosition.Top);
            ServiceLockGridViewControl.Pager = GridPagerTop;

            StatusFilter.Items.Add(new ListItem(SR.All));
            StatusFilter.Items.Add(new ListItem(SR.Enabled));
            StatusFilter.Items.Add(new ListItem(SR.Disabled));

            FileSystemsConfigurationController fileSystemController = new FileSystemsConfigurationController();
            IList <Model.Filesystem>           fileSystems          = fileSystemController.GetAllFileSystems();

            foreach (Model.Filesystem fs in fileSystems)
            {
                FileSystemFilter.Items.Add(new ListItem(fs.Description, fs.Key.ToString()));
            }

            ConfirmEditDialog.Confirmed += ConfirmEditDialog_Confirmed;
        }
Пример #2
0
        /// <summary>
        /// Retrieves the Filesystems to be rendered in the page.
        /// </summary>
        /// <returns></returns>
        private IList <Filesystem> GetFilesystems()
        {
            // TODO We may want to add context or user preference here to specify which partitions to load

            IList <Filesystem> list = _controller.GetAllFileSystems();

            return(list);
        }