allow daily discussion to appear in recent
This commit is contained in:
parent
cef122141f
commit
b68fadc63d
@ -120,7 +120,7 @@ export default {
|
|||||||
items = await models.$queryRaw(`
|
items = await models.$queryRaw(`
|
||||||
${SELECT}
|
${SELECT}
|
||||||
FROM "Item"
|
FROM "Item"
|
||||||
WHERE "parentId" IS NULL AND created_at <= $1 AND "pinId" IS NULL
|
WHERE "parentId" IS NULL AND created_at <= $1
|
||||||
${subClause(3)}
|
${subClause(3)}
|
||||||
${activeOrMine()}
|
${activeOrMine()}
|
||||||
ORDER BY created_at DESC
|
ORDER BY created_at DESC
|
||||||
|
@ -183,8 +183,6 @@ export default {
|
|||||||
await models.user.update({ where: { id: me.id }, data: { checkedNotesAt: new Date() } })
|
await models.user.update({ where: { id: me.id }, data: { checkedNotesAt: new Date() } })
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log(decodedCursor)
|
|
||||||
|
|
||||||
return {
|
return {
|
||||||
lastChecked: checkedNotesAt,
|
lastChecked: checkedNotesAt,
|
||||||
earn,
|
earn,
|
||||||
|
@ -113,8 +113,6 @@ function Notification ({ n }) {
|
|||||||
export default function Notifications ({ notifications, earn, cursor, lastChecked, variables }) {
|
export default function Notifications ({ notifications, earn, cursor, lastChecked, variables }) {
|
||||||
const { data, fetchMore } = useQuery(NOTIFICATIONS, { variables })
|
const { data, fetchMore } = useQuery(NOTIFICATIONS, { variables })
|
||||||
|
|
||||||
console.log(data)
|
|
||||||
|
|
||||||
if (data) {
|
if (data) {
|
||||||
({ notifications: { notifications, earn, cursor } } = data)
|
({ notifications: { notifications, earn, cursor } } = data)
|
||||||
}
|
}
|
||||||
|
@ -52,6 +52,7 @@ export const ITEMS = gql`
|
|||||||
cursor
|
cursor
|
||||||
items {
|
items {
|
||||||
...ItemFields
|
...ItemFields
|
||||||
|
position
|
||||||
},
|
},
|
||||||
pins {
|
pins {
|
||||||
...ItemFields
|
...ItemFields
|
||||||
|
Loading…
x
Reference in New Issue
Block a user