From 1c3d072de12f3319cf40fad592835d5dfb301e70 Mon Sep 17 00:00:00 2001 From: Santo Cariotti Date: Sun, 20 Oct 2024 21:58:58 +0200 Subject: Save notification's position info Since we save the last user's position only, we can't be able to link a notification to a position. So, the better thing is to save a redundant lat/lng --- src/graphql/query.rs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'src/graphql/query.rs') diff --git a/src/graphql/query.rs b/src/graphql/query.rs index 96b8a5b..63ca49c 100644 --- a/src/graphql/query.rs +++ b/src/graphql/query.rs @@ -93,13 +93,10 @@ impl Query { /// curl http://localhost:8000/graphql /// -H 'authorization: Bearer ***' /// -H 'content-type: application/json' - /// -d '{"query":"{notifications(seen: false alertId: 1) { + /// -d '{"query":"{notifications { /// id, /// alert { id, userId, createdAt, area, areaLevel2, areaLevel3, text1, text2, text3, reachedUsers }, - /// position {id, userId, createdAt, latitude, longitude, movingActivity}, - /// seen, - /// level, - /// createdAt + /// userId, latitude, longitude, movingActivity, level, seen, createdAt /// }}"}' /// ``` async fn notifications<'ctx>( -- cgit v1.2.3-18-g5258