mirror of
https://github.com/bpatrik/pigallery2.git
synced 2025-02-05 13:25:08 +02:00
fixing searching bug
This commit is contained in:
parent
7576e1678f
commit
bbef7f3e85
@ -92,7 +92,7 @@ export class SearchManager implements ISearchManager {
|
||||
};
|
||||
|
||||
const query = connection
|
||||
.getRepository(PhotoEntity)
|
||||
.getRepository(MediaEntity)
|
||||
.createQueryBuilder('media')
|
||||
.innerJoinAndSelect('media.directory', 'directory')
|
||||
.orderBy('media.metadata.creationDate', 'ASC');
|
||||
@ -150,7 +150,7 @@ export class SearchManager implements ISearchManager {
|
||||
};
|
||||
|
||||
result.media = await connection
|
||||
.getRepository(PhotoEntity)
|
||||
.getRepository(MediaEntity)
|
||||
.createQueryBuilder('media')
|
||||
.orderBy('media.metadata.creationDate', 'ASC')
|
||||
.where('media.metadata.keywords LIKE :text COLLATE utf8_general_ci', {text: '%' + text + '%'})
|
||||
|
Loading…
x
Reference in New Issue
Block a user