@itutoring/itutoring_application_js_api 1.11.0 → 1.11.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/.idea/iTutoring_Application_API-js.iml +11 -11
- package/.idea/modules.xml +7 -7
- package/.idea/vcs.xml +5 -5
- package/CookiesManager.js +47 -47
- package/LICENSE +21 -21
- package/README.md +6 -6
- package/apiController.js +436 -436
- package/cache.js +31 -31
- package/index.d.ts +116 -116
- package/index.js +114 -114
- package/modules/AiAssist.js +31 -31
- package/modules/Authentication.js +86 -86
- package/modules/Cart.js +83 -81
- package/modules/Checkout.js +60 -50
- package/modules/CustomerAuth.js +57 -57
- package/modules/CustomerLessonManager.js +29 -29
- package/modules/CustomerPortal.js +31 -31
- package/modules/FAQ.js +39 -39
- package/modules/GoogleReviews.js +36 -36
- package/modules/Inventory.js +51 -51
- package/modules/LectorDatabase.js +185 -185
- package/modules/LectorsCalendar.js +67 -67
- package/modules/LessonInventory.js +47 -47
- package/modules/MarketplaceController.js +86 -86
- package/modules/Models.js +380 -380
- package/modules/Payments.js +75 -75
- package/modules/Pricing.js +70 -70
- package/modules/ReservationSystem.js +48 -48
- package/modules/Reviews.js +53 -53
- package/modules/SubjectManager.js +139 -139
- package/modules/TableExplorer.js +246 -246
- package/modules/TeacherAuth.js +57 -57
- package/modules/TeacherProfileModule.js +299 -299
- package/modules/TeacherProfiles.js +60 -60
- package/modules/Version.js +24 -24
- package/modules/WebController.js +37 -37
- package/objects/AttendanceEvent.js +39 -39
- package/objects/AuthUser.js +24 -24
- package/objects/Course.js +38 -38
- package/objects/CourseReservation.js +22 -22
- package/objects/Customer.js +20 -20
- package/objects/Enums.js +62 -62
- package/objects/Event.js +125 -125
- package/objects/Reservation.js +42 -42
- package/objects/Subject.js +24 -24
- package/objects/Teacher.js +18 -18
- package/objects/TeacherProfile.js +17 -17
- package/objects/Webinar.js +25 -25
- package/objects/billingInfo.js +29 -29
- package/package.json +1 -1
- package/toolkit/Toolkit.jsx +51 -51
package/objects/Event.js
CHANGED
|
@@ -1,126 +1,126 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* @deprecated
|
|
11
|
-
*/
|
|
12
|
-
class iEvent
|
|
13
|
-
{
|
|
14
|
-
/**
|
|
15
|
-
* Event ID - cant be changed
|
|
16
|
-
*/
|
|
17
|
-
ID;
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* In case of videoconference this code can be used for authentication to connect, when you are not on the guest list.
|
|
21
|
-
*/
|
|
22
|
-
PassCode;
|
|
23
|
-
|
|
24
|
-
/**
|
|
25
|
-
* In case of video conference.
|
|
26
|
-
*
|
|
27
|
-
* - !Must be positive eger!
|
|
28
|
-
*/
|
|
29
|
-
RoomID = 0;
|
|
30
|
-
/**
|
|
31
|
-
* Email / Name of user who is responsible for this event
|
|
32
|
-
*
|
|
33
|
-
* Can be teacher in case of leesons when the event is generated automaticly
|
|
34
|
-
*/
|
|
35
|
-
Organizer;
|
|
36
|
-
|
|
37
|
-
/**
|
|
38
|
-
* Optional: of invited people (their emails).
|
|
39
|
-
*
|
|
40
|
-
* If someones not in this list, still can connect with PassCode.
|
|
41
|
-
*/
|
|
42
|
-
Guests;
|
|
43
|
-
|
|
44
|
-
/**
|
|
45
|
-
* Anyone can join
|
|
46
|
-
*/
|
|
47
|
-
Open;
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* If true organizer will have to manually allow the user when joining to be let in.
|
|
51
|
-
*/
|
|
52
|
-
RequestAccess;
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* 0 - Lesson; 1 - General meeting
|
|
56
|
-
*/
|
|
57
|
-
Type;
|
|
58
|
-
|
|
59
|
-
Name;
|
|
60
|
-
Description;
|
|
61
|
-
|
|
62
|
-
/**
|
|
63
|
-
* Optional: define which teached subject on this event.
|
|
64
|
-
*/
|
|
65
|
-
Subject;
|
|
66
|
-
|
|
67
|
-
OneTime;
|
|
68
|
-
/**
|
|
69
|
-
* Date and time when this event takes place.
|
|
70
|
-
*
|
|
71
|
-
* If is recursive, only time will be taken.
|
|
72
|
-
*/
|
|
73
|
-
DateAndTime;
|
|
74
|
-
/**
|
|
75
|
-
* Day in week this event takes place. In case of recursive events
|
|
76
|
-
*
|
|
77
|
-
* (starting with 1 up to 7)
|
|
78
|
-
*/
|
|
79
|
-
DayInWeekIndex;
|
|
80
|
-
|
|
81
|
-
/**
|
|
82
|
-
* How many times this event should repeat. If left -1 it will be forever ... forever young I wanna be....
|
|
83
|
-
*
|
|
84
|
-
* Just in case of recursive events
|
|
85
|
-
*/
|
|
86
|
-
Recursivity;
|
|
87
|
-
|
|
88
|
-
IsVideoConference;
|
|
89
|
-
|
|
90
|
-
ReadOnly;
|
|
91
|
-
|
|
92
|
-
State;
|
|
93
|
-
Place;
|
|
94
|
-
Class;
|
|
95
|
-
Students;
|
|
96
|
-
Item;
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
CreateFromJSON(json)
|
|
100
|
-
{
|
|
101
|
-
this.ID = json['ID'];
|
|
102
|
-
this.PassCode = json['PassCode'];
|
|
103
|
-
this.RoomID = json['RoomID'];
|
|
104
|
-
this.Organizer = json['Organizer'];
|
|
105
|
-
this.Guests = json['Guests'];
|
|
106
|
-
this.Open = json['Open'];
|
|
107
|
-
this.RequestAccess = json['RequestAccess'];
|
|
108
|
-
this.Type = json['Type'];
|
|
109
|
-
this.Name = json['Name'];
|
|
110
|
-
this.Description = json['Description'];
|
|
111
|
-
this.Subject = json['Subject'];
|
|
112
|
-
this.OneTime = json['OneTime'];
|
|
113
|
-
this.DateAndTime = json['DateAndTime'];
|
|
114
|
-
this.DayInWeekIndex = json['DayInWeekIndex'];
|
|
115
|
-
this.Recursivity = json['Recursivity'];
|
|
116
|
-
this.IsVideoConference = json['IsVideoConference'];
|
|
117
|
-
this.ReadOnly = json['ReadOnly'];
|
|
118
|
-
this.State = json['State'];
|
|
119
|
-
this.Class = json['Class'];
|
|
120
|
-
this.Place = json['Place'];
|
|
121
|
-
this.Students = json['Students'];
|
|
122
|
-
this.Item = json['Item'];
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated
|
|
11
|
+
*/
|
|
12
|
+
class iEvent
|
|
13
|
+
{
|
|
14
|
+
/**
|
|
15
|
+
* Event ID - cant be changed
|
|
16
|
+
*/
|
|
17
|
+
ID;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* In case of videoconference this code can be used for authentication to connect, when you are not on the guest list.
|
|
21
|
+
*/
|
|
22
|
+
PassCode;
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* In case of video conference.
|
|
26
|
+
*
|
|
27
|
+
* - !Must be positive eger!
|
|
28
|
+
*/
|
|
29
|
+
RoomID = 0;
|
|
30
|
+
/**
|
|
31
|
+
* Email / Name of user who is responsible for this event
|
|
32
|
+
*
|
|
33
|
+
* Can be teacher in case of leesons when the event is generated automaticly
|
|
34
|
+
*/
|
|
35
|
+
Organizer;
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Optional: of invited people (their emails).
|
|
39
|
+
*
|
|
40
|
+
* If someones not in this list, still can connect with PassCode.
|
|
41
|
+
*/
|
|
42
|
+
Guests;
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Anyone can join
|
|
46
|
+
*/
|
|
47
|
+
Open;
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* If true organizer will have to manually allow the user when joining to be let in.
|
|
51
|
+
*/
|
|
52
|
+
RequestAccess;
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* 0 - Lesson; 1 - General meeting
|
|
56
|
+
*/
|
|
57
|
+
Type;
|
|
58
|
+
|
|
59
|
+
Name;
|
|
60
|
+
Description;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Optional: define which teached subject on this event.
|
|
64
|
+
*/
|
|
65
|
+
Subject;
|
|
66
|
+
|
|
67
|
+
OneTime;
|
|
68
|
+
/**
|
|
69
|
+
* Date and time when this event takes place.
|
|
70
|
+
*
|
|
71
|
+
* If is recursive, only time will be taken.
|
|
72
|
+
*/
|
|
73
|
+
DateAndTime;
|
|
74
|
+
/**
|
|
75
|
+
* Day in week this event takes place. In case of recursive events
|
|
76
|
+
*
|
|
77
|
+
* (starting with 1 up to 7)
|
|
78
|
+
*/
|
|
79
|
+
DayInWeekIndex;
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* How many times this event should repeat. If left -1 it will be forever ... forever young I wanna be....
|
|
83
|
+
*
|
|
84
|
+
* Just in case of recursive events
|
|
85
|
+
*/
|
|
86
|
+
Recursivity;
|
|
87
|
+
|
|
88
|
+
IsVideoConference;
|
|
89
|
+
|
|
90
|
+
ReadOnly;
|
|
91
|
+
|
|
92
|
+
State;
|
|
93
|
+
Place;
|
|
94
|
+
Class;
|
|
95
|
+
Students;
|
|
96
|
+
Item;
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
CreateFromJSON(json)
|
|
100
|
+
{
|
|
101
|
+
this.ID = json['ID'];
|
|
102
|
+
this.PassCode = json['PassCode'];
|
|
103
|
+
this.RoomID = json['RoomID'];
|
|
104
|
+
this.Organizer = json['Organizer'];
|
|
105
|
+
this.Guests = json['Guests'];
|
|
106
|
+
this.Open = json['Open'];
|
|
107
|
+
this.RequestAccess = json['RequestAccess'];
|
|
108
|
+
this.Type = json['Type'];
|
|
109
|
+
this.Name = json['Name'];
|
|
110
|
+
this.Description = json['Description'];
|
|
111
|
+
this.Subject = json['Subject'];
|
|
112
|
+
this.OneTime = json['OneTime'];
|
|
113
|
+
this.DateAndTime = json['DateAndTime'];
|
|
114
|
+
this.DayInWeekIndex = json['DayInWeekIndex'];
|
|
115
|
+
this.Recursivity = json['Recursivity'];
|
|
116
|
+
this.IsVideoConference = json['IsVideoConference'];
|
|
117
|
+
this.ReadOnly = json['ReadOnly'];
|
|
118
|
+
this.State = json['State'];
|
|
119
|
+
this.Class = json['Class'];
|
|
120
|
+
this.Place = json['Place'];
|
|
121
|
+
this.Students = json['Students'];
|
|
122
|
+
this.Item = json['Item'];
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
126
|
export default iEvent;
|
package/objects/Reservation.js
CHANGED
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* @deprecated do not use
|
|
12
|
-
|
|
13
|
-
*/
|
|
14
|
-
class Reservation
|
|
15
|
-
{
|
|
16
|
-
Date;
|
|
17
|
-
StartTime;
|
|
18
|
-
Subject;
|
|
19
|
-
TeacherId;
|
|
20
|
-
Note;
|
|
21
|
-
FirstName;
|
|
22
|
-
LastName;
|
|
23
|
-
Email;
|
|
24
|
-
ID;
|
|
25
|
-
Phone;
|
|
26
|
-
|
|
27
|
-
IsValid()
|
|
28
|
-
{
|
|
29
|
-
if (this.Date == null ||
|
|
30
|
-
this.StartTime == null ||
|
|
31
|
-
this.Subject == null ||
|
|
32
|
-
this.Note == null ||
|
|
33
|
-
this.FirstName == null ||
|
|
34
|
-
this.LastName == null ||
|
|
35
|
-
this.Phone == null ||
|
|
36
|
-
this.Email == null)
|
|
37
|
-
return false;
|
|
38
|
-
|
|
39
|
-
return true;
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* @deprecated do not use
|
|
12
|
+
|
|
13
|
+
*/
|
|
14
|
+
class Reservation
|
|
15
|
+
{
|
|
16
|
+
Date;
|
|
17
|
+
StartTime;
|
|
18
|
+
Subject;
|
|
19
|
+
TeacherId;
|
|
20
|
+
Note;
|
|
21
|
+
FirstName;
|
|
22
|
+
LastName;
|
|
23
|
+
Email;
|
|
24
|
+
ID;
|
|
25
|
+
Phone;
|
|
26
|
+
|
|
27
|
+
IsValid()
|
|
28
|
+
{
|
|
29
|
+
if (this.Date == null ||
|
|
30
|
+
this.StartTime == null ||
|
|
31
|
+
this.Subject == null ||
|
|
32
|
+
this.Note == null ||
|
|
33
|
+
this.FirstName == null ||
|
|
34
|
+
this.LastName == null ||
|
|
35
|
+
this.Phone == null ||
|
|
36
|
+
this.Email == null)
|
|
37
|
+
return false;
|
|
38
|
+
|
|
39
|
+
return true;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
43
|
export default Reservation;
|
package/objects/Subject.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
class Subject
|
|
11
|
-
{
|
|
12
|
-
Name;
|
|
13
|
-
NameRaw;
|
|
14
|
-
Level;
|
|
15
|
-
Description;
|
|
16
|
-
Price;
|
|
17
|
-
PriceBeforeSale = -1;
|
|
18
|
-
IsSaled = false;
|
|
19
|
-
CreditPrice;
|
|
20
|
-
IconPath;
|
|
21
|
-
ID;
|
|
22
|
-
Item;
|
|
23
|
-
}
|
|
24
|
-
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class Subject
|
|
11
|
+
{
|
|
12
|
+
Name;
|
|
13
|
+
NameRaw;
|
|
14
|
+
Level;
|
|
15
|
+
Description;
|
|
16
|
+
Price;
|
|
17
|
+
PriceBeforeSale = -1;
|
|
18
|
+
IsSaled = false;
|
|
19
|
+
CreditPrice;
|
|
20
|
+
IconPath;
|
|
21
|
+
ID;
|
|
22
|
+
Item;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
25
|
export default Subject
|
package/objects/Teacher.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
class Teacher
|
|
11
|
-
{
|
|
12
|
-
Name;
|
|
13
|
-
Email;
|
|
14
|
-
ZoomMeeting;
|
|
15
|
-
ID;
|
|
16
|
-
TeachedLessons;
|
|
17
|
-
}
|
|
18
|
-
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class Teacher
|
|
11
|
+
{
|
|
12
|
+
Name;
|
|
13
|
+
Email;
|
|
14
|
+
ZoomMeeting;
|
|
15
|
+
ID;
|
|
16
|
+
TeachedLessons;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
19
|
export default Teacher;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
class TeacherProfile
|
|
11
|
-
{
|
|
12
|
-
Name;
|
|
13
|
-
Bio;
|
|
14
|
-
PhotoPath;
|
|
15
|
-
Subjects;
|
|
16
|
-
}
|
|
17
|
-
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class TeacherProfile
|
|
11
|
+
{
|
|
12
|
+
Name;
|
|
13
|
+
Bio;
|
|
14
|
+
PhotoPath;
|
|
15
|
+
Subjects;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
18
|
export default TeacherProfile;
|
package/objects/Webinar.js
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
class Webinar
|
|
11
|
-
{
|
|
12
|
-
Name;
|
|
13
|
-
Description;
|
|
14
|
-
Program;
|
|
15
|
-
Date;
|
|
16
|
-
StartTime;
|
|
17
|
-
EndTime;
|
|
18
|
-
TeacherId;
|
|
19
|
-
TeacherRole;
|
|
20
|
-
Price;
|
|
21
|
-
ID;
|
|
22
|
-
TeacherPhotoURL;
|
|
23
|
-
TeacherName;
|
|
24
|
-
}
|
|
25
|
-
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class Webinar
|
|
11
|
+
{
|
|
12
|
+
Name;
|
|
13
|
+
Description;
|
|
14
|
+
Program;
|
|
15
|
+
Date;
|
|
16
|
+
StartTime;
|
|
17
|
+
EndTime;
|
|
18
|
+
TeacherId;
|
|
19
|
+
TeacherRole;
|
|
20
|
+
Price;
|
|
21
|
+
ID;
|
|
22
|
+
TeacherPhotoURL;
|
|
23
|
+
TeacherName;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
26
|
export default Webinar;
|
package/objects/billingInfo.js
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
-
* All rights reserved.
|
|
4
|
-
*
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* BillingInfo API model representation.
|
|
12
|
-
* See documentation: https://zabesstudio.atlassian.net/wiki/spaces/ITUTAPP/pages/70549505/BillingInfo
|
|
13
|
-
*/
|
|
14
|
-
class BillingInfo
|
|
15
|
-
{
|
|
16
|
-
FirstName = "";
|
|
17
|
-
LastName = "";
|
|
18
|
-
StudentName = "";
|
|
19
|
-
Email = "";
|
|
20
|
-
Phone = "";
|
|
21
|
-
Address = "";
|
|
22
|
-
City = "";
|
|
23
|
-
Zip = "";
|
|
24
|
-
/**
|
|
25
|
-
* @var {int} Country
|
|
26
|
-
*/
|
|
27
|
-
Country = 2;
|
|
28
|
-
}
|
|
29
|
-
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024 iTutoring s.r.o.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* BillingInfo API model representation.
|
|
12
|
+
* See documentation: https://zabesstudio.atlassian.net/wiki/spaces/ITUTAPP/pages/70549505/BillingInfo
|
|
13
|
+
*/
|
|
14
|
+
class BillingInfo
|
|
15
|
+
{
|
|
16
|
+
FirstName = "";
|
|
17
|
+
LastName = "";
|
|
18
|
+
StudentName = "";
|
|
19
|
+
Email = "";
|
|
20
|
+
Phone = "";
|
|
21
|
+
Address = "";
|
|
22
|
+
City = "";
|
|
23
|
+
Zip = "";
|
|
24
|
+
/**
|
|
25
|
+
* @var {int} Country
|
|
26
|
+
*/
|
|
27
|
+
Country = 2;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
30
|
export default BillingInfo;
|
package/package.json
CHANGED
package/toolkit/Toolkit.jsx
CHANGED
|
@@ -1,52 +1,52 @@
|
|
|
1
|
-
import APIController from "../apiController";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
class Toolkit
|
|
5
|
-
{
|
|
6
|
-
static ModuleInfo = null;
|
|
7
|
-
static UserDataLoaded = false;
|
|
8
|
-
static AuthDone = false;
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Main function to initialize any toolkit module.
|
|
12
|
-
* It will handle all important authorizations
|
|
13
|
-
*/
|
|
14
|
-
static async Initialize(moduleUid)
|
|
15
|
-
{
|
|
16
|
-
this.ModuleInfo = await this.GetModuleProperties(moduleUid);
|
|
17
|
-
|
|
18
|
-
await this.RequestAccess(moduleUid);
|
|
19
|
-
|
|
20
|
-
this.AuthDone = true;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
/***** API Methods ******/
|
|
24
|
-
|
|
25
|
-
static #MODULE = "Toolkit";
|
|
26
|
-
|
|
27
|
-
static #REQUEST_ACCESS = "RequestAccess";
|
|
28
|
-
static #GET_MODULE_INFO = "GetModuleInfo";
|
|
29
|
-
|
|
30
|
-
static async RequestAccess(moduleUid)
|
|
31
|
-
{
|
|
32
|
-
var data = await APIController.Post(this.#MODULE, this.#REQUEST_ACCESS, {
|
|
33
|
-
'uid': moduleUid
|
|
34
|
-
});
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
/**
|
|
38
|
-
* Will be returned as array (parsed JSON).
|
|
39
|
-
* @param {*} moduleUid
|
|
40
|
-
* @returns
|
|
41
|
-
*/
|
|
42
|
-
static async GetModuleProperties(moduleUid)
|
|
43
|
-
{
|
|
44
|
-
var info = await APIController.Get(this.#MODULE, this.#GET_MODULE_INFO, {
|
|
45
|
-
'uid': moduleUid
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
return JSON.parse(info);
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
|
|
1
|
+
import APIController from "../apiController";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class Toolkit
|
|
5
|
+
{
|
|
6
|
+
static ModuleInfo = null;
|
|
7
|
+
static UserDataLoaded = false;
|
|
8
|
+
static AuthDone = false;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Main function to initialize any toolkit module.
|
|
12
|
+
* It will handle all important authorizations
|
|
13
|
+
*/
|
|
14
|
+
static async Initialize(moduleUid)
|
|
15
|
+
{
|
|
16
|
+
this.ModuleInfo = await this.GetModuleProperties(moduleUid);
|
|
17
|
+
|
|
18
|
+
await this.RequestAccess(moduleUid);
|
|
19
|
+
|
|
20
|
+
this.AuthDone = true;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/***** API Methods ******/
|
|
24
|
+
|
|
25
|
+
static #MODULE = "Toolkit";
|
|
26
|
+
|
|
27
|
+
static #REQUEST_ACCESS = "RequestAccess";
|
|
28
|
+
static #GET_MODULE_INFO = "GetModuleInfo";
|
|
29
|
+
|
|
30
|
+
static async RequestAccess(moduleUid)
|
|
31
|
+
{
|
|
32
|
+
var data = await APIController.Post(this.#MODULE, this.#REQUEST_ACCESS, {
|
|
33
|
+
'uid': moduleUid
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Will be returned as array (parsed JSON).
|
|
39
|
+
* @param {*} moduleUid
|
|
40
|
+
* @returns
|
|
41
|
+
*/
|
|
42
|
+
static async GetModuleProperties(moduleUid)
|
|
43
|
+
{
|
|
44
|
+
var info = await APIController.Get(this.#MODULE, this.#GET_MODULE_INFO, {
|
|
45
|
+
'uid': moduleUid
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
return JSON.parse(info);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
52
|
export default Toolkit;
|