diff options
Diffstat (limited to 'src/components/mao-tutoring.js')
| -rw-r--r-- | src/components/mao-tutoring.js | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/components/mao-tutoring.js b/src/components/mao-tutoring.js index 5ab3c97..19d844a 100644 --- a/src/components/mao-tutoring.js +++ b/src/components/mao-tutoring.js @@ -144,13 +144,13 @@ class MaoTutoring extends connect(store)(PageViewElement) { </style> <section> - <div class="tutoring-grid" id="tutoring-grid" hidden="${props.signedIn}"> + <div class="tutoring-grid" id="tutoring-grid"> <div class="title"> <h2 class="underline">Tutoring</h2> </div> - <div class="tutorCard"> + <div class="tutorCard" hidden="${props.signedIn}"> <h3>Need to see or document hours?</h3> <paper-button class="info" @@ -304,12 +304,15 @@ class MaoTutoring extends connect(store)(PageViewElement) { } requestHours() { - const timeHours = (this.shadowRoot.getElementById('timeField') .value) - /60; - const traineeName = this.shadowRoot.getElementById('traineeField').value; - const date = this.shadowRoot.getElementById('dateField') .value; - store.dispatch(requestHours(timeHours, traineeName, date)); + if(confirm('Are you sure that you want to send this request for hours?')) { + const timeHours = (this.shadowRoot.getElementById('timeField') .value) + /60; + const traineeName = this.shadowRoot.getElementById('traineeField').value; + const date = this.shadowRoot.getElementById('dateField') .value; + + store.dispatch(requestHours(timeHours, traineeName, date)); + } } } |
