22c2a371b0
This commit removes some actions and interactions that a bot user should not be part: - No actions available when clicking over bot user in the user-list - Remove bot from exported user-list - Remove bot from available users to be assigned to breakouts
76 lines
1.3 KiB
TypeScript
76 lines
1.3 KiB
TypeScript
import { gql } from '@apollo/client';
|
|
import { BreakoutUser } from './room-managment-state/types';
|
|
|
|
export interface getUserResponse {
|
|
user: Array<BreakoutUser>;
|
|
}
|
|
|
|
export interface breakoutRoom {
|
|
sequence: number;
|
|
name: string;
|
|
breakoutRoomId: string;
|
|
participants: Array<{
|
|
user: {
|
|
name: string;
|
|
userId: string;
|
|
isModerator: boolean;
|
|
}
|
|
}>
|
|
}
|
|
|
|
export interface getBreakoutsResponse {
|
|
breakoutRoom: Array<breakoutRoom>
|
|
}
|
|
|
|
export const getUser = gql`
|
|
query getUser {
|
|
user(
|
|
where: { bot: {_eq: false } }
|
|
order_by: [
|
|
{role: asc},
|
|
{raiseHandTime: asc_nulls_last},
|
|
{awayTime: asc_nulls_last},
|
|
{isDialIn: desc},
|
|
{hasDrawPermissionOnCurrentPage: desc},
|
|
{nameSortable: asc},
|
|
{userId: asc}
|
|
]) {
|
|
userId
|
|
name
|
|
isModerator
|
|
}
|
|
}
|
|
`;
|
|
|
|
export const getBreakouts = gql`
|
|
query getBreakouts {
|
|
breakoutRoom {
|
|
sequence
|
|
name
|
|
breakoutRoomId
|
|
participants {
|
|
user {
|
|
name
|
|
userId
|
|
isModerator
|
|
}
|
|
}
|
|
}
|
|
}
|
|
`;
|
|
|
|
export const getBreakoutCount = gql`
|
|
query getBreakoutCount {
|
|
breakoutRoom_aggregate {
|
|
aggregate {
|
|
count
|
|
}
|
|
}
|
|
}
|
|
`;
|
|
|
|
export default {
|
|
getUser,
|
|
getBreakouts,
|
|
};
|