/// <summary>
        /// 必要实际开启台数实时刷新数据
        /// </summary>
        /// <param name="currtime"></param>
        /// <param name="begtime"></param>
        /// <returns></returns>
        public Model.ViewObject.SupplyStackSumpowerpq_VO SupplySer(DateTime currtime, DateTime begtime)
        {
            var res = dal.QueryWhereDesc(f => f.DateTime >= begtime && f.DateTime <= currtime, or => or.OrderByDescending(o => o.DateTime)).Select(f => new
            {
                time    = f.DateTime,
                mustnum = Math.Round((double)f.ProduceFlowCentrifuge / 15000 * 1.1, 1),
                runnum  = f.RUN_NUM,
            }).FirstOrDefault();
            DateTime StartTime    = TimeZone.CurrentTimeZone.ToLocalTime(new DateTime(1970, 1, 1, 0, 0, 0, 0));
            long     timezone     = StartTime.Ticks;
            var      trantimezone = (DateTime.Parse("" + res.time).AddHours(8).Ticks - timezone) / 10000;

            Model.ViewObject.SupplyStackSumpowerpq_VO list = new Model.ViewObject.SupplyStackSumpowerpq_VO()
            {
                time    = trantimezone,
                dtime   = res.time.ToString(),
                Mustnum = Math.Round((decimal)res.mustnum, 2),
                Runnum  = Convert.ToInt32(res.runnum),
            };
            return(list);
        }
        /// <summary>
        /// 大数据界面压力功率流量数据
        /// </summary>
        /// <param name="currtime">当前时间</param>
        /// <param name="begtime">之前时间</param>
        /// <returns></returns>
        public List <Model.ViewObject.SupplyStackSumpowerpq_VO> SupplyStackSumPowerpq(DateTime currtime, DateTime begtime)
        {
            var res = dal.QueryWhere(f => f.DateTime >= begtime && f.DateTime <= currtime).Select(f => new
            {
                time     = f.DateTime,
                mustnum  = f.ProduceFlowCentrifuge / 15000,
                runnum   = f.RUN_NUM,
                flow     = f.ProduceFlowStation,
                press    = f.PipelinePressure,
                sumpower = f.SumPower
            }).ToList();
            DateTime StartTime = TimeZone.CurrentTimeZone.ToLocalTime(new DateTime(1970, 1, 1, 0, 0, 0, 0));
            long     timezone  = StartTime.Ticks;
            List <Model.ViewObject.SupplyStackSumpowerpq_VO> alllist = new List <Model.ViewObject.SupplyStackSumpowerpq_VO>();

            foreach (var item in res)
            {
                //转换成时间戳到秒
                var trantimezone = (DateTime.Parse("" + item.time).AddHours(8).Ticks - timezone) / 10000;
                Model.ViewObject.SupplyStackSumpowerpq_VO list = new Model.ViewObject.SupplyStackSumpowerpq_VO()
                {
                    //时间戳
                    time  = trantimezone,
                    dtime = item.time.ToString(),
                    //必要开启台数
                    Mustnum = Math.Round((decimal)item.mustnum, 2),
                    //实际开机台数
                    Runnum = Convert.ToInt32(item.runnum),
                    //功率
                    Power = Convert.ToInt32(item.sumpower),
                    //流量
                    ProduceStation = Convert.ToInt32(item.flow),
                    //压力
                    Press = (decimal)item.press
                };
                alllist.Add(list);
            }

            return(alllist);
        }
        /// <summary>
        /// 大数据界面功率流量压力实时刷新数据
        /// </summary>
        /// <param name="currtime"></param>
        /// <param name="begtime"></param>
        /// <returns></returns>
        public Model.ViewObject.SupplyStackSumpowerpq_VO StackProEpq(DateTime currtime, DateTime begtime)
        {
            DateTime startTime = TimeZone.CurrentTimeZone.ToLocalTime(new System.DateTime(1970, 1, 1, 0, 0, 0, 0));
            var      res       = dal.QueryWhereDesc(f => f.DateTime >= begtime && f.DateTime <= currtime, or => or.OrderByDescending(o => o.DateTime)).Select(f => new
            {
                time     = f.DateTime,
                flow     = f.ProduceFlowStation / 1000,//单位转换
                press    = f.PipelinePressure,
                sumpower = f.SumPower
            }).FirstOrDefault();
            var timezone     = startTime.Ticks;
            var trantimezone = (DateTime.Parse("" + res.time).AddHours(8).Ticks - timezone) / 10000;

            Model.ViewObject.SupplyStackSumpowerpq_VO list = new Model.ViewObject.SupplyStackSumpowerpq_VO()
            {
                time           = trantimezone,
                Power          = Convert.ToInt32(res.sumpower),
                Press          = (decimal)res.press,
                ProduceStation = Convert.ToInt32(res.flow)
            };
            return(list);
        }