public void LoadModel(string projectPath)
        {
            _projectPath = projectPath;
            var project = _projectLoader.Load(projectPath);

            _currentProject = project;
            Model           = new SpaceProjectDetails();
            Model.Schemas   = project.Schemas.Values.Select(x => new SchemaDetails {
                Schema = x, SchemaMigrations = project.SchemaMigrations[x.Name]
            }).ToList();
            Model.Queries = project.Queries.Values.Select(x => new QueryDetails {
                Query = x
            }).ToList();
            Model.Forms = project.Forms.Values.Select(x => new FormDetails {
                Form = x
            }).ToList();

            Model.EditWindows = project.Settings.EditWindows.Select(
                s =>
            {
                var obj = FindModelStoreObject(s);
                return(new EditWindowDetails {
                    StoreObject = obj, StoreObjectDetails = FindModelStoreObjectDetails(obj)
                });
            }).ToList();

            Model.EditWindows.ForEach(w => w.Type = GetStoreObjectType(w.StoreObject));
            UpdateFormBuilder();
        }
 public void CreateNewProject()
 {
     Model = new SpaceProjectDetails();
 }