Skip to content

Commit 32f9474

Browse files
Add unknown school/home schooled offline session to exports list
1 parent 4aa1a73 commit 32f9474

3 files changed

Lines changed: 15 additions & 2 deletions

File tree

app/locales/en.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1950,7 +1950,7 @@ export const en = {
19501950
title: 'Record offline',
19511951
description:
19521952
'If the internet connection at the vaccination session is unreliable, you can record offline using a spreadsheet.\n\nYou need to download the blank spreadsheet ahead of the session while you still have internet access.\n\nTo upload a completed spreadsheet, go to the ‘Vaccinations’ area. You also need an internet connection to upload the spreadsheet.',
1953-
confirm: 'Download spreadsheet',
1953+
confirm: 'Download offline spreadsheet',
19541954
vaccinator: {
19551955
label: 'Vaccinator',
19561956
firstName: 'First name',

app/models/download.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,10 @@ export class Download {
117117
return `School moves (${this.formatted.createdAt})`
118118
case this.type === DownloadType.Report:
119119
return `${this.programme.name} vaccination records`
120-
case this.type === DownloadType.Session:
120+
case this.type === DownloadType.Session && this.session_id:
121121
return `Offline spreadsheet for ${this.session.name}`
122+
case this.type === DownloadType.Session:
123+
return `Offline spreadsheet for no known school (including home-schooled children)`
122124
default:
123125
return 'Download'
124126
}

app/views/school/show.njk

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,17 @@
6464
}) | safe
6565
}) }}
6666

67+
{{ button({
68+
classes: "nhsuk-button--secondary nhsuk-button--small",
69+
text: __("session.offline.confirm"),
70+
value: DownloadType.Session,
71+
decorate: "download.type",
72+
attributes: {
73+
formaction: "/downloads/new?referrer=" + school.uri,
74+
formmethod: "post"
75+
}
76+
}) if data.invitedToClinic and results.count > 0 }}
77+
6778
{% for patient in results.page %}
6879
{% set reportStatusHtml -%}
6980
{%- if data.programme_id %}

0 commit comments

Comments
 (0)