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
8ee0496c
Commit
8ee0496c
authored
Sep 04, 2023
by
janithgamage1.ed
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: update
Desc : update project
parent
2d1af9bb
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
23 additions
and
10 deletions
+23
-10
Project/Frontend/SignConnectPlus/src/menu-items/application.tsx
...t/Frontend/SignConnectPlus/src/menu-items/application.tsx
+1
-1
Project/Frontend/SignConnectPlus/src/pages/learning-management/learning-curriculums-subscribed/list/list.tsx
...-management/learning-curriculums-subscribed/list/list.tsx
+1
-1
Project/Frontend/SignConnectPlus/src/pages/learning-management/learning-curriculums-subscribed/tutorial/tutorial.tsx
...ent/learning-curriculums-subscribed/tutorial/tutorial.tsx
+6
-3
Project/Frontend/SignConnectPlus/src/routes/MainRoutes.tsx
Project/Frontend/SignConnectPlus/src/routes/MainRoutes.tsx
+11
-1
Project/Frontend/SignConnectPlus/src/sections/learning-management/learning-curriculums-subscribed/CurriculumSection.tsx
...ent/learning-curriculums-subscribed/CurriculumSection.tsx
+2
-2
Project/Frontend/SignConnectPlus/src/sections/learning-management/learning-curriculums-subscribed/TutorialSection.tsx
...ement/learning-curriculums-subscribed/TutorialSection.tsx
+2
-2
No files found.
Project/Frontend/SignConnectPlus/src/menu-items/application.tsx
View file @
8ee0496c
...
...
@@ -157,7 +157,7 @@ const application: NavItemType = {
id
:
'
learning-curriculums-subscribed-tutorial
'
,
title
:
<
FormattedMessage
id=
"learning-curriculums-subscribed-tutorial"
/>,
type
:
'
item
'
,
url
:
'
/learning-management/curriculums-subscribed-tutorial
'
,
url
:
'
/learning-management/curriculums-subscribed-tutorial
/0/0
'
,
},
{
id
:
'
learning-lead-board
'
,
...
...
Project/Frontend/SignConnectPlus/src/pages/learning-management/learning-curriculums-subscribed/list/list.tsx
View file @
8ee0496c
...
...
@@ -261,7 +261,7 @@ const List = () => {
</
Stack
>
</
AccordionSummary
>
<
AccordionDetails
>
<
CurriculumSection
curriculum=
{
curriculum
}
/>
<
CurriculumSection
curriculum=
{
curriculum
}
curriculumIndex=
{
index
}
/>
</
AccordionDetails
>
</
Accordion
>
</
Box
>
...
...
Project/Frontend/SignConnectPlus/src/pages/learning-management/learning-curriculums-subscribed/tutorial/tutorial.tsx
View file @
8ee0496c
...
...
@@ -19,6 +19,7 @@ import ReportCard from "components/cards/statistics/ReportCard";
import
{
itemResultProps
,
selectedCommonDataProps
,
selectedItemContentProps
}
from
"
./types/types
"
;
import
CircularWithPath
from
"
components/@extended/progress/CircularWithPath
"
;
import
{
useParams
}
from
"
react-router
"
;
import
Webcam
from
'
react-webcam
'
;
import
{
useDispatch
,
useSelector
}
from
"
store
"
;
import
{
CalculateMarks
,
toInitialState
}
from
"
store/reducers/marksCalculator
"
;
...
...
@@ -49,6 +50,7 @@ const Tutorial = () => {
const
dispatch
=
useDispatch
();
const
{
marksCalculator
,
error
,
success
,
isLoading
}
=
useSelector
(
state
=>
state
.
marksCalculator
);
const
{
userProgress
}
=
useSelector
(
state
=>
state
.
userProgress
);
const
{
curriculumIndex
,
tutorialIndex
}
=
useParams
();
const
[
data
,
setData
]
=
useState
<
tutorialTypeUserProgress
>
()
const
[
selectedItem
,
setSelectedItem
]
=
useState
<
{
selectedCommonData
:
selectedCommonDataProps
|
null
,
backgroundColor
:
any
|
null
}
>
({
...
...
@@ -70,10 +72,11 @@ const Tutorial = () => {
})
useEffect
(()
=>
{
if
(
!
curriculumIndex
||
!
tutorialIndex
)
return
if
(
userProgress
)
{
const
firstTutorial
=
userProgress
?.
curriculums
?.[
0
]?.
tutorials
?.[
0
];
if
(
first
Tutorial
)
{
setData
(
first
Tutorial
);
const
selectedTutorial
=
userProgress
?.
curriculums
?.[
parseInt
(
curriculumIndex
)]?.
tutorials
?.[
parseInt
(
tutorialIndex
)
];
if
(
selected
Tutorial
)
{
setData
(
selected
Tutorial
);
}
}
},
[
userProgress
]);
...
...
Project/Frontend/SignConnectPlus/src/routes/MainRoutes.tsx
View file @
8ee0496c
...
...
@@ -148,7 +148,17 @@ const MainRoutes = {
},
{
path
:
'
curriculums-subscribed-tutorial
'
,
element
:
<
LearningCurriculumsSubscribedTutorial
/>
children
:
[
{
path
:
'
:curriculumIndex
'
,
// Parameter for curriculum index
children
:
[
{
path
:
'
:tutorialIndex
'
,
// Parameter for tutorial index
element
:
<
LearningCurriculumsSubscribedTutorial
/>
}
]
}
]
},
{
path
:
'
lead-board
'
,
...
...
Project/Frontend/SignConnectPlus/src/sections/learning-management/learning-curriculums-subscribed/CurriculumSection.tsx
View file @
8ee0496c
...
...
@@ -25,7 +25,7 @@ import ReportCard from 'components/cards/statistics/ReportCard';
// ==============================|| Curriculum - Section ||============================== //
const
CurriculumSection
=
({
curriculum
}:
{
curriculum
:
curriculumTypeUserProgress
})
=>
{
const
CurriculumSection
=
({
curriculum
,
curriculumIndex
}:
{
curriculum
:
curriculumTypeUserProgress
,
curriculumIndex
:
number
})
=>
{
const
theme
=
useTheme
();
return
(
...
...
@@ -85,7 +85,7 @@ const CurriculumSection = ({ curriculum }: { curriculum: curriculumTypeUserProgr
<
MainCard
title=
"Tutorials"
>
<
Grid
container
spacing=
{
2
}
>
{
curriculum
.
tutorials
&&
curriculum
.
tutorials
?.
map
((
tutorial
,
index
)
=>
{
return
(<
TutorialSection
tutorial=
{
tutorial
!
}
/>)
return
(<
TutorialSection
tutorial=
{
tutorial
!
}
curriculumIndex=
{
curriculumIndex
}
tutorialIndex=
{
index
}
/>)
})
}
</
Grid
>
</
MainCard
>
...
...
Project/Frontend/SignConnectPlus/src/sections/learning-management/learning-curriculums-subscribed/TutorialSection.tsx
View file @
8ee0496c
...
...
@@ -25,7 +25,7 @@ import MainCard from 'components/MainCard';
// ==============================|| Tutorial - Section ||============================== //
const
TutorialSection
=
({
tutorial
}:
{
tutorial
:
tutorialTypeUserProgress
})
=>
{
const
TutorialSection
=
({
tutorial
,
tutorialIndex
,
curriculumIndex
}:
{
tutorial
:
tutorialTypeUserProgress
,
curriculumIndex
:
number
,
tutorialIndex
:
number
})
=>
{
let
navigation
=
useNavigate
()
const
[
desc
,
setDesc
]
=
useState
(
tutorial
.
tutorialDescription
?.
slice
(
0
,
100
))
...
...
@@ -70,7 +70,7 @@ const TutorialSection = ({ tutorial }: { tutorial: tutorialTypeUserProgress }) =
variant=
"outlined"
endIcon=
{
<
PlaySquareOutlined
/>
}
sx=
{
{
my
:
2
}
}
onClick=
{
()
=>
{
navigation
(
`/learning-management/curriculums-subscribed-tutorial`
)
}
}
onClick=
{
()
=>
{
navigation
(
`/learning-management/curriculums-subscribed-tutorial
/${curriculumIndex}/${tutorialIndex}
`
)
}
}
>
Start Tutorial
</
Button
>
...
...
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