From 19cb7c9c9c7eab9bf542906e5c1c7bf8fdf96683 Mon Sep 17 00:00:00 2001 From: Valentin Cocaud Date: Sun, 7 Mar 2021 20:50:53 +0100 Subject: [PATCH] :lock: fix permissions for sopping list ingredients --- docker-compose.yaml | 2 +- hasura/metadata/tables.yaml | 9 +++++++-- package.json | 2 +- yarn.lock | 8 ++++---- 4 files changed, 13 insertions(+), 8 deletions(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index 0c14877..884c630 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -11,7 +11,7 @@ services: volumes: - db_data:/var/lib/postgresql/data graphql-engine: - image: hasura/graphql-engine:v1.3.0 + image: hasura/graphql-engine:v1.3.3 ports: - "8080:8080" depends_on: diff --git a/hasura/metadata/tables.yaml b/hasura/metadata/tables.yaml index 312de72..21572c4 100644 --- a/hasura/metadata/tables.yaml +++ b/hasura/metadata/tables.yaml @@ -409,8 +409,13 @@ - unit filter: shoppingList: - user_id: - _eq: X-Hasura-User-Id + _or: + - user_id: + _eq: X-Hasura-User-Id + - user: + sharingWith: + shared_to_user_id: + _eq: X-Hasura-User-Id allow_aggregations: true - table: schema: public diff --git a/package.json b/package.json index 6f28b07..de28ea5 100644 --- a/package.json +++ b/package.json @@ -24,6 +24,6 @@ "eslint-plugin-node": "^11.1.0", "eslint-plugin-promise": "^4.2.1", "eslint-plugin-standard": "^4.0.1", - "hasura-cli": "^1.3.0-beta.2" + "hasura-cli": "^1.3.3" } } diff --git a/yarn.lock b/yarn.lock index 98e71d6..d2cff0e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1097,10 +1097,10 @@ has@^1.0.3: dependencies: function-bind "^1.1.1" -hasura-cli@^1.3.0-beta.2: - version "1.3.0-beta.2" - resolved "https://registry.yarnpkg.com/hasura-cli/-/hasura-cli-1.3.0-beta.2.tgz#5e02234e07ccae4a4d1d932334cd8f6d0252e518" - integrity sha512-nSUpUHIJVJ4c03oFljnDAB8P75Ai/wQ4cXclaUh8Z90fA07LJfo5yoZVvwAXEZg/GSJRZdjvR2/eGt5t2YhRog== +hasura-cli@^1.3.3: + version "1.3.3" + resolved "https://registry.yarnpkg.com/hasura-cli/-/hasura-cli-1.3.3.tgz#8673d1c5748f9d8a05f0adacde6e3b446f0406a4" + integrity sha512-bIZaI+RIjTotqeHJpwByyvVQvS/EDoHdDcizcvFSPKSsh7Zehro9ZwyyPmvtIEvDn1EI3I2s5vxAVOOJrJR5qw== dependencies: axios "^0.19.0" chalk "^2.4.2"