Ejemplo n.º 1
0
 public ActionResult EditModel()
 {
     var model = new BlockModelViewModel
     {
         FileNames = BlockModelService.GetFileNameList(),
         FormatFileNames = BlockModelService.GetFormatFileNameList(),
         Projects = ProjectService.GetProjectList()
     };
     model.Stages = ProjectService.GetStagesList(new Guid(model.Projects.First().Value));
     return View(model);
 }
Ejemplo n.º 2
0
 public ActionResult ImportModel() {
     var model = new BlockModelViewModel
     {
         FileNames = BlockModelService.GetFileNameList(),
         FormatFileNames = BlockModelService.GetFormatFileNameList(),
         Projects = ProjectService.GetProjectListCurrent()
     };
     model.Stages = model.Projects.Any() ? ProjectService.GetStagesList(new Guid(model.Projects.First().Value)) : new SelectList(new SelectListItem[] { });
     return View("ImportModel", model);
 }
Ejemplo n.º 3
0
        public ActionResult ImportModelProcessStart(BlockModelViewModel m) {

            if (!ModelState.IsValid)
                return ImportModel();

            // TODO do some processing here
            string bmFile = m.FileName;

            string formatSpecFile = m.FormatFileName;// "gf_compact_bm_format.xml";
            double xOrigin = m.XOrigin;
            double yOrigin = m.YOrigin;
            double zOrigin = m.ZOrigin; 
            string projID = m.Project;
            string alias = m.Alias;
            string notes = m.Notes;
            string stage = m.Stage;
            Guid gg = PrivateService.XODB_BM_STAGE;
            BlockModelService.ProcessModelAsync(bmFile, formatSpecFile, projID, alias, this.getCurrentUserID(), notes, stage, gg, 60);
            return View(m);
        }