From 4924c8850ad6f370792ae17206619e2a3854a04b Mon Sep 17 00:00:00 2001 From: Gustavo Trott Date: Thu, 11 Apr 2024 12:06:20 -0300 Subject: [PATCH] Add graphql type caption_typed_activeLocales --- bbb-graphql-server/bbb_schema.sql | 7 +++++ .../public_v_caption_typed_activeLocales.yaml | 27 +++++++++++++++++++ .../BigBlueButton/tables/tables.yaml | 1 + 3 files changed, 35 insertions(+) create mode 100644 bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_caption_typed_activeLocales.yaml diff --git a/bbb-graphql-server/bbb_schema.sql b/bbb-graphql-server/bbb_schema.sql index 15d0232096..c59f850a10 100644 --- a/bbb-graphql-server/bbb_schema.sql +++ b/bbb-graphql-server/bbb_schema.sql @@ -1693,6 +1693,13 @@ SELECT * FROM "caption" WHERE "createdAt" > current_timestamp - INTERVAL '5 seconds'; +CREATE OR REPLACE VIEW "v_caption_typed_activeLocales" AS +select distinct "meetingId", "lang", "userId" +from "caption" +where "captionType" = 'TYPED'; + +create index "idx_caption_typed_activeLocales" on caption("meetingId","lang","userId") where "captionType" = 'TYPED'; + ------------------------------------ ---- diff --git a/bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_caption_typed_activeLocales.yaml b/bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_caption_typed_activeLocales.yaml new file mode 100644 index 0000000000..9b7787be24 --- /dev/null +++ b/bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_caption_typed_activeLocales.yaml @@ -0,0 +1,27 @@ +table: + name: v_caption_typed_activeLocales + schema: public +configuration: + column_config: {} + custom_column_names: {} + custom_name: caption_typed_activeLocales + custom_root_fields: {} +object_relationships: + - name: userOwner + using: + manual_configuration: + column_mapping: + userId: userId + insertion_order: null + remote_table: + name: v_user_ref + schema: public +select_permissions: + - role: bbb_client + permission: + columns: + - lang + filter: + meetingId: + _eq: X-Hasura-MeetingId + comment: "" diff --git a/bbb-graphql-server/metadata/databases/BigBlueButton/tables/tables.yaml b/bbb-graphql-server/metadata/databases/BigBlueButton/tables/tables.yaml index a9e3313d85..0492f8ff3f 100644 --- a/bbb-graphql-server/metadata/databases/BigBlueButton/tables/tables.yaml +++ b/bbb-graphql-server/metadata/databases/BigBlueButton/tables/tables.yaml @@ -3,6 +3,7 @@ - "!include public_v_breakoutRoom_participant.yaml" - "!include public_v_breakoutRoom_user.yaml" - "!include public_v_caption.yaml" +- "!include public_v_caption_typed_activeLocales.yaml" - "!include public_v_chat.yaml" - "!include public_v_chat_message_private.yaml" - "!include public_v_chat_message_public.yaml"