Skip to content

Commit

Permalink
feat: IDXR-48 changes to top collection trending weightage (#1191)
Browse files Browse the repository at this point in the history
idxr-48 changes to top collection trending weightage
  • Loading branch information
justraman authored Jul 28, 2024
1 parent e0dd6b0 commit 4cf4deb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/server-extension/resolvers/top_collections.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,10 @@ export class TopCollectionResolver {
.createQueryBuilder()
.select('*')
.addSelect(
'COALESCE(0.20 * (volume / NULLIF(MAX(volume) OVER(), 0)),0) + ' +
'COALESCE(0.35 * (volume / NULLIF(MAX(volume) OVER(), 0)),0) + ' +
'COALESCE(0.35 * (sales / NULLIF(MAX(sales) OVER(), 0)), 0) +' +
'COALESCE(0.20 * (avg_sale_change / NULLIF(MAX(avg_sale_change) OVER(), 0)),0) +' +
'COALESCE(0.25 * (users / NULLIF(MAX(users) OVER(), 0)), 0) AS trending_score'
'COALESCE(0.10 * (users / NULLIF(MAX(users) OVER(), 0)), 0) AS trending_score'
)
.addSelect(
'COALESCE(0.80 * (volume / NULLIF(MAX(volume) OVER(), 0)),0) + ' +
Expand Down

0 comments on commit 4cf4deb

Please sign in to comment.