Ejemplo n.º 1
0
 private List <GpsOrbit> GetGPSData(GpsOrbitFilter filter)
 {
     return(PT_BS_Service.Client.Framework.BeOperationInvoker.Invoke <I_CO_IA.Gps.I_CO_IA_Gps, List <GpsOrbit> >(channel =>
     {
         return channel.QueryCurrentGpsOrbit(filter);
     }));
 }
Ejemplo n.º 2
0
        private List <GpsOrbit> LoadData()
        {
            //OrgToMapStyle orgPoint = ucType as OrgToMapStyle;
            //if (orgPoint != null&&orgPoint.OrgInfo!=null&&!string.IsNullOrEmpty(orgPoint.OrgInfo.GUID))
            //{
            GpsOrbitFilter filter = new GpsOrbitFilter();

            filter.RunDate             = Convert.ToDateTime(dE.EditValue);// Convert.ToDateTime("2016-09-19");
            filter.PlateNumber         = VehicleNum;
            filter.ActivityId          = Obj.Activity.Guid;
            filter.RunTimeRange.Little = double.Parse(beginTime.TimeValue.ToString("HHmmss"));
            filter.RunTimeRange.Great  = double.Parse(endTime.TimeValue.ToString("HHmmss"));

            List <GpsOrbit> gpsOrbitlist =
                PT_BS_Service.Client.Framework.BeOperationInvoker.Invoke <I_CO_IA.Gps.I_CO_IA_Gps, List <GpsOrbit> >(channel =>
            {
                return(channel.QueryGpsOrbit(filter));
            });

            return(gpsOrbitlist);
            //}

            //List<MapPointEx> ps = new List<MapPointEx>()
            //    {
            //        Obj.screenMap.GetMapPointEx(108.775554,34.291461),
            //        Obj.screenMap.GetMapPointEx(108.822962, 34.278429),
            //        Obj.screenMap.GetMapPointEx(108.815323, 34.270131),
            //        Obj.screenMap.GetMapPointEx(108.822618, 34.269776),
            //        Obj.screenMap.GetMapPointEx(108.829742, 34.275592),
            //        Obj.screenMap.GetMapPointEx(108.829313, 34.265591),
            //        Obj.screenMap.GetMapPointEx(108.833862, 34.261548)
            //    };
            //return ps;
        }
Ejemplo n.º 3
0
        /// <summary>
        /// 获取id的gps信息
        /// </summary>
        /// <param name="ids"></param>
        /// <returns></returns>
        private Dictionary <string, Point> LoadData(List <string> ids)
        {
            if (ids == null || ids.Count == 0)
            {
                return(null);
            }
            string vehicle_Num = "";

            foreach (string s in ids)
            {
                vehicle_Num += "'" + s + "',";
            }
            vehicle_Num = vehicle_Num.TrimEnd(',');

            Dictionary <string, Point> dic = new Dictionary <string, Point>();

            GpsOrbitFilter filter = new GpsOrbitFilter();

            filter.ActivityId  = Obj.Activity.Guid;
            filter.PlateNumber = vehicle_Num;
            List <GpsOrbit> gpsInfo = GetGPSData(filter);

            if (gpsInfo != null && gpsInfo.Count > 0)
            {
                foreach (var item in gpsInfo)
                {
                    MapUtiles.PointEx px = Obj.clientUtile.Correct(item.Latitude, item.Longitude);
                    dic.Add(item.PlateNumber, new Point(px.X, px.Y));
                }
            }

            return(dic);
        }