Skip to content

Commit

Permalink
Merge pull request #8 from Pearson-Advance/vue/PADV-694
Browse files Browse the repository at this point in the history
PADV-694 - Fix error related to the path
  • Loading branch information
sergivalero20 authored Sep 14, 2023
2 parents 7d51455 + 2f244e7 commit 2600904
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 4 deletions.
1 change: 1 addition & 0 deletions .env
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,4 @@ USER_INFO_COOKIE_NAME=''
APP_ID=''
MFE_CONFIG_API_URL=''
ACCOUNT_PROFILE_URL=''
INSTITUTION_PORTAL_PATH=''
1 change: 1 addition & 0 deletions .env.development
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ USER_INFO_COOKIE_NAME='edx-user-info'
APP_ID=''
ACCOUNT_PROFILE_URL='http://localhost:1995/u'
MFE_CONFIG_API_URL='http://localhost:18000/api/mfe_config/v1'
INSTITUTION_PORTAL_PATH=''
1 change: 1 addition & 0 deletions .env.test
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ USER_INFO_COOKIE_NAME='edx-user-info'
APP_ID=''
MFE_CONFIG_API_URL=''
ACCOUNT_PROFILE_URL='http://localhost:1995/u'
INSTITUTION_PORTAL_PATH='/institution-portal'
2 changes: 1 addition & 1 deletion src/features/Main/Sidebar/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const Sidebar = () => {
return (
<header className="vertical-nav">
<div className="logo">
<a href={`${config.BASE_URL}`}>
<a href={`${config.LMS_BASE_URL}`}>
<img src={`${getConfig().LOGO_URL}`} alt="icon" />
</a>
</div>
Expand Down
3 changes: 2 additions & 1 deletion src/features/Main/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ import { Sidebar } from 'features/Main/Sidebar';
import { Header } from 'features/Main/Header';
import { Footer } from 'features/Main/Footer';
import StudentsPage from 'features/Students/StudentsPage';
import { getConfig } from '@edx/frontend-platform';
import './index.scss';

const Main = () => (
<BrowserRouter>
<BrowserRouter basename={getConfig().INSTITUTION_PORTAL_PATH}>
<div className="pageWrapper">
<Sidebar />
<main>
Expand Down
3 changes: 1 addition & 2 deletions src/features/Students/StudentsPage/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ const initialState = {
data: [],
status: RequestStatus.SUCCESS,
error: null,
itemsPerPage: 10,
currentPage: 1,
numPages: 0,
filters: {
Expand All @@ -46,7 +45,7 @@ const reducer = (state, action) => {
return { ...state, status: RequestStatus.LOADING };
case 'FETCH_SUCCESS': {
const { results, count } = action.payload;
const numPages = Math.ceil(count / state.itemsPerPage);
const numPages = count;
return {
...state,
status: RequestStatus.SUCCESS,
Expand Down

0 comments on commit 2600904

Please sign in to comment.