void ITaskFolderService.Create(TaskFolder folder) { _repository.Add(folder); if (this._log.IsInfoEnabled) { this._log.InfoFormat("新增任务表{0}#{1}|{2}", folder, folder.ID, folder.Name); } }
void ITaskFolderService.Delete(TaskFolder folder) { _repository.Remove(folder); //HACK:目前不会删除任务表下的所有任务 if (this._log.IsInfoEnabled) { this._log.InfoFormat("删除任务表#{0}", folder.ID); } }
/// <summary>设置任务所在的任务目录 /// </summary> /// <param name="folder"></param> public void SetTaskFolder(TaskFolder folder) { Assert.IsValid(folder); if (this.TaskFolderId == folder.ID) { return; } if (folder is PersonalTaskFolder) { Assert.AreEqual(this.CreatorAccountId, (folder as PersonalTaskFolder).OwnerAccountId); } this.TaskFolderId = folder.ID; this.MakeChange(); }
void ITaskFolderService.Update(TaskFolder folder) { _repository.Update(folder); }
IEnumerable <PersonalTask> IPersonalTaskService.GetIncompletedTasks(Account account, TaskFolder folder) { return(_repository.FindBy(account, false, folder)); }