mirror of
https://framagit.org/les/gancio.git
synced 2025-02-01 00:52:01 +01:00
get confirmed tag/place only
This commit is contained in:
parent
f9f29154a2
commit
847801033f
1 changed files with 2 additions and 0 deletions
|
@ -24,6 +24,7 @@ const eventController = {
|
|||
|
||||
async _getMeta () {
|
||||
const places = await Place.findAll({
|
||||
where: { confirmed: true },
|
||||
order: [[Sequelize.literal('weigth'), 'DESC']],
|
||||
attributes: {
|
||||
include: [[Sequelize.fn('count', Sequelize.col('events.placeId')), 'weigth']],
|
||||
|
@ -34,6 +35,7 @@ const eventController = {
|
|||
})
|
||||
|
||||
const tags = await Tag.findAll({
|
||||
where: { confirmed: true },
|
||||
raw: true,
|
||||
order: [['weigth', 'DESC']],
|
||||
attributes: {
|
||||
|
|
Loading…
Reference in a new issue