touchstudy-core 0.1.91 → 0.1.92
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/dist/containers/ExamResult/configs/types.d.ts +5 -2
- package/dist/index.js +34 -10
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +34 -10
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
@@ -74,8 +74,11 @@ export declare type ExamResult = {
|
|
74
74
|
totalStudent: number;
|
75
75
|
totalTime: any;
|
76
76
|
type: string;
|
77
|
-
|
78
|
-
|
77
|
+
courses?: CourtInfo[];
|
78
|
+
};
|
79
|
+
export declare type CourtInfo = {
|
80
|
+
id: number;
|
81
|
+
name: string;
|
79
82
|
};
|
80
83
|
export declare type EffectSize = {
|
81
84
|
id: number;
|
package/dist/index.js
CHANGED
@@ -2251,6 +2251,7 @@ var weekly_day = "주간";
|
|
2251
2251
|
var weekly_days = "주간";
|
2252
2252
|
var enter_class_name = "수업 이름을 입력하세요";
|
2253
2253
|
var class_required = "수업 이름은 필수 항목입니다";
|
2254
|
+
var class_name_must_be_at_least_N_characters = "클래스 이름은 {{length}}자 이상이어야 합니다";
|
2254
2255
|
var total_teachers = "총 교사 수";
|
2255
2256
|
var start_date_required = "시작일은 필수 항목입니다";
|
2256
2257
|
var end_date_required = "종료일은 필수 항목입니다";
|
@@ -2488,6 +2489,7 @@ var manage_textbooks = "교과서 관리";
|
|
2488
2489
|
var my_question = "내 질문";
|
2489
2490
|
var update_class = "수업 업데이트";
|
2490
2491
|
var create_class = "수업 만들기";
|
2492
|
+
var view_class = "수업 보기";
|
2491
2493
|
var problem_number = "문제 번호";
|
2492
2494
|
var answer = "정답";
|
2493
2495
|
var correct = "정답";
|
@@ -2658,6 +2660,7 @@ var update_exam_successfully = "시험을 성공적으로 업데이트했습니
|
|
2658
2660
|
var create_exam_successfully = "시험을 성공적으로 만들었습니다.";
|
2659
2661
|
var create_notification = "알림 생성";
|
2660
2662
|
var update_notification = "업데이트 알림";
|
2663
|
+
var view_notification = "알림 보기";
|
2661
2664
|
var new_notification = "새로운 알림";
|
2662
2665
|
var are_you_sure_to_delete_notification = "알림을 삭제하시겠습니까:";
|
2663
2666
|
var answer_list = "답변 목록";
|
@@ -3064,6 +3067,7 @@ var lang_ko = {
|
|
3064
3067
|
weekly_days: weekly_days,
|
3065
3068
|
enter_class_name: enter_class_name,
|
3066
3069
|
class_required: class_required,
|
3070
|
+
class_name_must_be_at_least_N_characters: class_name_must_be_at_least_N_characters,
|
3067
3071
|
total_teachers: total_teachers,
|
3068
3072
|
start_date_required: start_date_required,
|
3069
3073
|
end_date_required: end_date_required,
|
@@ -3287,6 +3291,7 @@ var lang_ko = {
|
|
3287
3291
|
my_question: my_question,
|
3288
3292
|
update_class: update_class,
|
3289
3293
|
create_class: create_class,
|
3294
|
+
view_class: view_class,
|
3290
3295
|
problem_number: problem_number,
|
3291
3296
|
answer: answer,
|
3292
3297
|
correct: correct,
|
@@ -3462,6 +3467,7 @@ var lang_ko = {
|
|
3462
3467
|
create_exam_successfully: create_exam_successfully,
|
3463
3468
|
create_notification: create_notification,
|
3464
3469
|
update_notification: update_notification,
|
3470
|
+
view_notification: view_notification,
|
3465
3471
|
new_notification: new_notification,
|
3466
3472
|
are_you_sure_to_delete_notification: are_you_sure_to_delete_notification,
|
3467
3473
|
answer_list: answer_list,
|
@@ -3868,6 +3874,7 @@ var weekly_day$1 = "Weekly day";
|
|
3868
3874
|
var weekly_days$1 = "Weekly days";
|
3869
3875
|
var enter_class_name$1 = "Enter class name";
|
3870
3876
|
var class_required$1 = "Class name is required";
|
3877
|
+
var class_name_must_be_at_least_N_characters$1 = "Class name must be at least {{length}} characters";
|
3871
3878
|
var total_teachers$1 = "Total teachers";
|
3872
3879
|
var start_date_required$1 = "Start date is required";
|
3873
3880
|
var end_date_required$1 = "End date is required";
|
@@ -4123,6 +4130,7 @@ var teachers$1 = "Teachers";
|
|
4123
4130
|
var lessons$1 = "Lessons";
|
4124
4131
|
var update_class$1 = "Update class";
|
4125
4132
|
var create_class$1 = "Create class";
|
4133
|
+
var view_class$1 = "View class";
|
4126
4134
|
var new_test$1 = "New Test";
|
4127
4135
|
var manage_saved_exams$1 = "Manage saved exams";
|
4128
4136
|
var manage_textbooks$1 = "Manage Textbooks";
|
@@ -4292,6 +4300,7 @@ var update_exam_successfully$1 = "Update exam successfully";
|
|
4292
4300
|
var create_exam_successfully$1 = "Create exam successfully";
|
4293
4301
|
var create_notification$1 = "Create Notification";
|
4294
4302
|
var update_notification$1 = "Update Notification";
|
4303
|
+
var view_notification$1 = "View Notification";
|
4295
4304
|
var new_notification$1 = "New Notification";
|
4296
4305
|
var are_you_sure_to_delete_notification$1 = "Are you sure to delete notification:";
|
4297
4306
|
var answer_list$1 = "Answer List";
|
@@ -4526,7 +4535,7 @@ var delete_action$1 = "Delete";
|
|
4526
4535
|
var edit_action$1 = "Edit";
|
4527
4536
|
var view_action$1 = "View";
|
4528
4537
|
var de_select$1 = "Deselect";
|
4529
|
-
var select_output$1 = "Select
|
4538
|
+
var select_output$1 = "Select";
|
4530
4539
|
var print_pdf$1 = "Print PDF";
|
4531
4540
|
var completed$1 = "Completed";
|
4532
4541
|
var in_progress$1 = "In Progress";
|
@@ -4682,6 +4691,7 @@ var lang_en = {
|
|
4682
4691
|
weekly_days: weekly_days$1,
|
4683
4692
|
enter_class_name: enter_class_name$1,
|
4684
4693
|
class_required: class_required$1,
|
4694
|
+
class_name_must_be_at_least_N_characters: class_name_must_be_at_least_N_characters$1,
|
4685
4695
|
total_teachers: total_teachers$1,
|
4686
4696
|
start_date_required: start_date_required$1,
|
4687
4697
|
end_date_required: end_date_required$1,
|
@@ -4923,6 +4933,7 @@ var lang_en = {
|
|
4923
4933
|
lessons: lessons$1,
|
4924
4934
|
update_class: update_class$1,
|
4925
4935
|
create_class: create_class$1,
|
4936
|
+
view_class: view_class$1,
|
4926
4937
|
new_test: new_test$1,
|
4927
4938
|
manage_saved_exams: manage_saved_exams$1,
|
4928
4939
|
manage_textbooks: manage_textbooks$1,
|
@@ -5097,6 +5108,7 @@ var lang_en = {
|
|
5097
5108
|
create_exam_successfully: create_exam_successfully$1,
|
5098
5109
|
create_notification: create_notification$1,
|
5099
5110
|
update_notification: update_notification$1,
|
5111
|
+
view_notification: view_notification$1,
|
5100
5112
|
new_notification: new_notification$1,
|
5101
5113
|
are_you_sure_to_delete_notification: are_you_sure_to_delete_notification$1,
|
5102
5114
|
answer_list: answer_list$1,
|
@@ -15315,6 +15327,7 @@ var studentNameStyle = {
|
|
15315
15327
|
lineHeight: 1
|
15316
15328
|
};
|
15317
15329
|
var PrintExamResult = function PrintExamResult(_ref) {
|
15330
|
+
var _resultData$courses;
|
15318
15331
|
var resultData = _ref.resultData,
|
15319
15332
|
examTime = _ref.examTime,
|
15320
15333
|
status = _ref.status,
|
@@ -15333,6 +15346,9 @@ var PrintExamResult = function PrintExamResult(_ref) {
|
|
15333
15346
|
var _state$common;
|
15334
15347
|
return state === null || state === void 0 ? void 0 : (_state$common = state.common) === null || _state$common === void 0 ? void 0 : _state$common.academy;
|
15335
15348
|
});
|
15349
|
+
var courses = resultData === null || resultData === void 0 ? void 0 : (_resultData$courses = resultData.courses) === null || _resultData$courses === void 0 ? void 0 : _resultData$courses.map(function (c) {
|
15350
|
+
return c.name;
|
15351
|
+
}).join(', ');
|
15336
15352
|
return React__default.createElement(material.Box, {
|
15337
15353
|
sx: {
|
15338
15354
|
minWidth: "768px",
|
@@ -15371,9 +15387,9 @@ var PrintExamResult = function PrintExamResult(_ref) {
|
|
15371
15387
|
sx: _extends({}, studentNameStyle, {
|
15372
15388
|
textAlign: "end"
|
15373
15389
|
})
|
15374
|
-
}, academy.name)),
|
15390
|
+
}, academy.name)), courses && React__default.createElement(material.Stack, null, React__default.createElement(material.Typography, {
|
15375
15391
|
sx: courseNameStyle
|
15376
|
-
},
|
15392
|
+
}, courses)), React__default.createElement(material.Box, {
|
15377
15393
|
display: "flex",
|
15378
15394
|
gap: "16px",
|
15379
15395
|
flexDirection: "column"
|
@@ -15522,6 +15538,7 @@ var PrintExamResult = function PrintExamResult(_ref) {
|
|
15522
15538
|
};
|
15523
15539
|
|
15524
15540
|
var ExamResultV2 = function ExamResultV2(_ref) {
|
15541
|
+
var _resultData$courses;
|
15525
15542
|
var searchParams = _ref.searchParams,
|
15526
15543
|
history = _ref.history,
|
15527
15544
|
_ref$examSessionId = _ref.examSessionId,
|
@@ -15572,6 +15589,9 @@ var ExamResultV2 = function ExamResultV2(_ref) {
|
|
15572
15589
|
handlePrintPdf = _usePrintExamResult.handlePrintPdf,
|
15573
15590
|
setRenderedChart = _usePrintExamResult.setRenderedChart;
|
15574
15591
|
var isTabletUp = material.useMediaQuery('(min-width:900px)');
|
15592
|
+
var courses = resultData === null || resultData === void 0 ? void 0 : (_resultData$courses = resultData.courses) === null || _resultData$courses === void 0 ? void 0 : _resultData$courses.map(function (c) {
|
15593
|
+
return c.name;
|
15594
|
+
}).join(', ');
|
15575
15595
|
return React__default.createElement(React.Fragment, null, React__default.createElement(LoadingComponent, {
|
15576
15596
|
isLoading: !!isLoading
|
15577
15597
|
}), timelyOrderQuestions[dataChartIndex] && longTimeSpend && resultData && effectSize ? React__default.createElement("div", {
|
@@ -15583,13 +15603,13 @@ var ExamResultV2 = function ExamResultV2(_ref) {
|
|
15583
15603
|
padding: "24px"
|
15584
15604
|
}, React__default.createElement(material.Grid, {
|
15585
15605
|
item: true
|
15586
|
-
},
|
15606
|
+
}, courses && React__default.createElement(material.Stack, null, React__default.createElement(material.Typography, {
|
15587
15607
|
sx: {
|
15588
15608
|
fontSize: "14px",
|
15589
15609
|
fontWeight: 600,
|
15590
15610
|
color: styles.less_dark
|
15591
15611
|
}
|
15592
|
-
},
|
15612
|
+
}, courses)), React__default.createElement(material.Box, {
|
15593
15613
|
display: "flex",
|
15594
15614
|
gap: "16px",
|
15595
15615
|
flexDirection: "column"
|
@@ -17775,7 +17795,9 @@ var DEFAULT_LESSON_REQUEST = {
|
|
17775
17795
|
};
|
17776
17796
|
var ClassSchema = function ClassSchema(t) {
|
17777
17797
|
return yup.object({
|
17778
|
-
name: yup.string().required(t("class_required")),
|
17798
|
+
name: yup.string().required(t("class_required")).trim().min(2, t("class_name_must_be_at_least_N_characters", {
|
17799
|
+
length: 2
|
17800
|
+
})),
|
17779
17801
|
startDate: yup.date().required(t("start_date_required")),
|
17780
17802
|
endDate: yup.date().required(t("end_date_required")),
|
17781
17803
|
mainTeacherId: yup.number().required(t("main_teacher_required")),
|
@@ -20349,7 +20371,7 @@ var ClassDetail = function ClassDetail(_ref) {
|
|
20349
20371
|
pt: !!id ? "12px" : "0px"
|
20350
20372
|
}, React__default.createElement(material.Typography, {
|
20351
20373
|
variant: "h4"
|
20352
|
-
}, t(!id ? "create_class" : "update_class"))), React__default.createElement(formik.Formik, {
|
20374
|
+
}, t(!id ? "create_class" : isAdmin ? "update_class" : "view_class"))), React__default.createElement(formik.Formik, {
|
20353
20375
|
initialValues: DEFAULT_CLASS_REQUEST,
|
20354
20376
|
validationSchema: schema,
|
20355
20377
|
onSubmit: handleSubmit
|
@@ -22265,7 +22287,7 @@ var NotificationDetail = function NotificationDetail(_ref) {
|
|
22265
22287
|
mb: 2
|
22266
22288
|
}, React__default.createElement(material.Typography, {
|
22267
22289
|
variant: "h4"
|
22268
|
-
}, t(!id ? "create_notification" : "update_notification"))), React__default.createElement(formik.Formik, {
|
22290
|
+
}, t(!id ? "create_notification" : !isAdmin && (!(detailNotification !== null && detailNotification !== void 0 && detailNotification.isOwned) || isTeacherAdmin) ? "view_notification" : "update_notification"))), React__default.createElement(formik.Formik, {
|
22269
22291
|
initialValues: DEFAULT_NOTIFICATION_REQUEST,
|
22270
22292
|
validationSchema: schema,
|
22271
22293
|
onSubmit: handleSubmit
|
@@ -22559,11 +22581,13 @@ var NotificationList = function NotificationList(_ref) {
|
|
22559
22581
|
className: "d-flex"
|
22560
22582
|
}, React__default.createElement(material.IconButton, {
|
22561
22583
|
color: "default",
|
22562
|
-
className: "bg-warning text-white me-1",
|
22584
|
+
className: "bg-" + (!isAdmin && (isTeacherAdmin || !i.isOwned) ? "primary" : "warning") + " text-white me-1",
|
22563
22585
|
onClick: function onClick() {
|
22564
22586
|
return handleUpdateNotification(i);
|
22565
22587
|
}
|
22566
|
-
}, React__default.createElement(
|
22588
|
+
}, !isAdmin && (isTeacherAdmin || !i.isOwned) ? React__default.createElement(fa.FaEye, {
|
22589
|
+
size: 12
|
22590
|
+
}) : React__default.createElement(hi.HiOutlinePencilAlt, {
|
22567
22591
|
size: 12
|
22568
22592
|
})), React__default.createElement(material.IconButton, {
|
22569
22593
|
color: "error",
|