Skip to content

Commit

Permalink
Calling new sprintReport methods from controller
Browse files Browse the repository at this point in the history
  • Loading branch information
jeppekroghitk committed Dec 12, 2023
1 parent 946d358 commit f53d3c4
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/Controller/SprintReportController.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ public function index(Request $request): Response
'csrf_protection' => false,
]);

$projects = $this->projectTracker->getAllProjects();
$projectCollection = $this->projectTracker->getAllProjectsV2();

$projectChoices = [];

foreach ($projects as $project) {
foreach ($projectCollection->projects as $project) {
$projectChoices[$project->name] = $project->id;
}

Expand All @@ -66,11 +66,11 @@ public function index(Request $request): Response
}

if (!empty($requestData['projectId'])) {
$project = $this->projectTracker->getProject($requestData['projectId']);
$versions = $this->projectTracker->getProjectMilestones($requestData['projectId']);
$project = $this->projectTracker->getProjectV2($requestData['projectId']);
$versionCollection = $this->projectTracker->getProjectVersions($requestData['projectId']);

$versionChoices = [];
foreach ($versions as $version) {
foreach ($versionCollection->versions as $version) {
$versionChoices[$version->headline] = $version->id;
}

Expand Down

0 comments on commit f53d3c4

Please sign in to comment.