mario-education 2.5.12-release → 2.5.14-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/components/icons/DoneCheckInIcon.d.ts +4 -0
- package/dist/components/layouts/icons/DeleteIcon.d.ts +5 -0
- package/dist/components/layouts/icons/FrequencyAndSetupIcon.d.ts +2 -0
- package/dist/components/layouts/icons/TeacherWellBeingIcon.d.ts +2 -0
- package/dist/components/layouts/icons/WellBeingDashboardIcon.d.ts +2 -0
- package/dist/containers/FrequencyAndSetup/components/ContactFlowInformation.d.ts +12 -0
- package/dist/containers/FrequencyAndSetup/components/FrequencyModeDetail.d.ts +6 -0
- package/dist/containers/FrequencyAndSetup/components/SortableItem.d.ts +6 -0
- package/dist/containers/FrequencyAndSetup/components/WrapperWellBeing.d.ts +8 -0
- package/dist/containers/FrequencyAndSetup/configs/constants.d.ts +17 -0
- package/dist/containers/FrequencyAndSetup/configs/type.d.ts +15 -0
- package/dist/containers/FrequencyAndSetup/hooks/useFrequencyAndSetup.d.ts +23 -0
- package/dist/containers/FrequencyAndSetup/views/FrequencyAndSetup.d.ts +5 -0
- package/dist/containers/MyProfile/configs/constants.d.ts +26 -0
- package/dist/containers/MyProfile/configs/teacherProfileSchema.d.ts +10 -0
- package/dist/containers/MyProfile/hooks/useChangePassword.d.ts +6 -0
- package/dist/containers/MyProfile/hooks/useProfile.d.ts +16 -0
- package/dist/containers/MyProfile/views/ChangePassword.d.ts +2 -0
- package/dist/containers/MyProfile/views/MyProfile.d.ts +3 -0
- package/dist/containers/MyProfile/views/Profile.d.ts +8 -0
- package/dist/containers/UserManagement/configs/constants.d.ts +52 -0
- package/dist/containers/UserManagement/configs/profileSchema.d.ts +13 -0
- package/dist/containers/UserManagement/hooks/useChangePassword.d.ts +6 -0
- package/dist/containers/UserManagement/hooks/useUserDetail.d.ts +45 -0
- package/dist/containers/UserManagement/views/ChangePassword.d.ts +2 -0
- package/dist/containers/UserManagement/views/Profile.d.ts +16 -0
- package/dist/containers/UserManagement/views/UserProfileManagement.d.ts +3 -0
- package/dist/containers/WellBeingDashboard/views/WellBeingDashboard.d.ts +5 -0
- package/dist/services/MyProfile.d.ts +6 -0
- package/dist/services/userManagementService.d.ts +9 -0
- package/package.json +2 -2
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ContactFlow } from '../configs/type';
|
|
2
|
+
interface IProps {
|
|
3
|
+
listContactFlow: ContactFlow[];
|
|
4
|
+
handleAddContactFlow: Function;
|
|
5
|
+
handleDeleteContactFlow: any;
|
|
6
|
+
handleChangeValueContact: Function;
|
|
7
|
+
contactIdToDeleteRef: any;
|
|
8
|
+
openModalDelete: boolean;
|
|
9
|
+
setOpenModalDelete: Function;
|
|
10
|
+
}
|
|
11
|
+
declare const ContactFlowInformation: ({ listContactFlow, handleAddContactFlow, handleDeleteContactFlow, handleChangeValueContact, contactIdToDeleteRef, openModalDelete, setOpenModalDelete }: IProps) => JSX.Element;
|
|
12
|
+
export default ContactFlowInformation;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ContactFlow, Frequency_Mode, Frequency_Setting } from "./type";
|
|
2
|
+
export declare const FrequencyMode: {
|
|
3
|
+
value: Frequency_Mode;
|
|
4
|
+
title: string;
|
|
5
|
+
description: string;
|
|
6
|
+
}[];
|
|
7
|
+
export declare const FrequencySetting: {
|
|
8
|
+
value: Frequency_Setting;
|
|
9
|
+
title: string;
|
|
10
|
+
}[];
|
|
11
|
+
export declare const listSortCheckIn: {
|
|
12
|
+
icon: string;
|
|
13
|
+
label: string;
|
|
14
|
+
value: string;
|
|
15
|
+
order: number;
|
|
16
|
+
}[];
|
|
17
|
+
export declare const InitialContactFlow: ContactFlow;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare enum Frequency_Mode {
|
|
2
|
+
Bulk = 0,
|
|
3
|
+
Detailed = 1
|
|
4
|
+
}
|
|
5
|
+
export declare enum Frequency_Setting {
|
|
6
|
+
Weekly = 0,
|
|
7
|
+
Monthly = 1,
|
|
8
|
+
Custom = 2
|
|
9
|
+
}
|
|
10
|
+
export interface ContactFlow {
|
|
11
|
+
id: number;
|
|
12
|
+
specialContactName: string;
|
|
13
|
+
contactRole: string;
|
|
14
|
+
contactEmail: string;
|
|
15
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ContactFlow, Frequency_Mode, Frequency_Setting } from '../configs/type';
|
|
3
|
+
declare const useFrequencyAndSetup: () => {
|
|
4
|
+
frequencyMode: Frequency_Mode;
|
|
5
|
+
setFrequencyMode: import("react").Dispatch<import("react").SetStateAction<Frequency_Mode>>;
|
|
6
|
+
frequencySetting: Frequency_Setting;
|
|
7
|
+
setFrequencySetting: import("react").Dispatch<import("react").SetStateAction<Frequency_Setting>>;
|
|
8
|
+
listSort: any[];
|
|
9
|
+
setListSort: import("react").Dispatch<import("react").SetStateAction<any[]>>;
|
|
10
|
+
valueSettingCustom: number;
|
|
11
|
+
setValueSettingCustom: import("react").Dispatch<import("react").SetStateAction<number>>;
|
|
12
|
+
switchContactFlow: boolean;
|
|
13
|
+
setSwitchContactFlow: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
14
|
+
listContactFlow: ContactFlow[];
|
|
15
|
+
setListContactFlow: import("react").Dispatch<import("react").SetStateAction<ContactFlow[]>>;
|
|
16
|
+
handleAddContactFlow: () => void;
|
|
17
|
+
handleDeleteContactFlow: (id: number) => void;
|
|
18
|
+
handleChangeValueContact: (id: number, key: string, value: string) => void;
|
|
19
|
+
contactIdToDeleteRef: import("react").MutableRefObject<number>;
|
|
20
|
+
openModalDelete: boolean;
|
|
21
|
+
setOpenModalDelete: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
22
|
+
};
|
|
23
|
+
export default useFrequencyAndSetup;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
interface IButtonControl {
|
|
2
|
+
value: TypeControl;
|
|
3
|
+
label: string;
|
|
4
|
+
icon: string;
|
|
5
|
+
isControl: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare enum TypeControl {
|
|
8
|
+
Info = "info",
|
|
9
|
+
ChangePassword = "changePassword",
|
|
10
|
+
Signout = "signout"
|
|
11
|
+
}
|
|
12
|
+
export declare const buttonsControl: IButtonControl[];
|
|
13
|
+
export declare const gender: string[];
|
|
14
|
+
export declare const rolesSelect: string[];
|
|
15
|
+
export declare const InitialData: {
|
|
16
|
+
firstName: string;
|
|
17
|
+
lastName: string;
|
|
18
|
+
legalGender: string;
|
|
19
|
+
dateOfBirth: string;
|
|
20
|
+
teacherRole: string;
|
|
21
|
+
email: string;
|
|
22
|
+
country: string;
|
|
23
|
+
phoneNumber: string;
|
|
24
|
+
address: string;
|
|
25
|
+
};
|
|
26
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
declare const schema: import("yup/lib/object").OptionalObjectSchema<{
|
|
2
|
+
firstName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
3
|
+
lastName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
4
|
+
email: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
5
|
+
}, Record<string, any>, import("yup/lib/object").TypeOfShape<{
|
|
6
|
+
firstName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
7
|
+
lastName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
8
|
+
email: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
9
|
+
}>>;
|
|
10
|
+
export default schema;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { TypeControl } from "../configs/constants";
|
|
3
|
+
declare const useProfile: () => {
|
|
4
|
+
dataProfile: any;
|
|
5
|
+
updateProfile: (data: any) => Promise<void>;
|
|
6
|
+
activeTab: TypeControl;
|
|
7
|
+
setActiveTab: import("react").Dispatch<import("react").SetStateAction<TypeControl>>;
|
|
8
|
+
handleImageChange: (e: any) => void;
|
|
9
|
+
handleDeleteAvatar: () => Promise<void>;
|
|
10
|
+
imageUse: any;
|
|
11
|
+
imagePreviewUrl: any;
|
|
12
|
+
currentUser: any;
|
|
13
|
+
goBack: () => void;
|
|
14
|
+
signout: () => void;
|
|
15
|
+
};
|
|
16
|
+
export default useProfile;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
interface IButtonControl {
|
|
2
|
+
value: TypeControl;
|
|
3
|
+
label: string;
|
|
4
|
+
icon: string;
|
|
5
|
+
isControl: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare enum TypeControl {
|
|
8
|
+
Info = "info",
|
|
9
|
+
ForgotPassword = "forgotPassword",
|
|
10
|
+
DownloadUserData = "downloadUserData",
|
|
11
|
+
ChangePassword = "changePassword"
|
|
12
|
+
}
|
|
13
|
+
export declare const buttonsControl: IButtonControl[];
|
|
14
|
+
export interface IOptions {
|
|
15
|
+
label: string;
|
|
16
|
+
value: string;
|
|
17
|
+
}
|
|
18
|
+
export declare type Teacher = {
|
|
19
|
+
id: string;
|
|
20
|
+
email: string;
|
|
21
|
+
};
|
|
22
|
+
export declare type IUserRoleDataCheck = {
|
|
23
|
+
isHasTeacherData: boolean;
|
|
24
|
+
isHasEduTeacherData: boolean;
|
|
25
|
+
isHasAssistantData: boolean;
|
|
26
|
+
isHasCounselorData: boolean;
|
|
27
|
+
isHasSecondaryTeacherData: boolean;
|
|
28
|
+
};
|
|
29
|
+
export declare const rolesSelect: string[];
|
|
30
|
+
export declare const ROLES: {
|
|
31
|
+
ADMIN: string;
|
|
32
|
+
TEACHER: string;
|
|
33
|
+
ASSISTANT: string;
|
|
34
|
+
EDUTEACHER: string;
|
|
35
|
+
STUDENT: string;
|
|
36
|
+
PARENT: string;
|
|
37
|
+
};
|
|
38
|
+
export declare const InitialData: {
|
|
39
|
+
firstName: string;
|
|
40
|
+
lastName: string;
|
|
41
|
+
dateOfBirth: string;
|
|
42
|
+
roles: never[];
|
|
43
|
+
email: string;
|
|
44
|
+
isActive: boolean;
|
|
45
|
+
};
|
|
46
|
+
export declare const statusCheck: {
|
|
47
|
+
value: boolean;
|
|
48
|
+
label: string;
|
|
49
|
+
}[];
|
|
50
|
+
export declare const gradeLevels: string[];
|
|
51
|
+
export declare const SPECIAL_ROLE: string[];
|
|
52
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as yup from "yup";
|
|
2
|
+
declare const schema: import("yup/lib/object").OptionalObjectSchema<{
|
|
3
|
+
firstName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
4
|
+
lastName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
5
|
+
email: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
6
|
+
roles: yup.ArraySchema<yup.StringSchema<string | undefined, Record<string, any>, string | undefined>, Record<string, any>, (string | undefined)[] | undefined, (string | undefined)[] | undefined>;
|
|
7
|
+
}, Record<string, any>, import("yup/lib/object").TypeOfShape<{
|
|
8
|
+
firstName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
9
|
+
lastName: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
10
|
+
email: import("yup/lib/string").RequiredStringSchema<string | undefined, Record<string, any>>;
|
|
11
|
+
roles: yup.ArraySchema<yup.StringSchema<string | undefined, Record<string, any>, string | undefined>, Record<string, any>, (string | undefined)[] | undefined, (string | undefined)[] | undefined>;
|
|
12
|
+
}>>;
|
|
13
|
+
export default schema;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { IOptions, IUserRoleDataCheck, TypeControl } from "../configs/constants";
|
|
3
|
+
declare type UserDetail = {
|
|
4
|
+
id?: string;
|
|
5
|
+
firstName: string;
|
|
6
|
+
lastName: string;
|
|
7
|
+
email?: string;
|
|
8
|
+
dateOfBirth?: string;
|
|
9
|
+
roles: string[];
|
|
10
|
+
isActive: boolean;
|
|
11
|
+
profileImageFileName: string;
|
|
12
|
+
teacherUserId: string[];
|
|
13
|
+
gradeLevel?: string;
|
|
14
|
+
currentGradeLevel?: string;
|
|
15
|
+
};
|
|
16
|
+
declare const useUserDetail: (id?: string | undefined) => {
|
|
17
|
+
userDetail: UserDetail;
|
|
18
|
+
backToList: (user?: string | undefined) => void;
|
|
19
|
+
confirmData: (data: any) => Promise<void>;
|
|
20
|
+
file: any;
|
|
21
|
+
setFile: import("react").Dispatch<any>;
|
|
22
|
+
edited: boolean;
|
|
23
|
+
currentRoles: string[];
|
|
24
|
+
setEdited: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
25
|
+
setEditedTrue: () => Promise<void>;
|
|
26
|
+
confirmChangePassword: (data: any) => Promise<void>;
|
|
27
|
+
forgotPasswordRequest: (data: any) => Promise<void>;
|
|
28
|
+
handleDisableRoles: (currentRoles: string) => boolean;
|
|
29
|
+
classFontSize: string;
|
|
30
|
+
teacherOptions: IOptions[];
|
|
31
|
+
handleToggleModel: () => void;
|
|
32
|
+
openModel: boolean;
|
|
33
|
+
user: any;
|
|
34
|
+
activeTab: TypeControl;
|
|
35
|
+
setActiveTab: import("react").Dispatch<import("react").SetStateAction<TypeControl>>;
|
|
36
|
+
imageSrc: any;
|
|
37
|
+
imageUse: string;
|
|
38
|
+
handleImageChange: (e: any) => void;
|
|
39
|
+
handleDeleteAvatar: () => Promise<void>;
|
|
40
|
+
getFile: () => void;
|
|
41
|
+
checkHasTeacher: boolean;
|
|
42
|
+
setCheckHasTeacher: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
43
|
+
userHasData: IUserRoleDataCheck;
|
|
44
|
+
};
|
|
45
|
+
export default useUserDetail;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import 'react-phone-number-input/style.css';
|
|
2
|
+
import { IUserRoleDataCheck } from '../configs/constants';
|
|
3
|
+
interface IProps {
|
|
4
|
+
userDetail: any;
|
|
5
|
+
confirmData: any;
|
|
6
|
+
teacherOptions: any;
|
|
7
|
+
id?: string;
|
|
8
|
+
goBack: any;
|
|
9
|
+
handleDisableRoles: (role: string) => boolean;
|
|
10
|
+
currentRoles: string[];
|
|
11
|
+
checkHasTeacher: boolean;
|
|
12
|
+
setCheckHasTeacher: (value: boolean) => void;
|
|
13
|
+
userHasData: IUserRoleDataCheck;
|
|
14
|
+
}
|
|
15
|
+
declare const Profile: ({ userDetail, confirmData, goBack, teacherOptions, id, checkHasTeacher, setCheckHasTeacher, userHasData, currentRoles }: IProps) => JSX.Element;
|
|
16
|
+
export default Profile;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export declare const getProfileTeacher: () => Promise<import("axios").AxiosResponse<any>>;
|
|
2
|
+
export declare const updateProfileTeacher: (data: any) => Promise<import("axios").AxiosResponse<any>>;
|
|
3
|
+
export declare const updateAvatarApi: (avatar: string) => Promise<import("axios").AxiosResponse<any>>;
|
|
4
|
+
export declare const systemProfileUpload: (formData: FormData) => Promise<import("axios").AxiosResponse<any>>;
|
|
5
|
+
export declare const changePasswordApi: (formData: any) => Promise<import("axios").AxiosResponse<any>>;
|
|
6
|
+
export declare const updateAvatarByAdminApi: (id: string, avatar: string) => Promise<import("axios").AxiosResponse<any>>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare const getById: (id: string) => Promise<import("axios").AxiosResponse<any>>;
|
|
2
|
+
export declare const getByIdUser: (id: string) => Promise<import("axios").AxiosResponse<any>>;
|
|
3
|
+
export declare const create: (data: any) => Promise<import("axios").AxiosResponse<any>>;
|
|
4
|
+
export declare const update: (data: any) => Promise<import("axios").AxiosResponse<any>>;
|
|
5
|
+
export declare const remove: (id: string) => Promise<import("axios").AxiosResponse<any>>;
|
|
6
|
+
export declare const changePassword: (formData: any) => Promise<import("axios").AxiosResponse<any>>;
|
|
7
|
+
export declare const forgotChangePassword: (data: any) => Promise<import("axios").AxiosResponse<any>>;
|
|
8
|
+
export declare const getTeachers: (filters: any) => Promise<import("axios").AxiosResponse<any>>;
|
|
9
|
+
export declare const userRoleHasDataApi: (userId: string) => Promise<import("axios").AxiosResponse<any>>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mario-education",
|
|
3
|
-
"version": "2.05.
|
|
3
|
+
"version": "2.05.14-release",
|
|
4
4
|
"description": "Contains education components && functions for BRSS Mario project",
|
|
5
5
|
"author": "brss",
|
|
6
6
|
"license": "MIT",
|
|
@@ -96,7 +96,7 @@
|
|
|
96
96
|
"grapesjs-preset-webpage": "^0.1.11",
|
|
97
97
|
"html2canvas": "^1.4.1",
|
|
98
98
|
"jspdf": "^2.5.1",
|
|
99
|
-
"mario-core": "2.10.
|
|
99
|
+
"mario-core": "2.10.12-release",
|
|
100
100
|
"papaparse": "^5.5.2",
|
|
101
101
|
"react-apexcharts": "^1.3.9",
|
|
102
102
|
"react-datepicker": "^3.8.0",
|