1 | <?php |
||
14 | class TranslatableCustomEntityRepository extends CustomEntityRepository |
||
15 | { |
||
16 | /** |
||
17 | * {@inheritdoc} |
||
18 | */ |
||
19 | public function createDatagridQueryBuilder() |
||
30 | |||
31 | /** |
||
32 | * {@inheritdoc} |
||
33 | */ |
||
34 | public function findBySearchQB($search, array $options) |
||
49 | |||
50 | /** |
||
51 | * If the column defined as the sorting one belongs to the entity fields, we filter by this field |
||
52 | * Otherwise, we consider that it's a translation one |
||
53 | * |
||
54 | * {@inheritdoc} |
||
55 | */ |
||
56 | protected function addSortOrder(QueryBuilder $qb) |
||
68 | |||
69 | /** |
||
70 | * Adds select in the findBySearch method |
||
71 | * Used in products datagrid filtering and product edit form |
||
72 | * This method is used by findBySearch method and it's not recommended to call it from elsewhere |
||
73 | * |
||
74 | * {@inheritdoc} |
||
75 | */ |
||
76 | protected function selectFields(QueryBuilder $qb, array $options) |
||
100 | |||
101 | /** |
||
102 | * Adds search on label or code in the findBySearch method |
||
103 | * Used in products datagrid filtering and product edit form |
||
104 | * This method is used by findBySearch method and it's not recommended to call it from elsewhere |
||
105 | * |
||
106 | * {@inheritdoc} |
||
107 | */ |
||
108 | protected function addSearchFilter(QueryBuilder $qb, $search) |
||
123 | } |
||
124 |