This commit is contained in:
2026-08-07 21:42:12 +02:00
parent c7414e4b21
commit feb408338a
40 changed files with 927 additions and 229 deletions

View File

@@ -97,11 +97,11 @@ export default (router, tpl) => {
`;
const favotop = await db`
select favorites.item_id, count(*) favs
select favorites.item_id as id, items.slug, count(*) favs
from favorites
join items on items.id = favorites.item_id
where items.active = true
group by favorites.item_id
group by favorites.item_id, items.slug
having count(*) > 1
order by favs desc
limit 10
@@ -110,7 +110,7 @@ export default (router, tpl) => {
let xdtop = [];
if (config.websrv.enable_xd_score) {
const xdRows = await db`
select id, xd_score
select id, slug, xd_score
from items
where active = true and is_deleted = false and xd_score > 0
order by xd_score desc