Skip to content

Commit

Permalink
Added navigation for the job status report
Browse files Browse the repository at this point in the history
  • Loading branch information
davewalker5 committed Oct 31, 2023
1 parent ec1701b commit da7d151
Show file tree
Hide file tree
Showing 7 changed files with 113 additions and 6 deletions.
4 changes: 2 additions & 2 deletions docker/ui/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM node:20-alpine
COPY musiccatalogue.ui-1.6.0.0 /opt/musiccatalogue.ui-1.6.0.0
WORKDIR /opt/musiccatalogue.ui-1.6.0.0
COPY musiccatalogue.ui-1.7.0.0 /opt/musiccatalogue.ui-1.7.0.0
WORKDIR /opt/musiccatalogue.ui-1.7.0.0
RUN npm install
RUN npm run build
ENTRYPOINT [ "npm", "start" ]
3 changes: 3 additions & 0 deletions src/music-catalogue-ui/components/componentPicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import AlbumList from "./albumList";
import TrackList from "./trackList";
import LookupAlbum from "./lookupAlbum";
import ExportCatalogue from "./exportCatalogue";
import JobStatusReport from "./jobStatusReport";

/**
* Component using the current page name to render the components required
Expand Down Expand Up @@ -36,6 +37,8 @@ const ComponentPicker = ({ context, navigate, logout }) => {
return <LookupAlbum navigate={navigate} logout={logout} />;
case pages.export:
return <ExportCatalogue navigate={navigate} logout={logout} />;
case pages.jobStatusReport:
return <JobStatusReport navigate={navigate} logout={logout} />;
default:
return <span />;
}
Expand Down
15 changes: 15 additions & 0 deletions src/music-catalogue-ui/components/jobStatusReport.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import { useCallback, useState } from "react";

const JobStatusReport = ({ navigate, logout }) => {
const [startDate, setStartDate] = useState(new Date());

return (
<>
<div className="row mb-2 pageTitle">
<h5 className="themeFontColor text-center">Job Status Report</h5>
</div>
</>
);
};

export default JobStatusReport;
4 changes: 3 additions & 1 deletion src/music-catalogue-ui/components/menuBar.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@ const MenuBar = ({ navigate, logout }) => {
</div>
</button>
<div className={styles.dropdownContent}>
<a href="#">Job Status</a>
<a onClick={() => navigate(pages.jobStatusReport, null, null)}>
Job Status
</a>
</div>
</div>
<a onClick={() => navigate(pages.export, null, null)}>Export</a>
Expand Down
1 change: 1 addition & 0 deletions src/music-catalogue-ui/helpers/navigation.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const pages = {
tracks: "Tracks",
lookup: "Lookup",
export: "Export",
jobStatusReport: "JobStatusReport",
};

export default pages;
91 changes: 88 additions & 3 deletions src/music-catalogue-ui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/music-catalogue-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"@fortawesome/react-fontawesome": "^0.2.0",
"next": "13.5.4",
"react": "^18",
"react-datepicker": "^4.21.0",
"react-dom": "^18"
},
"devDependencies": {
Expand Down

0 comments on commit da7d151

Please sign in to comment.