mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
order by indexId instead of createdAt
This commit is contained in:
parent
b933305cad
commit
54cf5b37a5
@ -17,7 +17,7 @@ export const createMessageMutation = () => {
|
||||
export const messageQuery = () => {
|
||||
return gql`
|
||||
query ($roomId: ID!, $first: Int, $offset: Int) {
|
||||
Message(roomId: $roomId, first: $first, offset: $offset, orderBy: createdAt_desc) {
|
||||
Message(roomId: $roomId, first: $first, offset: $offset, orderBy: indexId_desc) {
|
||||
_id
|
||||
id
|
||||
indexId
|
||||
|
||||
@ -3,8 +3,7 @@
|
||||
# }
|
||||
|
||||
enum _MessageOrdering {
|
||||
createdAt_asc
|
||||
createdAt_desc
|
||||
indexId_desc
|
||||
}
|
||||
|
||||
type Message {
|
||||
|
||||
@ -3,7 +3,7 @@ import gql from 'graphql-tag'
|
||||
export const messageQuery = () => {
|
||||
return gql`
|
||||
query ($roomId: ID!, $first: Int, $offset: Int) {
|
||||
Message(roomId: $roomId, first: $first, offset: $offset, orderBy: createdAt_desc) {
|
||||
Message(roomId: $roomId, first: $first, offset: $offset, orderBy: indexId_desc) {
|
||||
_id
|
||||
id
|
||||
indexId
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user