/// <summary>
        /// 质检
        /// </summary>
        /// <returns></returns>
        public ObservableCollection <string> Check()
        {
            TotalCount = 0;
            index      = 0.0;

            // 获取总共的条数
            if (Project.NaturalBuildings != null)
            {
                TotalCount += Project.NaturalBuildings.Count;
            }
            if (Project.LogicalBuildings != null)
            {
                TotalCount += Project.LogicalBuildings.Count;
            }
            if (Project.Floors != null)
            {
                TotalCount += Project.Floors.Count;
            }
            if (Project.Households != null)
            {
                TotalCount += Project.Households.Count;
            }
            if (Project.Obligees != null)
            {
                TotalCount += Project.Obligees.Count;
            }
            if (Project.Mortgages != null)
            {
                TotalCount += Project.Mortgages.Count;
            }
            if (Project.Sequestrations != null)
            {
                TotalCount += Project.Sequestrations.Count;
            }
            if (TotalCount == 0)
            {
                ErrorMsg.Add("该项目无数据");
                return(ErrorMsg);
            }

            ProjectMappingType   = (EMappingType)int.Parse(Project.MappingType);
            ProjectOwnershipType = (EOwnershipType)int.Parse(Project.OwnershipType);

            CheckNaturalBuilding();
            CheckLogicalBuilding();
            CheckFloor();
            CheckHousehold();
            CheckObligee();

            if (ProjectOwnershipType == EOwnershipType.OwnershipMakeup)
            {
                CheckMortgage();
                CheckSequestration();
            }

            return(ErrorMsg);
        }
        public Ghost CreateInstance(int prefabId, int?instanceId, Vector3 position, Quaternion rotation, EOwnershipType ownership, Transform parent)
        {
            var prefab   = ownership == EOwnershipType.Owner ? Ghosts[prefabId].OwnerPrefab : Ghosts[prefabId].GhostPrefab;
            var instance = Instantiate(prefab, parent);

            instance.transform.position = position;
            instance.transform.rotation = rotation;
            instance.PrefabId           = prefabId;
            instance.InstanceId         = instanceId ?? instance.GetInstanceID();

            return(instance);
        }