Skip to content

Commit

Permalink
fix welcome page bug
Browse files Browse the repository at this point in the history
  • Loading branch information
katrina-cityofdetroit committed Jul 29, 2024
1 parent f166347 commit 4aea29c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/js/views/00_welcome.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ export class WelcomeView extends View {
Welcome.show();

// initialize links in buttons
document.getElementById('step-upload').addEventListener('click', visitPage('upload'));
document.getElementById('step-initiatives').addEventListener('click', visitPage('new-inits'))
document.getElementById('step-revenue').addEventListener('click', visitPage('revenue'))
document.getElementById('step-finish').addEventListener('click', visitPage('summary'))
document.getElementById('step-upload').addEventListener('click', () => visitPage('upload'));
document.getElementById('step-initiatives').addEventListener('click', () => visitPage('new-inits'));
document.getElementById('step-revenue').addEventListener('click', () => visitPage('revenue'));
document.getElementById('step-finish').addEventListener('click', () => visitPage('summary'));

}

Expand Down
6 changes: 5 additions & 1 deletion src/js/views/08_summary.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { formatCurrency } from '../utils/common_utils.js';
import { View } from "./view_class.js";
import Prompt from "../components/prompt/prompt.js";
import { downloadXLSX } from "../utils/XLSX_handlers.js";
import WelcomeView from './00_welcome.js';

export function compareToTarget(){
const baseline = new Baseline;
Expand All @@ -22,7 +23,10 @@ export function compareToTarget(){
Prompt.show();
}

const returnToWelcome = () => {visitPage('welcome')};
function returnToWelcome() {
const welcome = new WelcomeView();
welcome.visit();
};

export class SummaryView extends View {

Expand Down

0 comments on commit 4aea29c

Please sign in to comment.