This commit is contained in:
parent
37346aaede
commit
7c17e1d0d0
1 changed files with 3 additions and 3 deletions
|
@ -63,7 +63,7 @@ export default class UserEffect extends AppBaseEntity {
|
||||||
|
|
||||||
const query = await repository.createQueryBuilder("effect")
|
const query = await repository.createQueryBuilder("effect")
|
||||||
.where("effect.UserId = :userId", { userId })
|
.where("effect.UserId = :userId", { userId })
|
||||||
.where("effect.Unused > 0")
|
.andWhere("effect.Unused > 0")
|
||||||
.orderBy("effect.Name", "ASC")
|
.orderBy("effect.Name", "ASC")
|
||||||
.skip(page * itemsPerPage)
|
.skip(page * itemsPerPage)
|
||||||
.take(itemsPerPage)
|
.take(itemsPerPage)
|
||||||
|
@ -77,7 +77,7 @@ export default class UserEffect extends AppBaseEntity {
|
||||||
|
|
||||||
const query = await repository.createQueryBuilder("effect")
|
const query = await repository.createQueryBuilder("effect")
|
||||||
.where("effect.UserId = :userId", { userId })
|
.where("effect.UserId = :userId", { userId })
|
||||||
.where("effect.WhenExpires IS NOT NULL")
|
.andWhere("effect.WhenExpires IS NOT NULL")
|
||||||
.andWhere("effect.WhenExpires > :now", { now: new Date() })
|
.andWhere("effect.WhenExpires > :now", { now: new Date() })
|
||||||
.getOne();
|
.getOne();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue