@quesmed/types-rn 2.5.0 → 2.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/models/OsceMarksheet.d.ts +7 -0
- package/models/Topic.d.ts +22 -0
- package/package.json +1 -1
- package/resolvers/mutation/restricted/users.d.ts +1 -0
- package/resolvers/mutation/users.d.ts +1 -1
- package/resolvers/query/restricted/osce.d.ts +9 -2
- package/resolvers/query/restricted/osce.js +22 -3
- package/resolvers/query/restricted/topics.d.ts +6 -1
- package/resolvers/query/restricted/topics.js +22 -1
|
@@ -81,6 +81,13 @@ export interface IDashboardOsce {
|
|
|
81
81
|
completed: number;
|
|
82
82
|
total: number;
|
|
83
83
|
}
|
|
84
|
+
export interface IOsceStats {
|
|
85
|
+
userId: number;
|
|
86
|
+
completed: number;
|
|
87
|
+
total: number;
|
|
88
|
+
avgScore: number;
|
|
89
|
+
types?: IOsceType[];
|
|
90
|
+
}
|
|
84
91
|
export interface IOsceTypeDashboard extends IOsceType {
|
|
85
92
|
completed: number;
|
|
86
93
|
total: number;
|
package/models/Topic.d.ts
CHANGED
|
@@ -13,6 +13,28 @@ export declare enum ETopicType {
|
|
|
13
13
|
export interface ITopicType {
|
|
14
14
|
id: ETopicType;
|
|
15
15
|
name: string;
|
|
16
|
+
totalQuestions?: number | null;
|
|
17
|
+
completedQuestions?: number | null;
|
|
18
|
+
correctQuestions?: number | null;
|
|
19
|
+
incorrectQuestions?: number | null;
|
|
20
|
+
totalCards?: number | null;
|
|
21
|
+
greenCards?: number | null;
|
|
22
|
+
yellowCards?: number | null;
|
|
23
|
+
redCards?: number | null;
|
|
24
|
+
dailyFeedCards?: number | null;
|
|
25
|
+
}
|
|
26
|
+
export interface ITopicStats {
|
|
27
|
+
userId: number;
|
|
28
|
+
totalQuestions?: number | null;
|
|
29
|
+
completedQuestions?: number | null;
|
|
30
|
+
correctQuestions?: number | null;
|
|
31
|
+
incorrectQuestions?: number | null;
|
|
32
|
+
totalCards?: number | null;
|
|
33
|
+
greenCards?: number | null;
|
|
34
|
+
yellowCards?: number | null;
|
|
35
|
+
redCards?: number | null;
|
|
36
|
+
dailyFeedCards?: number | null;
|
|
37
|
+
types?: ITopicType[];
|
|
16
38
|
}
|
|
17
39
|
export interface ITopic {
|
|
18
40
|
id: Id;
|
package/package.json
CHANGED
|
@@ -20,7 +20,7 @@ export interface RegisterUserInput {
|
|
|
20
20
|
referral?: string | null;
|
|
21
21
|
}
|
|
22
22
|
export interface IRegisterUserVar {
|
|
23
|
-
userData: RegisterUserInput
|
|
23
|
+
userData: Pick<RegisterUserInput, 'password' | 'username' | 'newsletter'>;
|
|
24
24
|
}
|
|
25
25
|
export type IRegisterUserData = RootData<string, 'registerUser'>;
|
|
26
26
|
export declare const RESET_PASSWORD_PREP: import("@apollo/client").DocumentNode;
|
|
@@ -1,6 +1,12 @@
|
|
|
1
|
-
import { EDifficultyType, Id, IDashboardOsce, IOsceMarksheet, IOsceStation } from '../../../models';
|
|
1
|
+
import { EDifficultyType, EOsceType, Id, IDashboardOsce, IOsceMarksheet, IOsceStation, IOsceStats } from '../../../models';
|
|
2
2
|
import { graphqlNormalize, RestrictedData } from '../../types';
|
|
3
3
|
import { ITopic } from './../../../models/Topic';
|
|
4
|
+
export interface IOsceStatsVar {
|
|
5
|
+
typeId?: EOsceType[];
|
|
6
|
+
solo: boolean;
|
|
7
|
+
}
|
|
8
|
+
export type IOsceStatsData = RestrictedData<graphqlNormalize & IOsceStats, 'osceStats'>;
|
|
9
|
+
export declare const OSCE_STATS: import("@apollo/client").DocumentNode;
|
|
4
10
|
export declare const DASHBOARD_OSCE: import("@apollo/client").DocumentNode;
|
|
5
11
|
export interface IDashboardOsceVar {
|
|
6
12
|
solo: boolean;
|
|
@@ -8,7 +14,8 @@ export interface IDashboardOsceVar {
|
|
|
8
14
|
export type IDashboardOsceData = RestrictedData<graphqlNormalize & IDashboardOsce, 'dashboardOsce'>;
|
|
9
15
|
export declare const OSCE_MARKSHEETS: import("@apollo/client").DocumentNode;
|
|
10
16
|
export interface IOsceMarksheetsVar {
|
|
11
|
-
solo
|
|
17
|
+
solo?: boolean;
|
|
18
|
+
days?: number;
|
|
12
19
|
}
|
|
13
20
|
export type IOsceMarksheetsData = RestrictedData<(graphqlNormalize & IOsceMarksheet)[], 'osceMarksheets'>;
|
|
14
21
|
export declare const OSCE_MARKSHEET: import("@apollo/client").DocumentNode;
|
|
@@ -1,9 +1,27 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.HEARTBEAT = exports.SEARCH_OSCE_STATIONS = exports.OSCE_TOPICS = exports.OSCE_STATION = exports.OSCE_STATIONS = exports.OSCE_MARKSHEET = exports.OSCE_MARKSHEETS = exports.DASHBOARD_OSCE = void 0;
|
|
3
|
+
exports.HEARTBEAT = exports.SEARCH_OSCE_STATIONS = exports.OSCE_TOPICS = exports.OSCE_STATION = exports.OSCE_STATIONS = exports.OSCE_MARKSHEET = exports.OSCE_MARKSHEETS = exports.DASHBOARD_OSCE = exports.OSCE_STATS = void 0;
|
|
4
4
|
const client_1 = require("@apollo/client");
|
|
5
5
|
const osce_1 = require("../../fragments/osce");
|
|
6
6
|
const osce_2 = require("./../../fragments/osce");
|
|
7
|
+
exports.OSCE_STATS = (0, client_1.gql) `
|
|
8
|
+
query OsceStats($solo: Boolean!, $typeId: [Int]) {
|
|
9
|
+
restricted {
|
|
10
|
+
osceStats(solo: $solo, typeId: $typeId) {
|
|
11
|
+
avgScore
|
|
12
|
+
completed
|
|
13
|
+
total
|
|
14
|
+
types {
|
|
15
|
+
avgScore
|
|
16
|
+
completed
|
|
17
|
+
id
|
|
18
|
+
name
|
|
19
|
+
total
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
`;
|
|
7
25
|
exports.DASHBOARD_OSCE = (0, client_1.gql) `
|
|
8
26
|
query DashboardOsce($solo: Boolean!) {
|
|
9
27
|
restricted {
|
|
@@ -27,9 +45,9 @@ exports.DASHBOARD_OSCE = (0, client_1.gql) `
|
|
|
27
45
|
exports.OSCE_MARKSHEETS = (0, client_1.gql) `
|
|
28
46
|
${osce_2.OSCE_STATION_FIELDS}
|
|
29
47
|
${osce_1.OSCE_MARKSHEET_FIELDS}
|
|
30
|
-
query OsceMarksheets($solo: Boolean
|
|
48
|
+
query OsceMarksheets($solo: Boolean, $days: Int) {
|
|
31
49
|
restricted {
|
|
32
|
-
osceMarksheets(solo: $solo) {
|
|
50
|
+
osceMarksheets(solo: $solo, days: $days) {
|
|
33
51
|
...OsceMarksheetFields
|
|
34
52
|
osceStation {
|
|
35
53
|
...OsceStationFields
|
|
@@ -38,6 +56,7 @@ exports.OSCE_MARKSHEETS = (0, client_1.gql) `
|
|
|
38
56
|
}
|
|
39
57
|
}
|
|
40
58
|
`;
|
|
59
|
+
;
|
|
41
60
|
exports.OSCE_MARKSHEET = (0, client_1.gql) `
|
|
42
61
|
${osce_2.OSCE_STATION_FIELDS}
|
|
43
62
|
${osce_1.OSCE_MARKSHEET_FIELDS}
|
|
@@ -1,5 +1,10 @@
|
|
|
1
|
-
import { ETopicType, Id, ITopic } from '../../../models';
|
|
1
|
+
import { ETopicType, Id, ITopic, ITopicStats } from '../../../models';
|
|
2
2
|
import { graphqlNormalize, RestrictedData } from '../../types';
|
|
3
|
+
export interface ITopicStatsVar {
|
|
4
|
+
typeId?: ETopicType[];
|
|
5
|
+
}
|
|
6
|
+
export type ITopicStatsData = RestrictedData<graphqlNormalize & ITopicStats, 'topicStats'>;
|
|
7
|
+
export declare const TOPIC_STATS: import("@apollo/client").DocumentNode;
|
|
3
8
|
export interface ITopicVar {
|
|
4
9
|
id: Id;
|
|
5
10
|
}
|
|
@@ -1,7 +1,28 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.FLASHCARDS_TOPICS = exports.QUESTION_TOPICS = exports.TOPICS = exports.TOPIC = void 0;
|
|
3
|
+
exports.FLASHCARDS_TOPICS = exports.QUESTION_TOPICS = exports.TOPICS = exports.TOPIC = exports.TOPIC_STATS = void 0;
|
|
4
4
|
const client_1 = require("@apollo/client");
|
|
5
|
+
exports.TOPIC_STATS = (0, client_1.gql) `
|
|
6
|
+
query TopicStats($typeId: [Int!]) {
|
|
7
|
+
restricted {
|
|
8
|
+
topicStats(typeId: $typeId) {
|
|
9
|
+
totalQuestions
|
|
10
|
+
completedQuestions
|
|
11
|
+
correctQuestions
|
|
12
|
+
incorrectQuestions
|
|
13
|
+
types {
|
|
14
|
+
id
|
|
15
|
+
name
|
|
16
|
+
totalQuestions
|
|
17
|
+
completedQuestions
|
|
18
|
+
correctQuestions
|
|
19
|
+
incorrectQuestions
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
`;
|
|
5
26
|
exports.TOPIC = (0, client_1.gql) `
|
|
6
27
|
query Topic($topicId: Int!) {
|
|
7
28
|
restricted {
|