mario-core 2.9.238-layout → 2.9.239-release
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/Login/constant/types.d.ts +14 -0
- package/dist/containers/Login/hooks/useLogin.d.ts +4 -4
- package/dist/containers/Login/views/block/BlockSelectTeacher.d.ts +0 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +278 -91
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +277 -92
- package/dist/index.modern.js.map +1 -1
- package/dist/redux/commons/action.d.ts +2 -0
- package/dist/rootReducer.d.ts +5 -0
- package/dist/services/accountService.d.ts +1 -1
- package/dist/services/weeklyQuestService.d.ts +1 -0
- package/dist/types/WeeklyQuest.d.ts +37 -0
- package/package.json +4 -1
package/dist/index.modern.js
CHANGED
|
@@ -5,9 +5,10 @@ export { I18nextProvider, useTranslation } from 'react-i18next';
|
|
|
5
5
|
import React, { useState, useCallback, useEffect, forwardRef, useRef, Suspense, memo, Fragment, useImperativeHandle, useMemo } from 'react';
|
|
6
6
|
import { Input, Modal, ModalHeader, ModalBody, ModalFooter, Button, Row, Col, Form, FormGroup, Navbar, NavbarBrand, Collapse, Nav, NavItem, NavLink, Dropdown, DropdownToggle, DropdownMenu, DropdownItem, Alert, Pagination, PaginationItem, PaginationLink, Table, Label, Popover, PopoverBody, TabContent, TabPane, CardText, CustomInput, Card, CardImg, CardBody, CardTitle, CardHeader } from 'reactstrap';
|
|
7
7
|
import { useHistory, Link, useLocation, Switch, Route, Prompt, useParams } from 'react-router-dom';
|
|
8
|
+
import { useDispatch, useSelector } from 'react-redux';
|
|
8
9
|
import { Formik } from 'formik';
|
|
9
10
|
import { object, string, boolean, number, array } from 'yup';
|
|
10
|
-
import {
|
|
11
|
+
import { LogLevel, PublicClientApplication } from '@azure/msal-browser';
|
|
11
12
|
import { createAction, createReducer, configureStore } from '@reduxjs/toolkit';
|
|
12
13
|
import axios from 'axios';
|
|
13
14
|
import amplitude from 'amplitude-js';
|
|
@@ -1843,6 +1844,7 @@ var accommodation_set = "Accommodation Set";
|
|
|
1843
1844
|
var add_new_accommodation = "Add new accommodation";
|
|
1844
1845
|
var print_my_accommodations = "Print my accommodations";
|
|
1845
1846
|
var my_learning_progress = "My Learning Progress";
|
|
1847
|
+
var weekly_quests = "Weekly quests";
|
|
1846
1848
|
var responses_comparisons = "Responses Comparisons";
|
|
1847
1849
|
var dropdown_and_verbal_questions_responses = "Dropdown and Verbal Questions Responses";
|
|
1848
1850
|
var mario_tools = "MARIO TOOLS";
|
|
@@ -1984,6 +1986,7 @@ var suggestion = "suggestion";
|
|
|
1984
1986
|
var tutorial_screen = "tutorial screen";
|
|
1985
1987
|
var reflection_forms = "reflection forms";
|
|
1986
1988
|
var select_question_to_add = "Select question to add";
|
|
1989
|
+
var all_of_the_students_marked_as_feeling_safe = "All of the students marked as feeling safe";
|
|
1987
1990
|
var lang_us = {
|
|
1988
1991
|
dashboard: dashboard,
|
|
1989
1992
|
user: user,
|
|
@@ -3811,6 +3814,7 @@ var lang_us = {
|
|
|
3811
3814
|
my_learning_progress: my_learning_progress,
|
|
3812
3815
|
"here_your_teacher_can_edit_or_add_your_accommodation_details._please_note_that_you_can_view_the_information,_but_for_any_edits_or_additions,_kindly_contact_your_teacher_directly.": "Here your teacher can edit or add your accommodation details. Please note that you can view the information, but for any edits or additions, kindly contact your teacher directly.",
|
|
3813
3816
|
"this_is_a_brand_new_beta_version_for_your_personal_learning_journey._you_can_think_about_what_you_want_like_to_do_and_how_you_like_to_learn._we_advise_you_to_do_it_gradually_per_section_and_visit_it_once_a_month.": "This is a brand new beta version for your personal learning journey. You can think about what you want like to do and how you like to learn. We advise you to do it gradually per section and visit it once a month.",
|
|
3817
|
+
weekly_quests: weekly_quests,
|
|
3814
3818
|
responses_comparisons: responses_comparisons,
|
|
3815
3819
|
dropdown_and_verbal_questions_responses: dropdown_and_verbal_questions_responses,
|
|
3816
3820
|
mario_tools: mario_tools,
|
|
@@ -3967,7 +3971,8 @@ var lang_us = {
|
|
|
3967
3971
|
suggestion: suggestion,
|
|
3968
3972
|
tutorial_screen: tutorial_screen,
|
|
3969
3973
|
reflection_forms: reflection_forms,
|
|
3970
|
-
select_question_to_add: select_question_to_add
|
|
3974
|
+
select_question_to_add: select_question_to_add,
|
|
3975
|
+
all_of_the_students_marked_as_feeling_safe: all_of_the_students_marked_as_feeling_safe
|
|
3971
3976
|
};
|
|
3972
3977
|
|
|
3973
3978
|
var dashboard$1 = "Dashboard";
|
|
@@ -4520,6 +4525,7 @@ var do_you_want_to_share_a_survey_to_teachers$1 = "Do you want to share a survey
|
|
|
4520
4525
|
var you_can_share_this_survey_to_teachers_to_get_more_insight_about_your_student$1 = "You can share this survey to teachers to get more insight about your student.";
|
|
4521
4526
|
var skip$1 = "skip";
|
|
4522
4527
|
var survey_questions$1 = "Survey questions";
|
|
4528
|
+
var weekly_quests$1 = "Weekly quests";
|
|
4523
4529
|
var add_survey_question$1 = "Add Survey Question";
|
|
4524
4530
|
var additional_question$1 = "Additional Question";
|
|
4525
4531
|
var add_additional_question$1 = "Add additional question";
|
|
@@ -5776,13 +5782,13 @@ var accommodation_set$1 = "Accommodation Set";
|
|
|
5776
5782
|
var add_new_accommodation$1 = "Add new accommodation";
|
|
5777
5783
|
var print_my_accommodations$1 = "Print my accommodations";
|
|
5778
5784
|
var my_learning_progress$1 = "My Learning Progress";
|
|
5785
|
+
var inactive_students$1 = "Inactive Students";
|
|
5779
5786
|
var responses_comparisons$1 = "Responses Comparisons";
|
|
5780
5787
|
var dropdown_and_verbal_questions_responses$1 = "Dropdown and Verbal Questions Responses";
|
|
5781
5788
|
var mario_tools$1 = "MARIO TOOLS";
|
|
5782
5789
|
var customize$1 = "Customize";
|
|
5783
5790
|
var techical_settings$1 = "Technical Settings";
|
|
5784
5791
|
var data_import_export$1 = "Data Import/Export";
|
|
5785
|
-
var inactive_students$1 = "Inactive Students";
|
|
5786
5792
|
var admin_general_tips$1 = "Admin General Tips";
|
|
5787
5793
|
var school_usage$1 = "School Usage";
|
|
5788
5794
|
var total_conversations_time$1 = "Total Conversations Time";
|
|
@@ -5917,6 +5923,7 @@ var suggestion$1 = "suggestion";
|
|
|
5917
5923
|
var tutorial_screen$1 = "tutorial screen";
|
|
5918
5924
|
var reflection_forms$1 = "reflection forms";
|
|
5919
5925
|
var select_question_to_add$1 = "Select question to add";
|
|
5926
|
+
var all_of_the_students_marked_as_feeling_safe$1 = "All of the students marked as feeling safe";
|
|
5920
5927
|
var lang_uk = {
|
|
5921
5928
|
dashboard: dashboard$1,
|
|
5922
5929
|
user: user$1,
|
|
@@ -6474,6 +6481,7 @@ var lang_uk = {
|
|
|
6474
6481
|
you_can_share_this_survey_to_teachers_to_get_more_insight_about_your_student: you_can_share_this_survey_to_teachers_to_get_more_insight_about_your_student$1,
|
|
6475
6482
|
skip: skip$1,
|
|
6476
6483
|
survey_questions: survey_questions$1,
|
|
6484
|
+
weekly_quests: weekly_quests$1,
|
|
6477
6485
|
add_survey_question: add_survey_question$1,
|
|
6478
6486
|
additional_question: additional_question$1,
|
|
6479
6487
|
add_additional_question: add_additional_question$1,
|
|
@@ -7743,6 +7751,7 @@ var lang_uk = {
|
|
|
7743
7751
|
print_my_accommodations: print_my_accommodations$1,
|
|
7744
7752
|
my_learning_progress: my_learning_progress$1,
|
|
7745
7753
|
"here_your_teacher_can_edit_or_add_your_accommodation_details._please_note_that_you_can_view_the_information,_but_for_any_edits_or_additions,_kindly_contact_your_teacher_directly.": "Here your teacher can edit or add your accommodation details. Please note that you can view the information, but for any edits or additions, kindly contact your teacher directly.",
|
|
7754
|
+
inactive_students: inactive_students$1,
|
|
7746
7755
|
"this_is_a_brand_new_beta_version_for_your_personal_learning_journey._you_can_think_about_what_you_want_like_to_do_and_how_you_like_to_learn._we_advise_you_to_do_it_gradually_per_section_and_visit_it_once_a_month.": "This is a brand new beta version for your personal learning journey. You can think about what you want like to do and how you like to learn. We advise you to do it gradually per section and visit it once a month.",
|
|
7747
7756
|
responses_comparisons: responses_comparisons$1,
|
|
7748
7757
|
dropdown_and_verbal_questions_responses: dropdown_and_verbal_questions_responses$1,
|
|
@@ -7750,7 +7759,6 @@ var lang_uk = {
|
|
|
7750
7759
|
customize: customize$1,
|
|
7751
7760
|
techical_settings: techical_settings$1,
|
|
7752
7761
|
data_import_export: data_import_export$1,
|
|
7753
|
-
inactive_students: inactive_students$1,
|
|
7754
7762
|
admin_general_tips: admin_general_tips$1,
|
|
7755
7763
|
school_usage: school_usage$1,
|
|
7756
7764
|
total_conversations_time: total_conversations_time$1,
|
|
@@ -7900,7 +7908,8 @@ var lang_uk = {
|
|
|
7900
7908
|
suggestion: suggestion$1,
|
|
7901
7909
|
tutorial_screen: tutorial_screen$1,
|
|
7902
7910
|
reflection_forms: reflection_forms$1,
|
|
7903
|
-
select_question_to_add: select_question_to_add$1
|
|
7911
|
+
select_question_to_add: select_question_to_add$1,
|
|
7912
|
+
all_of_the_students_marked_as_feeling_safe: all_of_the_students_marked_as_feeling_safe$1
|
|
7904
7913
|
};
|
|
7905
7914
|
|
|
7906
7915
|
var dashboard$2 = "لوحة المعلومات";
|
|
@@ -12519,8 +12528,6 @@ var performance$4 = "Actuación";
|
|
|
12519
12528
|
var not_enough_challenge_leading_to_boredom_and_lack_of_interest$3 = "No hay suficientes desafíos lo que lleva al aburrimiento y la falta de interés.";
|
|
12520
12529
|
var calm_and_relaxed_but_not_enough_motivation_to_perform_at_my_best$3 = "Tranquilo y relajado pero no hay suficiente motivación para dar lo mejor de mí.";
|
|
12521
12530
|
var manageable_levels_of_stress_allowing_me_to_perform_at_my_best$3 = "Niveles manejables de estrés que me permiten rendir al máximo.";
|
|
12522
|
-
var still_in_control_but_starting_to_feel_the_pressure$3 = "Aún tengo el control pero empiezo a sentir la presión.";
|
|
12523
|
-
var too_much_pressure_and_really_struggling_to_manage_my_workload$3 = "Demasiada presión y muchas dificultades para gestionar mi carga de trabajo.";
|
|
12524
12531
|
var import_emails_by_csv$3 = "Importar correo electrónico por csv";
|
|
12525
12532
|
var request_number$3 = "Número de solicitud";
|
|
12526
12533
|
var select_or_input_class_type$3 = "Seleccione o ingrese el tipo de clase";
|
|
@@ -13600,7 +13607,7 @@ var customize$3 = "Personalizar";
|
|
|
13600
13607
|
var techical_settings$3 = "Configuración técnica";
|
|
13601
13608
|
var data_import_export$3 = "Importación/Exportación de datos";
|
|
13602
13609
|
var question_text$3 = "Texto de la pregunta";
|
|
13603
|
-
var weekly_quests = "Misiones semanales";
|
|
13610
|
+
var weekly_quests$2 = "Misiones semanales";
|
|
13604
13611
|
var inactive_students$3 = "Estudiantes inactivos";
|
|
13605
13612
|
var admin_general_tips$3 = "Consejos generales para el administrador";
|
|
13606
13613
|
var school_usage$3 = "Uso escolar";
|
|
@@ -14453,8 +14460,6 @@ var lang_es = {
|
|
|
14453
14460
|
not_enough_challenge_leading_to_boredom_and_lack_of_interest: not_enough_challenge_leading_to_boredom_and_lack_of_interest$3,
|
|
14454
14461
|
calm_and_relaxed_but_not_enough_motivation_to_perform_at_my_best: calm_and_relaxed_but_not_enough_motivation_to_perform_at_my_best$3,
|
|
14455
14462
|
manageable_levels_of_stress_allowing_me_to_perform_at_my_best: manageable_levels_of_stress_allowing_me_to_perform_at_my_best$3,
|
|
14456
|
-
still_in_control_but_starting_to_feel_the_pressure: still_in_control_but_starting_to_feel_the_pressure$3,
|
|
14457
|
-
too_much_pressure_and_really_struggling_to_manage_my_workload: too_much_pressure_and_really_struggling_to_manage_my_workload$3,
|
|
14458
14463
|
import_emails_by_csv: import_emails_by_csv$3,
|
|
14459
14464
|
request_number: request_number$3,
|
|
14460
14465
|
select_or_input_class_type: select_or_input_class_type$3,
|
|
@@ -15539,7 +15544,7 @@ var lang_es = {
|
|
|
15539
15544
|
techical_settings: techical_settings$3,
|
|
15540
15545
|
data_import_export: data_import_export$3,
|
|
15541
15546
|
question_text: question_text$3,
|
|
15542
|
-
weekly_quests: weekly_quests,
|
|
15547
|
+
weekly_quests: weekly_quests$2,
|
|
15543
15548
|
inactive_students: inactive_students$3,
|
|
15544
15549
|
admin_general_tips: admin_general_tips$3,
|
|
15545
15550
|
school_usage: school_usage$3,
|
|
@@ -16422,8 +16427,8 @@ var performance$5 = "表现";
|
|
|
16422
16427
|
var not_enough_challenge_leading_to_boredom_and_lack_of_interest$4 = "挑战不够,导致无聊和缺乏兴趣。";
|
|
16423
16428
|
var calm_and_relaxed_but_not_enough_motivation_to_perform_at_my_best$4 = "平静而放松,但没有足够的动力来发挥我的最佳水平。";
|
|
16424
16429
|
var manageable_levels_of_stress_allowing_me_to_perform_at_my_best$4 = "可控的压力水平让我能够发挥出最佳水平。";
|
|
16425
|
-
var still_in_control_but_starting_to_feel_the_pressure$
|
|
16426
|
-
var too_much_pressure_and_really_struggling_to_manage_my_workload$
|
|
16430
|
+
var still_in_control_but_starting_to_feel_the_pressure$3 = "仍在控制之中,但开始感到压力。";
|
|
16431
|
+
var too_much_pressure_and_really_struggling_to_manage_my_workload$3 = "压力过大,真的很难管理我的工作量。";
|
|
16427
16432
|
var import_emails_by_csv$4 = "通过 csv 导入电子邮件";
|
|
16428
16433
|
var request_number$4 = "请求编号";
|
|
16429
16434
|
var select_or_input_class_type$4 = "选择或输入班级类型";
|
|
@@ -17503,7 +17508,7 @@ var customize$4 = "自定义";
|
|
|
17503
17508
|
var techical_settings$4 = "技术设置";
|
|
17504
17509
|
var data_import_export$4 = "数据导入/导出";
|
|
17505
17510
|
var question_text$4 = "问题文本";
|
|
17506
|
-
var weekly_quests$
|
|
17511
|
+
var weekly_quests$3 = "每周任务";
|
|
17507
17512
|
var inactive_students$4 = "非活跃学生";
|
|
17508
17513
|
var admin_general_tips$4 = "管理员一般提示";
|
|
17509
17514
|
var school_usage$4 = "学校使用";
|
|
@@ -18383,8 +18388,8 @@ var lang_zh = {
|
|
|
18383
18388
|
not_enough_challenge_leading_to_boredom_and_lack_of_interest: not_enough_challenge_leading_to_boredom_and_lack_of_interest$4,
|
|
18384
18389
|
calm_and_relaxed_but_not_enough_motivation_to_perform_at_my_best: calm_and_relaxed_but_not_enough_motivation_to_perform_at_my_best$4,
|
|
18385
18390
|
manageable_levels_of_stress_allowing_me_to_perform_at_my_best: manageable_levels_of_stress_allowing_me_to_perform_at_my_best$4,
|
|
18386
|
-
still_in_control_but_starting_to_feel_the_pressure: still_in_control_but_starting_to_feel_the_pressure$
|
|
18387
|
-
too_much_pressure_and_really_struggling_to_manage_my_workload: too_much_pressure_and_really_struggling_to_manage_my_workload$
|
|
18391
|
+
still_in_control_but_starting_to_feel_the_pressure: still_in_control_but_starting_to_feel_the_pressure$3,
|
|
18392
|
+
too_much_pressure_and_really_struggling_to_manage_my_workload: too_much_pressure_and_really_struggling_to_manage_my_workload$3,
|
|
18388
18393
|
import_emails_by_csv: import_emails_by_csv$4,
|
|
18389
18394
|
request_number: request_number$4,
|
|
18390
18395
|
select_or_input_class_type: select_or_input_class_type$4,
|
|
@@ -19469,7 +19474,7 @@ var lang_zh = {
|
|
|
19469
19474
|
techical_settings: techical_settings$4,
|
|
19470
19475
|
data_import_export: data_import_export$4,
|
|
19471
19476
|
question_text: question_text$4,
|
|
19472
|
-
weekly_quests: weekly_quests$
|
|
19477
|
+
weekly_quests: weekly_quests$3,
|
|
19473
19478
|
inactive_students: inactive_students$4,
|
|
19474
19479
|
admin_general_tips: admin_general_tips$4,
|
|
19475
19480
|
school_usage: school_usage$4,
|
|
@@ -37171,6 +37176,8 @@ var setModal = createAction("common/setModal");
|
|
|
37171
37176
|
var setUser = createAction("common/setUser");
|
|
37172
37177
|
var setSidebar = createAction("common/setSidebar");
|
|
37173
37178
|
var setAlert = createAction("common/setAlert");
|
|
37179
|
+
var setIsLoginGoogle = createAction("common/setIsLoginGoogle");
|
|
37180
|
+
var setInforUserGoogle = createAction("common/setInforUserGoogle");
|
|
37174
37181
|
var reset = createAction("common/reset");
|
|
37175
37182
|
var showMenuBar = createAction("common/showMenuBar");
|
|
37176
37183
|
var showFontSize = createAction("common/showFontSize");
|
|
@@ -37234,13 +37241,11 @@ var apiUpload = axios.create({
|
|
|
37234
37241
|
return i.interceptors.response.use(function (response) {
|
|
37235
37242
|
return response;
|
|
37236
37243
|
}, function (error) {
|
|
37237
|
-
var _error$response$confi, _error$response$confi2, _error$response$confi3, _error$response$confi4;
|
|
37238
|
-
|
|
37239
37244
|
console.log({
|
|
37240
37245
|
error: error
|
|
37241
37246
|
});
|
|
37242
37247
|
|
|
37243
|
-
if (error.response.status === 401
|
|
37248
|
+
if (error.response.status === 401) {
|
|
37244
37249
|
Object.keys(localStorage).forEach(function (key) {
|
|
37245
37250
|
if (!key.includes('learning-plan')) delete localStorage[key];
|
|
37246
37251
|
});
|
|
@@ -37257,13 +37262,16 @@ var apiUpload = axios.create({
|
|
|
37257
37262
|
amplitude.getInstance().resetSessionId();
|
|
37258
37263
|
}
|
|
37259
37264
|
|
|
37260
|
-
localStorage.
|
|
37265
|
+
localStorage.removeItem(ACCESS_TOKEN);
|
|
37266
|
+
localStorage.removeItem("USER_EMAIL");
|
|
37267
|
+
localStorage.removeItem("ROLES");
|
|
37261
37268
|
window.location.href = "/login";
|
|
37262
37269
|
}
|
|
37263
37270
|
|
|
37264
|
-
if (error.response.status == 403
|
|
37271
|
+
if (error.response.status == 403) {
|
|
37265
37272
|
localStorage.removeItem(ACCESS_TOKEN);
|
|
37266
37273
|
localStorage.removeItem("USER_EMAIL");
|
|
37274
|
+
localStorage.removeItem("ROLES");
|
|
37267
37275
|
window.location.href = "/login";
|
|
37268
37276
|
}
|
|
37269
37277
|
|
|
@@ -37307,8 +37315,12 @@ var checkResetToken = function checkResetToken(token, key) {
|
|
|
37307
37315
|
var resetPassword = function resetPassword(data) {
|
|
37308
37316
|
return api.post(ACCOUNT_URL + "/resetpassword", data);
|
|
37309
37317
|
};
|
|
37310
|
-
var checkUserGoogle = function checkUserGoogle(body) {
|
|
37311
|
-
return api.post(USER_URL + "/check-user", body
|
|
37318
|
+
var checkUserGoogle = function checkUserGoogle(type, body) {
|
|
37319
|
+
return api.post(USER_URL + "/check-user", body, {
|
|
37320
|
+
params: {
|
|
37321
|
+
type: type
|
|
37322
|
+
}
|
|
37323
|
+
});
|
|
37312
37324
|
};
|
|
37313
37325
|
var getAllLoginTeacher = function getAllLoginTeacher(param) {
|
|
37314
37326
|
return api.get(TEACHER_URL + "/get-teacher-login", {
|
|
@@ -37330,6 +37342,14 @@ var getSchoolSettings = function getSchoolSettings() {
|
|
|
37330
37342
|
return api.get(SCHOOL_URL + "/settings");
|
|
37331
37343
|
};
|
|
37332
37344
|
|
|
37345
|
+
var TypeLogin;
|
|
37346
|
+
|
|
37347
|
+
(function (TypeLogin) {
|
|
37348
|
+
TypeLogin[TypeLogin["Google"] = 0] = "Google";
|
|
37349
|
+
TypeLogin[TypeLogin["ClassLink"] = 1] = "ClassLink";
|
|
37350
|
+
TypeLogin[TypeLogin["MicrosoftSSO"] = 2] = "MicrosoftSSO";
|
|
37351
|
+
})(TypeLogin || (TypeLogin = {}));
|
|
37352
|
+
|
|
37333
37353
|
var LoginType;
|
|
37334
37354
|
|
|
37335
37355
|
(function (LoginType) {
|
|
@@ -37338,6 +37358,48 @@ var LoginType;
|
|
|
37338
37358
|
LoginType[LoginType["Impersonate"] = 2] = "Impersonate";
|
|
37339
37359
|
})(LoginType || (LoginType = {}));
|
|
37340
37360
|
|
|
37361
|
+
var msalConfig = {
|
|
37362
|
+
auth: {
|
|
37363
|
+
clientId: "90c6897c-f17b-475e-a7a8-9a19651e0060",
|
|
37364
|
+
authority: "https://login.microsoftonline.com/common",
|
|
37365
|
+
redirectUri: window.location.origin + "/login"
|
|
37366
|
+
},
|
|
37367
|
+
cache: {
|
|
37368
|
+
cacheLocation: "sessionStorage",
|
|
37369
|
+
storeAuthStateInCookie: false
|
|
37370
|
+
},
|
|
37371
|
+
system: {
|
|
37372
|
+
loggerOptions: {
|
|
37373
|
+
loggerCallback: function loggerCallback(level, message, containsPii) {
|
|
37374
|
+
if (containsPii) {
|
|
37375
|
+
return;
|
|
37376
|
+
}
|
|
37377
|
+
|
|
37378
|
+
switch (level) {
|
|
37379
|
+
case LogLevel.Error:
|
|
37380
|
+
console.error(message);
|
|
37381
|
+
return;
|
|
37382
|
+
|
|
37383
|
+
case LogLevel.Info:
|
|
37384
|
+
console.info(message);
|
|
37385
|
+
return;
|
|
37386
|
+
|
|
37387
|
+
case LogLevel.Verbose:
|
|
37388
|
+
console.debug(message);
|
|
37389
|
+
return;
|
|
37390
|
+
|
|
37391
|
+
case LogLevel.Warning:
|
|
37392
|
+
console.warn(message);
|
|
37393
|
+
return;
|
|
37394
|
+
|
|
37395
|
+
default:
|
|
37396
|
+
return;
|
|
37397
|
+
}
|
|
37398
|
+
}
|
|
37399
|
+
}
|
|
37400
|
+
}
|
|
37401
|
+
};
|
|
37402
|
+
|
|
37341
37403
|
var defaultInfo = {
|
|
37342
37404
|
email: "",
|
|
37343
37405
|
password: "",
|
|
@@ -37360,36 +37422,39 @@ var useLogin = function useLogin() {
|
|
|
37360
37422
|
openLogin = _useState[0],
|
|
37361
37423
|
setOpenLogin = _useState[1];
|
|
37362
37424
|
|
|
37363
|
-
var
|
|
37364
|
-
|
|
37365
|
-
|
|
37366
|
-
|
|
37367
|
-
var _useState3 = useState(""),
|
|
37368
|
-
googleClientId = _useState3[0],
|
|
37369
|
-
setGoogleClientId = _useState3[1];
|
|
37425
|
+
var isLoginGoogle = useSelector(function (state) {
|
|
37426
|
+
return state.common.isLoginGoogle;
|
|
37427
|
+
});
|
|
37370
37428
|
|
|
37371
|
-
var
|
|
37372
|
-
|
|
37373
|
-
|
|
37429
|
+
var _useState2 = useState(""),
|
|
37430
|
+
googleClientId = _useState2[0],
|
|
37431
|
+
setGoogleClientId = _useState2[1];
|
|
37374
37432
|
|
|
37375
|
-
var
|
|
37376
|
-
|
|
37377
|
-
|
|
37433
|
+
var _useState3 = useState(""),
|
|
37434
|
+
googleRecaptchaId = _useState3[0],
|
|
37435
|
+
setGoogleRecaptchaId = _useState3[1];
|
|
37378
37436
|
|
|
37437
|
+
var infoUser = useSelector(function (state) {
|
|
37438
|
+
return state.common.inforUserGoogle;
|
|
37439
|
+
});
|
|
37379
37440
|
var params = new URLSearchParams(location.search);
|
|
37380
37441
|
var loginClassLink = params.get("type") === "classlink";
|
|
37381
37442
|
var tokenClassLink = params.get("token");
|
|
37382
37443
|
|
|
37383
|
-
var
|
|
37384
|
-
openModelAssign =
|
|
37444
|
+
var _useState4 = useState(false),
|
|
37445
|
+
openModelAssign = _useState4[0];
|
|
37446
|
+
|
|
37447
|
+
var _useState5 = useState(),
|
|
37448
|
+
msalInstance = _useState5[0],
|
|
37449
|
+
setMsalInstance = _useState5[1];
|
|
37385
37450
|
|
|
37386
37451
|
var toggle = useCallback(function () {
|
|
37387
37452
|
setOpenLogin(!openLogin);
|
|
37388
37453
|
}, [openLogin]);
|
|
37389
37454
|
|
|
37390
|
-
var
|
|
37391
|
-
isShowPassword =
|
|
37392
|
-
setIsShowPassword =
|
|
37455
|
+
var _useState6 = useState(false),
|
|
37456
|
+
isShowPassword = _useState6[0],
|
|
37457
|
+
setIsShowPassword = _useState6[1];
|
|
37393
37458
|
|
|
37394
37459
|
useEffect(function () {
|
|
37395
37460
|
document.title = TITLE;
|
|
@@ -37571,40 +37636,51 @@ var useLogin = function useLogin() {
|
|
|
37571
37636
|
}
|
|
37572
37637
|
};
|
|
37573
37638
|
|
|
37574
|
-
var fnIsCheckLogin = useCallback(function (data, token, clickHandler) {
|
|
37639
|
+
var fnIsCheckLogin = useCallback(function (type, data, token, clickHandler) {
|
|
37575
37640
|
try {
|
|
37576
|
-
var
|
|
37641
|
+
var _temp16 = function _temp16() {
|
|
37577
37642
|
dispatch(setLoading(false));
|
|
37578
37643
|
};
|
|
37579
37644
|
|
|
37580
37645
|
dispatch(setLoading(true));
|
|
37581
37646
|
|
|
37582
|
-
var
|
|
37583
|
-
return Promise.resolve(checkUserGoogle(data)).then(function (res) {
|
|
37647
|
+
var _temp17 = _catch(function () {
|
|
37648
|
+
return Promise.resolve(checkUserGoogle(type, data)).then(function (res) {
|
|
37584
37649
|
var checkUser = res.data;
|
|
37585
37650
|
|
|
37586
|
-
var
|
|
37651
|
+
var _temp13 = function () {
|
|
37587
37652
|
if (checkUser) {
|
|
37588
|
-
|
|
37589
|
-
|
|
37590
|
-
|
|
37591
|
-
captcha: clickHandlerRes,
|
|
37592
|
-
isLoginGoogle: true,
|
|
37593
|
-
rememberMe: false,
|
|
37594
|
-
password: "default",
|
|
37595
|
-
accessToken: token,
|
|
37596
|
-
loginType: LoginType.Google
|
|
37597
|
-
};
|
|
37598
|
-
return Promise.resolve(userLogin(dataUser)).then(function () {
|
|
37599
|
-
setIsLoginGoogle(false);
|
|
37653
|
+
var _temp18 = function _temp18() {
|
|
37654
|
+
return Promise.resolve(userLogin(_dataUser)).then(function () {
|
|
37655
|
+
dispatch(setIsLoginGoogle(false));
|
|
37600
37656
|
});
|
|
37601
|
-
}
|
|
37657
|
+
};
|
|
37658
|
+
|
|
37659
|
+
var _dataUser = {
|
|
37660
|
+
email: data.email,
|
|
37661
|
+
isLoginGoogle: true,
|
|
37662
|
+
rememberMe: false,
|
|
37663
|
+
password: "default",
|
|
37664
|
+
accessToken: token,
|
|
37665
|
+
captcha: "",
|
|
37666
|
+
loginType: LoginType.Google
|
|
37667
|
+
};
|
|
37668
|
+
|
|
37669
|
+
var _temp19 = function () {
|
|
37670
|
+
if (clickHandler != null) {
|
|
37671
|
+
return Promise.resolve(clickHandler()).then(function (clickHandlerRes) {
|
|
37672
|
+
_dataUser.captcha = clickHandlerRes;
|
|
37673
|
+
});
|
|
37674
|
+
}
|
|
37675
|
+
}();
|
|
37676
|
+
|
|
37677
|
+
return _temp19 && _temp19.then ? _temp19.then(_temp18) : _temp18(_temp19);
|
|
37602
37678
|
} else {
|
|
37603
|
-
setIsLoginGoogle(true);
|
|
37679
|
+
dispatch(setIsLoginGoogle(true));
|
|
37604
37680
|
}
|
|
37605
37681
|
}();
|
|
37606
37682
|
|
|
37607
|
-
if (
|
|
37683
|
+
if (_temp13 && _temp13.then) return _temp13.then(function () {});
|
|
37608
37684
|
});
|
|
37609
37685
|
}, function (err) {
|
|
37610
37686
|
var _err$response4, _err$response4$data;
|
|
@@ -37615,7 +37691,7 @@ var useLogin = function useLogin() {
|
|
|
37615
37691
|
}));
|
|
37616
37692
|
});
|
|
37617
37693
|
|
|
37618
|
-
return Promise.resolve(
|
|
37694
|
+
return Promise.resolve(_temp17 && _temp17.then ? _temp17.then(_temp16) : _temp16(_temp17));
|
|
37619
37695
|
} catch (e) {
|
|
37620
37696
|
return Promise.reject(e);
|
|
37621
37697
|
}
|
|
@@ -37623,14 +37699,14 @@ var useLogin = function useLogin() {
|
|
|
37623
37699
|
|
|
37624
37700
|
var submitLogin = function submitLogin(teacherId, clickHandler) {
|
|
37625
37701
|
try {
|
|
37626
|
-
var
|
|
37627
|
-
setIsLoginGoogle(false);
|
|
37702
|
+
var _temp23 = function _temp23() {
|
|
37703
|
+
dispatch(setIsLoginGoogle(false));
|
|
37628
37704
|
dispatch(setLoading(false));
|
|
37629
37705
|
};
|
|
37630
37706
|
|
|
37631
37707
|
dispatch(setLoading(true));
|
|
37632
37708
|
|
|
37633
|
-
var
|
|
37709
|
+
var _temp24 = _catch(function () {
|
|
37634
37710
|
var data = {
|
|
37635
37711
|
firstName: infoUser.firstName,
|
|
37636
37712
|
lastName: infoUser.lastName,
|
|
@@ -37641,7 +37717,7 @@ var useLogin = function useLogin() {
|
|
|
37641
37717
|
teacherId: teacherId
|
|
37642
37718
|
};
|
|
37643
37719
|
return Promise.resolve(registerUserStudent(data)).then(function (res) {
|
|
37644
|
-
var
|
|
37720
|
+
var _temp20 = function () {
|
|
37645
37721
|
if (res.data) {
|
|
37646
37722
|
return Promise.resolve(clickHandler()).then(function (clickHandlerRes) {
|
|
37647
37723
|
var dataLogin = {
|
|
@@ -37653,7 +37729,7 @@ var useLogin = function useLogin() {
|
|
|
37653
37729
|
accessToken: infoUser.accessToken,
|
|
37654
37730
|
loginType: LoginType.Google
|
|
37655
37731
|
};
|
|
37656
|
-
setIsLoginGoogle(false);
|
|
37732
|
+
dispatch(setIsLoginGoogle(false));
|
|
37657
37733
|
return Promise.resolve(userLogin(dataLogin)).then(function () {
|
|
37658
37734
|
history.push(HOMEPAGE_STUDENT);
|
|
37659
37735
|
});
|
|
@@ -37661,7 +37737,7 @@ var useLogin = function useLogin() {
|
|
|
37661
37737
|
}
|
|
37662
37738
|
}();
|
|
37663
37739
|
|
|
37664
|
-
if (
|
|
37740
|
+
if (_temp20 && _temp20.then) return _temp20.then(function () {});
|
|
37665
37741
|
});
|
|
37666
37742
|
}, function (err) {
|
|
37667
37743
|
var _err$response5, _err$response5$data;
|
|
@@ -37672,7 +37748,7 @@ var useLogin = function useLogin() {
|
|
|
37672
37748
|
}));
|
|
37673
37749
|
});
|
|
37674
37750
|
|
|
37675
|
-
return Promise.resolve(
|
|
37751
|
+
return Promise.resolve(_temp24 && _temp24.then ? _temp24.then(_temp23) : _temp23(_temp24));
|
|
37676
37752
|
} catch (e) {
|
|
37677
37753
|
return Promise.reject(e);
|
|
37678
37754
|
}
|
|
@@ -37680,7 +37756,7 @@ var useLogin = function useLogin() {
|
|
|
37680
37756
|
|
|
37681
37757
|
var getInformationSetting = function getInformationSetting() {
|
|
37682
37758
|
try {
|
|
37683
|
-
var
|
|
37759
|
+
var _temp26 = _catch(function () {
|
|
37684
37760
|
return Promise.resolve(getSchoolSettings()).then(function (res) {
|
|
37685
37761
|
dispatch(setSandboxMode(res.data.isSandboxMode));
|
|
37686
37762
|
});
|
|
@@ -37688,14 +37764,89 @@ var useLogin = function useLogin() {
|
|
|
37688
37764
|
console.error(err);
|
|
37689
37765
|
});
|
|
37690
37766
|
|
|
37691
|
-
return Promise.resolve(
|
|
37767
|
+
return Promise.resolve(_temp26 && _temp26.then ? _temp26.then(function () {}) : void 0);
|
|
37768
|
+
} catch (e) {
|
|
37769
|
+
return Promise.reject(e);
|
|
37770
|
+
}
|
|
37771
|
+
};
|
|
37772
|
+
|
|
37773
|
+
var fnLoginSSO = function fnLoginSSO(clickHandler) {
|
|
37774
|
+
try {
|
|
37775
|
+
msalInstance.handleRedirectPromise().then(function (tokenResponse) {
|
|
37776
|
+
try {
|
|
37777
|
+
var _temp29 = function () {
|
|
37778
|
+
if (!tokenResponse) {
|
|
37779
|
+
var accounts = msalInstance.getAllAccounts();
|
|
37780
|
+
|
|
37781
|
+
var _temp30 = function () {
|
|
37782
|
+
if (accounts.length === 0) {
|
|
37783
|
+
msalInstance.loginRedirect();
|
|
37784
|
+
} else {
|
|
37785
|
+
var currentAccount = accounts[0];
|
|
37786
|
+
return Promise.resolve(getCurrentAccount(currentAccount, clickHandler)).then(function () {});
|
|
37787
|
+
}
|
|
37788
|
+
}();
|
|
37789
|
+
|
|
37790
|
+
if (_temp30 && _temp30.then) return _temp30.then(function () {});
|
|
37791
|
+
} else {
|
|
37792
|
+
var currentAccount = tokenResponse.account;
|
|
37793
|
+
return Promise.resolve(getCurrentAccount(currentAccount, clickHandler)).then(function () {});
|
|
37794
|
+
}
|
|
37795
|
+
}();
|
|
37796
|
+
|
|
37797
|
+
return Promise.resolve(_temp29 && _temp29.then ? _temp29.then(function () {}) : void 0);
|
|
37798
|
+
} catch (e) {
|
|
37799
|
+
return Promise.reject(e);
|
|
37800
|
+
}
|
|
37801
|
+
})["catch"](function (err) {
|
|
37802
|
+
console.error(err);
|
|
37803
|
+
});
|
|
37804
|
+
return Promise.resolve();
|
|
37805
|
+
} catch (e) {
|
|
37806
|
+
return Promise.reject(e);
|
|
37807
|
+
}
|
|
37808
|
+
};
|
|
37809
|
+
|
|
37810
|
+
var getCurrentAccount = function getCurrentAccount(account, clickHandler) {
|
|
37811
|
+
try {
|
|
37812
|
+
var fullName = account.name;
|
|
37813
|
+
var infoLogin = {
|
|
37814
|
+
firstName: fullName.split(' ').slice(0, -1).join(' '),
|
|
37815
|
+
lastName: fullName.split(' ').slice(-1).join(' '),
|
|
37816
|
+
fullName: fullName,
|
|
37817
|
+
imageUrl: "",
|
|
37818
|
+
email: account.username,
|
|
37819
|
+
accessToken: account.idTokenClaims.aio,
|
|
37820
|
+
googleId: account.tenantId
|
|
37821
|
+
};
|
|
37822
|
+
dispatch(setInforUserGoogle(infoLogin));
|
|
37823
|
+
return Promise.resolve(fnIsCheckLogin(TypeLogin.MicrosoftSSO, infoLogin, account.idTokenClaims.aio, clickHandler)).then(function () {});
|
|
37824
|
+
} catch (e) {
|
|
37825
|
+
return Promise.reject(e);
|
|
37826
|
+
}
|
|
37827
|
+
};
|
|
37828
|
+
|
|
37829
|
+
var initInformationSSO = function initInformationSSO() {
|
|
37830
|
+
try {
|
|
37831
|
+
var _msalInstance = new PublicClientApplication(msalConfig);
|
|
37832
|
+
|
|
37833
|
+
setMsalInstance(_msalInstance);
|
|
37834
|
+
return Promise.resolve();
|
|
37692
37835
|
} catch (e) {
|
|
37693
37836
|
return Promise.reject(e);
|
|
37694
37837
|
}
|
|
37695
37838
|
};
|
|
37696
37839
|
|
|
37840
|
+
useEffect(function () {
|
|
37841
|
+
var redirectUrl = window.location.href;
|
|
37842
|
+
|
|
37843
|
+
if (!!msalInstance && redirectUrl.includes("code") && redirectUrl.includes("client_info")) {
|
|
37844
|
+
fnLoginSSO();
|
|
37845
|
+
}
|
|
37846
|
+
}, [JSON.stringify(msalInstance)]);
|
|
37697
37847
|
useEffect(function () {
|
|
37698
37848
|
getInformationSetting();
|
|
37849
|
+
initInformationSSO();
|
|
37699
37850
|
}, []);
|
|
37700
37851
|
return {
|
|
37701
37852
|
defaultInfo: defaultInfo,
|
|
@@ -37707,13 +37858,12 @@ var useLogin = function useLogin() {
|
|
|
37707
37858
|
fnIsCheckLogin: fnIsCheckLogin,
|
|
37708
37859
|
isLoginGoogle: isLoginGoogle,
|
|
37709
37860
|
infoUser: infoUser,
|
|
37710
|
-
setInfoUser: setInfoUser,
|
|
37711
37861
|
submitLogin: submitLogin,
|
|
37712
|
-
setIsLoginGoogle: setIsLoginGoogle,
|
|
37713
37862
|
googleClientId: googleClientId,
|
|
37714
37863
|
googleRecaptchaId: googleRecaptchaId,
|
|
37715
37864
|
handleCancelModelAssign: handleCancelModelAssign,
|
|
37716
|
-
openModelAssign: openModelAssign
|
|
37865
|
+
openModelAssign: openModelAssign,
|
|
37866
|
+
fnLoginSSO: fnLoginSSO
|
|
37717
37867
|
};
|
|
37718
37868
|
};
|
|
37719
37869
|
|
|
@@ -37741,8 +37891,7 @@ var BlockSelectTeacher = function BlockSelectTeacher(_ref) {
|
|
|
37741
37891
|
openModal = _ref.openModal,
|
|
37742
37892
|
onSubmit = _ref.onSubmit,
|
|
37743
37893
|
token = _ref.token,
|
|
37744
|
-
email = _ref.email
|
|
37745
|
-
setOpenModal = _ref.setOpenModal;
|
|
37894
|
+
email = _ref.email;
|
|
37746
37895
|
|
|
37747
37896
|
var _useState = useState(false),
|
|
37748
37897
|
modal = _useState[0],
|
|
@@ -37751,12 +37900,6 @@ var BlockSelectTeacher = function BlockSelectTeacher(_ref) {
|
|
|
37751
37900
|
useEffect(function () {
|
|
37752
37901
|
setModal(openModal);
|
|
37753
37902
|
}, [openModal]);
|
|
37754
|
-
|
|
37755
|
-
var toggle = function toggle() {
|
|
37756
|
-
setModal(!modal);
|
|
37757
|
-
setOpenModal(!modal);
|
|
37758
|
-
};
|
|
37759
|
-
|
|
37760
37903
|
var dispatch = useDispatch();
|
|
37761
37904
|
|
|
37762
37905
|
var _useState2 = useState([]),
|
|
@@ -37776,6 +37919,12 @@ var BlockSelectTeacher = function BlockSelectTeacher(_ref) {
|
|
|
37776
37919
|
setLoading = _useState5[1];
|
|
37777
37920
|
|
|
37778
37921
|
var timeout = useRef();
|
|
37922
|
+
|
|
37923
|
+
var toggle = function toggle() {
|
|
37924
|
+
setModal(!modal);
|
|
37925
|
+
dispatch(setIsLoginGoogle(!modal));
|
|
37926
|
+
};
|
|
37927
|
+
|
|
37779
37928
|
var loadData = useCallback(function () {
|
|
37780
37929
|
try {
|
|
37781
37930
|
var _temp3 = function _temp3() {
|
|
@@ -37884,16 +38033,17 @@ var BlockLogin = function BlockLogin(_ref) {
|
|
|
37884
38033
|
setIsShowPassword = _useLogin.setIsShowPassword,
|
|
37885
38034
|
fnIsCheckLogin = _useLogin.fnIsCheckLogin,
|
|
37886
38035
|
isLoginGoogle = _useLogin.isLoginGoogle,
|
|
37887
|
-
setInfoUser = _useLogin.setInfoUser,
|
|
37888
38036
|
submitLogin = _useLogin.submitLogin,
|
|
37889
38037
|
infoUser = _useLogin.infoUser,
|
|
37890
|
-
|
|
37891
|
-
|
|
38038
|
+
googleClientId = _useLogin.googleClientId,
|
|
38039
|
+
fnLoginSSO = _useLogin.fnLoginSSO;
|
|
37892
38040
|
|
|
37893
38041
|
var togglePasswordVisible = function togglePasswordVisible() {
|
|
37894
38042
|
return setIsShowPassword(!isShowPassword);
|
|
37895
38043
|
};
|
|
37896
38044
|
|
|
38045
|
+
var dispatch = useDispatch();
|
|
38046
|
+
|
|
37897
38047
|
var _useGoogleReCaptcha = useGoogleReCaptcha(),
|
|
37898
38048
|
executeRecaptcha = _useGoogleReCaptcha.executeRecaptcha;
|
|
37899
38049
|
|
|
@@ -37927,6 +38077,7 @@ var BlockLogin = function BlockLogin(_ref) {
|
|
|
37927
38077
|
return;
|
|
37928
38078
|
}
|
|
37929
38079
|
|
|
38080
|
+
console.log("assss");
|
|
37930
38081
|
var infoLogin = {
|
|
37931
38082
|
firstName: givenName,
|
|
37932
38083
|
lastName: familyName,
|
|
@@ -37936,8 +38087,8 @@ var BlockLogin = function BlockLogin(_ref) {
|
|
|
37936
38087
|
accessToken: accessToken,
|
|
37937
38088
|
googleId: googleId
|
|
37938
38089
|
};
|
|
37939
|
-
|
|
37940
|
-
fnIsCheckLogin(infoLogin, accessToken, clickHandler);
|
|
38090
|
+
dispatch(setInforUserGoogle(infoLogin));
|
|
38091
|
+
fnIsCheckLogin(TypeLogin.Google, infoLogin, accessToken, clickHandler);
|
|
37941
38092
|
}
|
|
37942
38093
|
};
|
|
37943
38094
|
|
|
@@ -38022,6 +38173,15 @@ var BlockLogin = function BlockLogin(_ref) {
|
|
|
38022
38173
|
cookiePolicy: 'single_host_origin',
|
|
38023
38174
|
className: "" + styles["btn-login-google"]
|
|
38024
38175
|
})), React.createElement("div", {
|
|
38176
|
+
className: styles["btn-login-sso"] + " mb-3"
|
|
38177
|
+
}, React.createElement("div", {
|
|
38178
|
+
className: styles["btn-login-with-sso"],
|
|
38179
|
+
onClick: function onClick() {
|
|
38180
|
+
return fnLoginSSO(clickHandler);
|
|
38181
|
+
}
|
|
38182
|
+
}, React.createElement("img", {
|
|
38183
|
+
src: "images/Single-Sign-On.png"
|
|
38184
|
+
}), " Login with SSO")), React.createElement("div", {
|
|
38025
38185
|
className: "d-flex justify-content-between"
|
|
38026
38186
|
}, React.createElement(Link, {
|
|
38027
38187
|
to: "/forgot-password",
|
|
@@ -38044,8 +38204,7 @@ var BlockLogin = function BlockLogin(_ref) {
|
|
|
38044
38204
|
},
|
|
38045
38205
|
openModal: isLoginGoogle,
|
|
38046
38206
|
token: infoUser.accessToken,
|
|
38047
|
-
email: infoUser.email
|
|
38048
|
-
setOpenModal: setIsLoginGoogle
|
|
38207
|
+
email: infoUser.email
|
|
38049
38208
|
}));
|
|
38050
38209
|
};
|
|
38051
38210
|
|
|
@@ -47060,6 +47219,8 @@ var initialState = {
|
|
|
47060
47219
|
isEnableSurvey: false,
|
|
47061
47220
|
isConversationOneToOne: false,
|
|
47062
47221
|
isSandboxMode: false,
|
|
47222
|
+
isLoginGoogle: false,
|
|
47223
|
+
inforUserGoogle: null,
|
|
47063
47224
|
language: DEFAULT_LANGUAGE_CODE,
|
|
47064
47225
|
amplitude: {
|
|
47065
47226
|
user_id: "",
|
|
@@ -47085,6 +47246,10 @@ var commonReducer = createReducer(initialState, function (builder) {
|
|
|
47085
47246
|
state.user = action.payload;
|
|
47086
47247
|
}).addCase(setSidebar, function (state, action) {
|
|
47087
47248
|
state.sidebarShow = action.payload;
|
|
47249
|
+
}).addCase(setIsLoginGoogle, function (state, action) {
|
|
47250
|
+
state.isLoginGoogle = action.payload;
|
|
47251
|
+
}).addCase(setInforUserGoogle, function (state, action) {
|
|
47252
|
+
state.inforUserGoogle = action.payload;
|
|
47088
47253
|
}).addCase(setAlert, function (state, action) {
|
|
47089
47254
|
state.alert = action.payload;
|
|
47090
47255
|
}).addCase(reset, function (_state, _action) {
|
|
@@ -47960,6 +48125,24 @@ var navMobileReducer = createReducer(initialState$B, function (builder) {
|
|
|
47960
48125
|
});
|
|
47961
48126
|
});
|
|
47962
48127
|
|
|
48128
|
+
var setWeeklyQuestList = createAction("setWeeklyQuestList");
|
|
48129
|
+
var setOpenModelCongratulation = createAction("setOpenModelCongratulation");
|
|
48130
|
+
|
|
48131
|
+
var initialState$C = {
|
|
48132
|
+
isOpenModelCongratulation: false,
|
|
48133
|
+
lastQuest: undefined,
|
|
48134
|
+
weeklyQuests: []
|
|
48135
|
+
};
|
|
48136
|
+
var weeklyQuestReducer = createReducer(initialState$C, function (builder) {
|
|
48137
|
+
builder.addCase(setWeeklyQuestList, function (state, action) {
|
|
48138
|
+
state.weeklyQuests = action.payload;
|
|
48139
|
+
}).addCase(setOpenModelCongratulation, function (state, action) {
|
|
48140
|
+
state.isOpenModelCongratulation = action.payload;
|
|
48141
|
+
}).addCase(reset, function (_state, _action) {
|
|
48142
|
+
return initialState$C;
|
|
48143
|
+
});
|
|
48144
|
+
});
|
|
48145
|
+
|
|
47963
48146
|
var rootReducer = combineReducers({
|
|
47964
48147
|
common: commonReducer,
|
|
47965
48148
|
classes: classReducer,
|
|
@@ -48000,7 +48183,8 @@ var rootReducer = combineReducers({
|
|
|
48000
48183
|
widget: widgetReducer,
|
|
48001
48184
|
bandScores: commonReducer$h,
|
|
48002
48185
|
schoolBlankDays: commonReducer$i,
|
|
48003
|
-
navMobileReducer: navMobileReducer
|
|
48186
|
+
navMobileReducer: navMobileReducer,
|
|
48187
|
+
weeklyQuests: weeklyQuestReducer
|
|
48004
48188
|
});
|
|
48005
48189
|
|
|
48006
48190
|
var store = configureStore({
|
|
@@ -48456,6 +48640,7 @@ var TheLayout = function TheLayout(_ref) {
|
|
|
48456
48640
|
|
|
48457
48641
|
var resetAuth = function resetAuth() {
|
|
48458
48642
|
localStorage.removeItem(ACCESS_TOKEN);
|
|
48643
|
+
localStorage.removeItem("ROLES");
|
|
48459
48644
|
history.push("/");
|
|
48460
48645
|
};
|
|
48461
48646
|
|
|
@@ -48483,5 +48668,5 @@ var TheLayout = function TheLayout(_ref) {
|
|
|
48483
48668
|
|
|
48484
48669
|
var amplitudeClient$1 = amplitude.getInstance();
|
|
48485
48670
|
|
|
48486
|
-
export { ACCESS_TOKEN, ANSWER_EDITOR_HEIGHT, AcademicClassSelector, AddButton, BASE_URL, CHAT_CHANNEL, CategorySelector, CommonAlert, CommonHeader, CommonModal$1 as CommonModal, CreatableSelector, CustomPagination, CustomSelector, CustomTabs as CustomTab, DATE_FORMAT, DATE_RESULT, DEFAULT_FILTER, DEFAULT_LANGUAGE_CODE, Dashboard, DeleteButtonIcon, DetailActionButtons, EMOTIONS, EditButtonIcon, EmailTemplateDetail, EmailTemplateList, EmptyDataAlert, ErrorHandler, FULL_DATE_RESULT, FaqList, InputFile as FileInput, GOOGLE_RECAPTCHA_KEY, GalleryList, INIT_AMPLITUDE_KEY_PROD, INIT_AMPLITUDE_KEY_STAGE, Images, LANGUAGES, LICENSE_AGGRID, LinkEditButton, Loading, Login, MediaList, NOTIFICATION_ALERT_KEY, NOTIFICATION_CHANNEL, NotFound, NotificationList, NotificationLogoutModal, NotificationModal, QUESTION_TYPES, QUESTION_TYPES_OPTIONS, QuestionCategorySelector, QuestionTypeSelector, QuitPrompt, ReactNotification, RequiredLabel$1 as RequiredLabel, SANDBOX_NOTIFICATION, SUPPORTED_LANGUAGES_CODE, SandboxAlert, SchoolList, ScrollToTop, SearchBox$1 as SearchBox, SearchBoxContainer, SkillList, StarRatingSelector, SuggestionCategorySelector, TAB_COLORS, TINY_MCE_API_KEY, TheContent$1 as TheContent, TheLayout, ToggleButton, UploadFileButton, UserContainer, UserDetail, UserList, addTab, amplitudeClient$1 as amplitudeClient, answerQuestion, answerQuestionDataPlayer, api, apiUpload, canAccess as canAccessRoute, changeNote, changeTags, clearTab, closeTab, debounce, editTab, editorConfig, firstCheckToken, generateRandomString, getCookieValue, getFileUrl, getInfo, getStaticFileUrl, getTextFromHTML, i18n, initAmplitude, isInViewport, isLocalhost, reset, setAlert, setAssessmentList, setAssignmentList, setAssistantList, setBadgeList, setBandScoreList, setCertificateList, setClassList, setConferenceRubricList, setConversationOneToOne, setCurrentStudentId, setCurrentStudentName, setCurrentStudentUserId, setCustomAlertList, setDataPlayer, setEditItemQuesion, setEnableIEP, setEnableSurvey, setFeedbackList, setFilterWidget, setGoalExampleList, setImproveMyClass, setLanguage, setLearningSupportCategoryList, setLoading, setMailCategory, setModal, setMoveItemQuestion, setMyStudent, setQuestionByCategory, setQuestionCateList, setQuestionList, setReflectionList, setReflectionResultList, setResetQuestionList, setSandboxMode, setSchoolBlankDayList, setSelectQuestion, setSemesterList, setSessionPlayer, setSessionTemplateGeneralClassList, setSessionTemplateList, setStartTime, setStrategyList, setStudentIdSelectedByTeacher, setStudentList, setSubjectList, setSuggestionList, setTurnOffPassWhenChangeMode, setTutorialScreenList, setUser, setUserList, showFontSize, showMenuBar, store, systemCertificateUpload, systemStudentBadge, uploadFile, useFilters, useGalleryList, utcToLocalTime };
|
|
48671
|
+
export { ACCESS_TOKEN, ANSWER_EDITOR_HEIGHT, AcademicClassSelector, AddButton, BASE_URL, CHAT_CHANNEL, CategorySelector, CommonAlert, CommonHeader, CommonModal$1 as CommonModal, CreatableSelector, CustomPagination, CustomSelector, CustomTabs as CustomTab, DATE_FORMAT, DATE_RESULT, DEFAULT_FILTER, DEFAULT_LANGUAGE_CODE, Dashboard, DeleteButtonIcon, DetailActionButtons, EMOTIONS, EditButtonIcon, EmailTemplateDetail, EmailTemplateList, EmptyDataAlert, ErrorHandler, FULL_DATE_RESULT, FaqList, InputFile as FileInput, GOOGLE_RECAPTCHA_KEY, GalleryList, INIT_AMPLITUDE_KEY_PROD, INIT_AMPLITUDE_KEY_STAGE, Images, LANGUAGES, LICENSE_AGGRID, LinkEditButton, Loading, Login, MediaList, NOTIFICATION_ALERT_KEY, NOTIFICATION_CHANNEL, NotFound, NotificationList, NotificationLogoutModal, NotificationModal, QUESTION_TYPES, QUESTION_TYPES_OPTIONS, QuestionCategorySelector, QuestionTypeSelector, QuitPrompt, ReactNotification, RequiredLabel$1 as RequiredLabel, SANDBOX_NOTIFICATION, SUPPORTED_LANGUAGES_CODE, SandboxAlert, SchoolList, ScrollToTop, SearchBox$1 as SearchBox, SearchBoxContainer, SkillList, StarRatingSelector, SuggestionCategorySelector, TAB_COLORS, TINY_MCE_API_KEY, TheContent$1 as TheContent, TheLayout, ToggleButton, UploadFileButton, UserContainer, UserDetail, UserList, addTab, amplitudeClient$1 as amplitudeClient, answerQuestion, answerQuestionDataPlayer, api, apiUpload, canAccess as canAccessRoute, changeNote, changeTags, clearTab, closeTab, debounce, editTab, editorConfig, firstCheckToken, generateRandomString, getCookieValue, getFileUrl, getInfo, getStaticFileUrl, getTextFromHTML, i18n, initAmplitude, isInViewport, isLocalhost, reset, setAlert, setAssessmentList, setAssignmentList, setAssistantList, setBadgeList, setBandScoreList, setCertificateList, setClassList, setConferenceRubricList, setConversationOneToOne, setCurrentStudentId, setCurrentStudentName, setCurrentStudentUserId, setCustomAlertList, setDataPlayer, setEditItemQuesion, setEnableIEP, setEnableSurvey, setFeedbackList, setFilterWidget, setGoalExampleList, setImproveMyClass, setLanguage, setLearningSupportCategoryList, setLoading, setMailCategory, setModal, setMoveItemQuestion, setMyStudent, setOpenModelCongratulation, setQuestionByCategory, setQuestionCateList, setQuestionList, setReflectionList, setReflectionResultList, setResetQuestionList, setSandboxMode, setSchoolBlankDayList, setSelectQuestion, setSemesterList, setSessionPlayer, setSessionTemplateGeneralClassList, setSessionTemplateList, setStartTime, setStrategyList, setStudentIdSelectedByTeacher, setStudentList, setSubjectList, setSuggestionList, setTurnOffPassWhenChangeMode, setTutorialScreenList, setUser, setUserList, setWeeklyQuestList, showFontSize, showMenuBar, store, systemCertificateUpload, systemStudentBadge, uploadFile, useFilters, useGalleryList, utcToLocalTime };
|
|
48487
48672
|
//# sourceMappingURL=index.modern.js.map
|