Skip to content

Commit

Permalink
Merge pull request #5087 from 3liz/backport-5081-to-release_3_9
Browse files Browse the repository at this point in the history
[Backport release_3_9] Speed up main view with project main data
  • Loading branch information
rldhont authored Dec 5, 2024
2 parents 2c1f580 + ab71b50 commit 84a22a6
Show file tree
Hide file tree
Showing 8 changed files with 708 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public function getData($form)
if ($criteria && array_key_exists($criteria, $this->data)) {
$rep = lizmap::getRepository($criteria);
// Get projects metadata
$metadata = $rep->getProjectsMetadata();
$metadata = $rep->getProjectsMainData();
foreach ($metadata as $meta) {
if ($meta->getHidden()) {
continue;
Expand Down
5 changes: 5 additions & 0 deletions lizmap/modules/lizmap/classes/lizmapRepository.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,11 @@ public function getProjectsMetadata()
return $this->repo->getProjectsMetadata();
}

public function getProjectsMainData()
{
return $this->repo->getProjectsMainData();
}

/**
* Return the value of the Access-Control-Allow-Origin HTTP header.
*
Expand Down
Loading

0 comments on commit 84a22a6

Please sign in to comment.