@quesmed/types-rn 2.5.5 → 2.5.7
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/Concept.d.ts +1 -0
- package/models/Topic.d.ts +4 -0
- package/models/User.d.ts +4 -4
- package/models/User.js +8 -8
- package/package.json +1 -1
- package/resolvers/fragments/marksheet.js +1 -0
- package/resolvers/mutation/restricted/marksheet.js +12 -0
- package/resolvers/mutation/restricted/users.d.ts +4 -4
- package/resolvers/mutation/restricted/users.js +2 -2
- package/resolvers/query/restricted/marksheet.js +18 -4
- package/resolvers/query/restricted/quesBook.d.ts +1 -1
- package/resolvers/query/restricted/quesBook.js +7 -1
- package/resolvers/query/restricted/question.js +4 -0
package/models/Concept.d.ts
CHANGED
package/models/Topic.d.ts
CHANGED
|
@@ -53,4 +53,8 @@ export interface ITopic {
|
|
|
53
53
|
yellowCards?: number | null;
|
|
54
54
|
redCards?: number | null;
|
|
55
55
|
dailyFeedCards?: number | null;
|
|
56
|
+
unreadConcepts?: number | null;
|
|
57
|
+
completedConcepts?: number | null;
|
|
58
|
+
revisingConcepts?: number | null;
|
|
59
|
+
urgentConcepts?: number | null;
|
|
56
60
|
}
|
package/models/User.d.ts
CHANGED
|
@@ -15,11 +15,11 @@ export declare enum EClassYearGroup {
|
|
|
15
15
|
PRECLINICAL = 0,
|
|
16
16
|
CLINICAL = 1
|
|
17
17
|
}
|
|
18
|
-
export declare enum
|
|
18
|
+
export declare enum EUserLearningStatus {
|
|
19
19
|
UNREAD = 0,
|
|
20
20
|
COMPLETED = 1,
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
REVISING = 2,
|
|
22
|
+
URGENT = 3
|
|
23
23
|
}
|
|
24
24
|
export declare const classYearGroup: {
|
|
25
25
|
[key: string]: EClassYearGroup;
|
|
@@ -179,7 +179,7 @@ export interface IUserConceptStatus {
|
|
|
179
179
|
updatedAt: number | Date;
|
|
180
180
|
conceptId: Id;
|
|
181
181
|
userId: Id;
|
|
182
|
-
status:
|
|
182
|
+
status: EUserLearningStatus;
|
|
183
183
|
user: IUser;
|
|
184
184
|
concept: IConcept;
|
|
185
185
|
}
|
package/models/User.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.currentClassGroup = exports.currentClassYear = exports.EPracticeIntensity = exports.classYearGroup = exports.
|
|
3
|
+
exports.currentClassGroup = exports.currentClassYear = exports.EPracticeIntensity = exports.classYearGroup = exports.EUserLearningStatus = exports.EClassYearGroup = exports.classYears = void 0;
|
|
4
4
|
const luxon_1 = require("luxon");
|
|
5
5
|
exports.classYears = [
|
|
6
6
|
'Year 1',
|
|
@@ -15,13 +15,13 @@ var EClassYearGroup;
|
|
|
15
15
|
EClassYearGroup[EClassYearGroup["PRECLINICAL"] = 0] = "PRECLINICAL";
|
|
16
16
|
EClassYearGroup[EClassYearGroup["CLINICAL"] = 1] = "CLINICAL";
|
|
17
17
|
})(EClassYearGroup = exports.EClassYearGroup || (exports.EClassYearGroup = {}));
|
|
18
|
-
var
|
|
19
|
-
(function (
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
})(
|
|
18
|
+
var EUserLearningStatus;
|
|
19
|
+
(function (EUserLearningStatus) {
|
|
20
|
+
EUserLearningStatus[EUserLearningStatus["UNREAD"] = 0] = "UNREAD";
|
|
21
|
+
EUserLearningStatus[EUserLearningStatus["COMPLETED"] = 1] = "COMPLETED";
|
|
22
|
+
EUserLearningStatus[EUserLearningStatus["REVISING"] = 2] = "REVISING";
|
|
23
|
+
EUserLearningStatus[EUserLearningStatus["URGENT"] = 3] = "URGENT";
|
|
24
|
+
})(EUserLearningStatus = exports.EUserLearningStatus || (exports.EUserLearningStatus = {}));
|
|
25
25
|
exports.classYearGroup = {
|
|
26
26
|
'Year 1': EClassYearGroup.PRECLINICAL,
|
|
27
27
|
'Year 2': EClassYearGroup.PRECLINICAL,
|
package/package.json
CHANGED
|
@@ -126,6 +126,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
|
|
|
126
126
|
concept {
|
|
127
127
|
id
|
|
128
128
|
name
|
|
129
|
+
status
|
|
129
130
|
topic {
|
|
130
131
|
id
|
|
131
132
|
name
|
|
@@ -250,6 +251,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
|
|
|
250
251
|
concept {
|
|
251
252
|
id
|
|
252
253
|
name
|
|
254
|
+
status
|
|
253
255
|
topic {
|
|
254
256
|
id
|
|
255
257
|
name
|
|
@@ -377,6 +379,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
|
|
|
377
379
|
concept {
|
|
378
380
|
id
|
|
379
381
|
name
|
|
382
|
+
status
|
|
380
383
|
topic {
|
|
381
384
|
id
|
|
382
385
|
name
|
|
@@ -501,6 +504,7 @@ exports.BUILD_QUESTION_MARKSHEET = (0, client_1.gql) `
|
|
|
501
504
|
concept {
|
|
502
505
|
id
|
|
503
506
|
name
|
|
507
|
+
status
|
|
504
508
|
topic {
|
|
505
509
|
id
|
|
506
510
|
name
|
|
@@ -721,6 +725,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
721
725
|
concept {
|
|
722
726
|
id
|
|
723
727
|
name
|
|
728
|
+
status
|
|
724
729
|
topic {
|
|
725
730
|
id
|
|
726
731
|
name
|
|
@@ -845,6 +850,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
845
850
|
concept {
|
|
846
851
|
id
|
|
847
852
|
name
|
|
853
|
+
status
|
|
848
854
|
topic {
|
|
849
855
|
id
|
|
850
856
|
name
|
|
@@ -972,6 +978,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
972
978
|
concept {
|
|
973
979
|
id
|
|
974
980
|
name
|
|
981
|
+
status
|
|
975
982
|
topic {
|
|
976
983
|
id
|
|
977
984
|
name
|
|
@@ -1096,6 +1103,7 @@ exports.BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
1096
1103
|
concept {
|
|
1097
1104
|
id
|
|
1098
1105
|
name
|
|
1106
|
+
status
|
|
1099
1107
|
topic {
|
|
1100
1108
|
id
|
|
1101
1109
|
name
|
|
@@ -1321,6 +1329,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
1321
1329
|
concept {
|
|
1322
1330
|
id
|
|
1323
1331
|
name
|
|
1332
|
+
status
|
|
1324
1333
|
topic {
|
|
1325
1334
|
id
|
|
1326
1335
|
name
|
|
@@ -1445,6 +1454,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
1445
1454
|
concept {
|
|
1446
1455
|
id
|
|
1447
1456
|
name
|
|
1457
|
+
status
|
|
1448
1458
|
topic {
|
|
1449
1459
|
id
|
|
1450
1460
|
name
|
|
@@ -1572,6 +1582,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
1572
1582
|
concept {
|
|
1573
1583
|
id
|
|
1574
1584
|
name
|
|
1585
|
+
status
|
|
1575
1586
|
topic {
|
|
1576
1587
|
id
|
|
1577
1588
|
name
|
|
@@ -1696,6 +1707,7 @@ exports.RE_BUILD_MARKSHEET = (0, client_1.gql) `
|
|
|
1696
1707
|
concept {
|
|
1697
1708
|
id
|
|
1698
1709
|
name
|
|
1710
|
+
status
|
|
1699
1711
|
topic {
|
|
1700
1712
|
id
|
|
1701
1713
|
name
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { EUserLearningStatus, Id, IUser, IUserConceptStatus } from '../../../models';
|
|
2
2
|
import { graphqlNormalize, RestrictedData } from '../../types';
|
|
3
3
|
export declare const RESET_PROGRESS: import("@apollo/client").DocumentNode;
|
|
4
4
|
export interface IResetProgressVar {
|
|
@@ -40,8 +40,8 @@ export type ITocAcceptVar = null;
|
|
|
40
40
|
export type ITocAcceptData = RestrictedData<string, 'tocAccept'>;
|
|
41
41
|
export type ICompletedCardsData = Pick<IUser, 'completedCards' | 'completedCardsCount'>;
|
|
42
42
|
export type IUpsertUserConceptStatusVar = {
|
|
43
|
-
|
|
44
|
-
status:
|
|
43
|
+
conceptIds: Id[];
|
|
44
|
+
status: EUserLearningStatus;
|
|
45
45
|
};
|
|
46
|
-
export type IUpsertUserConceptStatusData = RestrictedData<graphqlNormalize & IUserConceptStatus, 'upsertUserConceptStatus'>;
|
|
46
|
+
export type IUpsertUserConceptStatusData = RestrictedData<graphqlNormalize & IUserConceptStatus[], 'upsertUserConceptStatus'>;
|
|
47
47
|
export declare const UPSERT_USER_CONCEPT_STATUS: import("@apollo/client").DocumentNode;
|
|
@@ -56,9 +56,9 @@ exports.TOC_ACCEPT = (0, client_1.gql) `
|
|
|
56
56
|
}
|
|
57
57
|
`;
|
|
58
58
|
exports.UPSERT_USER_CONCEPT_STATUS = (0, client_1.gql) `
|
|
59
|
-
mutation
|
|
59
|
+
mutation UpsertUserConceptStatus($conceptIds: [Int!]!, $status: Int!) {
|
|
60
60
|
restricted {
|
|
61
|
-
upsertUserConceptStatus(
|
|
61
|
+
upsertUserConceptStatus(conceptIds: $conceptIds, status: $status) {
|
|
62
62
|
id
|
|
63
63
|
status
|
|
64
64
|
conceptId
|
|
@@ -133,6 +133,7 @@ exports.MARKSHEET = (0, client_1.gql) `
|
|
|
133
133
|
concept {
|
|
134
134
|
id
|
|
135
135
|
name
|
|
136
|
+
status
|
|
136
137
|
topic {
|
|
137
138
|
id
|
|
138
139
|
name
|
|
@@ -257,6 +258,7 @@ exports.MARKSHEET = (0, client_1.gql) `
|
|
|
257
258
|
concept {
|
|
258
259
|
id
|
|
259
260
|
name
|
|
261
|
+
status
|
|
260
262
|
chapter {
|
|
261
263
|
id
|
|
262
264
|
explanation
|
|
@@ -379,6 +381,7 @@ exports.MARKSHEET = (0, client_1.gql) `
|
|
|
379
381
|
concept {
|
|
380
382
|
id
|
|
381
383
|
name
|
|
384
|
+
status
|
|
382
385
|
topic {
|
|
383
386
|
id
|
|
384
387
|
name
|
|
@@ -503,6 +506,7 @@ exports.MARKSHEET = (0, client_1.gql) `
|
|
|
503
506
|
concept {
|
|
504
507
|
id
|
|
505
508
|
name
|
|
509
|
+
status
|
|
506
510
|
topic {
|
|
507
511
|
id
|
|
508
512
|
name
|
|
@@ -610,10 +614,10 @@ exports.MARKSHEETS = (0, client_1.gql) `
|
|
|
610
614
|
displayName
|
|
611
615
|
}
|
|
612
616
|
marks {
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
+
question {
|
|
618
|
+
topic {
|
|
619
|
+
typeId
|
|
620
|
+
name
|
|
617
621
|
}
|
|
618
622
|
}
|
|
619
623
|
}
|
|
@@ -644,6 +648,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
|
|
|
644
648
|
flaggedQuestions(filter: $filter) {
|
|
645
649
|
total
|
|
646
650
|
results {
|
|
651
|
+
createdAt
|
|
647
652
|
id
|
|
648
653
|
markId
|
|
649
654
|
questionId
|
|
@@ -715,6 +720,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
|
|
|
715
720
|
concept {
|
|
716
721
|
id
|
|
717
722
|
name
|
|
723
|
+
status
|
|
718
724
|
topic {
|
|
719
725
|
name
|
|
720
726
|
typeId
|
|
@@ -841,6 +847,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
|
|
|
841
847
|
concept {
|
|
842
848
|
id
|
|
843
849
|
name
|
|
850
|
+
status
|
|
844
851
|
topic {
|
|
845
852
|
id
|
|
846
853
|
name
|
|
@@ -965,6 +972,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
|
|
|
965
972
|
concept {
|
|
966
973
|
id
|
|
967
974
|
name
|
|
975
|
+
status
|
|
968
976
|
topic {
|
|
969
977
|
id
|
|
970
978
|
name
|
|
@@ -1092,6 +1100,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
|
|
|
1092
1100
|
concept {
|
|
1093
1101
|
id
|
|
1094
1102
|
name
|
|
1103
|
+
status
|
|
1095
1104
|
topic {
|
|
1096
1105
|
id
|
|
1097
1106
|
name
|
|
@@ -1216,6 +1225,7 @@ exports.FLAGGED_QUESTIONS = (0, client_1.gql) `
|
|
|
1216
1225
|
concept {
|
|
1217
1226
|
id
|
|
1218
1227
|
name
|
|
1228
|
+
status
|
|
1219
1229
|
topic {
|
|
1220
1230
|
id
|
|
1221
1231
|
name
|
|
@@ -1429,6 +1439,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
|
|
|
1429
1439
|
concept {
|
|
1430
1440
|
id
|
|
1431
1441
|
name
|
|
1442
|
+
status
|
|
1432
1443
|
topic {
|
|
1433
1444
|
id
|
|
1434
1445
|
name
|
|
@@ -1553,6 +1564,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
|
|
|
1553
1564
|
concept {
|
|
1554
1565
|
id
|
|
1555
1566
|
name
|
|
1567
|
+
status
|
|
1556
1568
|
topic {
|
|
1557
1569
|
id
|
|
1558
1570
|
name
|
|
@@ -1680,6 +1692,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
|
|
|
1680
1692
|
concept {
|
|
1681
1693
|
id
|
|
1682
1694
|
name
|
|
1695
|
+
status
|
|
1683
1696
|
topic {
|
|
1684
1697
|
id
|
|
1685
1698
|
name
|
|
@@ -1804,6 +1817,7 @@ exports.FLAGGED_QUESTIONS_MARKSHEET = (0, client_1.gql) `
|
|
|
1804
1817
|
concept {
|
|
1805
1818
|
id
|
|
1806
1819
|
name
|
|
1820
|
+
status
|
|
1807
1821
|
topic {
|
|
1808
1822
|
id
|
|
1809
1823
|
name
|
|
@@ -2,7 +2,7 @@ import { ETopicType, IOsceStation, ITopic } from '../../../models';
|
|
|
2
2
|
import { RestrictedData, graphqlNormalize } from '../../types';
|
|
3
3
|
export type IQuesBookVar = {
|
|
4
4
|
/**TODO: make it mandatory once frontend changes are completed */
|
|
5
|
-
typeId?: ETopicType;
|
|
5
|
+
typeId?: ETopicType[];
|
|
6
6
|
};
|
|
7
7
|
export type IQuesBookData = RestrictedData<(graphqlNormalize & ITopic)[], 'quesBook'>;
|
|
8
8
|
export declare const QUES_BOOK: import("@apollo/client").DocumentNode;
|
|
@@ -4,14 +4,20 @@ exports.OSCE_BOOK = exports.QUES_BOOK = void 0;
|
|
|
4
4
|
const client_1 = require("@apollo/client");
|
|
5
5
|
const osce_1 = require("./../../fragments/osce");
|
|
6
6
|
exports.QUES_BOOK = (0, client_1.gql) `
|
|
7
|
-
query quesBook($typeId: Int) {
|
|
7
|
+
query quesBook($typeId: [Int]) {
|
|
8
8
|
restricted {
|
|
9
9
|
quesBook(typeId: $typeId) {
|
|
10
10
|
id
|
|
11
11
|
name
|
|
12
|
+
typeId
|
|
13
|
+
unreadConcepts
|
|
14
|
+
completedConcepts
|
|
15
|
+
revisingConcepts
|
|
16
|
+
urgentConcepts
|
|
12
17
|
concepts {
|
|
13
18
|
id
|
|
14
19
|
name
|
|
20
|
+
status
|
|
15
21
|
chapter {
|
|
16
22
|
id
|
|
17
23
|
typeId
|
|
@@ -66,6 +66,7 @@ exports.QUESTION = (0, client_1.gql) `
|
|
|
66
66
|
concept {
|
|
67
67
|
id
|
|
68
68
|
name
|
|
69
|
+
status
|
|
69
70
|
chapter {
|
|
70
71
|
id
|
|
71
72
|
explanation
|
|
@@ -187,6 +188,7 @@ exports.QUESTION = (0, client_1.gql) `
|
|
|
187
188
|
concept {
|
|
188
189
|
id
|
|
189
190
|
name
|
|
191
|
+
status
|
|
190
192
|
chapter {
|
|
191
193
|
id
|
|
192
194
|
explanation
|
|
@@ -311,6 +313,7 @@ exports.QUESTION = (0, client_1.gql) `
|
|
|
311
313
|
concept {
|
|
312
314
|
id
|
|
313
315
|
name
|
|
316
|
+
status
|
|
314
317
|
chapter {
|
|
315
318
|
id
|
|
316
319
|
explanation
|
|
@@ -432,6 +435,7 @@ exports.QUESTION = (0, client_1.gql) `
|
|
|
432
435
|
concept {
|
|
433
436
|
id
|
|
434
437
|
name
|
|
438
|
+
status
|
|
435
439
|
chapter {
|
|
436
440
|
id
|
|
437
441
|
explanation
|