Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 8c5a2a4

Browse files
committed
fix calendar name on thank you page
1 parent d0a35d6 commit 8c5a2a4

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

src/server/misc/routes/index.html

+5-5
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
font-size: 10pt;
1111
}
1212
.top-bar {
13-
margin-top: 20px;
13+
margin-top: 20px;
1414
display: flex;
1515
flex-direction: row;
1616
align-items: center;
@@ -61,7 +61,7 @@
6161
font-weight: 400;
6262
}
6363

64-
.slot-cancelview h4 {
64+
.slot-cancelview h4 {
6565
margin: 10px;
6666
font-size: 1.2rem;
6767
line-height: 1.7rem;
@@ -76,7 +76,7 @@
7676
flex: 1 1;
7777
}
7878

79-
.left-panel p{
79+
.left-panel p{
8080
opacity: 0.6;
8181
}
8282
.booking-summary {
@@ -101,7 +101,7 @@
101101
flex-direction: column;
102102
}
103103
.right-panel form {
104-
padding: 30px 70px 0;
104+
padding: 30px 70px 0;
105105
}
106106
.right-panel form h3 {
107107
margin-bottom: 15px;
@@ -154,7 +154,7 @@ <h2>
154154
<%= week %><br />
155155
<%= startDate %>
156156
</h2>
157-
<h4><%= startTime %> - <%= endTime %><br/><%= page_slug %> virtual calendar</h4>
157+
<h4><%= startTime %> - <%= endTime %><br/><%= calendarName %></h4>
158158
<p><%= tz %></p>
159159
</div>
160160
</div>

src/server/misc/routes/interview-thank-you-page.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,13 @@ async function getInterviewThankYouPageController(req, res) {
3030
const nylasconfig = JSON.parse(
3131
nylasHtml.match(/window.nylasWindowContext.page = (.*);<\/script>/)[1]
3232
);
33+
// get calendar name from timeslots
34+
const { data: timeslots } = await axios.get(
35+
`https://api.schedule.nylas.com/schedule/${query.page_slug}/timeslots?locale=en`
36+
);
3337
const object = {
3438
jobTitle: nylasconfig.name,
35-
page_slug: query.page_slug,
39+
calendarName: _.get(timeslots, '[0].host_name', ''),
3640
tz: query.tz,
3741
week: moment.unix(query.start_time).format("dddd"),
3842
startDate: moment.unix(query.start_time).format("MMMM DD, yyyy"),

0 commit comments

Comments
 (0)