public static List <Project> GetProjectsList(int page) { int takeCount = Config.PageItemCount(); int skipCount = page * takeCount; return(ProjectsRepositories.GetProjectsList(skipCount, takeCount)); }
public static List <ProjectUserDetails> GetUserProjectList(int page, int userId) { int takeCount = Config.PageItemCount(); int skipCount = page * takeCount; return(ProjectsRepositories.GetProjectUserList(userId, skipCount, takeCount)); }
public static CreateSuggestionModel UpdateProjectsList(CreateSuggestionModel model) { model.Projects = ProjectsRepositories.GetAllProjects(); model.Projects.Insert(0, (new Project { Name = "General", Id = 0 })); return(model); }
public static List <string> AutocompleteProjects(int sprintId, bool isInSprint) { if (isInSprint) { return(ProjectsRepositories.AutocompleteProjectsInSprint(sprintId)); } return(ProjectsRepositories.AutocompleteProjectsNotInSprint(sprintId)); }
public static bool InsertProjectSprint(int sprintId, string projectName, int userId) { return(ProjectsRepositories.InsertSprintProject(sprintId, new Project() { CreateDate = DateTimeHelper.Today(), UpdateDate = DateTimeHelper.Today(), CreatorId = userId, Name = projectName })); }
public static CreateSuggestionModel GetEditSuggestionModel(int suggestionId) { CreateSuggestionModel model = new CreateSuggestionModel(); model.Projects = ProjectsRepositories.GetAllProjects(); model.Projects.Insert(0, (new Project { Name = "General", Id = 0 })); model.Suggestion = SuggestionsRepositories.GetSuggestionById(suggestionId); return(model); }
public static bool InsertNewSprintProject(int sprintId, string projectName) { Project project = ProjectsRepositories.GetProjectByName(projectName); if (project != null) { SprintsRepositories.InsertNewSprintProject(new SprintProject { SprintId = sprintId, ProjectId = project.Id }); return(true); } return(false); }
public static StoriesIndexModel GetStoriesIndexModel(StoriesFilter storiesFilter, int projectId) { Project project = new Project(); StoriesIndexModel model = new StoriesIndexModel { projectId = projectId, OrderedByName = storiesFilter.OrderedByName, Reviewed = storiesFilter.Reviewed, SearchText = storiesFilter.SearchText }; if (projectId != 0) { project = ProjectsRepositories.GetProjectById(projectId); model.projectName = project.Name; } return(model); }
public static void DeleteProject(int id) { ProjectsRepositories.DeleteProject(id); }
public static void UpdateProject(Project project) { ProjectsRepositories.UpdateProject(project); }
public static void InsertNewProject(Project project) { ProjectsRepositories.InsertNewProject(project); }
public static Project GetProjectById(int id) { return(ProjectsRepositories.GetProjectById(id)); }
public static List <SprintProjectsDetails> GetProjectsBySprintId(int sprintId, string searchTxt) { return(ProjectsRepositories.GetProjectsBySprintId(sprintId, searchTxt)); }
public static List <Project> GetProjectlist() { return(ProjectsRepositories.GetProjectlist()); }
public static List <Project> GetProjectsBySprints(int sprintId) { return(ProjectsRepositories.GetProjectsBySprints(sprintId)); }
public static void UpdateProject(Project project) { DateTime myDate = DateTimeHelper.Today(); ProjectsRepositories.UpdateProject(project, myDate); }