Exemplo n.º 1
0
    // Start is called before the first frame update
    void Start()
    {
        Instance    = this;
        pathfinders = new GameObject[this.transform.childCount];

        for (int i = 0; i < pathfinders.Length; i++)
        {
            pathfinders[i] = this.transform.GetChild(i).gameObject;
        }
    }
Exemplo n.º 2
0
 private static void SetPatrolPointProperty(int Id, checkpoints item2, DbModel.Location.Work.PatrolPoint now)
 {
     now.ParentId   = Id;
     now.StaffCode  = item2.staffCode;
     now.StaffName  = item2.staffName;
     now.KksCode    = item2.kksCode;
     now.DevName    = item2.deviceName;
     now.DeviceCode = item2.deviceCode;
     now.DeviceId   = item2.deviceId;
     //if (dev1 != null)
     //{
     //    now.DevId = dev1.Id;
     //}
 }
        public checkpoints GetCheckPoints(string url)
        {
            checkpoints recv = new checkpoints();

            try
            {
                recv = WebApiHelper.GetEntity <checkpoints>(url);
                if (recv == null)
                {
                    return(null);
                }
                //if (recv.checks == null)
                //{
                //    recv.checks = new List<results>();
                //}
            }
            catch (Exception ex)
            {
                Message = ex.Message;
                return(null);
            }
            return(recv);
        }
Exemplo n.º 4
0
        private void DataGridRouteList_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (pd == null)
            {
                return;
            }
            checkpoints route = DataGridRouteList.SelectedItem as checkpoints;

            if (route == null)
            {
                return;
            }
            var checkResult = trackClient.Getcheckresults(pd.id, route.deviceId);

            foreach (var item in checkResult.checks)
            {
                var d1 = kksList.FindAll(i => i.Code.Contains(item.kksCode));
                if (d1.Count > 0)
                {
                    //item.deviceName = d1[0].Name;
                }
            }
            DataGridCheckList.ItemsSource = checkResult.checks;
        }
Exemplo n.º 5
0
 void Start()
 {
     gameController = GameObject.FindWithTag("GameController");
     worldSwitch    = gameController.GetComponent <WorldSwitch>();
     checkpoint     = gameController.GetComponent <checkpoints>();
 }
Exemplo n.º 6
0
 private static DbModel.LocationHistory.Work.PatrolPointHistory CreatePatrolPointHistory(int Id, checkpoints item2)
 {
     DbModel.LocationHistory.Work.PatrolPointHistory history = new DbModel.LocationHistory.Work.PatrolPointHistory();
     history.ParentId   = Id;
     history.StaffCode  = item2.staffCode;
     history.StaffName  = item2.staffName;
     history.KksCode    = item2.kksCode;
     history.DevName    = item2.deviceName;
     history.DeviceCode = item2.deviceCode;
     history.DeviceId   = item2.deviceId;
     //if (dev1 != null)
     //{
     //    history.DevId = dev1.Id;
     //}
     return(history);
 }