cas issue sans colonne dans la vue stat

This commit is contained in:
afornerot 2023-12-18 12:11:31 +01:00
parent 090471aa9e
commit dfb8eb6236

View File

@ -220,7 +220,7 @@ class ScrumController extends AbstractController
$em = $this->getDoctrine()->getManager();
$data=$em->getRepository($this->entity)->find($id);
if(!$data) return $this->redirectToRoute($this->route);
$em->getRepository("App:Scrum")->getGitea($data,$giteaassignees,$giteacolumns,$giteamilestones,$giteateams,$giteaprioritys,$giteatypes,$gitealabels);
// Préférences utilisateur
@ -251,7 +251,9 @@ class ScrumController extends AbstractController
$tbstat[$idmilestone]=["id"=>$idmilestone,"name"=>$lbmilestone,"stat"=>[]];
}
$ordercolumns=array_search($issue->getScrumcolumn()->getGiteaid(),$giteacolumns);
if(!$issue->getScrumcolumn()) $ordercolumns=0;
else $ordercolumns=array_search($issue->getScrumcolumn()->getGiteaid(),$giteacolumns);
//$ordercolumns=$issue->getScrumcolumn()->getId();
if(!array_key_exists($ordercolumns,$tbstat[$idmilestone]["stat"])) {
$tbstat[$idmilestone]["stat"][$ordercolumns]=[
@ -264,7 +266,7 @@ class ScrumController extends AbstractController
}
foreach($labels as $label) {
if($issue->getScrumcolumn()->getGiteaid()!=$label["id"]) {
if($ordercolumns!=$label["id"]) {
if(!array_key_exists($label["id"],$tbstat[$idmilestone]["stat"][$ordercolumns]["labels"])) {
$tbstat[$idmilestone]["stat"][$ordercolumns]["labels"][$label["id"]] = [
"id"=>$label["id"],