mirror of
https://github.com/rzmk/learnhouse.git
synced 2025-12-18 20:09:25 +00:00
fix: fix bugs
This commit is contained in:
parent
02a5ed6354
commit
e47a9939b5
3 changed files with 4 additions and 3 deletions
|
|
@ -26,7 +26,8 @@ function LecturePage(params: any) {
|
|||
|
||||
async function markLectureAsCompleteFront() {
|
||||
const activity = await maskLectureAsComplete("" + lectureid, courseid, lecture.lecture_id.replace("lecture_", ""));
|
||||
mutate(`${getAPIUrl()}courses/meta/${courseid}`);
|
||||
mutate(`${getAPIUrl()}lectures/lecture_${lectureid}`);
|
||||
mutate(`${getAPIUrl()}courses/meta/course_${courseid}`);
|
||||
}
|
||||
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ export const Menu = (params : any) => {
|
|||
<LogoArea>
|
||||
<Logo>
|
||||
<Image width={25} height={25} src={learnhouseIcon} alt="" />
|
||||
<Link href={"/"}>
|
||||
<Link href={getUriWithOrg(orgslug, "/")}>
|
||||
<Image width={108} height={28} src={learnhouseLogo} alt="" />
|
||||
</Link>
|
||||
</Logo>
|
||||
|
|
|
|||
|
|
@ -10,6 +10,6 @@ export const getUriWithOrg = ( orgslug: string, path: string) => {
|
|||
};
|
||||
|
||||
export const getOrgFromUri = (uri: any) => {
|
||||
let org = uri.match(/\/org\/(.*?)\//)[1];
|
||||
let org = uri.match(/\/org\/([\w]+)/)[1];
|
||||
return org;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue