Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
2
2023-029
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
2023-029
2023-029
Commits
007a3ac8
Commit
007a3ac8
authored
Sep 04, 2023
by
janithgamage1.ed
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: update
desc : update project
parent
8ee0496c
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
5 additions
and
53 deletions
+5
-53
Project/Frontend/SignConnectPlus/src/contexts/JWTContext.tsx
Project/Frontend/SignConnectPlus/src/contexts/JWTContext.tsx
+0
-2
Project/Frontend/SignConnectPlus/src/pages/home/dashboard.tsx
...ect/Frontend/SignConnectPlus/src/pages/home/dashboard.tsx
+1
-38
Project/Frontend/SignConnectPlus/src/pages/learning-management/learning-curriculums-subscribed/tutorial/tutorial.tsx
...ent/learning-curriculums-subscribed/tutorial/tutorial.tsx
+1
-5
Project/Frontend/SignConnectPlus/src/pages/parameter/tutorial-management/list/list.tsx
...lus/src/pages/parameter/tutorial-management/list/list.tsx
+1
-3
Project/Frontend/SignConnectPlus/src/sections/parameters/curriculum-management/AddEditCurriculum.tsx
...ns/parameters/curriculum-management/AddEditCurriculum.tsx
+1
-2
Project/Frontend/SignConnectPlus/src/store/reducers/userProgress.ts
...ontend/SignConnectPlus/src/store/reducers/userProgress.ts
+1
-3
No files found.
Project/Frontend/SignConnectPlus/src/contexts/JWTContext.tsx
View file @
007a3ac8
...
...
@@ -67,8 +67,6 @@ export const JWTProvider = ({ children }: { children: React.ReactElement }) => {
const
response
=
await
axiosServices
.
get
(
'
/rest_node/user/current-user
'
);
const
{
user
}
=
response
.
data
;
console
.
log
(
user
);
dispatch
({
type
:
LOGIN
,
payload
:
{
...
...
Project/Frontend/SignConnectPlus/src/pages/home/dashboard.tsx
View file @
007a3ac8
// material-ui
import
useAuth
from
"
hooks/useAuth
"
;
import
{
useEffect
}
from
"
react
"
;
// project import
// ==============================|| Dashboard ||============================== //
const
Dashboard
=
()
=>
{
const
{
user
}
=
useAuth
()
// const serviceToken = window.localStorage.getItem('serviceToken');
// useEffect(() => {
// const fetchData = async () => {
// try {
// // Set the token in your Axios instance for future requests
// axiosServices.defaults.headers.common['Authorization'] = `Bearer ${serviceToken}`;
// // Make the API request
// const response = await axiosServices.get('/rest_node/user/current-user');
// const { user } = response.data;
// console.log(user);
// console.log(response);
// // Handle the user data or dispatch it to your state here
// } catch (error) {
// // Handle errors here (e.g., token expiration, network issues)
// console.error('Error fetching user data:', error);
// // You can dispatch a logout action or handle the error accordingly
// }
// };
// fetchData();
// }, [])
useEffect
(()
=>
{
console
.
log
(
user
?.
id
);
},
[
user
])
const
Dashboard
=
()
=>
{
return
(
<>
...
...
Project/Frontend/SignConnectPlus/src/pages/learning-management/learning-curriculums-subscribed/tutorial/tutorial.tsx
View file @
007a3ac8
...
...
@@ -205,8 +205,6 @@ const Tutorial = () => {
const
file
=
new
File
([
blob
],
'
image.jpg
'
,
{
type
:
'
image/jpeg
'
});
console
.
log
(
file
);
dispatch
(
CalculateMarks
(
curriculumIndex
,
tutorialIndex
,
file
,
targetClass
));
}
else
{
dispatch
(
...
...
@@ -222,9 +220,7 @@ const Tutorial = () => {
})
);
}
}
else
if
(
itemPracticeReferenceData
==
"
upload
"
)
{
console
.
log
(
uploadImage
);
}
else
if
(
itemPracticeReferenceData
==
"
upload
"
)
{
const
curriculumIndex
:
number
=
1
;
const
tutorialIndex
:
number
=
1
;
const
imageData
:
any
=
uploadImage
[
0
];
// Your image data
...
...
Project/Frontend/SignConnectPlus/src/pages/parameter/tutorial-management/list/list.tsx
View file @
007a3ac8
...
...
@@ -421,9 +421,7 @@ const List = () => {
dispatch
(
fetchTutorials
());
},
[
dispatch
]);
useEffect
(()
=>
{
console
.
log
(
tutorials
);
useEffect
(()
=>
{
setData
(
tutorials
);
},
[
tutorials
])
...
...
Project/Frontend/SignConnectPlus/src/sections/parameters/curriculum-management/AddEditCurriculum.tsx
View file @
007a3ac8
...
...
@@ -89,8 +89,7 @@ const AddEditCurriculum = ({ curriculum, onCancel }: Props) => {
initialValues
:
getInitialValues
(
curriculum
!
),
validationSchema
:
CurriculumSchema
,
enableReinitialize
:
true
,
onSubmit
:
(
values
,
{
setSubmitting
,
resetForm
})
=>
{
console
.
log
(
values
);
onSubmit
:
(
values
,
{
setSubmitting
,
resetForm
})
=>
{
try
{
if
(
curriculum
)
{
...
...
Project/Frontend/SignConnectPlus/src/store/reducers/userProgress.ts
View file @
007a3ac8
...
...
@@ -30,9 +30,7 @@ const slice = createSlice({
},
// HAS ERROR
hasError
(
state
,
action
)
{
console
.
log
(
action
.
payload
);
hasError
(
state
,
action
)
{
state
.
error
=
action
.
payload
;
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment