Skip to content

Commit 5006c9e

Browse files
VIA-867 SP/EO Reorder booking options for Covid
1 parent c9e5ac0 commit 5006c9e

2 files changed

Lines changed: 17 additions & 19 deletions

File tree

src/services/content-api/parsers/custom/covid-19.test.tsx

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -52,18 +52,10 @@ describe("buildFilteredContentForCovid19Vaccine", () => {
5252
];
5353

5454
const openActions = [
55-
{
56-
type: ActionDisplayType.infotext,
57-
content: [
58-
"## If this applies to you",
59-
"### Get vaccinated at your GP surgery",
60-
"Contact your GP surgery to book an appointment.",
61-
].join("\n\n") as Content,
62-
button: undefined,
63-
},
6455
{
6556
type: ActionDisplayType.nbsAuthLinkButtonWithInfo,
6657
content: [
58+
"## If this applies to you",
6759
"### Book an appointment online",
6860
"You can book an appointment online at some pharmacies, GP surgeries and vaccination centres.",
6961
].join("\n\n") as Content,
@@ -84,6 +76,13 @@ describe("buildFilteredContentForCovid19Vaccine", () => {
8476
) as ButtonUrl,
8577
},
8678
},
79+
{
80+
type: ActionDisplayType.infotext,
81+
content: ["### Get vaccinated at your GP surgery", "Contact your GP surgery to book an appointment."].join(
82+
"\n\n",
83+
) as Content,
84+
button: undefined,
85+
},
8786
];
8887

8988
const expected = {

src/services/content-api/parsers/custom/covid-19.tsx

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,18 +54,10 @@ export const buildFilteredContentForCovid19Vaccine = async (apiContent: string):
5454
async function _buildActions(): Promise<Action[]> {
5555
const nbsURL = (await buildNbsUrl(VaccineType.COVID_19)) as ButtonUrl;
5656

57-
const contactGP: ActionWithoutButton = {
58-
type: ActionDisplayType.infotext,
59-
content: [
60-
"## If this applies to you",
61-
"### Get vaccinated at your GP surgery",
62-
"Contact your GP surgery to book an appointment.",
63-
].join("\n\n") as Content,
64-
button: undefined,
65-
};
6657
const nbsBooking: ActionWithButton = {
6758
type: ActionDisplayType.nbsAuthLinkButtonWithInfo,
6859
content: [
60+
"## If this applies to you",
6961
"### Book an appointment online",
7062
"You can book an appointment online at some pharmacies, GP surgeries and vaccination centres.",
7163
].join("\n\n") as Content,
@@ -84,8 +76,15 @@ async function _buildActions(): Promise<Action[]> {
8476
) as ButtonUrl,
8577
},
8678
};
79+
const contactGP: ActionWithoutButton = {
80+
type: ActionDisplayType.infotext,
81+
content: ["### Get vaccinated at your GP surgery", "Contact your GP surgery to book an appointment."].join(
82+
"\n\n",
83+
) as Content,
84+
button: undefined,
85+
};
8786

88-
return [contactGP, nbsBooking, walkIn];
87+
return [nbsBooking, walkIn, contactGP];
8988
}
9089

9190
async function _buildPreOpenActions(): Promise<Action[]> {

0 commit comments

Comments
 (0)