public FullGraphVyrab getFullGraphVyrab(bool steppedPBR=true)
        {
            Logger.Info("Получение графика нагрузки stairs:" + steppedPBR);
            FullGraphVyrab answer=new FullGraphVyrab();
            answer.GTP = getGraphVyrab(steppedPBR);
            answer.RGE = getGraphVyrabRGE(steppedPBR);
            answer.TimeStopGA = PuskStopReportFull.TimeStopGA();
            try {
                List<PiramidaEnrty>list=PiramidaAccess.GetDataFromDB(DateTime.Now.AddHours(-4), DateTime.Now.AddHours(-2), 1, 2, 12, (new int[] { 276 }).ToList(), true, true, "P3000");
                answer.Napor = list.Last().Value0;
            } catch (Exception e) {
                Logger.Error("Ошибка при получении напора" + e);
            }

            return answer;
        }
 public GraphVyrabRGEPage()
 {
     InitializeComponent();
     CurrentAnswer = new FullGraphVyrab();
     CurrentAnswer.Napor = 21;
     context = new GraphVyrabDomainContext();
     pnlSettings.DataContext = CurrentAnswer;
     settings = new SettingsGraphVyab();
     chbIsSteppedPBR.IsChecked = true;
     settings.Second = 60;
     settings.AutoRefresh = false;
     pnlRefresh.DataContext = settings;
     timer = new DispatcherTimer();
     timer.Tick += new EventHandler(timer_Tick);
     timer.Interval = new TimeSpan(0, 0, 1);
     rusaWindow = new RUSAWindow();
     rusaWindow.Closed += new EventHandler(rusaWindow_Closed);
 }