From c5c521469a63c1e1cf9399b443d56f3f070b09cd Mon Sep 17 00:00:00 2001 From: Jessica McInchak Date: Fri, 1 Dec 2023 16:55:04 +0000 Subject: [PATCH] fix: api client should be able to select * from `payment_status` (#2527) --- hasura.planx.uk/metadata/tables.yaml | 12 ++++++++++++ hasura.planx.uk/tests/payment_status.test.js | 6 +++--- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/hasura.planx.uk/metadata/tables.yaml b/hasura.planx.uk/metadata/tables.yaml index eb5be3e98f..5a9fc7c2a5 100644 --- a/hasura.planx.uk/metadata/tables.yaml +++ b/hasura.planx.uk/metadata/tables.yaml @@ -1002,6 +1002,18 @@ - flow_id - session_id - amount + select_permissions: + - role: api + permission: + columns: + - payment_id + - status + - team_slug + - created_at + - flow_id + - session_id + - amount + filter: {} - table: schema: public name: payment_status_enum diff --git a/hasura.planx.uk/tests/payment_status.test.js b/hasura.planx.uk/tests/payment_status.test.js index db1ff42490..6bcc81d3a0 100644 --- a/hasura.planx.uk/tests/payment_status.test.js +++ b/hasura.planx.uk/tests/payment_status.test.js @@ -73,9 +73,9 @@ describe("payment_status", () => { i = await introspectAs("api"); }); - test("cannot query payment_status", () => { - expect(i.queries).not.toContain("payment_status"); - }) + test("can query payment_status", () => { + expect(i.queries).toContain("payment_status"); + }); test("can insert payment_status", () => { expect(i.mutations).toContain("insert_payment_status");