/// <summary>
        /// Cette méthode est exécutée lorsqu'on sélectionne une target sur la sidebar.
        /// Cette opération a pour but de rajouté la target sélectionnée au filtre de la table en édition,
        /// ou au scope des cellProperties correspondants à la sélection Excel.
        /// </summary>
        /// <param name="sender">La target sélectionné</param>
        protected void onSelectTargetFromSidebar(object target)
        {
            ReconciliationFilterTemplateEditorItem page = (ReconciliationFilterTemplateEditorItem)getEditor().getActivePage();

            if (page == null)
            {
                return;
            }
            ReconciliationFilterTemplatePropertyBar bar = (ReconciliationFilterTemplatePropertyBar)this.PropertyBar;

            page.SetTarget((Target)target, bar.FilterLayoutAnchorable.IsSelected);
        }
 /// <summary>
 ///
 /// </summary>
 /// <param name="sender"></param>
 protected void onSelectPeriodFromSidebar(object sender)
 {
     if (sender != null)
     {
         ReconciliationFilterTemplateEditorItem page = (ReconciliationFilterTemplateEditorItem)getEditor().getActivePage();
         if (page == null)
         {
             return;
         }
         ReconciliationFilterTemplatePropertyBar bar = (ReconciliationFilterTemplatePropertyBar)this.PropertyBar;
         page.SetPeriod(sender, bar.FilterLayoutAnchorable.IsSelected);
     }
 }
        /// <summary>
        ///
        /// </summary>
        /// <param name="page"></param>
        public override void OnPageSelected(EditorItem <ReconciliationFilterTemplate> page)
        {
            if (page == null)
            {
                return;
            }
            base.OnPageSelected(page);
            ReconciliationFilterTemplateForm        form = ((ReconciliationFilterTemplateEditorItem)page).getForm();
            ReconciliationFilterTemplatePropertyBar bar  = (ReconciliationFilterTemplatePropertyBar)this.PropertyBar;

            if (bar.AdministratorLayoutAnchorable != null)
            {
                bar.AdministratorLayoutAnchorable.Content = form.AdministrationBar;
            }
            PerformSelectionChange();
        }
        protected virtual void PerformSelectionChange()
        {
            ReconciliationFilterTemplatePropertyBar bar  = (ReconciliationFilterTemplatePropertyBar)this.PropertyBar;
            ReconciliationFilterTemplateEditorItem  page = (ReconciliationFilterTemplateEditorItem)getEditor().getActivePage();

            if (page.getForm().SelectedIndex == 0)
            {
                ApplicationManager.MainWindow.displayPropertyBar(null);
                if (page.getForm().LeftGrid.GrilleBrowserForm.gridBrowser.RebuildGrid)
                {
                    UpdateGridForm(page.getForm().LeftGrid);
                }
                if (page.getForm().RightGrid.GrilleBrowserForm.gridBrowser.RebuildGrid)
                {
                    UpdateGridForm(page.getForm().RightGrid);
                }
                if (page.getForm().BottomGrid.GridBrowser.RebuildGrid)
                {
                    UpdateGridForm(page.getForm().BottomGrid);
                }

                page.getForm().LeftGrid.CustomizeDC();
                page.getForm().RightGrid.CustomizeDC();
            }
            else if (ApplicationManager.Instance.User.IsAdmin())
            {
                ApplicationManager.MainWindow.displayPropertyBar(this.PropertyBar);
                //if (!bar.Pane.Children.Contains(bar.DesignLayoutAnchorable)) bar.Pane.Children.Add(bar.DesignLayoutAnchorable);
                //if (bar.AdministratorLayoutAnchorable != null && !bar.Pane.Children.Contains(bar.AdministratorLayoutAnchorable)) bar.Pane.Children.Add(bar.AdministratorLayoutAnchorable);

                bar.Pane.Children.Remove(bar.FilterLayoutAnchorable);
                if (page.getForm().SelectedIndex == 1)
                {
                    ConfigurationPropertiesPanel configPane = page.getForm().ConfigurationPanel.ConfigurationPropertiesPanel;
                    configPane.displayObject();
                    bar.DesignLayoutAnchorable.Content = page.getForm().ConfigurationPanel.ConfigurationPropertiesPanel;
                    bar.DesignLayoutAnchorable.Title   = "Filter Properties";
                }
                else if (page.getForm().SelectedIndex == 2)
                {
                    bar.DesignLayoutAnchorable.Content = page.getForm().LeftGridProperties.InputGridPropertiesPanel;
                    bar.DesignLayoutAnchorable.Title   = "Left Grid Properties";
                    bar.FilterLayoutAnchorable.Content = page.getForm().LeftGrid.GrilleBrowserForm.filterForm;
                    bar.FilterLayoutAnchorable.Title   = "Left Filter Properties";

                    bar.Pane.Children.Insert(1, bar.FilterLayoutAnchorable);
                }
                else if (page.getForm().SelectedIndex == 3)
                {
                    bar.DesignLayoutAnchorable.Content = page.getForm().RightGridProperties.InputGridPropertiesPanel;
                    bar.DesignLayoutAnchorable.Title   = "Right Grid Properties";
                    bar.FilterLayoutAnchorable.Content = page.getForm().RightGrid.GrilleBrowserForm.filterForm;
                    bar.FilterLayoutAnchorable.Title   = "Right Filter Properties";

                    bar.Pane.Children.Insert(1, bar.FilterLayoutAnchorable);
                }
                else if (page.getForm().SelectedIndex == 4)
                {
                    bar.DesignLayoutAnchorable.Content = page.getForm().BottomGridProperties.InputGridPropertiesPanel;
                    bar.DesignLayoutAnchorable.Title   = "Bottom Grid Properties";
                }
            }
        }