public ActionResult CreateWorkflowDefinitionVersion(long workflowDefinitionId) { var workflowDefinitionVersion = new WorkflowDefinitionVersion { IsNew = true }; _workflowDefinitionVersionRepository.Insert(workflowDefinitionVersion); var workflowDefinition = _workflowDefinitionRepository.GetById(workflowDefinitionId); workflowDefinition.WorkflowDefinitionVersions.Add(workflowDefinitionVersion); this._dbContext.SaveChanges(); var model = new WorkflowDefinitionVersionModel(); model = workflowDefinitionVersion.ToModel(); var html = this.WorkflowDefinitionVersionPanel(model); return(Json(new { Id = workflowDefinitionVersion.Id, Html = html })); }
public string WorkflowDefinitionVersionPanel(WorkflowDefinitionVersionModel model) { var html = this.RenderPartialViewToString("_WorkflowDefinitionVersionDetails", model); return(html); }