private void Child_Fetch(StoryData data) { this.StoryId = data.StoryId; this.AssignedTo = data.AssignedTo; this.AssignedToEmail = data.AssignedToUser.Email; this.AssignedToName = data.AssignedToUser.Name; this.AssignedDate = data.AssignedDate; this.CompletedDate = data.CompletedDate; this.Description = data.Description; this.Duration = data.Duration; this.EstimatedCompletedDate = data.EstimatedCompletedDate; this.EstimatedDuration = data.EstimatedDuration; this.IsArchived = data.IsArchived; this.IsCompleted = data.IsCompleted; this.IsOpened = data.IsOpened; this.ProjectId = data.ProjectId; this.ProjectName = data.Project.Name; this.SprintId = data.SprintId; this.SprintName = data.Sprint.Name; this.StartDate = data.StartDate; this.StatusId = data.StatusId; this.StatusName = data.Status.Name; this.ModifiedBy = data.ModifiedBy; this.ModifiedByName = data.ModifiedByUser.Name; this.ModifiedDate = data.ModifiedDate; this.CreatedBy = data.CreatedBy; this.CreatedByName = data.CreatedByUser.Name; this.CreatedDate = data.CreatedDate; }
protected override void DataPortal_Insert() { using (var dalManager = DataFactoryManager.GetManager()) { var dalFactory = dalManager.GetProvider<IStoryDataFactory>(); var data = new StoryData(); using (this.BypassPropertyChecks) { this.ModifiedBy = ((IBusinessIdentity)Csla.ApplicationContext.User.Identity).UserId; this.ModifiedDate = DateTime.Now; this.CreatedBy = this.ModifiedBy; this.CreatedDate = this.ModifiedDate; this.Insert(data); data = dalFactory.Insert(data); this.StoryId = data.StoryId; } // this.FieldManager.UpdateChildren(data); } }
internal static Story FetchStory(StoryData data) { var result = new Story(); result.Fetch(data); result.MarkOld(); return result; }
protected void Update(StoryData data) { data.StoryId = this.StoryId; data.AssignedTo = this.AssignedTo; data.AssignedDate = this.AssignedDate; data.CompletedDate = this.CompletedDate; data.Description = this.Description; data.Duration = this.Duration; data.EstimatedCompletedDate = this.EstimatedCompletedDate; data.EstimatedDuration = this.EstimatedDuration; data.IsArchived = this.IsArchived; data.IsCompleted = this.IsCompleted; data.ProjectId = this.ProjectId; data.SprintId = this.SprintId; data.StartDate = this.StartDate; data.StatusId = this.StatusId; data.ModifiedBy = this.ModifiedBy; data.ModifiedDate = this.ModifiedDate; data.CreatedBy = this.CreatedBy; data.CreatedDate = this.CreatedDate; }
protected void Insert(StoryData data) { this.Update(data); }