Skip to content

Commit 5d9424b

Browse files
author
Kristof Jochmans
committed
performance improvements: added db indexes
1 parent c4a5d19 commit 5d9424b

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

Entity/PagePartRef.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
<?php
22

33
namespace Kunstmaan\PagePartBundle\Entity;
4+
45
use Doctrine\ORM\Mapping as ORM;
56
use Doctrine\ORM\EntityManager;
67

78
/**
89
* Reference between a page and a pagepart
910
*
1011
* @ORM\Entity(repositoryClass="Kunstmaan\PagePartBundle\Repository\PagePartRefRepository")
11-
* @ORM\Table(name="kuma_page_part_refs")
12+
* @ORM\Table(name="kuma_page_part_refs", indexes={@ORM\Index(name="idx_kuma_search", columns={"pageId", "pageEntityname", "context"})})
1213
* @ORM\HasLifecycleCallbacks()
1314
*/
1415
class PagePartRef

Entity/PageTemplateConfiguration.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* Configuration for page templates
1111
*
1212
* @ORM\Entity(repositoryClass="Kunstmaan\PagePartBundle\Repository\PageTemplateConfigurationRepository")
13-
* @ORM\Table(name="kuma_page_template_configuration")
13+
* @ORM\Table(name="kuma_page_template_configuration", indexes={@ORM\Index(name="idx_kuma_search", columns={"page_id", "page_entity_name"})})
1414
*/
1515
class PageTemplateConfiguration extends AbstractEntity
1616
{

0 commit comments

Comments
 (0)