Sort notifications by createdAt
ci/woodpecker/tag/ociImageTag Pipeline was successful
Details
ci/woodpecker/tag/ociImageTag Pipeline was successful
Details
This commit is contained in:
parent
4a7cd41a90
commit
96c748f807
|
@ -37,6 +37,8 @@ export const paramDef = {
|
||||||
limit: { type: "integer", minimum: 1, maximum: 100, default: 10 },
|
limit: { type: "integer", minimum: 1, maximum: 100, default: 10 },
|
||||||
sinceId: { type: "string", format: "misskey:id" },
|
sinceId: { type: "string", format: "misskey:id" },
|
||||||
untilId: { type: "string", format: "misskey:id" },
|
untilId: { type: "string", format: "misskey:id" },
|
||||||
|
sinceDate: { type: "integer" },
|
||||||
|
untilDate: { type: "integer" },
|
||||||
following: { type: "boolean", default: false },
|
following: { type: "boolean", default: false },
|
||||||
unreadOnly: { type: "boolean", default: false },
|
unreadOnly: { type: "boolean", default: false },
|
||||||
markAsRead: { type: "boolean", default: true },
|
markAsRead: { type: "boolean", default: true },
|
||||||
|
@ -87,6 +89,8 @@ export default define(meta, paramDef, async (ps, user) => {
|
||||||
Notifications.createQueryBuilder("notification"),
|
Notifications.createQueryBuilder("notification"),
|
||||||
ps.sinceId,
|
ps.sinceId,
|
||||||
ps.untilId,
|
ps.untilId,
|
||||||
|
ps.sinceDate,
|
||||||
|
ps.untilDate
|
||||||
)
|
)
|
||||||
.andWhere("notification.notifieeId = :meId", { meId: user.id })
|
.andWhere("notification.notifieeId = :meId", { meId: user.id })
|
||||||
.leftJoinAndSelect("notification.notifier", "notifier")
|
.leftJoinAndSelect("notification.notifier", "notifier")
|
||||||
|
|
Loading…
Reference in New Issue