stable
Clone or download
Part of story #35104 Milestones below Backlog To retrieve milestones and their sub-milestones, there is already several methods to do this. But it makes several queries to database and too much overhead time. Instead we choose to craft a single query which retrieves all we need. We first retrieve the top milestone tracker of project with a pre-existing query, then the new query find all opened artifacts of this tracker. It also finds opened artifact links to the first ones with type '_is_child'. The backend then gets the result of this query and filter it by checking timeframe, title and count (limit 5). *Testing:* In a project with Backlog service enabled 1. **Normal case** Create some releases and sprints in it (more than 5). Set timeframes with different values (past, present, future) both for releases and sprints. Shuffle status (open and close) Result: Sidebar should display at most 5 items, all should be opened and in current timeframe. Note: An opened release can be displayed even if all its sprints are closed 2. **Limit cases** - Link a bug to a current opened release with type '_is_child' - Add a third planning level (under sprints) with artifacts Result: None of added artifacts should be displayed Change-Id: I19a19aa7c537dcf0d6afa36b136a415b927f829d
Modified Files
Name | ||||
---|---|---|---|---|
M | plugins/agiledashboard/composer.json | +1 | −1 | Go to diff View file |
D | plugins/agiledashboard/include/AgileDashboard/Milestone/AgileDashboardPromotedMilestonesRetriever.php | +0 | −100 | Go to diff View file |
A | plugins/agiledashboard/include/AgileDashboard/Milestone/Sidebar/AgileDashboardPromotedMilestonesRetriever.php | +257 | −0 | Go to diff View file |
A | plugins/agiledashboard/include/AgileDashboard/Milestone/Sidebar/MilestoneDao.php | +102 | −0 | Go to diff View file |
A | plugins/agiledashboard/include/AgileDashboard/Milestone/Sidebar/RetrieveMilestonesWithSubMilestones.php | +28 | −0 | Go to diff View file |
M | plugins/agiledashboard/include/AgileDashboardService.php | +23 | −3 | Go to diff View file |
M | plugins/agiledashboard/include/Planning/PlanningFactory.class.php | +10 | −0 | Go to diff View file |
A | plugins/agiledashboard/tests/integration/Builders/DatabaseBuilder.php | +251 | −0 | Go to diff View file |
A | plugins/agiledashboard/tests/integration/Milestone/Sidebar/MilestoneDaoTest.php | +351 | −0 | Go to diff View file |
D | plugins/agiledashboard/tests/unit/AgileDashboard/Milestone/AgileDashboardPromotedMilestonesRetrieverTest.php | +0 | −138 | Go to diff View file |
A | plugins/agiledashboard/tests/unit/AgileDashboard/Milestone/Sidebar/AgileDashboardPromotedMilestonesRetrieverTest.php | +485 | −0 | Go to diff View file |
A | plugins/agiledashboard/tests/unit/Stub/Milestone/RetrieveMilestonesWithSubMilestonesStub.php | +84 | −0 | Go to diff View file |
M | plugins/kanban/include/Kanban/Service/KanbanService.php | +1 | −0 | Go to diff View file |
M | plugins/tracker/include/Tracker/Artifact/Creation/TrackerArtifactCreator.class.php | +1 | −2 | Go to diff View file |
M | plugins/tracker/include/Tracker/Semantic/Timeframe/SemanticTimeframeBuilder.php | +27 | −6 | Go to diff View file |
M | plugins/tracker/include/Tracker/Service/SidebarPromotedTrackerRetriever.php | +1 | −0 | Go to diff View file |
M | src/common/Layout/SidebarPromotedItemPresenter.php | +4 | −0 | Go to diff View file |